matlab解微分方程为什么老提示未定义的 t>> dydt = odefun(t,y)function dydt = vdp1000(t,y)dydt = [y(2); 1000*(1-y(1)^2)*y(2)-y(1)];[t,y] = ode15s(@vdp1000,[0 3000],[2; 0]);plot(t,y(:,1),'-');title('Solution of van der Pol Equation,\mu = 1

来源:学生作业帮助网 编辑:作业帮 时间:2024/11/16 13:37:33
matlab解微分方程为什么老提示未定义的 t>> dydt = odefun(t,y)function dydt = vdp1000(t,y)dydt = [y(2); 1000*(1-y(1)^2)*y(2)-y(1)];[t,y] = ode15s(@vdp1000,[0 3000],[2; 0]);plot(t,y(:,1),'-');title('Solution of van der Pol Equation,\mu = 1
xQoPǿ}B/d/j5TXBB"ol:f,,u#S37%kM(v2 3}9?-%c]n_j7vmD(t|1vFX(G.w CX3ZQ,ܛKu1_thyZc254:n]^u!g5MEXaEuz'\F+2Gmș>iu lWmF'yiշFW% .;_@NSXk3W2yƗc UAQm\[(LUĪ%M}lr* 7u=gx8&1, Bz%uqo;uס;IRGG;Oû 0z5s`> {d͙驪&A~.(H+ӲF VmK6[Oh

matlab解微分方程为什么老提示未定义的 t>> dydt = odefun(t,y)function dydt = vdp1000(t,y)dydt = [y(2); 1000*(1-y(1)^2)*y(2)-y(1)];[t,y] = ode15s(@vdp1000,[0 3000],[2; 0]);plot(t,y(:,1),'-');title('Solution of van der Pol Equation,\mu = 1
matlab解微分方程为什么老提示未定义的 t
>> dydt = odefun(t,y)
function dydt = vdp1000(t,y)
dydt = [y(2); 1000*(1-y(1)^2)*y(2)-y(1)];
[t,y] = ode15s(@vdp1000,[0 3000],[2; 0]);
plot(t,y(:,1),'-');
title('Solution of van der Pol Equation,\mu = 1000');
xlabel('time t');
ylabel('solution y_1');
Undefined function or variable 't'.

matlab解微分方程为什么老提示未定义的 t>> dydt = odefun(t,y)function dydt = vdp1000(t,y)dydt = [y(2); 1000*(1-y(1)^2)*y(2)-y(1)];[t,y] = ode15s(@vdp1000,[0 3000],[2; 0]);plot(t,y(:,1),'-');title('Solution of van der Pol Equation,\mu = 1
作为等号右边的变量,必须是前边已经定义过的或者出现过的.你可以在最前边声明t和y,并对它适当赋值.如果不需要赋值,直接给个声明也可.syms t y;