Changeset 3426de2 in git
- Timestamp:
- Sep 6, 2011, 3:08:38 PM (12 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'cdfcdb8287f66bc6070028082cbbc6eff10e609b')
- Children:
- 725e6002e0b07ad1474e14f72296c0c85a47ae4d
- Parents:
- 96f9fdfab406c4f1b69b407c26a25d199352b8c5
- Location:
- factory
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
factory/facFqBivar.cc
r96f9fdf r3426de2 1455 1455 break; 1456 1456 } 1457 if (isReduced (NTLN) )1457 if (isReduced (NTLN) && l > (minBound+1)*2) 1458 1458 { 1459 1459 reduced= true; … … 1514 1514 if (start > l) 1515 1515 l= start; 1516 int startl= l; 1516 1517 int oldL= l/2; 1517 1518 bool reduced= false; … … 1629 1630 break; 1630 1631 } 1631 if (isReduced (NTLN) )1632 if (isReduced (NTLN) && l > startl) 1632 1633 { 1633 1634 reduced= true; … … 1742 1743 break; 1743 1744 } 1744 if (isReduced (NTLN) )1745 if (isReduced (NTLN) && l > (minBound+1)*2) 1745 1746 { 1746 1747 reduced= true; … … 1855 1856 break; 1856 1857 } 1857 if (isReduced (NTLN) )1858 if (isReduced (NTLN) && l > (minBound+1)*2) 1858 1859 { 1859 1860 reduced= true; -
factory/facHensel.cc
r96f9fdf r3426de2 1380 1380 return 0; 1381 1381 1382 Variable v; 1382 1383 CanonicalForm Q; 1383 1384 if (degB <= 1 || CFFactory::gettype() == GaloisFieldDomain) … … 1388 1389 else 1389 1390 { 1390 CanonicalForm R= reverse (A, degA); 1391 CanonicalForm revB= reverse (B, degB); 1392 revB= newtonInverse (revB, m + 1, M); 1393 Q= mulMod2 (R, revB, M); 1394 Q= mod (Q, power (x, m + 1)); 1395 Q= reverse (Q, m); 1391 if (hasFirstAlgVar (A, v) || hasFirstAlgVar (B, v)) 1392 { 1393 CanonicalForm R= reverse (A, degA); 1394 CanonicalForm revB= reverse (B, degB); 1395 revB= newtonInverse (revB, m + 1, M); 1396 Q= mulMod2 (R, revB, M); 1397 Q= mod (Q, power (x, m + 1)); 1398 Q= reverse (Q, m); 1399 } 1400 else 1401 { 1402 zz_pX mipo= convertFacCF2NTLzzpX (M); 1403 Variable y= Variable (2); 1404 zz_pEX NTLA, NTLB; 1405 NTLA= convertFacCF2NTLzz_pEX (swapvar (A, x, y), mipo); 1406 NTLB= convertFacCF2NTLzz_pEX (swapvar (B, x, y), mipo); 1407 div (NTLA, NTLA, NTLB); 1408 Q= convertNTLzz_pEX2CF (NTLA, x, y); 1409 } 1396 1410 } 1397 1411 … … 1417 1431 } 1418 1432 1433 Variable v; 1419 1434 if (degB <= 1 || CFFactory::gettype() == GaloisFieldDomain) 1420 1435 { … … 1423 1438 else 1424 1439 { 1425 R= reverse (A, degA); 1426 1427 CanonicalForm revB= reverse (B, degB); 1428 revB= newtonInverse (revB, m + 1, M); 1429 Q= mulMod2 (R, revB, M); 1430 1431 Q= mod (Q, power (x, m + 1)); 1432 Q= reverse (Q, m); 1433 1434 R= A - mulMod2 (Q, B, M); 1440 if (hasFirstAlgVar (A, v) || hasFirstAlgVar (B, v)) 1441 { 1442 R= reverse (A, degA); 1443 1444 CanonicalForm revB= reverse (B, degB); 1445 revB= newtonInverse (revB, m + 1, M); 1446 Q= mulMod2 (R, revB, M); 1447 1448 Q= mod (Q, power (x, m + 1)); 1449 Q= reverse (Q, m); 1450 1451 R= A - mulMod2 (Q, B, M); 1452 } 1453 else 1454 { 1455 zz_pX mipo= convertFacCF2NTLzzpX (M); 1456 Variable y= Variable (2); 1457 zz_pEX NTLA, NTLB; 1458 NTLA= convertFacCF2NTLzz_pEX (swapvar (A, x, y), mipo); 1459 NTLB= convertFacCF2NTLzz_pEX (swapvar (B, x, y), mipo); 1460 zz_pEX NTLQ, NTLR; 1461 DivRem (NTLQ, NTLR, NTLA, NTLB); 1462 Q= convertNTLzz_pEX2CF (NTLQ, x, y); 1463 R= convertNTLzz_pEX2CF (NTLR, x, y); 1464 } 1435 1465 } 1436 1466 }
Note: See TracChangeset
for help on using the changeset viewer.