mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-22 15:20:39 +01:00
[poincare] Added framework to derivate unary functions, and implemented it for Sine
Added a method unaryFunctionDifferential to ExpressionNode and Expression, to be implemented by subclasses representing unary functions. Added a function derivateUnaryFunction to Derivative, to factor (f°g)' -> g' * f'°g. Change-Id: Id1780f1082ccd001f1282fe4ddfff2b7055d3a27
This commit is contained in:
committed by
Émilie Feral
parent
648cdbaa29
commit
5cf85368ea
@@ -131,6 +131,10 @@ bool ExpressionNode::didDerivate(ReductionContext reductionContext, Expression s
|
||||
return Expression(this).defaultDidDerivate();
|
||||
}
|
||||
|
||||
Expression ExpressionNode::unaryFunctionDifferential() {
|
||||
return Expression(this).defaultUnaryFunctionDifferential();
|
||||
}
|
||||
|
||||
bool ExpressionNode::isOfType(Type * types, int length) const {
|
||||
for (int i = 0; i < length; i++) {
|
||||
if (type() == types[i]) {
|
||||
|
||||
Reference in New Issue
Block a user