solve the differential equation ${dy \over dx} + qy^4+y=0$ Solve the differential equation ${dy \over dx}+qy^4+y=0$
the initial condition is $y(x=1)=-\frac 12$ with considering  $q \ll 1$.
don't consider the powers of $q$ which are higher than $2$. 
You will use Expansion.(expand the function $y=f(x)$ with the powers of the $q$)
 A: In the ODE $\displaystyle \quad\frac{dy}{dx} + qy^4 + y = 0\quad$ treat $x$ as a function of $y$, we have:
$$
x(y) = \int dx = - \int \frac{dy}{qy^4 + y} = -\frac13\int \frac{d(y^3)}{y^3(qy^3+1)}
= -\frac13 \int \left(\frac{1}{y^3} - \frac{q}{qy^3+1}\right)d(y^3)\\
= -\frac13 \left(\log(y^3)-\log(qy^3+1)\right) + K
= -\frac13 \log\left(\frac{-y^3}{qy^3+1}\right) + K'
$$
where $K$ and $K'$ are integration constants. Since $y(x) = -\frac12$ at $x = 1$, we get $$K' = 1-\frac13 \log(8 - q) \quad\implies\quad
x = 1 -\frac13 \log\left(\frac{(8-q)(-y^3)}{1+qy^3}\right)
$$
This is equivalent to
$$\begin{align} \frac{-y^3}{1+qy^3} = \frac{1}{8-q}e^{3(1-x)}
\iff & -y^3 = \frac{\frac{1}{8-q}e^{3(1-x)}}{1 + \frac{q}{8-q}e^{3(1-x)}}
=\frac{1}{(8-q)e^{3(x-1)} + q }\\
\iff &   \quad y\,  = -\left((8-q)e^{3(x-1)} + q\right)^{-1/3}\\
\iff &   \quad y\,  = -\frac12 e^{1-x} \left(1- \frac{q}{8}( 1 - e^{3(1-x)})\right)^{-1/3}
\end{align}$$
Expand to first order of $q$, we have:
$$y = -\frac12 e^{1-x} \left( 1 + \frac{q}{24} ( 1 - e^{3(1-x)}) + O(q^2)\right)\tag{*1}$$
If one only want/need the first order approximation of $y(x)$ in $q$, 
there is an alternate way. One can rewrite the ODE into an intego differential
equation and simplify it along the way  using the given initial conditions:
$$\begin{align} 
     & \frac{dy(x)}{dx} + y(x) + qy(x)^4 = 0\\
\iff &\frac{dy(x)}{dx} + y(x) = - qy(x)^4\\
\iff & \frac{d}{dx} ( e^{x-1} y(x) ) = -q e^{x-1} y(x)^4\\
\iff & e^{x-1}y(x) = -\frac12 - q \int_{1}^{x} e^{t-1} y(t)^4 dt\\
\iff & y(x) = -\frac12 e^{1-x} - q\int_{1}^{x} e^{t-x} y(t)^4 dt\tag{*2}
\end{align}$$
The R.H.S of $(*2)$ tell us up to $O(q)$, $y(x)$ is just $-\frac12 e^{1-x}$. 
One can substitute this back into the integral of R.H.S and get the next order of approximation in $q$:
$$\begin{align}y(x) = & -\frac12 e^{1-x} - q \int_{1}^{x} e^{t-x} \left( -\frac12 e^{1-t} \right)^4 dt + O(q^2)\\
= & -\frac12 e^{1-x} - \frac{q e^{4-x}}{16}\int_{1}^{x} e^{-3t} dt + O(q^2)\\
= & -\frac12 e^{1-x} - \frac{q e^{4-x}}{48}(e^{-3} - e^{-3x}) + O(q^2)\\
= & -\frac12 e^{1-x}\left ( 1 + \frac{q}{24}(1 - e^{3(1-x)})\right) + O(q^2)\\
\end{align}$$ 
This is the same result $(*1)$ we obtained before by solving the full initial value problem.
A: $$y(x)=-7^{-1/3}e^{(x-1)/9q}[1+7^{-1}e^{(x-1)/3q}]^{-1/3}$$
