# Nose-Hoover thermostat

In the approach by Nosé and Hoover[1][2][3][4], an extra degree of freedom is introduced in the Hamiltonian. The heat bath is considered as an integral part of the system and has a fictious coordinate ${\displaystyle s}$ which is introduced into the Lagrangian of the system. This Lagrangian for a ${\displaystyle N}$ particle system is written as

${\displaystyle {\mathcal {L}}=\sum \limits _{i=1}^{N}{\frac {m_{i}}{2}}s^{2}{\dot {\mathbf {r}}}_{i}^{2}-U({\mathbf {r}})+{\frac {Q}{2}}{\dot {s}}^{2}-gk_{B}T\mathrm {ln} \,s}$

where ${\displaystyle m_{i}}$ and ${\displaystyle k_{B}}$ are the mass of ion ${\displaystyle i}$ and the Boltzmann constant, respectively. The first two terms are the kinetic and potential energy of the system. The third and fourth term represent the kinetic and potential energy of the fictitious coordinate ${\displaystyle s}$. These terms also ensure the energy conservation of the Nose-Hoover thermostat. The parameter ${\displaystyle g}$ is usually equal to the number of degrees of freedom of the system ${\displaystyle g=3N-N_{\mathrm {constraint} }}$, where ${\displaystyle N_{\mathrm {constraint} }}$ is equal to the number of constraint set (fixed coordinates in the POSCAR file). The parameter ${\displaystyle Q}$ is an effective "mass" of ${\displaystyle s}$, which controls the coupling of the system to the heat bath. It is set by the INCAR tag SMASS.

The Nose-Hoover thermostat is selected by MDALGO=2.