r21207 - in /branches/relax_disp/docs/latex: dispersion.tex dispersion_models.tex

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 08:47:56 2013
New Revision: 21207

URL: http://svn.gna.org/viewcvs/relax?rev=21207view=rev
Log:
Shifted the 'NS CPMG 2-site expanded' model to the top of the CPMG numerical 
solutions in the manual.

This is because this is the default model which should be used in most cases.


Modified:
branches/relax_disp/docs/latex/dispersion.tex
branches/relax_disp/docs/latex/dispersion_models.tex

Modified: branches/relax_disp/docs/latex/dispersion.tex
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/docs/latex/dispersion.tex?rev=21207r1=21206r2=21207view=diff
==
--- branches/relax_disp/docs/latex/dispersion.tex (original)
+++ branches/relax_disp/docs/latex/dispersion.tex Tue Oct 22 08:47:56 2013
@@ -89,11 +89,11 @@
 For the CPMG-type experiments, the numeric models currently supported are:
 
 \begin{description}
+\item[`NS CPMG 2-site expanded':]\index{relaxation dispersion!NS CPMG 2-site 
expanded model}  A model for 2-site exchange expanded using Maple by Nikolai 
Skrynnikov \citep{Tollinger01}.  It has the parameters $\{\Rtwozero, \dots, 
\pA, \dw, \kex\}$.  See Section~\ref{sect: dispersion: NS CPMG 2-site expanded 
model} on page~\pageref{sect: dispersion: NS CPMG 2-site expanded model}.
 \item[`NS CPMG 2-site 3D':]\index{relaxation dispersion!NS CPMG 2-site 3D 
model}  The reduced model for 2-site exchange using 3D magnetisation vectors 
whereby the simplification $\RtwozeroA = \RtwozeroB$ is assumed.  It has the 
parameters $\{\Rtwozero, \dots, \pA, \dw, \kex\}$.  See Section~\ref{sect: 
dispersion: NS CPMG 2-site 3D model} on page~\pageref{sect: dispersion: NS CPMG 
2-site 3D model}.
 \item[`NS CPMG 2-site 3D full':]\index{relaxation dispersion!NS CPMG 2-site 3D 
full model}  The full model for 2-site exchange using 3D magnetisation vectors 
with parameters $\{\RtwozeroA, \RtwozeroB, \dots, \pA, \dw, \kex\}$.  See 
Section~\ref{sect: dispersion: NS CPMG 2-site 3D full model} on 
page~\pageref{sect: dispersion: NS CPMG 2-site 3D full model}.
 \item[`NS CPMG 2-site star':]\index{relaxation dispersion!NS CPMG 2-site star 
model}  The reduced model for 2-site exchange using complex conjugate matrices 
whereby the simplification $\RtwozeroA = \RtwozeroB$ is assumed.  It has the 
parameters $\{\Rtwozero, \dots, \pA, \dw, \kex\}$.  See Section~\ref{sect: 
dispersion: NS CPMG 2-site star model} on page~\pageref{sect: dispersion: NS 
CPMG 2-site star model}.
 \item[`NS CPMG 2-site star full':]\index{relaxation dispersion!NS CPMG 2-site 
star full model}  The full model for 2-site exchange using complex conjugate 
matrices with parameters $\{\RtwozeroA, \RtwozeroB, \dots, \pA, \dw, \kex\}$.  
See Section~\ref{sect: dispersion: NS CPMG 2-site star full model} on 
page~\pageref{sect: dispersion: NS CPMG 2-site star full model}.
-\item[`NS CPMG 2-site expanded':]\index{relaxation dispersion!NS CPMG 2-site 
expanded model}  A model for 2-site exchange expanded using Maple by Nikolai 
Skrynnikov \citep{Tollinger01}.  It has the parameters $\{\Rtwozero, \dots, 
\pA, \dw, \kex\}$.  See Section~\ref{sect: dispersion: NS CPMG 2-site expanded 
model} on page~\pageref{sect: dispersion: NS CPMG 2-site expanded model}.
 \end{description}
 
 
@@ -417,54 +417,6 @@
 \index{relaxation dispersion!Numeric CPMG model|textbf}
 
 
