506 #ifdef USE_HEURISTIC1 508 int there_are_superfluous=0;
514 if ((nextPairs==
NULL) || (howmuch==0))
return;
515 while ((k>0) && (syzstr->
res[
index]->m[k-1]==
NULL)) k--;
516 while ((ks>0) && (syzstr->
res[
index+1]->m[ks-1]==
NULL)) ks--;
519 ((redset[kres-1].
p==
NULL) || (redset[kres-1].order>actord))) kres--;
520 while ((kres<(*syzstr->
Tl)[
index]) &&
521 (redset[kres-1].order!=0) && (redset[kres-1].order<=actord)) kres++;
531 if (actord<temp1_hilb->
length())
533 toGo = (*temp1_hilb)[actord];
535 Print(
"\nStze toGo im Modul %d und Grad %d auf: %d\n",1,actord-1,toGo);
546 Print(
"\nStze toGo im Modul %d und Grad %d auf: %d\n",
index,actord-1,toGo);
570 nextPairs[kk].p = nextPairs[kk].syz = nextPairs[kk].lcm =
NULL;
573 #ifdef USE_HEURISTIC2 585 if (spl1!=
NULL)
delete spl1;
589 if ((tso.p1!=
NULL) && (tso.p2!=
NULL))
597 PrintS(
"reduziere Paar mit: \n");
612 && ((redset[j].ind1!=tso.ind1) || (redset[j].ind2!=tso.ind2)))
626 redset[j].length,
NULL);
650 PrintS(
"erhalte Paar mit: \n");
658 Print(
" mit index %d, %d ",tso.ind1,tso.ind2);
691 if (actord-
index>*maxdeg) *maxdeg = actord-
index;
699 #ifdef USE_HEURISTIC1 700 if (there_are_superfluous>=0)
707 if (tso.ind2==nextPairs[jj].ind2)
711 for (j2=j;j2<spl1->
length()-1;j2++)
713 (*spl1)[j2] = (*spl1)[j2+1];
723 if (there_are_superfluous==0) there_are_superfluous = 1;
735 tso.p = tso.syz = tso.lcm =
NULL;
745 Print(
"naechstes i ist: %d",i);
748 #ifdef USE_HEURISTIC1 749 if ((kk<0) && (there_are_superfluous>0))
753 spl1 = ivStrip(spl2);
757 there_are_superfluous = -1;
762 #ifdef USE_HEURISTIC2 763 if ((kk<0) && (toGo>0))
778 if (spl3!=
NULL)
delete spl3;
void kBucketClear(kBucket_pt bucket, poly *p, int *length)
void kBucketInit(kBucket_pt bucket, poly lm, int length)
number kBucketPolyRed(kBucket_pt bucket, poly p1, int l1, poly spNoether)
const poly kBucketGetLm(kBucket_pt bucket)
KINLINE poly ksOldCreateSpoly(poly p1, poly p2, poly spNoether, ring r)
void sySPRedSyz(syStrategy syzstr, sSObject redWith, poly q=NULL)
#define pLmDivisibleBy(a, b)
like pDivisibleBy, except that it is assumed that a!=NULL, b!=NULL
static number & pGetCoeff(poly p)
return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy ...
intvec * hHstdSeries(ideal S, intvec *modulweight, intvec *wdegree, ideal Q, ring tailRing)
VAR ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
void PrintS(const char *s)
static intvec * syLinStrat2(SSet nextPairs, syStrategy syzstr, int howmuch, int index, intvec **secondpairs)
static poly syRed_Hilb(poly toRed, syStrategy syzstr, int index)
static int index(p_Length length, p_Ord ord)
#define __p_Mult_nn(p, n, r)
long ** ShiftedComponents
void syEnlargeFields(syStrategy syzstr, int index)
void pNorm(poly p, const ring R=currRing)
void show(int mat=0, int spaces=0) const
static BOOLEAN length(leftv result, leftv arg)
#define IMATELEM(M, I, J)
void syDeletePair(SObject *so)
static void syHalfPair(poly syz, int newEl, syStrategy syzstr, int index)