curve fitting tool custom equation
이전 댓글 표시
Hi,
I used cf tool to get a function to describe my data but it seems to give me a straight line.
I know the custom equation is the right one is there anything else I can do to make the function more like my data?
Thank you all for your time!

댓글 수: 3
Michal Naim Ben Eliyahu
2022년 4월 18일
Can you provide the data t and h?
Technically, if
, then
, but since your equation
was incorrect, it didn't fit.
was incorrect, it didn't fit.The signal seems to slow down significantly in these 3 cycles, but regains momentum after 5.6 seconds.
The signal doesn't look like the one produced from a 2nd-order linear system. So your proposed model won't work. A rough estimation shows it could be from a 4th-order system.

Michal Naim Ben Eliyahu
2022년 4월 19일
채택된 답변
추가 답변 (2개)
Torsten
2022년 4월 18일
1 개 추천
Don't use the data for t > 6.3 in the fitting process.
댓글 수: 4
John D'Errico
2022년 4월 18일
I agree with that statement on general principles, since they fail to follow the nice smooth curve the rest of the data does. But the problem is more bad starting values. Those points in the tail will not significantly impact the sum of squares, so lack of fit there will not be what is causing the problem.
Michal Naim Ben Eliyahu
2022년 4월 18일
Torsten
2022년 4월 18일
What initial values for the parameters did you choose ?
Did you plot the resulting curve ? Is it near to the one you expect to get ?
Michal Naim Ben Eliyahu
2022년 4월 19일
Alex Sha
2022년 4월 19일
if taking only part of data, for example, from No. 105 to No. 300, then the result will looks good
Sum Squared Error (SSE): 1111312565.89975
Root of Mean Square Error (RMSE): 2381.16821558602
Correlation Coef. (R): 0.969742933902271
R-Square: 0.940401357853383
Adjusted R-Square: 0.939783755344092
Determination Coef. (DC): 0.940401357853381
Chi-Square: -43481.4424771284
F-Statistic: 753.442740102336
Parameter Best Estimate
---------- -------------
a -291924.957940865
b 7.9210511350074E-7
c -1.68465029667797E-5
d -2953.68909153569
e -9546.50019773865

카테고리
도움말 센터 및 File Exchange에서 Linear and Nonlinear Regression에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



