code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/standard_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/standard_lib.doc INSTEAD
@c library version: (1.58.2.9,2003/06/16)
@c library file: ../Singular/LIB/standard.lib
@cindex standard.lib
@cindex standard_lib
@table @asis
@item @strong{Library:}
standard.lib
@item @strong{Purpose:}
   Procedures which are always loaded at Start-up

@end table

@strong{Procedures:}
@menu
* stdfglm:: standard basis of ideal via fglm [and ordering ord]
* stdhilb:: standard basis of ideal using the Hilbert function
* groebner:: standard basis using a heuristically chosen method
* quot:: quotient using heuristically chosen method
* res:: free resolution of ideal or module
* sprintf:: returns formatted string
* fprintf:: writes formatted string to link
* printf:: displays formatted string
@end menu
@c ---end content LibInfo---

@c ------------------- stdfglm -------------
@node stdfglm, stdhilb,, standard_lib
@subsubsection stdfglm
@cindex stdfglm
@c ---content stdfglm---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{stdfglm (} ideal_expression @code{)} @*
@code{stdfglm (} ideal_expression@code{,} string_expression @code{)}

@item @strong{Type:}
ideal

@item @strong{Purpose:}
computes the standard basis of the ideal in the basering
via @code{fglm} (from the ordering given as the second argument
to the ordering of the basering).@*
If no second argument is given, "dp" is used.

@cindex fglm
@end table
@strong{Example:}
@smallexample
@c reused example stdfglm d2t_singular/standard_lib.doc:52
   ring r=0,(x,y,z),lp;
ideal i=y3+x2,x2y+x2,x3-x2,z4-x2-y;
ideal i1=stdfglm(i);         //uses fglm from "dp" to "lp"
i1;
@expansion{} i1[1]=z12
@expansion{} i1[2]=yz4-z8
@expansion{} i1[3]=y2+y-z8-z4
@expansion{} i1[4]=xy-xz4-y+z4
@expansion{} i1[5]=x2+y-z4
ideal i2=stdfglm(i,"Dp");    //uses fglm from "Dp" to "lp"
i2;
@expansion{} i2[1]=z12
@expansion{} i2[2]=yz4-z8
@expansion{} i2[3]=y2+y-z8-z4
@expansion{} i2[4]=xy-xz4-y+z4
@expansion{} i2[5]=x2+y-z4
@c end example stdfglm d2t_singular/standard_lib.doc:52
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:61
@ifinfo
@menu
See also:
* fglm::
* groebner::
* std::
* stdhilb::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{fglm};
@ref{groebner};
@ref{std};
@ref{stdhilb}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:61

@c ---end content stdfglm---

@c ------------------- stdhilb -------------
@node stdhilb, groebner, stdfglm, standard_lib
@subsubsection stdhilb
@cindex stdhilb
@c ---content stdhilb---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{stdhilb (} ideal_expression @code{)} @*
@code{stdhilb (} ideal_expression@code{,} intvec_expression @code{)}

@item @strong{Type:}
ideal

@item @strong{Purpose:}
computes the standard basis of the homogeneous ideal in the basering,
via a Hilbert driven standard basis computation.@*
An optional second argument will be used as 1st Hilbert function.

@item @strong{Assume:}
The optional second argument is the first Hilbert series as computed
by @code{hilb}.

@cindex Hilbert function
@end table
@strong{Example:}
@smallexample
@c reused example stdhilb d2t_singular/standard_lib.doc:95
   ring  r=0,(x,y,z),dp;
ideal i=y3+x2,x2y+x2,x3-x2,z4-x2-y;
ideal i1=stdhilb(i); i1;
@expansion{} i1[1]=y3+x2
@expansion{} i1[2]=x2y+x2
@expansion{} i1[3]=x3-x2
@expansion{} i1[4]=z4-x2-y
// the latter computation is equivalent to:
intvec v=hilb(i,1);
@expansion{} // ** i is no standardbasis
ideal i2=stdhilb(i,v); i2;
@expansion{} i2[1]=y3+x2
@expansion{} i2[2]=x2y+x2
@expansion{} i2[3]=x3-x2
@expansion{} i2[4]=z4-x2-y
@c end example stdhilb d2t_singular/standard_lib.doc:95
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:104
@ifinfo
@menu
See also:
* groebner::
* std::
* stdfglm::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{groebner};
@ref{std};
@ref{stdfglm}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:104

@c ---end content stdhilb---

@c ------------------- groebner -------------
@node groebner, quot, stdhilb, standard_lib
@subsubsection groebner
@cindex groebner
@c ---content groebner---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{groebner (} ideal_expression @code{)} @*
@code{groebner (} module_expression @code{)} @*
@code{groebner (} ideal_expression@code{,} int_expression @code{)} @*
@code{groebner (} module_expression@code{,} int_expression @code{)}

@item @strong{Type:}
type of the first argument

@item @strong{Purpose:}
computes the standard basis of the first argument @code{I}
(ideal or module), by a heuristically chosen method: if the
ordering of the current ring is a local ordering, or if it is a
non-block ordering and the current ring has no parameters, then
@code{std(I)} is returned. Otherwise, @code{I} is mapped into a
ring with no parameters and ordering dp, where its Hilbert series
is computed. This is followed by a Hilbert-series based std
computation in the original ring.

@item @strong{Note:}
If a 2nd argument @code{wait} is given, then the computation proceeds
at most @code{wait} seconds. That is, if no result could be computed in
@code{wait} seconds, then the computation is interrupted, 0 is returned,
a warning message is displayed, and the global variable
@code{groebner_error} is defined.

@cindex time limit on computations
@cindex MP, groebner basis computations
@end table
@strong{Example:}
@smallexample
@c reused example groebner d2t_singular/standard_lib.doc:149
  ring r=0,(a,b,c,d),lp;
option(prot);
ideal i=a+b+c+d,ab+ad+bc+cd,abc+abd+acd+bcd,abcd-1; // cyclic 4
groebner(i);
@expansion{} std in (0),(a,b,c,d,@@t),(dp,C)
@expansion{} [63:1]1(3)s2(2)s3s4-s5ss6-s7--
@expansion{} product criterion:8 chain criterion:5
@expansion{} std with hilb in  (0),(a,b,c,d,@@t),(lp(4),C)
@expansion{} [63:1]1(3)s2(2)s3s4-s5ss6shhhh8shh
@expansion{} product criterion:9 chain criterion:8
@expansion{} hilbert series criterion:6
@expansion{} dehomogenization
@expansion{} imap to original ring
@expansion{} simplification
@expansion{} _[1]=c2d6-c2d2-d4+1
@expansion{} _[2]=c3d2+c2d3-c-d
@expansion{} _[3]=bd4-b+d5-d
@expansion{} _[4]=bc-bd5+c2d4+cd-d6-d2
@expansion{} _[5]=b2+2bd+d2
@expansion{} _[6]=a+b+c+d
ring rp=(0,a,b),(c,d), lp;
ideal i=imap(r,i);
ideal j=groebner(i);
@expansion{} std in 0,(c,d,a,b,@@t),(dp,C)
@expansion{} [63:1]1(3)s2(2)s3s4-s5ss6-s7--
@expansion{} product criterion:8 chain criterion:5
@expansion{} std with hilb in  (0),(c,d,a,b,@@t),(lp(2),C, dp(3))
@expansion{} [63:3]1(3)s2(2)s3s4-s5ss6shhhh8shh
@expansion{} product criterion:9 chain criterion:8
@expansion{} hilbert series criterion:6
@expansion{} dehomogenization
@expansion{} imap to original ring
@expansion{} simplification
option(noprot);
j; simplify(j,1); std(i);
@expansion{} j[1]=(a3b2+a2b3-a-b)
@expansion{} _[1]=1
@expansion{} _[1]=1
if (system("with","MP")) @{groebner(i,0);@}
@expansion{} // ** groebner did not finish
@expansion{} _[1]=0
defined(groebner_error);
@expansion{} 1
@c end example groebner d2t_singular/standard_lib.doc:149
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:163
@ifinfo
@menu
See also:
* std::
* stdfglm::
* stdhilb::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{std};
@ref{stdfglm};
@ref{stdhilb}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:163

@c ---end content groebner---

@c ------------------- quot -------------
@node quot, res, groebner, standard_lib
@subsubsection quot
@cindex quot
@c ---content quot---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{quot (} module_expression@code{,} module_expression @code{)}
@*@code{quot (} module_expression@code{,} module_expression@code{,}
int_expression @code{)}
@*@code{quot (} ideal_expression@code{,} ideal_expression @code{)}
@*@code{quot (} ideal_expression@code{,} ideal_expression@code{,}
int_expression @code{)}

@item @strong{Type:}
ideal

@item @strong{Syntax:}
@code{quot (} module_expression@code{,} ideal_expression @code{)}

