VMD-L Mailing List
From: Vermaas, Joshua (Joshua.Vermaas_at_nrel.gov)
Date: Fri Mar 23 2018 - 12:01:22 CDT
- Next message: Vermaas, Joshua: "Re: Decompose Transformation Matrix to Rotations and Translations along XYZ axes"
- Previous message: Sandip Mondal: "Re: Parallelization to an axis"
- In reply to: Udaya Dahal: "Re: Text mode data extraction without trajectory update"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi,
Selections are your friend.
set sel0 [atomselect top "noh and water and d*d<x*x+y*y+z*z" frame 0]
puts "Initial value [$sel0 num]"
set self [atomselect top "noh and water and d*d<x*x+y*y+z*z and index [$sel0 get index]"]
for { set f 0 } { $f < [molinfo top get numframes] } { incr f } {
$self frame $f
$self update
put "$f [$self num]"
}
-Josh
On 03/18/2018 09:46 AM, Udaya Dahal wrote:
Sorry, I didn't put my question properly. I didn't mean to calculate distance. I want to calculate the correlation. I have 'n' water molecules within distance 'd' of a fixed point say (0,0,0). Now in subsequent frames, how many of them(water molecules in initial frame 'n') stay within that distance 'd' from (0,0,0).
Regards,
On Sun, Mar 18, 2018 at 8:50 AM, Ashar Malik <asharjm_at_gmail.com<mailto:asharjm_at_gmail.com>> wrote:
Do you mean you want to measure/monitor the distance between "a molecule A" and a "water molecule" in your simulation? The word trajectory update is confusing.
If you just want a distance between two molecules listed for every frame of your trajectory -- then you should know that a distance can only be calculated between two points. Molecules have more than 1 point point so you will have two decide which point to use as reference. You can choose an atom or select a centre of geometry/mass and measure distance between that for two molecules.
To measure distance look at the command measure bond (http://www.ks.uiuc.edu/Research/vmd/vmd-1.8.6/ug/node124.html For this I don't think you can use anything else apart from atoms, meaning this won't work with centre of mass/geometry.
On Sun, Mar 18, 2018 at 7:31 PM, Udaya Dahal <dahal.udaya_at_gmail.com<mailto:dahal.udaya_at_gmail.com>> wrote:
I would like to extract the data as in visualization without trajectory update. For eg. I am looking at water molecules at some distance from another molecule A. If I don't update the trajectory, I can see the water moving away from the initial distance. How to extract this data in text mode? I appreciate your help.
Regards,
Try this. Drop back if it doesn't work and someone can help more. This is obviously assuming I understood your problem correctly.
Hi,
UD
--
Best,
/A