MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   MATLAB论坛 (https://www.labfans.com/bbs/forumdisplay.php?f=6)
-   -   [MATLAB基础] 函数的赋值 (https://www.labfans.com/bbs/showthread.php?t=17831)

zhangyifei1990 2012-10-19 19:02

函数的赋值
 
a=0;
for i=0:5
for j=0:5
if i~=j
[COLOR="Red"]c=c*(x+1-j*0.4)/0.4*(i-j);[/COLOR] end
end
l=c/(1+25*(-1+2*i/5)*(-1+2*i/5));
a=a+l;
x=-1:0.1:1
end
plot(x,a)
这个是我用来解决复杂数学运算的程序,最后要给定自变量范围将函数作图,里面红色部分里面有个未知数x,所以运行之后提示Inner matrix dimensions must agree.这个怎么解决?谢谢


所有时间均为北京时间。现在的时间是 14:42

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.