@item @strong{Type:}
module

@item @strong{Purpose:}
computes the quotient of the 1st and the 2nd argument.
If a 3rd argument 'n' is given the n-th method is used
(n=1...5).

@end table
@strong{Example:}
@smallexample
@c reused example quot d2t_singular/standard_lib.doc:202
  ring r=181,(x,y,z),(c,ls);
ideal id1=maxideal(4);
ideal id2=x2+xyz,y2-z3y,z3+y5xz;
option(prot);
ideal id3=quotient(id1,id2);
@expansion{} [1023:1]4(14)s(13)s(12)s(11)s(10)s(9)s(8)s(7)s(6)s(5)s(4)s(3)s(2)sss
@expansion{} product criterion:12 chain criterion:0
@expansion{} @{3@}[1023:3]8(2)s(4)s(5)s9s.s.s.s.s.s
@expansion{} product criterion:0 chain criterion:39
id3;
@expansion{} id3[1]=z2
@expansion{} id3[2]=yz
@expansion{} id3[3]=y2
@expansion{} id3[4]=xz
@expansion{} id3[5]=xy
@expansion{} id3[6]=x2
ideal id4=quot(id1,id2,1);
@expansion{} [1023:2]4(14)s(13)s(12)s(11)s(10)s(9)s(8)s(7)s(6)s(5)s(4)s(3)s(2)sss
@expansion{} product criterion:0 chain criterion:0
@expansion{} (S:3)rtrtrt
@expansion{} @{1@}[1023:3]4(2)s(4)s(5)s5s.s(3)s(2)sss
@expansion{} product criterion:0 chain criterion:39
@expansion{} @{1@}[1023:3]4(5)s(4)s(3)s(2)sss
@expansion{} product criterion:0 chain criterion:9
@expansion{} [255:3]3(11)s(10)sss(9)s(10)s(8)ss(7)s(8)s(6)s(7)s4(5)-----
@expansion{} product criterion:12 chain criterion:9
@expansion{} @{1@}[1023:3]4(2)sss
@expansion{} product criterion:0 chain criterion:12
@expansion{} [255:3]2(8)s(7)s(6)s3(5)ssssss4-----
@expansion{} product criterion:15 chain criterion:3
id4;
@expansion{} id4[1]=z2
@expansion{} id4[2]=yz
@expansion{} id4[3]=xz
@expansion{} id4[4]=y2
@expansion{} id4[5]=xy
@expansion{} id4[6]=x2
ideal id5=quot(id1,id2,2);
@expansion{} [1023:2]4(14)s(13)s(12)s(11)s(10)s(9)s(8)s(7)s(6)s(5)s(4)s(3)s(2)sss
@expansion{} product criterion:0 chain criterion:0
@expansion{} (S:3)rtrtrt
@expansion{} @{1@}[1023:3]4(2)sss
@expansion{} product criterion:0 chain criterion:12
@expansion{} @{1@}[1023:3]4(5)s(4)s(3)s(2)sss
@expansion{} product criterion:0 chain criterion:9
@expansion{} [255:3]2(8)s(7)s(6)s3(5)s(4)s(3)s(2)sss
@expansion{} product criterion:15 chain criterion:0
id5;
@expansion{} id5[1]=z2
@expansion{} id5[2]=yz
@expansion{} id5[3]=xz
@expansion{} id5[4]=y2
@expansion{} id5[5]=xy
@expansion{} id5[6]=x2
@c end example quot d2t_singular/standard_lib.doc:202
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:215
@ifinfo
@menu
See also:
* quotient::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{quotient}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:215

@c ---end content quot---

@c ------------------- res -------------
@node res, sprintf, quot, standard_lib
@subsubsection res
@cindex res
@c ---content res---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@c we do texinfo here:
@cindex resolution, computation of
@table @code
@item @strong{Syntax:}
@code{res (} ideal_expression@code{,} int_expression @code{[,} any_expression @code{])}
@*@code{res (} module_expression@code{,} int_expression @code{[,} any_expression @code{])}
@item @strong{Type:}
resolution
@item @strong{Purpose:}
computes a (possibly minimal) free resolution of an ideal or module using
a heuristically chosen method.
@* The second (int) argument (say, @code{k}) specifies the length of
the resolution. If it is not positive then @code{k} is assumed to be the
number of variables of the basering.
@* If a third argument is given, the returned resolution is minimized.

Depending on the input, the returned resolution is computed using the
following methods:
@table @asis
@item @strong{quotient rings:}
@code{nres} (classical method using syzygies) , see @ref{nres}.

@item @strong{homogeneous ideals and k=0:}
@code{lres} (La'Scala's method), see @ref{lres}.

