Moving update/special/bonds into bond style to ensure correct fix ordering

This commit is contained in:
Joel Thomas Clemmer
2021-11-07 17:55:53 -07:00
parent f5626a2b9d
commit acb1c8e7f2
12 changed files with 161 additions and 152 deletions

View File

@ -243,7 +243,6 @@ OPT.
* :doc:`ttm/grid <fix_ttm>`
* :doc:`ttm/mod <fix_ttm>`
* :doc:`tune/kspace <fix_tune_kspace>`
* :doc:`update/special/bonds <fix_update_special_bonds>`
* :doc:`vector <fix_vector>`
* :doc:`viscosity <fix_viscosity>`
* :doc:`viscous <fix_viscous>`

View File

@ -26,37 +26,37 @@ preserved across run commands and is written to :doc:`binary restart files <rest
such that restarting the system will not reset the reference state of a bond.
As bonds can be broken between neighbor list builds, :doc:`special_bonds <special_bonds>`
work differently for BPM bond styles. There are two possible special
bond settings which determine how pair interactions work between bonded
particles. First, one can simply overlay pair interactions such that all
bonded particles also feel pair interactions. This can be accomplished by
simply turning off all special bonds by setting
.. code-block:: LAMMPS
special_bonds lj/coul 1 1 1
Alternatively, one can censor all pair interactions between bonded particles.
work differently for BPM bond styles. There are two possible settings
which determine how pair interactions work between bonded
particles.
First, one can censor all pair interactions between bonded particles.
Unlike :doc:`bond quartic <bond_quartic>`, this is not done by subtracting
pair forces during the bond computation but rather by dynamically updating
the special bond list. To do this, one must both define an instance of
:doc:`fix update/special/bonds <fix_update_special_bonds>` and have the special bond
settings
the special bond list. This is the default behavior of BPM bond styles
and is done by updating the 1-2 special bond list as bonds break.
To do this, LAMMPS requires :doc:`newton <newton>` bond off such that all
processors containing an atom know when a bond breaks. Additionally,
one must use the following special bond settings
.. code-block:: LAMMPS
special_bonds lj 0 1 1 coul 1 1 1
This fix ensures the 1-2 special bond list remains updated as bonds break. The fix
also requires :doc:`newton <newton>` bond off such that whena bond breaks between
atoms across multiple processors, all processors are aware of the event.
The special bond settings then accomplish two tasks. First, they turns off 1-3 and
These settings accomplish two goals. First, they turns off 1-3 and
1-4 special bond lists, which are not currently supported for BPMs. As BPMs often
have dense bond networks, generating 1-3 and 1-4 special bond lists is expensive.
By setting the lj weight for 1-2 bonds to zero, this censors pairwise interactions.
However, setting a nonzero coul weight for 1-2 bonds ensures all bonded
neighbors are included in the neighbor list. All bonded neighbors must be included
in neighbor lists as they could become unbonded at any timestep.
By setting a nonzero coul weight for 1-2 bonds ensures all bonded neighbors are
still included in the neighbor list in case bonds break between neighbor list builds.
Alternatively, one can simply overlay pair interactions such that all
bonded particles also feel pair interactions. This can be accomplished by
using the *overlay/pair* keyword in the bond settings and by
using the following special bond settings
.. code-block:: LAMMPS
special_bonds lj/coul 1 1 1
Currently there are two types of bonds included in this package. The first
bond style, :doc:`bond bpm/spring <bond_bpm_spring>`, only applies pairwise,

View File

@ -307,7 +307,6 @@ models for mesoscale simulations of solids and fracture. See the
* :doc:`bond_style bpm/spring <bond_bpm_spring>`
* :doc:`compute nbonds/atom <compute_nbonds_atom>`
* :doc:`fix nve/sphere/bpm <fix_nve_sphere_bpm>`
* :doc:`fix update/special/bonds <fix_update_special_bonds>`
* :doc:`pair_style bpm/spring <pair_bpm_spring>`
* examples/bpm

View File

@ -10,7 +10,7 @@ Syntax
bond_style bpm/rotational keyword value attribute1 attribute2 ...
* optional keyword = *store/local*
* optional keyword = *overlay/pair* or *store/local*
.. parsed-literal::
@ -121,10 +121,11 @@ or :doc:`read_restart <read_restart>` commands:
* :math:`\gamma_r` (distance*force/seconds/radians units)
* :math:`\gamma_t` (distance*force/seconds/radians units)
As bonds can be broken between neighbor list builds, particular
:doc:`special_bonds <special_bonds>` are required. See the `:doc: how to <Howto_BPM>`
page on BPMs or `:doc: fix update/special/bonds <fix_update_special_bonds>`
for details.
By default, pair forces are not calculated between bonded particles.
Pair forces can alternatively be overlaid on top of bond forces
using the *overlay/pair* keyword. These settings require specific
:doc:`special_bonds <special_bonds>` settings described in the restrictions.
Further details can be found in the `:doc: how to <Howto_BPM>` page on BPMs.
This bond style tracks broken bonds and can record them using an instance of
:doc:`fix store/local <fix_store_local>` if the *store/local* keyword is
@ -157,8 +158,18 @@ This bond style can only be used if LAMMPS was built with the BPM
package. See the :doc:`Build package <Build_package>` doc page for more
info.
The *bpm/rotational* style requires 1-3 and 1-4 :doc:`special_bonds <special_bonds>`
be turned off using the :doc:`special_bonds <special_bonds>` command.
By default if pair interactions are censored, this bond style requires setting
.. code-block:: LAMMPS
special_bonds lj 0 1 1 coul 1 1 1
and :doc:`newton <newton>` must be set to bond off.
If the *overlay/pair* option is used, this bond style alternatively requires setting
.. code-block:: LAMMPS
special_bonds lj/coul 1 1 1
The *bpm/rotational* style requires :doc:`atom style sphere/bpm <atom_style>`.

View File

@ -10,7 +10,7 @@ Syntax
bond_style bpm/spring keyword value attribute1 attribute2 ...
* optional keyword = *store/local*
* optional keyword = *overlay/pair* or *store/local*
.. parsed-literal::
@ -88,10 +88,11 @@ or :doc:`read_restart <read_restart>` commands:
* :math:`\epsilon_c` (unit less)
* :math:`\gamma` (force/velocity units)
As bonds can be broken between neighbor list builds, particular
:doc:`special_bonds <special_bonds>` are required. See the `:doc: how to <Howto_BPM>`
page on BPMs or `:doc: fix update/special/bonds <fix_update_special_bonds>`
for details.
By default, pair forces are not calculated between bonded particles.
Pair forces can alternatively be overlaid on top of bond forces
using the *overlay/pair* keyword. These settings require specific
:doc:`special_bonds <special_bonds>` settings described in the restrictions.
Further details can be found in the `:doc: how to <Howto_BPM>` page on BPMs.
This bond style tracks broken bonds and can record them using an instance of
:doc:`fix store/local <fix_store_local>` if the *store/local* keyword is
@ -124,8 +125,18 @@ This bond style can only be used if LAMMPS was built with the BPM
package. See the :doc:`Build package <Build_package>` doc page for more
info.
The *bpm/spring* style requires 1-3 and 1-4 :doc:`special_bonds <special_bonds>`
be turned off using the :doc:`special_bonds <special_bonds>` command.
By default if pair interactions are censored, this bond style requires setting
.. code-block:: LAMMPS
special_bonds lj 0 1 1 coul 1 1 1
and :doc:`newton <newton>` must be set to bond off.
If the *overlay/pair* option is used, this bond style alternatively requires setting
.. code-block:: LAMMPS
special_bonds lj/coul 1 1 1
Related commands
""""""""""""""""

View File

@ -1,55 +0,0 @@
.. index:: fix update/special/bonds
fix update/special/bonds command
======================
Syntax
""""""
.. parsed-literal::
fix ID group-ID update/special/bonds
* ID, group-ID are documented in :doc:`fix <fix>` command
* update/special/bonds = style name of this fix command
Examples
""""""""
.. code-block:: LAMMPS
fix 1 all update/special/bonds
Description
"""""""""""
This fix is used to update the 1-2 special bond list for BPM bond styles.
This feature is used to censor pair forces between bonded particles.
See the :doc:`BPM how to <Howto_bpm>` for more information.
----------
Restart, fix_modify, output, run start/stop, minimize info
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
No information about this fix is written to :doc:`binary restart files <restart>`. None of the :doc:`fix_modify <fix_modify>` options
are relevant to this fix. No global or per-atom quantities are stored
by this fix for access by various :doc:`output commands <Howto_output>`.
No parameter of this fix can be used with the *start/stop* keywords of
the :doc:`run <run>` command. This fix is not invoked during :doc:`energy minimization <minimize>`.
Restrictions
""""""""""""
This fix requires :doc:`newton <newton>` bond off.
Related commands
""""""""""""""""
:doc:`bond bpm/rotational <bond_bpm_rotational>`
Default
"""""""
none