Changeset 6e12a4 in git
- Timestamp:
- Jun 17, 2020, 6:16:48 PM (3 years ago)
- Branches:
- (u'spielwiese', '8d54773d6c9e2f1d2593a28bc68b7eeab54ed529')
- Children:
- cac0f8a0c0c0b22b71b76c3b44841f5cc1fec229
- Parents:
- ed6f2bb0876535189130e32d71be46f776012a36
- git-author:
- Hans Schoenemann <hannes@mathematik.uni-kl.de>2020-06-17 18:16:48+02:00
- git-committer:
- Hans Schoenemann <hannes@mathematik.uni-kl.de>2020-06-17 18:17:49+02:00
- Location:
- factory
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
factory/FLINTconvert.cc
red6f2b r6e12a4 291 291 return result; 292 292 } 293 294 #if __FLINT_RELEASE >= 20503 295 CFFList 296 convertFLINTfmpz_poly_factor2FacCFFList ( 297 const fmpz_poly_factor_t fac, ///< [in] a nmod_poly_factor_t 298 const Variable& x ///< [in] variable the result should 299 ///< have 300 ) 301 302 { 303 CFFList result; 304 long i; 305 306 for (i = 0; i < fac->num; i++) 307 result.append (CFFactor (convertFmpz_poly_t2FacCF ( 308 (fmpz_poly_t &)fac->p[i],x), 309 fac->exp[i])); 310 return result; 311 } 312 #endif 293 313 294 314 #if __FLINT_RELEASE >= 20400 -
factory/FLINTconvert.h
red6f2b r6e12a4 120 120 ); 121 121 122 /// conversion of a FLINT factorization over Z to a CFFList 123 CFFList 124 convertFLINTfmpz_poly_factor2FacCFFList ( 125 const fmpz_poly_factor_t fac, ///< [in] a fmpz_poly_factor_t 126 const Variable& x ///< [in] variable the result should 127 ///< have 128 ); 129 122 130 /// conversion of a factory univariate poly over Z to a FLINT poly over 123 131 /// Z/p (for non word size p) -
factory/cf_factor.cc
red6f2b r6e12a4 536 536 } 537 537 } 538 else 538 else // char 0 539 539 { 540 540 bool on_rational = isOn(SW_RATIONAL); … … 575 575 } 576 576 } 577 #else 578 factoryError ("univariate factorization over Z depends on NTL(missing)"); 577 if(isOn(SW_USE_NTL_SORT)) F.sort(cmpCF); 578 return F; 579 #endif 580 #if defined(HAVE_FLINT) && (__FLINT_RELEASE>=20504) 581 // use FLINT 582 fmpz_poly_t f1; 583 convertFacCF2Fmpz_poly_t (f1, f); 584 fmpz_poly_factor_t result; 585 fmpz_poly_factor_init (result); 586 fmpz_poly_factor_zassenhaus(result, f1); 587 F= convertFLINTfmpz_poly_factor2FacCFFList (result, f.mvar()); 588 fmpz_poly_factor_clear (result); 589 fmpz_poly_clear (f1); 590 if(isOn(SW_USE_NTL_SORT)) F.sort(cmpCF); 591 return F; 592 #endif 593 #if !defined(AHE_NTL) && !defined(HAVE_FLINT) 594 factoryError ("univariate factorization over Z depends on NTL/FLINT(missing)"); 579 595 return CFFList (CFFactor (f, 1)); 580 596 #endif 581 597 } 582 else 598 else // not univariate, char 0 583 599 { 584 600 On (SW_RATIONAL); … … 586 602 { 587 603 CFList factors; 604 #ifdef HAVE_NTL 588 605 factors= ratSqrfFactorize (fz); 589 606 for (CFListIterator i= factors; i.hasItem(); i++) 590 607 F.append (CFFactor (i.getItem(), 1)); 608 #else 609 factoryError ("multivariate factorization over Z depends on NTL(missing)"); 610 return CFFList (CFFactor (f, 1)); 611 #endif 591 612 } 592 613 else
Note: See TracChangeset
for help on using the changeset viewer.