-% Full NS CPMG 2-site 3D model.
-%~~
-
-\subsection{The full NS 2-site 3D CPMG model}
-\label{sect: dispersion: NS CPMG 2-site 3D full model}
-\index{relaxation dispersion!NS CPMG 2-site 3D full model|textbf}
-
-This is the numerical model for 2-site exchange using 3D magnetisation vectors.
-It is selected by setting the model to `NS CPMG 2-site 3D full'.
-The simple constraint $\pA  \pB$ is used to halve the optimisation space, as 
both sides of the limit are mirror image spaces.
-
-
-% Reduced NS CPMG 2-site 3D model.
-%~
-
-\subsection{The reduced NS 2-site 3D CPMG model}
-\label{sect: dispersion: NS CPMG 2-site 3D model}
-\index{relaxation dispersion!NS CPMG 2-site 3D model|textbf}
-
-This is the numerical model for 2-site exchange using 3D magnetisation 
vectors, whereby the simplification $\RtwozeroA = \RtwozeroB$ is assumed.
-It is selected by setting the model to `NS CPMG 2-site 3D'.
-The simple constraint $\pA  \pB$ is used to halve the optimisation space, as 
both sides of the limit are mirror image spaces.
-
-
-% Full NS CPMG 2-site star model.
-%
-
-\subsection{The full NS 2-site star CPMG model}
-\label{sect: dispersion: NS CPMG 2-site star full model}
-\index{relaxation dispersion!NS CPMG 2-site star full model|textbf}
-
-This is the numerical model for 2-site exchange using complex conjugate 
matrices.
-It is selected by setting the model to `NS CPMG 2-site star full'.
-The simple constraint $\pA  \pB$ is used to halve the optimisation space, as 
both sides of the limit are mirror 

r21209 - /branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 12:21:54 2013
New Revision: 21209

URL: http://svn.gna.org/viewcvs/relax?rev=21209view=rev
Log:
A 20-25% speed increase for the 'NS CPMG 2-site expanded' dispersion model.

Many repetitive mathematical operations have been eliminated and the equations 
have been changed to
optimise the calculation speed.


Modified:
branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py

Modified: branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py?rev=21209r1=21208r2=21209view=diff
==
--- branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py (original)
+++ branches/relax_disp/lib/dispersion/ns_cpmg_2site_expanded.py Tue Oct 22 
12:21:54 2013
@@ -222,7 +222,7 @@
 
 # Python module imports.
 from math import log
-from numpy import add, complex, conj, dot, exp, power, real, sqrt
+from numpy import add, conj, dot, exp, power, real, sqrt
 
 # relax module imports.
 from lib.float import isNaN
@@ -258,66 +258,84 @@
 @type num_cpmg: numpy int16, rank-1 array
 
 
+# Repeditive calculations.
+half_tcp = 0.5 * tcp
+k_AB_plus_k_BA = k_AB + k_BA
+k_BA_minus_k_AB = k_BA - k_AB
+
 # The expansion factors (in numpy array form for all dispersion points).
-t3 = complex(0, 1)
+t3 = 1.j
 t4 = t3 * dw
-t5 = k_BA * k_BA
-t8 = 2.0 * t3 * k_BA * dw
+two_t4 = 2.0 * t4
+t5 = k_BA**2
+t8 = two_t4 * k_BA
 t10 = 2.0 * k_BA * k_AB
-t11 = dw * dw
-t14 = 2.0 * t3 * k_AB*dw
-t15 = k_AB * k_AB
-t17 = sqrt(t5 - t8 + t10 - t11 + t14 + t15)
-t21 = exp((-k_BA + t4 - k_AB + t17) * tcp/2.0)
+t11 = dw**2
+t14 = two_t4 * k_AB
+t15 = k_AB**2
+t5_t10_t11_t15 = t5 + t10 - t11 + t15
+t8_t14 = t8 - t14
+t17 = sqrt(t5_t10_t11_t15 - t8_t14)
+
+k_AB_plus_k_BA_minus_t4 = k_AB_plus_k_BA - t4
+t21 = exp((t17 - k_AB_plus_k_BA_minus_t4) * half_tcp)
 t22 = 1.0/t17
-t28 = exp((-k_BA + t4 - k_AB - t17) * tcp/2.0)
-t31 = t21 * t22 * k_AB - t28 * t22 * k_AB
-t33 = sqrt(t5 + t8 + t10 - t11 - t14 + t15)
-t34 = k_BA + t4 - k_AB + t33
-t37 = exp((-k_BA - t4 - k_AB + t33) * tcp)
+t28 = exp(-(t17 + k_AB_plus_k_BA_minus_t4) * half_tcp)
+t31 = t22*k_AB * (t21 - t28)
+t33 = sqrt(t5_t10_t11_t15 + t8_t14)
+
+k_AB_plus_k_BA_plus_t4 = k_AB_plus_k_BA + t4
+k_BA_minus_k_AB_plus_t4 = k_BA_minus_k_AB + t4
+t34 = k_BA_minus_k_AB_plus_t4 + t33
+t37 = exp((t33 - k_AB_plus_k_BA_plus_t4) * tcp)
 t39 = 1.0/t33
-t41 = k_BA + t4 - k_AB - t33
-t44 = exp((-k_BA - t4 - k_AB - t33) * tcp)
-t47 = t34 * t37 * t39/2.0 - t41 * t44 * t39/2.0
-t49 = k_BA - t4 - k_AB - t17
+t41 = k_BA_minus_k_AB_plus_t4 - t33
+t44 = exp(-(t33 + k_AB_plus_k_BA_plus_t4) * tcp)
+t47 = 0.5*t39 * (t34*t37 - t41*t44)
+
+k_BA_minus_k_AB_minus_t4 = k_BA_minus_k_AB - t4
+t49 = k_BA_minus_k_AB_minus_t4 - t17
 t51 = t21 * t49 * t22
-t52 = k_BA - t4 - k_AB + t17
+t52 = k_BA_minus_k_AB_minus_t4 + t17
 t54 = t28 * t52 * t22
 t55 = -t51 + t54
-t60 = t37 * t39 * k_AB - t44 * t39 * k_AB
-t62 = t31 * t47 + t55 * t60/2.0
+t60 = 0.5*t39*k_AB * (t37 - t44)
+t62 = t31*t47 + t55*t60
 t63 = 1.0/k_AB
-t68 = -t52 * t63 * t51/2.0 + t49 * t63 * t54/2.0
-t69 = t62 * t68/2.0
+t68 = 0.5*t63 * (t49*t54 - t52*t51)
+t69 = 0.5*t62 * t68
 t72 = t37 * t41 * t39
 t76 = t44 * t34 * t39
-t78 = -t34 * t63 * t72/2.0 + t41 * t63 * t76/2.0
-t80 = -t72 + t76
-t82 = t31 * t78/2.0 + t55 * t80/4.0
+t78 = 0.5*t63 * (t41*t76 - t34*t72)
+t80 = 0.5 * (t76 - t72)
+t82 = 0.5 * (t31*t78 + t55*t80)
 t83 = t82 * t55/2.0
-t88 = t52 * t21 * t22/2.0 - t49 * t28 * t22/2.0
-t91 = t88 * t47 + t68 * t60/2.0
+t88 = 0.5 * t22 * (t52*t21 - t49*t28)
+t91 = t88 * t47 + t68*t60
 t92 = t91 * t88
-t95 = t88 * t78/2.0 + t68 * t80/4.0
+t95 = 0.5 * (t88*t78 + t68*t80)
 t96 = t95 * t31
 t97 = t69 + t83
-t98 = t97 * t97
+t98 = t97**2
 t99 = t92 + t96
-t102 = t99 * t99
+t102 = t99**2
 t108 = t62 * t88 + t82 * t31
-t112 = sqrt(t98 - 2.0 * t99 * t97 + t102 + 4.0 * (t91 * t68/2.0 + t95 * 
t55/2.0) * t108)
-t113 = t69 + t83 - t92 - t96 - t112
+t112 = sqrt(t98 - 2.0 * t99 * t97 + t102 + 2.0 * (t91 * t68 + t95 * t55) * 
t108)
+t97_t99 = t97 + t99
+t97_nt99 = t97 - t99
+t113 = t97_nt99 - t112
 t115 = num_cpmg
-t116 = power(t69/2.0 + t83/2.0 + t92/2.0 + t96/2.0 + t112/2.0, t115)
+t116 = power(0.5*(t97_t99 + t112), t115)
 t118 = 1.0/t112
-t120 = t69 + t83 - t92 - t96 + t112
-t122 = power(t69/2.0 + t83/2.0 + t92/2.0 + t96/2.0 - t112/2.0, t115)
-t127 = 1.0/t108
-t139 = 1.0/(k_AB + k_BA) * ((-t113 * t116 * t118/2.0 + t120 * t122 * 
t118/2.0) * k_BA + (-t113 * t127 * 

r21210 - /branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/

2013-10-22 Thread tlinnet
Author: tlinnet
Date: Tue Oct 22 13:09:22 2013
New Revision: 21210

URL: http://svn.gna.org/viewcvs/relax?rev=21210view=rev
Log:
Modified settings script for R1rho test dataset.


Modified:

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/NOTES.txt

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py

Modified: 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/NOTES.txt
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/NOTES.txt?rev=21210r1=21209r2=21210view=diff
==
--- 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/NOTES.txt
 (original)
+++ 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/NOTES.txt
 Tue Oct 22 13:09:22 2013
@@ -172,6 +172,6 @@
   cd ..
 end
 
-# The calibration values is found from: 
Original_data/NCBD_31C_WT_0Murea_t1rho/expList.txt
-power_to_offset_Hz = {'35': 321.1, '39': 509, '41': 640.8, '43': 806.7, '46': 
1139.6, '48': 1434.7}
+# The calibration values is found from: 
Original_data/NCBD_31C_WT_0Murea_t1rho/decayFiles/expList.txt
+spin_lock_field_strengths_Hz = {'35': 431.0, '39': 651.2, '41': 800.5, '43': 
984.0, '46': 1341.11, '48': 1648.5}
 

Modified: 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt?rev=21210r1=21209r2=21210view=diff
==
--- 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
 (original)
+++ 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
 Tue Oct 22 13:09:22 2013
@@ -27,42 +27,42 @@
 0.0 
 0.0 
 0.0 
-0.981284859463 
-0.981284859463 
-0.981284859463 
-0.981284859463 
-0.981284859463 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-1.96256971893 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-3.92513943785 
-9.81284859463 
-9.81284859463 
-9.81284859463 
-9.81284859463 
-9.81284859463 
-19.6256971893 
-19.6256971893 
-19.6256971893 
-19.6256971893 
+0.625173955356 
+0.625173955356 
+0.625173955356 
+0.625173955356 
+0.625173955356 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+1.25034791071 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+2.50069582143 
+6.25173955356 
+6.25173955356 
+6.25173955356 
+6.25173955356 
+6.25173955356 
+12.5034791071 
+12.5034791071 
+12.5034791071 
+12.5034791071 

Modified: 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py?rev=21210r1=21209r2=21210view=diff
==
--- 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py
 (original)
+++ 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py
 Tue Oct 22 13:09:22 2013
@@ -5,12 +5,8 @@
 
 # The lock power to field, has been found in an calibration experiment.
 # lock_powers = [35.0, 39.0, 41.0, 43.0, 46.0, 48.0]
-spin_lock_field_strengths_Hz = {'35': 321.1, '39': 509., '41': 640.8, '43': 
806.7, '46': 1139.6, '48': 1434.7}
+spin_lock_field_strengths_Hz = {'35': 431.0, '39': 651.2, '41': 800.5, '43': 
984.0, '46': 1341.11, '48': 1648.5}
 ncycs = [0, 4, 10, 14, 20, 40]
-
-# dw(ppm) = dw(rad.s^-1) * 10^6 * 1/(2*pi) * 
(gyro1H/(gyro15N*spectrometer_freq)) = 2.45E3 * 1E6 / (2 * math.pi) * 
(26.7522212E7/(-2.7126E7 * 599.8908622E6)) = -6.41 ppm.
-gyro1H = 26.7522212E7
-gyro15N = 2.7126E7
 
 # Load the experiments settings file.
 expfile = open('exp_parameters_sort.txt','r')
@@ -37,7 +33,6 @@
 ss = int(line.split()[6])
 set_sfrq = float(line.split()[7])
 spin_lock_field_strength = spin_lock_field_strengths_Hz[dpwr2slock]
-#offset_ppm = 
 
 # Calculate spin_lock time
 time_sl = 2*ncyc*trim
@@ -63,12 

r21211 - /branches/relax_disp/docs/latex/relax.tex

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 15:13:37 2013
New Revision: 21211

URL: http://svn.gna.org/viewcvs/relax?rev=21211view=rev
Log:
Fix for the amsmath LaTeX package in the user manual.

It needs to be after the hyperref package, as hyperref clobbers a number of 
amsmath features.


Modified:
branches/relax_disp/docs/latex/relax.tex

Modified: branches/relax_disp/docs/latex/relax.tex
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/docs/latex/relax.tex?rev=21211r1=21210r2=21211view=diff
==
--- branches/relax_disp/docs/latex/relax.tex (original)
+++ branches/relax_disp/docs/latex/relax.tex Tue Oct 22 15:13:37 2013
@@ -26,10 +26,6 @@
 
 % Better Table of contents (Toc), List of figures (Lof), and List of tables 
(Lot).
 \usepackage{tocloft}
-
-% Better maths.
-\usepackage{amsmath}
-\usepackage{amssymb}
 
 % Hyperlinks.
 \usepackage[pdftitle={The relax manual}]{hyperref}
@@ -39,6 +35,10 @@
 linkcolor=blue,%
 urlcolor=blue}
 \usepackage{breakurl}
+
+% Better maths.
+\usepackage{amsmath}
+\usepackage{amssymb}
 
 % Source code and scripts.
 \usepackage[procnames]{listings}


___
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

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


r21212 - /branches/relax_disp/docs/latex/dispersion.tex

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 15:14:38 2013
New Revision: 21212

URL: http://svn.gna.org/viewcvs/relax?rev=21212view=rev
Log:
Added all of the equations for the 'NS CPMG 2-site expanded' dispersion model 
to the relax manual.

These are essentially the source code modified to look good in LaTeX.


Modified:
branches/relax_disp/docs/latex/dispersion.tex

Modified: branches/relax_disp/docs/latex/dispersion.tex
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/docs/latex/dispersion.tex?rev=21212r1=21211r2=21212view=diff
==
--- branches/relax_disp/docs/latex/dispersion.tex (original)
+++ branches/relax_disp/docs/latex/dispersion.tex Tue Oct 22 15:14:38 2013
@@ -427,6 +427,81 @@
 This is the numerical model for 2-site exchange expanded using Maple by 
Nikolai Skrynnikov.
 It is selected by setting the model to `NS CPMG 2-site expanded'.
 The simple constraint $\pA  \pB$ is used to halve the optimisation space, as 
