mailr24378 - /branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on July 01, 2014 - 16:26:
Author: bugman
Date: Tue Jul  1 16:26:41 2014
New Revision: 24378

URL: http://svn.gna.org/viewcvs/relax?rev=24378&view=rev
Log:
Fixes for the cone geometric object created by the frame_order.pdb_model user 
function.

This was broken by the code refactoring and now works again for the 
pseudo-ellipse models.


Modified:
    branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py

Modified: 
branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py?rev=24378&r1=24377&r2=24378&view=diff
==============================================================================
--- branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py   
  (original)
+++ branches/frame_order_cleanup/specific_analyses/frame_order/geometric.py   
  Tue Jul  1 16:26:41 2014
@@ -202,19 +202,17 @@
     # The inversion matrix.
     inv_mat = -eye(3)
 
-    # The axis.
-    if cdp.model in ['rotor', 'free rotor']:
-        axis = create_rotor_axis_alpha(alpha=cdp.axis_alpha, pivot=pivot, 
point=com)
+    # The rotation matrix (rotation from the z-axis to the cone axis).
+    R = zeros((3, 3), float64)
+    if cdp.model in ['pseudo-ellipse', 'pseudo-ellipse, torsionless', 
'pseudo-ellipse, free rotor']:
+        euler_to_R_zyz(cdp.eigen_alpha, cdp.eigen_beta, cdp.eigen_gamma, R)
     else:
-        axis = create_rotor_axis_spherical(theta=cdp.axis_theta, 
phi=cdp.axis_phi)
-    print(("Central axis: %s." % axis))
-
-    # The rotation matrix (rotation from the z-axis to the cone axis).
-    if cdp.model not in ['iso cone', 'iso cone, torsionless', 'iso cone, 
free rotor']:
-        R = axes
-    else:
-        R = zeros((3, 3), float64)
+        if cdp.model in ['rotor', 'free rotor']:
+            axis = create_rotor_axis_alpha(alpha=cdp.axis_alpha, 
pivot=pivot, point=com)
+        elif cdp.model in ['iso cone', 'iso cone, torsionless', 'iso cone, 
free rotor']:
+            axis = create_rotor_axis_spherical(theta=cdp.axis_theta, 
phi=cdp.axis_phi)
         two_vect_to_R(array([0, 0, 1], float64), axis, R)
+    print(("Rotation matrix:\n%s" % R))
 
     # Average position rotation.
     R_pos = R




Related Messages


Powered by MHonArc, Updated Tue Jul 01 17:00:02 2014