mailr24142 - /branches/disp_spin_speed/lib/dispersion/mmq_cr72.py


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

Header


Content

Posted by tlinnet on June 18, 2014 - 20:22:
Author: tlinnet
Date: Wed Jun 18 20:22:02 2014
New Revision: 24142

URL: http://svn.gna.org/viewcvs/relax?rev=24142&view=rev
Log:
Moved the "eta_scale = 2.0**(-3.0/2.0)" out of lib function for mmq cr72, 
since this is only needs to be computed once.

Task #7807 (https://gna.org/task/index.php?7807): Speed-up of dispersion 
models for Clustered analysis.

Modified:
    branches/disp_spin_speed/lib/dispersion/mmq_cr72.py

Modified: branches/disp_spin_speed/lib/dispersion/mmq_cr72.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/disp_spin_speed/lib/dispersion/mmq_cr72.py?rev=24142&r1=24141&r2=24142&view=diff
==============================================================================
--- branches/disp_spin_speed/lib/dispersion/mmq_cr72.py (original)
+++ branches/disp_spin_speed/lib/dispersion/mmq_cr72.py Wed Jun 18 20:22:02 
2014
@@ -50,6 +50,9 @@
 # Python module imports.
 from numpy import arccosh, cos, cosh, isfinite, fabs, log, min, max, sin, 
sqrt, sum
 from numpy.ma import fix_invalid, masked_greater_equal, masked_where
+
+# Repetitive calculations (to speed up calculations).
+eta_scale = 2.0**(-3.0/2.0)
 
 
 def r2eff_mmq_cr72(r20=None, pA=None, dw=None, dwH=None, kex=None, 
cpmg_frqs=None, inv_tcpmg=None, tcp=None, back_calc=None):
@@ -130,7 +133,6 @@
     Dneg = 0.5 * (-1.0 + D_part)
 
     # Partial eta+/- values.
-    eta_scale = 2.0**(-3.0/2.0)
     etapos_part = eta_scale * sqrt(Psi + sqrt_psi2_zeta2)
     etaneg_part = eta_scale * sqrt(-Psi + sqrt_psi2_zeta2)
 




Related Messages


Powered by MHonArc, Updated Wed Jun 18 20:40:02 2014