| #### D.12.4.9 cantoradd Procedure from library `hyperel.lib` (see hyperel_lib). Usage: cantoradd(D,Q,h,f); Return: list P Note: Cantor's Algorithm - composition important: D and Q have to be semireduced! Computes semireduced divisor div(P[1],P[2])= div(D[1],D[2]) + div(Q[1],Q[2]) The divisors are defined over the basering. Curve C: y^2+h(x)y=f(x) is defined over the basering. Example:
    LIB "hyperel.lib";
    ring R=7,x,dp;
    // hyperelliptic curve y^2 + h*y = f
    poly h=x;
    poly f=x5+5x4+6x2+x+3;
    // two divisors in rational representation
    list D=x2-1,2x-1;
    list Q=x2-3x+2,-3x+1;
    cantoradd(D,Q,h,f);
    ==> [1]:
    ==>    x2-x-2
    ==> [2]:
    ==>    -3x+1

User manual for Singular version 4-0-2, 2015, generated by texi2html.