Originally Posted by

**Danny** If $\displaystyle y'' + y + \varepsilon y^2 = 0$, then substituting $\displaystyle y = y_0 + \varepsilon y_1 + O\left(\varepsilon^2\right)$ gives

$\displaystyle

y''_0 + \varepsilon y''_1 + y_0 + \varepsilon y_1 + \varepsilon \left(y_0 + \varepsilon y_1 \right)^2 + O\left(\varepsilon^2\right) = 0

$

or

$\displaystyle

O(1)\;\;\;y''_0 + y_0 = 0

$

$\displaystyle

O(\varepsilon)\;\;\;y''_1 + y_1 + y^2_0 = 0

$

with ICs $\displaystyle y_0(0) = 1, y'_0(0) = 0, y_1(0) = 0, y'_1(0) = 0, $.

The first one is easy - soln $\displaystyle y_0 = \cos x$. Use this in the second and solve for $\displaystyle y_1$.