Loading...
Searching...
No Matches
monomials.h File Reference
`#include "reporter/reporter.h"`
`#include "coeffs/coeffs.h"`

Go to the source code of this file.

## Data Structures

struct | poly

## Macros

#define | pNext(p)
#define | pIter(p)
#define | p_GetCoeff(p, r)
#define | pSetCoeff0(p, n)
#define | p_SetCoeff0(p, n, r)
#define | __p_GetComp(p, r)
#define | p_GetComp(p, r)
#define | pAssumeReturn(cond)
#define | pAssume(cond)
#define | _pPolyAssumeReturn(cond, p, r)
#define | _pPolyAssume(cond, p, r)
#define | _pPolyAssumeReturnMsg(cond, msg, p, r)
#define | pPolyAssume(cond)
#define | pPolyAssumeReturn(cond)
#define | pPolyAssumeReturnMsg(cond, msg)
#define | pFalseReturn(cond)
#define | p_SetRingOfLm(p, r)
#define | pAssume1(cond)
#define | pPolyAssume1(cond)
#define | _pPolyAssume1(cond, p, r)
#define | pAssumeReturn1(cond)
#define | pPolyAssumeReturn1(cond)
#define | _pPolyAssumeReturn1(cond, p, r)
#define | p_LmCheckPolyRing1(p, r)
#define | p_CheckRing1(r)
#define | pIfThen1(cond, check)
#define | pAssume2(cond)
#define | pPolyAssume2(cond)
#define | _pPolyAssume2(cond, p, r)
#define | pAssumeReturn2(cond)
#define | pPolyAssumeReturn2(cond)
#define | _pPolyAssumeReturn2(cond, p, r)
#define | p_LmCheckPolyRing2(p, r)
#define | p_CheckRing2(r)
#define | pIfThen2(cond, check)
#define | p_AllocBin(p, bin, r)
#define | p_FreeBinAddr(p, r)
#define | POLYSIZE (sizeof(poly) + sizeof(number))
#define | POLYSIZEW (POLYSIZE / sizeof(long))
#define | POLY_NEGWEIGHT_OFFSET (((long)0x80000000) << 32)
#define | p_AllocBin(p, bin, r)
#define | p_FreeBinAddr(p, r)
#define | rRing_has_Comp(r)

## Functions

static number & | pGetCoeff (poly p)
| return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy
BOOLEAN | dPolyReportError (poly p, ring r, const char *fmt,...)

## Data Structure Documentation

## spolyrec

struct spolyrec

Definition at line 22 of file monomials.h.

Data Fields
number | coef |
unsigned long | exp[1] |
poly | next |

## Macro Definition Documentation

## __p_GetComp

#define __p_GetComp | ( |  | p,
|  |  | r )

Value:
(p)->exp[r->pCompIndex]
p
int p
Definition cfModGcd.cc:4086
exp
gmp_float exp(const gmp_float &a)
Definition mpr_complex.cc:349

Definition at line 63 of file monomials.h.

## _pPolyAssume

#define _pPolyAssume | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "pPolyAssume violation of: %s", \
#cond); \
} \
} \
while (0)

Definition at line 113 of file monomials.h.

#define _pPolyAssume(cond,p,r) \
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "pPolyAssume violation of: %s", \
#cond); \
} \
} \
while (0)

## _pPolyAssume1

#define _pPolyAssume1 | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 173 of file monomials.h.

## _pPolyAssume2

#define _pPolyAssume2 | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 195 of file monomials.h.

## _pPolyAssumeReturn

#define _pPolyAssumeReturn | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "pPolyAssume violation of: %s", \
#cond); \
return FALSE; \
} \
} \
while (0)
FALSE
#define FALSE
Definition auxiliary.h:97

Definition at line 101 of file monomials.h.

#define _pPolyAssumeReturn(cond, p, r) \
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "pPolyAssume violation of: %s", \
#cond); \
return FALSE; \
} \
} \
while (0)

## _pPolyAssumeReturn1

#define _pPolyAssumeReturn1 | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 176 of file monomials.h.

## _pPolyAssumeReturn2

#define _pPolyAssumeReturn2 | ( |  | cond,
|  |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 198 of file monomials.h.

## _pPolyAssumeReturnMsg

#define _pPolyAssumeReturnMsg | ( |  | cond,
|  |  | msg,
|  |  | p,
|  |  | r )

Value:
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "%s ", msg); \
return FALSE; \
} \
} \
while (0)

Definition at line 124 of file monomials.h.

#define _pPolyAssumeReturnMsg(cond, msg, p, r) \
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(p, r, "%s ", msg); \
return FALSE; \
} \
} \
while (0)

