From: Θωμας Ευαγγελιδης (
Date: Tue Aug 07 2007 - 08:34:14 CDT

Dear John,
the concept was to write a plugin which creates smaller dcd files from bigger
ones by taking into account only the water molecules & ions which surround
the macromolecule. The user will give a cutoff distance, lets say 5 A, and the
program will find which atoms are within 5 A in the first frame, lets say N.
Then it will take frame No.2, find which N atoms are closer to the protein and
write them in the new dcd. Then frame No.3 , etc... Probably the most atoms out
of N will be the same in every frame, so those atomIDs writen in the dcd will be
the same too, but there will be also some others which will be raplaced. Thus
the program will have to write these new atomIDs in place of the others.
Could it be possible for that new dcd file to hold a time-varying set of atoms
if we would create in some way a new psf file - or even by keeping the initial-
that will contain information about all the atoms seen in all the frames of the
new dcd? Do you have anything else to propose?

Αρχικό μήνυμα από John Stone <>:

> Hi,
> Is there some specific reason you need to create a DCD file?
> One of the problems you're going to have with attempting to write
> out a time-varying set of atoms to a DCD is that you'll lose track
> of which atom indices are which. Why not just emit your own file format
> and use just the atoms you care about? The DCD format really isn't
> suited to holding a time-varying set of atoms, even with a big hammer ;-)
> The internal code in VMD does not calculate minimums nor maximums,
> but merely tests candidate atoms to see if they meet the distance
> selection criteria or not, for the currently active timestep.
> Calculating min, max, quantiles, or the histogram of distance for
> each atom over all timesteps would have to be done with your
> own script presently. If there is sufficient interest in adding
> a new "measure" subcommand for computing distances we could add one,
> but I haven't had any requests for such a feature thus far.
> Cheers,
> John Stone
> On Tue, Aug 07, 2007 at 12:52:34AM +0300, wrote:
> >
> > Hi,
> > I am writing a plugin for VMD and I need some help. What I am trying to do
> is to
> > create dcd files which contain only the atoms that are within a given
> cutoff
> > distance from the protein. The problem is that each frame of a dcd must
> contain
> > the same number of atoms, so if frame No.1 contains N atoms then I have to
> find
> > which N atoms of frame No.2 are closer to the protein and write only them
> in
> > the new dcd file. My question is if the "atomselect top "exwithin $cutoff
> of
> > protein"" command calculates by default the minimum distance of each atom
> it
> > selects from the protein and if there is a way to retrieve it from the
> source
> > code. I tried to read the source code but I am not sure if it does what I
> need.
> > I just figured out that the "within" macro functions by creating grid cells
> > enclosing the protein atoms (others) as well as the atoms which souround
> them
> > (flgs). I have also some other ideas but that would be the faster way to
> find
> > the atoms I need.
> > I would appreciate any help,
> > Thomas Evangelidis
> --
> NIH Resource for Macromolecular Modeling and Bioinformatics
> Beckman Institute for Advanced Science and Technology
> University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
> Email: Phone: 217-244-3349
> WWW: Fax: 217-244-6078