# Assume that the function $f(x)$ is continuous and $\lim_{n\to\infty}f_n(x)=f(x)$. Does this imply that $f_n(x)$ is uniform convergent?

I wonder if this is true:

Let $(f_n)$ be a sequence of real-valued functions defined on a set $S\subset\mathbb{R}$. Assume that the function $f(x)$ is continuous and $\lim_{n\to\infty}f_n(x)=f(x)$. Does this imply that $f_n(x)$ is uniform convergent?

The other way around it seems to be true, according to my book:

The uniform limit of continuous function is continuous.

-
Kasper: I posted an asnwer and some people down voted it and I do not know why? So do not worry about this downvote. It is an honesty problem. –  Mhenni Benghorbal Feb 20 '13 at 15:07
@julien Sry i will try to be more constructive –  Dominic Michaelis Feb 20 '13 at 15:08
This is my answer to the question and it was the first answer to be posted and because of the unfair downvote I deleted and I am posting it here. The answer is " No, it does not. On the other hand uniform convergence preserves continuity. " –  Mhenni Benghorbal Feb 20 '13 at 15:16
@MhenniBenghorbal I wasn't the downvoter and I never downvote, but I suspect the answer got downvoted because it didn't justify the claim. I think the OP is looking for a proof or counterexample, not just a yes or no answer. –  Ayman Hourieh Feb 20 '13 at 15:19
@AymanHourieh: He asked a question and I briefly answered him. I do not think this is wrong! The answer is right and the OP can ask for more details later? He started his question by " I wonder if this is true " –  Mhenni Benghorbal Feb 20 '13 at 15:22

No. Here is a counterexample. $f_n(x) = \frac{x}{n}$ converges pointwise (but not uniformly) to the constant function $f(x) = 0$ on $\Bbb R$, which is continuous.

-
But $f_n$ converges uniformly. –  Julián Aguirre Feb 20 '13 at 14:56
@JuliánAguirre Yeah, I thought the question was about continuity. –  Ayman Hourieh Feb 20 '13 at 14:57
@JuliánAguirre Fixed now. –  Ayman Hourieh Feb 20 '13 at 15:00

No it does not. As a counterexample, consider the function $f:(0,1)\to\Bbb R$ defined by $f(x)=1/x$. Clearly this is continuous; now consider the sequence of functions $$f_n(x)=\begin{cases} n &: x<1/n\\ 1/x &: 1/n\leq x<1\end{cases}.$$This is a standard example where I've merely modified the domain in order to preserve continuity.

As an aside, this example also shows that monotone convergence (i.e., $f_m\leq f_n$ for $m<n$) need not imply uniform convergence if the domain is bounded but not compact (an idea that Dominic Michaelis mentions in his answer).

-

The result is not true in general. Let $f_n\colon[0,1]\to\mathbb{R}$ be defined by $f_n(x)=4\,n\,x(1-n\,x)$ if $0\le x\le1/n$, $f_n(x)=0$ if $1/n<x\le1$. Then $f_n$ converges pointwise but not uniformly to the continuous function $f(x)=0$.

On the other hand, you should check Dini's theorem.

-

As it is mentioned it is not true. But if you add some more Assumptions like $S$ is compact and $f_n(x)\geq f_m(x)$ for $n>m$ (I think you don't need that $f_n$ is continuous), than you can show, that the convergence is uniform.

-
Dini's theorem say we need $f_n$ is continuous. I think i have heard of a version where we don't need $f_n$ is continuous, i am thinking about this one –  Dominic Michaelis Feb 20 '13 at 15:05