How to show $f\left(\frac{1}{2}\right) \le \frac{M}{4} + \int_0^1 f(x)\, dx$ Let $f$ be a differentiable function such that $f'(x)$ is continuous and $|f'(x)| \le M$ for all $x \in [0,1]$. Show that
\begin{align}
f\left(\frac{1}{2}\right) \le \frac{M}{4} + \int_0^1 f(x)\, dx
\end{align}
I have no idea how to begin proving this. I think Fundamental Theorem of Calculus will be used somewhere in the proof, but I can't see how that can be related to $f'(x)$. Any help is appreciated; thanks in advance!
 A: Let $f$ be as in the hypothesis. We know that $|f'|\leq M$. Therefore, it follows that for $x,s\in[0,1]$ with $s>x$
$$
-(s-x)M \leq \int_{x}^{s}f'(t) dx \leq (s-x)M.
$$
Indeed, by the Fundamental Theorem of Calculus, and by letting $s=\frac{1}{2}$, we find that
$$
f\left(\frac{1}{2}\right) - f(x) \leq \left(\frac{1}{2}-x\right)M. \tag{1}
$$
Integrating again over $[0,1/2]$ with respect to $x$, we find that
$$
\int_{0}^{1/2}f\left(\frac{1}{2}\right)dx \leq M\int_{0}^{1/2} \left(\frac{1}{2}-x\right) dx + \int_{0}^{1/2} f(x) dx
$$
Simplifying, we end up with
$$
\frac{1}{2}f\left(\frac{1}{2}\right) \leq M \left(\frac{x}{2}-\frac{x^2}{2}\right)_{x=0}^{x=1/2} + \int_{0}^{1/2} f(x) dx
$$
and in particular, that
$$
\frac{1}{2}f\left(\frac{1}{2}\right) \leq \frac{M}{8} + \int_{0}^{1/2} f(x) dx.
$$
Similarly, now instead integrating (1) over $[1/2,1]$, we have
$$
\frac{1}{2}f\left(\frac{1}{2}\right) \leq \frac{M}{8} + \int_{1/2}^{1} f(x) dx.
$$
Adding these two together gives you the desired result. In particular, we find that
$$\begin{align}
f\left(\frac{1}{2}\right) &= \frac{1}{2}f\left(\frac{1}{2}\right) + \frac{1}{2} f\left(\frac{1}{2}\right) \\
&\leq \frac{M}{8} + \frac{M}{8} + \int_{0}^{1/2} f(x) dx + \int_{1/2}^{1} f(x) dx \\
&= \frac{M}{4} + \int_{0}^{1} f(x) dx.
\end{align}
$$
A: According to the mean-value theorem you have $$f(1/2) - f(x) \le |f(1/2) - f(x)| \le M |1/2-x|$$ for all $x \in [0,1]$ so that $$f(1/2) \le M|1/2 - x| + f(x)$$ for all $x \in [0,1]$.  Now integrate from $[0,1]$:
$$f(1/2) \le M \int_0^1 |1/2 - x| \, dx + \int_0^1 f(x) \, dx.$$
The easiest way to see that $\int_0^1 |1/2 - x| \, dx = 1/4$ is to consider the area under its graph.
A: First notice that $f(\frac{1}{2})=\int_{0}^{1}f(\frac{1}{2})\,dx$.
Also by the mean-value-theorem (of integration), $f(x)=f(\frac{1}{2})+(x-\frac{1}{2})f'(\xi(x))$ where $\xi(x)$ is between $x$ and $\frac{1}{2}$, for all $x\in[0,1]$ (notice this holds even for $x=\frac{1}{2}$).
Therefore,
$\begin{align*}
f(\frac{1}{2})-\int_{0}^{1}f(x)\,dx
& =\int_{0}^{1}f(\frac{1}{2})-f(x)\,dx \\
& =-\int_{0}^{1}(x-\frac{1}{2})f'(\xi(x))\,dx \\
&\leq \int_0^1 |x-\frac12| |f'(\xi(x))| \, dx \\
& \leq M\left(\int_{0}^{\frac{1}{2}}(\frac{1}{2}-x)\,dx + \int_{\frac{1}{2}}^{1}(x-\frac{1}{2})\,dx\right) \\
& =\frac{M}{4}
\end{align*}$
as was to be shown.
