Changeset 94d062 in git
- Timestamp:
- Apr 14, 1998, 5:29:46 PM (25 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'a800fe4b3e9d37a38c5a10cc0ae9dfa0c15a4ee6')
- Children:
- 8677912280afed4016cd16f860024d5d2390f1e7
- Parents:
- b1b0b32e97337832321183b3829223506e117514
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/fglm.cc
rb1b0b3 r94d062 1 1 // emacs edit mode for this file is -*- C++ -*- 2 // $Id: fglm.cc,v 1.1 2 1998-01-23 14:20:38 obachmanExp $2 // $Id: fglm.cc,v 1.13 1998-04-14 15:29:46 Singular Exp $ 3 3 4 4 /**************************************** … … 6 6 ****************************************/ 7 7 /* 8 * ABSTRACT - The FGLM-Algorithm 8 * ABSTRACT - The FGLM-Algorithm plus extension 9 9 * Calculate a reduced groebner basis for one ordering, given a 10 10 * reduced groebner basis for another ordering. … … 13 13 * if the input is homogeneous ( then fglmhom.cc is used. Yet 14 14 * not implemented ). 15 * The extension (finduni) finds minimal univariate Polynomials 16 * lying in a 0-dimensional ideal. 15 17 */ 16 18 … … 201 203 } 202 204 203 // 204 // 205 // 206 // 207 // 208 // 209 // 210 // 205 // Checks if the ideal "theIdeal" is zero-dimensional and minimal. It does 206 // not check, if it is reduced. 207 // returns FglmOk if we can use theIdeal for CalculateFunctionals (this 208 // function reports an error if theIdeal is not reduced, 209 // so this need not to be tested here) 210 // FglmNotReduced if theIdeal is not minimal 211 // FglmNotZeroDim if it is not zero-dimensional 212 // FglmHasOne if 1 belongs to theIdeal 211 213 FglmState 212 214 fglmIdealcheck( const ideal theIdeal ) … … 239 241 } 240 242 241 // the main function for the fglm-Algorithm. 242 // Checks the input-data, calls CalculateFunctionals, handles change 243 // of ring-vars and finaly calls GroebnerViaFunctionals. 244 // returns the new groebnerbasis or 0 if an error occoured. 243 // The main function for the fglm-Algorithm. 244 // Checks the input-data, and calls fglmzero (see fglmzero.cc). 245 // Returns the new groebnerbasis or 0 if an error occoured. 245 246 BOOLEAN 246 247 fglmProc( leftv result, leftv first, leftv second ) … … 316 317 } 317 318 319 // The main function for finduni(). 320 // Checks the input-data, and calls FindUnivariateWrapper (see fglmzero.cc). 321 // Returns an ideal containing the univariate Polynomials or 0 if an error 322 // has occoured. 318 323 BOOLEAN 319 324 findUniProc( leftv result, leftv first ) 320 325 { 321 326 ideal sourceIdeal; 322 ideal destIdeal; 327 ideal destIdeal = NULL; 328 FglmState state; 323 329 324 330 idhdl sourceIdealHdl = (idhdl)first->data; 325 331 sourceIdeal= IDIDEAL(sourceIdealHdl); 326 327 destIdeal= FindUnivariateWrapper( sourceIdeal ); 332 333 assumeStdFlag( first ); 334 state= fglmIdealcheck( sourceIdeal ); 335 if ( state == FglmOk ) { 336 if ( FindUnivariateWrapper( sourceIdeal, destIdeal ) == FALSE ) 337 state = FglmNotReduced; 338 } 339 switch (state) { 340 case FglmOk: 341 break; 342 case FglmHasOne: 343 destIdeal= idInit(1,1); 344 (destIdeal->m)[0]= pOne(); 345 state= FglmOk; 346 break; 347 case FglmNotZeroDim: 348 Werror( "The ideal %s has to be 0-dimensional", first->Name() ); 349 destIdeal= idInit(0,0); 350 break; 351 case FglmNotReduced: 352 Werror( "The ideal %s has to be reduced", first->Name() ); 353 destIdeal= idInit(0,0); 354 break; 355 default: 356 destIdeal= idInit(1,1); 357 } 328 358 329 359 result->rtyp = IDEAL_CMD; 330 360 result->data= (void *)destIdeal; 331 361 332 362 return FALSE; 333 363 } 334 364 #endif
Note: See TracChangeset
for help on using the changeset viewer.