public class Derivative extends AbstractFunctionEvaluator implements DerivativeRules
RULES1, RULES2, RULES3, RULES4
Constructor and Description |
---|
Derivative() |
Modifier and Type | Method and Description |
---|---|
static IExpr |
derivative(int n,
int m,
ISymbol symbol)
Get the (n, m)-th derivative (
Derivative[n, m][symbol] ) if
possible. |
static IExpr |
derivative(int n,
ISymbol symbol)
Get the n-th derivative (
Derivative[n][symbol] ) if possible. |
IExpr |
evaluate(IAST ast,
EvalEngine engine)
Symbolic evaluation of a function.
|
void |
setUp(ISymbol symbol)
Evaluate built-in rules and define Attributes for a function.
|
createRuleFromMethod, getNormalizedNegativeExpression, getNormalizedNegativeExpression, getPeriodicParts, getPureImaginaryPart, getRuleAST, initSerializedRules, isNegativeExpression
numericEval
public IExpr evaluate(IAST ast, EvalEngine engine)
AbstractFunctionEvaluator
ast.get(0)
(or alternatively ast.head()
) contains the
head (i.e. the function symbol) of this abstract syntax tree (AST). ast.arg1()
to ast.get(n)
the ast
contains the first to n-th argument of the
function (alternatively you get the first to fifth argument with the methods arg1()
, arg2()
,...
arg5()
).Validate
class to check the number or types of arguments in the evaluate
method.null
value without throwing an exception!evaluate
in interface IFunctionEvaluator
evaluate
in class AbstractFunctionEvaluator
ast
- the abstract syntax tree (AST) which should be evaluatedengine
- the users current evaluation enginenull
, if evaluation isn't possibleValidate
,
IExpr.head()
,
IAST.arg1()
,
IAST.arg2()
,
IAST.arg3()
public static IExpr derivative(int n, ISymbol symbol)
Derivative[n][symbol]
) if possible.
Otherwise return null
n
- differentiating n
times with respect to the 1.
argumentsymbol
- the function symbol which should be searched in the look-up
table.null
if no entry was foundpublic static IExpr derivative(int n, int m, ISymbol symbol)
Derivative[n, m][symbol]
) if
possible. Otherwise return null
n
- differentiating n
times with respect to the 1.
argumentm
- differentiating m
times with respect to the 2.
argumentsymbol
- the function symbol which should be searched in the look-up
table.null
if no entry was foundpublic void setUp(ISymbol symbol) throws SyntaxError
AbstractFunctionEvaluator
setUp
in interface IEvaluator
setUp
in class AbstractFunctionEvaluator
symbol
- the symbol which should be set upSyntaxError