Changeset 5638b9 in git


Ignore:
Timestamp:
May 25, 2015, 8:32:35 PM (8 years ago)
Author:
Stephan Oberfranz <oberfran@…>
Branches:
(u'spielwiese', '8e0ad00ce244dfd0756200662572aef8402f13d5')
Children:
2c2d2e89ad6e29cc2a1d2903129b937241868370
Parents:
2675bd98cab28ad9ecfd872518826ad7e66b1935cb5589680933f4ddf0d5ae8b00c76e50b54220da
Message:
update

Merge branch 'spielwiese' of github.com:Singular/Sources into spielwiese
Files:
62 edited

Legend:

Unmodified
Added
Removed
  • Singular/LIB/deRham.lib

    r2675bd r5638b9  
    33category="Noncommutative";
    44info="
    5 LIBRARY:  derham.lib      Computation of deRham cohomology
     5LIBRARY:  deRham.lib      Computation of deRham cohomology
    66
    77AUTHORS:  Cornelia Rottner, rottner@mathematik.uni-kl.de
     
    1616     localzation, and local cohomology groups}, J. Pure Appl. Algebra 156, 267-308
    1717     (2001)
    18 [R]  Rottner, C.: Computing de Rham Cohomology,diploma thesis (2012)
     18[R]  Rottner, C.: Computing de Rham Cohomology,diploma thesis (2012)@*
    1919[W1] Walther, U.: Algorithmic computation of local cohomology modules and the local
    2020     cohomological dimension of algebraic varieties}, J. Pure Appl. Algebra 139,
    21      303-321 (1999)
     21     303-321 (1999)@*
    2222[W2] Walther, U.: Algorithmic computation of de Rham Cohomology of Complements of
    23      Complex Affine Varieties}, J. Symbolic Computation 29, 796-839 (2000)
     23     Complex Affine Varieties}, J. Symbolic Computation 29, 796-839 (2000)@*
    2424[W3] Walther, U.: Computing the cup product structure for complements of complex
    2525     affine varieties, J. Pure Appl. Algebra 164, 247-273 (2001)
  • Singular/LIB/grwalk.lib

    rcb5589 r5638b9  
    255255}
    256256
    257 proc gwalk(ideal Go, list #)
    258 "SYNTAX: gwalk(ideal i);
    259          gwalk(ideal i, intvec v, intvec w);
     257proc gwalk(ideal Go, int reduction,int printout, list #)
     258"SYNTAX: gwalk(ideal i, int reduction, int printout);
     259         gwalk(ideal i, int reduction, int printout, intvec v, intvec w);
    260260TYPE:    ideal
    261261PURPOSE: compute the standard basis of the ideal, calculated via
     
    274274   string ord_str =   OSCTW[2];
    275275   intvec curr_weight   =   OSCTW[3]; /* original weight vector */
    276    intvec target_weight =   OSCTW[4]; /* terget weight vector */
     276   intvec target_weight =   OSCTW[4]; /* target weight vector */
    277277   kill OSCTW;
    278278   option(redSB);
     
    284284   //print("//** help ring = " + string(basering));
    285285   ideal G = fetch(xR, Go);
    286    G = system("Mwalk", G, curr_weight, target_weight,basering);
     286   G = system("Mwalk", G, curr_weight, target_weight,basering,reduction,printout);
    287287
    288288   setring xR;
     
    299299  //** compute a Groebner basis of I w.r.t. lp.
    300300  ring r = 32003,(z,y,x), lp;
    301   ideal I = y3+xyz+y2z+xz3, 3+xy+x2y+y2z;
    302   gwalk(I);
     301  ideal I = zy2+yx2+yx+3,
     302            z3x+y3+zyx-yx2-yx-3,
     303            z2yx3-y5+z2yx2+y3x2+y2x3+y3x+y2x2+3z2x+3y2+3yx,
     304            zyx5+y6-y4x2-y3x3+2zyx4-y4x-y3x2+zyx3-3z2yx+3zx3-3y3-3y2x+3zx2,
     305            yx7-y7+y5x2+y4x3+3yx6+y5x+y4x2+3yx5-6zyx3+yx4+3x5+3y4+3y3x-6zyx2+6x4+3x3-9zx;
     306  gwalk(I,0,1);
    303307}
    304308
     
    346350}
    347351
    348 proc fwalk(ideal Go, list #)
    349 "SYNTAX: fwalk(ideal i);
    350          fwalk(ideal i, intvec v, intvec w);
     352proc fwalk(ideal Go, int reduction, int printout, list #)
     353"SYNTAX: fwalk(ideal i,int reductioin);
     354         fwalk(ideal i, int reduction intvec v, intvec w);
    351355TYPE:    ideal
    352356PURPOSE: compute the standard basis of the ideal w.r.t. the
     
    372376
    373377   ideal G = fetch(xR, Go);
    374    G = system("Mfwalk", G, curr_weight, target_weight);
     378   G = system("Mfwalk", G, curr_weight, target_weight, reduction, printout);
    375379
    376380   setring xR;
     
    387391    ring r = 32003,(z,y,x), lp;
    388392    ideal I = y3+xyz+y2z+xz3, 3+xy+x2y+y2z;
    389     fwalk(I);
     393    int reduction = 1;
     394    int printout = 1;
     395    fwalk(I,reduction,printout);
    390396}
    391397
     
    437443}
    438444
    439 proc pwalk(ideal Go, int n1, int n2, list #)
    440 "SYNTAX: pwalk(int d, ideal i, int n1, int n2);
    441          pwalk(int d, ideal i, int n1, int n2, intvec v, intvec w);
     445proc pwalk(ideal Go, int n1, int n2, int reduction, int printout, list #)
     446"SYNTAX: pwalk(int d, ideal i, int n1, int n2, int reduction, int printout);
     447         pwalk(int d, ideal i, int n1, int n2, int reduction, int printout, intvec v, intvec w);
    442448TYPE:    ideal
    443449PURPOSE: compute the standard basis of the ideal, calculated via
     
    477483  ideal G = fetch(xR, Go);
    478484
    479   G = system("Mpwalk", G, n1, n2, curr_weight, target_weight,nP);
    480 
     485  G = system("Mpwalk",G,n1,n2,curr_weight,target_weight,nP,reduction,printout);
     486 
    481487  setring xR;
    482   //kill Go;
     488  //kill Go; //unused
    483489
    484490  keepring basering;
     
    492498    ring r = 32003,(z,y,x), lp;
    493499    ideal I = y3+xyz+y2z+xz3, 3+xy+x2y+y2z;
    494     //I = std(I);
    495     //ring rr = 32003,(z,y,x),lp;
    496     //ideal I = fetch(r,I);
    497     pwalk(I,2,2);
     500    int reduction = 1;
     501    int printout = 2;
     502    pwalk(I,2,2,reduction,printout);
    498503}
    499504
  • Singular/LIB/modwalk.lib

    • Property mode changed from 100644 to 100755
    rcb5589 r5638b9  
    1616
    1717PROCEDURES:
    18 modWalk(ideal,int,int[,int,int,int,int]);        standard basis conversion of I using modular methods (chinese remainder)
     18
     19modWalk(I,#);                   standard basis conversion of I by Groebner Walk using modular methods
     20modrWalk(I,radius,pertdeg,#);   standard basis conversion of I by Random Walk using modular methods
     21modfWalk(I,#);                  standard basis conversion of I by Fractal Walk using modular methods
     22modfrWalk(I,radius,#);          standard basis conversion of I by Random Fractal Walk using modular methods
    1923";
    2024
    21 LIB "poly.lib";
    22 LIB "ring.lib";
    23 LIB "parallel.lib";
    2425LIB "rwalk.lib";
    2526LIB "grwalk.lib";
    26 LIB "modstd.lib";
    27 
    28 
    29 ////////////////////////////////////////////////////////////////////////////////
    30 
    31 static proc modpWalk(def II, int p, int variant, list #)
    32 "USAGE:  modpWalk(I,p,#); I ideal, p integer, variant integer
    33 ASSUME:  If size(#) > 0, then
    34            #[1] is an intvec describing the current weight vector
    35            #[2] is an intvec describing the target weight vector
    36 RETURN:  ideal - a standard basis of I mod p, integer - p
    37 NOTE:    The procedure computes a standard basis of the ideal I modulo p and
    38          fetches the result to the basering.
    39 EXAMPLE: example modpWalk; shows an example
    40 "
    41 {
    42   option(redSB);
    43   int k,nvar@r;
    44   def R0 = basering;
    45   string ordstr_R0 = ordstr(R0);
    46   list rl = ringlist(R0);
    47   int sizerl = size(rl);
    48   int neg = 1 - attrib(R0,"global");
    49   if(typeof(II) == "ideal")
    50   {
    51     ideal I = II;
     27LIB "modular.lib";
     28
     29proc modWalk(ideal I, list #)
     30"USAGE:   modWalk(I, [, v, w]); I ideal, v intvec, w intvec
     31RETURN:   a standard basis of I
     32NOTE:     The procedure computes a standard basis of I (over the rational
     33          numbers) by using modular methods.
     34SEE ALSO: modular
     35EXAMPLE:  example modWalk; shows an example"
     36{
     37    /* read optional parameter */
     38    if (size(#) > 0) {
     39        if (size(#) == 1) {
     40            intvec w = #[1];
     41        }
     42        if (size(#) == 2) {
     43            intvec v = #[1];
     44            intvec w = #[2];
     45        }
     46        if (size(#) > 2 || typeof(#[1]) != "intvec") {
     47            ERROR("wrong optional parameter");
     48        }
     49    }
     50
     51    /* save options */
     52    intvec opt = option(get);
     53    option(redSB);
     54
     55    /* set additional parameters */
     56    int reduction = 1;
     57    int printout = 0;
     58
     59    /* call modular() */
     60    if (size(#) > 0) {
     61        I = modular("gwalk", list(I,reduction,printout,#));
     62    }
     63    else {
     64        I = modular("gwalk", list(I,reduction,printout));
     65    }
     66
     67    /* return the result */
     68    attrib(I, "isSB", 1);
     69    option(set, opt);
     70    return(I);
     71}
     72example
     73{
     74    "EXAMPLE:";
     75    echo = 2;
     76    ring R1 = 0, (x,y,z,t), dp;
     77    ideal I = 3x3+x2+1, 11y5+y3+2, 5z4+z2+4;
     78    I = std(I);
     79    ring R2 = 0, (x,y,z,t), lp;
     80    ideal I = fetch(R1, I);
     81    ideal J = modWalk(I);
     82    J;
     83}
     84
     85proc modrWalk(ideal I, int radius, int pertdeg, list #)
     86"USAGE:   modrWalk(I, radius, pertdeg[, v, w]);
     87          I ideal, radius int, pertdeg int, v intvec, w intvec
     88RETURN:   a standard basis of I
     89NOTE:     The procedure computes a standard basis of I (over the rational
     90          numbers) by using modular methods.
     91SEE ALSO: modular
     92EXAMPLE:  example modrWalk; shows an example"
     93{
     94    /* read optional parameter */
     95    if (size(#) > 0) {
     96        if (size(#) == 1) {
     97            intvec w = #[1];
     98        }
     99        if (size(#) == 2) {
     100            intvec v = #[1];
     101            intvec w = #[2];
     102        }
     103        if (size(#) > 2 || typeof(#[1]) != "intvec") {
     104            ERROR("wrong optional parameter");
     105        }
     106    }
     107
     108    /* save options */
     109    intvec opt = option(get);
     110    option(redSB);
     111
     112    /* set additional parameters */
     113    int reduction = 1;
     114    int printout = 0;
     115
     116    /* call modular() */
     117    if (size(#) > 0) {
     118        I = modular("rwalk", list(I,radius,pertdeg,reduction,printout,#));
     119    }
     120    else {
     121        I = modular("rwalk", list(I,radius,pertdeg,reduction,printout));
     122    }
     123
     124    /* return the result */
     125    attrib(I, "isSB", 1);
     126    option(set, opt);
     127    return(I);
     128}
     129example
     130{
     131    "EXAMPLE:";
     132    echo = 2;
     133    ring R1 = 0, (x,y,z,t), dp;
     134    ideal I = 3x3+x2+1, 11y5+y3+2, 5z4+z2+4;
     135    I = std(I);
     136    ring R2 = 0, (x,y,z,t), lp;
     137    ideal I = fetch(R1, I);
    52138    int radius = 2;
    53     int pert_deg = 2;
    54   }
    55   if(typeof(II) == "list" && typeof(II[1]) == "ideal")
    56   {
    57     ideal I = II[1];
    58     if(size(II) == 2)
    59     {
    60       int radius = II[2];
    61       int pert_deg = 2;
    62     }
    63     if(size(II) == 3)
    64     {
    65       int radius = II[2];
    66       int pert_deg = II[3];
    67     }
    68   }
    69   rl[1] = p;
    70   int h = homog(I);
    71   def @r = ring(rl);
    72   setring @r;
    73   ideal i = fetch(R0,I);
    74   string order;
    75   if(system("nblocks") <= 2)
    76   {
    77     if(find(ordstr_R0, "M") + find(ordstr_R0, "lp") + find(ordstr_R0, "rp") <= 0)
    78     {
    79       order = "simple";
    80     }
    81   }
    82 
    83 //-------------------------  make i homogeneous  -----------------------------
    84   if(!mixedTest() && !h)
    85   {
    86     if(!((find(ordstr_R0, "M") > 0) || (find(ordstr_R0, "a") > 0) || neg))
    87     {
    88       if(!((order == "simple") || (sizerl > 4)))
    89       {
    90         list rl@r = ringlist(@r);
    91         nvar@r = nvars(@r);
    92         intvec w;
    93         for(k = 1; k <= nvar@r; k++)
    94         {
    95           w[k] = deg(var(k));
    96         }
    97         w[nvar@r + 1] = 1;
    98         rl@r[2][nvar@r + 1] = "homvar";
    99         rl@r[3][2][2] = w;
    100         def HomR = ring(rl@r);
    101         setring HomR;
    102         ideal i = imap(@r, i);
    103         i = homog(i, homvar);
    104       }
    105     }
    106   }
    107 
    108 //-------------------------  compute a standard basis mod p  -----------------------------
    109 
    110   if(variant == 1)
    111   {
    112     if(size(#)>0)
    113     {
    114       i = rwalk(i,radius,pert_deg,#);
    115      // rwalk(i,radius,pert_deg,#); std(i);
    116     }
    117     else
    118     {
    119       i = rwalk(i,radius,pert_deg);
    120     }
    121   }
    122   if(variant == 2)
    123   {
    124     if(size(#) == 2)
    125     {
    126       i = gwalk(i,#);
    127     }
    128     else
    129     {
    130       i = gwalk(i);
    131     }
    132   }
    133   if(variant == 3)
    134   {
    135     if(size(#) == 2)
    136     {
    137       i = frandwalk(i,radius,#);
    138     }
    139     else
    140     {
    141       i = frandwalk(i,radius);
    142     }
    143   }
    144   if(variant == 4)
    145   {
    146     if(size(#) == 2)
    147     {
    148       i=fwalk(i,#);
    149     }
    150     else
    151     {
    152       i=fwalk(i);
    153     }
    154   }
    155   if(variant == 5)
    156   {
    157     if(size(#) == 2)
    158     {
    159      i=prwalk(i,radius,pert_deg,pert_deg,#);
    160     }
    161     else
    162     {
    163       i=prwalk(i,radius,pert_deg,pert_deg);
    164     }
    165   }
    166   if(variant == 6)
    167   {
    168     if(size(#) == 2)
    169     {
    170       i=pwalk(i,pert_deg,pert_deg,#);
    171     }
    172     else
    173     {
    174       i=pwalk(i,pert_deg,pert_deg);
    175     }
    176   }
    177 
    178   if(!mixedTest() && !h)
    179   {
    180     if(!((find(ordstr_R0, "M") > 0) || (find(ordstr_R0, "a") > 0) || neg))
    181     {
    182       if(!((order == "simple") || (sizerl > 4)))
    183       {
    184         i = subst(i, homvar, 1);
    185         i = simplify(i, 34);
    186         setring @r;
    187         i = imap(HomR, i);
    188         i = interred(i);
    189         kill HomR;
    190       }
    191     }
    192   }
    193   setring R0;
    194   return(list(fetch(@r,i),p));
    195 }
    196 example
    197 {
    198   "EXAMPLE:"; echo = 2;
    199   option(redSB);
    200 
    201   int p = 181;
    202   intvec a = 2,1,3,4;
    203   intvec b = 1,9,1,1;
    204   ring ra = 0,x(1..4),(a(a),lp);
    205   ideal I = std(cyclic(4));
    206   ring rb = 0,x(1..4),(a(b),lp);
    207   ideal I = imap(ra,I);
    208   modpWalk(I,p,1,a,b);
    209   std(I);
    210 }
    211 
    212 ////////////////////////////////////////////////////////////////////////////////
    213 
    214 proc modWalk(def II, int variant, list #)
    215 "USAGE:  modWalk(II); II ideal or list(ideal,int)
    216 ASSUME:  If variant =
    217 @*       - 1 the Random Walk algorithm with radius II[2] is applied
    218            to II[1] if II = list(ideal, int). It is applied to II with radius 2
    219            if II is an ideal.
    220 @*       - 2, the Groebner Walk algorithm is applied to II[1] or to II, respectively.
    221 @*       - 3, the Fractal Walk algorithm with random element is applied to II[1] or II,
    222            respectively.
    223 @*       - 4, the Fractal Walk algorithm is applied to II[1] or II, respectively.
    224 @*       - 5, the Perturbation Walk algorithm with random element is applied to II[1]
    225            or II, respectively, with radius II[3] and perturbation degree II[2].
    226 @*       - 6, the Perturbation Walk algorithm is applied to II[1] or II, respectively,
    227            with perturbation degree II[3].
    228          If size(#) > 0, then # contains either 1, 2 or 4 integers such that
    229 @*       - #[1] is the number of available processors for the computation,
    230 @*       - #[2] is an optional parameter for the exactness of the computation,
    231                 if #[2] = 1, the procedure computes a standard basis for sure,
    232 @*       - #[3] is the number of primes until the first lifting,
    233 @*       - #[4] is the constant number of primes between two liftings until
    234            the computation stops.
    235 RETURN:  a standard basis of I if no warning appears.
    236 NOTE:    The procedure converts a standard basis of I (over the rational
    237          numbers) from the ordering \"a(v),lp\", "dp\" or \"Dp\" to the ordering
    238          \"(a(w),lp\" or \"a(1,0,...,0),lp\" by using modular methods.
    239          By default the procedure computes a standard basis of I for sure, but
    240          if the optional parameter #[2] = 0, it computes a standard basis of I
    241          with high probability.
    242 EXAMPLE: example modWalk; shows an example
    243 "
    244 {
    245   int TT = timer;
    246   int RT = rtimer;
    247   int i,j,pTest,sizeTest,weighted,n1;
    248   bigint N;
    249 
    250   def R0 = basering;
    251   list rl = ringlist(R0);
    252   if((npars(R0) > 0) || (rl[1] > 0))
    253   {
    254     ERROR("Characteristic of basering should be zero, basering should have no parameters.");
    255   }
    256 
    257   if(typeof(II) == "ideal")
    258   {
    259     ideal I = II;
    260     kill II;
    261     list II;
    262     II[1] = I;
    263     II[2] = 2;
    264     II[3] = 2;
    265   }
    266   else
    267   {
    268     if(typeof(II) == "list" && typeof(II[1]) == "ideal")
    269     {
    270       ideal I = II[1];
    271       if(size(II) == 1)
    272       {
    273         II[2] = 2;
    274         II[3] = 2;
    275       }
    276       if(size(II) == 2)
    277       {
    278         II[3] = 2;
    279       }
    280 
    281     }
    282     else
    283     {
    284       ERROR("Unexpected type of input.");
    285     }
    286   }
    287 
    288 //--------------------  Initialize optional parameters  ------------------------
    289   n1 = system("--cpus");
    290   if(size(#) == 0)
    291   {
    292     int exactness = 1;
    293     int n2 = 10;
    294     int n3 = 10;
    295   }
    296   else
    297   {
    298     if(size(#) == 1)
    299     {
    300       if(typeof(#[1]) == "int")
    301       {
    302         if(#[1] < n1)
    303         {
    304           n1 = #[1];
    305         }
    306         int exactness = 1;
    307         if(n1 >= 10)
    308         {
    309           int n2 = n1 + 1;
    310           int n3 = n1;
    311         }
    312         else
    313         {
    314           int n2 = 10;
    315           int n3 = 10;
    316         }
    317       }
    318       else
    319       {
    320         ERROR("Unexpected type of input.");
    321       }
    322     }
    323     if(size(#) == 2)
    324     {
    325       if(typeof(#[1]) == "int" && typeof(#[2]) == "int")
    326       {
    327         if(#[1] < n1)
    328         {
    329           n1 = #[1];
    330         }
    331         int exactness = #[2];
    332         if(n1 >= 10)
    333         {
    334           int n2 = n1 + 1;
    335           int n3 = n1;
    336         }
    337         else
    338         {
    339           int n2 = 10;
    340           int n3 = 10;
    341         }
    342       }
    343       else
    344       {
    345         if(typeof(#[1]) == "intvec" && typeof(#[2]) == "intvec")
    346         {
    347           intvec curr_weight = #[1];
    348           intvec target_weight = #[2];
    349           weighted = 1;
    350           int n2 = 10;
    351           int n3 = 10;
    352           int exactness = 1;
    353         }
    354         else
    355         {
    356           ERROR("Unexpected type of input.");
    357         }
    358       }
    359     }
    360     if(size(#) == 3)
    361     {
    362       if(typeof(#[1]) == "intvec" && typeof(#[2]) == "intvec" && typeof(#[3]) == "int")
    363       {
    364         intvec curr_weight = #[1];
    365         intvec target_weight = #[2];
    366         weighted = 1;
    367         n1 = #[3];
    368         int n2 = 10;
    369         int n3 = 10;
    370         int exactness = 1;
    371       }
    372       else
    373       {
    374         ERROR("Unexpected type of input.");
    375       }
    376     }
    377     if(size(#) == 4)
    378     {
    379       if(typeof(#[1]) == "intvec" && typeof(#[2]) == "intvec" && typeof(#[3]) == "int"
    380           && typeof(#[4]) == "int")
    381       {
    382         intvec curr_weight = #[1];
    383         intvec target_weight = #[2];
    384         weighted = 1;
    385         if(#[1] < n1)
    386         {
    387           n1 = #[3];
    388         }
    389         int exactness = #[4];
    390         if(n1 >= 10)
    391         {
    392           int n2 = n1 + 1;
    393           int n3 = n1;
    394         }
    395         else
    396         {
    397           int n2 = 10;
    398           int n3 = 10;
    399         }
    400       }
    401       else
    402       {
    403         if(typeof(#[1]) == "int" && typeof(#[2]) == "int" && typeof(#[3]) == "int" && typeof(#[4]) == "int")
    404         {
    405           if(#[1] < n1)
    406           {
    407             n1 = #[1];
    408           }
    409           int exactness = #[2];
    410           if(n1 >= #[3])
    411           {
    412             int n2 = n1 + 1;
    413           }
    414           else
    415           {
    416             int n2 = #[3];
    417           }
    418           if(n1 >= #[4])
    419           {
    420             int n3 = n1;
    421           }
    422           else
    423           {
    424             int n3 = #[4];
    425           }
    426         }
    427         else
    428         {
    429           ERROR("Unexpected type of input.");
    430         }
    431       }
    432     }
    433     if(size(#) == 6)
    434     {
    435       if(typeof(#[1]) == "intvec" && typeof(#[2]) == "intvec" && typeof(#[3]) == "int" && typeof(#[4]) == "int" && typeof(#[5]) == "int" && typeof(#[6]) == "int")
    436       {
    437         intvec curr_weight = #[1];
    438         intvec target_weight = #[2];
    439         weighted = 1;
    440         if(#[3] < n1)
    441         {
    442           n1 = #[3];
    443         }
    444         int exactness = #[4];
    445         if(n1 >= #[5])
    446         {
    447           int n2 = n1 + 1;
    448         }
    449         else
    450         {
    451           int n2 = #[5];
    452         }
    453         if(n1 >= #[6])
    454         {
    455           int n3 = n1;
    456         }
    457         else
    458         {
    459           int n3 = #[6];
    460         }
    461       }
    462       else
    463       {
    464         ERROR("Expected list(intvec,intvec,int,int,int,int) as optional parameter list.");
    465       }
    466     }
    467     if(size(#) == 1 || size(#) == 5 || size(#) > 6)
    468     {
    469       ERROR("Expected 0,2,3,4 or 5 optional arguments.");
    470     }
    471   }
    472   if(printlevel >= 10)
    473   {
    474   "n1 = "+string(n1)+", n2 = "+string(n2)+", n3 = "+string(n3)+", exactness = "+string(exactness);
    475   }
    476 
    477 //-------------------------  Save current options  -----------------------------
    478   intvec opt = option(get);
    479   //option(redSB);
    480 
    481 //--------------------  Initialize the list of primes  -------------------------
    482   int tt = timer;
    483   int rt = rtimer;
    484   int en = 2134567879;
    485   int an = 1000000000;
    486   intvec L = primeList(I,n2);
    487   if(n2 > 4)
    488   {
    489   //  L[5] = prime(random(an,en));
    490   }
    491   if(printlevel >= 10)
    492   {
    493     "CPU-time for primeList: "+string(timer-tt)+" seconds.";
    494     "Real-time for primeList: "+string(rtimer-rt)+" seconds.";
    495   }
    496   int h = homog(I);
    497   list P,T1,T2,LL,Arguments,PP;
    498   ideal J,K,H;
    499 
    500 //-------------------  parallelized Groebner Walk in positive characteristic  --------------------
    501 
    502   if(weighted)
    503   {
    504     for(i=1; i<=size(L); i++)
    505     {
    506       Arguments[i] = list(II,L[i],variant,list(curr_weight,target_weight));
    507     }
    508   }
    509   else
    510   {
    511     for(i=1; i<=size(L); i++)
    512     {
    513       Arguments[i] = list(II,L[i],variant);
    514     }
    515   }
    516   P = parallelWaitAll("modpWalk",Arguments);
    517   for(i=1; i<=size(P); i++)
    518   {
    519     T1[i] = P[i][1];
    520     T2[i] = bigint(P[i][2]);
    521   }
    522 
    523   while(1)
    524   {
    525     LL = deleteUnluckyPrimes(T1,T2,h);
    526     T1 = LL[1];
    527     T2 = LL[2];
    528 //-------------------  Now all leading ideals are the same  --------------------
    529 //-------------------  Lift results to basering via farey  ---------------------
    530 
    531     tt = timer; rt = rtimer;
    532     N = T2[1];
    533     for(i=2; i<=size(T2); i++)
    534     {
    535       N = N*T2[i];
    536     }
    537     H = chinrem(T1,T2);
    538     J = parallelFarey(H,N,n1);
    539     //J=farey(H,N);
    540     if(printlevel >= 10)
    541     {
    542       "CPU-time for lifting-process is "+string(timer - tt)+" seconds.";
    543       "Real-time for lifting-process is "+string(rtimer - rt)+" seconds.";
    544     }
    545 
    546 //----------------  Test if we already have a standard basis of I --------------
    547 
    548     tt = timer; rt = rtimer;
    549     pTest = pTestSB(I,J,L,variant);
    550     //pTest = primeTestSB(I,J,L,variant);
    551     if(printlevel >= 10)
    552     {
    553       "CPU-time for pTest is "+string(timer - tt)+" seconds.";
    554       "Real-time for pTest is "+string(rtimer - rt)+" seconds.";
    555     }
    556     if(pTest)
    557     {
    558       if(printlevel >= 10)
    559       {
    560         "CPU-time for computation without final tests is "+string(timer - TT)+" seconds.";
    561         "Real-time for computation without final tests is "+string(rtimer - RT)+" seconds.";
    562       }
    563       attrib(J,"isSB",1);
    564       if(exactness == 0)
    565       {
    566         option(set, opt);
    567         return(J);
    568       }
    569       else
    570       {
    571         tt = timer;
    572         rt = rtimer;
    573         sizeTest = 1 - isIdealIncluded(I,J,n1);
    574         if(printlevel >= 10)
    575         {
    576           "CPU-time for checking if I subset <G> is "+string(timer - tt)+" seconds.";
    577           "Real-time for checking if I subset <G> is "+string(rtimer - rt)+" seconds.";
    578         }
    579         if(sizeTest == 0)
    580         {
    581           tt = timer;
    582           rt = rtimer;
    583           K = std(J);
    584           if(printlevel >= 10)
    585           {
    586             "CPU-time for last std-computation is "+string(timer - tt)+" seconds.";
    587             "Real-time for last std-computation is "+string(rtimer - rt)+" seconds.";
    588           }
    589           if(size(reduce(K,J)) == 0)
    590           {
    591             option(set, opt);
    592             return(J);
    593           }
    594         }
    595       }
    596     }
    597 //--------------  We do not already have a standard basis of I, therefore do the main computation for more primes  --------------
    598 
    599     T1 = H;
    600     T2 = N;
    601     j = size(L)+1;
    602     tt = timer; rt = rtimer;
    603     L = primeList(I,n3,L,n1);
    604     if(printlevel >= 10)
    605     {
    606       "CPU-time for primeList: "+string(timer-tt)+" seconds.";
    607       "Real-time for primeList: "+string(rtimer-rt)+" seconds.";
    608     }
    609     Arguments = list();
    610     PP = list();
    611     if(weighted)
    612     {
    613       for(i=j; i<=size(L); i++)
    614       {
    615         //Arguments[i-j+1] = list(II,L[i],variant,list(curr_weight,target_weight));
    616         Arguments[size(Arguments)+1] = list(II,L[i],variant,list(curr_weight,target_weight));
    617       }
    618     }
    619     else
    620     {
    621       for(i=j; i<=size(L); i++)
    622       {
    623         //Arguments[i-j+1] = list(II,L[i],variant);
    624         Arguments[size(Arguments)+1] = list(II,L[i],variant);
    625       }
    626     }
    627     PP = parallelWaitAll("modpWalk",Arguments);
    628     if(printlevel >= 10)
    629     {
    630       "parallel modpWalk";
    631     }
    632     for(i=1; i<=size(PP); i++)
    633     {
    634       //P[size(P) + 1] = PP[i];
    635       T1[size(T1) + 1] = PP[i][1];
    636       T2[size(T2) + 1] = bigint(PP[i][2]);
    637     }
    638   }
    639   if(printlevel >= 10)
    640   {
    641     "CPU-time for computation with final tests is "+string(timer - TT)+" seconds.";
    642     "Real-time for computation with final tests is "+string(rtimer - RT)+" seconds.";
    643   }
    644 }
    645 
    646 example
    647 {
    648   "EXAMPLE:";
    649   echo = 2;
    650   ring R=0,(x,y,z),lp;
    651   ideal I=-x+y2z-z,xz+1,x2+y2-1;
    652   // I is a standard basis in dp
    653   ideal J = modWalk(I,1);
    654   J;
    655 }
    656 
    657 ////////////////////////////////////////////////////////////////////////////////
    658 static proc isIdealIncluded(ideal I, ideal J, int n1)
    659 "USAGE:  isIdealIncluded(I,J,int n1); I ideal, J ideal, n1 integer
    660 "
    661 {
    662   if(n1 > 1)
    663   {
    664     int k;
    665     list args,results;
    666     for(k=1; k<=size(I); k++)
    667     {
    668       args[k] = list(ideal(I[k]),J,1);
    669     }
    670     results = parallelWaitAll("reduce",args);
    671     for(k=1; k<=size(results); k++)
    672     {
    673       if(results[k] == 0)
    674       {
    675         return(1);
    676       }
    677     }
    678     return(0);
    679   }
    680   else
    681   {
    682     if(reduce(I,J,1) == 0)
    683     {
    684       return(1);
    685     }
    686     else
    687     {
    688       return(0);
    689     }
    690   }
    691 }
    692 
    693 ////////////////////////////////////////////////////////////////////////////////
    694 static proc parallelChinrem(list T1, list T2, int n1)
    695 "USAGE:  parallelChinrem(T1,T2); T1 list of ideals, T2 list of primes, n1 integer"
    696 {
    697   int i,j,k;
    698 
    699   ideal H,J;
    700 
    701   list arguments_chinrem,results_chinrem;
    702   for(i=1; i<=size(T1); i++)
    703   {
    704     J = ideal(T1[i]);
    705     attrib(J,"isSB",1);
    706     arguments_chinrem[size(arguments_chinrem)+1] = list(list(J),T2);
    707   }
    708   results_chinrem = parallelWaitAll("chinrem",arguments_chinrem);
    709     for(j=1; j <= size(results_chinrem); j++)
    710     {
    711       J = results_chinrem[j];
    712       attrib(J,"isSB",1);
    713       if(isIdealIncluded(J,H,n1) == 0)
    714       {
    715         if(H == 0)
    716         {
    717           H = J;
    718         }
    719         else
    720         {
    721           H = H,J;
    722         }
    723       }
    724     }
    725   return(H);
    726 }
    727 
    728 ////////////////////////////////////////////////////////////////////////////////
    729 static proc parallelFarey(ideal H, bigint N, int n1)
    730 "USAGE:  parallelFarey(H,N,n1); H ideal, N bigint, n1 integer
    731 "
    732 {
    733   int i,j;
    734   int ii = 1;
    735   list arguments_farey,results_farey;
    736   for(i=1; i<=size(H); i++)
    737   {
    738     for(j=1; j<=size(H[i]); j++)
    739     {
    740       arguments_farey[size(arguments_farey)+1] = list(H[i][j],N);
    741     }
    742   }
    743   results_farey = parallelWaitAll("farey",arguments_farey);
    744   ideal J,K;
    745   poly f_farey;
    746   while(ii<=size(results_farey))
    747   {
    748     for(i=1; i<=size(H); i++)
    749     {
    750       f_farey = 0;
    751       for(j=1; j<=size(H[i]); j++)
    752       {
    753         f_farey = f_farey + results_farey[ii][1];
    754         ii++;
    755       }
    756       K = ideal(f_farey);
    757       attrib(K,"isSB",1);
    758       attrib(J,"isSB",1);
    759       if(isIdealIncluded(K,J,n1) == 0)
    760       {
    761         if(J == 0)
    762         {
    763           J = K;
    764         }
    765         else
    766         {
    767           J = J,K;
    768         }
    769       }
    770     }
    771   }
    772   return(J);
    773 }
    774 //////////////////////////////////////////////////////////////////////////////////
    775 static proc primeTestSB(def II, ideal J, list L, int variant, list #)
    776 "USAGE:  primeTestSB(I,J,L,variant,#); I,J ideals, L intvec of primes, variant int
    777 RETURN:  1 (resp. 0) if for a randomly chosen prime p that is not in L
    778          J mod p is (resp. is not) a standard basis of I mod p
    779 EXAMPLE: example primeTestSB; shows an example
    780 "
    781 {
    782 if(typeof(II) == "ideal")
    783   {
    784   ideal I = II;
    785   int radius = 2;
    786   }
    787 if(typeof(II) == "list")
    788   {
    789   ideal I = II[1];
    790   int radius = II[2];
    791   }
    792 
    793 int i,j,k,p;
    794 def R = basering;
    795 list r = ringlist(R);
    796 
    797 while(!j)
    798   {
    799   j = 1;
    800   p = prime(random(1000000000,2134567879));
    801   for(i = 1; i <= size(L); i++)
    802     {
    803     if(p == L[i])
    804       {
    805       j = 0;
    806       break;
    807       }
    808     }
    809   if(j)
    810     {
    811     for(i = 1; i <= ncols(I); i++)
    812       {
    813       for(k = 2; k <= size(I[i]); k++)
    814         {
    815         if((denominator(leadcoef(I[i][k])) mod p) == 0)
    816           {
    817           j = 0;
    818           break;
    819           }
    820         }
    821       if(!j)
    822         {
    823         break;
    824         }
    825       }
    826     }
    827   if(j)
    828     {
    829     if(!primeTest(I,p))
    830       {
    831       j = 0;
    832       }
    833     }
    834   }
    835 r[1] = p;
    836 def @R = ring(r);
    837 setring @R;
    838 ideal I = imap(R,I);
    839 ideal J = imap(R,J);
    840 attrib(J,"isSB",1);
    841 
    842 int t = timer;
    843 j = 1;
    844 if(isIncluded(I,J) == 0)
    845   {
    846   j = 0;
    847   }
    848 if(printlevel >= 11)
    849   {
    850   "isIncluded(I,J) takes "+string(timer - t)+" seconds";
    851   "j = "+string(j);
    852   }
    853 t = timer;
    854 if(j)
    855   {
    856   if(size(#) > 0)
    857     {
    858     ideal K = modpWalk(I,p,variant,#)[1];
    859     }
    860   else
    861     {
    862     ideal K = modpWalk(I,p,variant)[1];
    863     }
    864   t = timer;
    865   if(isIncluded(J,K) == 0)
    866     {
    867     j = 0;
    868     }
    869   if(printlevel >= 11)
    870     {
    871     "isIncluded(K,J) takes "+string(timer - t)+" seconds";
    872     "j = "+string(j);
    873     }
    874   }
    875 setring R;
    876 
    877 return(j);
    878 }
    879 example
    880 { "EXAMPLE:"; echo = 2;
    881    intvec L = 2,3,5;
    882    ring r = 0,(x,y,z),lp;
    883    ideal I = x+1,x+y+1;
    884    ideal J = x+1,y;
    885    primeTestSB(I,I,L,1);
    886    primeTestSB(I,J,L,1);
    887 }
    888 
    889 ////////////////////////////////////////////////////////////////////////////////
    890 static proc pTestSB(ideal I, ideal J, list L, int variant, list #)
    891 "USAGE:  pTestSB(I,J,L,variant,#); I,J ideals, L intvec of primes, variant int
    892 RETURN:  1 (resp. 0) if for a randomly chosen prime p that is not in L
    893          J mod p is (resp. is not) a standard basis of I mod p
    894 EXAMPLE: example pTestSB; shows an example
    895 "
    896 {
    897    int i,j,k,p;
    898    def R = basering;
    899    list r = ringlist(R);
    900 
    901    while(!j)
    902    {
    903       j = 1;
    904       p = prime(random(1000000000,2134567879));
    905       for(i = 1; i <= size(L); i++)
    906       {
    907          if(p == L[i]) { j = 0; break; }
    908       }
    909       if(j)
    910       {
    911          for(i = 1; i <= ncols(I); i++)
    912          {
    913             for(k = 2; k <= size(I[i]); k++)
    914             {
    915                if((denominator(leadcoef(I[i][k])) mod p) == 0) { j = 0; break; }
    916             }
    917             if(!j){ break; }
    918          }
    919       }
    920       if(j)
    921       {
    922          if(!primeTest(I,p)) { j = 0; }
    923       }
    924    }
    925    r[1] = p;
    926    def @R = ring(r);
    927    setring @R;
    928    ideal I = imap(R,I);
    929    ideal J = imap(R,J);
    930    attrib(J,"isSB",1);
    931 
    932    int t = timer;
    933    j = 1;
    934    if(isIncluded(I,J) == 0) { j = 0; }
    935 
    936    if(printlevel >= 11)
    937    {
    938       "isIncluded(I,J) takes "+string(timer - t)+" seconds";
    939       "j = "+string(j);
    940    }
    941 
    942    t = timer;
    943    if(j)
    944    {
    945       if(size(#) > 0)
    946       {
    947          ideal K = modpStd(I,p,variant,#[1])[1];
    948       }
    949       else
    950       {
    951          ideal K = groebner(I);
    952       }
    953       t = timer;
    954       if(isIncluded(J,K) == 0) { j = 0; }
    955 
    956       if(printlevel >= 11)
    957       {
    958          "isIncluded(J,K) takes "+string(timer - t)+" seconds";
    959          "j = "+string(j);
    960       }
    961    }
    962    setring R;
    963    return(j);
    964 }
    965 example
    966 { "EXAMPLE:"; echo = 2;
    967    intvec L = 2,3,5;
    968    ring r = 0,(x,y,z),dp;
    969    ideal I = x+1,x+y+1;
    970    ideal J = x+1,y;
    971    pTestSB(I,I,L,2);
    972    pTestSB(I,J,L,2);
    973 }
    974 ////////////////////////////////////////////////////////////////////////////////
    975 static proc mixedTest()
    976 "USAGE:  mixedTest();
    977 RETURN:  1 if ordering of basering is mixed, 0 else
    978 EXAMPLE: example mixedTest(); shows an example
    979 "
    980 {
    981    int i,p,m;
    982    for(i = 1; i <= nvars(basering); i++)
    983    {
    984       if(var(i) > 1)
    985       {
    986          p++;
    987       }
    988       else
    989       {
    990          m++;
    991       }
    992    }
    993    if((p > 0) && (m > 0)) { return(1); }
    994    return(0);
    995 }
    996 example
    997 { "EXAMPLE:"; echo = 2;
    998    ring R1 = 0,(x,y,z),dp;
    999    mixedTest();
    1000    ring R2 = 31,(x(1..4),y(1..3)),(ds(4),lp(3));
    1001    mixedTest();
    1002    ring R3 = 181,x(1..9),(dp(5),lp(4));
    1003    mixedTest();
    1004 }
     139    int pertdeg = 3;
     140    ideal J = modrWalk(I,radius,pertdeg);
     141    J;
     142}
     143
     144proc modfWalk(ideal I, list #)
     145"USAGE:   modfWalk(I, [, v, w]); I ideal, v intvec, w intvec
     146RETURN:   a standard basis of I
     147NOTE:     The procedure computes a standard basis of I (over the rational
     148          numbers) by using modular methods.
     149SEE ALSO: modular
     150EXAMPLE:  example modfWalk; shows an example"
     151{
     152    /* read optional parameter */
     153    if (size(#) > 0) {
     154        if (size(#) == 1) {
     155            intvec w = #[1];
     156        }
     157        if (size(#) == 2) {
     158            intvec v = #[1];
     159            intvec w = #[2];
     160        }
     161        if (size(#) > 2 || typeof(#[1]) != "intvec") {
     162            ERROR("wrong optional parameter");
     163        }
     164    }
     165
     166    /* save options */
     167    intvec opt = option(get);
     168    option(redSB);
     169
     170    /* set additional parameters */
     171    int reduction = 1;
     172    int printout = 0;
     173
     174    /* call modular() */
     175    if (size(#) > 0) {
     176        I = modular("fwalk", list(I,reduction,printout,#));
     177    }
     178    else {
     179        I = modular("fwalk", list(I,reduction,printout));
     180    }
     181
     182    /* return the result */
     183    attrib(I, "isSB", 1);
     184    option(set, opt);
     185    return(I);
     186}
     187example
     188{
     189    "EXAMPLE:";
     190    echo = 2;
     191    ring R1 = 0, (x,y,z,t), dp;
     192    ideal I = 3x3+x2+1, 11y5+y3+2, 5z4+z2+4;
     193    I = std(I);
     194    ring R2 = 0, (x,y,z,t), lp;
     195    ideal I = fetch(R1, I);
     196    ideal J = modfWalk(I);
     197    J;
     198}
     199
     200proc modfrWalk(ideal I, int radius, list #)
     201"USAGE:   modfrWalk(I, radius [, v, w]); I ideal, radius int, v intvec, w intvec
     202RETURN:   a standard basis of I
     203NOTE:     The procedure computes a standard basis of I (over the rational
     204          numbers) by using modular methods.
     205SEE ALSO: modular
     206EXAMPLE:  example modfrWalk; shows an example"
     207{
     208    /* read optional parameter */
     209    if (size(#) > 0) {
     210        if (size(#) == 1) {
     211            intvec w = #[1];
     212        }
     213        if (size(#) == 2) {
     214            intvec v = #[1];
     215            intvec w = #[2];
     216        }
     217        if (size(#) > 2 || typeof(#[1]) != "intvec") {
     218            ERROR("wrong optional parameter");
     219        }
     220    }
     221
     222    /* save options */
     223    intvec opt = option(get);
     224    option(redSB);
     225
     226    /* set additional parameters */
     227    int reduction = 1;
     228    int printout = 0;
     229
     230    /* call modular() */
     231    if (size(#) > 0) {
     232        I = modular("frandwalk", list(I,radius,reduction,printout,#));
     233    }
     234    else {
     235        I = modular("frandwalk", list(I,radius,reduction,printout));
     236    }
     237
     238    /* return the result */
     239    attrib(I, "isSB", 1);
     240    option(set, opt);
     241    return(I);
     242}
     243example
     244{
     245    "EXAMPLE:";
     246    echo = 2;
     247    ring R1 = 0, (x,y,z,t), dp;
     248    ideal I = 3x3+x2+1, 11y5+y3+2, 5z4+z2+4;
     249    I = std(I);
     250    ring R2 = 0, (x,y,z,t), lp;
     251    ideal I = fetch(R1, I);
     252    int radius = 2;
     253    ideal J = modfrWalk(I,radius);
     254    J;
     255}
  • Singular/LIB/rwalk.lib

    • Property mode changed from 100644 to 100755
    rcb5589 r5638b9  
    1010rwalk(ideal,int,int[,intvec,intvec]);   standard basis of ideal via Random Walk algorithm
    1111rwalk(ideal,int[,intvec,intvec]);       standard basis of ideal via Random Perturbation Walk algorithm
    12 frwalk(ideal,int[,intvec,intvec]);      standard basis of ideal via Random Fractal Walk algorithm
     12frandwalk(ideal,int[,intvec,intvec]);      standard basis of ideal via Random Fractal Walk algorithm
    1313";
    1414
     
    141141 * Random Walk  *
    142142 ****************/
    143 proc rwalk(ideal Go, int radius, int pert_deg, list #)
     143proc rwalk(ideal Go, int radius, int pert_deg, int reduction, int printout, list #)
    144144"SYNTAX: rwalk(ideal i, int radius);
    145145         if size(#)>0 then rwalk(ideal i, int radius, intvec v, intvec w);
     146         intermediate Groebner bases are not reduced if reduction = 0
    146147TYPE:    ideal
    147148PURPOSE: compute the standard basis of the ideal, calculated via
     
    178179
    179180ideal G = fetch(xR, Go);
    180 G = system("Mrwalk", G, curr_weight, target_weight, radius, pert_deg, basering);
     181G = system("Mrwalk", G, curr_weight, target_weight, radius, pert_deg, reduction, printout);
    181182
    182183setring xR;
     
    196197  int radius = 1;
    197198  int perturb_deg = 2;
    198   rwalk(I,radius,perturb_deg);
     199  int reduction = 0;
     200  int printout = 1;
     201  rwalk(I,radius,perturb_deg,reduction,printout);
    199202}
    200203
     
    202205 * Perturbation Walk with random element *
    203206 *****************************************/
    204 proc prwalk(ideal Go, int radius, int o_pert_deg, int t_pert_deg, list #)
     207proc prwalk(ideal Go, int radius, int o_pert_deg, int t_pert_deg, int reduction, int printout, list #)
    205208"SYNTAX: rwalk(ideal i, int radius);
    206209         if size(#)>0 then rwalk(ideal i, int radius, intvec v, intvec w);
     
    227230  OSCTW= OrderStringalp_NP("al", #);
    228231  }
     232int nP = OSCTW[1];
    229233string ord_str = OSCTW[2];
    230234intvec curr_weight = OSCTW[3]; // original weight vector
     
    238242
    239243ideal G = fetch(xR, Go);
    240 G = system("Mprwalk", G, curr_weight, target_weight, radius, o_pert_deg, t_pert_deg, basering);
     244G = system("Mprwalk", G, curr_weight, target_weight, radius, o_pert_deg, t_pert_deg,
     245           nP, reduction, printout);
    241246
    242247setring xR;
     
    257262  int o_perturb_deg = 2;
    258263  int t_perturb_deg = 2;
    259   prwalk(I,radius,o_perturb_deg,t_perturb_deg);
     264  int reduction = 0;
     265  int printout = 2;
     266  prwalk(I,radius,o_perturb_deg,t_perturb_deg,reduction,printout);
    260267}
    261268
     
    263270 * Fractal Walk with random element *
    264271 ************************************/
    265 proc frandwalk(ideal Go, int radius, list #)
    266 "SYNTAX: frwalk(ideal i, int radius);
    267          frwalk(ideal i, int radius, intvec v, intvec w);
     272proc frandwalk(ideal Go, int radius, int reduction, int printout, list #)
     273"SYNTAX: frwalk(ideal i, int radius, int reduction, int printout);
     274         frwalk(ideal i, int radius, int reduction, int printout, intvec v, intvec w);
    268275TYPE:    ideal
    269276PURPOSE: compute the standard basis of the ideal, calculated via
     
    299306   ideal G = fetch(xR, Go);
    300307   int pert_deg = 2;
    301    G = system("Mfrwalk", G, curr_weight, target_weight, radius);
     308
     309   G = system("Mfrwalk", G, curr_weight, target_weight, radius, reduction, printout);
    302310
    303311   setring xR;
     
    314322    ring r = 0,(z,y,x), lp;
    315323    ideal I = y3+xyz+y2z+xz3, 3+xy+x2y+y2z;
    316     frandwalk(I,2);
    317 }
     324    int reduction = 0;
     325    frandwalk(I,2,0,1);
     326}
  • Singular/LIB/swalk.lib

    • Property mode changed from 100644 to 100755
  • Singular/dyn_modules/Order/nforder_elt.cc

    r2675bd r5638b9  
    2020  return ((nforder *)r->data)->String();
    2121}
    22 static void EltWrite(number &a, const coeffs r)
     22static void EltWrite(number a, const coeffs r)
    2323{
    2424  bigintmat * b = (bigintmat*)a;
  • Singular/extra.cc

    r2675bd r5638b9  
    6565#include <polys/weight.h>
    6666
    67 
     67#include <coeffs/bigintmat.h>
    6868#include <kernel/fast_mult.h>
    6969#include <kernel/digitech.h>
     
    37723772    }
    37733773    else
     3774/*==================== LU for bigintmat =================*/
     3775#ifdef SINGULAR_4_1
     3776    if(strcmp(sys_cmd,"LU")==0)
     3777    {
     3778      if ((h!=NULL) && (h->Typ()==CMATRIX_CMD))
     3779      {
     3780        // get the argument:
     3781        bigintmat *b=(bigintmat *)h->Data();
     3782        // just for tests: simply transpose
     3783        bigintmat *bb=b->transpose();
     3784        // return the result:
     3785        res->rtyp=CMATRIX_CMD;
     3786        res->data=(char*)bb;
     3787        return FALSE;
     3788      }
     3789      else
     3790      {
     3791        WerrorS("system(\"LU\",<cmatrix>) expected");
     3792        return TRUE;
     3793      }
     3794    }
     3795    else
     3796#endif   
    37743797/*==================== Error =================*/
    37753798      Werror( "(extended) system(\"%s\",...) %s", sys_cmd, feNotImplemented );
  • Singular/grammar.cc

    r2675bd r5638b9  
    239239
    240240/* Line 189 of yacc.c  */
    241 #line 243 "grammar.cc"
     241#line 242 "grammar.cc"
    242242
    243243/* Enabling traces.  */
     
    412412
    413413/* Line 264 of yacc.c  */
    414 #line 416 "grammar.cc"
     414#line 415 "grammar.cc"
    415415
    416416#ifdef short
     
    792792static const yytype_uint16 yyrline[] =
    793793{
    794        0,   364,   364,   366,   400,   401,   403,   405,   409,   414,
    795      416,   467,   468,   469,   470,   471,   472,   473,   474,   478,
    796      481,   482,   483,   484,   485,   486,   487,   488,   489,   492,
    797      499,   504,   508,   512,   516,   520,   533,   561,   585,   591,
    798      597,   601,   605,   609,   613,   617,   621,   625,   629,   633,
    799      637,   641,   645,   649,   653,   657,   661,   665,   669,   673,
    800      677,   683,   687,   691,   695,   699,   706,   717,   723,   728,
    801      729,   730,   734,   738,   742,   746,   750,   754,   758,   762,
    802      766,   783,   790,   789,   807,   815,   823,   832,   836,   840,
    803      844,   848,   852,   856,   860,   864,   868,   872,   876,   880,
    804      892,   899,   900,   919,   920,   932,   937,   942,   946,   950,
    805      990,  1016,  1037,  1045,  1049,  1050,  1064,  1072,  1081,  1126,
    806     1127,  1136,  1137,  1143,  1150,  1152,  1154,  1164,  1163,  1171,
    807     1176,  1183,  1191,  1203,  1219,  1238,  1242,  1246,  1251,  1255,
    808     1259,  1263,  1267,  1272,  1278,  1284,  1290,  1296,  1302,  1308,
    809     1320,  1327,  1331,  1368,  1375,  1383,  1389,  1389,  1392,  1464,
    810     1468,  1497,  1510,  1527,  1536,  1541,  1549,  1561,  1580,  1590,
    811     1609,  1632,  1638,  1650,  1656
     794       0,   363,   363,   365,   399,   400,   402,   404,   408,   413,
     795     415,   466,   467,   468,   469,   470,   471,   472,   473,   477,
     796     480,   481,   482,   483,   484,   485,   486,   487,   488,   491,
     797     498,   503,   507,   511,   515,   519,   532,   560,   584,   590,
     798     596,   600,   604,   608,   612,   616,   620,   624,   628,   632,
     799     636,   640,   644,   648,   652,   656,   660,   664,   668,   672,
     800     676,   682,   686,   690,   694,   698,   705,   716,   722,   727,
     801     728,   729,   733,   737,   741,   745,   749,   753,   757,   761,
     802     765,   782,   789,   788,   806,   814,   822,   831,   835,   839,
     803     843,   847,   851,   855,   859,   863,   867,   871,   875,   879,
     804     891,   898,   899,   918,   919,   931,   936,   941,   945,   949,
     805     985,  1011,  1032,  1040,  1044,  1045,  1059,  1067,  1076,  1121,
     806    1122,  1131,  1132,  1138,  1145,  1147,  1149,  1159,  1158,  1166,
     807    1171,  1178,  1186,  1198,  1214,  1233,  1237,  1241,  1246,  1250,
     808    1254,  1258,  1262,  1267,  1273,  1279,  1285,  1291,  1297,  1303,
     809    1315,  1322,  1326,  1363,  1370,  1378,  1384,  1384,  1387,  1459,
     810    1463,  1492,  1505,  1522,  1531,  1536,  1544,  1556,  1575,  1585,
     811    1604,  1627,  1633,  1645,  1651
    812812};
    813813#endif
     
    24272427
    24282428/* Line 1464 of yacc.c  */
    2429 #line 367 "grammar.y"
     2429#line 366 "grammar.y"
    24302430    {
    24312431            if (timerv)
     
    24632463
    24642464/* Line 1464 of yacc.c  */
    2465 #line 402 "grammar.y"
     2465#line 401 "grammar.y"
    24662466    {currentVoice->ifsw=0;;}
    24672467    break;
     
    24702470
    24712471/* Line 1464 of yacc.c  */
    2472 #line 404 "grammar.y"
     2472#line 403 "grammar.y"
    24732473    { (yyvsp[(1) - (2)].lv).CleanUp(); currentVoice->ifsw=0;;}
    24742474    break;
     
    24772477
    24782478/* Line 1464 of yacc.c  */
    2479 #line 406 "grammar.y"
     2479#line 405 "grammar.y"
    24802480    {
    24812481            YYACCEPT;
     
    24862486
    24872487/* Line 1464 of yacc.c  */
    2488 #line 410 "grammar.y"
     2488#line 409 "grammar.y"
    24892489    {
    24902490            currentVoice->ifsw=0;
     
    24962496
    24972497/* Line 1464 of yacc.c  */
    2498 #line 415 "grammar.y"
     2498#line 414 "grammar.y"
    24992499    {currentVoice->ifsw=0;;}
    25002500    break;
     
    25032503
    25042504/* Line 1464 of yacc.c  */
    2505 #line 417 "grammar.y"
     2505#line 416 "grammar.y"
    25062506    {
    25072507            #ifdef SIQ
     
    25572557
    25582558/* Line 1464 of yacc.c  */
    2559 #line 475 "grammar.y"
     2559#line 474 "grammar.y"
    25602560    {if (currentVoice!=NULL) currentVoice->ifsw=0;;}
    25612561    break;
     
    25642564
    25652565/* Line 1464 of yacc.c  */
    2566 #line 478 "grammar.y"
     2566#line 477 "grammar.y"
    25672567    { omFree((ADDRESS)(yyvsp[(2) - (2)].name)); ;}
    25682568    break;
     
    25712571
    25722572/* Line 1464 of yacc.c  */
    2573 #line 493 "grammar.y"
     2573#line 492 "grammar.y"
    25742574    {
    25752575            if(iiAssign(&(yyvsp[(1) - (2)].lv),&(yyvsp[(2) - (2)].lv))) YYERROR;
     
    25802580
    25812581/* Line 1464 of yacc.c  */
    2582 #line 500 "grammar.y"
     2582#line 499 "grammar.y"
    25832583    {
    25842584            if (currRing==NULL) MYYERROR("no ring active");
     
    25902590
    25912591/* Line 1464 of yacc.c  */
    2592 #line 505 "grammar.y"
     2592#line 504 "grammar.y"
    25932593    {
    25942594            syMake(&(yyval.lv),(yyvsp[(1) - (1)].name));
     
    25992599
    26002600/* Line 1464 of yacc.c  */
    2601 #line 509 "grammar.y"
     2601#line 508 "grammar.y"
    26022602    {
    26032603            if(iiExprArith2(&(yyval.lv), &(yyvsp[(1) - (3)].lv), COLONCOLON, &(yyvsp[(3) - (3)].lv))) YYERROR;
     
    26082608
    26092609/* Line 1464 of yacc.c  */
    2610 #line 513 "grammar.y"
     2610#line 512 "grammar.y"
    26112611    {
    26122612            if(iiExprArith2(&(yyval.lv), &(yyvsp[(1) - (3)].lv), '.', &(yyvsp[(3) - (3)].lv))) YYERROR;
     
    26172617
    26182618/* Line 1464 of yacc.c  */
    2619 #line 517 "grammar.y"
     2619#line 516 "grammar.y"
    26202620    {
    26212621            if(iiExprArith1(&(yyval.lv),&(yyvsp[(1) - (3)].lv),'(')) YYERROR;
     
    26262626
    26272627/* Line 1464 of yacc.c  */
    2628 #line 521 "grammar.y"
     2628#line 520 "grammar.y"
    26292629    {
    26302630            if ((yyvsp[(1) - (4)].lv).rtyp==UNKNOWN)
     
    26442644
    26452645/* Line 1464 of yacc.c  */
    2646 #line 534 "grammar.y"
     2646#line 533 "grammar.y"
    26472647    {
    26482648            if (currRingHdl==NULL) MYYERROR("no ring active");
     
    26772677
    26782678/* Line 1464 of yacc.c  */
    2679 #line 562 "grammar.y"
     2679#line 561 "grammar.y"
    26802680    {
    26812681            memset(&(yyval.lv),0,sizeof((yyval.lv)));
     
    27062706
    27072707/* Line 1464 of yacc.c  */
    2708 #line 586 "grammar.y"
     2708#line 585 "grammar.y"
    27092709    {
    27102710            memset(&(yyval.lv),0,sizeof((yyval.lv)));
     
    27172717
    27182718/* Line 1464 of yacc.c  */
    2719 #line 592 "grammar.y"
     2719#line 591 "grammar.y"
    27202720    {
    27212721            memset(&(yyval.lv),0,sizeof((yyval.lv)));
     
    27282728
    27292729/* Line 1464 of yacc.c  */
    2730 #line 598 "grammar.y"
     2730#line 597 "grammar.y"
    27312731    {
    27322732            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    27372737
    27382738/* Line 1464 of yacc.c  */
    2739 #line 602 "grammar.y"
     2739#line 601 "grammar.y"
    27402740    {
    27412741            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    27462746
    27472747/* Line 1464 of yacc.c  */
    2748 #line 606 "grammar.y"
     2748#line 605 "grammar.y"
    27492749    {
    27502750            if(iiExprArithM(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    27552755
    27562756/* Line 1464 of yacc.c  */
    2757 #line 610 "grammar.y"
     2757#line 609 "grammar.y"
    27582758    {
    27592759            if(iiExprArithM(&(yyval.lv),NULL,(yyvsp[(1) - (3)].i))) YYERROR;
     
    27642764
    27652765/* Line 1464 of yacc.c  */
    2766 #line 614 "grammar.y"
     2766#line 613 "grammar.y"
    27672767    {
    27682768            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    27732773
    27742774/* Line 1464 of yacc.c  */
    2775 #line 618 "grammar.y"
     2775#line 617 "grammar.y"
    27762776    {
    27772777            if(iiExprArithM(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    27822782
    27832783/* Line 1464 of yacc.c  */
    2784 #line 622 "grammar.y"
     2784#line 621 "grammar.y"
    27852785    {
    27862786            if(iiExprArithM(&(yyval.lv),NULL,(yyvsp[(1) - (3)].i))) YYERROR;
     
    27912791
    27922792/* Line 1464 of yacc.c  */
    2793 #line 626 "grammar.y"
     2793#line 625 "grammar.y"
    27942794    {
    27952795            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    28002800
    28012801/* Line 1464 of yacc.c  */
    2802 #line 630 "grammar.y"
     2802#line 629 "grammar.y"
    28032803    {
    28042804            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    28092809
    28102810/* Line 1464 of yacc.c  */
    2811 #line 634 "grammar.y"
     2811#line 633 "grammar.y"
    28122812    {
    28132813            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    28182818
    28192819/* Line 1464 of yacc.c  */
    2820 #line 638 "grammar.y"
     2820#line 637 "grammar.y"
    28212821    {
    28222822            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    28272827
    28282828/* Line 1464 of yacc.c  */
    2829 #line 642 "grammar.y"
     2829#line 641 "grammar.y"
    28302830    {
    28312831            if(iiExprArith2(&(yyval.lv),&(yyvsp[(3) - (6)].lv),(yyvsp[(1) - (6)].i),&(yyvsp[(5) - (6)].lv),TRUE)) YYERROR;
     
    28362836
    28372837/* Line 1464 of yacc.c  */
    2838 #line 646 "grammar.y"
     2838#line 645 "grammar.y"
    28392839    {
    28402840            if(iiExprArith2(&(yyval.lv),&(yyvsp[(3) - (6)].lv),(yyvsp[(1) - (6)].i),&(yyvsp[(5) - (6)].lv),TRUE)) YYERROR;
     
    28452845
    28462846/* Line 1464 of yacc.c  */
    2847 #line 650 "grammar.y"
     2847#line 649 "grammar.y"
    28482848    {
    28492849            if(iiExprArith2(&(yyval.lv),&(yyvsp[(3) - (6)].lv),(yyvsp[(1) - (6)].i),&(yyvsp[(5) - (6)].lv),TRUE)) YYERROR;
     
    28542854
    28552855/* Line 1464 of yacc.c  */
    2856 #line 654 "grammar.y"
     2856#line 653 "grammar.y"
    28572857    {
    28582858            if(iiExprArith2(&(yyval.lv),&(yyvsp[(3) - (6)].lv),(yyvsp[(1) - (6)].i),&(yyvsp[(5) - (6)].lv),TRUE)) YYERROR;
     
    28632863
    28642864/* Line 1464 of yacc.c  */
    2865 #line 658 "grammar.y"
     2865#line 657 "grammar.y"
    28662866    {
    28672867            if(iiExprArith3(&(yyval.lv),(yyvsp[(1) - (8)].i),&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    28722872
    28732873/* Line 1464 of yacc.c  */
    2874 #line 662 "grammar.y"
     2874#line 661 "grammar.y"
    28752875    {
    28762876            if(iiExprArith3(&(yyval.lv),(yyvsp[(1) - (8)].i),&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    28812881
    28822882/* Line 1464 of yacc.c  */
    2883 #line 666 "grammar.y"
     2883#line 665 "grammar.y"
    28842884    {
    28852885            if(iiExprArith3(&(yyval.lv),(yyvsp[(1) - (8)].i),&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    28902890
    28912891/* Line 1464 of yacc.c  */
    2892 #line 670 "grammar.y"
     2892#line 669 "grammar.y"
    28932893    {
    28942894            if(iiExprArith3(&(yyval.lv),(yyvsp[(1) - (8)].i),&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    28992899
    29002900/* Line 1464 of yacc.c  */
    2901 #line 674 "grammar.y"
     2901#line 673 "grammar.y"
    29022902    {
    29032903            if(iiExprArithM(&(yyval.lv),NULL,(yyvsp[(1) - (3)].i))) YYERROR;
     
    29082908
    29092909/* Line 1464 of yacc.c  */
    2910 #line 678 "grammar.y"
     2910#line 677 "grammar.y"
    29112911    {
    29122912            int b=iiExprArithM(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i)); // handle branchTo
     
    29192919
    29202920/* Line 1464 of yacc.c  */
    2921 #line 684 "grammar.y"
     2921#line 683 "grammar.y"
    29222922    {
    29232923            if(iiExprArith3(&(yyval.lv),(yyvsp[(1) - (8)].i),&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    29282928
    29292929/* Line 1464 of yacc.c  */
    2930 #line 688 "grammar.y"
     2930#line 687 "grammar.y"
    29312931    {
    29322932            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),(yyvsp[(1) - (4)].i))) YYERROR;
     
    29372937
    29382938/* Line 1464 of yacc.c  */
    2939 #line 692 "grammar.y"
     2939#line 691 "grammar.y"
    29402940    {
    29412941            if(iiExprArith3(&(yyval.lv),RING_CMD,&(yyvsp[(3) - (8)].lv),&(yyvsp[(5) - (8)].lv),&(yyvsp[(7) - (8)].lv))) YYERROR;
     
    29462946
    29472947/* Line 1464 of yacc.c  */
    2948 #line 696 "grammar.y"
     2948#line 695 "grammar.y"
    29492949    {
    29502950            if(iiExprArith1(&(yyval.lv),&(yyvsp[(3) - (4)].lv),RING_CMD)) YYERROR;
     
    29552955
    29562956/* Line 1464 of yacc.c  */
    2957 #line 700 "grammar.y"
     2957#line 699 "grammar.y"
    29582958    {
    29592959            if (iiARROW(&(yyval.lv),(yyvsp[(1) - (3)].name),(yyvsp[(3) - (3)].name))) YYERROR;
     
    29642964
    29652965/* Line 1464 of yacc.c  */
    2966 #line 707 "grammar.y"
     2966#line 706 "grammar.y"
    29672967    {
    29682968            leftv v = &(yyvsp[(1) - (3)].lv);
     
    29802980
    29812981/* Line 1464 of yacc.c  */
    2982 #line 718 "grammar.y"
     2982#line 717 "grammar.y"
    29832983    {
    29842984            (yyval.lv) = (yyvsp[(1) - (1)].lv);
     
    29892989
    29902990/* Line 1464 of yacc.c  */
    2991 #line 724 "grammar.y"
     2991#line 723 "grammar.y"
    29922992    {
    29932993            /*if ($1.typ == eunknown) YYERROR;*/
     
    29992999
    30003000/* Line 1464 of yacc.c  */
     3001#line 727 "grammar.y"
     3002    { (yyval.lv) = (yyvsp[(1) - (1)].lv); ;}
     3003    break;
     3004
     3005  case 70:
     3006
     3007/* Line 1464 of yacc.c  */
    30013008#line 728 "grammar.y"
    3002     { (yyval.lv) = (yyvsp[(1) - (1)].lv); ;}
    3003     break;
    3004 
    3005   case 70:
    3006 
    3007 /* Line 1464 of yacc.c  */
    3008 #line 729 "grammar.y"
    30093009    { (yyval.lv) = (yyvsp[(2) - (3)].lv); ;}
    30103010    break;
     
    30133013
    30143014/* Line 1464 of yacc.c  */
    3015 #line 731 "grammar.y"
     3015#line 730 "grammar.y"
    30163016    {
    30173017            if(iiExprArith3(&(yyval.lv),'[',&(yyvsp[(1) - (6)].lv),&(yyvsp[(3) - (6)].lv),&(yyvsp[(5) - (6)].lv))) YYERROR;
     
    30223022
    30233023/* Line 1464 of yacc.c  */
    3024 #line 735 "grammar.y"
     3024#line 734 "grammar.y"
    30253025    {
    30263026            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (4)].lv),'[',&(yyvsp[(3) - (4)].lv))) YYERROR;
     
    30313031
    30323032/* Line 1464 of yacc.c  */
    3033 #line 739 "grammar.y"
     3033#line 738 "grammar.y"
    30343034    {
    30353035            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), (yyvsp[(5) - (6)].i), NULL)) YYERROR;
     
    30403040
    30413041/* Line 1464 of yacc.c  */
    3042 #line 743 "grammar.y"
     3042#line 742 "grammar.y"
    30433043    {
    30443044            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), (yyvsp[(5) - (6)].i), NULL)) YYERROR;
     
    30493049
    30503050/* Line 1464 of yacc.c  */
    3051 #line 747 "grammar.y"
     3051#line 746 "grammar.y"
    30523052    {
    30533053            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), (yyvsp[(5) - (6)].i), NULL)) YYERROR;
     
    30583058
    30593059/* Line 1464 of yacc.c  */
    3060 #line 751 "grammar.y"
     3060#line 750 "grammar.y"
    30613061    {
    30623062            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), (yyvsp[(5) - (6)].i), NULL)) YYERROR;
     
    30673067
    30683068/* Line 1464 of yacc.c  */
    3069 #line 755 "grammar.y"
     3069#line 754 "grammar.y"
    30703070    {
    30713071            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), (yyvsp[(5) - (6)].i), NULL)) YYERROR;
     
    30763076
    30773077/* Line 1464 of yacc.c  */
    3078 #line 759 "grammar.y"
     3078#line 758 "grammar.y"
    30793079    {
    30803080            if (iiApply(&(yyval.lv), &(yyvsp[(3) - (6)].lv), 0, &(yyvsp[(5) - (6)].lv))) YYERROR;
     
    30853085
    30863086/* Line 1464 of yacc.c  */
    3087 #line 763 "grammar.y"
     3087#line 762 "grammar.y"
    30883088    {
    30893089            (yyval.lv)=(yyvsp[(2) - (3)].lv);
     
    30943094
    30953095/* Line 1464 of yacc.c  */
    3096 #line 767 "grammar.y"
     3096#line 766 "grammar.y"
    30973097    {
    30983098            #ifdef SIQ
     
    31163116
    31173117/* Line 1464 of yacc.c  */
    3118 #line 784 "grammar.y"
     3118#line 783 "grammar.y"
    31193119    {
    31203120            iiTestAssume(&(yyvsp[(2) - (5)].lv),&(yyvsp[(4) - (5)].lv));
     
    31273127
    31283128/* Line 1464 of yacc.c  */
    3129 #line 790 "grammar.y"
     3129#line 789 "grammar.y"
    31303130    {
    31313131            #ifdef SIQ
     
    31383138
    31393139/* Line 1464 of yacc.c  */
    3140 #line 796 "grammar.y"
     3140#line 795 "grammar.y"
    31413141    {
    31423142            #ifdef SIQ
     
    31533153
    31543154/* Line 1464 of yacc.c  */
    3155 #line 808 "grammar.y"
     3155#line 807 "grammar.y"
    31563156    {
    31573157            #ifdef SIQ
     
    31643164
    31653165/* Line 1464 of yacc.c  */
    3166 #line 816 "grammar.y"
     3166#line 815 "grammar.y"
    31673167    {
    31683168            #ifdef SIQ
     
    31753175
    31763176/* Line 1464 of yacc.c  */
    3177 #line 824 "grammar.y"
     3177#line 823 "grammar.y"
    31783178    {
    31793179            #ifdef SIQ
     
    31863186
    31873187/* Line 1464 of yacc.c  */
    3188 #line 833 "grammar.y"
     3188#line 832 "grammar.y"
    31893189    {
    31903190            if(iiExprArith1(&(yyval.lv),&(yyvsp[(1) - (2)].lv),PLUSPLUS)) YYERROR;
     
    31953195
    31963196/* Line 1464 of yacc.c  */
    3197 #line 837 "grammar.y"
     3197#line 836 "grammar.y"
    31983198    {
    31993199            if(iiExprArith1(&(yyval.lv),&(yyvsp[(1) - (2)].lv),MINUSMINUS)) YYERROR;
     
    32043204
    32053205/* Line 1464 of yacc.c  */
    3206 #line 841 "grammar.y"
     3206#line 840 "grammar.y"
    32073207    {
    32083208            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),'+',&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32133213
    32143214/* Line 1464 of yacc.c  */
    3215 #line 845 "grammar.y"
     3215#line 844 "grammar.y"
    32163216    {
    32173217            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),'-',&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32223222
    32233223/* Line 1464 of yacc.c  */
    3224 #line 849 "grammar.y"
     3224#line 848 "grammar.y"
    32253225    {
    32263226            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),(yyvsp[(2) - (3)].i),&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32313231
    32323232/* Line 1464 of yacc.c  */
    3233 #line 853 "grammar.y"
     3233#line 852 "grammar.y"
    32343234    {
    32353235            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),'^',&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32403240
    32413241/* Line 1464 of yacc.c  */
    3242 #line 857 "grammar.y"
     3242#line 856 "grammar.y"
    32433243    {
    32443244            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),(yyvsp[(2) - (3)].i),&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32493249
    32503250/* Line 1464 of yacc.c  */
    3251 #line 861 "grammar.y"
     3251#line 860 "grammar.y"
    32523252    {
    32533253            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),(yyvsp[(2) - (3)].i),&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32583258
    32593259/* Line 1464 of yacc.c  */
    3260 #line 865 "grammar.y"
     3260#line 864 "grammar.y"
    32613261    {
    32623262            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),NOTEQUAL,&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32673267
    32683268/* Line 1464 of yacc.c  */
    3269 #line 869 "grammar.y"
     3269#line 868 "grammar.y"
    32703270    {
    32713271            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),EQUAL_EQUAL,&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32763276
    32773277/* Line 1464 of yacc.c  */
    3278 #line 873 "grammar.y"
     3278#line 872 "grammar.y"
    32793279    {
    32803280            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),DOTDOT,&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32853285
    32863286/* Line 1464 of yacc.c  */
    3287 #line 877 "grammar.y"
     3287#line 876 "grammar.y"
    32883288    {
    32893289            if(iiExprArith2(&(yyval.lv),&(yyvsp[(1) - (3)].lv),':',&(yyvsp[(3) - (3)].lv))) YYERROR;
     
    32943294
    32953295/* Line 1464 of yacc.c  */
    3296 #line 881 "grammar.y"
     3296#line 880 "grammar.y"
    32973297    {
    32983298            if (siq>0)
     
    33113311
    33123312/* Line 1464 of yacc.c  */
    3313 #line 893 "grammar.y"
     3313#line 892 "grammar.y"
    33143314    {
    33153315            if(iiExprArith1(&(yyval.lv),&(yyvsp[(2) - (2)].lv),'-')) YYERROR;
     
    33203320
    33213321/* Line 1464 of yacc.c  */
    3322 #line 899 "grammar.y"
     3322#line 898 "grammar.y"
    33233323    { (yyval.lv) = (yyvsp[(1) - (2)].lv); ;}
    33243324    break;
     
    33273327
    33283328/* Line 1464 of yacc.c  */
    3329 #line 901 "grammar.y"
     3329#line 900 "grammar.y"
    33303330    {
    33313331            if ((yyvsp[(1) - (2)].lv).rtyp==0)
     
    33473347
    33483348/* Line 1464 of yacc.c  */
    3349 #line 921 "grammar.y"
     3349#line 920 "grammar.y"
    33503350    {
    33513351            if ((yyvsp[(2) - (3)].lv).Typ()!=STRING_CMD)
     
    33613361
    33623362/* Line 1464 of yacc.c  */
    3363 #line 933 "grammar.y"
     3363#line 932 "grammar.y"
    33643364    {
    33653365            if (iiDeclCommand(&(yyval.lv),&(yyvsp[(2) - (2)].lv),myynest,(yyvsp[(1) - (2)].i),&((yyvsp[(2) - (2)].lv).req_packhdl->idroot)))
     
    33713371
    33723372/* Line 1464 of yacc.c  */
    3373 #line 938 "grammar.y"
     3373#line 937 "grammar.y"
    33743374    {
    33753375            if (iiDeclCommand(&(yyval.lv),&(yyvsp[(2) - (2)].lv),myynest,(yyvsp[(1) - (2)].i),&((yyvsp[(2) - (2)].lv).req_packhdl->idroot)))
     
    33813381
    33823382/* Line 1464 of yacc.c  */
    3383 #line 943 "grammar.y"
     3383#line 942 "grammar.y"
    33843384    {
    33853385            if (iiDeclCommand(&(yyval.lv),&(yyvsp[(2) - (2)].lv),myynest,(yyvsp[(1) - (2)].i),&(currRing->idroot), TRUE)) YYERROR;
     
    33903390
    33913391/* Line 1464 of yacc.c  */
    3392 #line 947 "grammar.y"
     3392#line 946 "grammar.y"
    33933393    {
    33943394            if (iiDeclCommand(&(yyval.lv),&(yyvsp[(2) - (2)].lv),myynest,(yyvsp[(1) - (2)].i),&(currRing->idroot), TRUE)) YYERROR;
     
    33993399
    34003400/* Line 1464 of yacc.c  */
    3401 #line 951 "grammar.y"
     3401#line 950 "grammar.y"
    34023402    {
    34033403            int r; TESTSETINT((yyvsp[(4) - (8)].lv),r);
    34043404            int c; TESTSETINT((yyvsp[(7) - (8)].lv),c);
    3405             if (r < 1)
    3406               MYYERROR("rows must be greater than 0");
    3407             if (c < 0)
    3408               MYYERROR("cols must be greater than -1");
    34093405            leftv v;
    34103406            idhdl h;
     
    34443440
    34453441/* Line 1464 of yacc.c  */
    3446 #line 991 "grammar.y"
     3442#line 986 "grammar.y"
    34473443    {
    34483444            if ((yyvsp[(1) - (2)].i) == MATRIX_CMD)
     
    34753471
    34763472/* Line 1464 of yacc.c  */
    3477 #line 1017 "grammar.y"
     3473#line 1012 "grammar.y"
    34783474    {
    34793475            int t=(yyvsp[(1) - (3)].lv).Typ();
     
    35013497
    35023498/* Line 1464 of yacc.c  */
    3503 #line 1038 "grammar.y"
     3499#line 1033 "grammar.y"
    35043500    {
    35053501            if (iiDeclCommand(&(yyval.lv),&(yyvsp[(2) - (2)].lv),myynest,(yyvsp[(1) - (2)].i),&((yyvsp[(2) - (2)].lv).req_packhdl->idroot)))
     
    35113507
    35123508/* Line 1464 of yacc.c  */
    3513 #line 1051 "grammar.y"
     3509#line 1046 "grammar.y"
    35143510    {
    35153511            leftv v = &(yyvsp[(2) - (5)].lv);
     
    35273523
    35283524/* Line 1464 of yacc.c  */
    3529 #line 1065 "grammar.y"
     3525#line 1060 "grammar.y"
    35303526    {
    35313527          // let rInit take care of any errors
     
    35373533
    35383534/* Line 1464 of yacc.c  */
    3539 #line 1073 "grammar.y"
     3535#line 1068 "grammar.y"
    35403536    {
    35413537            memset(&(yyval.lv),0,sizeof((yyval.lv)));
     
    35513547
    35523548/* Line 1464 of yacc.c  */
    3553 #line 1082 "grammar.y"
     3549#line 1077 "grammar.y"
    35543550    {
    35553551            memset(&(yyval.lv),0,sizeof((yyval.lv)));
     
    35983594
    35993595/* Line 1464 of yacc.c  */
    3600 #line 1128 "grammar.y"
     3596#line 1123 "grammar.y"
    36013597    {
    36023598            (yyval.lv) = (yyvsp[(1) - (3)].lv);
     
    36093605
    36103606/* Line 1464 of yacc.c  */
    3611 #line 1138 "grammar.y"
     3607#line 1133 "grammar.y"
    36123608    {
    36133609            (yyval.lv) = (yyvsp[(2) - (3)].lv);
     
    36183614
    36193615/* Line 1464 of yacc.c  */
    3620 #line 1144 "grammar.y"
     3616#line 1139 "grammar.y"
    36213617    {
    36223618            expected_parms = TRUE;
     
    36273623
    36283624/* Line 1464 of yacc.c  */
    3629 #line 1151 "grammar.y"
     3625#line 1146 "grammar.y"
    36303626    { (yyval.i) = (yyvsp[(1) - (1)].i); ;}
    36313627    break;
     
    36343630
    36353631/* Line 1464 of yacc.c  */
    3636 #line 1153 "grammar.y"
     3632#line 1148 "grammar.y"
    36373633    { (yyval.i) = (yyvsp[(1) - (1)].i); ;}
    36383634    break;
     
    36413637
    36423638/* Line 1464 of yacc.c  */
    3643 #line 1155 "grammar.y"
     3639#line 1150 "grammar.y"
    36443640    { (yyval.i) = (yyvsp[(1) - (1)].i); ;}
    36453641    break;
     
    36483644
    36493645/* Line 1464 of yacc.c  */
    3650 #line 1164 "grammar.y"
     3646#line 1159 "grammar.y"
    36513647    { if ((yyvsp[(1) - (2)].i) != '<') YYERROR;
    36523648            if((feFilePending=feFopen((yyvsp[(2) - (2)].name),"r",NULL,TRUE))==NULL) YYERROR; ;}
     
    36563652
    36573653/* Line 1464 of yacc.c  */
     3654#line 1162 "grammar.y"
     3655    { newFile((yyvsp[(2) - (4)].name),feFilePending); ;}
     3656    break;
     3657
     3658  case 129:
     3659
     3660/* Line 1464 of yacc.c  */
    36583661#line 1167 "grammar.y"
    3659     { newFile((yyvsp[(2) - (4)].name),feFilePending); ;}
    3660     break;
    3661 
    3662   case 129:
    3663 
    3664 /* Line 1464 of yacc.c  */
    3665 #line 1172 "grammar.y"
    36663662    {
    36673663            feHelp((yyvsp[(2) - (3)].name));
     
    36733669
    36743670/* Line 1464 of yacc.c  */
    3675 #line 1177 "grammar.y"
     3671#line 1172 "grammar.y"
    36763672    {
    36773673            feHelp(NULL);
     
    36823678
    36833679/* Line 1464 of yacc.c  */
    3684 #line 1184 "grammar.y"
     3680#line 1179 "grammar.y"
    36853681    {
    36863682            singular_example((yyvsp[(2) - (3)].name));
     
    36923688
    36933689/* Line 1464 of yacc.c  */
    3694 #line 1192 "grammar.y"
     3690#line 1187 "grammar.y"
    36953691    {
    36963692          if (basePack!=(yyvsp[(2) - (2)].lv).req_packhdl)
     
    37063702
    37073703/* Line 1464 of yacc.c  */
    3708 #line 1204 "grammar.y"
     3704#line 1199 "grammar.y"
    37093705    {
    37103706          leftv v=&(yyvsp[(2) - (2)].lv);
     
    37273723
    37283724/* Line 1464 of yacc.c  */
    3729 #line 1220 "grammar.y"
     3725#line 1215 "grammar.y"
    37303726    {
    37313727          leftv v=&(yyvsp[(3) - (3)].lv);
     
    37483744
    37493745/* Line 1464 of yacc.c  */
    3750 #line 1239 "grammar.y"
     3746#line 1234 "grammar.y"
    37513747    {
    37523748            list_cmd((yyvsp[(3) - (4)].i),NULL,"// ",TRUE);
     
    37573753
    37583754/* Line 1464 of yacc.c  */
    3759 #line 1243 "grammar.y"
     3755#line 1238 "grammar.y"
    37603756    {
    37613757            list_cmd((yyvsp[(3) - (4)].i),NULL,"// ",TRUE);
     
    37663762
    37673763/* Line 1464 of yacc.c  */
    3768 #line 1247 "grammar.y"
     3764#line 1242 "grammar.y"
    37693765    {
    37703766            if ((yyvsp[(3) - (4)].i)==QRING_CMD) (yyvsp[(3) - (4)].i)=RING_CMD;
     
    37763772
    37773773/* Line 1464 of yacc.c  */
    3778 #line 1252 "grammar.y"
     3774#line 1247 "grammar.y"
    37793775    {
    37803776            list_cmd((yyvsp[(3) - (4)].i),NULL,"// ",TRUE);
     
    37853781
    37863782/* Line 1464 of yacc.c  */
    3787 #line 1256 "grammar.y"
     3783#line 1251 "grammar.y"
    37883784    {
    37893785            list_cmd(RING_CMD,NULL,"// ",TRUE);
     
    37943790
    37953791/* Line 1464 of yacc.c  */
    3796 #line 1260 "grammar.y"
     3792#line 1255 "grammar.y"
    37973793    {
    37983794            list_cmd((yyvsp[(3) - (4)].i),NULL,"// ",TRUE);
     
    38033799
    38043800/* Line 1464 of yacc.c  */
    3805 #line 1264 "grammar.y"
     3801#line 1259 "grammar.y"
    38063802    {
    38073803            list_cmd(PROC_CMD,NULL,"// ",TRUE);
     
    38123808
    38133809/* Line 1464 of yacc.c  */
    3814 #line 1268 "grammar.y"
     3810#line 1263 "grammar.y"
    38153811    {
    38163812            list_cmd(0,(yyvsp[(3) - (4)].lv).Fullname(),"// ",TRUE);
     
    38223818
    38233819/* Line 1464 of yacc.c  */
    3824 #line 1273 "grammar.y"
     3820#line 1268 "grammar.y"
    38253821    {
    38263822            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38333829
    38343830/* Line 1464 of yacc.c  */
    3835 #line 1279 "grammar.y"
     3831#line 1274 "grammar.y"
    38363832    {
    38373833            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38443840
    38453841/* Line 1464 of yacc.c  */
    3846 #line 1285 "grammar.y"
     3842#line 1280 "grammar.y"
    38473843    {
    38483844            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38553851
    38563852/* Line 1464 of yacc.c  */
    3857 #line 1291 "grammar.y"
     3853#line 1286 "grammar.y"
    38583854    {
    38593855            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38663862
    38673863/* Line 1464 of yacc.c  */
    3868 #line 1297 "grammar.y"
     3864#line 1292 "grammar.y"
    38693865    {
    38703866            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38773873
    38783874/* Line 1464 of yacc.c  */
    3879 #line 1303 "grammar.y"
     3875#line 1298 "grammar.y"
    38803876    {
    38813877            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38883884
    38893885/* Line 1464 of yacc.c  */
    3890 #line 1309 "grammar.y"
     3886#line 1304 "grammar.y"
    38913887    {
    38923888            if((yyvsp[(3) - (6)].lv).Typ() == PACKAGE_CMD)
     
    38993895
    39003896/* Line 1464 of yacc.c  */
    3901 #line 1321 "grammar.y"
     3897#line 1316 "grammar.y"
    39023898    {
    39033899            list_cmd(-1,NULL,"// ",TRUE);
     
    39083904
    39093905/* Line 1464 of yacc.c  */
    3910 #line 1327 "grammar.y"
     3906#line 1322 "grammar.y"
    39113907    { yyInRingConstruction = TRUE; ;}
    39123908    break;
     
    39153911
    39163912/* Line 1464 of yacc.c  */
    3917 #line 1336 "grammar.y"
     3913#line 1331 "grammar.y"
    39183914    {
    39193915            const char *ring_name = (yyvsp[(2) - (8)].lv).name;
     
    39533949
    39543950/* Line 1464 of yacc.c  */
    3955 #line 1369 "grammar.y"
     3951#line 1364 "grammar.y"
    39563952    {
    39573953            const char *ring_name = (yyvsp[(2) - (2)].lv).name;
     
    39653961
    39663962/* Line 1464 of yacc.c  */
    3967 #line 1376 "grammar.y"
     3963#line 1371 "grammar.y"
    39683964    {
    39693965            yyInRingConstruction = FALSE;
     
    39753971
    39763972/* Line 1464 of yacc.c  */
    3977 #line 1384 "grammar.y"
     3973#line 1379 "grammar.y"
    39783974    {
    39793975            if (((yyvsp[(1) - (2)].i)!=LIB_CMD)||(jjLOAD((yyvsp[(2) - (2)].name),TRUE))) YYERROR;
     
    39843980
    39853981/* Line 1464 of yacc.c  */
    3986 #line 1393 "grammar.y"
     3982#line 1388 "grammar.y"
    39873983    {
    39883984            if (((yyvsp[(1) - (2)].i)==KEEPRING_CMD) && (myynest==0))
     
    40584054
    40594055/* Line 1464 of yacc.c  */
    4060 #line 1465 "grammar.y"
     4056#line 1460 "grammar.y"
    40614057    {
    40624058            type_cmd(&((yyvsp[(2) - (2)].lv)));
     
    40674063
    40684064/* Line 1464 of yacc.c  */
    4069 #line 1469 "grammar.y"
     4065#line 1464 "grammar.y"
    40704066    {
    40714067            //Print("typ is %d, rtyp:%d\n",$1.Typ(),$1.rtyp);
     
    40954091
    40964092/* Line 1464 of yacc.c  */
    4097 #line 1498 "grammar.y"
     4093#line 1493 "grammar.y"
    40984094    {
    40994095            int i; TESTSETINT((yyvsp[(3) - (5)].lv),i);
     
    41134109
    41144110/* Line 1464 of yacc.c  */
    4115 #line 1511 "grammar.y"
     4111#line 1506 "grammar.y"
    41164112    {
    41174113            if (currentVoice->ifsw==1)
     
    41354131
    41364132/* Line 1464 of yacc.c  */
    4137 #line 1528 "grammar.y"
     4133#line 1523 "grammar.y"
    41384134    {
    41394135            int i; TESTSETINT((yyvsp[(3) - (5)].lv),i);
     
    41494145
    41504146/* Line 1464 of yacc.c  */
    4151 #line 1537 "grammar.y"
     4147#line 1532 "grammar.y"
    41524148    {
    41534149            if (exitBuffer(BT_break)) YYERROR;
     
    41594155
    41604156/* Line 1464 of yacc.c  */
    4161 #line 1542 "grammar.y"
     4157#line 1537 "grammar.y"
    41624158    {
    41634159            if (contBuffer(BT_break)) YYERROR;
     
    41694165
    41704166/* Line 1464 of yacc.c  */
    4171 #line 1550 "grammar.y"
     4167#line 1545 "grammar.y"
    41724168    {
    41734169            /* -> if(!$2) break; $3; continue;*/
     
    41834179
    41844180/* Line 1464 of yacc.c  */
    4185 #line 1562 "grammar.y"
     4181#line 1557 "grammar.y"
    41864182    {
    41874183            /* $2 */
     
    42044200
    42054201/* Line 1464 of yacc.c  */
    4206 #line 1581 "grammar.y"
     4202#line 1576 "grammar.y"
    42074203    {
    42084204            idhdl h = enterid((yyvsp[(2) - (3)].name),myynest,PROC_CMD,&IDROOT,TRUE);
     
    42194215
    42204216/* Line 1464 of yacc.c  */
    4221 #line 1591 "grammar.y"
     4217#line 1586 "grammar.y"
    42224218    {
    42234219            idhdl h = enterid((yyvsp[(1) - (3)].name),myynest,PROC_CMD,&IDROOT,TRUE);
     
    42434239
    42444240/* Line 1464 of yacc.c  */
    4245 #line 1610 "grammar.y"
     4241#line 1605 "grammar.y"
    42464242    {
    42474243            omFree((ADDRESS)(yyvsp[(3) - (4)].name));
     
    42684264
    42694265/* Line 1464 of yacc.c  */
    4270 #line 1633 "grammar.y"
     4266#line 1628 "grammar.y"
    42714267    {
    42724268            // decl. of type proc p(int i)
     
    42794275
    42804276/* Line 1464 of yacc.c  */
    4281 #line 1639 "grammar.y"
     4277#line 1634 "grammar.y"
    42824278    {
    42834279            // decl. of type proc p(i)
     
    42934289
    42944290/* Line 1464 of yacc.c  */
    4295 #line 1651 "grammar.y"
     4291#line 1646 "grammar.y"
    42964292    {
    42974293            iiRETURNEXPR.Copy(&(yyvsp[(3) - (4)].lv));
     
    43044300
    43054301/* Line 1464 of yacc.c  */
    4306 #line 1657 "grammar.y"
     4302#line 1652 "grammar.y"
    43074303    {
    43084304            if ((yyvsp[(1) - (3)].i)==RETURN)
     
    43184314
    43194315/* Line 1464 of yacc.c  */
    4320 #line 4320 "grammar.cc"
     4316#line 4315 "grammar.cc"
    43214317      default: break;
    43224318    }
  • Singular/grammar.y

    r2675bd r5638b9  
    951951            int r; TESTSETINT($4,r);
    952952            int c; TESTSETINT($7,c);
    953             if (r < 1)
    954               MYYERROR("rows must be greater than 0");
    955             if (c < 0)
    956               MYYERROR("cols must be greater than -1");
    957953            leftv v;
    958954            idhdl h;
  • Singular/iparith.cc

    r2675bd r5638b9  
    26672667  if(strcmp(s, "with")==0)
    26682668    return jjLOAD((char*)v->Data(), TRUE);
     2669  if (strcmp(s,"try")==0)
     2670    return jjLOAD_TRY((char*)v->Data());
    26692671  WerrorS("invalid second argument");
    2670   WerrorS("load(\"libname\" [,\"with\"]);");
     2672  WerrorS("load(\"libname\" [,option]);");
    26712673  return TRUE;
    26722674}
     
    53265328#endif /* HAVE_DYNAMIC_LOADING */
    53275329  }
     5330  return TRUE;
     5331}
     5332BOOLEAN jjLOAD_TRY(const char *s)
     5333{
     5334  WerrorS("not yet");
    53285335  return TRUE;
    53295336}
  • Singular/ipassign.cc

    r2675bd r5638b9  
    460460  return FALSE;
    461461}
     462static BOOLEAN jiA_NUMBER2_I(leftv res, leftv a, Subexpr e)
     463{
     464  if (e==NULL)
     465  {
     466    if (res->data!=NULL)
     467    {
     468      number2 nn=(number2)res->data;
     469      number2 n=n2Init((long)a->Data(),nn->cf);
     470      n2Delete(nn);
     471      res->data=(void *)n;
     472    }
     473    else
     474    {
     475      WerrorS("no (c)ring avialable for conversion from int");
     476      return TRUE;
     477    }
     478  }
     479  else
     480  {
     481    int i=e->start-1;
     482    if (i<0)
     483    {
     484      Werror("index[%d] must be positive",i+1);
     485      return TRUE;
     486    }
     487    bigintmat *iv=(bigintmat *)res->data;
     488    if (e->next==NULL)
     489    {
     490      WerrorS("only one index given");
     491      return TRUE;
     492    }
     493    else
     494    {
     495      int c=e->next->start;
     496      if ((i>=iv->rows())||(c<1)||(c>iv->cols()))
     497      {
     498        Werror("wrong range [%d,%d] in cmatrix %s(%d,%d)",i+1,c,res->Name(),iv->rows(),iv->cols());
     499        return TRUE;
     500      }
     501      else
     502      {
     503        n_Delete((number *)&BIMATELEM(*iv,i+1,c),iv->basecoeffs());
     504        BIMATELEM(*iv,i+1,c) = n_Init((long)a->Data(),iv->basecoeffs());
     505      }
     506    }
     507  }
     508  return FALSE;
     509}
     510static BOOLEAN jiA_NUMBER2_N(leftv res, leftv a, Subexpr e)
     511{
     512  if (e==NULL)
     513  {
     514    if (res->data!=NULL)
     515    {
     516      number2 nn=(number2)res->data;
     517      if (currRing->cf==nn->cf)
     518      {
     519        number2 n=(number2)omAlloc(sizeof(*n));
     520        n->cf=currRing->cf; n->cf++;
     521        n->n=(number)a->CopyD(NUMBER_CMD);
     522        n2Delete(nn);
     523        res->data=(void *)n;
     524      }
     525      else
     526      {
     527        WerrorS("different base");
     528        return TRUE;
     529      }
     530    }
     531    else
     532    {
     533      WerrorS("no (c)ring avialable for conversion from number");
     534      return TRUE;
     535    }
     536  }
     537  else
     538  {
     539    int i=e->start-1;
     540    if (i<0)
     541    {
     542      Werror("index[%d] must be positive",i+1);
     543      return TRUE;
     544    }
     545    bigintmat *iv=(bigintmat *)res->data;
     546    if (e->next==NULL)
     547    {
     548      WerrorS("only one index given");
     549      return TRUE;
     550    }
     551    else
     552    {
     553      int c=e->next->start;
     554      if ((i>=iv->rows())||(c<1)||(c>iv->cols()))
     555      {
     556        Werror("wrong range [%d,%d] in cmatrix %s(%d,%d)",i+1,c,res->Name(),iv->rows(),iv->cols());
     557        return TRUE;
     558      }
     559      else if (iv->basecoeffs()==currRing->cf)
     560      {
     561        n_Delete((number *)&BIMATELEM(*iv,i+1,c),iv->basecoeffs());
     562        BIMATELEM(*iv,i+1,c) = (number)(a->CopyD(NUMBER_CMD));
     563      }
     564      else
     565      {
     566        WerrorS("different base");
     567        return TRUE;
     568      }
     569    }
     570  }
     571  return FALSE;
     572}
    462573#endif
    463574static BOOLEAN jiA_BIGINT(leftv res, leftv a, Subexpr e)
     
    714825}
    715826static BOOLEAN jiA_MODUL_P(leftv res, leftv a, Subexpr)
     827/* module = poly */
    716828{
    717829  if (res->data!=NULL) idDelete((ideal*)&res->data);
     
    18801992      sleftv t;
    18811993      matrix olm = (matrix)l->Data();
    1882       int rk=olm->rank;
     1994      int rk;
    18831995      char *pr=((map)olm)->preimage;
    18841996      BOOLEAN module_assign=(/*l->Typ()*/ lt==MODUL_CMD);
     
    18922004      if (lt /*l->Typ()*/==MATRIX_CMD)
    18932005      {
    1894         num=olm->cols()*olm->rows();
     2006        rk=olm->rows();
     2007        num=olm->cols()*rk /*olm->rows()*/;
    18952008        lm=mpNew(olm->rows(),olm->cols());
    18962009        int el;
     
    19042017        num=exprlist_length(hh);
    19052018        lm=(matrix)idInit(num,1);
    1906         rk=1;
    19072019        if (module_assign)
    19082020        {
     2021          rk=0;
    19092022          mtyp=MODUL_CMD;
    19102023          etyp=VECTOR_CMD;
    19112024        }
     2025        else
     2026          rk=1;
    19122027      }
    19132028
  • Singular/ipprint.cc

    r2675bd r5638b9  
    6363static void ipPrint_MA0(matrix m, const char *name)
    6464{
    65   if (MATCOLS(m)>0)
     65  if ((MATCOLS(m)>0)&&(MATROWS(m)>0))
    6666  {
    6767    char **s=(char **)omAlloc(MATCOLS(m)*MATROWS(m)*sizeof(char*));
     
    181181    omFreeSize((ADDRESS)l,MATCOLS(m)*sizeof(int));
    182182  }
     183  else Print("%d x %d zero matrix\n",MATROWS(m),MATCOLS(m));
    183184}
    184185
  • Singular/ipshell.h

    r2675bd r5638b9  
    7979/// load lib/module given in v
    8080BOOLEAN jjLOAD(const char *s, BOOLEAN autoexport = FALSE);
     81BOOLEAN jjLOAD_TRY(const char *s);
    8182BOOLEAN iiLocateLib(const char* lib, char* where);
    8283leftv   iiMap(map theMap, const char * what);
  • Singular/libsingular.h

    r2675bd r5638b9  
    1818#include <polys/sparsmat.h>
    1919
     20#include <Singular/mod_lib.h>
    2021#include <Singular/subexpr.h>
    2122#include <Singular/tok.h>
  • Singular/links/ssiLink.cc

    r2675bd r5638b9  
    6060#include <time.h>
    6161
    62 #define SSI_VERSION 8
     62#define SSI_VERSION 9
    6363// 5->6: changed newstruct representation
    6464// 6->7: attributes
    6565// 7->8: qring
     66// 8->9: module: added rank
    6667
    6768#define SSI_BASE 16
     
    11391140        fputs("99\n",d->f_write);
    11401141        fflush(d->f_write);
     1142        if (d->f_read!=NULL) { s_close(d->f_read);s_free(d->f_read);}
     1143        if (d->f_write!=NULL) { fclose(d->f_write); d->f_write=NULL; }
    11411144      }
    11421145      if (d->r!=NULL) rKill(d->r);
     
    11501153        struct timespec rem;
    11511154        int r;
    1152         do
     1155        loop
    11531156        {
    11541157          r = nanosleep(&t, &rem);
    11551158          t = rem;
    1156         } while ((r < 0) && (errno == EINTR)
    1157             && (si_waitpid(d->pid,NULL,WNOHANG) == 0));
    1158         if ((r == 0) && (kill(d->pid,0) == 0))
     1159          // child finished:
     1160          if (si_waitpid(d->pid,NULL,WNOHANG) != 0) break;
     1161          // other signal, waited s>= 100 ms:
     1162          if ((r==0) || (errno != EINTR)) break;
     1163        }
     1164        if (kill(d->pid,0) == 0)
    11591165        {
    11601166          kill(d->pid,15);
    11611167          t.tv_sec=5; // <=5s
    11621168          t.tv_nsec=0;
    1163           do
     1169          loop
    11641170          {
    11651171            r = nanosleep(&t, &rem);
    11661172            t = rem;
    1167           } while ((r < 0) && (errno == EINTR)
    1168               && (si_waitpid(d->pid,NULL,WNOHANG) == 0));
    1169           if ((r == 0) && (kill(d->pid,0) == 0))
     1173            // child finished:
     1174            if (si_waitpid(d->pid,NULL,WNOHANG) != 0) break;
     1175            // other signal, waited s>= 100 ms:
     1176            if ((r==0) || (errno != EINTR)) break;
     1177          }
     1178          if (kill(d->pid,0) == 0)
    11701179          {
    11711180            kill(d->pid,9); // just to be sure
     
    11741183        }
    11751184      }
    1176       if (d->f_read!=NULL) s_close(d->f_read);
    1177       if (d->f_read!=NULL) s_free(d->f_read);
    1178       if (d->f_write!=NULL) fclose(d->f_write);
     1185      if (d->f_read!=NULL) { s_close(d->f_read);s_free(d->f_read);}
     1186      if (d->f_write!=NULL) { fclose(d->f_write); d->f_write=NULL; }
    11791187      if ((strcmp(l->mode,"tcp")==0)
    11801188      || (strcmp(l->mode,"fork")==0))
     
    12661274    case 10:res->rtyp=MODUL_CMD;
    12671275           if (d->r==NULL) goto no_ring;
    1268            res->data=(char*)ssiReadIdeal(d);
     1276           {
     1277             int rk=s_readint(d->f_read);
     1278             ideal M=ssiReadIdeal(d);
     1279             M->rank=rk;
     1280             res->data=(char*)M;
     1281           }
    12691282           break;
    12701283    case 11:
     
    14471460                        if(tt==IDEAL_CMD)       fputs("7 ",d->f_write);
    14481461                        else if(tt==MATRIX_CMD) fputs("8 ",d->f_write);
    1449                         else                    fputs("10 ",d->f_write);
     1462                        else
     1463                        {
     1464                          ideal M=(ideal)dd;
     1465                          fprintf(d->f_write,"10 %d ",M->rank);
     1466                        }
    14501467                        ssiWriteIdeal(d,tt,(ideal)dd);
    14511468                        break;
  • Singular/mod_lib.cc

    r2675bd r5638b9  
    22
    33#include <resources/feFopen.h>
     4#include <reporter/reporter.h>
    45#include <polys/mod_raw.h>
    56
     
    3132  const unsigned char mach_FAT[]={0xca,0xfe,0xba,0xbe,0};
    3233  const unsigned char mach_fat[]={0xbe,0xba,0xfe,0xca,0};
     34
     35  const unsigned char utf16be[]={0xfe,0xff,0};
     36  const unsigned char utf16le[]={0xff,0xfe,0};
     37  const unsigned char utf8ms[]={0xEF,0xBB,0xBF,0};
    3338
    3439  int i=0;
     
    113118    goto lib_type_end;
    114119  }
     120  if ((strncmp(buf,(const char *)utf16be,2)==0)
     121  ||(strncmp(buf,(const char *)utf16le,2)==0))
     122  {
     123    WerrorS("UTF-16 not supported");
     124    LT=LT_NOTFOUND;
     125    goto lib_type_end;
     126  }
     127  if (strncmp(buf,(const char *)utf8ms,3)==0)
     128  {
     129    WarnS("UTF-8 detected - may not work");
     130    LT=LT_SINGULAR;
     131    goto lib_type_end;
     132  }
    115133  if(isprint(buf[0]) || buf[0]=='\n')
    116134  { LT = LT_SINGULAR; goto lib_type_end; }
  • Singular/subexpr.cc

    r2675bd r5638b9  
    223223        case NUMBER_CMD:
    224224        case BIGINT_CMD:
     225          if (t==NUMBER_CMD)
     226          {
     227            number n=(number)d;
     228            nNormalize(n);
     229            d=n;
     230          }
    225231          s=String(d);
    226232          if (s==NULL) return;
  • Singular/table.h

    r2675bd r5638b9  
    12211221,{D(jiA_BIGINTMAT),CMATRIX_CMD,    CMATRIX_CMD}
    12221222,{D(jiA_NUMBER2),  CNUMBER_CMD,    CNUMBER_CMD }
     1223,{D(jiA_NUMBER2_I),CNUMBER_CMD,    INT_CMD }
     1224,{D(jiA_NUMBER2_N),CNUMBER_CMD,    NUMBER_CMD }
    12231225,{D(jiA_CRING),    CRING_CMD,      CRING_CMD }
    12241226#endif
  • Singular/walk.cc

    r2675bd r5638b9  
    67936793    // We only perturb the current target vector at the recursion level 1
    67946794    if(Xngleich == 0 && nlev == 1) //(ngleich == 0) important, e.g. ex2, ex3
    6795       if (MivComp(next_vect, omega2) == 1)
     6795      if (MivComp(next_vect, omega2) != 1)
    67966796      {
    67976797        // to dispense with taking initial (and lifting/interreducing
  • Singular/walk.h

    • Property mode changed from 100644 to 100755
    rcb5589 r5638b9  
    5252
    5353/* Okt -- Nov'01 */
    54 // compute a Groebner basis of an ideal G w.r.t. lexicographic order
     54// compute a Groebner basis of an ideal G w.r.t. lexicographic order 
    5555//ideal Mwalk(ideal Go, intvec* orig_M, intvec* target_M);
    56 ideal Mwalk(ideal Go, intvec* orig_M, intvec* target_M, ring baseRing);
     56ideal Mwalk(ideal Go, intvec* orig_M, intvec* target_M, ring baseRing, int reduction, int printout);
    5757
    5858// random walk algorithm to compute a Groebner basis
    59 ideal Mrwalk(ideal Go, intvec* curr_weight, intvec* target_weight, int weight_rad, int pert_deg, ring baseRing);
     59
     60ideal Mrwalk(ideal Go, intvec* orig_M, intvec* target_M, int weight_rad, int pert_deg, int reduction, int printout);
    6061
    6162/* the perturbation walk algorithm */
    6263
    63 ideal Mpwalk(ideal Go, int op_deg, int tp_deg,intvec* curr_weight,intvec* target_weight, int nP);
     64ideal Mpwalk(ideal Go, int op_deg, int tp_deg,intvec* curr_weight,intvec* target_weight, int nP, int reduction, int printout);
    6465
    6566/* the perturbation walk algorithm with random element */
    66 
    67 ideal Mprwalk(ideal Go, intvec* curr_weight, intvec* target_weight, int weight_rad, int op_deg, int tp_deg, ring baseRing);
     67ideal Mprwalk(ideal Go, intvec* orig_M, intvec* target_M, int weight_rad, int op_deg, int tp_deg, int nP, int reduction, int printout);
    6868
    6969/* The fractal walk algorithm */
    70 ideal Mfwalk(ideal G, intvec* ivstart, intvec* ivtarget);
     70ideal Mfwalk(ideal G, intvec* ivstart, intvec* ivtarget, int reduction, int printout);
    7171
    7272/* The fractal walk algorithm with random element */
    73 ideal Mfrwalk(ideal G, intvec* ivstart, intvec* ivtarget,int weight_rad);
     73ideal Mfrwalk(ideal G, intvec* ivstart, intvec* ivtarget, int weight_rad, int reduction, int printout);
    7474
    7575/* Implement Tran's idea */
  • Tst/BuchDL/Ex_L5.res.gz.uu

    r2675bd r5638b9  
    11begin 640 Ex_L5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825TC*L0A2\7UKY50P6
     31MRP5MG"Z6ZSS"+A&C<1I-IRWR6,!,&*]7F#.4,":$<?V_#*]*$YIQ:403$`-R
     32ME+[4KWB`<O7%VOAE:&LR4%D3]50NIKC5W,VLN,MX9Y=S%68IY$A,U[",K2(R
     33MC5=9WO!R-=4HHVH9JS2SEA[%,Y[]<B7C*XO2D`7'5C'FG;N*4=Q^QE-@2W-K
     34M$DWC))I8<?9N'N:V;?\MCHB8@N?I3!P3M9-81Q[)S.RA>O59:OF$Z!4[4XB\
     35MU]3HI0P\+<:S@,Q8^ZGG[JW]U(.580JTG]+Q.BL9^/X7A2HB5MT;5_H,-WMR
     36M`1^I\U-NT5:+V>6)DL*)<JE5]8+=XR12D,TE?L(75GYA-N_YP30G+.T(F8%2
     37M%_L]SO.#B:U]A1.:/-%42H8&'QI^B$&5W)U30%6L)-HY`U0'DD0]@VAGZ)+$
     38MV,?6*H,[60$'6N)!.+.""I_5H((B*DS5;4?1>\96`%\*10?H_7IZ;G(YEK!<
     39MLP2'6*C!PC0._/8AR/J=?<CB)K<>LG7!,C:\AXEP!_R76+C+$T_5&TK3@.YX
     40M6QRJJ"/4D%3LD#V!MV\/;GL/V"-/J28J@F#7((VHH%U%9H6OHR<J;G+5<T_N
     41M\IV1`Y;<*3/:[K'TZ+&STR-N17?3X\<TVZ[G[T52+(ZFR3:XUTR3-64:VO9D
     42M:IEB:MEB76E3-+%$I6E\%<P!WVN9F(5E*"25+>,BA!/XAF]K;^Z^\S$?E*A`
     43MG@ZKMEA39^"XMKTKVLV?B*`DI9$%'"`+58VB[79?'__,=GZ..3`0W1^(PE9K
     44M=R`7#J>4;*-56MJDA'?WT=G6=0V*&V/AU!DZM1#'+F-![=`#;IB=[@8X:H+4
     45M3:%DZL5GK\L[X(S9Z<X`8+APQ,3C>^&XVE3?K)]Q"ME3J3H!C^IHOZ`-V]>&
     46M)9/30].I280=8Q9WC##AGE_,:!68+CTZE?VSIW*7U52D8:.9Y'&R%G,&)DME
     47MB!.$>L8>PF.NZP'*++?5\JL3O*LG[W!PLP@W')B6WNK3+LS),`<G/EK#@7,1
     48M9QB0V84C#HFXR35H8;K!7$_G:Z[VGRD>\1)H05;7H%/%K\<HSV,+"&WG@C]?
     49M`)418)>_4_[.^+O'WWW^'C2:)[]0:I.^-N0%_-'5[Z*%T'.DYFD>SD^3JJS7
     50M^>$,2R6S4=,[7<N2N:>W2F=X0S+3_V=D?65PAL<DL[$YQA-KN82$\^53Z`+"
     51M5F$R21<6PIPYU'4\C;2>OD/`50B(Q3=+,-M7`#W85VIZ7>RB/5@D2N0C[S[V
     52MJ;/WSY@,O6YE,DS'Z9_1*HGFJ`-."2[3F!2]7G52*(;3I\81X'+N,NB=LV%O
     53M0KV.N[0#@G`BO!7#J<!2#,R$\4L620;OW!'\.KB^-$*@(,JP$%%B;A*O(-PY
     54M`#1;IEG$8ZXBSER\!Q2UMF<@:U*G_,]>^*^YNRHQPS`&.I^-$7I5#`I]./R0
     55M1V_)&=X(5M`'_:<`[R!H>+YEKPV7<?>12B)NFN]\#'>_XS`P#4A6QM!@I/0H
     56M&!4I.PH21>I5\FBME9+4KTNY5;LE:5"!=:TG)&G[=%T[-5#>\98DU3LAAA><
     57MNP<,/%[E4:)/%B(1[QPL&'/->L2L+-9+;HXL.%7I3,FP#&6@]-U`8M3<-#!]
     58M!RH0^FYP[I[AI'7=1"'=#Y8!U;I8[A$QD^C\I+N'\U*GEQ*P<0-\DE<DFW_6
     59M^J[8:E%[V'.2K5V7PP_[4K)U*FQ'O2O9NO^;;;W#NY871O/T32##RB`6\<?I
     60M)%X@L)-?X2JS1G83;VCTKQT85@<%T75#Y21/AU*W09S$50YGQXN=>!$E>-P@
     61ML,"D?[1L`N.PAK[R4<W0KN+MZ0J(;H.H5!14LW<1)^G*^B,<IX\PK",TM<D5
     62M&>!$#I0`?<#2;49:\6K2RB1:YD_'RA7,AZS"*=%J//@-2)P=+BZ,7@T:*B"^
     63M7@5T&VOQ2S)1_P0;U'[$UT[7;?HG1,PWUGIQO_S2B=!OGWLB9'@SO5_[_FUX
     64MW$?=NI(.;`C,,Q_#6IY1+]XV"^:0YVT3*Q'/17.CMQB!*^7]G*?C?9F9IJ2F
     65M3%'.,W[+PT0M[[<AAZR*@5''TVV&IP/#TUB44P6V9T=.%=G;.78R]WMGQP'K
     66M>\?=&9SL3JP$#FYDP5TV@N?F4<C;JAE;7A%B+[^SYA?EO%I9R.)\45;D579H
     67L[UPR%+K'VZFW%ZK'WRFR:QXC`'B_C+^_PU_9K?$';=?_:/P7T_42U+4G````
    6968`
    7069end
  • Tst/Long/deform_l.res.gz.uu

    r2675bd r5638b9  
    11begin 640 deform_l.res.gz
    2 M'XL(")`IVE0``V1E9F]R;5]L+G)E<P#M7/EOVS@6_MU_!;=8H+9)IA8E'TG&
     2M'XL("$QZ6U4``V1E9F]R;5]L+G)E<P#M7/EOVS@6_MU_!;=8H+9)IA8E'TG&
    33M`:S+CN/TV%F@`P1IQHW55CNVE5H^)`_F?]_W*.KPT29NT^YB$">Q)/+CX^/U
    44MO?<H*;_^VSY_20C1SLB+%R/O0S";W(R/YN&\]*O*$4>0,PZF'PF9>^$\)(`A
     
    99M:C@=(1Q3\=(/R>?%,/3YIV`2?/2F7K`(`7XW\T)O.O=&9.6#M)7G?_PTYTOO
    1010M=A[,2C6V\8.B_.D'[%LO]"?0MJ3SAG,_F)X0-SPA)=E0VEGKU(S6@EKP9T=K
    11 MZJRI&]-N1'O%3D"!-S<WQ`'-4$9(@@]D`O*3CBBT#6&E^^#S8`[?.?XP7:3X
    12 MYXFHY]`S\\5L"MTRE(/#2#B,R8!AC1^"Q4S.@/"(G$_)X$J[)L,9*`I=YHU.
    13 M4`PAPY!`O\S\2';+AL9%-?'RDU=L1*%+V;:H_K:HO7VU4^Q?4"R,U_%'WY.E
    14 M7,@)1B#M2$Z.@`QO;[TP1$U`QF@X'S(RC^^\$L$/*$1>1VULYBD)O;F<^Z^C
    15 MTV2!E-VPDI[V\]-_P:GLT,&5N(89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!]8(2Q/6-Z[9;3UX!VC&PB<*+-NA.JQB.!/N
     89MX6S\..H!QP@;N,="NNJ@2K8NST`"2((OD`,J`]_8R$2``$Y"ZD&M#VG=/HXR
     90M#N8H8*=ZPD[RUWCBJ)_`4:FC9YSM\4,QN@!/%%RR9Y\_/V//WL+?Z`Z^@D`]
     91M4+[%;W(I=J933($$/Y3OTP$)[>$]\2B\]U4_\3?@-X@:WL88293>4LE%_#<:
     92M?0OWU`ZGF;<[_LK]:Y__9M"W7[3\LOQJYL]QP#_X$/<\#X(;XWFRVY]-/)9/
     93M<Y9/63EW9(_+Z`7/4`R(E^N&?/[\&A;`#(YOHF]9O4]>Q0]9L>D2K6_MC&Z(
     94MQ(M?@S;NIR87KS#'R$-%?`,81V`YG)6Q\F3]OHK(USY7M6LBAPBQOP8/Q[XY
     95M0.[K0[`/T*$JP6FS(50//P6K\ILH:3%FGI!RK<+*;]EO3&X>E4=WR'3)MY7@
     96M8*CO@G&<ON/\>1',?9AZR>;3AUDP2?:83DHW5_CX@T%CN6B#]__Q;F&%O/?P
     97MOPHA=A[`E``JDQ4CI!_>WP8U(1LD2FX+#AY>1D`9R6:7AY9)NZR5_*<B_&=$
     980BQ!?A/YGZ;^@U#P02DD`````
    9999`
    100100end
  • Tst/Manual/fwalk.res.gz.uu

    r2675bd r5638b9  
    1 begin 644 fwalk.res.gz
    2 M'XL("$(-$%(``V9W86QK+G)E<P!%4DUKPS`,O?=7B+)#BI,22[:34)K#V"4P
    3 M=NENHY2,=24LE-%FU,JOGYR/]A#IZ3V]6'*R>W^IW@!`E_!:/<.RNW;KMOE<
    4 M;D#0H3DW7;3:+$*&LH3O6]W^K,_'V_K:U=UB-YEQ,I\N@S[X[R*5<&G.)[C`
    5 M%@C3E.*HCSGVJQC:WT>;*:'Y.M8M5-+'I#SWBK%7OJ<80JD\<F`>%CL-%%4R
    6 MXN%#[[<)%XHSCR$H=IY"0$7LY+%"D<\$D7=#M($PJF`4J'-)8T$*,YXB2O3R
    7 M=MQO>Z]R+#+.A9R`(FL=9\E0.K%K:](BG#Q3.`(;3A@TZ\U,T6BW8<01C-G,
    8 MBA&[3IW+V4R9_&A&7R1:YU9`KK1!-(*RF7)SDTV"1APD\3L6:0)WR2B9+:SN
    9 D2?8DV9/E`L,ERCCWRW;E\$>$[_YWC?1J\[3X!WVL<P$\`@``
     1begin 640 fwalk.res.gz
     2M'XL("!0%6E4``V9W86QK+G)E<P!%4L%JPS`,O?<K1-DAQ4F))=M)*,UA[%(8
     3MNW2W44K'NA(6RF@S:N7K)R=.>[#T])Z>;27>OK]LW@!`U_"Z>89Y=^V6;?,Y
     4M7X&@?7-NNF2QFH4,=0W?MT/[LSP?;\MK=^AFVVC&:#Y=!GWPWT6JX=*<3W"!
     5M-1#F.:5)GW+J%RFTOX\V4T/S=3RTL)$^)N6Y5XR]\CVE$$KED0/SL-AXH60C
     6M5]Q_Z-V:JXP+CR%D[#R%@!FQDV6%(E\((N^&:`-ALHI1H"XEC05E6'",*-'+
     7MYKA;]UZ56!5<>IR`(FL=%]E0.F^4MB:OAI,CA2.PWD;-RB&1HM%N9;\(QFPF
     8MQ8A=Y\Z5;&(F/YK15YG6I150*FT0C:!BHMS4)&.)1APD\3L6*8*[9)3<#4,B
     9BF9-D3D8E@\M2=/_6KAX>1/CM?]=$+U9/LW]-@V&+.P(`````
    1010`
    1111end
  • Tst/Short/absfact.res.gz.uu

    r2675bd r5638b9  
    11begin 640 absfact.res.gz
    2 M'XL(".:W8%0``V%B<V9A8W0N<F5S`.V<6V_CN!7'W_,IB,$"*UE20A[>Q`WL
     2M'XL("/C:654``V%B<V9A8W0N<F5S`.V<6V_CN!7'W_,IB,$"*UE20A[>Q`WL
    33MAVW18H&B#Y.\+28#.;%WC*9)$&L:*9^^A[Z(=$1)=KHS#QUE,([$FR6=__GI
    44MD#K*U?5??_LG(83-R#]^^Y5\*-?E^?UJ_N'R[&I7`S."A9]7#ZLRBB_/[&\R
  • Tst/Short/absfact.stat

    r2675bd r5638b9  
    1 1 >> tst_memory_0 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:311468
    2 1 >> tst_memory_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2420736
    3 1 >> tst_memory_2 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2427260
    4 1 >> tst_timer :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:37
    5 2 >> tst_memory_0 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:317460
    6 2 >> tst_memory_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2420736
    7 2 >> tst_memory_2 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2427260
    8 2 >> tst_timer :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:96
    9 3 >> tst_memory_0 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:317460
    10 3 >> tst_memory_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2420736
    11 3 >> tst_memory_2 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2427260
    12 3 >> tst_timer :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:1
    13 4 >> tst_memory_0 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:319692
    14 4 >> tst_memory_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2420736
    15 4 >> tst_memory_2 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2427260
    16 4 >> tst_timer :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:22
    17 5 >> tst_memory_0 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:319584
    18 5 >> tst_memory_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2420736
    19 5 >> tst_memory_2 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:2427260
    20 5 >> tst_timer_1 :: 1389793926:3170:3-1-7:ix86-Linux:mamawutz:159
     11 >> tst_memory_0 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:170680
     21 >> tst_memory_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     31 >> tst_memory_2 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     41 >> tst_timer :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:12
     52 >> tst_memory_0 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:181336
     62 >> tst_memory_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     72 >> tst_memory_2 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     82 >> tst_timer :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:48
     93 >> tst_memory_0 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:181336
     103 >> tst_memory_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     113 >> tst_memory_2 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     123 >> tst_timer :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:1
     134 >> tst_memory_0 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:188168
     144 >> tst_memory_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     154 >> tst_memory_2 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2461696
     164 >> tst_timer :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:7
     175 >> tst_memory_0 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:189200
     185 >> tst_memory_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2547712
     195 >> tst_memory_2 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:2547712
     205 >> tst_timer_1 :: 1431939564:4020, 64 bit:4.0.2:x86_64-Linux:nepomuck:69
  • doc/NEWS.texi

    r2675bd r5638b9  
    2424@itemize
    2525@item renamed algemodstd_lib to @nref{nfmodstd_lib}
    26 @item renamed derham_lib to @nref{deRhamlib}
     26@item renamed derham_lib to @nref{deRham_lib}
    2727@item new library: graal_lib
    2828@item new library: deflation.lib
  • doc/changes_in_singular4.texi

    r2675bd r5638b9  
    102102dynamic module @code{syzextra.so}, not available in Singular 3.
    103103It implements the low-level functions for Schreyer resolutions and many auxiliary functions.
    104 The following new libraries @ref{derham_lib}, @ref{schreyer_lib} depend on it:
    105 
    106 @c table @asis
    107 @itemize @bullet
    108 @item @ref{derham_lib} - computes de Rham cohomology
     104The following new libraries @ref{deRham_lib}, @ref{schreyer_lib} depend on it:
     105
     106@c table @asis
     107@itemize @bullet
     108@item @ref{deRham_lib} - computes de Rham cohomology
    109109@item @ref{schreyer_lib} - computes Schreyer resolution via several approaches. It also serves as a high-level wrapper to the dynamic module @code{syzextra.so}
    110110@end itemize
  • libpolys/coeffs/OPAE.cc

    r2675bd r5638b9  
    4141number  nAEImPart      (number a, number b, const coeffs r); // nachgicken
    4242
    43 void    nAEWriteLong   (number &a, const coeffs r);//
    44 void    nAEWriteShort  (number &a, const coeffs r);//
     43void    nAEWriteLong   (number a, const coeffs r);//
     44void    nAEWriteShort  (number a, const coeffs r);//
    4545
    4646
     
    192192}
    193193
    194 void    nAEWriteLong   (number &a, const coeffs)
     194void    nAEWriteLong   (number a, const coeffs)
    195195{
    196196    int_poly* f=reinterpret_cast <int_poly*>(a);
     
    199199}
    200200
    201 void    nAEWriteShort  (number &a, const coeffs)
     201void    nAEWriteShort  (number a, const coeffs)
    202202{
    203203    int_poly* f=reinterpret_cast <int_poly*>(a);
  • libpolys/coeffs/OPAEQ.cc

    r2675bd r5638b9  
    4141number  nAEQImPart      (number a, number b, const coeffs r); // nachgicken
    4242
    43 void    nAEQWriteLong   (number &a, const coeffs r);//
    44 void    nAEQWriteShort  (number &a, const coeffs r);//
     43void    nAEQWriteLong   (number a, const coeffs r);//
     44void    nAEQWriteShort  (number a, const coeffs r);//
    4545
    4646
     
    187187}
    188188
    189 void    nAEQWriteLong   (number &, const coeffs)
     189void    nAEQWriteLong   (number , const coeffs)
    190190{
    191191    return;
    192192}
    193193
    194 void    nAEQWriteShort  (number &, const coeffs)
     194void    nAEQWriteShort  (number , const coeffs)
    195195{
    196196    return ;
  • libpolys/coeffs/OPAEp.cc

    r2675bd r5638b9  
    195195}
    196196
    197 void    nAEpWriteLong   (number &a, const coeffs)
     197void    nAEpWriteLong   (number a, const coeffs)
    198198{
    199199    p_poly* f=reinterpret_cast <p_poly*>(a);
     
    203203}
    204204
    205 void    nAEpWriteShort  (number &a, const coeffs)
     205void    nAEpWriteShort  (number a, const coeffs)
    206206{
    207207    p_poly* f=reinterpret_cast <p_poly*>(a);
  • libpolys/coeffs/coeffs.h

    r2675bd r5638b9  
    201201
    202202   /// print a given number (long format)
    203    void    (*cfWriteLong)(number &a, const coeffs r);
     203   void    (*cfWriteLong)(number a, const coeffs r);
    204204
    205205   /// print a given number in a shorter way, if possible
    206206   /// e.g. in K(a): a2 instead of a^2
    207    void    (*cfWriteShort)(number &a, const coeffs r);
     207   void    (*cfWriteShort)(number a, const coeffs r);
    208208
    209209   // it is legal, but not always useful to have cfRead(s, a, r)
  • libpolys/coeffs/ffields.cc

    r2675bd r5638b9  
    424424* write via StringAppend
    425425*/
    426 static void nfWriteLong (number &a, const coeffs r)
     426static void nfWriteLong (number a, const coeffs r)
    427427{
    428428#ifdef LDEBUG
     
    446446* write (shortert output) via StringAppend
    447447*/
    448 static void nfWriteShort (number &a, const coeffs r)
     448static void nfWriteShort (number a, const coeffs r)
    449449{
    450450#ifdef LDEBUG
  • libpolys/coeffs/gnumpc.cc

    r2675bd r5638b9  
    5353number   ngc_Copy(number a, coeffs r);
    5454const char * ngcRead (const char *s, number *a, const coeffs r);
    55 void     ngcWrite(number &a, const coeffs r);
     55void     ngcWrite(number a, const coeffs r);
    5656number   ngcRePart(number a, const coeffs r);
    5757number   ngcImPart(number a, const coeffs r);
     
    403403* write a floating point number
    404404*/
    405 void ngcWrite (number &a, const coeffs r)
     405void ngcWrite (number a, const coeffs r)
    406406{
    407407  assume( getCoeffType(r) == ID );
  • libpolys/coeffs/gnumpfl.cc

    r2675bd r5638b9  
    5151number   ngfCopy(number a, const coeffs r);
    5252number   ngf_Copy(number a, coeffs r);
    53 void     ngfWrite(number &a, const coeffs r);
     53void     ngfWrite(number a, const coeffs r);
    5454void     ngfCoeffWrite(const coeffs r, BOOLEAN details);
    5555
     
    398398* write a floating point number
    399399*/
    400 void ngfWrite (number &a, const coeffs r)
     400void ngfWrite (number a, const coeffs r)
    401401{
    402402  assume( getCoeffType(r) == ID );
  • libpolys/coeffs/longrat.cc

    r2675bd r5638b9  
    6969void     nlPower(number x, int exp, number *lu, const coeffs r);
    7070const char *   nlRead (const char *s, number *a, const coeffs r);
    71 void     nlWrite(number &a, const coeffs r);
     71void     nlWrite(number a, const coeffs r);
    7272
    7373number   nlGetDenom(number &n, const coeffs r);
  • libpolys/coeffs/longrat0.cc

    r2675bd r5638b9  
    115115* write a rational number
    116116*/
    117 void nlWrite (number &a, const coeffs r)
     117void nlWrite (number a, const coeffs r)
    118118{
    119119  char *s,*z;
  • libpolys/coeffs/modulop.cc

    r2675bd r5638b9  
    4343BOOLEAN npGreater     (number a, number b,const coeffs r);
    4444BOOLEAN npEqual       (number a, number b,const coeffs r);
    45 void    npWrite       (number &a, const coeffs r);
     45void    npWrite       (number a, const coeffs r);
    4646void    npCoeffWrite  (const coeffs r, BOOLEAN details);
    4747const char *  npRead  (const char *s, number *a,const coeffs r);
     
    348348}
    349349
    350 void npWrite (number &a, const coeffs r)
     350void npWrite (number a, const coeffs r)
    351351{
    352352  n_Test(a, r);
  • libpolys/coeffs/rintegers.cc

    r2675bd r5638b9  
    6060number  nrzExtGcd      (number a, number b, number *s, number *t, const coeffs r);
    6161nMapFunc nrzSetMap     (const coeffs src, const coeffs dst);
    62 void    nrzWrite       (number &a, const coeffs r);
     62void    nrzWrite       (number a, const coeffs r);
    6363const char *  nrzRead  (const char *s, number *a, const coeffs r);
    6464char *  nrzName        (number n, const coeffs r);
     
    378378#endif
    379379
    380 void nrzWrite (number &a, const coeffs)
     380void nrzWrite (number a, const coeffs)
    381381{
    382382  char *s,*z;
  • libpolys/coeffs/rintegers.h

    r2675bd r5638b9  
    2727
    2828// will be reused by rmodulon.cc
    29 void    nrzWrite       (number &a, const coeffs r);
     29void    nrzWrite       (number a, const coeffs r);
    3030
    3131#endif
  • libpolys/coeffs/rmodulo2m.cc

    r2675bd r5638b9  
    5454number  nr2mExtGcd      (number a, number b, number *s, number *t, const coeffs r);
    5555nMapFunc nr2mSetMap     (const coeffs src, const coeffs dst);
    56 void    nr2mWrite       (number &a, const coeffs r);
     56void    nr2mWrite       (number a, const coeffs r);
    5757const char *  nr2mRead  (const char *s, number *a, const coeffs r);
    5858char *  nr2mName        (number n, const coeffs r);
     
    826826#endif
    827827
    828 void nr2mWrite (number &a, const coeffs r)
     828void nr2mWrite (number a, const coeffs r)
    829829{
    830830  long i = nr2mInt(a, r);
  • libpolys/coeffs/shortfl.cc

    r2675bd r5638b9  
    4444BOOLEAN nrGreater     (number a, number b, const coeffs r);
    4545BOOLEAN nrEqual       (number a, number b, const coeffs r);
    46 void    nrWrite       (number &a, const coeffs r);
     46void    nrWrite       (number a, const coeffs r);
    4747const char *  nrRead  (const char *s, number *a, const coeffs r);
    4848
     
    280280}
    281281
    282 void nrWrite (number &a, const coeffs r)
     282void nrWrite (number a, const coeffs r)
    283283{
    284284  assume( getCoeffType(r) == ID );
  • libpolys/polys/ext_fields/algext.cc

    r2675bd r5638b9  
    9797void     naPower(number a, int exp, number *b, const coeffs cf);
    9898number   naCopy(number a, const coeffs cf);
    99 void     naWriteLong(number &a, const coeffs cf);
    100 void     naWriteShort(number &a, const coeffs cf);
     99void     naWriteLong(number a, const coeffs cf);
     100void     naWriteShort(number a, const coeffs cf);
    101101number   naGetDenom(number &a, const coeffs cf);
    102102number   naGetNumerator(number &a, const coeffs cf);
     
    582582}
    583583
    584 void naWriteLong(number &a, const coeffs cf)
     584void naWriteLong(number a, const coeffs cf)
    585585{
    586586  naTest(a);
     
    600600}
    601601
    602 void naWriteShort(number &a, const coeffs cf)
     602void naWriteShort(number a, const coeffs cf)
    603603{
    604604  naTest(a);
  • libpolys/polys/ext_fields/transext.cc

    r2675bd r5638b9  
    2121*           certain threshold (see constant in the *.h file), then the
    2222*           cancellation heuristic will call 'factory' to compute the gcd
    23 *           and cancel it out in the given number. (This definite cancel-
    24 *           lation will also be performed at the beginning of ntWrite,
    25 *           ensuring that any output is free of common factors.
     23*           and cancel it out in the given number.
    2624*           For the special case of K = Q (i.e., when computing over the
    2725*           rationals), this definite cancellation procedure will also take
     
    113111void     ntPower(number a, int exp, number *b, const coeffs cf);
    114112number   ntCopy(number a, const coeffs cf);
    115 void     ntWriteLong(number &a, const coeffs cf);
    116 void     ntWriteShort(number &a, const coeffs cf);
     113void     ntWriteLong(number a, const coeffs cf);
     114void     ntWriteShort(number a, const coeffs cf);
    117115number   ntRePart(number a, const coeffs cf);
    118116number   ntImPart(number a, const coeffs cf);
     
    13911389}
    13921390
    1393 // NOTE: modifies a
    1394 void ntWriteLong(number &a, const coeffs cf)
    1395 {
    1396   ntTest(a);
    1397   definiteGcdCancellation(a, cf, FALSE);
     1391void ntWriteLong(number a, const coeffs cf)
     1392{
     1393  ntTest(a);
    13981394  if (IS0(a))
    13991395    StringAppendS("0");
     
    14181414}
    14191415
    1420 // NOTE: modifies a
    1421 void ntWriteShort(number &a, const coeffs cf)
    1422 {
    1423   ntTest(a);
    1424   definiteGcdCancellation(a, cf, FALSE);
     1416void ntWriteShort(number a, const coeffs cf)
     1417{
     1418  ntTest(a);
    14251419  if (IS0(a))
    14261420    StringAppendS("0");
  • libpolys/polys/matpol.cc

    r2675bd r5638b9  
    4848matrix mpNew(int r, int c)
    4949{
    50   if (r<=0) r=1;
    51   if ( (((int)(MAX_INT_VAL/sizeof(poly))) / r) <= c)
     50  int rr=r;
     51  if (rr<=0) rr=1;
     52  if ( (((int)(MAX_INT_VAL/sizeof(poly))) / rr) <= c)
    5253  {
    5354    Werror("internal error: creating matrix[%d][%d]",r,c);
     
    5859  rc->ncols = c;
    5960  rc->rank = r;
    60   if (c != 0)
     61  if ((c != 0)&&(r!=0))
    6162  {
    6263    int s=r*c*sizeof(poly);
  • libpolys/polys/monomials/ring.cc

    r2675bd r5638b9  
    42224222      Print("%ld ",p->exp[i]);
    42234223    PrintLn();
    4224     Print("v0:%d ",p_GetComp(p, r));
     4224    Print("v0:%ld ",p_GetComp(p, r));
    42254225    for(i=1;i<=r->N;i++) Print(" v%d:%ld",i,p_GetExp(p,i, r));
    42264226    PrintLn();
  • libpolys/polys/polys0.cc

    r2675bd r5638b9  
    143143    return;
    144144  }
     145  p_Normalize(p,lmRing);
    145146  if ((p_GetComp(p, lmRing) == 0) || (!lmRing->VectorOut))
    146147  {
  • libpolys/polys/templates/p_Add_q__T.cc

    r2675bd r5638b9  
    4343  n2 = pGetCoeff(q);
    4444  #if 0
    45   t = n_Add__T(n1,n2, r);
    46   n_Delete__T(&n1, r);
     45  t = n_Add__T(n1,n2, r->cf);
     46  n_Delete__T(&n1, r->cf);
    4747  #else
    48   n_InpAdd__T(n1,n2,r);
     48  n_InpAdd__T(n1,n2,r->cf);
    4949  t = n1;
    5050  #endif
    51   n_Delete__T(&n2, r);
     51  n_Delete__T(&n2, r->cf);
    5252  q = p_LmFreeAndNext(q, r);
    5353
    54   if (n_IsZero__T(t, r))
     54  if (n_IsZero__T(t, r->cf))
    5555  {
    5656    shorter += 2;
    57     n_Delete__T(&t, r);
     57    n_Delete__T(&t, r->cf);
    5858    p = p_LmFreeAndNext(p, r);
    5959  }
  • libpolys/polys/templates/p_Copy__T.cc

    r2675bd r5638b9  
    2424    p_AllocBin(pNext(d_p), bin, r);
    2525    pIter(d_p);
    26     pSetCoeff0(d_p, n_Copy__T(pGetCoeff(s_p), r));
     26    pSetCoeff0(d_p, n_Copy__T(pGetCoeff(s_p), r->cf));
    2727    // it is better to iter here,
    2828    // for MemCopy advances goes from low to high addresses
  • libpolys/polys/templates/p_Delete__T.cc

    r2675bd r5638b9  
    1515  while (p != NULL)
    1616  {
    17     n_Delete__T(&(p->coef), r);
     17    n_Delete__T(&(p->coef), r->cf);
    1818    p = p_LmFreeAndNext(p, r);
    1919  }
  • libpolys/polys/templates/p_Minus_mm_Mult_qq__T.cc

    r2675bd r5638b9  
    3737
    3838  number tm = pGetCoeff(m),           // coefficient of m
    39     tneg = n_Neg__T(n_Copy__T(tm, r), r),    // - (coefficient of m)
     39    tneg = n_Neg__T(n_Copy__T(tm, r->cf), r->cf),    // - (coefficient of m)
    4040    tb,                            // used for tm*coeff(a1)
    4141    tc;                            // used as intermediate number
     
    6464
    6565  Equal:   // qm equals p
    66   tb = n_Mult__T(pGetCoeff(q), tm, r);
     66  tb = n_Mult__T(pGetCoeff(q), tm, r->cf);
    6767#ifdef HAVE_ZERODIVISORS
    68   if (!n_IsZero__T(tb,r)) {
     68  if (!n_IsZero__T(tb,r->cf)) {
    6969#endif
    7070  tc = pGetCoeff(p);
    71   if (!n_Equal__T(tc, tb, r))
     71  if (!n_Equal__T(tc, tb, r->cf))
    7272  {
    7373    shorter++;
    74     tc = n_Sub__T(tc, tb, r);
    75     n_Delete__T(&(pGetCoeff(p)), r);
     74    tc = n_Sub__T(tc, tb, r->cf);
     75    n_Delete__T(&(pGetCoeff(p)), r->cf);
    7676    pSetCoeff0(p,tc); // adjust coeff of p
    7777    a = pNext(a) = p; // append p to result and advance p
     
    8181  { // coeffs are equal, so their difference is 0:
    8282    shorter += 2;
    83     n_Delete__T(&tc, r);
     83    n_Delete__T(&tc, r->cf);
    8484    p = p_LmFreeAndNext(p, r);
    8585  }
     
    9191  }
    9292#endif
    93   n_Delete__T(&tb, r);
     93  n_Delete__T(&tb, r->cf);
    9494  pIter(q);
    9595  if (q == NULL || p == NULL) goto Finish; // are we done ?
     
    100100  Greater:
    101101#ifdef HAVE_ZERODIVISORS
    102   tb = n_Mult__T(pGetCoeff(q), tneg, r);
    103   if (!n_IsZero__T(tb,r))
     102  tb = n_Mult__T(pGetCoeff(q), tneg, r->cf);
     103  if (!n_IsZero__T(tb,r->cf))
    104104  {
    105105#endif
    106     pSetCoeff0(qm, n_Mult__T(pGetCoeff(q), tneg, r));
     106    pSetCoeff0(qm, n_Mult__T(pGetCoeff(q), tneg, r->cf));
    107107    a = pNext(a) = qm;       // append qm to result and advance q
    108108#ifdef HAVE_ZERODIVISORS
     
    112112    shorter++;
    113113  }
    114   n_Delete__T(&tb, r);
     114  n_Delete__T(&tb, r->cf);
    115115#endif
    116116  pIter(q);
     
    157157  }
    158158
    159   n_Delete__T(&tneg, r);
     159  n_Delete__T(&tneg, r->cf);
    160160  if (qm != NULL) p_FreeBinAddr(qm, r);
    161161  Shorter = shorter;
  • libpolys/polys/templates/p_Mult_mm__T.cc

    r2675bd r5638b9  
    2727  DECLARE_LENGTH(const unsigned long length = ri->ExpL_Size);
    2828  const unsigned long* m_e = m->exp;
    29   pAssume(!n_IsZero__T(ln,ri));
     29  pAssume(!n_IsZero__T(ln,ri->cf));
    3030
    3131#ifdef HAVE_ZERODIVISORS
     
    3535  {
    3636    pn = pGetCoeff(p);
    37     number tmp = n_Mult__T(ln, pn, ri);
     37    number tmp = n_Mult__T(ln, pn, ri->cf);
    3838#ifdef HAVE_ZERODIVISORS
    39     if (n_IsZero__T(tmp, ri))
     39    if (n_IsZero__T(tmp, ri->cf))
    4040    {
    41       n_Delete__T(&tmp, ri);
     41      n_Delete__T(&tmp, ri->cf);
    4242      if (before == p)
    4343      {
     
    5656    {
    5757      pSetCoeff0(p, tmp);
    58       n_Delete__T(&pn, ri);
     58      n_Delete__T(&pn, ri->cf);
    5959      p_MemAdd__T(p->exp, m_e, length);
    6060      p_MemAddAdjust__T(p, ri);
  • libpolys/polys/templates/p_Mult_nn__T.cc

    r2675bd r5638b9  
    1818LINKAGE poly p_Mult_nn__T(poly p, const number n, const ring r)
    1919{
    20   pAssume(!n_IsZero__T(n,r));
     20  pAssume(!n_IsZero__T(n,r->cf));
    2121  p_Test(p, r);
    2222
     
    2828  {
    2929#ifndef HAVE_ZERODIVISORS
    30     n_InpMult__T(pGetCoeff(p), n, r);
     30    n_InpMult__T(pGetCoeff(p), n, r->cf);
    3131    pIter(p);
    3232#else
    33     number tmp = n_Mult__T(n, pGetCoeff(p), r);
    34     if (!n_IsZero__T(tmp,r))
     33    number tmp = n_Mult__T(n, pGetCoeff(p), r->cf);
     34    if (!n_IsZero__T(tmp,r->cf))
    3535    {
    3636       number nc = pGetCoeff(p);
    3737       p_SetCoeff0(p, tmp, r);
    38        n_Delete__T(&nc, r);
     38       n_Delete__T(&nc, r->cf);
    3939       old = p;
    4040       pIter(p);
     
    4242    else
    4343    {
    44       n_Delete__T(&tmp, r);
     44      n_Delete__T(&tmp, r->cf);
    4545      if (old == NULL)
    4646      {
  • libpolys/polys/templates/p_Neg__T.cc

    r2675bd r5638b9  
    2020  while (p != NULL)
    2121  {
    22     pSetCoeff0(p, n_Neg__T(pGetCoeff(p), r));
     22    pSetCoeff0(p, n_Neg__T(pGetCoeff(p), r->cf));
    2323    pIter(p);
    2424  }
  • libpolys/polys/templates/p_Numbers.h

    r2675bd r5638b9  
    1616#include <polys/monomials/ring.h>
    1717
    18 static FORCE_INLINE number n_Copy_FieldGeneral(number n,    const ring r)
    19 { return n_Copy(n,r->cf); }
     18static FORCE_INLINE number n_Copy_FieldGeneral(number n,  const coeffs r)
     19{ return n_Copy(n,r); }
    2020
    21 static FORCE_INLINE void   n_Delete_FieldGeneral(number* p, const ring r)
    22 { n_Delete(p,r->cf); }
     21static FORCE_INLINE void   n_Delete_FieldGeneral(number* p, const coeffs r)
     22{ n_Delete(p,r); }
    2323
    24 static FORCE_INLINE number n_Mult_FieldGeneral(number n1, number n2, const ring r)
    25 { return n_Mult(n1, n2, r->cf); }
     24static FORCE_INLINE number n_Mult_FieldGeneral(number n1, number n2, const coeffs r)
     25{ return n_Mult(n1, n2, r); }
    2626
    27 static FORCE_INLINE number n_Add_FieldGeneral(number n1, number n2, const ring r)
    28 { return n_Add(n1, n2, r->cf); }
     27static FORCE_INLINE number n_Add_FieldGeneral(number n1, number n2, const coeffs r)
     28{ return n_Add(n1, n2, r); }
    2929
    30 static FORCE_INLINE BOOLEAN n_IsZero_FieldGeneral(number n, const ring r)
    31 { return n_IsZero(n, r->cf); }
     30static FORCE_INLINE BOOLEAN n_IsZero_FieldGeneral(number n, const coeffs r)
     31{ return n_IsZero(n, r); }
    3232
    33 static FORCE_INLINE BOOLEAN n_Equal_FieldGeneral(number n1, number n2, const ring r)
    34 { return n_Equal(n1, n2, r->cf); }
     33static FORCE_INLINE BOOLEAN n_Equal_FieldGeneral(number n1, number n2, const coeffs r)
     34{ return n_Equal(n1, n2, r); }
    3535
    36 static FORCE_INLINE number n_Neg_FieldGeneral(number n,     const ring r)
    37 { return n_InpNeg(n, r->cf); }
     36static FORCE_INLINE number n_Neg_FieldGeneral(number n, const coeffs r)
     37{ return n_InpNeg(n, r); }
    3838
    39 static FORCE_INLINE number n_Sub_FieldGeneral(number n1, number n2, const ring r)
    40 { return n_Sub(n1, n2, r->cf); }
     39static FORCE_INLINE number n_Sub_FieldGeneral(number n1, number n2, const coeffs r)
     40{ return n_Sub(n1, n2, r); }
    4141
    42 static FORCE_INLINE void n_InpMult_FieldGeneral(number &n1, number n2, const ring r)
    43 { n_InpMult(n1, n2, r->cf); }
     42static FORCE_INLINE void n_InpMult_FieldGeneral(number &n1, number n2, const coeffs r)
     43{ n_InpMult(n1, n2, r); }
    4444
    45 static FORCE_INLINE void n_InpAdd_FieldGeneral(number &n1, number n2, const ring r)
    46 { n_InpAdd(n1, n2, r->cf); }
     45static FORCE_INLINE void n_InpAdd_FieldGeneral(number &n1, number n2, const coeffs r)
     46{ n_InpAdd(n1, n2, r); }
    4747
    4848#ifdef HAVE_RINGS
     
    5858#define n_InpMult_RingGeneral(n1, n2, r)   n_InpMult_FieldGeneral(n1, n2, r)
    5959
    60 static FORCE_INLINE void n_InpAdd_RingGeneral(number &n1, number n2, const ring r)
    61 {  assume(rField_is_Ring(r)); n_InpAdd(n1, n2, r->cf); }
     60static FORCE_INLINE void n_InpAdd_RingGeneral(number &n1, number n2, const coeffs r)
     61{  assume(nCoeff_is_Ring(r)); n_InpAdd(n1, n2, r); }
    6262#endif
    6363
     
    6767#define n_Delete_FieldZp(n, r)      do {} while (0)
    6868
    69 static FORCE_INLINE number n_Mult_FieldZp(number n1, number n2, const ring r)
    70 { STATISTIC(n_Mult); return npMultM(n1, n2, r->cf); }
     69static FORCE_INLINE number n_Mult_FieldZp(number n1, number n2, const coeffs r)
     70{ STATISTIC(n_Mult); return npMultM(n1, n2, r); }
    7171
    7272#ifdef HAVE_NUMSTATS
    73 static FORCE_INLINE number n_Add_FieldZp(number n1, number n2, const ring r)
    74 { STATISTIC(n_Add); const number sum = npAddM(n1, n2, r->cf);
     73static FORCE_INLINE number n_Add_FieldZp(number n1, number n2, const coeffs r)
     74{ STATISTIC(n_Add); const number sum = npAddM(n1, n2, r);
    7575  // avoid double counting
    76   if( npIsZeroM(sum,r->cf) ) STATISTIC(n_CancelOut);
    77  return sum;
     76  if( npIsZeroM(sum,r) ) STATISTIC(n_CancelOut);
     77  return sum;
    7878}
    7979#else
    80 static FORCE_INLINE number n_Add_FieldZp(number n1, number n2, const ring r)
    81 { return npAddM(n1, n2, r->cf); }
     80static FORCE_INLINE number n_Add_FieldZp(number n1, number n2, const coeffs r)
     81{ return npAddM(n1, n2, r); }
    8282#endif
    8383
    8484#ifdef HAVE_NUMSTATS
    85 static FORCE_INLINE number n_Sub_FieldZp(number n1, number n2, const ring r)
    86 { STATISTIC(n_Sub); const number d = npSubM(n1, n2, r->cf);
     85static FORCE_INLINE number n_Sub_FieldZp(number n1, number n2, const coeffs r)
     86{ STATISTIC(n_Sub); const number d = npSubM(n1, n2, r);
    8787  // avoid double counting
    88   if( npIsZeroM(d,r->cf) ) STATISTIC(n_CancelOut);
     88  if( npIsZeroM(d,r) ) STATISTIC(n_CancelOut);
    8989  return d;
    9090}
    9191#else
    92 static FORCE_INLINE number n_Sub_FieldZp(number n1, number n2, const ring r)
    93 { return npSubM(n1, n2, r->cf); }
     92static FORCE_INLINE number n_Sub_FieldZp(number n1, number n2, const coeffs r)
     93{ return npSubM(n1, n2, r); }
    9494#endif
    9595
    96 static FORCE_INLINE BOOLEAN n_IsZero_FieldZp(number n, const ring r)
    97 { STATISTIC(n_IsZero); return npIsZeroM(n, r->cf); }
     96static FORCE_INLINE BOOLEAN n_IsZero_FieldZp(number n, const coeffs r)
     97{ STATISTIC(n_IsZero); return npIsZeroM(n, r); }
    9898
    99 static FORCE_INLINE BOOLEAN n_Equal_FieldZp(number n1, number n2, const ring r)
    100 { STATISTIC(n_Equal); return  npEqualM(n1, n2, r->cf); }
     99static FORCE_INLINE BOOLEAN n_Equal_FieldZp(number n1, number n2, const coeffs r)
     100{ STATISTIC(n_Equal); return  npEqualM(n1, n2, r); }
    101101
    102 static FORCE_INLINE number n_Neg_FieldZp(number n,     const ring r)
    103 { STATISTIC(n_InpNeg); return npNegM(n, r->cf); }
     102static FORCE_INLINE number n_Neg_FieldZp(number n, const coeffs r)
     103{ STATISTIC(n_InpNeg); return npNegM(n, r); }
    104104
    105 static FORCE_INLINE void n_InpMult_FieldZp(number &n1, number n2, const ring r)
    106 { STATISTIC(n_InpMult); n1=npMultM(n1, n2, r->cf);  }
     105static FORCE_INLINE void n_InpMult_FieldZp(number &n1, number n2, const coeffs r)
     106{ STATISTIC(n_InpMult); n1=npMultM(n1, n2, r);  }
    107107
    108108#ifdef HAVE_NUMSTATS
    109 static FORCE_INLINE void n_InpAdd_FieldZp(number &n1, number n2, const ring r)
     109static FORCE_INLINE void n_InpAdd_FieldZp(number &n1, number n2, const coeffs r)
    110110{
    111   STATISTIC(n_InpAdd); n1=npAddM(n1, n2, r->cf);
     111  STATISTIC(n_InpAdd); n1=npAddM(n1, n2, r);
    112112  // avoid double counting
    113   if( npIsZeroM(n1,r->cf) ) STATISTIC(n_CancelOut);
     113  if( npIsZeroM(n1,r) ) STATISTIC(n_CancelOut);
    114114}
    115115#else
    116 static FORCE_INLINE void n_InpAdd_FieldZp(number &n1, number n2, const ring r)
    117 { n1=npAddM(n1, n2, r->cf); }
     116static FORCE_INLINE void n_InpAdd_FieldZp(number &n1, number n2, const coeffs r)
     117{ n1=npAddM(n1, n2, r); }
    118118#endif
    119119
     
    121121#include <coeffs/longrat.cc> // for inlining... TODO: fix this Uglyness?!!!
    122122
    123 static FORCE_INLINE number n_Copy_FieldQ(number n,    const ring r)
    124 { STATISTIC(n_Copy); return nlCopy(n, r->cf); }
     123static FORCE_INLINE number n_Copy_FieldQ(number n, const coeffs r)
     124{ STATISTIC(n_Copy); return nlCopy(n, r); }
    125125
    126 static FORCE_INLINE void   n_Delete_FieldQ(number* n, const ring r)
    127 { STATISTIC(n_Delete); nlDelete(n,r->cf); }
     126static FORCE_INLINE void   n_Delete_FieldQ(number* n, const coeffs r)
     127{ STATISTIC(n_Delete); nlDelete(n,r); }
    128128
    129 static FORCE_INLINE number n_Mult_FieldQ(number n1, number n2, const ring r)
    130 { STATISTIC(n_Mult); return nlMult(n1,n2, r->cf); }
     129static FORCE_INLINE number n_Mult_FieldQ(number n1, number n2, const coeffs r)
     130{ STATISTIC(n_Mult); return nlMult(n1,n2, r); }
    131131
    132132#ifdef HAVE_NUMSTATS
    133 static FORCE_INLINE number n_Add_FieldQ(number n1, number n2, const ring r)
    134 { STATISTIC(n_Add); const number sum = nlAdd(n1, n2, r->cf);
     133static FORCE_INLINE number n_Add_FieldQ(number n1, number n2, const coeffs r)
     134{ STATISTIC(n_Add); const number sum = nlAdd(n1, n2, r);
    135135  // avoid double counting
    136   if( nlIsZero(sum,r->cf) ) STATISTIC(n_CancelOut);
    137  return sum;
     136  if( nlIsZero(sum,r) ) STATISTIC(n_CancelOut);
     137  return sum;
    138138}
    139139#else
    140 static FORCE_INLINE number n_Add_FieldQ(number n1, number n2, const ring r)
    141 { return nlAdd(n1, n2, r->cf); }
     140static FORCE_INLINE number n_Add_FieldQ(number n1, number n2, const coeffs r)
     141{ return nlAdd(n1, n2, r); }
    142142#endif
    143143
    144144#ifdef HAVE_NUMSTATS
    145 static FORCE_INLINE number n_Sub_FieldQ(number n1, number n2, const ring r)
    146 { STATISTIC(n_Sub); const number d = nlSub(n1, n2, r->cf);
     145static FORCE_INLINE number n_Sub_FieldQ(number n1, number n2, const coeffs r)
     146{ STATISTIC(n_Sub); const number d = nlSub(n1, n2, r);
    147147  // avoid double counting
    148   if( nlIsZero(d,r->cf) ) STATISTIC(n_CancelOut);
     148  if( nlIsZero(d,r) ) STATISTIC(n_CancelOut);
    149149  return d;
    150150}
    151151#else
    152 static FORCE_INLINE number n_Sub_FieldQ(number n1, number n2, const ring r)
    153 { return nlSub(n1, n2, r->cf); }
     152static FORCE_INLINE number n_Sub_FieldQ(number n1, number n2, const coeffs r)
     153{ return nlSub(n1, n2, r); }
    154154#endif
    155155
    156 static FORCE_INLINE BOOLEAN n_IsZero_FieldQ(number n, const ring r)
    157 { STATISTIC(n_IsZero); return nlIsZero(n, r->cf); }
     156static FORCE_INLINE BOOLEAN n_IsZero_FieldQ(number n, const coeffs r)
     157{ STATISTIC(n_IsZero); return nlIsZero(n, r); }
    158158
    159 static FORCE_INLINE BOOLEAN n_Equal_FieldQ(number n1, number n2, const ring r)
    160 { STATISTIC(n_Equal); return  nlEqual(n1, n2, r->cf); }
     159static FORCE_INLINE BOOLEAN n_Equal_FieldQ(number n1, number n2, const coeffs r)
     160{ STATISTIC(n_Equal); return  nlEqual(n1, n2, r); }
    161161
    162 static FORCE_INLINE number n_Neg_FieldQ(number n,     const ring r)
    163 { STATISTIC(n_InpNeg); return nlNeg(n, r->cf); }
     162static FORCE_INLINE number n_Neg_FieldQ(number n, const coeffs r)
     163{ STATISTIC(n_InpNeg); return nlNeg(n, r); }
    164164
    165 static FORCE_INLINE void n_InpMult_FieldQ(number &n1, number n2, const ring r)
    166 { STATISTIC(n_InpMult); nlInpMult(n1, n2, r->cf); }
     165static FORCE_INLINE void n_InpMult_FieldQ(number &n1, number n2, const coeffs r)
     166{ STATISTIC(n_InpMult); nlInpMult(n1, n2, r); }
    167167
    168168#ifdef HAVE_NUMSTATS
    169 static FORCE_INLINE void n_InpAdd_FieldQ(number &n1, number n2, const ring r)
    170 { STATISTIC(n_InpAdd); assume(rField_is_Q(r)); nlInpAdd(n1, n2, r->cf);
    171 
     169static FORCE_INLINE void n_InpAdd_FieldQ(number &n1, number n2, const coeffs r)
     170{ STATISTIC(n_InpAdd); assume(nCoeff_is_Q(r)); nlInpAdd(n1, n2, r);
    172171  // avoid double counting
    173   if( nlIsZero(n1,r->cf) ) STATISTIC(n_CancelOut);
     172  if( nlIsZero(n1,r) ) STATISTIC(n_CancelOut);
    174173}
    175174#else
    176 static FORCE_INLINE void n_InpAdd_FieldQ(number &n1, number n2, const ring r)
    177 { nlInpAdd(n1, n2, r->cf); }
     175static FORCE_INLINE void n_InpAdd_FieldQ(number &n1, number n2, const coeffs r)
     176{ nlInpAdd(n1, n2, r); }
    178177#endif
    179178
  • libpolys/polys/templates/p_kBucketSetLm__T.cc

    r2675bd r5638b9  
    5555        Greater:
    5656        {
    57           if (n_IsZero__T(pGetCoeff(p), r))
     57          if (n_IsZero__T(pGetCoeff(p), r->cf))
    5858          {
    59             n_Delete__T(&pGetCoeff(p), r);
     59            n_Delete__T(&pGetCoeff(p), r->cf);
    6060            pIter(bucket->buckets[j]);
    6161            p_FreeBinAddr(p, r);
     
    7171          number tn = pGetCoeff(p);
    7272          #if 0
    73           pSetCoeff0(p, n_Add__T(pGetCoeff(bucket->buckets[i]), tn, r));
    74           n_Delete__T(&tn, r);
     73          pSetCoeff0(p, n_Add__T(pGetCoeff(bucket->buckets[i]), tn, r->cf));
     74          n_Delete__T(&tn, r->cf);
    7575          #else
    76           n_InpAdd__T(tn,pGetCoeff(bucket->buckets[i]), r);
     76          n_InpAdd__T(tn,pGetCoeff(bucket->buckets[i]), r->cf);
    7777          pSetCoeff0(p, tn);
    7878          #endif
    7979          p = bucket->buckets[i];
    8080          pIter(bucket->buckets[i]);
    81           n_Delete__T(&pGetCoeff(p), r);
     81          n_Delete__T(&pGetCoeff(p), r->cf);
    8282          p_FreeBinAddr(p, r);
    8383          (bucket->buckets_length[i])--;
     
    8888    }
    8989    p = bucket->buckets[j];
    90     if (j > 0 && n_IsZero__T(pGetCoeff(p), r))
     90    if (j > 0 && n_IsZero__T(pGetCoeff(p), r->cf))
    9191    {
    92       n_Delete__T(&pGetCoeff(p), r);
     92      n_Delete__T(&pGetCoeff(p), r->cf);
    9393      pIter(bucket->buckets[j]);
    9494      p_FreeBinAddr(p, r);
  • libpolys/polys/templates/pp_Mult_Coeff_mm_DivSelectMult__T.cc

    r2675bd r5638b9  
    2525  number n = pGetCoeff(m);
    2626  number nc;
    27   pAssume(!n_IsZero__T(n,r));
     27  pAssume(!n_IsZero__T(n,r->cf));
    2828
    2929  spolyrec rp;
     
    5959    q = pNext(q);
    6060    nc = pGetCoeff(p);
    61     pSetCoeff0(q, n_Mult__T(n, nc, r));
     61    pSetCoeff0(q, n_Mult__T(n, nc, r->cf));
    6262    p_MemSum__T(q->exp, p->exp, ab_e, length);
    6363
  • libpolys/polys/templates/pp_Mult_Coeff_mm_DivSelect__T.cc

    r2675bd r5638b9  
    2020{
    2121  number n = pGetCoeff(m);
    22   pAssume(!n_IsZero__T(n,r));
     22  pAssume(!n_IsZero__T(n,r->cf));
    2323  p_Test(p, r);
    2424  if (p == NULL) return NULL;
     
    3636      q = pNext(q);
    3737      number nc = pGetCoeff(p);
    38       pSetCoeff0(q, n_Mult__T(n, nc, r));
     38      pSetCoeff0(q, n_Mult__T(n, nc, r->cf));
    3939      p_MemCopy__T(q->exp, p->exp, length);
    4040    }
  • libpolys/polys/templates/pp_Mult_mm_Noether__T.cc

    r2675bd r5638b9  
    3636  DECLARE_ORDSGN(const long* ordsgn = ri->ordsgn);
    3737  const unsigned long* m_e = m->exp;
    38   pAssume(!n_IsZero__T(ln,ri));
     38  pAssume(!n_IsZero__T(ln,ri->cf));
    3939  pAssume1(p_GetComp(m, ri) == 0 || p_MaxComp(p, ri) == 0);
    4040  int l = 0;
     
    5454    Continue:
    5555
    56     n = n_Mult__T(ln, pGetCoeff(p), ri);
     56    n = n_Mult__T(ln, pGetCoeff(p), ri->cf);
    5757
    5858    #ifdef HAVE_RINGS
    59     if(n_IsZero__T(n, ri))
     59    if(n_IsZero__T(n, ri->cf))
    6060    {
    61       n_Delete__T(&n, ri);
     61      n_Delete__T(&n, ri->cf);
    6262      p_FreeBinAddr(r, ri);
    6363    } else
  • libpolys/polys/templates/pp_Mult_mm__T.cc

    r2675bd r5638b9  
    3232  DECLARE_LENGTH(const unsigned long length = ri->ExpL_Size);
    3333  const unsigned long* m_e = m->exp;
    34   pAssume(!n_IsZero__T(ln,ri));
     34  pAssume(!n_IsZero__T(ln,ri->cf));
    3535  pAssume1(p_GetComp(m, ri) == 0 || p_MaxComp(p, ri) == 0);
    3636  number tmp;
     
    3838  do
    3939  {
    40     tmp = n_Mult__T(ln, pGetCoeff(p), ri);
     40    tmp = n_Mult__T(ln, pGetCoeff(p), ri->cf);
    4141#ifdef HAVE_ZERODIVISORS
    42     if (! n_IsZero__T(tmp, ri))
     42    if (! n_IsZero__T(tmp, ri->cf))
    4343    {
    4444#endif
     
    5050#ifdef HAVE_ZERODIVISORS
    5151    }
    52     else n_Delete__T(&tmp, ri);
     52    else n_Delete__T(&tmp, ri->cf);
    5353#endif
    5454    p = pNext(p);
  • libpolys/polys/templates/pp_Mult_nn__T.cc

    r2675bd r5638b9  
    1717LINKAGE poly pp_Mult_nn__T(poly p, const number n, const ring r)
    1818{
    19   pAssume(!n_IsZero__T(n,r));
     19  pAssume(!n_IsZero__T(n,r->cf));
    2020  p_Test(p, r);
    2121  if (p == NULL) return NULL;
     
    3434    pIter(q);
    3535    number nc = pGetCoeff(p);
    36     pSetCoeff0(q, n_Mult__T(n, nc, r));
     36    pSetCoeff0(q, n_Mult__T(n, nc, r->cf));
    3737    p_MemCopy__T(q->exp, p->exp, length);
    3838#else
    3939    number nc = pGetCoeff(p);
    40     number tmp = n_Mult__T(n, nc, r);
    41     if (! n_IsZero__T(tmp,r))
     40    number tmp = n_Mult__T(n, nc, r->cf);
     41    if (! n_IsZero__T(tmp,r->cf))
    4242    {
    4343      p_AllocBin(pNext(q), bin, r);
     
    4747    }
    4848    else
    49       n_Delete__T(&tmp,r);
     49      n_Delete__T(&tmp,r->cf);
    5050#endif
    5151    pIter(p);
Note: See TracChangeset for help on using the changeset viewer.