Hi Phil,

If you have a reasonably recent version of the cctbx around (phenix, cci apps, 
maybe ccp4), try
this:

import scitbx.math
rotation_matrix = (1,0,0,0,0,1,0,-1,0)
fm = scitbx.math.r3_rotation_axis_and_angle_from_matrix(r=rotation_matrix)
print fm.axis
print fm.angle(deg=True)

The implementation (with comments) is in 
scitbx/include/scitbx/math/r3_rotation.h

Ralf



----- Original Message ----
From: Phil Evans <[EMAIL PROTECTED]>
To: CCP4BB@JISCMAIL.AC.UK
Sent: Tuesday, July 29, 2008 1:10:50 AM
Subject: [ccp4bb] Rotation axis

If I've go a superposition transformation (x' = Rx + t), as it happens  
from a superposition in ccp4mg, how do I get the position & direction  
of the rotation axis (to draw in a picture)?
I know that any (orthonormal) transformation can be represented as a  
rotation about an axis + a screw translation along that axis

I'm sure I've done this before ...

thanks
Phil

Reply via email to