@item @strong{not minimized resolution and (homogeneous input with k not 0, or local rings):}
@code{sres} (Schreyer's method), see @ref{sres}.

@item @strong{all other inputs:}
@code{mres} (classical method), see @ref{mres}.
@end table
@item @strong{Note:}
Accessing single elements of a resolution may require that some partial
computations have to be finished and may therefore take some time.
@end table
@c inserted refs from d2t_singular/standard_lib.doc:263
@ifinfo
@menu
See also
* betti::
* hres::
* ideal::
* lres::
* minres::
* module::
* mres::
* nres::
* resolution::
* sres::
@end menu
@end ifinfo
@iftex
See also
@ref{betti};
@ref{hres};
@ref{ideal};
@ref{lres};
@ref{minres};
@ref{module};
@ref{mres};
@ref{nres};
@ref{resolution};
@ref{sres}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:263

@strong{Example:}
@smallexample
@c reused example res d2t_singular/standard_lib.doc:279
  ring r=0,(x,y,z),dp;
ideal i=xz,yz,x3-y3;
def l=res(i,0); // homogeneous ideal: uses lres
l;
@expansion{}  1      3      2
@expansion{} r <--  r <--  r
@expansion{}
@expansion{} 0      1      2
@expansion{} resolution not minimized yet
@expansion{}
print(betti(l), "betti"); // input to betti may be of type resolution
@expansion{}            0     1     2
@expansion{} ------------------------
@expansion{}     0:     1     -     -
@expansion{}     1:     -     2     1
@expansion{}     2:     -     1     1
@expansion{} ------------------------
@expansion{} total:     1     3     2
l[2];         // element access may take some time
@expansion{} _[1]=-x*gen(1)+y*gen(2)
@expansion{} _[2]=-x2*gen(2)+y2*gen(1)+z*gen(3)
i=i,x+1;
l=res(i,0);   // inhomogeneous ideal: uses mres
l;
@expansion{}  1      3      3      1
@expansion{} r <--  r <--  r <--  r
@expansion{}
@expansion{} 0      1      2      3
@expansion{} resolution not minimized yet
@expansion{}
ring rs=0,(x,y,z),ds;
ideal i=imap(r,i);
def l=res(i,0); // local ring not minimized: uses sres
l;
@expansion{}   1       1
@expansion{} rs <--  rs
@expansion{}
@expansion{} 0       1
@expansion{} resolution not minimized yet
@expansion{}
res(i,0,0);     // local ring and minimized: uses mres
@expansion{}   1       1
@expansion{} rs <--  rs
@expansion{}
@expansion{} 0       1
@expansion{}
@c end example res d2t_singular/standard_lib.doc:279
@end smallexample
@c ---end content res---

@c ------------------- sprintf -------------
@node sprintf, fprintf, res, standard_lib
@subsubsection sprintf
@cindex sprintf
@c ---content sprintf---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{sprintf (} string_expression @code{[,} any_expressions
@code{] )}

@item @strong{Return:}
string

@item @strong{Purpose:}
@code{sprintf(fmt,...);} performs output formatting. The first
argument is a format control string. Additional arguments may be
required, depending on the content of the control string. A series
of output characters is generated as directed by the control string;
these characters are returned as a string. @*
The control string @code{fmt} is simply text to be copied,
except that the string may contain conversion specifications.@*
Do @code{help print;} for a listing of valid conversion
specifications. As an addition to the conversions of @code{print},
the @code{%n} and @code{%2} conversion specification does not
consume an additional argument, but simply generates a newline
character.

@item @strong{Note:}
If one of the additional arguments is a list, then it should be
enclosed once more into a @code{list()} command, since passing a list
as an argument flattens the list by one level.

@end table
@strong{Example:}
@smallexample
@c reused example sprintf d2t_singular/standard_lib.doc:335
  ring r=0,(x,y,z),dp;
module m=[1,y],[0,x+z];
intmat M=betti(mres(m,0));
list l = r, m, M;
string s = sprintf("s:%s,%n l:%l", 1, 2); s;
@expansion{} s:1,
@expansion{}  l:int(2)
s = sprintf("s:%n%s", l); s;
@expansion{} s:
@expansion{} (0),(x,y,z),(dp(3),C)
s = sprintf("s:%2%s", list(l)); s;
@expansion{} s:
@expansion{} (0),(x,y,z),(dp(3),C),y*gen(2)+gen(1),x*gen(2)+z*gen(2),1,1
s = sprintf("2l:%n%2l", list(l)); s;
@expansion{} 2l:
@expansion{} list("(0),(x,y,z),(dp(3),C)",
@expansion{} module(y*gen(2)+gen(1),
@expansion{} x*gen(2)+z*gen(2)),
@expansion{} intmat(intvec(1,1 ),1,2))
@expansion{}
s = sprintf("%p", list(l)); s;
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
s = sprintf("%;", list(l)); s;
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
s = sprintf("%b", M); s;
@expansion{}            0     1
@expansion{} ------------------
@expansion{}     0:     1     1
@expansion{} ------------------
@expansion{} total:     1     1
@expansion{}
@c end example sprintf d2t_singular/standard_lib.doc:335
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:349
@ifinfo
@menu
See also:
* fprintf::
* print::
* printf::
* string::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{fprintf};
@ref{print};
@ref{printf};
@ref{string}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:349

@c ---end content sprintf---

@c ------------------- fprintf -------------
@node fprintf, printf, sprintf, standard_lib
@subsubsection fprintf
@cindex fprintf
@c ---content fprintf---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{fprintf (} link_expression@code{,} string_expression @code{[,}
any_expressions@code{] )}

@item @strong{Return:}
none

@item @strong{Purpose:}
@code{fprintf(l,fmt,...);} performs output formatting.
The second argument is a format control string. Additional
arguments may be required, depending on the content of the
control string. A series of output characters is generated as
directed by the control string; these characters are
written to the link l.
The control string @code{fmt} is simply text to be copied, except
that the string may contain conversion specifications.@*
Do @code{help print;} for a listing of valid conversion
specifications. As an addition to the conversions of @code{print},
the @code{%n} and @code{%2} conversion specification does not
consume an additional argument, but simply generates a newline
character.

@item @strong{Note:}
If one of the additional arguments is a list, then it should be
enclosed once more into a @code{list()} command, since passing
a list as an argument flattens the list by one level.

@end table
@strong{Example:}
@smallexample
@c reused example fprintf d2t_singular/standard_lib.doc:393
  ring r=0,(x,y,z),dp;
module m=[1,y],[0,x+z];
intmat M=betti(mres(m,0));
list l=r,m,M;
link li="";   // link to stdout
fprintf(li,"s:%s,l:%l",1,2);
@expansion{} s:1,l:int(2)
fprintf(li,"s:%s",l);
@expansion{} s:(0),(x,y,z),(dp(3),C)
fprintf(li,"s:%s",list(l));
@expansion{} s:(0),(x,y,z),(dp(3),C),y*gen(2)+gen(1),x*gen(2)+z*gen(2),1,1
fprintf(li,"2l:%2l",list(l));
@expansion{} 2l:list("(0),(x,y,z),(dp(3),C)",
@expansion{} module(y*gen(2)+gen(1),
@expansion{} x*gen(2)+z*gen(2)),
@expansion{} intmat(intvec(1,1 ),1,2))
@expansion{}
fprintf(li,"%p",list(l));
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
fprintf(li,"%;",list(l));
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
fprintf(li,"%b",M);
@expansion{}            0     1
@expansion{} ------------------
@expansion{}     0:     1     1
@expansion{} ------------------
@expansion{} total:     1     1
@expansion{}
@c end example fprintf d2t_singular/standard_lib.doc:393
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:408
@ifinfo
@menu
See also:
* print::
* printf::
* sprintf::
* string::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{print};
@ref{printf};
@ref{sprintf};
@ref{string}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:408

@c ---end content fprintf---

@c ------------------- printf -------------
@node printf,, fprintf, standard_lib
@subsubsection printf
@cindex printf
@c ---content printf---
Procedure from library @code{standard.lib} (@pxref{standard_lib}).

@table @asis
@item @strong{Syntax:}
@code{printf (} string_expression @code{[,} any_expressions@code{] )}

@item @strong{Return:}
none

@item @strong{Purpose:}
@code{printf(fmt,...);} performs output formatting. The first
argument is a format control string. Additional arguments may be
required, depending on the content of the control string. A series
of output characters is generated as directed by the control string;
these characters are displayed (i.e., printed to standard out). @*
The control string @code{fmt} is simply text to be copied, except
that the string may contain conversion specifications. @*
Do @code{help print;} for a listing of valid conversion
specifications. As an addition to the conversions of @code{print},
the @code{%n} and @code{%2} conversion specification does not
consume an additional argument, but simply generates a newline
character.

@item @strong{Note:}
If one of the additional arguments is a list, then it should be
enclosed once more into a @code{list()} command, since passing a
list as an argument flattens the list by one level.

@end table
@strong{Example:}
@smallexample
@c reused example printf d2t_singular/standard_lib.doc:450
  ring r=0,(x,y,z),dp;
module m=[1,y],[0,x+z];
intmat M=betti(mres(m,0));
list l=r,m,M;
printf("s:%s,l:%l",1,2);
@expansion{} s:1,l:int(2)
printf("s:%s",l);
@expansion{} s:(0),(x,y,z),(dp(3),C)
printf("s:%s",list(l));
@expansion{} s:(0),(x,y,z),(dp(3),C),y*gen(2)+gen(1),x*gen(2)+z*gen(2),1,1
printf("2l:%2l",list(l));
@expansion{} 2l:list("(0),(x,y,z),(dp(3),C)",
@expansion{} module(y*gen(2)+gen(1),
@expansion{} x*gen(2)+z*gen(2)),
@expansion{} intmat(intvec(1,1 ),1,2))
@expansion{}
printf("%p",list(l));
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
printf("%;",list(l));
@expansion{} [1]:
@expansion{}    //   characteristic : 0
@expansion{} //   number of vars : 3
@expansion{} //        block   1 : ordering dp
@expansion{} //                  : names    x y z
@expansion{} //        block   2 : ordering C
@expansion{} [2]:
@expansion{}    _[1]=y*gen(2)+gen(1)
@expansion{}    _[2]=x*gen(2)+z*gen(2)
@expansion{} [3]:
@expansion{}    1,1
@expansion{}
printf("%b",M);
@expansion{}            0     1
@expansion{} ------------------
@expansion{}     0:     1     1
@expansion{} ------------------
@expansion{} total:     1     1
@expansion{}
@c end example printf d2t_singular/standard_lib.doc:450
@end smallexample
@c inserted refs from d2t_singular/standard_lib.doc:464
@ifinfo
@menu
See also:
* fprintf::
* print::
* sprintf::
* string::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{fprintf};
@ref{print};
@ref{sprintf};
@ref{string}.
@end iftex
@c end inserted refs from d2t_singular/standard_lib.doc:464

@c ---end content printf---


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/stratify_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/stratify_lib.doc INSTEAD
@c library version: (1.7.2.4,2002/04/11)
@c library file: ../Singular/LIB/stratify.lib
@cindex stratify.lib
@cindex stratify_lib
@table @asis
@item @strong{Library:}
stratify.lib
@item @strong{Purpose:}
   Algorithmic Stratification for Unipotent Group-Actions
@item @strong{Author:}
Anne Fruehbis-Krueger, anne@@mathematik.uni-kl.de

@item @strong{Overview:}
This library provides an implementation of the algorithm
of Greuel and Pfister introduced in the article <Geometric
quotients of unipotent group actions>.

@end table

@strong{Procedures:}
@menu
* prepMat:: list of submatrices corresp. to given filtration
* stratify:: algorithmic stratification (main procedure)
@end menu
@c ---end content LibInfo---

@c ------------------- prepMat -------------
@node prepMat, stratify,, stratify_lib
@subsubsection prepMat
@cindex prepMat
@c ---content prepMat---
Procedure from library @code{stratify.lib} (@pxref{stratify_lib}).

@table @asis
@item @strong{Usage:}
prepMat(M,wr,ws,step);
@*where M is a matrix, wr is an intvec of size ncols(M),
ws an intvec of size nrows(M) and step is an integer

@item @strong{Return:}
2 lists of submatrices corresponding to the filtrations
specified by wr and ws
@*the first list corresponds to the list for the filtration
of AdA, i.e. the ranks of these matrices will be the r_i,
the second one to the list for the filtration of L, i.e.
the ranks of these matrices will be the s_i

@item @strong{Note:}
* the entries of the matrix M are M_ij=delta_i(x_j),
@** wr is used to determine what subset of the set of all dx_i is
generating AdF^l(A):
@*if (k-1)*step <= wr[i] < k*step, then dx_i is in the set of
generators of AdF^l(A) for all l>=k and the i-th column
of M appears in each submatrix starting from the k-th
@** ws is used to determine what subset of the set of all delta_i
is generating Z_l(L):
@*if (k-1)*step <= ws[i] < k*step, then delta_i is in the set
of generators of Z_l(A) for l < k and the i-th row of M
appears in each submatrix up to the (k-1)th
@** the entries of wr and ws as well as step should be positive
integers

@end table
@strong{Example:}
@smallexample
@c computed example prepMat d2t_singular/stratify_lib.doc:67
LIB "stratify.lib";
ring r=0,(t(1..3)),dp;
matrix M[2][3]=0,t(1),3*t(2),0,0,t(1);
print(M);
@expansion{} 0,t(1),3*t(2),
@expansion{} 0,0,   t(1)
intvec wr=1,3,5;
intvec ws=2,4;
int step=2;
prepMat(M,wr,ws,step);
@expansion{} [1]:
@expansion{}    [1]:
@expansion{}       _[1,1]=0
@expansion{}       _[2,1]=0
@expansion{}    [2]:
@expansion{}       _[1,1]=0
@expansion{}       _[1,2]=t(1)
@expansion{}       _[2,1]=0
@expansion{}       _[2,2]=0
@expansion{}    [3]:
@expansion{}       _[1,1]=0
@expansion{}       _[1,2]=t(1)
@expansion{}       _[1,3]=3*t(2)
@expansion{}       _[2,1]=0
@expansion{}       _[2,2]=0
@expansion{}       _[2,3]=t(1)
@expansion{} [2]:
@expansion{}    [1]:
@expansion{}       _[1,1]=0
@expansion{}       _[1,2]=t(1)
@expansion{}       _[1,3]=3*t(2)
@expansion{}       _[2,1]=0
@expansion{}       _[2,2]=0
@expansion{}       _[2,3]=t(1)
@expansion{}    [2]:
@expansion{}       _[1,1]=0
@expansion{}       _[1,2]=0
@expansion{}       _[1,3]=t(1)
@c end example prepMat d2t_singular/stratify_lib.doc:67
@end smallexample
@c ---end content prepMat---

@c ------------------- stratify -------------
@node stratify,, prepMat, stratify_lib
@subsubsection stratify
@cindex stratify
@c ---content stratify---
Procedure from library @code{stratify.lib} (@pxref{stratify_lib}).

@table @asis
@item @strong{Usage:}
stratify(M,wr,ws,step);
@*where M is a matrix, wr is an intvec of size ncols(M),
ws an intvec of size nrows(M) and step is an integer

@item @strong{Return:}
list of lists, each entry of the big list corresponds to one
locally closed set and has the following entries:
@*1) intvec giving the corresponding rs-vector
@*2) ideal determining the closed set
@*3) list d of polynomials determining the open set D(d[1])
empty list if there is more than one open set
@*4-n) lists of polynomials determining open sets which all lead
to the same rs-vector

