mailr15132 - /branches/frame_order_testing/generic_fns/structure/mass.py


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

Header


Content

Posted by edward on January 03, 2012 - 16:46:
Author: bugman
Date: Tue Jan  3 16:46:16 2012
New Revision: 15132

URL: http://svn.gna.org/viewcvs/relax?rev=15132&view=rev
Log:
The centre_of_mass() function now averages the atomic positions over all 
models.

This is to fix a bug with the change to the atom_loop() API call.


Modified:
    branches/frame_order_testing/generic_fns/structure/mass.py

Modified: branches/frame_order_testing/generic_fns/structure/mass.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_testing/generic_fns/structure/mass.py?rev=15132&r1=15131&r2=15132&view=diff
==============================================================================
--- branches/frame_order_testing/generic_fns/structure/mass.py (original)
+++ branches/frame_order_testing/generic_fns/structure/mass.py Tue Jan  3 
16:46:16 2012
@@ -1,6 +1,6 @@
 
###############################################################################
 #                                                                            
 #
-# Copyright (C) 2003-2011 Edward d'Auvergne                                  
 #
+# Copyright (C) 2003-2012 Edward d'Auvergne                                  
 #
 #                                                                            
 #
 # This file is part of the program relax.                                    
 #
 #                                                                            
 #
@@ -59,7 +59,7 @@
     M = 0.0
 
     # Loop over all atoms.
-    for mol_name, res_num, res_name, atom_num, atom_name, element, pos in 
cdp.structure.atom_loop(atom_id=atom_id, model_num=model, mol_name_flag=True, 
res_num_flag=True, res_name_flag=True, atom_num_flag=True, 
atom_name_flag=True, element_flag=True, pos_flag=True):
+    for mol_name, res_num, res_name, atom_num, atom_name, element, pos in 
cdp.structure.atom_loop(atom_id=atom_id, model_num=model, mol_name_flag=True, 
res_num_flag=True, res_name_flag=True, atom_num_flag=True, 
atom_name_flag=True, element_flag=True, pos_flag=True, ave=True):
         # Initialise the spin id string.
         id = ''
 




Related Messages


Powered by MHonArc, Updated Tue Jan 03 17:00:02 2012