Uniform Continuity between $f$ and $|f|$

64 Views Asked by At

$f$ is a continuous function on $\mathbb{R}$,if $|f|$ is uniformly continuous on $\mathbb{R}$, then how about the uniform continuity of $f$?

I know that if $f$ is uniformly continuous, then $|f|$ is uniformly continuous since the triangle inequation. And I try to find the counterexample, but I find that the difference between the $f$ and $|f|$ should be the inverse of the sign when the interval is rather small. But the inversion of the sign means that both $f$ and $|f|$ should go to zero and some big numbers (larger than $\epsilon$), but that makes $|f|$ difficult to be uniformly continuous. How should I continue? Thanks a lot in advance.

2

There are 2 best solutions below

3
On BEST ANSWER

This should also be true, for interval-based domains. Take some $f:\Bbb R\to\Bbb R$ such that $|f|$ is uniformly continuous. I'd be interested to know if this holds with the domain replaced by a general metric space. I think it should work for spaces that are somehow "uniformly" locally connected or more simply for metric spaces whose balls are all connected.

Fix $\epsilon>0$. There is $\delta>0$ such that if $x,y$ have $|x-y|<\delta$ then $||f(x)|-|f(y)||<\frac{1}{2}\epsilon$.

Let $(x,y)$ be an arbitrary pair of real numbers, $|x-y|<\delta$. If $f(x),f(y)$ have the same sign (allowing $0$ to take either sign), then the bound on $|f|=\pm f$ shows: $$|f(x)-f(y)|=||f(x)|-|f(y)||<\frac{1}{2}\epsilon<\epsilon$$Will hold. If $f(x),f(y)$ have a different sign then there is maybe a problem... but by continuity and connectedness of $\Bbb R$ there exists some $a$ inbetween $x,y$ with $f(a)=0$.

Then: $$|f(x)-f(y)|\le|f(x)-f(a)|+|f(y)-f(a)|=||f(x)|-|f(a)||+||f(y)|-|f(a)||<\epsilon$$Since $|x-a|$ and $|y-a|$ are both $<\delta$.

Note continuity of $f$ was used here. Without that it’s certainly false that uniform continuity of $|f|$ implies (uniform) continuity of $f$; consider $f:=\chi_{\Bbb Q}-\chi_{\Bbb R\setminus\Bbb Q}:\Bbb R\to\Bbb R$. This is nowhere continuous (never mind uniformly!) yet $|f|$, which is constant, is certainly uniformly continuous.

3
On

Just adding to the nice answer by FShrike, this is not true for a general metric space. Consider the subspace of $\mathbb{R}$

$$S=\left\{\frac{1}{n}\bigg|n\in\mathbb{N}\right\}$$

And define

\begin{align} f : S&\to \mathbb{R} \\ \frac{1}{n} &\mapsto (-1)^n \end{align}

Then $f$ is clearly continuous since every point in $S$ is isolated, and $|f|$ is uniformly continuous since it is constant, but $f$ is not uniformly continuous.