mailr15089 - /branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/


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

Header


Content

Posted by edward on December 13, 2011 - 22:45:
Author: bugman
Date: Tue Dec 13 22:45:06 2011
New Revision: 15089

URL: http://svn.gna.org/viewcvs/relax?rev=15089&view=rev
Log:
Started to create the isotropic cone frame order test model.


Added:
    branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/
      - copied from r15072, 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone_free_rotor/
    
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/frame_order.py
      - copied unchanged from r15087, 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone_free_rotor/frame_order.py
Modified:
    
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/animate.py
    
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.log.bz2
    
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.py

Modified: 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/animate.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/animate.py?rev=15089&r1=15072&r2=15089&view=diff
==============================================================================
--- 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/animate.py
 (original)
+++ 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/animate.py
 Tue Dec 13 22:45:06 2011
@@ -12,6 +12,9 @@
 
 # The cone representation.
 pymol.cone_pdb('cone.pdb')
+
+# Load the distribution of structures.
+pymol.command('load distribution.pdb.gz')
 
 # Structure display.
 pymol.command('hide everything, 1J7O_1st_NH')

Modified: 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.log.bz2
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.log.bz2?rev=15089&r1=15072&r2=15089&view=diff
==============================================================================
Binary files - no diff available.

Modified: 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.py?rev=15089&r1=15072&r2=15089&view=diff
==============================================================================
--- 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.py
 (original)
+++ 
branches/frame_order_testing/test_suite/shared_data/frame_order/iso_cone/generate_distribution.py
 Tue Dec 13 22:45:06 2011
@@ -9,8 +9,10 @@
 from maths_fns.rotation_matrix import axis_angle_to_R, R_random_hypersphere
 
 
-# The number of structures.
+# Init.
 N = 5000
+THETA_MAX = 10.0 * 2.0 * pi / 360.0
+SIGMA_MAX = 20.0 * 2.0 * pi / 360.0
 
 # Create a data pipe.
 pipe.create('generate', 'N-state')
@@ -21,6 +23,10 @@
 axis = pivot - com
 axis = axis / norm(axis)
 
+# A perpendicular axis to check the torsion angle.
+perp_axis = cross(axis, array([0, 0, 1]))
+perp_axis = perp_axis / norm(perp_axis)
+
 # Init a rotation matrix.
 R = zeros((3, 3), float64)
 
@@ -30,10 +36,20 @@
     # The random rotation matrix.
     R_random_hypersphere(R)
 
-    # Skip the rotation if the angle is violated.
-    new_axis = dot(R, axis)
-    angle = acos(dot(axis, new_axis))
-    if angle > (20.0 * 2.0 * pi / 360.0):
+    # Skip the rotation if the cone angle is violated.
+    rot_z = dot(R, axis)
+    theta = acos(dot(axis, rot_z))
+    if theta > THETA_MAX:
+        continue
+
+    # Skip the rotation if the torsion angle is violated.
+    rot_x = dot(R, perp_axis)
+    temp = cross(axis, rot_x)
+    temp = temp / norm(temp)
+    temp2 = cross(temp, axis)
+    temp2 = temp2 / norm(temp2)
+    sigma = acos(dot(perp_axis, temp2))
+    if sigma > SIGMA_MAX:
         continue
 
     # Load the PDB as a new model.




Related Messages


Powered by MHonArc, Updated Tue Dec 13 23:00:02 2011