Changeset a2b50c in git


Ignore:
Timestamp:
May 29, 2009, 11:27:20 AM (14 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', '00e2e9c41af3fde1273eb3633f4c0c7c3db2579d')
Children:
30bb07aae70a2a23ab764df7a9aa5063f1dd3698
Parents:
3ea5cee1504eb5dced1aa095461b2eafa2c20a37
Message:
slaplagne:
* new option: "noRed" in proc normalP, to avoid the reduction of
variables when computing the ring structure of the normalization
* bug fixed: the ideal norid in the output was wrong when the input
ideal was already normal.
* bug fixed: computeRing was not working for matrix orderings.


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

Legend:

Unmodified
Added
Removed
  • Singular/LIB/normal.lib

    r3ea5cee ra2b50c  
    11///////////////////////////////////////////////////////////////////////////////
    2 version="$Id: normal.lib,v 1.54 2009-05-25 16:29:04 Singular Exp $";
     2version="$Id: normal.lib,v 1.55 2009-05-29 09:27:20 Singular Exp $";
    33category="Commutative Algebra";
    44info="
     
    228228    {
    229229      result = list(list(ideal(1), poly(1), ROut), 0);
    230     } else {
     230    }
     231    else
     232    {
    231233      result = list(list(ideal(1), poly(1), ROut));
    232234    }
     
    380382      "// Sum of delta for all components: ", deltI;
    381383    }
    382     if(size(prim) > 1){
     384    if(size(prim) > 1)
     385    {
    383386      dbprint(dbg, "// Computing the sum of the intersection multiplicities of the components...");
    384387      int mul = iMult(prim);
     
    386389      {
    387390        deltI = -1;
    388       } else {
     391      }
     392      else
     393      {
    389394        deltI = deltI + mul;
    390395      }
     
    416421  {
    417422    resultNew = list(RL, MG, list(DV, deltI));
    418   } else {
     423  }
     424  else
     425  {
    419426    resultNew = list(RL, MG);
    420427  }
     
    428435    {
    429436      "// 'normal' created a list, say nor, of two elements.";
    430     } else {
     437    }
     438    else
     439    {
    431440      "// 'normal' created a list, say nor, of three elements.";
    432441    }
     
    522531   if(size(Li) > 4)
    523532   {
    524      if(Li[5] == 1)
    525      {
    526        noRed = 1;
    527      }
     533     if(Li[5] == 1) { noRed = 1; }
    528534   }
    529535
     
    776782    setring lastRing;
    777783    //return(lastRing);
    778   } else {
     784  }
     785  else
     786  {
    779787    list RL = ringlist(newRing);
    780788    def lastRing = ring(RL);
     
    43014309  ideal oldU = 1;
    43024310
    4303   if(dbg >= 2)
    4304   {
    4305     "The quotient is"; U;
    4306   }
     4311  if(dbg >= 2) { "The quotient is"; U; }
    43074312
    43084313  // ----------------- Grauer-Remmert criterion check -----------------------
     
    43454350  {
    43464351    step++;
    4347     if(dbg >= 1)
    4348     {
    4349       "";
    4350       "Step ", step, " begins.";
    4351     }
     4352    if(dbg >= 1) { ""; "Step ", step, " begins."; }
    43524353    dbprint(dbg, "Computing the test ideal...");
    43534354
     
    43714372    cJMod = getGenerators(cJ, U, c);
    43724373
    4373     if(dbg >= 2)
    4374     {
    4375       "The test ideal in this step is ";
    4376       cJMod;
    4377     }
     4374    if(dbg >= 2) { "The test ideal in this step is "; cJMod; }
    43784375
    43794376    cJ = cJMod;
     
    44324429  // Ring structure of the new ring
    44334430  def ere = testOut[2];
    4434   if(withDelta){
     4431  if(withDelta)
     4432  {
    44354433    list output = U, c, ere, delt;
    4436   } else {
     4434  }
     4435  else
     4436  {
    44374437    list output = U, c, ere;
    44384438  }
    44394439  return(output);
    4440 
    44414440}
    44424441
     
    44534452    {
    44544453      if(size(newU) == 0)
    4455       {
    4456         newU = U[i];
    4457       }
     4454      { newU = U[i]; }
    44584455      else
    4459       {
    4460         newU = newU, U[i];
    4461       }
     4456      { newU = newU, U[i]; }
    44624457    }
    44634458  }
    44644459  if(size(newU) == 0)
    4465   {
    4466     newU = c;
    4467   }
     4460  { newU = c; }
    44684461  else
    4469   {
    4470     newU = newU, c;
    4471   }
     4462  { newU = newU, c; }
    44724463  return(newU);
    44734464}
     
    45524543        {
    45534544          "New polynoial added:", p;
    4554           if(dbg>4){pause();}
     4545          if(dbg>4) {pause();}
    45554546        }
    45564547        JGr = JGr, p;
     
    46834674  }
    46844675
    4685   if(dbg > 1)
    4686   {
    4687     "Computing the map...";
    4688   }
     4676  if(dbg > 1){ "Computing the map..."; }
    46894677
    46904678  J = f(mapJ);
     
    47084696    else
    47094697    {
    4710       if(degs[i]==0)
    4711       {
    4712         J[i] = c*J[i];
    4713       }
     4698      if(degs[i]==0) { J[i] = c*J[i]; }
    47144699    }
    47154700  }
     
    47604745  ideal U2;
    47614746  poly p;
    4762   for(a = 1; a <= ncols(U1); a++){
     4747  for(a = 1; a <= ncols(U1); a++)
     4748  {
    47634749    p = lift(c1, c2*U1[a])[1,1];
    47644750    U2[a] = p;
     
    47944780    reduction2 = reduce(U1, groebner(U2));
    47954781    reduction2[1];
    4796     if(size(reduction2[1]) > 0){
     4782    if(size(reduction2[1]) > 0)
     4783    {
    47974784      "Something went wrong... (this inclusion should always be satisfied)";
    47984785      ~;
     
    48634850  int d = degSubring(p, @v);
    48644851  poly g = 0;
    4865   for(i = 1; i <= size(p); i++)
     4852  int size_p=size(p);
     4853  for(i = 1; i <= size_p; i++)
    48664854  {
    48674855    e = sum(leadexp(p[i]), @v);
     
    51055093    attrib(id,"isRad",0);
    51065094  }
    5107 
    51085095  return(id);
    51095096}
     
    57305717   return(result);
    57315718}
     5719
    57325720example
    57335721{ "EXAMPLE:";
     
    57795767  int n=size(L);
    57805768  for (int i=1;i<=n;i++)
    5781   {
    5782     if (defined(R(i)))
    5783     {
    5784       string s="Fixed name R("+string(i)+") leads to conflict with existing "
    5785             +"object having this name";
    5786       ERROR(s);
    5787     }
    5788     def R(i)=L[i];
    5789     export R(i);
    5790   }
     5769    {
     5770      if (defined(R(i)))
     5771      {
     5772        string s="Fixed name R("+string(i)+") leads to conflict with existing "
     5773              +"object having this name";
     5774        ERROR(s);
     5775      }
     5776      def R(i)=L[i];
     5777      export R(i);
     5778    }
     5779
    57915780  return();
    57925781}
     
    57985787  list L=primeClosure(ReesAlgebra(I)[1]);
    57995788  L=delete(L,size(L));
    5800 L;
     5789  L;
    58015790  closureRingtower(L);
    58025791  R(1);
     
    60366025{
    60376026  int s = 1;
    6038   while(s*s < n)
    6039   {
    6040     s++;
    6041   }
     6027  while(s*s < n) { s++; }
    60426028  return(s);
    60436029}
Note: See TracChangeset for help on using the changeset viewer.