# Andersen thermostat

The Andersen thermostat couples the system to a heat bath via stochastic forces that modify the kinetic energy of the atoms or molecules. The time between collisions, or the number of collisions in some (short) time interval is decided randomly, with the following Poisson distribution,

$P(t) = \nu e^{-\nu t},$

where $\nu$ is the stochastic collision frequency.[1] Between collisions, the system evolves at constant energy. Upon a collision event the new momentum of the atom (or molecule) is chosen at random from a Boltzmann distribution at temperature $T$. While in principle $\nu$ can adopt any value, there does exist an optimal choice,

$\nu = \frac{2a \kappa V^{1/3}}{3 k_BN} = \frac{2a \kappa}{3 k_B\rho^{1/3}N^{2/3}},$

where $a$ is a dimensionless constant, $\kappa$ is the thermal conductivity, $V$ is the volume, $k_B$ is the Boltzmann constant, and $\rho$ is the number density of particles, $\rho = N/V$.

Note: the Andersen thermostat should only be used for time-independent properties. Dynamic properties, such as the diffusion, should not be calculated if the system is thermostated using the Andersen algorithm.[2]

## References

1. ^ Hans C. Andersen "Molecular dynamics simulations at constant pressure and/or temperature", Journal of Chemical Physics 72, 2384-2393 (1980)
2. ^ H. Tanaka, Koichiro Nakanishi, and Nobuatsu Watanabe "Constant temperature molecular dynamics calculation on Lennard-Jones fluid and its application to water", Journal of Chemical Physics 78 2626-2634 (1983)