9.8.39 problem 41

Internal problem ID [3042]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 12, page 46
Problem number : 41
Date solved : Tuesday, September 30, 2025 at 06:24:24 AM
CAS classification : [_separable]

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

With initial conditions

\begin{align*} y \left (0\right )&=0 \\ \end{align*}
Maple. Time used: 0.146 (sec). Leaf size: 29
ode:=x*exp(-y(x)^2)+y(x)*diff(y(x),x) = 0; 
ic:=[y(0) = 0]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\begin{align*} y &= \sqrt {\ln \left (-x^{2}+1\right )} \\ y &= -\sqrt {\ln \left (-x^{2}+1\right )} \\ \end{align*}
Mathematica. Time used: 1.106 (sec). Leaf size: 35
ode=(x*Exp[-y[x]^2])+y[x]*D[y[x],x]==0; 
ic={y[0]==0}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\sqrt {\log \left (1-x^2\right )}\\ y(x)&\to \sqrt {\log \left (1-x^2\right )} \end{align*}
Sympy. Time used: 0.592 (sec). Leaf size: 26
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*exp(-y(x)**2) + y(x)*Derivative(y(x), x),0) 
ics = {y(0): 0} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - \sqrt {\log {\left (1 - x^{2} \right )}}, \ y{\left (x \right )} = \sqrt {\log {\left (1 - x^{2} \right )}}\right ] \]