API

API for TaylorDiff.

TaylorDiff.TaylorScalarType
TaylorScalar{T, N}

Representation of Taylor polynomials.

Fields

  • value::NTuple{N, T}: i-th element of this stores the (i-1)-th derivative
source
TaylorDiff.TaylorScalarMethod
TaylorScalar{T, N}(x::T, d::T) where {T, N}

Construct a Taylor polynomial with zeroth and first order coefficient, acting as a seed.

source
TaylorDiff.can_taylorizeMethod
TaylorDiff.can_taylor(V::Type)

Determines whether the type V is allowed as the scalar type in a Dual. By default, only <:Real types are allowed.

source
TaylorDiff.derivativeFunction
derivative(f, x, l, ::Val{N})
derivative(f!, y, x, l, ::Val{N})

Computes order-th directional derivative of f w.r.t. vector x in direction l.

source
TaylorDiff.derivative!Function
derivative!(result, f, x, l, ::Val{N})
derivative!(result, f!, y, x, l, ::Val{N})

In-place derivative calculation APIs. result is expected to be pre-allocated and have the same shape as y.

source
TaylorDiff.derivativesFunction
derivatives(f, x, l, ::Val{N})
derivatives(f!, y, x, l, ::Val{N})

Computes all derivatives of f at x up to order N - 1.

source