Simulating pulse EPR spectra

This user guide explains how to simulate a variety of pulse EPR spectra, using EasySpin's function saffron.

saffron can simulate data from a broad range of pulse EPR experiments. Some common ones are predefined.

Others can be simulated using saffron's interface for custom user-defined pulse sequences. For this saffron employs two different algorithms to simulate pulse experiments:

The fast algorithm can accommodate a single electron spin (S=1/2 or S>1/2) coupled to an arbitrary number of magnetic nuclei. It is also limited to experiments with rectangular pulses and a single microwave carrier frequency. Relaxation is limited to T1 and T2. The fast algorithm also does not work with transient detection and more than two indirect dimensions or the modification of a pulse parameter along one of the indirect dimensions.

If any of these requirements are not met, saffron uses the slower but general thyme algorithm (named after the function that is used for propagation), which is described here.

In the following, we go over the following topics:

Look at the list of examples for more examples on how to use saffron.

Running the simulation

To simulate a pulse EPR spectrum, use EasySpin's saffron function. Its usage conforms with the other simulation functions in EasySpin. You need to provide it with two input arguments. The first one collects information about the spin system, and the second one collects information about the pulse experiment. There is an optional third input argument that allows you to set some algorithmic parameters.

Here is a simple example upfront, before we dive into more detail. Let's take a simple spin system: an electron spin coupled to a proton with a relatively weak hyperfine coupling.

Sys.g = 2;
Sys.Nucs = '1H';   % a proton
Sys.A = [2 3 6];   % MHz

For more details on spin systems and their parameters, look at the page on the spin Hamiltonian.

For the experimental information, the minimum information you need to provide is the magnetic field and the type of experiment, including its settings. For example, for

Exp.Field = 350;            % mT
Exp.Sequence = '2pESEEM';
Exp.dt = 0.005;             % µs

With these inputs, you can call the simulation function. If you don't ask for outputs, then it will plot the result. Otherwise, you get the result stored in the outputs, and no plotting is happening. For two-pulse ESSEM, a 1D experiment, the first output is the time τ, and the second output is the echo amplitude.

saffron(Sys,Exp);           % plots the results

[tau,V] = saffron(Sys,Exp);   % returns results in t (µs) and V 
plot(tau,real(V),tau,imag(V));  % plotting real and imaginary part separately
Experimental parameters

The most important parameters for a pulse EPR simulation are the magnetic field and the pulse experiment. The magnetic field is given in Exp.Field, in units of millitesla (mT):

Exp.Field = 350;   % mT

There are two ways to specify the pulse experiment. You can either use one of the built-in ones, or you can define it fully yourself. We will discuss user-defined experiments further down. For a full list of supported built-in experiments and their parameters look here. You specify them in the field Exp.Sequence.

Exp.Sequence = '2pESEEM';
Exp.Sequence = '3pESEEM';
Exp.Sequence = '4pESEEM';
Exp.Sequence = 'HYSCORE';
Exp.Sequence = 'MimsENDOR';

In these pre-defined pulse sequence, all microwave pulses are treated as ideal (infinitely short, infinite bandwidth). The RF pulse in Mims ENDOR is assumed to have infinitely narrow excitation bandwidth. Each of these pre-defined pulse experiments needs additional parameters. If you run any of the ESEEM/HYSCORE experiments, then you need to provide a time increment interval in Exp.dt. Note that the units are microseconds, not nanoseconds.

Exp.dt = 0.010;    % microseconds; equal to 10 ns

For the two-dimensional HYSCORE experiment, saffron uses Exp.dt for both dimensions.

Next, you need to specify whatever additional parameters are required for the pre-defined experiment you selected. For the ESEEM and HYSCORE experiments, these include initial inter-pulse delays:

% Two-pulse ESEEM
Exp.tau = 0.080;   % initial tau value, in µs

% Three-pulse ESEEM, four-pulse ESEEM
Exp.tau = 0.120;   % fixed tau value, in µs
Exp.T = 0.100;     % initial T value, in µs

% HYSCORE
Exp.tau = 0.130;   % fixed tau value, in µs
Exp.t1 = 0.100;    % initial value of t1, in µs
Exp.t2 = 0.100;    % initial value of t2, in µs

For Mims ENDOR, you must specify the frequency range in Exp.Range, in units of MHz:

Exp.Range = [2 20];     % RF range, MHz

Further, you can specify the number of points. This is done in Exp.nPoints. If you don't give it, EasySpin uses a default value.

