2.37 problem 37

2.37.1 Solving as riccati ode
2.37.2 Maple step by step solution

Internal problem ID [10366]
Internal file name [OUTPUT/9314_Monday_June_06_2022_01_51_15_PM_48702340/index.tex]

Book: Handbook of exact solutions for ordinary differential equations. By Polyanin and Zaitsev. Second edition
Section: Chapter 1, section 1.2. Riccati Equation. 1.2.2. Equations Containing Power Functions
Problem number: 37.
ODE order: 1.
ODE degree: 1.

The type(s) of ODE detected by this program : "riccati"

Maple gives the following as the ode type

[_rational, _Riccati]

\[ \boxed {y^{\prime } x -y^{2} x -a y=b \,x^{n}} \]

2.37.1 Solving as riccati ode

In canonical form the ODE is \begin {align*} y' &= F(x,y)\\ &= \frac {x \,y^{2}+y a +b \,x^{n}}{x} \end {align*}

This is a Riccati ODE. Comparing the ODE to solve \[ y' = y^{2}+\frac {x^{n} b}{x}+\frac {y a}{x} \] With Riccati ODE standard form \[ y' = f_0(x)+ f_1(x)y+f_2(x)y^{2} \] Shows that \(f_0(x)=\frac {x^{n} b}{x}\), \(f_1(x)=\frac {a}{x}\) and \(f_2(x)=1\). Let \begin {align*} y &= \frac {-u'}{f_2 u} \\ &= \frac {-u'}{u} \tag {1} \end {align*}

Using the above substitution in the given ODE results (after some simplification)in a second order ODE to solve for \(u(x)\) which is \begin {align*} f_2 u''(x) -\left ( f_2' + f_1 f_2 \right ) u'(x) + f_2^2 f_0 u(x) &= 0 \tag {2} \end {align*}

But \begin {align*} f_2' &=0\\ f_1 f_2 &=\frac {a}{x}\\ f_2^2 f_0 &=\frac {x^{n} b}{x} \end {align*}

Substituting the above terms back in equation (2) gives \begin {align*} u^{\prime \prime }\left (x \right )-\frac {a u^{\prime }\left (x \right )}{x}+\frac {x^{n} b u \left (x \right )}{x} &=0 \end {align*}

Solving the above ODE (this ode solved using Maple, not this program), gives

\[ u \left (x \right ) = \left (\operatorname {BesselY}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{2} +\operatorname {BesselJ}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{1} \right ) x^{\frac {1}{2}+\frac {a}{2}} \] The above shows that \[ u^{\prime }\left (x \right ) = x^{\frac {a}{2}+\frac {n}{2}} \sqrt {b}\, \left (-\operatorname {BesselJ}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{1} -\operatorname {BesselY}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{2} \right ) \] Using the above in (1) gives the solution \[ y = -\frac {x^{\frac {a}{2}+\frac {n}{2}} \sqrt {b}\, \left (-\operatorname {BesselJ}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{1} -\operatorname {BesselY}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{2} \right ) x^{-\frac {1}{2}-\frac {a}{2}}}{\operatorname {BesselY}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{2} +\operatorname {BesselJ}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{1}} \] Dividing both numerator and denominator by \(c_{1}\) gives, after renaming the constant \(\frac {c_{2}}{c_{1}}=c_{3}\) the following solution

\[ y = \frac {\sqrt {b}\, x^{-\frac {1}{2}+\frac {n}{2}} \left (\operatorname {BesselJ}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3} +\operatorname {BesselY}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )\right )}{\operatorname {BesselY}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )+\operatorname {BesselJ}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3}} \]

Summary

The solution(s) found are the following \begin{align*} \tag{1} y &= \frac {\sqrt {b}\, x^{-\frac {1}{2}+\frac {n}{2}} \left (\operatorname {BesselJ}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3} +\operatorname {BesselY}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )\right )}{\operatorname {BesselY}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )+\operatorname {BesselJ}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3}} \\ \end{align*}

Verification of solutions

\[ y = \frac {\sqrt {b}\, x^{-\frac {1}{2}+\frac {n}{2}} \left (\operatorname {BesselJ}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3} +\operatorname {BesselY}\left (\frac {-a +n}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )\right )}{\operatorname {BesselY}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right )+\operatorname {BesselJ}\left (\frac {-a -1}{1+n}, \frac {2 \sqrt {b}\, x^{\frac {1}{2}+\frac {n}{2}}}{1+n}\right ) c_{3}} \] Verified OK.

2.37.2 Maple step by step solution

\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & y^{\prime } x -y^{2} x -a y=b \,x^{n} \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 1 \\ {} & {} & y^{\prime } \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & y^{\prime }=\frac {y^{2} x +a y+b \,x^{n}}{x} \end {array} \]

Maple trace

