Changeset 4782bc in git for factory


Ignore:
Timestamp:
Sep 10, 2012, 3:45:37 PM (12 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', '6e5adcba05493683b94648c659a729c189812c77')
Children:
4604b84fc397bca4fcd80a0d3b01bfdb7a7fdb76
Parents:
c8f95dcff8b4cb5bddaf189cc7eb14c5d52ebe26
git-author:
Martin Lee <martinlee84@web.de>2012-09-10 15:45:37+02:00
git-committer:
Martin Lee <martinlee84@web.de>2012-10-25 15:11:13+02:00
Message:
chg: use flint in algext
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/algext.cc

    rc8f95d r4782bc  
    2929#ifdef HAVE_NTL
    3030#include "NTLconvert.h"
     31#endif
     32
     33#ifdef HAVE_FLINT
     34#include "FLINTconvert.h"
    3135#endif
    3236
     
    637641    {
    638642      if (c.isZero()) return abs (f);
     643#ifdef HAVE_FLINT
     644      fmpz_poly_t FLINTf, FLINTc;
     645      convertFacCF2Fmpz_poly_t (FLINTf, f);
     646      convertFacCF2Fmpz_poly_t (FLINTc, c);
     647      fmpz_poly_gcd (FLINTc, FLINTc, FLINTf);
     648      CanonicalForm result;
     649      if (f.inCoeffDomain())
     650        result= convertFmpz_poly_t2FacCF (FLINTc, f.mvar());
     651      else
     652        result= convertFmpz_poly_t2FacCF (FLINTc, c.mvar());
     653      fmpz_poly_clear (FLINTc);
     654      fmpz_poly_clear (FLINTf);
     655      return result;
     656#else
    639657      ZZX NTLf= convertFacCF2NTLZZX (f);
    640658      ZZX NTLc= convertFacCF2NTLZZX (c);
     
    644662      else
    645663        return convertNTLZZX2CF(NTLc,c.mvar());
     664#endif
    646665    }
    647666    else
Note: See TracChangeset for help on using the changeset viewer.