Changeset 36b9ef in git for kernel/gr_kstd2.cc
- Timestamp:
- Jul 29, 2008, 3:16:44 PM (15 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'a800fe4b3e9d37a38c5a10cc0ae9dfa0c15a4ee6')
- Children:
- 63774ecd0500a3c894a18af2fea779b41ee11c64
- Parents:
- 342c80d50cde81c223648091d8364e6eeb6dc3f3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/gr_kstd2.cc
r342c80 r36b9ef 2 2 * Computer Algebra System SINGULAR * 3 3 ****************************************/ 4 /* $Id: gr_kstd2.cc,v 1.2 2 2008-07-29 12:38:52Singular Exp $ */4 /* $Id: gr_kstd2.cc,v 1.23 2008-07-29 13:16:44 Singular Exp $ */ 5 5 /* 6 6 * ABSTRACT - Kernel: noncomm. alg. of Buchberger … … 253 253 #endif 254 254 //poly hh = nc_CreateSpoly(strat->S[c_j],(*h).p, currRing); 255 poly hh=c_p; c_p=NULL; 255 if(c_e==-1) 256 c_p = nc_CreateSpoly(pCopy(strat->S[c_j]),pCopy((*h).p), currRing); 257 else 258 c_p=nc_rat_ReduceSpolyNew(pCopy(strat->S[c_j]), 259 pCopy((*h).p),currRing->real_var_start-1,currRing); 256 260 pDelete(&((*h).p)); 257 (*h).p= hh;261 (*h).p=c_p; 258 262 if (!TEST_OPT_INTSTRATEGY) 259 263 { … … 282 286 pass++; 283 287 j=0; 284 c_j=-1; c_e=-2; 288 c_j=-1; c_e=-2; c_p=NULL; 285 289 } 286 290 else … … 302 306 { 303 307 c_e=-1; c_j=j; 304 pDelete(&c_p);305 c_p = nc_CreateSpoly(pCopy(strat->S[c_j]),pCopy((*h).p), currRing);306 308 } 307 309 } … … 321 323 { 322 324 c_e=a_e; c_j=j; 323 pDelete(&c_p);324 325 //c_p = nc_CreateSpoly(pCopy(strat->S[c_j]),pCopy((*h).p), currRing); 325 c_p=nc_rat_ReduceSpolyNew(strat->S[c_j],(*h).p,currRing->real_var_start-1,currRing);326 }327 else if (c_e == a_e)328 {329 //poly cc_pp= nc_CreateSpoly(pCopy(strat->S[j]),pCopy((*h).p), currRing);330 poly cc_pp=nc_rat_ReduceSpolyNew(strat->S[c_j],(*h).p,currRing->real_var_start-1,currRing);331 if (((cc_pp==NULL)&&(c_p!=NULL)) || (pCmp(cc_pp,c_p)==-1))332 {333 assume(pTotaldegree(cc_pp)<=pTotaldegree(c_p));334 c_e=a_e; c_j=j;335 pDelete(&c_p);336 c_p = cc_pp;337 }338 326 } 339 327 /*computes the ecart*/ … … 993 981 if (currRing->real_var_start>0) 994 982 { 995 strat->red=redGrRatGB; 983 int ii=IDELEMS(F)-1; 984 int jj; 985 BOOLEAN is_rat_id=FALSE; 986 for(;ii>=0;ii--) 987 { 988 for(jj=currRing->real_var_start;jj<=currRing->real_var_end;jj++) 989 { 990 if(pGetExp(F->m[ii],jj)>0) { is_rat_id=TRUE; break; } 991 } 992 if (is_rat_id) break; 993 } 994 if (is_rat_id) strat->red=redGrRatGB; 996 995 } 997 996
Note: See TracChangeset
for help on using the changeset viewer.