|
| Term () |
|
| Term (const Term &term) |
|
| Term (const Exponent *exponents, size_t varCount) |
|
| Term (size_t varCount) |
| This object is initialized to the identity, i.e. the exponent vector is the zero vector. More...
|
|
| Term (const string &str) |
| Accepts a whitespace-separated list of integers as exponent vector. More...
|
|
| ~Term () |
|
| operator Exponent * () |
|
| operator const Exponent * () const |
|
Exponent * | begin () |
|
const Exponent * | begin () const |
|
Exponent * | end () |
|
const Exponent * | end () const |
|
size_t | getVarCount () const |
|
Exponent | operator[] (int offset) const |
|
Exponent | operator[] (unsigned int offset) const |
|
Exponent | operator[] (unsigned long offset) const |
|
Exponent | operator[] (unsigned long long offset) const |
|
Exponent & | operator[] (int offset) |
|
Exponent & | operator[] (unsigned int offset) |
|
Exponent & | operator[] (unsigned long offset) |
|
Exponent & | operator[] (unsigned long long offset) |
|
bool | operator== (const Term &term) const |
|
bool | operator== (const Exponent *term) const |
|
bool | operator!= (const Term &term) const |
|
bool | operator!= (const Exponent *term) const |
|
Term & | operator= (const Term &term) |
|
Term & | operator= (const Exponent *exponents) |
|
bool | divides (const Term &term) const |
|
bool | divides (const Exponent *term) const |
|
bool | dominates (const Term &term) const |
|
bool | dominates (const Exponent *term) const |
|
bool | strictlyDivides (const Term &term) const |
|
bool | strictlyDivides (const Exponent *term) const |
|
void | lcm (const Term &a, const Term &b, int position) |
|
void | lcm (const Term &a, const Term &b) |
|
void | lcm (const Exponent *a, const Exponent *b) |
|
void | gcd (const Term &a, const Term &b) |
|
void | gcd (const Exponent *a, const Exponent *b) |
|
void | product (const Term &a, const Term &b) |
| Set this object equal to the product of a and b. More...
|
|
void | product (const Exponent *a, const Exponent *b) |
|
void | setToIdentity () |
|
bool | isIdentity () const |
|
bool | isSquareFree () const |
|
size_t | getFirstNonZeroExponent () const |
|
size_t | getMiddleNonZeroExponent () const |
|
size_t | getFirstMaxExponent () const |
|
size_t | getMaxExponent () const |
|
size_t | getSizeOfSupport () const |
|
size_t | getHashCode () const |
|
bool | sharesNonZeroExponent (const Exponent *a) const |
|
bool | sharesNonZeroExponent (const Term &a) const |
|
bool | hasSameSupport (const Term &a) const |
|
bool | hasSameSupport (const Exponent *a) const |
|
void | colon (const Term &a, const Term &b) |
|
void | colon (const Exponent *a, const Exponent *b) |
|
void | encodedDual (const Term &dualOf, const Term &point) |
|
void | encodedDual (const Exponent *dualOf, const Exponent *point) |
|
void | decrement () |
|
void | swap (Term &term) |
|
void | reset (size_t newVarCount) |
|
void | clear () |
|
void | print (FILE *file) const |
|
void | print (ostream &out) const |
|
|
static bool | divides (const Exponent *a, const Exponent *b, size_t varCount) |
| Returns whether a divides b. More...
|
|
static bool | dominates (const Exponent *a, const Exponent *b, size_t varCount) |
| Returns whether a dominates b, i.e. whether b divides a. More...
|
|
static bool | strictlyDivides (const Exponent *a, const Exponent *b, size_t varCount) |
| Returns whether a strictly divides b. More...
|
|
static void | lcm (Exponent *res, const Exponent *a, const Exponent *b, size_t varCount) |
| Sets res equal to the least commom multiple of a and b. More...
|
|
static void | gcd (Exponent *res, const Exponent *a, const Exponent *b, size_t varCount) |
| Sets res equal to the greatest common divisor of a and b. More...
|
|
static void | product (Exponent *res, const Exponent *a, const Exponent *b, size_t varCount) |
| Sets res equal to the product of a and b. More...
|
|
static void | setToIdentity (Exponent *res, size_t varCount) |
| Set res equal to , i.e. set each entry of res equal to 0. More...
|
|
static bool | isIdentity (const Exponent *a, size_t varCount) |
| Returns whether a is 1, i.e. whether all entries of a are 0. More...
|
|
static bool | isSquareFree (const Exponent *a, size_t varCount) |
| Returns whether a is square free, i.e. for each where . More...
|
|
static size_t | getFirstNonZeroExponent (const Exponent *a, size_t varCount) |
| Returns least var such that a[var] is non-zero. More...
|
|
static size_t | getMiddleNonZeroExponent (const Exponent *a, size_t varCount) |
| Returns a median element of the set of var's such that a[var] is non-zero. More...
|
|
static size_t | getFirstMaxExponent (const Exponent *a, size_t varCount) |
| Returns a var such that a[var] >= a[i] for all i. More...
|
|
static size_t | getSizeOfSupport (const Exponent *a, size_t varCount) |
| Returns the number of variables such that divides . More...
|
|
static bool | sharesNonZeroExponent (const Exponent *a, const Exponent *b, size_t varCount) |
| Returns whether there is some such that . More...
|
|
static size_t | getHashCode (const Exponent *a, size_t varCount) |
|
static bool | hasSameSupport (const Exponent *a, const Exponent *b, size_t varCount) |
| Returns whether for every variable . More...
|
|
static void | colon (Exponent *res, const Exponent *a, const Exponent *b, size_t varCount) |
| Sets res equal to . More...
|
|
static void | encodedDual (Exponent *res, const Exponent *dualOf, const Exponent *point, size_t varCount) |
| The parameter dualOf is interpreted to encode an irreducible ideal, and the dual of that reflected in point is a principal ideal. More...
|
|
static void | decrement (Exponent *a, size_t varCount) |
| Decrements each positive entry of a by one. More...
|
|
static void | print (FILE *file, const Exponent *e, size_t varCount) |
| Writes e to file in a format suitable for debug output. More...
|
|
static void | print (ostream &out, const Exponent *e, size_t varCount) |
| Writes e to out in a format suitable for debug output. More...
|
|
Term represents a product of variables which does not include a coefficient.
This concept is also sometimes called a monomial or power product.
A term is represented as an array of Exponent and an integer indicating the length of the array, i.e. the number of variables. It is sometimes desirable to separate the length from the array, e.g. when representing an array of terms all of the same length, such as in representing the generators of a monomial ideal, in which case representing the length once for each generator would be wasteful. Thus Term has static versions of most methods where the number of variables is a separate parameter. In these cases it is allowed for the exponent array pointer to be null (i.e. equal to 0) if the length is zero.
Most methods on Term are inline to avoid function call overhead. This is significant because these methods tend to be called in the innermost loops of monomial ideal algorithms.
- Todo:
- Move the inline code out of the class declaration and add them as inline below the class declaration.
- Todo:
- Duplicate the comments for overloads using the copydoc Doxygen command.
- Todo:
- Rename term.h to Term.h.
Definition at line 49 of file Term.h.