Hilbert Spaces and L2
A Hilbert space is what you get when you take ordinary geometry — lengths, angles, right angles — and let it work for functions and infinite-dimensional objects instead of just arrows in 3D space.
Prerequisites: Metric Spaces and Completeness, Inner Products and Orthogonality
Ordinary vectors have length, and two vectors have an angle between them — in particular, you can ask if they're perpendicular. That geometric machinery is enormously useful: projecting one vector onto another is the basis of least-squares regression, and "closest point" problems are everywhere in quant work. A Hilbert space takes that exact machinery — length, angle, projection, perpendicularity — and extends it to work for objects that aren't little arrows in 3D space at all: entire functions, infinite sequences, random variables. is the specific, most important Hilbert space in finance: the space of functions (or random variables) with finite "energy," where the inner product is built from an integral instead of a finite sum.
The analogy: treating whole functions like arrows
In ordinary 3D geometry, you can decompose any vector into components along perpendicular axes, and the length of the whole vector is recovered by Pythagoras from those components. A Hilbert space says: you can do exactly this with functions. Treat an entire function as if it were a single "point" or "arrow" in a space with infinitely many axes, one axis per possible "basis function" (like a sine wave of a particular frequency). Two functions can be "perpendicular" (orthogonal) in a precise sense, and any function can be decomposed into components along a chosen set of perpendicular basis functions — this is exactly what a Fourier series does to a periodic signal.
The mechanics, one symbol at a time
is the set of functions (or random variables) with finite "size" in the sense that
In words: belongs to if its squared values, added up (integrated) over the whole domain, sum to a finite number — a "finite total energy" condition. The inner product between two members of generalizes the ordinary dot product:
and two functions are orthogonal exactly when — the functional analogue of perpendicular vectors. is a Hilbert space because it is (a) an inner-product space with this geometric structure, and (b) complete: every Cauchy sequence of functions in converges to another function that is itself in — no "potholes." That completeness is what makes limiting constructions (like building the Itô integral as a limit of simple approximating functions) actually land on a well-defined object.
Worked example 1: orthogonality of two simple return-decomposition signals
Let and on — two frequency components you might use to decompose a periodic seasonal pattern in returns. Their inner product is
a standard trigonometric-integral result. These two frequency components are exactly orthogonal — meaning a regression of a signal onto both simultaneously assigns each frequency's contribution independently, with no overlap to worry about, exactly the property that makes Fourier decomposition of periodic financial time series well-posed.
Worked example 2: computing an norm (finite variance as "length")
Let be a random variable representing a strategy's daily P&L, with and (dollars squared, in thousands). Then 's norm is
This is exactly the standard deviation — in language, the "length" of a mean-zero random variable is its standard deviation. Two P&L streams are "orthogonal" in this space exactly when , which (for mean-zero variables) means uncorrelated: correlation is literally the cosine of the angle between two random variables viewed as vectors in .
Think of each curve on screen as one "point" living in the space of functions — the whole curve, not any single value, is the object whose length and angle-to-other-curves the Hilbert space structure measures.
What this means in practice
and Hilbert-space geometry are the rigorous foundation under several everyday quant tools: least-squares regression is literally projecting a target vector onto the subspace spanned by predictors in ; principal component analysis finds an orthogonal basis that captures the most "energy" (variance) with the fewest components; the Itô integral is constructed as an limit of simple step-function approximations, which is precisely why completeness matters for stochastic calculus to be well-defined at all.
A Hilbert space extends ordinary geometric ideas — length, angle, orthogonality, projection — to functions and random variables via an inner product built from an integral (or expectation); , the space of finite-variance objects, is the specific Hilbert space underlying regression, PCA, Fourier analysis, and the Itô integral.
A common mistake is assuming "orthogonal" always means "unrelated" in some vague statistical sense. In , orthogonality is the precise algebraic statement (zero covariance for mean-zero variables) — it says nothing about independence in general (uncorrelated does not imply independent) and depends entirely on the inner product chosen. Two variables can be -orthogonal under one weighting or measure and not under another, so "orthogonal" is always relative to a specific inner product, not an absolute property of the variables themselves.
Related concepts
Practice in interviews
Further reading
- Reed & Simon, Functional Analysis, ch. II
- Shreve, Stochastic Calculus for Finance II, ch. 4