Vectors and Matrices in a Brutal Love Triangle—Eigenvalues λ and Eigenvectors x

ln

“I’ll have a plate of vectors smothered in rich matrix sauce, and a large glass of scalar multiplication.” “Oh, sir, that will kill quite a few brain cells.” “I know.”

Content translated by ChatGPT.

What is a matrix?

A bunch of numbers arranged in a rectangular table.

What is a vector?

A pile of numbers lined up in a list.

By definition, to multiply two matrices AA and BB, we take the dot product of each row of AA with each column of BB. In other words,

AB=(abcd)(efgh)=(ae+bgaf+bhce+dgcf+dh)AB = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} e & f \\ g & h \end{pmatrix} = \begin{pmatrix} ae + bg & af + bh \\ ce + dg & cf + dh \end{pmatrix}

For a matrix multiplied by a vector, this becomes

Ax=(abcd)(ef)=(ae+bfce+df)Ax = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} e \\ f \end{pmatrix} = \begin{pmatrix} ae + bf \\ ce + df \end{pmatrix}

It is that simple.

But at what cost?

Zero: The Geometry Behind Matrix Multiplication

We know that in two-dimensional space, any nonzero vector can be expressed as a linear combination of two linearly independent vectors. These two linearly independent vectors are called basis vectors.

Linearly independent: neither vector can be expressed as a scalar multiple of the other.

In other words, for vectors x=(ab)x=\begin{pmatrix}a \\ b \end{pmatrix} and y=(cd)y=\begin{pmatrix}c \\ d \end{pmatrix}, if xx and yy are linearly independent, then kx≠ykx \ne y for every constant kk.

For example, the vector y=(23)y=\begin{pmatrix}2 \\ 3 \end{pmatrix} can be expressed using e1=(10)e_1=\begin{pmatrix}1 \\ 0 \end{pmatrix} and e2=(01)e_2=\begin{pmatrix}0 \\ 1 \end{pmatrix} as y=2e1+3e2y=2e_1+3e_2. This is our familiar Cartesian coordinate system.

Now suppose a matrix P=(1−111)P=\begin{pmatrix}1 & -1 \\ 1 & 1 \end{pmatrix} suddenly barges in. What happens if we multiply yy by it? Working through the calculation gives us

Py=(1−111)(23)=(1×2−1×31×2+1×3)=(−15)Py=\begin{pmatrix}1 & -1 \\ 1 & 1 \end{pmatrix}\begin{pmatrix}2 \\ 3 \end{pmatrix}= \begin{pmatrix} 1\times2 -1\times3 \\ 1\times2 + 1\times3 \end{pmatrix} = \begin{pmatrix}-1 \\ 5 \end{pmatrix}

We can view PP as two two-dimensional column vectors placed side by side: P=(p1,p2)P=(p_1, p_2), where p1=(11)p_1=\begin{pmatrix}1 \\ 1 \end{pmatrix} and p2=(−11)p_2=\begin{pmatrix}-1 \\ 1 \end{pmatrix}.

The expression above can therefore be read as

Py=(p1,p2)(23)=2p1+3p2Py=(p_1, p_2)\begin{pmatrix}2 \\ 3 \end{pmatrix}=2p_1+3p_2

Look familiar? Exactly! We have built a vector using p1p_1 and p2p_2 as the basis vectors, with the same coefficients as before. Multiplying yy by PP replaces the basis vectors e1e_1 and e2e_2 with p1p_1 and p2p_2 while keeping those coefficients.

One: A Matrix and That Special Someone

Back to the topic. Generally, when a matrix acts on vectorsa.k.a. when we multiply them on the left by a matrix, replacing their basis vectors, most of them will change directionhave a change of heart. What a bunch of fickle creatures!

But one kind of vector is different. When the matrix acts on it, it stays along the same line, merely stretching, shrinking, or reversing direction.

She is different. She is special.

We call these vectors the matrix’s eigenvectors. For example, consider the matrix multiplication

Ax1=(3−102)(10)=(30)Ax_1=\begin{pmatrix}3 & -1 \\ 0 & 2 \end{pmatrix}\begin{pmatrix}1 \\ 0 \end{pmatrix}= \begin{pmatrix}3 \\ 0 \end{pmatrix}

