From: Axel Kohlmeyer (akohlmey_at_cmm.chem.upenn.edu)
Date: Thu May 10 2007 - 09:45:04 CDT

On Thu, 10 May 2007, Philipp Schoen1 wrote:

PS> Dear Users,

dear philipp,

PS> at the risk of boring you with a comment about water density calculation
PS> again I would like to put the following question for discussion.
PS> I wrote a program to calculate the density of water. My results deviate
PS> from experiments by about <5% , i.e. approx. 0.975 g/cm3 @ 300K which is
PS> quite ok.

of course, that depends on the water potential that you are using. ;)

PS> For the calculations I select water by
PS> set vol [atomselect 0 "water and same residue as $zlowerbound <= z and z <
PS> $zupperbound" frame $i].
PS> The "same residue" ensures that the boundaries are "weak", i.e. single
PS> atoms of a molecule can be out of the range so that the domain size
PS> fluctuates.

actually, i would suggest to modify the selection to check lower and
upper bound only on the water oxygen and then apply 'same residue of'
to it. this way you avoid double counting of water molecules in two
boxes.

PS> I track the thus occuring fluctuations in the volume for all frames and
PS> calculate the density with the average out of that.
PS> I would like to ask the list members if this is a reasonable approach or do
PS> you think I got nice values accidently?

i've done something similar a loooong time ago (not only for density but
also for other, dielectric properties. and not with VMD), and whether
it works depends on the size of the system, the size of the grid boxes
and the length of your trajectory, IOW you have to check whether the
statistics are sufficiently converged.

cheers,
   axel.

PS>
PS> Cheers and thanks in advance
PS> Philipp
PS>

-- 
=======================================================================
Axel Kohlmeyer   akohlmey_at_cmm.chem.upenn.edu   http://www.cmm.upenn.edu
   Center for Molecular Modeling   --   University of Pennsylvania
Department of Chemistry, 231 S.34th Street, Philadelphia, PA 19104-6323
tel: 1-215-898-1582,  fax: 1-215-573-6233,  office-tel: 1-215-898-5425
=======================================================================
If you make something idiot-proof, the universe creates a better idiot.