SD14: Algebraic schemes
system:sage

{{{id=0|
P2.<x,y,z> = ProjectiveSpace(QQ, 2)
S = P2.subscheme([y^2*z-x^3+x*z^2]); S
///
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  -x^3 + y^2*z + x*z^2
}}}

{{{id=2|
type(S)
///
<class 'sage.schemes.generic.algebraic_scheme.AlgebraicScheme_subscheme_projective'>
}}}

{{{id=41|
isinstance(S, sage.schemes.generic.algebraic_scheme.AlgebraicScheme)
///
True
}}}

{{{id=3|
S.defining_ideal()
///
Ideal (-x^3 + y^2*z + x*z^2) of Multivariate Polynomial Ring in x, y, z over Rational Field
}}}

{{{id=4|
S.coordinate_ring()
///
Quotient of Multivariate Polynomial Ring in x, y, z over Rational Field by the ideal (-x^3 + y^2*z + x*z^2)
}}}

{{{id=5|
S.dimension()
///
1
}}}

{{{id=6|
S.irreducible_components()
///
[
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  x^3 - y^2*z - x*z^2
]
}}}

{{{id=7|
len(S.irreducible_components())
///
1
}}}

{{{id=8|
S.rational_points(bound=3)
///
[(0 : 0 : 1), (1 : 0 : 1), (-1 : 0 : 1), (0 : 1 : 0)]
}}}

{{{id=11|
T = P2.subscheme([y]); T
///
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  y
}}}

{{{id=13|
T.dimension()
///
1
}}}

{{{id=14|
T.irreducible_components()
///
[
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  y
]
}}}

{{{id=15|
X = S.intersection(T); X
///
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  -x^3 + y^2*z + x*z^2
  y
}}}

{{{id=17|
X.dimension()
///
0
}}}

{{{id=18|
X.irreducible_components()
///
[
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  y
  x,
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  y
  x - z,
Closed subscheme of Projective Space of dimension 2 over Rational Field defined by:
  y
  x + z
]
}}}

{{{id=19|
X.rational_points(bound=2)
///
[(0 : 0 : 1), (1 : 0 : 1), (-1 : 0 : 1)]
}}}

{{{id=24|
# check Bezout
len(X.irreducible_components()) == S.defining_polynomials()[0].degree() * T.defining_polynomials()[0].degree()
///
True
}}}

{{{id=27|
P2.<x,y,z> = ProjectiveSpace(ZZ, 2)
S = P2.subscheme([y^2*z-x^3+x*z^2]); S
///
Closed subscheme of Projective Space of dimension 2 over Integer Ring defined by:
  -x^3 + y^2*z + x*z^2
}}}

{{{id=28|
# base change
S5 = S/GF(5); S5
///
Closed subscheme of Projective Space of dimension 2 over Finite Field of size 5 defined by:
  -x^3 + y^2*z + x*z^2
}}}

{{{id=30|
S5.count_points(3)
///
[8, 32, 104]
}}}

{{{id=31|
R.<t> = ZZ[[]]
S5.zeta_series(3, t)
///
1 + 8*t + 48*t^2 + 248*t^3 + O(t^4)
}}}

{{{id=34|
R.<x> = QQ[]
J = HyperellipticCurve(x^6+x-1).jacobian(); J
///
Jacobian of Hyperelliptic Curve over Rational Field defined by y^2 = x^6 + x - 1
}}}

{{{id=36|
# defined by equations? no
isinstance(J, sage.schemes.generic.algebraic_scheme.AlgebraicScheme)
///
False
}}}

{{{id=37|
isinstance(J, sage.schemes.generic.scheme.Scheme)
///
True
}}}

{{{id=38|
P.<x> = QQ[]
R = P.quotient(Ideal(x^2))
S = Spec(R); S
///
Spectrum of Univariate Quotient Polynomial Ring in xbar over Rational Field with modulus x^2
}}}

{{{id=40|

///
}}}