40.4.24 problem 23 (d)

Internal problem ID [6664]
Book : Schaums Outline. Theory and problems of Differential Equations, 1st edition. Frank Ayres. McGraw Hill 1952
Section : Chapter 6. Equations of first order and first degree (Linear equations). Supplemetary problems. Page 39
Problem number : 23 (d)
Date solved : Sunday, March 30, 2025 at 11:15:31 AM
CAS classification : [_Abel]

\begin{align*} y^{\prime }+x \left (x +y\right )&=x^{3} \left (x +y\right )^{3}-1 \end{align*}

Maple. Time used: 0.002 (sec). Leaf size: 76
ode:=diff(y(x),x)+x*(x+y(x)) = x^3*(x+y(x))^3-1; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= -x \\ y &= -\frac {{\mathrm e}^{-\frac {x^{2}}{2}}}{\sqrt {{\mathrm e}^{-x^{2}} x^{2}+{\mathrm e}^{-x^{2}}+c_1}}-x \\ y &= \frac {{\mathrm e}^{-\frac {x^{2}}{2}}}{\sqrt {{\mathrm e}^{-x^{2}} x^{2}+{\mathrm e}^{-x^{2}}+c_1}}-x \\ \end{align*}
Mathematica. Time used: 10.052 (sec). Leaf size: 85
ode=D[y[x],x]+x*(x+y[x])==x^3*(x+y[x])^3-1; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -x-\frac {e^{-\frac {x^2}{2}}}{\sqrt {e^{-x^2} \left (x^2+1\right )+c_1}} \\ y(x)\to -x+\frac {e^{-\frac {x^2}{2}}}{\sqrt {e^{-x^2} \left (x^2+1\right )+c_1}} \\ y(x)\to -x \\ \end{align*}
Sympy. Time used: 7.042 (sec). Leaf size: 42
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**3*(x + y(x))**3 + x*(x + y(x)) + Derivative(y(x), x) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - x - \frac {1}{\sqrt {C_{1} e^{x^{2}} + x^{2} + 1}}, \ y{\left (x \right )} = - x + \frac {1}{\sqrt {C_{1} e^{x^{2}} + x^{2} + 1}}\right ] \]