Changeset 836e389 in git
- Timestamp:
- Jan 9, 2009, 4:19:26 PM (14 years ago)
- Branches:
- (u'spielwiese', '91fdef05f09f54b8d58d92a472e9c4a43aa4656f')
- Children:
- 360507e4cf4ba3531cb19770b86e6a337f9d439a
- Parents:
- 35eef23de304e5ae3c4f51aadb5be842bb3f3c8a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/teachstd.lib
r35eef23 r836e389 2 2 //GMG, last modified 28.9.01 3 3 /////////////////////////////////////////////////////////////////////////////// 4 version="$Id: teachstd.lib,v 1. 6 2006-07-25 12:02:44 SingularExp $";4 version="$Id: teachstd.lib,v 1.7 2009-01-09 15:19:26 motsak Exp $"; 5 5 category="Teaching"; 6 6 info=" … … 191 191 int e; 192 192 poly o = monomialLcm(f,g); 193 193 194 if( o == 0) //can only happen, if vectors f and g involve 194 195 { //different module components … … 197 198 } 198 199 199 poly m=leadmonomial(f); //compute the leading monomial as poly 200 poly n=leadmonomial(g); 200 poly m=(o/leadmonomial(f)); //compute the leading monomial as poly 201 poly n=(o/leadmonomial(g)); 202 203 f = m * f; 204 g = n * g; // now they have the same LM! 201 205 202 206 if (#[1]==0) //the asymmetric s-poly 203 207 { 204 def sp = (o/m)*f - (leadcoef(f)/leadcoef(g))*(o/n)*g;208 def sp = f - (leadcoef(f)/leadcoef(g))*g; 205 209 } 206 210 else //the symmetric s-poly, avoiding division 207 211 { 208 def sp = leadcoef(g)* (o/m)*f - leadcoef(f)*(o/n)*g;212 def sp = leadcoef(g)*f - leadcoef(f)*g; 209 213 } 210 214 return(sp); … … 413 417 " 414 418 { 419 if( defined(@@@NOPC) && (@@@NOPC == 1) ) 420 { 421 return(0); 422 }; 423 415 424 if(typeof(f)=="poly") //product criterion for polynomials 416 425 {
Note: See TracChangeset
for help on using the changeset viewer.