mailr22514 - /branches/double_rotor/specific_analyses/frame_order/optimisation.py


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

Header


Content

Posted by edward on March 21, 2014 - 09:17:
Author: bugman
Date: Fri Mar 21 09:17:23 2014
New Revision: 22514

URL: http://svn.gna.org/viewcvs/relax?rev=22514&view=rev
Log:
Improvements for the centre of mass calculation for the frame order model 
optimisation.

This is now only calculated for the rotor models.  The CoM is also printed 
out for better user feedback.


Modified:
    branches/double_rotor/specific_analyses/frame_order/optimisation.py

Modified: branches/double_rotor/specific_analyses/frame_order/optimisation.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/double_rotor/specific_analyses/frame_order/optimisation.py?rev=22514&r1=22513&r2=22514&view=diff
==============================================================================
--- branches/double_rotor/specific_analyses/frame_order/optimisation.py 
(original)
+++ branches/double_rotor/specific_analyses/frame_order/optimisation.py Fri 
Mar 21 09:17:23 2014
@@ -684,8 +684,14 @@
         cdp.num_int_pts = 200000
 
     # The centre of mass, for use in the rotor models.
-    com = pipe_centre_of_mass(verbosity=0)
-    com = array(com, float64)
+    com = None
+    if cdp.model in ['rotor', 'double rotor']:
+        # The centre of mass of all objects in the data pipe.
+        com = pipe_centre_of_mass(verbosity=0)
+        com = array(com, float64)
+
+        # Printout.
+        print("The centre of mass reference coordinate for the rotor models 
is at:\n    %s" % list(com))
 
     # The centre of mass of the moving domain - to use as the centroid for 
the average domain position rotation.
     if cdp.ave_pos_pivot == 'com':




Related Messages


Powered by MHonArc, Updated Fri Mar 21 09:40:02 2014