Merge branch 'develop' of github.com:lammps/lammps into snap-inner-mod
This commit is contained in:
@ -21,12 +21,13 @@ Examples
|
||||
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
units real
|
||||
compute cos all viscosity/cos
|
||||
variable V equal c_cos[7]
|
||||
variable A equal 0.02E-5
|
||||
variable A equal 0.02E-5 # A/fs^2
|
||||
variable density equal density
|
||||
variable lz equal lz
|
||||
variable reciprocalViscosity equal v_V/${A}/v_density*39.4784/v_lz/v_lz*100
|
||||
variable reciprocalViscosity equal v_V/${A}/v_density*39.4784/v_lz/v_lz*100 # 1/(Pa*s)
|
||||
|
||||
Description
|
||||
"""""""""""
|
||||
|
||||
@ -13,7 +13,7 @@ Syntax
|
||||
|
||||
* ID, group-ID are documented in :doc:`fix <fix>` command
|
||||
* accelerate/cos = style name of this fix command
|
||||
* value = amplitude of acceleration (in unit of force/mass)
|
||||
* value = amplitude of acceleration (in unit of velocity/time)
|
||||
|
||||
|
||||
Examples
|
||||
|
||||
@ -25,7 +25,7 @@ Syntax
|
||||
f_ID = global scalar calculated by a fix with ID
|
||||
f_ID[I] = Ith component of global vector calculated by a fix with ID, I can include wildcard (see below)
|
||||
v_name = global value calculated by an equal-style variable with name
|
||||
v_name[I] = Ith component of a vector-style variable with name
|
||||
v_name[I] = Ith component of a vector-style variable with name, I can include wildcard (see below)
|
||||
|
||||
* zero or more keyword/arg pairs may be appended
|
||||
* keyword = *type* or *ave* or *start* or *prefactor* or *file* or *overwrite* or *title1* or *title2* or *title3*
|
||||
@ -105,20 +105,21 @@ individual fixes for info on which ones produce such values.
|
||||
ones that can be used with this fix. Variables of style *atom* cannot
|
||||
be used, since they produce per-atom values.
|
||||
|
||||
Note that for values from a compute or fix, the bracketed index I can
|
||||
be specified using a wildcard asterisk with the index to effectively
|
||||
specify multiple values. This takes the form "\*" or "\*n" or "n\*" or
|
||||
"m\*n". If N = the size of the vector (for *mode* = scalar) or the
|
||||
number of columns in the array (for *mode* = vector), then an asterisk
|
||||
with no numeric values means all indices from 1 to N. A leading
|
||||
asterisk means all indices from 1 to n (inclusive). A trailing
|
||||
asterisk means all indices from n to N (inclusive). A middle asterisk
|
||||
means all indices from m to n (inclusive).
|
||||
----------
|
||||
|
||||
For input values from a compute or fix or variable , the bracketed
|
||||
index I can be specified using a wildcard asterisk with the index to
|
||||
effectively specify multiple values. This takes the form "\*" or
|
||||
"\*n" or "n\*" or "m\*n". If N = the size of the vector, then an
|
||||
asterisk with no numeric values means all indices from 1 to N. A
|
||||
leading asterisk means all indices from 1 to n (inclusive). A
|
||||
trailing asterisk means all indices from n to N (inclusive). A middle
|
||||
asterisk means all indices from m to n (inclusive).
|
||||
|
||||
Using a wildcard is the same as if the individual elements of the
|
||||
vector had been listed one by one. E.g. these 2 fix ave/correlate
|
||||
commands are equivalent, since the :doc:`compute pressure <compute_pressure>` command creates a global vector with 6
|
||||
values.
|
||||
commands are equivalent, since the :doc:`compute pressure
|
||||
<compute_pressure>` command creates a global vector with 6 values.
|
||||
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
@ -128,6 +129,14 @@ values.
|
||||
c_myPress[1] c_myPress[2] c_myPress[3] &
|
||||
c_myPress[4] c_myPress[5] c_myPress[6]
|
||||
|
||||
.. note::
|
||||
|
||||
For a vector-style variable, only the wildcard forms "\*n" or
|
||||
"m\*n" are allowed. You must specify the upper bound, because
|
||||
vector-style variable lengths are not determined until the variable
|
||||
is evaluated. If n is specified larger than the vector length
|
||||
turns out to be, zeroes are output for missing vector values.
|
||||
|
||||
----------
|
||||
|
||||
The *Nevery*, *Nrepeat*, and *Nfreq* arguments specify on what
|
||||
|
||||
@ -32,7 +32,7 @@ Syntax
|
||||
f_ID = scalar or vector calculated by a fix with ID
|
||||
f_ID[I] = Ith component of vector or Ith column of array calculated by a fix with ID, I can include wildcard (see below)
|
||||
v_name = value(s) calculated by an equal-style or vector-style or atom-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name, I can include wildcard (see below)
|
||||
|
||||
* zero or more keyword/arg pairs may be appended
|
||||
* keyword = *mode* or *file* or *ave* or *start* or *beyond* or *overwrite* or *title1* or *title2* or *title3*
|
||||
@ -120,27 +120,6 @@ If *mode* = vector, then the input values must be vectors, or arrays
|
||||
with a bracketed term appended, indicating the Ith column of the array
|
||||
is used.
|
||||
|
||||
Note that for values from a compute or fix, the bracketed index I can
|
||||
be specified using a wildcard asterisk with the index to effectively
|
||||
specify multiple values. This takes the form "\*" or "\*n" or "n\*" or
|
||||
"m\*n". If N = the size of the vector (for *mode* = scalar) or the
|
||||
number of columns in the array (for *mode* = vector), then an asterisk
|
||||
with no numeric values means all indices from 1 to N. A leading
|
||||
asterisk means all indices from 1 to n (inclusive). A trailing
|
||||
asterisk means all indices from n to N (inclusive). A middle asterisk
|
||||
means all indices from m to n (inclusive).
|
||||
|
||||
Using a wildcard is the same as if the individual elements of the
|
||||
vector or columns of the array had been listed one by one. E.g. these
|
||||
2 fix ave/histo commands are equivalent, since the :doc:`compute com/chunk <compute_com_chunk>` command creates a global array with
|
||||
3 columns:
|
||||
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
compute myCOM all com/chunk
|
||||
fix 1 all ave/histo 100 1 100 -10.0 10.0 100 c_myCOM[*] file tmp1.com mode vector
|
||||
fix 2 all ave/histo 100 1 100 -10.0 10.0 100 c_myCOM[1] c_myCOM[2] c_myCOM[3] file tmp2.com mode vector
|
||||
|
||||
If the fix ave/histo/weight command is used, exactly two values must
|
||||
be specified. If the values are vectors, they must be the same
|
||||
length. The first value (a scalar or vector) is what is histogrammed
|
||||
@ -153,6 +132,38 @@ the first vector.
|
||||
|
||||
----------
|
||||
|
||||
For input values from a compute or fix or variable, the bracketed
|
||||
index I can be specified using a wildcard asterisk with the index to
|
||||
effectively specify multiple values. This takes the form "\*" or
|
||||
"\*n" or "n\*" or "m\*n". If N = the size of the vector (for *mode* =
|
||||
scalar) or the number of columns in the array (for *mode* = vector),
|
||||
then an asterisk with no numeric values means all indices from 1 to N.
|
||||
A leading asterisk means all indices from 1 to n (inclusive). A
|
||||
trailing asterisk means all indices from n to N (inclusive). A middle
|
||||
asterisk means all indices from m to n (inclusive).
|
||||
|
||||
Using a wildcard is the same as if the individual elements of the
|
||||
vector or columns of the array had been listed one by one. E.g. these
|
||||
2 fix ave/histo commands are equivalent, since the :doc:`compute
|
||||
com/chunk <compute_com_chunk>` command creates a global array with 3
|
||||
columns:
|
||||
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
compute myCOM all com/chunk
|
||||
fix 1 all ave/histo 100 1 100 -10.0 10.0 100 c_myCOM[*] file tmp1.com mode vector
|
||||
fix 2 all ave/histo 100 1 100 -10.0 10.0 100 c_myCOM[1] c_myCOM[2] c_myCOM[3] file tmp2.com mode vector
|
||||
|
||||
.. note::
|
||||
|
||||
For a vector-style variable, only the wildcard forms "\*n" or
|
||||
"m\*n" are allowed. You must specify the upper bound, because
|
||||
vector-style variable lengths are not determined until the variable
|
||||
is evaluated. If n is specified larger than the vector length
|
||||
turns out to be, zeroes are output for missing vector values.
|
||||
|
||||
----------
|
||||
|
||||
The *Nevery*, *Nrepeat*, and *Nfreq* arguments specify on what
|
||||
timesteps the input values will be used in order to contribute to the
|
||||
histogram. The final histogram is generated on timesteps that are
|
||||
|
||||
@ -25,7 +25,7 @@ Syntax
|
||||
f_ID = global scalar or vector calculated by a fix with ID
|
||||
f_ID[I] = Ith component of global vector or Ith column of global array calculated by a fix with ID, I can include wildcard (see below)
|
||||
v_name = value(s) calculated by an equal-style or vector-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name, I can include wildcard (see below)
|
||||
|
||||
* zero or more keyword/arg pairs may be appended
|
||||
* keyword = *mode* or *file* or *ave* or *start* or *off* or *overwrite* or *title1* or *title2* or *title3*
|
||||
@ -113,20 +113,23 @@ with a bracketed term appended, indicating the Ith column of the array
|
||||
is used. All vectors must be the same length, which is the length of
|
||||
the vector or number of rows in the array.
|
||||
|
||||
Note that for values from a compute or fix, the bracketed index I can
|
||||
be specified using a wildcard asterisk with the index to effectively
|
||||
specify multiple values. This takes the form "\*" or "\*n" or "n\*" or
|
||||
"m\*n". If N = the size of the vector (for *mode* = scalar) or the
|
||||
number of columns in the array (for *mode* = vector), then an asterisk
|
||||
with no numeric values means all indices from 1 to N. A leading
|
||||
asterisk means all indices from 1 to n (inclusive). A trailing
|
||||
asterisk means all indices from n to N (inclusive). A middle asterisk
|
||||
means all indices from m to n (inclusive).
|
||||
----------
|
||||
|
||||
For input values from a compute or fix or variable, the bracketed
|
||||
index I can be specified using a wildcard asterisk with the index to
|
||||
effectively specify multiple values. This takes the form "\*" or
|
||||
"\*n" or "n\*" or "m\*n". If N = the size of the vector (for *mode* =
|
||||
scalar) or the number of columns in the array (for *mode* = vector),
|
||||
then an asterisk with no numeric values means all indices from 1 to N.
|
||||
A leading asterisk means all indices from 1 to n (inclusive). A
|
||||
trailing asterisk means all indices from n to N (inclusive). A middle
|
||||
asterisk means all indices from m to n (inclusive).
|
||||
|
||||
Using a wildcard is the same as if the individual elements of the
|
||||
vector or columns of the array had been listed one by one. E.g. these
|
||||
2 fix ave/time commands are equivalent, since the :doc:`compute rdf <compute_rdf>` command creates, in this case, a global array
|
||||
with 3 columns, each of length 50:
|
||||
2 fix ave/time commands are equivalent, since the :doc:`compute rdf
|
||||
<compute_rdf>` command creates, in this case, a global array with 3
|
||||
columns, each of length 50:
|
||||
|
||||
.. code-block:: LAMMPS
|
||||
|
||||
@ -134,6 +137,14 @@ with 3 columns, each of length 50:
|
||||
fix 1 all ave/time 100 1 100 c_myRDF[*] file tmp1.rdf mode vector
|
||||
fix 2 all ave/time 100 1 100 c_myRDF[1] c_myRDF[2] c_myRDF[3] file tmp2.rdf mode vector
|
||||
|
||||
.. note::
|
||||
|
||||
For a vector-style variable, only the wildcard forms "\*n" or
|
||||
"m\*n" are allowed. You must specify the upper bound, because
|
||||
vector-style variable lengths are not determined until the variable
|
||||
is evaluated. If n is specified larger than the vector length
|
||||
turns out to be, zeroes are output for missing vector values.
|
||||
|
||||
----------
|
||||
|
||||
The *Nevery*, *Nrepeat*, and *Nfreq* arguments specify on what
|
||||
@ -169,9 +180,12 @@ asterisk to effectively specify multiple values.
|
||||
Note that there is a :doc:`compute reduce <compute_reduce>` command
|
||||
which can sum per-atom quantities into a global scalar or vector which
|
||||
can thus be accessed by fix ave/time. Or it can be a compute defined
|
||||
not in your input script, but by :doc:`thermodynamic output <thermo_style>` or other fixes such as :doc:`fix nvt <fix_nh>` or :doc:`fix temp/rescale <fix_temp_rescale>`. See
|
||||
the doc pages for these commands which give the IDs of these computes.
|
||||
Users can also write code for their own compute styles and :doc:`add them to LAMMPS <Modify>`.
|
||||
not in your input script, but by :doc:`thermodynamic output
|
||||
<thermo_style>` or other fixes such as :doc:`fix nvt <fix_nh>` or
|
||||
:doc:`fix temp/rescale <fix_temp_rescale>`. See the doc pages for
|
||||
these commands which give the IDs of these computes. Users can also
|
||||
write code for their own compute styles and :doc:`add them to LAMMPS
|
||||
<Modify>`.
|
||||
|
||||
If a value begins with "f\_", a fix ID must follow which has been
|
||||
previously defined in the input script. If *mode* = scalar, then if
|
||||
|
||||
@ -85,7 +85,7 @@ Syntax
|
||||
f_ID[I] = Ith component of global vector calculated by a fix with ID, I can include wildcard (see below)
|
||||
f_ID[I][J] = I,J component of global array calculated by a fix with ID
|
||||
v_name = value calculated by an equal-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name
|
||||
v_name[I] = value calculated by a vector-style variable with name, I can include wildcard (see below)
|
||||
|
||||
Examples
|
||||
""""""""
|
||||
@ -348,16 +348,15 @@ dimensions *lx*, *ly*, *lz*, *yz*, *xz*, *xy*\ .
|
||||
|
||||
----------
|
||||
|
||||
For output values from a compute or fix, the bracketed index I used to
|
||||
index a vector, as in *c_ID[I]* or *f_ID[I]*, can be specified
|
||||
using a wildcard asterisk with the index to effectively specify
|
||||
multiple values. This takes the form "\*" or "\*n" or "n\*" or "m\*n".
|
||||
If N = the size of the vector (for *mode* = scalar) or the number of
|
||||
columns in the array (for *mode* = vector), then an asterisk with no
|
||||
numeric values means all indices from 1 to N. A leading asterisk
|
||||
means all indices from 1 to n (inclusive). A trailing asterisk means
|
||||
all indices from n to N (inclusive). A middle asterisk means all
|
||||
indices from m to n (inclusive).
|
||||
For output values from a compute or fix or variable, the bracketed
|
||||
index I used to index a vector, as in *c_ID[I]* or *f_ID[I]* or
|
||||
*v_name[I]*, can be specified using a wildcard asterisk with the index
|
||||
to effectively specify multiple values. This takes the form "\*" or
|
||||
"\*n" or "n\*" or "m\*n". If N = the size of the vector, then an
|
||||
asterisk with no numeric values means all indices from 1 to N. A
|
||||
leading asterisk means all indices from 1 to n (inclusive). A
|
||||
trailing asterisk means all indices from n to N (inclusive). A middle
|
||||
asterisk means all indices from m to n (inclusive).
|
||||
|
||||
Using a wildcard is the same as if the individual elements of the
|
||||
vector had been listed one by one. E.g. these 2 thermo_style commands
|
||||
@ -372,6 +371,15 @@ creates a global vector with 6 values.
|
||||
c_myTemp[1] c_myTemp[2] c_myTemp[3] &
|
||||
c_myTemp[4] c_myTemp[5] c_myTemp[6]
|
||||
|
||||
|
||||
.. note::
|
||||
|
||||
For a vector-style variable, only the wildcard forms "\*n" or
|
||||
"m\*n" are allowed. You must specify the upper bound, because
|
||||
vector-style variable lengths are not determined until the variable
|
||||
is evaluated. If n is specified larger than the vector length
|
||||
turns out to be, zeroes are output for missing vector values.
|
||||
|
||||
----------
|
||||
|
||||
The *c_ID* and *c_ID[I]* and *c_ID[I][J]* keywords allow global values
|
||||
|
||||
Reference in New Issue
Block a user