update hessian code