lec05
Lecture 5. Convex Functions
5.1 Definition
We now introduce convex functions. For convenience, use
Let
- the domain
is convex; satisfies the Jensen’s inequality, i.e., for all and , it holds that
The function
Geometrically, the line segment between

Let
- the domain
is convex; satisfies the strict Jensen’s inequality, i.e., for all and , it holds that
The function
Note that an affine function
Let
Why? Suppose there exists
Why these functions are called convex? Someone may think their graphs are somehow concave. Actually, what we concern is the area above the graphs of convex functions.
Given a real-valued function
- the graph of
is defined as - the epigraph of
is defined by - the hypograph of
is defined by
Let
- "
". Given any and , since is convex, and both and in , then which implies that and Thus is convex and the Jensen’s inequality holds. - "
". Given where and , and , let By the convexity of , . By the definition of , Then, , which means is convex.
- (Univariate functions)
where , and where are all strictly convex. (Or we say and are convex over , and is convex over .) - (Norm functions) Any norm
is a convex function, but can not be strictly convex (e.g., -norm, not strictly convex by absolute homogeneity).
Why do we consider convex functions? One of the most important properties of convex functions is that local minimum points must be global minimum.
If
Assume not. Then there exists
Extended-value functions
Suppose the domain of function
Note that the extended-value function of a convex function is still convex, since the epigraph remains the same.
Generalization of the Jensen’s inequality
It is easy to show the following generalization of Jensen’s inequality by induction.
Suppose
Intuitively we can generalize the inequality to the convex combination of infinite many variables. We actually have the following generalized form of the Jensen’s inequality but we should note that the proof of it is nontrivial since we cannot use induction!
Let
5.2 Properties and conditions of convexity
Midpoint convexity
Now we would like to proof that
We verify the Jensen's inequality:
Technically we cannot use the weighted AM-GM inequality here, since the weighted version is usually proved by the Jensen's inequality and concavity of the logarithm, which is what we want to show!
We say a function
If
Prove by contradiction. Assume
Now let
There exists midpoint convex but not convex functions if we admit the axiom of choice. Such a function would have to be non-measurable.
Now we use this theorem to verify a more complicated example:
We admit the fact that
If
Combining all of above, we conclude that
Zeroth order condition
We now consider some properties of convexity. Conversely, these properties also provide some criteria to verify convexity.
Let
Suppose
- "
". Assume is convex. Fix . For any , let . It suffices to show that , (i) ; (ii) .
Let . Since , . Thus, , which indicates that . Furthermore, - "
". Given , let and . Since is convex and , we have that , . Thus . Moreover, , which implies that is convex.
First order condition
If
Suppose
The first order condition shows that convex functions have linear lower bounds.

We usually use
if and ; .
- "
". Fix any . Let . By the Jensen's inequality, Rearranging it, we have Recall that . Taking the limits on both sides, we have - "
". For all and , let . The first-order condition gives that Then immediately implies that .
- In particular, if
, then for all . If is further strictly convex, is the unique global minimum point. - Given
, is a supporting hyperplane of at .
The first order condition also holds for the strict convexity if applying strict inequality. For the proof for strict convexity, the
Suppose
Let
Applying Jensen inequality (writing
An important corollary of the first order condition is the property of monotone gradient.
Let
- "
". When is convex, for all , by the first order condition, Then, Thus we obtain the monotone gradient. - "
". When is monotone, for all , define the function . Then For , by elementary calculation Note that . Then This means, we can assume the dimension . For all (without loss of generality, assuming ), by the mean value theorem, there exists such that Since , we have , which leads to the first order condition .
Second order condition
The property of monotone gradients indicates that the second order derivative is somehow nonnegative. Assume
Suppose
Furthermore, if
is strictly concave over , since and . is strictly convex for all , since . is convex over for or , and concave otherwise.- The log-sum-exp function
is convex over . (Exercise. Hint: , , , so , where and , thus )
- "
". For any , we define , where . Hence . By the first order condition, for all , which implies by the second-order condition for optimality. So we have . - "
". Given two arbitrary points , let , and . Applying Taylor series with Lagrange remainder to , there exists such that Since, for all , it follows that Therefore, is convex by the first order condition.
For strict convexity, we can replace
Consider the function
Similarly, consider the function
However, for a series of special functions, the equivalent relation of strict convexity holds. Consider quadratic functions,
is convex iff . It can be implied by the above theorem. is strictly convex iff . The " " direction is easy to verify. So we only need to prove the " " direction. Note that Since is strictly convex, we have for all (applying the first order condition). That is, , which implies that .
The following figures show the different convexity of

- The first one is strict convex since
. - The second one is convex since
. - The third one is not convex since
.