After AA acts on it, the vector x1x_1 simply stretches to three times its original length along the same direction. This makes x1x_1 an eigenvector of AA. We denote its scale factor by λ1\lambda_1 and call it an eigenvalue of the matrix. Thus,

Ax1=λ1x1Ax_1=\lambda_1x_1

And this is the root of all evil.

More generally, every eigenvector xnx_n of AA satisfies

Ax=λxAx=\lambda x

where λ\lambda is the corresponding eigenvalue.

Now comes the question: given a matrix, how do we find its eigenvectors?

1. Finding a Matrix’s Eigenvectors and Eigenvalues

From the definition, we know that

Ax=λx (x≠0)Ax=\lambda x \ (x \ne 0)

Rearranging gives us

Ax−λx=0Ax-\lambda x=0

Factoring out xx gives

(A−λE)x=0(A-\lambda E)x=0

Nothing suspicious yet? With our astonishing powers of observation, we notice an n×nn\times n matrix multiplying an n×1n\times1 vector on the left-hand side. Let us write out what this looks like in two dimensions:

(abcd)(x1x2)=0\begin{pmatrix}a & b \\ c & d \end{pmatrix}\begin{pmatrix}x_1 \\ x_2 \end{pmatrix}=0

Multiplying gives us

(ax1+bx2cx1+dx2)=0\begin{pmatrix}ax_1+bx_2 \\ cx_1+dx_2 \end{pmatrix}=0

We know that a matrix being 00 means every entry is 00, so we have

