ODE No. 13

\[ -a x-b+y'(x)+y(x)^2=0 \] Mathematica : cpu = 0.0909047 (sec), leaf count = 79

DSolve[-b - a*x + y[x]^2 + Derivative[1][y][x] == 0,y[x],x]
 

\[\left \{\left \{y(x)\to -\frac {\sqrt [3]{a} \text {Bi}'\left (\frac {b+a x}{a^{2/3}}\right )+\sqrt [3]{a} c_1 \text {Ai}'\left (\frac {b+a x}{a^{2/3}}\right )}{-\text {Bi}\left (\frac {b+a x}{a^{2/3}}\right )-c_1 \text {Ai}\left (\frac {b+a x}{a^{2/3}}\right )}\right \}\right \}\] Maple : cpu = 0.194 (sec), leaf count = 79

dsolve(diff(y(x),x)+y(x)^2-a*x-b = 0,y(x))
 

\[y \left (x \right ) = -\frac {i \left (-i a \right )^{\frac {1}{3}} \left (\AiryAi \left (1, -\frac {a x +b}{\left (-i a \right )^{\frac {2}{3}}}\right ) c_{1}+\AiryBi \left (1, -\frac {a x +b}{\left (-i a \right )^{\frac {2}{3}}}\right )\right )}{\AiryAi \left (-\frac {a x +b}{\left (-i a \right )^{\frac {2}{3}}}\right ) c_{1}+\AiryBi \left (-\frac {a x +b}{\left (-i a \right )^{\frac {2}{3}}}\right )}\]

Hand solution

\begin {align} y^{\prime }\left ( x\right ) +y^{2}\left ( x\right ) -ax-b & =0\nonumber \\ y^{\prime }\left ( x\right ) & =b+ax-y^{2}\left ( x\right ) \tag {1} \end {align}

This is Riccati first order non-linear ODE of the form \begin {equation} y^{\prime }\left ( x\right ) =P\left ( x\right ) +Q\left ( x\right ) y+R\left ( x\right ) y^{2}\left ( x\right ) \tag {2} \end {equation} where in this case \(Q\left ( x\right ) =0,R\left ( x\right ) =-1,P\left ( x\right ) =b+ax\). We can solve this in two ways. If we know one particular solution \(y_{p}\left ( x\right ) \) for (1) then we use the substitution \(y=y_{p}+\frac {1}{u}\) and convert (1) to new associated linear ODE of the form \(u^{\prime }+\left ( Q\left ( x\right ) +2R\left ( x\right ) \right ) y_{p}+R\left ( x\right ) =0\). If we do not know a particular solution, then we use the standard substitution \(y=\frac {-u^{\prime }}{uR\left ( x\right ) }=\frac {u^{\prime }}{u}\) since \(R\left ( x\right ) =-1\) and this is what we will do here.

Since \(u^{\prime }=yu\) then \begin {align*} u^{\prime \prime } & =yu^{\prime }+y^{\prime }u\\ & =y\left ( yu\right ) +\left ( b+ax-y^{2}\right ) u\\ & =y^{2}u+\left ( b+ax\right ) u-y^{2}u\\ & =\left ( b+ax\right ) u \end {align*}

So we have new second order ODE \begin {equation} u^{\prime \prime }-\left ( b+ax\right ) u=0 \tag {3} \end {equation} which we solve for \(u\). This ODE is of the form \(u^{\prime \prime }-q\left ( x\right ) u=0\) which has solutions in terms of Airy function of first \(Ai\left ( x\right ) \) and second kind \(Bi\left ( x\right ) \), where

\begin {align*} Ai\left ( x\right ) & =\frac {1}{\pi }\int _{0}^{\infty }\cos \left ( \frac {t^{3}}{3}+xt\right ) dt\\ Bi\left ( x\right ) & =\frac {1}{\pi }\int _{0}^{\infty }\exp \left ( -\frac {t^{3}}{3}+xt\right ) +\sin \left ( \frac {t^{3}}{3}+xt\right ) dt \end {align*}

Therefore the solution to (3) is

\[ u\left ( x\right ) =c_{1}Ai\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) +c_{2}Bi\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) \]

We need to find \(u^{\prime }\left ( x\right ) \) now. Using \(Ai^{\prime }\left ( x\right ) ,Bi^{\prime }\left ( x\right ) \) for derivative of Airy functions of first and second kind, then

\[ u^{\prime }\left ( x\right ) =c_{1}Ai^{\prime }\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}+c_{2}Bi^{\prime }\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}\]

Therefore since \(u^{\prime }=yu\) then

\begin {align*} y & =\frac {u^{\prime }}{u}\\ & =\frac {c_{1}A^{\prime }i\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}+c_{2}Bi^{\prime }\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}}{c_{1}Ai\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) +c_{2}Bi\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) } \end {align*}

Let \(C_{1}=\frac {c_{1}}{c_{2}}\) then the above can be written as

\[ y=\frac {C_{1}A^{\prime }i\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}+Bi^{\prime }\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) a^{\frac {1}{3}}}{C_{1}Ai\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) +Bi\left ( \frac {b+ax}{a^{\frac {2}{3}}}\right ) }\]

Reference: Airy function