Let $f_n$ be a sequence of functions defined on $\mathbb{R}$ sucht that $f_n\to f$ pointwise on $\mathbb{R}$ as $n\to\infty$ and each $f_n$ is bounded. Is $f$ necessarily bounded? Prove of give a counter-example. I would like to know if the following example holds as a counter-example. In the end I have also a question on it's non-uniform convergence proof.
Suppose $f_n(x)=x$ if $x<n$ and $f_n(x)=n$ if $x\ge n$. $f_n$ converges pointwise to $f(x)=x$ . Moreover, each $f_n$ is bounded (by $n$) and $f(x)$ is unbounded.
Now I would like to know if my proof on not uniform convergence of $f_n$ is correct. To prove it, we have to satisfy the following: $\exists \epsilon>0 \ \forall N \ \exists n\ge N \ \exists x \in \mathbb{R}:|f_n(x)-f(x)|>\epsilon$
Choosing $x=2n>n$ and $\epsilon=\frac{1}{2}$ we have that $|f_n(x)-f(x)|=|n-2n|=n>\frac{1}{2}$. So, $f_n$ doesn't converge uniformly to $f(x)=x$ regardless how $n$ is big.
Those functions $f_n$ are not bounded. Yes, $n$ is an upper bound, but they have no lower bound. However, you can define$$f_n(x)=\begin{cases}n&\text{ if }x>n\\x&\text{ if }x\in[-n,n]\\-n&\text{ if }x<-n,\end{cases}$$and that will work.
And this sequence $(f_n)_{n\in\Bbb N}$ is not uniformly convergent to $f(x)=x$ because$$(\forall n\in\Bbb N):\bigl|f(n+1)-f_n(n+1)\bigr|=1.$$So, if you take $\varepsilon=1$, and if $N\in\Bbb N$, then $\bigl|f(N+1)-f_N(N+1)\bigr|\geqslant\varepsilon$.