60 #ifndef RTIMER_BENCHMARKING 61 # define RTIMER_BENCHMARKING 0 104 inline void Add( poly
p,
const int l )
135 const poly nxt =
pNext(s);
160 return ((
int)(
long)(
atGet(rootRingHdl, attribute,
INT_CMD, (
void*)def)));
163 #if (defined(HAVE_QSORT_R) && (defined __APPLE__ || defined __MACH__ || defined __DARWIN__ || defined __FreeBSD__ || defined __BSD__ || defined OpenBSD3_1 || defined OpenBSD3_9)) 164 static int cmp_c_ds(
void *
R,
const void *p1,
const void *p2){
165 #elif (defined(HAVE_QSORT_R) && (defined _GNU_SOURCE || defined __GNU__ || defined __linux__)) 166 static int cmp_c_ds(
const void *p1,
const void *p2,
void *
R){
174 const ring r = (
const ring) R;
178 const poly a = *(
const poly*)p1;
179 const poly
b = *(
const poly*)p2;
212 for (
int v =
rVar(r);
v > 0;
v--)
277 memcpy(np->exp, p->exp, r->ExpL_Size*
sizeof(
long));
288 poly
leadmonom(
const poly
p,
const ring r,
const bool bSetZeroComp)
333 newid->m[
i] =
p_Tail( id->m[
i], r );
344 const int sizeNew =
IDELEMS(
id);
346 #if ( (defined(HAVE_QSORT_R)) && (defined __APPLE__ || defined __MACH__ || defined __DARWIN__ || defined __FreeBSD__ || defined __BSD__ || defined OpenBSD3_1 || defined OpenBSD3_9) ) 347 #define qsort_my(m, s, ss, r, cmp) qsort_r(m, s, ss, r, cmp) 348 #elif ( (defined(HAVE_QSORT_R)) && (defined _GNU_SOURCE || defined __GNU__ || defined __linux__)) 349 #define qsort_my(m, s, ss, r, cmp) qsort_r(m, s, ss, cmp, r) 351 #define qsort_my(m, s, ss, r, cmp) qsort(m, s, ss, cmp) 365 id_Delete(const_cast<ideal*>(&m_idTails), m_rBaseRing);
374 if( m_spoly_bucket !=
NULL )
377 m_spoly_bucket =
NULL;
380 for( TCache::iterator it = m_cache.begin(); it != m_cache.end(); it++ )
384 for(TP2PCache::iterator vit = T.begin(); vit != T.end(); vit++ )
386 p_Delete( (&(vit->second)), m_rBaseRing);
387 p_Delete( const_cast<poly*>(&(vit->first)), m_rBaseRing);
406 const ring r = m_rBaseRing;
409 if(
LIKELY(OPT__TAILREDSYZ) )
417 CReducersHash::const_iterator itr = m_hash.find(comp);
419 if ( itr == m_hash.end() )
422 assume( itr->first == comp );
424 const bool bIdealCase = (comp == 0);
425 const bool bSyzCheck = syzChecker.
IsNonempty();
427 if(
LIKELY(OPT__TAILREDSYZ && (bIdealCase || bSyzCheck)) )
430 const int N =
rVar(r);
433 for(TReducers::const_iterator vit = v.begin(); (vit != v.end()) && coprime; ++vit )
435 assume( (*vit)->CheckLT( m_L ) );
437 const poly
p = (*vit)->lt();
442 for(
int var = N; var > 0; --var )
449 if( bSyzCheck && coprime )
461 assume( p == (*vit)->lt() );
462 assume( (*vit)->CheckLT( m_L ) );
465 return coprime? 3: 0;
476 const ideal idTails = m_idTails;
479 const ring r = m_rBaseRing;
481 unsigned long pp[4] = {0,0,0,0};
483 for(
int p =
IDELEMS(idTails) - 1;
p >= 0; --
p )
484 for( poly* tt = &(idTails->m[
p]); (*tt) !=
NULL; )
487 const int k = m_div.PreProcessTerm(t, m_checker);
488 assume( 0 <= k && k <= 3 );
503 Print(
"(PP/ST: {c: %lu, C: %lu, P: %lu} + %lu)", pp[1], pp[2], pp[3], pp[0]);
504 m_stat[0] += pp [0]; m_stat[1] += pp [1]; m_stat[2] += pp [2]; m_stat[3] += pp [3];
535 Print(
"SchreyerSyzygyComputation Stats: (PP/ST: {c: %lu, C: %lu, P: %lu} + %lu, LOT: %lu, LCM: %lu, ST:%lu, LK: %lu {*: %lu})\n",
536 m_stat[1], m_stat[2], m_stat[3], m_stat[0],
537 m_stat[4], m_stat[5],
539 m_stat[6] + m_stat[7], m_stat[7]
546 const ideal&
id = m_idLeads;
547 const ring& r = m_rBaseRing;
561 const ideal newid =
idInit(1, 0); newid->m[0] =
NULL;
572 const ideal newid =
idInit( (size * (size-1))/2, size);
578 const poly
p =
id->m[
j];
582 for (
int i =
j - 1;
i >= 0;
i--)
584 const poly
pp =
id->m[
i];
594 for (
int v =
rVar(r);
v > 0;
v--)
636 const ideal&
id = m_idLeads;
637 const ring& r = m_rBaseRing;
649 const ideal newid =
idInit(1, 1); newid->m[0] =
NULL;
661 ideal newid =
idInit( (size * (size-1))/2, size);
667 const poly
p =
id->m[
j];
671 for (
int i =
j - 1;
i >= 0;
i--)
673 const poly
pp =
id->m[
i];
687 for (
int v =
rVar(r);
v > 0;
v--)
717 number
g =
n_Lcm( lc1, lc2, r->cf );
767 const ideal& L = m_idLeads;
768 const ideal&
T = m_idTails;
770 const ring& R = m_rBaseRing;
811 const ideal& L = m_idLeads;
812 const ideal&
T = m_idTails;
814 ideal& TT = m_syzTails;
815 const ring& R = m_rBaseRing;
821 if( m_spoly_bucket ==
NULL )
832 Print(
"\n{ \"syzygylayer\": \"%d\", \"hybridnf\": \"%d\", \"diagrams\": \n[", OPT__SYZNUMBER, OPT__HYBRIDNF );
836 if( m_syzLeads ==
NULL )
842 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::ComputeLeadingSyzygyTerms: t: %d, r: %d\n", r, t, r);
849 if(
UNLIKELY(OPT__PROT & RTIMER_BENCHMARKING) )
852 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::ComputeLeadingSyzygyTerms: dt: %d, dr: %d\n",
getRTimer(), t, r);
859 ideal& LL = m_syzLeads;
864 if( size == 1 && LL->m[0] ==
NULL )
873 const bool method = (OPT__HYBRIDNF == 1);
878 if(
LIKELY(!OPT__IGNORETAILS) )
886 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::SetUpTailTerms(): t: %d, r: %d\n", r, t, r);
893 if(
UNLIKELY(OPT__PROT & RTIMER_BENCHMARKING) )
896 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::SetUpTailTerms(): dt: %d, dr: %d\n",
getRTimer(), t, r);
906 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::SyzygyLift: t: %d, r: %d\n", r, t, r);
911 for(
int k = size - 1;
k >= 0; --
k )
940 nf = TraverseNF(a, a2);
954 if(
UNLIKELY( OPT__PROT && (vp !=
NULL) ) )
Warn(
"ERROR: SyzCheck failed, wrong tail: [%d]\n\n",
k);
961 if(
UNLIKELY( OPT__PROT & RTIMER_BENCHMARKING ) )
964 Print(
"\n%% %5d **!TIME4!** SchreyerSyzygyComputation::ComputeSyzygy::SyzygyLift: dt: %d, dr: %d\n",
getRTimer(), t, r);
995 m_syzLeads = Compute1LeadingSyzygyTerms();
1002 if (
LIKELY( OPT__TAILREDSYZ && !OPT__IGNORETAILS && (
IDELEMS(m_syzLeads) > 0) && !((
IDELEMS(m_syzLeads) == 1) && (m_syzLeads->m[0] ==
NULL)) ) )
1005 m_checker.Initialize(m_syzLeads);
1006 assume( m_checker.IsNonempty() );
1009 if(
UNLIKELY( OPT__PROT ) )
Print(
"(L%dS:%d)", bComputeSecondTerms ? 2 : 1,
IDELEMS(m_syzLeads));
1015 assume( !OPT__IGNORETAILS );
1017 const ideal& L = m_idLeads;
1018 const ideal&
T = m_idTails;
1019 const ring& r = m_rBaseRing;
1025 const int rr =
p_GetComp(syz_lead, r) - 1;
1031 syz_2 = m_div.FindReducer(syz_lead, L->m[rr], syz_lead, m_checker);
1038 syz_2 = m_div.FindReducer(aa, syz_lead, m_checker);
1057 if( m_spoly_bucket ==
NULL )
1091 poly t = m_div.FindReducer(spoly,
NULL, m_checker);
1109 if(
UNLIKELY(OPT__PROT) ) ++ m_stat[4];
1122 if( m_spoly_bucket ==
NULL )
1123 m_spoly_bucket = bucket;
1146 const ring& r = m_rBaseRing;
1154 return ComputeImage(multiplier, tail);
1157 TCache::iterator top_itr = m_cache.find(tail);
1159 if ( top_itr != m_cache.end() )
1161 assume( top_itr->first == tail );
1165 TP2PCache::iterator itr = T.find(multiplier);
1167 if( itr != T.end() )
1171 if( itr->second ==
NULL )
1174 poly
p =
p_Copy(itr->second, r);
1187 Print(
"\"recale\": \"%s\", ", s);
1191 if(
UNLIKELY( OPT__PROT ) ) ++ m_stat[7];
1196 if(
UNLIKELY( OPT__PROT ) ) ++ m_stat[6];
1206 const poly
p = ComputeImage(multiplier, tail);
1208 if(
UNLIKELY(OPT__PROT) ) ++ m_stat[8];
1212 T.insert( TP2PCache::value_type(
myp_Head(multiplier, (p==
NULL), r), p) );
1224 const poly
p = ComputeImage(multiplier, tail);
1226 if(
UNLIKELY( OPT__PROT ) ) ++ m_stat[8];
1228 T.insert( TP2PCache::value_type(
myp_Head(multiplier, (p==
NULL), r), p) );
1230 m_cache.insert( TCache::value_type(tail, T) );
1240 const ring& r = m_rBaseRing;
1247 const poly t = m_idTails->m[tail];
1263 assume( !OPT__IGNORETAILS );
1265 const ideal& L = m_idLeads;
1266 const ideal&
T = m_idTails;
1267 const ring& r = m_rBaseRing;
1276 if(
UNLIKELY( !( (!OPT__TAILREDSYZ) || m_lcm.Check(multiplier) )) )
1278 if(
UNLIKELY(OPT__TAILREDSYZ && OPT__PROT) )
1355 assume( !OPT__IGNORETAILS );
1357 const ideal& L = m_idLeads;
1358 const ideal&
T = m_idTails;
1359 const ring& r = m_rBaseRing;
1373 if( (!OPT__TAILREDSYZ) || m_lcm.Check(multiplier) )
1376 s = m_div.FindReducer(multiplier, term4reduction, syztermCheck, m_checker);
1383 if(
UNLIKELY(OPT__PROT) ) ++ m_stat[4];
1389 poly product =
pp_Mult_mm(multiplier, term4reduction, r);
1392 s = m_div.FindReducer(product, syztermCheck, m_checker);
1399 if(
UNLIKELY(OPT__PROT) ) ++ m_stat[4];
1409 if(
UNLIKELY( OPT__TAILREDSYZ && OPT__PROT) )
1428 PrintS(
"\", \"children\": [");
1443 OPT__DEBUG(
atGetInt(rootRingHdl,
"DEBUG", 0) ),
1444 OPT__LEAD2SYZ(
atGetInt(rootRingHdl,
"LEAD2SYZ", 0) ),
1445 OPT__TAILREDSYZ(
atGetInt(rootRingHdl,
"TAILREDSYZ", 1) ),
1446 OPT__HYBRIDNF(
atGetInt(rootRingHdl,
"HYBRIDNF", 0) ),
1447 OPT__IGNORETAILS(
atGetInt(rootRingHdl,
"IGNORETAILS", 0) ),
1448 OPT__SYZNUMBER(
atGetInt(rootRingHdl,
"SYZNUMBER", 0) ),
1449 OPT__TREEOUTPUT(
atGetInt(rootRingHdl,
"TREEOUTPUT", 0) ),
1450 OPT__SYZCHECK(
atGetInt(rootRingHdl,
"SYZCHECK", 0) ),
1452 OPT__NOCACHING(
atGetInt(rootRingHdl,
"NOCACHING", 0) ),
1453 m_rBaseRing( rootRingHdl->data.uring )
1472 for( CReducersHash::const_iterator it = m_hash.begin(); it != m_hash.end(); it++ )
1475 for(TReducers::const_iterator vit = v.begin(); vit != v.end(); vit++ )
1476 delete const_cast<CLeadingTerm*>(*vit);
1491 const ring& R = m_rBaseRing;
1496 const poly a = L->m[
k];
1507 m_L(const_cast<ideal>(L)),
1518 int i=r->VarL_Size - 1;
1519 unsigned long divmask = r->divmask;
1520 unsigned long la, lb;
1522 if (r->VarL_LowIndex >= 0)
1524 i += r->VarL_LowIndex;
1528 lb = b->exp[
i] + c->exp[
i];
1530 (((la & divmask) ^ (lb & divmask)) != ((lb - la) & divmask)))
1537 while (i>=r->VarL_LowIndex);
1543 la = a->exp[r->VarL_Offset[
i]];
1544 lb = b->exp[r->VarL_Offset[
i]] + c->exp[r->VarL_Offset[
i]];
1546 (((la & divmask) ^ (lb & divmask)) != ((lb - la) & divmask)))
1565 return ( L->m[label()] == lt() );
1607 if (sev() & not_sev)
1625 CReducerFinder::CReducersHash::const_iterator
m_itr;
1626 CReducerFinder::TReducers::const_iterator m_current,
m_finish;
1637 m_itr(), m_current(), m_finish(),
1651 m_itr = m_reds.
m_hash.find(m_comp);
1653 if( m_itr == m_reds.
m_hash.end() )
1656 assume( m_itr->first == m_comp );
1658 m_current = (m_itr->second).begin();
1659 m_finish = (m_itr->second).end();
1661 if (m_current == m_finish)
1671 assume( m_current != m_finish );
1673 return *(*m_current);
1678 assume( m_current != m_finish );
1686 for( ; m_current != m_finish; ++m_current )
1688 assume( Current().CheckLT( m_reds.
m_L ) );
1690 if( Current().DivisibilityCheck(m_product, m_not_sev,
m_rBaseRing) )
1693 assume( Current().CheckLT( m_reds.
m_L ) );
1696 assume( Current().CheckLT( m_reds.
m_L ) );
1700 assume( m_current == m_finish );
1733 CReducerFinder::CReducersHash::const_iterator
m_itr;
1734 CReducerFinder::TReducers::const_iterator m_current,
m_finish;
1742 m_multiplier(m), m_term(t),
1745 m_itr(), m_current(), m_finish(),
1766 m_itr = m_reds.
m_hash.find(m_comp);
1768 if( m_itr == m_reds.
m_hash.end() )
1771 assume( m_itr->first == m_comp );
1773 m_current = (m_itr->second).begin();
1774 m_finish = (m_itr->second).end();
1776 if (m_current == m_finish)
1785 assume( m_current != m_finish );
1787 return *(*m_current);
1792 assume( m_current != m_finish );
1801 for( ; m_current != m_finish; ++m_current )
1803 assume( Current().CheckLT( m_reds.
m_L ) );
1805 if( Current().DivisibilityCheck(m_multiplier, m_term, m_not_sev,
m_rBaseRing) )
1808 assume( Current().CheckLT( m_reds.
m_L ) );
1812 assume( Current().CheckLT( m_reds.
m_L ) );
1816 assume( m_current == m_finish );
1844 if (syzterm !=
NULL)
1875 if (syzterm !=
NULL && (k == c))
1935 if (syzterm !=
NULL)
1956 if (syzterm !=
NULL && (k == c))
2079 for(
int k = l - 1;
k >= 0;
k-- )
2083 for (
unsigned int j =
m_N;
j > 0;
j--)
2102 for (
unsigned int j =
m_N;
j > 0;
j--)
void kBucketClear(kBucket_pt bucket, poly *p, int *length)
Computation attribute storage.
BOOLEAN kbTest(kBucket_pt bucket)
Tests.
const unsigned long m_not_sev
const CanonicalForm int s
void id_DelDiv(ideal id, const ring r)
delete id[j], if LT(j) == coeff*mon*LT(i) and vice versa, i.e., delete id[i], if LT(i) == coeff*mon*L...
const CReducerFinder & m_reds
const CLeadingTerm & Current() const
static poly p_LmDeleteAndNext(poly p, const ring r)
SBucketFactory & m_factory
poly SchreyerSyzygyNF(const poly syz_lead, poly syz_2=NULL) const
Main HybridNF == 1: poly reduce + LOT + LCM?
const int OPT__HYBRIDNF
Use the usual NF's S-poly reduction while dropping lower order terms 2 means - smart selection! ...
Compatiblity layer for legacy polynomial operations (over currRing)
static FORCE_INLINE BOOLEAN n_IsOne(number n, const coeffs r)
TRUE iff 'n' represents the one element.
static poly p_Mult_mm(poly p, poly m, const ring r)
static unsigned long p_SetComp(poly p, unsigned long c, ring r)
CReducerFinder(const ideal L, const SchreyerSyzygyComputationFlags &flags)
goes over all leading terms
BOOLEAN p_DebugLmDivisibleByNoComp(poly a, poly b, ring r)
std::vector< const CLeadingTerm * > TReducers
static FORCE_INLINE number n_Init(long i, const coeffs r)
a number representing i in the given coeff field/ring r
static short rVar(const ring r)
#define rVar(r) (r->N)
void id_Delete(ideal *h, ring r)
deletes an ideal/module/matrix
static poly pp_Mult_mm(poly p, poly m, const ring r)
ideal kStd(ideal F, ideal Q, tHomog h, intvec **w, intvec *hilb, int syzComp, int newIdeal, intvec *vw, s_poly_proc_t sp)
CDivisorEnumerator2(const CReducerFinder &self, const poly m, const poly t)
static long p_Totaldegree(poly p, const ring r)
poly FindReducer(const poly multiplier, const poly monom, const poly syzterm, const CReducerFinder &checker) const
void sBucket_Add_p(sBucket_pt bucket, poly p, int length)
adds poly p to bucket destroys p!
unsigned long sev() const
CDivisorEnumerator(const CReducerFinder &self, const poly product)
void PrintStats() const
print statistics about the used heuristics
#define omTypeAllocBin(type, addr, bin)
static number & pGetCoeff(poly p)
return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy ...
CReducerFinder::CReducersHash::const_iterator m_itr
static Bucket _CreateBucket(const ring r)
inital allocation for new buckets
Bucket getBucket(const ring r, const bool remove=true)
ideal Compute2LeadingSyzygyTerms()
leading + second terms
static void p_LmFree(poly p, ring)
poly kBucketExtractLm(kBucket_pt bucket)
static poly p_Copy(poly p, const ring r)
returns a copy of p
poly ReduceTerm(poly multiplier, poly term4reduction, poly syztermCheck) const
TODO: save shortcut (syz: |-.->) LM(m) * "t" -> ? ???
const int OPT__TAILREDSYZ
Reduce syzygy tails wrt the leading syzygy terms.
int comp(const CanonicalForm &A, const CanonicalForm &B)
compare polynomials
static BOOLEAN p_LmIsConstant(const poly p, const ring r)
static FORCE_INLINE number n_Mult(number a, number b, const coeffs r)
return the product of 'a' and 'b', i.e., a*b
void ComputeSyzygy()
The main driver function: computes.
poly TraverseNF(const poly syz_lead, const poly syz_2=NULL) const
Coefficient rings, fields and other domains suitable for Singular polynomials.
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
const CanonicalForm CFMap CFMap & N
static long p_GetExp(const poly p, const unsigned long iBitmask, const int VarOffset)
get a single variable exponent : the integer VarOffset encodes:
CLCM(const ideal &L, const SchreyerSyzygyComputationFlags &flags)
#define p_SetRingOfLm(p, r)
SBucketWrapper(const ring r, SBucketFactory &factory)
bool CheckLT(const ideal &L) const
void sBucketDestroy(sBucket_pt *bucket)
void StringSetS(const char *st)
static poly pp_Mult_qq(poly p, poly q, const ring r)
static void _DestroyBucket(Bucket &bt)
we only expect empty buckets to be left at the end for destructor bt will be set to NULL ...
bool DivisibilityCheck(const poly multiplier, const poly t, const unsigned long not_sev, const ring r) const
as DivisibilityCheck(multiplier * t, ...) for monomial 'm' and a module term 't'
void CleanUp()
Clean up all the accumulated data.
sBucket_pt sBucketCreate(const ring r)
static FORCE_INLINE void n_Write(number n, const coeffs r, const BOOLEAN bShortOut=TRUE)
CReducerFinder::TReducers::const_iterator m_finish
poly TraverseTail(poly multiplier, const int tail) const
High level caching function!!!
void SetUpTailTerms()
Convert the given ideal of tails into the internal representation (with reducers!) Preprocess m_idTai...
void ComputeLeadingSyzygyTerms(bool bComputeSecondTerms=true)
Computes Syz(leads) or only LEAD of it. The result is stored into m_syzLeads.
static int p_LmCmp(poly p, poly q, const ring r)
static FORCE_INLINE number n_InpNeg(number n, const coeffs r)
in-place negation of n MUST BE USED: n = n_InpNeg(n) (no copy is returned)
ideal Compute1LeadingSyzygyTerms()
just leading terms
void PrintS(const char *s)
static poly p_Mult_nn(poly p, number n, const ring r)
SBucketFactory::Bucket Bucket
void Add(poly p, const int l)
adds p to the internal bucket destroys p, l == length(p)
static BOOLEAN p_LmShortDivisibleByNoComp(poly a, unsigned long sev_a, poly b, unsigned long not_sev_b, const ring r)
#define p_LmCheckPolyRing1(p, r)
void Initialize(const ideal L)
static unsigned pLength(poly a)
static FORCE_INLINE BOOLEAN n_IsZero(number n, const coeffs r)
TRUE iff 'n' represents the zero element.
const CReducerFinder & m_reds
const unsigned int m_N
number of ring variables
void idSkipZeroes(ideal ide)
gives an ideal/module the minimal possible size
static FORCE_INLINE number n_Lcm(number a, number b, const coeffs r)
in Z: return the lcm of 'a' and 'b' in Z/nZ, Z/2^kZ: computed as in the case Z in Z/pZ...
bool Check(const poly m) const
const CLeadingTerm & Current() const
static void p_Delete(poly *p, const ring r)
unsigned long p_GetShortExpVector(const poly p, const ring r)
ideal idInit(int idsize, int rank)
initialise an ideal / module
#define p_LmEqual(p1, p2, r)
const Variable & v
< [in] a sqrfree bivariate poly
static void p_ExpVectorDiff(poly pr, poly p1, poly p2, const ring r)
static unsigned long p_SetExp(poly p, const unsigned long e, const unsigned long iBitmask, const int VarOffset)
set a single variable exponent : VarOffset encodes the position in p->exp
void * atGet(idhdl root, const char *name, int t, void *defaultReturnValue)
static BOOLEAN rField_is_Ring(const ring r)
#define FROM_NAMESPACE(a, s)
static FORCE_INLINE number n_Copy(number n, const coeffs r)
return a copy of 'n'
void kBucket_Plus_mm_Mult_pp(kBucket_pt bucket, poly m, poly p, int l)
Bpoly == Bpoly + m*p; where m is a monom Does not destroy p and m assume (l <= 0 || pLength(p) == l) ...
static FORCE_INLINE number n_Div(number a, number b, const coeffs r)
return the quotient of 'a' and 'b', i.e., a/b; raises an error if 'b' is not invertible in r exceptio...
const unsigned long m_not_sev
SchreyerSyzygyComputationFlags(idhdl rootRingHdl)
poly ComputeImage(poly multiplier, const int tail) const
low level computation...
const ring m_rBaseRing
global base ring
void putBucket(const Bucket &bt, const bool replace=false)
ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
static FORCE_INLINE BOOLEAN n_Equal(number a, number b, const coeffs r)
TRUE iff 'a' and 'b' represent the same number; they may have different representations.
static poly p_LmInit(poly p, const ring r)
static void p_Setm(poly p, const ring r)
unsigned int label() const
CReducerFinder::CReducersHash::const_iterator m_itr
bool IsDivisible(const poly q) const
static void p_LmDelete(poly p, const ring r)
#define p_SetCoeff0(p, n, r)
void Add(poly p)
adds p to the internal bucket destroys p
CReducerFinder::TReducers::const_iterator m_finish
static FORCE_INLINE void n_Delete(number *p, const coeffs r)
delete 'p'
static void p_ExpVectorSum(poly pr, poly p1, poly p2, const ring r)
static BOOLEAN p_ExpVectorEqual(poly p1, poly p2, const ring r1, const ring r2)
static poly p_Add_q(poly p, poly q, const ring r)
int status int void size_t count int const void size_t count const char int flags
kBucket_pt kBucketCreate(const ring bucket_ring)
Creation/Destruction of buckets.
static poly p_New(const ring, omBin bin)
static poly p_Init(const ring r, omBin bin)
#define SI_RESTORE_OPT1(A)
int PreProcessTerm(const poly t, CReducerFinder &syzChecker) const
is the term to be "preprocessed" as lower order term or lead to only reducible syzygies...
void sBucketClearAdd(sBucket_pt bucket, poly *p, int *length)