[gmx-developers] energy conservation with constraints

Berk Hess hessb at mpip-mainz.mpg.de
Tue Apr 11 16:44:19 CEST 2006


Hi,

With all the discussion on the list I thought I'd dig up my
single precision code with double precision constraints.

I have made xprime, the update and the constraint code
double precision. This should allow the particles displacements
to be corrected in double precision for the constraints.

My test system is 216 SPC, NVE, dt=2fs, shifted Coulomb and LJ.

The energy drift over 100 ps as a fraction of Ekin is:
dp, settle dp 0.0%
sp, settle sp -0.6%
sp, settle dp: -0.3%
dp, settle dp, x rounded to sp at the beginning of each step: 0.0%
dp, lincs dp order 8, iter 8: 0.0%
dp, lincs dp order 8, iter 4: 0.3%
sp, lincs sp order 8, iter 8: 2.1%

This shows that for energy conservation in double precision
both settle and lincs work fine.
In single precision with settle energy conservation is not as good,
but still not bad. Certainly useful for a 100 ps simulation.
In single precision lincs is less accurate than settle.
This could also be the case in double precision, but there I would
need more than 100 ps to observe this.

The double precision run with the coordinates rounded to float
at the beginning of each md step shows that one could probably
use single precision force calculation and still obtain good energy
conservation.

But I am a bit puzzled by the difference between the double run
with rounded x and the single precision run with double precision update.
If you have float accuracy coordinates to start with, where does
the extra accuracy come from?
I wouldn't assume we would need the velocities to be that accurate
when the coordinates are less accurate.

Berk.




More information about the gromacs.org_gmx-developers mailing list