求助!Function definitions are not permitted at the prompt or in scripts
function xdot = lorenzeq(t,x)xdot=[-8/3*x(1)+x(2)*x(3);
-10*x(2)+10*x(3);
-x(1)*x(2)+28*x(2)-x(3)];
t_final=100; x0=;
=ode45('lorenzeq',,x0);
plot(t,x),
figure; plot3(x(:,1),x(:,2),x(:,3)); axis();
为什么每次运行之后都说出现错误呢?
??? function xdot = lorenzeq(t,x)
|
Error: Function definitions are not permitted at the prompt or in scripts.
[ 本帖最后由 ChaChing 于 2009-4-18 14:05 编辑 ] Ref:
常见的程序出错问题整理 (eight)
http://forum.vibunion.com/forum/thread-46001-1-1.html
[ 本帖最后由 ChaChing 于 2009-4-18 14:11 编辑 ]
页:
[1]