4.10 problem Problem 3.14

4.10.1 Solving as riccati ode
4.10.2 Maple step by step solution

Internal problem ID [5884]
Internal file name [OUTPUT/5132_Sunday_June_05_2022_03_25_43_PM_27953378/index.tex]

Book: THEORY OF DIFFERENTIAL EQUATIONS IN ENGINEERING AND MECHANICS. K.T. CHAU, CRC Press. Boca Raton, FL. 2018
Section: Chapter 3. Ordinary Differential Equations. Section 3.6 Summary and Problems. Page 218
Problem number: Problem 3.14.
ODE order: 1.
ODE degree: 1.

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

Maple gives the following as the ode type

[[_1st_order, `_with_symmetry_[F(x),G(x)]`], _Riccati]

\[ \boxed {\left (\phi ^{\prime }-\frac {\phi ^{2}}{2}\right ) \sin \left (\theta \right )^{2}-\cos \left (\theta \right ) \phi \sin \left (\theta \right )=\frac {\cos \left (2 \theta \right )}{2}+1} \]

4.10.1 Solving as riccati ode

In canonical form the ODE is \begin {align*} \phi ' &= F(\theta ,\phi )\\ &= \frac {\phi ^{2} \sin \left (\theta \right )^{2}+2 \cos \left (\theta \right ) \phi \sin \left (\theta \right )+\cos \left (2 \theta \right )+2}{2 \sin \left (\theta \right )^{2}} \end {align*}

This is a Riccati ODE. Comparing the ODE to solve \[ \phi ' = \frac {\phi ^{2}}{2}+\frac {\cos \left (\theta \right ) \phi }{\sin \left (\theta \right )}+\frac {\cos \left (\theta \right )^{2}}{\sin \left (\theta \right )^{2}}+\frac {1}{2 \sin \left (\theta \right )^{2}} \] With Riccati ODE standard form \[ \phi ' = f_0(\theta )+ f_1(\theta )\phi +f_2(\theta )\phi ^{2} \] Shows that \(f_0(\theta )=\frac {2+\cos \left (2 \theta \right )}{2 \sin \left (\theta \right )^{2}}\), \(f_1(\theta )=\frac {\cos \left (\theta \right )}{\sin \left (\theta \right )}\) and \(f_2(\theta )={\frac {1}{2}}\). Let \begin {align*} \phi &= \frac {-u'}{f_2 u} \\ &= \frac {-u'}{\frac {u}{2}} \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''(\theta ) -\left ( f_2' + f_1 f_2 \right ) u'(\theta ) + f_2^2 f_0 u(\theta ) &= 0 \tag {2} \end {align*}

But \begin {align*} f_2' &=0\\ f_1 f_2 &=\frac {\cos \left (\theta \right )}{2 \sin \left (\theta \right )}\\ f_2^2 f_0 &=\frac {2+\cos \left (2 \theta \right )}{8 \sin \left (\theta \right )^{2}} \end {align*}

Substituting the above terms back in equation (2) gives \begin {align*} \frac {u^{\prime \prime }\left (\theta \right )}{2}-\frac {\cos \left (\theta \right ) u^{\prime }\left (\theta \right )}{2 \sin \left (\theta \right )}+\frac {\left (2+\cos \left (2 \theta \right )\right ) u \left (\theta \right )}{8 \sin \left (\theta \right )^{2}} &=0 \end {align*}

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

\[ u \left (\theta \right ) = \sqrt {\sin \left (\theta \right )}\, \left (c_{1} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+c_{2} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}\right ) \] The above shows that \[ u^{\prime }\left (\theta \right ) = \frac {\left (\sin \left (\theta \right )+\cos \left (\theta \right )\right ) c_{1} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+\left (-\sin \left (\theta \right )+\cos \left (\theta \right )\right ) c_{2} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}}{2 \sqrt {\sin \left (\theta \right )}} \] Using the above in (1) gives the solution \[ \phi = -\frac {\left (\sin \left (\theta \right )+\cos \left (\theta \right )\right ) c_{1} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+\left (-\sin \left (\theta \right )+\cos \left (\theta \right )\right ) c_{2} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}}{\sin \left (\theta \right ) \left (c_{1} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+c_{2} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}\right )} \] Dividing both numerator and denominator by \(c_{1}\) gives, after renaming the constant \(\frac {c_{2}}{c_{1}}=c_{3}\) the following solution

