I want to solve an ODE when it appears an Interpolating Function. First I obtain the function y[s] (or Y[s])
aa = .4; sol = NDSolve[{-4 + 4/y[s]^2 - y[s]^2 + y[s]^4 + y'[s]^2 == 0, y[0] == 1.207}, y[s], {s, 0, aa}];
ParametricPlot [Evaluate[{s, y[s]} /. sol[[2]]], {s, 0, aa}, PlotRange -> All]
Y[s_] = y[s] /. sol[[2]];
(with the function Y[s] I can plot the solution y[s])
Now, I want to solve the ODE w'[s]= Sqrt[y[s]^2 + 2] with initial condition w[0] = 0. My first attempt is
w1 = NDSolve[{w'[s] == Sqrt[Y[s]^2 + 2], w[0] == 0}, w[s], {s, 0, aa}]
Next, I put W[s_] = w[s] /. w1[[1]] and I plot the function W[s] by means of Plot[W[s], {s, 0, aa}]
Is it right?
(thanks)enter code here