30.6.27 problem 28

Internal problem ID [7562]
Book : Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
Section : Chapter 2, First order differential equations. Review problems. page 79
Problem number : 28
Date solved : Tuesday, September 30, 2025 at 04:51:46 PM
CAS classification : [[_homogeneous, `class C`], _rational, [_Abel, `2nd type`, `class A`]]

\begin{align*} y^{\prime }&=\frac {x -y-1}{x +y+5} \end{align*}
Maple. Time used: 0.096 (sec). Leaf size: 32
ode:=diff(y(x),x) = (x-y(x)-1)/(x+y(x)+5); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {-\sqrt {2 \left (x +2\right )^{2} c_1^{2}+1}+\left (-x -5\right ) c_1}{c_1} \]
Mathematica. Time used: 0.09 (sec). Leaf size: 53
ode=D[y[x],x]==(x-y[x]-1)/(x+y[x]+5); 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\sqrt {2 x^2+8 x+25+c_1}-x-5\\ y(x)&\to \sqrt {2 x^2+8 x+25+c_1}-x-5 \end{align*}
Sympy. Time used: 1.217 (sec). Leaf size: 39
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-(x - y(x) - 1)/(x + y(x) + 5) + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - x - \sqrt {C_{1} + 2 x^{2} + 8 x} - 5, \ y{\left (x \right )} = - x + \sqrt {C_{1} + 2 x^{2} + 8 x} - 5\right ] \]