I am using ode45() to solve a differential equation like this:
[t,state] = ode45(@odefun,tspan,0);
Now I want to solve another differential equation:
which uses the matrix state that is computed from the first differential equation. How is it possible for the ode solver to get for each time step one value of the matrix state ?