How do i fit an equation to a given curve?
Mostra commenti meno recenti
I've been giving the following data.
t=[0:14]';
n=[105 118 139 164 189 214 240 265 290 316 330 348 363 369 373]';
and have been asked to fit the following two equations to this set of data.
1) N(t+1)= Nt=rNt
and
2) N(t+1)=Nt(1+r(1-Nt/k))
any advice on how to go about it. I can use polyfit and polyval to determine a fitted graph. but i have no idea how to relate it to the above equations. is there anyway i can determine an "r" value that will give me the best fitted results?
6 Commenti
Walter Roberson
il 2 Feb 2014
Could you recheck 1) ? It appears to be Nt=rNt with an assignment or comparison between the two sides.
Kyle
il 2 Feb 2014
Kyle
il 2 Feb 2014
Walter Roberson
il 2 Feb 2014
Nt+rNT -- isn't that the same as (1+r)*N(t) ?
And to check the interpretation of the other part, it is
N(t+1) = N(t)*(1+r*(1-N(t)/k))
right?
Kyle
il 2 Feb 2014
Kyle
il 2 Feb 2014
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Get Started with Curve Fitting Toolbox 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!