I’m trying to solve differential equations using ode23 in MATLAB but in the given problem, the value given is different from the endpoint. For example: y’+y=2, y(0)=0, t on [-2,10]. ode23 expects a y0 but in this case, I need y(0)=0 and not y(-2)=0. How can I change the parameters of ode23 so that it still tells me the values on the interval [-2,10] but also with y(0)=0?
I’m trying to solve differential equations using ode23 in MATLAB but in the given
Share
You can split your problem and solve
and
where (a) directly fits ode23, while (b) has to be rewritten by a variable transform
t := -tto giveAs ode23 bases on single step methods, the approach of splitting the integration interval is legit.