Index: Singular/LIB/atkins.lib
===================================================================
--- Singular/LIB/atkins.lib	(revision 1625c14e1865ffd016b1b23fc908e7e790e66291)
+++ Singular/LIB/atkins.lib	(revision 3eadab96fecbb57aa75151e22b15ce9249b408b6)
@@ -1,4 +1,4 @@
 ///////////////////////////////////////////////////////////////////////////////
-version="$Id: atkins.lib,v 1.2 2007-01-09 12:42:22 pfister Exp $";
+version="$Id: atkins.lib,v 1.3 2007-07-20 10:02:38 Singular Exp $";
 category="Teaching";
 info="
@@ -14,19 +14,17 @@
 
 PROCEDURES:
-  new(L,D)                     checks if number D already exists in list L
-  bubblesort(L)                sorts elements of the list L
-  disc(N,k)                    generates a list of negative discriminants
-  Cornacchia(d,p)              computes solution (x,y) for x^2+d*y^2=p
-  CornacchiaModified(D,p)      computes solution (x,y) for x^2+|D|*y^2=4p
-  maximum(L)                   computes the maximal number contained in L
-  cmod(x,y)                    computes x mod y
-  sqr(w,k)                     computes the square root of w
-  e(z,k)                       computes exp(z)
-  jot(t,k)                     computes the j-invariant of t
-  round(r)                     rounds r to the nearest number out of Z
-  HilbertClassPolynomial(D,k)  computes the Hilbert Class Polynomial
-  RootsModp(p,P)               computes roots of the polynomial P modulo p
-  w(D)                         computes the number of units in Q(sqr(D))
-  Atkin(N,K,B)                 tries to prove that N is prime
+  newTest(L,D)              checks if number D already exists in list L
+  bubblesort(L)             sorts elements of the list L
+  disc(N,k)                 generates a list of negative discriminants
+  Cornacchia(d,p)           computes solution (x,y) for x^2+d*y^2=p
+  CornacchiaModified(D,p)   computes solution (x,y) for x^2+|D|*y^2=4p
+  maximum(L)                computes the maximal number contained in L
+  expo(z,k)                 computes exp(z)
+  jOft(t,k)                 computes the j-invariant of t
+  round(r)                  rounds r to the nearest number out of Z
+  HilbertClassPoly(D,k)     computes the Hilbert Class Polynomial
+  rootsModp(p,P)            computes roots of the polynomial P modulo p
+  wUnit(D)                  computes the number of units in Q(sqr(D))
+  Atkin(N,K,B)              tries to prove that N is prime
 
 ";
@@ -39,6 +37,6 @@
 ///////////////////////////////////////////////////////////////////////////////
 
-proc new(list L, number D)
-"USAGE: new(L,D);
+proc newTest(list L, number D)
+"USAGE: newTest(L,D);
 RETURN:  1, if D does not already exist in L,
         -1, if D does already exist in L
@@ -63,5 +61,5 @@
     list L=8976,-223456,556,-778,3,-55603,45,766677;
     number D=-55603;
-    new(L,D);
+    newTest(L,D);
 }
 
@@ -118,5 +116,5 @@
     {
       D=-4*a+B;
-      if((D<0)&&((D mod 4)!=2)&&((D mod 4)!=3)&&(absValue(D)<4*N)&&(new(L,D)==1))
+      if((D<0)&&((D mod 4)!=2)&&((D mod 4)!=3)&&(absValue(D)<4*N)&&(newTest(L,D)==1))
       {
         L[size(L)+1]=D;
@@ -342,5 +340,5 @@
 
 
-proc cmod(number x, number y)
+static proc cmod(number x, number y)
 "USAGE: cmod(x,y);
 RETURN: x mod y
@@ -369,5 +367,5 @@
 
 
-proc sqr(number w, int k)
+static proc sqr(number w, int k)
 "USAGE: sqr(w,k);
 RETURN: the square root of w
@@ -397,6 +395,6 @@
 
 
-proc e(number z, int k)
-"USAGE: e(z,k);
+proc expo(number z, int k)
+"USAGE: expo(z,k);
 RETURN: e^z to the order k
 NOTE:   k describes the number of summands being calculated in the exponential power series
@@ -420,11 +418,11 @@
     ring r = (real,30),x,dp;
     number z=40.35;
-    e(z,1000);
-}
-
-
-
-proc jot(number t, int k)
-"USAGE: jot(t,k);
+    expo(z,1000);
+}
+
+
+
+proc jOft(number t, int k)
+"USAGE: jOft(t,k);
 RETURN: the j-invariant of t
 ASSUME: t is a complex number with positive imaginary part
