Bug #797

bd giving incorrect results, such as a temperature 2x as high as it should be in release-4-5-patches

Added by Michael Shirts over 9 years ago. Updated almost 9 years ago.

Target version:
Affected version - extra info:
Affected version:


Crashes with bd -- when I reduce the time step, I can get it to run, but the temperature is generally about 2x what it should be. This appears to have been the case since at least January.

bd.gro (181 KB) bd.gro Michael Shirts, 08/27/2011 07:38 PM
bd.mdp (7.99 KB) bd.mdp Michael Shirts, 08/27/2011 07:38 PM (89 Bytes) Michael Shirts, 08/27/2011 07:38 PM

Associated revisions

Revision 5df58711 (diff)
Added by Berk Hess over 8 years ago

fixed the reported temperature with Brownian dynamics

Reduced the (meaningless) masses with BD by a factor 2.
Since v with BD is defined as dx/dt, the reported Ekin and T are
now correct (and if there are too high, dt is too large).
Fixes #797

Change-Id: Iee8613ff9637deb58600ad03289f7bcce7f32df2


#1 Updated by Berk Hess over 9 years ago

It should crash with such a timestep/friction ratio.
The reported temperature always seems to have been a factor 2 too high.
This is because the velocity is set to the displacement divided by the time step
and the mass is set to the friction coefficient times the time step.
As both velocity and mass are meaningless, there are two solutions:
1) set the velocity to 0.5*displacement/dt
2) set the mass to 0.5*fric*dt
The velocity has no meaning, but I think it makes more sense to set that equal to the displacement and therefore use 2). I can do this when we agree.
Note that all this has no effect on the simulations, only on the reported ekin and T.

#2 Updated by Rossen Apostolov over 9 years ago

You mean use 1) ?

#3 Updated by Rossen Apostolov over 9 years ago

  • Target version changed from 4.5.5 to 4.5.6

#4 Updated by Rossen Apostolov almost 9 years ago

  • Target version changed from 4.5.6 to 4.6

this will go in 4.6, Berk has the fix ready

#5 Updated by Berk Hess almost 9 years ago

  • Status changed from New to Closed

I halved the masses with BD. Now the temperature is correct.
And if you observe a too high temperature, this means the time step is too large.

Also available in: Atom PDF