Re: [AMBER] CPPTRAJ: distance between atoms

From: Daniel Roe <>
Date: Mon, 4 May 2020 07:35:17 -0400


From your description, it’s not clear what you’re trying to do, or what
exactly you’re comparing to in VMD. The cpptraj command you gave would give
the distance (and note the distance will be imaged by default if there is
box information) from the center of mass of all atoms of Type1 to the
center of mass of all atoms of Type2. If what you want is each distance
between each individual atom of those types, you need a separate distance
command for each. You could use two for mask loops: “for atoms A0 inmask
.%Type1” etc. see the manual for full syntax.


On Mon, May 4, 2020 at 6:55 AM emanuele falbo <>

> Dear all,
> I want to compute the distance between two type of atoms from a MD
> trajectory.
> I am using cpptraj which returns the distance between the center of mass:
> distance dist .%Type1 @%Type2 out file.dat
> However, the file.dat contains different distances from those that
> I can check in molecular editor (like VMD).
> Do you have any idea about how to get just the distances between each
> individual atom types?
> Thanks in advance for the help.
> Cheers,
> Manuel
> --
> *Emanuele Falbo*
> PhD student
> Penfold group
> School of Natural and Environmental Sciences
> Bedson Building, Newcastle University
> Newcastle upon Tyne, NE1 7RU
> w:
> _______________________________________________
> AMBER mailing list
AMBER mailing list
Received on Mon May 04 2020 - 05:00:02 PDT
Custom Search