hessian.RdNumerically compute the Hessian matrix.
hessian(f, x0, h = .Machine$double.eps^(1/4), ...)Computes the hessian matrix based on the three-point central difference formula, expanded to two variables.
Assumes that the function has continuous partial derivatives.
An n-by-n matrix with \(\frac{\partial^2 f}{\partial x_i \partial x_j}\) as (i, j) entry.
Fausett, L. V. (2007). Applied Numerical Analysis Using Matlab. Second edition, Prentice Hall.