73.3.45 problem 4.8 (d)

Internal problem ID [15008]
Book : Ordinary Differential Equations. An introduction to the fundamentals. Kenneth B. Howell. second edition. CRC Press. FL, USA. 2020
Section : Chapter 4. SEPARABLE FIRST ORDER EQUATIONS. Additional exercises. page 90
Problem number : 4.8 (d)
Date solved : Monday, March 31, 2025 at 01:12:04 PM
CAS classification : [_separable]

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

With initial conditions

\begin{align*} y \left (2\right )&=1 \end{align*}

Maple. Time used: 0.011 (sec). Leaf size: 5
ode:=x*diff(y(x),x) = y(x)^2-y(x); 
ic:=y(2) = 1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = 1 \]
Mathematica. Time used: 0.001 (sec). Leaf size: 6
ode=x*D[y[x],x]==y[x]^2-y[x]; 
ic={y[2]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to 1 \]
Sympy. Time used: 0.310 (sec). Leaf size: 3
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*Derivative(y(x), x) - y(x)**2 + y(x),0) 
ics = {y(2): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = 1 \]