50#define TRANSEXT_PRIVATES 1
54#define naTest(a) naDBTest(a,__FILE__,__LINE__,cf)
57#define naTest(a) do {} while (0)
61#define naRing cf->extRing
67#define naCoeffs cf->extRing->cf
70#define naMinpoly naRing->qideal->m[0]
120 if (
p ==
NULL)
return;
121 number n = n_Init(1, r->cf);
122 if (
p->next==
NULL) { p_SetCoeff(
p,n,r);
return; }
125 if (n_IsOne(
lc, r->cf))
return;
126 number lcInverse = n_Invers(
lc, r->cf);
131 number n = n_Mult(
p_GetCoeff(
p, r), lcInverse, r->cf);
132 n_Normalize(n,r->cf);
136 n_Delete(&lcInverse, r->cf);
163static inline poly
p_Gcd(
const poly
p,
const poly q,
const ring r)
167 poly a =
p; poly
b = q;
169 a = p_Copy(a, r);
b = p_Copy(
b, r);
188 p_SetCoeff(pFactor, n_Invers(
p_GetCoeff(
p, r), r->cf), r);
195 poly ppFactor =
NULL; poly qqFactor =
NULL;
198 qFactor = p_Add_q(qqFactor,
199 p_Neg(p_Mult_q(pDivQ, p_Copy(ppFactor, r), r), r),
214poly
p_ExtGcd(poly
p, poly &pFactor, poly q, poly &qFactor, ring r)
219 { a = q;
b =
p; aCorrespondsToP =
FALSE; }
220 a = p_Copy(a, r);
b = p_Copy(
b, r);
221 poly aFactor =
NULL; poly bFactor =
NULL;
223 if (aCorrespondsToP) { pFactor = aFactor; qFactor = bFactor; }
224 else { pFactor = bFactor; qFactor = aFactor; }
239 && (p_Totaldegree((poly)a,
naRing)> 1))
264 cf =
cf->extRing->cf;
278 if (*a ==
NULL)
return;
280 poly aAsPoly = (poly)(*a);
281 p_Delete(&aAsPoly,
naRing);
298 return (number)p_Copy((poly)a,
naRing);
304 poly aAsPoly = (poly)a;
312 poly aAsPoly = (poly)a;
321 if (a !=
NULL) a = (number)p_Neg((poly)a,
naRing);
327 if (
i == 0)
return NULL;
334 return (number)
p_NSet(n,r->extRing);
340 poly aAsPoly = (poly)a;
343 if (!p_IsConstant(aAsPoly,
naRing))
356 return !n_GreaterZero(pGetCoeff((poly)
b),
naCoeffs);
360 return n_GreaterZero(pGetCoeff((poly)a),
naCoeffs);
362 int aDeg = p_Totaldegree((poly)a,
naRing);
363 int bDeg = p_Totaldegree((poly)
b,
naRing);
364 if (aDeg>bDeg)
return TRUE;
365 if (aDeg<bDeg)
return FALSE;
366 return n_Greater(pGetCoeff((poly)a),pGetCoeff((poly)
b),
naCoeffs);
375 if (p_Totaldegree((poly)a,
naRing) > 0)
return TRUE;
383 const ring
A =
cf->extRing;
392 const int P = rVar(
A);
397 for (
int nop=0; nop < P; nop ++)
399 Print(
"%s", rRingVar(nop,
A));
400 if (nop!=P-1)
PrintS(
", ");
405 const ideal I =
A->qideal;
434 poly aPlusB = p_Add_q(p_Copy((poly)a,
naRing),
437 return (number)aPlusB;
446 poly aPlusB = p_Add_q((poly)a, p_Copy((poly)
b,
naRing),
naRing);
456 if (a ==
NULL)
return (number)minusB;
457 poly aMinusB = p_Add_q(p_Copy((poly)a,
naRing), minusB,
naRing);
459 return (number)aMinusB;
466 poly aTimesB = pp_Mult_qq((poly)a, (poly)
b,
naRing);
469 return (number)aTimesB;
476 poly aTimesB = p_Mult_q((poly)a, p_Copy((poly)
b,
naRing),
naRing);
490 poly aDivB = p_Mult_q(p_Copy((poly)a,
naRing), bInverse,
naRing);
493 return (number)aDivB;
521 int expAbs =
exp;
if (expAbs < 0) expAbs = -expAbs;
524 poly
pow; poly aAsPoly = (poly)a;
528 for (
int i = 2;
i <= expAbs;
i++)
558 number n = (number)
pow;
579 if (p_Totaldegree(
p,
naRing) > 10 * p_Totaldegree(reducer,
naRing))
590 poly aAsPoly = (poly)a;
608 poly aAsPoly = (poly)a;
624 *a = (number)aAsPoly;
630static number naLcm(number a, number
b,
const coeffs cf)
635 number theProduct = (number)pp_Mult_qq((poly)a, (poly)
b,
naRing);
639 return naDiv(theProduct, theGcd,
cf);
666 a=(number)p_Copy((poly)a,
naRing);
668 if(!n_IsOne(t,
naRing->cf))
674 bt = n_SubringGcd(t, pGetCoeff(xx),
naRing->cf);
675 rr = n_Mult(t, pGetCoeff(xx),
naRing->cf);
676 n_Delete(&pGetCoeff(xx),
naRing->cf);
677 pGetCoeff(xx) = n_Div(rr, bt,
naRing->cf);
678 n_Normalize(pGetCoeff(xx),
naRing->cf);
708 const ideal mi =
naRing->qideal;
710 const ideal ii = e->
r->qideal;
727 if (a ==
NULL)
return 0;
728 poly aAsPoly = (poly)a;
730 while (aAsPoly !=
NULL)
733 int d = p_GetExp(aAsPoly, 1,
naRing);
791 return (number)p_Copy(ax,
naRing);
794 if(nCoeff_is_Zp(
naRing->cf))
798 number
x = n_Copy(pGetCoeff((poly)a),
naRing->cf);
804 number
y = n_SubringGcd(
x, pGetCoeff(ax),
naRing->cf);
812 number
y = n_SubringGcd(
x, pGetCoeff(bx),
naRing->cf);
836 poly aFactor =
NULL; poly mFactor =
NULL; poly theGcd =
NULL;
845 fmpz_init(
p); fmpz_init_set_ui(
p,
R->ch);
846 fmpz_mod_ctx_init(ctxp,
p);
849 fmpz_mod_poly_t modulus;
850 poly
p=
R->qideal->m[0];
851 fmpz_mod_poly_init2(modulus,deg(
p)+1,ctxp);
854 fmpz_mod_poly_set_coeff_ui(
result,p_GetExp(
p,1,
R),(
long)(pGetCoeff(
p)));
859 fq_ctx_init_modulus(ctx,modulus,ctxp,
"a");
860 fmpz_mod_poly_clear(modulus);
864 fq_poly_init2 (aa, p_GetExp(
ap,1,
R), ctx);
868 fmpz_poly_init2(
buf,fq_ctx_degree(ctx));
869 _fmpz_poly_set_length(
buf, fq_ctx_degree(ctx));
870 fmpz_set_si (
buf,(
long)pGetCoeff(
ap));
871 fq_poly_set_coeff (aa, p_GetExp(
ap,1,
R),
buf, ctx);
879 fmpz_mod_ctx_clear(ctxp);
888 if (ret)
return NULL;
892 p_Delete(&mFactor,
naRing);
899 WerrorS(
"zero divisor found - your minpoly is not irreducible");
902 p_Delete(&theGcd,
naRing);
904 return (number)(aFactor);
910 if (n_IsZero(a, src))
return NULL;
911 assume(src->rep == dst->extRing->cf->rep);
913 p_SetCoeff(
result, n_Copy(a, src), dst->extRing);
920 if (n_IsZero(a, src))
return NULL;
922 nMapFunc nMap=n_SetMap(src,dst->extRing->cf);
923 p_SetCoeff(
result, nMap(a, src, dst->extRing->cf), dst->extRing);
924 if (n_IsZero(pGetCoeff(
result),dst->extRing->cf))
925 p_Delete(&
result,dst->extRing);
932 if (n_IsZero(a, src))
return NULL;
934 int n = n_Int(a, src);
935 number q = n_Init(n, dst->extRing->cf);
937 p_SetCoeff(
result, q, dst->extRing);
944static number naCopyMap(number a,
const coeffs src,
const coeffs dst)
954 fraction fa=(fraction)a;
958 p = p_Copy(
NUM(fa),src->extRing);
961 q = p_Copy(DEN(fa),src->extRing);
967 assume ((strcmp(rRingVar(0,src->extRing),rRingVar(0,dst->extRing))==0) && (rVar (src->extRing) == rVar (dst->extRing)));
969 nMapFunc nMap= n_SetMap (src->extRing->cf, dst->extRing->cf);
975 q=
p_PermPoly (DEN (fa),
NULL, src->extRing, dst->extRing,nMap,
NULL,rVar (src->extRing));
987 number t=
naDiv ((number)
p,(number)q, dst);
988 p_Delete (&
p, dst->extRing);
989 p_Delete (&q, dst->extRing);
992 WerrorS (
"mapping denominator to zero");
1000 if (n_IsZero(a, src))
return NULL;
1003 number q =
nlModP(a, src, dst->extRing->cf);
1013 if (n_IsZero(a, src))
return NULL;
1014 assume(src == dst->extRing->cf);
1016 p_SetCoeff(
result, n_Copy(a, src), dst->extRing);
1023 if (n_IsZero(a, src))
return NULL;
1025 int n = n_Int(a, src);
1026 number q = n_Init(n, dst->extRing->cf);
1028 p_SetCoeff(
result, q, dst->extRing);
1036 const ring rSrc =
cf->extRing;
1037 const ring rDst = dst->extRing;
1039 const nMapFunc nMap=n_SetMap(rSrc->cf,rDst->cf);
1041 poly
g =
prMapR(
f, nMap, rSrc, rDst);
1051 const ring rSrc =
cf->extRing;
1052 const ring rDst = dst->extRing;
1054 const nMapFunc nMap=n_SetMap(rSrc->cf,rDst->cf);
1055 fraction
f = (fraction)a;
1062 h =
prMapR(DEN(
f), nMap, rSrc, rDst);
1067 p_Delete(&
g,dst->extRing);
1068 p_Delete(&
h,dst->extRing);
1099 if (nCoeff_is_Zp(src) && nCoeff_is_Zp(bDst))
1101 if (src->ch == dst->ch)
return naMapPP;
1105 if (
h != 1)
return NULL;
1109 nMapFunc nMap=n_SetMap(src->extRing->cf,dst->extRing->cf);
1110 if (
rSamePolyRep(src->extRing, dst->extRing) && (strcmp(rRingVar(0, src->extRing), rRingVar(0, dst->extRing)) == 0))
1117 else if ((nMap!=
NULL) && (strcmp(rRingVar(0,src->extRing),rRingVar(0,dst->extRing))==0) && (rVar (src->extRing) == rVar (dst->extRing)))
1130 if (a ==
NULL)
return -1;
1132 return cf->extRing->pFDeg(aa,
cf->extRing);
1140 const ring
R =
cf->extRing;
1142 assume( 0 < iParameter && iParameter <= rVar(
R) );
1144 poly
p =
p_One(
R); p_SetExp(
p, iParameter, 1,
R); p_Setm(
p,
R);
1155 const ring
R =
cf->extRing;
1168 const ring
R =
cf->extRing;
1174 numberCollectionEnumerator.
Reset();
1176 if( !numberCollectionEnumerator.
MoveNext() )
1185 int s1;
int s=2147483647;
1189 int normalcount = 0;
1195 number& n = numberCollectionEnumerator.
Current();
1208 }
while (numberCollectionEnumerator.
MoveNext() );
1215 numberCollectionEnumerator.
Reset();
1218 while (numberCollectionEnumerator.
MoveNext() )
1220 number& n = numberCollectionEnumerator.
Current();
1223 if( (--normalcount) <= 0)
1273 numberCollectionEnumerator.
Reset();
1276 while (numberCollectionEnumerator.
MoveNext() )
1278 number& n = numberCollectionEnumerator.
Current();
1285 n = (number) p_Mult_q(p_Copy(cInverse,
R), (poly)n,
R);
1289 n = (number) p_Mult_q(cInverse, (poly)n,
R);
1380 c = (number)
p_NSet(n,
cf->extRing);
1385 rDecRefCnt(
cf->extRing);
1386 if(
cf->extRing->ref<=0)
1397 l+=(strlen(
p[
i])+1);
1401 snprintf(
s,10+1,
"%d",r->ch);
1415 poly *P=(poly*)
omAlloc(rl*
sizeof(poly*));
1416 number *X=(number *)
omAlloc(rl*
sizeof(number));
1418 for(
i=0;
i<rl;
i++) P[
i]=p_Copy((poly)(
x[
i]),
cf->extRing);
1445 (e->
r->qideal->m[0] !=
NULL) );
1451 const ring
R = e->
r;
1491 if( rCanShortOut(
naRing) )
1515 cf->iNumberOfParameters = rVar(
R);
1516 cf->pParameterNames = (
const char**)
R->names;
1518 cf->has_simple_Inverse=
R->cf->has_simple_Inverse;
1549#define n2pTest(a) n2pDBTest(a,__FILE__,__LINE__,cf)
1552#define n2pTest(a) do {} while (0)
1556#define n2pRing cf->extRing
1562#define n2pCoeffs cf->extRing->cf
1583 poly aTimesB = pp_Mult_qq((poly)a, (poly)
b,
n2pRing);
1584 return (number)aTimesB;
1607 *a = (number)aAsPoly;
1639 l+=(strlen(
p[
i])+1);
1644 snprintf(
s,strlen(cf_s)+2,
"%s",cf_s);
1654 else { tt[0]=
']'; strcat(
s,tt); }
1663 const ring
A =
cf->extRing;
1666 PrintS(
"// polynomial ring as coefficient ring :\n");
1700 const ring
R = e->
r;
1759 cf->iNumberOfParameters = rVar(
R);
1760 cf->pParameterNames = (
const char**)
R->names;
Rational pow(const Rational &a, int e)
Concrete implementation of enumerators over polynomials.
static number naInit(long i, const coeffs cf)
number n2pDiv(number a, number b, const coeffs cf)
static number naSub(number a, number b, const coeffs cf)
static BOOLEAN naEqual(number a, number b, const coeffs cf)
static BOOLEAN naGreaterZero(number a, const coeffs cf)
forward declarations
static CanonicalForm naConvSingNFactoryN(number n, BOOLEAN, const coeffs cf)
static void naInpAdd(number &a, number b, const coeffs cf)
static BOOLEAN naIsOne(number a, const coeffs cf)
static void p_Monic(poly p, const ring r)
returns NULL if p == NULL, otherwise makes p monic by dividing by its leading coefficient (only done ...
static number naFarey(number p, number n, const coeffs cf)
static number naInvers(number a, const coeffs cf)
static void naPower(number a, int exp, number *b, const coeffs cf)
static number naGenTrans2AlgExt(number a, const coeffs cf, const coeffs dst)
number n2pMult(number a, number b, const coeffs cf)
static void heuristicReduce(poly &p, poly reducer, const coeffs cf)
const char * n2pRead(const char *s, number *a, const coeffs cf)
static number naChineseRemainder(number *x, number *q, int rl, BOOLEAN, CFArray &inv_cache, const coeffs cf)
static number naConvFactoryNSingN(const CanonicalForm n, const coeffs cf)
static number naMult(number a, number b, const coeffs cf)
static void naInpMult(number &a, number b, const coeffs cf)
static number naGenMap(number a, const coeffs cf, const coeffs dst)
static BOOLEAN naDBTest(number a, const char *f, const int l, const coeffs r)
static number naMapPP(number a, const coeffs src, const coeffs dst)
static void naClearContent(ICoeffsEnumerator &numberCollectionEnumerator, number &c, const coeffs cf)
static const char * naRead(const char *s, number *a, const coeffs cf)
static number napNormalizeHelper(number b, const coeffs cf)
static void naWriteShort(number a, const coeffs cf)
static int naSize(number a, const coeffs cf)
static number naAdd(number a, number b, const coeffs cf)
poly p_ExtGcd(poly p, poly &pFactor, poly q, poly &qFactor, ring r)
assumes that p and q are univariate polynomials in r, mentioning the same variable; assumes a global ...
static poly p_Gcd(const poly p, const poly q, const ring r)
static number naMapZ0(number a, const coeffs src, const coeffs dst)
static number naParameter(const int iParameter, const coeffs cf)
return the specified parameter as a number in the given alg. field
static number naMap0P(number a, const coeffs src, const coeffs dst)
BOOLEAN n2pDBTest(number a, const char *f, const int l, const coeffs r)
static void definiteReduce(poly &p, poly reducer, const coeffs cf)
static int naParDeg(number a, const coeffs cf)
static number naCopy(number a, const coeffs cf)
static number naCopyTrans2AlgExt(number a, const coeffs src, const coeffs dst)
static void naClearDenominators(ICoeffsEnumerator &numberCollectionEnumerator, number &c, const coeffs cf)
static number naMapUP(number a, const coeffs src, const coeffs dst)
static number naInitMPZ(mpz_t m, const coeffs r)
static BOOLEAN n2pCoeffIsEqual(const coeffs cf, n_coeffType n, void *param)
static long naInt(number &a, const coeffs cf)
static number naLcmContent(number a, number b, const coeffs cf)
char * n2pCoeffName(const coeffs cf)
static number naGcd(number a, number b, const coeffs cf)
static BOOLEAN naCoeffIsEqual(const coeffs cf, n_coeffType n, void *param)
char * naCoeffName(const coeffs r)
nMapFunc naSetMap(const coeffs src, const coeffs dst)
Get a mapping function from src into the domain of this type (n_algExt).
static poly p_ExtGcdHelper(poly &p, poly &pFactor, poly &q, poly &qFactor, ring r)
static void naKillChar(coeffs cf)
static BOOLEAN naGreater(number a, number b, const coeffs cf)
BOOLEAN naInitChar(coeffs cf, void *infoStruct)
Initialize the coeffs object.
static void naNormalize(number &a, const coeffs cf)
BOOLEAN n2pInitChar(coeffs cf, void *infoStruct)
static BOOLEAN naIsZero(number a, const coeffs cf)
number n2pInvers(number a, const coeffs cf)
static number naMap00(number a, const coeffs src, const coeffs dst)
static number naDiv(number a, number b, const coeffs cf)
int naIsParam(number m, const coeffs cf)
if m == var(i)/1 => return i,
void n2pCoeffWrite(const coeffs cf, BOOLEAN details)
static void naDelete(number *a, const coeffs cf)
#define n2pTest(a)
ABSTRACT: numbers as polys in the ring K[a] Assuming that we have a coeffs object cf,...
void n2pNormalize(number &a, const coeffs cf)
static number naMapP0(number a, const coeffs src, const coeffs dst)
static coeffs nCoeff_bottom(const coeffs r, int &height)
static void naCoeffWrite(const coeffs cf, BOOLEAN details)
static void naWriteLong(number a, const coeffs cf)
void n2pPower(number a, int exp, number *b, const coeffs cf)
static number naNeg(number a, const coeffs cf)
this is in-place, modifies a
static BOOLEAN naIsMOne(number a, const coeffs cf)
static poly p_GcdHelper(poly &p, poly &q, const ring r)
see p_Gcd; additional assumption: deg(p) >= deg(q); must destroy p and q (unless one of them is retur...
struct for passing initialization parameters to naInitChar
const CanonicalForm const CanonicalForm const CanonicalForm const CanonicalForm & cand
CanonicalForm convSingPFactoryP(poly p, const ring r)
poly convFactoryPSingP(const CanonicalForm &f, const ring r)
poly singclap_pdivide(poly f, poly g, const ring r)
BOOLEAN singclap_extgcd(poly f, poly g, poly &res, poly &pa, poly &pb, const ring r)
poly singclap_gcd_r(poly f, poly g, const ring r)
go into polynomials over an alg. extension recursively
Templated accessor interface for accessing individual data (for instance, of an enumerator).
virtual reference Current()=0
Gets the current element in the collection (read and write).
virtual void Reset()=0
Sets the enumerator to its initial position: -1, which is before the first element in the collection.
virtual bool MoveNext()=0
Advances the enumerator to the next element of the collection. returns true if the enumerator was suc...
Coefficient rings, fields and other domains suitable for Singular polynomials.
IEnumerator< number > ICoeffsEnumerator
Abstract interface for an enumerator of number coefficients for an object, e.g. a polynomial.
static FORCE_INLINE number n_NormalizeHelper(number a, number b, const coeffs r)
assume that r is a quotient field (otherwise, return 1) for arguments (a1/a2,b1/b2) return (lcm(a1,...
static FORCE_INLINE void n_CoeffWrite(const coeffs r, BOOLEAN details=TRUE)
output the coeff description
static FORCE_INLINE BOOLEAN nCoeff_is_Extension(const coeffs r)
number ndCopyMap(number a, const coeffs src, const coeffs dst)
#define n_Test(a, r)
BOOLEAN n_Test(number a, const coeffs r).
@ n_polyExt
used to represent polys as coefficients
@ n_algExt
used for all algebraic extensions, i.e., the top-most extension in an extension tower is algebraic
static FORCE_INLINE char const ** n_ParameterNames(const coeffs r)
Returns a (const!) pointer to (const char*) names of parameters.
static FORCE_INLINE BOOLEAN nCoeff_is_Q(const coeffs r)
static FORCE_INLINE void n_ClearDenominators(ICoeffsEnumerator &numberCollectionEnumerator, number &d, const coeffs r)
(inplace) Clears denominators on a collection of numbers number d is the LCM of all the coefficient d...
static FORCE_INLINE BOOLEAN nCoeff_is_Q_or_BI(const coeffs r)
static FORCE_INLINE char * nCoeffName(const coeffs cf)
static FORCE_INLINE number n_InitMPZ(mpz_t n, const coeffs r)
conversion of a GMP integer to number
static FORCE_INLINE int n_NumberOfParameters(const coeffs r)
Returns the number of parameters.
static FORCE_INLINE void n_ClearContent(ICoeffsEnumerator &numberCollectionEnumerator, number &c, const coeffs r)
Computes the content and (inplace) divides it out on a collection of numbers number c is the content ...
static FORCE_INLINE BOOLEAN nCoeff_is_algExt(const coeffs r)
TRUE iff r represents an algebraic extension field.
@ n_rep_gap_rat
(number), see longrat.h
@ n_rep_gap_gmp
(), see rinteger.h, new impl.
@ n_rep_poly
(poly), see algext.h
number(*) nMapFunc(number a, const coeffs src, const coeffs dst)
maps "a", which lives in src, into dst
static FORCE_INLINE BOOLEAN nCoeff_is_transExt(const coeffs r)
TRUE iff r represents a transcendental extension field.
static FORCE_INLINE BOOLEAN nCoeff_is_Q_algExt(const coeffs r)
is it an alg. ext. of Q?
const CanonicalForm int s
const CanonicalForm int const CFList const Variable & y
factory.h' is the user interface to Factory.
void WerrorS(const char *s)
poly p_ChineseRemainder(poly *xx, mpz_ptr *x, mpz_ptr *q, int rl, mpz_ptr *C, const ring R)
number nlModP(number q, const coeffs, const coeffs Zp)
int dReportError(const char *fmt,...)
#define p_SetCoeff0(p, n, r)
gmp_float exp(const gmp_float &a)
The main handler for Singular numbers which are suitable for Singular polynomials.
number ndGcd(number, number, const coeffs r)
const char *const nDivBy0
#define omFreeSize(addr, size)
poly p_Farey(poly p, number N, const ring r)
poly p_PolyDiv(poly &p, const poly divisor, const BOOLEAN needResult, const ring r)
assumes that p and divisor are univariate polynomials in r, mentioning the same variable; assumes div...
poly p_ISet(long i, const ring r)
returns the poly representing the integer i
poly p_PermPoly(poly p, const int *perm, const ring oldRing, const ring dst, nMapFunc nMap, const int *par_perm, int OldPar, BOOLEAN use_mult)
poly p_Power(poly p, int i, const ring r)
void p_Normalize(poly p, const ring r)
int p_Var(poly m, const ring r)
poly p_NSet(number n, const ring r)
returns the poly representing the number n, destroys n
long p_Deg(poly a, const ring r)
const char * p_Read(const char *st, poly &rc, const ring r)
BOOLEAN p_EqualPolys(poly p1, poly p2, const ring r)
void p_String0Long(const poly p, ring lmRing, ring tailRing)
print p in a long way
void p_String0Short(const poly p, ring lmRing, ring tailRing)
print p in a short way, if possible
void p_Write0(poly p, ring lmRing, ring tailRing)
#define __p_Mult_nn(p, n, r)
poly prMapR(poly src, nMapFunc nMap, ring src_r, ring dest_r)
void StringAppendS(const char *st)
void PrintS(const char *s)
void rWrite(ring r, BOOLEAN details)
BOOLEAN rSamePolyRep(ring r1, ring r2)
returns TRUE, if r1 and r2 represents the monomials in the same way FALSE, otherwise this is an analo...
void rDelete(ring r)
unconditionally deletes fields in r
BOOLEAN rEqual(ring r1, ring r2, BOOLEAN qr)
returns TRUE, if r1 equals r2 FALSE, otherwise Equality is determined componentwise,...
int status int void * buf
poly gcd_over_Q(poly f, poly g, const ring r)
helper routine for calling singclap_gcd_r