필터 지우기
필터 지우기

Parameters to consider in non linear curve fitting

조회 수: 1 (최근 30일)
Zine
Zine 2014년 3월 1일
편집: Star Strider 2014년 3월 3일
I have a complex (sum and multiplication of several elementary functions) function to fit with experimental data, but I could not reach the desired fit, the program does his work but the parameters are far from what they should be, I noticed that if I change the lb or ub it changes the results also if I change Beta0 it also affects the results. I need help and advise on the factors that I should consider to have the best fit
note: the experimental data are about 6000 points, I have around 15 parameters to find
thanks in advance

채택된 답변

Star Strider
Star Strider 2014년 3월 1일
Without knowing more, I suggest you choose Beta0 to be close to what you expect the parameters to be as you can. I also suggest not restricting the parameters with lb and ub unless you know that, for instance, they must be positive or if you already know they should not exceed a specific value.
Fitting so many parameters will give any solver problems. Consider reducing them if you can.
  댓글 수: 2
Zine
Zine 2014년 3월 2일
Thanks Star, I tried this idea and it makes the values closer, thanks for that, but in some cases it creates complex numbers, so how to impose real values only so the program will not search in complex numbers, I should find as result only real results (no imaginary parts)
note: the modules of my complex results are very close to what I want to have
Star Strider
Star Strider 2014년 3월 3일
편집: Star Strider 2014년 3월 3일
The only way I can think of to force real numbers is for the last lines of your objective function to return them as reals. For instance:
function (p,x) = fun(p,x)
(code)
p = abs(p);
end
That’s not recommended, but it is probably an experiment you can do to force the returned parameters to be real. If it fails to converge to what you consider a ‘correct’ solution, you can always remove the ’abs’ line and live with complex parameter estimates.

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Image Analyst
Image Analyst 2014년 3월 1일
Yeah, I don't know either from this description, so I'll just put in a plug for John's masterpiece: http://www.mathworks.com/matlabcentral/fileexchange/24443-slm-shape-language-modeling
Description
If you could only download one curve fitting tool to your laptop on a desert island, this should be it.
For many years.......
  댓글 수: 4
Image Analyst
Image Analyst 2014년 3월 1일
John has lots of good ones I use: allwords, polyfitn (to do background correction of images), suite of min bounding objects, etc. It's worth everyone looking over his impressive File Exchange. There's something there for just about everybody.
Star Strider
Star Strider 2014년 3월 1일
I’ll search on his name from the link you provided. Thanks again.
(I’m just happy when someone occasionally downloads polyparci!)

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Get Started with Curve Fitting Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by