Rolle-like equality Let $f$ be a ${\cal C}^2$ function $[a,b] \to {\mathbb R}$, (i.e. the second derivative $f''$ is continuous). Let $g$ be the unique affine map agreeing with $f$ on $a$ and $b$ :
$$
g(x)=f(a)+(f(b)-f(a))\bigg(\frac{x-a}{b-a}\bigg)
$$
Prove or find a counterexample : for any $x\in ]a,b[$, there is a $\xi \in ]a,b[$ satisfying 
$$
f''(\xi)=2\frac{f(x)-g(x)}{(x-a)(x-b)}
$$
 A: The statement is indeed true. 
Let $h(x)=\frac{2(f(x)-g(x))}{(x-a)(x-b)}$. By the intermediate value theorem, it suffices to show $m \leq h(x) \leq M$, where $m$ and $M$ are the minimum and maximum of $f''$ respectively on $[a,b]$. Rescaling if necessary, we may assume that $a=0$ and $b=1$.
Now define a map $\phi : [0,1] \to {\mathbb R}$ by 
$$
\phi(t)=\left\lbrace
\begin{array}{lcl}
(1-x)t, &\text{if} & t \in [0,x] \\
(1-t)x, &\text{if} & t \in [x,1]
\end{array}\right.
$$
Then $\phi$ is continuous, positive, and the integral of $\phi$ equals $\frac{x(1-x)}{2}$. And
$$
\begin{array}{lcl}
\int_{0}^{x} \phi(t)f''(t) dt &=& (1-x)\int_{0}^{x} tf''(t) dt=(1-x)\big[tf'(t)-f(t)\big]^{x}_{0}=
(1-x)\big(xf'(x)-f(x)+f(0)\big) \\
\int_{x}^{1} \phi(t)f''(t) dt &=& x\int_{x}^{1} (1-t)f''(t) dt=x\big[(1-t)f'(t)+f(t)\big]^{1}_{x}=
x\big(-(1-x)f'(x)-f(x)+f(1)\big)
\end{array}
$$
We deduce
$$
\int_{0}^{1} \phi(t)f''(t) dt=(1-x)f(0)-f(x)+xf(1)=\frac{x(1-x)}{2}h(x)
$$
Since $-m \leq f'' \leq  M$, the left-hand side is between $m\frac{x(1-x)}{2}$ and $M\frac{x(1-x)}{2}$. So $m \leq h(x) \leq M$ as wished.
