Continuous functions uniformly convergent to a function, metric spaces, equivalent conditions

Let $X, \ (Y, d)$ be metric spaces, $f_1, f_2, \ldots \ : X \rightarrow Y$ be continuous functions, $f: X \rightarrow Y$ an arbitrary function. Prove that the following condtions are equivalent:

1) For any compact set $K \subset X$ functions $f_n$ converge uniformly (with metric $d$) on the set $K$ to $f$.

2) Function $f$ is continuous and $\lim _{n \rightarrow \infty} x_n = x \Rightarrow \lim _{n \rightarrow \infty} f_n(x_n) = f(x)$.

I remember I've once solved a seemingly similar problem:

If $f$ is a nondecreasing function on [0,1], then there exists a sequence of continuous functions ${f_n}$ on $[0,1]$ such that for each $x \in [0,1] \ \ \lim _{n \rightarrow \infty} f_n(x) = f(x)$.

Can I somehow use it here?

Could you help me with this problem?

Thank you.

• In (2), did you mean to say $f_n(x_n)$? Also, I don't think your "similar" problem is going to be helpful here, as there is nothing to play the role of "nondecreasing". Apr 22 '13 at 16:40
• Yes, I did. Sorry. Apr 22 '13 at 16:42
• From the one dimensional case one knows that the function $f$ is continuous. Can you generalize this result to metric spaces? The second condition in 2) is stronger than pointwise convergence. What have you tried so far for the uniform convergence? Apr 22 '13 at 16:47
• I thought Dini's theorem might be useful here, but when I realized it's not (the sequence is neither increasind nor decreasing), I posted this question here. And I've tried nothing since. I've read that if a sequence of functions is uniformly convergent, then it is compactly convergent. Apr 22 '13 at 16:59

HINT for 1)$\Rightarrow$2): Use $K:=\{x_n\mid n\in\mathbb N\}\cup \{x\}$ as compact set and a typiclal $\frac\epsilon3$ proof.

• Could you tell me why $K$ is compact? And how exactly can I use $\frac{\epsilon}{3} here$? Apr 22 '13 at 17:27
• Each convergent sequence is compact, because each open neigborhood of its limit contains all but finitely many elements of the sequence. Apr 23 '13 at 2:22

It seems that the following is the proof.

2) $\Rightarrow$ 1). Suppose that there is a compact subset $K$ of $X$ such that the sequence $f_n|K$ does not converge uniformly to $f|K$. Therefore there are a number $\varepsilon>0$, a strictly monotone sequence $\{m_k\}$ of positive integer numbers and a sequence $\{x_{m_k}\}$ of points of $K$ such that $d(f_{m_k}(x_{m_k}),f(x_{m_k}))>\varepsilon$ for each $k$. Since $K$ is compact, the sequence $\{x_{m_k}\}$ has a subsequence $\{x_{n_k}\}$ convergent to a some point $x\in K$. For each $n$ put $x_n=x_{k(n)}$, where $k(n)=\min\{n_k:n_k\ge n\}$. Then the sequence $\{x_n\}$ coverges to the point $x$ too. Therefore the sequence $\{f(x_n)\}$ converges to the point $f(x)$. Since the function $f$ is continuous at the point $x$, there is a neighborhood $U$ of $x$ such that $d(f(y),f(x))<\varepsilon/2$ for each point $y\in U$. Since the sequence $\{f(x_n)\}$ converges to the point $f(x)$, there is a number $N$ such that $d(f(x_n),f(x))<\varepsilon/2$ for each $n>N$. Since the sequence $\{x_{n_k}\}$ converges to the point $x$, there is a number $n_k>N$ such that $x_{n_k}\in U$. Then $\varepsilon=\varepsilon/2+\varepsilon/2>$ $d(f_{n_k}(x_{n_k}),f(x))+d(f(x),f(x_{n_k}))\ge d(f_{n_k}(x_{n_k}),f(x_{n_k}))>\varepsilon,$ a contradiction.

1) $\Rightarrow$ 2). Suppose that the function $f$ is discontinuous at some point $x\in X$. Then there are a number $\varepsilon>0$ and a sequence $\{x_n\}$ of points of $X$, convergent to $x$ such that $d(f(x_n),f(x))>\varepsilon$ for each $n$. Put $K=\{x\}\cup \{x_n\}$. Since each open neighborhood of the point $x$ contains all but finitely many elements of the sequence $\{x_n\}$, we see that the set $K$ is compact. Therefore the sequence $f_n|K$ converges uniformly to $f|K$. Thus there is a number $M$ such that $d(f_m(y), f(y))<\varepsilon/3$ for each $m>M$ and $y\in K$. Put $m=M+1$. Since the function $f_m$ is continuous at the point $x$, there is a neighborhood $U$ of $x$ such that $d(f_m(y),f_m(x))<\varepsilon/3$ for each point $y\in U$. Since the sequence $\{x_n\}$ converges to $x$, there is a number $n$ such that $x_n\in U$. Then $\varepsilon=\varepsilon/3+\varepsilon/3+\varepsilon/3>$ $d(f(x_n),f_m(x_n))+d(f_m(x_n),f_m(x))+d(f_m(x),f(x))\ge d(f(x_n),f(x))>\varepsilon$, a contradiction.

Let $\{x_n\}$ be a sequence of points of $X$, convergent to a point $x\in X$ and $\varepsilon>0$ be an arbitrary number. Put $K=\{x\}\cup \{x_n\}$. Then $K$ is compact. Therefore the sequence $f_n|K$ converges uniformly to $f|K$. Thus there is a number $M$ such that $d(f_m(y), f(y))<\varepsilon/2$ for each $m>M$ and $y\in K$. Since the function $f$ is continuous at the point $x$, there is a neighborhood $U$ of $x$ such that $d(f(y),f(x))<\varepsilon/2$ for each point $y\in U$. Since the sequence $\{x_n\}$ converges to $x$, there is a number $N\ge M$ such that $x_n\in U$ for each $n>N$. Then $d(f_n(x_n),f(x))\le d(f_n(x_n),f(x_n))+ d(f(x_n),f(x))<$ $\varepsilon/2+\varepsilon/2=\varepsilon$.

• Nice answer! This is going to help me even though I am not the OP.
– Lays
Apr 23 '13 at 4:21