From: Dave Schall (schalljd_at_gmail.com)
Date: Fri Oct 03 2014 - 13:25:27 CDT

Axel,

How do you create the dummy atoms in topotools for output to lammps?

Say I have a pdb file with molecule A having atom types A1 and A2 and
molecule B having types B1 and B2.

In a system with a mix of A and B my lammps coord file would have atoms
tagged as A1=1, A2=2, B1=3, B2=4.

If I have a system containing only B molecules, is there a way to make
topotools dump the B atoms as lammps type 3 and 4 for lammps (instead of
defaulting to 1 and 2) so I don't need to renumber everything in the lammps
input script to match the coord file?

Dave

On Fri, Oct 3, 2014 at 2:16 PM, Axel Kohlmeyer <akohlmey_at_gmail.com> wrote:

> On Fri, Oct 3, 2014 at 1:21 PM, Josh Vermaas <vermaas2_at_illinois.edu>
> wrote:
> > Hi Dave,
> >
> > The issue here is actually something that is usually quite benign (I
> think).
> > You say you are loading in pdbs, which normally don't have connectivity
> > information (I dunno how packmol does it, but I don't see many with PDBs
> > with conect records filled in). This means you are implicitly counting on
> > VMD's bond-search algorithm to determine all of your connectivity. VMD's
> > bond-search algorithm is efficient, which means it breaks down the N
> > particles, and assigns them to grid patches based on their location in
> space
> > (not the order they were loaded), searching for atoms that are close
> from a
> > small subset of the system, vastly reducing the number of distance
> > comparisons that need to be made. Now you said you let packmol make all
> of
> > these systems independently, which means that by chance alone, some
> > molecules are split across these patches differently in one structure
> > relative to another. The order of the bonds stored internally will be
> > different each time! You can test this by asking VMD to write out a psf
> > after the bonds, angles and dihedrals have been guessed. I'm betting the
> > order of the indices will not be sorted, and that the bondlists will be
> > different for each system. Now topotools iterates linearly over this
> > bondlist to build up angles and dihedrals, which I *think* is why it has
> > this weird behavior. Why does the order of the angles and dihedrals
> matter
> > though? Is this something LAMMPS specific? I'm also confused as to why
> the
>
> josh,
>
> this was not about the order of the angles and dihedrals, but the *types*.
> a psf file doesn't even store that information, but it is crucial in
> LAMMPS, because they are not referred to with a symbolic name but a
> number. the symbolic names that were quoted are only comments. if you
> want to use the same (bond/angle/dihedral) parameter definition for
> multiple simulations of the same system, those names need to be
> ordered, so the assigned numbers are the same.
>
> in fact, for systems with more variety, it may be needed to pad the
> list for interaction types with dummies that are not present in a
> specific topology to enforce the reuse of parameter files. with
> CHARMM/NAMD this matching and assigning is all done at a later step
> during the MD run. that has some advantages (it is simpler to create
> the topology), but also some drawbacks (it requires that the bonded
> interaction types are uniquely defined by the atom types comprising
> that interaction).
>
> axel.
>
> > angles and dihedrals are specified based on what look like atomnames and
> not
> > indices, but I'm sure its just a formatting thing.
> >
> > -Josh Vermaas
> >
> >
> > On 10/03/2014 11:08 AM, Dave Schall wrote:
> >
> > Hi vmd-users,
> >
> > I am converting pdb files to a lammps coord files using vmd/topotools. I
> > have a system with two types of molecules, say A and B. I am using
> packmol
> > to generate pdb files for systems with different mole fractions of A and
> B.
> > Packmol generates lists all the A molecules first then, all the B
> molecules
> > after.
> >
> > I take this pdb file and read into vmd, do some atom selections to set
> > charges/types/masses, etc. I have topotools guess the angles and
> dihedrals.
> > Then I dump to a lammps coord file via topotools. I have a tcl script
> set up
> > to do this the same way every time.
> >
> > Since I am running a fairly large set of simulations, I'd like this to be
> > somewhat automated, but what I find when I inspect the lammps coord
> files is
> > that the order of angles and dihedrals is not always the same. This
> means I
> > have to check each coord file against my lammps input file to make sure
> the
> > order of the parameters match.
> >
> > For example for some files I get:
> >
> > # 1 C3-C4-H1
> > # 2 C-C1-H
> > # 3 C1-C-H
> > # 4 C2-C-H
> > # 5 H1-C3-H1
> > # 6 C-C2-H
> >
> > For some others:
> >
> > # 1 C3-C4-H1
> > # 2 C-C1-H
> > # 3 C1-C-H
> > # 4 C2-C-H
> > # 5 C-C2-H
> > # 6 H1-C3-H1
> >
> > (5 and 6 as switched)
> >
> > Dihedrals are much more mixed up than angles.
> >
> > Am I wrong in assuming that if the order of molecules (and atoms therein)
> > are the same in every pdb file they should be read in the same order by
> > vmd/topotools? Is this some function of how "topo guessangles" and "topo
> > guessdihedrals" works? If so I guess I better get busy building a a
> > parameter database and script that can create input decks from lammps
> coord
> > files.
> >
> > Thanks,
> >
> > Dave
> >
> >
> >
> >
> > --
> > J. David Schall, Assistant Professor
> > Dept. of Mechanical Engineering, Oakland University
> > 328 Engineering Center, Rochester, MI 48309
> > 248-370-2870
> >
> >
>
>
>
> --
> Dr. Axel Kohlmeyer akohlmey_at_gmail.com http://goo.gl/1wk0
> College of Science & Technology, Temple University, Philadelphia PA, USA
> International Centre for Theoretical Physics, Trieste. Italy.
>

-- 
J. David Schall, Assistant Professor
Dept. of Mechanical Engineering, Oakland University
328 Engineering Center, Rochester, MI 48309
248-370-2870