82.1.18 problem 23-21

Internal problem ID [21760]
Book : The Differential Equations Problem Solver. VOL. II. M. Fogiel director. REA, NY. 1978. ISBN 78-63609
Section : Chapter 23. Power series. Page 695
Problem number : 23-21
Date solved : Thursday, October 02, 2025 at 08:01:53 PM
CAS classification : [_quadrature]

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

Using series method with expansion around

\begin{align*} 2 \end{align*}

With initial conditions

\begin{align*} y \left (2\right )&=1 \\ \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 11
Order:=6; 
ode:=diff(y(x),x) = x^2; 
ic:=[y(2) = 1]; 
dsolve([ode,op(ic)],y(x),type='series',x=2);
 
\[ y = -\frac {5}{3}+\frac {x^{3}}{3} \]
Mathematica. Time used: 0.007 (sec). Leaf size: 26
ode=D[y[x],x]==x^2; 
ic={y[2]==1}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,2,5}]
 
\[ y(x)\to \frac {1}{3} (x-2)^3+2 (x-2)^2+4 (x-2)+1 \]
Sympy. Time used: 0.157 (sec). Leaf size: 24
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**2 + Derivative(y(x), x),0) 
ics = {y(2): 1} 
dsolve(ode,func=y(x),ics=ics,hint="1st_power_series",x0=2,n=6)
 
\[ y{\left (x \right )} = -7 + 2 \left (x - 2\right )^{2} + \frac {\left (x - 2\right )^{3}}{3} + 4 x + O\left (x^{6}\right ) \]