Here is my call to ode45
[t,y] = ode45(@Phase_1, tspan, intial_conditions);
and here is the function i am referencing
function dydt = Phase_1(t, y)dydt(1,1) = y(3);dydt(1,2) = y(4);dydt(1,3) = 2*t;dydt(1,4) = 1.5*t;dydt(1,5) = t^(1/9);dydt(1,6) = t^(1/6);end
when I call ode45 I get these error messages and I can't seem to figure out what I'm doing wrong. Any help would be much appreciated.
Error using odearguments (line 93)
PHASE_1 must return a column vector.
Error in ode45 (line 115)
odearguments(FcnHandlesUsed, solver_name, ode, tspan, y0, options, varargin);
Error in rocket_code (line 32)
[t,y] = ode45(@Phase_1, tspan, intial_conditions);
Best Answer