|q⟩ Bad Qubits

beginner · Physics · Math Foundations: Linear Algebra

Eigenvalues and Eigenvectors

What are eigenvalues and eigenvectors?

A square matrix AA acts on column vectors by rotating and stretching them. Most vectors change direction when multiplied by AA. An eigenvector is special: it is a non-zero vector v|v\rangle that AA only scales, never rotates:

Av=λv.A\,|v\rangle = \lambda\,|v\rangle.

The scalar λ\lambda is the corresponding eigenvalue. The pair (λ,v)(\lambda,\, |v\rangle) is called an eigenpair. Every eigenvector points along a direction that the matrix leaves invariant.

Finding eigenvalues: the characteristic equation

Rearranging the definition gives (AλI)v=0(A - \lambda I)\,|v\rangle = 0. A non-zero solution v|v\rangle exists only when the matrix AλIA - \lambda I is singular — that is, when its determinant is zero:

det(AλI)=0.\det(A - \lambda I) = 0.

This is the characteristic equation (or characteristic polynomial) of AA. For an n×nn \times n matrix it is a degree-nn polynomial in λ\lambda, so there are exactly nn eigenvalues (counted with multiplicity, possibly complex).

Worked example for 2x2 matrices

For a general 2×22 \times 2 matrix

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

the characteristic equation is

det(aλbcdλ)=(aλ)(dλ)bc=0.\det\begin{pmatrix} a-\lambda & b \\ c & d-\lambda \end{pmatrix} = (a-\lambda)(d-\lambda) - bc = 0.

Expanding:

λ2(a+d)λ+(adbc)=0.\lambda^2 - (a+d)\,\lambda + (ad - bc) = 0.

The coefficient a+da + d is the trace of AA, denoted tr(A)\operatorname{tr}(A), and adbcad - bc is the determinant det(A)\det(A). So the characteristic equation always takes the form

λ2tr(A)λ+det(A)=0.\lambda^2 - \operatorname{tr}(A)\,\lambda + \det(A) = 0.

The two eigenvalues are the roots of this quadratic.

Finding eigenvectors once you have the eigenvalues

Once λ\lambda is known, plug it back into (AλI)v=0(A - \lambda I)\,|v\rangle = 0 and solve for v|v\rangle. The system will always be underdetermined (because the matrix is singular by construction), leaving one free parameter — that is the eigenvector direction. Conventionally, eigenvectors are normalised so that vv=1\langle v | v \rangle = 1.

A concrete 2x2 example

Let

A=(3113).A = \begin{pmatrix} 3 & 1 \\ 1 & 3 \end{pmatrix}.

The trace is 3+3=63 + 3 = 6 and the determinant is 3311=83 \cdot 3 - 1 \cdot 1 = 8, so the characteristic equation is

λ26λ+8=0.\lambda^2 - 6\lambda + 8 = 0.

Factoring: (λ4)(λ2)=0(\lambda - 4)(\lambda - 2) = 0, giving eigenvalues λ1=4\lambda_1 = 4 and λ2=2\lambda_2 = 2.

Eigenvector for λ1=4\lambda_1 = 4: Solve (A4I)v=0(A - 4I)\,|v\rangle = 0:

(1111)(v1v2)=0    v1+v2=0    v1=v2.\begin{pmatrix} -1 & 1 \\ 1 & -1 \end{pmatrix} \begin{pmatrix} v_1 \\ v_2 \end{pmatrix} = 0 \implies -v_1 + v_2 = 0 \implies v_1 = v_2.

Normalising gives v1=12(11)|v_1\rangle = \tfrac{1}{\sqrt{2}}\begin{pmatrix}1\\1\end{pmatrix}.

Eigenvector for λ2=2\lambda_2 = 2: Solve (A2I)v=0(A - 2I)\,|v\rangle = 0:

(1111)(v1v2)=0    v1+v2=0    v2=v1.\begin{pmatrix} 1 & 1 \\ 1 & 1 \end{pmatrix} \begin{pmatrix} v_1 \\ v_2 \end{pmatrix} = 0 \implies v_1 + v_2 = 0 \implies v_2 = -v_1.

Normalising gives v2=12(11)|v_2\rangle = \tfrac{1}{\sqrt{2}}\begin{pmatrix}1\\-1\end{pmatrix}.

Notice that the two eigenvectors are orthogonal: v1v2=12(1)(1)+12(1)(1)=0\langle v_1 | v_2 \rangle = \tfrac{1}{2}(1)(1) + \tfrac{1}{2}(1)(-1) = 0. This is not a coincidence — the matrix AA above is symmetric (Hermitian), and Hermitian matrices always have real eigenvalues and orthogonal eigenvectors. That property is precisely why Hermitian matrices represent physical observables.

Why this matters for quantum mechanics

The energy levels of a quantum system are eigenvalues of its Hamiltonian operator HH. The time-independent Schrödinger equation is exactly the eigenvalue equation

Hψ=Eψ,H\,|\psi\rangle = E\,|\psi\rangle,

where EE is the energy eigenvalue and ψ|\psi\rangle is the corresponding energy eigenstate. Every time you solve for the allowed energies of a potential well, a harmonic oscillator, or a hydrogen atom, you are finding eigenvalues of a Hermitian matrix or operator.

Try it

This is a numerical exercise — your code should return a number. For the matrix A=(3113)A = \begin{pmatrix} 3 & 1 \\ 1 & 3 \end{pmatrix}, find both eigenvalues by solving the characteristic equation det(AλI)=0\det(A - \lambda I) = 0, then return the larger eigenvalue.

Run your code to see the quantum state.

Sign in on the full site to ask questions and join the discussion.