# kernel for a (semi-) metric space

Let's say I have a metric space $(\mathcal{X}, d)$. Is there any kernel function that I can use with SVM?

If we change the RBF kernel a little bit, we have $k(x,y) = e^{-d(x,y)^2}$. Is this a valid kernel?

Additionally, what if $d$ is semi-metric?

• stats.stackexchange.com/q/64126/9964 is very related. One condition for the generalized RBF being a psd kernel is that $d$ needs to be isometrically embeddable in $L_2$. – Danica Jun 4 '15 at 2:13

## 1 Answer

See Schoenberg's theorem http://djalil.chafai.net/blog/2013/02/09/a-probabilistic-proof-of-the-schoenberg-theorem/ $K_t(x,y)=\exp(-td(x,y))$ is a positive definite symmetric kernel for all $t>0$ iff $d$ is negative definite symmetric.

• I don't see how Schoenberg's theorem answers my question. Can you elaborate? – Weipeng He Mar 3 '15 at 12:05
• You have a metric $d$. Does $d^2$ satisfy the axioms of a negative definite symmetric kernel? If yes, then $k(x,y)=e^{-d(x,y)^2}$ is a "valid" (i.e., positive definite symmetric) kernel. Otherwise, no. – Aryeh Mar 4 '15 at 21:00