@item @strong{Note:}
* ring ordering should be global, i.e. the ring should be a
polynomial ring
@** the entries of the matrix M are M_ij=delta_i(x_j),
@** wr is used to determine what subset of the set of all dx_i is
generating AdF^l(A):
@*if (k-1)*step < wr[i] <= k*step, then dx_i is in the set of
generators of AdF^l(A) for all l>=k
@** ws is used to determine what subset of the set of all delta_i
is generating Z_l(L):
@*if (k-1)*step <= ws[i] < k*step, then delta_i is in the set
of generators of Z_l(A) for l < k
@** the entries of wr and ws as well as step should be positive
integers
@** the filtrations have to be known, no sanity checks concerning
the filtrations are performed !!!

@end table
@strong{Example:}
@smallexample
@c computed example stratify d2t_singular/stratify_lib.doc:123
LIB "stratify.lib";
ring r=0,(t(1..3)),dp;
matrix M[2][3]=0,t(1),3*t(2),0,0,t(1);
intvec wr=1,3,5;
intvec ws=2,4;
int step=2;
stratify(M,wr,ws,step);
@expansion{} [1]:
@expansion{}    [1]:
@expansion{}       0,0,0,0
@expansion{}    [2]:
@expansion{}       _[1]=t(2)
@expansion{}       _[2]=t(1)
@expansion{}    [3]:
@expansion{}       [1]:
@expansion{}          1
@expansion{} [2]:
@expansion{}    [1]:
@expansion{}       0,1,0,1
@expansion{}    [2]:
@expansion{}       _[1]=t(1)
@expansion{}    [3]:
@expansion{}       [1]:
@expansion{}          t(2)
@expansion{}       [2]:
@expansion{}          t(2)
@expansion{} [3]:
@expansion{}    [1]:
@expansion{}       1,2,1,2
@expansion{}    [2]:
@expansion{}       _[1]=0
@expansion{}    [3]:
@expansion{}       [1]:
@expansion{}          t(1)
@expansion{}       [2]:
@expansion{}          t(1)
@c end example stratify d2t_singular/stratify_lib.doc:123
@end smallexample
@c ---end content stratify---

repo_name: mthl/texinfo

license: mit


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/surf_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/surf_lib.doc INSTEAD
@c library version: (1.19.2.6,2002/07/17)
@c library file: ../Singular/LIB/surf.lib
@cindex surf.lib
@cindex surf_lib
@table @asis
@item @strong{Library:}
surf.lib
@item @strong{Purpose:}
    Procedures for Graphics with Surf
@item @strong{Author:}
Hans Schoenemann,
@*the program surf is written by Stefan Endrass

@item @strong{Note:}
To use this library requires the program @code{surf} to be installed.
 @code{surf} is only available for Linux PCs and Sun workstations.
 You can download @code{surf} either from
  @uref{http://sourceforge.net/projects/surf}
  or from @uref{ftp://www.mathematik.uni-kl.de/pub/Math/Singular/utils/}.

@end table

@strong{Procedures:}
@menu
* plot:: plots plane curves and surfaces
@end menu
@c ---end content LibInfo---

@c ------------------- plot -------------
@node plot,,, surf_lib
@subsubsection plot
@cindex plot
@c ---content plot---
Procedure from library @code{surf.lib} (@pxref{surf_lib}).

@table @asis
@item @strong{Usage:}
plot(I); I ideal or poly

@item @strong{Assume:}
I defines a plane curve or a surface given by one equation

@item @strong{Return:}
nothing

@item @strong{Note:}
requires the external program 'surf' to be installed

@end table
@strong{Example:}
@smallexample
@c skipped computation of example plot d2t_singular/surf_lib.doc:53
LIB "surf.lib";
// ---------  plane curves ------------
ring rr0 = 0,(x1,x2),dp;
ideal I = x1^3 - x2^2;
plot(I);
ring rr1 = 0,(x,y,z),dp;
ideal I(1) = 2x2-1/2x3 +1-y+1;
plot(I(1));
//  ---- Singular Logo --------------
poly logo = ((x+3)^3 + 2*(x+3)^2 - y^2)*(x^3 - y^2)*((x-3)^3-2*(x-3)^2-y^2);
plot(logo);
// Steiner surface
ideal J(2) = x^2*y^2+x^2*z^2+y^2*z^2-17*x*y*z;
plot(J(2));
// --------------------
plot(x*(x2-y2)+z2);
// E7
plot(x^3-x*y^3+z^2);
// Whitney umbrella
plot(z^2-x^2*y);
@end smallexample
@c ---end content plot---


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/template_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/template_lib.doc INSTEAD
@c library version: (1.10,2001/01/16)
@c library file: ../Singular/LIB/template.lib
@cindex template.lib
@cindex template_lib
@table @asis
@item @strong{Library:}
template.lib
@item @strong{Purpose:}
  A Template for a Singular Library
@item @strong{Author:}
Olaf Bachmann, email: obachman@@mathematik.uni-kl.de

@cindex library, template.lib
@cindex template.lib
@cindex library, info string
@end table

@strong{Procedures:}
@menu
* mdouble:: return double of int argument
* mtripple:: return three times int argument
* msum:: sum of int arguments
@end menu
@c inserted refs from d2t_singular/template_lib.doc:25
@ifinfo
@menu
See also:
* Guidelines for writing a library::
* Typesetting of help strings::
* standard_lib::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Guidelines for writing a library};
@ref{Typesetting of help strings};
@ref{standard_lib}.
@end iftex
@c end inserted refs from d2t_singular/template_lib.doc:25

@c ---end content LibInfo---

@c ------------------- mdouble -------------
@node mdouble, mtripple,, template_lib
@subsubsection mdouble
@cindex mdouble
@c ---content mdouble---
Procedure from library @code{template.lib} (@pxref{template_lib}).

@table @asis
@item @strong{Usage:}
mdouble(i); i int

@item @strong{Return:}
int: i+i

@item @strong{Note:}
Help string is in pure ASCII
@*this line starts on a new line since previous line is short
mdouble(i): no new line

@cindex procedure, ASCII help
@end table
@strong{Example:}
@smallexample
@c computed example mdouble d2t_singular/template_lib.doc:54
LIB "template.lib";
mdouble(0);
@expansion{} 0
mdouble(-1);
@expansion{} -2
@c end example mdouble d2t_singular/template_lib.doc:54
@end smallexample
@c inserted refs from d2t_singular/template_lib.doc:60
@ifinfo
@menu
See also:
* Typesetting of help strings::
* msum::
* mtripple::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Typesetting of help strings};
@ref{msum};
@ref{mtripple}.
@end iftex
@c end inserted refs from d2t_singular/template_lib.doc:60