## p_AllocBin [1/2]

#define p_AllocBin | ( |  | p,
|  |  | bin,
|  |  | r )

Value:
do \
{ \
omTypeAllocBin(poly, p, bin); \
p_SetRingOfLm(p, r); \
} \
while (0)

Definition at line 210 of file monomials.h.

#define p_AllocBin(p, bin, r) \
do \
{ \
omTypeAllocBin(poly, p, bin); \
p_SetRingOfLm(p, r); \
} \
while (0)

## p_AllocBin [2/2]

#define p_AllocBin | ( |  | p,
|  |  | bin,
|  |  | r )

Value:
do \
{ \
omTypeAllocBin(poly, p, bin); \
p_SetRingOfLm(p, r); \
} \
while (0)

Definition at line 210 of file monomials.h.

#define p_AllocBin(p, bin, r) \
do \
{ \
omTypeAllocBin(poly, p, bin); \
p_SetRingOfLm(p, r); \
} \
while (0)

## p_CheckRing1

#define p_CheckRing1 | ( |  | r | ) |

Value:
do {} while (0)

Definition at line 178 of file monomials.h.

## p_CheckRing2

#define p_CheckRing2 | ( |  | r | ) |

Value:
do {} while (0)

Definition at line 200 of file monomials.h.

## p_FreeBinAddr [1/2]

#define p_FreeBinAddr | ( |  | p,
|  |  | r )

Value:
p_LmFree(p, r)
p_LmFree
static void p_LmFree(poly p, ring)
Definition p_polys.h:685

Definition at line 217 of file monomials.h.

## p_FreeBinAddr [2/2]

#define p_FreeBinAddr | ( |  | p,
|  |  | r )

Value:
p_LmFree(p, r)

Definition at line 217 of file monomials.h.

## p_GetCoeff

#define p_GetCoeff | ( |  | p,
|  |  | r )

Value:
pGetCoeff(p)
pGetCoeff
static number & pGetCoeff(poly p)
return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy
Definition monomials.h:44

Definition at line 50 of file monomials.h.

## p_GetComp

#define p_GetComp | ( |  | p,
|  |  | r )

Value:
((long) (r->pCompIndex >= 0 ? __p_GetComp(p, r) : 0))
__p_GetComp
#define __p_GetComp(p, r)
Definition monomials.h:63

Definition at line 64 of file monomials.h.

## p_LmCheckPolyRing1

#define p_LmCheckPolyRing1 | ( |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 177 of file monomials.h.

## p_LmCheckPolyRing2

#define p_LmCheckPolyRing2 | ( |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 199 of file monomials.h.

## p_SetCoeff0

#define p_SetCoeff0 | ( |  | p,
|  |  | n,
|  |  | r )

Value:
pSetCoeff0(p,n)
pSetCoeff0
#define pSetCoeff0(p, n)
Definition monomials.h:59

Definition at line 60 of file monomials.h.

## p_SetRingOfLm

#define p_SetRingOfLm | ( |  | p,
|  |  | r )

Value:
do {} while (0)

Definition at line 144 of file monomials.h.

## pAssume

#define pAssume | ( |  | cond | ) |

Value:
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(NULL, NULL, "pAssume violation of: %s", \
#cond); \
} \
} \
while (0)
NULL
#define NULL
Definition omList.c:12

Definition at line 90 of file monomials.h.

#define pAssume(cond) \
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(NULL, NULL, "pAssume violation of: %s", \
#cond); \
} \
} \
while (0)

## pAssume1

#define pAssume1 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 171 of file monomials.h.

## pAssume2

#define pAssume2 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 193 of file monomials.h.

## pAssumeReturn

#define pAssumeReturn | ( |  | cond | ) |

Value:
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(NULL, NULL, "pAssume violation of: %s", \
#cond); \
return FALSE; \
} \
} \
while (0)

Definition at line 78 of file monomials.h.

#define pAssumeReturn(cond) \
do \
{ \
if (! (cond)) \
{ \
dPolyReportError(NULL, NULL, "pAssume violation of: %s", \
#cond); \
return FALSE; \
} \
} \
while (0)

## pAssumeReturn1

#define pAssumeReturn1 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 174 of file monomials.h.

## pAssumeReturn2

#define pAssumeReturn2 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 196 of file monomials.h.

## pFalseReturn

#define pFalseReturn | ( |  | cond | ) |

Value:
do {if (! (cond)) return FALSE;} while (0)

Definition at line 139 of file monomials.h.

## pIfThen1

#define pIfThen1 | ( |  | cond,
|  |  | check )

Value:
do {} while (0)

