5.22 problem 22

5.22.1 Solved as second order missing x ode
5.22.2 Solved as second order can be made integrable
5.22.3 Maple step by step solution
5.22.4 Maple trace
5.22.5 Maple dsolve solution
5.22.6 Mathematica DSolve solution

Internal problem ID [7963]
Book : Own collection of miscellaneous problems
Section : section 5.0
Problem number : 22
Date solved : Monday, October 21, 2024 at 04:39:42 PM
CAS classification : [[_2nd_order, _missing_x], [_2nd_order, _reducible, _mu_x_y1]]

Solve

\begin{align*} y^{\prime \prime }+{\mathrm e}^{y}&=0 \end{align*}

5.22.1 Solved as second order missing x ode

Time used: 7.813 (sec)

This is missing independent variable second order ode. Solved by reduction of order by using substitution which makes the dependent variable \(y\) an independent variable. Using

\begin{align*} y' &= p \end{align*}

Then

\begin{align*} y'' &= \frac {dp}{dx}\\ &= \frac {dp}{dy}\frac {dy}{dx}\\ &= p \frac {dp}{dy} \end{align*}

Hence the ode becomes

\begin{align*} p \left (y \right ) \left (\frac {d}{d y}p \left (y \right )\right )+{\mathrm e}^{y} = 0 \end{align*}

Which is now solved as first order ode for \(p(y)\).

The ode \(p^{\prime } = -\frac {{\mathrm e}^{y}}{p}\) is separable as it can be written as

\begin{align*} p^{\prime }&= -\frac {{\mathrm e}^{y}}{p}\\ &= f(y) g(p) \end{align*}

Where

\begin{align*} f(y) &= -{\mathrm e}^{y}\\ g(p) &= \frac {1}{p} \end{align*}

Integrating gives

\begin{align*} \int { \frac {1}{g(p)} \,dp} &= \int { f(y) \,dy}\\ \int { p\,dp} &= \int { -{\mathrm e}^{y} \,dy}\\ \frac {p^{2}}{2}&=-{\mathrm e}^{y}+c_1 \end{align*}

Solving for \(p\) from the above solution(s) gives (after possible removing of solutions that do not verify)

\begin{align*} p&=\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}\\ p&=-\sqrt {-2 \,{\mathrm e}^{y}+2 c_1} \end{align*}

For solution (1) found earlier, since \(p=y^{\prime }\) then we now have a new first order ode to solve which is

\begin{align*} y^{\prime } = \sqrt {-2 \,{\mathrm e}^{y}+2 c_1} \end{align*}

Integrating gives

\begin{align*} \int \frac {1}{\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}}d y &= dx\\ -\frac {\sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}\, \sqrt {2}}{2 \sqrt {c_1}}\right )}{\sqrt {c_1}}&= x +c_2 \end{align*}

Singular solutions are found by solving

\begin{align*} \sqrt {-2 \,{\mathrm e}^{y}+2 c_1}&= 0 \end{align*}

for \(y\). This is because we had to divide by this in the above step. This gives the following singular solution(s), which also have to satisfy the given ODE.

\begin{align*} y = \ln \left (c_1 \right ) \end{align*}

For solution (2) found earlier, since \(p=y^{\prime }\) then we now have a new first order ode to solve which is

\begin{align*} y^{\prime } = -\sqrt {-2 \,{\mathrm e}^{y}+2 c_1} \end{align*}

Integrating gives

\begin{align*} \int -\frac {1}{\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}}d y &= dx\\ \frac {\sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}\, \sqrt {2}}{2 \sqrt {c_1}}\right )}{\sqrt {c_1}}&= x +c_3 \end{align*}

Singular solutions are found by solving

\begin{align*} -\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}&= 0 \end{align*}

for \(y\). This is because we had to divide by this in the above step. This gives the following singular solution(s), which also have to satisfy the given ODE.

\begin{align*} y = \ln \left (c_1 \right ) \end{align*}

Solving for \(y\) from the above solution(s) gives (after possible removing of solutions that do not verify)

\begin{align*} y&=\ln \left (c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_3 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right ) \end{align*}

Will add steps showing solving for IC soon.

Solving for \(y\) from the above solution(s) gives (after possible removing of solutions that do not verify)

