2.3.10 problem 10

Internal problem ID [686]
Book : Differential equations and linear algebra, 3rd ed., Edwards and Penney
Section : Section 1.4. Separable equations. Page 43
Problem number : 10
Date solved : Tuesday, September 30, 2025 at 04:06:00 AM
CAS classification : [_separable]

\begin{align*} \left (x^{2}+1\right ) y^{\prime }&=\left (1+y\right )^{2} \end{align*}
Maple. Time used: 0.003 (sec). Leaf size: 20
ode:=(x^2+1)*diff(y(x),x) = (1+y(x))^2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {-\arctan \left (x \right )-c_1 -1}{\arctan \left (x \right )+c_1} \]
Mathematica. Time used: 0.136 (sec). Leaf size: 25
ode=(x^2+1)*D[y[x],x]== (1+y[x])^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\frac {\arctan (x)+1+c_1}{\arctan (x)+c_1}\\ y(x)&\to -1 \end{align*}
Sympy. Time used: 0.135 (sec). Leaf size: 15
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x**2 + 1)*Derivative(y(x), x) - (y(x) + 1)**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {- C_{1} - \operatorname {atan}{\left (x \right )} - 1}{C_{1} + \operatorname {atan}{\left (x \right )}} \]