How to apply curve fitting with a model where y shows up on both sides of the equation.
Ältere Kommentare anzeigen
I have a set of data to fit with the following equation: y=a*(((4*(1-x/b+y/c))^-2)-0.25+x/b-y/c), where x and y are the independent and dependent variables, respectively. Coefficients are a, b, and c. As you see, y shows up on both sides of the equation. I tried to generate this equation in Matlab curve fitting tool box, however, it does not allow y to be on the right side of the equation. Do you have any idea how to apply this equation to fit the data? Thanks ahead.
Akzeptierte Antwort
Weitere Antworten (2)
Sargondjani
am 7 Apr. 2012
0 Stimmen
i know how you could get your a, b and c using lsqnonlin (minimizing least squares), but im not sure if the statistical properpties are what you want them to be
to do it with lsqnonlin you would have to write a function in the format: F(par,x,y)= y - (right hand side); %this should return a vector with the residuals, where par is a vector with [a,b,c], so par(1) instead of 'a', etc.
then optimize: [par]=lsqnonlin(function,par0);
i suppose there is nicer way to do it, but this could get you started...
Zhongbo
am 7 Apr. 2012
0 Stimmen
Kategorien
Mehr zu Conversion Between Symbolic and Numeric finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!