Fitting multiple exponential function .
Mostra commenti meno recenti
I am trying to fit my experimental data with the following function, where T is temperature and rest all are fitting parameter.

I am using following matlab code for fitting.
fun = @(x)shibita_fitting(x,data)
x0=[8000 2000 0.1 10^3 0.5 10^3 0.1];
bestx = fminsearch(fun,x0)
where fitting function is defined as
function sse = shibita_fitting(x,data)
a = x(1);
d=x(2);
e1=x(3);
c1=x(4);
E1=x(5);
c2=x(6);
E2=x(7);
T=data(:,1);
I=data(:,2);
I_new=a* (1+d*exp(-e1./T))./(1+c1*exp(-E1./T)+c2*exp(-E2./T));
sse = sum((I - I_new).^2);
The result of fitting is displayed below. The fitting is following the trend but it is not able to reproduce the kink near T=50.
Please suggest.

3 Commenti
I am skeptical that your equation model can capture the kink. Your equation model is smooth, differentiable function. The trend near the kink is not.
In any case, it might be better to use lsqcurvefit, if you have the appropriate toolbox. You have a number of unknowns that strains what fminsearch was designed for.
Mathieu NOE
il 7 Giu 2023
are you sure your model is capable of reproducing that kink ?
also , on complex models, fminsearch is very sensitive to x0 values. If you are a bit too off, the convergence is poor
you may have to use a more robust tool.
Saroj Poudyal
il 7 Giu 2023
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Choose a Solver in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
