Skip to content

Commit

Permalink
fix errors in fix amoeba/pitorsion doc page
Browse files Browse the repository at this point in the history
  • Loading branch information
sjplimp committed Jun 21, 2024
1 parent 8ce284f commit 6b42545
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 20 deletions.
23 changes: 14 additions & 9 deletions doc/src/fix_amoeba_bitorsion.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,11 @@ the implementation of AMOEBA and HIPPO in LAMMPS.

Bitorsion interactions add additional potential energy contributions
to pairs of overlapping phi-psi dihedrals of amino-acids, which are
important to properly represent their conformational behavior.
important to properly represent their conformational behavior. Each
bitorsion interaction is thus defined for a 5-tuple of atoms
:math:`IJKLM` with bonds between successive atoms in the list,
i.e. two overlapping dihedral interactions for atoms :math:`IJKL` and
:math:`JKLM`.

The examples/amoeba directory has a sample input script and data file
for ubiquitin, which illustrates use of the fix amoeba/bitorsion
Expand Down Expand Up @@ -68,14 +72,15 @@ lines:
[...]
N 3 314 315 317 318 330
The first column is an index from 1 to :math:`N` to enumerate the bitorsion
5-atom tuples; it is ignored by LAMMPS. The second column is the
*type* of the interaction; it is an index into the bitorsion force
field file. The remaining 5 columns are the atom IDs of the atoms in
the two 4-atom dihedrals that overlap to create the bitorsion 5-body
interaction. Note that the *bitorsions* and *BiTorsions* keywords for
the header and body sections match those specified in the
:doc:`read_data <read_data>` command following the data file name.
The first column is an index from 1 to :math:`N` to enumerate the
bitorsion 5-atom tuples; it is ignored by LAMMPS. The second column
is the *type* of the interaction; it is an index into the bitorsion
force field file. The remaining 5 columns are the atom IDs of the
atoms (in order) for the 5-tuple :math:`IJKLM`, as described above.

Note that the *bitorsions* and *BiTorsions* keywords for the header
and body sections match those specified in the :doc:`read_data
<read_data>` command following the data file name.

The data file should be generated by using the
tools/tinker/tinker2lmp.py conversion script which creates a LAMMPS
Expand Down
17 changes: 8 additions & 9 deletions doc/src/fix_amoeba_pitorsion.rst
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ should have two lines like these in its header section:
M pitorsion types
N pitorsions
where :math:`N` is the number of pitorsion 5-body interactions and :math:`M` is
where :math:`N` is the number of pitorsion 6-body interactions and :math:`M` is
the number of pitorsion types. It should also have two sections in the body
of the data file like these with :math:`M` and :math:`N` lines each:

Expand All @@ -79,16 +79,15 @@ of the data file like these with :math:`M` and :math:`N` lines each:
[...]
N 3 314 315 317 318 330
For PiTorsion Coeffs, the first column is an index from 1 to :math:`M` to
enumerate the pitorsion types. The second column is the single
For PiTorsion Coeffs, the first column is an index from 1 to :math:`M`
to enumerate the pitorsion types. The second column is the single
prefactor coefficient needed for each type.

For PiTorsions, the first column is an index from 1 to :math:`N` to enumerate
the pitorsion 5-atom tuples; it is ignored by LAMMPS. The second
column is the "type" of the interaction; it is an index into the
PiTorsion Coeffs. The remaining 5 columns are the atom IDs of the
atoms in the two 4-atom dihedrals that overlap to create the pitorsion
5-body interaction.
For PiTorsions, the first column is an index from 1 to :math:`N` to
enumerate the pitorsion 6-atom tuples; it is ignored by LAMMPS. The
second column is the "type" of the interaction; it is an index into
the PiTorsion Coeffs. The remaining 6 columns are the atom IDs of the
atoms (in order) for the 6-tuple :math:`IJKLMN`, as described above.

Note that the *pitorsion types* and *pitorsions* and *PiTorsion
Coeffs* and *PiTorsions* keywords for the header and body sections of
Expand Down
4 changes: 2 additions & 2 deletions tools/tinker/tinker2lmp.py
Original file line number Diff line number Diff line change
Expand Up @@ -923,7 +923,7 @@ def bitorsions(self):
elif (c3,c2,c1) in ubdict:
ublist.append((atom3,atom2,atom1))

# create pitorslist = list of 6-body interactions
# create pitorsionlist = list of 6-body interactions
# based on central bond, each bond atom is bonded to exactly 2 other atoms
# avoid double counting by requiring atom1 < atom2
# NOTE: need more info on how to order the 6 atoms for Tinker to compute on
Expand Down Expand Up @@ -962,7 +962,7 @@ def bitorsions(self):

pitorsionlist.append((atom3,atom4,atom1,atom2,atom5,atom6))

# create bitorslist = list of 5-body interactions
# create bitorsionlist = list of 5-body interactions
# generate topology via double loop over neighbors of central atom3
# additional double loop over bonds of atom2 and bonds of atom4
# avoid double counting the reverse bitorsion by use of btdict dictionary
Expand Down

0 comments on commit 6b42545

Please sign in to comment.