Derivative

org.abh80.nf.core.math.calculus.Derivative
trait Derivative

A trait for representing a function and its partial derivatives in a multivariate automatic differentiation system. Implementations store the function value and all partial derivatives up to a specified order for a given number of free parameters.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Members list

Value members

Abstract methods

Returns the number of free parameters in the function.

Returns the number of free parameters in the function.

Attributes

Returns

The number of independent variables.

def getOrder: Int

Returns the maximum derivation order supported by this instance.

Returns the maximum derivation order supported by this instance.

Attributes

Returns

The maximum order of partial derivatives.

def getPartialDerivative(orders: Array[Int]): Double

Retrieves the value of the partial derivative for the specified orders.

Retrieves the value of the partial derivative for the specified orders.

Value parameters

orders

An array specifying the order of differentiation for each free parameter. The length must match the number of free parameters, and the sum of orders must not exceed the maximum derivation order.

Attributes

Returns

The value of the partial derivative corresponding to the specified orders.

Throws
IllegalArgumentException

if the orders array length does not match the number of free parameters or if the sum of orders exceeds the maximum derivation order.

def getValue: Double

Get the value part of the wrapper

Get the value part of the wrapper

Attributes