While, as we noted in the introduction, time-averaging the force sum
(1.2) from set
on set
is a logical way to reduce
statistical fluctuations, the virial stress is based on an average
that is diabolically more clever. Since it was assumed that the
macroscopic stress has negligible variation over the stress plane
, it will normally also have negligible variation
over a similar linear extent in the
-direction. (Note that this
might not always be desirable, for example near walls, (Todd et
al. 1995), but we will assume it is.) We can therefore average
over an infinitely dense set of equivalent planes
in a vertical
region
, as sketched in figure 3.
The mathematics of the averaging is simple. For a given pair of atoms
and
as shown, the relative fraction of planes that have
below and
above them is obviously
. Thus our sum of the
forces through a single plane (1.2) becomes exactly the
second term in the virial stress theorem (1.1). The factor
1/2 comes in since only pairs with
should be counted, and
the virial theorem counts them all. (Because of Newton's
third law,
.)
Following Cormier et al. (2001), for pair
and
not
both inside the volume, it is desirable to reduce the contribution of
that pair by the fraction of their bond that is actually inside, since
this gives a straight average of the stress of Irving & Kirkwood,
(Irving & Kirkwood, 1950, Appendix).
The diabolical part of this averaging is that it makes undercounting
cross-overs unavoidable: not all these planes can be away from nominal
atom positions. Fortunately, the amount that needs to be added to fix
things is simple. In an infinitesimal time interval
, (that
can be much smaller than even the microscopic time scales,) the
relative fraction of planes crossed by an atom
is
and the corresponding momentum that must be
substracted (becoming added if
is negative) from these
planes to correct for uncounted physical forces is an amount
larger. This exactly produces the first term in the virial
stress.
Thus the dynamical term in the virial stress becomes simply the proper sum of all the mechanical forces missed in the second term, and nothing more.