Changeset 2eb456 in git for Singular/LIB


Ignore:
Timestamp:
Jan 7, 2001, 3:08:19 AM (23 years ago)
Author:
Gert-Martin Greuel <greuel@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'b4f17ed1d25f93d46dbe29e4b499baecc2fd51bb')
Children:
90611c96f29bf20282ba8567dc61e6aa0533155e
Parents:
96388596a33e9e3d07d36f23dbbc7ee977b0506d
Message:
* GMG: Kosmetik; Beispiel Ausschriften verkleinert


git-svn-id: file:///usr/local/Singular/svn/trunk@5020 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/LIB/algebra.lib

    r963885 r2eb456  
    11///////////////////////////////////////////////////////////////////////////////
    2 version="$Id: algebra.lib,v 1.7 2000-12-22 13:34:59 greuel Exp $";
     2version="$Id: algebra.lib,v 1.8 2001-01-07 02:08:19 greuel Exp $";
    33category="Commutative Algebra";
    44info="
    55LIBRARY:  algebra.lib   Compute with Algbras and Algebra Maps
    66AUTHORS:  Gert-Martin Greuel,     greuel@mathematik.uni-kl.de,
    7           Agnes Eileen Heydtmann, agnes@math.uni-sb.de,
    8           Gerhard Pfister,        pfister@mathematik.uni-kl.de
     7@*        Agnes Eileen Heydtmann, agnes@math.uni-sb.de,
     8@*        Gerhard Pfister,        pfister@mathematik.uni-kl.de
    99
    1010PROCEDURES:
     
    3030
    3131proc algebra_containment (poly p, ideal A, list #)
    32 "USAGE:   algebra_containment(p,A[,k]); p poly, A ideal, k integer
    33          A = A[1],...,A[m] generators of subalgebra of the basering
    34 RETURN:  - k=0 (or if k is not given) an integer:
    35            1    : if p is contained in the subalgebra K[A[1],...,A[m]]
    36            0    : if p is not contained in K[A[1],...,A[m]]
    37          - k=1: a list, say l, of size 2, l[1] integer, l[2] ring, satisfying
     32"USAGE:   algebra_containment(p,A[,k]); p poly, A ideal, k integer.
     33@*       A = A[1],...,A[m] generators of subalgebra of the basering
     34RETURN: 
     35@format
     36         - k=0 (or if k is not given) an integer:
     37           1  : if p is contained in the subalgebra K[A[1],...,A[m]]
     38           0  : if p is not contained in K[A[1],...,A[m]]
     39         - k=1 : a list, say l, of size 2, l[1] integer, l[2] ring, satisfying
    3840           l[1]=1 if p is in the subalgebra K[A[1],...,A[m]] and then the ring
    3941           l[2] contains poly check = h(y(1),...,y(m)) if p=h(A[1],...,A[m])
     
    4244           the nonlinear relation p = h(x,A[1],...,A[m]) where
    4345           x = x(1),...,x(n) denote the variables of the basering
     46@end format
    4447DISPLAY: if k=0 and printlevel >= voice+1 (default) display the poly check
    45 NOTE:    The proc inSubring uses different algorithm which is sometimes faster
     48NOTE:    The proc inSubring uses a different algorithm which is sometimes
     49         faster.
    4650THEORY:  The ideal of algebraic relations of the algebra generators A[1],...,
    4751         A[m] is computed introducing new variables y(i) and the product
     
    9195      dbprint(printlevel-voice+3,"
    9296// 'algebra_containment' created a ring as 2nd element of the list.
    93 // This ring contains the poly check which defines the algebraic relation.
    94 // To access to the ring and see check you must give the ring a name, e.g.:
    95      def S = l[2]; setring S; check;
     97// The ring contains the poly check which defines the algebraic relation.
     98// To access to the ring and see check you must give the ring a name,
     99// e.g.:
     100               def S = l[2]; setring S; check;
    96101        ");
    97102     return(l);
     
    104109   ideal A=x2+y2,z2,x4+y4,1,x2z-1y2z,xyz,x3y-1xy3;
    105110   poly p1=z;
    106    poly p2=x10z3-x8y2z3+2x6y4z3-2x4y6z3+x2y8z3-y10z3+x6z4+3x4y2z4+3x2y4z4+y6z4;
    107    
     111   poly p2=
     112   x10z3-x8y2z3+2x6y4z3-2x4y6z3+x2y8z3-y10z3+x6z4+3x4y2z4+3x2y4z4+y6z4;
    108113   algebra_containment(p1,A);
    109114   algebra_containment(p2,A);
     
    118123proc module_containment(poly p, ideal P, ideal S, list #)
    119124"USAGE:   module_containment(p,P,M[,k]); p poly, P ideal, M ideal, k int
    120          P = P[1],...,P[n] generators of a subalgebra of the basering,
    121          M = M[1],...,M[m] generators of a module over the subalgebra K[P]
     125@*       P = P[1],...,P[n] generators of a subalgebra of the basering,
     126@*       M = M[1],...,M[m] generators of a module over the subalgebra K[P]
    122127ASSUME:  ncols(P) = nvars(basering), the P[i] are algebraically independent
    123 RETURN:  - k=0 (or if k is not given), an integer:
     128RETURN:
     129@format
     130         - k=0 (or if k is not given), an integer:
    124131           1    : if p is contained in the module <M[1],...,M[m]> over K[P]
    125132           0    : if p is not contained in <M[1],...,M[m]>
     
    132139             the nonlinear relation p = h(x,M[1],...,M[m],P[1],...,P[n]) where
    133140             x = x(1),...,x(n) denote the variables of the basering
     141@end format
    134142DISPLAY: the polynomial h(y(1),...,y(m),z(1),...,z(n)) if k=0, resp.
    135          a comment how to access the relation check if k=1,
    136          provided printlevel >= voice+1 (default)
     143         a comment how to access the relation check if k=1, provided
     144         printlevel >= voice+1 (default).
    137145THEORY:  The ideal of algebraic relations of all the generators p1,...,pn,
    138146         s1,...,st given by P and S is computed introducing new variables y(j),
     
    184192      export check;       
    185193      dbprint(printlevel-voice+3,"
    186 // 'module_containment' created a ring as 2nd element of the list.
    187 // This ring contains the poly check which defines the algebraic relation for p
    188 // To access to the ring and see check you must give the ring a name, e.g.:
     194// 'module_containment' created a ring as 2nd element of the list. The
     195// ring contains the poly check which defines the algebraic relation
     196// for p. To access to the ring and see check you must give the ring
     197// a name, e.g.:
    189198     def S = l[2]; setring S; check;
    190199      ");
     
    203212   ideal P = x2+y2,z2,x4+y4;           //algebra generators
    204213   ideal M = 1,x2z-1y2z,xyz,x3y-1xy3;  //module generators
    205    poly p1=x10z3-x8y2z3+2x6y4z3-2x4y6z3+x2y8z3-y10z3+x6z4+3x4y2z4+3x2y4z4+y6z4;
     214   poly p1=
     215   x10z3-x8y2z3+2x6y4z3-2x4y6z3+x2y8z3-y10z3+x6z4+3x4y2z4+3x2y4z4+y6z4;
    206216   module_containment(p1,P,M);
    207217   poly p2=z;
     
    215225proc inSubring(poly p, ideal I)
    216226"USAGE:   inSubring(p,i); p poly, i ideal
    217 RETURN:  a list, say l,of size 2, l[1] integer, l[2] string
     227RETURN:
     228@format
     229         a list l of size 2, l[1] integer, l[2] string
    218230         l[1]=1 iff p is in the subring generated by i=i[1],...,i[k],
    219231                and then l[2] = y(0)-h(y(1),...,y(k)) if p = h(i[1],...,i[k])
     
    221233                and then l[2] = h(y(0),y(1),...,y(k) where p satisfies the
    222234                nonlinear relation h(p,i[1],...,i[k])=0.
     235@end format
    223236NOTE:    the proc algebra_containment tests the same with a different
    224237         algorithm, which is often faster
     
    273286proc algDependent( ideal A, list # )
    274287"USAGE:   algDependent(f[,c]); f ideal (say, f = f1,...,fm), c integer
    275 RETURN:  a list, say l, of size 2, l[1] integer, l[2] ring:
    276          l[1] = 1 if f1,...,fm are algebraic dependent, 0 if not
    277          l[2] is a ring with variables x(1),...,x(n),y(1),...,y(m) if the
    278          basering has n variables. It contains the ideal 'ker', depending
    279          only on the y(i) and generating the algebraic relations between the
    280          f[i], i.e. substituting y(i) by fi yields 0. Of course, ker is
    281          nothing but the kernel of the ring map
     288RETURN:
     289@format
     290         a list l  of size 2, l[1] integer, l[2] ring:
     291         - l[1] = 1 if f1,...,fm are algebraic dependent, 0 if not
     292         - l[2] is a ring with variables x(1),...,x(n),y(1),...,y(m) if the
     293           basering has n variables. It contains the ideal 'ker', depending
     294           only on the y(i) and generating the algebraic relations between the
     295           f[i], i.e. substituting y(i) by fi yields 0. Of course, ker is
     296           nothing but the kernel of the ring map
    282297              K[y(1),...,y(m)] ---> basering,  y(i) --> fi.
    283          Three different algorithms are used depending on c = 1,2,3.
     298@end format
     299NOTE:    Three different algorithms are used depending on c = 1,2,3.
    284300         If c is not given or c=0, a heuristically best method is choosen.
    285301         The basering may be a quotient ring.
     
    374390    export(ker);
    375391    dbprint(printlevel-voice+3,"
    376 // The 2nd element of the list, say l, is a ring with variables x(1),...,x(n),
    377 // y(1),...,y(m) if the basering has n variables and the ideal is f[1],...,f[m]
    378 // It contains the ideal ker only depending on the y(i) and generating the
    379 // relations between the f[i], i.e. substituting y(i) by f[i] yields 0.
    380 // To access to the ring and see ker you must give the ring a name, e.g.:
    381      def S = l[2]; setring S; ker;
     392// The 2nd element of the list l is a ring with variables x(1),...,x(n),
     393// and y(1),...,y(m) if the basering has n variables and if the ideal
     394// is f[1],...,f[m]. The ring contains the ideal ker which depends only
     395// on the y(i) and generates the relations between the f[i].
     396// I.e. substituting y(i) by f[i] yields 0.
     397// To access to the ring and see ker you must give the ring a name,
     398// e.g.:
     399             def S = l[2]; setring S; ker;
    382400        ");
    383401    return (L);
     
    398416proc alg_kernel( map phi, pr, list #)
    399417"USAGE:   alg_kernel(phi,pr[,s,c]); phi map to basering, pr preimage ring,
    400          s string (name of kernel in pr), c integer
    401 RETURN:  a string, the kernel of phi as string
    402          If, moreover, a string s is given, the algorithm creates, in pr,
    403          the kernel of phi with name equal to s.
     418         s string (name of kernel in pr), c integer.
     419RETURN:  a string, the kernel of phi as string.
     420         If, moreover, a string s is given, the algorithm creates, in the
     421         preimage ring pr the kernel of phi with name s.
    404422         Three differnt algorithms are used depending on c = 1,2,3.
    405423         If c is not given or c=0, a heuristically best method is choosen.
    406424         (alogrithm 1 uses the preimage command)
    407 NOTE:    The basering may be a quotient ring.
     425NOTE:    Since the kernel of phi lives in pr, it cannot be returned to the
     426         basering. If s is given, the user has access to it in pr via s.
     427         The basering may be a quotient ring.
    408428EXAMPLE: example alg_kernel; shows an example
    409429"
     
    455475   ring s = 0,(x,y,z,u,v,w),dp;
    456476   ideal I = x-w,u2w+1,yz-v;
    457    map phi = r,I;                   // a map from r to s:
    458    alg_kernel(phi,r);               // a,b,c ---> x-w,u2w+1,yz-v
     477   map phi = r,I;                // a map from r to s:
     478   alg_kernel(phi,r);            // a,b,c ---> x-w,u2w+1,yz-v
    459479 
    460480   ring S = 0,(a,b,c),ds;
     
    462482   qring Q = std(x-y);
    463483   ideal i = x, y, x2-y3;
    464    map phi = S,i;                    // a map to a quotient ring
    465    alg_kernel(phi,S,"ker",3);        // uses algorithm 3
    466    setring S;                        // you have access to kernel in preimage
    467    // setring preimage(phi);      ## wenn realisiert ##
     484   map phi = S,i;                 // a map to a quotient ring
     485   alg_kernel(phi,S,"ker",3);     // uses algorithm 3
     486   setring S;                     // you have access to kernel in preimage
    468487   ker;
    469488}
     
    472491proc is_injective( map phi, pr,list #)
    473492"USAGE:   is_injective(phi[,c,s]); phi map, pr reimage ring, c int, s string
    474 RETURN:  - 1 (type int) if phi is injective, 0 if not (if s is not given).
    475          - If s is given, return a list, say l, of size 2, l[1] int, l[2] ring:
    476            l[1] = 1 if phi is injective, 0 if not
     493RETURN:
     494@format 
     495         - 1 (type int) if phi is injective, 0 if not (if s is not given).
     496         - If s is given, return a list l of size 2, l[1] int, l[2] ring:
     497           l[1] is 1 if phi is injective, 0 if not
    477498           l[2] is a ring with variables x(1),...,x(n),y(1),...,y(m) if the
    478499           basering has n variables and the map m components, it contains the
    479500           ideal 'ker', depending only on the y(i), the kernel of the given map
    480          Three differnt algorithms are used depending on c = 1,2,3.
     501@end format
     502NOTE:    Three differnt algorithms are used depending on c = 1,2,3.
    481503         If c is not given or c=0, a heuristically best method is choosen.
    482 NOTE:    The basering may be a quotient ring. However, if the preimage ring is
     504         The basering may be a quotient ring. However, if the preimage ring is
    483505         a quotient ring, say pr = P/I, consider phi as a map from P and then
    484506         the algorithm returns 1 if the kernel of phi is 0 mod I.
     
    535557    {
    536558      dbprint(printlevel-voice+3,"
    537 // The 2nd element of the list is a ring with variables x(1),...,x(n),y(1),
    538 // ...,y(m) if the basering has n variables and the map is, say, F[1],...,F[m].
     559// The 2nd element of the list is a ring with variables x(1),...,x(n),
     560// y(1),...,y(m) if the basering has n variables and the map is
     561// F[1],...,F[m].
    539562// It contains the ideal ker, the kernel of the given map y(i) --> F[i].
    540 // To access to the ring and see ker you must give the ring a name, e.g.:
     563// To access to the ring and see ker you must give the ring a name,
     564// e.g.:
    541565     def S = l[2]; setring S; ker;
    542566        ");
     
    546570example
    547571{ "EXAMPLE:"; echo = 2;
    548    int p = printlevel; printlevel = 1;
     572   int p = printlevel;
    549573   ring r = 0,(a,b,c),ds;
    550574   ring s = 0,(x,y,z,u,v,w),dp;
     
    559583   def S = l[2]; setring S;
    560584   ker;
    561    
    562    printlevel = p;
    563  }
     585}
    564586///////////////////////////////////////////////////////////////////////////////
    565587
     
    637659         To interprete this for local/mixed orderings, or for quotient rings
    638660         type help is_surjective; and help is_injective;
    639 DISPLAY: Comment if printlevel >= voice-1 (default)
     661DISPLAY: A comment if printlevel >= voice-1 (default)
    640662EXAMPLE: example is_bijective; shows an example
    641663"
     
    731753proc noetherNormal(ideal i, list #)
    732754"USAGE:   noetherNormal(id[,p]);  id ideal, p integer
    733 RETURN:  a list of two ideals, say I,J: I is generated by a subset of the
    734          variables with size(I) = dim(id) and J defines a map (coordinate
    735          change in the basering), such that, if we define  map phi=basering,J;
    736          then k[var(1),...,var(n)]/phi(id) is finite over k[I]
     755RETURN:
     756@format
     757         a list l two ideals, say I,J:
     758         - I is generated by a subset of the variables with size(I) = dim(id)
     759         - J defines a map (coordinate change in the basering), such that:
     760           if we define  map phi=basering,J;
     761           then k[var(1),...,var(n)]/phi(id) is finite over k[I].
    737762         If p is given, 0<=p<=100, a sparse coordinate change with p percent
    738763         of the matrix entries being 0 (default: p=0 i.e. dense)
    739 NOTE:    designed for characteristic 0, works also in char k > 0 if it
    740          terminates, may result in an infinite loop in small characteristic
     764@end format
     765NOTE:    Designed for characteristic 0.It works also in char k > 0 if it
     766         terminates,but may result in an infinite loop in small characteristic
    741767EXAMPLE: example noetherNormal; shows an example
    742768"
     
    838864proc finitenessTest(ideal i,list #)
    839865"USAGE:   finitenessTest(J[,v]); J ideal, v intvec (say v1,...,vr with vi>0)
    840 RETURN:  a list, say l, with l[1] integer, l[2], l[3], l[4] ideals
    841          l[1] = 1 if var(v1),...,var(vr) are in l[2] and 0 else
    842          l[2] (resp. l[3]) contains those variables which occur, (resp. occur
    843          not) as pure power in the leading term of one of the generators of J,
    844          l[4] contains those J[i] for which the leading term is a pure power
    845          of a variable (which is then in l[2])
     866RETURN: 
     867@format
     868         a list l with l[1] integer, l[2], l[3], l[4] ideals
     869         - l[1] = 1 if var(v1),...,var(vr) are in l[2] and 0 else
     870         - l[2] (resp. l[3]) contains those variables which occur,
     871           (resp. occur not) as pure power in the leading term of one of the
     872           generators of J,
     873         - l[4] contains those J[i] for which the leading term is a pure power
     874           of a variable (which is then in l[2])
    846875         (default: v = [1,2,..,nvars(basering)])
     876@end format
    847877THEORY:  If J is a standard basis of an ideal generated by x_1 - f_1(y),...,
    848878         x_n - f_n with y_j ordered lexicographically and y_j >> x_i, then,
    849          if y_i appears as pure power in the leading term of J[k], J[k] defines
     879         if y_i appears as pure power in the leading term of J[k]. J[k] defines
    850880         an integral relation for y_i over the y_(i+1),... and the f's.
    851881         Moreover, in this situation, if l[2] = y_1,...,y_r, then K[y_1,...y_r]
     
    915945proc mapIsFinite(map phi, R, list #)
    916946"USAGE:   mapIsFinite(phi,R[,J]); R a ring, phi: R ---> basering a map
    917          [J an ideal in the basering, J = 0 if not given]
     947         J an ideal in the basering, J = 0 if not given
    918948RETURN:  1 if R ---> basering/J is finite and 0 else
    919949EXAMPLE: example mapIsFinite; shows an example
Note: See TracChangeset for help on using the changeset viewer.