[frames] | no frames]

# Module ns_matrices

source code

A collection of functions for generating the relaxation matrices for the numerical solutions.

These are for the numerical solutions to the Bloch-McConnell equations for relaxation dispersion.

 Functions
numpy rank-2, 4D array
 r180x_2d(flip=3.14159265359) The 2D rotation matrix for an imperfect X-axis pi-pulse. source code
numpy rank-2, 7D array
 r180x_3d(flip=3.14159265359) The 3D rotation matrix for an imperfect X-axis pi-pulse. source code
numpy rank-2, 4D array
 rcpmg_2d(R2A=None, R2B=None, dw=None, k_AB=None, k_BA=None) Definition of the 2D exchange matrix. source code
numpy rank-2, 7D array
 rcpmg_3d(R1A=None, R1B=None, R2A=None, R2B=None, pA=None, pB=None, dw=None, k_AB=None, k_BA=None) Definition of the 3D exchange matrix. source code

 rmmq_2site(matrix=None, R20A=None, R20B=None, dw=None, k_AB=None, k_BA=None) The Bloch-McConnell matrix for 2-site exchange. source code

 rmmq_3site(matrix=None, R20A=None, R20B=None, R20C=None, dw_AB=None, dw_AC=None, k_AB=None, k_BA=None, k_BC=None, k_CB=None, k_AC=None, k_CA=None) The Bloch-McConnell matrix for 3-site exchange. source code

 rr1rho_3d_2site(matrix=None, R1=None, r1rho_prime=None, pA=None, pB=None, wA=None, wB=None, w1=None, k_AB=None, k_BA=None) Definition of the 3D exchange matrix. source code

 rr1rho_3d_3site(matrix=None, R1=None, r1rho_prime=None, pA=None, pB=None, pC=None, wA=None, wB=None, wC=None, w1=None, k_AB=None, k_BA=None, k_BC=None, k_CB=None, k_AC=None, k_CA=None) Definition of the 3D exchange matrix. source code
 Variables
__package__ = `'lib.dispersion'`

Imports: cos, sin, pi, array, float64, matrix

 Function Details

### r180x_2d(flip=3.14159265359)

source code

The 2D rotation matrix for an imperfect X-axis pi-pulse.

Parameters:
• `flip` (float) - The X-axis pi-pulse flip angle (in rad). This is currently unused, hence perfect pi-pulses are assumed.
Returns: numpy rank-2, 4D array
The 2D rotational matrix.

### r180x_3d(flip=3.14159265359)

source code

The 3D rotation matrix for an imperfect X-axis pi-pulse.

Parameters:
• `flip` (float) - The X-axis pi-pulse flip angle (in rad).
Returns: numpy rank-2, 7D array
The 3D rotational matrix.

### rcpmg_2d(R2A=None, R2B=None, dw=None, k_AB=None, k_BA=None)

source code

Definition of the 2D exchange matrix.

Parameters:
• `R2A` (float) - The transverse, spin-spin relaxation rate for state A.
• `R2B` (float) - The transverse, spin-spin relaxation rate for state B.
• `dw` (float) - The chemical exchange difference between states A and B in rad/s.
• `k_AB` (float) - The forward exchange rate from state A to state B.
• `k_BA` (float) - The reverse exchange rate from state B to state A.
Returns: numpy rank-2, 4D array
The relaxation matrix.

### rcpmg_3d(R1A=None, R1B=None, R2A=None, R2B=None, pA=None, pB=None, dw=None, k_AB=None, k_BA=None)

source code

Definition of the 3D exchange matrix.

Parameters:
• `R1A` (float) - The longitudinal, spin-lattice relaxation rate for state A.
• `R1B` (float) - The longitudinal, spin-lattice relaxation rate for state B.
• `R2A` (float) - The transverse, spin-spin relaxation rate for state A.
• `R2B` (float) - The transverse, spin-spin relaxation rate for state B.
• `pA` (float) - The population of state A.
• `pB` (float) - The population of state B.
• `dw` (float) - The chemical exchange difference between states A and B in rad/s.
• `k_AB` (float) - The forward exchange rate from state A to state B.
• `k_BA` (float) - The reverse exchange rate from state B to state A.
Returns: numpy rank-2, 7D array
The relaxation matrix.

### rmmq_2site(matrix=None, R20A=None, R20B=None, dw=None, k_AB=None, k_BA=None)

source code

The Bloch-McConnell matrix for 2-site exchange.

