If $f:\Bbb R \to\Bbb R$ is continuous and $f^2$ is uniformly continuous, does that necessarily imply that $f$ is uniformly continuous

real-analysisuniform-continuity

Actually, by given criterion, if $\{x_n\}$ and $\{y_n\}$ be any two sequences such that $|x_n – y_n|$ goes to $0$, then $|f^2(x_n) – f^2(y_n)|$ also goes to $0$, now if $|f(x_n) + f(y_n)|$ is bounded, then f is also uniformly continuous.

But, I think it has a counter-example, I was thinking about a function $f(x)= \sqrt{\ln(1+x)} ; x\geq 0$, it can be shown by the mean value theorem that $f^2$ is uniformly continuous, but I can't think it about $f$.
One fact is obvious that as $f'$ is unbounded, then $f$ is not Lipschitz.

Best Answer

First, note that the composition of two uniformly continuous functions is uniformly continuous; and $g(x) = \sqrt{x}$ is uniformly continuous on $[0, \infty)$. Therefore, if $f^2$ is uniformly continuous, then $g \circ f^2 = |f|$ is also uniformly continuous.

It remains to show that $f$ continuous and $|f|$ uniformly continuous implies that $f$ is uniformly continuous. To see this, for $\epsilon > 0$ choose $\delta > 0$ such that $|x-y| < \delta$ implies $|\,|f(x)| - |f(y)|\,| < \frac{\epsilon}{2}$. Then whenever $|x-y| < \delta$, if $f(x)$ and $f(y)$ have the same sign, then $|f(x) - f(y)| = |\,|f(x)| - |f(y)|\,| < \frac{\epsilon}{2} < \epsilon$. On the other hand, if $f(x)$ and $f(y)$ have opposite signs, then by the intermediate value theorem there exists $z$ between $x$ and $y$ such that $f(z) = 0$. Then $|x-z| < \delta$ and $|z-y| < \delta$; so $$|f(x) - f(y)| \le |f(x) - f(z)| + |f(z) - f(y)| = \\ |\,|f(x)| - |f(z)|\,| + |\,|f(z)| - |f(y)|\,| < \frac{\epsilon}{2} + \frac{\epsilon}{2} = \epsilon.$$

Related Question