\begin{align*} y&=\ln \left (c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_2 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_3 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right ) \end{align*}

The solution

\[ y = \ln \left (c_1 \right ) \]

was found not to satisfy the ode or the IC. Hence it is removed.

5.22.2 Solved as second order can be made integrable

Time used: 6.756 (sec)

Multiplying the ode by \(y^{\prime }\) gives

\[ y^{\prime } y^{\prime \prime }+y^{\prime } {\mathrm e}^{y} = 0 \]

Integrating the above w.r.t \(x\) gives

\begin{align*} \int \left (y^{\prime } y^{\prime \prime }+y^{\prime } {\mathrm e}^{y}\right )d x &= 0 \\ \frac {{y^{\prime }}^{2}}{2}+{\mathrm e}^{y} &= c_1 \end{align*}

Which is now solved for \(y\). Solving for the derivative gives these ODE’s to solve

\begin{align*} \tag{1} y^{\prime }&=\sqrt {-2 \,{\mathrm e}^{y}+2 c_1} \\ \tag{2} y^{\prime }&=-\sqrt {-2 \,{\mathrm e}^{y}+2 c_1} \\ \end{align*}

Now each of the above is solved separately.

Solving Eq. (1)

Integrating gives

\begin{align*} \int \frac {1}{\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}}d y &= dx\\ -\frac {\sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}\, \sqrt {2}}{2 \sqrt {c_1}}\right )}{\sqrt {c_1}}&= x +c_2 \end{align*}

Singular solutions are found by solving

\begin{align*} \sqrt {-2 \,{\mathrm e}^{y}+2 c_1}&= 0 \end{align*}

for \(y\). This is because we had to divide by this in the above step. This gives the following singular solution(s), which also have to satisfy the given ODE.

\begin{align*} y = \ln \left (c_1 \right ) \end{align*}

Solving Eq. (2)

Integrating gives

\begin{align*} \int -\frac {1}{\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}}d y &= dx\\ \frac {\sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}\, \sqrt {2}}{2 \sqrt {c_1}}\right )}{\sqrt {c_1}}&= x +c_3 \end{align*}

Singular solutions are found by solving

\begin{align*} -\sqrt {-2 \,{\mathrm e}^{y}+2 c_1}&= 0 \end{align*}

for \(y\). This is because we had to divide by this in the above step. This gives the following singular solution(s), which also have to satisfy the given ODE.

\begin{align*} y = \ln \left (c_1 \right ) \end{align*}

Solving for \(y\) from the above solution(s) gives (after possible removing of solutions that do not verify)

\begin{align*} y&=\ln \left (c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_3 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right ) \end{align*}

Will add steps showing solving for IC soon.

Solving for \(y\) from the above solution(s) gives (after possible removing of solutions that do not verify)

\begin{align*} y&=\ln \left (c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_2 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right )\\ y&=\ln \left (-\tanh \left (\frac {\sqrt {c_1}\, \left (x +c_3 \right ) \sqrt {2}}{2}\right )^{2} c_1 +c_1 \right ) \end{align*}

The solution

\[ y = \ln \left (c_1 \right ) \]

was found not to satisfy the ode or the IC. Hence it is removed.

