Changeset a969ff in git


Ignore:
Timestamp:
Mar 21, 2016, 2:43:26 PM (8 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
cf5fba9676fd2b05c5b5e85d2a950307c034fd1e
Parents:
770afafee6b4b73035818ab5d72c01d2c9fbd566
Message:
fix: clear common factors in T/S (updateT) after highest corner found
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/GBEngine/kstd1.cc

    r770afa ra969ff  
    12051205    else
    12061206      deleteHC(&(strat->L[i]), strat);
    1207    if (strat->L[i].IsNull())
     1207    if (strat->L[i].IsNull())
    12081208      deleteInL(strat->L,&strat->Ll,i,strat);
    12091209    else
     
    12201220/*2
    12211221* cuts in T above strat->kNoether and tries to cancel a unit
     1222* changes also S as S is a subset of T
    12221223*/
    12231224void updateT(kStrategy strat)
     
    12321233    /*- tries to cancel a unit: -*/
    12331234    cancelunit(&p);
     1235    if (TEST_OPT_INTSTRATEGY) /* deleteHC and/or cancelunit may have changed p*/
     1236      p.pCleardenom();
    12341237    if (p.p != strat->T[i].p)
    12351238    {
     
    12821285      return;
    12831286
    1284 #ifndef HAVE_RINGS
    1285     strat->red = redFirst;
    1286     strat->use_buckets = kMoraUseBucket(strat);
    1287 #else
     1287#ifdef HAVE_RINGS
    12881288    if ( (!rField_is_Ring(currRing)) || (rHasGlobalOrdering(currRing)))
     1289#endif
    12891290    {
    12901291      strat->red = redFirst;
    12911292      strat->use_buckets = kMoraUseBucket(strat);
    12921293    }
    1293 #endif
    12941294    updateT(strat);
    12951295
    1296 #ifndef HAVE_RINGS
    1297     strat->posInT = posInT2;
    1298     reorderT(strat);
    1299 #else
     1296#ifdef HAVE_RINGS
    13001297    if ( (!rField_is_Ring(currRing)) || (rHasGlobalOrdering(currRing)))
     1298#endif
    13011299    {
    13021300      strat->posInT = posInT2;
    13031301      reorderT(strat);
    13041302    }
    1305 #endif
    13061303  }
    13071304  kTest_TS(strat);
     
    17241721    }
    17251722
     1723    // the s-poly
    17261724    if (!strat->P.IsNull())
    17271725    {
     
    17501748    }
    17511749
     1750    // the reduced s-poly
    17521751    if (! strat->P.IsNull())
    17531752    {
     
    17561755      if (TEST_OPT_PROT) PrintS("s");
    17571756      // normalization
    1758       if (!TEST_OPT_INTSTRATEGY)
     1757      if (TEST_OPT_INTSTRATEGY)
     1758        strat->P.pCleardenom();
     1759      else
    17591760        strat->P.pNorm();
    17601761      // tailreduction
     
    17711772      cancelunit(&strat->P);
    17721773      // for char 0, clear denominators
    1773       if (TEST_OPT_INTSTRATEGY)
     1774      if ((strat->P.p->next==NULL) /* i.e. cancelunit did something*/
     1775      && TEST_OPT_INTSTRATEGY)
    17741776        strat->P.pCleardenom();
    17751777
     
    18331835      // clear strat->P
    18341836      if (strat->P.lcm!=NULL)
     1837      {
    18351838#if defined(HAVE_RINGS)
    18361839        pLmDelete(strat->P.lcm);
     
    18381841        pLmFree(strat->P.lcm);
    18391842#endif
    1840       strat->P.lcm=NULL;
     1843        strat->P.lcm=NULL;
     1844      }
    18411845#ifdef KDEBUG
    18421846      // make sure kTest_TS does not complain about strat->P
Note: See TracChangeset for help on using the changeset viewer.