How can i linearise this equation in matlab? y=a*x*e^b*x
3 ビュー (過去 30 日間)
古いコメントを表示
clc
clear all
close all
syms x y a b A B a0 a1
%given dependent and independent datas
xdata=[0.1 0.2 0.4 0.6 0.9 1.3 1.5 1.7 1.8];
ydata=[0.75 1.25 1.45 1.25 0.85 0.55 0.35 0.28 0.18];
xlim([0 2])
ylim([0 1.8])
plot(xdata,ydata,'m')
grid on
xlabel('x')
ylabel('y')
y=@(X) a*X*exp^(b*X)
Y=@(x) a0+a1*x
K=@(X) log(a)+log(X)+(b*X)
Y=log(y)
a0=ln(a1)
a1=b
x=X
2 件のコメント
James Tursa
2019 年 4 月 29 日
What is the context? I.e., what problem are you trying to solve and how do you expect "linearizing" (whatever that means in your context) to help?
回答 (1 件)
Alex Sha
2019 年 4 月 30 日
by linearization, the results are:
a: 9.66178585962543
b: -2.47330876570272
While if using nonlinear regression fitting directly, the results will be:
a 9.89736155015817
b -2.53186923697479
The method of "linearizing" is not recommended since the errors sometime are very large.
0 件のコメント
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!