@c ---end content mdouble---

@c ------------------- mtripple -------------
@node mtripple, msum, mdouble, template_lib
@subsubsection mtripple
@cindex mtripple
@c ---content mtripple---
Procedure from library @code{template.lib} (@pxref{template_lib}).

@c we do texinfo here
@table @asis
@item @strong{Usage:}
@code{mtripple(i)}; @code{i} int

@item @strong{Return:}
int:
@ifinfo
@math{i+i+i}
@end ifinfo
@tex
$i+i+i$
@end tex

@item @strong{Note:}
Help is in pure Texinfo
@*This help string is written in texinfo, which enables you to use,
among others, the @@math command for mathematical typesetting (like

@ifinfo
@math{\alpha, \beta}
@end ifinfo
@tex
$\alpha, \beta$
@end tex
).
@*It also gives more control over the layout, but is, admittingly,
more cumbersome to write.
@end table
@c use @c ref contstuct for references
@cindex procedure, texinfo help
@c inserted refs from d2t_singular/template_lib.doc:90
@ifinfo
@menu
@strong{See also:}
* Typesetting of help strings::
* mdouble::
* msum::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Typesetting of help strings};
@ref{mdouble};
@ref{msum}.
@end iftex
@c end inserted refs from d2t_singular/template_lib.doc:90

@strong{Example:}
@smallexample
@c computed example mtripple d2t_singular/template_lib.doc:97
LIB "template.lib";
mtripple(0);
@expansion{} 0
mtripple(-1);
@expansion{} -3
@c end example mtripple d2t_singular/template_lib.doc:97
@end smallexample
@c ---end content mtripple---

@c ------------------- msum -------------
@node msum,, mtripple, template_lib
@subsubsection msum
@cindex msum
@c ---content msum---
Procedure from library @code{template.lib} (@pxref{template_lib}).

@table @asis
@item @strong{Usage:}
msum([i_1,..,i_n]); @code{i_1,..,i_n} def

@item @strong{Return:}
Sum of int arguments

@item @strong{Note:}
This help string is written in a mixture of ASCII and texinfo
@* Use a @@ref constructs for references (like @pxref{mtripple})
@* Use @@code for typewriter font (like @code{i_1})
@* Use @@math for simple math mode typesetting (like
@ifinfo
@math{i_1}
@end ifinfo
@tex
$i_1$
@end tex
).
@* Note: No parenthesis like @} are allowed inside @@math and @@code
@* Use @@example for indented preformatted text typeset in typewriter
font like
@smallexample
         this  --> that
@end smallexample
Use @@format for preformatted text typeset in normal font
@format
         this --> that
@end format
Use @@texinfo for text in pure texinfo

@expansion{}
@tex
$i_{1,1}$
@end tex

Notice that
@*automatic linebreaking is still in affect (like on this line).

@cindex procedure, ASCII/Texinfo help
@end table
@strong{Example:}
@smallexample
@c computed example msum d2t_singular/template_lib.doc:149
LIB "template.lib";
msum();
@expansion{} 0
msum(4);
@expansion{} 4
msum(1,2,3,4);
@expansion{} 10
@c end example msum d2t_singular/template_lib.doc:149
@end smallexample
@c inserted refs from d2t_singular/template_lib.doc:156
@ifinfo
@menu
See also:
* Typesetting of help strings::
* mdouble::
* mtripple::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Typesetting of help strings};
@ref{mdouble};
@ref{mtripple}.
@end iftex
@c end inserted refs from d2t_singular/template_lib.doc:156

@c ---end content msum---


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/toric_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/toric_lib.doc INSTEAD
@c library version: (1.11,2001/02/06)
@c library file: ../Singular/LIB/toric.lib
@cindex toric.lib
@cindex toric_lib
@table @asis
@item @strong{Library:}
toric.lib
@item @strong{Purpose:}
   Standard Basis of Toric Ideals
@item @strong{Author:}
Christine Theis, email: ctheis@@math.uni-sb.de

@end table

@strong{Procedures:}
@menu
* toric_ideal:: computes the toric ideal of A
* toric_std:: standard basis of I by a specialized Buchberger algorithm
@end menu
@c ---end content LibInfo---

@c ------------------- toric_ideal -------------
@node toric_ideal, toric_std,, toric_lib
@subsubsection toric_ideal
@cindex toric_ideal
@c ---content toric_ideal---
Procedure from library @code{toric.lib} (@pxref{toric_lib}).

@table @asis
@item @strong{Usage:}
toric_ideal(A,alg); A intmat, alg string
@*toric_ideal(A,alg,prsv); A intmat, alg string, prsv intvec

@item @strong{Return:}
ideal: standard basis of the toric ideal of A

@item @strong{Note:}
These procedures return the standard basis of the toric ideal of A
with respect to the term ordering in the current basering. Not all
term orderings are supported: The usual global term orderings may be
used, but no block orderings combining them.
@*One may call the procedure with several different algorithms: @*
- the algorithm of Conti/Traverso using elimination (ect), @*
- the algorithm of Pottier (pt),
@*- an algorithm of Bigatti/La Scala/Robbiano (blr),
@*- the algorithm of Hosten/Sturmfels (hs),
@*- the algorithm of DiBiase/Urbanke (du).
@*The argument `alg' should be the abbreviation for an algorithm as
above: ect, pt, blr, hs or du.

If `alg' is chosen to be `blr' or `hs', the algorithm needs a vector
with positive coefficients in the row space of A.
@*If no row of A contains only positive entries, one has to use the
second version of toric_ideal which takes such a vector as its third
argument.
@*For the mathematical background, see

  @ref{Toric ideals and integer programming}.

@end table
@strong{Example:}
@smallexample
@c computed example toric_ideal d2t_singular/toric_lib.doc:64
LIB "toric.lib";
ring r=0,(x,y,z),dp;
// call with two arguments
intmat A[2][3]=1,1,0,0,1,1;
A;
@expansion{} 1,1,0,
@expansion{} 0,1,1
ideal I=toric_ideal(A,"du");
I;
@expansion{} I[1]=xz-y
I=toric_ideal(A,"blr");
@expansion{} ERROR: The chosen algorithm needs a positive vector in the row space of t\
   he matrix.
I;
@expansion{} I[1]=0
// call with three arguments
intvec prsv=1,2,1;
I=toric_ideal(A,"blr",prsv);
I;
@expansion{} I[1]=xz-y
@c end example toric_ideal d2t_singular/toric_lib.doc:64
@end smallexample
@c inserted refs from d2t_singular/toric_lib.doc:80
@ifinfo
@menu
See also:
* Toric ideals::
* intprog_lib::
* toric_lib::
* toric_std::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Toric ideals};
@ref{intprog_lib};
@ref{toric_lib};
@ref{toric_std}.
@end iftex
@c end inserted refs from d2t_singular/toric_lib.doc:80

@c ---end content toric_ideal---

@c ------------------- toric_std -------------
@node toric_std,, toric_ideal, toric_lib
@subsubsection toric_std
@cindex toric_std
@c ---content toric_std---
Procedure from library @code{toric.lib} (@pxref{toric_lib}).

@table @asis
@item @strong{Usage:}
toric_std(I); I ideal

@item @strong{Return:}
ideal: standard basis of I

@item @strong{Note:}
This procedure computes the standard basis of I using a specialized
Buchberger algorithm. The generating system by which I is given has
to consist of binomials of the form x^u-x^v. There is no real check
if I is toric. If I is generated by binomials of the above form,
but not toric, toric_std computes an ideal `between' I and its
saturation with respect to all variables.
@*For the mathematical background, see

   @ref{Toric ideals and integer programming}.

@end table
@strong{Example:}
@smallexample
@c computed example toric_std d2t_singular/toric_lib.doc:114
LIB "toric.lib";
ring r=0,(x,y,z),wp(3,2,1);
// call with toric ideal (of the matrix A=(1,1,1))
ideal I=x-y,x-z;
ideal J=toric_std(I);
J;
@expansion{} J[1]=y-z
@expansion{} J[2]=x-z
// call with the same ideal, but badly chosen generators:
// 1) not only binomials
I=x-y,2x-y-z;
J=toric_std(I);
@expansion{} ERROR: Generator 2 of the input ideal is no difference of monomials.
// 2) binomials whose monomials are not relatively prime
I=x-y,xy-yz,y-z;
J=toric_std(I);
@expansion{} Warning: The monomials of generator 2 of the input ideal are not relative\
   ly prime.