5.22.3 Maple step by step solution
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & \frac {d}{d x}y^{\prime }+{\mathrm e}^{y}=0 \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 2 \\ {} & {} & \frac {d}{d x}y^{\prime } \\ \bullet & {} & \textrm {Define new dependent variable}\hspace {3pt} u \\ {} & {} & u \left (x \right )=y^{\prime } \\ \bullet & {} & \textrm {Compute}\hspace {3pt} \frac {d}{d x}y^{\prime } \\ {} & {} & u^{\prime }\left (x \right )=y^{\prime \prime } \\ \bullet & {} & \textrm {Use chain rule on the lhs}\hspace {3pt} \\ {} & {} & y^{\prime } \left (\frac {d}{d y}u \left (y \right )\right )=y^{\prime \prime } \\ \bullet & {} & \textrm {Substitute in the definition of}\hspace {3pt} u \\ {} & {} & u \left (y \right ) \left (\frac {d}{d y}u \left (y \right )\right )=y^{\prime \prime } \\ \bullet & {} & \textrm {Make substitutions}\hspace {3pt} y^{\prime }=u \left (y \right ),\frac {d}{d x}y^{\prime }=u \left (y \right ) \left (\frac {d}{d y}u \left (y \right )\right )\hspace {3pt}\textrm {to reduce order of ODE}\hspace {3pt} \\ {} & {} & u \left (y \right ) \left (\frac {d}{d y}u \left (y \right )\right )+{\mathrm e}^{y}=0 \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & u \left (y \right ) \left (\frac {d}{d y}u \left (y \right )\right )=-{\mathrm e}^{y} \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} y \\ {} & {} & \int u \left (y \right ) \left (\frac {d}{d y}u \left (y \right )\right )d y =\int -{\mathrm e}^{y}d y +\mathit {C1} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & \frac {u \left (y \right )^{2}}{2}=-{\mathrm e}^{y}+\mathit {C1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} u \left (y \right ) \\ {} & {} & \left \{u \left (y \right )=\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}, u \left (y \right )=-\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}\right \} \\ \bullet & {} & \textrm {Solve 1st ODE for}\hspace {3pt} u \left (y \right ) \\ {} & {} & u \left (y \right )=\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Revert to original variables with substitution}\hspace {3pt} u \left (y \right )=y^{\prime },y =y \\ {} & {} & y^{\prime }=\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & y^{\prime }=\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & \frac {y^{\prime }}{\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}}=1 \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \frac {y^{\prime }}{\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}}d x =\int 1d x +\mathit {C2} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & -\frac {\sqrt {2}\, \mathrm {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}\, \sqrt {2}}{2 \sqrt {\mathit {C1}}}\right )}{\sqrt {\mathit {C1}}}=x +\mathit {C2} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & y=\ln \left (-\tanh \left (\frac {\sqrt {\mathit {C1}}\, \left (x +\mathit {C2} \right ) \sqrt {2}}{2}\right )^{2} \mathit {C1} +\mathit {C1} \right ) \\ \bullet & {} & \textrm {Solve 2nd ODE for}\hspace {3pt} u \left (y \right ) \\ {} & {} & u \left (y \right )=-\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Revert to original variables with substitution}\hspace {3pt} u \left (y \right )=y^{\prime },y =y \\ {} & {} & y^{\prime }=-\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & y^{\prime }=-\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}} \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & \frac {y^{\prime }}{\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}}=-1 \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \frac {y^{\prime }}{\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}}d x =\int \left (-1\right )d x +\mathit {C2} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & -\frac {\sqrt {2}\, \mathrm {arctanh}\left (\frac {\sqrt {-2 \,{\mathrm e}^{y}+2 \mathit {C1}}\, \sqrt {2}}{2 \sqrt {\mathit {C1}}}\right )}{\sqrt {\mathit {C1}}}=-x +\mathit {C2} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & y=\ln \left (-\tanh \left (\frac {\sqrt {\mathit {C1}}\, \left (-x +\mathit {C2} \right ) \sqrt {2}}{2}\right )^{2} \mathit {C1} +\mathit {C1} \right ) \end {array} \]

5.22.4 Maple trace
Methods for second order ODEs:
 
5.22.5 Maple dsolve solution

Solving time : 0.032 (sec)
Leaf size : 25

dsolve(diff(diff(y(x),x),x)+exp(y(x)) = 0, 
       y(x),singsol=all)
 
\[ y = -\ln \left (2\right )+\ln \left (\frac {\operatorname {sech}\left (\frac {x +c_2}{2 c_1}\right )^{2}}{c_1^{2}}\right ) \]
5.22.6 Mathematica DSolve solution

Solving time : 21.487 (sec)
Leaf size : 60

DSolve[{D[y[x],{x,2}]+Exp[y[x]]==0,{}}, 
       y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \log \left (\frac {1}{2} c_1 \text {sech}^2\left (\frac {1}{2} \sqrt {c_1 (x+c_2){}^2}\right )\right ) \\ y(x)\to \log \left (\frac {1}{2} c_1 \text {sech}^2\left (\frac {\sqrt {c_1 x^2}}{2}\right )\right ) \\ \end{align*}