Lecture 7
Lecture 7
Lecture 7
Lecture 7
Instructor: Quanquan Gu Date: September 14th
x2
f (x, y) = , y > 0.
y
f (x, y) is convex over R × (0, +∞). To show this, we first calculate the partial derivatives.
The first order partial derivatives are:
∂f (x, y) 2x ∂f (x, y) x2
= , = − 2.
∂x y ∂y y
Note that the matrix can be factorized as the outer product of two vectors, yielding
2 2 y
∇ f (x, y) = 3 (y, −x),
y −x
1
Example 2 (Log-sum-exponential Function) f : Rd → R is defined as follows
d
X
f (x) = log exp(xi ) . (1)
i=1
It is a convex function.
It is a concave function.
For convex function, we can show that its local minimum is also a global minimum. In
detail, the following theorem shows that, a local minimum of a convex function is also a
global minimum.
Proof: Since D is a convex set, for any y, y − x∗ is a feasible direction. Since x∗ is a local
minimum, for any y ∈ D, we can choose a small enough α > 0, such that
which implies that f (x∗ ) ≤ f (y). Since y is an arbitrary point in D, this immediately proves
that x∗ is a global minimum.
2
Proof: “⇒”
Since x∗ is a global minimum, x∗ must also be a local minimum. By the first order necessary
condition of a local minimum, we have ∇f (x∗ )> d ≥ 0 where d is a feasible direction. For
any x ∈ D, d = x − x∗ is a feasible direction. Then we obtain:
∇f (x∗ )> (x − x∗ ) ≥ 0
“⇐”
By definition, we have that:
Thus, if ∇f (x∗ )> (x − x∗ ) ≥ 0, then f (x) − f (x∗ ) ≥ ∇f (x∗ )> (x − x∗ ) ≥ 0, which means x∗
is a global minimum of f over D.
In the following, we will show another way to prove that a function is convex. First of
all, let’s introduce the restriction of a function to a line.
Let f : Rd → R be a function. The restriction of f to a line x + tv is defined as
g : R → R : g(t) = f (x + tv), where dom(g) = {t : x + tv ∈ dom(f )}.
where the last equality follows by the definition of g(t). Thus, by definition, g(t) is convex.
3
Let v = y − x, and consider g(t) = f (x + t(y − x)). It is easy to verify that g(0) = f (x),
g(1) = f (y), and g(1 − α) = f (αx + (1 − α)y). We then have
Theorem 3 basically suggests that a function is convex if and only if the restriction of this
function to any lines is convex. It enables us to check convexity of f by checking convexity
of functions of one variable.