Each problem is tagged by difficulty —
EasyMediumHardConceptual
— and within each section the problems are ordered from easiest to hardest, ending with a
conceptual question, so you can warm up, push yourself, and then test your understanding of
the ideas rather than just the mechanics.
Let
\[
A = \begin{pmatrix}2&-1\\3&4\end{pmatrix}, \qquad
B = \begin{pmatrix}0&5\\-2&1\end{pmatrix}.
\]
Compute \(2A - B\).
Solution:
Scalar multiplication acts entrywise, so first compute \(2A\) by multiplying every entry of \(A\) by \(2\):
\[
2A = \begin{pmatrix}4&-2\\6&8\end{pmatrix}.
\]
Matrix subtraction is also entrywise (and only defined because \(2A\) and \(B\) are both \(2\times2\)): subtract each entry of \(B\) from the corresponding entry of \(2A\):
Compute the determinant of
\[
A = \begin{pmatrix}4&-3\\2&5\end{pmatrix}.
\]
Solution:
For a \(2\times2\) matrix \(\begin{pmatrix}a&b\\c&d\end{pmatrix}\), the determinant is the simple cross-product formula \(ad-bc\). Here \(a=4\), \(b=-3\), \(c=2\), \(d=5\), so
Let
\[
A = \begin{pmatrix}2&1\\0&3\end{pmatrix}, \qquad
B = \begin{pmatrix}1&0\\2&-1\end{pmatrix}.
\]
Compute both \(AB\) and \(BA\), and confirm that \(AB\neq BA\).
Solution:
To multiply two matrices, each entry of the product is a row of the left matrix "dotted" with a column of the right matrix. Since \(A\) and \(B\) are both \(2\times2\), both orders \(AB\) and \(BA\) are defined and both results are \(2\times2\) — but that does not mean they have to agree.
First, \(AB\): the \((1,1)\) entry is row \(1\) of \(A\) dotted with column \(1\) of \(B\), and so on for each entry:
Even though both products exist and are the same size here, reversing the order of multiplication genuinely changes the answer — matrix multiplication is not commutative.
Problem 4 Medium
Compute the determinant of
\[
A = \begin{pmatrix}2&1&-1\\0&3&2\\1&-1&1\end{pmatrix}
\]
by cofactor expansion along the first row.
Solution:
Expanding along the first row, each entry \(a_{1j}\) is multiplied by the determinant of the \(2\times2\) minor obtained by deleting row \(1\) and column \(j\), with alternating signs \(+,-,+\):
Let
\[
A = \begin{pmatrix}1&2&0\\-1&3&2\end{pmatrix} \ (2\times3), \qquad
B = \begin{pmatrix}2&1\\0&-1\\3&4\end{pmatrix} \ (3\times2).
\]
Compute \(AB\). Then determine the size of \(BA\) (you do not need to stop there — compute it too), and explain why \(AB\) and \(BA\) cannot possibly be equal in this example.
Solution:
Since \(A\) is \(2\times3\) and \(B\) is \(3\times2\), the number of columns of \(A\) (\(3\)) matches the number of rows of \(B\) (\(3\)), so \(AB\) is defined and has size \(2\times2\) (the outer dimensions):
Now consider the reversed product \(BA\). Here \(B\) is \(3\times2\) and \(A\) is \(2\times3\); the inner dimensions again match (\(2=2\)), so \(BA\) is also defined — but its size is the outer dimensions of this new ordering, \(3\times3\), which is already a different size than the \(2\times2\) matrix \(AB\). Computing it in full, row by row (each row of \(B\) dotted with each column of \(A\)):
Since \(AB\) is \(2\times2\) and \(BA\) is \(3\times3\), they are not even the same size, let alone equal as matrices — two matrices of different dimensions can never be equal, no matter what entries they contain. This is an even more basic obstruction to commutativity than Problem 3's example, where at least both orders produced the same size.
Problem 6 Conceptual
Explain why the product \(AB\) is only defined when the number of columns of \(A\) equals the
number of rows of \(B\), and why — even when both \(AB\) and \(BA\) are defined and turn out
to be the same size — they still need not be equal (as in Problem 3). What does this reveal
about matrix multiplication that is fundamentally different from multiplying ordinary real numbers?
Solution:
Each entry of a matrix product \(AB\) is defined as a row of \(A\) "dotted" with a column of
\(B\) — that is, the entries of a row of \(A\) are multiplied pairwise against the entries of
a column of \(B\) and the results are added. For this pairing to even make sense, the row of
\(A\) and the column of \(B\) must have the same length, so that every entry has a
partner to multiply against. A row of \(A\) has as many entries as \(A\) has columns, and a
column of \(B\) has as many entries as \(B\) has rows — so the requirement "number of columns
of \(A\)\ = number of rows of \(B\)" is really just the requirement that this dot product be
well-defined in the first place. It has nothing to do with the matrices' overall sizes matching;
it is purely about the lengths of the vectors being combined.
As for why \(AB\neq BA\) can happen even when both are defined and the same size (Problem 3):
multiplying real numbers is a single, symmetric operation (\(ab\) and \(ba\) are computed the
same way), but matrix multiplication represents the composition of two linear
transformations, and composing transformations in a different order genuinely changes
the result in general — much like putting on socks then shoes gives a different outcome than
putting on shoes then socks. \(AB\) means "first apply the transformation \(B\), then apply
\(A\)," while \(BA\) means "first apply \(A\), then \(B\)" — there is no reason those two
sequences of operations should produce the same combined transformation, and in general they
do not. This is the essential way matrix multiplication differs from multiplication of real
numbers: real-number multiplication is commutative because it is not secretly encoding an
order of operations, while matrix multiplication always is.
Row \(2\) says \(-7y=-14\), so \(y=2\). Substituting into Row \(1\), \(x+2(2)=5\), so \(x=1\). Both equations check out: \(1+2(2)=5\) and \(3(1)-2=1\).
\[
\boxed{x=1,\quad y=2.}
\]
Problem 8 Medium
Solve the following system using Gaussian elimination:
\[
\begin{aligned}
x+y+z &= 6\\
2x-y+z &= 3\\
x+2y-z &= 2.
\end{aligned}
\]
Row \(3\) gives \(z=3\) directly. Substituting into Row \(2\): \(y-2(3)=-4\), so \(y=2\). Substituting both into Row \(1\): \(x+2+3=6\), so \(x=1\). Checking against the third original equation: \(1+2(2)-3=2\). \(\checkmark\)
\[
\boxed{x=1,\quad y=2,\quad z=3.}
\]
Problem 9 Medium
Solve the following system using Gaussian elimination:
\[
\begin{aligned}
x+y+z &= 8\\
2x-y+5z &= 7\\
x-2y+4z &= -1.
\end{aligned}
\]
Step 4(Interpret the zero row and solve for the free variable).
A row of all zeros (including in the constant column) means the third equation carried no new information — the system really only pins down two relationships among three unknowns, so one variable is free. From Row \(2\): \(-3y+3z=-9\), i.e. \(y-z=3\), so \(y=3+z\). Let \(z=t\) for a real parameter \(t\). Substituting into Row \(1\): \(x+(3+t)+t=8\), so \(x=5-2t\).
This system has infinitely many solutions. As a check, substituting back into the second original equation: \(2(5-2t)-(3+t)+5t = 10-4t-3-t+5t = 7\). \(\checkmark\)
Step 5(Scale \(R_3\) by \(-\tfrac16\), then back-substitute).
Scaling Row \(3\) gives \(z=-1\). Substituting into Row \(2\): \(y-2(-1)=3\), so \(y=1\). Substituting both into Row \(1\): \(x+1+(-1)=2\), so \(x=2\). Checking against the third original equation: \(3(2)+2(1)-(-1)=6+2+1=9\). \(\checkmark\)
\[
\boxed{x=2,\quad y=1,\quad z=-1.}
\]
Problem 11 Conceptual
Without fully row-reducing, explain what it means when Gaussian elimination produces a row of
the form \([0\ \,0\ \,0\mid k]\) with \(k\neq0\), as opposed to a row of the form
\([0\ \,0\ \,0\mid 0]\). Then use this idea to determine, as quickly as possible, whether the
following system has a solution:
\[
\begin{aligned}
x+y-z &= 2\\
2x+2y-2z &= 3\\
x-y+z &= 1.
\end{aligned}
\]
Solution:
A row \([0\ \,0\ \,0\mid 0]\) says "\(0x+0y+0z=0\)" — a true statement no matter what \(x,y,z\)
are, so it simply drops out of the system and leaves a free variable (Problem 9). A row
\([0\ \,0\ \,0\mid k]\) with \(k\neq0\), on the other hand, says "\(0x+0y+0z=k\)," i.e. "\(0=k\)"
— a statement that is false regardless of \(x,y,z\). If this ever appears during elimination,
the system is inconsistent and has no solution at all, no
matter what the other rows say.
In the system given, notice that the left-hand side of the second equation,
\(2x+2y-2z\), is exactly twice the left-hand side of the first equation, \(x+y-z\). So
subtracting twice Row \(1\) from Row \(2\) should eliminate every variable:
\[
R_2-2R_1: \quad (2-2)x+(2-2)y+(-2+2)z = 3-2(2) \;\Longrightarrow\; 0=3-4=-1.
\]
This is exactly a row of the form \([0\ \,0\ \,0\mid{-1}]\) — a contradiction. It does not
matter what the third equation says; the first two equations alone are already inconsistent
with each other (geometrically, they describe two parallel planes that never intersect), so
\(\boxed{\text{the system has no solution.}}\)
Verify that \(K=\begin{pmatrix}2\\1\end{pmatrix}\) is an eigenvector of
\(A=\begin{pmatrix}4&2\\3&-1\end{pmatrix}\), and find the corresponding eigenvalue.
Solution:
To check whether \(K\) is an eigenvector, we compute \(AK\) and see whether the result is a scalar multiple of \(K\) itself:
\[
AK = \begin{pmatrix}4&2\\3&-1\end{pmatrix}\begin{pmatrix}2\\1\end{pmatrix}
= \begin{pmatrix}4(2)+2(1)\\3(2)+(-1)(1)\end{pmatrix}
= \begin{pmatrix}10\\5\end{pmatrix}.
\]
Comparing this to \(K\), we see \(\begin{pmatrix}10\\5\end{pmatrix} = 5\begin{pmatrix}2\\1\end{pmatrix} = 5K\). Since \(AK\) is indeed a scalar multiple of the nonzero vector \(K\), \(K\) is confirmed to be an eigenvector of \(A\), with
\[
\boxed{\lambda = 5.}
\]
Problem 13 Medium
Find all eigenvalues and eigenvectors of
\[
A = \begin{pmatrix}5&4\\1&2\end{pmatrix}.
\]
Solution:
Step 1(Form \(A-\lambda I\) and set up the characteristic equation).
\[
A-\lambda I = \begin{pmatrix}5-\lambda&4\\1&2-\lambda\end{pmatrix}.
\]
So the eigenvalues are \(\lambda_1=0\) and \(\lambda_2=5\). It is perfectly fine for an eigenvalue to be zero — it just means \(A\) itself (not \(A\) shifted by anything) already sends some nonzero vector to \(\mathbf{0}\), i.e. \(A\) is singular.
Find all eigenvalues and eigenvectors of
\[
A = \begin{pmatrix}2&0&0\\1&3&0\\4&5&-1\end{pmatrix}.
\]
Solution:
Step 1(Form \(A-\lambda I\) and use its triangular structure).
\[
A-\lambda I = \begin{pmatrix}2-\lambda&0&0\\1&3-\lambda&0\\4&5&-1-\lambda\end{pmatrix}.
\]
This matrix is lower triangular (every entry above the main diagonal is \(0\)). Expanding the determinant along the first row eliminates two of the three cofactors immediately (since two of the entries in row \(1\) are \(0\)), and repeating this along each subsequent row shows that the determinant of any triangular matrix is just the product of its diagonal entries:
Explain why the equation \(\det(A-\lambda I)=0\) is exactly the condition needed for
\((A-\lambda I)K=0\) to have a nonzero solution \(K\). What would happen if we tried to find
an eigenvector for a value of \(\lambda\) where \(\det(A-\lambda I)\neq0\)?
Solution:
The equation \((A-\lambda I)K=0\) is a homogeneous linear system in the unknown vector \(K\),
with coefficient matrix \(A-\lambda I\). Every homogeneous system automatically has the
trivial solution \(K=\mathbf{0}\); the question is whether it has any others.
If \(\det(A-\lambda I)\neq0\), the matrix \(A-\lambda I\) is invertible, so we can multiply
both sides of \((A-\lambda I)K=0\) by \((A-\lambda I)^{-1}\) to get
\[
K = (A-\lambda I)^{-1}(A-\lambda I)K = (A-\lambda I)^{-1}\mathbf{0} = \mathbf{0}.
\]
In other words, whenever \(\det(A-\lambda I)\neq0\), the only solution is the trivial
one — Gaussian elimination on \((A-\lambda I\mid 0)\) would simply reduce all the way to the
identity matrix with an all-zero constant column, forcing \(x=y=\cdots=0\). Since the
definition of an eigenvector explicitly requires \(K\) to be nonzero, such a
\(\lambda\) can never produce an eigenvector.
So a nontrivial (nonzero) solution \(K\) can exist only when \(A-\lambda I\) fails to be
invertible, i.e. exactly when \(\det(A-\lambda I)=0\). This is precisely why solving the
characteristic equation for \(\lambda\) is the first step of the method — it identifies the
only values of \(\lambda\) for which a genuine eigenvector could possibly exist, before we
even try to solve for \(K\).
Write the system
\[
\frac{dx}{dt} = 3x-y+2, \qquad \frac{dy}{dt} = 4x+5y-t
\]
in the matrix form \(X'=AX+F(t)\).
Solution:
Let \(X=\begin{pmatrix}x\\y\end{pmatrix}\), so \(X'=\begin{pmatrix}x'\\y'\end{pmatrix}\). The coefficient matrix \(A\) is built from the coefficients multiplying \(x\) and \(y\) in each equation, and everything left over (terms that don't involve \(x\) or \(y\)) becomes the vector \(F(t)\):
From \(x'=3x-y+2\): the coefficients are \((3,-1)\), with leftover term \(2\). From \(y'=4x+5y-t\): the coefficients are \((4,5)\), with leftover term \(-t\).
Verify that
\[
X = \begin{pmatrix}e^{3t}\\e^{3t}\end{pmatrix}
\]
is a solution vector of \(X'=AX\), where \(A=\begin{pmatrix}2&1\\1&2\end{pmatrix}\).
Solution:
To verify a proposed solution vector, we differentiate each component of \(X\) to get \(X'\), separately compute \(AX\), and check that the two match for every \(t\). Differentiating,
Since \(X'=AX\) holds identically for every real \(t\), and both components of \(X\) are differentiable on all of \((-\infty,\infty)\), \(X\) is indeed a solution vector of the system on \((-\infty,\infty)\).
Problem 19 Medium
Convert the second-order differential equation
\[
y''-5y'+6y=4t
\]
into a system of first-order equations in matrix form.
Solution:
Let \(x_1=y\) and \(x_2=y'\). By these definitions alone, \(x_1'=y'=x_2\) — this first relationship never depends on the original differential equation, only on how we named the new variables.
The second relationship, however, does come from the differential equation: \(x_2'=y''\), and solving the original equation for \(y''\) gives
\[
y'' = 4t-6y+5y' = -6x_1+5x_2+4t.
\]
So \(x_2'=-6x_1+5x_2+4t\). Assembling both equations into matrix form,
Convert the third-order differential equation
\[
y'''+2y''-y'+3y=te^{-t}
\]
into a system of first-order equations in matrix form.
Solution:
Let \(x_1=y\), \(x_2=y'\), \(x_3=y''\). As with any conversion of this type, the first two equations are purely definitional and do not depend on the differential equation at all:
\[
x_1'=y'=x_2, \qquad x_2'=y''=x_3.
\]
The last equation is where the original differential equation actually enters, since \(x_3'=y'''\). Solving the given equation for \(y'''\),
When converting a single \(n\)th-order linear differential equation into a first-order system
via \(x_1=y,\, x_2=y',\,\dots,\,x_n=y^{(n-1)}\), the resulting coefficient matrix \(A\) always
has \(1\)'s immediately above the main diagonal and \(0\)'s everywhere else in its first
\(n-1\) rows, regardless of what the original differential equation was. Explain why this is
always true, and identify the one place in the matrix (and in \(F(t)\), if the equation is
nonhomogeneous) where the original equation's own coefficients actually show up.
Solution:
The first \(n-1\) equations of the system, \(x_1'=x_2\), \(x_2'=x_3\), \(\dots\),
\(x_{n-1}'=x_n\), come entirely from the definitions \(x_2=y'=x_1'\), \(x_3=y''=x_2'\),
and so on — each one just restates that "the derivative of \(x_i\) is, by construction, the
next variable \(x_{i+1}\)." This relationship is baked into how we chose to name the
variables, and it holds no matter what the original differential equation looked like. That
is exactly why every one of these rows has a single \(1\) in the column just to the right of
the diagonal and \(0\)'s everywhere else: row \(i\) (for \(i
The only equation that actually uses the original differential equation is the last
one, \(x_n'=y^{(n)}\), because \(y^{(n)}\) is exactly the term we solve for by rearranging the
given equation. Whatever coefficients and forcing term appeared in the original equation get
transferred, term for term, into the last row of \(A\) (the coefficients of \(x_1,\dots,x_n\)
appearing in the solved-for \(y^{(n)}\)) and into the last entry of \(F(t)\) (any leftover
function of \(t\) alone). Every other row of \(A\) is completely generic — it looks the same
for any \(n\)th-order equation converted this way — and every other entry of \(F(t)\) is
automatically \(0\), since only the highest-derivative equation was ever nonhomogeneous to
begin with.
\[
X = c_1\begin{pmatrix}1\\1\end{pmatrix}e^{-t} + c_2\begin{pmatrix}1\\-1\end{pmatrix}e^{-3t}.
\]
Step 4(Apply the initial condition).
At \(t=0\), \(e^{-t}=e^{-3t}=1\), so we need \(c_1\begin{pmatrix}1\\1\end{pmatrix}+c_2\begin{pmatrix}1\\-1\end{pmatrix}=\begin{pmatrix}2\\4\end{pmatrix}\), i.e. \(c_1+c_2=2\) and \(c_1-c_2=4\). Adding these two equations gives \(2c_1=6\), so \(c_1=3\), and then \(c_2=2-3=-1\).
Both rows give the same equation, so there is only a single independent direction of eigenvectors. Choosing \(y=1\) gives \(K=\begin{pmatrix}1\\1\end{pmatrix}\). (Check: \(AK=\begin{pmatrix}4-1\\1+2\end{pmatrix}=\begin{pmatrix}3\\3\end{pmatrix}=3K\).) This gives only one solution, \(X_1=\begin{pmatrix}1\\1\end{pmatrix}e^{3t}\) — but a \(2\times2\) system needs two linearly independent solutions.
Step 3(Find the generalized eigenvector by solving \((A-3I)P=K\)).
(As a check, differentiating \(X_2\) and comparing to \(AX_2\) confirms they agree — this is exactly what the formula \((A-3I)P=K\) was designed to guarantee.) The general solution is
Why does the repeated-eigenvalue case need a second, generalized eigenvector at all —
why can't we just find a second ordinary eigenvector, or use \(Ke^{\lambda t}\) with a
different constant vector \(K\)?
Solution:
For an \(n\times n\) system \(X'=AX\), the general solution requires \(n\) linearly
independent solution vectors (a fundamental set of solutions) — for a \(2\times2\)
system, that means exactly two. When \(\lambda\) is a repeated eigenvalue of multiplicity
\(2\) but the equation \((A-\lambda I)K=0\) only has a one-dimensional space of solutions
(as in Problem 25, where both rows reduced to the same equation), there is only one
genuinely independent eigenvector direction available — every other eigenvector for that
\(\lambda\) is just a scalar multiple of the one we already found.
Trying \(X=\widetilde{K}e^{\lambda t}\) for some other constant vector \(\widetilde K\) does
not help unless \(\widetilde K\) is itself an eigenvector for \(\lambda\) — and we just said
every eigenvector for this \(\lambda\) is a multiple of \(K\), so \(\widetilde{K}e^{\lambda t}\)
would just be a scalar multiple of \(X_1=Ke^{\lambda t}\), not linearly independent from it.
We genuinely need a different functional form, not just a different constant vector.
The generalized-eigenvector ansatz \(X_2=Kte^{\lambda t}+Pe^{\lambda t}\) introduces exactly
this new functional form (the extra factor of \(t\)), which is the direct system analogue of
needing \(te^{\lambda t}\) (instead of just \(e^{\lambda t}\)) for a repeated root of a scalar
constant-coefficient equation back in Section 4.3. Substituting this ansatz into \(X'=AX\)
and matching terms is exactly what forces the condition \((A-\lambda I)P=K\) on the new vector
\(P\) — it is not an arbitrary choice, but the unique extra condition needed to make
\(X_2\) actually satisfy the differential equation while remaining independent of \(X_1\).
Solve the system
\[
X' = \begin{pmatrix}1&2\\0&3\end{pmatrix}X + \begin{pmatrix}4\\-3\end{pmatrix}
\]
on \((-\infty,\infty)\).
Solution:
Step 1(Solve the associated homogeneous system).
Since \(A\) is triangular, \(\det(A-\lambda I)=(1-\lambda)(3-\lambda)\), so \(\lambda_1=1\), \(\lambda_2=3\). For \(\lambda_1=1\): \((A-I\mid0)=\begin{pmatrix}0&2\\0&2\end{pmatrix}\Rightarrow y=0\), giving \(K_1=\begin{pmatrix}1\\0\end{pmatrix}\). For \(\lambda_2=3\): \((A-3I\mid0)=\begin{pmatrix}-2&2\\0&0\end{pmatrix}\Rightarrow x=y\), giving \(K_2=\begin{pmatrix}1\\1\end{pmatrix}\). So
From the second row, \(3b=3\), so \(b=1\). Substituting into the first row, \(a+2(1)=-4\), so \(a=-6\). Thus \(X_p=\begin{pmatrix}-6\\1\end{pmatrix}\).
For \(\lambda_1=1\): \((A-I\mid0)=\begin{pmatrix}1&1\\1&1\end{pmatrix}\Rightarrow y=-x\), giving \(K_1=\begin{pmatrix}1\\-1\end{pmatrix}\). For \(\lambda_2=3\): \((A-3I\mid0)=\begin{pmatrix}-1&1\\1&-1\end{pmatrix}\Rightarrow y=x\), giving \(K_2=\begin{pmatrix}1\\1\end{pmatrix}\). So
Step 2(Guess a particular solution linear in \(t\), since \(F\) is linear in \(t\)).
Let \(X_p=\begin{pmatrix}a_1t+a_2\\b_1t+b_2\end{pmatrix}\), so \(X_p'=\begin{pmatrix}a_1\\b_1\end{pmatrix}\). Substituting into \(X_p'=AX_p+F\) and matching the coefficient of \(t\) and the constant term separately in each row gives four equations:
Step 3(Solve the \(t\)-coefficient equations for \(a_1,b_1\)).
From \(2a_1+b_1=-3\) and \(a_1+2b_1=-3\): multiplying the first by \(2\) gives \(4a_1+2b_1=-6\), and subtracting the second equation gives \(3a_1=-3\), so \(a_1=-1\). Then \(b_1=-3-2(-1)=-1\).
Step 4(Solve the constant equations for \(a_2,b_2\)).
With \(a_1=b_1=-1\): \(2a_2+b_2=a_1+2=1\) and \(a_2+2b_2=b_1=-1\). From the first, \(b_2=1-2a_2\); substituting into the second, \(a_2+2(1-2a_2)=-1 \Rightarrow -3a_2=-3 \Rightarrow a_2=1\), so \(b_2=1-2=-1\).
So \(X_p=\begin{pmatrix}-t+1\\-t-1\end{pmatrix}\). As a check, substituting \(X_p\) directly into the original system confirms both rows balance.
Use variation of parameters to solve
\[
X' = \begin{pmatrix}1&2\\0&3\end{pmatrix}X + \begin{pmatrix}2t\\0\end{pmatrix}.
\]
Solution:
Step 1(Build the fundamental matrix \(\Phi(t)\)).
This is the same coefficient matrix \(A\) as Problem 27, with eigenpairs \(\lambda_1=1,\ K_1=\begin{pmatrix}1\\0\end{pmatrix}\) and \(\lambda_2=3,\ K_2=\begin{pmatrix}1\\1\end{pmatrix}\), so its columns give
As a check, \(X_p'=\begin{pmatrix}-2\\0\end{pmatrix}\), and \(AX_p+F = \begin{pmatrix}1&2\\0&3\end{pmatrix}\begin{pmatrix}-2t-2\\0\end{pmatrix}+\begin{pmatrix}2t\\0\end{pmatrix} = \begin{pmatrix}-2t-2\\0\end{pmatrix}+\begin{pmatrix}2t\\0\end{pmatrix} = \begin{pmatrix}-2\\0\end{pmatrix}\), which matches.
As a check: differentiating gives \(X_p'=\begin{pmatrix}-\left(t+\frac32\right)e^t\\-(t+2)e^t\end{pmatrix}\), and computing \(AX_p+F\) directly reproduces the same vector, confirming the particular solution.
Explain why the method of undetermined coefficients could not be used to find a particular
solution of \(X'=AX+F(t)\) if \(F(t)=\begin{pmatrix}\tan t\\0\end{pmatrix}\), while variation
of parameters still applies to this system without any trouble.
Solution:
Undetermined coefficients only works when the entries of \(F(t)\) belong to a short list of
"nice" function families — constants, polynomials, exponentials, or sines and cosines —
precisely because the method relies on guessing a particular solution built from
that same family (plus finitely many undetermined constants) and then matching coefficients.
This works because differentiating a polynomial, exponential, or sine/cosine keeps producing
terms from that same finite family, so a finite guess can absorb all of them.
\(\tan t\) is not on that list, and for good reason: differentiating it produces \(\sec^2t\),
differentiating that produces more secant and tangent factors multiplying each other, and the
pattern never closes up into a small, fixed family of functions the way \(e^{at}\) or
\(\sin(\omega t)\) do. There is no finite-parameter guess \(X_p\) we could write down whose
derivatives would ever match \(\tan t\) term for term, so the method simply has no starting
point here.
Variation of parameters, by contrast, never guesses a form for \(X_p\) at all. Its formula,
\[
X_p = \Phi(t)\int \Phi(t)^{-1}F(t)\,dt,
\]
only asks that we compute the fundamental matrix \(\Phi(t)\) (which depends only on \(A\),
not on \(F\)) and then integrate the vector \(\Phi(t)^{-1}F(t)\) — and this is a well-defined
calculus problem no matter what continuous function \(F(t)\) is. The integral of a term
involving \(\tan t\) might not have as clean a closed form as an integral of \(e^{at}\), but
it can still be computed (or at worst left as a definite integral), which is exactly why
variation of parameters is considered the more general of the two methods.