Merge branch 'develop' into amoeba
This commit is contained in:
@ -276,10 +276,27 @@ Compilation of the plugin can be managed via both, CMake or traditional
|
||||
GNU makefiles. Some examples that can be used as a template are in the
|
||||
``examples/plugins`` folder. The CMake script code has some small
|
||||
adjustments to allow building the plugins for running unit tests with
|
||||
them. Another example that converts the KIM package into a plugin can be
|
||||
found in the ``examples/kim/plugin`` folder. No changes to the sources
|
||||
of the KIM package themselves are needed; only the plugin interface and
|
||||
loader code needs to be added. This example only supports building with
|
||||
CMake, but is probably a more typical example. To compile you need to
|
||||
run CMake with -DLAMMPS_SOURCE_DIR=<path/to/lammps/src/folder>. Other
|
||||
them.
|
||||
|
||||
Another example that converts the KIM package into a plugin can be found
|
||||
in the ``examples/kim/plugin`` folder. No changes to the sources of the
|
||||
KIM package themselves are needed; only the plugin interface and loader
|
||||
code needs to be added. This example only supports building with CMake,
|
||||
but is probably a more typical example. To compile you need to run CMake
|
||||
with -DLAMMPS_SOURCE_DIR=<path/to/lammps/src/folder>. Other
|
||||
configuration setting are identical to those for compiling LAMMPS.
|
||||
|
||||
A second example for a plugin from a package is in the
|
||||
``examples/PACKAGES/pace/plugin`` folder that will create a plugin from
|
||||
the ML-PACE package. In this case the bulk of the code is in a static
|
||||
external library that is being downloaded and compiled first and then
|
||||
combined with the pair style wrapper and the plugin loader. This
|
||||
example also contains a NSIS script that can be used to create an
|
||||
Installer package for Windows (the mutual licensing terms of the
|
||||
external library and LAMMPS conflict when distributing binaries, so the
|
||||
ML-PACE package cannot be linked statically, but the LAMMPS headers
|
||||
required to build the plugin are also available under a less restrictive
|
||||
license). This will automatically set the required environment variable
|
||||
and launching a (compatible) LAMMPS binary will load and register the
|
||||
plugin and the ML-PACE package can then be used as it was linked into
|
||||
LAMMPS.
|
||||
|
||||
@ -184,7 +184,7 @@ frame.
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
import re, yaml
|
||||
import yaml
|
||||
import pandas as pd
|
||||
|
||||
try:
|
||||
@ -193,7 +193,7 @@ frame.
|
||||
from yaml import SafeLoader as Loader
|
||||
|
||||
with open("ave.yaml") as f:
|
||||
ave = yaml.load(docs, Loader=Loader)
|
||||
ave = yaml.load(f, Loader=Loader)
|
||||
|
||||
keys = ave['keywords']
|
||||
df = {}
|
||||
|
||||
@ -676,7 +676,7 @@ advection-diffusion-reaction systems. The equations of motion of these
|
||||
DPD extensions are integrated through a modified velocity-Verlet (MVV)
|
||||
algorithm.
|
||||
|
||||
**Author:** Zhen Li (Division of Applied Mathematics, Brown University)
|
||||
**Author:** Zhen Li (Department of Mechanical Engineering, Clemson University)
|
||||
|
||||
**Supporting info:**
|
||||
|
||||
|
||||
@ -42,5 +42,4 @@ inaccurate relative timing data, because processors have to wait when
|
||||
communication occurs for other processors to catch up. Thus the
|
||||
reported times for "Communication" or "Other" may be higher than they
|
||||
really are, due to load-imbalance. If this is an issue, you can
|
||||
uncomment the MPI_Barrier() lines in src/timer.cpp, and re-compile
|
||||
LAMMPS, to obtain synchronized timings.
|
||||
use the :doc:`timer sync <timer>` command to obtain synchronized timings.
|
||||
|
||||
@ -95,7 +95,7 @@ Miscellaneous tools
|
||||
* :ref:`LAMMPS shell <lammps_shell>`
|
||||
* :ref:`LAMMPS magic patterns for file(1) <magic>`
|
||||
* :ref:`Offline build tool <offline>`
|
||||
* :ref:`singularity <singularity_tool>`
|
||||
* :ref:`singularity/apptainer <singularity_tool>`
|
||||
* :ref:`SWIG interface <swig>`
|
||||
* :ref:`vim <vim>`
|
||||
|
||||
@ -1007,14 +1007,15 @@ Ivanov, at University of Iceland (ali5 at hi.is).
|
||||
|
||||
.. _singularity_tool:
|
||||
|
||||
singularity tool
|
||||
----------------------------------------
|
||||
singularity/apptainer tool
|
||||
--------------------------
|
||||
|
||||
The singularity sub-directory contains container definitions files
|
||||
that can be used to build container images for building and testing
|
||||
LAMMPS on specific OS variants using the `Singularity <https://sylabs.io>`_
|
||||
container software. Contributions for additional variants are welcome.
|
||||
For more details please see the README.md file in that folder.
|
||||
The singularity sub-directory contains container definitions files that
|
||||
can be used to build container images for building and testing LAMMPS on
|
||||
specific OS variants using the `Apptainer <https://apptainer.org>`_ or
|
||||
`Singularity <https://sylabs.io>`_ container software. Contributions for
|
||||
additional variants are welcome. For more details please see the
|
||||
README.md file in that folder.
|
||||
|
||||
----------
|
||||
|
||||
|
||||
@ -35,16 +35,24 @@ Examples
|
||||
Description
|
||||
"""""""""""
|
||||
|
||||
Define a computation that calculates the local density and temperature
|
||||
for each atom and neighbors inside a spherical cutoff.
|
||||
Define a computation that calculates the local mass density and
|
||||
temperature for each atom based on its neighbors inside a spherical
|
||||
cutoff. If an atom has M neighbors, then its local mass density is
|
||||
calculated as the sum of its mass and its M neighbor masses, divided
|
||||
by the volume of the cutoff sphere (or circle in 2d). The local
|
||||
temperature of the atom is calculated as the temperature of the
|
||||
collection of M+1 atoms, after subtracting the center-of-mass velocity
|
||||
of the M+1 atoms from each of the M+1 atom's velocities. This is
|
||||
effectively the thermal velocity of the neighborhood of the central
|
||||
atom, similar to :doc:`compute temp/com <compute_temp_com>`.
|
||||
|
||||
The optional keyword *cutoff* defines the distance cutoff
|
||||
used when searching for neighbors. The default value is the cutoff
|
||||
specified by the pair style. If no pair style is defined, then a cutoff
|
||||
must be defined using this keyword. If the specified cutoff is larger than
|
||||
that of the pair_style plus neighbor skin (or no pair style is defined),
|
||||
the *comm_modify cutoff* option must also be set to match that of the
|
||||
*cutoff* keyword.
|
||||
The optional keyword *cutoff* defines the distance cutoff used when
|
||||
searching for neighbors. The default value is the cutoff specified by
|
||||
the pair style. If no pair style is defined, then a cutoff must be
|
||||
defined using this keyword. If the specified cutoff is larger than
|
||||
that of the pair_style plus neighbor skin (or no pair style is
|
||||
defined), the *comm_modify cutoff* option must also be set to match
|
||||
that of the *cutoff* keyword.
|
||||
|
||||
The neighbor list needed to compute this quantity is constructed each
|
||||
time the calculation is performed (i.e. each time a snapshot of atoms
|
||||
@ -55,16 +63,16 @@ too frequently.
|
||||
|
||||
If you have a bonded system, then the settings of
|
||||
:doc:`special_bonds <special_bonds>` command can remove pairwise
|
||||
interactions between atoms in the same bond, angle, or dihedral. This
|
||||
is the default setting for the :doc:`special_bonds <special_bonds>`
|
||||
command, and means those pairwise interactions do not appear in the
|
||||
neighbor list. Because this fix uses the neighbor list, it also means
|
||||
those pairs will not be included in the order parameter. This
|
||||
difficulty can be circumvented by writing a dump file, and using the
|
||||
:doc:`rerun <rerun>` command to compute the order parameter for
|
||||
snapshots in the dump file. The rerun script can use a
|
||||
:doc:`special_bonds <special_bonds>` command that includes all pairs in
|
||||
the neighbor list.
|
||||
interactions between atoms in the same bond, angle, or dihedral.
|
||||
This is the default setting for the :doc:`special_bonds
|
||||
<special_bonds>` command, and means those pairwise interactions do
|
||||
not appear in the neighbor list. Because this compute uses the
|
||||
neighbor list, it also means those pairs will not be included in
|
||||
the order parameter. This difficulty can be circumvented by
|
||||
writing a dump file, and using the :doc:`rerun <rerun>` command to
|
||||
compute the order parameter for snapshots in the dump file. The
|
||||
rerun script can use a :doc:`special_bonds <special_bonds>` command
|
||||
that includes all pairs in the neighbor list.
|
||||
|
||||
----------
|
||||
|
||||
@ -77,17 +85,20 @@ too frequently.
|
||||
Output info
|
||||
"""""""""""
|
||||
|
||||
This compute calculates a per-atom array with two columns: density and temperature.
|
||||
This compute calculates a per-atom array with two columns: mass
|
||||
density in density :doc:`units <units>` and temperature in temperature
|
||||
:doc:`units <units>`.
|
||||
|
||||
These values can be accessed by any command that uses per-atom values
|
||||
from a compute as input. See the :doc:`Howto output <Howto_output>` doc
|
||||
page for an overview of LAMMPS output options.
|
||||
from a compute as input. See the :doc:`Howto output <Howto_output>`
|
||||
doc page for an overview of LAMMPS output options.
|
||||
|
||||
Restrictions
|
||||
""""""""""""
|
||||
|
||||
This compute is part of the EXTRA-COMPUTE package. It is only enabled if
|
||||
LAMMPS was built with that package. See the :doc:`Build package <Build_package>` page for more info.
|
||||
This compute is part of the EXTRA-COMPUTE package. It is only enabled
|
||||
if LAMMPS was built with that package. See the :doc:`Build package
|
||||
<Build_package>` page for more info.
|
||||
|
||||
Related commands
|
||||
""""""""""""""""
|
||||
@ -97,5 +108,5 @@ Related commands
|
||||
Default
|
||||
"""""""
|
||||
|
||||
The option defaults are *cutoff* = pair style cutoff
|
||||
The option defaults are *cutoff* = pair style cutoff.
|
||||
|
||||
|
||||
@ -12,7 +12,6 @@ Syntax
|
||||
|
||||
* ID, group-ID are documented in :doc:`fix <fix>` command
|
||||
* mdi/aimd = style name of this fix command
|
||||
* optional keyword = *plugin*
|
||||
|
||||
Examples
|
||||
""""""""
|
||||
@ -20,7 +19,6 @@ Examples
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
fix 1 all mdi/aimd
|
||||
fix 1 all mdi/aimd plugin
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
@ -53,14 +51,6 @@ same time as LAMMPS, or as a plugin library. See the :doc:`mdi plugin
|
||||
Again, the examples/mdi/README file explains how to launch both driver
|
||||
and engine codes so that engine is used in plugin mode.
|
||||
|
||||
To use this fix with a plugin engine, you must specify the
|
||||
*plugin* keyword as the last argument, as illustrated above.
|
||||
|
||||
.. note::
|
||||
|
||||
As of April 2022, the *plugin* keyword is needed. In a future
|
||||
version of the MDI library it will no longer be necessary.
|
||||
|
||||
----------
|
||||
|
||||
This fix performs the timestepping portion of an AIMD simulation.
|
||||
|
||||
@ -129,8 +129,8 @@ Examples
|
||||
|
||||
kspace_style pppm 1.0e-4
|
||||
kspace_style pppm/cg 1.0e-5 1.0e-6
|
||||
kspace style msm 1.0e-4
|
||||
kspace style scafacos fmm 1.0e-4
|
||||
kspace_style msm 1.0e-4
|
||||
kspace_style scafacos fmm 1.0e-4
|
||||
kspace_style none
|
||||
|
||||
Used in input scripts:
|
||||
|
||||
@ -50,6 +50,12 @@ Examples
|
||||
pair_style hybrid/overlay e3b 1 lj/cut/tip4p/long 1 2 1 1 0.15 8.5
|
||||
pair_coeff * * e3b preset 2011
|
||||
|
||||
Used in example input script:
|
||||
|
||||
.. parsed-literal::
|
||||
|
||||
examples/PACKAGES/e3b/in.e3b-tip4p2005
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
|
||||
@ -68,21 +74,27 @@ The *e3b* style computes an \"explicit three-body\" (E3B) potential for water :r
|
||||
0 & r>R_f\\
|
||||
\end{cases}
|
||||
|
||||
This potential was developed as a water model that includes the three-body cooperativity of hydrogen bonding explicitly.
|
||||
To use it in this way, it must be applied in conjunction with a conventional two-body water model, through *pair_style hybrid/overlay*.
|
||||
The three body interactions are split into three types: A, B, and C.
|
||||
Type A corresponds to anti-cooperative double hydrogen bond donor interactions.
|
||||
Type B corresponds to the cooperative interaction of molecules that both donate and accept a hydrogen bond.
|
||||
Type C corresponds to anti-cooperative double hydrogen bond acceptor interactions.
|
||||
The three-body interactions are smoothly cutoff by the switching function s(r) between Rs and Rc3.
|
||||
The two-body interactions are designed to correct for the effective many-body interactions implicitly included in the conventional two-body potential.
|
||||
The two-body interactions are cut off sharply at Rc2, because K3 is typically significantly smaller than K2.
|
||||
See :ref:`(Kumar 2008) <Kumar>` for more details.
|
||||
This potential was developed as a water model that includes the
|
||||
three-body cooperativity of hydrogen bonding explicitly. To use it in
|
||||
this way, it must be applied in conjunction with a conventional two-body
|
||||
water model, through pair style :doc:`hybrid/overlay <pair_hybrid>`. The
|
||||
three body interactions are split into three types: A, B, and C. Type A
|
||||
corresponds to anti-cooperative double hydrogen bond donor interactions.
|
||||
Type B corresponds to the cooperative interaction of molecules that both
|
||||
donate and accept a hydrogen bond. Type C corresponds to
|
||||
anti-cooperative double hydrogen bond acceptor interactions. The
|
||||
three-body interactions are smoothly cutoff by the switching function
|
||||
s(r) between Rs and Rc3. The two-body interactions are designed to
|
||||
correct for the effective many-body interactions implicitly included in
|
||||
the conventional two-body potential. The two-body interactions are cut
|
||||
off sharply at Rc2, because K3 is typically significantly smaller than
|
||||
K2. See :ref:`(Kumar 2008) <Kumar>` for more details.
|
||||
|
||||
Only a single *pair_coeff* command is used with the *e3b* style.
|
||||
The first two arguments must be \* \*.
|
||||
The oxygen atom type for the pair style is passed as the only argument to the *pair_style* command, not in the *pair_coeff* command.
|
||||
The hydrogen atom type is inferred by the ordering of the atoms.
|
||||
Only a single :doc:`pair_coeff <pair_coeff>` command is used with the
|
||||
*e3b* style and the first two arguments must be \* \*. The oxygen atom
|
||||
type for the pair style is passed as the only argument to the
|
||||
*pair_style* command, not in the *pair_coeff* command. The hydrogen
|
||||
atom type is inferred from the ordering of the atoms.
|
||||
|
||||
.. note::
|
||||
|
||||
@ -90,26 +102,41 @@ The hydrogen atom type is inferred by the ordering of the atoms.
|
||||
Each water molecule must have consecutive IDs with the oxygen first.
|
||||
This pair style does not test that this criteria is met.
|
||||
|
||||
The *pair_coeff* command must have at least one keyword/value pair, as described above.
|
||||
The *preset* keyword sets the potential parameters to the values used in :ref:`(Tainter 2011) <Tainter2011>` or :ref:`(Tainter 2015) <Tainter2015>`.
|
||||
To use the water models defined in those references, the *e3b* style should always be used in conjunction with an *lj/cut/tip4p/long* style through *pair_style hybrid/overlay*, as demonstrated in the second example above.
|
||||
The *preset 2011* option should be used with the :doc:`TIP4P water model <Howto_tip4p>`.
|
||||
The *preset 2015* option should be used with the :doc:`TIP4P/2005 water model <Howto_tip4p>`.
|
||||
If the *preset* keyword is used, no other keyword is needed.
|
||||
Changes to the preset parameters can be made by specifying the *preset* keyword followed by the specific parameter to change, like *Ea*\ .
|
||||
Note that the other keywords must come after *preset* in the pair_style command.
|
||||
The *e3b* style can also be used to implement any three-body potential of the same form by specifying all the keywords except *neigh*\ : *Ea*, *Eb*, *Ec*, *E2*, *K3*, *K2*, *Rc3*, *Rc2*, *Rs*, and *bondL*\ .
|
||||
The keyword *bondL* specifies the intramolecular OH bond length of the water model being used.
|
||||
This is needed to include H atoms that are within the cutoff even when the attached oxygen atom is not.
|
||||
The *pair_coeff* command must have at least one keyword/value pair, as
|
||||
described above. The *preset* keyword sets the potential parameters to
|
||||
the values used in :ref:`(Tainter 2011) <Tainter2011>` or
|
||||
:ref:`(Tainter 2015) <Tainter2015>`. To use the water models defined in
|
||||
those references, the *e3b* style should always be used in conjunction
|
||||
with an *lj/cut/tip4p/long* style through *pair_style hybrid/overlay*,
|
||||
as demonstrated in the second example above. The *preset 2011* option
|
||||
should be used with the :doc:`TIP4P water model <Howto_tip4p>`. The
|
||||
*preset 2015* option should be used with the :doc:`TIP4P/2005 water
|
||||
model <Howto_tip4p>`. If the *preset* keyword is used, no other keyword
|
||||
is needed. Changes to the preset parameters can be made by specifying
|
||||
the *preset* keyword followed by the specific parameter to change, like
|
||||
*Ea*\ . Note that the other keywords must come after *preset* in the
|
||||
pair_style command. The *e3b* style can also be used to implement any
|
||||
three-body potential of the same form by specifying all the keywords
|
||||
except *neigh*\ : *Ea*, *Eb*, *Ec*, *E2*, *K3*, *K2*, *Rc3*, *Rc2*,
|
||||
*Rs*, and *bondL*\ . The keyword *bondL* specifies the intramolecular
|
||||
OH bond length of the water model being used. This is needed to include
|
||||
H atoms that are within the cutoff even when the attached oxygen atom is
|
||||
not.
|
||||
|
||||
This pair style allocates arrays sized according to the number of pairwise interactions within Rc3.
|
||||
To do this it needs an estimate for the number of water molecules within Rc3 of an oxygen atom.
|
||||
This estimate defaults to 10 and can be changed using the *neigh* keyword, which takes an integer as an argument.
|
||||
If the neigh setting is too small, the simulation will fail with the error "neigh is too small".
|
||||
If the neigh setting is too large, the pair style will use more memory than necessary.
|
||||
This pair style allocates arrays sized according to the number of
|
||||
pairwise interactions within Rc3. To do this it needs an estimate for
|
||||
the number of water molecules within Rc3 of an oxygen atom. This
|
||||
estimate defaults to 10 and can be changed using the *neigh* keyword,
|
||||
which takes an integer as an argument. If the neigh setting is too
|
||||
small, the simulation will fail with the error "neigh is too small". If
|
||||
the neigh setting is too large, the pair style will use more memory than
|
||||
necessary.
|
||||
|
||||
This pair style tallies a breakdown of the total E3B potential energy into sub-categories, which can be accessed via the :doc:`compute pair <compute_pair>` command as a vector of values of length 4.
|
||||
The 4 values correspond to the terms in the first equation above: the E2 term, the Ea term, the Eb term, and the Ec term.
|
||||
This pair style tallies a breakdown of the total E3B potential energy
|
||||
into sub-categories, which can be accessed via the :doc:`compute pair
|
||||
<compute_pair>` command as a vector of values of length 4. The 4 values
|
||||
correspond to the terms in the first equation above: the E2 term, the Ea
|
||||
term, the Eb term, and the Ec term.
|
||||
|
||||
See the examples/PACKAGES/e3b directory for a complete example script.
|
||||
|
||||
|
||||
@ -23,9 +23,9 @@ Examples
|
||||
|
||||
Used in example input script:
|
||||
|
||||
.. parsed-literal::
|
||||
.. parsed-literal::
|
||||
|
||||
examples/PACKAGES/manybody_table/in.spce_sw
|
||||
examples/PACKAGES/manybody_table/in.spce_sw
|
||||
|
||||
|
||||
Description
|
||||
|
||||
@ -27,10 +27,10 @@ Examples
|
||||
|
||||
Used in example input scripts:
|
||||
|
||||
.. parsed-literal::
|
||||
.. parsed-literal::
|
||||
|
||||
examples/PACKAGES/manybody_table/in.spce
|
||||
examples/PACKAGES/manybody_table/in.spce2
|
||||
examples/PACKAGES/manybody_table/in.spce
|
||||
examples/PACKAGES/manybody_table/in.spce2
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
|
||||
@ -56,7 +56,7 @@ Examples
|
||||
read_data ../run7/data.polymer.gz
|
||||
read_data data.protein fix mycmap crossterm CMAP
|
||||
read_data data.water add append offset 3 1 1 1 1 shift 0.0 0.0 50.0
|
||||
read_data data.water add merge 1 group solvent
|
||||
read_data data.water add merge group solvent
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
@ -622,6 +622,8 @@ of analysis.
|
||||
- atom-ID molecule-ID atom-type x y z
|
||||
* - charge
|
||||
- atom-ID atom-type q x y z
|
||||
* - dielectric
|
||||
- atom-ID atom-type q x y z normx normy normz area ed em epsilon curvature
|
||||
* - dipole
|
||||
- atom-ID atom-type q x y z mux muy muz
|
||||
* - dpd
|
||||
|
||||
@ -11,7 +11,6 @@ Syntax
|
||||
read_restart file flag
|
||||
|
||||
* file = name of binary restart file to read in
|
||||
* flag = remap (optional)
|
||||
|
||||
Examples
|
||||
""""""""
|
||||
@ -19,44 +18,40 @@ Examples
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
read_restart save.10000
|
||||
read_restart save.10000 remap
|
||||
read_restart restart.*
|
||||
read_restart restart.*.mpiio
|
||||
read_restart poly.*.% remap
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
|
||||
Read in a previously saved system configuration from a restart file.
|
||||
This allows continuation of a previous run. Details about what
|
||||
information is stored (and not stored) in a restart file is given
|
||||
below. Basically this operation will re-create the simulation box
|
||||
with all its atoms and their attributes as well as some related global
|
||||
settings, at the point in time it was written to the restart file by a
|
||||
previous simulation. The simulation box will be partitioned into a
|
||||
regular 3d grid of rectangular bricks, one per processor, based on the
|
||||
number of processors in the current simulation and the settings of the
|
||||
information is stored (and not stored) in a restart file is given below.
|
||||
Basically this operation will re-create the simulation box with all its
|
||||
atoms and their attributes as well as some related global settings, at
|
||||
the point in time it was written to the restart file by a previous
|
||||
simulation. The simulation box will be partitioned into a regular 3d
|
||||
grid of rectangular bricks, one per processor, based on the number of
|
||||
processors in the current simulation and the settings of the
|
||||
:doc:`processors <processors>` command. The partitioning can later be
|
||||
changed by the :doc:`balance <balance>` or :doc:`fix balance <fix_balance>` commands.
|
||||
|
||||
.. note::
|
||||
|
||||
Normally, restart files are written by the
|
||||
:doc:`restart <restart>` or :doc:`write_restart <write_restart>` commands
|
||||
so that all atoms in the restart file are inside the simulation box.
|
||||
If this is not the case, the read_restart command will print an error
|
||||
that atoms were "lost" when the file is read. This error should be
|
||||
reported to the LAMMPS developers so the invalid writing of the
|
||||
restart file can be fixed. If you still wish to use the restart file,
|
||||
the optional *remap* flag can be appended to the read_restart command.
|
||||
This should avoid the error, by explicitly remapping each atom back
|
||||
into the simulation box, updating image flags for the atom
|
||||
appropriately.
|
||||
changed by the :doc:`balance <balance>` or :doc:`fix balance
|
||||
<fix_balance>` commands.
|
||||
|
||||
Restart files are saved in binary format to enable exact restarts,
|
||||
meaning that the trajectories of a restarted run will precisely match
|
||||
those produced by the original run had it continued on.
|
||||
|
||||
The binary restart file format was not designed with backward, forward,
|
||||
or cross-platform compatibility in mind, so the files are only expected
|
||||
to be read correctly by the same LAMMPS executable on the same platform.
|
||||
Changes to the architecture, compilation settings, or LAMMPS version can
|
||||
render a restart file unreadable or it may read the data incorrectly.
|
||||
If you want a more portable format, you can use the data file format as
|
||||
created by the :doc:`write_data <write_data>` command. Binary restart
|
||||
files can also be converted into a data file from the command line by
|
||||
the LAMMPS executable that wrote them using the :ref:`-restart2data
|
||||
<restart2data>` command line flag.
|
||||
|
||||
Several things can prevent exact restarts due to round-off effects, in
|
||||
which case the trajectories in the 2 runs will slowly diverge. These
|
||||
include running on a different number of processors or changing
|
||||
@ -65,7 +60,8 @@ certain settings such as those set by the :doc:`newton <newton>` or
|
||||
these cases.
|
||||
|
||||
Certain fixes will not restart exactly, though they should provide
|
||||
statistically similar results. These include :doc:`fix shake <fix_shake>` and :doc:`fix langevin <fix_langevin>`.
|
||||
statistically similar results. These include :doc:`fix shake
|
||||
<fix_shake>` and :doc:`fix langevin <fix_langevin>`.
|
||||
|
||||
Certain pair styles will not restart exactly, though they should
|
||||
provide statistically similar results. This is because the forces
|
||||
@ -81,18 +77,19 @@ produced the restart file, it could be a LAMMPS bug, so consider
|
||||
:doc:`reporting it <Errors_bugs>` if you think the behavior is a bug.
|
||||
|
||||
Because restart files are binary, they may not be portable to other
|
||||
machines. In this case, you can use the :doc:`-restart command-line switch <Run_options>` to convert a restart file to a data file.
|
||||
machines. In this case, you can use the :doc:`-restart command-line
|
||||
switch <Run_options>` to convert a restart file to a data file.
|
||||
|
||||
Similar to how restart files are written (see the
|
||||
:doc:`write_restart <write_restart>` and :doc:`restart <restart>`
|
||||
commands), the restart filename can contain two wild-card characters.
|
||||
If a "\*" appears in the filename, the directory is searched for all
|
||||
filenames that match the pattern where "\*" is replaced with a timestep
|
||||
value. The file with the largest timestep value is read in. Thus,
|
||||
this effectively means, read the latest restart file. It's useful if
|
||||
you want your script to continue a run from where it left off. See
|
||||
the :doc:`run <run>` command and its "upto" option for how to specify
|
||||
the run command so it does not need to be changed either.
|
||||
Similar to how restart files are written (see the :doc:`write_restart
|
||||
<write_restart>` and :doc:`restart <restart>` commands), the restart
|
||||
filename can contain two wild-card characters. If a "\*" appears in the
|
||||
filename, the directory is searched for all filenames that match the
|
||||
pattern where "\*" is replaced with a timestep value. The file with the
|
||||
largest timestep value is read in. Thus, this effectively means, read
|
||||
the latest restart file. It's useful if you want your script to
|
||||
continue a run from where it left off. See the :doc:`run <run>` command
|
||||
and its "upto" option for how to specify the run command so it does not
|
||||
need to be changed either.
|
||||
|
||||
If a "%" character appears in the restart filename, LAMMPS expects a
|
||||
set of multiple files to exist. The :doc:`restart <restart>` and
|
||||
@ -222,17 +219,17 @@ its calculations in a consistent manner.
|
||||
|
||||
.. note::
|
||||
|
||||
There are a handful of commands which can be used before or
|
||||
between runs which may require a system initialization. Examples
|
||||
include the "balance", "displace_atoms", "delete_atoms", "set" (some
|
||||
options), and "velocity" (some options) commands. This is because
|
||||
they can migrate atoms to new processors. Thus they will also discard
|
||||
unused "state" information from fixes. You will know the discard has
|
||||
There are a handful of commands which can be used before or between
|
||||
runs which may require a system initialization. Examples include the
|
||||
"balance", "displace_atoms", "delete_atoms", "set" (some options),
|
||||
and "velocity" (some options) commands. This is because they can
|
||||
migrate atoms to new processors. Thus they will also discard unused
|
||||
"state" information from fixes. You will know the discard has
|
||||
occurred because a list of discarded fixes will be printed to the
|
||||
screen and log file, as explained above. This means that if you wish
|
||||
to retain that info in a restarted run, you must re-specify the
|
||||
relevant fixes and computes (which create fixes) before those commands
|
||||
are used.
|
||||
relevant fixes and computes (which create fixes) before those
|
||||
commands are used.
|
||||
|
||||
Some pair styles, like the :doc:`granular pair styles <pair_gran>`, also
|
||||
use a fix to store "state" information that persists from timestep to
|
||||
@ -245,18 +242,19 @@ LAMMPS allows bond interactions (angle, etc) to be turned off or
|
||||
deleted in various ways, which can affect how their info is stored in
|
||||
a restart file.
|
||||
|
||||
If bonds (angles, etc) have been turned off by the :doc:`fix shake <fix_shake>` or :doc:`delete_bonds <delete_bonds>` command,
|
||||
their info will be written to a restart file as if they are turned on.
|
||||
This means they will need to be turned off again in a new run after
|
||||
the restart file is read.
|
||||
If bonds (angles, etc) have been turned off by the :doc:`fix shake
|
||||
<fix_shake>` or :doc:`delete_bonds <delete_bonds>` command, their info
|
||||
will be written to a restart file as if they are turned on. This means
|
||||
they will need to be turned off again in a new run after the restart
|
||||
file is read.
|
||||
|
||||
Bonds that are broken (e.g. by a bond-breaking potential) are written
|
||||
to the restart file as broken bonds with a type of 0. Thus these
|
||||
bonds will still be broken when the restart file is read.
|
||||
|
||||
Bonds that have been broken by the :doc:`fix bond/break <fix_bond_break>` command have disappeared from the
|
||||
system. No information about these bonds is written to the restart
|
||||
file.
|
||||
Bonds that have been broken by the :doc:`fix bond/break
|
||||
<fix_bond_break>` command have disappeared from the system. No
|
||||
information about these bonds is written to the restart file.
|
||||
|
||||
----------
|
||||
|
||||
|
||||
Reference in New Issue
Block a user