Internal problem ID [15430]
Internal file name [OUTPUT/15431_Wednesday_May_08_2024_03_58_38_PM_85480017/index.tex
]
Book: A book of problems in ordinary differential equations. M.L. KRASNOV, A.L. KISELYOV,
G.I. MARKARENKO. MIR, MOSCOW. 1983
Section: Chapter 2 (Higher order ODE’s). Section 15.5 Linear equations with variable coefficients.
The Lagrange method. Exercises page 148
Problem number: 666.
ODE order: 2.
ODE degree: 1.
The type(s) of ODE detected by this program : "second_order_ode_missing_y"
Maple gives the following as the ode type
[[_2nd_order, _missing_y]]
\[ \boxed {y^{\prime \prime }+y^{\prime } \tan \left (x \right )=\cot \left (x \right ) \cos \left (x \right )} \]
This is second order ode with missing dependent variable \(y\). Let \begin {align*} p(x) &= y^{\prime } \end {align*}
Then \begin {align*} p'(x) &= y^{\prime \prime } \end {align*}
Hence the ode becomes \begin {align*} p^{\prime }\left (x \right )+p \left (x \right ) \tan \left (x \right )-\cot \left (x \right ) \cos \left (x \right ) = 0 \end {align*}
Which is now solve for \(p(x)\) as first order ode.
Entering Linear first order ODE solver. In canonical form a linear first order is \begin {align*} p^{\prime }\left (x \right ) + p(x)p \left (x \right ) &= q(x) \end {align*}
Where here \begin {align*} p(x) &=\tan \left (x \right )\\ q(x) &=\cot \left (x \right ) \cos \left (x \right ) \end {align*}
Hence the ode is \begin {align*} p^{\prime }\left (x \right )+p \left (x \right ) \tan \left (x \right ) = \cot \left (x \right ) \cos \left (x \right ) \end {align*}
The integrating factor \(\mu \) is \begin{align*} \mu &= {\mathrm e}^{\int \tan \left (x \right )d x} \\ &= \frac {1}{\cos \left (x \right )} \\ \end{align*} Which simplifies to \[ \mu = \sec \left (x \right ) \] The ode becomes \begin {align*} \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu p\right ) &= \left (\mu \right ) \left (\cot \left (x \right ) \cos \left (x \right )\right ) \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}} \left (\sec \left (x \right ) p\right ) &= \left (\sec \left (x \right )\right ) \left (\cot \left (x \right ) \cos \left (x \right )\right )\\ \mathrm {d} \left (\sec \left (x \right ) p\right ) &= \cot \left (x \right )\, \mathrm {d} x \end {align*}
Integrating gives \begin {align*} \sec \left (x \right ) p &= \int {\cot \left (x \right )\,\mathrm {d} x}\\ \sec \left (x \right ) p &= \ln \left (\sin \left (x \right )\right ) + c_{1} \end {align*}
Dividing both sides by the integrating factor \(\mu =\sec \left (x \right )\) results in \begin {align*} p \left (x \right ) &= \cos \left (x \right ) \ln \left (\sin \left (x \right )\right )+c_{1} \cos \left (x \right ) \end {align*}
which simplifies to \begin {align*} p \left (x \right ) &= \cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \end {align*}
Since \(p=y^{\prime }\) then the new first order ode to solve is \begin {align*} y^{\prime } = \cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \end {align*}
Integrating both sides gives \begin {align*} y &= \int { \cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right )\,\mathop {\mathrm {d}x}}\\ &= \left (-1+\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \sin \left (x \right )+c_{2} \end {align*}
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= \left (-1+\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \sin \left (x \right )+c_{2} \\ \end{align*}
Verification of solutions
\[ y = \left (-1+\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \sin \left (x \right )+c_{2} \] Verified OK.
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & y^{\prime \prime }+y^{\prime } \tan \left (x \right )=\cot \left (x \right ) \cos \left (x \right ) \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 2 \\ {} & {} & y^{\prime \prime } \\ \bullet & {} & \textrm {Make substitution}\hspace {3pt} u =y^{\prime }\hspace {3pt}\textrm {to reduce order of ODE}\hspace {3pt} \\ {} & {} & u^{\prime }\left (x \right )+u \left (x \right ) \tan \left (x \right )=\cot \left (x \right ) \cos \left (x \right ) \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & u^{\prime }\left (x \right )=-u \left (x \right ) \tan \left (x \right )+\cot \left (x \right ) \cos \left (x \right ) \\ \bullet & {} & \textrm {Group terms with}\hspace {3pt} u \left (x \right )\hspace {3pt}\textrm {on the lhs of the ODE and the rest on the rhs of the ODE}\hspace {3pt} \\ {} & {} & u^{\prime }\left (x \right )+u \left (x \right ) \tan \left (x \right )=\cot \left (x \right ) \cos \left (x \right ) \\ \bullet & {} & \textrm {The ODE is linear; multiply by an integrating factor}\hspace {3pt} \mu \left (x \right ) \\ {} & {} & \mu \left (x \right ) \left (u^{\prime }\left (x \right )+u \left (x \right ) \tan \left (x \right )\right )=\mu \left (x \right ) \cot \left (x \right ) \cos \left (x \right ) \\ \bullet & {} & \textrm {Assume the lhs of the ODE is the total derivative}\hspace {3pt} \frac {d}{d x}\left (u \left (x \right ) \mu \left (x \right )\right ) \\ {} & {} & \mu \left (x \right ) \left (u^{\prime }\left (x \right )+u \left (x \right ) \tan \left (x \right )\right )=u^{\prime }\left (x \right ) \mu \left (x \right )+u \left (x \right ) \mu ^{\prime }\left (x \right ) \\ \bullet & {} & \textrm {Isolate}\hspace {3pt} \mu ^{\prime }\left (x \right ) \\ {} & {} & \mu ^{\prime }\left (x \right )=\mu \left (x \right ) \tan \left (x \right ) \\ \bullet & {} & \textrm {Solve to find the integrating factor}\hspace {3pt} \\ {} & {} & \mu \left (x \right )=\frac {1}{\cos \left (x \right )} \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \left (\frac {d}{d x}\left (u \left (x \right ) \mu \left (x \right )\right )\right )d x =\int \mu \left (x \right ) \cot \left (x \right ) \cos \left (x \right )d x +c_{1} \\ \bullet & {} & \textrm {Evaluate the integral on the lhs}\hspace {3pt} \\ {} & {} & u \left (x \right ) \mu \left (x \right )=\int \mu \left (x \right ) \cot \left (x \right ) \cos \left (x \right )d x +c_{1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} u \left (x \right ) \\ {} & {} & u \left (x \right )=\frac {\int \mu \left (x \right ) \cot \left (x \right ) \cos \left (x \right )d x +c_{1}}{\mu \left (x \right )} \\ \bullet & {} & \textrm {Substitute}\hspace {3pt} \mu \left (x \right )=\frac {1}{\cos \left (x \right )} \\ {} & {} & u \left (x \right )=\cos \left (x \right ) \left (\int \cot \left (x \right )d x +c_{1} \right ) \\ \bullet & {} & \textrm {Evaluate the integrals on the rhs}\hspace {3pt} \\ {} & {} & u \left (x \right )=\cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \\ \bullet & {} & \textrm {Solve 1st ODE for}\hspace {3pt} u \left (x \right ) \\ {} & {} & u \left (x \right )=\cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \\ \bullet & {} & \textrm {Make substitution}\hspace {3pt} u =y^{\prime } \\ {} & {} & y^{\prime }=\cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \\ \bullet & {} & \textrm {Integrate both sides to solve for}\hspace {3pt} y \\ {} & {} & \int y^{\prime }d x =\int \cos \left (x \right ) \left (\ln \left (\sin \left (x \right )\right )+c_{1} \right )d x +c_{2} \\ \bullet & {} & \textrm {Compute integrals}\hspace {3pt} \\ {} & {} & y=c_{1} \sin \left (x \right )+\ln \left (\sin \left (x \right )\right ) \sin \left (x \right )-\sin \left (x \right )+c_{2} \end {array} \]
Maple trace
`Methods for second order ODEs: --- Trying classification methods --- trying a quadrature trying high order exact linear fully integrable -> Calling odsolve with the ODE`, diff(_b(_a), _a) = -_b(_a)*tan(_a)+cot(_a)*cos(_a), _b(_a)` *** Sublevel 2 *** Methods for first order ODEs: --- Trying classification methods --- trying a quadrature trying 1st order linear <- 1st order linear successful <- high order exact linear fully integrable successful`
✓ Solution by Maple
Time used: 0.015 (sec). Leaf size: 15
dsolve(diff(y(x),x$2)+tan(x)*diff(y(x),x)=cos(x)*cot(x),y(x), singsol=all)
\[ y \left (x \right ) = c_{2} +\sin \left (x \right ) \left (-1+\ln \left (\sin \left (x \right )\right )+c_{1} \right ) \]
✓ Solution by Mathematica
Time used: 0.14 (sec). Leaf size: 39
DSolve[y''[x]+Tan[x]*y'[x]==Cos[x]*Cot[x],y[x],x,IncludeSingularSolutions -> True]
\[ y(x)\to \frac {1}{2} \sqrt {\sin ^2(x)} \log \left (\sin ^2(x)\right )-(1+c_2) \sqrt {\sin ^2(x)}+c_1 \]