Book III · Functional Analysis
Part 10 of 10Banach Algebras and the Spectral Theorem
What does it mean to diagonalize an operator that has no eigenvectors?
The part opens with two meanings of spectrum: hydrogen's lines, and the set of lambda where T - lambda has no inverse. The shift on l^2 has no eigenvalue, yet its spectrum is the closed disc, and a finite section's eigenvalues lie while its resolvent tells the truth. Banach algebras give operators an arithmetic: the Neumann series, a spectrum that is compact and nonempty by Liouville, Gelfand's formula for its radius, and the Volterra operator with spectrum {0} and no eigenvector. Cauchy's formula with the resolvent as kernel defines f(A), and Gelfand's transform turns a commutative algebra into functions, which proves Wiener's 1/f theorem in three lines. In Hilbert space the compact self-adjoint case is the vibrating string; multiplication by x has an interval of spectrum, approximate eigenvectors and the Born rule; and the spectral theorem for normal operators is proved with tools from Parts 3, 5, 6, 7 and 8. Unbounded operators come with domains: i d/dx on [0, 1] has a circle of self-adjoint extensions, the Cayley transform reduces the unbounded theorem to the unitary one, and Stone's theorem forces time evolution to be e^(-itH). The part ends with hydrogen's spectrum and the reason position and momentum must be unbounded.
What you need. Eigenvalues and diagonalization of matrices; for the last three chapters, the vocabulary of quantum mechanics (states, observables, the Schroedinger equation) helps but is not needed.
What you will be able to do
Undergraduate
- Sum a Neumann series to invert I - A when the norm of A is below one, and bound the error after n terms.
- Compute adjoints, projections and the numerical range of small matrices, and say what self-adjoint, unitary and normal mean.
Graduate
- Prove that the spectrum of an element of a Banach algebra is compact and nonempty, and prove Gelfand's spectral radius formula.
- Prove the spectral theorem for compact self-adjoint operators, and show that multiplication by x on L^2[0, 1] has spectrum [0, 1] and no eigenvalue.
Qualifying exam
- Prove the spectral theorem for bounded normal operators from Gelfand-Naimark and the Riesz representation theorem, and extend it to unbounded self-adjoint operators by the Cayley transform.
- Compute deficiency indices and classify the self-adjoint extensions of i d/dx on an interval; state Stone's theorem.
Applications
- Diagonalize a discretized operator to solve the heat or the Schroedinger equation, and read a state's spectral measure as the Born rule.
- Use the size of the resolvent, not the eigenvalues, to judge a non-normal matrix, and explain why no finite matrices satisfy the canonical commutation relation.
Contents
Each chapter has a home level. Choose a track to see what to read and watch: Undergraduate 8 min · Graduate 22 min · Qualifying exam 28 min · Applications 14 min.
- 0Two meanings of spectrumUndergraduate2 min
- 1Banach algebrasUndergraduate2 min
- 2The spectrumGraduate2 min
- 3Functions of an operatorGraduate2 min
- 4Gelfand theoryQualifying exam2 min
- 5Operators on Hilbert spaceUndergraduate2 min
- 6Compact self-adjoint operatorsApplications2 min
- 7A spectrum with no eigenvectorsGraduate2 min
- 8The spectral theoremQualifying exam2 min
- 9Unbounded operatorsGraduate2 min
- 10The Cayley transformQualifying exam2 min
- 11Stone's theoremApplications1 min
- 12What this proves about quantum mechanicsApplications2 min
- The last row of the ledgerAll tracks2 min
Also on this page: Lecture · Key results · Try it · Lab · Notes and sources · Build the film.
Lecture
The text of each chapter is the film's narration, as it is spoken, so you can read along or revise without the film. The pictures are in the film.
Two meanings of spectrumUndergraduate2 min
Nine rows of the ledger are filled. The last part is about operators, and what it means to diagonalize one.
Spectrum is the word for the lines of light a hot gas gives off. Hydrogen's visible lines sit at these wavelengths, computed from Rydberg's formula. And spectrum is the word for the set of complex numbers lambda where T minus lambda has no inverse. It's the same word for a reason: the energy levels of the atom are the spectrum of an operator, the Hamiltonian, and each line is a jump between two levels. The quantum videos assumed that such operators can be diagonalized. This part proves it.
Here's the first surprise. The shift on square-summable sequences moves every entry one slot to the right. It has no eigenvalues: S x equal to lambda x forces the first entry to vanish, then the next, then all of them. Its adjoint, the backward shift, drops the first entry, and for every lambda inside the unit disc the geometric sequence one, lambda, lambda squared is an eigenvector. Two hundred of them, checked. So the spectrum of the shift is the whole closed disc, though it has not a single eigenvalue.
A computer can only hold a finite piece of the shift: an N by N block whose only eigenvalue is zero. But measure how close T minus lambda is to failing to be invertible: the glow is the size of the inverse. Inside the disc it's astronomically large, like one over lambda to the N, and the contours spread outward as N grows. The eigenvalues lie, but the resolvent tells the truth. That's why the spectrum is defined by invertibility, not by eigenvectors.
Here's the plan, following chapters ten to thirteen of Functional Analysis. First the algebra: Banach algebras, the spectrum, functions of an operator, and Gelfand's theory. Then Hilbert space, where the spectral theorem diagonalizes compact operators, then operators with no eigenvectors at all, then every normal operator. Then the unbounded operators of physics, and what all of it proves about quantum mechanics.
1Banach algebrasUndergraduate2 min
Banach algebras, where elements can be multiplied as well as added. A Banach algebra is a complete normed space where you can also multiply, with the norm of a product at most the product of the norms. The continuous functions on a compact set, with the pointwise product. The bounded operators on a Banach space, with composition: the main example. The integrable functions with convolution, from Part 9, and summable sequences with convolution, and the disc algebra of Part 7. Test the rule: in two thousand random trials of each kind, the ratio piles up below one and never crosses it.
The first tool is the oldest series there is. Multiply I minus A by one plus A plus up to A to the n, and everything telescopes to I minus A to the n plus one. If the norm of A is below one, that last term dies, so I minus A is invertible, and its inverse is the geometric series: the Neumann series. For a random matrix of norm 0.8, the partial sums close in on the inverse, always under the geometric bound.
Here's a slice through the two by two matrices, around the identity. The red circle is where the determinant vanishes. The Neumann series says: if x is invertible, anything closer to x than one over the norm of x inverse is invertible too. Around the identity that's a disc of radius one, and around this matrix A, radius 0.6. Both discs touch the singular circle exactly, so the bound is sharp. The invertible elements form an open set, and inversion is continuous: the lemma from Part 4, in its final home.
2The spectrumGraduate2 min
The spectrum, which is never empty, and how big it is. For a six by six matrix, here's the trace of the resolvent, lambda minus A inverse, colored by phase. It's holomorphic except at the eigenvalues, where it has poles. In any Banach algebra the same is true. Outside the circle of radius the norm of x, the Neumann series inverts x minus lambda, and the invertibles are open, so the spectrum is closed and bounded. And it's never empty: if it were, every functional of the resolvent would be an entire function going to zero at infinity, so zero, by Liouville's theorem, and then Hahn-Banach makes the resolvent itself zero, which is absurd. A corollary: a Banach algebra where every nonzero element is invertible is just the complex numbers.
Expand the resolvent in powers of one over lambda. That's a Laurent series, Part 7's tool, and it converges exactly outside the smallest circle that contains the spectrum. By the root test from Part 2, its radius is the limit of the n-th root of the norm of x to the n. That's Gelfand's spectral radius formula: a purely algebraic, metric quantity equals the size of the spectrum. For ten random matrices, the n-th roots start well above the largest eigenvalue, and settle onto it, within a tenth of a percent by n equal to a thousand.
Part 8's Volterra operator integrates from zero. Its norm is two over pi. Its powers are repeated integrals, with kernel x minus t to the n minus one over n minus one factorial, and their norms collapse like one over n factorial: n factorial times the norm tends to one half. So the n-th roots go to zero, and by Gelfand's formula the spectrum is the single point zero. Yet zero isn't an eigenvalue, because if V f vanishes, so does its derivative, which is f. A nonzero operator, a one-point spectrum, and no eigenvector at all.
3Functions of an operatorGraduate2 min
Applying functions to operators, with Cauchy's formula. How do you take the exponential of a matrix, or of any element of a Banach algebra? Part 7 already answered it. Cauchy's formula recovers a holomorphic function from its values on a circle, through the kernel one over lambda minus z. Put the operator in place of z: the kernel becomes the resolvent. Integrate around a contour enclosing the spectrum, and you get f of A. For a random matrix, with the exponential and a hundred twenty-eight points on the circle, the result matches the exponential computed the usual way, to rounding error.
And the spectrum goes along. The eigenvalues of A, on the left, are carried by the exponential to the eigenvalues of e to the A, on the right, while the grid around them is bent by the same map. That's the spectral mapping theorem: the spectrum of f of A is f of the spectrum of A, for every holomorphic f, in every Banach algebra.
Square roots need care, because the square root isn't holomorphic across its branch cut. Shift the matrix so its spectrum sits in the right half-plane, and take a contour that encloses the spectrum without touching the cut. The same formula, with the square root in it, gives a matrix whose square is B, to rounding error. Logarithms and fractional powers work the same way, and Runge's theorem from Part 7 explains why rational functions are enough. One famous consequence of this circle of ideas, Lomonosov's theorem, finds nontrivial invariant subspaces with a fixed-point argument.
4Gelfand theoryQualifying exam2 min
Gelfand's theory, which turns every commutative Banach algebra into functions. In a commutative Banach algebra, the maximal ideals are exactly the kernels of the homomorphisms to the complex numbers. Gelfand's idea: evaluate x at every homomorphism. That turns x into a continuous function on the space of homomorphisms, which is compact, by Alaoglu's theorem. In summable sequences under convolution, the homomorphisms are indexed by an angle theta: sum a n times e to the i n theta. So the Gelfand transform of a sequence is its Fourier series, a closed curve in the plane. And the spectrum of x is the range of its transform: here, the curve itself.
Here's what that buys. Our curve never passes through zero. Wiener asked: does one over it also have absolutely summable Fourier coefficients? Computed by fast Fourier transform: the coefficients of one over f decay like one over n squared, and their absolute sums settle at 2.65427. Gelfand's proof is three lines. The transform never vanishes, so the sequence lies in no maximal ideal. So it's invertible in the algebra, and the inverse transforms to one over f. Wiener's original proof took pages.
Add an adjoint, with the norm of x star x equal to the norm of x squared, the identity that holds for operators on Hilbert space. Then Gelfand-Naimark says: a commutative such algebra is exactly an algebra of continuous functions, with nothing lost. The dictionary: a normal element becomes the coordinate z on its spectrum, its adjoint becomes z bar, and any continuous f of it becomes f composed with z. For a normal matrix this is concrete. Its adjoint is a polynomial in the matrix, the one that interpolates z bar at the eigenvalues, and a square root computed two ways agrees to rounding error. And by the Gelfand-Naimark-Segal construction, every C-star algebra, commutative or not, is an algebra of operators.
5Operators on Hilbert spaceUndergraduate2 min
On a Hilbert space every bounded operator has an adjoint, defined by moving it across the inner product. The matrix words all survive: self-adjoint, unitary, normal, projection. And one identity makes everything work: the norm of T star T is the square of the norm of T, because the size of T x squared is the inner product of T star T x with x. So the bounded operators form a C-star algebra, and Gelfand's theory applies to the algebra generated by any normal operator.
The simplest self-adjoint operators are the projections. Each point drops perpendicularly onto a closed subspace, its nearest point there, from Part 6. Projecting twice changes nothing, and the leftover is perpendicular, so Pythagoras splits the length. Projections will be the bricks of the spectral theorem: diagonalizing an operator will mean writing it as a sum, or an integral, of numbers times projections.
The numerical range collects the values of T x against x, for unit vectors x. For this non-normal matrix it's a convex region, traced by its supporting lines, and it contains the eigenvalues, but it's much bigger than they are. For a normal matrix, it's exactly the convex hull of the eigenvalues: T x against x is just an average of eigenvalues, weighted by the squared coordinates of x. And for a self-adjoint operator it's a real interval. Normal operators are the ones whose geometry is controlled by their spectrum.
6Compact self-adjoint operatorsApplications2 min
Here's the operator behind Part 8's string: integrate against this kernel, and you solve minus u double prime equals f with the ends held fixed. It's compact and self-adjoint. For such operators the finite-dimensional proof works. Maximize T x against x over unit vectors. A maximizing sequence has a weakly convergent subsequence, and compactness upgrades that to norm convergence, so the maximum is attained, at an eigenvector. Then restrict to the orthogonal complement and repeat. The eigenvalues shrink to zero and the eigenvectors span everything T can reach. T is diagonal in that basis.
Watch the proof run. Start with a lopsided function and apply G again and again, normalizing each time. The largest mode wins: the curve settles into a half sine, and the Rayleigh quotient into one over pi squared. Now remove that mode and repeat: the next survivor is a full sine, with one over four pi squared. Then the third. With two thousand points, the eigenvalues match one over n pi squared to six digits. So minus the second derivative, the inverse of G, has eigenvalues n pi squared and eigenfunctions the sines: the Fourier sine series is the spectral theorem for this operator.
Diagonalizing solves equations. For the heat equation on the string, expand the initial temperature in the sines; each mode just decays, at a rate set by its eigenvalue. Here's a block of heat spreading out, from the eigen-expansion, with an independent finite-difference solver as dots, agreeing to about one part in a hundred thousand. In the quantum videos, the same modes rotate instead of decaying: that's the particle in a box.
7A spectrum with no eigenvectorsGraduate2 min
An operator with a whole interval of spectrum and not one eigenvector. Multiply every function by x. That's a bounded self-adjoint operator on L two of zero to one, and it's quantum mechanics' position operator. Its resolvent is multiplication by one over x minus lambda, which is bounded exactly when lambda is outside the interval. So the spectrum is the whole interval from zero to one. But it has no eigenvectors: x minus lambda times f vanishing almost everywhere forces f itself to vanish almost everywhere. A full interval of spectrum, and nothing to diagonalize.
What makes 0.4 part of the spectrum, then? Take a bump centered at 0.4 and squeeze it. M minus 0.4 makes it small relative to its size, by a factor proportional to the width, so the ratio goes to zero. These are approximate eigenvectors: they show that M minus lambda can't have a bounded inverse, even though nothing is ever mapped exactly to lambda times itself.
So what can diagonalizing mean here? M is already diagonal, in a continuous sense: any function of M is just multiplication by that function. And each state psi spreads a unit of mass over the spectrum: the measure of a set omega is the integral of psi squared over omega. That's the Born rule: the probability that the particle's position lies in omega. The total is one, and the average of x is the expected position. The spectral theorem will say every self-adjoint operator looks like this.
8The spectral theoremQualifying exam2 min
The spectral theorem, the proof that uses every part of the series. Diagonalizing a symmetric matrix means splitting space into eigenspaces. Here are the fifty eigenvalues of a random symmetric matrix, on its spectrum. Pick a vector x. Its squared coordinates in the eigenbasis put a mass on each eigenvalue, and the masses add up to the squared length of x. For any set omega, the projection onto the eigenvectors with eigenvalues in omega, E of omega, carries exactly the mass over omega. That assignment of a projection to every set is a projection-valued measure. And H is the integral of lambda against it. For the multiplication operator, E of omega multiplies by the indicator of omega: no eigenvectors needed.
Rudin's proof of the spectral theorem for a normal operator T uses the whole series. Take the algebra generated by T and its adjoint: commutative, and a C-star algebra. Its spectrum is compact and nonempty by Liouville, from Part 7, and its maximal ideal space is compact by Alaoglu, from Part 8. Gelfand-Naimark identifies it with the continuous functions on the spectrum, which needs Stone-Weierstrass, from Part 3. For two vectors x and y, f maps to f of T x against y: a bounded linear functional on continuous functions. By the Riesz representation theorem, from Part 5, it's integration against a measure. Those measures define the projections E of omega, in Hilbert space, from Part 6. And T is the integral of lambda d E.
One payoff. Average the powers of a unitary operator applied to a vector. In the spectral picture, that averages lambda to the k over the spectrum, which lies on the unit circle; the averages die everywhere except at lambda equal to one. So the averages converge to the projection onto the fixed vectors: von Neumann's ergodic theorem. For an eight by eight unitary with two fixed directions, the error falls like one over n.
9Unbounded operatorsGraduate2 min
Unbounded operators, where the domain is part of the operator. Momentum is a derivative, and derivatives are not bounded: sine n x has the same size for every n, but its derivative is n times bigger. And Part 8's Hellinger-Toeplitz theorem says a symmetric operator defined on all of Hilbert space is automatically bounded. So the operators of physics can't be defined everywhere. They come with a domain, a dense subspace, and the domain is part of the operator.
Here's the cautionary example. Take i times the derivative on the interval from zero to one, defined on smooth functions that vanish near both ends. Integration by parts gives a boundary term, which vanishes, so the operator is symmetric. But its adjoint has no boundary conditions at all, so it's much bigger. The equations D star f equals plus or minus i f have solutions, e to the x and e to the minus x: one dimension each. Symmetric is not self-adjoint, and only self-adjoint operators get a spectral theorem.
To make it self-adjoint, impose a boundary condition: f at one equals e to the i theta times f at zero, one condition for each point on a circle. Each gives a self-adjoint operator, with eigenfunctions e to the minus i lambda x, and the condition forces lambda into the ladder two pi n minus theta. Computed numerically for three values of theta, the eigenvalues match to many digits. Now turn theta around the circle. The whole ladder slides down, and after a full turn it lands on itself. The same differential expression, a circle of different operators, each with its own spectrum.
10The Cayley transformQualifying exam2 min
The Cayley transform, which turns unbounded self-adjoint operators into unitary ones. A self-adjoint operator's spectrum lies on the real line, and for an unbounded one it runs off to infinity, like the ladder of the last chapter. The Cayley map, lambda minus i over lambda plus i, bends the real line onto the unit circle, because a real number is equally far from i and minus i. Zero goes to minus one, and both ends of the line go to one. The ladder lands on the circle, piling up at one from both sides: a bounded picture of an unbounded spectrum.
Von Neumann applied the same map to operators. If T is self-adjoint, T minus i times the inverse of T plus i is unitary, and bounded. Diagonalize that unitary with the bounded spectral theorem, then carry its spectral measure back along the inverse map, and you have T as the integral of lambda against a projection-valued measure on the real line. For merely symmetric operators the transform is only an isometry, and the dimensions it misses are the deficiency indices. Self-adjoint extensions correspond to unitary maps between those gaps: in our example, a circle of them, the circle of theta.
The momentum operator, minus i d d x on the whole line, is the leading example. Here's a packet with two components, and its Fourier transform, two bumps at the two momenta. Conjugating by the Fourier transform turns momentum into multiplication by xi, checked here to ten digits. So Plancherel's theorem from Part 9 is the spectral theorem for momentum: the Fourier transform is the change of basis that diagonalizes it. The dictionary's last card: eigenvalues become the spectrum, a whole measure's worth of them.
11Stone's theoremApplications1 min
In the quantum videos, a state evolves by e to the minus i t H. Here's a packet in a harmonic well, sliding back and forth. Expand it in the eigenstates of H, with energies one half, three halves, and so on. Each coefficient is a clock hand that turns at its own rate, its energy. The sizes, the spectral measure of the state, never change: a Poisson distribution here. Computed both ways, by splitting the evolution into small steps and by the spectral decomposition, the states agree to eight digits, and the norm stays one.
Stone's theorem says this is the only way it can go. Any self-adjoint operator generates a continuous group of unitaries, e to the i t A, through its spectral measure. And conversely, every continuous one-parameter group of unitaries has a generator, the derivative at time zero, which is densely defined and self-adjoint. So if time evolution preserves probability, it's e to the minus i t H for a self-adjoint H: the assumption the quantum videos made is forced. Drop unitarity, keep contraction, and you get semigroups like the heat flow.
12What this proves about quantum mechanicsApplications2 min
Back to the hook. Hydrogen's Hamiltonian, for states without angular momentum, is this unbounded self-adjoint operator. Discretized and diagonalized, its lowest eigenvalues are minus one half over n squared, to five decimal places: the energy levels whose differences are the spectral lines. They pile up at zero. Above zero, the spectrum is continuous: the electron flies free. In a finite box that shows up as a dense ladder. A state's spectral measure has point masses at the bound states and a continuous part above.
The canonical commutation relation says x p minus p x is i times the identity. For matrices that's impossible: the trace of a commutator is zero, the trace of i I is not. Discretize x and p on sixty-four points and look at the eigenvalues of the commutator divided by i. Fifty-five of them sit near one, as the relation wants, and a few run off to plus and minus a hundred to make the trace zero. For bounded operators, Wielandt's argument rules it out too: commuting through powers gives n times the norm of B to the n minus one at most a fixed constant times it. So position and momentum must be unbounded: the honest reason the quantum videos needed this part.
So here's what's been proved. Observables are self-adjoint operators, so each has a spectral measure, and the Born rule is that measure. Position and momentum have continuous spectra and no eigenvectors, and their commutation relation forces them to be unbounded. Time evolution is e to the minus i t H, and by Stone's theorem it has to be. And hydrogen's spectrum is points below zero, continuum above.
The last row of the ledgerAll tracks2 min
Let's take stock one last time. Banach algebras gave operators an arithmetic, with the Neumann series and an open set of invertibles. The spectrum is compact and never empty, and Gelfand's formula measures it. Cauchy's formula gave functions of operators, and Gelfand's transform turned commutative algebras into functions. In Hilbert space, compact self-adjoint operators have eigenbases, multiplication by x has none and is still diagonal, and the spectral theorem handles every normal operator, then every self-adjoint one, through the Cayley transform. Stone's theorem closed the loop with quantum mechanics.
The ledger's last row. The space: bounded operators, and the C-star algebras they generate. Completeness: they're closed in norm, and Gelfand-Naimark makes them function algebras. Compactness: Alaoglu again, behind the maximal ideal space. The interchange: f of T for every Borel function f, so limits of functions become limits of operators. And the Fourier answer: the Fourier transform is the spectral theorem, for momentum. And that's the whole ledger: ten rows, from the least upper bound property to the spectral theorem.
And the timeline is complete: from Fourier's claim in 1807 that every function is a sum of sines, through Dirichlet and Riemann; then forty crowded years: Dedekind and Cantor, Heine and Borel, Lebesgue, Fréchet, Riesz and Fischer; then Banach and Schwartz, to Carleson's theorem in 1966. Every idea in the series was invented to answer a question about Fourier series.
From here the road divides. Operator algebras and noncommutative geometry. Index theory. Nonlinear analysis, where Sobolev spaces do their real work. Partial differential equations, which use all of it. And harmonic analysis, which is still answering Fourier's question.
This part followed chapters ten to thirteen of Functional Analysis and chapter eighteen of Real and Complex Analysis. That's the end of the series. Thanks for watching all of it.
Where it goes next. This is the last part: it closes the ledger from the least upper bound property to the spectral theorem and proves what the quantum films assumed. The film names where the road divides: operator algebras, index theory, nonlinear analysis, partial differential equations and harmonic analysis.
Key results
The part's results in one place, for revision.
Try it
Lab 10 · The resolvent tells the truth
Check Gelfand's formula |A^n|^(1/n) -> max |eigenvalue| on a random non-normal matrix, watch n! |V^n| -> 1/2 for the Volterra operator (spectrum {0}, no eigenvalue), and see that a finite section of the shift has the single eigenvalue 0 while its resolvent is enormous on the whole open disc.
python -m videos.analysis.labs 10
needs numpy, scipy, matplotlib · download lab10.py ·
source on GitHubrandom 8 x 8 matrix: |A|, largest |eigenvalue| 4.7281 2.8480
|A^n|^(1/n) at n = 10, 100, 1000 3.0883 2.8710 2.8503
Volterra: |V| 0.636616 (2/pi = 0.636620)
Volterra: n! |V^n| at n = 1, 4, 8, 12 0.6366 0.5331 0.5165 0.5120 (limit 1/2)
Volterra: |V^n|^(1/n) at n = 1, 4, 8, 12 0.6366 0.3861 0.2446 0.1788 (limit 0)
shift, 40 x 40 section: eigenvalues all 0
smallest singular value of S - lam at |lam| = 0.5 6.82e-13 (0.5^40 = 9.09e-13)
... and at |lam| = 1.6 0.6072 (at least 0.6)
Eigenvalues of a finite section say the shift's spectrum is {0}; the resolvent says every point of the open disc is within |lam|^N of the spectrum, and in the limit the spectrum is the closed disc. Gelfand's formula reads the spectral radius off the norms of powers, with or without eigenvectors.
The code (97 lines; it asserts its own result)
"""Lab 10: measure spectra by invertibility: Gelfand's formula, the Volterra operator, and the shift's lying eigenvalues."""
import math
import numpy as np
from videos.coursekit import labs
TITLE = "The resolvent tells the truth"
GOAL = ("Check Gelfand's formula |A^n|^(1/n) -> max |eigenvalue| on a random non-normal matrix, watch n! |V^n| -> 1/2 "
"for the Volterra operator (spectrum {0}, no eigenvalue), and see that a finite section of the shift has the "
"single eigenvalue 0 while its resolvent is enormous on the whole open disc.")
TASKS = [
"Make the random matrix normal (A = Q diag(d) Q* with Q unitary). How does |A^n|^(1/n) behave now, and why is it constant?",
"For the shift's section, print the smallest singular value of S - lam at |lam| = 0.9 for N = 20, 40, 80 and compare with 0.9^N.",
"Apply the truncated vector (1, lam, lam^2, ...) to the backward shift: how small is |(S* - lam) x| / |x|, and what does it say about lam?",
]
def opnorm(M):
return np.linalg.norm(M, 2)
def volterra(N):
"""The Volterra operator (Vf)(x) = int_0^x f on L^2[0, 1], by the midpoint rule on N cells."""
return (np.tril(np.ones((N, N)), -1) + 0.5 * np.eye(N)) / N
def run(seed=0):
rng = np.random.default_rng(seed)
lab = labs.Lab()
# 1. Gelfand's spectral radius formula on a random real 8 x 8 matrix (not normal).
A = rng.normal(size=(8, 8))
rho = np.abs(np.linalg.eigvals(A)).max()
ns = np.unique(np.round(np.logspace(0, 3, 40)).astype(int))
roots = []
for n in ns:
P = np.linalg.matrix_power(A / rho, int(n)) # scaled so the powers neither overflow nor underflow
roots.append(rho * opnorm(P) ** (1 / n))
roots = np.array(roots)
assert np.all(roots >= rho * (1 - 1e-9)), "|A^n|^(1/n) is never below the spectral radius"
assert roots[0] > 1.1 * rho and abs(roots[-1] / rho - 1) < 0.01, "and it converges to it"
lab.row("random 8 x 8 matrix: |A|, largest |eigenvalue|", f"{roots[0]:.4f} {rho:.4f}")
lab.row("|A^n|^(1/n) at n = 10, 100, 1000", " ".join(f"{roots[np.searchsorted(ns, n)]:.4f}" for n in (10, 100, 1000)))
# 2. The Volterra operator: norm 2/pi, n! |V^n| -> 1/2, so the spectral radius is 0.
V = volterra(200)
norms, P = [], np.eye(200)
for n in range(1, 13):
P = P @ V
norms.append(opnorm(P))
norms = np.array(norms)
scaled = norms * np.array([math.factorial(n) for n in range(1, 13)])
vroots = norms ** (1 / np.arange(1, 13))
assert abs(norms[0] - 2 / np.pi) < 1e-5, "the Volterra operator has norm 2/pi"
assert abs(scaled[-1] - 0.5) < 0.03 and np.all(np.diff(np.abs(scaled - 0.5)) < 0), "n! |V^n| -> 1/2"
assert np.all(np.diff(vroots) < 0) and vroots[-1] < 0.2, "|V^n|^(1/n) -> 0: the spectrum is {0}"
lab.row("Volterra: |V|", f"{norms[0]:.6f} (2/pi = {2 / np.pi:.6f})")
lab.row("Volterra: n! |V^n| at n = 1, 4, 8, 12", " ".join(f"{scaled[n - 1]:.4f}" for n in (1, 4, 8, 12)) + " (limit 1/2)")
lab.row("Volterra: |V^n|^(1/n) at n = 1, 4, 8, 12", " ".join(f"{vroots[n - 1]:.4f}" for n in (1, 4, 8, 12)) + " (limit 0)")
# 3. The shift: an N x N section is a Jordan block with the single eigenvalue 0, but 1/smin(S - lam) is the
# size of the resolvent, and it is huge on the whole open disc.
N = 40
S = np.diag(np.ones(N - 1), -1)
assert np.abs(np.linalg.eigvals(S)).max() < 1e-12
radii = np.linspace(0.05, 1.6, 63)
phase = np.exp(2j * np.pi * rng.uniform()) # the resolvent norm depends only on |lam|: any direction will do
smin = {n: np.array([np.linalg.svd(np.diag(np.ones(n - 1), -1) - r * phase * np.eye(n), compute_uv=False)[-1]
for r in radii]) for n in (10, 20, 40)}
inside, outside = radii < 0.8, radii > 1.05
assert np.all(smin[40][inside] < np.maximum(2 * radii[inside] ** 40, 1e-12)), "inside the disc S - lam is within |lam|^N of singular"
assert np.all(smin[40][outside] >= radii[outside] - 1 - 1e-9), "outside, |(S - lam) x| >= (|lam| - 1) |x|"
r_half = np.argmin(np.abs(radii - 0.5))
lab.row("shift, 40 x 40 section: eigenvalues", "all 0")
lab.row("smallest singular value of S - lam at |lam| = 0.5", f"{smin[40][r_half]:.2e} (0.5^40 = {0.5 ** 40:.2e})")
lab.row("... and at |lam| = 1.6", f"{smin[40][-1]:.4f} (at least 0.6)")
lab.note = ("Eigenvalues of a finite section say the shift's spectrum is {0}; the resolvent says every point of "
"the open disc is within |lam|^N of the spectrum, and in the limit the spectrum is the closed disc. "
"Gelfand's formula reads the spectral radius off the norms of powers, with or without eigenvectors.")
fig, ax = labs.figure(2, size=(11, 4.2))
ax[0].semilogx(ns, roots, color=labs.BLUE, label="random 8 x 8 matrix: |A^n|^(1/n)")
ax[0].axhline(rho, color=labs.GOLD, ls="--", label=f"its largest |eigenvalue| = {rho:.3f}")
ax[0].semilogx(np.arange(1, 13), vroots, "o-", color=labs.GREEN, ms=4, label="Volterra operator: |V^n|^(1/n) -> 0")
ax[0].set(title="Gelfand's formula", xlabel="n", ylabel="n-th root of the norm of the n-th power", ylim=(0, None))
ax[0].legend()
for n, color in ((10, labs.TEAL), (20, labs.PURPLE), (40, labs.RED)):
ax[1].semilogy(radii, 1 / np.maximum(smin[n], 1e-15), color=color, label=f"N = {n}")
ax[1].axvline(1, color=labs.MUTED, ls="--", lw=1)
ax[1].text(1.02, 1e13, "unit circle", color=labs.MUTED, fontsize=9)
ax[1].text(0.06, 3e15, "capped at 1e15: beyond double precision", color=labs.MUTED, fontsize=9)
ax[1].set(title="Size of the resolvent of the N x N shift", xlabel="|lambda|", ylabel="norm of (S - lambda)^-1", ylim=(0.5, 1e17))
ax[1].legend(title="only eigenvalue: 0")
lab.fig = fig
return lab
Now change it
- Make the random matrix normal (A = Q diag(d) Q* with Q unitary). How does |A^n|^(1/n) behave now, and why is it constant?
- For the shift's section, print the smallest singular value of S - lam at |lam| = 0.9 for N = 20, 40, 80 and compare with 0.9^N.
- Apply the truncated vector (1, lam, lam^2, ...) to the backward shift: how small is |(S* - lam) x| / |x|, and what does it say about lam?
Notes and sources
Sources
W. Rudin, Principles of Mathematical Analysis, 3rd ed. (1976); Real and Complex Analysis, 3rd ed. (1987); Functional Analysis, 2nd ed. (1991). Theorem numbers on screen are those editions'. Each part's credits scene lists the original authors and the companion texts.
About this partfrom its README
Part 10 of a ten-part series that builds mathematical analysis from the holes in the rational numbers to the spectral theorem, following the arc of Walter Rudin's three textbooks. This part covers chapters 4 and 10-13 of Functional Analysis and chapter 18 of Real and Complex Analysis, in a hook, 12 chapters and an outro.
The shift's disc of spectrum without eigenvalues, Banach algebras and the Neumann series, the spectrum (nonempty by Liouville, measured by Gelfand's formula, and the Volterra operator), functions of operators by Cauchy's formula, Gelfand theory and Wiener's 1/f theorem, C*-algebras, operators on Hilbert space, compact self-adjoint operators and the string's modes, multiplication by x and the Born rule, projection-valued measures and the spectral theorem (proved with the whole series), unbounded operators and a circle of self-adjoint extensions, the Cayley transform, Stone's theorem, and what all of it proves about quantum mechanics.
Every number the narration states is computed in compute.py and asserted; most scenes also assert the specific values they display.
What is computed and builtComputations (compute.py)
| Item | What is computed and asserted |
|---|---|
shift |
the backward shift's eigenvectors (1, l, l^2, ...) for 200 l in the disc; the forward shift has none; the pseudospectra of N x N sections (a Jordan block: only eigenvalue 0) filling the disc |
neumann |
(I - A)^-1 = sum A^n for a random A with |
radius |
|
calculus |
e^A and sqrt(A) by the Cauchy integral around the spectrum, against scipy; spectral mapping |
wiener |
1/f for f = 1.2 + Li_2(e^(i theta)): its Fourier coefficients are absolutely summable (Wiener's 1/f) |
normal |
for a normal matrix A* is a polynomial in A; f(A) by eigenvectors = f(A) by interpolation |
numrange |
the numerical range of a non-normal 4 x 4 matrix: a convex set containing the eigenvalues |
green |
the Green's operator of -d^2/dx^2 on [0, 1]: eigenvalues 1/(n pi)^2, eigenfunctions sin(n pi x); power iteration and deflation; the heat equation by the eigen-expansion against Crank-Nicolson |
multop |
multiplication by x on L^2[0, 1]: narrowing bumps are approximate eigenvectors, none is exact |
pvm |
a 50 x 50 self-adjoint H: the spectral measure E_(x,x) as weights on the eigenvalues; the ergodic averages of a unitary converge to the projection onto its fixed vectors |
twisted |
i d/dx on [0, 1] with f(1) = e^(i theta) f(0): spectrum {2 pi n - theta} |
momentum |
-i d/dx, diagonalized by the FFT: F P F^-1 = multiplication by xi |
stone |
e^(-itH) for a discretized oscillator by the spectral decomposition and by split-operator steps |
hydrogen |
the radial hydrogen problem (l = 0) by finite differences: bound states at -1/(2 n^2), a continuum |
commutator |
[x, p] for N x N matrices has trace 0: it cannot be i I |
Chapter notes
| # | Scene | Chapter |
|---|---|---|
| 0 | Hook |
Two meanings of spectrum |
| 1 | BanachAlgebras |
1. Banach algebras |
| 2 | Spectrum |
2. The spectrum |
| 3 | SymbolicCalculus |
3. Functions of an operator |
| 4 | Gelfand |
4. Gelfand theory |
| 5 | HilbertOperators |
5. Operators on Hilbert space |
| 6 | CompactSelfAdjoint |
6. Compact self-adjoint operators |
| 7 | NoEigenvectors |
7. A spectrum with no eigenvectors |
| 8 | SpectralTheorem |
8. The spectral theorem |
| 9 | Unbounded |
9. Unbounded operators |
| 10 | Cayley |
10. The Cayley transform |
| 11 | Stone |
11. Stone's theorem |
| 12 | QuantumClosure |
12. What this proves about quantum mechanics |
| 13 | Outro |
The last row of the ledger |
Companion material in this repository
Build the film
python -m videos.analysis.analysis10.compute # the part's numbers, into .cache/analysis10
python tools/build.py analysis10 # render and assemble the film
EXPLAINER_TTS=silent python tools/qa_scene.py analysis10 Hook # one chapter, silent, with a contact sheet
Scenes: videos/analysis/analysis10. Setup: see the course page. Source of these notes: the README and the scenes' narration.
Build it
The finished video is not stored in the repository. From the repo root, after the one-time setup in the top-level README:
python -m videos.analysis.analysis10.compute # once: every computed item (cached in .cache/analysis10)
python tools/build.py analysis10 -q k --fps 60 # the full-quality cut: 2160p60 + subtitles + chapters -> renders/analysis10_2160p.mp4
python tools/build.py analysis10 # 1080p30 -> renders/analysis10.mp4
python tools/build.py analysis10 -q l # fast 480p preview
python tools/export_script.py analysis10 # regenerate SCRIPT.md from the code
python tools/check_narration.py analysis10 # Whisper listen test of every narration line
The scenes share the series' instruments in explainer/analysis and helpers from earlier parts (see common.py). The full narration is in SCRIPT.md.