=================================================================== RCS file: /home/cvs/OpenXM_contrib2/asir2000/lib/primdec_mod,v retrieving revision 1.2 retrieving revision 1.6 diff -u -p -r1.2 -r1.6 --- OpenXM_contrib2/asir2000/lib/primdec_mod 2003/04/20 07:33:29 1.2 +++ OpenXM_contrib2/asir2000/lib/primdec_mod 2003/04/21 01:59:35 1.6 @@ -4,10 +4,11 @@ extern T_GRF,T_INT,T_PD,T_MP$ extern BuchbergerMinipoly,PartialDecompByLex,ParallelMinipoly$ extern B_Win,D_Win$ extern COMMONCHECK_SF,CID_SF$ -extern FFF_LOADED_BY_PRIMDEC_MOD$ +extern LIBRARY_GR_LOADED$ +extern LIBRARY_FFF_LOADED$ -if(FFF_LOADED_BY_PRIMDEC_MOD) load("fff"); else ; -FFF_LOADED_BY_PRIMDEC_MOD = 1$ +if(!LIBRARY_FFF_LOADED) load("fff"); else ; LIBRARY_FFF_LOADED = 1$ +if(!LIBRARY_GR_LOADED) load("gr"); else ; LIBRARY_GR_LOADED = 1$ /*==============================================*/ /* prime decomposition of ideals over */ @@ -133,7 +134,7 @@ def frobeniuskernel_main(P,VSet,WSet) XSet=append(VSet,WSet); NewOrder=[[0,length(VSet)],[0,length(WSet)]]; - Char=setmod_ff()[0]; + Char=characteristic_ff(); for (I=0;I by using minimal polynomails.*/ /* separableclosure outputs */ @@ -1315,19 +1335,24 @@ def zeroprimedecomposition(P,TargetVSet,VSet) if ( Sep[1] != 0 ) { - print("The ideal is inseparable. ",2); + if ( dp_gr_print() ) { + print("The ideal is inseparable. ",2); + } CHECK2=checkgeneric2(Sep[2]); } else { - print("The ideal is already separable. ",2); + if ( dp_gr_print() ) { + print("The ideal is already separable. ",2); + } } if ( Sep[1] !=0 && CHECK2 == 1 ) { - print("The separable closure is of generic type. ",2); - print("So, the intermediate ideal is prime or primary. ",2); - + if ( dp_gr_print() ) { + print("The separable closure is of generic type. ",2); + print("So, the intermediate ideal is prime or primary. ",2); + } PDiv=convertdivisor(Sep[0],TargetVSet,VSet,Sep[1]); if ( TargetVSet != VSet ) { @@ -1418,8 +1443,9 @@ def zeroseparableprimedecomposition(P,TargetVSet,VSet) /* Generic=[f, minimal polynomial of f in newt, newt], */ /* where newt (X) is a newly introduced variable. */ - print("We search for a linear sum of variables in generic position. ",2); - + if ( dp_gr_print() ) { + print("We search for a linear sum of variables in generic position. ",2); + } Generic=findgeneric(NewGP,TargetVSet,VSet); X=Generic[2]; /* newly introduced variable */ @@ -1600,14 +1626,17 @@ def separableclosure(CP,TargetVSet,VSet) if ( CHECK == 1 ) { - print("This is already a separable ideal.", 2); + if ( dp_gr_print() ) { + print("This is already a separable ideal.", 2); + } return [CP[0],0]; } - print("This is not a separable ideal, so we make its separable closure.", 2); - + if ( dp_gr_print() ) { + print("This is not a separable ideal, so we make its separable closure.", 2); + } WSet=makecounterpart(TargetVSet); - Char=setmod_ff()[0]; + Char=characteristic_ff(); NewP=CP[0]; EXPVECTOR=newvect(NVSet); @@ -1663,7 +1692,7 @@ def convertdivisor(P,TargetVSet,VSet,ExVector) NVSet=length(TargetVSet); WSet=makecounterpart(TargetVSet); - Char=setmod_ff()[0]; + Char=characteristic_ff(); Ord=0; NewP=P; @@ -1766,7 +1795,9 @@ def findgeneric(P,TargetVSet,VSet) } } #endif - print("Extend the ground field. ",2); + if ( dp_gr_print() ) { + print("Extend the ground field. ",2); + } error(); } @@ -2003,7 +2034,7 @@ def checkseparablepoly(P,V) def pdivide(F,V) { - Char=setmod_ff()[0]; + Char=characteristic_ff(); TestP=P; Deg=ideg(TestP,V); @@ -2051,14 +2082,15 @@ def convertsmallfield(PP,VSet,Ord) { dp_ord(Ord); NVSet=length(VSet); - Char=setmod_ff()[0]; - ExtDeg=deg(setmod_ff()[1],x); + Char=characteristic_ff(); + ExtDeg=extdeg_ff(); - NewV=pg; + NewV=pgpgpgpgpgpgpg; MPP=map(monic_hc,PP,VSet); MPP=map(sfptopsfp,MPP,NewV); - MinPoly=subst(setmod_ff()[1],x,NewV); + DefPoly=setmod_ff()[1]; + MinPoly=subst(DefPoly,var(DefPoly),NewV); XSet=cons(NewV,VSet); Ord1=[[0,1],[Ord,NVSet]]; @@ -2078,7 +2110,7 @@ def checkgaloisorbit(PP,VSet,Ord,Flag) { NPP=length(PP); TmpPP=PP; - ExtDeg=deg(setmod_ff()[1],x); + ExtDeg=extdeg_ff(); ANS=[]; BNS=[];