Changeset dabe365 in git for kernel/shiftgb.cc
- Timestamp:
- Aug 7, 2008, 8:08:37 PM (15 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'a800fe4b3e9d37a38c5a10cc0ae9dfa0c15a4ee6')
- Children:
- 5d97859f88aa52d68bbca5a456cd859d9492231a
- Parents:
- 35ee9b7a58e79afeef7aebc85bd49c899533d499
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/shiftgb.cc
r35ee9b7 rdabe365 2 2 * Computer Algebra System SINGULAR * 3 3 ****************************************/ 4 /* $Id: shiftgb.cc,v 1. 9 2008-07-26 14:28:03 motsakExp $ */4 /* $Id: shiftgb.cc,v 1.10 2008-08-07 18:08:37 levandov Exp $ */ 5 5 /* 6 6 * ABSTRACT: kernel: utils for shift GB and free GB … … 380 380 { 381 381 /* investigate only the leading monomial of p in currRing */ 382 if ( pIsConstant(p) ) return(1); 382 383 if (lV <= 0) return(0); 383 384 /* returns 1 iff p is in V */ … … 428 429 } 429 430 431 int poly_isInV(poly p, int lV) 432 { 433 /* tests whether the whole polynomial p in in V */ 434 poly q = p; 435 while (q!=NULL) 436 { 437 if ( !isInV(q,lV) ) 438 { 439 return(0); 440 } 441 q = pNext(q); 442 } 443 return(1); 444 } 445 446 int ideal_isInV(ideal I, int lV) 447 { 448 /* tests whether each polynomial of an ideal I lies in in V */ 449 int i; 450 int s = IDELEMS(I)-1; 451 for(i = 0; i <= s; i++) 452 { 453 if ( !poly_isInV(I->m[i],lV) ) 454 { 455 return(0); 456 } 457 } 458 return(1); 459 } 460 461 430 462 int itoInsert(poly p, int uptodeg, int lV, const ring r) 431 463 {
Note: See TracChangeset
for help on using the changeset viewer.