diff --git a/doc/src/Commands_fix.rst b/doc/src/Commands_fix.rst index 8b47325f02..d5cfdf4ef4 100644 --- a/doc/src/Commands_fix.rst +++ b/doc/src/Commands_fix.rst @@ -148,6 +148,7 @@ OPT. * :doc:`oneway ` * :doc:`orient/bcc ` * :doc:`orient/fcc ` + * :doc:`orient/eco ` * :doc:`phonon ` * :doc:`pimd ` * :doc:`planeforce ` diff --git a/doc/src/fix_bond_create.rst b/doc/src/fix_bond_create.rst index fab5d6f0f0..5e42ab832d 100644 --- a/doc/src/fix_bond_create.rst +++ b/doc/src/fix_bond_create.rst @@ -20,7 +20,7 @@ Syntax * bondtype = type of created bonds * zero or more keyword/value pairs may be appended to args * keyword = *iparam* or *jparam* or *prob* or *atype* or *dtype* or *itype* or *aconstrain* - + .. parsed-literal:: *iparam* values = maxbond, newtype @@ -117,15 +117,15 @@ and 1.0. A uniform random number between 0.0 and 1.0 is generated and the eligible bond is only created if the random number < fraction. The *aconstrain* keyword allows to specify a minimal and maximal angle -*amin* and *amax* between the two prospective bonding partners and a -third particle that is already bonded to one of the two partners. -Such a criterion can be important, for instance when new angle -potentials are simultaneously introduced after the formation of the -new bond. Without a restriction on the permissible angle, and for -stiffer angle potentials very large energies can arise and lead to +*amin* and *amax* between the two prospective bonding partners and a +third particle that is already bonded to one of the two partners. +Such a criterion can be important, for instance when new angle +potentials are simultaneously introduced after the formation of the +new bond. Without a restriction on the permissible angle, and for +stiffer angle potentials very large energies can arise and lead to uncontrolled behavior. -Any bond that is created is assigned a bond type of *bondtype*. +Any bond that is created is assigned a bond type of *bondtype* When a bond is created, data structures within LAMMPS that store bond topology are updated to reflect the creation. If the bond is part of @@ -169,13 +169,13 @@ of type *angletype*\ , with parameters assigned by the corresponding .. note:: LAMMPS stores and maintains a data structure with a list of the - 1st, 2nd, and 3rd neighbors of each atom (within the bond topology of + first, second, and third neighbors of each atom (within the bond topology of the system) for use in weighting pairwise interactions for bonded - atoms. Note that adding a single bond always adds a new 1st neighbor - but may also induce \*many\* new 2nd and 3rd neighbors, depending on the + atoms. Note that adding a single bond always adds a new first neighbor + but may also induce \*many\* new second and third neighbors, depending on the molecular topology of your system. The "extra special per atom" parameter must typically be set to allow for the new maximum total - size (1st + 2nd + 3rd neighbors) of this per-atom list. There are 2 + size (first + second + third neighbors) of this per-atom list. There are 2 ways to do this. See the :doc:`read_data ` or :doc:`create_box ` commands for details. @@ -187,12 +187,12 @@ of type *angletype*\ , with parameters assigned by the corresponding considered for pairwise interactions, using the weighting rules set by the :doc:`special_bonds ` command. Consider a new bond created between atoms I,J. If J has a bonded neighbor K, then K - becomes a 2nd neighbor of I. Even if the *atype* keyword is not used + becomes a second neighbor of I. Even if the *atype* keyword is not used to create angle I-J-K, the pairwise interaction between I and K will be potentially turned off or weighted by the 1-3 weighting specified by the :doc:`special_bonds ` command. This is the case even if the "angle yes" option was used with that command. The same - is true for 3rd neighbors (1-4 interactions), the *dtype* keyword, and + is true for third neighbors (1-4 interactions), the *dtype* keyword, and the "dihedral yes" option used with the :doc:`special_bonds ` command. @@ -252,12 +252,12 @@ Restrictions """""""""""" This fix is part of the MC package. It is only enabled if LAMMPS was -built with that package. See the :doc:`Build package ` doc page for more info. +built with that package. See the :doc:`Build package ` +doc page for more info. -The *aconstrain* keyword is only available +The *aconstrain* keyword is only available when LAMMPS was built with the FixBondCreateAngle class. - Related commands """""""""""""""" diff --git a/src/MC/fix_bond_create.cpp b/src/MC/fix_bond_create.cpp index b862f4bf44..0647bfc0e6 100644 --- a/src/MC/fix_bond_create.cpp +++ b/src/MC/fix_bond_create.cpp @@ -125,16 +125,18 @@ FixBondCreate::FixBondCreate(LAMMPS *lmp, int narg, char **arg) : itype = force->inumeric(FLERR,arg[iarg+1]); if (itype < 0) error->all(FLERR,"Illegal fix bond/create command"); iarg += 2; - } else if (strcmp(arg[iarg],"aconstrain") == 0) { - if (iarg+3 > narg) error->all(FLERR,"Illegal fix bond/create command"); + } else if (strcmp(arg[iarg],"aconstrain") == 0 && + strcmp(arg[2],"bond/create/angle") == 0) { + if (iarg+3 > narg) + error->all(FLERR,"Illegal fix bond/create/angle command"); amin = force->numeric(FLERR,arg[iarg+1]); amax = force->inumeric(FLERR,arg[iarg+2]); if (amin >= amax) - error->all(FLERR,"Illegal fix bond/create command"); + error->all(FLERR,"Illegal fix bond/create/angle command"); if (amin < 0 || amin > 180) - error->all(FLERR,"Illegal fix bond/create command"); + error->all(FLERR,"Illegal fix bond/create/angle command"); if (amax < 0 || amax > 180) - error->all(FLERR,"Illegal fix bond/create command"); + error->all(FLERR,"Illegal fix bond/create/angle command"); amin = (3.14159265358979323846/180.0) * amin; amax = (3.14159265358979323846/180.0) * amax; constrainflag = 1;