both sides of the limit are mirror image spaces.
+
+This model will give the same results as the other numerical solutions whereby 
$\RtwozeroA = \RtwozeroB$.  The following is the set of equations of the 
expansion used in relax.  It has been modified from the original for speed.  
See the \module{lib.dispersion.ns\_cpmg\_2site\_expanded} module for more 
details including the original code.  Further simplifications can be found in 
the code.
+
+\begin{subequations}
+\begin{align}
+  t_{3} = \imath, \\
+  t_{4} = t_{3} \dw, \\
+  t_{5} = \kBA^2, \\
+  t_{8} = 2 t_{4} \kBA, \\
+ t_{10} = 2 \kBA \kAB, \\
+ t_{11} = \dw^2, \\
+ t_{14} = 2 t_{4} \kAB, \\
+ t_{15} = \kAB^2, \\
+ t_{17} = \sqrt{t_{5} - t_{8} + t_{10} - t_{11} + t_{14} + t_{15}}, \\
+ t_{21} = \exp \left(\frac{(-\kBA + t_{4} - \kAB + t_{17}) \taucpmg}{2} 
\right), \\
+ t_{22} = \frac{1}{t_{17}}, \\
+ t_{28} = \exp \left(\frac{(-\kBA + t_{4} - \kAB - t_{17}) \taucpmg}{2} 
\right), \\
+ t_{31} = t_{22} \kAB (t_{21} - t_{28}), \\
+ t_{33} = \sqrt{t_{5} + t_{8} + t_{10} - t_{11} - t_{14} + t_{15}}, \\
+ t_{34} = \kBA + t_{4} - \kAB + t_{33}, \\
+ t_{37} = \exp \left((-\kBA - t_{4} - \kAB + t_{33}) \taucpmg \right), \\
+ t_{39} = \frac{1}{t_{33}}, \\
+ t_{41} = \kBA + t_{4} - \kAB - t_{33}, \\
+ t_{44} = \exp \left((-\kBA - t_{4} - \kAB - t_{33}) \taucpmg \right), \\
+ t_{47} = \frac{t_{39}}{2} \left(t_{34} t_{37} - t_{41} t_{44} \right), \\
+ t_{49} = \kBA - t_{4} - \kAB - t_{17}, \\
+ t_{51} = t_{21} t_{49} t_{22}, \\
+ t_{52} = \kBA - t_{4} - \kAB + t_{17}, \\
+ t_{54} = t_{28} t_{52} t_{22}, \\
+ t_{55} = t_{54} - t_{51}, \\
+ t_{60} = \frac{1}{2} t_{39} \kAB \left(t_{37} - t_{44} \right), \\
+ t_{62} = t_{31} t_{47} + t_{55} t_{60}, \\
+ t_{63} = \frac{1}{\kAB}, \\
+ t_{68} = \frac{t_{63}}{2} \left(t_{49} t_{54} - t_{52} t_{51} \right), \\
+ t_{69} = \frac{t_{62} t_{68}}{2}, \\
+ t_{72} = t_{37} t_{41} t_{39}, \\
+ t_{76} = t_{44} t_{34} t_{39}, \\
+ t_{78} = \frac{t_{63}}{2} \left(t_{41} t_{76} - t_{34} t_{72} \right), \\
+ t_{80} = \frac{1}{2} (t_{76} - t_{72}), \\
+ t_{82} = \frac{1}{2} (t_{31} t_{78} + t_{55} t_{80}), \\
+ t_{83} = \frac{t_{82} t_{55}}{2}, \\
+ t_{88} = \frac{t_{22}}{2} \left(t_{52} t_{21} - t_{49} t_{28} \right), \\
+ t_{91} = t_{88} t_{47} + t_{68} t_{60}, \\
+ t_{92} = t_{91} t_{88}, \\
+ t_{95} = \frac{1}{2} (t_{88} t_{78} + t_{68} t_{80}), \\
+ t_{96} = t_{95} t_{31}, \\
+ t_{97} = t_{69} + t_{83}, \\
+ t_{98} = t_{97}^2, \\
+ t_{99} = t_{92} + t_{96}, \\
+t_{102} = t_{99}^2, \\
+t_{108} = t_{62} t_{88} + t_{82} t_{31}, \\
+t_{112} = \sqrt{t_{98} - 2 t_{99} t_{97} + t_{102} + 2 (t_{91} t_{68} + 
t_{95} t_{55}) t_{108}}, \\
+t_{113} = t_{97} - t_{99} - t_{112}, \\
+t_{115} = n_\textrm{CPMG}, \\
+t_{116} = \left( \frac{t_{97} + t_{99} + t_{112}}{2} \right)^{t_{115}}, \\
+t_{118} = \frac{1}{t_{112}}, \\
+t_{120} = t_{97} - t_{99} + t_{112}, \\
+t_{122} = \left( \frac{t_{97} + t_{99} - t_{112}}{2} \right)^{t_{115}}, \\
+t_{127} = \frac{1}{2 t_{108}}, \\
+t_{139} = \frac{1}{2(\kAB + \kBA)} \Big[ (t_{120} t_{122} - t_{113} 
t_{116}) t_{118} \kBA \nonumber \\
+ \qquad \qquad   + (t_{120} t_{122} - t_{116} 
t_{120}) t_{113} t_{118} t_{127} \kAB \Big].
+\end{align}
+\end{subequations}
+
+The relative peak intensities, magnitisation, and effective $\Rtwo$ relaxation 
rate are calculated as
+\begin{subequations}
+\begin{align}
+I_0 = \pA, \\
+I_1 = \Re(t_{139}) \exp(-T_\textrm{relax} \Rtwozero), \\
+M_x = I_1 / I_0, \\
+\Rtwoeff = -\frac{1}{T_\textrm{relax}} \cdot \ln \left( M_x \right). 
\label{eq: R2eff NS CPMG 2-site expanded}
+\end{align}
+\end{subequations}
+
+In these equations $\taucpmg$ and $n_\textrm{CPMG}$ are numpy arrays and hence 
$t_{139}$ is also a numpy array.  

