2.3.4 problem 4

Solved as first order separable ode
Maple step by step solution
Maple trace
Maple dsolve solution
Mathematica DSolve solution

Internal problem ID [18224]
Book : Elementary Differential Equations. By Thornton C. Fry. D Van Nostrand. NY. First Edition (1929)
Section : Chapter IV. Methods of solution: First order equations. section 29. Problems at page 81
Problem number : 4
Date solved : Friday, December 20, 2024 at 10:45:27 AM
CAS classification : [_separable]

Solve

\begin{align*} \sec \left (x \right )^{2} \tan \left (y\right ) y^{\prime }+\sec \left (y\right )^{2} \tan \left (x \right )&=0 \end{align*}

Solved as first order separable ode

Time used: 0.308 (sec)

The ode \(y^{\prime } = -\frac {\sec \left (y\right )^{2} \tan \left (x \right )}{\sec \left (x \right )^{2} \tan \left (y\right )}\) is separable as it can be written as

\begin{align*} y^{\prime }&= -\frac {\sec \left (y\right )^{2} \tan \left (x \right )}{\sec \left (x \right )^{2} \tan \left (y\right )}\\ &= f(x) g(y) \end{align*}

Where

\begin{align*} f(x) &= -\frac {\tan \left (x \right )}{\sec \left (x \right )^{2}}\\ g(y) &= \frac {\sec \left (y \right )^{2}}{\tan \left (y \right )} \end{align*}

Integrating gives

\begin{align*} \int { \frac {1}{g(y)} \,dy} &= \int { f(x) \,dx}\\ \int { \frac {\tan \left (y \right )}{\sec \left (y \right )^{2}}\,dy} &= \int { -\frac {\tan \left (x \right )}{\sec \left (x \right )^{2}} \,dx}\\ -\frac {\cos \left (y\right )^{2}}{2}&=\frac {\cos \left (x \right )^{2}}{2}+c_1 \end{align*}

Solving for \(y\) gives

\begin{align*} y &= \pi -\arccos \left (\sqrt {-\cos \left (x \right )^{2}-2 c_1}\right ) \\ y &= \arccos \left (\sqrt {-\cos \left (x \right )^{2}-2 c_1}\right ) \\ \end{align*}
Figure 2.31: Slope field plot
\(\sec \left (x \right )^{2} \tan \left (y\right ) y^{\prime }+\sec \left (y\right )^{2} \tan \left (x \right ) = 0\)

Summary of solutions found

\begin{align*} y &= \pi -\arccos \left (\sqrt {-\cos \left (x \right )^{2}-2 c_1}\right ) \\ y &= \arccos \left (\sqrt {-\cos \left (x \right )^{2}-2 c_1}\right ) \\ \end{align*}
Maple step by step solution
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & \sec \left (x \right )^{2} \tan \left (y\right ) y^{\prime }+\sec \left (y\right )^{2} \tan \left (x \right )=0 \\ \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 {\sec \left (y\right )^{2} \tan \left (x \right )}{\sec \left (x \right )^{2} \tan \left (y\right )} \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & \frac {y^{\prime } \tan \left (y\right )}{\sec \left (y\right )^{2}}=-\frac {\tan \left (x \right )}{\sec \left (x \right )^{2}} \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \frac {y^{\prime } \tan \left (y\right )}{\sec \left (y\right )^{2}}d x =\int -\frac {\tan \left (x \right )}{\sec \left (x \right )^{2}}d x +\mathit {C1} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & -\frac {1}{2 \sec \left (y\right )^{2}}=\frac {1}{2 \sec \left (x \right )^{2}}+\mathit {C1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & \left \{y=\pi -\mathrm {arcsec}\left (\frac {1}{\sqrt {-\cos \left (x \right )^{2}-2 \mathit {C1}}}\right ), y=\mathrm {arcsec}\left (\frac {1}{\sqrt {-\cos \left (x \right )^{2}-2 \mathit {C1}}}\right )\right \} \end {array} \]

Maple trace
`Methods for first order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
trying 1st order linear 
trying Bernoulli 
trying separable 
<- separable successful`
 
Maple dsolve solution

Solving time : 0.006 (sec)
Leaf size : 41

dsolve(sec(x)^2*tan(y(x))*diff(y(x),x)+sec(y(x))^2*tan(x) = 0, 
       y(x),singsol=all)
 
\begin{align*} y &= \operatorname {arcsec}\left (\frac {2}{\sqrt {-2 \cos \left (2 x \right )+8 c_1}}\right ) \\ y &= \frac {\pi }{2}+\operatorname {arccsc}\left (\frac {2}{\sqrt {-2 \cos \left (2 x \right )+8 c_1}}\right ) \\ \end{align*}
Mathematica DSolve solution

Solving time : 0.522 (sec)
Leaf size : 41

DSolve[{Sec[x]^2*Tan[y[x]]*D[y[x],x]+Sec[y[x]]^2*Tan[x]==0,{}}, 
       y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\frac {1}{2} \arccos (-\cos (2 x)-2 c_1) \\ y(x)\to \frac {1}{2} \arccos (-\cos (2 x)-2 c_1) \\ \end{align*}