mirror of https://github.com/lammps/lammps.git
321 lines
15 KiB
HTML
321 lines
15 KiB
HTML
|
|
|
|
<!DOCTYPE html>
|
|
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
|
|
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
|
|
<head>
|
|
<meta charset="utf-8">
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
|
<title>fix flow/gauss command — LAMMPS documentation</title>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="_static/sphinxcontrib-images/LightBox2/lightbox2/css/lightbox.css" type="text/css" />
|
|
|
|
|
|
|
|
<link rel="top" title="LAMMPS documentation" href="index.html"/>
|
|
|
|
|
|
<script src="_static/js/modernizr.min.js"></script>
|
|
|
|
</head>
|
|
|
|
<body class="wy-body-for-nav" role="document">
|
|
|
|
<div class="wy-grid-for-nav">
|
|
|
|
|
|
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
<div class="wy-side-nav-search">
|
|
|
|
|
|
|
|
<a href="Manual.html" class="icon icon-home"> LAMMPS
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
<div role="search">
|
|
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
<input type="text" name="q" placeholder="Search docs" />
|
|
<input type="hidden" name="check_keywords" value="yes" />
|
|
<input type="hidden" name="area" value="default" />
|
|
</form>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
|
|
|
|
|
|
|
|
<ul>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_intro.html">1. Introduction</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_start.html">2. Getting Started</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_commands.html">3. Commands</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_packages.html">4. Packages</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_accelerate.html">5. Accelerating LAMMPS performance</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_howto.html">6. How-to discussions</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_example.html">7. Example problems</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_perf.html">8. Performance & scalability</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_tools.html">9. Additional tools</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_modify.html">10. Modifying & extending LAMMPS</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_python.html">11. Python interface to LAMMPS</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_errors.html">12. Errors</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="Section_history.html">13. Future and history</a></li>
|
|
</ul>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</nav>
|
|
|
|
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
|
|
|
|
|
|
<nav class="wy-nav-top" role="navigation" aria-label="top navigation">
|
|
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
<a href="Manual.html">LAMMPS</a>
|
|
</nav>
|
|
|
|
|
|
|
|
<div class="wy-nav-content">
|
|
<div class="rst-content">
|
|
<div role="navigation" aria-label="breadcrumbs navigation">
|
|
<ul class="wy-breadcrumbs">
|
|
<li><a href="Manual.html">Docs</a> »</li>
|
|
|
|
<li>fix flow/gauss command</li>
|
|
<li class="wy-breadcrumbs-aside">
|
|
|
|
|
|
<a href="http://lammps.sandia.gov">Website</a>
|
|
<a href="Section_commands.html#comm">Commands</a>
|
|
|
|
</li>
|
|
</ul>
|
|
<hr/>
|
|
|
|
</div>
|
|
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
<div itemprop="articleBody">
|
|
|
|
<div class="section" id="fix-flow-gauss-command">
|
|
<span id="index-0"></span><h1>fix flow/gauss command</h1>
|
|
<div class="section" id="syntax">
|
|
<h2>Syntax</h2>
|
|
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">fix</span> <span class="n">ID</span> <span class="n">group</span><span class="o">-</span><span class="n">ID</span> <span class="n">flow</span><span class="o">/</span><span class="n">gauss</span> <span class="n">xflag</span> <span class="n">yflag</span> <span class="n">zflag</span> <span class="n">keyword</span>
|
|
</pre></div>
|
|
</div>
|
|
<ul class="simple">
|
|
<li>ID, group-ID are documented in <a class="reference internal" href="fix.html"><span class="doc">fix</span></a> command</li>
|
|
<li>flow/gauss = style name of this fix command</li>
|
|
<li>xflag,yflag,zflag = 0 or 1</li>
|
|
</ul>
|
|
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="mi">0</span> <span class="o">=</span> <span class="n">do</span> <span class="ow">not</span> <span class="n">conserve</span> <span class="n">current</span> <span class="ow">in</span> <span class="n">this</span> <span class="n">dimension</span>
|
|
<span class="mi">1</span> <span class="o">=</span> <span class="n">conserve</span> <span class="n">current</span> <span class="ow">in</span> <span class="n">this</span> <span class="n">dimension</span>
|
|
</pre></div>
|
|
</div>
|
|
<ul class="simple">
|
|
<li>zero or more keyword/value pairs may be appended</li>
|
|
<li>keyword = <em>energy</em></li>
|
|
</ul>
|
|
<pre class="literal-block">
|
|
<em>energy</em> value = no or yes
|
|
no = do not compute work done by this fix
|
|
yes = compute work done by this fix
|
|
</pre>
|
|
</div>
|
|
<div class="section" id="examples">
|
|
<h2>Examples</h2>
|
|
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">fix</span> <span class="n">GD</span> <span class="n">fluid</span> <span class="n">flow</span><span class="o">/</span><span class="n">gauss</span> <span class="mi">1</span> <span class="mi">0</span> <span class="mi">0</span>
|
|
<span class="n">fix</span> <span class="n">GD</span> <span class="n">fluid</span> <span class="n">flow</span><span class="o">/</span><span class="n">gauss</span> <span class="mi">1</span> <span class="mi">1</span> <span class="mi">1</span> <span class="n">energy</span> <span class="n">yes</span>
|
|
</pre></div>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="description">
|
|
<h2>Description</h2>
|
|
<p>This fix implements the Gaussian dynamics (GD) method to simulate a
|
|
system at constant mass flux <a class="reference internal" href="#strong"><span class="std std-ref">(Strong)</span></a>. GD is a
|
|
nonequilibrium molecular dynamics simulation method that can be used
|
|
to study fluid flows through pores, pipes, and channels. In its
|
|
original implementation GD was used to compute the pressure required
|
|
to achieve a fixed mass flux through an opening. The flux can be
|
|
conserved in any combination of the directions, x, y, or z, using
|
|
xflag,yflag,zflag. This fix does not initialize a net flux through a
|
|
system, it only conserves the center-of-mass momentum that is present
|
|
when the fix is declared in the input script. Use the
|
|
<a class="reference internal" href="velocity.html"><span class="doc">velocity</span></a> command to generate an initial center-of-mass
|
|
momentum.</p>
|
|
<p>GD applies an external fluctuating gravitational field that acts as a
|
|
driving force to keep the system away from equilibrium. To maintain
|
|
steady state, a profile-unbiased thermostat must be implemented to
|
|
dissipate the heat that is added by the driving force. <a class="reference internal" href="compute_temp_profile.html"><span class="doc">Compute temp/profile</span></a> can be used to implement a
|
|
profile-unbiased thermostat.</p>
|
|
<p>A common use of this fix is to compute a pressure drop across a pipe,
|
|
pore, or membrane. The pressure profile can be computed in LAMMPS with
|
|
<a class="reference internal" href="compute_stress_atom.html"><span class="doc">compute stress/atom</span></a> and <a class="reference internal" href="fix_ave_chunk.html"><span class="doc">fix ave/chunk</span></a>, or with the hardy method in <a class="reference internal" href="fix_atc.html"><span class="doc">fix atc</span></a>. Note that the simple <a class="reference internal" href="compute_stress_atom.html"><span class="doc">compute stress/atom</span></a> method is only accurate away
|
|
from inhomogeneities in the fluid, such as fixed wall atoms. Further,
|
|
the computed pressure profile must be corrected for the acceleration
|
|
applied by GD before computing a pressure drop or comparing it to
|
|
other methods, such as the pump method <a class="reference internal" href="#zhu"><span class="std std-ref">(Zhu)</span></a>. The pressure
|
|
correction is discussed and described in <a class="reference internal" href="#strong"><span class="std std-ref">(Strong)</span></a>.</p>
|
|
<div class="admonition note">
|
|
<p class="first admonition-title">Note</p>
|
|
<p class="last">For a complete example including the considerations discussed
|
|
above, see the examples/USER/flow_gauss directory.</p>
|
|
</div>
|
|
<div class="admonition note">
|
|
<p class="first admonition-title">Note</p>
|
|
<p class="last">Only the flux of the atoms in group-ID will be conserved. If the
|
|
velocities of the group-ID atoms are coupled to the velocities of
|
|
other atoms in the simulation, the flux will not be conserved. For
|
|
example, in a simulation with fluid atoms and harmonically constrained
|
|
wall atoms, if a single thermostat is applied to group <em>all</em>, the
|
|
fluid atom velocities will be coupled to the wall atom velocities, and
|
|
the flux will not be conserved. This issue can be avoided by
|
|
thermostatting the fluid and wall groups separately.</p>
|
|
</div>
|
|
<p>Adding an acceleration to atoms does work on the system. This added
|
|
energy can be optionally subtracted from the potential energy for the
|
|
thermodynamic output (see below) to check that the timestep is small
|
|
enough to conserve energy. Since the applied acceleration is
|
|
fluctuating in time, the work cannot be computed from a potential. As
|
|
a result, computing the work is slightly more computationally
|
|
expensive than usual, so it is not performed by default. To invoke the
|
|
work calculation, use the <em>energy</em> keyword. The
|
|
<a class="reference internal" href="fix_modify.html"><span class="doc">fix_modify</span></a> <em>energy</em> option also invokes the work
|
|
calculation, and overrides an <em>energy no</em> setting here. If neither
|
|
<em>energy yes</em> or <em>fix_modify energy yes</em> are set, the global scalar
|
|
computed by the fix will return zero.</p>
|
|
<div class="admonition note">
|
|
<p class="first admonition-title">Note</p>
|
|
<p class="last">In order to check energy conservation, any other fixes that do
|
|
work on the system must have <em>fix_modify energy yes</em> set as well. This
|
|
includes thermostat fixes and any constraints that hold the positions
|
|
of wall atoms fixed, such as <a class="reference internal" href="fix_spring_self.html"><span class="doc">fix spring/self</span></a>.</p>
|
|
</div>
|
|
</div>
|
|
<hr class="docutils" />
|
|
<div class="section" id="restart-fix-modify-output-run-start-stop-minimize-info">
|
|
<h2>Restart, fix_modify, output, run start/stop, minimize info</h2>
|
|
<p>This fix is part of the USER-MISC package. It is only enabled if
|
|
LAMMPS was built with that package. See the <a class="reference internal" href="Section_start.html#start-3"><span class="std std-ref">Making LAMMPS</span></a> section for more info.</p>
|
|
<p>No information about this fix is written to <a class="reference internal" href="restart.html"><span class="doc">binary restart files</span></a>.</p>
|
|
<p>The <a class="reference internal" href="fix_modify.html"><span class="doc">fix_modify</span></a> <em>energy</em> option is supported by this
|
|
fix to subtract the work done from the
|
|
system’s potential energy as part of <a class="reference internal" href="thermo_style.html"><span class="doc">thermodynamic output</span></a>.</p>
|
|
<p>This fix computes a global scalar and a global 3-vector of forces,
|
|
which can be accessed by various <a class="reference internal" href="Section_howto.html#howto-15"><span class="std std-ref">output commands</span></a>. The scalar is the negative of the
|
|
work done on the system, see above discussion. The vector is the total force
|
|
that this fix applied to the group of atoms on the current timestep.
|
|
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 <a class="reference internal" href="run.html"><span class="doc">run</span></a> command.</p>
|
|
</div>
|
|
<div class="section" id="restrictions">
|
|
<h2>Restrictions</h2>
|
|
<blockquote>
|
|
<div>none</div></blockquote>
|
|
</div>
|
|
<div class="section" id="related-commands">
|
|
<h2>Related commands</h2>
|
|
<p><a class="reference internal" href="fix_addforce.html"><span class="doc">fix addforce</span></a>, <a class="reference internal" href="compute_temp_profile.html"><span class="doc">compute temp/profile</span></a>, <a class="reference internal" href="velocity.html"><span class="doc">velocity</span></a></p>
|
|
</div>
|
|
<div class="section" id="default">
|
|
<h2>Default</h2>
|
|
<p>The option default for the <em>energy</em> keyword is energy = no.</p>
|
|
<hr class="docutils" />
|
|
<p id="strong"><strong>(Strong)</strong> Strong and Eaves, J. Phys. Chem. Lett. 7, 1907 (2016).</p>
|
|
<p id="evans"><strong>(Evans)</strong> Evans and Morriss, Phys. Rev. Lett. 56, 2172 (1986).</p>
|
|
<p id="zhu"><strong>(Zhu)</strong> Zhu, Tajkhorshid, and Schulten, Biophys. J. 83, 154 (2002).</p>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
<footer>
|
|
|
|
|
|
<hr/>
|
|
|
|
<div role="contentinfo">
|
|
<p>
|
|
© Copyright 2013 Sandia Corporation.
|
|
</p>
|
|
</div>
|
|
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
|
|
|
|
</footer>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</section>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
var DOCUMENTATION_OPTIONS = {
|
|
URL_ROOT:'./',
|
|
VERSION:'',
|
|
COLLAPSE_INDEX:false,
|
|
FILE_SUFFIX:'.html',
|
|
HAS_SOURCE: true
|
|
};
|
|
</script>
|
|
<script type="text/javascript" src="_static/jquery.js"></script>
|
|
<script type="text/javascript" src="_static/underscore.js"></script>
|
|
<script type="text/javascript" src="_static/doctools.js"></script>
|
|
<script type="text/javascript" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
|
|
<script type="text/javascript" src="_static/sphinxcontrib-images/LightBox2/lightbox2/js/jquery-1.11.0.min.js"></script>
|
|
<script type="text/javascript" src="_static/sphinxcontrib-images/LightBox2/lightbox2/js/lightbox.min.js"></script>
|
|
<script type="text/javascript" src="_static/sphinxcontrib-images/LightBox2/lightbox2-customize/jquery-noconflict.js"></script>
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript" src="_static/js/theme.js"></script>
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
jQuery(function () {
|
|
SphinxRtdTheme.StickyNav.enable();
|
|
});
|
|
</script>
|
|
|
|
|
|
</body>
|
|
</html> |