# Uniform continuity of continuous periodic function

Defn: Let $f$ be a function from $\mathbb{R}$ into a set $X$. We say that $f$ is periodic if there exists $p>0$ such that for all $x\in \mathbb{R}$, we have $f(x+p)=f(x)$.

Prove: If $f$ is a continuous periodic function from $\mathbb{R}$ into a metric space $M$, then $f$ is uniformly continuous on $\mathbb{R}$.

Attempt: I think I can use the fact that for all $x \in \mathbb{R}$, $[x,x+p]$ is a closed and bounded interval. Then $f$ is compact and hence uniformly continuous on the interval.

I also tried considering $[0,p]$. In that case, $x = np+\alpha$ and $y = mp + \beta$ for some $m,p \in \mathbb{Z}$ and $\alpha,\beta \in \mathbb{R}$. If $n<0$, then we can choose $\alpha \in \mathbb{R^\mathbf{-}}$, so that $f(np+\alpha)=f(|\alpha|)$ and not $f(1-\alpha)$. Hope that makes sense.

Then $\alpha,\beta \in [0,p]$, and I can find a $\delta$ that works for all $\alpha, \beta$ in $[0,p]$. The problem is, I need to constrain $|x-y|$ and somehow get that $|\alpha-\beta| < \delta$. So far I haven't figured out how to do this.

Been furrowing my brow at this for a while.. any hints very welcomed...

Thanks

• Your basic intuition is correct: if $f$ is continuous on a compact set (e.g. a closed interval), then it is uniformly continuous on that set. Since $f$ is both continuous and periodic (of period $T$, for specificity), it is (in particular) uniformly continuous on any interval of length $T$. Suppose that you get a $\delta_1$ that works on the interval $[0,T]$ (thus also on $[kT,(k+1)T]$ for $k\in\mathbb{Z}$), and $\delta_2$ on the interval $[\frac{T}{2}, \frac{3T}{2}]$ (ditto). Then $\min\{\delta_1,\delta_2\}$ works on all of $\mathbb{R}$. (This may be overkill.) – Xander Henderson Sep 6 '17 at 1:54
• Suppose $|x-y|<\min\{\delta_1,\delta_2\}$. How can I show that $|f(x)-f(y)|<\epsilon$? I get that by using two intervals and two $\delta$s, we can avoid the problem of when $x<T$ and $y>T$, but I'm having trouble writing out the last steps – EternusVia Sep 6 '17 at 2:07
• If $|x-y| < \delta$ (where $\delta$ is this minimum), then you can assume WLOG (by further assuming that $\delta < T$) that both $x$ and $y$ are in an interval of the form $[kT, (k+1)T]$ or of the form $[\frac{T}{2}+kT, \frac{3T}{2}+(k+1)T]$, where $k\in\mathbb{Z}$. Then use uniform continuity on whichever interval you've landed in. – Xander Henderson Sep 6 '17 at 2:10
• Shoot... I knew what I meant, which was $[\frac{T}{2} + kT, \frac{T}{2} + (k+1)T]$ (or maybe I meant $[\frac{T}{2} + kT ,\frac{3T}{2} + kT]$, which is the same thing, really). – Xander Henderson Sep 6 '17 at 2:16
• Sure, that'll work---sorry, I'm not very good at details. But the fact that you can follow my error-prone computation seems to indicate that you have the idea. ;) – Xander Henderson Sep 6 '17 at 3:02

For $r>0$ let $s_r\in (0,p)$ such that $\forall x,y\in [0,2p]\;(|x-y|<s_r\implies |f(x)-f(y)|<r).$
For any $x,y\in \mathbb R$ with $|x-y|<s_r$ there exists $n\in \mathbb Z$ such that $\{x,y\}\subset [np, (n+2)p].$ Because if $n=\max \{m\in \mathbb Z: mp\leq \min (x,y)\}$ then $\min (x,y)<(n+1)p,$ so $$np\leq \min (x,y)\leq\max (x,y)<\min (x,y)+s_r<(n+1)p+s_r<(n+2)p .$$
Now $\{x-np,y-np\}\subset [0,2p]$ and $|(x-np)-(y-np)|=|x-y|<s_r.\;$ Therefore $$|f(x)-f(y)|=|f(x-np)-f(y-np)|<r.$$
your idea is to translate each point to the interval $[0,p]$ and hope that the translates are also close by. Better to translate both by the same multiple of p, so that the smaller one lands inside, and the larger one is still guaranteed not too far. So you consider the restriction of your function to [0, p+1]. hope you can continue from here.