# Is this a valid consequence of Dini's Theorem?

I have an increasing sequence of continuous functions $\{f_n\}_{n \in \mathbb{N}}$ such that $f_n : \mathbb{R} \to \mathbb{R}$ that converges pointwise to a limit $f: \mathbb{R} \to \mathbb{R}$.

Dini's Theorem says that for any compact subset $K \subset \mathbb{R}$, we have that $f_n$ converges uniformly to $f$ and therefore $f$ is continuous on $K$.

Does this imply that $f$ is continuous on all of $\mathbb{R}$? Can't I just say that for any point $x \in \mathbb{R}$, I can find a compact set $K$ around $x$ such that $f$ is continuous on $K$ and therefore continuous around $x$?

• No! Dini's theorem does not say what you say it says! (Yes, it's true that if $f:\Bbb R\to\Bbb R$ and $f|_K$ is continuous for every compact $K$ then $f$ is continuous. This is because $\Bbb R$ is locally compact.) – David C. Ullrich Sep 3 '18 at 18:54

It is one of the assumptions of Dini's theorem that the limit function $f$ is continuous. You can't use Dini's theorem to show that a monotone limit of continuous functions is continuous, because that is not true.
Counterexample: $$f_n(x)=\begin{cases} 0 & x\le 0 \\ x^n & 0<x<1\\ 1 & x\ge 1 \end{cases}$$
Non-sequitur. We must assume $f$ is continuous, then it is guaranteed the convergence is uniform.