`Methods for first order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
trying 1st order linear 
trying Bernoulli 
trying separable 
trying inverse linear 
trying homogeneous types: 
trying Chini 
differential order: 1; looking for linear symmetries 
trying exact 
Looking for potential symmetries 
trying Riccati 
trying Riccati sub-methods: 
   trying Riccati_symmetries 
   trying Riccati to 2nd Order 
   -> Calling odsolve with the ODE`, diff(diff(y(x), x), x) = (diff(y(x), x))*a/x-b*x^(n-1)*y(x), y(x)`      *** Sublevel 2 *** 
      Methods for second order ODEs: 
      --- Trying classification methods --- 
      trying a symmetry of the form [xi=0, eta=F(x)] 
      checking if the LODE is missing y 
      -> Trying an equivalence, under non-integer power transformations, 
         to LODEs admitting Liouvillian solutions. 
         -> Trying a Liouvillian solution using Kovacics algorithm 
         <- No Liouvillian solutions exists 
      -> Trying a solution in terms of special functions: 
         -> Bessel 
         <- Bessel successful 
      <- special function solution successful 
   <- Riccati to 2nd Order successful`
 

Solution by Maple

Time used: 0.0 (sec). Leaf size: 139

dsolve(x*diff(y(x),x)=x*y(x)^2+a*y(x)+b*x^n,y(x), singsol=all)
 

\[ y \left (x \right ) = \frac {x^{\frac {n}{2}-\frac {1}{2}} \sqrt {b}\, \left (\operatorname {BesselY}\left (\frac {-a +n}{n +1}, \frac {2 \sqrt {b}\, x^{\frac {n}{2}+\frac {1}{2}}}{n +1}\right ) c_{1} +\operatorname {BesselJ}\left (\frac {-a +n}{n +1}, \frac {2 \sqrt {b}\, x^{\frac {n}{2}+\frac {1}{2}}}{n +1}\right )\right )}{\operatorname {BesselY}\left (\frac {-a -1}{n +1}, \frac {2 \sqrt {b}\, x^{\frac {n}{2}+\frac {1}{2}}}{n +1}\right ) c_{1} +\operatorname {BesselJ}\left (\frac {-a -1}{n +1}, \frac {2 \sqrt {b}\, x^{\frac {n}{2}+\frac {1}{2}}}{n +1}\right )} \]

Solution by Mathematica

Time used: 1.381 (sec). Leaf size: 855

DSolve[x*y'[x]==x*y[x]^2+a*y[x]+b*x^n,y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to -\frac {\sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}} \operatorname {Gamma}\left (\frac {a+n+2}{n+1}\right ) \operatorname {BesselJ}\left (\frac {a-n}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )-\sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}} \operatorname {Gamma}\left (\frac {a+n+2}{n+1}\right ) \operatorname {BesselJ}\left (\frac {a+n+2}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )+a \operatorname {Gamma}\left (\frac {a+n+2}{n+1}\right ) \operatorname {BesselJ}\left (\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )+\operatorname {Gamma}\left (\frac {a+n+2}{n+1}\right ) \operatorname {BesselJ}\left (\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )-\sqrt {b} c_1 \left (x^n\right )^{\frac {n+1}{2 n}} \operatorname {Gamma}\left (\frac {n-a}{n+1}\right ) \operatorname {BesselJ}\left (\frac {n-a}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )+\sqrt {b} c_1 \left (x^n\right )^{\frac {n+1}{2 n}} \operatorname {Gamma}\left (\frac {n-a}{n+1}\right ) \operatorname {BesselJ}\left (-\frac {a+n+2}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )+(a+1) c_1 \operatorname {Gamma}\left (\frac {n-a}{n+1}\right ) \operatorname {BesselJ}\left (-\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )}{2 x \left (\operatorname {Gamma}\left (\frac {a+n+2}{n+1}\right ) \operatorname {BesselJ}\left (\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )+c_1 \operatorname {Gamma}\left (\frac {n-a}{n+1}\right ) \operatorname {BesselJ}\left (-\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )\right )} \\ y(x)\to -\frac {\frac {\sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}} \left (\operatorname {BesselJ}\left (-\frac {a+n+2}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )-\operatorname {BesselJ}\left (\frac {n-a}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )\right )}{\operatorname {BesselJ}\left (-\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )}+a+1}{2 x} \\ y(x)\to -\frac {\frac {\sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}} \left (\operatorname {BesselJ}\left (-\frac {a+n+2}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )-\operatorname {BesselJ}\left (\frac {n-a}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )\right )}{\operatorname {BesselJ}\left (-\frac {a+1}{n+1},\frac {2 \sqrt {b} \left (x^n\right )^{\frac {n+1}{2 n}}}{n+1}\right )}+a+1}{2 x} \\ \end{align*}