LAMMPS WWW Site - LAMMPS Documentation - LAMMPS Commands

fix langevin command

Syntax:

fix ID group-ID langevin Tstart Tstop damp seed xflag yflag zflag 

Examples:

fix 3 boundary langevin 1.0 1.0 1000.0 699483
fix 1 all langevin 1.0 1.1 100.0 48279 0 1 1 

Description:

Apply a Langevin thermostat to a group of atoms. Uniform random numbers are used to generate a white-noise term that is added to the force of each atom to keep them at a specified temperature. The desired temperature at each timestep is a ramped value during the run from Tstart to Tstop. The damp parameter is specified in time units and determines how rapidly the temperature is relaxed. For example, a value of 100.0 means to relax the temperature in a timespan of (roughly) 100 time units (tau or fmsec or psec - see the units command).

The random # seed should be a non-zero integer with 1 to 8 digits. A Marsaglia random number generator is used. Each processor uses the input seed to generate its own unique seed and its own stream of random numbers. Thus the dynamics of the system will not be identical on two runs on different numbers of processors. Also, the state of the random number generator is not saved in a restart file. This means you cannot do exact restarts when a fix langevin command is used.

The last 3 arguments are flags that specify which dimensions to add langevin white noise to. A flag of 0 means do not add noise to that dimension. A flag of 1 means add noise. The default is 1 for all 3 dimensions. These flags are optional; use all 3 or none of them.

The way that temperature is computed by this fix can be changed by using the fix_modify command.

A langevin fix does not update the coordinates or velocities of its atoms. It is normally used with a fix of style nve that does that. A langevin fix should not normally be used on atoms that also have their temperature controlled by another fix - e.g. a nvt or temp/rescale fix.

Restrictions: none

Related commands:

fix nvt, fix temp/rescale, fix_modify

Default: none