forked from lijiext/lammps
121 lines
4.9 KiB
Plaintext
121 lines
4.9 KiB
Plaintext
"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c
|
|
|
|
:link(lws,http://lammps.sandia.gov)
|
|
:link(ld,Manual.html)
|
|
:link(lc,Section_commands.html#comm)
|
|
|
|
:line
|
|
|
|
temperature command :h3
|
|
|
|
[Syntax:]
|
|
|
|
temperature ID group-ID style args keyword value ... :pre
|
|
|
|
ID = user-assigned name for the temperature :ulb,l
|
|
group-ID = ID of group of atoms to compute the temperature for :l
|
|
style = {full} or {partial} or {ramp} or {region} :l
|
|
{full} args = none
|
|
{partial} args = x y z
|
|
x,y,z = 0 or 1
|
|
{ramp} args = vdim vlo vhi dim clo chi
|
|
vdim = {vx} or {vy} or {vz}
|
|
vlo,vhi = subtract velocities between vlo and vhi (velocity units)
|
|
dim = {x} or {y} or {z}
|
|
clo,chi = lower and upper bound of domain to
|
|
subtract from (distance units)
|
|
{region} args = region-ID
|
|
region-ID = ID of region to use for choosing atoms :pre
|
|
zero or more keyword/value pairs may be appended to the args :l
|
|
keyword = {units} :l
|
|
{units} value = {lattice} or {box} :pre
|
|
:ule
|
|
|
|
[Examples:]
|
|
|
|
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
|
|
|
|
[Description:]
|
|
|
|
Define a method for computing the temperature of a group of atoms.
|
|
|
|
The ID of the temperature can be referred to in other commands, such
|
|
as "thermo_modify"_thermo_modify.html, "velocity"_velocity.html,
|
|
"fix_modify"_fix_modify.html, "temp_modify"_temp_modify.html. Note
|
|
that certain fixes create their own temperatures with the same ID as
|
|
the fix, e.g. "fix temp/rescale"_fix_temp_rescale.html, "fix
|
|
nvt"_fix_nvt.html, "fix npt"_fix_npt.html, etc.
|
|
|
|
The style determines how the temperature is computed. The {full}
|
|
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.
|
|
|
|
The {partial} style uses the same formula as {full}, 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.
|
|
|
|
The {ramp} 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 "velocity"_velocity.html command which was
|
|
presumably used to impose the velocity.
|
|
|
|
The {region} style is the same as {full} 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.
|
|
|
|
Note that a {region}-style temperature can be used to thermostat with
|
|
"fix temp/rescale"_fix_temp_rescale.html or "fix
|
|
langevin"_fix_langevin.html, but should probably not be used with
|
|
Nose/Hoover style fixes ("fix nvt"_fix_nvt.html, fix
|
|
npt"_fix_npt.html, or "fix nph"_fix_nph.html), if the
|
|
degrees-of-freedom included in the computed T varies with time.
|
|
|
|
The {units} keyword determines the meaning of the distance units used
|
|
for coordinates (c1,c2) and velocities (vlo,vhi) defined for the
|
|
{ramp} style. A {box} value selects standard distance units as
|
|
defined by the "units"_units.html command, e.g. Angstroms for units =
|
|
real or metal. A {lattice} value means the distance units are in
|
|
cubic lattice spacings; e.g. lattice spacings / tau. The
|
|
"lattice"_lattice.html command must first be used to define a lattice.
|
|
|
|
LAMMPS defines a temperature with ID = {default} which computes a
|
|
{full} style on the {all} group of atoms. This is the temperature
|
|
used for thermodynamic output of quantities like temperature,
|
|
pressure, kinetic energy (see the "thermo_style"_thermo_style.html
|
|
command) unless you change it via the
|
|
"thermo_modify"_thermo_modify.html command.
|
|
|
|
All temperature styles (except {region}) subtract out
|
|
degrees-of-freedom (DOF) due to fixes that constrain molecular motion.
|
|
Currently, these are "fix shake"_fix_shake.html and "fix
|
|
rigid"_fix_rigid.html. DOF is the N * dim factor in the above
|
|
equation for the {full} 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
|
|
"temp_modify"_temp_modify.html command.
|
|
|
|
[Restrictions:] none
|
|
|
|
[Related commands:]
|
|
|
|
"thermo_modify"_thermo_modify.html, "velocity"_velocity.html,
|
|
"fix_modify"_fix_modify.html, "temp_modify"_temp_modify.html
|
|
|
|
[Default:]
|
|
|
|
A temperature with ID = {default} is defined by LAMMPS, as if it had
|
|
been specified as "temperature default all full". The option default
|
|
is units = lattice.
|