53.4.18 problem 19

Internal problem ID [8506]
Book : Elementary differential equations. By Earl D. Rainville, Phillip E. Bedient. Macmilliam Publishing Co. NY. 6th edition. 1981.
Section : CHAPTER 16. Nonlinear equations. Section 101. Independent variable missing. EXERCISES Page 324
Problem number : 19
Date solved : Sunday, March 30, 2025 at 01:12:24 PM
CAS classification : [[_2nd_order, _missing_x], [_2nd_order, _reducible, _mu_x_y1]]

\begin{align*} y^{\prime \prime }&=-{\mathrm e}^{-2 y} \end{align*}

With initial conditions

\begin{align*} y \left (3\right )&=0\\ y^{\prime }\left (3\right )&=-1 \end{align*}

Maple. Time used: 0.079 (sec). Leaf size: 12
ode:=diff(diff(y(x),x),x) = -exp(-2*y(x)); 
ic:=y(3) = 0, D(y)(3) = -1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \frac {\ln \left (\left (x -4\right )^{2}\right )}{2} \]
Mathematica. Time used: 0.162 (sec). Leaf size: 11
ode=D[y[x],{x,2}]==-Exp[-2*y[x]]; 
ic={y[3]==0,Derivative[1][y][3 ]==-1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \log (4-x) \]
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(Derivative(y(x), (x, 2)) + exp(-2*y(x)),0) 
ics = {y(3): 0, Subs(Derivative(y(x), x), x, 3): -1} 
dsolve(ode,func=y(x),ics=ics)