|
楼主 |
发表于 2010-12-1 12:15
|
显示全部楼层
本帖最后由 zhijieguo 于 2010-12-1 12:16 编辑
按照我的程序,计算的时候报错:
??? In an assignment A(I) = B, the number of elements in B and
I must be the same.(好像在说dz(2),dz(1)和f不匹配)
Error in ==> fun1 at 8
dz(2)=-3*z(2)-5*z(1)-f;
(好像在说dz(2),dz(1)和f不匹配,dz(2)是向量元素?f是向量,无法赋值?)
Error in ==> funfun\private\odearguments at 110
f0 = feval(ode,t0,y0,args{:}); % ODE15I sets args{1} to yp0.
Error in ==> ode45 at 173
[neq, tspan, ntspan, next, t0, tfinal, tdir, y0, f0, odeArgs, odeFcn, ...
(以上两处错误,好像在说ode45这个内部函数有些要求,而我违反了。)
|
|