Changeset 15a879 in git for factory/facFqFactorize.cc


Ignore:
Timestamp:
Aug 27, 2012, 2:53:30 PM (12 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
ee4a7ded18ac9e58470a1628b76664aa441d3556
Parents:
e3cb321a536f5d1fea376ee2b01122921297faa8
git-author:
Martin Lee <martinlee84@web.de>2012-08-27 14:53:30+02:00
git-committer:
Martin Lee <martinlee84@web.de>2012-09-05 15:00:01+02:00
Message:
chg: pass to larger extension if over a small finite field
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/facFqFactorize.cc

    re3cb321 r15a879  
    705705}
    706706
     707#define CHAR_THRESHOLD 8
    707708CFList
    708709evalPoints (const CanonicalForm& F, CFList & eval, const Variable& alpha,
     
    715716  GFRandom genGF;
    716717  int p= getCharacteristic ();
     718  if (p < CHAR_THRESHOLD && !GF && alpha.level() == 1)
     719  {
     720    fail= true;
     721    return CFList();
     722  }
    717723  double bound;
    718724  if (alpha != x)
     
    32803286    bool extension= true;
    32813287    int p= getCharacteristic();
    3282     if (p*p < (1<<16)) // pass to GF if possible
     3288    if (p < 7)
     3289    {
     3290      if (p == 2)
     3291        setCharacteristic (getCharacteristic(), 6, 'Z');
     3292      else if (p == 3)
     3293        setCharacteristic (getCharacteristic(), 4, 'Z');
     3294      else if (p == 5)
     3295        setCharacteristic (getCharacteristic(), 3, 'Z');
     3296      ExtensionInfo info= ExtensionInfo (extension);
     3297      A= A.mapinto();
     3298      factors= multiFactorize (A, info);
     3299
     3300      CanonicalForm mipo= gf_mipo;
     3301      setCharacteristic (getCharacteristic());
     3302      Variable vBuf= rootOf (mipo.mapinto());
     3303      for (CFListIterator j= factors; j.hasItem(); j++)
     3304        j.getItem()= GF2FalphaRep (j.getItem(), vBuf);
     3305    }
     3306    else if (p >= 7 && p*p < (1<<16)) // pass to GF if possible
    32833307    {
    32843308      setCharacteristic (getCharacteristic(), 2, 'Z');
Note: See TracChangeset for help on using the changeset viewer.