69.4.32 problem 97

Internal problem ID [18021]
Book : A book of problems in ordinary differential equations. M.L. KRASNOV, A.L. KISELYOV, G.I. MARKARENKO. MIR, MOSCOW. 1983
Section : Section 4. Equations with variables separable and equations reducible to them. Exercises page 38
Problem number : 97
Date solved : Thursday, October 02, 2025 at 02:33:37 PM
CAS classification : [_separable]

\begin{align*} \left (1+x \right ) y^{\prime }&=y-1 \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 10
ode:=(1+x)*diff(y(x),x) = y(x)-1; 
dsolve(ode,y(x), singsol=all);
 
\[ y = c_1 x +c_1 +1 \]
Mathematica. Time used: 0.018 (sec). Leaf size: 18
ode=(x+1)*D[y[x],x]==y[x]-1; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to 1+c_1 (x+1)\\ y(x)&\to 1 \end{align*}
Sympy. Time used: 0.137 (sec). Leaf size: 8
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x + 1)*Derivative(y(x), x) - y(x) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} x + C_{1} + 1 \]