<li>any of Tx,Ty,Tz can be a variable (see below)</li>
</ul>
</div>
<divclass="section"id="examples">
<h2>Examples</h2>
<preclass="literal-block">
fix kick bead addtorque 2.0 3.0 5.0
fix kick bead addtorque 0.0 0.0 v_oscillate
</pre>
</div>
<divclass="section"id="description">
<h2>Description</h2>
<p>Add a set of forces to each atom in
the group such that:</p>
<ulclass="simple">
<li>the components of the total torque applied on the group (around its
center of mass) are Tx,Ty,Tz</li>
<li>the group would move as a rigid body in the absence of other
forces.</li>
</ul>
<p>This command can be used to drive a group of atoms into rotation.</p>
<p>Any of the 3 quantities defining the torque components can be specified
as an equal-style <aclass="reference internal"href="variable.html"><spanclass="doc">variable</span></a>, namely <em>Tx</em>,
<em>Ty</em>, <em>Tz</em>. If the value is a variable, it should be specified as
v_name, where name is the variable name. In this case, the variable
will be evaluated each timestep, and its value used to determine the
torque component.</p>
<p>Equal-style variables can specify formulas with various mathematical
functions, and include <aclass="reference internal"href="thermo_style.html"><spanclass="doc">thermo_style</span></a> command
keywords for the simulation box parameters and timestep and elapsed
time. Thus it is easy to specify a time-dependent torque.</p>
<hrclass="docutils"/>
<p><strong>Restart, fix_modify, output, run start/stop, minimize info:</strong></p>
<p>No information about this fix is written to <aclass="reference internal"href="restart.html"><spanclass="doc">binary restart files</span></a>.</p>
<p>The <aclass="reference internal"href="fix_modify.html"><spanclass="doc">fix_modify</span></a><em>energy</em> option is supported by this
fix to add the potential “energy” inferred by the added forces to the
system’s potential energy as part of <aclass="reference internal"href="thermo_style.html"><spanclass="doc">thermodynamic output</span></a>. This is a fictitious quantity but is
needed so that the <aclass="reference internal"href="minimize.html"><spanclass="doc">minimize</span></a> command can include the
forces added by this fix in a consistent manner. I.e. there is a
decrease in potential energy when atoms move in the direction of the
added forces.</p>
<p>The <aclass="reference internal"href="fix_modify.html"><spanclass="doc">fix_modify</span></a><em>respa</em> option is supported by
this fix. This allows to set at which level of the <aclass="reference internal"href="run_style.html"><spanclass="doc">r-RESPA</span></a>
integrator the fix is adding its torque. Default is the outermost level.</p>
<p>This fix computes a global scalar and a global 3-vector, which can be
accessed by various <aclass="reference internal"href="Section_howto.html#howto-15"><spanclass="std std-ref">output commands</span></a>.
The scalar is the potential energy discussed above. The vector is the
total torque on the group of atoms before the forces on individual
atoms are changed by the fix. The scalar and vector values calculated
by this fix are “extensive”.</p>
<p>No parameter of this fix can be used with the <em>start/stop</em> keywords of
the <aclass="reference internal"href="run.html"><spanclass="doc">run</span></a> command.</p>
<p>The forces due to this fix are imposed during an energy minimization,
invoked by the <aclass="reference internal"href="minimize.html"><spanclass="doc">minimize</span></a> command. You should not
specify force components with a variable that has time-dependence for
use with a minimizer, since the minimizer increments the timestep as
the iteration count during the minimization.</p>
</div>
<divclass="section"id="restrictions">
<h2>Restrictions</h2>
<p>This fix is part of the USER-MISC package. It is only enabled if
LAMMPS was built with that package. See the <aclass="reference internal"href="Section_start.html#start-3"><spanclass="std std-ref">Making LAMMPS</span></a> section for more info.</p>
Built with <ahref="http://sphinx-doc.org/">Sphinx</a> using a <ahref="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <ahref="https://readthedocs.org">Read the Docs</a>.