I\'m using Matlab to solve a differential equation. I want to force ode45 to take constant steps, so it always increments 0.01 on the T axis while solving the equation. How
This can be done just need to use a few more commands.
NEW:
options= odeset('Reltol',0.001,'Stats','on');
%figure(1);
%clf;
init=[xo yo zo]';
to=some number;
tf= some number;
nsteps= number of points you want function evaluated on.
tspan = linspace(t0,tf, nsteps);
[T,Y]=ode45(@function,tspan,init,options);
You can verify that it took the number points that you wanted using the command size(variable).