Diferentiable function $g$ with $f(x)\leq g(x) \leq h(x), \forall x$ Let $f,g,h:X \to \mathbb{R}$ that $f(x)\leq g(x)\leq h(x), \forall x \in X$. If $f,h$ are differentiable in $x_0 \in X\cap X'$, with $f(x_0)=h(x_0)$ and $f'(x_0)=h'(x_0)$, show that:
a. $g(x_0) = f(x_0)$
b. Exists $g'(x_0)$ and $g'(x_0)=f'(x_0)$
The first one is pretty obvious, but I can't solve the item b. . Any leads ?
 A: $$f(x)\leq g(x)\leq h(x)\Longrightarrow f(x)-f(x_0)\leq g(x)-g(x_0)\leq h(x)-h(x_0)$$ since $f(x_0)=g(x_0)=h(x_0)$.
If $x>x_0$, then $$\frac{f(x)-f(x_0)}{x-x_0}\leq \frac{g(x)-g(x_0)}{x-x_0}\leq\frac{h(x)-h(x_0)}{x-x_0}$$
so by the squeeze theorem, as $x\to x_0^+$, $$f'(x_0)\leq\lim\limits_{x\to x_0^+}\frac{g(x)-g(x_0)}{x-x_0}\leq h'(x_0)$$
If $x<x_0$, then $$\frac{f(x)-f(x_0)}{x-x_0}\geq \frac{g(x)-g(x_0)}{x-x_0}\geq\frac{h(x)-h(x_0)}{x-x_0}$$
so by the squeeze theorem again, as $x\to x_0^-$, we have $$f'(x_0)\geq\lim\limits_{x\to x_0^-}\frac{g(x)-g(x_0)}{x-x_0}\geq h'(x_0) $$
and it follows that $$\lim\limits_{x\to x_0^-}\frac{g(x)-g(x_0)}{x-x_0} = f'(x_0)=h'(x_0)=\lim\limits_{x\to x_0^+}\frac{g(x)-g(x_0)}{x-x_0}$$
hence $f'(x_0)=g'(x_0)=h'(x_0)$
A: Let us find if $g(x)$ is derivable at $x=x_0$.
For that we wish to know if the following limit exists: $$\lim_{k\to 0}\frac{g(x_0+k)-g(x_0)}{k}$$.
Now $g(x_0)=f(x_0)$ and $g(x_0+k)\geq f(x_0+k)$, therefore $$g(x_0+k)-g(x_0) \geq f(x_0+k)-f(x_0)$$
Similarly, $$g(x_0+k)-g(x_0)\leq h(x_0+k)-h(x_0)$$
Dividing both the inequalities by a positive number k would have no bearing on the nature of inequalities.
Therefore, dividing by k and combining both the inequalities, we get:
$$\frac{h(x_0+k)-h(x_0)}{k}\geq \frac {g(x_0+k)-g(x_0)}{k} \geq \frac {f(x_0+k)-f(x_0)}{k}$$
Taking $\lim k\to 0$, we get,$$h'(x_0) \geq \lim_{k\to 0}\frac {g(x_0+k)-g(x_0)}{k} \geq f'(x_0)$$.
Now if $f'(x_0)=h'(x_0)$, then $$\lim_{k\to 0} \frac {g(x_0+k)-g(x_0)}{k}=f'(x_0)$$
Since Right hand side of equality is not dependent on approach of k towards 0, therefore Left hand side of equality must converge for all the approaches of k towards 0.
Hence $\lim_{x\to x_0} g(x)$ exists, and is equal to $f'(x_0)$