r21213 - /branches/relax_disp/docs/latex/dispersion.tex

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 15:19:58 2013
New Revision: 21213

URL: http://svn.gna.org/viewcvs/relax?rev=21213view=rev
Log:
Fix for the 'NS CPMG 2-site expanded' model equations in the manual.


Modified:
branches/relax_disp/docs/latex/dispersion.tex

Modified: branches/relax_disp/docs/latex/dispersion.tex
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/docs/latex/dispersion.tex?rev=21213r1=21212r2=21213view=diff
==
--- branches/relax_disp/docs/latex/dispersion.tex (original)
+++ branches/relax_disp/docs/latex/dispersion.tex Tue Oct 22 15:19:58 2013
@@ -431,6 +431,7 @@
 This model will give the same results as the other numerical solutions whereby 
$\RtwozeroA = \RtwozeroB$.  The following is the set of equations of the 
expansion used in relax.  It has been modified from the original for speed.  
See the \module{lib.dispersion.ns\_cpmg\_2site\_expanded} module for more 
details including the original code.  Further simplifications can be found in 
the code.
 
 \begin{subequations}
+\renewcommand{\theequation}{\theparentequation .\arabic{equation}}
 \begin{align}
   t_{3} = \imath, \\
   t_{4} = t_{3} \dw, \\


