 |
My Project
debian-1:4.1.1-p2+ds-4
|
Go to the source code of this file.
|
static void | syCreateNewPairs_Hilb (syStrategy syzstr, int index, int actdeg) |
|
static void | syOrder_Hilb (poly p, syStrategy syzstr, int index) |
|
static void | syHalfPair (poly syz, int newEl, syStrategy syzstr, int index) |
|
static intvec * | syLinStrat2 (SSet nextPairs, syStrategy syzstr, int howmuch, int index, intvec **secondpairs) |
|
void | sySPRedSyz (syStrategy syzstr, sSObject redWith, poly q=NULL) |
|
static poly | syRed_Hilb (poly toRed, syStrategy syzstr, int index) |
|
static void | syRedNextPairs_Hilb (SSet nextPairs, syStrategy syzstr, int howmuch, int index, int actord, int *toSub, int *maxindex, int *maxdeg) |
|
void | sySetNewHilb (syStrategy syzstr, int toSub, int index, int actord) |
|
static void | syRedGenerOfCurrDeg_Hilb (syStrategy syzstr, int deg, int *maxindex, int *maxdeg) |
|
static void | syReOrdResult_Hilb (syStrategy syzstr, int maxindex, int maxdeg) |
|
syStrategy | syHilb (ideal arg, int *length) |
|
◆ sopen_pairs
Definition at line 56 of file syz2.cc.
Data Fields |
int |
first_poly |
|
crit_pairs |
next |
|
int |
second_poly |
|
◆ poly_write
◆ USE_CHAINCRIT
◆ USE_HEURISTIC2
◆ crit_pairs
◆ syCreateNewPairs_Hilb()
static void syCreateNewPairs_Hilb |
( |
syStrategy |
syzstr, |
|
|
int |
index, |
|
|
int |
actdeg |
|
) |
| |
|
static |
Definition at line 66 of file syz2.cc.
72 int r1,r2=0,rr,
l=(*syzstr->
Tl)[
index];
85 while ((rr>=0) && ((syzstr->
resPairs[
index])[rr].order==actdeg)
117 while ((tcp!=
NULL) &&
118 ((tcp->first_poly!=
i)||(tcp->second_poly!=r1))) tcp = tcp->next;
160 tcp->second_poly =
i;
209 tso.lcm =
p = nP->m[
i];
220 tso.order += (*syzstr->
cw)[jj-1];
227 tso.isNotMinimal = (poly)1;
243 tso.syz =
pAdd(
pp,tso.syz);
247 Print(
"erzeuge Paar im Modul %d,%d mit: \n",
index,tso.order);
◆ syHalfPair()
static void syHalfPair |
( |
poly |
syz, |
|
|
int |
newEl, |
|
|
syStrategy |
syzstr, |
|
|
int |
index |
|
) |
| |
|
static |
Definition at line 288 of file syz2.cc.
292 memset(&tso,0,
sizeof(tso));
304 tso.order += (*syzstr->
cw)[jj-1];
311 tso.isNotMinimal =
NULL;
314 tso.syz =
pHead(syz);
317 tso.lcm =
pHead(tso.syz);
321 Print(
"erzeuge Halbpaar im Module %d,%d mit: \n",
index,tso.order);
◆ syHilb()
Definition at line 951 of file syz2.cc.
956 int maxindex=0,maxdeg=0;
991 if (origR != syzstr->
syRing)
995 if (temp->m[
i]!=
NULL)
998 if (
j<actdeg) actdeg =
j;
1020 while (nextPairs!=
NULL)
1023 Print(
"compute %d Paare im Module %d im Grad %d \n",howmuch,
index,actdeg+
index);
1044 Print(
"Bilde neue Paare in Modul %d!\n",
index);
1050 Print(
"Bilde neue Paare in Modul %d!\n",
index+1);
1059 PrintS(
"minimal resolution:\n");
1060 for (
int ti=1;ti<=*
length;ti++)
1064 PrintS(
"full resolution:\n");
1065 for (
int ti=1;ti<=*
length;ti++)
1071 Print(
"Criterion %d times applied\n",crit);
1072 Print(
"Criterion1 %d times applied\n",crit1);
1073 Print(
"%d superfluous pairs\n",spfl);
1074 Print(
"%d pairs considered\n",cons_pairs);
1075 Print(
"Criterion fails %d times\n",crit_fails);
1085 if (origR != syzstr->
syRing)
◆ syLinStrat2()
Definition at line 331 of file syz2.cc.
341 #ifndef USE_HEURISTIC2
344 (*result)[i1] = i1+1;
349 while ((ll>0) && (o_r->m[ll-1]==
NULL)) ll--;
355 while ((
l<ll) && (!isDivisible))
359 isDivisible = isDivisible ||
367 Print(
"streiche Paar im Modul %d,%d mit: \n",
index,nextPairs[
i].order);
375 if (*secondpairs==
NULL) *secondpairs =
new intvec(howmuch);
376 (**secondpairs)[i2] =
i+1;
◆ syOrder_Hilb()
static void syOrder_Hilb |
( |
poly |
p, |
|
|
syStrategy |
syzstr, |
|
|
int |
index |
|
) |
| |
|
static |
◆ syRed_Hilb()
static poly syRed_Hilb |
( |
poly |
toRed, |
|
|
syStrategy |
syzstr, |
|
|
int |
index |
|
) |
| |
|
static |
Definition at line 402 of file syz2.cc.
406 if (redWith==
NULL)
return toRed;
410 while ((
j>0) && (redWith->m[
j-1]==
NULL))
j--;
411 if ((toRed==
NULL) || (
j==0))
return toRed;
429 if (toRed==
NULL)
break;
436 if ((
i>=
j) || (q==
NULL))
break;
453 if (q!=
NULL)
PrintS(
"Hier ist was schief gelaufen!\n");
◆ syRedGenerOfCurrDeg_Hilb()
static void syRedGenerOfCurrDeg_Hilb |
( |
syStrategy |
syzstr, |
|
|
int |
deg, |
|
|
int * |
maxindex, |
|
|
int * |
maxdeg |
|
) |
| |
|
static |
Definition at line 842 of file syz2.cc.
851 while ((
i<(*syzstr->
Tl)[0]) && (((sPairs)[
i].syz==
NULL) ||
852 ((sPairs)[
i].order<deg)))
854 if ((
i>=(*syzstr->
Tl)[0]) || ((sPairs)[
i].order>deg))
return;
855 while ((
i<(*syzstr->
Tl)[0]) && (((sPairs)[
i].syz==
NULL) ||
856 ((sPairs)[
i].order==deg)))
858 if ((sPairs)[
i].syz!=
NULL)
861 PrintS(
"reduziere Erzeuger: \n");
866 PrintS(
"erhalte Erzeuger: \n");
870 if ((sPairs)[
i].syz !=
NULL)
879 if ((sPairs)[
i].isNotMinimal==
NULL)
881 PrintS(
"\nminimal generator: ");
887 res->m[
k] = (sPairs)[
i].syz;
892 if (1>*maxindex) *maxindex = 1;
893 if (deg-1>*maxdeg) *maxdeg = deg-1;
◆ syRedNextPairs_Hilb()
static void syRedNextPairs_Hilb |
( |
SSet |
nextPairs, |
|
|
syStrategy |
syzstr, |
|
|
int |
howmuch, |
|
|
int |
index, |
|
|
int |
actord, |
|
|
int * |
toSub, |
|
|
int * |
maxindex, |
|
|
int * |
maxdeg |
|
) |
| |
|
static |
Definition at line 492 of file syz2.cc.
508 #ifdef USE_HEURISTIC1
510 int there_are_superfluous=0;
516 if ((nextPairs==
NULL) || (howmuch==0))
return;
518 while ((ks>0) && (syzstr->
res[
index+1]->m[ks-1]==
NULL)) ks--;
521 ((redset[kres-1].
p==
NULL) || (redset[kres-1].order>actord))) kres--;
522 while ((kres<(*syzstr->
Tl)[
index]) &&
523 (redset[kres-1].order!=0) && (redset[kres-1].order<=actord)) kres++;
533 if (actord<temp1_hilb->
length())
535 toGo = (*temp1_hilb)[actord];
537 Print(
"\nStze toGo im Modul %d und Grad %d auf: %d\n",1,actord-1,toGo);
548 Print(
"\nStze toGo im Modul %d und Grad %d auf: %d\n",
index,actord-1,toGo);
572 nextPairs[kk].p = nextPairs[kk].syz = nextPairs[kk].lcm =
NULL;
575 #ifdef USE_HEURISTIC2
587 if (spl1!=
NULL)
delete spl1;
591 if ((tso.p1!=
NULL) && (tso.p2!=
NULL))
599 PrintS(
"reduziere Paar mit: \n");
614 && ((redset[
j].ind1!=tso.ind1) || (redset[
j].ind2!=tso.ind2)))
628 redset[
j].length,
NULL);
652 PrintS(
"erhalte Paar mit: \n");
660 Print(
" mit index %d, %d ",tso.ind1,tso.ind2);
693 if (actord-
index>*maxdeg) *maxdeg = actord-
index;
701 #ifdef USE_HEURISTIC1
702 if (there_are_superfluous>=0)
709 if (tso.ind2==nextPairs[jj].ind2)
713 for (j2=
j;j2<spl1->
length()-1;j2++)
715 (*spl1)[j2] = (*spl1)[j2+1];
725 if (there_are_superfluous==0) there_are_superfluous = 1;
737 tso.p = tso.syz = tso.lcm =
NULL;
747 Print(
"naechstes i ist: %d",
i);
750 #ifdef USE_HEURISTIC1
751 if ((kk<0) && (there_are_superfluous>0))
755 spl1 = ivStrip(spl2);
759 there_are_superfluous = -1;
764 #ifdef USE_HEURISTIC2
765 if ((kk<0) && (toGo>0))
780 if (spl3!=
NULL)
delete spl3;
◆ syReOrdResult_Hilb()
static void syReOrdResult_Hilb |
( |
syStrategy |
syzstr, |
|
|
int |
maxindex, |
|
|
int |
maxdeg |
|
) |
| |
|
static |
Definition at line 903 of file syz2.cc.
911 (*syzstr->
betti)[0] = 1;
918 while ((
k>0) && (toreor->m[
k-1]==
NULL))
k--;
921 for (
int j=0;
j<
k;
j++)
924 reor->m[
j] = toreor->m[
j];
928 for (
int j=0;
j<togo;
j++)
933 while ((
l<
k) && (syzstr->
res[
i]->m[
j]!=reor->m[
l]))
l++;
936 toreor->m[
m] = reor->m[
l];
◆ sySetNewHilb()
void sySetNewHilb |
( |
syStrategy |
syzstr, |
|
|
int |
toSub, |
|
|
int |
index, |
|
|
int |
actord |
|
) |
| |
Definition at line 782 of file syz2.cc.
803 if (actord+1<temp_hilb->
length())
806 Print(
"\nSetze fuer Modul %d im Grad %d die Wert: \n",
index+1,actord);
807 (temp_hilb)->
show(0,0);
810 for (
int j=
k;
j>actord;
j--)
821 Print(
"\nSubtrahiere im Modul %d im Grad %d den Wert: %d\n",
index,actord-1,toSub);
829 for (
int j=cont_hilb->
length()-1;
j>actord;
j--)
◆ sySPRedSyz()
static int si_min(const int a, const int b)
static int show(unsigned long offset, char *close)
SSet syChosePairs(syStrategy syzstr, int *index, int *howmuch, int *actdeg)
#define pGetComp(p)
Component.
void pNorm(poly p, const ring R=currRing)
#define idDelete(H)
delete an ideal
static void pLmFree(poly p)
frees the space of the monomial m, assumes m != NULL coef is not freed, m is not advanced
void rChangeCurrRing(ring r)
#define pGetExp(p, i)
Exponent.
void sySPRedSyz(syStrategy syzstr, sSObject redWith, poly q=NULL)
number kBucketPolyRed(kBucket_pt bucket, poly p1, int l1, poly spNoether)
int syInitSyzMod(syStrategy syzstr, int index, int init=17)
static BOOLEAN length(leftv result, leftv arg)
const poly kBucketGetLm(kBucket_pt bucket)
void syCompactify1(SSet sPairs, int *sPlength, int first)
BOOLEAN idIs0(ideal h)
returns true if h is the zero ideal
void syDeletePair(SObject *so)
#define __p_Mult_nn(p, n, r)
SRes syInitRes(ideal arg, int *length, intvec *Tl, intvec *cw=NULL)
static long pTotaldegree(poly p)
static unsigned pLength(poly a)
static void syRedNextPairs_Hilb(SSet nextPairs, syStrategy syzstr, int howmuch, int index, int actord, int *toSub, int *maxindex, int *maxdeg)
ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
poly kBucketExtractLm(kBucket_pt bucket)
void kBucketDestroy(kBucket_pt *bucket_pt)
long id_RankFreeModule(ideal s, ring lmRing, ring tailRing)
return the maximal component number found in any polynomial in s
void show(int mat=0, int spaces=0) const
void PrintS(const char *s)
#define omFreeSize(addr, size)
ring rAssure_dp_C(const ring r)
void syCompactifyPairSet(SSet sPairs, int sPlength, int first)
void kBucketInit(kBucket_pt bucket, poly lm, int length)
void kBucket_Minus_m_Mult_p(kBucket_pt bucket, poly m, poly p, int *l, poly spNoether)
Bpoly == Bpoly - m*p; where m is a monom Does not destroy p and m assume (*l <= 0 || pLength(p) == *l...
void idSkipZeroes(ideal ide)
gives an ideal/module the minimal possible size
static intvec * syLinStrat2(SSet nextPairs, syStrategy syzstr, int howmuch, int index, intvec **secondpairs)
void resize(int new_length)
intvec * hHstdSeries(ideal S, intvec *modulweight, intvec *wdegree, ideal Q, ring tailRing)
static void syRedGenerOfCurrDeg_Hilb(syStrategy syzstr, int deg, int *maxindex, int *maxdeg)
void kBucketClear(kBucket_pt bucket, poly *p, int *length)
#define pLmDivisibleByNoComp(a, b)
like pLmDivisibleBy, does not check components
static void syCreateNewPairs_Hilb(syStrategy syzstr, int index, int actdeg)
#define IMATELEM(M, I, J)
static poly syRed_Hilb(poly toRed, syStrategy syzstr, int index)
ideal idInit(int idsize, int rank)
initialise an ideal / module
static void syOrder_Hilb(poly p, syStrategy syzstr, int index)
static void syReOrdResult_Hilb(syStrategy syzstr, int maxindex, int maxdeg)
#define pLmDelete(p)
assume p != NULL, deletes Lm(p)->coef and Lm(p)
int lcm(unsigned long *l, unsigned long *a, unsigned long *b, unsigned long p, int dega, int degb)
static FORCE_INLINE number n_SubringGcd(number a, number b, const coeffs r)
#define pLmDivisibleBy(a, b)
like pDivisibleBy, except that it is assumed that a!=NULL, b!=NULL
kBucket_pt kBucketCreate(const ring bucket_ring)
Creation/Destruction of buckets.
void syEnterPair(syStrategy syzstr, SObject *so, int *sPlength, int index)
#define pCopy(p)
return a copy of the poly
#define pHead(p)
returns newly allocated copy of Lm(p), coef is copied, next=NULL, p might be NULL
static number & pGetCoeff(poly p)
return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy
long ** ShiftedComponents
void syEnlargeFields(syStrategy syzstr, int index)
static long p_FDeg(const poly p, const ring r)
static int index(p_Length length, p_Ord ord)
poly prCopyR(poly p, ring src_r, ring dest_r)
long * currShiftedComponents
static void syHalfPair(poly syz, int newEl, syStrategy syzstr, int index)
KINLINE poly ksOldCreateSpoly(poly p1, poly p2, poly spNoether, ring r)
void sySetNewHilb(syStrategy syzstr, int toSub, int index, int actord)