lammps/doc/newton.html

68 lines
2.1 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>newton command
</H3>
<P><B>Syntax:</B>
</P>
<PRE>newton flag
newton flag1 flag2
</PRE>
<UL><LI>flag = <I>on</I> or <I>off</I> for both pairwise and bonded interactions
<LI>flag1 = <I>on</I> or <I>off</I> for pairwise interactions
<LI>flag2 = <I>on</I> or <I>off</I> for bonded interactions
</UL>
<P><B>Examples:</B>
</P>
<PRE>newton off
newton on off
</PRE>
<P><B>Description:</B>
</P>
<P>This command turns Newton's 3rd law <I>on</I> or <I>off</I> for pairwise and
bonded interactions. For most problems, setting Newton's 3rd law to
<I>on</I> means a modest savings in computation at the cost of two times
more communication. Whether this is faster depends on problem size,
force cutoff lengths, a machine's compute/communication ratio, and how
many processors are being used.
</P>
<P>Setting the pairwise newton flag to <I>off</I> means that if two
interacting atoms are on different processors, both processors compute
their interaction and the resulting force information is not
communicated. Similarly, for bonded interactions, newton <I>off</I> means
that if a bond, angle, dihedral, or improper interaction contains
atoms on 2 or more processors, the interaction is computed by each
processor.
</P>
<P>LAMMPS should produce the same answers for any newton flag settings,
except for round-off issues.
</P>
<P>With <A HREF = "run_style.html">run_style</A> <I>respa</I> and only bonded interactions
(bond, angle, etc) computed in the innermost timestep, it may be
faster to turn newton <I>off</I> for bonded interactions, to avoid extra
communication in the innermost loop.
</P>
<P><B>Restrictions:</B>
</P>
<P>The newton bond setting cannot be changed after the simulation box is
defined by a <A HREF = "read_data.html">read_data</A> or
<A HREF = "create_box.html">create_box</A> command.
</P>
<P><B>Related commands:</B>
</P>
<P><A HREF = "run_style.html">run_style</A> respa
</P>
<P><B>Default:</B>
</P>
<PRE>newton on
</PRE>
</HTML>