3.5 problem 3 (E)

3.5.1 Solving as quadrature ode
3.5.2 Maple step by step solution

Internal problem ID [12618]
Internal file name [OUTPUT/11271_Friday_November_03_2023_06_29_33_AM_19494184/index.tex]

Book: Ordinary Differential Equations by Charles E. Roberts, Jr. CRC Press. 2010
Section: Chapter 2. The Initial Value Problem. Exercises 2.1, page 40
Problem number: 3 (E).
ODE order: 1.
ODE degree: 1.

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

Maple gives the following as the ode type

[_quadrature]

\[ \boxed {y^{\prime }-y^{2}=-4} \]

3.5.1 Solving as quadrature ode

Integrating both sides gives \begin {align*} \int \frac {1}{y^{2}-4}d y &= x +c_{1}\\ -\frac {\operatorname {arctanh}\left (\frac {y}{2}\right )}{2}&=x +c_{1} \end {align*}

Solving for \(y\) gives these solutions \begin {align*} y_1&=-2 \tanh \left (2 x +2 c_{1} \right ) \end {align*}

Summary

The solution(s) found are the following \begin{align*} \tag{1} y &= -2 \tanh \left (2 x +2 c_{1} \right ) \\ \end{align*}

Figure 90: Slope field plot

Verification of solutions

\[ y = -2 \tanh \left (2 x +2 c_{1} \right ) \] Verified OK.

3.5.2 Maple step by step solution

\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & y^{\prime }-y^{2}=-4 \\ \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 }=y^{2}-4 \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & \frac {y^{\prime }}{y^{2}-4}=1 \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \frac {y^{\prime }}{y^{2}-4}d x =\int 1d x +c_{1} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & -\frac {\ln \left (y+2\right )}{4}+\frac {\ln \left (y-2\right )}{4}=x +c_{1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & y=-\frac {2 \left ({\mathrm e}^{4 x +4 c_{1}}+1\right )}{-1+{\mathrm e}^{4 x +4 c_{1}}} \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`
 

Solution by Maple

Time used: 0.031 (sec). Leaf size: 24

dsolve(diff(y(x),x)=y(x)^2-4,y(x), singsol=all)
 

\[ y \left (x \right ) = \frac {-2 c_{1} {\mathrm e}^{4 x}-2}{-1+c_{1} {\mathrm e}^{4 x}} \]

Solution by Mathematica

Time used: 1.066 (sec). Leaf size: 40

DSolve[y'[x]==y[x]^2-4,y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to \frac {2-2 e^{4 (x+c_1)}}{1+e^{4 (x+c_1)}} \\ y(x)\to -2 \\ y(x)\to 2 \\ \end{align*}