Changeset 124970 in git


Ignore:
Timestamp:
May 2, 2020, 11:22:27 AM (4 years ago)
Author:
Karim Abou Zeid <karim23697@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
72c30369edc68da6cbab1a305ed752d2a847ec63
Parents:
9d58a7caf741db5e365f7257bd91048bb1bddf31
Message:
Fix prod crit for modules in LP
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/GBEngine/kutil.cc

    r9d58a7c r124970  
    1278912789
    1279012790  int degbound = currRing->N/currRing->isLPring;
    12791   int neededShift = p_lastVblock - 1;
     12791  int neededShift = p_lastVblock - ((pGetComp(p) > 0 || pGetComp(q) > 0) ? 0 : 1); // in the module case, product criterion does not hold
    1279212792  int maxPossibleShift = degbound - q_lastVblock;
    1279312793  int maxShift = si_min(neededShift, maxPossibleShift);
     
    1284412844#endif
    1284512845  {
    12846     assume(q_shift <= p_lastVblock - 1); // there should be an overlap
     12846    assume(q_shift <= p_lastVblock - ((pGetComp(q) > 0 || pGetComp(p) > 0) ? 0 : 1)); // there should be an overlap (in the module case epsilon overlap is also allowed)
    1284712847    enterOnePairShift(q, p, ecartp, p_isFromQ, strat, -1, ecartq, q_isFromQ, q_shift, -1);
    1284812848  }
     
    1328313283                poly s = strat->S[j];
    1328413284                int s_lastVblock = pmLastVblock(s);
    13285                 if (i < s_lastVblock)
     13285                if (i < s_lastVblock || (pGetComp(s) > 0 && i == s_lastVblock)) // in the module case, product criterion does not hold (note: comp h is always zero here)
    1328613286                  enterOnePairWithoutShifts(j, hh, s, ecart, isFromQ, strat, atR, s_lastVblock, i);
    1328713287#ifdef HAVE_RINGS
     
    1332013320            poly s = strat->S[j];
    1332113321            int s_lastVblock = pmLastVblock(s);
    13322             if (i < s_lastVblock)
     13322            if (i < s_lastVblock || (pGetComp(s) > 0 && i == s_lastVblock)) // in the module case, product criterion does not hold (note: comp h is always zero here)
    1332313323              enterOnePairWithoutShifts(j, hh, s, ecart, isFromQ, strat, atR, s_lastVblock, i);
    1332413324#ifdef HAVE_RINGS
     
    1333613336#endif
    1333713337          }
    13338           if (i < h_lastVblock)
     13338          if (i < h_lastVblock) // in the module case, product criterion does not hold (note: comp h is always zero here)
    1333913339            enterOnePairWithoutShifts(-1, hh, h, ecart, isFromQ, strat, atR, h_lastVblock, i);
    1334013340#ifdef HAVE_RINGS
     
    1338313383        // pairs (shifts(s[1..k]),h), (s[1..k],h)
    1338413384        for (j=0; j<=k; j++)
    13385         {
     13385        {
    1338613386          if ((pGetComp(h)==pGetComp(strat->S[j]))
    1338713387              || (pGetComp(strat->S[j])==0))
     
    1340213402              poly s = strat->S[j];
    1340313403              int s_lastVblock = pmLastVblock(s);
    13404               if (i < s_lastVblock)
     13404              if (i <= s_lastVblock) // in the module case, product criterion does not hold
    1340513405                enterOnePairWithoutShifts(j, hh, s, ecart, isFromQ, strat, atR, s_lastVblock, i);
    1340613406#ifdef HAVE_RINGS
     
    1341913419            }
    1342013420          }
    13421           if (i < h_lastVblock)
     13421          if (i <= h_lastVblock) // in the module case, product criterion does not hold
    1342213422            enterOnePairWithoutShifts(-1, hh, h, ecart, isFromQ, strat, atR, h_lastVblock, i);
    1342313423#ifdef HAVE_RINGS
Note: See TracChangeset for help on using the changeset viewer.