Subject: MD pressure calculation problem/question

From: Richard Moss <[email-masked]>
Date: Wed, 06 Nov 1996 15:04:36 -0800

Hi ya,

I'm trying to calculate the pressure tensor in a MD simulation for
different regions within the system (ie divide my "box" up into
sub-regions and look at the tensor separately for each of them).

But I have several problems when trying to do this:

I can't use an addition to the force routine to sum the components of
the tensor, because the force routine loops over i=1,N-1 j=i+1,N, which
though fine for calculating the tensor over the entire system, _doesn't_
work for separate regions, as you miss certain interactions. (ie the
tensor is bigger in some regions, smaller in other, over what it should
be).

The second problem is if I try and use a simple loop over i, calculating
the x/y/z components of R(i).F(i).  This doesn't work when you use
periodic boundaries (ref Allen&Tildesly) - only the R(ij).F(ij) form can
be used.

So, as I see it the only way I can get the tensor properly is to do an
"extended" force calculation type routine, and do a double sum, both
over N (opposed to the normal force where it is an i,j>i sum).

Is this correct?

Are there any other methods for calculating the pressure tensor (or at
least the diagonal components).

thanks,

Richard