Hi Troels, This looks nicer, but you now can't use the trick in point one at http://thread.gmane.org/gmane.science.nmr.relax.devel/5635 to speed up the code. The previous code: - Minty = Rpre - inv_tcpmg * ( ncyc * arccosh(v1c.real) + log(Tog.real) ) actually used this trick and is hence faster. It might be better to stay with the faster code? Regards, Edward On 7 May 2014 15:55, <tlinnet@xxxxxxxxxxxxx> wrote:
Author: tlinnet Date: Wed May 7 15:55:02 2014 New Revision: 23055 URL: http://svn.gna.org/viewcvs/relax?rev=23055&view=rev Log: Re-wrote lines to follow appendix 1 in paper. sr #3154: (https://gna.org/support/?3154) Implementation of Baldwin (2014) B14 model - 2-site exact solution model for all time scales. This follows the tutorial for adding relaxation dispersion models at: http://wiki.nmr-relax.com/Tutorial_for_adding_relaxation_dispersion_models_to_relax#Debugging Modified: trunk/lib/dispersion/b14.py Modified: trunk/lib/dispersion/b14.py URL: http://svn.gna.org/viewcvs/relax/trunk/lib/dispersion/b14.py?rev=23055&r1=23054&r2=23055&view=diff ============================================================================== --- trunk/lib/dispersion/b14.py (original) +++ trunk/lib/dispersion/b14.py Wed May 7 15:55:02 2014 @@ -226,11 +226,14 @@ # -1/Trel * log(LpreDyn). Rpre = (r20a + r20b + kex) / 2.0 + # Carver and Richards (1972) + R2eff_CR72 = Rpre - inv_tcpmg * ncyc * arccosh(v1c.real) + # Estimate R2eff. relax_time = Trel = 1/inv_tcpmg. - Minty = Rpre - inv_tcpmg * ( ncyc * arccosh(v1c.real) + log(Tog.real) ) + R2eff = R2eff_CR72 - inv_tcpmg * log(Tog.real) # Loop over the time points, back calculating the R2eff values. for i in range(num_points): # The full formula. - back_calc[i] = Minty[i] + back_calc[i] = R2eff[i] _______________________________________________ relax (http://www.nmr-relax.com) This is the relax-commits mailing list relax-commits@xxxxxxx To unsubscribe from this list, get a password reminder, or change your subscription options, visit the list information page at https://mail.gna.org/listinfo/relax-commits