___
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

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


r21214 - /branches/relax_disp/docs/latex/dispersion.tex

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 15:43:43 2013
New Revision: 21214

URL: http://svn.gna.org/viewcvs/relax?rev=21214view=rev
Log:
Better section spacing in the dispersion chapter of the manual.

Each model section is now on a new page.


Modified:
branches/relax_disp/docs/latex/dispersion.tex

Modified: branches/relax_disp/docs/latex/dispersion.tex
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/docs/latex/dispersion.tex?rev=21214r1=21213r2=21214view=diff
==
--- branches/relax_disp/docs/latex/dispersion.tex (original)
+++ branches/relax_disp/docs/latex/dispersion.tex Tue Oct 22 15:43:43 2013
@@ -214,6 +214,8 @@
 % The analytic CPMG models.
 %%%
 
+\clearpage
+
 \section{The analytic CPMG models}
 \label{sect: dispersion: analytic CPMG models}
 \index{relaxation dispersion!Analytic CPMG model|textbf}
@@ -411,6 +413,8 @@
 
 % The numeric CPMG models.
 %%
+
+\clearpage
 
 \section{The numeric CPMG models}
 \label{sect: dispersion: numeric CPMG models}
@@ -562,6 +566,8 @@
 % The analytic R1rho models.
 %%%
 
