啊啊,跪求解答,我想用matlab解一下多元非齐次方程的三个未知数,为什么结果总是Empty sym: 0-by-1
symsN1N2N3a=0.0640;b=-0.7629;c=-0.0936;x1=xlsread('F:\data1.xlsx','C2:C9');x2=xlsread...
syms N1 N2 N3
a=0.0640;
b=-0.7629;
c=-0.0936;
x1=xlsread('F:\data 1.xlsx', 'C2:C9');
x2=xlsread('F:\data 1.xlsx', 'G2:G9');
x3=xlsread('F:\data 1.xlsx', 'F2:F9');
y=xlsread('F:\data 1.xlsx', 'B2:B9');
QUE=y-((a.*x1+b.*(x2.^(1/2))+c.*x3).*(1-(x1./N1)-((x2.^(1/2))./N2)-(x3./N3)));
[N1,N2,N3]=solve(QUE,N1,N2,N3) 展开
a=0.0640;
b=-0.7629;
c=-0.0936;
x1=xlsread('F:\data 1.xlsx', 'C2:C9');
x2=xlsread('F:\data 1.xlsx', 'G2:G9');
x3=xlsread('F:\data 1.xlsx', 'F2:F9');
y=xlsread('F:\data 1.xlsx', 'B2:B9');
QUE=y-((a.*x1+b.*(x2.^(1/2))+c.*x3).*(1-(x1./N1)-((x2.^(1/2))./N2)-(x3./N3)));
[N1,N2,N3]=solve(QUE,N1,N2,N3) 展开
1个回答
展开全部
你要这样写试一下,应该没有问题的。
a=0.0640;
b=-0.7629;
c=-0.0936;
x1=xlsread('F:\data 1.xlsx', 'C2:C9');
x2=xlsread('F:\data 1.xlsx', 'G2:G9');
x3=xlsread('F:\data 1.xlsx', 'F2:F9');
y=xlsread('F:\data 1.xlsx', 'B2:B9');
for i=1:length(y)
syms N1 N2 N3
QUE=y(i)-((a.*x1(i)+b.*(x2(i).^(1/2))+c.*x3(i)).*(1-(x1(i)./N1)-((x2(i).^(1/2))./N2)-(x3(i)./N3)));
[N1,N2,N3]=solve(QUE,N1,N2,N3)
end
方程求解只能一个一个来。
a=0.0640;
b=-0.7629;
c=-0.0936;
x1=xlsread('F:\data 1.xlsx', 'C2:C9');
x2=xlsread('F:\data 1.xlsx', 'G2:G9');
x3=xlsread('F:\data 1.xlsx', 'F2:F9');
y=xlsread('F:\data 1.xlsx', 'B2:B9');
for i=1:length(y)
syms N1 N2 N3
QUE=y(i)-((a.*x1(i)+b.*(x2(i).^(1/2))+c.*x3(i)).*(1-(x1(i)./N1)-((x2(i).^(1/2))./N2)-(x3(i)./N3)));
[N1,N2,N3]=solve(QUE,N1,N2,N3)
end
方程求解只能一个一个来。
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询