Package jscl.math
Class Expression
- java.lang.Object
-
- jscl.math.Generic
-
- jscl.math.Expression
-
- All Implemented Interfaces:
java.lang.Comparable,jscl.editor.rendering.MathObject,Arithmetic
public class Expression extends Generic
-
-
Method Summary
-
Methods inherited from class jscl.math.Generic
abs, add, booleanValue, compareTo, divide, equals, gcdAndNormalize, inverse, isIdentity, isOne, isZero, multiply, normalize, pow, pow, remainder, scm, subtract, vectorValue
-
-
-
-
Method Detail
-
size
public int size()
-
literal
public Literal literal(int n)
-
coef
public JSCLInteger coef(int n)
-
add
public Expression add(Expression expression)
-
subtract
public Expression subtract(Expression expression)
-
multiply
public Expression multiply(Expression expression)
-
multiple
public boolean multiple(Generic generic) throws java.lang.ArithmeticException
-
divideAndRemainder
public Generic[] divideAndRemainder(Generic generic) throws java.lang.ArithmeticException
- Overrides:
divideAndRemainderin classGeneric- Throws:
java.lang.ArithmeticException
-
literalScm
public Literal literalScm()
-
antiderivative
public Generic antiderivative(Variable variable) throws NotIntegrableException
- Specified by:
antiderivativein classGeneric- Throws:
NotIntegrableException
-
derivative
public Generic derivative(Variable variable)
- Specified by:
derivativein classGeneric
-
substitute
public Generic substitute(Variable variable, Generic generic)
- Specified by:
substitutein classGeneric
-
elementary
public Generic elementary()
- Specified by:
elementaryin classGeneric
-
productValue
public Generic[] productValue() throws NotProductException
- Specified by:
productValuein classGeneric- Throws:
NotProductException
-
powerValue
public Power powerValue() throws NotPowerException
- Specified by:
powerValuein classGeneric- Throws:
NotPowerException
-
expressionValue
public Expression expressionValue()
- Specified by:
expressionValuein classGeneric
-
integerValue
public JSCLInteger integerValue() throws NotIntegerException
- Specified by:
integerValuein classGeneric- Throws:
NotIntegerException
-
variableValue
public Variable variableValue() throws NotVariableException
- Specified by:
variableValuein classGeneric- Throws:
NotVariableException
-
isPolynomial
public boolean isPolynomial(Variable variable)
- Specified by:
isPolynomialin classGeneric
-
isConstant
public boolean isConstant(Variable variable)
- Specified by:
isConstantin classGeneric
-
grad
public JSCLVector grad(Variable[] variable)
-
compareTo
public int compareTo(Expression expression)
-
valueOf
public static Expression valueOf(Variable variable)
-
valueOf
public static Expression valueOf(Literal literal)
-
valueOf
public static Expression valueOf(JSCLInteger integer)
-
valueOf
public static Expression valueOf(Literal literal, JSCLInteger integer)
-
valueOf
public static Expression valueOf(Rational rational)
-
valueOf
public static Expression valueOf(java.lang.String str) throws ParseException
- Throws:
ParseException
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
toMathML
public java.lang.String toMathML()
-
newinstance
protected Expression newinstance(int n)
-
-