34.2.24 problem 49

Internal problem ID [7889]
Book : Schaums Outline. Theory and problems of Differential Equations, 1st edition. Frank Ayres. McGraw Hill 1952
Section : Chapter 4. Equations of first order and first degree (Variable separable). Supplemetary problems. Page 22
Problem number : 49
Date solved : Tuesday, September 30, 2025 at 05:09:20 PM
CAS classification : [_rational, _Bernoulli]

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

With initial conditions

\begin{align*} y \left (1\right )&=1 \\ \end{align*}
Maple. Time used: 0.163 (sec). Leaf size: 22
ode:=y(x)^2+x*y(x)-x*diff(y(x),x) = 0; 
ic:=[y(1) = 1]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\[ y = \frac {{\mathrm e}^{x}}{\operatorname {Ei}_{1}\left (-x \right )+{\mathrm e}-\operatorname {Ei}_{1}\left (-1\right )} \]
Mathematica. Time used: 0.115 (sec). Leaf size: 31
ode=(y[x]^2+x*y[x])-x*D[y[x],x]== 0; 
ic={y[1]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {e^x}{e-\int _1^x\frac {e^{K[1]}}{K[1]}dK[1]} \end{align*}
Sympy. Time used: 0.267 (sec). Leaf size: 15
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*y(x) - x*Derivative(y(x), x) + y(x)**2,0) 
ics = {y(1): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {e^{x}}{- \operatorname {Ei}{\left (x \right )} + \operatorname {Ei}{\left (1 \right )} + e} \]