# $D$ dense in $M$, $\{f_n\}$ sequence of equicontinuous maps, $f_n \rightarrow f$ pontwise in D. So $f_n \rightarrow f$ uniformly in $K$ compact

Let $M$ and $N$ be arbitrary metric spaces and $D \subset M$ dense. Given an equicontinuous sequence of maps $f_n\colon M \rightarrow N$ and a continuous map $f\colon M \rightarrow N$, suppose that $f_n \rightarrow f$ pointwisely in D. Show that $f_n \rightarrow f$ uniformly in each $K \subset M$ compact.

I know that if $f_n \rightarrow f$ pointwisely in M, then $f_n \rightarrow f$ uniformly in each $K \subset M$ compact.

So, my problem is showing that $f_n \rightarrow f$ pointwisely not just in D, but in M. For that, I should use that D is dense. How can I do that?

Can someone help me?

Thank you

Hint 1: $D\subset M$ is dense in $M$ if $\operatorname{cl}(D) = M$; in particular each $x\in M\smallsetminus D$ is a limit point of $D$.
Hint 2: Consider the following inequality $$d\left(f_n(x),f(x)\right) \leq d\left(f_n(x),f_n(x_k)\right) + d\left(f_n(x_k),f(x_k)\right) + d\left(f(x_k),f(x)\right)$$
Let $d$ be the distance in $M$. Let $\delta>0$ be such that $d(x,y)<\delta$ implies $d(f_n(x),f_n(y))<\epsilon$. Since $K$ is compact, it can be covered by finitely many open balls of radius $\delta$, say $U_1,\dots, U_k$. Since $D$ is dense, we can find $x_i\in D$ ($i=1,2,...,k$) such that $x_i\in U_i$. Now notice that $f$ is also uniformly continuous in $M$, since $d(x,y)<\delta\Longrightarrow d(f_n(x),f_n(y))<\epsilon\Longrightarrow\lim_{n\to\infty} d(f_n(x),f_n(y))=d(f(x),f(y))<\epsilon$ . Define $g_n=d(f_n,f)$. Hence, $\{g_n\}$ is also equicontinuous on $M$. Since $g_n(x)\to 0$ point-wise, we can find $N$ such that $g_n(x_i)<\epsilon$ for all $n>N$ and for all $i=1,2,..,k$. Now, take any $x\in K$. Then $x\in U_i$ for some $i=1,2..,k$. Now observe that $$d(f_n(x),f(x))\le d(f_n(x),f_n(x_i))+d(f_n(x_i),f(x_i))+d(f(x_i),f(x))$$. Now using this inequality, for all $n>N$, we have $d(f_n(x),f(x))<3\epsilon$.