问题描述:
关于Matlab的一个简单问题,ode45函数的
>> t0=0;tf=10;
>> [t,y]=ode45('eq',[t0 tf],[0 0 ]);
>> T=0:0.1:2*pi;
>> X=20*cos(T);
>> Y=15*sin(T);
>> plot(X,Y,'-')
>> hold on
>> plot(y(:,1),y(:,2),'+')
这是程序,然后第二行是显示:
Warning:Mixture of single and double data for 't0','y0',and 'f(t0,y0)' in call to ode45.
> In funfun\private\odearguments at 140
In ode45 at 173怎么回事?这样最后没有画出来函数图象
>> t0=0;tf=10;
>> [t,y]=ode45('eq',[t0 tf],[0 0 ]);
>> T=0:0.1:2*pi;
>> X=20*cos(T);
>> Y=15*sin(T);
>> plot(X,Y,'-')
>> hold on
>> plot(y(:,1),y(:,2),'+')
这是程序,然后第二行是显示:
Warning:Mixture of single and double data for 't0','y0',and 'f(t0,y0)' in call to ode45.
> In funfun\private\odearguments at 140
In ode45 at 173怎么回事?这样最后没有画出来函数图象
问题解答:
我来补答展开全文阅读