57.12.4 problem 1(d)

Internal problem ID [14447]
Book : A First Course in Differential Equations by J. David Logan. Third Edition. Springer-Verlag, NY. 2015.
Section : Chapter 2, Second order linear equations. Section 2.4.2 Variation of parameters. Exercises page 124
Problem number : 1(d)
Date solved : Thursday, October 02, 2025 at 09:37:23 AM
CAS classification : [[_2nd_order, _exact, _linear, _nonhomogeneous]]

\begin{align*} t^{2} x^{\prime \prime }-2 x&=t^{3} \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 20
ode:=t^2*diff(diff(x(t),t),t)-2*x(t) = t^3; 
dsolve(ode,x(t), singsol=all);
 
\[ x = t^{2} c_2 +\frac {t^{3}}{4}+\frac {c_1}{t} \]
Mathematica. Time used: 0.008 (sec). Leaf size: 25
ode=t^2*D[x[t],{t,2}]-2*x[t]==t^3; 
ic={}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to \frac {t^3}{4}+c_2 t^2+\frac {c_1}{t} \end{align*}
Sympy. Time used: 0.118 (sec). Leaf size: 14
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(-t**3 + t**2*Derivative(x(t), (t, 2)) - 2*x(t),0) 
ics = {} 
dsolve(ode,func=x(t),ics=ics)
 
\[ x{\left (t \right )} = \frac {C_{1} + \frac {t^{3} \left (C_{2} + t\right )}{4}}{t} \]