65.6.1 problem 12.1 (i)

Internal problem ID [13671]
Book : AN INTRODUCTION TO ORDINARY DIFFERENTIAL EQUATIONS by JAMES C. ROBINSON. Cambridge University Press 2004
Section : Chapter 12, Homogeneous second order linear equations. Exercises page 118
Problem number : 12.1 (i)
Date solved : Wednesday, March 05, 2025 at 10:11:25 PM
CAS classification : [[_2nd_order, _missing_x]]

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

With initial conditions

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

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