自定义方程拟合曲线计算出现复数值 无法拟合

12 ビュー (過去 30 日間)
Han Wang
Han Wang 2022 年 8 月 31 日
回答済み: sai charan sampara 2023 年 10 月 6 日
对一组数据自定义方程拟合 以得出方程中对常数值
数据:
x: 836 1264 2236 3768
y: 0.836 1.264 2.236 3.768
拟合方程:y=a*(1+(b/x)^c)
拟合结果如下图

回答 (1 件)

sai charan sampara
sai charan sampara 2023 年 10 月 6 日
Hello Han,
As per my understanding you are trying to fit the data into a custom equation of the required form but are getting imaginary coefficients for the parameters.
It might be because of an error in importing data. Try to make sure you have imported the right data as x data and y data in the “Select data” option in the “Data” tab in curve fitter.
The given data was:
x: 836 1264 2236 3768
y: 0.836 1.264 2.236 3.768
These points lie on a straight line but that does not seem the case in the screenshot you have shared. Hence there might be an issue with the data importing.
On importing the data correctly, the result looks as follows:
Please refer to the following documentation to know more about curve fitting app.
I hope this resolves the issue you were facing.

カテゴリ

Help Center および File ExchangeInterpolation についてさらに検索

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!