Doesn't plot 10^8 correctly in log fitting curve
Afficher commentaires plus anciens
Hello,
I am trying to fit data to log curve (I took the model from the matlab manual).
Everything is fine before coefficient in y reaches 10^8. At that point and beyond (10^9, 10^10) matlab doesn't fit the data.
What seems to be the problem? Screenshots of graphs attached.
Thanks you in advance!
x = [3 9 27 81 243 729 2187 6561];
y = 100000000*[0.0120 0.0360 0.1080 0.3217 0.8515 1.5367 2.0733 2.1704];
myfittype = fittype('a + b*log(x)',...
'dependent',{'y'},'independent',{'x'},...
'coefficients',{'a','b'})
myfit = fit(x',y',myfittype)
figure(1)
plot(myfit,x,y)
title('10^8 fitting')
Réponses (0)
Catégories
En savoir plus sur MATLAB dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!