Definition at line 179 of file monomials.h.

## pIfThen2

#define pIfThen2 | ( |  | cond,
|  |  | check )

Value:
do {} while (0)

Definition at line 201 of file monomials.h.

## pIter

#define pIter | ( |  | p | ) |

Value:
(void)((p) = (p)->next)
next
ListNode * next
Definition janet.h:31

Definition at line 37 of file monomials.h.

## pNext

#define pNext | ( |  | p | ) |

Value:
((p)->next)

Definition at line 36 of file monomials.h.

## POLY_NEGWEIGHT_OFFSET

#define POLY_NEGWEIGHT_OFFSET (((long)0x80000000) << 32)

Definition at line 236 of file monomials.h.

## POLYSIZE

#define POLYSIZE (sizeof(poly) + sizeof(number))

Definition at line 233 of file monomials.h.

## POLYSIZEW

#define POLYSIZEW (POLYSIZE / sizeof(long))

Definition at line 234 of file monomials.h.

## pPolyAssume

#define pPolyAssume | ( |  | cond | ) |

Value:
_pPolyAssume(cond, p, r)
_pPolyAssume
#define _pPolyAssume(cond, p, r)
Definition monomials.h:113

Definition at line 135 of file monomials.h.

## pPolyAssume1

#define pPolyAssume1 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 172 of file monomials.h.

## pPolyAssume2

#define pPolyAssume2 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 194 of file monomials.h.

## pPolyAssumeReturn

#define pPolyAssumeReturn | ( |  | cond | ) |

Value:
_pPolyAssumeReturn(cond, p, r)
_pPolyAssumeReturn
#define _pPolyAssumeReturn(cond, p, r)
Definition monomials.h:101

Definition at line 136 of file monomials.h.

## pPolyAssumeReturn1

#define pPolyAssumeReturn1 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 175 of file monomials.h.

## pPolyAssumeReturn2

#define pPolyAssumeReturn2 | ( |  | cond | ) |

Value:
do {} while (0)

Definition at line 197 of file monomials.h.

## pPolyAssumeReturnMsg

#define pPolyAssumeReturnMsg | ( |  | cond,
|  |  | msg )

Value:
_pPolyAssumeReturnMsg(cond, msg, p, r)
_pPolyAssumeReturnMsg
#define _pPolyAssumeReturnMsg(cond, msg, p, r)
Definition monomials.h:124

Definition at line 137 of file monomials.h.

## pSetCoeff0

#define pSetCoeff0 | ( |  | p,
|  |  | n )

Value:
(p)->coef=(n)

Definition at line 59 of file monomials.h.

## rRing_has_Comp

#define rRing_has_Comp | ( |  | r | ) |

Value:
(r->pCompIndex >= 0)

Definition at line 266 of file monomials.h.

## Function Documentation

## dPolyReportError()

BOOLEAN dPolyReportError | ( | poly | p,
|  | ring | r,
|  | const char * | fmt,
|  |  | ... )

extern

Definition at line 43 of file pDebug.cc.

{
if (d_poly_error_reporting) return FALSE;
d_poly_error_reporting = TRUE;
va_list ap;
va_start(ap, fmt);
fprintf(stderr, "\n// ***dPolyReportError: ");
vfprintf(stderr, fmt, ap);
fprintf(stderr, "\n occurred at\n");
#ifdef HAVE_OMALLOC
omPrintCurrentBackTraceMax(stderr, 8);
#endif
if (p != NULL)
{
fprintf(stderr, " occurred for poly: ");
p_wrp(p, r);
omPrintAddrInfo(stderr, p, " ");
}
#ifndef MAKE_DISTRIBUTION
dErrorBreak();
#endif
d_poly_error_reporting = FALSE;
return FALSE;
}
TRUE
#define TRUE
Definition auxiliary.h:101
dErrorBreak
void dErrorBreak(void)
Definition dError.cc:140
ap
Definition ap.h:40
d_poly_error_reporting
STATIC_VAR BOOLEAN d_poly_error_reporting
Definition pDebug.cc:42
p_wrp
void p_wrp(poly p, ring lmRing, ring tailRing)
Definition polys0.cc:373
omPrintAddrInfo
#define omPrintAddrInfo(A, B, C)
Definition xalloc.h:270
omPrintCurrentBackTraceMax
#define omPrintCurrentBackTraceMax(A, B)
Definition xalloc.h:265

## pGetCoeff()

number & pGetCoeff | ( | poly | p | ) |

inline static

return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy

Definition at line 44 of file monomials.h.

{
assume(p != NULL);
return p->coef;
}
assume
#define assume(x)
Definition mod2.h:389