git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@13812 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
sjplimp 2015-07-31 23:59:29 +00:00
parent 992d9ff3ea
commit 80a58bfc47
17 changed files with 158 additions and 113 deletions

View File

@ -287,7 +287,7 @@ can be enclosed in triple quotes, in which case “&” characters a
needed. For example:</p>
<div class="highlight-python"><div class="highlight"><pre>print &quot;Volume = $v&quot;
print &#39;Volume = $v&#39;
if &quot;$*steps* &gt; 1000&quot; then quit
if &quot;${steps} &gt; 1000&quot; then quit
variable a string &quot;red green blue &amp;
purple orange cyan&quot;
print &quot;&quot;&quot;
@ -891,10 +891,10 @@ KOKKOS, o = USER-OMP, t = OPT.</p>
<td><a class="reference internal" href="compute_reduce.html"><em>reduce</em></a></td>
<td><a class="reference internal" href="compute_reduce.html"><em>reduce/region</em></a></td>
<td><a class="reference internal" href="compute_slice.html"><em>slice</em></a></td>
<td><code class="xref doc docutils literal"><span class="pre">sna/atom</span></code></td>
<td><a class="reference internal" href="compute_sna_atom.html"><em>sna/atom</em></a></td>
</tr>
<tr class="row-odd"><td><code class="xref doc docutils literal"><span class="pre">snad/atom</span></code></td>
<td><code class="xref doc docutils literal"><span class="pre">snav/atom</span></code></td>
<tr class="row-odd"><td><a class="reference internal" href="compute_sna_atom.html"><em>snad/atom</em></a></td>
<td><a class="reference internal" href="compute_sna_atom.html"><em>snav/atom</em></a></td>
<td><a class="reference internal" href="compute_stress_atom.html"><em>stress/atom</em></a></td>
<td><a class="reference internal" href="compute_temp.html"><em>temp (c)</em></a></td>
<td><a class="reference internal" href="compute_temp_asphere.html"><em>temp/asphere</em></a></td>

View File