{ax1+bx2=0cx1+dx2=0\begin{cases} a x_1 + b x_2 = 0 \\ \\ c x_1 + d x_2 = 0 \end{cases}

What? It was a homogeneous system of linear equations all along?!

We know that, for this square homogeneous system, if all the equations are linearly independent, the only solution is the zero solution. But we have one crucial condition: (x≠0)(x \ne 0).

For a nonzero solution to exist, the equations must therefore be linearly dependent. This means the determinant of the coefficient matrix must be zero:

∣abcd∣=0\begin{vmatrix} a & b \\ c & d \end{vmatrix} = 0
Why?

We need one equation to be expressible in terms of the other. In this two-equation system, that means the coefficients of one equation are all the same scalar multiple of the corresponding coefficients of the other.

Extracting the coefficients gives us the matrix

(abcd)\begin{pmatrix}a & b \\ c & d \end{pmatrix}

Suppose aa and bb are kk times cc and dd, respectively. Then the determinant of this square matrix is

∣abcd∣=∣kckdcd∣=k∣cdcd∣\begin{vmatrix} a & b \\ c & d \end{vmatrix} = \begin{vmatrix} kc & kd \\ c & d \end{vmatrix} = k\begin{vmatrix} c & d \\ c & d \end{vmatrix}

We know that a determinant with two identical rows or columns is zero.

Therefore,

∣abcd∣=0\begin{vmatrix} a & b \\ c & d \end{vmatrix} = 0

Returning to our original expression, the goal is now clear. We want

∣A−λE∣=0\begin{vmatrix}A-\lambda E \end{vmatrix}=0

This lets us solve for λ\lambda.

For a simple example, suppose A=(3−1−13)A=\begin{pmatrix}3 & -1 \\ -1 & 3 \end{pmatrix}. Then

∣A−λE∣=∣3−λ−1−13−λ∣=(3−λ)2−1=(λ−2)(λ−4)\begin{vmatrix}A-\lambda E \end{vmatrix} = \begin{vmatrix}3-\lambda & -1 \\ -1 & 3-\lambda \end{vmatrix} = (3-\lambda)^2-1 = (\lambda-2)(\lambda-4)

We can then find the two eigenvalues of AA: λ1=2, λ2=4\lambda_1=2,\ \lambda_2=4.

Now we know that AA has two distinct eigenvalues, with two corresponding families of eigenvectors. Note that, in this example, the vectors within each family are scalar multiples of one another.

Next, substitute λ1=2\lambda_1=2 into the original equation:

(A−2E)x=0(A-2E)x=0

After row reduction, this becomes

(1−100)(x1x2)=0\begin{pmatrix}1 & -1 \\ 0 & 0 \end{pmatrix}\begin{pmatrix}x_1 \\ x_2 \end{pmatrix}=0

We obtain

x1−x2=0x_1-x_2=0

Let x1=k1x_1=k_1. Then the vector is x=k1(11)x=k_1\begin{pmatrix}1 \\ 1 \end{pmatrix}.

Similarly, when λ2=4\lambda_2=4, we obtain x=k2(−11)x=k_2\begin{pmatrix}-1 \\ 1 \end{pmatrix}.

2. Diagonalizing a Matrix (A Major Matrix Makeover?!)

Suppose we have a 3×33\times3 matrix AA with three eigenvectors x1, x2, x3x_1, \ x_2, \ x_3. Time for some super assembly: combine the three eigenvectors into one matrix!

P=(x1,x2,x3)P=\begin{pmatrix}x_1,x_2,x_3\end{pmatrix}

Multiply PP on the left by AA:

AP=(Ax1,Ax2,Ax3)AP=(Ax_1, Ax_2, Ax_3)

Recall that when AA multiplies one of its eigenvectors, we have Ax−λx=0Ax-\lambda x=0. Therefore,

AP=(Ax1,Ax2,Ax3)=(λ1x1, λ2x2, λ3x3)=(x1,x2,x3)(λ1000λ2000λ3)=P(λ1000λ2000λ3)\begin{align*} AP &= (Ax_1, Ax_2, Ax_3) \\ &= (\lambda_1 x_1,\ \lambda_2 x_2,\ \lambda_3 x_3) \\ &= \begin{pmatrix} x_1, x_2, x_3 \end{pmatrix} \begin{pmatrix} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{pmatrix} \\ &= P\begin{pmatrix} \lambda_1 & 0 & 0 \\ 0 & \lambda_2 & 0 \\ 0 & 0 & \lambda_3 \end{pmatrix} \\ \end{align*}

Pretty magical, right? We get a diagonal matrix whose diagonal entries are the eigenvalues. We denote it by Λ\Lambda; it is a diagonal matrix similar to AA. Thus,

AP=PΛAP = P\Lambda

Multiplying both sides on the left by P−1P^{-1} gives us

P−1AP=P−1PΛ=Λ\begin{align*} P^{-1}AP &=P^{-1}P\Lambda = \Lambda \end{align*}

Similar matrices:

By definition, if there exists an invertible matrix PP such that P−1AP=BP^{-1}AP=B, then BB is similar to AA.

From The Geometry Behind Matrix Multiplication, we can see what similarity means geometrically: the two matrices describe the same linear transformation using different coordinate systems (bases).

We can break the transformation y=Bxy=Bx into a sequence of steps.

P

A

P⁻¹

Coordinates in the new basis: x

Coordinates in the original basis: Px

Transformed coordinates in the original basis: APx

Transformed coordinates in the new basis: P⁻¹APx

The formula can therefore be broken down as follows:

B⏟Matrix in the new basis=P−1⏟Back to the new basisA⏟Apply the transformationP⏟To the original basis\underbrace{B}_{\text{Matrix in the new basis}} = \underbrace{P^{-1}}_{\text{Back to the new basis}} \underbrace{A}_{\text{Apply the transformation}} \underbrace{P}_{\text{To the original basis}}

From this expression, we can observe that

∣A∣=∣P−1∣∣Λ∣∣P∣=∣P−1P∣∣Λ∣=∣Λ∣\begin{align*} |A|&=|P^{-1}||\Lambda||P|\\ &=|P^{-1}P||\Lambda|\\ &=|\Lambda| \end{align*}

Therefore, the product of all eigenvalues of a matrix is equal to the determinant of the matrix.

3. The Trace of a Matrix

The trace of a matrix is simple: add up all the entries on the main diagonal of a square matrix. For example, for A=(abcd)A=\begin{pmatrix}a & b \\ c & d \end{pmatrix}, its trace is

tr(A)=a+dtr(A)=a+d

If AA is similar to a diagonal matrix Λ\Lambda, then tr(A)tr(A) equals tr(Λ)tr(\Lambda): the sum of all the eigenvalues.

Here is a quick proof:

A=PΛP−1A=P\Lambda P^{-1}

Then

tr(A)=tr(PΛP−1)=tr(ΛPP−1)=tr(Λ)\begin{align*} tr(A)&=tr(P\Lambda P^{-1}) \\ &= tr(\Lambda PP^{-1}) \\ &= tr(\Lambda) \end{align*}
Why?

Let us prove it using two 2×22\times2 matrices:

A=(abcd),B=(efgh)A=\begin{pmatrix}a&b\\c&d\end{pmatrix}, \quad B=\begin{pmatrix}e&f\\g&h\end{pmatrix}

First, calculate ABAB:

AB=(ae+bgaf+bhce+dgcf+dh)AB=\begin{pmatrix} ae+bg&af+bh\\ ce+dg&cf+dh \end{pmatrix}

So,

tr⁡(AB)=ae+bg+cf+dh\operatorname{tr}(AB)=ae+bg+cf+dh

Next, calculate BABA:

BA=(ea+fceb+fdga+hcgb+hd)BA=\begin{pmatrix} ea+fc&eb+fd\\ ga+hc&gb+hd \end{pmatrix}

So,

tr⁡(BA)=ea+fc+gb+hd\operatorname{tr}(BA)=ea+fc+gb+hd

Since multiplication of ordinary numbers is commutative,

ae=ea,bg=gb,cf=fc,dh=hdae=ea,\quad bg=gb,\quad cf=fc,\quad dh=hd

Therefore,

tr⁡(AB)=tr⁡(BA)\boxed{\operatorname{tr}(AB)=\operatorname{tr}(BA)}

This result holds for any two square matrices of the same size.

Suppose we know the eigenvalues of AA.

1. The eigenvalues of aA+bEaA+bE are aλ+ba\lambda+b

Here is a quick proof:

(aA+bE)x=aAx+bEx=aλx+bx=(aλ+b)x\begin{align*} (aA+bE)x &= aAx+bEx\\ &= a\lambda x+bx\\ &=(a\lambda+b)x \end{align*}
2. The eigenvalues of AnA^n are λn\lambda^n
Anx=An−1Ax=An−1λx=An−2λ2x...=λnx\begin{align*} A^nx&=A^{n-1}Ax\\ &=A^{n-1}\lambda x\\ &=A^{n-2}\lambda^2x\\ &...\\ &=\lambda^nx \end{align*}
3. The eigenvalues of A−1A^{-1} are λ−1\lambda^{-1}

Since

AA−1=EAA^{-1}=E

We obtain

A−1Ax=xA−1λx=xA−1x=λ−1x\begin{align*} A^{-1}Ax&=x\\ A^{-1}\lambda x&=x\\ A^{-1}x&=\lambda^{-1}x \end{align*}
4. The eigenvalues of the adjugate A∗A^* are ∣A∣λ\frac{|A|}{\lambda}

Since

A∗A=∣A∣E\begin{align*} A^*A=|A|E \end{align*}

Therefore,

A∗Ax=∣A∣xA∗λx=∣A∣xA∗x=∣A∣λx\begin{align*} A^*Ax&=|A|x\\ A^*\lambda x&=|A|x\\ A^*x&=\frac{|A|}{\lambda}x \end{align*}
5. The eigenvalues of ATA^T are still λ\lambda

We start from the characteristic equation

∣A−λE∣=0|A-\lambda E|=0

And since

AT−λE=AT−λET=(A−λE)TA^T-\lambda E=A^T-\lambda E^T=(A-\lambda E)^T

it follows that

∣AT−λE∣=∣(A−λE)T∣=∣A−λE∣|A^T-\lambda E|=|(A-\lambda E)^T|=|A-\lambda E|

The two matrices have exactly the same characteristic equation, so naturally they have the same eigenvalues.

Comments

Feel free to leave your thoughts here. 💭💡

After signing in, click “Subscribe by Email” in the comment box to receive updates by email.

Loading comments…