GiNaCRA
0.6.4
|
A class for a univariate polynomial providing everything what a GiNaC expression of type polynomial is and in addition, stores the single main variable of the polynomial. More...
#include <UnivariatePolynomial.h>
Public Types | |
enum | subresultantStrategy { GENERIC_SUBRESULTANTSTRATEGY, LAZARDS_SUBRESULTANTSTRATEGY, DUCOS_SUBRESULTANTSTRATEGY } |
Predefined flags for different solving strategies in UnivariatePolynomial::subresultants . More... | |
Public Member Functions | |
UnivariatePolynomial () | |
Constructs a univariate polynomial consisting of the standard variable defined in constants.h. | |
UnivariatePolynomial (const numeric &n) | |
Constructs a univariate polynomial with exactly the specified root. | |
UnivariatePolynomial (const ex &p, const symbol &s, bool enableCheck=true) throw ( invalid_argument ) | |
Constructs a univariate polynomial. | |
UnivariatePolynomial (const UnivariatePolynomial &p) | |
Constructs a univariate polynomial as copy of another one. | |
const symbol | variable () const |
Selects the main variable of the polynomial. | |
const bool | enabledPolynomialCheck () const |
Selects the flag for the is_rational_polynomial check. | |
UnivariatePolynomial | inVariable (const symbol &x) const |
const UnivariatePolynomial & | operator= (const UnivariatePolynomial &) |
This polynomial gets all values of the other. | |
const UnivariatePolynomial & | operator= (const ex &) |
This polynomial gets all values of the other expression, using the current main variable. | |
ex | coeff (int i) const |
ex | lcoeff () const |
ex | tcoeff () const |
ex | content () const |
UnivariatePolynomial | diff (unsigned nth=1) const |
UnivariatePolynomial | trunc () const |
Removes the leading term. | |
bool | isZero () const |
Returns true if the univariate polynomial is the zero polynomial, otherwise false. | |
const bool | hasZeroRoot () const |
int | degree () const |
int | ldegree () const |
The low-degree is the smallest exponent at the main variable occuring. | |
UnivariatePolynomial | primpart () const |
UnivariatePolynomial | primpart (const ex &content) const |
UnivariatePolynomial | sepapart () const |
Computes a polynomial being decomposed into linear factors of multiplicity 1 with the same set of zeros as this polynomial. | |
UnivariatePolynomial | nonzeropart () const |
Eliminates the root 0 from the polynomial by dividing the polynomial by a power of the main variable. | |
bool | isCompatible (const UnivariatePolynomial &o) const |
Compares univariate polynomials for compatibility regarding common computations. | |
bool | isConstant () const |
Returns true if the univariate polynomial is constant in the respective variable, otherwise false. | |
ex | evaluateAt (const ex &a) const |
Evaluation of the univariate polynomial at the specified expression, yielding a term in the coefficients only. | |
const UnivariatePolynomial | rem (const UnivariatePolynomial &o) const |
Compute the remainder of o modulo the given polynomial in this variable. | |
const UnivariatePolynomial | quo (const UnivariatePolynomial &o) const |
Compute the quotient of division by o in this variable. | |
const UnivariatePolynomial | add (const UnivariatePolynomial &o) const |
Compute the sum of this and o in this variable. | |
const UnivariatePolynomial | mul (const UnivariatePolynomial &o) const |
Compute the product of this and o in this variable. | |
const UnivariatePolynomial | sub (const UnivariatePolynomial &o) const |
Compute the subtraction of this by o in this variable. | |
UnivariatePolynomial | square () const |
Calculates the square. | |
const UnivariatePolynomial | gcd (const UnivariatePolynomial &o) const |
Computes the greatest common divisor of this polynomial and the given by Euclid's algorithm. | |
const UnivariatePolynomial | resultant (const UnivariatePolynomial &o) const |
Compute the resultant of o and the given polynomial in this variable. | |
const bool | isEqual (const UnivariatePolynomial &o) const |
void | do_print (const print_context &c, unsigned level=0) const |
Static Public Member Functions | |
static list< UnivariatePolynomial > | standardSturmSequence (const UnivariatePolynomial &a, const UnivariatePolynomial &b) throw ( invalid_argument ) |
Generates a standard Sturm sequence by generating an additively inverted polynomial remainder sequence. | |
static bool | univariatePolynomialIsLess (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static bool | univariatePolynomialIsLessLowDeg (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static bool | univariatePolynomialIsLessOddDeg (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static bool | univariatePolynomialIsLessOddLowDeg (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static bool | univariatePolynomialIsLessEvenDeg (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static bool | univariatePolynomialIsLessEvenLowDeg (const UnivariatePolynomial &a, const UnivariatePolynomial &b) |
Compares two univariate polynomials. | |
static const list < UnivariatePolynomial > | subresultants (const UnivariatePolynomial &a, const UnivariatePolynomial &b, const subresultantStrategy strategy=GENERIC_SUBRESULTANTSTRATEGY) |
Computes the subresultant sequence according to the algorithm in [Lionel Ducos. | |
static const vector< ex > | subresultantCoefficients (const UnivariatePolynomial &a, const UnivariatePolynomial &b, const subresultantStrategy strategy=GENERIC_SUBRESULTANTSTRATEGY) |
Returns the leading coefficients of the subresultants of a and b. | |
static const vector< ex > | principalSubresultantCoefficients (const UnivariatePolynomial &a, const UnivariatePolynomial &b, const subresultantStrategy strategy=GENERIC_SUBRESULTANTSTRATEGY) |
Returns the i-th coefficients of the i-th subresultant of a and b at the i-th position of the result vector. | |
Protected Attributes | |
symbol | mVariable |
bool | mEnabledPolynomialCheck |
A class for a univariate polynomial providing everything what a GiNaC expression of type polynomial is and in addition, stores the single main variable of the polynomial.
Definition at line 51 of file UnivariatePolynomial.h.
Predefined flags for different solving strategies in UnivariatePolynomial::subresultants
.
Definition at line 461 of file UnivariatePolynomial.h.
GiNaCRA::UnivariatePolynomial::UnivariatePolynomial | ( | ) | [inline] |
Constructs a univariate polynomial consisting of the standard variable defined in constants.h.
Definition at line 63 of file UnivariatePolynomial.h.
Referenced by add(), diff(), evaluateAt(), gcd(), inVariable(), mul(), nonzeropart(), primpart(), quo(), rem(), resultant(), sepapart(), square(), sub(), subresultants(), and trunc().
GiNaCRA::UnivariatePolynomial::UnivariatePolynomial | ( | const numeric & | n | ) | [inline] |
Constructs a univariate polynomial with exactly the specified root.
n | root to-be |
Definition at line 73 of file UnivariatePolynomial.h.
GiNaCRA::UnivariatePolynomial::UnivariatePolynomial | ( | const ex & | p, |
const symbol & | s, | ||
bool | enableCheck = true |
||
) | throw ( invalid_argument ) |
Constructs a univariate polynomial.
p | polynomial |
s | main variable of the univariate polynomial p |
enableCheck | if set to true (default), the polynomial is checked for being a proper polynomial by GiNaC::ex::is_polynomial. Otherwise no check will be performed. |
Definition at line 49 of file UnivariatePolynomial.cpp.
GiNaCRA::UnivariatePolynomial::UnivariatePolynomial | ( | const UnivariatePolynomial & | p | ) | [inline] |
Constructs a univariate polynomial as copy of another one.
p | univariate polynomial |
Definition at line 91 of file UnivariatePolynomial.h.
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::add | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the sum of this and o
in this variable.
o | other polynomial |
Definition at line 311 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::operator+().
ex GiNaCRA::UnivariatePolynomial::coeff | ( | int | i | ) | const [inline] |
i | degree of which the coefficient shall be returned |
Reimplemented in GiNaCRA::RationalUnivariatePolynomial.
Definition at line 148 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RationalUnivariatePolynomial::cauchyBound(), and nonzeropart().
ex GiNaCRA::UnivariatePolynomial::content | ( | ) | const [inline] |
Definition at line 172 of file UnivariatePolynomial.h.
References mVariable.
int GiNaCRA::UnivariatePolynomial::degree | ( | ) | const [inline] |
Definition at line 212 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RationalUnivariatePolynomial::cauchyBound(), GiNaCRA::RealAlgebraicNumberFactory::commonRealRoots(), GiNaCRA::RationalUnivariatePolynomial::evaluateAt(), GiNaCRA::RealAlgebraicNumberIR::inverse(), isConstant(), GiNaCRA::RationalUnivariatePolynomial::maximumNorm(), nonzeropart(), GiNaCRA::RationalUnivariatePolynomial::oneNorm(), subresultants(), GiNaCRA::RationalUnivariatePolynomial::twoNorm(), univariatePolynomialIsLessEvenDeg(), univariatePolynomialIsLessEvenLowDeg(), univariatePolynomialIsLessLowDeg(), univariatePolynomialIsLessOddDeg(), and univariatePolynomialIsLessOddLowDeg().
UnivariatePolynomial GiNaCRA::UnivariatePolynomial::diff | ( | unsigned | nth = 1 | ) | const [inline] |
nth |
Definition at line 181 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::RealAlgebraicNumberIR::add(), GiNaCRA::RationalUnivariatePolynomial::approximateRealRoot(), GiNaCRA::RationalUnivariatePolynomial::calculateRemainderTarskiQuery(), GiNaCRA::RationalUnivariatePolynomial::countRealRoots(), GiNaCRA::CAD::elimination(), GiNaCRA::RealAlgebraicNumberFactory::evaluateIR(), GiNaCRA::RealAlgebraicNumberIR::mul(), GiNaCRA::RealAlgebraicNumberFactory::realRoots(), GiNaCRA::RealAlgebraicNumberFactory::realRootsEval(), sepapart(), and GiNaCRA::RealAlgebraicNumberIR::sgn().
void GiNaCRA::UnivariatePolynomial::do_print | ( | const print_context & | c, |
unsigned | level = 0 |
||
) | const |
Definition at line 62 of file UnivariatePolynomial.cpp.
References mVariable.
const bool GiNaCRA::UnivariatePolynomial::enabledPolynomialCheck | ( | ) | const [inline] |
Selects the flag for the is_rational_polynomial check.
Definition at line 114 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck.
Referenced by GiNaCRA::operator-().
ex GiNaCRA::UnivariatePolynomial::evaluateAt | ( | const ex & | a | ) | const [inline] |
Evaluation of the univariate polynomial at the specified expression, yielding a term in the coefficients only.
a | an expression for evaluation |
Definition at line 277 of file UnivariatePolynomial.h.
References mVariable, and UnivariatePolynomial().
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::gcd | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Computes the greatest common divisor of this polynomial and the given by Euclid's algorithm.
o |
Definition at line 351 of file UnivariatePolynomial.h.
References GiNaC::gcd(), mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by sepapart().
const bool GiNaCRA::UnivariatePolynomial::hasZeroRoot | ( | ) | const [inline] |
Definition at line 204 of file UnivariatePolynomial.h.
References ldegree().
Referenced by GiNaCRA::RealAlgebraicNumberFactory::realRoots(), and GiNaCRA::RealAlgebraicNumberFactory::realRootsEval().
UnivariatePolynomial GiNaCRA::UnivariatePolynomial::inVariable | ( | const symbol & | x | ) | const [inline] |
Definition at line 123 of file UnivariatePolynomial.h.
References mVariable, and UnivariatePolynomial().
bool GiNaCRA::UnivariatePolynomial::isCompatible | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compares univariate polynomials for compatibility regarding common computations.
Definition at line 259 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RealAlgebraicNumberIR::sgn(), and subresultants().
bool GiNaCRA::UnivariatePolynomial::isConstant | ( | ) | const [inline] |
Returns true if the univariate polynomial is constant in the respective variable, otherwise false.
Definition at line 268 of file UnivariatePolynomial.h.
References degree(), and mVariable.
Referenced by GiNaCRA::RealAlgebraicNumberFactory::realRoots(), sepapart(), and GiNaCRA::CAD::truncation().
const bool GiNaCRA::UnivariatePolynomial::isEqual | ( | const UnivariatePolynomial & | o | ) | const [inline] |
o |
Definition at line 378 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::operator!=(), GiNaCRA::UnivariatePolynomialSetEquals::operator()(), GiNaCRA::operator==(), and univariatePolynomialIsLess().
bool GiNaCRA::UnivariatePolynomial::isZero | ( | ) | const [inline] |
Returns true if the univariate polynomial is the zero polynomial, otherwise false.
Definition at line 196 of file UnivariatePolynomial.h.
Referenced by GiNaCRA::CAD::elimination(), and subresultants().
ex GiNaCRA::UnivariatePolynomial::lcoeff | ( | ) | const [inline] |
Reimplemented in GiNaCRA::RationalUnivariatePolynomial.
Definition at line 156 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RationalUnivariatePolynomial::cauchyBound(), and subresultants().
int GiNaCRA::UnivariatePolynomial::ldegree | ( | ) | const [inline] |
The low-degree is the smallest exponent at the main variable occuring.
Definition at line 220 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RationalUnivariatePolynomial::cauchyBound(), hasZeroRoot(), GiNaCRA::RationalUnivariatePolynomial::maximumNorm(), nonzeropart(), GiNaCRA::RationalUnivariatePolynomial::oneNorm(), and GiNaCRA::RationalUnivariatePolynomial::twoNorm().
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::mul | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the product of this and o
in this variable.
o | other polynomial |
Definition at line 321 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::operator*().
Eliminates the root 0 from the polynomial by dividing the polynomial by a power of the main variable.
Definition at line 111 of file UnivariatePolynomial.cpp.
References coeff(), degree(), ldegree(), mVariable, UnivariatePolynomial(), and variable().
Referenced by GiNaCRA::RealAlgebraicNumberFactory::realRoots(), and GiNaCRA::RealAlgebraicNumberFactory::realRootsEval().
const UnivariatePolynomial & GiNaCRA::UnivariatePolynomial::operator= | ( | const UnivariatePolynomial & | o | ) |
This polynomial gets all values of the other.
Definition at line 73 of file UnivariatePolynomial.cpp.
References mEnabledPolynomialCheck, and mVariable.
Referenced by operator=().
const UnivariatePolynomial & GiNaCRA::UnivariatePolynomial::operator= | ( | const ex & | o | ) |
This polynomial gets all values of the other expression, using the current main variable.
Definition at line 81 of file UnivariatePolynomial.cpp.
References operator=().
UnivariatePolynomial GiNaCRA::UnivariatePolynomial::primpart | ( | ) | const [inline] |
Definition at line 228 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::RealAlgebraicNumberIR::add(), GiNaCRA::RealAlgebraicNumberIR::mul(), and sepapart().
UnivariatePolynomial GiNaCRA::UnivariatePolynomial::primpart | ( | const ex & | content | ) | const [inline] |
content | precomputed content of this polynomial |
Definition at line 237 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
const vector< ex > GiNaCRA::UnivariatePolynomial::principalSubresultantCoefficients | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b, | ||
const subresultantStrategy | strategy = GENERIC_SUBRESULTANTSTRATEGY |
||
) | [static] |
Returns the i-th coefficients of the i-th subresultant of a and b at the i-th position of the result vector.
a | the first Polynomial |
b | the second Polynomial |
strategy | choice of optimization. Standard is none, other possibilities are due to the sections 2 and 3 of the paper. |
Definition at line 228 of file UnivariatePolynomial.cpp.
References subresultants().
Referenced by GiNaCRA::CAD::elimination().
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::quo | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the quotient of division by o
in this variable.
o | other polynomial |
Definition at line 301 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::operator/(), and sepapart().
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::rem | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the remainder of o
modulo the given polynomial in this variable.
o | other polynomial |
Definition at line 291 of file UnivariatePolynomial.h.
References mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::operator%().
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::resultant | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the resultant of o
and the given polynomial in this variable.
The resultant ist the subresultant of lowest degree.
o | other polynomial |
Definition at line 364 of file UnivariatePolynomial.h.
References mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::RealAlgebraicNumberFactory::evaluateIR().
Computes a polynomial being decomposed into linear factors of multiplicity 1 with the same set of zeros as this polynomial.
This is also referred to as the square-free part.
Definition at line 103 of file UnivariatePolynomial.cpp.
References diff(), gcd(), isConstant(), mEnabledPolynomialCheck, mVariable, primpart(), quo(), and UnivariatePolynomial().
UnivariatePolynomial GiNaCRA::UnivariatePolynomial::square | ( | ) | const [inline] |
Calculates the square.
Definition at line 340 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
list< UnivariatePolynomial > GiNaCRA::UnivariatePolynomial::standardSturmSequence | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | throw ( invalid_argument ) [static] |
Generates a standard Sturm sequence by generating an additively inverted polynomial remainder sequence.
Convention: If one polynomial is zero, the corresponding Sturm sequence is zero followed by the other polynomial.
a | |
b |
Definition at line 254 of file UnivariatePolynomial.cpp.
const UnivariatePolynomial GiNaCRA::UnivariatePolynomial::sub | ( | const UnivariatePolynomial & | o | ) | const [inline] |
Compute the subtraction of this by o
in this variable.
o | other polynomial |
Definition at line 331 of file UnivariatePolynomial.h.
References mEnabledPolynomialCheck, mVariable, and UnivariatePolynomial().
Referenced by GiNaCRA::operator-().
const vector< ex > GiNaCRA::UnivariatePolynomial::subresultantCoefficients | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b, | ||
const subresultantStrategy | strategy = GENERIC_SUBRESULTANTSTRATEGY |
||
) | [static] |
Returns the leading coefficients of the subresultants of a and b.
a | the first Polynomial |
b | the second Polynomial |
strategy | choice of optimization. Standard is none, other possibilities are due to the sections 2 and 3 of the paper. |
Definition at line 217 of file UnivariatePolynomial.cpp.
References subresultants().
const list< UnivariatePolynomial > GiNaCRA::UnivariatePolynomial::subresultants | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b, | ||
const subresultantStrategy | strategy = GENERIC_SUBRESULTANTSTRATEGY |
||
) | [static] |
Computes the subresultant sequence according to the algorithm in [Lionel Ducos.
Optimizations of the subresultant algorithm. Journal of Pure and Applied Algebra 145 (2000) 149–163]
Marginal cases: Let the degree of a be smaller or equal than the degree of b. if deg(b) is less than 2, then only a, b are returned.
a | the first Polynomial |
b | the second Polynomial |
strategy | choice of optimization. Standard is none, other possibilities are due to the sections 2 and 3 of the paper. |
Definition at line 125 of file UnivariatePolynomial.cpp.
References degree(), DUCOS_SUBRESULTANTSTRATEGY, GENERIC_SUBRESULTANTSTRATEGY, isCompatible(), isZero(), LAZARDS_SUBRESULTANTSTRATEGY, lcoeff(), mVariable, UnivariatePolynomial(), and variable().
Referenced by principalSubresultantCoefficients(), and subresultantCoefficients().
ex GiNaCRA::UnivariatePolynomial::tcoeff | ( | ) | const [inline] |
Reimplemented in GiNaCRA::RationalUnivariatePolynomial.
Definition at line 164 of file UnivariatePolynomial.h.
References mVariable.
Removes the leading term.
Definition at line 93 of file UnivariatePolynomial.cpp.
References mEnabledPolynomialCheck, UnivariatePolynomial(), and variable().
Referenced by GiNaCRA::CAD::truncation().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLess | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 273 of file UnivariatePolynomial.cpp.
References isEqual().
Referenced by univariatePolynomialIsLessEvenDeg(), univariatePolynomialIsLessEvenLowDeg(), univariatePolynomialIsLessLowDeg(), univariatePolynomialIsLessOddDeg(), and univariatePolynomialIsLessOddLowDeg().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLessEvenDeg | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to a.degree() even or a.degree() >= b.degree() and GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 295 of file UnivariatePolynomial.cpp.
References degree(), and univariatePolynomialIsLess().
Referenced by GiNaCRA::CADSettings::getSettings().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLessEvenLowDeg | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to a.degree() even and a.degree() < b.degree() or a.degree() >= b.degree() and GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 300 of file UnivariatePolynomial.cpp.
References degree(), and univariatePolynomialIsLess().
Referenced by GiNaCRA::CADSettings::getSettings().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLessLowDeg | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to a.degree() < b.degree() or a.degree() >= b.degree() and GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 278 of file UnivariatePolynomial.cpp.
References degree(), and univariatePolynomialIsLess().
Referenced by GiNaCRA::CADSettings::getSettings().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLessOddDeg | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to a.degree() odd or a.degree() >= b.degree() and GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 283 of file UnivariatePolynomial.cpp.
References degree(), and univariatePolynomialIsLess().
Referenced by GiNaCRA::CADSettings::getSettings().
bool GiNaCRA::UnivariatePolynomial::univariatePolynomialIsLessOddLowDeg | ( | const UnivariatePolynomial & | a, |
const UnivariatePolynomial & | b | ||
) | [static] |
Compares two univariate polynomials.
The behavior of this function is equivalent to a.degree() odd and a.degree() < b.degree() or a.degree() >= b.degree() and GiNaC::ex_is_less( a, b )
.
a | |
b |
a < b
, false otherwise Definition at line 289 of file UnivariatePolynomial.cpp.
References degree(), and univariatePolynomialIsLess().
Referenced by GiNaCRA::CADSettings::getSettings().
const symbol GiNaCRA::UnivariatePolynomial::variable | ( | ) | const [inline] |
Selects the main variable of the polynomial.
Definition at line 105 of file UnivariatePolynomial.h.
References mVariable.
Referenced by GiNaCRA::RealAlgebraicNumberIR::add(), GiNaCRA::RealAlgebraicNumberIR::inverse(), GiNaCRA::RealAlgebraicNumberIR::minus(), GiNaCRA::RealAlgebraicNumberIR::mul(), nonzeropart(), GiNaCRA::operator*(), GiNaCRA::operator+(), GiNaCRA::operator-(), GiNaCRA::RationalUnivariatePolynomial::RationalUnivariatePolynomial(), GiNaCRA::RealAlgebraicNumberIR::sgn(), subresultants(), and trunc().
bool GiNaCRA::UnivariatePolynomial::mEnabledPolynomialCheck [protected] |
Definition at line 524 of file UnivariatePolynomial.h.
Referenced by add(), diff(), enabledPolynomialCheck(), gcd(), mul(), operator=(), primpart(), quo(), sepapart(), square(), sub(), and trunc().
symbol GiNaCRA::UnivariatePolynomial::mVariable [protected] |
Definition at line 523 of file UnivariatePolynomial.h.
Referenced by add(), GiNaCRA::RationalUnivariatePolynomial::coeff(), coeff(), content(), degree(), diff(), do_print(), evaluateAt(), gcd(), inVariable(), isCompatible(), isConstant(), isEqual(), GiNaCRA::RationalUnivariatePolynomial::lcoeff(), lcoeff(), ldegree(), mul(), nonzeropart(), operator=(), primpart(), quo(), rem(), resultant(), sepapart(), square(), sub(), subresultants(), GiNaCRA::RationalUnivariatePolynomial::tcoeff(), tcoeff(), and variable().