34 for (i=(
currRing->N); i>=rat_shift; i--)
67 if (q ==
NULL)
return p;
89 for (i=ishift+1; i<=r->N; i++)
97 PrintS(
"negative ExpVectorDiff\n");
120 PrintS(
"running syzygy comp. for nc_GCD:\n");
124 PrintS(
"done syzygy comp. for nc_GCD\n");
350 if ((lCompP1!=lCompP2) && (lCompP1!=0) && (lCompP2!=0))
353 Werror(
"nc_rat_CreateSpoly: different non-zero components!");
407 ideal ncsyz =
ncGCD(C,K,r);
408 poly KK = ncsyz->m[0]; ncsyz->m[0]=
NULL;
409 poly CC = ncsyz->m[1]; ncsyz->m[1]=
NULL;
444 PrintS(
" k'(r_f + d^{gamma-alpha} t_f): ");
p_wrp(p1,r);
445 PrintS(
" c'(r_g + d^{gamma-beta} t_g): ");
p_wrp(p2,r);
471 if ((lCompP1!=lCompP2) && (lCompP1!=0) && (lCompP2!=0))
474 Werror(
"nc_rat_ReduceSpolyNew: different non-zero components!");
516 ideal ncsyz =
ncGCD(P,K,r);
517 poly KK = ncsyz->m[0]; ncsyz->m[0]=
NULL;
518 poly PP = ncsyz->m[1]; ncsyz->m[1]=
NULL;
547 PrintS(
" end reduction\n");
573 PrintS(
"invoke p_DivByRat with a = ");
580 for(i=r->N; i>ishift; i--)
596 if ((*h)==
NULL)
return 0;
608 j=
i; l=red_length[
i];
654 int i = r->real_var_end;
656 while ( (
p_GetExp(p,i,r)==0) && (i>=r->real_var_start))
660 return ( i+1 == r->real_var_start );
void pLcmRat(poly a, poly b, poly m, int rat_shift)
Compatiblity layer for legacy polynomial operations (over currRing)
poly singclap_gcd(poly f, poly g, const ring r)
destroys f and g
void id_Delete(ideal *h, ring r)
deletes an ideal/module/matrix
BOOLEAN p_DivisibleByRat(poly a, poly b, int ishift, const ring r)
poly nc_rat_ReduceSpolyNew(const poly p1, poly p2, int ishift, const ring r)
poly singclap_pdivide(poly f, poly g, const ring r)
#define pGetComp(p)
Component.
static poly p_Copy(poly p, const ring r)
returns a copy of p
ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
#define pGetExp(p, i)
Exponent.
static poly nc_mm_Mult_p(const poly m, poly p, const ring r)
static poly p_Head(poly p, const ring r)
static int p_Comp_k_n(poly a, poly b, int k, ring r)
static void p_SetCompP(poly p, int i, ring r)
static long p_GetExp(const poly p, const unsigned long iBitmask, const int VarOffset)
get a single variable exponent : the integer VarOffset encodes:
void p_LmDeleteAndNextRat(poly *p, int ishift, ring r)
BOOLEAN p_LmIsConstantCompRat(const poly p, const ring r)
poly nc_rat_CreateSpoly(poly pp1, poly pp2, int ishift, const ring r)
static int si_max(const int a, const int b)
poly p_GetCoeffRat(poly p, int ishift, ring r)
void PrintS(const char *s)
#define p_LmCheckPolyRing1(p, r)
poly p_HeadRat(poly p, int ishift, ring r)
static void p_Delete(poly *p, const ring r)
ideal idInit(int idsize, int rank)
initialise an ideal / module
const Variable & v
< [in] a sqrfree bivariate poly
BOOLEAN p_LmIsConstantRat(const poly p, const ring r)
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 pTakeOutComp(poly *p, long comp, poly *q, int *lq, const ring R=currRing)
Splits *p into two polys: *q which consists of all monoms with component == comp and *p of all other ...
void p_ExpVectorDiffRat(poly pr, poly p1, poly p2, int ishift, ring r)
ideal ncGCD2(poly p, poly q, const ring r)
static void p_Setm(poly p, const ring r)
static poly p_GetExp_k_n(poly p, int l, int k, const ring r)
int redRat(poly *h, poly *reducer, int *red_length, int rl, int ishift, ring r)
static poly p_Neg(poly p, const ring r)
ideal ncGCD(poly p, poly q, const ring r)
void p_wrp(poly p, ring lmRing, ring tailRing)
static FORCE_INLINE BOOLEAN n_GreaterZero(number n, const coeffs r)
ordered fields: TRUE iff 'n' is positive; in Z/pZ: TRUE iff 0 < m <= roundedBelow(p/2), where m is the long representing n in C: TRUE iff (Im(n) != 0 and Im(n) >= 0) or (Im(n) == 0 and Re(n) >= 0) in K(a)/
: TRUE iff (n != 0 and (LC(n) > 0 or deg(n) > 0)) in K(t_1, ..., t_n): TRUE iff (LC(numerator(n) is a constant and > 0) or (LC(numerator(n) is not a constant) in Z/2^kZ: TRUE iff 0 < n <= 2^(k-1) in Z/mZ: TRUE iff the internal mpz is greater than zero in Z: TRUE iff n > 0
static poly p_Add_q(poly p, poly q, const ring r)
ideal idSyzygies(ideal h1, tHomog h, intvec **w, BOOLEAN setSyzComp, BOOLEAN setRegularity, int *deg)
static poly p_Mult_q(poly p, poly q, const ring r)
void Werror(const char *fmt,...)