J;
@expansion{} J[1]=y-z
@expansion{} J[2]=x-z
// call with a non-toric ideal that seems to be toric
I=x-yz,xy-z;
J=toric_std(I);
J;
@expansion{} J[1]=y2-1
@expansion{} J[2]=x-yz
// comparison with real standard basis and saturation
ideal H=std(I);
H;
@expansion{} H[1]=x-yz
@expansion{} H[2]=y2z-z
LIB "elim.lib";
sat(H,xyz);
@expansion{} [1]:
@expansion{}    _[1]=x-yz
@expansion{}    _[2]=y2-1
@expansion{} [2]:
@expansion{}    1
@c end example toric_std d2t_singular/toric_lib.doc:114
@end smallexample
@c inserted refs from d2t_singular/toric_lib.doc:140
@ifinfo
@menu
See also:
* Toric ideals::
* intprog_lib::
* toric_ideal::
* toric_lib::
@end menu
@end ifinfo
@iftex
@strong{See also:}
@ref{Toric ideals};
@ref{intprog_lib};
@ref{toric_ideal};
@ref{toric_lib}.
@end iftex
@c end inserted refs from d2t_singular/toric_lib.doc:140

@c ---end content toric_std---


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/triang_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/triang_lib.doc INSTEAD
@c library version: (1.7,2001/02/19)
@c library file: ../Singular/LIB/triang.lib
@cindex triang.lib
@cindex triang_lib
@table @asis
@item @strong{Library:}
triang.lib
@item @strong{Purpose:}
   Decompose Zero-dimensional Ideals into Triangular Sets
@item @strong{Author:}
D. Hillebrand

@end table

@strong{Procedures:}
@menu
* triangL:: Decomposition of (G) into triangular systems (Lazard).
* triangLfak:: Decomp. of (G) into tri. systems plus factorization.
* triangM:: Decomposition of (G) into triangular systems (Moeller).
* triangMH:: Decomp. of (G) into tri. syst. with disjoint varieties.
@end menu
@c ---end content LibInfo---

@c ------------------- triangL -------------
@node triangL, triangLfak,, triang_lib
@subsubsection triangL
@cindex triangL
@c ---content triangL---
Procedure from library @code{triang.lib} (@pxref{triang_lib}).

@table @asis
@item @strong{Usage:}
triangL(G); G=ideal

@item @strong{Assume:}
G is the reduced lexicographical Groebner bases of the
zero-dimensional ideal (G), sorted by increasing leading terms.

@item @strong{Return:}
a list of finitely many triangular systems, such that
the union of their varieties equals the variety of (G).

@item @strong{Note:}
Algorithm of Lazard (see: Lazard, D.: Solving zero-dimensional
algebraic systems, J. Symb. Comp. 13, 117 - 132, 1992).

@end table
@strong{Example:}
@smallexample
@c skipped computation of example triangL d2t_singular/triang_lib.doc:51
LIB "triang.lib";
ring rC5 = 0,(e,d,c,b,a),lp;
triangL(stdfglm(cyclic(5)));
@end smallexample
@c ---end content triangL---

@c ------------------- triangLfak -------------
@node triangLfak, triangM, triangL, triang_lib
@subsubsection triangLfak
@cindex triangLfak
@c ---content triangLfak---
Procedure from library @code{triang.lib} (@pxref{triang_lib}).

@table @asis
@item @strong{Usage:}
triangLfak(G); G=ideal

@item @strong{Assume:}
G is the reduced lexicographical Groebner bases of the
zero-dimensional ideal (G), sorted by increasing leading terms.

@item @strong{Return:}
a list of finitely many triangular systems, such that
the union of their varieties equals the variety of (G).

@item @strong{Note:}
Algorithm of Lazard with factorization (see: Lazard, D.: Solving
zero-dimensional algebraic systems, J. Symb. Comp. 13, 117 - 132, 1992).

@item @strong{Remark:}
each polynomial of the triangular systems is factorized.

@end table
@strong{Example:}
@smallexample
@c skipped computation of example triangLfak d2t_singular/triang_lib.doc:88
LIB "triang.lib";
ring rC5 = 0,(e,d,c,b,a),lp;
triangLfak(stdfglm(cyclic(5)));
@end smallexample
@c ---end content triangLfak---

@c ------------------- triangM -------------
@node triangM, triangMH, triangLfak, triang_lib
@subsubsection triangM
@cindex triangM
@c ---content triangM---
Procedure from library @code{triang.lib} (@pxref{triang_lib}).

@table @asis
@item @strong{Usage:}
triangM(G[,i]); G=ideal, i=integer,@*

@item @strong{Assume:}
G is the reduced lexicographical Groebner bases of the
zero-dimensional ideal (G), sorted by increasing leading terms.

@item @strong{Return:}
a list of finitely many triangular systems, such that
the union of their varieties equals the variety of (G).
If i = 2, then each polynomial of the triangular systems
is factorized.

@item @strong{Note:}
Algorithm of Moeller (see: Moeller, H.M.:
@*On decomposing systems of polynomial equations with
@*finitely many solutions, Appl. Algebra Eng. Commun. Comput. 4,
217 - 230, 1993).

@end table
@strong{Example:}
@smallexample
@c skipped computation of example triangM d2t_singular/triang_lib.doc:126
LIB "triang.lib";
ring rC5 = 0,(e,d,c,b,a),lp;
triangM(stdfglm(cyclic(5))); //oder: triangM(stdfglm(cyclic(5)),2);
@end smallexample
@c ---end content triangM---

@c ------------------- triangMH -------------
@node triangMH,, triangM, triang_lib
@subsubsection triangMH
@cindex triangMH
@c ---content triangMH---
Procedure from library @code{triang.lib} (@pxref{triang_lib}).

@table @asis
@item @strong{Usage:}
triangMH(G[,i]); G=ideal, i=integer

@item @strong{Assume:}
G is the reduced lexicographical Groebner bases of the
zero-dimensional ideal (G), sorted by increasing leading terms.

@item @strong{Return:}
a list of finitely many triangular systems, such that
the disjoint union of their varieties equals the variety of (G).
If i = 2, then each polynomial of the triangular systems is factorized.

@item @strong{Note:}
Algorithm of Moeller and Hillebrand (see: Moeller, H.M.:
On decomposing systems of polynomial equations with finitely many
solutions, Appl. Algebra Eng. Commun. Comput. 4, 217 - 230, 1993 and
Hillebrand, D.: Triangulierung nulldimensionaler Ideale -
Implementierung und Vergleich zweier Algorithmen, master thesis,
Universitaet Dortmund, Fachbereich Mathematik, Prof. Dr. H.M. Moeller,
1999).

@end table
@strong{Example:}
@smallexample
@c skipped computation of example triangMH d2t_singular/triang_lib.doc:166
LIB "triang.lib";
ring rC5 = 0,(e,d,c,b,a),lp;
triangMH(stdfglm(cyclic(5)));
@end smallexample
@c ---end content triangMH---


code:
@c ---content LibInfo---
@comment This file was generated by doc2tex.pl from d2t_singular/zeroset_lib.doc
@comment DO NOT EDIT DIRECTLY, BUT EDIT d2t_singular/zeroset_lib.doc INSTEAD
@c library version: (1.7.2.2,2002/02/20)
@c library file: ../Singular/LIB/zeroset.lib
@cindex zeroset.lib
@cindex zeroset_lib
@table @asis
@item @strong{Library:}
zeroset.lib
@item @strong{Purpose:}
      Procedures For Roots and Factorization
@item @strong{Author:}
Thomas Bayer, email: tbayer@@mathematik.uni-kl.de
@*http://wwwmayr.informatik.tu-muenchen.de/personen/bayert/
Current Adress: Institut fuer Informatik, TU Muenchen

@item @strong{Overview:}
Algorithms for finding the zero-set of a zero-dim. ideal in Q(a)[x_1,..,x_n],
Roots and Factorization of univariate polynomials over Q(a)[t]
where a is an algebraic number. Written in the frame of the
diploma thesis (advisor: Prof. Gert-Martin Greuel) 'Computations of moduli
spaces of semiquasihomogeneous singularities and an implementation in Singular'.
This library is meant as a preliminary extension of the functionality
of Singular for univariate factorization of polynomials over simple algebraic
extensions in characteristic 0.
@*Subprocedures with postfix 'Main' require that the ring contains a variable
'a' and no parameters, and the ideal 'mpoly', where 'minpoly' from the
basering is stored.

@end table

