Labfans是一个针对大学生、工程师和科研工作者的技术社区。 | 论坛首页 | 联系我们(Contact Us) |
![]() |
![]() |
#1 |
初级会员
注册日期: 2009-10-25
帖子: 4
声望力: 0 ![]() |
![]()
我建立了一个函数文件 保存在work中
function f=fun3(x,y) f=[-2*y+2*x.^2+2*x] end 然后进行了如下调用 [x,y]=ode23('fun3',[0,0.5],1) ??? Error using ==> feval Undefined function or method 'fun3' for input arguments of type 'double'. Error in ==> odearguments at 110 f0 = feval(ode,t0,y0,args{:}); % ODE15I sets args{1} to yp0. Error in ==> ode23 at 172 [neq, tspan, ntspan, next, t0, tfinal, tdir, y0, f0, odeArgs, odeFcn, ... 计算常微分方程,但是却一直出错。 请高手帮忙,谢谢! |
![]() |
![]() |