Parameters:
• `matrix` (numpy rank-2, 2D complex128 array) - The matrix to populate.
• `R20A` (float) - The transverse, spin-spin relaxation rate for state A.
• `R20B` (float) - The transverse, spin-spin relaxation rate for state B.
• `dw` (float) - The combined chemical exchange difference parameters between states A and B in rad/s. This can be any combination of dw and dwH.
• `k_AB` (float) - The rate of exchange from site A to B (rad/s).
• `k_BA` (float) - The rate of exchange from site B to A (rad/s).

### rmmq_3site(matrix=None, R20A=None, R20B=None, R20C=None, dw_AB=None, dw_AC=None, k_AB=None, k_BA=None, k_BC=None, k_CB=None, k_AC=None, k_CA=None)

source code

The Bloch-McConnell matrix for 3-site exchange.

Parameters:
• `matrix` (numpy rank-2, 3D complex128 array) - The matrix to populate.
• `R20A` (float) - The transverse, spin-spin relaxation rate for state A.
• `R20B` (float) - The transverse, spin-spin relaxation rate for state B.
• `R20C` (float) - The transverse, spin-spin relaxation rate for state C.
• `dw_AB` (float) - The combined chemical exchange difference parameters between states A and B in rad/s. This can be any combination of dw and dwH.
• `dw_AC` (float) - The combined chemical exchange difference parameters between states A and C in rad/s. This can be any combination of dw and dwH.
• `k_AB` (float) - The rate of exchange from site A to B (rad/s).
• `k_BA` (float) - The rate of exchange from site B to A (rad/s).
• `k_BC` (float) - The rate of exchange from site B to C (rad/s).
• `k_CB` (float) - The rate of exchange from site C to B (rad/s).
• `k_AC` (float) - The rate of exchange from site A to C (rad/s).
• `k_CA` (float) - The rate of exchange from site C to A (rad/s).

### rr1rho_3d_2site(matrix=None, R1=None, r1rho_prime=None, pA=None, pB=None, wA=None, wB=None, w1=None, k_AB=None, k_BA=None)

source code

Definition of the 3D exchange matrix.

This code originates from the funNumrho.m file from the Skrynikov & Tollinger code (the sim_all.tar file https://web.archive.org/web/https://gna.org/support/download.php?file_id=18404 attached to https://web.archive.org/web/https://gna.org/task/?7712#comment5).

Parameters:
• `matrix` (numpy rank-2 6D array) - The matrix to fill.
• `R1` (float) - The longitudinal, spin-lattice relaxation rate.
• `r1rho_prime` (float) - The R1rho transverse, spin-spin relaxation rate in the absence of exchange.
• `pA` (float) - The population of state A.
• `pB` (float) - The population of state B.
• `wA` (float) - The chemical shift offset of state A from the spin-lock.
• `wB` (float) - The chemical shift offset of state A from the spin-lock.
• `w1` (float) - The spin-lock field strength in rad/s.
• `k_AB` (float) - The forward exchange rate from state A to state B.
• `k_BA` (float) - The reverse exchange rate from state B to state A.

### rr1rho_3d_3site(matrix=None, R1=None, r1rho_prime=None, pA=None, pB=None, pC=None, wA=None, wB=None, wC=None, w1=None, k_AB=None, k_BA=None, k_BC=None, k_CB=None, k_AC=None, k_CA=None)

source code

Definition of the 3D exchange matrix.

Parameters:
• `matrix` (numpy rank-2 9D array) - The matrix to fill.
• `R1` (float) - The longitudinal, spin-lattice relaxation rate.
• `r1rho_prime` (float) - The R1rho transverse, spin-spin relaxation rate in the absence of exchange.
• `pA` (float) - The population of state A.
• `pB` (float) - The population of state B.
• `pC` (float) - The population of state C.
• `wA` (float) - The chemical shift offset of state A from the spin-lock.
• `wB` (float) - The chemical shift offset of state B from the spin-lock.
• `wC` (float) - The chemical shift offset of state C from the spin-lock.
• `w1` (float) - The spin-lock field strength in rad/s.
• `k_AB` (float) - The forward exchange rate from state A to state B.
• `k_BA` (float) - The reverse exchange rate from state B to state A.
• `k_BC` (float) - The forward exchange rate from state B to state C.
• `k_CB` (float) - The reverse exchange rate from state C to state B.
• `k_AC` (float) - The forward exchange rate from state A to state C.
• `k_CA` (float) - The reverse exchange rate from state C to state A.

 Generated by Epydoc 3.0.1 on Fri Jun 14 11:29:05 2019 http://epydoc.sourceforge.net