- Timestamp:
- Nov 29, 2021, 7:40:35 PM (2 years ago)
- Branches:
- (u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
- Children:
- 90a388e1fb12d58cc5fbfdc8d3b8aadef7614f29
- Parents:
- 1fb20e9245aa094bd5f9aceb554d08c4af44d72f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/tropical.lib
r1fb20e r081f5e9 1 1 //////////////////////////////////////////////////////////////////////////////// 2 version="version tropical.lib 4.2.1. 1 Jul_2021 ";2 version="version tropical.lib 4.2.1.2 Nov_2021 "; 3 3 category="Tropical Geometry"; 4 4 info=" … … 589 589 // from LIFTRING are present, 590 590 // and where also the variables of CUTDOWNRING live 591 592 593 594 591 list RL=ring_list(LIFTRING); 592 list RL2=ring_list(CUTDOWNRING); 593 RL[2]=RL2[2]; 594 RL[3]=list(list("dp",1:nvars(CUTDOWNRING))); 595 595 ring REPLACEMENTRING = ring(RL); 596 596 list repl=imap(CUTDOWNRING,repl); // get the replacement rules … … 4127 4127 variablen=0; 4128 4128 j2=0; 4129 4129 VARIABLEN=list(); 4130 4130 for(j1=1;j1<=nvars(basering)-1;j1++) 4131 4131 { … … 4141 4141 variablen=variablen+var(j1); // read the set of remaining variables 4142 4142 // (needed to make quotring later) 4143 4143 VARIABLEN=VARIABLEN+list(RL[2][j1]); 4144 4144 } 4145 4145 } 4146 4146 // return pideal, the initial and the list ergl which tells us 4147 4147 // which variables we replaced by which form 4148 4149 4148 RL=ring_list(BASERING); 4149 RL[2]=VARIABLEN+list("t"); 4150 4150 RL[3]=list(list("dp",1:size(VARIABLEN)),list("lp",1:1)); 4151 4151 ring BASERINGLESS1 = ring(RL); … … 4623 4623 if (charstr(basering)!="0") 4624 4624 { 4625 system("sh","gfan_tropicalbasis --mod "+charstr(basering)+" < /tmp/gfaninput > /tmp/gfanbasis"); 4626 system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput"); 4625 if (system("sh","gfan_tropicalbasis --mod "+charstr(basering)+" < /tmp/gfaninput > /tmp/gfanbasis")) 4626 { ERROR("error in gfan_tropicalbasis"); 4627 if (system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput")) 4628 { ERROR("error in gfan_tropicalintersection"); 4627 4629 } 4628 4630 else … … 4630 4632 // system("sh","gfan_tropicalstartingcone < /tmp/gfaninput > /tmp/gfantropstcone"); 4631 4633 // system("sh","gfan_tropicaltraverse < /tmp/gfantropstcone > /tmp/gfanoutput"); 4632 system("sh","gfan_tropicalbasis < /tmp/gfaninput > /tmp/gfanbasis"); 4633 system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput"); 4634 if (system("sh","gfan_tropicalbasis < /tmp/gfaninput > /tmp/gfanbasis")) 4635 { ERROR("error in gfan_tropicalbasis"); 4636 if (system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput")) 4637 { ERROR("error in gfan_tropicalintersection"); 4634 4638 } 4635 4639 string trop=read("/tmp/gfanoutput"); … … 4666 4670 else 4667 4671 { 4668 system("sh","gfan_tropicallifting -n "+string(anzahlvariablen)+" --noMult -c < /tmp/gfaninput > /tmp/gfanoutput"); 4672 if(system("sh","gfan_tropicallifting -n "+string(anzahlvariablen)+" --noMult -c < /tmp/gfaninput > /tmp/gfanoutput")) 4673 { ERROR("error in gfan_tropicallifting"); } 4669 4674 // read the result from gfan and store it to a string, 4670 4675 // which in a later version … … 4756 4761 if (anzahlvariablen+numberdeletedvariables<nvars(basering)) 4757 4762 { 4758 list l2; 4763 list l2; 4759 4764 for (int zz = 1; zz <= (nvars(basering)-anzahlvariablen-numberdeletedvariables); zz++) 4760 4765 { … … 4954 4959 variablen=variablen+var(j); 4955 4960 } 4956 list l3; 4961 list l3; 4957 4962 for (int zz = string(nvars(BASERING)-anzahlvariablen+1); zz <= string(nvars(BASERING)-anzahlvariablen+neuvar); zz++) 4958 4963 { … … 5693 5698 if (charstr(basering)!="0") 5694 5699 { 5695 system("sh","gfan_tropicalbasis --mod "+charstr(basering)+" < /tmp/gfaninput > /tmp/gfanbasis"); 5696 system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput"); 5700 if(system("sh","gfan_tropicalbasis --mod "+charstr(basering)+" < /tmp/gfaninput > /tmp/gfanbasis")) 5701 { ERROR("error in gfan_tropicalbasis"); } 5702 if(system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput")) 5703 { ERROR("error in gfan_tropicalintersection"); } 5697 5704 } 5698 5705 else … … 5700 5707 // system("sh","gfan_tropicalstartingcone < /tmp/gfaninput > /tmp/gfantropstcone"); 5701 5708 // system("sh","gfan_tropicaltraverse < /tmp/gfantropstcone > /tmp/gfanoutput"); 5702 system("sh","gfan_tropicalbasis < /tmp/gfaninput > /tmp/gfanbasis"); 5703 system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput"); 5709 if(system("sh","gfan_tropicalbasis < /tmp/gfaninput > /tmp/gfanbasis")) 5710 { ERROR("error in gfan_tropicalbasis"); } 5711 if(system("sh","gfan_tropicalintersection < /tmp/gfanbasis > /tmp/gfanoutput")) 5712 { ERROR("error in gfan_tropicalintersection"); } 5704 5713 } 5705 5714 string trop=read("/tmp/gfanoutput"); … … 5736 5745 else 5737 5746 { 5738 system("sh","gfan_tropicallifting -n "+string(anzahlvariablen)+" --noMult -c < /tmp/gfaninput > /tmp/gfanoutput"); 5747 if(system("sh","gfan_tropicallifting -n "+string(anzahlvariablen)+" --noMult -c < /tmp/gfaninput > /tmp/gfanoutput")) 5748 { ERROR("error in gfan_tropicallifting"); } 5739 5749 // read the result from gfan and store it to a string, 5740 5750 // which in a later version
Note: See TracChangeset
for help on using the changeset viewer.