+\clearpage
+
 \section{The analytic $\Ronerho$ models}
 \label{sect: dispersion: analytic R1rho models}
 \index{relaxation dispersion!Analytic R1rho model|textbf}
@@ -635,6 +641,8 @@
 % The numeric R1rho models.
 %%%
 
+\clearpage
+
 \section{The numeric $\Ronerho$ models}
 \label{sect: dispersion: numeric R1rho models}
 \index{relaxation dispersion!Numeric R1rho model|textbf}
@@ -654,6 +662,8 @@
 
 % The analytic MQ CPMG models.
 %
+
+\clearpage
 
 \section{The analytic MQ CPMG models}
 \label{sect: dispersion: analytic MQ CPMG models}
@@ -716,6 +726,8 @@
 
 % The numeric MQ CPMG models.
 %
+
+\clearpage
 
 \section{The numeric MQ CPMG models}
 \label{sect: dispersion: numeric MQ CPMG models}


___
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

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


r21215 - /branches/relax_disp/gui/components/spectrum.py

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 18:58:57 2013
New Revision: 21215

URL: http://svn.gna.org/viewcvs/relax?rev=21215view=rev
Log:
Fix for the display of the spin-lock nu1 values in the dispersion GUI tab.

This was reported by Troels at 
http://thread.gmane.org/gmane.science.nmr.relax.devel/4708.

