Class Variable<T extends Ring<T>>
java.lang.Object
org.episteme.core.mathematics.symbolic.Variable<T>
- All Implemented Interfaces:
Expression<T>
Represents a symbolic variable (e.g., "x", "y", "theta").
- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadd(Expression<T> other) Adds this expression to another.compose(Variable<T> variable, Expression<T> substitution) Composes this expression by substituting a variable with another expression.differentiate(Variable<T> variable) Differentiates this expression with respect to the given variable.divide(Expression<T> other) Divides this expression by another.booleanEvaluates this expression with the given variable assignments.getRing()Returns the ring this expression belongs to.inthashCode()Integrates this expression with respect to the given variable.multiply(Expression<T> other) Multiplies this expression by another.negate()Negates this expression.simplify()Simplifies this expression using algebraic rules.subtract(Expression<T> other) Subtracts another expression from this.toLatex()Converts this expression to LaTeX format.toString()Methods inherited from interface Expression
pow
-
Constructor Details
-
Variable
-
Variable
Default constructor for symbolic variables (uses Real numbers by default).- Parameters:
symbol- the variable symbol
-
-
Method Details
-
getSymbol
-
getRing
Description copied from interface:ExpressionReturns the ring this expression belongs to.- Specified by:
getRingin interfaceExpression<T extends Ring<T>>- Returns:
- the ring
-
add
Description copied from interface:ExpressionAdds this expression to another.- Specified by:
addin interfaceExpression<T extends Ring<T>>- Parameters:
other- the other expression- Returns:
- the sum expression
-
multiply
Description copied from interface:ExpressionMultiplies this expression by another.- Specified by:
multiplyin interfaceExpression<T extends Ring<T>>- Parameters:
other- the other expression- Returns:
- the product expression
-
subtract
Description copied from interface:ExpressionSubtracts another expression from this.- Specified by:
subtractin interfaceExpression<T extends Ring<T>>- Parameters:
other- the subtrahend- Returns:
- the difference expression
-
negate
Description copied from interface:ExpressionNegates this expression.- Specified by:
negatein interfaceExpression<T extends Ring<T>>- Returns:
- the negated expression
-
divide
Description copied from interface:ExpressionDivides this expression by another.- Specified by:
dividein interfaceExpression<T extends Ring<T>>- Parameters:
other- the divisor- Returns:
- the quotient expression
-
differentiate
Description copied from interface:ExpressionDifferentiates this expression with respect to the given variable.- Specified by:
differentiatein interfaceExpression<T extends Ring<T>>- Parameters:
variable- the variable to differentiate by- Returns:
- the derivative expression
-
integrate
Description copied from interface:ExpressionIntegrates this expression with respect to the given variable.- Specified by:
integratein interfaceExpression<T extends Ring<T>>- Parameters:
variable- the variable to integrate by- Returns:
- the integral expression
-
compose
Description copied from interface:ExpressionComposes this expression by substituting a variable with another expression.- Specified by:
composein interfaceExpression<T extends Ring<T>>- Parameters:
variable- the variable to substitutesubstitution- the expression to substitute with- Returns:
- the composed expression
-
evaluate
Description copied from interface:ExpressionEvaluates this expression with the given variable assignments.- Specified by:
evaluatein interfaceExpression<T extends Ring<T>>- Parameters:
assignments- the variable assignments- Returns:
- the evaluated value
-
simplify
Description copied from interface:ExpressionSimplifies this expression using algebraic rules.- Specified by:
simplifyin interfaceExpression<T extends Ring<T>>- Returns:
- the simplified expression
-
toLatex
Description copied from interface:ExpressionConverts this expression to LaTeX format.- Specified by:
toLatexin interfaceExpression<T extends Ring<T>>- Returns:
- the LaTeX string
-
toString
-
equals
-
hashCode
-