Exp.nPoints = 200;        % for 1D experiments
Exp.nPoints = [200 200];  % for 2D experiments with equal dimensions
Exp.nPoints = [200 100];  % for 2D experiments with unequal dimensions
Orientation selection

By default, all pulses are assumed to have infinite excitation bandwidth. This means that you will get a full powder spectrum, no matter what microwave frequency you are using. However, in practice, microwave pulse excitation bandwidths do not exceed 100 MHz or so. As a consequence, only spins within a subset of orientations in a powder sample are excited. This is referred to as orientation selection. Often, the limited excitation bandwidth also results in selective excitation of certain EPR transitions. This is termed transition selection.

Let's look at how orientation and transition selection can be accounted for in a simulation. The excitation bandwidth of a rectangular pulse is determined by its length. You can give finite pulse lengths when specifying the pulse experiment yourself, see below. However, when using the built-in experiment definitions, this is not possible. Instead, saffron offers a simple mechanism to include effects of orientation selection using the field Exp.ExciteWidth. The excitation profile of the first pulse in the sequence is approximated as Gaussian, and Exp.ExciteWidth is its full width at half maximum (FWHM), in MHz.

Exp.ExciteWidth = 50;    % FWHM of Gaussian excitation profile, in MHz

With limited pulse excitation bandwidth, it is now necessary to specify the microwave pulse carrier frequency. As elsewhere in EasySpin, this is in units of GHz.

Exp.mwFreq = 9.5;   % GHz

Both Exp.ExciteWidth and Exp.mwFreq are necessary to obtain orientation selection. If your excitation bandwidth is narrow, and your magnetic field/microwave frequency settings are off-resonant relative to any EPR transition, you won't get any intensity in your pulse EPR spectrum.

Fast user-defined experiments

saffron allows you specify your own custom pulse sequence. For this, you need to provide full details about pulses, delays and incrementation. A pulse experiment is specified in two parts: the pulse sequence and the indirect dimensions. Together, they fully specify the pulse experiment.

To specify the pulse sequence, you need to provide details about each (rectangular) pulse and its temporal placement relative to the preceding one. Each pulse needs a flip angle and, if you want to use real pulses, a duration. Pulses need to be defined separately Par.and can then be combined with delays in Exp.Sequence. The flip angles go into Par.Flip, in radians:

% Create two ideal pulses:
p90.Flip = pi/2; 
p180.Flip = pi; 

% Two-pulse ESEEM sequence with ideal pulses
tau = 0.1; % start value for tau
Exp.Sequence = {p90 tau p180 tau};  % 90° - tau - 180° -  tau;

For real pulses, durations are expected in Par.tp, in units of microseconds:

% Create two real pulses:
p90real.Flip = pi/2;  % flip angle
p90real.tp = 0.01; % length of pulse in microseconds

p180real.Flip = pi; % flip angle 
p180real.tp = 0.02; % length of pulse in microseconds

% HYSCORE sequence with real pulses
tau = 0.1; % length of first interpulse delay in microseconds
t1 = 0; % start value for t1 
t2 = 0; % start value for t2 

Exp.Sequence = {p90real tau p90real t1 p180real t2 p90real tau};      % 90° - tau - 90° - t1 - 180° - t2 - 90° - tau;

Omitting Par.tp or setting it to zero corresponds to a zero-length pulse with infinite excitation bandwidth and flip angle given in Par.Flip.

If you have pulses with different phases, specify the phases in Par.Phase. Again, give it in radians;

p90.Phase = pi/2 % set phase to +y
p180real.Phase = pi; % set phase to -x

This defines the pulse sequence. Next, we need to define the incrementation scheme. This includes specifying which pulse intervals are incremented or decremented, and which dimension in the data the incrementation should count for. The fast algorithm only supports in/ or decrementation of delays along a maximum of two indirect dimensions. How to change pulse parameters or run experiments with more than two indirect dimensions is discussed here.

For this, use the field Exp.Dim1 for a one-dimensional experiment or Exp.Dim1 and Exp.Dim2 for a two-dimensional experiment. Each entry first has a character array that identifies the delay you want to change, which is followed by the size of the increment for each step in microseconds. For delays, the character array has to have the form 'dx' where d stands for 'delay' and x for a number that corresponds to the index of the delay, e.g. 'd1' is the first delay in Exp.Sequence. Here are a few examples:

% One dimensional experiment:
Exp.Dim1 = {'d1' 0.01}; % increment the first delay by 10 ns each step

