70.1.20 problem 20

Internal problem ID [18606]
Book : Differential equations. An introduction to modern methods and applications. James Brannan, William E. Boyce. Third edition. Wiley 2015
Section : Chapter 2. First order differential equations. Section 2.1 (Separable equations). Problems at page 44
Problem number : 20
Date solved : Thursday, October 02, 2025 at 03:15:57 PM
CAS classification : [_separable]

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

With initial conditions

\begin{align*} y \left (2\right )&=0 \\ \end{align*}
Maple. Time used: 0.092 (sec). Leaf size: 12
ode:=diff(y(x),x) = x^2*exp(-3*y(x)); 
ic:=[y(2) = 0]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\[ y = \frac {\ln \left (x^{3}-7\right )}{3} \]
Mathematica. Time used: 0.22 (sec). Leaf size: 15
ode=D[y[x],x]==x^2*Exp[-3*y[x]]; 
ic={y[2]==0}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{3} \log \left (x^3-7\right ) \end{align*}
Sympy. Time used: 0.643 (sec). Leaf size: 10
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**2*exp(-3*y(x)) + Derivative(y(x), x),0) 
ics = {y(2): 0} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {\log {\left (x^{3} - 7 \right )}}{3} \]