26.5.21 problem Exercise 11.22, page 97

Internal problem ID [6994]
Book : Ordinary Differential Equations, By Tenenbaum and Pollard. Dover, NY 1963
Section : Chapter 2. Special types of differential equations of the first kind. Lesson 11, Bernoulli Equations
Problem number : Exercise 11.22, page 97
Date solved : Tuesday, September 30, 2025 at 04:08:00 PM
CAS classification : [_separable]

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

With initial conditions

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