@strong{Procedures:}
@menu
* EGCD:: gcd over an algebraic extension field of Q
* Factor:: factorization of f over an algebraic extension field
* Quotient:: quotient q of f w.r.t. g (in f = q*g + remainder)
* Remainder:: remainder of the division of f by g
* Roots:: computes all roots of f in an extension field of Q
* SQFRNorm:: norm of f (f must be squarefree)
* ZeroSet:: zero-set of the 0-dim. ideal I
@end menu
@strong{Auxiliary procedures:}
@menu
* EGCDMain:: gcd over an algebraic extension field of Q
* FactorMain:: factorization of f over an algebraic extension field
* InvertNumberMain:: inverts an element of an algebraic extension field
* QuotientMain:: quotient of f w.r.t. g
* RemainderMain:: remainder of the division of f by g
* RootsMain:: computes all roots of f, might extend the ground field
* SQFRNormMain:: norm of f (f must be squarefree)
* ContainedQ:: f in data ?
* SameQ:: a == b (list a,b)
@end menu
@c ---end content LibInfo---

@c ------------------- EGCD -------------
@node EGCD, Factor,, zeroset_lib
@subsubsection EGCD
@cindex EGCD
@c ---content EGCD---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
EGCD(f, g); where f,g are polynomials

@item @strong{Purpose:}
compute the polynomial gcd of f and g over Q(a)[x]

@item @strong{Return:}
polynomial h s.t. h is a greatest common divisor of f and g (not nec.
monic)

@item @strong{Assume:}
basering = Q(a)[t]

@end table
@strong{Example:}
@smallexample
@c computed example EGCD d2t_singular/zeroset_lib.doc:79
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f =  x4 - 1;
poly g = x2 - 2*a*x - 1;
EGCD(f, g);
@expansion{} (-4a)*x-4
@c end example EGCD d2t_singular/zeroset_lib.doc:79
@end smallexample
@c ---end content EGCD---

@c ------------------- Factor -------------
@node Factor, Quotient, EGCD, zeroset_lib
@subsubsection Factor
@cindex Factor
@c ---content Factor---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
Factor(f); where f is a polynomial

@item @strong{Purpose:}
compute the factorization of the squarefree poly f over Q(a)[t]

@item @strong{Return:}
list with two entries
  @format
  _[1] = factors (monic), first entry is the leading coefficient
  _[2] = multiplicities (not yet implemented)
  @end format

@item @strong{Assume:}
basering must be the univariate polynomial ring over a field, which
is Q or a simple extension of Q given by a minpoly.

@item @strong{Note:}
if basering = Q[t] then this is the built-in @code{factorize}

@end table
@strong{Example:}
@smallexample
@c computed example Factor d2t_singular/zeroset_lib.doc:121
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f =  x4 - 1;
list fl = Factor(f);
fl;
@expansion{} [1]:
@expansion{}    _[1]=1
@expansion{}    _[2]=(40a+60)*x+(40a+60)
@expansion{}    _[3]=(1/65a-29/130)*x+(-1/65a+29/130)
@expansion{}    _[4]=(4a)*x+4
@expansion{}    _[5]=(7/520a+1/130)*x+(1/130a-7/520)
@expansion{} [2]:
@expansion{}    _[1]=1
@expansion{}    _[2]=1
@expansion{}    _[3]=1
@expansion{}    _[4]=1
@expansion{}    _[5]=1
fl[1][1]*fl[1][2]*fl[1][3]*fl[1][4]*fl[1][5] - f;
@expansion{} 0
@c end example Factor d2t_singular/zeroset_lib.doc:121
@end smallexample
@c ---end content Factor---

@c ------------------- Quotient -------------
@node Quotient, Remainder, Factor, zeroset_lib
@subsubsection Quotient
@cindex Quotient
@c ---content Quotient---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
Quotient(f, g); where f,g are polynomials;

@item @strong{Purpose:}
compute the quotient q and remainder r s.t. f = g*q + r, deg(r) < deg(g)

@item @strong{Return:}
list of polynomials
  @format
  _[1] = quotient  q
  _[2] = remainder r
  @end format

@item @strong{Assume:}
basering = Q[x] or Q(a)[x]

@end table
@strong{Example:}
@smallexample
@c computed example Quotient d2t_singular/zeroset_lib.doc:160
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f =  x4 - 2;
poly g = x - a;
list qr = Quotient(f, g);
qr;
@expansion{} [1]:
@expansion{}    x3+(a)*x2-x+(-a)
@expansion{} [2]:
@expansion{}    0
qr[1]*g + qr[2] - f;
@expansion{} 1
@c end example Quotient d2t_singular/zeroset_lib.doc:160
@end smallexample
@c ---end content Quotient---

@c ------------------- Remainder -------------
@node Remainder, Roots, Quotient, zeroset_lib
@subsubsection Remainder
@cindex Remainder
@c ---content Remainder---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
Remainder(f, g); where f,g are polynomials

@item @strong{Purpose:}
compute the remainder of the division of f by g, i.e. a polynomial r
s.t. f = g*q + r, deg(r) < deg(g).

@item @strong{Return:}
poly

@item @strong{Assume:}
basering = Q[x] or Q(a)[x]

@end table
@strong{Example:}
@smallexample
@c computed example Remainder d2t_singular/zeroset_lib.doc:197
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f =  x4 - 1;
poly g = x3 - 1;
Remainder(f, g);
@expansion{} x-1
@c end example Remainder d2t_singular/zeroset_lib.doc:197
@end smallexample
@c ---end content Remainder---

@c ------------------- Roots -------------
@node Roots, SQFRNorm, Remainder, zeroset_lib
@subsubsection Roots
@cindex Roots
@c ---content Roots---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
Roots(f); where f is a polynomial

@item @strong{Purpose:}
compute all roots of f in a finite extension of the ground field
without multiplicities.

