8.3.19 problem 20

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

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

With initial conditions

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

Maple. Time used: 0.020 (sec). Leaf size: 12
ode:=diff(y(x),x) = 3*x^2*(1+y(x)^2); 
ic:=y(0) = 1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \tan \left (x^{3}+\frac {\pi }{4}\right ) \]
Mathematica. Time used: 0.176 (sec). Leaf size: 15
ode=D[y[x],x]== 3*x^2*(1+y[x]^2); 
ic=y[0]==1; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \tan \left (x^3+\frac {\pi }{4}\right ) \]
Sympy. Time used: 0.282 (sec). Leaf size: 10
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-3*x**2*(y(x)**2 + 1) + Derivative(y(x), x),0) 
ics = {y(0): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \tan {\left (x^{3} + \frac {\pi }{4} \right )} \]