Changeset a973339 in git
- Timestamp:
- Dec 12, 2013, 1:55:10 PM (9 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'f875bbaccd0831e36aaed09ff6adeb3eb45aeb94')
- Children:
- 53beb57b7f12a428116cb0a7b7bf24460400c5fb
- Parents:
- f1babfbabc0fc2906b36df32051eaaf09673dc6f
- Location:
- kernel
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/kstd1.cc
rf1babf ra973339 2969 2969 2970 2970 // enter into S, L, and T 2971 //if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 2971 if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 2972 { 2972 2973 enterT(strat->P, strat); 2973 // posInS only depends on the leading term 2974 strat->enterS(strat->P, pos, strat, strat->tl); 2975 2974 // posInS only depends on the leading term 2975 strat->enterS(strat->P, pos, strat, strat->tl); 2976 2977 if (pos<strat->sl) 2978 { 2979 need_retry++; 2980 // move all "larger" elements fromS to L 2981 // remove them from T 2982 int ii=pos+1; 2983 for(;ii<=strat->sl;ii++) 2984 { 2985 LObject h; 2986 memset(&h,0,sizeof(h)); 2987 h.tailRing=strat->tailRing; 2988 h.p=strat->S[ii]; strat->S[ii]=NULL; 2989 strat->initEcart(&h); 2990 h.sev=strat->sevS[ii]; 2991 int jj=strat->tl; 2992 while (jj>=0) 2993 { 2994 if (strat->T[jj].p==h.p) 2995 { 2996 strat->T[jj].p=NULL; 2997 if (jj<strat->tl) 2998 { 2999 memmove(&(strat->T[jj]),&(strat->T[jj+1]), 3000 (strat->tl-jj)*sizeof(strat->T[jj])); 3001 memmove(&(strat->sevT[jj]),&(strat->sevT[jj+1]), 3002 (strat->tl-jj)*sizeof(strat->sevT[jj])); 3003 } 3004 strat->tl--; 3005 break; 3006 } 3007 jj--; 3008 } 3009 int lpos=strat->posInL(strat->L,strat->Ll,&h,strat); 3010 enterL(&strat->L,&strat->Ll,&strat->Lmax,h,lpos); 3011 #ifdef KDEBUG 3012 if (TEST_OPT_DEBUG) 3013 { 3014 Print("move S[%d] -> L[%d]: ",ii,pos); 3015 p_wrp(h.p,currRing, strat->tailRing); 3016 PrintLn(); 3017 } 3018 #endif 3019 } 3020 if (strat->fromQ!=NULL) 3021 { 3022 for(ii=pos+1;ii<=strat->sl;ii++) strat->fromQ[ii]=0; 3023 } 3024 strat->sl=pos; 3025 } 3026 } 3027 else 3028 { 3029 // clean P 3030 } 2976 3031 if (strat->P.lcm!=NULL) 2977 3032 #ifdef HAVE_RINGS … … 2980 3035 pLmFree(strat->P.lcm); 2981 3036 #endif 2982 if (pos<strat->sl)2983 {2984 need_retry++;2985 // move all "larger" elements fromS to L2986 // remove them from T2987 int ii=pos+1;2988 for(;ii<=strat->sl;ii++)2989 {2990 LObject h;2991 memset(&h,0,sizeof(h));2992 h.tailRing=strat->tailRing;2993 h.p=strat->S[ii]; strat->S[ii]=NULL;2994 strat->initEcart(&h);2995 h.sev=strat->sevS[ii];2996 int jj=strat->tl;2997 while (jj>=0)2998 {2999 if (strat->T[jj].p==h.p)3000 {3001 strat->T[jj].p=NULL;3002 if (jj<strat->tl)3003 {3004 memmove(&(strat->T[jj]),&(strat->T[jj+1]),3005 (strat->tl-jj)*sizeof(strat->T[jj]));3006 memmove(&(strat->sevT[jj]),&(strat->sevT[jj+1]),3007 (strat->tl-jj)*sizeof(strat->sevT[jj]));3008 }3009 strat->tl--;3010 break;3011 }3012 jj--;3013 }3014 int lpos=strat->posInL(strat->L,strat->Ll,&h,strat);3015 enterL(&strat->L,&strat->Ll,&strat->Lmax,h,lpos);3016 #ifdef KDEBUG3017 if (TEST_OPT_DEBUG)3018 {3019 Print("move S[%d] -> L[%d]: ",ii,pos);3020 p_wrp(h.p,currRing, strat->tailRing);3021 PrintLn();3022 }3023 #endif3024 }3025 if (strat->fromQ!=NULL)3026 {3027 for(ii=pos+1;ii<=strat->sl;ii++) strat->fromQ[ii]=0;3028 }3029 strat->sl=pos;3030 }3031 3037 } 3032 3038 -
kernel/kstd2.cc
rf1babf ra973339 1390 1390 1391 1391 // enter into S, L, and T 1392 //if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 1392 if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 1393 { 1393 1394 enterT(strat->P, strat); 1394 1395 #ifdef HAVE_RINGS 1395 if (rField_is_Ring(currRing))1396 superenterpairs(strat->P.p,strat->sl,strat->P.ecart,pos,strat, strat->tl);1397 else1398 #endif 1399 enterpairs(strat->P.p,strat->sl,strat->P.ecart,pos,strat, strat->tl);1400 // posInS only depends on the leading term1401 strat->enterS(strat->P, pos, strat, strat->tl);1396 if (rField_is_Ring(currRing)) 1397 superenterpairs(strat->P.p,strat->sl,strat->P.ecart,pos,strat, strat->tl); 1398 else 1399 #endif 1400 enterpairs(strat->P.p,strat->sl,strat->P.ecart,pos,strat, strat->tl); 1401 // posInS only depends on the leading term 1402 strat->enterS(strat->P, pos, strat, strat->tl); 1402 1403 #if 0 1403 int pl=pLength(strat->P.p); 1404 if (pl==1) 1405 { 1406 //if (TEST_OPT_PROT) 1407 //PrintS("<1>"); 1408 } 1409 else if (pl==2) 1410 { 1411 //if (TEST_OPT_PROT) 1412 //PrintS("<2>"); 1413 } 1414 #endif 1404 int pl=pLength(strat->P.p); 1405 if (pl==1) 1406 { 1407 //if (TEST_OPT_PROT) 1408 //PrintS("<1>"); 1409 } 1410 else if (pl==2) 1411 { 1412 //if (TEST_OPT_PROT) 1413 //PrintS("<2>"); 1414 } 1415 #endif 1416 } 1415 1417 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 1416 1418 // Print("[%d]",hilbeledeg); … … 2449 2451 // enter into S, L, and T 2450 2452 // here we need to recompute new signatures, but those are trivial ones 2451 //if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 2452 enterT(strat->P, strat); 2453 // posInS only depends on the leading term 2454 strat->enterS(strat->P, pos, strat, strat->tl); 2453 if ((!TEST_OPT_IDLIFT) || (pGetComp(strat->P.p) <= strat->syzComp)) 2454 { 2455 enterT(strat->P, strat); 2456 // posInS only depends on the leading term 2457 strat->enterS(strat->P, pos, strat, strat->tl); 2455 2458 //#if 1 2456 2459 #ifdef DEBUGF5 2457 Print("ELEMENT ADDED TO GCURR DURING INTERRED: "); 2458 pWrite(pHead(strat->S[strat->sl])); 2459 pWrite(strat->sig[strat->sl]); 2460 #endif 2461 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 2460 Print("ELEMENT ADDED TO GCURR DURING INTERRED: "); 2461 pWrite(pHead(strat->S[strat->sl])); 2462 pWrite(strat->sig[strat->sl]); 2463 #endif 2464 if (hilb!=NULL) khCheck(Q,w,hilb,hilbeledeg,hilbcount,strat); 2465 } 2462 2466 // Print("[%d]",hilbeledeg); 2463 2467 if (strat->P.lcm!=NULL)
Note: See TracChangeset
for help on using the changeset viewer.