Example 7.9.1.
Suppose that we have the system
\begin{equation*}
\begin{aligned}
x_1' + 5x_1 - 3x_2 &= e^t , \\
x_2' + 3x_1 - x_2 &= 0 ,
\end{aligned}
\end{equation*}
with initial conditions \(x_1(0) = 1, x_2(0) = 0\text{.}\)
Let us write the system as
\begin{equation*}
{\vec{x}}' +
\begin{bmatrix} 5 & -3 \\ 3 & -1 \end{bmatrix}
\vec{x} =
\begin{bmatrix} e^t \\ 0 \end{bmatrix} ,
\qquad
\vec{x}(0) =
\begin{bmatrix} 1 \\ 0 \end{bmatrix} .
\end{equation*}
The matrix \(P = \left[
\begin{smallmatrix} 5 & -3 \\ 3 & -1 \end{smallmatrix} \right]\) has a doubled eigenvalue 2 with defect 1, and we leave it as an exercise to double check we computed \(e^{tP}\) correctly. Once we have \(e^{tP}\text{,}\) we find \(e^{-tP}\text{,}\) simply by negating \(t\text{.}\)
\begin{equation*}
e^{tP} =
\begin{bmatrix}
(1+3t)\,e^{2t} & -3te^{2t} \\
3te^{2t} & (1-3t)\,e^{2t}
\end{bmatrix}
, \qquad
e^{-tP} =
\begin{bmatrix}
(1-3t)\,e^{-2t} & 3te^{-2t} \\
-3te^{-2t} & (1+3t)\,e^{-2t}
\end{bmatrix}
.
\end{equation*}
Instead of computing the whole formula at once, let us do it in stages. First
\begin{equation*}
\begin{split}
\int_0^t e^{sP}\vec{f}(s) \, ds & =
\int_0^t
\begin{bmatrix}
(1+3s)\,e^{2s} & -3se^{2s} \\
3se^{2s} & (1-3s)\,e^{2s}
\end{bmatrix}
\begin{bmatrix} e^{s} \\ 0 \end{bmatrix}
\, ds
\\
& =
\int_0^t
\begin{bmatrix}
(1+3s)\,e^{3s} \\
3se^{3s}
\end{bmatrix}
\, ds
\\
&=
\begin{bmatrix}
\int_0^t (1+3s)\,e^{3s} \,ds \\
\int_0^t 3se^{3s} \,ds
\end{bmatrix}
\\
& =
\begin{bmatrix}
t e^{3t} \\
\frac{(3t-1) \,e^{3t} + 1}{3}
\end{bmatrix} \qquad \qquad \text{(used integration by parts).}
\end{split}
\end{equation*}
Then
\begin{equation*}
\begin{split}
\vec{x}(t)
& = e^{-tP} \int_0^t e^{sP}\vec{f}(s) \, ds + e^{-tP} \vec{b} \\
& =
\begin{bmatrix}
(1-3t)\,e^{-2t} & 3te^{-2t} \\
-3te^{-2t} & (1+3t)\,e^{-2t}
\end{bmatrix}
\begin{bmatrix}
t e^{3t} \\
\frac{(3t-1) \,e^{3t} + 1}{3}
\end{bmatrix}
+
\begin{bmatrix}
(1-3t)\,e^{-2t} & 3te^{-2t} \\
-3te^{-2t} & (1+3t)\,e^{-2t}
\end{bmatrix}
\begin{bmatrix} 1 \\ 0 \end{bmatrix} \\
& =
\begin{bmatrix}
te^{-2t} \\
-\frac{e^t}{3}+\left( \frac{1}{3} + t \right) \, e^{-2t}
\end{bmatrix}
+
\begin{bmatrix}
(1-3t)\,e^{-2t} \\
-3te^{-2t}
\end{bmatrix} \\
& =
\begin{bmatrix}
(1-2t)\,e^{-2t} \\
-\frac{e^t}{3}+\left( \frac{1}{3} -2 t \right) \, e^{-2t}
\end{bmatrix} .
\end{split}
\end{equation*}
Phew!
Let us check that this really works.
\begin{equation*}
x_1' + 5 x_1 - 3x_2 = (4te^{-2t} - 4 e^{-2t}) + 5
(1-2t)\,e^{-2t}
+e^t-( 1 -6 t ) \, e^{-2t} = e^t .
\end{equation*}
Similarly (exercise) \(x_2' + 3 x_1 - x_2 = 0\text{.}\) The initial conditions are also satisfied (exercise).