The Analysis Behind Kernels
The three chapters before this one built a working model: a kernel says how the values of an unknown function move together (Chapter 7), conditioning turns it into predictions (Chapter 8), and the marginal likelihood picks its settings (Chapter 9). That is enough to run Bayesian optimization. It is not enough to say why it works. The guarantees of Chapter 13 are of two kinds. The Bayesian ones hold for a function drawn from the prior. The frequentist ones, and their counterparts for comparisons in Chapter 21 and Chapter 29, hold for one fixed function whose norm in a reproducing kernel Hilbert space is at most a number . The rates of both depend on how fast the eigenvalues of the kernel decay. These statements treat a kernel not as a recipe for covariance matrices but as an object in its own right: a linear map on functions, with eigenvalues, a spectrum of frequencies, and a space of functions it calls simple.
This chapter builds that view from what the reader already has: inner products and eigenvectors (Chapter 3) and the information a Gaussian model gains from noisy data (Section 6.5). The plan is to treat a function as a very long vector and to carry each finite fact over. It ends where the results are used, with the growth of the maximum information gain and with a precise account of what a Gaussian process is as a random object. None of it is needed to use the methods of Part III; it is needed to read their guarantees.
10.1 Functions as vectors #
A vector is a list of numbers, which is the same thing as a function from the indices to : give it an index , and it returns . A function on is the same kind of object with a continuum of indices. Section 7.4 used this reading when it drew a function as the vector of its values on a grid.
10.1.1 Inner products of functions #
Take the grid of midpoints and the vectors and of two functions' values there. Their inner product (Equation (3.1)) grows with , because it adds more terms. Divided by it settles, a Riemann sum turning into an integral as in Section 7.2.1:
The limit is the inner product of two functions, and length, , and orthogonality follow as in Section 3.1.1. A weighting density can make some inputs count more: . This chapter uses the uniform weighting on unless it says otherwise.
10.1.2 Orthonormal bases: Fourier as the example #
An orthonormal basis gives vectors coordinates, and functions too. The best-known basis on is Fourier's: the constant and the functions and for , each of length 1 and orthogonal to the others. The coordinates of are its Fourier coefficients (cosine) and (sine), and its squared length is the sum of their squares, Parseval's identity.
Coefficients carry smoothness. For a differentiable with , integrating by parts moves the derivative onto the basis function and brings out a factor : the cosine coefficient of is times the sine coefficient of , and the sine coefficient of is times the cosine coefficient of . Parseval's identity for then gives
The energy of the slope, a natural measure of roughness, is a sum of squared coefficients with weights that grow with frequency. High frequencies are expensive and low ones cheap. The norm of Section 10.2 has this shape, with weights chosen by the kernel.
10.1.3 The kernel matrix as a view of an operator #
A matrix maps vectors to vectors. A kernel maps functions to functions:
a combination of the values of , weighted by how strongly is correlated with each . On the grid the integral becomes , the matrix-vector product . So is the operator seen through points, and its eigenvalues approximate the operator's.
Section 3.4.4 met one such matrix: the RBF kernel with lengthscale 0.1 on 100 evenly spaced inputs, with largest eigenvalues 23.9, 21.2, and 17.5. Divided by 100 they are 0.239, 0.212, and 0.175. Those inputs include both ends of . Placed instead at the 100 midpoints of Section 10.1.1, as in Figure 10.1 below, they give 0.241, 0.214, and 0.176, and finer grids of midpoints leave these digits unchanged. The rapid decay that broke the Cholesky factorization there belongs to the operator, not to the grid.
10.2 The space a kernel defines #
The frequentist regret theorems of Chapter 13, which bound how much an optimizer loses against the best value it could have found for one fixed function, need a class of functions large enough to contain realistic objectives and small enough that finitely many evaluations can pin a member down. A kernel defines one, and the construction starts from the weight-space view of Chapter 7.
10.2.1 Functions built from bumps #
Take a kernel that comes from features, , as in Equation (7.3) with prior weight covariance . Each weight vector gives a function , and the kernel bump is the one with weights . A sum of bumps therefore has weights , and for a second sum the inner product of the two weight vectors is
The right side mentions no features, so it serves as a definition for any positive semidefinite kernel. It does not depend on how and are written as sums: grouping by gives and grouping by gives , which depend only on the functions' values. The squared norm of is .
10.2.2 The reproducing property #
With , a single bump with coefficient 1, the same grouping gives
Taking the inner product with a bump evaluates the function. This is the reproducing property. With it gives : the bumps are features for the kernel. The Cauchy-Schwarz inequality, , applied to Equation (10.4) and to the difference of two bumps, gives two bounds (Chowdhury and Gopalan, 2017):
They say what the norm controls. Under a kernel with , a function of norm at most never exceeds in absolute value. And it cannot change quickly: for the RBF kernel the second square root is at distance , which is 0.0999 at when , close to . Over a distance short compared with the lengthscale, such a function changes by at most about . Large values and fast changes cost norm.
The first bound also shows that only the zero function has norm zero, so is a genuine length, and that sums of bumps converging in this norm converge at every input, so their limits are functions too. Adding those limits completes the construction.
Let be a symmetric positive semidefinite kernel on . Its reproducing kernel Hilbert space (RKHS) is the space of functions obtained by completing the sums of bumps under the norm of Equation (10.3). It is the unique Hilbert space of functions (an inner-product space in which every sequence whose terms come arbitrarily close to one another has a limit in the space) that contains every bump and in which Equation (10.4) holds for every member and every input (Aronszajn, 1950; Rasmussen and Williams, 2006, thm. 6.1).
For familiar kernels the space is recognizable. The line kernel (Example 7.1 with , ) has the lines as its RKHS, with norm , the slope. For a kernel from finitely many features with weight covariance , the norm of is the length of the shortest weight vector that produces it (Steinwart and Christmann, 2008, ch. 4). The RKHS of a Matérn kernel with smoothness on a bounded domain in dimensions holds the same functions as a Sobolev space, those whose derivatives up to order are square-integrable, with an equivalent norm, when is a whole number and the boundary is regular (Kanagawa et al., 2018, ex. 2.6). The RBF kernel's RKHS holds only functions whose Fourier transforms decay exponentially fast, so they are extremely smooth (Kanagawa et al., 2018, ex. 2.7).
10.2.3 The posterior mean lives in the space #
The posterior mean of Gaussian process regression is a weighted sum of bumps, one per observation (Equation (8.4)), so it lies in . It also solves a problem stated without probability.
Find the that minimizes .
- Let be the span of , and write with orthogonal to every bump in .
- By Equation (10.4), . The data term sees only .
- By Pythagoras, , so dropping lowers the penalty and the minimizer lies in : .
- Then the fitted values are and .
- The gradient, , vanishes at , so : the posterior mean of Equation (8.6).
That a penalized fit over an infinite-dimensional space has a solution with terms is the representer theorem, first stated for squared error by Kimeldorf and Wahba (1971); the match with the Gaussian process posterior mean goes back to Kimeldorf and Wahba (1970) (see also Kanagawa et al., 2018, prop. 3.6). With the data term a plain sum, as here, the penalty weight is the noise variance, the kernel ridge regression of Section 8.2.1. In weight space the match is expected: with , minus twice the log posterior is up to a constant, and the shortest for has length . The squared norm plays the part of minus twice the log prior.
The posterior mean of Figure 8.1 at its defaults (lengthscale 0.12, four observations, the largest 0.85 in absolute value) has , so Equation (10.5) caps it at 1.18, above its actual maximum: the norm is a guarantee, not a description.
10.2.4 What a norm bound assumes #
The frequentist regret theorems (Section 13.4.4, Section 21.3, Chapter 29), in which is one fixed function and the only randomness is the evaluation noise, assume that lies in with a known bound on its norm. By the sections above, if and , then is no larger than anywhere, changes by at most about per lengthscale, and puts little weight where the kernel says weight is expensive. The assumption depends on the kernel and its lengthscale, not only on : a longer lengthscale makes fast changes more expensive, and under the RBF kernel a Gaussian bump of width or less has infinite norm (Exercise 10.1).
Two conventions are in use, and they differ by a square. Srinivas et al. (2010) assume , as Section 13.4.4 does; Chowdhury and Gopalan (2017) and the preference papers of Section 21.3 and Chapter 29 assume . In the second convention the bound enters the confidence width directly. For noise that is -sub-Gaussian (tails no heavier than those of a Gaussian with standard deviation ), Chowdhury and Gopalan show that with probability at least , for all and all rounds , with (Chowdhury and Gopalan, 2017, thm. 2); their posterior and their use the noise variance in place of , and their is the square root of the book's. Chapter 13 explains where such widths come from. In practice is unknown, and the kernel that sets its units is fitted from the same data (Section 13.5.2).
10.2.5 Samples are rougher than the space #
The Bayesian theorem of Section 13.4.1 assumes instead that is a draw from . It is natural to guess that a typical draw has a moderate norm in . It has none at all.
Let be distinct inputs whose kernel matrices are all invertible; for the RBF and Matérn kernels any distinct inputs qualify (Section 10.4.1).
- Interpolation bound. For with values at , steps 1 to 3 above (with no data term) show that its part in the span of the first bumps has the same values and no larger norm. With and , this gives .
- The same quantity for a draw. Write the draw's values as , with the Cholesky factor of and standard normal (Section 4.3.1). Then .
- Nesting. Adding appends a row to without changing it, so the first entries of stay put and .
- No bound. has mean and standard deviation , so for any fixed the probability that tends to zero. Since only grows, the probability that it stays below for every is zero.
- A draw in would have for every by step 1, so for some whole number it would have for every . The norm differs from draw to draw, so step 4, which is about a fixed , does not apply to it directly. But for each of the countably many the event has probability zero by step 4, and so does their union, since the probability of a union is at most the sum of the probabilities (Equation (13.7), with countably many events).
The general statement is a zero-one law: a Gaussian process lies in a given RKHS with probability 0 or 1, and in the RKHS of its own kernel with probability 0 whenever that space is infinite-dimensional (Driscoll, 1973; Lukić and Beder, 2001; Kanagawa et al., 2018, thm. 4.9 and cor. 4.10). Read through inputs, a draw looks like a function of squared norm about , and each new input adds about 1. The posterior mean is a finite sum of bumps, and averaging removes the roughness (Rasmussen and Williams, 2006, sec. 6.1).
Draws do lie in slightly larger spaces of rougher functions. For the RBF kernel the difference rarely matters (Kanagawa et al., 2018, cor. 4.13 and remark 4.13). For a Matérn kernel it does: the RKHS asks for Sobolev smoothness , while draws have every order below and no more, rougher by (Kanagawa et al., 2018, cor. 4.15 and remarks 4.14 and 4.15).
So the two settings of Chapter 13 assume different things. The Bayesian theorem is about draws, which no bound covers; the frequentist theorems are about members of , a set to which the prior gives probability zero. Neither contains the other, as Srinivas et al. (2010) note. Choosing a Matérn 5/2 kernel in dimensions and then quoting a frequentist bound assumes smoothness , more than the draws of the same prior have (inference).
Sources cited in Section 10.2 10
- Chowdhury and Gopalan (2017) On Kernelized Multi-armed Bandits
- Aronszajn (1950) Theory of Reproducing Kernels
- Rasmussen and Williams (2006) Gaussian Processes for Machine Learning
- Steinwart and Christmann (2008) Support Vector Machines
- Kanagawa et al. (2018) Gaussian Processes and Kernel Methods: A Review on Connections and Equivalences
- Kimeldorf and Wahba (1971) Some Results on Tchebycheffian Spline Functions
- Kimeldorf and Wahba (1970) A Correspondence Between Bayesian Estimation on Stochastic Processes and Smoothing by Splines
- Srinivas et al. (2010) Gaussian Process Optimization in the Bandit Setting: No Regret and Experimental Design
- Driscoll (1973) The Reproducing Kernel Hilbert Space Structure of the Sample Paths of a Gaussian Process
- Lukić and Beder (2001) Stochastic Processes with Sample Paths in Reproducing Kernel Hilbert Spaces
10.3 Mercer's theorem #
Bumps overlap and are not orthogonal, so they make awkward coordinates. For a symmetric matrix, Section 3.4.1 found better ones, the eigenvectors. The operator is the continuous version of a symmetric matrix, and the same move works.
10.3.1 Eigenfunctions and the expansion of the kernel #
An eigenfunction of is a function that the operator only rescales, , with eigenvalue . (This chapter writes for eigenfunctions, to keep them apart from the features of Chapter 7 and the normal density .)
Let be a closed and bounded subset of , a continuous, symmetric, positive semidefinite kernel on , and a weighting that gives positive weight to every open region of (a density with , or more generally a finite measure whose support is ). Then has eigenvalues , finitely or countably many, with eigenfunctions orthonormal under , and
for all , the series converging absolutely and uniformly (Mercer, 1909; Steinwart and Christmann, 2008, thm. 4.49; Kanagawa et al., 2018, thm. 4.1).
Equation (10.6) is the spectral theorem Theorem 3.1, , with functions in place of vectors. The conditions matter: where the weighting gives no weight, the expansion can fail (Kanagawa et al., 2018, remark 4.2). The eigenvalues and eigenfunctions depend on the weighting, while the kernel and its RKHS do not (Kanagawa et al., 2018, remarks 4.1 and 4.3). Three consequences follow.
The eigenvalues are a variance budget. Setting in Equation (10.6) and integrating against gives, by orthonormality, . For a stationary kernel and a probability density , the eigenvalues sum to , the prior variance, and say how it is shared among directions.
Every kernel is an inner product of features. With , Equation (10.6) reads . This is the converse quoted in Section 7.2.2.
The RKHS norm in eigen-coordinates. Expand with . Then exactly when the following sum is finite, and
(Rasmussen and Williams, 2006, sec. 6.1; Kanagawa et al., 2018, thm. 4.2). The reproducing property checks it: by Equation (10.6) the bump has coefficients , so . This is Equation (10.1) with weights chosen by the kernel, and the continuous form of written in the eigenvectors of (Rasmussen and Williams, 2006, sec. 6.1). A direction with a small eigenvalue is expensive: a coefficient along it costs .
10.3.2 The eigen-expansion of a sample #
The same coordinates describe the prior. With independent standard normal numbers , set
Then , since is 1 for and 0 otherwise. So Equation (10.8) is a draw from written in the eigenbasis, with independent coefficients of variance . This is the Karhunen-Loève expansion; the series converges in mean square, uniformly over the domain (Kanagawa et al., 2018, thm. 4.3; Berlinet and Thomas-Agnan, 2004, sec. 2.3). By orthonormality, keeping the first terms leaves an average squared error of
the eigenvalue mass left out.
The two readings of a small eigenvalue agree: the prior gives the direction little variance, , and the norm charges it heavily, . By Equation (10.7) the truncated draw has , about , the picture of Section 10.2.5 in eigen-coordinates. This last step is intuition rather than proof, because the full series converges in mean square and not in the norm (Kanagawa et al., 2018, remark 4.9); Section 10.2.5 gave the proof.
10.3.3 Computing them #
Eigenfunctions rarely have a closed form. They are computed as Section 10.1.3 suggested: on a grid of points with uniform weighting, the eigenvalues of estimate the , and the eigenvectors times estimate the at the grid points. This is the Nyström method; it estimates the larger eigenvalues better than the smaller ones (Rasmussen and Williams, 2006, sec. 4.3.2).
Read the default. The RBF kernel with lengthscale 0.1 has largest eigenvalues 0.241, 0.214, and 0.176, the values of Section 10.1.3; all of its eigenvalues together sum to 1.00, the prior variance, and they reach the rounding floor by the 32nd. The first four eigenfunctions look like cosines with 0, 1, 2, and 3 sign changes.
Move the terms slider. One term holds 24% of the prior variance and ten hold 99.5%; the ten-term draw is hard to tell from the exact one. The squared norm of the truncated draw keeps growing, 8.7 with ten terms and 96.5 with all 100, though the draw barely changes.
Switch to Matérn 1/2. The eigenvalues fall on a straight line on log axes, a power law. Ten terms hold 80% of the variance and twenty about 90%. The truncated draw is smooth and the exact one jagged: the roughness lives in the many small eigenvalues.
Compare the slopes. The Matérn lines have slopes near , , and for , , and ; on a grid of 3,000 points, between the 20th and 60th eigenvalues, they are , , and . The eigenvalues decay like , in line with the result of Ritter and colleagues that a process with mean-square derivatives on has eigenvalues decaying like (Rasmussen and Williams, 2006, sec. 4.3).
Lengthen the lengthscale to 0.3. The first RBF eigenvalue rises to 0.590 and four terms hold 99.6% of the variance: a longer lengthscale concentrates the prior on fewer directions.
Sources cited in Section 10.3 5
- Mercer (1909) Functions of Positive and Negative Type, and Their Connection with the Theory of Integral Equations
- Steinwart and Christmann (2008) Support Vector Machines
- Kanagawa et al. (2018) Gaussian Processes and Kernel Methods: A Review on Connections and Equivalences
- Rasmussen and Williams (2006) Gaussian Processes for Machine Learning
- Berlinet and Thomas-Agnan (2004) Reproducing Kernel Hilbert Spaces in Probability and Statistics
10.4 Bochner's theorem #
Mercer's eigenfunctions depend on the domain and the weighting, and must be computed. For a stationary kernel, which depends only on (Section 7.5.1), there is a description that needs neither: a list of frequencies and the variance each carries.
10.4.1 Kernels as spectra #
Start from one cosine with a random amplitude. If with independent standard normals, then , a stationary kernel. Mixtures over frequencies give more, and Bochner's theorem says they give all.
A continuous function on is a stationary kernel, meaning that is positive semidefinite, exactly when for a finite nonnegative measure over frequencies (Bochner, 1933; Rasmussen and Williams, 2006, thm. 4.1).
For the kernels of this book has a density , the spectral density, symmetric in , and . Frequencies here are in radians per unit of input; Rasmussen and Williams use cycles, , which rescales the density but not its shape (Rasmussen and Williams, 2006, eq. 4.6). Since , is a probability density, and
One direction of the theorem is short. For inputs and coefficients , the identity gives
If is positive at every frequency, as for the RBF and Matérn kernels, the integral is positive unless all are zero, because for distinct inputs the two sums cannot vanish together at every frequency. Every kernel matrix of distinct inputs is then invertible, which Section 10.2.5 used (Wendland, 2004, ch. 6). The converse, that every stationary kernel has such a spectrum, is the deep part.
10.4.2 The spectra of the RBF and Matérn kernels #
For the RBF kernel the frequencies are Gaussian, , so a typical frequency is about (Exercise 10.2). For the Matérn kernel they follow a Student-t distribution with degrees of freedom and scale ,
which is eq. 4.15 of Rasmussen and Williams (2006) in radians. For in one dimension it is the Cauchy distribution, .
The tails differ. The Gaussian falls faster than any power, while Equation (10.11) falls like , keeping a little variance at every high frequency, more for smaller . The tails set the smoothness. Differentiating Equation (10.10) twice at in one dimension gives , the variance of the mean-square derivative (Section 7.5.3). It is finite only if the tail falls faster than , which for the Matérn kernel means , or . With higher even powers of in place of the same argument gives the rule of Table 9.1: a mean-square derivative of every whole order below , and none of order or above. And , the root-mean-square frequency, is what Equation (7.6) counts: for Matérn 5/2 the Student-t with 5 degrees of freedom has variance in units of , the of Exercise 7.4.
Mercer and Bochner describe the same kernel, and on a domain without ends they coincide. Join the ends of into a circle and wrap the kernel around it, over all integers . Integrating over one turn equals integrating over the whole line: substituting turns the integral of the term over into the integral of over , since the cosine repeats with period 1, and these intervals cover the line. With , the cosine splits as . The sine part integrates to zero because is even, and the cosine part gives , because the spectral density is recovered from the kernel by (Rasmussen and Williams, 2006, eq. 4.6). Sines work the same way. So the eigenfunctions on the circle are Fourier's, and the eigenvalues are : the spectral density sampled at the frequencies that fit around the circle. Eigenvalue decay is spectral decay. Since the th eigenvalue sits near frequency , a Matérn spectrum falling like gives eigenvalues falling like , the slopes of Figure 10.1. The interval's ends change the values but not the tail: at lengthscale 0.1 the 80th Matérn 1/2 eigenvalue is on the interval and on the circle.
10.4.3 Random Fourier features #
Equation (10.10) turns a kernel into an expectation, which an average can estimate. Draw frequencies from and use the features
By the cosine identity, , an average whose expectation is . These are the random Fourier features of Rahimi and Recht (2007). With each term lies in and has variance , which tends to at large distances (Exercise 10.3), so the error at one distance is typically about . Accuracy at all pairs of inputs in a bounded domain at once needs of order , with the domain's diameter and the spread of entering through the logarithm (Rahimi and Recht, 2007, claim 1).
A weighted sum with is the linear model of Equation (7.1) with features: an approximate draw from that is a formula, costs per input, and can be maximized like any function. This is one way for Thompson sampling, which evaluates where a random draw from the posterior is largest (Section 12.5), to draw whole functions on a continuous domain, as Section 8.5 mentioned (Rahimi and Recht, 2007; Wilson et al., 2020).
Read the default. The Matérn 3/2 density falls like a power and is still near of its peak at , where the RBF density has vanished. With the estimated kernel wanders around the true one, with a root-mean-square gap of 0.152 against .
Raise M to 200, then 2000. The gap falls to 0.058, then 0.023, against 0.050 and 0.016: roughly the rate of an average, a factor of about three per tenfold increase in .
Switch to Matérn 1/2 at M = 20. The heavy Cauchy tail puts a few of the twenty frequencies far out, and they show as a regular ripple, in the kernel estimate and in the feature draw, which is otherwise smooth. The exact draw is rough at every scale. A heavy-tailed spectrum spreads its roughness over many high frequencies, each with little variance, and twenty features sample only a few of them.
Switch to RBF. The frequencies all lie within a few multiples of , and the feature draw has the character of the exact one at small , because RBF draws are made of such frequencies. The kernel estimate is no more accurate than before: its gap at is 0.161.
Sources cited in Section 10.4 5
- Bochner (1933) Monotone Funktionen, Stieltjessche Integrale und harmonische Analyse
- Rasmussen and Williams (2006) Gaussian Processes for Machine Learning
- Wendland (2004) Scattered Data Approximation
- Rahimi and Recht (2007) Random Features for Large-Scale Kernel Machines
- Wilson et al. (2020) Efficiently Sampling Functions from Gaussian Process Posteriors
10.5 From eigenvalues to information gain #
The regret bounds of Chapter 13 (bounds on an optimizer's total shortfall from the best value) depend on the maximum information gain (Definition 13.3), the most that noisy evaluations could reveal about . Section 6.5 quoted its growth for the RBF and Matérn kernels. The rates come from the eigenvalues.
10.5.1 Counting resolved directions #
Write the kernel matrix of inputs through Equation (10.6) as , where row of holds the eigenfunctions at and holds the eigenvalues on its diagonal. The determinant lemma (Equation (B.7)) moves the information gain Equation (6.15) from the evaluations to the eigen-directions: . If the inputs are spread in proportion to , then approximates , which is 1 or 0, as the Riemann sum of Section 10.1.1 did, so and
Each eigen-direction is a separate experiment: its coefficient has prior variance , and spread-out evaluations measure it with noise variance about , which Equation (6.12) turns into the term above. A direction with is resolved and adds about ; one with adds about . The information is roughly the number of resolved directions times half a logarithm, plus times the unresolved eigenvalue mass.
Equation (10.13) is an approximation. Against the exact information of evenly spaced evaluations on (lengthscale 0.1, ), it is within 0.25% at for the RBF and the Matérn 5/2 and 3/2 kernels. For Matérn 1/2 it is 46% too high at , because it counts 143 resolved directions, more than 100 evaluations can resolve, and 7.4% too high at .
10.5.2 A bound from the eigenvalues #
The count can be made rigorous for any design by cutting at directions and paying for the eigenvalue mass beyond them.
Let satisfy the conditions of Theorem 10.1, with and for all and . For every ,
This is Theorem 3 of Vakili et al. (2021a), whose is and whose is .
The tail is eigenvalue mass, not a failure probability like the of Section 10.2.4; the letter follows the paper. The bound on the eigenfunctions is an assumption, which the authors state holds for the kernels used in practice; we found no proof that it holds for the RBF and Matérn kernels on every domain and weighting. The proof needs only the tools of Section 6.3.
Fix inputs and split the kernel at : with and the rest, both positive semidefinite.
- Split the function. Independent and sum to a process with kernel (Exercise 7.3), so with at , is the information in about the sum (Equation (6.12)). The sum is computed from the pair , so by the data processing inequality (Equation (6.10)) this is at most the information about the pair.
- Chain rule. That is (Section 6.5.1) (Cover and Thomas, 2006, ch. 2). Given , the data are plus noise, so the second term is . The first is at most the information of about , since adding the independent is further processing: .
- The first directions. , so by Equation (B.7) its determinant is that of the matrix with . For its eigenvalues , concavity of the logarithm gives . A trace is unchanged when the factors of a product are rotated, so . Each term satisfies , since , so .
- The rest. Since , , and .
- Add steps 3 and 4, halve, and maximize over .
10.5.3 Polynomial and exponential decay #
The best balances the two terms of Equation (10.14), directions kept times against times the mass beyond them, and the balance depends only on how fast the eigenvalues fall.
Polynomial decay, with .
- , so the second term is of order ; the first is of order .
- They match for , where both are of order .
For a Matérn kernel with in dimensions, (Santin and Schaback, 2016; Vakili et al., 2021a, remark 2), so and .
Exponential decay, in one dimension .
- .
- With , , so the second term is bounded by a constant and the first is of order .
For the RBF kernel in dimensions, (Belkin, 2018; Vakili et al., 2021a, remark 2), and of order gives (Vakili et al., 2021a, cor. 1).
These are the rates of Section 6.5.2 and Table 13.1: the Matérn rate is that of Vakili et al. (2021a), stated for , and the RBF rate, first proved by Srinivas et al. (2010), is recovered by the same theorem. A kernel built from features, such as the linear kernel in dimensions, has at most nonzero eigenvalues, the tail vanishes at , and the bound gives (Exercise 10.4). In words: a polynomially decaying spectrum keeps about directions within reach as grows, an exponentially decaying one only about , and each resolved direction costs a logarithm. Smoothness lowers the exponent; dimension raises it.
The rates are asymptotic. Figure 10.3 computes exactly the information that evaluations spread evenly over gather, a lower bound on , since takes the best design.
Read the default. At , with lengthscale 0.1 and noise standard deviation 0.1, the RBF kernel gathers 36.5 nats, Matérn 5/2 53.4, Matérn 3/2 70.2, and Matérn 1/2 150.4, against 230.8 for a hundred completely new evaluations. The curves leave the dashed line, falling below 90% of it, between and , when evaluations start to overlap.
Move T to 1000. The local slopes are 0.16, 0.22, 0.28, and 0.58, still above the large- values of 0 for the RBF kernel and , , and for the Matérn kernels. A thousand evaluations in one dimension is not yet the long run.
Lengthen the lengthscale to 0.3. At the four values fall to 25.2, 41.5, 63.9, and 398.0 nats. The rates do not depend on the lengthscale; the constants in front of them do, through how many eigenvalues are large.
10.5.4 From information gain to regret #
Table 10.1 carries the rates through the regret bounds of GP-UCB, the rule that evaluates where the posterior mean plus a multiple of the posterior standard deviation is largest (Equation (13.11)), with the setting each result assumes.
| Kernel | Eigenvalues | Regret upper bound, Bayesian | Lower bound, fixed function | |
|---|---|---|---|---|
| RBF | (Belkin, 2018) | |||
| Matérn, | (Santin and Schaback, 2016) |
The and regret columns are those of Vakili et al. (2021a); the regret is with substituted, and for the RBF kernel it is the of Section 13.4.3. The lower bounds are those of Scarlett et al. (2017). On a continuous domain the Bayesian bound needs sample paths smooth enough to discretize, which the RBF kernel and Matérn kernels with provide (Section 13.4.4, Section 10.6.3).
For a fixed function in the RKHS, the frequentist analysis of GP-UCB gives regret of order up to logarithmic factors (Chowdhury and Gopalan, 2017), whose exponent with the Matérn rate, , reaches 1 once (inference, as in Section 13.5.2). The factor between that and the lower bound is the subject of Section 21.4 and Section 29.4.
Sources cited in Section 10.5 7
- Vakili et al. (2021a) On Information Gain and Regret Bounds in Gaussian Process Bandits
- Cover and Thomas (2006) Elements of Information Theory
- Santin and Schaback (2016) Approximation of Eigenfunctions in Kernel-Based Spaces
- Belkin (2018) Approximation Beats Concentration? An Approximation View on Inference with Smooth Radial Kernels
- Srinivas et al. (2010) Gaussian Process Optimization in the Bandit Setting: No Regret and Experimental Design
- Scarlett et al. (2017) Lower Bounds on Regret for Noisy Gaussian Process Bandit Optimization
- Chowdhury and Gopalan (2017) On Kernelized Multi-armed Bandits
10.6 A Gaussian process made precise #
Definition 7.1 defined a Gaussian process as a collection of random variables, any finite number of them jointly Gaussian, and Section 7.3 read it as an interface that answers queries at finitely many inputs. The regret bounds ask more: they take the maximum of over a continuous domain, infinitely many inputs at once. This section says what kind of object a Gaussian process is, and when such questions have answers.
10.6.1 Random variables indexed by inputs #
A random variable is a function of the outcome of a random experiment (Section 2.1.3; here is an outcome, not a frequency). A stochastic process on a domain is a function such that is a random variable for every fixed . Fixing the outcome instead gives the sample path . A Gaussian process is a stochastic process whose values at any finite list of inputs are jointly Gaussian (Da Costa et al., 2026, def. 2.1).
The joint distributions at finite lists of inputs, the finite-dimensional distributions, must agree in two ways: listing the inputs in another order permutes the distribution accordingly, and dropping an input gives the marginal of the rest. Section 7.3 checked the second for every mean function and kernel.
Every family of finite-dimensional distributions consistent in these two ways belongs to some stochastic process on , and it determines that process's probabilities for every event that involves countably many inputs (Kolmogoroff, 1933, ch. III, sec. 4).
This is the theorem the aside of Section 7.3 named. For a Gaussian process it says that a mean function and a positive semidefinite kernel define a random function on any domain (Da Costa et al., 2026, sec. 2). Its proof needs measure theory, and the book does not give it.
10.6.2 What the finite-dimensional distributions do not decide #
Whether the path is continuous, or what its maximum on is, are questions about uncountably many inputs, and the finite-dimensional distributions do not decide them. Let be uniform on , and define for every and if , 0 otherwise. At any fixed , unless lands exactly on , which has probability zero, so and have the same finite-dimensional distributions. Yet every path of is continuous with maximum 0, and every path of jumps and has maximum 1.
Processes that agree with probability 1 at each fixed input are called versions of each other (Kanagawa et al., 2018, def. 4.8), and a statement about sample paths says that some version has them. When a Gaussian process on a closed and bounded domain has a continuous version, that version is the one meant, and its maximum and maximizer exist, because a continuous function on such a domain attains its maximum. Entropy search, which chooses evaluations by what they reveal about where is (Section 12.7), presupposes this.
10.6.3 Sample-path regularity #
Whether a continuous version exists depends on the kernel near zero distance. For a stationary kernel and mean zero, the expected squared difference of two nearby values is
If this shrinks like for some between 0 and 1, the process has a version whose paths are continuous, and Hölder continuous of every order , meaning that near each point (Da Costa et al., 2026, thm. 3.1). For Gaussian processes this is a sharp form of the continuity theorem of Kolmogorov, on which the proof rests.
For the Matérn 1/2 kernel, , so : the paths are continuous, Hölder of every order below 1/2 like Brownian motion (a random walk taken to continuous time), and no more, so not differentiable (Da Costa et al., 2026, remark 3.4). Applying the criterion to the derivative process, whose kernel is , climbs the ladder: for that is not a whole number, a Matérn path is (for a suitable version) times continuously differentiable and no more, so give 0, 1, and 2 continuous derivatives (Da Costa et al., 2026, cor. 1.2 and prop. 3.1). For such these sample-path statements agree with the mean-square ladder of Table 9.1, which also gives derivatives of every whole order below and no more. RBF paths have derivatives of every order (Da Costa et al., 2026, remark 3.5).
The agreement is a theorem, not a definition. Mean-square differentiability (Section 7.5.3) concerns second moments of difference quotients and follows from alone (Rasmussen and Williams, 2006, sec. 4.1.1); sample-path differentiability concerns each drawn function. The continuous-domain regret bound of Section 13.4.4 needs the second, with some to spare: its proof discretizes the domain and asks that nearby values be close with high probability, which the RBF kernel and Matérn kernels with provide (Srinivas et al., 2010).
For a Matérn kernel, then, draws have continuous derivatives and Sobolev smoothness just below , while RKHS functions, the posterior mean among them, have Sobolev smoothness (Section 10.2.5). Every regret bound assumes one of these levels.
Sources cited in Section 10.6 5
- Da Costa et al. (2026) Sample Path Regularity of Gaussian Processes from the Covariance Kernel
- Kolmogoroff (1933) Grundbegriffe der Wahrscheinlichkeitsrechnung
- Kanagawa et al. (2018) Gaussian Processes and Kernel Methods: A Review on Connections and Equivalences
- Rasmussen and Williams (2006) Gaussian Processes for Machine Learning
- Srinivas et al. (2010) Gaussian Process Optimization in the Bandit Setting: No Regret and Experimental Design
10.7 Exercises #
Let be the RBF kernel with unit amplitude and lengthscale on . (a) Show that and evaluate it at and . (b) For a stationary kernel on , exactly when is finite, where is the Fourier transform of and the spectral density (Wendland, 2004, thm. 10.12; Kanagawa et al., 2018, thm. 2.4). For the bump , with , find the widths for which .
Solution
(a) By Equation (10.3) with coefficients and , the squared norm is . At distance , and it is ; at , and it is , close to 2, the value for two bumps that do not overlap. (b) The RBF spectral density is proportional to , so the integrand is proportional to , and the integral is finite exactly when . A narrower bump has infinite norm: the kernel gives its high frequencies too little prior variance to pay for them. The kernel's own bump, of width , qualifies, as it must.
Let and . (a) Show, by integrating by parts, that for a differentiable that does not grow too fast. (b) Use it to show , and conclude that .
Solution
(a) The density has , so by parts, the boundary terms vanishing because decays faster than grows. (b) , and with , , so . With the unique solution is , the RBF kernel: Gaussian frequencies with standard deviation give lengthscale , and a short lengthscale needs high frequencies.
One random feature estimates a unit-amplitude kernel at distance by , . (a) Show that its variance is . (b) Evaluate it at and as . (c) For the RBF kernel, show that it never exceeds , so the average of features has standard deviation at most .
Solution
(a) , so by Equation (10.10); subtract the squared mean . (b) At it is , since every feature gives exactly; as it tends to . (c) For the RBF kernel , so the variance is for . The terms are independent, so the average has variance at most , the comparison value of Figure 10.2.
(a) The linear kernel on the unit ball of has at most nonzero eigenvalues. Use Theorem 10.3 with to show . (b) Compare with the independent arms of Exercise 13.3, for which , and explain the shared form.
Solution
(a) With the tail is zero, and on the unit ball , so and only the first term of Equation (10.14) remains: , which is , the linear rate of Section 6.5.2. The bound does not enter, because step 4 of the proof is not needed. (b) Both kernels have a fixed number of directions, or , holding all the variance. Each can be measured repeatedly but contributes only a logarithm, and the best design spreads the evaluations evenly among them. A kernel with infinitely many eigenvalues behaves like one with directions, where grows with as fast as the decay allows.
Sources cited in Section 10.7 2
- Wendland (2004) Scattered Data Approximation
- Kanagawa et al. (2018) Gaussian Processes and Kernel Methods: A Review on Connections and Equivalences
Further reading #
- Kanagawa et al. (2018), a long review available as a preprint, sets the Gaussian process and RKHS views side by side, with Mercer's theorem, the Karhunen-Loève expansion, the zero-one law for sample paths, and the Sobolev spaces of Matérn kernels.
- Rasmussen and Williams (2006), chapter 4, treats stationary kernels, Bochner's theorem, and eigenfunction analysis; chapter 6 introduces the RKHS and its link to regularization.
- Aronszajn (1950) founded the theory of reproducing kernels; Steinwart and Christmann (2008), chapter 4, and Berlinet and Thomas-Agnan (2004) give modern treatments, the second with probability in view.
- Wendland (2004) develops positive definite functions (chapter 6) and the native spaces of kernels (chapter 10) from approximation theory.
- Rahimi and Recht (2007) introduced random Fourier features, with the uniform convergence bound quoted here.
- Vakili et al. (2021a) derives the information-gain rates from eigenvalue decay; Theorem 10.3 is their Theorem 3.
- Da Costa et al. (2026) gives necessary and sufficient conditions on the kernel for the sample paths to have a given smoothness, with the Matérn and RBF kernels as examples.
References
- (1950). Theory of Reproducing Kernels. Transactions of the American Mathematical Society. Cited in §10.2
- (2018). Approximation Beats Concentration? An Approximation View on Inference with Smooth Radial Kernels. Proceedings of the 31st Conference on Learning Theory. Cited in §10.5
- (2004). Reproducing Kernel Hilbert Spaces in Probability and Statistics. Springer. Cited in §10.3
- (1933). Monotone Funktionen, Stieltjessche Integrale und harmonische Analyse. Mathematische Annalen. Cited in §10.4
- (2017). On Kernelized Multi-armed Bandits. International Conference on Machine Learning. Cited in §10.2 §10.5
- (2006). Elements of Information Theory. Wiley. Cited in §10.5
- (2026). Sample Path Regularity of Gaussian Processes from the Covariance Kernel. Analysis and Applications. Cited in §10.6
- (1973). The Reproducing Kernel Hilbert Space Structure of the Sample Paths of a Gaussian Process. Zeitschrift für Wahrscheinlichkeitstheorie und Verwandte Gebiete. Cited in §10.2
- (2018). Gaussian Processes and Kernel Methods: A Review on Connections and Equivalences. arXiv preprint. preprint Cited in §10.2 §10.3 §10.6 §10.7
- (1970). A Correspondence Between Bayesian Estimation on Stochastic Processes and Smoothing by Splines. The Annals of Mathematical Statistics. Cited in §10.2
- (1971). Some Results on Tchebycheffian Spline Functions. Journal of Mathematical Analysis and Applications. Cited in §10.2
- (1933). Grundbegriffe der Wahrscheinlichkeitsrechnung. Springer. Cited in §10.6
- (2001). Stochastic Processes with Sample Paths in Reproducing Kernel Hilbert Spaces. Transactions of the American Mathematical Society. Cited in §10.2
- (1909). Functions of Positive and Negative Type, and Their Connection with the Theory of Integral Equations. Philosophical Transactions of the Royal Society of London. Series A, Containing Papers of a Mathematical or Physical Character. Cited in §10.3
- (2007). Random Features for Large-Scale Kernel Machines. Advances in Neural Information Processing Systems 20 (NeurIPS 2007). Cited in §10.4
- (2006). Gaussian Processes for Machine Learning. MIT Press. Cited in §10.2 §10.3 §10.4 §10.6
- (2016). Approximation of Eigenfunctions in Kernel-Based Spaces. Advances in Computational Mathematics. Cited in §10.5
- (2017). Lower Bounds on Regret for Noisy Gaussian Process Bandit Optimization. Conference on Learning Theory. Cited in §10.5
- (2010). Gaussian Process Optimization in the Bandit Setting: No Regret and Experimental Design. ICML 2010. Cited in §10.2 §10.5 §10.6
- (2008). Support Vector Machines. Springer. Cited in §10.2 §10.3
- (2021a). On Information Gain and Regret Bounds in Gaussian Process Bandits. International Conference on Artificial Intelligence and Statistics. Cited in §10.5
- (2004). Scattered Data Approximation. Cambridge University Press. Cited in §10.4 §10.7
- (2020). Efficiently Sampling Functions from Gaussian Process Posteriors. Proceedings of the 37th International Conference on Machine Learning (ICML 2020). Cited in §10.4