lammps/doc/compute_pe.html

71 lines
2.4 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>compute pe command
</H3>
<P><B>Syntax:</B>
</P>
<PRE>compute ID group-ID pe keyword ...
</PRE>
<UL><LI>ID, group-ID are documented in <A HREF = "compute.html">compute</A> command
<LI>pe = style name of this compute command
<LI>zero or more keywords may be appended
<LI>keyword = <I>pair</I> or <I>bond</I> or <I>angle</I> or <I>dihedral</I> or <I>improper</I> or <I>kspace</I>
</UL>
<P><B>Examples:</B>
</P>
<PRE>compute 1 all pe
compute molPE all pe bond angle dihedral improper
</PRE>
<P><B>Description:</B>
</P>
<P>Define a computation that calculates the potential energy of the
entire system of atoms. The specified group must be "all". See the
<A HREF = "compute_pe_atom.html">compute pe/atom</A> command if you want per-atom
energies. These per-atom values could be summed for a group of atoms
via the <A HREF = "compute_reduce.html">compute reduce</A> command.
</P>
<P>The energy is calculated by the various pair, bond, etc potentials
defined for the simulation. If no extra keywords are listed, then the
potential energy is the sum of pair, bond, angle, dihedral, improper,
and kspace (long-range) energy. If any extra keywords are listed,
then only those components are summed to compute the potential energy.
</P>
<P>Various fixes can contribute to the total potential energy of the
system. See the doc pages for <A HREF = "fix.html">individual fixes</A> for
details. The <I>thermo</I> option of the
<A HREF = "compute_modify.html">compute_modify</A> command determines whether these
contributions are added into the computed potential energy. If no
keywords are specified the default is <I>yes</I>. If any keywords are
specified, the default is <I>no</I>.
</P>
<P>A compute of this style with the ID of "thermo_pe" is created when
LAMMPS starts up, as if this command were in the input script:
</P>
<PRE>compute thermo_pe all pe
</PRE>
<P>See the "thermo_style" command for more details.
</P>
<P><B>Output info:</B>
</P>
<P>The scalar value calculated by this compute is "extensive", meaning it
it scales with the number of atoms in the simulation.
</P>
<P><B>Restrictions:</B> none
</P>
<P><B>Related commands:</B>
</P>
<P><A HREF = "compute_pe_atom.html">compute pe/atom</A>
</P>
<P><B>Default:</B> none
</P>
</HTML>