object EmpiricalHessian
- Companion:
- class
Value members
Concrete methods
def hessian(df: DiffFunction[DenseVector[Double]], x: DenseVector[Double], eps: Double)(implicit vs: VectorSpace[DenseVector[Double], Double], copy: CanCopy[DenseVector[Double]]): DenseMatrix[Double]
Calculate the Hessian using central differences
Calculate the Hessian using central differences
H_{i,j} = \lim_h -> 0 ((f'(x_{i} + he_{j}) - f'(x_{i} + he_{j}))/4h + (f'(x_{j} + he_{i}) - f'(x_{j} + he_{i}))/4h)
where e_{i} is the unit vector with 1 in the i^^th position and zeros elsewhere
- Value parameters:
- df
differentiable function
- eps
a small value
- x
the point we compute the hessian for
- Returns:
Approximate hessian matrix