Author: bugman Date: Mon Jun 10 15:48:36 2013 New Revision: 20014 URL: http://svn.gna.org/viewcvs/relax?rev=20014&view=rev Log: Added the support for the tex parameter (tex = 1/(2kex)) to the dispersion specific analysis. This is needed for the Ishima and Torchia 1999 2-site model for all timescales with pA >> pB. This commit follows step 5 of the relaxation dispersion model addition tutorial (http://thread.gmane.org/gmane.science.nmr.relax.devel/3907). Modified: branches/relax_disp/specific_analyses/relax_disp/__init__.py branches/relax_disp/specific_analyses/relax_disp/parameters.py Modified: branches/relax_disp/specific_analyses/relax_disp/__init__.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/__init__.py?rev=20014&r1=20013&r2=20014&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/__init__.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/__init__.py Mon Jun 10 15:48:36 2013 @@ -100,6 +100,7 @@ self.PARAMS.add('padw2', scope='spin', default=1.0, desc='The pA.dw**2 value (ppm^2)', set='params', py_type=float, grace_string='\\qp\\sA\\N.\\xDw\\B\\S2\\N\\Q (ppm\\S2\\N)', err=True, sim=True) self.PARAMS.add('dw', scope='spin', default=0.0, desc='The chemical shift difference between states A and B (in ppm)', set='params', py_type=float, grace_string='\\q\\xDw\f{}\\Q (ppm)', err=True, sim=True) self.PARAMS.add('kex', scope='spin', default=10000.0, desc='The exchange rate', set='params', py_type=float, grace_string='\\qk\\sex\\N\\Q (rad.s\\S-1\\N)', err=True, sim=True) + self.PARAMS.add('tex', scope='spin', default=1.0/20000.0, desc='The time of exchange (tex = 1/(2kex))', set='params', py_type=float, grace_string='\\q\\xt\\B\\sex\\N\\Q (s.rad\\S-1\\N)', err=True, sim=True) self.PARAMS.add('r2a', scope='spin', default=15.0, desc='The transversal relaxation rate for state A', set='params', py_type=float, grace_string='\\qR\\s2,A\\N\\Q (rad.s\\S-1\\N)', err=True, sim=True) self.PARAMS.add('ka', scope='spin', default=10000.0, desc='The exchange rate from state A to state B', set='params', py_type=float, grace_string='\\qk\\sA\\N\\Q (rad.s\\S-1\\N)', err=True, sim=True) self.PARAMS.add('params', scope='spin', desc='The model parameters', py_type=list) @@ -416,6 +417,11 @@ elif spin.params[i] in ['kex', 'ka']: lower.append(1.0) upper.append(100000.0) + + # Time of exchange. + elif spin.params[i] in ['tex']: + lower.append(1/200000.0) + upper.append(0.5) # The full grid size. grid_size = 1 @@ -1584,6 +1590,7 @@ _table.add_row(["Chemical shift difference between states A and B (ppm)", "'dw'"]) _table.add_row(["Exchange rate (rad/s)", "'kex'"]) _table.add_row(["Exchange rate from state A to state B (rad/s)", "'ka'"]) + _table.add_row(["Time of exchange (s/rad)", "'tex'"]) _table.add_row(["Peak intensities (series)", "'intensities'"]) _table.add_row(["CPMG pulse train frequency (series, Hz)", "'cpmg_frqs'"]) return_data_name_doc.add_table(_table.label) Modified: branches/relax_disp/specific_analyses/relax_disp/parameters.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/parameters.py?rev=20014&r1=20013&r2=20014&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/parameters.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/parameters.py Mon Jun 10 15:48:36 2013 @@ -156,6 +156,10 @@ elif param_name in ['kex', 'ka']: scaling_matrix[param_index, param_index] = 10000 + # Time of exchange scaling. + elif param_name == 'tex': + scaling_matrix[param_index, param_index] = 1e4 + # Return the scaling matrix. return scaling_matrix @@ -257,6 +261,7 @@ padw2 >= 0 dw >= 0 kex >= 0 + tex >= 0 kA >= 0 @@ -274,9 +279,9 @@ | 1 0 0 | | pA | | 0.5 | | | | | | | |-1 0 0 | | pA | | -1 | + | | | | | | + | 1 0 0 | | pA | | 0.85 | | | . | | >= | | - | 1 0 0 | | pA | | 0.85 | - | | | | | | | 1 0 0 | | phi_ex | | 0 | | | | | | | | 1 0 0 | | padw2 | | 0 | @@ -284,6 +289,8 @@ | 1 0 0 | | dw | | 0 | | | | | | | | 1 0 0 | | kex | | 0 | + | | | | | | + | 1 0 0 | | tex | | 0 | | | | | | | | 1 0 0 | | kA | | 0 | @@ -376,8 +383,8 @@ b.append(0.5 / scaling_matrix[param_index, param_index]) j += 1 - # Exchange rates (k >= 0). - elif param_name in ['kex', 'ka']: + # Exchange rates and times (k >= 0 and t >= 0). + elif param_name in ['kex', 'ka', 'tex']: A.append(zero_array * 0.0) A[j][param_index] = 1.0 b.append(0.0)