# Can a continuous real valued function, differentiable everywhere but $x_0$, be expressed as $g(x)+h(x)|x-x_0|$ for some differentiable $g$ and $h$?

Let $$f:\mathbb R \rightarrow \mathbb R$$ be a continuous function and $$x_0 \in \mathbb R$$ such that f is differentiable on both intervals $$(-\infty, x_0]$$ and $$[x_0, +\infty)$$. Prove or disprove that there exist two functions $$g, h : \mathbb R \rightarrow \mathbb R$$ differentiable everywhere such that

$$f(x) = g(x) + h(x)|x - x_0|\ \ \forall x \in \mathbb R.$$

This feels like it characterizes every non-differentiable point of a continuous function in terms of absolute values but I couldn't come up with a function to disprove nor I was able to construct $$g$$ and $$h$$.

Help and directions appreciated.

• Note that there might be non-differentiable points where the one-sided limits do not exist, like in $\sqrt{|x|}$, or where the non-differentiable points accumulate somewhere. In both cases you won't have differentiability on $(x_0-\varepsilon,x_0]$ and $[x_0,x_0+\varepsilon)$, so it certainly doesn't characterize every non-differentiable point of a continuous function. Dec 8, 2018 at 7:32

Suppose $$\phi(x) = \begin{cases} ax, & x < 0 \\ bx, & x \ge 0 \end{cases}$$, note that we can write $$\phi(x) = {b-a \over 2} |x| + {a+b \over 2} x$$.
Let us consider the following two differentiable extensions of $$f$$: $$F_+(x) = \begin{cases} f(x), & x \ge x_0, \\ f(x_0)+f'_+(x_0)(x-x_0), & x \le x_0, \end{cases}$$ and $$F_-(x) = \begin{cases} f(x), & x \le x_0, \\ f(x_0)+f'_-(x_0)(x-x_0), & x \ge x_0. \end{cases}$$ Then $$F:=F_+ + F_-$$ is differentiable in $$\mathbb{R}$$ and $$F(x)-f(x)=f(x_0)+\begin{cases} f'_+(x_0)(x-x_0), & x \le x_0, \\ f'_-(x_0)(x-x_0), & x \ge x_0, \end{cases}$$ that is $$F(x)-f(x)=f(x_0)+f'_+(x_0)\cdot \frac{x-x_0 -|x-x_0|}{2} +f'_-(x_0)\cdot \frac{x-x_0 +|x-x_0|}{2}.$$ Can you take it from here?