forked from lijiext/lammps
265 lines
11 KiB
Plaintext
265 lines
11 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
|
|
|
|
thermo_style command :h3
|
|
|
|
[Syntax:]
|
|
|
|
thermo_style style args :pre
|
|
|
|
style = {one} or {multi} or {custom} :ulb,l
|
|
args = list of arguments for a particular style :l
|
|
{one} args = none
|
|
{multi} args = none
|
|
{custom} args = list of attributes
|
|
possible attributes = step, atoms, cpu, temp, press,
|
|
pe, ke, etotal, enthalpy,
|
|
evdwl, ecoul, epair, ebond, eangle, edihed, eimp,
|
|
emol, elong, etail,
|
|
vol, lx, ly, lz, xlo, xhi, ylo, yhi, zlo, zhi,
|
|
pxx, pyy, pzz, pxy, pxz, pyz
|
|
c_ID, c_ID\[n\], f_ID, f_ID\[n\], v_name
|
|
step = timestep
|
|
atoms = # of atoms
|
|
cpu = elapsed CPU time
|
|
temp = temperature
|
|
press = pressure
|
|
pe = total potential energy
|
|
ke = kinetic energy
|
|
etotal = total energy (pe + ke)
|
|
enthalpy = enthalpy (pe + press*vol)
|
|
evdwl = VanderWaal pairwise energy
|
|
ecoul = Coulombic pairwise energy
|
|
epair = pairwise energy (evdwl + ecoul + elong + etail)
|
|
ebond = bond energy
|
|
eangle = angle energy
|
|
edihed = dihedral energy
|
|
eimp = improper energy
|
|
emol = molecular energy (ebond + eangle + edihed + eimp)
|
|
elong = long-range kspace energy
|
|
etail = VanderWaal energy long-range tail correction
|
|
vol = volume
|
|
lx,ly,lz = box lengths in x,y,z
|
|
xlo,xhi,ylo,yhi,zlo,zhi = box boundaries
|
|
pxx,pyy,pzz,pxy,pxz,pyz = 6 components of pressure tensor
|
|
c_ID = global scalar value calculated by a compute with ID
|
|
c_ID\[N\] = Nth component of global vector calculated by a compute with ID
|
|
f_ID = global scalar value calculated by a fix with ID
|
|
f_ID\[N\] = Nth component of global vector calculated by a fix with ID
|
|
v_name = global value calculated by an equal-style variable with name :pre
|
|
:ule
|
|
|
|
[Examples:]
|
|
|
|
thermo_style multi
|
|
thermo_style custom step temp pe etotal press vol
|
|
thermo_style custom step temp etotal c_myTemp v_abc :pre
|
|
|
|
[Description:]
|
|
|
|
Set the style and content for printing thermodynamic data to the
|
|
screen and log file.
|
|
|
|
Style {one} prints a one-line summary of thermodynamic info that is
|
|
the equivalent of "thermo_style custom step temp epair emol etotal
|
|
press". The line contains only numeric values.
|
|
|
|
Style {multi} prints a multiple-line listing of thermodynamic info
|
|
that is the equivalent of "thermo_style custom etotal ke temp pe ebond
|
|
eangle edihed eimp evdwl ecoul elong press". The listing contains
|
|
numeric values and a string ID for each quantity.
|
|
|
|
Style {custom} is the most general setting and allows you to specify
|
|
which of the keywords listed above you want printed on each
|
|
thermodynamic timestep. Note that the keywords c_ID, f_ID, v_name are
|
|
references to "computes"_compute.html, "fixes"_fix.html, and
|
|
equal-style "variables"_variable.html" that have been defined
|
|
elsewhere in the input script or can even be new styles which users
|
|
have added to LAMMPS (see the "Section_modify"_Section_modify.html
|
|
section of the documentation). Thus the {custom} style provides a
|
|
flexible means of outputting essentially any desired quantity as a
|
|
simulation proceeds.
|
|
|
|
All styles except {custom} have {vol} appended to their list of
|
|
outputs if the simulation box volume changes during the simulation.
|
|
|
|
The values printed by the various keywords are instantaneous values,
|
|
calculated on the current timestep. Time-averaged quantities, which
|
|
include values from previous timesteps, can be output by using the
|
|
f_ID keyword and accessing a fix that does time-averaging such as the
|
|
"fix ave/time"_fix_ave_time.html command.
|
|
|
|
Options invoked by the "thermo_modify"_thermo_modify.html command can
|
|
be used to set the one- or multi-line format of the print-out, the
|
|
normalization of energy quantities (total or per-atom), and the
|
|
numeric precision of each printed value.
|
|
|
|
IMPORTANT NOTE: When you specify a "thermo_style" command, all
|
|
thermodynamic settings are restored to their default values, including
|
|
those previously set by a :thermo_modify"_thermo_modify.html command.
|
|
Thus if your input script specifies a thermo_style command, you should
|
|
use the thermo_modify command after it.
|
|
|
|
:line
|
|
|
|
Several of the thermodynamic quantities require a temperature to be
|
|
computed: "temp", "press", "ke", "etotal", "enthalpy", "pxx etc". By
|
|
default this is done by using the "thermo_temp" compute which is
|
|
created when LAMMPS starts up, as if this command had been issued:
|
|
|
|
compute thermo_temp all temp :pre
|
|
|
|
See the "compute temp"_compute_temp.html command for details. Note
|
|
that the ID of this compute is {thermo_temp} and the group is {all}.
|
|
You can change the attributes of this temperature (e.g. its
|
|
degrees-of-freedom) via the "compute_modify"_compute_modify.html
|
|
command. Alternatively, you can directly assign a new compute (that
|
|
calculates temperature) which you have defined, to be used for
|
|
calculating any thermodynamic quantity that requires a temperature.
|
|
This is done via the "thermo_modify"_thermo_modify.html command.
|
|
|
|
Several of the thermodynamic quantities require a pressure to be
|
|
computed: "press", "enthalpy", "pxx", etc. By default this is done by
|
|
using the pressure compute which is created when LAMMPS starts up, as
|
|
if this command had been issued:
|
|
|
|
compute thermo_press all pressure thermo_temp :pre
|
|
|
|
See the "compute pressure"_compute_pressure.html command for details.
|
|
Note that the ID of this compute is {thermo_press} and the group is
|
|
{all}. You can change the attributes of this pressure via the
|
|
"compute_modify"_compute_modify.html command. Alternatively, you can
|
|
directly assign a new compute (that calculates pressure) which you
|
|
have defined, to be used for calculating any thermodynamic quantity
|
|
that requires a pressure. This is done via the
|
|
"thermo_modify"_thermo_modify.html command.
|
|
|
|
Several of the thermodynamic quantities require a potential energy to
|
|
be computed: "pe", "etotal", "ebond", etc. This is done by using the
|
|
"thermo_pe" compute which is created when LAMMPS starts up, as if this
|
|
command had been issued:
|
|
|
|
compute thermo_pe all pe :pre
|
|
|
|
See the "compute pe"_compute_pe.html command for details. Note that
|
|
the ID of this compute is {thermo_pe} and the group is {all}. You can
|
|
change the attributes of this potential energy via the
|
|
"compute_modify"_compute_modify.html command.
|
|
|
|
:line
|
|
|
|
The kinetic energy of the system {ke} is inferred from the temperature
|
|
of the system with 1/2 Kb T of energy for each degree of freedom.
|
|
Thus using different "compute commands"_compute.html for calculating
|
|
temperature, via the "thermo_modify temp"_thermo_modify.html command,
|
|
may yield different kinetic energies.
|
|
|
|
The potential energy of the system {pe} will include contributions
|
|
from fixes if the "fix_modify thermo"_fix_modify.html option is set
|
|
for a fix that calculates such a contribution. For example, the "fix
|
|
wall/lj93"_fix_wall_lj93 fix calculates the energy of atoms
|
|
interacting with the wall. See the doc pages for "individual fixes"
|
|
to see which ones contribute.
|
|
|
|
A long-range tail correction {etail} for the VanderWaal pairwise
|
|
energy will be non-zero only if the "pair_modify
|
|
tail"_pair_modify.html option is turned on. The {etail} contribution
|
|
is included in {evdwl}, {pe}, and {etotal}, and the corresponding tail
|
|
correction to the pressure is included in {press} and {pxx}, {pyy},
|
|
etc.
|
|
|
|
:line
|
|
|
|
The {c_ID} and {c_ID\[N\]} keywords allow global scalar or vector
|
|
quantities calculated by a compute to be output. The ID in the
|
|
keyword should be replaced by the actual ID of the compute that has
|
|
been defined elsewhere in the input script. See the
|
|
"compute"_compute.html command for details. Note that only global
|
|
scalar or vector quantities calculated by a compute can be output as
|
|
thermodynamic data; per-atom quantities calculated by a compute can be
|
|
output by the "dump custom"_dump.html command. There is a "compute
|
|
reduce"_compute_reduce.html command which can sum per-atom quantities
|
|
into a global scalar or vector which can be output by thermo_style
|
|
custom.
|
|
|
|
Note that some computes calculate "intensive" global quantities like
|
|
temperature; others calculate "extensive" global quantities like
|
|
kinetic energy that are summed over all atoms in the compute group.
|
|
Intensive quantities are printed directly as is by thermo_style
|
|
custom. Extensive quantities may be normalized when output by the
|
|
total number of atoms in the simulation (NOT the number of atoms in
|
|
the compute group) depending on the "thermo_modify
|
|
norm"_thermo_modify.html option being used.
|
|
|
|
If {c_ID} is used as a keyword, then the scalar quantity calculated by
|
|
the compute is printed. If {c_ID\[N\]} is used, then N must be an
|
|
index from 1-M where M is the length of the vector calculated by the
|
|
compute. See the doc pages for individual compute styles for info on
|
|
what these quantities are.
|
|
|
|
The {f_ID} and {f_ID\[N\]} keywords allow global scalar or vector
|
|
quantities calculated by a fix to be output. The ID in the keyword
|
|
should be replaced by the actual ID of the fix that has been defined
|
|
elsewhere in the input script. See the doc pages for individual "fix
|
|
commands"_fix.html for details of which fixes generate global values.
|
|
One particularly useful fix to use in this context is the "fix
|
|
ave/time"_fix_ave_time.html command, which calculates time-averages of
|
|
global scalar and vector quantities calculated by other
|
|
"computes"_compute.html, "fixes"_fix.html, or
|
|
"variables"_variable.html.
|
|
|
|
Note that some fixes calculate "intensive" global quantities like
|
|
timestep size; others calculate "extensive" global quantities like
|
|
energy that are summed over all atoms in the fix group. Intensive
|
|
quantities are printed directly as is by thermo_style custom.
|
|
Extensive quantities may be normalized when output by the total number
|
|
of atoms in the simulation (NOT the number of atoms in the fix group)
|
|
depending on the "thermo_modify norm"_thermo_modify.html option being
|
|
used.
|
|
|
|
If {f_ID} is used as a keyword, then the scalar quantity calculated by
|
|
the fix is printed. If {f_ID\[N\]} is used, then N must be an index
|
|
from 1-M where M is the length of the vector calculated by the fix.
|
|
See the doc pages for individual fix styles for info on which fixes
|
|
calculate these global quantities and what they are. For fixes that
|
|
compute a contribution to the potential energy of the system, the
|
|
scalar quantity referenced by f_ID is typically that quantity.
|
|
|
|
The {v_name} keyword allow the current value of a variable to be
|
|
output. The name in the keyword should be replaced by the actual name
|
|
of the variable that has been defined elsewhere in the input script.
|
|
Only equal-style variables can be referenced. See the
|
|
"variable"_variable.html command for details. Variables of style
|
|
{equal} can reference individual atom properties or thermodynamic
|
|
keywords, or they can invoke other computes, fixes, or variables when
|
|
evaluated, so this is a very general means of creating thermodynamic
|
|
output.
|
|
|
|
See "this section"_Section_modify.html for information on how to add
|
|
new compute and fix styles to LAMMPS to calculate quantities that
|
|
could then be output with these keywords as part of thermodynamic
|
|
information.
|
|
|
|
:line
|
|
|
|
[Restrictions:]
|
|
|
|
This command must come after the simulation box is defined by a
|
|
"read_data"_read_data.html, "read_restart"_read_restart.html, or
|
|
"create_box"_create_box.html command.
|
|
|
|
[Related commands:]
|
|
|
|
"thermo"_thermo.html, "thermo_modify"_thermo_modify.html,
|
|
"fix_modify"_fix_modify.html, "compute temp"_compute_temp.html,
|
|
"compute pressure"_compute_pressure.html
|
|
|
|
[Default:]
|
|
|
|
thermo_style one :pre
|