Numdiff.Generic Functor

This document is auto-generated for Owl’s APIs. #14 entries have been extracted.

Github: {Signature} {Implementation}

Type definition

type arr

General ndarray type

type elt

Scalar type

Basic functions

val diff : (elt -> elt) -> elt -> elt

derivative of f : scalar -> scalar.

source code

val diff' : (elt -> elt) -> elt -> elt * elt

derivative of f : scalar -> scalar, return both f x and f' x.

source code

val diff2 : (elt -> elt) -> elt -> elt

second order derivative of f : float -> float.

source code

val diff2' : (elt -> elt) -> elt -> elt * elt

second order derivative of f : float -> float, return f x and f' x.

source code

val grad : (arr -> elt) -> arr -> arr

gradient of f : vector -> scalar.

source code

val grad' : (arr -> elt) -> arr -> arr * arr

gradient of f : vector -> scalar, return f x and g x.

source code

val jacobian : (arr -> arr) -> arr -> arr

jacobian of f : vector -> vector.

source code

val jacobian' : (arr -> arr) -> arr -> arr * arr

jacobian of f : vector -> vector, return f x and j x.

source code

val jacobianT : (arr -> arr) -> arr -> arr

transposed jacobian of f : vector -> vector.

source code

val jacobianT' : (arr -> arr) -> arr -> arr * arr

transposed jacobian of f : vector -> vector, return f x and j x.

source code