powered by
For Cartesian coordinates of atoms A-B-C-D, calculate the dihedral angle formed by viewing down the B-C axis.
torsion(a, b, c, d)
length 3 vector of coordinates of atom A
length 3 vector of coordinates of atom B
length 3 vector of coordinates of atom C
length 3 vector of coordinates of atom D
Returns the dihedral angle (in degrees between -180 and 180).
Similar to torsion.xyz, but with implementation in C++.
# NOT RUN { torsion(c(50.051, 37.144, -4.723), c(50.044, 36.248, -3.559), c(51.296, 35.369, -3.476), c(51.930,35.119,-4.618)) # }
Run the code above in your browser using DataLab