Changeset 024d09 in git


Ignore:
Timestamp:
Feb 12, 2020, 12:17:49 PM (4 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'c7af8613769b29c741d6c338945669719f1fc4f8')
Children:
695e99ba40d9a7b4b8d122867c98a893ed7443b9
Parents:
894939ec803ea69f0a5444280deadd71c127156c45ae563436e565c7a868d577dee4e2ca4590f6df
Message:
Merge branch 'execute' of https://github.com/sachinkm308/Sources into sachinkm308-execute
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • Singular/LIB/noether.lib

    r894939e r024d09  
    856856  def r0 = basering;
    857857  int n = nvars(r0)-1;
    858   string s = "ring r1 = ",charstr(r0),",x(0..n),dp;";
    859   execute(s);
     858  list l12;
     859  for (int zz = 0; zz <= n; zz++)
     860  {
     861   l12[zz+1] = "x("+string(zz)+")";
     862  }
     863  ring r1 = create_ring(ringlist(r0)[1], l12, "dp", "no_minpoly");
    860864  ideal i,sbi,I,J,K,L,lsbi1,lsbi2;
    861865  list #;
  • Singular/LIB/primdec.lib

    r894939e r024d09  
    40324032   }
    40334033
    4034    string cR="ring @R="+string(p)+",("+parstr(R)+","+varstr(R)+"),dp;";
    4035    execute(cR);
     4034   ring @R = create_ring(p, "("+parstr(R)+","+varstr(R)+")", "dp");
    40364035   ideal F=imap(R,F);
    40374036
    4038    string nR="ring @S="+string(p)+",(@y(1..m),"+varstr(R)+","+parstr(R)+"),dp;";
    4039    execute(nR);
     4037   list l2; 
     4038   for (int zz = 1; zz <= m; zz++)
     4039   {
     4040    l2[size(l2)+1] = "@y("+string(zz)+")";
     4041   }
     4042   ring @S = create_ring(p, "("+string(l2)+","+varstr(R)+","+parstr(R)+")", "dp");
    40404043
    40414044   ideal G=fetch(@R,F);    //G[i](t(1)^(p^-k),...,t(m)^(p^-k),x(i))=sep(F[i])
     
    40754078
    40764079   string mp="poly @p="+string(minpoly)+";";
    4077    string gnir="ring RH="+string(char(R))+",("+varstr(R)+","+string(par(1))
    4078                 +"),dp;";
    4079    execute(gnir);
     4080   ring RH = create_ring(char(R), "("+varstr(R)+","+string(par(1))+")", "dp");
    40804081   execute(mp);
    40814082   ideal i=imap(R,i);
    40824083   i=i,@p;
    40834084   ideal ra=radical(i);
    4084    gnir="ring RS="+string(char(R))+",("+varstr(RH)
    4085                 +"),(dp("+string(n)+"),lp);";
    4086    execute(gnir);
     4085   ring RS = create_ring(char(R), "("+varstr(RH)+")", "(dp("+string(n)+"),lp)");
    40874086   ideal K=imap(RH,ra);
    40884087   K=std(K);
  • Singular/LIB/qhmoduli.lib

    r894939e r024d09  
    141141      dbprint(dbPrt, " number of equations = " + string(size(sList[1])));
    142142      dbprint(dbPrt, " number of variables = " + string(size(sList[3])));
    143       ringSTR = "ring RME5 = (" + charstr(basering) + "), (Y(1.." + string(size(sList[3])) + ")),dp;";
    144       execute(ringSTR);
     143      list l3;
     144      for (int zz = 1; zz <= size(sList[3]); zz++)
     145      {
     146       l3[zz] = "Y("+string(zz)+")";
     147      }
     148      ring RME5 = create_ring(ringlist(basering)[1], l3, "dp", "no_minpoly");
    145149      execute("minpoly = number(" + @mPoly + ");");
    146150      ideal modid = imap(RME4, newid);
     
    335339
    336340  varSTR = string(maxideal(1));
    337   ringSTR2 = "ring RAAS = ";
     341  ringSTR2 = "";
    338342  if(npars(basering) == 1) {
    339343    parName = parstr(basering);
    340     ringSTR2 = ringSTR2 + "(0, " + parstr(1) + "), ";
     344    ringSTR2 = "(0, " + parstr(1) + ")";
    341345  }
    342346  else {
    343347    parName = "a";
    344     ringSTR2 = ringSTR2 + "0, ";
     348    ringSTR2 = "0";
    345349  }
    346350  offset = 1 + nrStabVars;
    347351  namesSTR = "s(1.." + string(nrStabVars) + "), t(1.." + string(size(B)) + ")";
    348   ringSTR2 = ringSTR2 + "(" + namesSTR + "), lp;";
    349   ringSTR1 = "ring RAAR = (0, " + parName + "," + namesSTR + "), (" + varSTR + "), ls;";  // lp ?
    350 
    351   execute(ringSTR1);
     352
     353  list l4;
     354  for (int zz = 1; zz <= nrStabVars; zz++)
     355  {
     356   l4[zz] = "s("+string(zz)+")";
     357  }
     358  list l5;
     359  for (int zz = 1; zz <= size(B); zz++)
     360  {
     361   l5[zz] = "t("+string(zz)+")";
     362  }
     363  l4 = l4 + l5;
     364  ring RAAR = create_ring("(0, " + parName + "," + string(l4) + ")", "(" + varSTR + ")", "ls");   // lp ?
    352365  export(RAAR);
    353366  ideal upperBasis, stabaction, action, reduceIdeal;
     
    380393    if (pos!=0) { action[pos] = parts[2][i]/parts[1][i];}
    381394  }
    382   execute(ringSTR2);
     395  ring RAAS = create_ring(ringSTR2, l4, "lp");
    383396  execute("minpoly = number(" + @mPoly + ");");
    384397  ideal actionid = imap(RAAR, action);
     
    500513
    501514  varString = "s(1.." + string(nrVars) + ")";
     515  list l6;
     516  for (int zz = 1; zz <= nrVars; zz++)
     517  {
     518   l6[zz] = "s("+string(zz)+")";
     519  }
    502520  if(npars(basering) == 1)
    503521  {
     
    507525
    508526  def RSTB = basering;
     527  string varSTRR = ""+varstr(basering)+"";
    509528  string @mPoly = string(minpoly);
    510   ringSTR = "ring RSTR = " + parString + ", (" + varstr(basering) + ", " + varString + "), dp;";  // dp
    511         ringSTR1 = "ring RSTT = " + parString + ", (" + varString + ", " + varstr(basering) + "), dp;";
    512529
    513530  if(defined(RSTR)) { kill RSTR;}
    514531        if(defined(RSTT)) { kill RSTT;}
    515         execute(ringSTR1);      // this ring is only used for the result, where the variables
     532        ring RSTT = create_ring(parString, "("+string(l6)+","+string(varSTRR)+")", "dp");      // this ring is only used for the result, where the variables
    516533  export(RSTT);           // are s(1..m),t(1..n), as needed for Derksens algorithm (NullCone)
    517534  execute("minpoly = number(" + @mPoly + ");");
    518535
    519   execute(ringSTR);
     536  ring RSTR = create_ring(parString, "("+string(varSTRR)+","+string(l6)+")", "dp");  // dp
    520537  export(RSTR);
    521538  execute("minpoly = number(" + @mPoly + ");");
     
    610627
    611628  varString = "s(1.." + string(sln) + ")";
    612   ringSTR = "ring RSTS = " + parString + ", (" + varString + "), dp;";
    613   execute(ringSTR);
     629  list l7;
     630  for (int zz = 1; zz <= sln; zz++)
     631  {
     632   l7[zz] = "s("+string(zz)+")";
     633  }
     634  ring RSTS = create_ring(parString, l7, "dp");
    614635  execute("minpoly = number(" + @mPoly + ");");
    615636  ideal stabid = std(imap(RSTR, stabid));
     
    10181039  if(nrs > 0)
    10191040  {
    1020     @ringVars = @ringVars + "s(1.." + string(nrs) + "), ";
    1021   }
    1022   @ringVars = @ringVars + "t(1.." + string(nrt) + "))";
    1023   ringSTR = "ring RASR = 0, " + @ringVars + ", dp;";    // new basering
     1041    list l8;
     1042    for (int zz = 1; zz <= nrs; zz++)
     1043    {
     1044     l8[zz] = "s("+string(zz)+")";
     1045    }
     1046    @ringVars = @ringVars + ""+string(l8)+", ";
     1047  }
     1048  list l9;
     1049  for (int zz = 1; zz <= nrt; zz++)
     1050  {
     1051   l9[zz] = "t("+string(zz)+")";
     1052  }
     1053  @ringVars = @ringVars + ""+string(l9)+")";
    10241054
    10251055  // built the "reduction" ring with the reduction ideal
    10261056
    1027   execute(ringSTR);
     1057  ring RASR = create_ring(0, @ringVars, "dp");
    10281058  export(RASR);
    10291059  ideal reduceIdeal, substitution, newSubs;
  • Singular/LIB/standard.lib

    r894939e r024d09  
    27442744
    27452745  /* return ring */
     2746  L;
    27462747  def S = ring(L);
    27472748  if (kill_ring)
  • Singular/ipassign.cc

    r45ae56 r024d09  
    164164        jjMINPOLY_red((idhdl)&(L->m[i]));
    165165      }
     166      break;
    166167    }
    167168    default:
     
    11141115* assign a = b
    11151116*/
    1116 static BOOLEAN jiAssign_1(leftv l, leftv r, BOOLEAN toplevel)
     1117static BOOLEAN jiAssign_1(leftv l, leftv r, BOOLEAN toplevel, BOOLEAN is_qring=FALSE)
    11171118{
    11181119  int rt=r->Typ();
     
    11991200#endif
    12001201    return (bb==NULL) || bb->blackbox_Assign(l,r);
     1202  }
     1203  if ((is_qring)
     1204  &&(lt==RING_CMD)
     1205  &&(rt==RING_CMD))
     1206  {
     1207    Warn("qring .. = <ring>; is misleading in >>%s<<",my_yylinebuf);
    12011208  }
    12021209  int start=0;
     
    18351842  int lt=l->Typ();
    18361843  int rt=NONE;
     1844  int is_qring=FALSE;
    18371845  BOOLEAN b=FALSE;
    18381846  if (l->rtyp==ALIAS_CMD)
     
    18441852  {
    18451853    atKillAll((idhdl)l->data);
     1854    is_qring=hasFlag((idhdl)l->data,FLAG_QRING_DEF);
    18461855    IDFLAG((idhdl)l->data)=0;
    18471856    l->attribute=NULL;
     
    19291938      &&((lt==rt)||(lt!=LIST_CMD)))
    19301939      {
    1931         b=jiAssign_1(l,r,toplevel);
     1940        b=jiAssign_1(l,r,toplevel,is_qring);
    19321941        if (l->rtyp==IDHDL)
    19331942        {
  • Singular/ipid.h

    r45ae56 r024d09  
    102102void *idrecDataInit(int t);
    103103
    104 #define FLAG_STD   0
    105 #define FLAG_TWOSTD  3
    106 #define FLAG_QRING   4
     104#define FLAG_STD       0
     105#define FLAG_TWOSTD    3
     106#define FLAG_QRING     4
     107#define FLAG_QRING_DEF 5
    107108#define hasFlag(A,F) Sy_inset((F),(A)->flag)
    108109#define setFlag(A,F) (A)->flag|=Sy_bit(F)
  • Singular/ipshell.cc

    r45ae56 r024d09  
    11261126{
    11271127  BOOLEAN res=FALSE;
     1128  BOOLEAN is_qring=FALSE;
    11281129  const char *id = name->name;
    11291130
     
    11451146      }
    11461147    }
    1147     if (t==QRING_CMD) t=RING_CMD; // qring is always RING_CMD
     1148    if (t==QRING_CMD)
     1149    {
     1150      t=RING_CMD; // qring is always RING_CMD
     1151      is_qring=TRUE;
     1152    }
    11481153
    11491154    if (TEST_V_ALLWARN
     
    11621167      sy->rtyp=IDHDL;
    11631168      currid=sy->name=IDID((idhdl)sy->data);
     1169      if (is_qring)
     1170      {
     1171        IDFLAG((idhdl)sy->data)=sy->flag=Sy_bit(FLAG_QRING_DEF);
     1172      }
    11641173      // name->name=NULL; /* used in enterid */
    11651174      //sy->e = NULL;
  • kernel/ideals.cc

    r45ae56 r024d09  
    29082908      //    if (mm[i]!=0) Print("x_%d:%d ",i,mm[i]);
    29092909      //PrintLn();
    2910       memset(&strat->P,0,sizeof(strat->P));
     2910      strat->P.Init(currRing);
     2911      //memset(&strat->P,0,sizeof(strat->P));
    29112912      strat->P.tailRing = strat->tailRing;
    29122913      strat->P.p=p;
     
    29592960      //    if (mm[i]!=0) Print("x_%d:%d ",i,mm[i]);
    29602961      //PrintLn();
    2961       memset(&strat->P,0,sizeof(strat->P));
     2962      strat->P.Init(currRing);
     2963      //memset(&strat->P,0,sizeof(strat->P));
    29622964      strat->P.tailRing = strat->tailRing;
    29632965      strat->P.t_p=p;
Note: See TracChangeset for help on using the changeset viewer.