From: Axel Kohlmeyer (akohlmey_at_gmail.com)
Date: Thu Nov 18 2010 - 20:27:55 CST

On Thu, Nov 18, 2010 at 9:20 PM, Axel Kohlmeyer <akohlmey_at_gmail.com> wrote:
> On Thu, Nov 18, 2010 at 8:41 PM, David Wedner <wedner.david_at_yahoo.com> wrote:
>> Hi vmd users
>> I hope some one can help me regarding the following issue
>> I would like to calculate the radial distribution function from the center
>> of mass of solute molecules
>> how can I define the center of mass as one selection ?
>
> you cannot.

to expand a little bit on this.

you have to try to stay away of assuming that a software
will be able to do what is "reasonable" or "makes sense".
software is stupid and has no imagination.

the selection text used with the atomselect function in VMD
and that does one thing "selecting atoms" nothing else.
and the gofr code expects to loop over such list of atoms.

that being said, there are two ways to continue from here
and still get what you want (or about as good).

method a): select only atoms that are the closest to the
center of mass. e.g. for water, picking the oxygen is a
very, very good approximation.

method b): you create a fake molecule that contains
only one atom per solute but the rest as is and then
write a script that copies over the coordinates and
replaces the coordinates for the one solute atom
per molecule with the center of mass of the whole
molecule. that would be a bit time consuming, but
not very complicated if you build this script step by
step.

cheers,
    axel.

>>
>> Thanks in advance
>>
>> David
>>
>>
>
>
>
> --
> Dr. Axel Kohlmeyer
> akohlmey_at_gmail.com  http://goo.gl/1wk0
>
> Institute for Computational Molecular Science
> Temple University, Philadelphia PA, USA.
>

-- 
Dr. Axel Kohlmeyer
akohlmey_at_gmail.com  http://goo.gl/1wk0
Institute for Computational Molecular Science
Temple University, Philadelphia PA, USA.