public abstract class ChainRuleDiffRules extends java.lang.Object implements DiffRulesI
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
name |
protected PostfixMathCommandI |
pfmc |
protected Node[] |
rules |
Constructor and Description |
---|
ChainRuleDiffRules()
Cannot construct outside the context of a differentation visitor.
|
Modifier and Type | Method and Description |
---|---|
Node |
differentiate(ASTFunNode node,
java.lang.String var,
Node[] children,
Node[] dchildren,
DJep djep)
Use the chain rule to differentiate.
|
java.lang.String |
getName()
returns the name of the function
|
int |
getNumRules()
Returns the number of rules which should be number of arguments of function
|
PostfixMathCommandI |
getPfmc()
returns the PostfixMathCommandI for the function.
|
Node |
getRule(int i)
returns the i-th rule as an expression tree.
|
java.lang.String |
toString()
Returns a string representation of the rule.
|
protected java.lang.String name
protected PostfixMathCommandI pfmc
protected Node[] rules
public ChainRuleDiffRules()
public java.lang.String getName()
getName
in interface DiffRulesI
public PostfixMathCommandI getPfmc()
public int getNumRules()
public Node getRule(int i)
public Node differentiate(ASTFunNode node, java.lang.String var, Node[] children, Node[] dchildren, DJep djep) throws ParseException
differentiate
in interface DiffRulesI
var
- The name of variable to differentiate wrt to.children
- the arguments of the functiondchildren
- the derivatives of each argument of the function.ParseException
- if there is some problem in compiling the derivative.public java.lang.String toString()
DiffRulesI
toString
in interface DiffRulesI
toString
in class java.lang.Object
http://www.singularsys.com/jep Copyright © 2007 Singular Systems