@@ -445,8 +443,8 @@
          {
            tr=tr-round(tr);
-           qr1=e(2*i*pi*tr,10*k);
+           qr1=expo(2*i*pi*tr,10*k);
          }
 
-      qi1=e(-pi*ti,10*k);
+      qi1=expo(-pi*ti,10*k);
       q1=qr1*qi1^2;
       q2=q1^2;
@@ -470,5 +468,5 @@
     ring r = (complex,30,i),x,dp;
     number t=(-7+i*sqr(7,250))/2;
-    jot(t,50);
+    jOft(t,50);
 }
 
@@ -530,7 +528,7 @@
 
 
-proc HilbertClassPolynomial(number D, int k)
-"USAGE: HilbertClassPolynomial(D,k);
-RETURN: the monic polynomial of degree h(D) in Z[X] of which jot((D+sqr(D))/2) is a root
+proc HilbertClassPoly(number D, int k)
+"USAGE: HilbertClassPoly(D,k);
+RETURN: the monic polynomial of degree h(D) in Z[X] of which jOft((D+sqr(D))/2) is a root
 ASSUME: D is a negative discriminant
 NOTE:   k is input for the procedure "jot",
@@ -605,5 +603,5 @@
                              {
                                tau=(-b+i*sqr(absValue(D),5*k))/(2*a);
-                               j=jot(tau,k);
+                               j=jOft(tau,k);
                                if((a==b)||(a^2==t)||(b==0))
                                   {
@@ -677,16 +675,16 @@
     ring r = 0,x,dp;
     number D=-23;
-    HilbertClassPolynomial(D,50);
-}
-
-
-
-proc RootsModp(int p, poly P)
-"USAGE: RootsModp(p,P);
+    HilbertClassPoly(D,50);
+}
+
+
+
+proc rootsModp(int p, poly P)
+"USAGE: rootsModp(p,P);
 RETURN: list of roots of the polynomial P modulo p with p prime
 ASSUME: p>=3
 NOTE:   this algorithm will be called recursively, and it is understood
         that all the operations are done in Z/pZ (excepting sqareRoot(d,p))
-EXAMPLE:example RootsModp; shows an example
+EXAMPLE:example rootsModp; shows an example
 "
 {
@@ -757,5 +755,5 @@
            poly B=imap(R,B);
            poly C=imap(R,C);
-           list l=L+RootsModp(p,B)+RootsModp(p,C);
+           list l=L+rootsModp(p,B)+rootsModp(p,C);
            return(l);
          }
@@ -765,13 +763,13 @@
     ring r = 0,x,dp;
     poly f=x4+2x3-5x2+x;
-    RootsModp(7,f);
+    rootsModp(7,f);
     poly g=x5+112x4+655x3+551x2+1129x+831;
-    RootsModp(1223,g);
-}
-
-
-
-proc w(number D)
-"USAGE: w(D);
+    rootsModp(1223,g);
+}
+
+
+
+proc wUnit(number D)
+"USAGE: wUnit(D);
 RETURN: the number of roots of unity in the quadratic order of discriminant D
 ASSUME: D<0 a discriminant kongruent to 0 or 1 modulo 4
@@ -794,5 +792,5 @@
     ring r = 0,x,dp;
     number D=-3;
-    w(D);
+    wUnit(D);
 }
 
