8.3.25 problem 26

Internal problem ID [701]
Book : Differential equations and linear algebra, 3rd ed., Edwards and Penney
Section : Section 1.4. Separable equations. Page 43
Problem number : 26
Date solved : Tuesday, March 04, 2025 at 11:33:09 AM
CAS classification : [_separable]

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

With initial conditions

\begin{align*} y \left (1\right )&=-1 \end{align*}

Maple. Time used: 0.013 (sec). Leaf size: 16
ode:=diff(y(x),x) = 2*x*y(x)^2+3*x^2*y(x)^2; 
ic:=y(1) = -1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = -\frac {1}{x^{3}+x^{2}-1} \]
Mathematica. Time used: 0.136 (sec). Leaf size: 17
ode=D[y[x],x] == 2*x*y[x]^2+3*x^2*y[x]^2; 
ic=y[1]==-1; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to -\frac {1}{x^3+x^2-1} \]
Sympy. Time used: 0.281 (sec). Leaf size: 14
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-3*x**2*y(x)**2 - 2*x*y(x)**2 + Derivative(y(x), x),0) 
ics = {y(1): -1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = - \frac {1}{x^{3} + x^{2} - 1} \]