37.3 Plane curves over a general ring

Module: sage.schemes.plane_curves.projective_curve

Plane curves over a general ring

Author Log:

Class: ProjectiveCurve_finite_field

class ProjectiveCurve_finite_field

Functions: rational_points

rational_points( self, [algorithm=enum], [sort=True])

Return the rational points on this curve computed via enumeration.

Note: This is a slow Python-level implementation.

Class: ProjectiveCurve_generic

class ProjectiveCurve_generic
ProjectiveCurve_generic( self, A, f)

Functions: arithmetic_genus,$ \,$ divisor_of_function,$ \,$ local_coordinates

arithmetic_genus( self)

Return the arithmetic genus of this curve.

This is the arithmetic genus $ g_a(C)$ as defined in Hartshorne. If the curve has degree $ d$ then this is simply $ (d-1)(d-2)/2$ . It need not equal the geometric genus (the genus of the normalize of the curve).

sage: x,y,z = PolynomialRing(GF(5), 3, 'xyz').gens()
sage: C = Curve(y^2*z^7 - x^9 - x*z^8); C
Projective Curve over Finite Field of size 5 defined by -x^9 + y^2*z^7 -
x*z^8
sage: C.arithmetic_genus()
28
sage: C.genus()
4

divisor_of_function( self, r)

Return the divisor of a function on a curve.

Input: r is a rational function on X

Output:

list
- The divisor of r represented as a list of coefficients and points. (TODO: This will change to a more structural output in the future.)

sage: FF = FiniteField(5)
sage: P2 = ProjectiveSpace(2, FF, names = ['x','y','z'])
sage: R = P2.coordinate_ring()
sage: x, y, z = R.gens()
sage: f = y^2*z^7 - x^9 - x*z^8
sage: C = Curve(f)
sage: K = FractionField(R)
sage: r = 1/x
sage: C.divisor_of_function(r)     # todo: not implemented  !!!!
[[-1, (0, 0, 1)]]
sage: r = 1/x^3
sage: C.divisor_of_function(r)     # todo: not implemented  !!!!
[[-3, (0, 0, 1)]]

local_coordinates( self, pt, n)

Return local coordinates to precision n at the given point.


\begin{note}
{\bf Behaviour is flakey} - some choices of $n$\ are worst that others.
\end{note}

Input:

pt
- an F-rational point on X which is not a point of ramification for the projection (x,y) -> x.
n
- the number of terms desired

Output: x = x0 + t y = y0 + power series in t

sage: FF = FiniteField(5)   
sage: P2 = ProjectiveSpace(2, FF, names = ['x','y','z'])
sage: x, y, z = P2.coordinate_ring().gens()
sage: C = Curve(y^2*z^7-x^9-x*z^8)
sage: pt = C([2,3,1])
sage: C.local_coordinates(pt,9)     # todo: not implemented  !!!!
      [2 + t, 3 + 3*t^2 + t^3 + 3*t^4 + 3*t^6 + 3*t^7 + t^8 + 2*t^9 +
3*t^11 + 3*t^12]

Special Functions: __init__,$ \,$ _repr_type

Class: ProjectiveCurve_prime_finite_field

class ProjectiveCurve_prime_finite_field

Functions: rational_points,$ \,$ riemann_roch_basis

rational_points( self, [algorithm=enum], [sort=True])

Input:

algorithm
- string:
'enum'
- straightforward enumeration
'bn'
- via Singular's brnoeth package.

sage: x, y, z = PolynomialRing(GF(5), 3, 'xyz').gens()
sage: f = y^2*z^7 - x^9 - x*z^8
sage: C = Curve(f); C
Projective Curve over Finite Field of size 5 defined by -x^9 + y^2*z^7 -
x*z^8
sage: C.rational_points()
[(0 : 0 : 1), (0 : 1 : 0), (2 : 2 : 1), (2 : 3 : 1), (3 : 1 : 1), (3 : 4 :
1)]
sage: C = Curve(x - y + z)
sage: C.rational_points()
[(0 : 1 : 1), (1 : 1 : 0), (1 : 2 : 1), (2 : 3 : 1), (3 : 4 : 1), (4 : 0 :
1)]

Note: The Brill-Noether package does not always work (i.e., the 'bn' algorithm. When it fails a RuntimeError exception is raised.

riemann_roch_basis( self, D)

Return a basis for the Riemann-Roch space corresponding to $ D$ .

Note: ** WARNING: This function calls a Singular function that appears to be very buggy and should not be trusted. **

This uses Singular's Brill-Noether implementation.

Input:

sort
- bool (default: True), if True return the point list sorted. If False, returns the pointes in the order computed by Singular.

sage: R.<x,y,z> = GF(2)[]
sage: f = x^3*y + y^3*z + x*z^3
sage: C = Curve(f); pts = C.rational_points()
sage: D = C.divisor([ (4, pts[0]), (0,pts[1]), (4, pts[2]) ])
sage: C.riemann_roch_basis(D)
[x/y, 1, z/y, z^2/y^2, z/x, z^2/(x*y)]

The following example illustrates that the Riemann-Roch space function in Singular doesn't not work correctly.

sage: R.<x,y,z> = GF(5)[]
sage: f = x^7 + y^7 + z^7
sage: C = Curve(f); pts = C.rational_points()
sage: D = C.divisor([ (3, pts[0]), (-1,pts[1]), (10, pts[5]) ])
sage: C.riemann_roch_basis(D)    # output is random (!!!!)
[x/(y + x), (z + y)/(y + x)]

The answer has dimension 2 (confirmed via Magma). But it varies between 1 and quite large with Singular.

Special Functions: _points_via_singular

_points_via_singular( self, [sort=True])

Return all rational points on this curve, computed using Singular's Brill-Noether implementation.

Input:

sort
- bool (default: True), if True return the point list sorted. If False, returns the pointes in the order computed by Singular.

sage: x, y, z = PolynomialRing(GF(5), 3, 'xyz').gens()
sage: f = y^2*z^7 - x^9 - x*z^8
sage: C = Curve(f); C
Projective Curve over Finite Field of size 5 defined by -x^9 + y^2*z^7 -
x*z^8
sage: C._points_via_singular()
[(0 : 0 : 1), (0 : 1 : 0), (2 : 2 : 1), (2 : 3 : 1), (3 : 1 : 1), (3 : 4 :
1)]
sage: v = C._points_via_singular(sort=True)     
sage: v
[(0 : 0 : 1), (0 : 1 : 0), (2 : 2 : 1), (2 : 3 : 1), (3 : 1 : 1), (3 : 4 :
1)]

Note: The Brill-Noether package does not always work (i.e., the 'bn' algorithm. When it fails a RuntimeError exception is raised.

Class: ProjectiveSpaceCurve_generic

class ProjectiveSpaceCurve_generic
ProjectiveSpaceCurve_generic( self, A, X)

Special Functions: __init__,$ \,$ _repr_type

See About this document... for information on suggesting changes.