NVT ensemble: Difference between revisions

From VASP Wiki
No edit summary
No edit summary
 
(58 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[:Category: NVT ensemble]]
The [[NVT ensemble]] (canonical ensemble) is a [[:Category:Ensembles|statistical ensemble]] that is used to study material properties under the conditions of a 
constant particle number N, constant volume V and a temperature fluctuating around an equilibrium value <math>\langle T \rangle</math>.
This page describes how to sample the NVT ensemble from a [[Molecular dynamics calculations|molecular-dynamics]] run. 
   
   
== NVT ensemble ==
''' Instructions for setting up an NVT ensemble '''  
The NVT ensemble is a statistical ensemble that is used to study material properties under the conditions of a
 
constant particle number N, constant volume V and a temperature fluctuating around an equilibrium value T.
There are multiple choices of thermostats to control the temperature for the NVT ensemble
This page describes how to sample the NVT ensemble from a [[Molecular dynamics calculations|molecular dynamics]] run.
The stochastic [[Andersen thermostat]], [[Langevin thermostat]] and [[CSVR thermostat]], as well as
the deterministic [[Nosé-Hoover thermostat]], [[Nosé-Hoover chain thermostat]] and [[MDALGO#MDALGO.3D13:_Multiple_Anderson_thermostats|Multiple Andersen thermostats]] can be used.  
''' Instructions for setting up a NVT ensemble '''
See table for the corresponding {{TAG|MDALGO}} setting and related tags.  
There are 4 choices of thermostats which can either be stochastic or deterministic to simulate the NVT ensemble.
 
The stochastic [[Andersen thermostat]] or [[Langevin thermostat]],
{|class="wikitable" style="margin:aut
the deterministic [[Nose-Hoover thermostat]] or [[MDALGO#MDALGO.3D13:_Multiple_Anderson_thermostats|Multiple Anderson thermostats]] can be used.
! NVT ensemble !! Nosé-Hoover<ref name="legacy-nh"/> !! Andersen !! Nosé-Hoover !! Langevin  !! Nosé-Hoover chain !! CSVR !! Multiple Andersen 
See table for the corresponding {{TAG|MDALGO}} tags.
|-
|{{TAG|MDALGO}}        ||  style="text-align:center;"|  0          ||  style="text-align:center;"|  1        ||  style="text-align:center;"|  2            ||  style="text-align:center;"|  3      ||  style="text-align:center;"|  4      ||  style="text-align:center;"|  5      ||  style="text-align:center;"|      13
|- {{TAG|PSUBSYS}}
| additional tags to set || style="text-align:center;"| {{TAG|SMASS}}  || style="text-align:center;"| {{TAG|ANDERSEN_PROB}} || style="text-align:center;"| {{TAG|SMASS}} || style="text-align:center;"|  {{TAG|LANGEVIN_GAMMA}}      || style="text-align:center;"|  {{TAG|NHC_NCHAINS}}, {{TAG|NHC_PERIOD}}, {{TAG|NHC_NRESPA}}, {{TAG|NHC_NS}}      || style="text-align:center;"|  {{TAG|CSVR_PERIOD}}      || style="text-align:center;"|  {{TAG|NSUBSYS}}, {{TAG|TSUBSYS}}, {{TAG|PSUBSYS}}
|}
 
The additional tags in the column for every thermostat have to be set. For example, the [[Nosé-Hoover thermostat]] needs the additional {{TAG|SMASS}} tag. To enforce constant volume throughout the calculation, set {{TAG|ISIF|3|op=<}}. In NVT MD runs there is no control over pressure because the volume is fixed. The average value will therefore depend on the initial lattice given in the {{FILE|POSCAR}} file. It is often desirable to equilibrate the lattice degrees of freedom, for example, by running an [[NpT_ensemble|NpT simulation]] or by performing structure and volume optimization with {{TAG|IBRION|1 or 2}} and setting {{TAG|ISIF|2|op=>}}. A general guide for molecular-dynamics simulations can be found on the [[Molecular dynamics calculations|molecular-dynamics]] page.
 
''Example {{FILE|INCAR}} file for the [[Nosé-Hoover thermostat]]''
 
  #INCAR molecular-dynamics tags NVT ensemble
  {{TAGBL|IBRION}} = 0                  # choose molecular dynamics
  {{TAGBL|MDALGO}} = 2                  # use Nosé-Hoover thermostat
  {{TAGBL|ISIF}} = 2                    # compute stress tensor but do not change box volume/shape
  {{TAGBL|TEBEG}} = 300                  # set temperature
  {{TAGBL|NSW}} = 10000                  # number of time steps
  {{TAGBL|POTIM}} = 1.0                  # time step in femto seconds
  {{TAGBL|SMASS}} = 1.0                  # setting the virtual mass for the Nosé-Hoover thermostat
{{NB|mind| This {{FILE|INCAR}} file only contains the parameters for the molecular-dynamics part. The [[Electronic minimization|electronic minimization]] or the [[Machine-learned force fields|machine learning]] tags have to be added.}}
 
==Related tags and articles==
[[Molecular dynamics calculations|Molecular-dynamics calculations]], {{TAG|ISIF}}, {{TAG|MDALGO}}, {{TAG|LANGEVIN_GAMMA}}, {{TAG|SMASS}},{{TAG|ANDERSEN_PROB}}, {{TAG|NSUBSYS}}, {{TAG|TSUBSYS}}, {{TAG|PSUBSYS}}
 
== Footnotes and references ==
<references>
<ref name="legacy-nh">If possible, use another Nosé–Hoover thermostat implementation, e.g. {{TAG|MDALGO|2}}, see also comments [[MDALGO#MDALGO=0:_Standard_molecular_dynamics|here]].</ref>
</references>


{|class="wikitable" style="margin:aut
[[Category:Molecular dynamics]][[Category:Ensembles]][[Category:Thermostats]]
! NVT ensemble !! Andersen !! Langevin !! Nose-Hoover !! Multiple Andersen
|-
|MDALGO          ||    1        ||    3            ||      2      ||        13
|- {{TAG|PSUBSYS}
| additional tags || {{TAG|ANDERSEN_PROB}} ||  {{TAG|LANGEVIN_GAMMA}} ||  {{TAG|SMASS}}      || {{TAG|NSUBSYS}}, {{TAG|TSUBSYS}}, {{TAG|PSUBSYS}}
|}
The user is not allowed to set ISF>2 because then the volume of the simulation would be allowed to change
and the simulation would not result in a NVT ensemble. Setting ISIF=0 will speed up the calculation because the stress
tensor is not computed. The tag {{TAG|IBRION}} has to be set to zero.

Latest revision as of 08:00, 24 October 2025

The NVT ensemble (canonical ensemble) is a statistical ensemble that is used to study material properties under the conditions of a constant particle number N, constant volume V and a temperature fluctuating around an equilibrium value [math]\displaystyle{ \langle T \rangle }[/math]. This page describes how to sample the NVT ensemble from a molecular-dynamics run.

Instructions for setting up an NVT ensemble

There are multiple choices of thermostats to control the temperature for the NVT ensemble: The stochastic Andersen thermostat, Langevin thermostat and CSVR thermostat, as well as the deterministic Nosé-Hoover thermostat, Nosé-Hoover chain thermostat and Multiple Andersen thermostats can be used. See table for the corresponding MDALGO setting and related tags.

NVT ensemble Nosé-Hoover[1] Andersen Nosé-Hoover Langevin Nosé-Hoover chain CSVR Multiple Andersen
MDALGO 0 1 2 3 4 5 13
additional tags to set SMASS ANDERSEN_PROB SMASS LANGEVIN_GAMMA NHC_NCHAINS, NHC_PERIOD, NHC_NRESPA, NHC_NS CSVR_PERIOD NSUBSYS, TSUBSYS, PSUBSYS

The additional tags in the column for every thermostat have to be set. For example, the Nosé-Hoover thermostat needs the additional SMASS tag. To enforce constant volume throughout the calculation, set ISIF < 3. In NVT MD runs there is no control over pressure because the volume is fixed. The average value will therefore depend on the initial lattice given in the POSCAR file. It is often desirable to equilibrate the lattice degrees of freedom, for example, by running an NpT simulation or by performing structure and volume optimization with IBRION = 1 or 2 and setting ISIF > 2. A general guide for molecular-dynamics simulations can be found on the molecular-dynamics page.

Example INCAR file for the Nosé-Hoover thermostat

 #INCAR molecular-dynamics tags NVT ensemble 
 IBRION = 0                   # choose molecular dynamics 
 MDALGO = 2                   # use Nosé-Hoover thermostat 
 ISIF = 2                     # compute stress tensor but do not change box volume/shape 
 TEBEG = 300                  # set temperature 
 NSW = 10000                  # number of time steps 
 POTIM = 1.0                  # time step in femto seconds 
 SMASS = 1.0                  # setting the virtual mass for the Nosé-Hoover thermostat
Mind: This INCAR file only contains the parameters for the molecular-dynamics part. The electronic minimization or the machine learning tags have to be added.

Related tags and articles

Molecular-dynamics calculations, ISIF, MDALGO, LANGEVIN_GAMMA, SMASS,ANDERSEN_PROB, NSUBSYS, TSUBSYS, PSUBSYS

Footnotes and references

  1. If possible, use another Nosé–Hoover thermostat implementation, e.g. MDALGO = 2, see also comments here.