% Two dimensional experiment:
Exp.Dim1 = {'d2' 0.01}; % increment 2nd delay by 10 ns along the 1st dimension
Exp.Dim2 = {'d3' 0.02}; % increment 3rd delay by 10 ns along the 2nd dimension

It is also possible to change two or more delays within one dimension:

% Increment two delays equally:
Exp.Dim1 = {'d1,d2' 0.01}; % increment the 1st and 2nd delay by 10 ns

% Increment two delays with different dt:
Exp.Dim1 = {'d1' 0.01; 'd2' 0.03 }; 

If you want to decrement an interval instead of incrementing it, use negative signs. For, example, the following gives a one-dimensional incrementation scheme where the second interval is incremented and the third one is decrement at the same time. This gives a fixed-length pulse experiment.

Exp.Dim1 = {'d2' 0.01;'d3' -0.01};    % combination of increment and decrement

Keep in mind, the starting values (the first data points) are always the ones given in Exp.Sequence.

The last thing that is missing is to tell saffron the number of data points along each indirect dimension. This is done with Exp.nPoints. For a two-dimensional experiment the points of both dimensions must be specified:

Exp.nPoints = 200;        % for 1D experiments
Exp.nPoints = [200 200];  % for 2D experiments with equal dimensions
Exp.nPoints = [200 100];  % for 2D experiments with unequal dimensions

With all this, the manual definition of a three-pulse ESEEM experiment could look like this:

% Spin system
Sys.S = 1/2;
Sys.Nucs = '1H';
Sys.A_ = [5 2];

% Experiment definition
p90.Flip = pi/2; % by providing only a flip angle, pulses are ideal
tau = 0.4;

Exp.Field = 350;
Exp.Sequence = {p90 tau p90 0 p90 tau}; % three pulse ESEEM sequence, the
					% starting value for the 2nd delay is 0

Exp.nPoints = 512;        % 512 data points
Exp.Dim1 = {'d2', 0.1}; % increment 2nd delay by 8 ns 

saffron(Sys,Exp);

For more settings, such as coherence filters, see the reference page on saffron.

Single crystals

By default, saffron simulates powder spectra. But just like all other EasySpin simulation functions, it can also handle single crystals. For this, use the fields Exp.SampleFrame (for the crystal orientation in the spectrometer) and Exp.CrystalSymmetry (for the space group of the crystal, optional):

Exp.SampleFrame = [0 -pi/2 0];    % single crystal, crystal x axis parallel to the static field

For more details, see the pages on frames and crystal simulations.

Options

saffron has a range of settings that can be used to adjust the level of theory and other aspects of the simulation. These are provided in the third input argument to saffron, usually called Opt. One of the most often neede parameters is Opt.GridSize, which specifies the resolution of the orientational grid used for powder simulations. The higher the number in Opt.GridSize, the finer the grid.

Opt.GridSize = 19;   % 5° increments
Opt.GridSize = 31;   % 3° increments
Opt.GridSize = 46;   % 2° increments
Opt.GridSize = 91;   % 1° increments

By default, EasySpin uses a mid-range resolution. For systems with very anisotropic tensors, it is often necessary to manually increase Opt.GridSize to get fully converged spectra.

Another useful setting concerns the "product rule". This rule states that ESEEM traces from a spin system with multiple nuclei can be approximated as sums of products of the ESEEM traces from single-nucleus subsystems. Using the product rule is an approximation (except for ideal pulses), but can substantially speed up simulations for multi-nuclear systems. By default, it is not used. To activate it, use

Opt.ProductRule = 1;    % use product rule approximation

For other settings, included settings for data processing and display, see the reference page on saffron.

Adding relaxation

It is possible to add relaxation to pre-defined experimental sequences. For this, give scalar longitudinal and transverse relaxation time constants (T1, T2) in Sys.T1 and Sys.T2. If either of the two fields is omitted or set to zero, it is ignored.

The following example shows how to add decay to a two-pulse sequence:

Exp.Sequence = '2pESEEM';
Exp.Field = 324.9;
Exp.dt = 0.010;

Sys.Nucs = '14N';
nuI = larmorfrq(Sys.Nucs,Exp.Field);
Sys.A = 2*nuI;
Sys.Q = [4*0.1*nuI, 0.6];
Sys.T1 = 4; % adds longitudinal relaxation
Sys.T2 = 2; % adds transverse relaxation (phase memory time)

To include transition-selective relaxation times, the slower thyme method must be used (see corresponding user guide).