Changeset 3fd81b in git
- Timestamp:
- Aug 13, 2019, 11:32:55 AM (4 years ago)
- Branches:
- (u'spielwiese', 'd1ba061a762c62d3a25159d8da8b6e17332291fa')
- Children:
- 7a34bdf477bab1bcfbeff902f83eadc50ba41c0f
- Parents:
- b258e2adb78434353acc85388a6c40c626c4b5ee
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/tropical.lib
rb258e2a r3fd81b 340 340 if (nvars(basering)==2) 341 341 { 342 execute("ring BASERING=("+charstr(ALTERRING)+"),(t,x(1)),("+ordstr(ALTERRING)+");");342 ring BASERING = create_ring(ringlist(ALTERRING)[1], "(t,x(1))", "("+ordstr(ALTERRING)+")", "no_minpoly"); 343 343 } 344 344 else … … 470 470 variablen=variablen+var(j); 471 471 } 472 execute("ring GRUNDRING=("+charstr(basering)+"),("+string(variablen)+",t),(dp("+string(nvars(basering)-1)+"),lp(1));");472 ring GRUNDRING = create_ring(ringlist(basering)[1], "("+string(variablen)+",t)", "(dp("+string(nvars(basering)-1)+"),lp(1))", "no_minpoly"); 473 473 ideal variablen; 474 474 for (j=1;j<=nvars(basering)-1;j++) … … 573 573 // from LIFTRING are present, 574 574 // and where also the variables of CUTDOWNRING live 575 execute("ring REPLACEMENTRING=("+charstr(LIFTRING)+"),("+varstr(CUTDOWNRING)+"),dp;");575 ring REPLACEMENTRING = create_ring(ringlist(LIFTRING)[1], "("+varstr(CUTDOWNRING)+")", "dp", "no_minpoly"); 576 576 list repl=imap(CUTDOWNRING,repl); // get the replacement rules 577 577 // from CUTDOWNRING … … 1069 1069 poly mp=minpoly; 1070 1070 def OLDRING=basering; 1071 execute("ring NEWRING=0,("+varstr(basering)+","+parstr(basering)+"),ds;");1071 ring NEWRING = create_ring(0, "("+varstr(basering)+","+parstr(basering)+")", "ds"); 1072 1072 ideal I=imap(OLDRING,mp),imap(OLDRING,f); 1073 1073 } … … 1717 1717 { 1718 1718 string polynomstring=string(f); 1719 execute("ring drawring=(0,"+parstr(basering)+"),("+varstr(basering)+"),dp;");1719 ring drawring = create_ring("(0,"+parstr(basering)+")", "("+varstr(basering)+")", "dp"); 1720 1720 execute("poly f="+polynomstring+";"); 1721 1721 } … … 2652 2652 } 2653 2653 // we want to homogenise the ideal i .... 2654 execute("ring HOMOGRING=("+charstr(basering)+"),(@s,"+string(variablen)+"),dp;");2654 ring HOMOGRING = create_ring(ringlist(basering)[1], "(@s,"+string(variablen)+")", "dp", "no_minpoly"); 2655 2655 ideal i=homog(std(imap(BASERING,i)),@s); 2656 2656 // ... and compute a standard basis with … … 2667 2667 } 2668 2668 intmat O=weightVectorToOrderMatrix(whomog); 2669 execute("ring WEIGHTRING=("+charstr(basering)+"),("+varstr(basering)+"),(M("+string(O)+"));");2669 ring WEIGHTRING = create_ring(ringlist(basering)[1], "("+varstr(basering)+")", "(M("+string(O)+"))", "no_minpoly"); 2670 2670 // map i to the new ring and compute a GB of i, then dehomogenise i, 2671 2671 // so that we can be sure, that the … … 2674 2674 // compute the w-initial ideal with the help of the procedure tInitialForm; 2675 2675 setring BASERING; 2676 execute("ring COMPINIRING=("+charstr(basering)+"),("+string(variablen)+"),dp;");2676 ring COMPINIRING = create_ring(ringlist(basering)[1], "("+string(variablen)+")", "dp", "no_minpoly"); 2677 2677 ideal i=imap(WEIGHTRING,i); 2678 2678 ideal ini; … … 2711 2711 def BASERING=basering; 2712 2712 intmat O=weightVectorToOrderMatrix(w); 2713 execute("ring INITIALRING=("+charstr(BASERING)+"),("+varstr(basering)+"),M("+string(O)+");");2713 ring INITIALRING = create_ring(ringlist(BASERING)[1], "("+varstr(basering)+")", "M("+string(O)+")", "no_minpoly"); 2714 2714 poly f=imap(BASERING,f); 2715 2715 int GRAD=deg(f); … … 2784 2784 def BASERING=basering; 2785 2785 intmat O=weightVectorToOrderMatrix(w); 2786 execute("ring INITIALRING=("+charstr(BASERING)+"),("+varstr(basering)+"),M("+string(O)+");");2786 ring INITIALRING = create_ring(ringlist(BASERING)[1], "("+varstr(basering)+")", "M("+string(O)+")", "no_minpoly"); 2787 2787 ideal i=imap(BASERING,i); 2788 2788 i=std(i); … … 2834 2834 } 2835 2835 def BASERING=basering; 2836 execute("ring PARAMETERRING=("+string(char(basering))+"),("+parstr(basering)+"),ds;");2836 ring PARAMETERRING = create_ring("("+string(char(basering))+")", "("+parstr(basering)+")", "ds"); 2837 2837 poly den=imap(BASERING,den); 2838 2838 poly num=imap(BASERING,num); … … 3493 3493 { 3494 3494 def BASERING=basering; 3495 execute("ring RADRING=("+charstr(basering)+"),(@T,"+varstr(basering)+"),(dp(1),"+ordstr(basering)+");");3495 ring RADRING = create_ring(ringlist(basering)[1], "(@T,"+varstr(basering)+")", "(dp(1),"+ordstr(basering)+")", "no_minpoly"); 3496 3496 ideal I=ideal(imap(BASERING,i))+ideal(1-@T*imap(BASERING,f)); 3497 3497 if (reduce(1,std(I))==0) … … 4218 4218 // return pideal, the initial and the list ergl which tells us 4219 4219 // which variables we replaced by which form 4220 execute("ring BASERINGLESS1=("+charstr(BASERING)+"),("+string(variablen)+",t),(dp("+string(ncols(variablen))+"),lp(1));");4220 ring BASERINGLESS1 = create_ring(ringlist(BASERING)[1], "("+string(variablen)+",t)", "(dp("+string(ncols(variablen))+"),lp(1))", "no_minpoly"); 4221 4221 ideal i=imap(BASERING,pideal); 4222 4222 ideal ini=imap(BASERING,pini); //ideal ini2=tInitialIdeal(i,wvecp,1); … … 4295 4295 } 4296 4296 setring BASERING; 4297 execute("ring BASERINGLESS2=("+charstr(BASERING)+"),("+string(variablen)+",t),(dp("+string(ncols(variablen))+"),lp(1));");4297 ring BASERINGLESS2 = create_ring(ringlist(BASERING)[1], "("+string(variablen)+",t)", "(dp("+string(ncols(variablen))+"),lp(1))", "no_minpoly"); 4298 4298 // using the 0/1-vector which tells us which variables belong 4299 4299 // to the set of smallest entries of wvec … … 4643 4643 if ((numberdeletedvariables>0) and (anzahlvariablen>1)) // if only t remains, 4644 4644 { // all true variables are gone 4645 execute("ring NEURING=("+charstr(basering)+"),("+string(variablen)+"),(dp("+string(size(variablen)-1)+"),lp(1));");4645 ring NEURING = create_ring(ringlist(basering)[1], "("+string(variablen)+")", "(dp("+string(size(variablen)-1)+"),lp(1))", "no_minpoly"); 4646 4646 ideal i=imap(BASERING,i); 4647 4647 ideal gesamt_m=imap(BASERING,gesamt_m); … … 4659 4659 { 4660 4660 // pass to a ring which has variables which are suitable for gfan 4661 execute("ring GFANRING=("+charstr(basering)+"),(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z),dp;");4661 ring GFANRING = create_ring(ringlist(basering)[1], "(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z)", "dp", "no_minpoly"); 4662 4662 ideal phiideal=b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z; 4663 4663 phiideal[nvars(PREGFANRING)]=a; // map t to a … … 4829 4829 else 4830 4830 { 4831 execute("ring PARARing=("+charstr(basering)+"),t,ls;");4831 ring PARARing = create_ring(ringlist(basering)[1], "t", "ls", "no_minpoly"); 4832 4832 } 4833 4833 ideal PARA; // will contain the parametrisation … … 4917 4917 variablen=variablen+var(j); 4918 4918 } 4919 execute("ring INITIALRING=("+charstr(basering)+"),("+string(variablen)+"),dp;");4919 ring INITIALRING = create_ring(ringlist(basering)[1], "("+string(variablen)+")", "dp", "no_minpoly"); 4920 4920 ideal ini=imap(BASERING,ini); 4921 4921 // compute the associated primes of the initialideal … … 5164 5164 else 5165 5165 { 5166 execute("ring TINRING=("+charstr(basering)+"),("+string(variablen)+"),dp;");5166 ring TINRING = create_ring(ringlist(basering)[1], "("+string(variablen)+")", "dp", "no_minpoly"); 5167 5167 } 5168 5168 ideal tin=imap(BASERING,tin); … … 5543 5543 if (size(#)>0) // noAbs was used 5544 5544 { 5545 execute("ring NOQRing=("+string(char(LIFTRing))+"),("+varstr(basering)+","+parstr(LIFTRing)+"),dp;");5545 ring NOQRing = create_ring("("+string(char(LIFTRing))+")", "("+varstr(basering)+","+parstr(LIFTRing)+")", "dp"); 5546 5546 execute("qring TESTRing=std("+#[1]+");"); 5547 5547 ideal i=imap(BASERING,i);
Note: See TracChangeset
for help on using the changeset viewer.