Curve fitting multiple parameters function
6 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hello,
I have a set of data that fits a defined curve fitting function model as
I = a*exp(-bx)+c;
the parameters a, b and c depends on a function r, say (a,b,c) = f(r)
My defined function I also depends on another parameter k , say (a,b,c) = f(k)
How can I define single function that that depends on both k and r, say
I = f(a,b,c)
I = a*exp(-bx)+c
(a,b,c) = f(k,r)
Thank you
2 commentaires
Sambit Supriya Dash
le 15 Août 2021
Could you elaborate more the question with funs. or with some similar examples ?
Réponses (1)
Sulaymon Eshkabilov
le 16 Août 2021
You can write a function file or function handle, e.g.:
F=@(k, r, x)(2*r*k*exp(0.576*k*x)+c); % etc.
% OR
function F = MyFun(k,r, x)
F = (2*r*k*exp(0.576*k*x)+c);
end
2 commentaires
Voir également
Catégories
En savoir plus sur Get Started with Curve Fitting Toolbox dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!