- All Superinterfaces:
NumericExpression,RationalExpression,SymbolicExpression,SymbolicObject
- All Known Subinterfaces:
Constant,Monic,Polynomial,Primitive,PrimitivePower
-
Nested Class Summary
Nested classes/interfaces inherited from interface dev.civl.sarl.IF.expr.SymbolicExpression
SymbolicExpression.SymbolicOperatorNested classes/interfaces inherited from interface dev.civl.sarl.IF.object.SymbolicObject
SymbolicObject.SymbolicObjectKind -
Method Summary
Modifier and TypeMethodDescriptionMonomial[]expand(IdealFactory factory) Returns the expansion of this monomial.booleanhasNontrivialExpansion(IdealFactory factory) Determines whether or not this monomial could possibly have a non-trivial expansion.Monomial[]lower(IdealFactory factory) Computes a term map from performing a single outer-level expansion.maxDegreeOf(NumberFactory factory, Primitive primitive) Computes the maximum degree to whichprimitiveoccurs in thisMonomial.monic(IdealFactory factory) Returns the monic factor of this monomial.monomialConstant(IdealFactory factory) Returns the constant factor of this monomial.monomialDegree(NumberFactory factory) Returns the degree of the monic where each factor is considered to have degree 1.intmonomialOrder(IdealFactory factory) Computes the "monomial order" of thisMonomial.powerInt(IdealFactory factory, IntegerNumber exponent) Computes an expression equivalent to raising this expression to theexponentpower.Monomial[]termMap(IdealFactory factory) Returns the term map of this monomial.totalDegree(NumberFactory factory) The degree of this monomial if it were fully expanded to a polynomial in which the variables cannot be expressed as the sum, product, difference, or quotient of expressions.Methods inherited from interface dev.civl.sarl.ideal.IF.RationalExpression
denominator, numerator, powerRationalMethods inherited from interface dev.civl.sarl.IF.expr.SymbolicExpression
argument, atomString, getArguments, getFreeVars, isFalse, isNull, isNumeric, isOne, isTrue, isZero, numArguments, operator, printCompressedTree, size, typeMethods inherited from interface dev.civl.sarl.IF.object.SymbolicObject
containsQuantifier, containsSubobject, containsSubobjectIgnoringType, equals, getOrder, hashCode, id, isCanonic, setInCanonic, setOrder, symbolicObjectKind, toString, toStringBuffer, toStringBufferLong
-
Method Details
-
monomialConstant
Returns the constant factor of this monomial.- Parameters:
factory- the ideal factory responsible for this monomial- Returns:
- the constant factor of this monomial
-
monic
Returns the monic factor of this monomial.- Parameters:
factory- the ideal factory responsible for this monomial- Returns:
- the monic factor of this monomial
-
monomialDegree
Returns the degree of the monic where each factor is considered to have degree 1. For example, (X^2+Y^2)^3*Z^2 has monomial degree 5: it has two factors, one of degree 3 and one of degree 2.- Parameters:
factory- theNumberFactoryused for this operation- Returns:
- The
IntegerNumberrepresents the monomial degree with NO expansion
-
totalDegree
The degree of this monomial if it were fully expanded to a polynomial in which the variables cannot be expressed as the sum, product, difference, or quotient of expressions. For example, (X^2+Y^2)^3*Z^2 has total degree 8.- Parameters:
factory- theNumberFactoryused for this operation- Returns:
- The
IntegerNumberrepresents total degree of this monomial after full expansion to a polynomial
-
expand
Returns the expansion of this monomial.- Parameters:
factory- the ideal factory responsible for this monomial- Returns:
- term map whose sum is equivalent to this but with no
Polynomials. - See Also:
-
hasNontrivialExpansion
Determines whether or not this monomial could possibly have a non-trivial expansion. A trivial expansion is one consisting of exactly one term.- Parameters:
factory- the ideal factory responsible for this monomial- Returns:
- if
falseis returned then this monomial has only a trivial expansion, otherwise is might have a nontrivial one
-
termMap
Returns the term map of this monomial.- Parameters:
factory- the ideal factory responsible for this monomial- Returns:
- a term map whose sum is equivalent to this monomial
- See Also:
-
monomialOrder
Computes the "monomial order" of thisMonomial. This is defined as follows:- the monomial order of a
Constantis 0 - the monomial order of a
Primitivewhich is not aPolynomial(a "true primitive") is also 0 - the monomial order of a
PrimitivePowers the monomial order of itsPrimitive - the monomial order of a
Monicis the maximum of the monomial orders of itsPrimitivePowerfactors - the monomial order of a
Monomialis the monomial order of itsMonic - the monomial order of a
Polynomialwhich is not aMonomialis one more than the monomial orders of itsMonomialterms.
Another interpretation: consider this symbolic expressions as a rooted tree. Along any path from the root to a leaf, count the number of "+" (addition) operators to occur. (Note that each
Polynomialintroduces a single addition operator whose argument is a set of terms.) The maximum plus-count (over all paths) is the monomial order.- Parameters:
factory- theIdealFactoryresponsible for thisMonomial- Returns:
- the monomial order of this
Monomial
- the monomial order of a
-
lower
Computes a term map from performing a single outer-level expansion. This is in contrast with
expand(IdealFactory), which performs a full expansion.Suppose the monomial order of this
Monomialis d. Then theMonomials occurring in the returned map will have monomial order at most d-1. Furthermore, if this is aPolynomial, theoccurring in the returned map will have monomial order at most d-2 (assuming d>=2).invalid reference
Monomials- Parameters:
factory- theIdealFactoryresponsible for thisMonomial- Returns:
- a term map with lower monomial order.
-
powerInt
Description copied from interface:RationalExpressionComputes an expression equivalent to raising this expression to theexponentpower. In this case the exponent is anIntegerNumber.- Specified by:
powerIntin interfaceRationalExpression- Parameters:
factory- the ideal factory responsible for this expressionexponent- the power to which this expression should be raised, must be positive- Returns:
- an expression equivalent to raising this expression to the
exponentpower
-
maxDegreeOf
Computes the maximum degree to whichprimitiveoccurs in thisMonomial. For example the primitive X occurs with max degree 11 in XY(X+Z)^10.- Parameters:
factory- theNumberFactoryused for this operationprimitive- thePrimitivewhich must have same type as this; it is possible the primitive does not occur at all in this, in which case the result is 0- Returns:
- The
IntegerNumberrepresents the maximum degree to whichprimitiveoccurs in this
-
getTruePrimitives
Returns thePrimitives which are notPolynomials occurring in thisMonomial. These are essentially the "variables" occurring in the polynomial expression.- Returns:
- the set of primitives that are not polynomials occurring herein
-