TITLE: What can be said about the set of points that makes the MVT "works"?
QUESTION [7 upvotes]: Consider a (real-valued) function $f$ that is differentiable on an open interval $I$ of $\mathbb R$. 
For $a\neq b$ in $\mathbb R$, we consider $S_{a,b}=\left\{ x\in I\; \middle|\; f'(x)=\frac{f(b)-f(a)}{b-a}\;  \right\}$. $S_{a,b}$ is non empty by the Mean Value Theorem.
Let now $\displaystyle S=\bigcup_{a\neq b \in I}S_{a,b}$
What can be said about $S$? 
Has this set been studied before? Is $S$ an interval? Is $S$ open? 
Clearly, $S$ is a subset of $I$ but the inclusion can be strict. For example, if $f(x)=x^3$, we have $0\notin S$.  This example also shows that $S$ is not always an interval.
Note: feel free to add conditions on $f$ if it allows $S$ to have nice properties.

REPLY [2 votes]: For any $y$ define
$$g_y(x) = f(x) - f'(y) (x-y).$$
Clearly $g_y'(y) = 0$, so

either $y$ is a local extremum, and in this case clearly $y \in S$. 
or $y$ is not an extremum, which is equivalent to $g_y'$ (and so also f') having an strict extremum at $y$ (i.e., as @edm showed, $f$ is strictly concave or strictly convex at that point).

This means that $\{x: f' \, \text{does not have a strict extremum at } x\} \subset S$. The other inclusion is not true: take for example $f = e^{x^2} \sin (x)$, where $S = \mathbb R$, but $f''$ vanishes in many places.