Page 1 of 1

Different Line Width for Different Transitions?

Posted: Wed Oct 25, 2023 1:28 am
by christiansen

Dear Easyspin Comminity

Are any of you aware if it is possible to apply different line widths for different transitions when calculating spectra using pepper? The "separate" output option is very convenient to look at transitions individually - perhaps one could provide an array with the same length as the number of transitions and apply line widths individually.

I do most of my EPR experiments on a home-built high-frequency setup, and line widths etc often have their own will and behave differently to what one would expect for a commercial instrument. And yes, I have checked whether strains of any kind can reproduce my observed line widths - they cannot.

Cheers,
Rasmus


Re: Different Line Width for Different Transitions?

Posted: Thu Oct 26, 2023 3:03 am
by katarkon

Yes, You should use separate outpun and 0 harmonic with zero linewidth. Follow each stick spectrum may be convoluted with the desired lineshape.


Re: Different Line Width for Different Transitions?

Posted: Thu Nov 02, 2023 3:28 am
by christiansen

This was very helpful, thank you!


Re: Different Line Width for Different Transitions?

Posted: Thu Nov 02, 2023 11:33 am
by christiansen

Follow-up question: I use Matlab's "normpdf" to generate a gaussian array for the convolution and "conv" with the kwarg "same" to perform the convolution. However, I find that the resulting spectra depend on my x-array spacing in the pdf array. Am I doing something wrong?

Code snippet

Code: Select all

% Xspc_sep is the output from pepper with the keyword 'separate', 0th harmonic and 0 line width.

mywidth = 10; %defining general line width
widths = ones(length(Xspc_sep(:,1)),1).*mywidth; %creating an Nx1 array with the width 'mywidth' for each transition. There are N transitions.
widths(28) = 1.25; %setting the width of a particular transition. The index of particular transitions may change if Hamiltonian is changes.
x = -1500:0.05:1500; %the result of the convolution depends on the spacing of this array.
for i=1:numel(widths)
    normdist = normpdf(x,0,widths(i)); % generating the lineshape for the particular transition
    absorps(:,i) = conv(Xspc_sep(i,:),normdist,'same'); %doing the convolution
    trans(:,i) = diff(absorps(:,i)); %converting to the derivative spectrum
end

total_spec = sum(trans,2);

Re: Different Line Width for Different Transitions?

Posted: Fri Nov 03, 2023 12:00 am
by katarkon

I think, the best way is using EasySpin lineshape functions like voigtian either lshape.


Re: Different Line Width for Different Transitions?

Posted: Fri Nov 03, 2023 2:04 am
by christiansen

Thank you once again! I was not aware these features were built into Easyspin. I even found 'convspec' which produces the line shape and does the convolution all in one line.


Re: Different Line Width for Different Transitions?

Posted: Tue Nov 07, 2023 1:28 am
by katarkon

Take in mind that convspec uses pseudovoightian lineshape.