TermExtra.h File Reference
`#include "Term.h"`

Go to the source code of this file.

## Functions

Exponent | median (const Exponent *a, size_t varCount)
| Returns the lower median exponent of a.
Exponent | median (const Term &a)
Exponent | medianPositive (const Exponent *a, size_t varCount)
| Returns the lower median of the positive exponents of a.
Exponent | medianPositive (const Term &a)
void | totalDegree (mpz_class &res, const Exponent *a, size_t varCount)
| Puts the sum of the entries of a into res.
void | totalDegree (mpz_class &res, const Term &a)
Exponent | minimumPositive (const Exponent *a, size_t varCount)
| Returns the smallest positive exponent of a.
Exponent | minimumPositive (const Term &a)
Exponent | maximum (const Exponent *a, size_t varCount)
| Returns the largest exponent of a.
Exponent | maximum (const Term &a)

## Function Documentation

## maximum() [1/2]

Exponent maximum | ( | const Exponent * | a,
|  | size_t | varCount )

Returns the largest exponent of a.

Returns zero if varCount is zero.

Definition at line 68 of file TermExtra.cpp.

## maximum() [2/2]

Exponent maximum | ( | const Term & | a | ) |

inline

Definition at line 61 of file TermExtra.h.

## median() [1/2]

Exponent median | ( | const Exponent * | a,
|  | size_t | varCount )

Returns the lower median exponent of a.

Returns zero if varCount is zero.

Definition at line 25 of file TermExtra.cpp.

## median() [2/2]

Exponent median | ( | const Term & | a | ) |

inline

Definition at line 32 of file TermExtra.h.

## medianPositive() [1/2]

Exponent medianPositive | ( | const Exponent * | a,
|  | size_t | varCount )

Returns the lower median of the positive exponents of a.

Returns zero if all terms of a are zero.

Definition at line 35 of file TermExtra.cpp.

## medianPositive() [2/2]

Exponent medianPositive | ( | const Term & | a | ) |

inline

Definition at line 39 of file TermExtra.h.

## minimumPositive() [1/2]

Exponent minimumPositive | ( | const Exponent * | a,
|  | size_t | varCount )

Returns the smallest positive exponent of a.

Returns zero if all entries of a are zero.

Definition at line 55 of file TermExtra.cpp.

## minimumPositive() [2/2]

Exponent minimumPositive | ( | const Term & | a | ) |

inline

Definition at line 54 of file TermExtra.h.

## totalDegree() [1/2]

void totalDegree | ( | mpz_class & | res,
|  | const Exponent * | a,
|  | size_t | varCount )

Puts the sum of the entries of a into res.

res has to be an mpz_class as opposed to an Exponent since the sum could cause an overflow.

Definition at line 49 of file TermExtra.cpp.

## totalDegree() [2/2]

void totalDegree | ( | mpz_class & | res,
|  | const Term & | a )

inline

Definition at line 47 of file TermExtra.h.