<spanid="index-0"></span><h1>fix wall/srd command<aclass="headerlink"href="#fix-wall-srd-command"title="Permalink to this headline">¶</a></h1>
<divclass="section"id="syntax">
<h2>Syntax<aclass="headerlink"href="#syntax"title="Permalink to this headline">¶</a></h2>
<divclass="highlight-python"><divclass="highlight"><pre>fix ID group-ID wall/srd face arg ... keyword value ...
</pre></div>
</div>
<ulclass="simple">
<li>ID, group-ID are documented in <aclass="reference internal"href="fix.html"><em>fix</em></a> command</li>
<li>wall/srd = style name of this fix command</li>
<li>one or more face/arg pairs may be appended</li>
<li>face = <em>xlo</em> or <em>xhi</em> or <em>ylo</em> or <em>yhi</em> or <em>zlo</em> or <em>zhi</em></li>
</ul>
<preclass="literal-block">
<em>xlo</em>,*ylo*,*zlo* arg = EDGE or constant or variable
EDGE = current lo edge of simulation box
constant = number like 0.0 or -30.0 (distance units)
variable = <aclass="reference internal"href="variable.html"><em>equal-style variable</em></a> like v_x or v_wiggle
<em>xhi</em>,*yhi*,*zhi* arg = EDGE or constant or variable
EDGE = current hi edge of simulation box
constant = number like 50.0 or 100.3 (distance units)
variable = <aclass="reference internal"href="variable.html"><em>equal-style variable</em></a> like v_x or v_wiggle
</pre>
<ulclass="simple">
<li>zero or more keyword/value pairs may be appended</li>
<li>keyword = <em>units</em></li>
</ul>
<preclass="literal-block">
<em>units</em> value = <em>lattice</em> or <em>box</em>
<em>lattice</em> = the wall position is defined in lattice units
<em>box</em> = the wall position is defined in simulation box units
</pre>
</div>
<divclass="section"id="examples">
<h2>Examples<aclass="headerlink"href="#examples"title="Permalink to this headline">¶</a></h2>
<divclass="highlight-python"><divclass="highlight"><pre>fix xwalls all wall/srd xlo EDGE xhi EDGE
fix walls all wall/srd xlo 0.0 ylo 10.0 units box
fix top all wall/srd zhi v_pressdown
</pre></div>
</div>
</div>
<divclass="section"id="description">
<h2>Description<aclass="headerlink"href="#description"title="Permalink to this headline">¶</a></h2>
<p>Bound the simulation with one or more walls which interact with
stochastic reaction dynamics (SRD) particles as slip (smooth) or
no-slip (rough) flat surfaces. The wall interaction is actually
invoked via the <aclass="reference internal"href="fix_srd.html"><em>fix srd</em></a> command, only on the group of
SRD particles it defines, so the group setting for the fix wall/srd
command is ignored.</p>
<p>A particle/wall collision occurs if an SRD particle moves outside the
wall on a timestep. This alters the position and velocity of the SRD
particle and imparts a force to the wall.</p>
<p>The <em>collision</em> and <em>Tsrd</em> settings specified via the <aclass="reference internal"href="fix_srd.html"><em>fix srd</em></a> command affect the SRD/wall collisions. A <em>slip</em>
setting for the <em>collision</em> keyword means that the tangential
component of the SRD particle momentum is preserved. Thus only a
normal force is imparted to the wall. The normal component of the new
SRD velocity is sampled from a Gaussian distribution at temperature
<em>Tsrd</em>.</p>
<p>For a <em>noslip</em> setting of the <em>collision</em> keyword, both the normal and
tangential components of the new SRD velocity are sampled from a
Gaussian distribution at temperature <em>Tsrd</em>. Additionally, a new
tangential direction for the SRD velocity is chosen randomly. This
collision style imparts both a normal and tangential force to the
wall.</p>
<p>Up to 6 walls or faces can be specified in a single command: <em>xlo</em>,
<em>xhi</em>, <em>ylo</em>, <em>yhi</em>, <em>zlo</em>, <em>zhi</em>. A <em>lo</em> face reflects particles
that move to a coordinate less than the wall position, back in the
<em>hi</em> direction. A <em>hi</em> face reflects particles that move to a
coordinate higher than the wall position, back in the <em>lo</em> direction.</p>
<p>The position of each wall can be specified in one of 3 ways: as the
EDGE of the simulation box, as a constant value, or as a variable. If
EDGE is used, then the corresponding boundary of the current
simulation box is used. If a numeric constant is specified then the
wall is placed at that position in the appropriate dimension (x, y, or
z). In both the EDGE and constant cases, the wall will never move.
If the wall position is a variable, it should be specified as v_name,
where name is an <aclass="reference internal"href="variable.html"><em>equal-style variable</em></a> name. In this
case the variable is evaluated each timestep and the result becomes
the current position of the reflecting wall. Equal-style variables
can specify formulas with various mathematical functions, and include
<aclass="reference internal"href="thermo_style.html"><em>thermo_style</em></a> command keywords for the simulation
box parameters and timestep and elapsed time. Thus it is easy to
specify a time-dependent wall position.</p>
<divclass="admonition note">
<pclass="first admonition-title">Note</p>
<pclass="last">Because the trajectory of the SRD particle is tracked as it
collides with the wall, you must insure that r = distance of the
particle from the wall, is always > 0 for SRD particles, or LAMMPS
will generate an error. This means you cannot start your simulation
with SRD particles at the wall position <em>coord</em> (r = 0) or with
particles on the wrong side of the wall (r < 0).</p>
</div>
<divclass="admonition note">
<pclass="first admonition-title">Note</p>
<pclass="last">If you have 2 or more walls that come together at an edge or
corner (e.g. walls in the x and y dimensions), then be sure to set the
<em>overlap</em> keyword to <em>yes</em> in the <aclass="reference internal"href="fix_srd.html"><em>fix srd</em></a> command,
since the walls effectively overlap when SRD particles collide with
them. LAMMPS will issue a warning if you do not do this.</p>
</div>
<divclass="admonition note">
<pclass="first admonition-title">Note</p>
<pclass="last">The walls of this fix only interact with SRD particles, as
defined by the <aclass="reference internal"href="fix_srd.html"><em>fix srd</em></a> command. If you are simulating
a mixture containing other kinds of particles, then you should
typically use <aclass="reference internal"href="fix_wall.html"><em>another wall command</em></a> to act on the other
particles. Since SRD particles will be colliding both with the walls
and the other particles, it is important to insure that the other
particle’s finite extent does not overlap an SRD wall. If you do not
do this, you may generate errors when SRD particles end up “inside”
another particle or a wall at the beginning of a collision step.</p>
</div>
<p>The <em>units</em> keyword determines the meaning of the distance units used
to define a wall position, but only when a numeric constant is used.
It is not relevant when EDGE or a variable is used to specify a face
position.</p>
<p>A <em>box</em> value selects standard distance units as defined by the
<aclass="reference internal"href="units.html"><em>units</em></a> command, e.g. Angstroms for units = real or metal.
A <em>lattice</em> value means the distance units are in lattice spacings.
The <aclass="reference internal"href="lattice.html"><em>lattice</em></a> command must have been previously used to
define the lattice spacings.</p>
<hrclass="docutils"/>
<p>Here are examples of variable definitions that move the wall position
<h2>Restart, fix_modify, output, run start/stop, minimize info<aclass="headerlink"href="#restart-fix-modify-output-run-start-stop-minimize-info"title="Permalink to this headline">¶</a></h2>
<p>No information about this fix is written to <aclass="reference internal"href="restart.html"><em>binary restart files</em></a>. None of the <aclass="reference internal"href="fix_modify.html"><em>fix_modify</em></a> options
are relevant to this fix.</p>
<p>This fix computes a global array of values which can be accessed by
various <aclass="reference internal"href="Section_howto.html#howto-15"><span>output commands</span></a>. The number of
rows in the array is equal to the number of walls defined by the fix.
The number of columns is 3, for the x,y,z components of force on each
wall.</p>
<p>Note that an outward normal force on a wall will be a negative value
for <em>lo</em> walls and a positive value for <em>hi</em> walls. The array 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"><em>run</em></a> command. This fix is not invoked during <aclass="reference internal"href="minimize.html"><em>energy minimization</em></a>.</p>
</div>
<divclass="section"id="restrictions">
<h2>Restrictions<aclass="headerlink"href="#restrictions"title="Permalink to this headline">¶</a></h2>
<p>Any dimension (xyz) that has an SRD wall must be non-periodic.</p>
</div>
<divclass="section"id="related-commands">
<h2>Related commands<aclass="headerlink"href="#related-commands"title="Permalink to this headline">¶</a></h2>
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>.