2006-09-22 00:22:34 +08:00
|
|
|
<HTML>
|
|
|
|
<CENTER><A HREF = "http://lammps.sandia.gov">LAMMPS WWW Site</A> - <A HREF = "Manual.html">LAMMPS Documentation</A> - <A HREF = "Section_commands.html#comm">LAMMPS Commands</A>
|
|
|
|
</CENTER>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<HR>
|
|
|
|
|
|
|
|
<H3>fix langevin command
|
|
|
|
</H3>
|
|
|
|
<P><B>Syntax:</B>
|
|
|
|
</P>
|
|
|
|
<PRE>fix ID group-ID langevin Tstart Tstop damp seed keyword values ...
|
|
|
|
</PRE>
|
|
|
|
<UL><LI>ID, group-ID are documented in <A HREF = "fix.html">fix</A> command
|
|
|
|
|
|
|
|
<LI>langevin = style name of this fix command
|
|
|
|
|
|
|
|
<LI>Tstart,Tstop = desired temperature at start/end of run (temperature units)
|
|
|
|
|
|
|
|
<LI>damp = damping parameter (time units)
|
|
|
|
|
2007-10-10 07:40:45 +08:00
|
|
|
<LI>seed = random # seed to use for white noise (positive integer)
|
2006-09-22 00:22:34 +08:00
|
|
|
|
2007-07-03 04:04:44 +08:00
|
|
|
<LI>zero or more keyword/value pairs may be appended
|
2006-09-22 00:22:34 +08:00
|
|
|
|
2008-03-12 01:28:21 +08:00
|
|
|
<PRE>keyword = <I>scale</I>
|
2006-09-22 00:22:34 +08:00
|
|
|
<I>scale</I> values = type ratio
|
|
|
|
type = atom type (1-N)
|
2008-03-12 01:28:21 +08:00
|
|
|
ratio = factor by which to scale the damping coefficient
|
|
|
|
</PRE>
|
2006-09-22 00:22:34 +08:00
|
|
|
|
|
|
|
</UL>
|
|
|
|
<P><B>Examples:</B>
|
|
|
|
</P>
|
|
|
|
<PRE>fix 3 boundary langevin 1.0 1.0 1000.0 699483
|
2008-03-12 01:30:41 +08:00
|
|
|
fix 1 all langevin 1.0 1.1 100.0 48279 scale 3 1.5
|
2006-09-22 00:22:34 +08:00
|
|
|
</PRE>
|
|
|
|
<P><B>Description:</B>
|
|
|
|
</P>
|
|
|
|
<P>Apply a Langevin thermostat to a group of atoms which models an
|
|
|
|
interaction with a background implicit solvent. Used with <A HREF = "fix_nve.html">fix
|
|
|
|
nve</A>, this command performs Brownian dynamics (BD), since
|
|
|
|
the total force on each atom will have the form:
|
|
|
|
</P>
|
|
|
|
<PRE>F = Fc + Ff + Fr
|
|
|
|
</PRE>
|
|
|
|
<P>Fc is the conservative force computed via the usual inter-particle
|
|
|
|
interactions (<A HREF = "pair_style.html">pair_style</A>,
|
|
|
|
<A HREF = "bond_style.html">bond_style</A>, etc).
|
|
|
|
</P>
|
|
|
|
<P>The Ff and Fr terms are added by this fix. Ff = - gamma v and is a
|
|
|
|
frictional drag or viscous damping term proportional to the particle's
|
|
|
|
velocity. Gamma for each atom is computed as m/damp, where m is the
|
|
|
|
mass of the particle and damp is the damping factor specified by the
|
|
|
|
user.
|
|
|
|
</P>
|
|
|
|
<P>Fr is a force due to solvent atoms at a temperature T randomly bumping
|
|
|
|
into the particle. As derived from the fluctuation/dissipation
|
2008-03-01 09:13:20 +08:00
|
|
|
theorem, its magnitude is proportional to sqrt(T m / dt damp), where T
|
2006-09-22 00:22:34 +08:00
|
|
|
is the desired temperature, m is the mass of the particle, dt is the
|
|
|
|
timestep size, and damp is the damping factor. Random numbers are
|
2007-11-15 23:29:14 +08:00
|
|
|
used to randomize the direction and magnitude of this force as
|
|
|
|
described in <A HREF = "#Dunweg">(Dunweg)</A>, where a uniform random number is used
|
|
|
|
(instead of a Gaussian random number) for speed.
|
2006-09-22 00:22:34 +08:00
|
|
|
</P>
|
2008-03-12 01:15:19 +08:00
|
|
|
<P>IMPORTANT NOTE: Unlike the <A HREF = "fix_nvt.html">fix nvt</A> command which
|
|
|
|
performs Nose/Hoover thermostatting AND time integration, this fix
|
|
|
|
does NOT perform time integration. It only modifies forces to effect
|
|
|
|
thermostatting. Thus you must use a separate time integration fix,
|
|
|
|
like <A HREF = "fix_nve.html">fix nve</A> to actually update the velocities and
|
2008-03-18 04:49:34 +08:00
|
|
|
positions of atoms using the modified forces. Likewise, this fix
|
2008-03-12 01:15:19 +08:00
|
|
|
should not normally be used on atoms that also have their temperature
|
|
|
|
controlled by another fix - e.g. by <A HREF = "fix_nvt.html">fix nvt</A> or <A HREF = "fix_temp_rescale.html">fix
|
|
|
|
temp/rescale</A> commands.
|
|
|
|
</P>
|
2006-09-22 00:22:34 +08:00
|
|
|
<P>The desired temperature at each timestep is a ramped value during the
|
2007-06-26 08:03:39 +08:00
|
|
|
run from <I>Tstart</I> to <I>Tstop</I>.
|
2006-09-22 00:22:34 +08:00
|
|
|
</P>
|
2008-03-12 01:15:19 +08:00
|
|
|
<P>Like other fixes that perform thermostatting, this fix can be used
|
|
|
|
with <A HREF = "compute.html">compute commands</A> that calculate a temperature
|
|
|
|
after removing a "bias" from the atom velocities. E.g. removing the
|
|
|
|
center-of-mass velocity from a group of atoms or only calculating
|
|
|
|
temperature on the x-component of velocity or only calculating
|
|
|
|
temperature for atoms in a geometric region. This is not done by
|
|
|
|
default, but only if the <A HREF = "fix_modify.html">fix_modify</A> command is used
|
|
|
|
to assign a temperature compute to this fix that includes such a bias
|
|
|
|
term. See the doc pages for individual <A HREF = "compute.html">compute
|
|
|
|
commands</A> to determine which ones include a bias. In
|
|
|
|
this case, the thermostat works in the following manner: the current
|
|
|
|
temperature is calculated taking the bias into account, bias is
|
|
|
|
removed from each atom, thermostatting is performed on the remaining
|
|
|
|
thermal degrees of freedom, and the bias is added back in.
|
|
|
|
</P>
|
2006-09-22 00:22:34 +08:00
|
|
|
<P>The <I>damp</I> 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 <A HREF = "units.html">units</A> command).
|
|
|
|
The damp factor can be thought of as inversely related to the
|
|
|
|
viscosity of the solvent. I.e. a small relaxation time implies a
|
|
|
|
hi-viscosity solvent and vice versa. See the discussion about gamma
|
|
|
|
and viscosity in the documentation for the <A HREF = "fix_viscous.html">fix
|
|
|
|
viscous</A> command for more details.
|
|
|
|
</P>
|
2007-10-10 07:44:18 +08:00
|
|
|
<P>The random # <I>seed</I> must be a positive integer. 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.
|
2006-09-22 00:22:34 +08:00
|
|
|
</P>
|
|
|
|
<P>The keyword <I>axes</I> can be used to specify which dimensions to add Ff
|
|
|
|
and Fr to. A flag of 0 means skip that dimension; a flag of 1 means
|
|
|
|
include that dimension. The default is 1 for all 3 dimensions.
|
|
|
|
</P>
|
|
|
|
<P>The keyword <I>scale</I> allows the damp factor to be scaled up or down by
|
2008-03-11 01:48:22 +08:00
|
|
|
the specified factor for atoms of that type. This can be useful when
|
|
|
|
different atom types have different sizes or masses. It can be used
|
|
|
|
multiple times to adjust damp for several atom types. Note that
|
2008-03-19 04:18:54 +08:00
|
|
|
specifying a ratio of 2 increases the relaxation time which is
|
2008-03-11 01:48:22 +08:00
|
|
|
equivalent to the the solvent's viscosity acting on particles with 1/2
|
|
|
|
the diameter. This is the opposite effect of scale factors used by
|
|
|
|
the <A HREF = "fix_viscous.html">fix viscous</A> command, since the damp factor in
|
|
|
|
fix <I>langevin</I> is inversely related to the gamma factor in fix
|
|
|
|
<I>viscous</I>. Also note that the damping factor in fix <I>langevin</I>
|
|
|
|
includes the particle mass in Ff, unlike fix <I>viscous</I>. Thus the mass
|
|
|
|
and size of different atom types should be accounted for in the choice
|
|
|
|
of ratio values.
|
2006-09-22 00:22:34 +08:00
|
|
|
</P>
|
2007-10-11 06:28:11 +08:00
|
|
|
<P><B>Restart, fix_modify, output, run start/stop, minimize info:</B>
|
2007-06-26 08:03:39 +08:00
|
|
|
</P>
|
|
|
|
<P>No information about this fix is written to <A HREF = "restart.html">binary restart
|
|
|
|
files</A>. Because the state of the random number generator
|
|
|
|
is not saved in restart files, this means you cannot do "exact"
|
|
|
|
restarts with this fix, where the simulation continues on the same as
|
|
|
|
if no restart had taken place. However, in a statistical sense, a
|
|
|
|
restarted simulation should produce the same behavior.
|
|
|
|
</P>
|
2008-03-12 01:15:19 +08:00
|
|
|
<P>The <A HREF = "fix_modify.html">fix_modify</A> <I>temp</I> option is supported by this
|
|
|
|
fix. You can use it to assign a temperature <A HREF = "compute.html">compute</A>
|
|
|
|
you have defined to this fix which will be used in its thermostatting
|
|
|
|
procedure, as described above. For consistency, the group used by
|
|
|
|
this fix and by the compute should be the same.
|
|
|
|
</P>
|
|
|
|
<P>No global scalar or vector or per-atom quantities are stored by this
|
|
|
|
fix for access by various <A HREF = "Section_howto.html#4_15">output commands</A>.
|
2007-06-26 08:03:39 +08:00
|
|
|
</P>
|
|
|
|
<P>This fix can ramp its target temperature over multiple runs, using the
|
|
|
|
<I>start</I> and <I>stop</I> keywords of the <A HREF = "run.html">run</A> command. See the
|
|
|
|
<A HREF = "run.html">run</A> command for details of how to do this.
|
|
|
|
</P>
|
|
|
|
<P>This fix is not invoked during <A HREF = "minimize.html">energy minimization</A>.
|
|
|
|
</P>
|
2006-09-22 00:22:34 +08:00
|
|
|
<P><B>Restrictions:</B> none
|
|
|
|
</P>
|
|
|
|
<P><B>Related commands:</B>
|
|
|
|
</P>
|
|
|
|
<P><A HREF = "fix_nvt.html">fix nvt</A>, <A HREF = "fix_temp_rescale.html">fix temp/rescale</A>, <A HREF = "fix_viscous.html">fix
|
|
|
|
viscous</A>
|
|
|
|
</P>
|
2008-02-09 04:00:41 +08:00
|
|
|
<P><B>Default:</B>
|
|
|
|
</P>
|
|
|
|
<P>The option defaults are axes = 1 1 1, scale = 1.0 for all types, no
|
|
|
|
region, and weight = 1.0.
|
2006-09-22 00:22:34 +08:00
|
|
|
</P>
|
2007-11-15 23:29:14 +08:00
|
|
|
<A NAME = "Dunweg"></A>
|
|
|
|
|
|
|
|
<P><B>(Dunweg)</B> Dunweg and Paul, Int J of Modern Physics C, 2, 817-27 (1991).
|
|
|
|
</P>
|
2006-09-22 00:22:34 +08:00
|
|
|
</HTML>
|