411 if (maxlength!=-1) *length = maxlength+1;
413 if ((wlength!=0) && (*length!=wlength))
416 wtmp[0]=(*weights)[0];
427 if (syz_ring != origR)
438 if ((weights!=
NULL) && (*weights!=
NULL)&& ((*weights)[0]!=
NULL))
442 WarnS(
"wrong weights given(1):"); (*weights)[0]->show();
PrintLn();
449 if ((weights==
NULL) || (*weights==
NULL) || ((*weights)[0]==
NULL))
460 if ((weights!=
NULL) && (*weights!=
NULL)&& ((*weights)[0]!=
NULL))
462 w =
ivCopy((*weights)[0]);
473 #endif // HAVE_PLURAL
485 setRegularity =
FALSE;
490 setRegularity =
FALSE;
494 while ((res[syzIndex]!=
NULL) && (!
idIs0(res[syzIndex])) &&
495 ((maxlength==-1) || (syzIndex<=maxlength)))
500 if (syzIndex+1==*length)
504 for (
j=0;
j<*length;
j++)
507 if (*weights!=
NULL) tempW[
j] = (*weights)[
j];
523 if (minim || (syzIndex!=0))
528 res[syzIndex] = temp;
545 completeMinim=(syzIndex!=maxlength) || (maxlength ==-1) || (hom!=
isHomog);
551 if ((minim)||(syzIndex>1))
552 syMinStep(res[syzIndex-1],res[syzIndex],!completeMinim,
NULL,hom);
572 (*weights)[syzIndex] =
new intvec(k);
575 if (res[syzIndex-1]->
m[i]!=
NULL)
580 += (*w)[
pGetComp(res[syzIndex-1]->
m[i])-1];
584 for (i=k;i<k+
IDELEMS(res[syzIndex]);i++)
586 if (res[syzIndex]->
m[i-k]!=
NULL)
588 +(*w)[
pGetComp(res[syzIndex]->
m[i-k])-1];
594 if ((syzIndex!=0) && (res[syzIndex]!=
NULL) && (
idIs0(res[syzIndex])))
596 if (w !=
NULL)
delete w;
602 for (i=1; i<=syzIndex; i++)
610 if (origR != syz_ring)
613 for (i=0; i<=syzIndex; i++)
#define TEST_OPT_NOTREGULARITY
void resize(int new_length)
#define TEST_OPT_DEGBOUND
BOOLEAN idTestHomModule(ideal m, ideal Q, intvec *w)
static int rGetCurrSyzLimit(const ring r)
#define omFreeSize(addr, size)
intvec * ivCopy(const intvec *o)
static bool rIsPluralRing(const ring r)
we must always have this test!
#define pGetComp(p)
Component.
ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
void id_Shift(ideal M, int s, const ring r)
long id_RankFreeModule(ideal s, ring lmRing, ring tailRing)
return the maximal component number found in any polynomial in s
#define TEST_OPT_NO_SYZ_MINIM
static long pTotaldegree(poly p)
int rGetMaxSyzComp(int i, const ring r)
return the max-comonent wchich has syzIndex i Assume: i<= syzIndex_limit
ring rAssure_SyzComp(const ring r, BOOLEAN complete)
static long p_FDeg(const poly p, const ring r)
static int si_max(const int a, const int b)
ideal kInterRedOld(ideal F, ideal Q)
void idSkipZeroes(ideal ide)
gives an ideal/module the minimal possible size
void rSetSyzComp(int k, const ring r)
void rChangeCurrRing(ring r)
static void syMinStep(ideal mod, ideal syz, BOOLEAN final=FALSE, ideal up=NULL, tHomog h=isNotHomog)
static BOOLEAN rField_is_Ring(const ring r)
void rDelete(ring r)
unconditionally deletes fields in r
static bool rIsSCA(const ring r)
void show(int mat=0, int spaces=0) const
ideal idSyzygies(ideal h1, tHomog h, intvec **w, BOOLEAN setSyzComp, BOOLEAN setRegularity, int *deg)
BOOLEAN idIs0(ideal h)
returns true if h is the zero ideal
#define SI_RESTORE_OPT1(A)
ideal idrCopyR_NoSort(ideal id, ring src_r, ring dest_r)
BOOLEAN idHomModule(ideal m, ideal Q, intvec **w)
void idDelete(ideal *h)
delete an ideal
static intvec * syPrepareModComp(ideal arg, intvec **w)
ideal idrMoveR_NoSort(ideal &id, ring src_r, ring dest_r)