1

In my notebook I have 2 consecutive exercises where the second one uses the result from the first one. The first one is the following:

(Ex1) Suppose that $f\in C^2(a,b)$ and $f\in C^1([a,b])$. Show that if $f{''}(x)\geq 0$ on $[a,b]$ then $f$ is convex on $[a,b]$.

And the second exercise is the following:

(Ex2) Using the result from the previous exercise, show that $t\to |t|^p$ is convex on $\mathbb{R}$ for all $p\in [1,\infty)$.

The following is the answer to the second exercise (assume without the proof that Ex1 is correct):

For $t\geq 0$ we have $f(t):=|t|^q=t^q$. This is twice differentiable, with $f^{''}(t)=q(q-1)t^{q-2}\geq 0$ on $[,\infty)$, so $f$ is convex on $[0,\infty)$. A similar argument shows that $f$ is convex on $(-\infty,0]$

This is what I did, and I thought that this was enough to prove that $f$ is convex. But the answer continues with the following:

So it only remains to check the required convexity inequality if $x<0$ and $y>0$, and then using convexity on $[0,\infty)$,

$$|tx+(1-t)y|q\leq |t|x|+(q-t)|y||^q\leq t|x|^q+(1-t)|y|^q$$

I'm not sure first of all, why is this needed. I am aware of the definition of a convex function, which is if $f(tx+(1-t)y)\leq tf(x)+(1-t)f(y)$ for all $t\in (0,1)$. Why would we show this if from exercise 1 we proved that if the function has the above stated properties, then it is convex?

  • 1
    As a personal note, I think it would have been more elegant to just compute the derivative of $\lvert t\rvert^q$ (which is differentiable as soon $q>1$) and then show that the derivative is increasing. $q=1$ nobody has problems. The second derivative test runs into the issue that $\lvert t\rvert^q$ is twice differentiable at $0$ if and only if $q\ge2$, leaving out the non-obvious case $q\in (1,2)$. –  Jun 21 '21 at 10:42

1 Answers1

1

With this question, it is good to think about what exactly convexity means. Geometrically, it means that you can connect any two points in the upper half space of the function with a straight line that is contained in this upper half space.

Recall that you only proved convexity in each half real space, but have not yet proved convexity throughout the whole of the real line.

Note that if we define a function by $$ \begin{align} f(x) = \begin{cases} x-1 & x > 1 \\ 0 & -1<x<1 \\ x+1 & x < -1 \end{cases} \end{align} $$ then is it clearly convex in each piecewise continuously differentiable segment of $f$, although it is not convex on the whole real line, since say we cannot connect the points $(-2,-1)$ and $(2,1)$ without also crossing below the line representing the function, see image attached.

This is precisely the behaviour you want to check does not happen with your function, and so you must make sure that you can draw a line from $x<0$ to $x>0$ without cross the function line.

enter image description here

spaceman
  • 796