wmpy.core.polynomial.Polynomial¶
- class Polynomial(expr, variables, env)[source]¶
Bases:
objectInternal class representing canonical polynomials. Implemented as a dict, having for each monomial: {key : coefficient} where key is a tuple encoding exponents of the ordered variables.
E.g. {(2,0,1): 3} = “3 * x^2 * y^0 * z^1”
- monomials¶
the monomial dictionary
- variables¶
the continuous integration domain
- ordered_keys¶
sorted list of monomial keys
- mgr¶
the pysmt formula manager
Default constructor.
- Parameters:
expr (
FNode) – the polynomial in pysmt formatvariables (
Collection[FNode]) – the continuous integration domainenv (
Environment) – the pysmt environment
Methods
Returns the polynomial as a callable function.
Returns the polynomial in pysmt format.
Attributes
Returns the degree of the polynomial.
Returns true if the polynomial is zero.