74.20.6 problem 6

Internal problem ID [16559]
Book : INTRODUCTORY DIFFERENTIAL EQUATIONS. Martha L. Abell, James P. Braselton. Fourth edition 2014. ElScAe. 2014
Section : Chapter 5. Applications of Higher Order Equations. Exercises 5.2, page 241
Problem number : 6
Date solved : Thursday, March 13, 2025 at 08:20:37 AM
CAS classification : [[_2nd_order, _missing_x]]

\begin{align*} x^{\prime \prime }+4 x^{\prime }+20 x&=0 \end{align*}

With initial conditions

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

Maple. Time used: 0.022 (sec). Leaf size: 18
ode:=diff(diff(x(t),t),t)+4*diff(x(t),t)+20*x(t) = 0; 
ic:=x(0) = 1, D(x)(0) = 2; 
dsolve([ode,ic],x(t), singsol=all);
 
\[ x \left (t \right ) = {\mathrm e}^{-2 t} \left (\sin \left (4 t \right )+\cos \left (4 t \right )\right ) \]
Mathematica. Time used: 0.019 (sec). Leaf size: 20
ode=D[x[t],{t,2}]+4*D[x[t],t]+20*x[t]==0; 
ic={x[0]==1,Derivative[1][x][0 ]==2}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\[ x(t)\to e^{-2 t} (\sin (4 t)+\cos (4 t)) \]
Sympy. Time used: 0.191 (sec). Leaf size: 17
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(20*x(t) + 4*Derivative(x(t), t) + Derivative(x(t), (t, 2)),0) 
ics = {x(0): 1, Subs(Derivative(x(t), t), t, 0): 2} 
dsolve(ode,func=x(t),ics=ics)
 
\[ x{\left (t \right )} = \left (\sin {\left (4 t \right )} + \cos {\left (4 t \right )}\right ) e^{- 2 t} \]