From b5ef98cc22ea023579351a3c7fc2f1210f1801e3 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 1 Apr 2021 12:42:07 -0400 Subject: [PATCH] consolidate the documentation for lj/switch3/coulgauss/long and mm3/switch3/coulgauss/long into a single file --- doc/src/Commands_pair.rst | 2 +- doc/src/Packages_details.rst | 2 +- doc/src/pair_lj_switch3_coulgauss_long.rst | 55 +++++++++- doc/src/pair_mm3_switch3_coulgauss_long.rst | 109 -------------------- doc/src/pair_style.rst | 2 +- 5 files changed, 53 insertions(+), 117 deletions(-) delete mode 100644 doc/src/pair_mm3_switch3_coulgauss_long.rst diff --git a/doc/src/Commands_pair.rst b/doc/src/Commands_pair.rst index da403aa87e..080f3eff20 100644 --- a/doc/src/Commands_pair.rst +++ b/doc/src/Commands_pair.rst @@ -187,7 +187,7 @@ OPT. * :doc:`mgpt ` * :doc:`mie/cut (g) ` * :doc:`mliap ` - * :doc:`mm3/switch3/coulgauss/long ` + * :doc:`mm3/switch3/coulgauss/long ` * :doc:`momb ` * :doc:`morse (gkot) ` * :doc:`morse/smooth/linear (o) ` diff --git a/doc/src/Packages_details.rst b/doc/src/Packages_details.rst index e858593c4c..173c515fc2 100644 --- a/doc/src/Packages_details.rst +++ b/doc/src/Packages_details.rst @@ -2456,6 +2456,6 @@ which discuss the `QuickFF `_ methodology. * :doc:`bond_style mm3 ` * :doc:`improper_style distharm ` * :doc:`improper_style sqdistharm ` -* :doc:`pair_style mm3/switch3/coulgauss/long ` +* :doc:`pair_style mm3/switch3/coulgauss/long ` * :doc:`pair_style lj/switch3/coulgauss/long ` * examples/USER/yaff diff --git a/doc/src/pair_lj_switch3_coulgauss_long.rst b/doc/src/pair_lj_switch3_coulgauss_long.rst index f791b9836b..6b918c1071 100644 --- a/doc/src/pair_lj_switch3_coulgauss_long.rst +++ b/doc/src/pair_lj_switch3_coulgauss_long.rst @@ -1,8 +1,12 @@ .. index:: pair_style lj/switch3/coulgauss/long +.. index:: pair_style mm3/switch3/coulgauss/long pair_style lj/switch3/coulgauss/long command ============================================ +pair_style mm3/switch3/coulgauss/long command +============================================= + Syntax """""" @@ -10,7 +14,7 @@ Syntax pair_style style args -* style = *lj/switch3/coulgauss/long* +* style = *lj/switch3/coulgauss/long* or *mm3/switch3/coulgauss/long* * args = list of arguments for a particular style .. parsed-literal:: @@ -20,6 +24,11 @@ Syntax cutoff2 = global cutoff for Coulombic (optional) (distance units) width = width parameter of the smoothing function (distance units) + *mm3/switch3/coulgauss/long* args = cutoff (cutoff2) width + cutoff = global cutoff for MM3 (and Coulombic if only 1 arg) (distance units) + cutoff2 = global cutoff for Coulombic (optional) (distance units) + width = width parameter of the smoothing function (distance units) + Examples """""""" @@ -31,6 +40,12 @@ Examples pair_style lj/switch3/coulgauss/long 12.0 10.0 3.0 pair_coeff 1 0.2 2.5 1.2 + pair_style mm3/switch3/coulgauss/long 12.0 3.0 + pair_coeff 1 0.2 2.5 1.2 + + pair_style mm3/switch3/coulgauss/long 12.0 10.0 3.0 + pair_coeff 1 0.2 2.5 1.2 + Description """"""""""" @@ -41,8 +56,17 @@ vdW potential E = 4\epsilon \left[ \left(\frac{\sigma}{r}\right)^{12}-\left(\frac{\sigma}{r}\right)^{6} \right] -, which goes smoothly to zero at the cutoff r_c as defined -by the switching function +The *mm3/switch3/coulgauss/long* style evaluates the MM3 +vdW potential :ref:`(Allinger) ` + +.. math:: + + E & = \epsilon_{ij} \left[ -2.25 \left(\frac{r_{v,ij}}{r_{ij}}\right)^6 + 1.84(10)^5 \exp\left[-12.0 r_{ij}/r_{v,ij}\right] \right] S_3(r_{ij}) \\ + r_{v,ij} & = r_{v,i} + r_{v,j} \\ + \epsilon_{ij} & = \sqrt{\epsilon_i \epsilon_j} + +Both potentials go smoothly to zero at the cutoff r_c as defined by the +switching function .. math:: @@ -85,14 +109,35 @@ commands: Mixing, shift, table, tail correction, restart, rRESPA info """"""""""""""""""""""""""""""""""""""""""""""""""""""""""" +For atom type pairs I,J and I != J, the epsilon and sigma coefficients +and cutoff distance for all of the lj/long pair styles can be mixed. +The default mix value is *geometric*\ . See the "pair_modify" command +for details. + Shifting the potential energy is not necessary because the switching function ensures that the potential is zero at the cut-off. +These pair styles support the :doc:`pair_modify ` table and +options since they can tabulate the short-range portion of the +long-range Coulombic interactions. + +Thes pair styles do not support the :doc:`pair_modify ` +tail option for adding a long-range tail correction to the +Lennard-Jones portion of the energy and pressure. + +These pair styles write their information to :doc:`binary restart files `, so pair_style and pair_coeff commands do not need +to be specified in an input script that reads a restart file. + +These pair styles can only be used via the *pair* keyword of the +:doc:`run_style respa ` command. They do not support the +*inner*\ , *middle*\ , *outer* keywords. + Restrictions """""""""""" -These styles are part of the USER-YAFF package. They are only -enabled if LAMMPS was built with that package. See the :doc:`Build package ` doc page for more info. +These styles are part of the USER-YAFF package. They are only enabled +if LAMMPS was built with that package. See the :doc:`Build package +` doc page for more info. Related commands """""""""""""""" diff --git a/doc/src/pair_mm3_switch3_coulgauss_long.rst b/doc/src/pair_mm3_switch3_coulgauss_long.rst deleted file mode 100644 index 798df0bf7a..0000000000 --- a/doc/src/pair_mm3_switch3_coulgauss_long.rst +++ /dev/null @@ -1,109 +0,0 @@ -.. index:: pair_style mm3/switch3/coulgauss/long - -pair_style mm3/switch3/coulgauss/long command -============================================= - -Syntax -"""""" - -.. code-block:: LAMMPS - - pair_style style args - -* style = *mm3/switch3/coulgauss/long* -* args = list of arguments for a particular style - -.. parsed-literal:: - - *mm3/switch3/coulgauss/long* args = cutoff (cutoff2) width - cutoff = global cutoff for MM3 (and Coulombic if only 1 arg) (distance units) - cutoff2 = global cutoff for Coulombic (optional) (distance units) - width = width parameter of the smoothing function (distance units) - -Examples -"""""""" - -.. code-block:: LAMMPS - - pair_style mm3/switch3/coulgauss/long 12.0 3.0 - pair_coeff 1 0.2 2.5 1.2 - - pair_style mm3/switch3/coulgauss/long 12.0 10.0 3.0 - pair_coeff 1 0.2 2.5 1.2 - -Description -""""""""""" - -The *mm3/switch3/coulgauss/long* style evaluates the MM3 -vdW potential :ref:`(Allinger) ` - -.. math:: - - E & = \epsilon_{ij} \left[ -2.25 \left(\frac{r_{v,ij}}{r_{ij}}\right)^6 + 1.84(10)^5 \exp\left[-12.0 r_{ij}/r_{v,ij}\right] \right] S_3(r_{ij}) \\ - r_{v,ij} & = r_{v,i} + r_{v,j} \\ - \epsilon_{ij} & = \sqrt{\epsilon_i \epsilon_j} - -, which goes smoothly to zero at the cutoff r_c as defined -by the switching function - -.. math:: - - S_3(r) = \left\lbrace \begin{array}{ll} - 1 & \quad\mathrm{if}\quad r < r_\mathrm{c} - w \\ - 3x^2 - 2x^3 & \quad\mathrm{if}\quad r < r_\mathrm{c} \quad\mathrm{with\quad} x=\frac{r_\mathrm{c} - r}{w} \\ - 0 & \quad\mathrm{if}\quad r >= r_\mathrm{c} - \end{array} \right. - -where w is the width defined in the arguments. This potential -is combined with Coulomb interaction between Gaussian charge densities: - -.. math:: - - E = \frac{q_i q_j \mathrm{erf}\left( r/\sqrt{\gamma_1^2+\gamma_2^2} \right) }{\epsilon r_{ij}} - -where :math:`q_i` and :math:`q_j` are the charges on the 2 atoms, -epsilon is the dielectric constant which can be set by the -:doc:`dielectric ` command, ::math:`\gamma_i` and -:math:`\gamma_j` are the widths of the Gaussian charge distribution and -erf() is the error-function. This style has to be used in conjunction -with the :doc:`kspace_style ` command - -If one cutoff is specified it is used for both the vdW and Coulomb -terms. If two cutoffs are specified, the first is used as the cutoff -for the vdW terms, and the second is the cutoff for the Coulombic term. - -The following coefficients must be defined for each pair of atoms -types via the :doc:`pair_coeff ` command as in the examples -above, or in the data file or restart files read by the -:doc:`read_data ` or :doc:`read_restart ` -commands: - -* :math:`\epsilon` (energy) -* :math:`r_v` (distance) -* :math:`\gamma` (distance) - ----------- - -Mixing, shift, table, tail correction, restart, rRESPA info -""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" - -Mixing rules are fixed for this style as defined above. - -Shifting the potential energy is not necessary because the switching -function ensures that the potential is zero at the cut-off. - -Restrictions -"""""""""""" - -These styles are part of the USER-YAFF package. They are only -enabled if LAMMPS was built with that package. See the :doc:`Build package ` doc page for more info. - -Related commands -"""""""""""""""" - -:doc:`pair_coeff ` - -Default -""""""" - -none diff --git a/doc/src/pair_style.rst b/doc/src/pair_style.rst index fc66b778a1..89530895c4 100644 --- a/doc/src/pair_style.rst +++ b/doc/src/pair_style.rst @@ -250,7 +250,7 @@ accelerated styles exist. * :doc:`mgpt ` - simplified model generalized pseudopotential theory (MGPT) potential * :doc:`mesont/tpm ` - nanotubes mesoscopic force field * :doc:`mie/cut ` - Mie potential -* :doc:`mm3/switch3/coulgauss/long ` - smoothed MM3 vdW potential with Gaussian electrostatics +* :doc:`mm3/switch3/coulgauss/long ` - smoothed MM3 vdW potential with Gaussian electrostatics * :doc:`momb ` - Many-Body Metal-Organic (MOMB) force field * :doc:`morse ` - Morse potential * :doc:`morse/smooth/linear ` - linear smoothed Morse potential