@@ -843,5 +841,5 @@
     number a,b,j,c;                    // characterize E(Z/N(i)Z)
     number g,u;                        // g out of Z/N(i)Z, u=Jacobi(g,N(i))
-    poly T;                            // T=HilbertClassPolynomial(D,K)
+    poly T;                            // T=HilbertClassPoly(D,K)
     matrix M;                          // M contains the coefficients of T
 
@@ -1013,5 +1011,5 @@
         {
           if(printlevel>=1) {"Das Minimalpolynom T von j((D+sqr(D))/2) aus Z[X] fuer D="+string(D)+" wird berechnet.";}
-          T=HilbertClassPolynomial(D,K);
+          T=HilbertClassPoly(D,K);
           if(printlevel>=1) {"T="+string(T);pause();}
 
@@ -1026,5 +1024,5 @@
           if(printlevel>=1) {"Setze T=T mod N("+string(i)+").";"T="+string(T);pause();}
 
-          R=RootsModp(int(N(i)),T);
+          R=rootsModp(int(N(i)),T);
           if(deg(T)>size(R))
           {
@@ -1117,7 +1115,7 @@
       {
         k=k+1;
-        if(k>=w(D))
-        {
-          if(printlevel>=1) {"Da k=w(D)="+string(k)+", ist N("+string(i)+")="+string(N(i))+" nicht prim.";pause();}
+        if(k>=wUnit(D))
+        {
+          if(printlevel>=1) {"Da k=wUnit(D)="+string(k)+", ist N("+string(i)+")="+string(N(i))+" nicht prim.";pause();}
           step=14;
         }
@@ -1220,5 +1218,5 @@
         else
         {
-          if(printlevel>=1) {"N(0)=N="+string(N)+" und daher ist N nicht prim.";pause();}
+          if(printlevel>=1) {"N(0)=N="+string(N)+" und daher ist N nicht prim.";pause(n);}
           return(-1);
         }
@@ -1237,2 +1235,3 @@
     Atkin(10000079,100,2);
 }
+
Index: Singular/LIB/crypto.lib
===================================================================
--- Singular/LIB/crypto.lib	(revision 1625c14e1865ffd016b1b23fc908e7e790e66291)
+++ Singular/LIB/crypto.lib	(revision 3eadab96fecbb57aa75151e22b15ce9249b408b6)
@@ -1,5 +1,5 @@
 //GP, last modified 28.6.06
 ///////////////////////////////////////////////////////////////////////////////
-version="$Id: crypto.lib,v 1.1 2007-01-09 10:31:49 Singular Exp $";
+version="$Id: crypto.lib,v 1.2 2007-07-20 10:02:38 Singular Exp $";
 category="Teaching";
 info="
@@ -2063,2 +2063,3 @@
 
 */
+
Index: Singular/LIB/modstd.lib
===================================================================
--- Singular/LIB/modstd.lib	(revision 1625c14e1865ffd016b1b23fc908e7e790e66291)
+++ Singular/LIB/modstd.lib	(revision 3eadab96fecbb57aa75151e22b15ce9249b408b6)
@@ -1,5 +1,5 @@
 //GP, last modified 23.10.06
 ///////////////////////////////////////////////////////////////////////////////
-version="$Id: modstd.lib,v 1.13 2007-07-04 13:14:43 Singular Exp $";
+version="$Id: modstd.lib,v 1.14 2007-07-20 10:02:38 Singular Exp $";
 category="Commutative Algebra";
 info="
@@ -8,5 +8,4 @@
 @*       G. Pfister      pfister@mathematik.uni-kl.de
 @*       H. Schoenemann  hannes@mathematik.uni-kl.de
-@*       Cindy Magin,    c.magin@web.de
 
 NOTE:
@@ -24,5 +23,4 @@
 modS(I,L);     liftings to Q of standard bases of I mod p for p in L
 primeList(n);  intvec of n primes  <= 2134567879 in decreasing order
-pStd(p,i);     compute a standard basis of i using p-adic methods
 ";
 
@@ -887,2 +885,3 @@
 
 */
+
