# Can any analytic function be written as the difference of two monotonically increasing analytic functions?

This question is not a duplicate of this one or this one, since the solutions shown there contain jumps.

Let $$f(x)$$ be an analytic function on $$\mathbb{R}$$. We can take its Taylor series and group the terms with a positive coefficient in one function $$f_+(x)$$ and terms with a negative coefficient in a function $$f_-(x)$$. Then $$f(x) = f_+(x) - f_-(x)$$, both components are monotonically rising on $$\mathbb{R}_+$$, and both are analytic. However, at $$0$$ the components would have to swap to maintain monotonicity, creating a discontinuity. Can this be avoided?

For an easier question, consider specifically the case of $$f(x) = x^2$$. I can't even find a simple decomposition for this basic case. I'm not convinced it exists -- this is not homework, I have no idea which way the truth lies.

• "However, at $0$ the components would have to swap to maintain monotonicity, creating a discontinuity": Do you mean a discontinuity in some derivative? The functions themselves could be continuous, I think. For example, in $f (x) = x^2$, you could take $f_- (x) = \begin{cases} -x^2 & x \le 0 \\ 0 & x > 0 \end{cases}$ and $f_+ (x) = \begin{cases} 0 & x \le 0 \\ x^2 & x > 0 \end{cases}$ (of course, these are not analytic, but they are continuous and monotonic). Commented Aug 5 at 1:39
• $x^2 = (x^3 + x^2 + x) - (x^3 + x)$ Commented Aug 5 at 1:43

Define two new analytic functions $$g(x) = \int_0^x (1+f'(t)^2)\,dt \quad\text{and}\quad h(x) = g(x) + f(x).$$ Then certainly $$f(x) = h(x)-g(x)$$; and $$g'(x) = 1+f'(x)^2 > 0 \quad\text{and}\quad h'(x) = 1+f'(x)^2 + f'(x) = \tfrac34 + (f'(x)+\tfrac12)^2 > 0,$$ so both functions are increasing.
One way to solve this is to construct an increasing analytic function $$g$$ so that $$f+g$$ is also increasing. For that to hold, we need $$g'(x)\ge\max(0, -f'(x))$$.
Let $$g(x) = \int_0^x h\left(f'(t)\right)\,dt$$ where $$h$$ is an analytical function with $$h(u)>\max(0,-u)$$: eg $$h(u)=\sqrt{1+u^2}$$. This makes $$g$$ analytical and increasing, and $$f'(x)+g'(x)>0$$ so that $$f+g$$ is too.