Difference between revisions of "Masdnp.m"

From Spinach Documentation Wiki
Jump to: navigation, search
(Notes)
(Update function See also links and function index membership)
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Magic angle spinning DNP simulation.
+
{{DISPLAYTITLE:masdnp.m}} __NOTOC__
 +
Magic angle spinning DNP simulation, returning the rotor period averaged steady state magnetization. This function takes a lot of inspiration from the code donated by Fred Mentink, please cite Fred's papers if you are using it.
  
 
==Syntax==
 
==Syntax==
Line 5: Line 6:
 
     dnp=masdnp(spin_system,parameters)
 
     dnp=masdnp(spin_system,parameters)
  
==Description==
+
==Parameters==
The function returns the rotor period averaged steady state magnetization. The implementation takes a lot of inspiration from the code donated by [[Frederic Mentink-Vigier]], please cite Fred's papers (http://dx.doi.org/10.1016/j.jmr.2015.07.001 and http://dx.doi.org/10.1016/j.jmr.2012.08.013) if you are using it.
 
  
==Arguments==
+
     parameters.spins     -  the spins to microwave
 
 
     parameters.spins   a cell array of strings listing the spins to
 
                            which the parameters.offset variable refers
 
 
   
 
   
     parameters.rate     -  spinning rate, Hz
+
     parameters.rate     -  spinning rate, Hz
 
   
 
   
     parameters.axis     -  spinning axis direction vector.
+
     parameters.axis     -  spinning axis direction vector.
 
   
 
   
     parameters.max_rank -  rotor discretization grid rank, typically in the thousands
+
     parameters.max_rank -  rotor discretization grid rank
 
   
 
   
     parameters.mw_pwr   -  microwave power, Hz
+
     parameters.mw_pwr   -  microwave power, rad/s
 
   
 
   
     parameters.mw_frq   -  microwave frequency, Hz
+
     parameters.mw_frq   -  microwave frequency, Hz
 
   
 
   
     parameters.eq_time  equilibration time, seconds
+
     parameters.mw_time  microwave irradiation duration
 +
                            before the average magnetistion
 +
                            is computed, seconds
 
   
 
   
     parameters.grid     -  the name of the spherical averaging grid
+
     parameters.grid     -  the name of the spherical avera-
 +
                            ging grid
 
   
 
   
     parameters.coil     -  detection state
+
     parameters.coil     -  detection state
 
   
 
   
     parameters.verbose -  set this to 1 to enable diagnostic output
+
     parameters.verbose   -  set this to 1 to enable diag-
 +
                            nostic output
  
==Returns==
+
==Outputs==
The function returns the steady state population of the detection state.
+
 
 +
    dnp - enhancement of the user-specified state relative to
 +
          the thermal equilibrium
  
 
==Examples==
 
==Examples==
Line 50: Line 53:
  
 
==Notes==
 
==Notes==
# The steep transitions visible in the figures above necessitate very large rotor grids, typically thousands of points. Our attempts at reducing this number have not been successful.
+
# Increase the rotor rank and the spherical grid size until the answer stops changing. You will likely need huge values for both parameters.
# Because DNP simulations involve strong anisotropic interactions acting for a long time, large powder averaging grids are likely to be needed. Always check that your calculation is converged with respect to the size of the spherical grid.
+
# This function must be called directly, without a context wrapper.
  
 
==See also==
 
==See also==
[[dnp_field_scan.m]], [[dnp_freq_scan.m]], [[solid_effect.m]]
+
[[beamdnp.m]], [[dnp_field_scan.m]], [[dnp_freq_scan.m]], [[dnp_time_dep.m]], [[noveldnp.m]], [[noveldnp_steady.m]], [[solid_effect.m]], [[topdnp.m]], [[xixdnp.m]], [[xixdnp_steady.m]], [[Built-in_experiments]]
 
 
  
''Revision 3284, authors: [[Frederic Mentink-Vigier]], [[Ilya Kuprov]]''
+
''Version 2.5, authors: [[Frederic Mentink-Vigier]], [[Ilya Kuprov]]''

Latest revision as of 19:38, 6 June 2026

Magic angle spinning DNP simulation, returning the rotor period averaged steady state magnetization. This function takes a lot of inspiration from the code donated by Fred Mentink, please cite Fred's papers if you are using it.

Syntax

    dnp=masdnp(spin_system,parameters)

Parameters

    parameters.spins     -  the spins to microwave

    parameters.rate      -  spinning rate, Hz

    parameters.axis      -  spinning axis direction vector.

    parameters.max_rank  -  rotor discretization grid rank

    parameters.mw_pwr    -  microwave power, rad/s

    parameters.mw_frq    -  microwave frequency, Hz

    parameters.mw_time   -  microwave irradiation duration 
                            before the average magnetistion
                            is computed, seconds

    parameters.grid      -  the name of the spherical avera-
                            ging grid

    parameters.coil      -  detection state

    parameters.verbose   -  set this to 1 to enable diag-
                            nostic output

Outputs

    dnp - enhancement of the user-specified state relative to
          the thermal equilibrium

Examples

A detailed walkthough for solid effect and cross effect MAS DNP is given in the example set. For a simple three-spin system discussed in Fred's paper, cross_effect_mas_enlev.m returns the rotor phase dependence of the energy levels in the system:

Dnp example 5.png

The energy level population dynamics during the first rotor cycle is returned by cross_effect_mas_dynam.m example:

Dnp example 6.png

The energy level population dynamics during the steady state rotor cycle is returned by cross_effect_mas_steady.m example:

Dnp example 7.png

and finally the steady state rotor-averaged, powder-averaged DNP amplitude is returned by a call to this function in cross_effect_mas_powder.m example file.

Notes

  1. Increase the rotor rank and the spherical grid size until the answer stops changing. You will likely need huge values for both parameters.
  2. This function must be called directly, without a context wrapper.

See also

beamdnp.m, dnp_field_scan.m, dnp_freq_scan.m, dnp_time_dep.m, noveldnp.m, noveldnp_steady.m, solid_effect.m, topdnp.m, xixdnp.m, xixdnp_steady.m, Built-in_experiments

Version 2.5, authors: Frederic Mentink-Vigier, Ilya Kuprov