# Mean value theorem for convex functions

Let $f$ be a real function with left and right derivatives $f'_-$ and $f'_+$ on the open interval $(a,b)$, and continuous on $[a,b]$ (e.g., let $f$ be convex on $[a,b]$). Then,

Is there something like the mean value theorem for $f$?

• If $f:[a,b]\to\mathbb{R}$ is a convex function let \begin{equation*} \partial f(x)=\left\{p\in\mathbb{R}\bigm\vert f(y)\ge f(x)+p(y-x)\right\}. \end{equation*} We refer to this as the subdifferential of $f$. Now suppose, in addition to the above, that we know $f(a)=0=f(b)$ and that $f$ is continuous. Then I claim there is $c\in(a,b)$ so that \begin{equation*} 0\in\partial f(c). \end{equation*} – user71352 Mar 9 '17 at 5:41
• To see this, note that we may assume that $f$ is non-constant. Then by extreme value theorem a minimum is obtained somewhere on $[a,b]$. By the previous assumption it occurs at $c\in(a,b)$. It follows by definition that $0\in\partial f(c)$. To conclude a mean value theorem note that \begin{equation*} g(x)=f(x)-\left[\frac{f(b)-f(a)}{b-a}(x-a)+f(a)\right] \end{equation*} is convex, satisfies $g(a)=0=g(b)$, and $\partial v(x)=\partial f(x)-\frac{f(b)-f(a)}{b-a}$. – user71352 Mar 9 '17 at 5:41
• I think if $f$ is convex then there exits a $c$ in $(a,b)$ such that $f'_-(c)\leq \frac{f(b)-f(a)}{b-a}\leq f'_+(c)$, is it true? Now, what can we say about the original case? – M.H.Hooshmand Mar 9 '17 at 7:17
• I believe this statement about convex functions follows from my previous comments and the notion of the subdifferential. Observe that $p\in\partial f(c)$ means that for $y<x$ we have \begin{equation*} \frac{f(y)-f(x)}{y-x}\le p \end{equation*} and so taking limits gives $f_{-}'(c)\le p$. A similar conclusion follows for $f_{+}'(c)$. Were you trying to prove a similar statement for the original case? – user71352 Mar 9 '17 at 15:29
• I think the result you mentioned is valid after a slight modification. The proof follows from a reduction to Rolle's Theorem. The statement I'm thinking of is: Let $f:[a,b]\to\mathbb{R}$ be a continuous function. Suppose that the right and left derivatives, $f_{+}'(x),f_{-}'(x)$ exist everywhere on (a,b). Then there is $c\in(a,b)$ so that the following inequality holds: \begin{equation*} \min\left\{f_{-}'(c),f_{+}'(c)\right\}\le\frac{f(b)-f(a)}{b-a}\le\max\left\{f_{-}'(c),f_{+}'(c)\right\}. \end{equation*} – user71352 Mar 9 '17 at 17:07

For locally Lipschitz functions $f$ there is a notion of generalised gradient $\partial f$ that you can view as a generalisation of the subdifferential in convex analysis. The (generalised) mean value theorem then states that there is some $t \in (a,b)$ such that ${f(b)-f(a) \over b-a } \in \partial f (a + t(b-a))$.
As an example, take $f(x) = |x|$, $a=-1, b=1$, then $\partial f(x) = \begin{cases} \{-1\}, & x <0 \\ [-1,1], & x = 0 \\ \{1\}, & x > 0 \end{cases}$, so we see that ${|1|-|-1| \over 1 - (-1) } = 0 \in \partial f(0) = [-1,1]$.