[gmx-users] How to compute self diffusivities when the xtc trajectory file contains only a subset of atoms

rocwhite168 rocwhite168 at 163.com
Sun Sep 28 20:32:42 CEST 2014


On Sun, Sep 28, 2014 at 12:24 PM, Mark Abraham <mark.j.abraham at gmail.com>
wrote:

> On Sun, Sep 28, 2014 at 5:36 PM, rocwhite168 <rocwhite168 at 163.com> wrote:
>
> > Hi Mark,
> >
> > Thanks for your suggestion. That's actually what I've been doing.
> However,
> > it requires modifying not only .top but also conf.gro and grompp.mdp (to
> > remove reference to index groups of fixed atoms that no longer exist), as
> > well as rerunning make_ndx. I was hoping there would be a less tortuous
> > path :)
>
>
> Sounds like a 10 minute job to me :-) - sed on the gro file, wc -l to check
> the number of atoms, text editor to pull out any references in the .mdp
> that no longer make sense. You only need the topology definitions in the
> .tpr, not anything to do with the physics...
>
> Well, 10 min for one state point, and there are multiple temperatures,
pressures and mixture compositions ... Not that I'm really going to do this
manually, but facing the impressive set of auxiliary tools Gromacs has, I
was hoping that I missed a simpler solution.

> It's strange that .tpr generated by grompp has everything correctly:
> >
> >    moltype (0):
> >       name="Water"
> >       atoms:
> >          atom (4):
> > ...
> >          atom (4):
> >             atom[0]={name="OW"}
> >             atom[1]={name="HW"}
> >             atom[2]={name="HW"}
> >             atom[3]={name="MW"}
> >          type (4):
> > ...
> >
> > but .tpr generated by gmx convert-tpr does not:
> >
> >    moltype (0):
> >       name="This becomes the system name"
> >       atoms:
> >          atom (60):
> > ...
> >          atom (60):
> >             atom[0]={name="OW"}
> >             atom[1]={name="HW"}
> >             atom[2]={name="HW"}
> >             atom[3]={name="MW"}
> >             atom[4]={name="OW"}
> >             atom[5]={name="HW"}
> >             atom[6]={name="HW"}
> >             atom[7]={name="MW"}
> >             atom[8]={name="OW"}
> >             atom[9]={name="HW"}
> >             atom[10]={name="HW"}
> >             atom[11]={name="MW"}
> >             atom[12]={name="OW"}
> > ...
> >
> > Any ideas why this would happen?
> >
>
> Like most software, because someone made it work well enough to solve their
> immediate problem.
>
> Back on the main question, why aren't you just using index groups on the
> trajectory with the tool you were planning to use? That's the simplest time
> to take a subset.
>
If I just give the original .tpr and .ndx to "gmx msd", the program will
crash with a segmentation error because the indices for the atoms in the
index group I want to analyze are larger than the total number of atoms in
the .xtc file.

>
> Mark
>
> In any case, thanks for your input.

Roc

>
> > Thanks,
> >
> > Roc
> >
> > On Sun, Sep 28, 2014 at 1:32 AM, Mark Abraham <mark.j.abraham at gmail.com>
> > wrote:
> >
> > > Hi,
> > >
> > > I'm not sure this will help, because I'm not sure what the origin of
> the
> > > problem is, but you can easily hack a copy of your .top so that a fresh
> > run
> > > of grompp will produce a .tpr that will match the .xtc.
> > >
> > > Mark
> > > On Sep 28, 2014 7:47 AM, "rocwhite168" <rocwhite168 at 163.com> wrote:
> > >
> > > > Dear GROMACS users,
> > > >
> > > > I'm trying to compute mean square displacements for molecules. My
> > > > system contains atoms that don't move, so I used "compressed-x-grps"
> > > > in grompp.mdp to exclude them from the xtc trajectory file. After
> > > > mdrun, I ran "gmx convert-tpr -s topol.tpr -n index.ndx" to reduce
> the
> > > > set of atoms in the tpr file to match those in the xtc file
> (otherwise
> > > > "gmx msd" will fail because the atom indices exceed those found in
> the
> > > > xtc file). Say, for both "compressed-x-grps" and "gmx convert-tpr" I
> > > > specified OW_HW to include all water molecules. However, tpxout.tpr
> > > > generated by "gmx convert-tpr" treats all water molecules as a large,
> > > > single molecule, and as a result "gmx msd" detects only that one
> > > > molecule. This would be useful for computing corrected diffusivities,
> > > > but is there a way to let "gmx msd" detect individual molecules
> > > > correctly if I want to compute self diffusivities?
> > > >
> > > > Any suggestions would be very much appreciated!
> > > >
> > > > Thanks,
> > > >
> > > > Roc
> > > > --
> > > > Gromacs Users mailing list
> > > >
> > > > * Please search the archive at
> > > > http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
> > > > posting!
> > > >
> > > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
> > > >
> > > > * For (un)subscribe requests visit
> > > > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users
> or
> > > > send a mail to gmx-users-request at gromacs.org.
> > > >
> > > --
> > > Gromacs Users mailing list
> > >
> > > * Please search the archive at
> > > http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
> > > posting!
> > >
> > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
> > >
> > > * For (un)subscribe requests visit
> > > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
> > > send a mail to gmx-users-request at gromacs.org.
> > >
> > >
> > --
> > Gromacs Users mailing list
> >
> > * Please search the archive at
> > http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
> > posting!
> >
> > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
> >
> > * For (un)subscribe requests visit
> > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
> > send a mail to gmx-users-request at gromacs.org.
> >
> --
> Gromacs Users mailing list
>
> * Please search the archive at
> http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
> posting!
>
> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>
> * For (un)subscribe requests visit
> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
> send a mail to gmx-users-request at gromacs.org.
>
>


More information about the gromacs.org_gmx-users mailing list