
D.15.21.1 RiemannRochHess
Procedure from library hess.lib (see hess_lib).
 Note:
 All fractional ideals must represented by a list of size two.
The first element is an ideal of k[x,y] and the second element
the common denominator, i.e, a polynomial of k[x].
 Assume:
 The base ring R must be a ring in two variables, say x,y,
or three variables, say x,y,z.
If nvars(R) = 2:
 f is an absolutely irreducible polynomial, monic as a
polynomial in y.
 List divisorD describes a divisor D of F = Quot(k[x,y]/f).
If (s = "ideals")
D is given in ideal representation, i.e., divisorD is a
list of size 2.
divisorD[1] is the finite ideal of D, i.e., the
fractional ideal of D of IntCl(k[x],F).
divisorD[2] is the infinite ideal of D, i.e,
the fractional ideal of D of IntCl(k[1/x],F).
If (s = "free")
D is given in free representation, i.e., divisorD is a list
of size 2, containing the finite and infinite places of D
with exponents.
divisorD[i], i = 1,2, is a list. Each element of the list
is again a list. The first entry is a fractional ideal,
and the second an integer, the exponent of the place.
If nvars(R) = 3:
 f is an absolutely irreducible homogeneous polynomial
describing the projective plane curve corresponding to
the function field F. We assume that the dehomogenization
of f w.r.t. z is monic as a polynomial in y.
List divisorD describes a divisor D of F.
If (s = "ideals")
D is given in ideal representation, i.e., divisorD is
a list of size 2. divisorD[1] is an ideal of the base
ring representing the positive divisor of D and
divisorD[2] is an ideal of the base ring representing the
negative divisor. (i.e. D = (I) (J)).
If (s = "free")
D is given in free representation, i.e., divisorD is a
list of places of D. D[i][1] is an prime ideal and D[i][2]
an integer, the exponent of the place.
 Return:
 A vector space basis of the RiemannRoch space of D,
stored in a list RRBasis. The list RRBasis contains a
list, say rbasis, and a polynomial, say den. The basis of
L(D) consists of all rational functions g/den, where g is
an element of rbasis.
Example:
 LIB "hess.lib";
ring R = 0,(x,y),dp;
poly f = y^2*(y1)^3x^5;
list A1 = list(ideal(x,y1),1),2;
list A2 = list(ideal(y^2y+1,x),1),3;
list A3 = list(ideal(1,yx),x),2;
list D = A1,A2;
list E = list(A3);
RiemannRochHess(f,list(D,E),"free");
==> // ** redefining Infin ( list Infin = maxorderInfinite(f_aff);)
==> [1]:
==> [1]:
==> 5x2y35xy45x2y2+10xy32y45xy2+4y32y2
==> [2]:
==> 2x3y2+x2y33xy42x3yx2y2+6xy33xy2
==> [3]:
==> 5x3y25xy44x3y+10xy35xy2
==> [4]:
==> 5x4y5xy4x3y+10xy35xy2
==> [5]:
==> x5+2x4y3xy4+6xy33xy2
==> [2]:
==> x5
ring S = 0,(x,y,z),dp;
poly f = y^2*(y1)^3x^5;
f = homog(f,z);
ideal P1 = x,yz;
ideal P2 = y^2yz+z^2,x;
ideal P3 = xy,z;
list B1 = P1,2;
list B2 = P2,3;
list B3 = P3,2;
list Ddivisor = B1,B2,B3;
RiemannRochHess(f,Ddivisor,"free");
==> [1]:
==> [1]:
==> 5x2y35xy45x2y2+10xy32y45xy2+4y32y2
==> [2]:
==> 2x3y2+x2y33xy42x3yx2y2+6xy33xy2
==> [3]:
==> 5x3y25xy44x3y+10xy35xy2
==> [4]:
==> 5x4y5xy4x3y+10xy35xy2
==> [5]:
==> x5+2x4y3xy4+6xy33xy2
==> [2]:
==> x5
ideal I = intersect(P1^2,P2^3);
ideal J = P3^2;
RiemannRochHess(f,list(I,J),"ideals");
==> [1]:
==> [1]:
==> 5x2y35xy45x2y2+10xy32y45xy2+4y32y2
==> [2]:
==> 2x3y2+x2y33xy42x3yx2y2+6xy33xy2
==> [3]:
==> 5x3y25xy44x3y+10xy35xy2
==> [4]:
==> 5x4y5xy4x3y+10xy35xy2
==> [5]:
==> x5+2x4y3xy4+6xy33xy2
==> [2]:
==> x5

