DynamicDiff
Documentation for DynamicDiff.
DynamicDiff.OperatorDerivative
— TypeOperatorDerivative{F,degree,arg} <: Function
A callable type representing the partial derivative of an operator. Takes either one (degree=1
) or two (degree=2
) scalar arguments. Returns a scalar.
Parameters
F
: The type of the original operatordegree
: The arity of the operator (1 for unary, 2 for binary)arg
: Which argument to take the derivative with respect to
Fields
op
: The actual function performing the partial derivative.
DynamicDiff.D
— MethodD(ex::AbstractExpression, feature::Integer)
Compute the derivative of ex
with respect to the feature
-th variable. Returns a new expression with an expanded set of operators.
DynamicDiff.operator_derivative
— Methodoperator_derivative(op::F, ::Val{degree}, ::Val{arg}) where {F,degree,arg}
Create a partial derivative operator of a given function op
with respect to argument arg
.
Arguments
op
: The operator to differentiatedegree
: The arity of the operator (1 for unary, 2 for binary)arg
: Which argument to take the derivative with respect to