Loading...
Searching...
No Matches
kutil.h
Go to the documentation of this file.
#ifndef KUTIL_H
#define KUTIL_H
/****************************************
* Computer Algebra System SINGULAR *
****************************************/
/*
* ABSTRACT: kernel: utils for kStd
*/
#include <string.h>
#include "omalloc/omalloc.h"
#ifdef HAVE_OMALLOC
#include "omalloc/omallocClass.h"
#endif
#include "misc/mylimits.h"
#include "kernel/polys.h"
#include "polys/operations/pShallowCopyDelete.h"
#include "kernel/structs.h"
#include "kernel/GBEngine/kstd1.h" /* for s_poly_proc_t */
#include "coeffs/bigintmat.h" /* for s_poly_proc_t */
// define if tailrings should be used
#define HAVE_TAIL_RING
#define setmax 128
#define setmaxL ((int)((4096-12)/sizeof(LObject)))
#define setmaxLinc ((int)((4096)/sizeof(LObject)))
#define setmaxT ((int)((4096-12)/sizeof(TObject)))
#define setmaxTinc ((int)((4096)/sizeof(TObject)))
#define RED_CANONICALIZE 200
#define REDNF_CANONICALIZE 60
#define REDTAIL_CANONICALIZE 100
// if you want std computations as in Singular version < 2:
// This disables RedThrough, tailReductions against T (bba),
// sets posInT = posInT15 (bba, strat->honey), and enables redFirst with LDeg
// NOTE: can be achieved with option(oldStd)
#undef NO_KINLINE
#if !defined(KDEBUG) && !defined(NO_INLINE)
#define KINLINE inline
#else
#define KINLINE
#define NO_KINLINE 1
#endif
typedef int* intset;
typedef int64 wlen_type;
typedef wlen_type* wlen_set;
typedef class sTObject TObject;
typedef class sLObject LObject;
typedef TObject * TSet;
typedef LObject * LSet;
typedef struct denominator_list_s denominator_list_s;
typedef denominator_list_s *denominator_list;
struct denominator_list_s{number n; denominator_list next;};
EXTERN_VAR denominator_list DENOMINATOR_LIST;
class sTObject
{
public:
unsigned long sevSig;
poly sig; // the signature of the element
poly p; // Lm(p) \in currRing Tail(p) \in tailRing
poly t_p; // t_p \in tailRing: as monomials Lm(t_p) == Lm(p)
poly max_exp; // p_GetMaxExpP(pNext(p))
ring tailRing;
long FDeg; // pFDeg(p)
int ecart,
length, // as of pLDeg
pLength, // either == 0, or == pLength(p)
i_r; // index of TObject in R set, or -1 if not in T
#ifdef HAVE_SHIFTBBA
int shift;
#endif
/*BOOLEAN*/ char is_normalized; // true, if pNorm was called on p, false otherwise
// used in incremental sba() with F5C:
// we know some of the redundant elements in
// strat->T beforehand, so we can just discard
// them and do not need to consider them in the
// interreduction process
/*BOOLEAN*/ char is_redundant;
// used in sba's sig-safe reduction:
// sometimes we already know that a reducer
// is sig-safe, so no need for a real
// sig-safeness check
/*BOOLEAN*/ char is_sigsafe;
#ifdef HAVE_PLURAL
/*BOOLEAN*/ char is_special; // true, it is a new special S-poly (e.g. for SCA)
#endif
// initialization
KINLINE void Init(ring r = currRing);
KINLINE sTObject(ring tailRing = currRing);
KINLINE sTObject(poly p, ring tailRing = currRing);
KINLINE sTObject(poly p, ring c_r, ring tailRing);
KINLINE sTObject(sTObject* T, int copy);
KINLINE void Set(ring r=currRing);
KINLINE void Set(poly p_in, ring r=currRing);
KINLINE void Set(poly p_in, ring c_r, ring t_r);
// Frees the polys of T
KINLINE void Delete();
// Sets polys to NULL
KINLINE void Clear();
// makes a copy of the poly of T
KINLINE void Copy();
// ring-dependent Lm access: these might result in allocation of monomials
KINLINE poly GetLmCurrRing();
KINLINE poly GetLmTailRing();
KINLINE poly GetLm(ring r);
// this returns Lm and ring r (preferably from tailRing), but does not
// allocate a new poly
KINLINE void GetLm(poly &p, ring &r) const;
#ifdef OLIVER_PRIVAT_LT
// routines for calc. with rings
KINLINE poly GetLtCurrRing();
KINLINE poly GetLtTailRing();
KINLINE poly GetLt(ring r);
KINLINE void GetLt(poly &p, ring &r) const;
#endif
KINLINE BOOLEAN IsNull() const;
KINLINE int GetpLength();
// makes sure that T.p exists
KINLINE void SetLmCurrRing();
// Iterations
// simply get the next monomial
KINLINE poly Next();
KINLINE void LmDeleteAndIter();
// deg stuff
// compute pTotalDegree
KINLINE long pTotalDeg() const;
// computes pFDeg
KINLINE long pFDeg() const;
// computes and sets FDeg
KINLINE long SetpFDeg();
// gets stored FDeg
KINLINE long GetpFDeg() const;
// computes pLDeg
KINLINE long pLDeg();
// sets length, FDeg, returns LDeg
KINLINE long SetDegStuffReturnLDeg();
// arithmetic
KINLINE void Mult_nn(number n);
KINLINE void ShallowCopyDelete(ring new_tailRing, omBin new_tailBin,
pShallowCopyDeleteProc p_shallow_copy_delete,
BOOLEAN set_max = TRUE);
// manipulations
KINLINE void pNorm();
KINLINE void pCleardenom();
KINLINE void pContent();
#ifdef KDEBUG
void wrp();
#endif
};
EXTERN_VAR int strat_nr;
class sLObject : public sTObject
{
public:
unsigned long sev;
poly p1,p2; /*- the pair p comes from,
lm(pi) in currRing, tail(pi) in tailring -*/
poly lcm; /*- the lcm of p1,p2 -*/
kBucket_pt bucket;
int i_r1, i_r2;
unsigned checked; // this is the index of S up to which
// the corresponding LObject was already checked in
// critical pair creation => when entering the
// reduction process it is enough to start a second
// rewritten criterion check from checked+1 onwards
BOOLEAN prod_crit;
// NOTE: If prod_crit = TRUE then the corresponding pair is
// detected by Buchberger's Product Criterion and can be
// deleted
// initialization
KINLINE void Init(ring tailRing = currRing);
KINLINE sLObject(ring tailRing = currRing);
KINLINE sLObject(poly p, ring tailRing = currRing);
KINLINE sLObject(poly p, ring c_r, ring tailRing);
// Frees the polys of L
KINLINE void Delete();
KINLINE void Clear();
// Iterations
KINLINE void LmDeleteAndIter();
KINLINE poly LmExtractAndIter();
// spoly related things
// preparation for reduction if not spoly
KINLINE void PrepareRed(BOOLEAN use_bucket);
KINLINE void SetLmTail(poly lm, poly new_p, int length,
int use_bucket, ring r);
KINLINE void Tail_Minus_mm_Mult_qq(poly m, poly qq, int lq, poly spNoether);
KINLINE void Tail_Mult_nn(number n);
// deletes bucket, makes sure that p and t_p exists
KINLINE poly GetP(omBin lmBin = (omBin)NULL);
// similar, except that only t_p exists
KINLINE poly GetTP();
// does not delete bucket, just canonicalizes it
// returned poly is such that Lm(p) \in currRing, Tail(p) \in tailRing
KINLINE void CanonicalizeP();
// makes a copy of the poly of L
KINLINE void Copy();
KINLINE int GetpLength();
KINLINE long pLDeg(BOOLEAN use_last);
KINLINE long pLDeg();
KINLINE int SetLength(BOOLEAN lengt_pLength = FALSE);
KINLINE long SetDegStuffReturnLDeg();
KINLINE long SetDegStuffReturnLDeg(BOOLEAN use_last);
// returns minimal component of p
KINLINE long MinComp();
// returns component of p
KINLINE long Comp();
KINLINE void ShallowCopyDelete(ring new_tailRing,
pShallowCopyDeleteProc p_shallow_copy_delete);
// sets sev
KINLINE void SetShortExpVector();
// enable assignment from TObject
KINLINE sLObject& operator=(const sTObject&);
// get T's corresponding to p1, p2: they might return NULL
KINLINE TObject* T_1(const skStrategy* strat);
KINLINE TObject* T_2(const skStrategy* strat);
KINLINE void T_1_2(const skStrategy* strat,
TObject* &T_1, TObject* &T_2);
// simplify coefficients
KINLINE void Normalize();
KINLINE void HeadNormalize();
};
EXTERN_VAR int HCord;
class skStrategy
#ifdef HAVE_OMALLOC
: public omallocClass
#endif
{
public:
kStrategy next;
int (*red)(LObject * L,kStrategy strat);
int (*red2)(LObject * L,kStrategy strat);
void (*initEcart)(TObject * L);
int (*posInT)(const TSet T,const int tl,LObject &h);
int (*posInL)(const LSet set, const int length,
LObject* L,const kStrategy strat);
void (*enterS)(LObject* h, int pos,kStrategy strat, int atR/* =-1*/ );
void (*initEcartPair)(LObject * h, poly f, poly g, int ecartF, int ecartG);
int (*posInLOld)(const LSet Ls,const int Ll,
LObject* Lo,const kStrategy strat);
void (*enterOnePair) (int i,poly p,int ecart, int isFromQ,kStrategy strat, int atR /*= -1*/);
void (*chainCrit) (poly p,int ecart,kStrategy strat);
BOOLEAN (*syzCrit) (poly sig, unsigned long not_sevSig, kStrategy strat);
BOOLEAN (*rewCrit1) (poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start /*= 0*/);
BOOLEAN (*rewCrit2) (poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start /*= 0*/);
BOOLEAN (*rewCrit3) (poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start /*= 0*/);
pFDegProc pOrigFDeg;
pLDegProc pOrigLDeg;
pFDegProc pOrigFDeg_TailRing;
pLDegProc pOrigLDeg_TailRing;
s_poly_proc_t s_poly;
LObject P;
ideal Shdl;
ideal D; /*V(S) is in D(D)*/
ideal M; /*set of minimal generators*/
polyset S;
polyset syz;
polyset sig;
intset ecartS;
intset fromS; // from which S[i] S[j] comes from
// this is important for signature-based
// algorithms
intset syzIdx;// index in the syz array at which the first
// syzygy of component i comes up
// important for signature-based algorithms
unsigned sbaOrder;
int currIdx;
int max_lower_index;
intset lenS;
wlen_set lenSw; /* for tgb.ccc */
intset fromQ;
unsigned long* sevS;
unsigned long* sevSyz;
unsigned long* sevSig;
unsigned long* sevT;
TSet T;
LSet L;
LSet B;
poly kNoether;
poly t_kNoether; // same polys in tailring
KINLINE poly kNoetherTail();
BOOLEAN * NotUsedAxis;
BOOLEAN * pairtest;/*used for enterOnePair*/
poly tail;
intvec * kModW;
intvec * kHomW;
// procedure for ShalloCopy from tailRing to currRing
pShallowCopyDeleteProc p_shallow_copy_delete;
// pointers to Tobjects R[i] is ith Tobject which is generated
TObject** R;
// S_2_R[i] yields Tobject which corresponds to S[i]
int* S_2_R;
ring tailRing;
omBin lmBin;
omBin tailBin;
int nr;
int cp,c3;
int sl,mu;
int syzl,syzmax,syzidxmax;
int tl,tmax;
int Ll,Lmax;
int Bl,Bmax;
int ak,LazyDegree,LazyPass;
int syzComp;
int lastAxis;
int newIdeal;
int minim;
bool sigdrop; //This is used to check sigdrop in sba over Z
int nrsyzcrit; // counts how many pairs are deleted by SyzCrit
int nrrewcrit; // counts how many pairs are deleted by FaugereRewCrit
int sbaEnterS; // sba over Z strategy: if sigdrop element has _*gen(sbaEnterS+1), then
// add directly sbaEnterS elements into S
int blockred; // counter for blocked reductions in redSig
int blockredmax;
#ifdef HAVE_SHIFTBBA
int cv; // in shift bases: counting V criterion
/*BOOLEAN*/ char rightGB;
#endif
/*BOOLEAN*/ char interpt;
/*BOOLEAN*/ char homog;
#ifdef HAVE_PLURAL
/*BOOLEAN*/ char z2homog; // Z_2 - homogeneous input allows product criterion in commutative and SCA cases!
#endif
/*BOOLEAN*/ char kAllAxis; // all axis are used -> (re)compute noether
/*BOOLEAN*/ char honey,sugarCrit;
/*BOOLEAN*/ char Gebauer,noTailReduction;
/*BOOLEAN*/ char fromT;
/*BOOLEAN*/ char noetherSet;
/*BOOLEAN*/ char update;
/*BOOLEAN*/ char posInLOldFlag;
/*BOOLEAN*/ char use_buckets;
// if set, pLDeg(p, l) == (pFDeg(pLast(p), pLength)
/*BOOLEAN*/ char LDegLast;
// if set, then L.length == L.pLength
/*BOOLEAN*/ char length_pLength;
// if set, then posInL does not depend on L.length
/*BOOLEAN*/ char posInLDependsOnLength;
/*FALSE, if posInL == posInL10*/
#ifdef HAVE_PLURAL
// set this flag to 1 to stop the product criteria
// use ALLOW_PROD_CRIT(strat) to test
/*BOOLEAN*/ char no_prod_crit;
#define ALLOW_PROD_CRIT(A) (!(A)->no_prod_crit)
#else
#define ALLOW_PROD_CRIT(A) (1)
#endif
char redTailChange;
char news;
char newt;/*used for messageSets*/
char noClearS;
char completeReduce_retry;
char overflow;
skStrategy();
~skStrategy();
// return TObject corresponding to S[i]: assume that it exists
// i.e. no error checking is done
KINLINE TObject* S_2_T(int i);
// like S_2_T, except that NULL is returned if it can not be found
KINLINE TObject* s_2_t(int i);
};
void deleteHC(poly *p, int *e, int *l, kStrategy strat);
void deleteHC(LObject* L, kStrategy strat, BOOLEAN fromNext = FALSE);
void deleteInS (int i,kStrategy strat);
void cleanT (kStrategy strat);
static inline LSet initL (int nr=setmaxL)
{ return (LSet)omAlloc(nr*sizeof(LObject)); }
void deleteInL(LSet set, int *length, int j,kStrategy strat);
void enterL (LSet *set,int *length, int *LSetmax, LObject p,int at);
void enterSBba (LObject* p,int atS,kStrategy strat, int atR = -1);
void enterSBbaShift (LObject* p,int atS,kStrategy strat, int atR = -1);
void enterSSba (LObject* p,int atS,kStrategy strat, int atR = -1);
void initEcartPairBba (LObject* Lp,poly f,poly g,int ecartF,int ecartG);
void initEcartPairMora (LObject* Lp,poly f,poly g,int ecartF,int ecartG);
int posInS (const kStrategy strat, const int length, const poly p,
const int ecart_p);
int posInSMonFirst (const kStrategy strat, const int length, const poly p);
int posInIdealMonFirst (const ideal F, const poly p,int start = 0,int end = -1);
int posInT0 (const TSet set,const int length,LObject &p);
int posInT1 (const TSet set,const int length,LObject &p);
int posInT2 (const TSet set,const int length,LObject &p);
int posInT11 (const TSet set,const int length,LObject &p);
int posInTSig (const TSet set,const int length,LObject &p);
int posInT110 (const TSet set,const int length,LObject &p);
int posInT13 (const TSet set,const int length,LObject &p);
int posInT15 (const TSet set,const int length,LObject &p);
int posInT17 (const TSet set,const int length,LObject &p);
int posInT17_c (const TSet set,const int length,LObject &p);
int posInT19 (const TSet set,const int length,LObject &p);
int posInT_EcartpLength(const TSet set,const int length,LObject &p);
int posInT_EcartFDegpLength(const TSet set,const int length,LObject &p);
int posInT_FDegpLength(const TSet set,const int length,LObject &p);
int posInT_pLength(const TSet set,const int length,LObject &p);
#ifdef HAVE_MORE_POS_IN_T
int posInT_EcartFDegpLength(const TSet set,const int length,LObject &p);
int posInT_FDegpLength(const TSet set,const int length,LObject &p);
int posInT_pLength(const TSet set,const int length,LObject &p);
#endif
void reorderS (int* suc,kStrategy strat);
//int posInLF5C (const LSet set, const int length,
// LObject* L,const kStrategy strat);
int posInLSig (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInLSigRing (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInSyz (const kStrategy strat, const poly sig);
int posInL0 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL11 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL11Ring (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInLF5CRing (const LSet set, int start , const int length,
LObject* L,const kStrategy strat);
int posInL11Ringls (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL13 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL15 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL15Ring (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL17 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL10 (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL10Ring (const LSet set, const int length,
LObject* L,const kStrategy strat);
int posInL110 (const LSet set, const int length,
LObject* L,const kStrategy strat);
KINLINE poly redtailBba (poly p,int end_pos,kStrategy strat,BOOLEAN normalize=FALSE);
KINLINE poly redtailBbaBound (poly p,int end_pos,kStrategy strat,int bound,BOOLEAN normalize=FALSE);
KINLINE poly redtailBba_Ring (poly p,int end_pos,kStrategy strat);
KINLINE poly redtailBba_Z (poly p,int end_pos,kStrategy strat);
poly redtailBba_NF (poly p, kStrategy strat );
poly redtailBba_Ring (LObject* L, int end_pos, kStrategy strat );
poly redtailBba_Z (LObject* L, int end_pos, kStrategy strat );
void redtailBbaAlsoLC_Z (LObject* L, int end_pos, kStrategy strat );
poly redtailBba (LObject *L, int end_pos,kStrategy strat,
BOOLEAN withT = FALSE,BOOLEAN normalize=FALSE);
poly redtailBbaBound (LObject *L, int end_pos,kStrategy strat,int bound,
BOOLEAN withT = FALSE,BOOLEAN normalize=FALSE);
poly redtailSba (LObject *L, int end_pos,kStrategy strat,
BOOLEAN withT = FALSE,BOOLEAN normalize=FALSE);
poly redtailBba (TObject *T, int end_pos,kStrategy strat);
poly redtail (poly p,int end_pos,kStrategy strat);
poly redtail (LObject *L,int end_pos,kStrategy strat);
poly redNF (poly h,int & max_ind,int nonorm,kStrategy strat);
int redNF0 (LObject *P,kStrategy strat);
poly redNFTail (poly h,const int sl,kStrategy strat);
int redHoney (LObject* h, kStrategy strat);
int redHoneyM (LObject* h, kStrategy strat);
int redLiftstd (LObject* h, kStrategy strat);
int redRing (LObject* h,kStrategy strat);
int redRing_Z (LObject* h,kStrategy strat);
int redRiloc (LObject* h,kStrategy strat);
void enterExtendedSpoly(poly h,kStrategy strat);
void enterExtendedSpolySig(poly h,poly hSig,kStrategy strat);
void superenterpairs (poly h,int k,int ecart,int pos,kStrategy strat, int atR = -1);
void superenterpairsSig (poly h,poly hSig,int hFrom,int k,int ecart,int pos,kStrategy strat, int atR = -1);
int redLazy (LObject* h,kStrategy strat);
int redHomog (LObject* h,kStrategy strat);
int redSig (LObject* h,kStrategy strat);
int redSigRing (LObject* h,kStrategy strat);
//adds hSig to be able to check with F5's criteria when entering pairs!
void enterpairsSig (poly h, poly hSig, int from, int k, int ec, int pos,kStrategy strat, int atR = -1);
void enterpairs (poly h, int k, int ec, int pos,kStrategy strat, int atR = -1);
void entersets (LObject h);
void pairs ();
BOOLEAN sbaCheckGcdPair (LObject* h,kStrategy strat);
void message (int i,int* olddeg,int* reduc,kStrategy strat,int red_result);
void messageStat (int hilbcount,kStrategy strat);
void messageStatSBA (int hilbcount,kStrategy strat);
#ifdef KDEBUG
void messageSets (kStrategy strat);
#else
#define messageSets(s) do {} while (0)
#endif
void initEcartNormal (TObject* h);
void initEcartBBA (TObject* h);
void initS (ideal F, ideal Q,kStrategy strat);
void initSL (ideal F, ideal Q,kStrategy strat);
void initSLSba (ideal F, ideal Q,kStrategy strat);
/*************************************************
* when initializing a new bunch of principal
* syzygies at the beginning of a new iteration
* step in a signature-based algorithm we
* compute ONLY the leading elements of those
* syzygies, NOT the whole syzygy
* NOTE: this needs to be adjusted for a more
* general approach on signature-based algorithms
***********************************************/
void initSyzRules (kStrategy strat);
void updateS(BOOLEAN toT,kStrategy strat);
void enterSyz (LObject &p,kStrategy strat, int atT);
void enterT (LObject* p,kStrategy strat, int atT = -1);
#if STDZ_EXCHANGE_DURING_REDUCTIO
void replaceInLAndSAndT(LObject* p, int tj, kStrategy strat);
#endif
void enterT_strong (LObject* p,kStrategy strat, int atT = -1);
void cancelunit (LObject* p,BOOLEAN inNF=FALSE);
void HEckeTest (poly pp,kStrategy strat);
void initBuchMoraCrit(kStrategy strat);
void initSbaCrit(kStrategy strat);
void initHilbCrit(ideal F, ideal Q, bigintmat **hilb,kStrategy strat);
void initBuchMoraPos(kStrategy strat);
void initBuchMoraPosRing(kStrategy strat);
void initSbaPos(kStrategy strat);
void initBuchMora (ideal F, ideal Q,kStrategy strat);
void initSbaBuchMora (ideal F, ideal Q,kStrategy strat);
void exitBuchMora (kStrategy strat);
void exitSba (kStrategy strat);
void updateResult(ideal r,ideal Q,kStrategy strat);
void completeReduce (kStrategy strat, BOOLEAN withT=FALSE);
void kFreeStrat(kStrategy strat);
void enterOnePairNormal (int i,poly p,int ecart, int isFromQ,kStrategy strat, int atR);
void chainCritNormal (poly p,int ecart,kStrategy strat);
void chainCritOpt_1 (poly,int,kStrategy strat);
void chainCritSig (poly p,int ecart,kStrategy strat);
BOOLEAN homogTest(polyset F, int Fmax);
BOOLEAN newHEdge(kStrategy strat);
BOOLEAN syzCriterion(poly sig, unsigned long not_sevSig, kStrategy strat);
BOOLEAN syzCriterionInc(poly sig, unsigned long not_sevSig, kStrategy strat);
KINLINE BOOLEAN arriRewDummy(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start);
BOOLEAN arriRewCriterion(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start);
BOOLEAN arriRewCriterionPre(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start);
BOOLEAN faugereRewCriterion(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start);
BOOLEAN findMinLMPair(poly sig, unsigned long not_sevSig, kStrategy strat, int start);
/// returns index of p in TSet, or -1 if not found
int kFindInT(poly p, TSet T, int tlength);
#ifdef HAVE_SHIFTBBA
int kFindInTShift(poly p, TSet T, int tlength);
#endif
/// return -1 if no divisor is found
/// number of first divisor in T, otherwise
int kFindDivisibleByInT(const kStrategy strat, const LObject* L, const int start=0);
int kFindDivisibleByInT_ecart(const kStrategy strat, const LObject* L, const int ecart);
int kFindDivisibleByInT_Z(const kStrategy strat, const LObject* L, const int start=0);
int kFindSameLMInT_Z(const kStrategy strat, const LObject* L, const int start=0);
/// tests if T[0] divides the leading monomial of L, returns -1 if not
int kTestDivisibleByT0_Z(const kStrategy strat, const LObject* L);
/// return -1 if no divisor is found
/// number of first divisor in S, otherwise
int kFindDivisibleByInS(const kStrategy strat, int *max_ind, LObject* L);
int kFindNextDivisibleByInS(const kStrategy strat, int start,int max_ind, LObject* L);
TObject* kFindDivisibleByInS_T(kStrategy strat, int end_pos, LObject* L, TObject *T, long ecart = LONG_MAX);
/***************************************************************
*
* stuff to be inlined
*
***************************************************************/
KINLINE TSet initT ();
KINLINE TObject** initR();
KINLINE unsigned long* initsevT();
KINLINE poly k_LmInit_currRing_2_tailRing(poly p, ring tailRing, omBin bin);
KINLINE poly k_LmInit_tailRing_2_currRing(poly p, ring tailRing, omBin bin);
KINLINE poly k_LmShallowCopyDelete_currRing_2_tailRing(poly p, ring tailRing, omBin bin);
KINLINE poly k_LmShallowCopyDelete_tailRing_2_currRing(poly p, ring tailRing, omBin bin);
KINLINE poly k_LmInit_currRing_2_tailRing(poly p, ring tailRing);
KINLINE poly k_LmInit_tailRing_2_currRing(poly p, ring tailRing);
KINLINE poly k_LmShallowCopyDelete_currRing_2_tailRing(poly p, ring tailRing);
KINLINE poly k_LmShallowCopyDelete_tailRing_2_currRing(poly p, ring tailRing);
// if exp bound is not violated, return TRUE and
// get m1 = LCM(LM(p1), LM(p2))/LM(p1)
// m2 = LCM(LM(p1), LM(p2))/LM(p2)
// return FALSE and m1 == NULL, m2 == NULL , otherwise
KINLINE BOOLEAN k_GetLeadTerms(const poly p1, const poly p2, const ring p_r,
poly &m1, poly &m2, const ring m_r);
KINLINE void k_GetStrongLeadTerms(const poly p1, const poly p2, const ring leadRing,
poly &m1, poly &m2, poly &lcm, const ring taiRing);
#ifdef KDEBUG
// test strat
BOOLEAN kTest(kStrategy strat);
// test strat, and test that S is contained in T
BOOLEAN kTest_TS(kStrategy strat);
// test LObject
BOOLEAN kTest_L(LObject* L, kStrategy strat,
BOOLEAN testp = FALSE, int lpos = -1,
TSet T = NULL, int tlength = -1);
// test TObject
BOOLEAN kTest_T(TObject* T, kStrategy strat, int tpos = -1, char TN = '?');
// test set strat->SevS
BOOLEAN kTest_S(kStrategy strat);
#else
#define kTest(A) (TRUE)
#define kTest_TS(A) (TRUE)
#define kTest_T(T,S) (TRUE)
#define kTest_S(T) (TRUE)
#define kTest_L(T,R) (TRUE)
#endif
/***************************************************************
*
* From kstd1.cc
*
***************************************************************/
int redFirst (LObject* h,kStrategy strat);
int redEcart (LObject* h,kStrategy strat);
void enterSMora (LObject* p,int atS,kStrategy strat, int atR=-1);
void enterSMoraNF (LObject* p,int atS,kStrategy strat, int atR=-1);
/***************************************************************
*
* From kstd2.cc
*
***************************************************************/
poly kFindZeroPoly(poly input_p, ring leadRing, ring tailRing);
ideal bba (ideal F, ideal Q,intvec *w,bigintmat *hilb,kStrategy strat);
ideal sba (ideal F, ideal Q,intvec *w,bigintmat *hilb,kStrategy strat);
poly kNF2 (ideal F, ideal Q, poly q, kStrategy strat, int lazyReduce);
ideal kNF2 (ideal F,ideal Q,ideal q, kStrategy strat, int lazyReduce);
poly kNF2Bound (ideal F, ideal Q, poly q,int bound, kStrategy strat, int lazyReduce);
ideal kNF2Bound (ideal F,ideal Q,ideal q,int bound, kStrategy strat, int lazyReduce);
void initBba(kStrategy strat);
void initSba(ideal F,kStrategy strat);
void f5c (kStrategy strat, int& olddeg, int& minimcnt, int& hilbeledeg,
int& hilbcount, int& srmax, int& lrmax, int& reduc, ideal Q,
intvec *w,bigintmat *hilb );
/***************************************************************
*
* From kspoly.cc
*
***************************************************************/
// Reduces PR with PW
// Assumes PR != NULL, PW != NULL, Lm(PW) divides Lm(PR)
// Changes: PR
// Const: PW
// If coef != NULL, then *coef is a/gcd(a,b), where a = LC(PR), b = LC(PW)
// If strat != NULL, tailRing is changed if reduction would violate exp bound
// of tailRing
// Returns: 0 everything ok, no tailRing change
// 1 tailRing has successfully changed (strat != NULL)
// 2 no reduction performed, tailRing needs to be changed first
// (strat == NULL)
// -1 tailRing change could not be performed due to exceeding exp
// bound of currRing
// reduce should be set inside "kNF" (only relevant for rings)
int ksReducePoly(LObject* PR,
TObject* PW,
poly spNoether = NULL,
number *coef = NULL,
poly *mon =NULL,
kStrategy strat = NULL,
BOOLEAN redtail = FALSE);
/* like ksReducePoly, but if the reducer has only 1 term we still
* compute a possible coefficient multiplier for PR. this comes from
* a special situation in redRing_Z and it is used only there. */
int ksReducePolyZ(LObject* PR,
TObject* PW,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
int ksReducePolyLC(LObject* PR,
TObject* PW,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
int ksReducePolyGCD(LObject* PR,
TObject* PW,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
int ksReducePolyBound(LObject* PR,
TObject* PW,
int bound,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
// Reduces PR with PW
// Assumes PR != NULL, PW != NULL, Lm(PW) divides Lm(PR)
// Changes: PR
// Const: PW
// If coef != NULL, then *coef is a/gcd(a,b), where a = LC(PR), b = LC(PW)
// If strat != NULL, tailRing is changed if reduction would violate exp bound
// of tailRing
// Returns: 0 everything ok, no tailRing change
// 1 tailRing has successfully changed (strat != NULL)
// 2 no reduction performed, tailRing needs to be changed first
// (strat == NULL)
// 3 no reduction performed, not sig-safe!!!
// -1 tailRing change could not be performed due to exceeding exp
// bound of currRing
int ksReducePolySig(LObject* PR,
TObject* PW,
long idx,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
int ksReducePolySigRing(LObject* PR,
TObject* PW,
long idx,
poly spNoether = NULL,
number *coef = NULL,
kStrategy strat = NULL);
// Reduces PR at Current->next with PW
// Assumes PR != NULL, Current contained in PR
// Current->next != NULL, LM(PW) divides LM(Current->next)
// Changes: PR
// Const: PW
// Return: see ksReducePoly
int ksReducePolyTail(LObject* PR,
TObject* PW,
poly Current,
poly spNoether = NULL);
KINLINE int ksReducePolyTail(LObject* PR, TObject* PW, LObject* Red);
// Creates S-Poly of Pair
// Const: Pair->p1, Pair->p2
// Changes: Pair->p == S-Poly of p1, p2
// Assume: Pair->p1 != NULL && Pair->p2
void ksCreateSpoly(LObject* Pair, poly spNoether = NULL,
int use_buckets=0, ring tailRing=currRing,
poly m1 = NULL, poly m2 = NULL, TObject** R = NULL);
/*2
* creates the leading term of the S-polynomial of p1 and p2
* do not destroy p1 and p2
* remarks:
* 1. the coefficient is 0 (nNew)
* 2. pNext is undefined
*/
poly ksCreateShortSpoly(poly p1, poly p2, ring tailRing);
// old stuff
KINLINE poly ksOldSpolyRed(poly p1, poly p2, poly spNoether = NULL);
KINLINE poly ksOldSpolyRedNew(poly p1, poly p2, poly spNoether = NULL);
KINLINE poly ksOldCreateSpoly(poly p1, poly p2, poly spNoether = NULL, ring r = currRing);
KINLINE void ksOldSpolyTail(poly p1, poly q, poly q2, poly spNoether, ring r = currRing);
/***************************************************************
*
* Routines related for ring changes during std computations
*
***************************************************************/
// return TRUE and set m1, m2 to k_GetLcmTerms,
// if spoly creation of strat->P does not violate
// exponent bound of strat->tailRing
// FALSE, otherwise
BOOLEAN kCheckSpolyCreation(LObject* L, kStrategy strat, poly &m1, poly &m2);
// return TRUE if gcdpoly creation of R[atR] and S[atS] does not violate
// exponent bound of strat->tailRing
// FALSE, otherwise
BOOLEAN kCheckStrongCreation(int atR, poly m1, int atS, poly m2, kStrategy strat);
poly preIntegerCheck(ideal F, ideal Q);
void postReduceByMon(LObject* h, kStrategy strat);
void postReduceByMonSig(LObject* h, kStrategy strat);
void finalReduceByMon(kStrategy strat);
// change strat->tailRing and adjust all data in strat, L, and T:
// new tailRing has larger exponent bound
// do nothing and return FALSE if exponent bound increase would result in
// larger exponent bound that that of currRing
BOOLEAN kStratChangeTailRing(kStrategy strat,
LObject* L = NULL, TObject* T = NULL,
// take this as new_expbound: if 0
// new expbound is 2*expbound of tailRing
unsigned long new_expbound = 0);
// initiate a change of the tailRing of strat -- should be called
// right before main loop in bba
void kStratInitChangeTailRing(kStrategy strat);
/// Output some debug info about a given strategy
void kDebugPrint(kStrategy strat);
// getting sb order for sba computations
ring sbaRing(kStrategy strat, const ring r=currRing, BOOLEAN complete=TRUE, int sgn=1);
KINLINE void clearS (poly p, unsigned long p_sev, int* at, int* k,
kStrategy strat);
#include "kernel/GBEngine/kInline.h"
/* shiftgb stuff */
#include "kernel/GBEngine/shiftgb.h"
#ifdef HAVE_SHIFTBBA
static inline int kFindInL1(const poly p, const kStrategy strat)
{
for(int i=strat->Ll;i>=0;i--)
{
if (p==strat->L[i].p1) return i;
}
return -1;
}
void enterTShift(LObject* p, kStrategy strat, int atT = -1);
BOOLEAN enterOnePairShift (poly q, poly p, int ecart, int isFromQ, kStrategy strat, int atR, int ecartq, int qisFromQ, int shiftcount, int ifromS);
void enterpairsShift (poly h,int k,int ecart,int pos,kStrategy strat, int atR);
void superenterpairsShift (poly h,int k,int ecart,int pos,kStrategy strat, int atR);
poly redtailBbaShift (LObject* L, int pos, kStrategy strat, BOOLEAN withT, BOOLEAN normalize);
int redFirstShift (LObject* h,kStrategy strat); // ok
ideal bbaShift(ideal F, ideal Q,intvec *w,bigintmat *hilb,kStrategy strat);
#endif
static inline void kDeleteLcm(LObject *P)
{
if (P->lcm!=NULL)
{
if (rField_is_Ring(currRing))
pLmDelete(P->lcm);
else
pLmFree(P->lcm);
P->lcm=NULL;
}
}
void initenterpairs (poly h,int k,int ecart,int isFromQ,kStrategy strat, int atR = -1);
#endif
sgn
int sgn(const Rational &a)
Definition GMPrat.cc:430
int64
long int64
Definition auxiliary.h:68
BOOLEAN
int BOOLEAN
Definition auxiliary.h:88
TRUE
#define TRUE
Definition auxiliary.h:101
FALSE
#define FALSE
Definition auxiliary.h:97
bigintmat.h
pp
CanonicalForm FACTORY_PUBLIC pp(const CanonicalForm &)
CanonicalForm pp ( const CanonicalForm & f ).
Definition cf_gcd.cc:676
l
int l
Definition cfEzgcd.cc:100
m
int m
Definition cfEzgcd.cc:128
i
int i
Definition cfEzgcd.cc:132
k
int k
Definition cfEzgcd.cc:99
p
int p
Definition cfModGcd.cc:4086
g
g
Definition cfModGcd.cc:4098
bound
static CanonicalForm bound(const CFMatrix &M)
Definition cf_linsys.cc:460
f
FILE * f
Definition checklibs.c:9
bigintmat
Matrices of numbers.
Definition bigintmat.h:51
intvec
Definition intvec.h:24
omallocClass
Definition omallocClass.h:20
sLObject
Definition kutil.h:185
sLObject::SetDegStuffReturnLDeg
KINLINE long SetDegStuffReturnLDeg()
Definition kInline.h:850
sLObject::Tail_Mult_nn
KINLINE void Tail_Mult_nn(number n)
Definition kInline.h:655
sLObject::i_r1
int i_r1
Definition kutil.h:194
sLObject::Copy
KINLINE void Copy()
Definition kInline.h:803
sLObject::Delete
KINLINE void Delete()
Definition kInline.h:585
sLObject::LmDeleteAndIter
KINLINE void LmDeleteAndIter()
Definition kInline.h:691
sLObject::T_2
KINLINE TObject * T_2(const skStrategy *strat)
Definition kInline.h:921
sLObject::PrepareRed
KINLINE void PrepareRed(BOOLEAN use_bucket)
Definition kInline.h:616
sLObject::checked
unsigned checked
Definition kutil.h:195
sLObject::CanonicalizeP
KINLINE void CanonicalizeP()
Definition kInline.h:361
sLObject::SetLmTail
KINLINE void SetLmTail(poly lm, poly new_p, int length, int use_bucket, ring r)
Definition kInline.h:637
sLObject::T_1_2
KINLINE void T_1_2(const skStrategy *strat, TObject *&T_1, TObject *&T_2)
Definition kInline.h:932
sLObject::Normalize
KINLINE void Normalize()
Definition kInline.h:347
sLObject::sev
unsigned long sev
Definition kutil.h:188
sLObject::Init
KINLINE void Init(ring tailRing=currRing)
Definition kInline.h:592
sLObject::MinComp
KINLINE long MinComp()
Definition kInline.h:881
sLObject::bucket
kBucket_pt bucket
Definition kutil.h:193
sLObject::p2
poly p2
Definition kutil.h:189
sLObject::prod_crit
BOOLEAN prod_crit
Definition kutil.h:200
sLObject::T_1
KINLINE TObject * T_1(const skStrategy *strat)
Definition kInline.h:911
sLObject::GetpLength
KINLINE int GetpLength()
Definition kInline.h:864
sLObject::SetLength
KINLINE int SetLength(BOOLEAN lengt_pLength=FALSE)
Definition kInline.h:871
sLObject::lcm
poly lcm
Definition kutil.h:192
sLObject::Clear
KINLINE void Clear()
Definition kInline.h:578
sLObject::Tail_Minus_mm_Mult_qq
KINLINE void Tail_Minus_mm_Mult_qq(poly m, poly qq, int lq, poly spNoether)
Definition kInline.h:669
sLObject::ShallowCopyDelete
KINLINE void ShallowCopyDelete(ring new_tailRing, pShallowCopyDeleteProc p_shallow_copy_delete)
Definition kInline.h:780
sLObject::GetTP
KINLINE poly GetTP()
Definition kInline.h:737
sLObject::pLDeg
KINLINE long pLDeg()
Definition kInline.h:819
sLObject::operator=
KINLINE sLObject & operator=(const sTObject &)
Definition kInline.h:905
sLObject::SetShortExpVector
KINLINE void SetShortExpVector()
Definition kInline.h:791
sLObject::HeadNormalize
KINLINE void HeadNormalize()
Definition kInline.h:367
sLObject::GetP
KINLINE poly GetP(omBin lmBin=(omBin) NULL)
Definition kInline.h:753
sLObject::sLObject
KINLINE sLObject(ring tailRing=currRing)
Definition kInline.h:600
sLObject::p1
poly p1
Definition kutil.h:189
sLObject::Comp
KINLINE long Comp()
Definition kInline.h:896
sLObject::LmExtractAndIter
KINLINE poly LmExtractAndIter()
Definition kInline.h:711
sLObject::i_r2
int i_r2
Definition kutil.h:194
sTObject
Definition kutil.h:70
sTObject::GetLm
KINLINE poly GetLm(ring r)
Definition kInline.h:262
sTObject::GetLmCurrRing
KINLINE poly GetLmCurrRing()
Definition kInline.h:242
sTObject::is_redundant
char is_redundant
Definition kutil.h:94
sTObject::sig
poly sig
Definition kutil.h:73
sTObject::Init
KINLINE void Init(ring r=currRing)
Definition kInline.h:110
sTObject::Mult_nn
KINLINE void Mult_nn(number n)
Definition kInline.h:334
sTObject::length
int length
Definition kutil.h:80
sTObject::SetDegStuffReturnLDeg
KINLINE long SetDegStuffReturnLDeg()
Definition kInline.h:446
sTObject::GetLmTailRing
KINLINE poly GetLmTailRing()
Definition kInline.h:249
sTObject::pCleardenom
KINLINE void pCleardenom()
Definition kInline.h:458
sTObject::ecart
int ecart
Definition kutil.h:79
sTObject::GetpFDeg
KINLINE long GetpFDeg() const
Definition kInline.h:437
sTObject::sTObject
KINLINE sTObject(ring tailRing=currRing)
Definition kInline.h:116
sTObject::ShallowCopyDelete
KINLINE void ShallowCopyDelete(ring new_tailRing, omBin new_tailBin, pShallowCopyDeleteProc p_shallow_copy_delete, BOOLEAN set_max=TRUE)
Definition kInline.h:381
sTObject::is_special
char is_special
Definition kutil.h:103
sTObject::SetLmCurrRing
KINLINE void SetLmCurrRing()
Definition kInline.h:299
sTObject::max_exp
poly max_exp
Definition kutil.h:76
sTObject::is_normalized
char is_normalized
Definition kutil.h:88
sTObject::pLDeg
KINLINE long pLDeg()
Definition kInline.h:442
sTObject::is_sigsafe
char is_sigsafe
Definition kutil.h:99
sTObject::LmDeleteAndIter
KINLINE void LmDeleteAndIter()
Definition kInline.h:313
sTObject::pLength
int pLength
Definition kutil.h:81
sTObject::pFDeg
KINLINE long pFDeg() const
Definition kInline.h:422
sTObject::i_r
int i_r
Definition kutil.h:82
sTObject::p
poly p
Definition kutil.h:74
sTObject::IsNull
KINLINE BOOLEAN IsNull() const
Definition kInline.h:288
sTObject::Set
KINLINE void Set(ring r=currRing)
Definition kInline.h:106
sTObject::Delete
KINLINE void Delete()
Definition kInline.h:199
sTObject::t_p
poly t_p
Definition kutil.h:75
sTObject::tailRing
ring tailRing
Definition kutil.h:77
sTObject::GetpLength
KINLINE int GetpLength()
Definition kInline.h:293
sTObject::pNorm
KINLINE void pNorm()
Definition kInline.h:558
sTObject::Clear
KINLINE void Clear()
Definition kInline.h:213
sTObject::FDeg
long FDeg
Definition kutil.h:78
sTObject::Next
KINLINE poly Next()
Definition kInline.h:305
sTObject::wrp
void wrp()
Definition kutil.cc:757
sTObject::shift
int shift
Definition kutil.h:85
sTObject::pContent
KINLINE void pContent()
Definition kInline.h:536
sTObject::pTotalDeg
KINLINE long pTotalDeg() const
Definition kInline.h:427
sTObject::SetpFDeg
KINLINE long SetpFDeg()
Definition kInline.h:432
sTObject::sevSig
unsigned long sevSig
Definition kutil.h:72
sTObject::Copy
KINLINE void Copy()
Definition kInline.h:224
skStrategy
Definition kutil.h:276
skStrategy::kNoetherTail
KINLINE poly kNoetherTail()
Definition kInline.h:66
skStrategy::sevSyz
unsigned long * sevSyz
Definition kutil.h:322
skStrategy::next
kStrategy next
Definition kutil.h:278
skStrategy::kModW
intvec * kModW
Definition kutil.h:334
skStrategy::sigdrop
bool sigdrop
Definition kutil.h:357
skStrategy::t_kNoether
poly t_kNoether
Definition kutil.h:329
skStrategy::syzComp
int syzComp
Definition kutil.h:353
skStrategy::S_2_R
int * S_2_R
Definition kutil.h:341
skStrategy::tailRing
ring tailRing
Definition kutil.h:342
skStrategy::chainCrit
void(* chainCrit)(poly p, int ecart, kStrategy strat)
Definition kutil.h:290
skStrategy::D
ideal D
Definition kutil.h:303
skStrategy::noTailReduction
char noTailReduction
Definition kutil.h:375
skStrategy::currIdx
int currIdx
Definition kutil.h:316
skStrategy::~skStrategy
~skStrategy()
Definition kutil.cc:11306
skStrategy::skStrategy
skStrategy()
Definition kutil.cc:11286
skStrategy::nrsyzcrit
int nrsyzcrit
Definition kutil.h:358
skStrategy::lenS
intset lenS
Definition kutil.h:318
skStrategy::nrrewcrit
int nrrewcrit
Definition kutil.h:359
skStrategy::posInLOldFlag
char posInLOldFlag
Definition kutil.h:379
skStrategy::pOrigFDeg_TailRing
pFDegProc pOrigFDeg_TailRing
Definition kutil.h:297
skStrategy::Ll
int Ll
Definition kutil.h:350
skStrategy::T
TSet T
Definition kutil.h:325
skStrategy::rewCrit1
BOOLEAN(* rewCrit1)(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.h:292
skStrategy::news
char news
Definition kutil.h:397
skStrategy::lmBin
omBin lmBin
Definition kutil.h:343
skStrategy::syzmax
int syzmax
Definition kutil.h:348
skStrategy::Bl
int Bl
Definition kutil.h:351
skStrategy::ecartS
intset ecartS
Definition kutil.h:308
skStrategy::syzidxmax
int syzidxmax
Definition kutil.h:348
skStrategy::honey
char honey
Definition kutil.h:374
skStrategy::rightGB
char rightGB
Definition kutil.h:366
skStrategy::S
polyset S
Definition kutil.h:305
skStrategy::minim
int minim
Definition kutil.h:356
skStrategy::kNoether
poly kNoether
Definition kutil.h:328
skStrategy::NotUsedAxis
BOOLEAN * NotUsedAxis
Definition kutil.h:331
skStrategy::B
LSet B
Definition kutil.h:327
skStrategy::pairtest
BOOLEAN * pairtest
Definition kutil.h:332
skStrategy::cp
int cp
Definition kutil.h:346
skStrategy::ak
int ak
Definition kutil.h:352
skStrategy::R
TObject ** R
Definition kutil.h:339
skStrategy::rewCrit3
BOOLEAN(* rewCrit3)(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.h:294
skStrategy::lastAxis
int lastAxis
Definition kutil.h:354
skStrategy::M
ideal M
Definition kutil.h:304
skStrategy::tl
int tl
Definition kutil.h:349
skStrategy::red2
int(* red2)(LObject *L, kStrategy strat)
Definition kutil.h:280
skStrategy::sevT
unsigned long * sevT
Definition kutil.h:324
skStrategy::sevSig
unsigned long * sevSig
Definition kutil.h:323
skStrategy::nr
int nr
Definition kutil.h:345
skStrategy::kHomW
intvec * kHomW
Definition kutil.h:335
skStrategy::max_lower_index
int max_lower_index
Definition kutil.h:317
skStrategy::tail
poly tail
Definition kutil.h:333
skStrategy::sugarCrit
char sugarCrit
Definition kutil.h:374
skStrategy::posInL
int(* posInL)(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.h:283
skStrategy::s_2_t
KINLINE TObject * s_2_t(int i)
Definition kInline.h:47
skStrategy::blockred
int blockred
Definition kutil.h:362
skStrategy::syzIdx
intset syzIdx
Definition kutil.h:312
skStrategy::Shdl
ideal Shdl
Definition kutil.h:302
skStrategy::syzl
int syzl
Definition kutil.h:348
skStrategy::sbaOrder
unsigned sbaOrder
Definition kutil.h:315
skStrategy::pOrigFDeg
pFDegProc pOrigFDeg
Definition kutil.h:295
skStrategy::blockredmax
int blockredmax
Definition kutil.h:363
skStrategy::tmax
int tmax
Definition kutil.h:349
skStrategy::posInLOld
int(* posInLOld)(const LSet Ls, const int Ll, LObject *Lo, const kStrategy strat)
Definition kutil.h:287
skStrategy::sig
polyset sig
Definition kutil.h:307
skStrategy::syz
polyset syz
Definition kutil.h:306
skStrategy::LDegLast
char LDegLast
Definition kutil.h:382
skStrategy::initEcartPair
void(* initEcartPair)(LObject *h, poly f, poly g, int ecartF, int ecartG)
Definition kutil.h:286
skStrategy::syzCrit
BOOLEAN(* syzCrit)(poly sig, unsigned long not_sevSig, kStrategy strat)
Definition kutil.h:291
skStrategy::lenSw
wlen_set lenSw
Definition kutil.h:319
skStrategy::enterS
void(* enterS)(LObject *h, int pos, kStrategy strat, int atR)
Definition kutil.h:285
skStrategy::kAllAxis
char kAllAxis
Definition kutil.h:373
skStrategy::cv
int cv
Definition kutil.h:365
skStrategy::noetherSet
char noetherSet
Definition kutil.h:377
skStrategy::p_shallow_copy_delete
pShallowCopyDeleteProc p_shallow_copy_delete
Definition kutil.h:337
skStrategy::Gebauer
char Gebauer
Definition kutil.h:375
skStrategy::fromQ
intset fromQ
Definition kutil.h:320
skStrategy::newt
char newt
Definition kutil.h:398
skStrategy::use_buckets
char use_buckets
Definition kutil.h:380
skStrategy::mu
int mu
Definition kutil.h:347
skStrategy::interpt
char interpt
Definition kutil.h:368
skStrategy::redTailChange
char redTailChange
Definition kutil.h:396
skStrategy::newIdeal
int newIdeal
Definition kutil.h:355
skStrategy::fromT
char fromT
Definition kutil.h:376
skStrategy::completeReduce_retry
char completeReduce_retry
Definition kutil.h:400
skStrategy::initEcart
void(* initEcart)(TObject *L)
Definition kutil.h:281
skStrategy::tailBin
omBin tailBin
Definition kutil.h:344
skStrategy::P
LObject P
Definition kutil.h:301
skStrategy::S_2_T
KINLINE TObject * S_2_T(int i)
Definition kInline.h:38
skStrategy::noClearS
char noClearS
Definition kutil.h:399
skStrategy::Lmax
int Lmax
Definition kutil.h:350
skStrategy::z2homog
char z2homog
Definition kutil.h:371
skStrategy::LazyPass
int LazyPass
Definition kutil.h:352
skStrategy::no_prod_crit
char no_prod_crit
Definition kutil.h:391
skStrategy::overflow
char overflow
Definition kutil.h:401
skStrategy::enterOnePair
void(* enterOnePair)(int i, poly p, int ecart, int isFromQ, kStrategy strat, int atR)
Definition kutil.h:289
skStrategy::L
LSet L
Definition kutil.h:326
skStrategy::length_pLength
char length_pLength
Definition kutil.h:384
skStrategy::posInT
int(* posInT)(const TSet T, const int tl, LObject &h)
Definition kutil.h:282
skStrategy::red
int(* red)(LObject *L, kStrategy strat)
Definition kutil.h:279
skStrategy::rewCrit2
BOOLEAN(* rewCrit2)(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.h:293
skStrategy::sl
int sl
Definition kutil.h:347
skStrategy::sbaEnterS
int sbaEnterS
Definition kutil.h:360
skStrategy::LazyDegree
int LazyDegree
Definition kutil.h:352
skStrategy::posInLDependsOnLength
char posInLDependsOnLength
Definition kutil.h:386
skStrategy::sevS
unsigned long * sevS
Definition kutil.h:321
skStrategy::homog
char homog
Definition kutil.h:369
skStrategy::pOrigLDeg
pLDegProc pOrigLDeg
Definition kutil.h:296
skStrategy::fromS
intset fromS
Definition kutil.h:309
skStrategy::update
char update
Definition kutil.h:378
skStrategy::s_poly
s_poly_proc_t s_poly
Definition kutil.h:299
skStrategy::pOrigLDeg_TailRing
pLDegProc pOrigLDeg_TailRing
Definition kutil.h:298
skStrategy::Bmax
int Bmax
Definition kutil.h:351
skStrategy::c3
int c3
Definition kutil.h:346
w
const CanonicalForm & w
Definition facAbsFact.cc:51
copy
CFArray copy(const CFList &list)
write elements of list into an array
Definition facFqBivarUtil.cc:364
j
int j
Definition facHensel.cc:110
EXTERN_VAR
#define EXTERN_VAR
Definition globaldefs.h:6
length
static BOOLEAN length(leftv result, leftv arg)
Definition interval.cc:257
T
STATIC_VAR jList * T
Definition janet.cc:30
h
STATIC_VAR Poly * h
Definition janet.cc:971
kInline.h
kstd1.h
s_poly_proc_t
BOOLEAN(* s_poly_proc_t)(kStrategy strat)
Definition kstd1.h:15
strat_nr
VAR int strat_nr
Definition kstdfac.cc:21
redtail
poly redtail(LObject *L, int end_pos, kStrategy strat)
Definition kutil.cc:6836
HCord
VAR int HCord
Definition kutil.cc:239
DENOMINATOR_LIST
VAR denominator_list DENOMINATOR_LIST
Definition kutil.cc:79
ksOldSpolyTail
KINLINE void ksOldSpolyTail(poly p1, poly q, poly q2, poly spNoether, ring r=currRing)
Definition kInline.h:1204
initSbaPos
void initSbaPos(kStrategy strat)
Definition kutil.cc:9863
findMinLMPair
BOOLEAN findMinLMPair(poly sig, unsigned long not_sevSig, kStrategy strat, int start)
ksReducePolyGCD
int ksReducePolyGCD(LObject *PR, TObject *PW, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
ksReducePolyLC
int ksReducePolyLC(LObject *PR, TObject *PW, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
Definition kspoly.cc:477
initenterpairs
void initenterpairs(poly h, int k, int ecart, int isFromQ, kStrategy strat, int atR=-1)
Definition kutil.cc:3809
posInSyz
int posInSyz(const kStrategy strat, const poly sig)
Definition kutil.cc:5758
redLiftstd
int redLiftstd(LObject *h, kStrategy strat)
Definition kLiftstd.cc:167
ksReducePolyBound
int ksReducePolyBound(LObject *PR, TObject *PW, int bound, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
Definition kspoly.cc:590
kFindDivisibleByInT
int kFindDivisibleByInT(const kStrategy strat, const LObject *L, const int start=0)
return -1 if no divisor is found number of first divisor in T, otherwise
Definition kstd2.cc:317
redRing_Z
int redRing_Z(LObject *h, kStrategy strat)
Definition kstd2.cc:720
posInT17
int posInT17(const TSet set, const int length, LObject &p)
Definition kutil.cc:5278
posInL13
int posInL13(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:6145
initBuchMora
void initBuchMora(ideal F, ideal Q, kStrategy strat)
Definition kutil.cc:9749
initEcartPairBba
void initEcartPairBba(LObject *Lp, poly f, poly g, int ecartF, int ecartG)
Definition kutil.cc:1308
redFirst
int redFirst(LObject *h, kStrategy strat)
Definition kstd1.cc:794
denominator_list
denominator_list_s * denominator_list
Definition kutil.h:64
wlen_set
wlen_type * wlen_set
Definition kutil.h:56
kFindZeroPoly
poly kFindZeroPoly(poly input_p, ring leadRing, ring tailRing)
Definition kstd2.cc:609
enterSSba
void enterSSba(LObject *p, int atS, kStrategy strat, int atR=-1)
Definition kutil.cc:8915
redFirstShift
int redFirstShift(LObject *h, kStrategy strat)
Definition kstd2.cc:4951
arriRewCriterionPre
BOOLEAN arriRewCriterionPre(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.cc:6646
enterSyz
void enterSyz(LObject &p, kStrategy strat, int atT)
Definition kutil.cc:9343
posInL15
int posInL15(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:6180
redNF0
int redNF0(LObject *P, kStrategy strat)
redEcart
int redEcart(LObject *h, kStrategy strat)
Definition kstd1.cc:168
posInT11
int posInT11(const TSet set, const int length, LObject &p)
Definition kutil.cc:4953
posInLSigRing
int posInLSigRing(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5694
ksReducePolySigRing
int ksReducePolySigRing(LObject *PR, TObject *PW, long idx, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
Definition kspoly.cc:943
posInTSig
int posInTSig(const TSet set, const int length, LObject &p)
posInT1
int posInT1(const TSet set, const int length, LObject &p)
Definition kutil.cc:4896
ksReducePolySig
int ksReducePolySig(LObject *PR, TObject *PW, long idx, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
Definition kspoly.cc:737
message
void message(int i, int *olddeg, int *reduc, kStrategy strat, int red_result)
Definition kutil.cc:7463
kTest
BOOLEAN kTest(kStrategy strat)
Definition kutil.cc:1004
chainCritSig
void chainCritSig(poly p, int ecart, kStrategy strat)
Definition kutil.cc:3461
posInT_EcartpLength
int posInT_EcartpLength(const TSet set, const int length, LObject &p)
Definition kutil.cc:5146
kTest_TS
BOOLEAN kTest_TS(kStrategy strat)
Definition kutil.cc:1067
kFindDivisibleByInS
int kFindDivisibleByInS(const kStrategy strat, int *max_ind, LObject *L)
return -1 if no divisor is found number of first divisor in S, otherwise
Definition kstd2.cc:464
kFindInT
int kFindInT(poly p, TSet T, int tlength)
returns index of p in TSet, or -1 if not found
Definition kutil.cc:703
kCheckStrongCreation
BOOLEAN kCheckStrongCreation(int atR, poly m1, int atS, poly m2, kStrategy strat)
Definition kutil.cc:10497
ksReducePoly
int ksReducePoly(LObject *PR, TObject *PW, poly spNoether=NULL, number *coef=NULL, poly *mon=NULL, kStrategy strat=NULL, BOOLEAN redtail=FALSE)
Definition kspoly.cc:187
kTestDivisibleByT0_Z
int kTestDivisibleByT0_Z(const kStrategy strat, const LObject *L)
tests if T[0] divides the leading monomial of L, returns -1 if not
Definition kstd2.cc:142
kTest_L
BOOLEAN kTest_L(LObject *L, kStrategy strat, BOOLEAN testp=FALSE, int lpos=-1, TSet T=NULL, int tlength=-1)
Definition kutil.cc:916
TSet
TObject * TSet
Definition kutil.h:60
enterSBbaShift
void enterSBbaShift(LObject *p, int atS, kStrategy strat, int atR=-1)
Definition kutil.cc:8892
enterL
void enterL(LSet *set, int *length, int *LSetmax, LObject p, int at)
Definition kutil.cc:1269
enterTShift
void enterTShift(LObject *p, kStrategy strat, int atT=-1)
Definition kutil.cc:12957
posInL17
int posInL17(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:6255
setmaxL
#define setmaxL
Definition kutil.h:31
kFindSameLMInT_Z
int kFindSameLMInT_Z(const kStrategy strat, const LObject *L, const int start=0)
posInT2
int posInT2(const TSet set, const int length, LObject &p)
Definition kutil.cc:4925
posInL15Ring
int posInL15Ring(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:6215
superenterpairsSig
void superenterpairsSig(poly h, poly hSig, int hFrom, int k, int ecart, int pos, kStrategy strat, int atR=-1)
Definition kutil.cc:4470
posInT_pLength
int posInT_pLength(const TSet set, const int length, LObject &p)
Definition kutil.cc:11449
completeReduce
void completeReduce(kStrategy strat, BOOLEAN withT=FALSE)
Definition kutil.cc:10257
initHilbCrit
void initHilbCrit(ideal F, ideal Q, bigintmat **hilb, kStrategy strat)
Definition kutil.cc:9417
enterOnePairNormal
void enterOnePairNormal(int i, poly p, int ecart, int isFromQ, kStrategy strat, int atR)
Definition kutil.cc:1939
kFindInL1
static int kFindInL1(const poly p, const kStrategy strat)
Definition kutil.h:852
posInT13
int posInT13(const TSet set, const int length, LObject &p)
Definition kutil.cc:5117
redtailBbaAlsoLC_Z
void redtailBbaAlsoLC_Z(LObject *L, int end_pos, kStrategy strat)
Definition kutil.cc:7140
kNF2
poly kNF2(ideal F, ideal Q, poly q, kStrategy strat, int lazyReduce)
Definition kstd2.cc:3927
enterSBba
void enterSBba(LObject *p, int atS, kStrategy strat, int atR=-1)
Definition kutil.cc:8792
syzCriterionInc
BOOLEAN syzCriterionInc(poly sig, unsigned long not_sevSig, kStrategy strat)
Definition kutil.cc:6513
deleteHC
void deleteHC(poly *p, int *e, int *l, kStrategy strat)
Definition kutil.cc:351
kFindDivisibleByInT_ecart
int kFindDivisibleByInT_ecart(const kStrategy strat, const LObject *L, const int ecart)
Definition kstd2.cc:416
posInSMonFirst
int posInSMonFirst(const kStrategy strat, const int length, const poly p)
Definition kutil.cc:4764
arriRewDummy
KINLINE BOOLEAN arriRewDummy(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kInline.h:1258
initBuchMoraPos
void initBuchMoraPos(kStrategy strat)
Definition kutil.cc:9580
initS
void initS(ideal F, ideal Q, kStrategy strat)
Definition kutil.cc:7586
posInIdealMonFirst
int posInIdealMonFirst(const ideal F, const poly p, int start=0, int end=-1)
Definition kutil.cc:4841
redtailBbaBound
KINLINE poly redtailBbaBound(poly p, int end_pos, kStrategy strat, int bound, BOOLEAN normalize=FALSE)
Definition kInline.h:1218
redHoney
int redHoney(LObject *h, kStrategy strat)
Definition kstd2.cc:2110
preIntegerCheck
poly preIntegerCheck(ideal F, ideal Q)
used for GB over ZZ: look for constant and monomial elements in the ideal background: any known const...
Definition kutil.cc:10518
k_LmShallowCopyDelete_currRing_2_tailRing
KINLINE poly k_LmShallowCopyDelete_currRing_2_tailRing(poly p, ring tailRing, omBin bin)
Definition kInline.h:977
kStratChangeTailRing
BOOLEAN kStratChangeTailRing(kStrategy strat, LObject *L=NULL, TObject *T=NULL, unsigned long new_expbound=0)
Definition kutil.cc:10939
wlen_type
int64 wlen_type
Definition kutil.h:55
posInLSig
int posInLSig(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5669
k_LmInit_tailRing_2_currRing
KINLINE poly k_LmInit_tailRing_2_currRing(poly p, ring tailRing, omBin bin)
Definition kInline.h:968
posInL11
int posInL11(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5802
chainCritOpt_1
void chainCritOpt_1(poly, int, kStrategy strat)
Definition kutil.cc:3445
sba
ideal sba(ideal F, ideal Q, intvec *w, bigintmat *hilb, kStrategy strat)
Definition kstd2.cc:2971
denominator_list_s::n
number n
Definition kutil.h:66
kFindNextDivisibleByInS
int kFindNextDivisibleByInS(const kStrategy strat, int start, int max_ind, LObject *L)
Definition kstd2.cc:567
initL
static LSet initL(int nr=setmaxL)
Definition kutil.h:417
initT
KINLINE TSet initT()
Definition kInline.h:84
cancelunit
void cancelunit(LObject *p, BOOLEAN inNF=FALSE)
Definition kutil.cc:365
posInL11Ringls
int posInL11Ringls(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5912
k_LmShallowCopyDelete_tailRing_2_currRing
KINLINE poly k_LmShallowCopyDelete_tailRing_2_currRing(poly p, ring tailRing, omBin bin)
Definition kInline.h:984
redtailBba_Ring
KINLINE poly redtailBba_Ring(poly p, int end_pos, kStrategy strat)
Definition kInline.h:1224
kFindDivisibleByInT_Z
int kFindDivisibleByInT_Z(const kStrategy strat, const LObject *L, const int start=0)
Definition kstd2.cc:209
LSet
LObject * LSet
Definition kutil.h:61
redHomog
int redHomog(LObject *h, kStrategy strat)
Definition kstd2.cc:1150
posInT17_c
int posInT17_c(const TSet set, const int length, LObject &p)
Definition kutil.cc:5384
redtailBbaShift
poly redtailBbaShift(LObject *L, int pos, kStrategy strat, BOOLEAN withT, BOOLEAN normalize)
Definition kutil.cc:12980
denominator_list_s::next
denominator_list next
Definition kutil.h:66
posInT_EcartFDegpLength
int posInT_EcartFDegpLength(const TSet set, const int length, LObject &p)
Definition kutil.cc:11358
posInT15
int posInT15(const TSet set, const int length, LObject &p)
Definition kutil.cc:5184
enterSMoraNF
void enterSMoraNF(LObject *p, int atS, kStrategy strat, int atR=-1)
Definition kstd1.cc:1682
kFreeStrat
void kFreeStrat(kStrategy strat)
pairs
void pairs()
postReduceByMon
void postReduceByMon(LObject *h, kStrategy strat)
used for GB over ZZ: intermediate reduction by monomial elements background: any known constant eleme...
Definition kutil.cc:10682
syzCriterion
BOOLEAN syzCriterion(poly sig, unsigned long not_sevSig, kStrategy strat)
Definition kutil.cc:6478
HEckeTest
void HEckeTest(poly pp, kStrategy strat)
Definition kutil.cc:493
redLazy
int redLazy(LObject *h, kStrategy strat)
Definition kstd2.cc:1905
enterT
void enterT(LObject *p, kStrategy strat, int atT=-1)
Definition kutil.cc:9143
enterExtendedSpolySig
void enterExtendedSpolySig(poly h, poly hSig, kStrategy strat)
Definition kutil.cc:4316
enterpairsSig
void enterpairsSig(poly h, poly hSig, int from, int k, int ec, int pos, kStrategy strat, int atR=-1)
Definition kutil.cc:4513
enterpairsShift
void enterpairsShift(poly h, int k, int ecart, int pos, kStrategy strat, int atR)
Definition kutil.cc:12927
k_LmInit_currRing_2_tailRing
KINLINE poly k_LmInit_currRing_2_tailRing(poly p, ring tailRing, omBin bin)
Definition kInline.h:959
initBba
void initBba(kStrategy strat)
Definition kstd1.cc:1690
exitBuchMora
void exitBuchMora(kStrategy strat)
Definition kutil.cc:9837
messageStatSBA
void messageStatSBA(int hilbcount, kStrategy strat)
Definition kutil.cc:7517
redRiloc
int redRiloc(LObject *h, kStrategy strat)
Definition kstd1.cc:385
initEcartNormal
void initEcartNormal(TObject *h)
Definition kutil.cc:1293
kDeleteLcm
static void kDeleteLcm(LObject *P)
Definition kutil.h:876
posInS
int posInS(const kStrategy strat, const int length, const poly p, const int ecart_p)
Definition kutil.cc:4663
updateS
void updateS(BOOLEAN toT, kStrategy strat)
Definition kutil.cc:8557
posInL0
int posInL0(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5611
redSigRing
int redSigRing(LObject *h, kStrategy strat)
Definition kstd2.cc:1536
intset
int * intset
Definition kutil.h:54
initSLSba
void initSLSba(ideal F, ideal Q, kStrategy strat)
Definition kutil.cc:7781
kFindDivisibleByInS_T
TObject * kFindDivisibleByInS_T(kStrategy strat, int end_pos, LObject *L, TObject *T, long ecart=LONG_MAX)
Definition kutil.cc:6697
initSba
void initSba(ideal F, kStrategy strat)
Definition kstd1.cc:1750
ksReducePolyTail
int ksReducePolyTail(LObject *PR, TObject *PW, poly Current, poly spNoether=NULL)
Definition kspoly.cc:1350
initSyzRules
void initSyzRules(kStrategy strat)
Definition kutil.cc:7933
initSbaBuchMora
void initSbaBuchMora(ideal F, ideal Q, kStrategy strat)
Definition kutil.cc:9936
kCheckSpolyCreation
BOOLEAN kCheckSpolyCreation(LObject *L, kStrategy strat, poly &m1, poly &m2)
Definition kutil.cc:10459
cleanT
void cleanT(kStrategy strat)
Definition kutil.cc:557
k_GetStrongLeadTerms
KINLINE void k_GetStrongLeadTerms(const poly p1, const poly p2, const ring leadRing, poly &m1, poly &m2, poly &lcm, const ring taiRing)
Definition kInline.h:1060
posInT110
int posInT110(const TSet set, const int length, LObject &p)
Definition kutil.cc:5029
kTest_S
BOOLEAN kTest_S(kStrategy strat)
Definition kutil.cc:1049
initR
KINLINE TObject ** initR()
Definition kInline.h:95
redNF
poly redNF(poly h, int &max_ind, int nonorm, kStrategy strat)
Definition kstd2.cc:2307
bbaShift
ideal bbaShift(ideal F, ideal Q, intvec *w, bigintmat *hilb, kStrategy strat)
Definition kstd2.cc:4577
reorderS
void reorderS(int *suc, kStrategy strat)
Definition kutil.cc:4610
ksOldSpolyRed
KINLINE poly ksOldSpolyRed(poly p1, poly p2, poly spNoether=NULL)
Definition kInline.h:1174
enterExtendedSpoly
void enterExtendedSpoly(poly h, kStrategy strat)
Definition kutil.cc:4232
enterSMora
void enterSMora(LObject *p, int atS, kStrategy strat, int atR=-1)
Definition kstd1.cc:1629
enterpairs
void enterpairs(poly h, int k, int ec, int pos, kStrategy strat, int atR=-1)
Definition kutil.cc:4487
superenterpairs
void superenterpairs(poly h, int k, int ecart, int pos, kStrategy strat, int atR=-1)
Definition kutil.cc:4457
redSig
int redSig(LObject *h, kStrategy strat)
Definition kstd2.cc:1369
redtailBba_Z
KINLINE poly redtailBba_Z(poly p, int end_pos, kStrategy strat)
Definition kInline.h:1229
ksOldSpolyRedNew
KINLINE poly ksOldSpolyRedNew(poly p1, poly p2, poly spNoether=NULL)
Definition kInline.h:1184
posInL10
int posInL10(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kstd1.cc:1360
redtailBba
KINLINE poly redtailBba(poly p, int end_pos, kStrategy strat, BOOLEAN normalize=FALSE)
Definition kInline.h:1212
updateResult
void updateResult(ideal r, ideal Q, kStrategy strat)
Definition kutil.cc:10051
posInT0
int posInT0(const TSet set, const int length, LObject &p)
Definition kutil.cc:4885
KINLINE
#define KINLINE
Definition kutil.h:50
posInT19
int posInT19(const TSet set, const int length, LObject &p)
Definition kutil.cc:5510
redtailBba_NF
poly redtailBba_NF(poly p, kStrategy strat)
Definition kutil.cc:7350
exitSba
void exitSba(kStrategy strat)
Definition kutil.cc:10011
sbaRing
ring sbaRing(kStrategy strat, const ring r=currRing, BOOLEAN complete=TRUE, int sgn=1)
Definition kutil.cc:11064
enterOnePairShift
BOOLEAN enterOnePairShift(poly q, poly p, int ecart, int isFromQ, kStrategy strat, int atR, int ecartq, int qisFromQ, int shiftcount, int ifromS)
Definition kutil.cc:12143
kDebugPrint
void kDebugPrint(kStrategy strat)
Output some debug info about a given strategy.
Definition kutil.cc:11478
deleteInL
void deleteInL(LSet set, int *length, int j, kStrategy strat)
Definition kutil.cc:1208
ksOldCreateSpoly
KINLINE poly ksOldCreateSpoly(poly p1, poly p2, poly spNoether=NULL, ring r=currRing)
Definition kInline.h:1194
kStratInitChangeTailRing
void kStratInitChangeTailRing(kStrategy strat)
Definition kutil.cc:11036
arriRewCriterion
BOOLEAN arriRewCriterion(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.cc:6621
initBuchMoraCrit
void initBuchMoraCrit(kStrategy strat)
Definition kutil.cc:9435
initBuchMoraPosRing
void initBuchMoraPosRing(kStrategy strat)
Definition kutil.cc:9664
kNF2Bound
poly kNF2Bound(ideal F, ideal Q, poly q, int bound, kStrategy strat, int lazyReduce)
Definition kstd2.cc:4015
kFindInTShift
int kFindInTShift(poly p, TSet T, int tlength)
Definition kutil.cc:728
postReduceByMonSig
void postReduceByMonSig(LObject *h, kStrategy strat)
Definition kutil.cc:10758
ksCreateSpoly
void ksCreateSpoly(LObject *Pair, poly spNoether=NULL, int use_buckets=0, ring tailRing=currRing, poly m1=NULL, poly m2=NULL, TObject **R=NULL)
Definition kspoly.cc:1203
posInL11Ring
int posInL11Ring(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5844
messageSets
void messageSets(kStrategy strat)
Definition kutil.cc:7536
redRing
int redRing(LObject *h, kStrategy strat)
Definition kstd2.cc:988
deleteInS
void deleteInS(int i, kStrategy strat)
Definition kutil.cc:1132
posInT_FDegpLength
int posInT_FDegpLength(const TSet set, const int length, LObject &p)
Definition kutil.cc:11412
sbaCheckGcdPair
BOOLEAN sbaCheckGcdPair(LObject *h, kStrategy strat)
Definition kutil.cc:1688
posInL110
int posInL110(const LSet set, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:6058
redtail
poly redtail(poly p, int end_pos, kStrategy strat)
Definition kutil.cc:6906
posInL10Ring
int posInL10Ring(const LSet set, const int length, LObject *L, const kStrategy strat)
initEcartPairMora
void initEcartPairMora(LObject *Lp, poly f, poly g, int ecartF, int ecartG)
Definition kutil.cc:1315
superenterpairsShift
void superenterpairsShift(poly h, int k, int ecart, int pos, kStrategy strat, int atR)
entersets
void entersets(LObject h)
chainCritNormal
void chainCritNormal(poly p, int ecart, kStrategy strat)
Definition kutil.cc:3204
initEcartBBA
void initEcartBBA(TObject *h)
Definition kutil.cc:1301
TObject
class sTObject TObject
Definition kutil.h:58
bba
ideal bba(ideal F, ideal Q, intvec *w, bigintmat *hilb, kStrategy strat)
Definition kstd2.cc:2614
clearS
KINLINE void clearS(poly p, unsigned long p_sev, int *at, int *k, kStrategy strat)
Definition kInline.h:1235
enterT_strong
void enterT_strong(LObject *p, kStrategy strat, int atT=-1)
Definition kutil.cc:9242
posInLF5CRing
int posInLF5CRing(const LSet set, int start, const int length, LObject *L, const kStrategy strat)
Definition kutil.cc:5878
ksReducePolyZ
int ksReducePolyZ(LObject *PR, TObject *PW, poly spNoether=NULL, number *coef=NULL, kStrategy strat=NULL)
redNFTail
poly redNFTail(poly h, const int sl, kStrategy strat)
ksCreateShortSpoly
poly ksCreateShortSpoly(poly p1, poly p2, ring tailRing)
Definition kspoly.cc:1446
messageStat
void messageStat(int hilbcount, kStrategy strat)
Definition kutil.cc:7504
redHoneyM
int redHoneyM(LObject *h, kStrategy strat)
f5c
void f5c(kStrategy strat, int &olddeg, int &minimcnt, int &hilbeledeg, int &hilbcount, int &srmax, int &lrmax, int &reduc, ideal Q, intvec *w, bigintmat *hilb)
Definition kstd2.cc:4265
initSL
void initSL(ideal F, ideal Q, kStrategy strat)
Definition kutil.cc:7679
k_GetLeadTerms
KINLINE BOOLEAN k_GetLeadTerms(const poly p1, const poly p2, const ring p_r, poly &m1, poly &m2, const ring m_r)
Definition kInline.h:1018
finalReduceByMon
void finalReduceByMon(kStrategy strat)
used for GB over ZZ: final reduction by constant elements background: any known constant element of i...
Definition kutil.cc:10847
kTest_T
BOOLEAN kTest_T(TObject *T, kStrategy strat, int tpos=-1, char TN='?')
Definition kutil.cc:789
initSbaCrit
void initSbaCrit(kStrategy strat)
Definition kutil.cc:9498
newHEdge
BOOLEAN newHEdge(kStrategy strat)
Definition kutil.cc:10379
homogTest
BOOLEAN homogTest(polyset F, int Fmax)
LObject
class sLObject LObject
Definition kutil.h:59
redtailSba
poly redtailSba(LObject *L, int end_pos, kStrategy strat, BOOLEAN withT=FALSE, BOOLEAN normalize=FALSE)
Definition kstd2.cc:1785
faugereRewCriterion
BOOLEAN faugereRewCriterion(poly sig, unsigned long not_sevSig, poly lm, kStrategy strat, int start)
Definition kutil.cc:6562
initsevT
KINLINE unsigned long * initsevT()
Definition kInline.h:100
denominator_list_s
Definition kutil.h:66
lcm
int lcm(unsigned long *l, unsigned long *a, unsigned long *b, unsigned long p, int dega, int degb)
Definition minpoly.cc:709
mylimits.h
lq
Definition lq.h:40
omAlloc
#define omAlloc(size)
Definition omAllocDecl.h:210
NULL
#define NULL
Definition omList.c:12
omBin
omBin_t * omBin
Definition omStructs.h:12
omallocClass.h
omalloc.h
pShallowCopyDelete.h
currRing
VAR ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
Definition polys.cc:13
polys.h
Compatibility layer for legacy polynomial operations (over currRing).
pLmDelete
#define pLmDelete(p)
assume p != NULL, deletes Lm(p)->coef and Lm(p)
Definition polys.h:77
pLmFree
static void pLmFree(poly p)
frees the space of the monomial m, assumes m != NULL coef is not freed, m is not advanced
Definition polys.h:71
polyset
poly * polyset
Definition polys.h:260
pFDegProc
long(* pFDegProc)(poly p, ring r)
Definition ring.h:39
pLDegProc
long(* pLDegProc)(poly p, int *length, ring r)
Definition ring.h:38
kBucket_pt
kBucket * kBucket_pt
Definition ring.h:26
pShallowCopyDeleteProc
poly(* pShallowCopyDeleteProc)(poly s_p, ring source_r, ring dest_r, omBin dest_bin)
returns a poly from dest_r which is a ShallowCopy of s_p from source_r assumes that source_r->N == de...
Definition ring.h:45
rField_is_Ring
#define rField_is_Ring(R)
Definition ring.h:491
shiftgb.h
R
#define R
Definition sirandom.c:27
Q
#define Q
Definition sirandom.c:26
structs.h
kStrategy
skStrategy * kStrategy
Definition structs.h:54
normalize
static poly normalize(poly next_p, ideal add_generators, syStrategy syzstr, int *g_l, int *p_l, int crit_comp)
Definition syz3.cc:1027