forked from lijiext/lammps
133 lines
5.6 KiB
HTML
133 lines
5.6 KiB
HTML
|
<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>temperature command
|
||
|
</H3>
|
||
|
<P><B>Syntax:</B>
|
||
|
</P>
|
||
|
<PRE>temperature ID group-ID style args keyword value ...
|
||
|
</PRE>
|
||
|
<UL><LI>ID = user-assigned name for the temperature
|
||
|
|
||
|
<LI>group-ID = ID of group of atoms to compute the temperature for
|
||
|
|
||
|
<LI>style = <I>full</I> or <I>partial</I> or <I>ramp</I> or <I>region</I>
|
||
|
|
||
|
<PRE> <I>full</I> args = none
|
||
|
<I>partial</I> args = x y z
|
||
|
x,y,z = 0 or 1
|
||
|
<I>ramp</I> args = vdim vlo vhi dim clo chi
|
||
|
vdim = <I>vx</I> or <I>vy</I> or <I>vz</I>
|
||
|
vlo,vhi = subtract velocities between vlo and vhi (velocity units)
|
||
|
dim = <I>x</I> or <I>y</I> or <I>z</I>
|
||
|
clo,chi = lower and upper bound of domain to
|
||
|
subtract from (distance units)
|
||
|
<I>region</I> args = region-ID
|
||
|
region-ID = ID of region to use for choosing atoms
|
||
|
</PRE>
|
||
|
<LI>zero or more keyword/value pairs may be appended to the args
|
||
|
|
||
|
<LI>keyword = <I>units</I>
|
||
|
|
||
|
<PRE> <I>units</I> value = <I>lattice</I> or <I>box</I>
|
||
|
</PRE>
|
||
|
|
||
|
</UL>
|
||
|
<P><B>Examples:</B>
|
||
|
</P>
|
||
|
<PRE>temperature mine peptide full
|
||
|
temperature new flow partial 1 1 0
|
||
|
temperature mine flow region boundary
|
||
|
temperature 2nd middle ramp vx 0 8 y 2 12 units lattice
|
||
|
</PRE>
|
||
|
<P><B>Description:</B>
|
||
|
</P>
|
||
|
<P>Define a method for computing the temperature of a group of atoms.
|
||
|
</P>
|
||
|
<P>The ID of the temperature can be referred to in other commands, such
|
||
|
as <A HREF = "thermo_modify.html">thermo_modify</A>, <A HREF = "velocity.html">velocity</A>,
|
||
|
<A HREF = "fix_modify.html">fix_modify</A>, <A HREF = "temp_modify.html">temp_modify</A>. Note
|
||
|
that certain fixes create their own temperatures with the same ID as
|
||
|
the fix, e.g. <A HREF = "fix_temp_rescale.html">fix temp/rescale</A>, <A HREF = "fix_nvt.html">fix
|
||
|
nvt</A>, <A HREF = "fix_npt.html">fix npt</A>, etc.
|
||
|
</P>
|
||
|
<P>The style determines how the temperature is computed. The <I>full</I>
|
||
|
style means KE = dim/2 N k T, where KE = total kinetic energy of the
|
||
|
group of atoms (sum of 1/2 m v^2), dim = 2 or 3 = dimensionality of
|
||
|
the simulation, N = number of atoms in the group, k = Boltzmann
|
||
|
constant, and T = temperature.
|
||
|
</P>
|
||
|
<P>The <I>partial</I> style uses the same formula as <I>full</I>, except entire
|
||
|
dimensions can be eliminated from the kinetic energy computation.
|
||
|
This can be useful for systems where atoms are flowing, and only the
|
||
|
thermal temperature in the non-flow directions is desired. A "0"
|
||
|
means do not use the component of velocity in that dimension when
|
||
|
computing KE. In the example above with arguments 1 1 0, only x and y
|
||
|
velocities (not z) would be used in computing KE and temperature.
|
||
|
</P>
|
||
|
<P>The <I>ramp</I> style can be used to eliminate an imposed velocity on a
|
||
|
system before computing thermal KE. The meaning of these arguments is
|
||
|
the same as for the <A HREF = "velocity.html">velocity</A> command which was
|
||
|
presumably used to impose the velocity.
|
||
|
</P>
|
||
|
<P>The <I>region</I> style is the same as <I>full</I> except that only atoms in the
|
||
|
specified geometric region contribute to the temperature. Since atoms
|
||
|
can enter/leave a region, this test is performed each time the
|
||
|
temperature is computed. This can be useful for thermostatting one
|
||
|
portion of the simulation box. E.g. a McDLT simulation where one side
|
||
|
is cooled, and the other side is heated.
|
||
|
</P>
|
||
|
<P>Note that a <I>region</I>-style temperature can be used to thermostat with
|
||
|
<A HREF = "fix_temp_rescale.html">fix temp/rescale</A> or <A HREF = "fix_langevin.html">fix
|
||
|
langevin</A>, but should probably not be used with
|
||
|
Nose/Hoover style fixes (<A HREF = "fix_nvt.html<A HREF = "fix_npt.html">>fix nvt</A>, fix
|
||
|
npt</A>, or <A HREF = "fix_nph.html">fix nph</A>), if the
|
||
|
degrees-of-freedom included in the computed T varies with time.
|
||
|
</P>
|
||
|
<P>The <I>units</I> keyword determines the meaning of the distance units used
|
||
|
for coordinates (c1,c2) and velocities (vlo,vhi) defined for the
|
||
|
<I>ramp</I> style. A <I>box</I> value selects standard distance units as
|
||
|
defined by the <A HREF = "units.html">units</A> command, e.g. Angstroms for units =
|
||
|
real or metal. A <I>lattice</I> value means the distance units are in
|
||
|
cubic lattice spacings; e.g. lattice spacings / tau. The
|
||
|
<A HREF = "lattice.html">lattice</A> command must first be used to define a lattice.
|
||
|
</P>
|
||
|
<P>LAMMPS defines a temperature with ID = <I>default</I> which computes a
|
||
|
<I>full</I> style on the <I>all</I> group of atoms. This is the temperature
|
||
|
used for thermodynamic output of quantities like temperature,
|
||
|
pressure, kinetic energy (see the <A HREF = "thermo_style.html">thermo_style</A>
|
||
|
command) unless you change it via the
|
||
|
<A HREF = "thermo_modify.html">thermo_modify</A> command.
|
||
|
</P>
|
||
|
<P>All temperature styles (except <I>region</I>) subtract out
|
||
|
degrees-of-freedom (DOF) due to fixes that constrain molecular motion.
|
||
|
Currently, these are <A HREF = "fix_shake.html">fix shake</A> and <A HREF = "fix_rigid.html">fix
|
||
|
rigid</A>. DOF is the N * dim factor in the above
|
||
|
equation for the <I>full</I> style. This means the temperature of groups
|
||
|
of atoms that include these constraints will be computed correctly.
|
||
|
If needed, the subtracted degrees-of-freedom can be tweaked using the
|
||
|
<A HREF = "temp_modify.html">temp_modify</A> command.
|
||
|
</P>
|
||
|
<P><B>Restrictions:</B> none
|
||
|
</P>
|
||
|
<P><B>Related commands:</B>
|
||
|
</P>
|
||
|
<P><A HREF = "thermo_modify.html">thermo_modify</A>, <A HREF = "velocity.html">velocity</A>,
|
||
|
<A HREF = "fix_modify.html">fix_modify</A>, <A HREF = "temp_modify.html">temp_modify</A>
|
||
|
</P>
|
||
|
<P><B>Default:</B>
|
||
|
</P>
|
||
|
<P>A temperature with ID = <I>default</I> is defined by LAMMPS, as if it had
|
||
|
been specified as "temperature default all full". The option default
|
||
|
is units = lattice.
|
||
|
</P>
|
||
|
</HTML>
|