VMD-L Mailing List
From: Lee, Hwan Kyu (NIH/NHLBI) [E] (leeh3_at_nhlbi.nih.gov)
Date: Tue Feb 24 2009 - 19:09:27 CST
- Next message: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Previous message: Katherine Parra: "Re: Test"
- Next in thread: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Reply: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Reply: J T: "Re: question about "measure dihed" with COM points"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Dear VMDer,
I calculated center of mass for each residue, and then calculated dihedral angles for those four center of mass. I wrote tcl script like below, but got an error, "expected integer but got "11.965297699" measure dihed: bad atom index". It looks like $sel11 cannot be recognized as a coordinate of COM. How can I fix this problem?
Thanks for your help in advance.
-----------------
set numFrames [molinfo top get numframes]
for {set pp 300} {$pp < $numFrames} {incr pp} {
set n 1
while {$n < 35} {
set n1 [expr {$n+1}]
set n2 [expr {$n+2}]
set n3 [expr {$n+3}]
set sel1 [atomselect top "resid $n"]
set sel2 [atomselect top "resid $n1"]
set sel3 [atomselect top "resid $n2"]
set sel4 [atomselect top "resid $n3"]
set sel11 [measure center $sel1 weight mass]
set sel21 [measure center $sel2 weight mass]
set sel31 [measure center $sel3 weight mass]
set sel41 [measure center $sel4 weight mass]
set dih [measure dihed [list $sel11 $sel21 $sel31 $sel41]]
$sel1 delete
$sel2 delete
$sel3 delete
$sel4 delete
$sel11 delete
$sel21 delete
$sel31 delete
$sel41 delete
incr n
set result [open "dihedral.xvg" a]
puts $result "$dih"
close $result
}
}
-----------------
best,
Hwankyu.
- Next message: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Previous message: Katherine Parra: "Re: Test"
- Next in thread: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Reply: Axel Kohlmeyer: "Re: question about "measure dihed" with COM points"
- Reply: J T: "Re: question about "measure dihed" with COM points"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]