Author: bugman Date: Thu Feb 21 11:08:03 2008 New Revision: 5092 URL: http://svn.gna.org/viewcvs/relax?rev=5092&view=rev Log: The pivot-CoM vector is now stored in the data pipe. Modified: 1.3/specific_fns/n_state_model.py Modified: 1.3/specific_fns/n_state_model.py URL: http://svn.gna.org/viewcvs/relax/1.3/specific_fns/n_state_model.py?rev=5092&r1=5091&r2=5092&view=diff ============================================================================== --- 1.3/specific_fns/n_state_model.py (original) +++ 1.3/specific_fns/n_state_model.py Thu Feb 21 11:08:03 2008 @@ -119,9 +119,11 @@ else: cdp.CoM = generic_fns.structure.centre_of_mass() + # Calculate the vector between the pivot and CoM points. + cdp.pivot_CoM = array(cdp.CoM, float64) - array(cdp.pivot_point, float64) + # Calculate the unit vector between the pivot and CoM points. - unit_vect = array(cdp.CoM, float64) - array(cdp.pivot_point, float64) - unit_vect = unit_vect / norm(unit_vect) + unit_vect = cdp.pivot_CoM / norm(unit_vect) # Initilise some data structures. R = zeros((3,3), float64) @@ -158,6 +160,7 @@ # Print out. print "\n%-40s %-20s" % ("Pivot point:", `cdp.pivot_point`) print "%-40s %-20s" % ("Moving domain CoM (prior to rotation):", `cdp.CoM`) + print "%-40s %-20s" % ("Pivot-CoM vector", `cdp.pivot_CoM`) print "%-40s %-20s" % ("Pivot-CoM unit vector:", `unit_vect`) print "%-40s %-20s" % ("Reduced CoM vector:", `cdp.red_CoM`) print "%-40s %-20s" % ("Full length rotated CoM vector:", `cdp.rot_CoM`)