Thank you in advance for the help.
I want to use the optimization toolbox to find the correct value of v to get the condition that Y(end,2) = 0 instead of trying random v values in a for loop.
Does anyone has any suggestions in how can i do that?
here there is the code
v = [13:0.1:15]
u0 = (v(i)-ev-q*rd);
f = @(z,y) [-(a*y(2))./((1-(y(1)./(b*xi_star))).^3);...
[z,Y] = ode45(f,[0 1],[u0 q_0]);