# What kernel function (if one exists) is equivalent to adding a feature vector x1^2 + x2^2

Suppose I have a 2d feature set {$\bf x_1, x_2$}. I can create a third feature $\bf x_3 = {x_1}^2 + {x_2}^2$ and train a model on all three features. Is there a kernel function for this transformation?

This is not a standard kernel function, but you can easily make it: $$\kappa(\mathbf{u},\mathbf{v}) = u_1v_1 + u_2v_2 + (\mathbf{u}^T\mathbf{u}) (\mathbf{v}^T\mathbf{v}) = \varphi(\mathbf{u})^T \varphi(\mathbf{v})$$ with $\varphi(\mathbf{x}): \mathbb{R}^2 \mapsto \mathbb{R}^3 = [x_1, x_2, x_1^2 + x_2^2]^T$.