\[ \phi = \frac {\left (-\cot \left (\theta \right )+1\right ) \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}-c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}} \left (\cot \left (\theta \right )+1\right )}{c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+\left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}} \]

Summary

The solution(s) found are the following \begin{align*} \tag{1} \phi &= \frac {\left (-\cot \left (\theta \right )+1\right ) \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}-c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}} \left (\cot \left (\theta \right )+1\right )}{c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+\left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}} \\ \end{align*}

Figure 61: Slope field plot

Verification of solutions

\[ \phi = \frac {\left (-\cot \left (\theta \right )+1\right ) \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}-c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}} \left (\cot \left (\theta \right )+1\right )}{c_{3} \left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{\frac {i}{2}}+\left (\sin \left (\theta \right )+i \cos \left (\theta \right )\right )^{-\frac {i}{2}}} \] Verified OK.

4.10.2 Maple step by step solution

\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & \left (\phi ^{\prime }-\frac {\phi ^{2}}{2}\right ) \sin \left (\theta \right )^{2}-\cos \left (\theta \right ) \phi \sin \left (\theta \right )=\frac {\cos \left (2 \theta \right )}{2}+1 \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 1 \\ {} & {} & \phi ^{\prime } \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & \phi ^{\prime }=\frac {\phi ^{2} \sin \left (\theta \right )^{2}+2 \cos \left (\theta \right ) \phi \sin \left (\theta \right )+\cos \left (2 \theta \right )+2}{2 \sin \left (\theta \right )^{2}} \end {array} \]

Maple trace Kovacic algorithm successful

`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) = cos(x)*(diff(y(x), x))/sin(x)-(1/4)*(2*cos(x)^2+1)*y(x)/sin(x)^2, y(x) 
      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 a Liouvillian solution using Kovacics algorithm 
         A Liouvillian solution exists 
         Reducible group (found an exponential solution) 
         Reducible group (found another exponential solution) 
      <- Kovacics algorithm successful 
   <- Riccati to 2nd Order successful`
 

Solution by Maple

Time used: 0.016 (sec). Leaf size: 37

dsolve((diff(phi(theta),theta)-1/2*phi(theta)^2)*sin(theta)^2-phi(theta)*sin(theta)*cos(theta)=1/2*cos(2*theta)+1,phi(theta), singsol=all)
 

\[ \phi \left (\theta \right ) = \frac {-\sinh \left (\frac {\theta }{2}\right ) c_{1} -\cosh \left (\frac {\theta }{2}\right )}{\cosh \left (\frac {\theta }{2}\right ) c_{1} +\sinh \left (\frac {\theta }{2}\right )}-\cot \left (\theta \right ) \]

Solution by Mathematica

Time used: 0.64 (sec). Leaf size: 36

DSolve[(\[Phi]'[\[Theta]]-1/2\[Phi][\[Theta]]^2)*Sin[\[Theta]]^2-\[Phi][\[Theta]]*Sin[\[Theta]]*Cos[\[Theta]]==1/2*Cos[2*\[Theta]]+1,\[Phi][\[Theta]],\[Theta],IncludeSingularSolutions -> True]
 

\begin{align*} \phi (\theta )\to -\cot (\theta )-\frac {2 e^{\theta }}{e^{\theta }-2 c_1}+1 \\ \phi (\theta )\to 1-\cot (\theta ) \\ \end{align*}