# Proving differentiability by using Caratheodory's Lemma

Let $I$ be an open interval and let $c\in I$. Let $f:I\rightarrow\mathbb{R}$ be continuous and define $g:I\rightarrow\mathbb{R}$ by $g(x)=\left|f(x)\right|$.

Prove that if $g$ is differentiable at $c$, then $f$ is also differentiable at $c$.

Hint was to use Caratheodory's Lemma. I have tried by separating the three cases: $f(c)>0$ , $f(c)<0$ and $f(c)=0$.

1. For $f(c)>0$, I used the continuity of $f$ at $c$ to show that there is a neighborhood $J\subset I$ of $c$ such that $f_{/J}>0$.
Thus, able to prove that for $f'(c)=\lim_{x\to c} \frac{f(x)-f(c)}{x-c},$ the limit exist, hence $f$ differentiable.

2. Use same argument if $f(c)<0$.

3. For $f(c)=0$, I am stuck as I am not able show that $\phi(x)\to 0$ (as $x\to c$), i.e $g'(c)=0$.

Can someone help me with the last case?

• If $f(c)=0$ then $g$ attains local minimum at $c$ hence $g'(c)=0.$ – user110661 Sep 3 '14 at 8:35
• @FisiaiLusia so after showing that $\phi(x)\to 0$ (as $x\to c$), how to next prove that $f$ is differentiable when $f(c)=0$ – Joash Sep 3 '14 at 9:15

First of all, notice that $$f(x) = \operatorname{sign}(f(x))|f(x)|.$$ If $f(c)=0$, then $x=c$ is an absolute minimum point of $g$, and therefore $g'(c)=0$. Hence $g(x) = \omega(x)(x-c)$ with $\omega(0)=0$ and $\omega$ a continuous function. Now $$f(x) = \operatorname{sign}(f(x))|f(x)| = \operatorname{sign}(f(x))g(x) = \operatorname{sign}(f(x))\omega(x)(x-c),$$ and remark that $x \mapsto \operatorname{sign}(f(x))\omega(x)$ is continuous at $x=c$ because $\omega(c)=0$.