Contents:
Quadratic function and its gradient \(f(x) = \frac{1}{2} x^T P x + \langle q, x \rangle + r\)