Questions / Quant research, Machine learning judgment

A symmetric similarity need not be a kernel

Challenge, about 10 minutes. Question R146.

A proposed kernel produces the Gram matrix K=[[1,2],[2,1]] on two inputs. For coefficient vector v=(1,−1), what is vᵀKv?

Answer it in the app It's free. You get hints, a second try if you miss, and a follow-up question.

Show the answer and worked solution

Answer: -2 quadratic-form units

  1. Kv=(−1,1), so vᵀKv=−1−1=−2. This negative value proves that K is not positive semidefinite, despite being symmetric and having positive diagonal entries.

Interview shortcut. Quadratic form: vᵀKv = 1 + 1 − 2 × 2.

In the app this has a follow-up where one thing about the setup changes. Try the follow-up.

More machine learning judgment questions