The GUI spectrum element at gui.components.spectrum was at fault, the 
add_disp_point() method was buggy.


Modified:
branches/relax_disp/gui/components/spectrum.py

Modified: branches/relax_disp/gui/components/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/gui/components/spectrum.py?rev=21215r1=21214r2=21215view=diff
==
--- branches/relax_disp/gui/components/spectrum.py (original)
+++ branches/relax_disp/gui/components/spectrum.py Tue Oct 22 18:58:57 2013
@@ -352,7 +352,7 @@
 self.element.SetStringItem(i, index, 
float_to_gui(cdp.cpmg_frqs[cdp.spectrum_ids[i]]))
 
 # Set the spin-lock field strength.
-if hasattr(cdp, 'spin_lock_nu1') and cdp.spectrum_ids[i] not in 
cdp.spin_lock_nu1.keys():
+if hasattr(cdp, 'spin_lock_nu1') and cdp.spectrum_ids[i] in 
cdp.spin_lock_nu1.keys():
 self.element.SetStringItem(i, index, 
float_to_gui(cdp.spin_lock_nu1[cdp.spectrum_ids[i]]))
 
 # Successful.


___
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

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


r21216 - /branches/relax_disp/gui/components/spectrum.py

2013-10-22 Thread edward
Author: bugman
Date: Tue Oct 22 19:11:51 2013
New Revision: 21216