@item @strong{Return:}
ring, a polynomial ring over an extension field of the ground field,
containing a list 'roots' and polynomials 'newA' and 'f':
  @format
  - 'roots' is the list of roots of the polynomial f (no multiplicities)
  - if the ground field is Q(a') and the extension field is Q(a), then
    'newA' is the representation of a' in Q(a).
    If the basering contains a parameter 'a' and the minpoly remains unchanged
    then 'newA' = 'a'.
    If the basering does not contain a parameter then 'newA' = 'a' (default).
  - 'f' is the polynomial f in Q(a) (a' being substituted by 'newA')
  @end format

@item @strong{Assume:}
ground field to be Q or a simple extension of Q given by a minpoly

@end table
@strong{Example:}
@smallexample
@c computed example Roots d2t_singular/zeroset_lib.doc:242
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f = x3 - a;
def R1 = Roots(f);
@expansion{}
@expansion{} // 'Roots' created a new ring which contains the list 'roots' and
@expansion{} // the polynomials 'f' and 'newA'
@expansion{} // To access the roots, newA and the new representation of f, type
@expansion{}    def R = Roots(f); setring R; roots; newA; f;
@expansion{}
setring R1;
minpoly;
@expansion{} (a4-a2+1)
newA;
@expansion{} (a3)
f;
@expansion{} x3+(-a3)
roots;
@expansion{} [1]:
@expansion{}    (-a3)
@expansion{} [2]:
@expansion{}    (a3-a)
@expansion{} [3]:
@expansion{}    (a)
map F;
F[1] = roots[1];
F(f);
@expansion{} 0
@c end example Roots d2t_singular/zeroset_lib.doc:242
@end smallexample
@c ---end content Roots---

@c ------------------- SQFRNorm -------------
@node SQFRNorm, ZeroSet, Roots, zeroset_lib
@subsubsection SQFRNorm
@cindex SQFRNorm
@c ---content SQFRNorm---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
SQFRNorm(f); where f is a polynomial

@item @strong{Purpose:}
compute the norm of the squarefree polynomial f in Q(a)[x].

@item @strong{Return:}
list with 3 entries
  @format
  _[1] = squarefree norm of g (poly)
  _[2] = g (= f(x - s*a)) (poly)
  _[3] = s (int)
  @end format

@item @strong{Assume:}
f must be squarefree, basering = Q(a)[x] and minpoly != 0.

@item @strong{Note:}
the norm is an element of Q[x]

@end table
@strong{Example:}
@smallexample
@c computed example SQFRNorm d2t_singular/zeroset_lib.doc:291
LIB "zeroset.lib";
ring R = (0,a), x, lp;
minpoly = a2+1;
poly f =  x4 - 2*x + 1;
SQFRNorm(f);
@expansion{} [1]:
@expansion{}    x8+4*x6-4*x5+8*x4+8*x3-4*x2+8*x+8
@expansion{} [2]:
@expansion{}    x4+(-4a)*x3-6*x2+(4a-2)*x+(2a+2)
@expansion{} [3]:
@expansion{}    1
@c end example SQFRNorm d2t_singular/zeroset_lib.doc:291
@end smallexample
@c ---end content SQFRNorm---

@c ------------------- ZeroSet -------------
@node ZeroSet, EGCDMain, SQFRNorm, zeroset_lib
@subsubsection ZeroSet
@cindex ZeroSet
@c ---content ZeroSet---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
ZeroSet(I [,opt] ); I=ideal, opt=integer

@item @strong{Purpose:}
compute the zero-set of the zero-dim. ideal I, in a finite extension
of the ground field.

@item @strong{Return:}
ring, a polynomial ring over an extension field of the ground field,
containing a list 'zeroset', a polynomial 'newA', and an
ideal 'id':
  @format
  - 'zeroset' is the list of the zeros of the ideal I, each zero is an ideal.
  - if the ground field is Q(a') and the extension field is Q(a), then
    'newA' is the representation of a' in Q(a).
    If the basering contains a parameter 'a' and the minpoly remains unchanged
    then 'newA' = 'a'.
    If the basering does not contain a parameter then 'newA' = 'a' (default).
  - 'id' is the ideal I in Q(a)[x_1,...] (a' substituted by 'newA')
  @end format

@item @strong{Assume:}
dim(I) = 0, and ground field to be Q or a simple extension of Q given
by a minpoly.

@item @strong{Options:}
opt = 0 no primary decomposition (default)
@*opt > 0 primary decomposition

@item @strong{Note:}
If I contains an algebraic number (parameter) then 'I' must be
transformed w.r.t. 'newA' in the new ring.

@end table
@strong{Example:}
@smallexample
@c computed example ZeroSet d2t_singular/zeroset_lib.doc:345
LIB "zeroset.lib";
ring R = (0,a), (x,y,z), lp;
minpoly = a2 + 1;
ideal I = x2 - 1/2, a*z - 1, y - 2;
def T = ZeroSet(I);
@expansion{} 1
setring T;
minpoly;
@expansion{} (4a4+4a2+9)
newA;
@expansion{} (1/3a3+5/6a)
id;
@expansion{} id[1]=(1/3a3+5/6a)*z-1
@expansion{} id[2]=y-2
@expansion{} id[3]=2*x2-1
zeroset;
@expansion{} [1]:
@expansion{}    _[1]=(1/3a3-1/6a)
@expansion{}    _[2]=2
@expansion{}    _[3]=(-1/3a3-5/6a)
@expansion{} [2]:
@expansion{}    _[1]=(-1/3a3+1/6a)
@expansion{}    _[2]=2
@expansion{}    _[3]=(-1/3a3-5/6a)
map F1 = basering, zeroset[1];
map F2 = basering, zeroset[2];
F1(id);
@expansion{} _[1]=0
@expansion{} _[2]=0
@expansion{} _[3]=0
F2(id);
@expansion{} _[1]=0
@expansion{} _[2]=0
@expansion{} _[3]=0
@c end example ZeroSet d2t_singular/zeroset_lib.doc:345
@end smallexample
@c ---end content ZeroSet---

@c ------------------- EGCDMain -------------
@node EGCDMain, FactorMain, ZeroSet, zeroset_lib
@subsubsection EGCDMain
@cindex EGCDMain
@c ---content EGCDMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Purpose:}
compute the polynomial gcd of f and g over Q(a)[x]

@item @strong{Return:}
poly

@item @strong{Assume:}
basering = Q[x,a] and ideal mpoly is defined (it might be 0),
this represents the ring Q(a)[x] together with its minimal polynomial.

@end table
@c ---end content EGCDMain---

@c ------------------- FactorMain -------------
@node FactorMain, InvertNumberMain, EGCDMain, zeroset_lib
@subsubsection FactorMain
@cindex FactorMain
@c ---content FactorMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Purpose:}
compute the factorization of the squarefree poly f over Q(a)[t],
minpoly = p(a).

@item @strong{Return:}
list with 2 entries
  @format
  _[1] = factors, first is a constant
  _[2] = multiplicities (not yet implemented)
  @end format

@item @strong{Assume:}
basering = Q[x,a], representing Q(a)[x]. An ideal mpoly must
be defined, representing the minimal polynomial (it might be 0!).

@end table
@c ---end content FactorMain---

@c ------------------- InvertNumberMain -------------
@node InvertNumberMain, QuotientMain, FactorMain, zeroset_lib
@subsubsection InvertNumberMain
@cindex InvertNumberMain
@c ---content InvertNumberMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
InvertNumberMain(f); where f is a polynomial

@item @strong{Purpose:}
compute 1/f if f is a number in Q(a) i.e., f is represented by a
polynomial in Q[a].

@item @strong{Return:}
poly 1/f

@item @strong{Assume:}
basering = Q[x_1,...,x_n,a], ideal mpoly must be defined and != 0 !

@end table
@c ---end content InvertNumberMain---

@c ------------------- QuotientMain -------------
@node QuotientMain, RemainderMain, InvertNumberMain, zeroset_lib
@subsubsection QuotientMain
@cindex QuotientMain
@c ---content QuotientMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
QuotientMain(f, g); where f,g are polynomials

@item @strong{Purpose:}
compute the quotient q and remainder r s.t. f = g*q + r, deg(r) < deg(g)

@item @strong{Return:}
list of polynomials
  @format
  _[1] = quotient  q
  _[2] = remainder r
  @end format

@item @strong{Assume:}
basering = Q[x,a] and ideal mpoly is defined (it might be 0),
this represents the ring Q(a)[x] together with its minimal polynomial.

@end table
@c ---end content QuotientMain---

@c ------------------- RemainderMain -------------
@node RemainderMain, RootsMain, QuotientMain, zeroset_lib
@subsubsection RemainderMain
@cindex RemainderMain
@c ---content RemainderMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
RemainderMain(f, g); where f,g are polynomials

@item @strong{Purpose:}
compute the remainder r s.t. f = g*q + r, deg(r) < deg(g)

@item @strong{Return:}
poly

@item @strong{Assume:}
basering = Q[x,a] and ideal mpoly is defined (it might be 0),
this represents the ring Q(a)[x] together with its minimal polynomial.

@end table
@c ---end content RemainderMain---

@c ------------------- RootsMain -------------
@node RootsMain, SQFRNormMain, RemainderMain, zeroset_lib
@subsubsection RootsMain
@cindex RootsMain
@c ---content RootsMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
RootsMain(f); where f is a polynomial

@item @strong{Purpose:}
compute all roots of f in a finite extension of the ground field
without multiplicities.

@item @strong{Return:}
list, all entries are polynomials
  @format
  _[1] = roots of f, each entry is a polynomial
  _[2] = 'newA' - if the ground field is Q(a') and the extension field
         is Q(a), then 'newA' is the representation of a' in Q(a)
  _[3] = minpoly of the algebraic extension of the ground field
  @end format

@item @strong{Assume:}
basering = Q[x,a] ideal mpoly must be defined, it might be 0!

@item @strong{Note:}
might change the ideal mpoly !!

@end table
@c ---end content RootsMain---

@c ------------------- SQFRNormMain -------------
@node SQFRNormMain, ContainedQ, RootsMain, zeroset_lib
@subsubsection SQFRNormMain
@cindex SQFRNormMain
@c ---content SQFRNormMain---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
SQFRNorm(f); where f is a polynomial

@item @strong{Purpose:}
compute the norm of the squarefree polynomial f in Q(a)[x].

@item @strong{Return:}
list with 3 entries
  @format
  _[1] = squarefree norm of g (poly)
  _[2] = g (= f(x - s*a)) (poly)
  _[3] = s (int)
  @end format

@item @strong{Assume:}
f must be squarefree, basering = Q[x,a] and ideal mpoly is equal to
'minpoly',this represents the ring Q(a)[x] together with 'minpoly'.

@item @strong{Note:}
the norm is an element of Q[x]

@end table
@c ---end content SQFRNormMain---

@c ------------------- ContainedQ -------------
@node ContainedQ, SameQ, SQFRNormMain, zeroset_lib
@subsubsection ContainedQ
@cindex ContainedQ
@c ---content ContainedQ---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
ContainedQ(data, f [, opt]); data=list; f=any type, opt=integer

@item @strong{Purpose:}
test if f is an element of data.

@item @strong{Return:}
int
@*0 if f not contained in data
@*1 if f contained in data

@item @strong{Options:}
opt = 0 : use '==' for comparing f with elements from data@*
opt = 1 : use @code{SameQ} for comparing f with elements from data

@end table
@c ---end content ContainedQ---

@c ------------------- SameQ -------------
@node SameQ,, ContainedQ, zeroset_lib
@subsubsection SameQ
@cindex SameQ
@c ---content SameQ---
Procedure from library @code{zeroset.lib} (@pxref{zeroset_lib}).

@table @asis
@item @strong{Usage:}
SameQ(a, b); a,b=list/intvec

@item @strong{Purpose:}
test a == b elementwise, i.e., a[i] = b[i].

@item @strong{Return:}
int
@*0 if a != b
@*1 if a == b

@end table
@c ---end content SameQ---