## Neural Computation

Just storing the Hessian H (the matrix of second derivatives δ^{2}*E*/δ*w*_{i}δ*w*_{j} of the error *E* with respect to each pair of weights) of a large neural network is difficult. Since a common use of a large matrix like H is to compute its product with various vectors, we derive a technique that directly calculates Hv, where v is an arbitrary vector. To calculate Hv, we first define a differential operator *R _{v}*{

*f*(w)} = (δ/δr)

*f*(w +

*r*v)|

*r*=0, note that R

_{v}{▽w} = Hv and R

*{w} = v, and then apply*

_{v}*R*{·} to the equations used to compute ▽

_{v}_{w}. The result is an exact and numerically stable procedure for computing Hv, which takes about as much computation, and is about as local, as a gradient evaluation. We then apply the technique to a one pass gradient calculation algorithm (backpropagation), a relaxation gradient calculation algorithm (recurrent backpropagation), and two stochastic gradient calculation algorithms (Boltzmann machines and weight perturbation). Finally, we show that this technique can be used at the heart of many iterative techniques for computing various properties of H, obviating any need to calculate the full Hessian.