Prev | Next |
H = f.hessian(x, w)
\[
w_0 * F_0 (x) + \cdots + w_{m-1} * F_{m-1} (x)
\]
where
F : \B{R}^n \rightarrow \B{R}^m
is the
function corresponding to the adfun
object f
.
f
must be an adfun
object.
We use level
for the AD ad
level of
this object.
x
is a numpy.array
with one dimension
(i.e., a vector) with length equal to the domain size n
for the function
f
.
It specifies the argument value at which the derivative is computed.
If the AD level
for
f
is zero,
all the elements of
x
must be either int
or instances
of float
.
If the AD level
for
f
is one,
all the elements of
x
must be a_float
objects.
w
is a numpy.array
with one dimension
(i.e., a vector) with length equal to the range size m
for the function
f
.
It specifies the argument value at which the derivative is computed.
If the AD level
for
f
is zero,
all the elements of
w
must be either int
or instances
of float
.
If the AD level
for
f
is one,
all the elements of
w
must be a_float
objects.
H
is a numpy.array
with two dimensions
(i.e., a matrix).
Both its first and second dimension size
(row and column size) are equal to n
(the number of domain components in the function
f
).
It is set to the Hessian; i.e.,
\[
H = w_0 * F_0^{(2)} (x) + \cdots + w_{m-1} * F_{m-1}^{(2)} (x)
\]
If the AD level
for
f
is zero,
all the elements of
H
will be instances of float
.
If the AD level
for
f
is one,
all the elements of
H
will be a_float
objects.