Demonstrate using first-order conditions

38 Views Asked by At

A quadratic function of the form function $ f:\mathbb{R}^n\rightarrow \mathbb{R} $ , given by $ f(x)=(1/2)x^T P x + q^T x + r$, where $P\succeq 0$ and $x, q \in \mathbb{R}^n$ and $r \in\mathbb{R}$. How can I demonstrate that it is convex using first-order conditions?

My attempt:

In S.Boyd's lecture:

  1. First-order: f is convex if $f(y)\geq f(x)+\nabla f(x)^T(y-x)$

Then,

$$ f(y)\geq (1/2)x^T P x + q^T x + r+ (Px+q)^T(y-x) $$

How do I simplify? Does anyone have any ideas?

2

There are 2 best solutions below

1
On BEST ANSWER

\begin{align} f(y) - f(x) - \nabla f(x)(y-x) &= \frac12 y^TPy + q^Ty + r - \left(\frac12 x^TPx + q^Tx + r\right) - \left(Px + q\right)^T(y-x)\\ &= \frac12y^TPy + q^Ty + r - \frac12x^TPx - q^Tx - r - x^TPy + x^TPx - q^Ty + q^Tx\\ &= \frac12\left(y^TPy - 2x^TPy + x^TPx\right)\\ &= \frac12 (y-x)^TP(y-x)\ge 0 \end{align}

0
On

\begin{align} f(y) &\ge f(x) + \nabla f(x)^\top (y-x) \\ \frac{1}{2} y^\top P y + q^\top y + r &\ge \frac{1}{2} x^\top P x + q^\top x + r + (Px+q)^\top (y-x). \end{align}

If you cancel terms and rearrange, you will eventually get $(y-x)^\top P (y-x) \ge 0$ which you can justify using a given property of $P$.