Error from Using easfit with Multicomponent
Posted: Sat Aug 10, 2019 12:47 am
I've an error when I constructed 2 systems in easyspin-5.2.25 that affacted by few protons. Here is my code
After I complied this code, I got an error about using hyperfine nucleus;
[/color]
What should I prove my code?
Code: Select all
clear all
clc;
[numbers,strings] = xlsread('RAWDATA','RAWDATA');
XDATA = numbers(:,1);
YDATA = datasmooth(numbers(:,3),40,'binom');
FitOpt.Method = 'simplex';
FitOpt.Scaling = 'maxabs';
AmT2MHz = 10*4.258; % A[mT] to A[MHz]
type1.S = 1/2;
type1.g = [2.0071 1.9944];
type1.Nucs = '1H, 1H, 1H';
type1.A = [1.1*AmT2MHz, 0.5*AmT2MHz, 0.35*AmT2MHz]; %MHz
type1.lwpp = [0 0.2];
type1.weight = 50;
Vary_type1.weight = 25;
Vary_type1.lwpp = [0 1];
type2.S = 1/2;
type2.g = [2.0069 2.0057];
type2.Nucs = '1H';
type2.A = [0.72*AmT2MHz 0.72*AmT2MHz 0.72*AmT2MHz];
type2.lwpp = [0 0.71];
type2.weight = 50;
Vary_type2.weight = 25;
Vary_type2.lwpp = [0 1];
type3.g = [2.0013 2.0013];
type3.lwpp = [0 0.17];
type3.weight = 50;
Exp.mwFreq = 9.849740;
Exp.Range = [min(XDATA/10) max(XDATA/10)];
fitparams = esfit('pepper',YDATA,{type1,type2},{Vary_type1,Vary_type2},Exp,[],FitOpt);
[Bsim,spcsim] = pepper({fitparams},Exp);
Bsim_n = (Bsim*10);
spcsim_n = ((spcsim)*max(YDATA))/max(spcsim);
figure(1); clf;
plot(XDATA, YDATA, Bsim_n, spcsim_n,'-.r','LineWidth', 1.25);
legend('Typical Measurement', 'Simulation');
xlim(Exp.Range*10);
xlabel('Magnetic Filed (G)');
ylabel('ESR signal intensity (a.u.)');
title('Simulation');
Code: Select all
Error using isotopologues
List of nuclei must be a string (e.g. 'Cu,Cl,H,H').
Error in pepper
What should I prove my code?