The state of a network with N units at time
t can be described by a vector
, where
is the output of the ith
unit at time t. We define the energy
at time t to be

The energy of the network is analogous to the potential energy of a physical system. In the billiard table model, it corresponds to the difference between the height of the surface of the table at a point and the height of the nearest pocket. The choice of the energy function makes the Hopfield network essentially the same as a Ising model for spin glasses, which makes it of great interest to physicists.
The operation of the Hopfield network may be summed up as energy minimization. The choice of the network weights ensures that minima of the energy function occur at (or near) points representing exemplar patterns. The formula used to update the states ensures that the energy of each state is no greater than the energy of the preceeding state. The network rolls down the energy surface to the nearest exemplar pattern.
There are two methods for updating the states of the units. In the sequential method, the states of the units are changed one at a time, in random order. In the simultaneous method, the states of the units are all changed at the same time, on the basis of their states after the previous update.
It is easy to show that the sequential updating
method decreases the energy at
each step. Suppose that at time t, the state
of the kth unit is changed.
If the change in the state of the ith unit is
, then
we have
for
, and
.
The change in the energy caused by the change in the state of the kth unit is



The term in brackets is the same as the argument
of the threshold function of
the kth unit, so if its value is positive, the
value of
is
also positive, so
is negative. If
the value of the argument of the
threshold function is negative, so is
,
and again
is negative. Hence each change of state brought
about by the sequential
updating method reduces the value of the energy
function.
The simultaneous updating method also leads to a reduction in the energy at each stage, but this is more difficult to show.
Since the operation of the network ensures that its energy is reduced at each update, it follows that the network will tend towards states that are local minima of the energy function. The positions of these minima are determined by the weights wij. The formula used to determine the weights from the exemplar patterns ensures that local minima of the energy function will occur at positions corresponding to the exemplar patterns, provided the number of exemplars is small in comparison to the number of units. It is usually stated that the number of patterns that can be effectively stored in the network is of the order of 15 per cent of the number of units. This makes the Hopfield network relatively inefficient as a memory device.