60.1.126 problem 129

Internal problem ID [10140]
Book : Differential Gleichungen, E. Kamke, 3rd ed. Chelsea Pub. NY, 1948
Section : Chapter 1, linear first order
Problem number : 129
Date solved : Sunday, March 30, 2025 at 03:19:41 PM
CAS classification : [_rational, _Bernoulli]

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

Maple. Time used: 0.003 (sec). Leaf size: 33
ode:=(1+x)*diff(y(x),x)+(y(x)-x)*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {{\mathrm e}^{x}}{-\operatorname {Ei}_{1}\left (-x -1\right ) \left (x +1\right ) {\mathrm e}^{-1}-{\mathrm e}^{x}+c_1 \left (x +1\right )} \]
Mathematica. Time used: 0.305 (sec). Leaf size: 70
ode=(x+1)*D[y[x],x]+ y[x]*(y[x]-x)==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {\exp \left (\int _1^x\frac {K[1]}{K[1]+1}dK[1]\right )}{-\int _1^x-\frac {\exp \left (\int _1^{K[2]}\frac {K[1]}{K[1]+1}dK[1]\right )}{K[2]+1}dK[2]+c_1} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 1.825 (sec). Leaf size: 32
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((-x + y(x))*y(x) + (x + 1)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {e^{x}}{C_{1} x + C_{1} + x \int \frac {e^{x}}{\left (x + 1\right )^{2}}\, dx + \int \frac {e^{x}}{\left (x + 1\right )^{2}}\, dx} \]