58.4.7 problem 7

Internal problem ID [14577]
Book : Differential Equations by Shepley L. Ross. Third edition. John Willey. New Delhi. 2004.
Section : Chapter 2, section 2.2 (Separable equations). Exercises page 47
Problem number : 7
Date solved : Thursday, October 02, 2025 at 09:42:37 AM
CAS classification : [_separable]

\begin{align*} \left (4+x \right ) \left (1+y^{2}\right )+y \left (x^{2}+3 x +2\right ) y^{\prime }&=0 \end{align*}
Maple. Time used: 0.005 (sec). Leaf size: 114
ode:=(x+4)*(1+y(x)^2)+y(x)*(x^2+3*x+2)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \frac {\sqrt {-x^{6}-6 x^{5}+c_1 \,x^{4}+\left (8 c_1 +100\right ) x^{3}+\left (24 c_1 +345\right ) x^{2}+\left (32 c_1 +474\right ) x +16 c_1 +239}}{\left (x +1\right )^{3}} \\ y &= -\frac {\sqrt {-x^{6}-6 x^{5}+c_1 \,x^{4}+\left (8 c_1 +100\right ) x^{3}+\left (24 c_1 +345\right ) x^{2}+\left (32 c_1 +474\right ) x +16 c_1 +239}}{\left (x +1\right )^{3}} \\ \end{align*}
Mathematica. Time used: 4.594 (sec). Leaf size: 126
ode=(x+4)*(y[x]^2+1) + y[x]*(x^2+3*x+2)*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\frac {\sqrt {-(x+1)^6+e^{2 c_1} (x+2)^4}}{(x+1)^3}\\ y(x)&\to \frac {\sqrt {-(x+1)^6+e^{2 c_1} (x+2)^4}}{(x+1)^3}\\ y(x)&\to -i\\ y(x)&\to i\\ y(x)&\to \frac {(x+1)^3}{\sqrt {-(x+1)^6}}\\ y(x)&\to \frac {\sqrt {-(x+1)^6}}{(x+1)^3} \end{align*}
Sympy. Time used: 8.416 (sec). Leaf size: 393
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x + 4)*(y(x)**2 + 1) + (x**2 + 3*x + 2)*y(x)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - \sqrt {\frac {x^{4} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {8 x^{3} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {24 x^{2} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {32 x e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} - 1 + \frac {16 e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1}}, \ y{\left (x \right )} = \sqrt {\frac {x^{4} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {8 x^{3} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {24 x^{2} e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} + \frac {32 x e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1} - 1 + \frac {16 e^{2 C_{1}}}{x^{6} + 6 x^{5} + 15 x^{4} + 20 x^{3} + 15 x^{2} + 6 x + 1}}\right ] \]