Langevin thermostat for Gaussian basis AIMD equilibrates higher than target temperature


Clicked A Few Times
I am trying to run a Gaussian basis AIMD NVT simulation at 300 K with the Langevin thermostat. When I don't set the target temperature (i.e., it is set to the default, 298.15 K), the average temperature is ~320 K (for up to 200 fs). I've also tried changing the friction parameter, but in my case it does not change the average temperature more than a couple K. Does this thermostat just take a really long time to equilibrate? Or is the temperature in the output file different from the target temperature?

I've also started a calculation with targ_temp set to 270 K and it's average temperature is also ~20 K higher at 290 K. I've also used a variety of XC functionals (B3LYP, BLYP, PBE0, PBE96) and this doesn't seem to be an issue with choice of functional. Below is a sample of my input file. Any help is appreciated!

basis
  * library 6-31G*
end

dft
 xc xpbe96 cpbe96
end

qmd
 nstep_nucl  300000
 targ_temp 270.0
 thermostat  langevin
 rand_seed   12345
 print_xyz    100
end
task dft qmd

Forum Regular
There is a bug in the MD code for the Langevin thermostat. Since the dynamics are performed in Cartesian coordinates and the Langevin thermostat is a local thermostat, there are 3*N degrees of freedom as far as the thermostat is concerned (N is the number of atoms). However, the temperature is calculated assuming 3*N-6 (or 3*N-5 for a linear molecule) degrees of freedom. Now, since by default center-of-mass translations and rotations are removed and the velocities rescaled to maintain the same kinetic energy after removal, the calculated temperature is (approximately) reflective of the temperature for the internal degrees of freedom. Until this gets fixed in a future version of the code, you have three options:

1) Set the com_step keyword to 1 so that there is no center-of-mass motion, and set targ_temp to [(3*N-6)/(3*N)] T where T is the actual temperature you want. The temperature reported in the output will then be the temperature of the internal degrees of freedom.

2) Set com_step to larger than nstep_nucl, and set targ_temp to the temperature you want. The temperature in the output will then be (3*N)/(3*N-6) times larger than the actual temperature of the system, but the dynamics will correspond to a system at the target temperature. Note, that for this set up your system will experience center-of-mass motion and the temperature associated with the internal degrees of freedom will be lower than your target temperature.

3) Use a different thermostat. In particular, I suggest the stochastic velocity rescaling thermostat. This thermostat correctly samples the canonical ensemble, is a global version of the Langevin thermostat, minimally perturbs the dynamics of the system away from Hamiltonian dynamics, and the results are less sensitive to the choice of relaxation parameter.

Clicked A Few Times
Thank you!
I'll try those!

Forum Regular
We will fix this in the development branch. Please check github for updates.

Best,
-Niri

Forum Regular
I have checked in a fix for this. Please check the master and hotfix branches on github

Forum Regular
github commit id for the:

master branch: 6316102fc746c93cff2bcb3eb4f2ef6550fefc9a
hotfix (6.8.1) branch: 78bac41361c6ac0029cc4b7e8f8b7eb79c0100a0

Let us know if there are any issues.

Best,
-Niri Govind

Clicked A Few Times
Thanks!


Forum >> NWChem's corner >> Running NWChem