@ -164,7 +164,7 @@ needed. For example:
print "Volume = $v"
print 'Volume = $v'
if "${steps} > 1000" then quit
if "$\{steps\} > 1000" then quit
variable a string "red green blue &
purple orange cyan"
print """
@ -697,9 +697,9 @@ KOKKOS, o = USER-OMP, t = OPT.
"reduce"_compute_reduce.html,
"reduce/region"_compute_reduce.html,
"slice"_compute_slice.html,
"sna/atom"_compute_sna.html,
"snad/atom"_compute_sna.html,
"snav/atom"_compute_sna.html,
"sna/atom"_compute_sna_atom.html,
"snad/atom"_compute_sna_atom.html,
"snav/atom"_compute_sna_atom.html,
"stress/atom"_compute_stress_atom.html,
"temp (c)"_compute_temp.html,
"temp/asphere"_compute_temp_asphere.html,

View File

@ -337,8 +337,8 @@ described above.</p>
<p>If you set the paths to these files as environment variables, you only
have to do it once. For the csh or tcsh shells, add something like
this to your ~/.cshrc file, one line for each of the two files:</p>
<div class="highlight-python"><div class="highlight"><pre>setenv PYTHONPATH $*PYTHONPATH*:/home/sjplimp/lammps/python
setenv LD_LIBRARY_PATH $*LD_LIBRARY_PATH*:/home/sjplimp/lammps/src
<div class="highlight-python"><div class="highlight"><pre>setenv PYTHONPATH ${PYTHONPATH}:/home/sjplimp/lammps/python
setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/home/sjplimp/lammps/src
</pre></div>
</div>
<p>If you use the python/install.py script, you need to invoke it every

View File

@ -221,8 +221,8 @@ If you set the paths to these files as environment variables, you only
have to do it once. For the csh or tcsh shells, add something like
this to your ~/.cshrc file, one line for each of the two files:
setenv PYTHONPATH ${PYTHONPATH}:/home/sjplimp/lammps/python
setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/home/sjplimp/lammps/src :pre
setenv PYTHONPATH $\{PYTHONPATH\}:/home/sjplimp/lammps/python
setenv LD_LIBRARY_PATH $\{LD_LIBRARY_PATH\}:/home/sjplimp/lammps/src :pre
If you use the python/install.py script, you need to invoke it every
time you rebuild LAMMPS (as a shared library) or make changes to the

View File

@ -1169,13 +1169,13 @@ current version of the shared library is always available to programs
that use it.</p>
<p>For the csh or tcsh shells, you would add something like this to your
~/.cshrc file:</p>
<div class="highlight-python"><div class="highlight"><pre>setenv LD_LIBRARY_PATH $*LD_LIBRARY_PATH*:/home/sjplimp/lammps/src
<div class="highlight-python"><div class="highlight"><pre>setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/home/sjplimp/lammps/src
</pre></div>
</div>
</div>
<div class="section" id="calling-the-lammps-library">
<h3>2.5.4. <strong>Calling the LAMMPS library:</strong><a class="headerlink" href="#calling-the-lammps-library" title="Permalink to this headline"></a></h3>
<p>Either flavor of library (static or shared0 allows one or more LAMMPS
<p>Either flavor of library (static or shared) allows one or more LAMMPS
objects to be instantiated from the calling program.</p>
<p>When used from a C++ program, all of LAMMPS is wrapped in a LAMMPS_NS
namespace; you can safely use any of its classes and methods from

View File

@ -1130,11 +1130,11 @@ that use it.
For the csh or tcsh shells, you would add something like this to your
~/.cshrc file:
setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/home/sjplimp/lammps/src :pre
setenv LD_LIBRARY_PATH $\{LD_LIBRARY_PATH\}:/home/sjplimp/lammps/src :pre
[Calling the LAMMPS library:] :h5
Either flavor of library (static or shared0 allows one or more LAMMPS
Either flavor of library (static or shared) allows one or more LAMMPS
objects to be instantiated from the calling program.
When used from a C++ program, all of LAMMPS is wrapped in a LAMMPS_NS

View File

@ -322,9 +322,9 @@ are given in the compute section of <a class="reference internal" href="Section_
<li><a class="reference internal" href="compute_reduce.html"><em>reduce</em></a> - combine per-atom quantities into a single global value</li>
<li><a class="reference internal" href="compute_reduce.html"><em>reduce/region</em></a> - same as compute reduce, within a region</li>
<li><a class="reference internal" href="compute_slice.html"><em>slice</em></a> - extract values from global vector or array</li>
<li><code class="xref doc docutils literal"><span class="pre">sna/atom</span></code> - calculate bispectrum coefficients for each atom</li>
<li><code class="xref doc docutils literal"><span class="pre">snad/atom</span></code> - derivative of bispectrum coefficients for each atom</li>
<li><code class="xref doc docutils literal"><span class="pre">snav/atom</span></code> - virial contribution from bispectrum coefficients for each atom</li>
<li><a class="reference internal" href="compute_sna_atom.html"><em>sna/atom</em></a> - calculate bispectrum coefficients for each atom</li>
<li><a class="reference internal" href="compute_sna_atom.html"><em>snad/atom</em></a> - derivative of bispectrum coefficients for each atom</li>
<li><a class="reference internal" href="compute_sna_atom.html"><em>snav/atom</em></a> - virial contribution from bispectrum coefficients for each atom</li>
<li><a class="reference internal" href="compute_stress_atom.html"><em>stress/atom</em></a> - stress tensor for each atom</li>
<li><a class="reference internal" href="compute_temp.html"><em>temp</em></a> - temperature of group of atoms</li>
<li><a class="reference internal" href="compute_temp_asphere.html"><em>temp/asphere</em></a> - temperature of aspherical particles</li>

View File

@ -218,9 +218,9 @@ page"_Section_commands.html#cmd_5.
"reduce"_compute_reduce.html - combine per-atom quantities into a single global value
"reduce/region"_compute_reduce.html - same as compute reduce, within a region
"slice"_compute_slice.html - extract values from global vector or array
"sna/atom"_compute_sna.html - calculate bispectrum coefficients for each atom
"snad/atom"_compute_sna.html - derivative of bispectrum coefficients for each atom
"snav/atom"_compute_sna.html - virial contribution from bispectrum coefficients for each atom
"sna/atom"_compute_sna_atom.html - calculate bispectrum coefficients for each atom
"snad/atom"_compute_sna_atom.html - derivative of bispectrum coefficients for each atom
"snav/atom"_compute_sna_atom.html - virial contribution from bispectrum coefficients for each atom
"stress/atom"_compute_stress_atom.html - stress tensor for each atom
"temp"_compute_temp.html - temperature of group of atoms
"temp/asphere"_compute_temp_asphere.html - temperature of aspherical particles

View File

@ -206,11 +206,11 @@ as the following may be useful:</p>
velocity all create 600.0 8675309 mom yes rot yes dist gaussian
fix NVE all nve
fix TFIX all langevin 600.0 0.0 100 24601
fix REST all restrain dihedral 2 1 3 8 0.0 5000.0 $*angle1* dihedral 3 1 2 9 0.0 5000.0 $*angle2*
fix REST all restrain dihedral 2 1 3 8 0.0 5000.0 ${angle1} dihedral 3 1 2 9 0.0 5000.0 ${angle2}
fix_modify REST energy yes
run 10000
fix TFIX all langevin 0.0 0.0 100 24601
fix REST all restrain dihedral 2 1 3 8 5000.0 5000.0 $*angle1* dihedral 3 1 2 9 5000.0 5000.0 $*angle2*
fix REST all restrain dihedral 2 1 3 8 5000.0 5000.0 ${angle1} dihedral 3 1 2 9 5000.0 5000.0 ${angle2}
fix_modify REST energy yes
run 10000
# sanity check for convergence

View File

@ -85,11 +85,11 @@ as the following may be useful:
velocity all create 600.0 8675309 mom yes rot yes dist gaussian
fix NVE all nve
fix TFIX all langevin 600.0 0.0 100 24601
fix REST all restrain dihedral 2 1 3 8 0.0 5000.0 ${angle1} dihedral 3 1 2 9 0.0 5000.0 ${angle2}
fix REST all restrain dihedral 2 1 3 8 0.0 5000.0 $\{angle1\} dihedral 3 1 2 9 0.0 5000.0 $\{angle2\}
fix_modify REST energy yes
run 10000
fix TFIX all langevin 0.0 0.0 100 24601
fix REST all restrain dihedral 2 1 3 8 5000.0 5000.0 ${angle1} dihedral 3 1 2 9 5000.0 5000.0 ${angle2}
fix REST all restrain dihedral 2 1 3 8 5000.0 5000.0 $\{angle1\} dihedral 3 1 2 9 5000.0 5000.0 $\{angle2\}
fix_modify REST energy yes
run 10000
# sanity check for convergence

View File

@ -310,9 +310,40 @@ for applying weightings that change the strength of pairwise
interactions bewteen pairs of atoms that are also 1-2, 1-3, and 1-4
neighbors in the molecular bond topology, as normally set by the
<a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> command. Different weights can be
assigned to different pair hybrid sub-styles via the <a class="reference internal" href="pair_modify.html"><em>pair_modify special</em></a> command. This allows multiple force fields
to be used in a model of a hybrid system. See the
<a class="reference internal" href="pair_modify.html"><em>pair_modify</em></a> doc page for details.</p>
assigned to different pair hybrid sub-styles via the <a class="reference internal" href="pair_modify.html"><em>pair_modify special</em></a> command. This allows multiple force fields
to be used in a model of a hybrid system, however, there is no consistent
approach to determine parameters automatically for the interactions
between the two force fields, this is only recommended when particles
described by the different force fields do not mix.</p>
<p>Here is an example for mixing CHARMM and AMBER: The global <em>amber</em>
setting sets the 1-4 interactions to non-zero scaling factors and
then overrides them with 0.0 only for CHARMM:</p>
<div class="highlight-python"><div class="highlight"><pre>special_bonds amber
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0
</pre></div>
</div>
<p>The this input achieves the same effect:</p>
<div class="highlight-python"><div class="highlight"><pre>special_bonds 0.0 0.0 0.1
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/cut/coul/long special lj 0.0 0.0 0.5
pair_modify pair lj/cut/coul/long special coul 0.0 0.0 0.83333333
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0
</pre></div>
</div>
<p>Here is an example for mixing Tersoff with OPLS/AA based on
a data file that defines bonds for all atoms where for the
Tersoff part of the system the force constants for the bonded
interactions have been set to 0. Note the global settings are
effectively <em>lj/coul 0.0 0.0 0.5</em> as required for OPLS/AA:</p>
<div class="highlight-python"><div class="highlight"><pre>special_bonds lj/coul 1e-20 1e-20 0.5
pair_hybrid tersoff lj/cut/coul/long 12.0
pair_modify pair tersoff special lj/coul 1.0 1.0 1.0
</pre></div>
</div>
<p>See the <a class="reference internal" href="pair_modify.html"><em>pair_modify</em></a> doc page for details on
the specific syntax, requirements and restrictions.</p>
<hr class="docutils" />
<p>The potential energy contribution to the overall system due to an
individual sub-style can be accessed and output via the <a class="reference internal" href="compute_pair.html"><em>compute pair</em></a> command.</p>
<hr class="docutils" />

View File

@ -190,9 +190,42 @@ interactions bewteen pairs of atoms that are also 1-2, 1-3, and 1-4
neighbors in the molecular bond topology, as normally set by the
"special_bonds"_special_bonds.html command. Different weights can be
assigned to different pair hybrid sub-styles via the "pair_modify
special"_pair_modify.html command. This allows multiple force fields
to be used in a model of a hybrid system. See the
"pair_modify"_pair_modify.html doc page for details.
special"_pair_modify.html command. This allows multiple force fields
to be used in a model of a hybrid system, however, there is no consistent
approach to determine parameters automatically for the interactions
between the two force fields, this is only recommended when particles
described by the different force fields do not mix.
Here is an example for mixing CHARMM and AMBER: The global {amber}
setting sets the 1-4 interactions to non-zero scaling factors and
then overrides them with 0.0 only for CHARMM:
special_bonds amber
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0 :pre
The this input achieves the same effect:
special_bonds 0.0 0.0 0.1
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/cut/coul/long special lj 0.0 0.0 0.5
pair_modify pair lj/cut/coul/long special coul 0.0 0.0 0.83333333
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0 :pre
Here is an example for mixing Tersoff with OPLS/AA based on
a data file that defines bonds for all atoms where for the
Tersoff part of the system the force constants for the bonded
interactions have been set to 0. Note the global settings are
effectively {lj/coul 0.0 0.0 0.5} as required for OPLS/AA:
special_bonds lj/coul 1e-20 1e-20 0.5
pair_hybrid tersoff lj/cut/coul/long 12.0
pair_modify pair tersoff special lj/coul 1.0 1.0 1.0 :pre
See the "pair_modify"_pair_modify.html doc page for details on
the specific syntax, requirements and restrictions.
:line
The potential energy contribution to the overall system due to an
individual sub-style can be accessed and output via the "compute

View File

@ -133,15 +133,15 @@
</div>
<ul class="simple">
<li>one or more keyword/value pairs may be listed</li>
<li>keyword = <em>pair</em> or <em>special</em> or <em>shift</em> or <em>mix</em> or <em>table</em> or <em>table/disp</em> or <em>tabinner</em> or <em>tabinner/disp</em> or <em>tail</em> or <em>compute</em></li>
<li>keyword = <em>pair</em> or <em>shift</em> or <em>mix</em> or <em>table</em> or <em>table/disp</em> or <em>tabinner</em> or <em>tabinner/disp</em> or <em>tail</em> or <em>compute</em></li>
</ul>
<pre class="literal-block">
<em>pair</em> values = sub-style N special which w1 wt2 wt3
<em>pair</em> values = sub-style N <em>special</em> which wt1 wt2 wt3
sub-style = sub-style of <a class="reference internal" href="pair_hybrid.html"><em>pair hybrid</em></a>
N = which instance of sub-style (only if sub-style is used multiple times)
<em>special</em> values = flavor w1 w2 w3
flavor = <em>lj/coul</em> or <em>lj</em> or <em>coul</em>
w1,w2,w3 = weights from 0.0 to 1.0 inclusive
<em>special</em> which wt1 wt2 wt3 = override <em>special_bonds</em> settings (optional)
which = <em>lj/coul</em> or <em>lj</em> or <em>coul</em>
w1,w2,w3 = 1-2, 1-3, and 1-4 weights from 0.0 to 1.0 inclusive
<em>mix</em> value = <em>geometric</em> or <em>arithmetic</em> or <em>sixthpower</em>
<em>shift</em> value = <em>yes</em> or <em>no</em>
<em>table</em> value = N
@ -158,11 +158,11 @@
</div>
<div class="section" id="examples">
<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline"></a></h2>
<div class="highlight-python"><div class="highlight"><pre>pair_modify shift yes mix geometric
<p>pair_modify shift yes mix geometric
pair_modify tail yes
pair_modify table 12
</pre></div>
</div>
pair_modify pair lj/cut compute no
pair_modify pair lj/cut/coul/long 1 special lj/coul 0.0 0.0 0.0:pre</p>
</div>
<div class="section" id="description">
<h2>Description<a class="headerlink" href="#description" title="Permalink to this headline"></a></h2>
@ -179,12 +179,10 @@ number indicates which instance of the sub-style the remaining
keywords will be applied to. Note that if the <em>pair</em> keyword is not
used, and the pair style is <em>hybrid</em> or <em>hybrid/overlay</em>, then all the
specified keywords will be applied to all sub-styles.</p>
<p>If used, the <em>special</em> keyword must appear second in the list of
keywords, and must follow the <em>pair</em> keyword. Like the <em>pair</em>
keyword, it also can only be used with the <a class="reference internal" href="pair_hybrid.html"><em>hybrid and hybrid/overlay</em></a> pair styles. Its parameters are
similar to the <a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> command, and it
overrides the special_bond settings for the specified sub-style. More
details are given below.</p>
<p>The <em>special</em> keyword can only be used in conjunction with the <em>pair</em>
keyword and must directly follow it. It allows to override the
<a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> settings for the specified sub-style.
More details are given below.</p>
<p>The <em>mix</em> keyword affects pair coefficients for interactions between
atoms of type I and J, when I != J and the coefficients are not
explicitly set in the input script. Note that coefficients for I = J
@ -228,7 +226,7 @@ see the doc page for individual styles to see which potentials support
these options. If N is non-zero, a table of length 2^N is
pre-computed for forces and energies, which can shrink their
computational cost by up to a factor of 2. The table is indexed via a
bit-mapping technique <a class="reference internal" href="pair_table.html#wolff"><span>(Wolff)</span></a> and a linear interpolation is
bit-mapping technique <a class="reference internal" href="#wolff"><span>(Wolff)</span></a> and a linear interpolation is
performed between adjacent table values. In our experiments with
different table styles (lookup, linear, spline), this method typically
gave the best performance in terms of speed and accuracy.</p>
@ -319,37 +317,29 @@ pair style be defined.</p>
<hr class="docutils" />
<div class="section" id="use-of-special-keyword">
<h3>Use of <em>special</em> keyword<a class="headerlink" href="#use-of-special-keyword" title="Permalink to this headline"></a></h3>
<p>The <em>special</em> keyword requires 4 values similar to those specified
with the <a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> command, <em>flavor</em> and
w1,w2,w3. The <em>flavor</em> argument can be <em>lj</em> to change the
Lennard-Jones settings, <em>coul</em> to change the Coulombic settings, or
<em>lj/coul</em> to change both to the same set of 3 values. The w1,w2,w3
<p>The <em>special</em> keyword allows to override the 1-2, 1-3, and 1-4
exclusion settings for individual sub-styles of a
<a class="reference internal" href="pair_hybrid.html"><em>hybrid pair style</em></a>. It requires 4 arguments similar
to the <a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> command, <em>which</em> and
wt1,wt2,wt3. The <em>which</em> argument can be <em>lj</em> to change the
Lennard-Jones settings, <em>coul</em> to change the Coulombic settings,
or <em>lj/coul</em> to change both to the same set of 3 values. The wt1,wt2,wt3
values are numeric weights from 0.0 to 1.0 inclusive, for the 1-2,
1-3, and 1-4 bond topology neighbors. For example, these commands</p>
<div class="highlight-python"><div class="highlight"><pre>special_bonds lj/coul 0.0 0.0 0.1
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0
pair_modify pair lj/cut/coul/long special lj 0.0 0.0 0.5
pair_modify pair lj/cut/coul/long special coul 0.0 0.0 0.8333
</pre></div>
</div>
<p>show how to use both the CHARMM and AMBER force fields in a single
simulation. The first pair modify command sets the special bonds to
CHARMM values (all 0.0). The last 2 pair modify commands set the
standard AMBER values for LJ and Coulombic weights.</p>
1-3, and 1-4 bond topology neighbors, respectively. The <em>special</em>
keyword can only be used in conjunction with the <em>pair</em> keyword
and has to directly follow it.</p>
<div class="admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">The global settings specified by the
<a class="reference internal" href="special_bonds.html"><em>special_bonds</em></a> command affect the construction of
neighbor lists. Weights of 0.0 (for 1-2, 1-3, or 1-4 neighbors)
exclude those pairs from the neighbor list entirely. Weights of 1.0
store the neighbor with no weighting applied. The format of the
neighbor list cannot be changed by setting a sub-style weight to a
non-zero or non-one value. Thus an error is generated if the new
sub-style value is not 0.0 (or 1.0) when the global setting is 0.0 (or
1.0). Note that as in the example above, the global factor can simply
be set a value other than 0.0 or 1.0, then overridden by any of the
sub-styles with a value that is 0.0 or 1.0.</p>
store the neighbor with no weighting applied. Thus only global values
different from exactly 0.0 or 1.0 can be overridden and an error
is generated if the requested setting is not compatible with the
global setting. Substituting 1.0e-10 for 0.0 and 0.9999999999 for
1.0 is usually a sufficient workaround in this case without causing
a significant error.</p>
</div>
</div>
</div>

View File

@ -13,13 +13,13 @@ pair_modify command :h3
pair_modify keyword values ... :pre
one or more keyword/value pairs may be listed :ulb,l
keyword = {pair} or {special} or {shift} or {mix} or {table} or {table/disp} or {tabinner} or {tabinner/disp} or {tail} or {compute} :l
{pair} values = sub-style N special which w1 wt2 wt3
keyword = {pair} or {shift} or {mix} or {table} or {table/disp} or {tabinner} or {tabinner/disp} or {tail} or {compute} :l
{pair} values = sub-style N {special} which wt1 wt2 wt3
sub-style = sub-style of "pair hybrid"_pair_hybrid.html
N = which instance of sub-style (only if sub-style is used multiple times)
{special} values = flavor w1 w2 w3
flavor = {lj/coul} or {lj} or {coul}
w1,w2,w3 = weights from 0.0 to 1.0 inclusive
{special} which wt1 wt2 wt3 = override {special_bonds} settings (optional)
which = {lj/coul} or {lj} or {coul}
w1,w2,w3 = 1-2, 1-3, and 1-4 weights from 0.0 to 1.0 inclusive
{mix} value = {geometric} or {arithmetic} or {sixthpower}
{shift} value = {yes} or {no}
{table} value = N
@ -38,7 +38,9 @@ keyword = {pair} or {special} or {shift} or {mix} or {table} or {table/disp} or
pair_modify shift yes mix geometric
pair_modify tail yes
pair_modify table 12 :pre
pair_modify table 12
pair_modify pair lj/cut compute no
pair_modify pair lj/cut/coul/long 1 special lj/coul 0.0 0.0 0.0:pre
[Description:]
@ -58,13 +60,10 @@ keywords will be applied to. Note that if the {pair} keyword is not
used, and the pair style is {hybrid} or {hybrid/overlay}, then all the
specified keywords will be applied to all sub-styles.
If used, the {special} keyword must appear second in the list of
keywords, and must follow the {pair} keyword. Like the {pair}
keyword, it also can only be used with the "hybrid and
hybrid/overlay"_pair_hybrid.html pair styles. Its parameters are
similar to the "special_bonds"_special_bonds.html command, and it
overrides the special_bond settings for the specified sub-style. More
details are given below.
The {special} keyword can only be used in conjunction with the {pair}
keyword and must directly follow it. It allows to override the
"special_bonds"_special_bonds.html settings for the specified sub-style.
More details are given below.
The {mix} keyword affects pair coefficients for interactions between
atoms of type I and J, when I != J and the coefficients are not
@ -210,36 +209,28 @@ pair style be defined.
Use of {special} keyword :h5
The {special} keyword requires 4 values similar to those specified
with the "special_bonds"_special_bonds.html command, {flavor} and
w1,w2,w3. The {flavor} argument can be {lj} to change the
Lennard-Jones settings, {coul} to change the Coulombic settings, or
{lj/coul} to change both to the same set of 3 values. The w1,w2,w3
The {special} keyword allows to override the 1-2, 1-3, and 1-4
exclusion settings for individual sub-styles of a
"hybrid pair style"_pair_hybrid.html. It requires 4 arguments similar
to the "special_bonds"_special_bonds.html command, {which} and
wt1,wt2,wt3. The {which} argument can be {lj} to change the
Lennard-Jones settings, {coul} to change the Coulombic settings,
or {lj/coul} to change both to the same set of 3 values. The wt1,wt2,wt3
values are numeric weights from 0.0 to 1.0 inclusive, for the 1-2,
1-3, and 1-4 bond topology neighbors. For example, these commands
special_bonds lj/coul 0.0 0.0 0.1
pair_hybrid lj/charmm/coul/long 8.0 10.0 lj/cut/coul/long 10.0
pair_modify pair lj/charmm/coul/long special lj/coul 0.0 0.0 0.0
pair_modify pair lj/cut/coul/long special lj 0.0 0.0 0.5
pair_modify pair lj/cut/coul/long special coul 0.0 0.0 0.8333 :pre
show how to use both the CHARMM and AMBER force fields in a single
simulation. The first pair modify command sets the special bonds to
CHARMM values (all 0.0). The last 2 pair modify commands set the
standard AMBER values for LJ and Coulombic weights.
1-3, and 1-4 bond topology neighbors, respectively. The {special}
keyword can only be used in conjunction with the {pair} keyword
and has to directly follow it.
IMPORTANT NOTE: The global settings specified by the
"special_bonds"_special_bonds.html command affect the construction of
neighbor lists. Weights of 0.0 (for 1-2, 1-3, or 1-4 neighbors)
exclude those pairs from the neighbor list entirely. Weights of 1.0
store the neighbor with no weighting applied. The format of the
neighbor list cannot be changed by setting a sub-style weight to a
non-zero or non-one value. Thus an error is generated if the new
sub-style value is not 0.0 (or 1.0) when the global setting is 0.0 (or
1.0). Note that as in the example above, the global factor can simply
be set a value other than 0.0 or 1.0, then overridden by any of the
sub-styles with a value that is 0.0 or 1.0.
store the neighbor with no weighting applied. Thus only global values
different from exactly 0.0 or 1.0 can be overridden and an error
is generated if the requested setting is not compatible with the
global setting. Substituting 1.0e-10 for 0.0 and 0.9999999999 for
1.0 is usually a sufficient workaround in this case without causing
a significant error.
:line

View File

@ -184,7 +184,7 @@ def loop(lmpptr,N,cut0):
<div class="highlight-python"><div class="highlight"><pre> for i in range(N):
cut = cut0 + i*0.1
lmp.set_variable(&quot;cut&quot;,cut) # set a variable in LAMMPS
lmp.command(&quot;pair_style lj/cut $*cut*&quot;) # LAMMPS commands
lmp.command(&quot;pair_style lj/cut ${cut}&quot;) # LAMMPS commands
lmp.command(&quot;pair_coeff * * 1.0 1.0&quot;)
lmp.command(&quot;run 100&quot;)
&quot;&quot;&quot;
@ -429,7 +429,7 @@ which loads and runs the following function from examples/python/funcs.py:</p>
</pre></div>
</div>
<div class="highlight-python"><div class="highlight"><pre><span class="n">lmp</span><span class="o">.</span><span class="n">set_variable</span><span class="p">(</span><span class="s">&quot;cut&quot;</span><span class="p">,</span><span class="n">cut</span><span class="p">)</span> <span class="c"># set a variable in LAMMPS</span>
<span class="n">lmp</span><span class="o">.</span><span class="n">command</span><span class="p">(</span><span class="s">&quot;pair_style lj/cut $*cut*&quot;</span><span class="p">)</span> <span class="c"># LAMMPS command</span>
<span class="n">lmp</span><span class="o">.</span><span class="n">command</span><span class="p">(</span><span class="s">&quot;pair_style lj/cut ${cut}&quot;</span><span class="p">)</span> <span class="c"># LAMMPS command</span>
<span class="c">#lmp.command(&quot;pair_style lj/cut %d&quot; % cut) # LAMMPS command option</span>
</pre></div>
</div>

View File

@ -58,7 +58,7 @@ def loop(lmpptr,N,cut0):
for i in range(N):
cut = cut0 + i*0.1
lmp.set_variable("cut",cut) # set a variable in LAMMPS
lmp.command("pair_style lj/cut ${cut}") # LAMMPS commands
lmp.command("pair_style lj/cut $\{cut\}") # LAMMPS commands
lmp.command("pair_coeff * * 1.0 1.0")
lmp.command("run 100")
""" :pre
@ -326,7 +326,7 @@ def loop(N,cut0,thresh,lmpptr):
cut = cut0 + i*0.1 :pre
lmp.set_variable("cut",cut) # set a variable in LAMMPS
lmp.command("pair_style lj/cut ${cut}") # LAMMPS command
lmp.command("pair_style lj/cut $\{cut\}") # LAMMPS command
#lmp.command("pair_style lj/cut %d" % cut) # LAMMPS command option :pre
lmp.command("pair_coeff * * 1.0 1.0") # ditto

File diff suppressed because one or more lines are too long