In order to exploit kernel substitution, we need to be able to construct valid kernel functions. A necessary and sufficient for a function $k(\bold x,\bold x^{\prime})$ to be a valid kernel is that the Gram matrix $\bold K$, whose elements are given by $k(\bold x_n,\bold x_m)$, should be positive semidefinite for all possible choices of the set $\{\bold x_n\}$.

Techniques for Constructing New Kernels

Given valid kernels $k_1(\bold x,\bold x^{\prime})$ and $k_2(\bold x,\bold x^{\prime})$, the following new kernels will also be valid:

$$ \begin{aligned} k(\bold x,\bold x^{\prime})&=ck_1(\bold x,\bold x^{\prime})\\ k(\bold x,\bold x^{\prime})&=f(\bold x)k_1(\bold x,\bold x^{\prime})f(\bold x^{\prime})\\ k(\bold x,\bold x^{\prime})&=q(k_1(\bold x,\bold x^{\prime}))\\ k(\bold x,\bold x^{\prime})&=\exp(k_1(\bold x,\bold x^{\prime}))\\ k(\bold x,\bold x^{\prime})&=k_1(\bold x,\bold x^{\prime})+k_2(\bold x,\bold x^{\prime})\\ k(\bold x,\bold x^{\prime})&=k_1(\bold x,\bold x^{\prime})k_2(\bold x,\bold x^{\prime})\\ k(\bold x,\bold x^{\prime})&=k_3(\bm\phi(\bold x),\bm\phi(\bold x^{\prime}))\\ k(\bold x,\bold x^{\prime})&=\bold x^{\text T}\bold A\bold x^{\prime}\\ k(\bold x,\bold x^{\prime})&=k_a(\bold x_a,\bold x_a^{\prime})+k_b(\bold x_b,\bold x_b^{\prime})\\ k(\bold x,\bold x^{\prime})&=k_a(\bold x_a,\bold x_a^{\prime})k_b(\bold x_b,\bold x_b^{\prime}) \end{aligned} $$

where $c>0$ is a constant, $f(\cdot)$ is any function, $q(\cdot)$ is a polynomial with nonnegative coefficients, $\bm\phi(\bold x)$ is a function from $\bold x$ to $\Bbb R^M$, $k_3(\cdot,\cdot)$ is a valid kernel in $\Bbb R^M$, $\bold A$ is a symmetric positive semidefinite matrix, $\bold x_a$ and $\bold x_b$ are variables (not necessarily disjoint) with $\bold x=(\bold x_a,\bold x_b)$, and $k_a$ and $k_b$ are valid kernel functions over their respective spaces.

Equipped with these properties, we can now embark on the construction of more complex kernels appropriate to specific applications. We require that the kernel $k(\bold x,\bold x^{\prime})$ by symmetric and positive semidefinite and that it expresses the appropriate form of similarity between $\bold x$ and $\bold x^{\prime}$ according to the intended application.

The construction of kernels starts from a probabilistic generative model.