URL: http://svn.gna.org/viewcvs/relax?rev=21216view=rev
Log:
Fix for the right click pop up menu entry Set the spin-lock field in the 
dispersion GUI tab.

This is for the spectra list relax_disp.spin_lock_field user function call.  
The reference spectra
are now detected and the field value set to None.  This fix has been propagated 
to the
relax_disp.cpmg_frq user function menu entry as well.


Modified:
branches/relax_disp/gui/components/spectrum.py

Modified: branches/relax_disp/gui/components/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/gui/components/spectrum.py?rev=21216r1=21215r2=21216view=diff
==
--- branches/relax_disp/gui/components/spectrum.py (original)
+++ branches/relax_disp/gui/components/spectrum.py Tue Oct 22 19:11:51 2013
@@ -97,14 +97,16 @@
 
 # The current frequency.
 frq = None
+frq_flag = False
 if hasattr(cdp, 'cpmg_frqs') and id in cdp.cpmg_frqs.keys():
 frq = cdp.cpmg_frqs[id]
-
-# Launch the dialog.
-if frq == None:
+frq_flag = True
+
+# Launch the dialog.
+if frq_flag:
+uf_store['relax_disp.cpmg_frq'](cpmg_frq=frq, spectrum_id=id)
+else:
 uf_store['relax_disp.cpmg_frq'](spectrum_id=id)
-else:
-uf_store['relax_disp.cpmg_frq'](cpmg_frq=frq, spectrum_id=id)
 
 
 def action_relax_disp_exp_type(self, event=None, item=None):
@@ -181,14 +183,16 @@
 
 # The spin-lock.
 nu1 = None
+nu1_flag = False
 if hasattr(cdp, 'spin_lock_nu1') and id in cdp.spin_lock_nu1.keys():
 nu1 = cdp.spin_lock_nu1[id]
-
-# Launch the dialog.
-if nu1 == None:
+nu1_flag = True
+
+# Launch the dialog.
+if nu1_flag:
+uf_store['relax_disp.spin_lock_field'](field=nu1, spectrum_id=id)
+else:
 uf_store['relax_disp.spin_lock_field'](spectrum_id=id)
-else:
-uf_store['relax_disp.spin_lock_field'](field=nu1, spectrum_id=id)
 
 
 def action_relax_fit_relax_time(self, event=None, item=None):


___
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

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


r21217 - /branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/

2013-10-22 Thread tlinnet
Author: tlinnet
Date: Tue Oct 22 20:08:52 2013
New Revision: 21217

URL: http://svn.gna.org/viewcvs/relax?rev=21217view=rev
Log:
Correcting the R1rho settings script for the right calculation of the spin-lock 
offset, omega_rf, in ppm when offset values are provided in Hz.


Modified:

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_1_ini.py

branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_3_spectra_settings.py

Modified: 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt?rev=21217r1=21216r2=21217view=diff
==
--- 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
 (original)
+++ 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/omega_rf_ppm.txt
 Tue Oct 22 20:08:52 2013
@@ -1,68 +1,68 @@
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.0 
-0.625173955356 
-0.625173955356 
-0.625173955356 
-0.625173955356 
-0.625173955356 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-1.25034791071 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-2.50069582143 
-6.25173955356 
-6.25173955356 
-6.25173955356 
-6.25173955356 
-6.25173955356 
-12.5034791071 
-12.5034791071 
-12.5034791071 
-12.5034791071 
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 0.0 118.078
+8105.0 118.078 6.16903146206 124.247031462
+8105.0 118.078 6.16903146206 124.247031462
+8105.0 118.078 6.16903146206 124.247031462
+8105.0 118.078 6.16903146206 124.247031462
+8105.0 118.078 6.16903146206 124.247031462
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 12.3380629241 130.416062924
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 24.6761258482 142.754125848
+8105.0 118.078 61.6903146206 179.768314621
+8105.0 118.078 61.6903146206 179.768314621
+8105.0 118.078 61.6903146206 179.768314621
+8105.0 118.078 61.6903146206 179.768314621
+8105.0 118.078 61.6903146206 179.768314621
+8105.0 118.078 123.380629241 241.458629241
+8105.0 118.078 123.380629241 241.458629241
+8105.0 118.078 123.380629241 241.458629241
+8105.0 118.078 123.380629241 241.458629241

Modified: 
branches/relax_disp/test_suite/shared_data/dispersion/Kjaergaard_et_al_2013/r1rho_1_ini.py
URL: