Changeset 4b278c in git for Singular/LIB/algemodstd.lib
- Timestamp:
- Jan 22, 2015, 1:19:41 PM (9 years ago)
- Branches:
- (u'spielwiese', 'a719bcf0b8dbc648b128303a49777a094b57592c')
- Children:
- 2a5eb8ef50edb654ddd5bbc8e061d551ea44cc74d181eea62bf528f5777c224499fbf26cccac5ff7
- Parents:
- 29b5e9d336d980cc76f0fb6c9d67818a144f3ed3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/algemodstd.lib
r29b5e9d r4b278c 293 293 //////////////////////////////////////////////////////////////////////////////// 294 294 295 static proc check_leadmonom_and_size(list L) 296 { 297 /* 298 * compare the size of ideals in the list and 299 * check the corresponding leading monomials 300 * size(L)>=2 301 */ 302 ideal J=L[1]; 303 int i=size(L); 304 int sc=ncols(J); 305 int j,k; 306 poly g=leadmonom(J[1]); 307 for(j=1;j<=i;j++) 308 { 309 if(ncols(L[j])!=sc) 310 { 311 return(0); 312 } 313 } 314 for(k=2;k<=i;k++) 315 { 316 for(j=1;j<=sc;j++) 317 { 318 if(leadmonom(J[j])!=leadmonom(L[k][j])) 319 { 320 return(0); 321 } 322 } 323 } 324 return(1); 325 } 326 327 //////////////////////////////////////////////////////////////////////////////// 328 295 329 static proc LiftPolyCRT(ideal I) 296 330 { … … 324 358 } 325 359 } 326 // apply CRT for polynomials 327 II =chinrempoly(Lk,LL),f; 360 if(check_leadmonom_and_size(Lk)) 361 { 362 // apply CRT for polynomials 363 II =chinrempoly(Lk,LL),f; 364 } 365 else 366 { 367 II=0; 368 } 328 369 return(II); 329 370 }
Note: See TracChangeset
for help on using the changeset viewer.