Changeset 6036d90 in git for factory/facFactorize.cc


Ignore:
Timestamp:
Nov 18, 2011, 5:41:42 PM (12 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
Children:
615ca847eb54f53d0896364932b51cc9074dffda
Parents:
7d58b610fedb008c184de5ef38c1cd5bc05d1ecc
git-author:
Martin Lee <martinlee84@web.de>2011-11-18 17:41:42+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2011-11-19 03:27:46+01:00
Message:
added heuristic for sparse lifting and updated tests
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/facFactorize.cc

    r7d58b6 r6036d90  
    695695    refineBiFactors (A, biFactors, Aeval2, evaluation, minFactorsLength);
    696696
     697  if (differentSecondVar == A.level() - 2)
     698  {
     699    bool zeroOccured= false;
     700    for (CFListIterator iter= evaluation; iter.hasItem(); iter++)
     701    {
     702      if (iter.getItem().isZero())
     703      {
     704        zeroOccured= true;
     705        break;
     706      }
     707    }
     708    if (!zeroOccured)
     709    {
     710      factors= sparseHeuristic (A, biFactors, Aeval2, evaluation, minFactorsLength);
     711      if (factors.length() == biFactors.length())
     712      {
     713        appendSwapDecompress (factors, contentAFactors, N, 0, 0, x);
     714        normalize (factors);
     715        delete [] Aeval2;
     716        return factors;
     717      }
     718      else
     719        factors= CFList();
     720      //TODO case where factors.length() > 0
     721    }
     722  }
     723
    697724  CFList uniFactors= buildUniFactors (biFactors, evaluation.getLast(), y);
    698725
Note: See TracChangeset for help on using the changeset viewer.