# In mean value theorem, does the mean value vary continuously?

Let $f\colon\mathbb R\to\mathbb R$ be continuously differentiable and let's say, for simplicity, that $f(0)=0$. Then by mean value theorem it's $$f(x)=f'(\xi)\cdot x \,\text{ for some } \xi \in (0, x)$$

What I wondered is: What can we tell about the $\xi$ as we change $x$? My intuition says we should at least be able to find some $\xi\equiv \xi(x)$ that varies continuously with respect to $x$.

Or isn't this necessarily the case? Thanks for any ideas.

No. Here is a counterexample: Choose $f$ such that $$f'(x)=\begin{cases} 2x-2 & x \le 1 \\ 0 & 1 \le x \le 2 \\ 2x-4 & x\ge 2\end{cases}$$ so $$f(x)=\begin{cases} x^2-2x & x\le 1 \\ -1 & 1\le x \le 2 \\ x^2-4x+3 & x\ge 2\end{cases}$$ Then $f(3)=0$, and for $0<x<3$, $f(x)<0$, and $\xi$ has to be chosen to be $\le 1$, and for $x>3$, $f(x)>0$, so $\xi\ge 2$ for these $x$.
• What makes the counterexample work is that $f'(\xi)=0$ for some $\xi$. Now what if we exclude this and assume that $f'(\xi)\neq0$ for all $\xi$? Commented Dec 8, 2015 at 9:26
• @OskarLimka, if $f'(\xi)\neq0$ for all $\xi$ you can apply the implicit function theorem. It guarantees the existence of a function which is at least locally continuous. Commented Nov 14, 2021 at 22:51
• @Philipp thanks, that's what I thought, I was trying to stimulate a positive response to the OP, i.e., adding conditions that will make their conclusion correct. My hunch is that if $f$ is analytic (i.e., expressible as a convergent power series on some open interval containing 0) then we can continuously track $\xi$ as a (possibly multivalued) function of $x$. (I would start with a polynomial $f$.) Commented Nov 19, 2021 at 15:12