Let $f_n$ and $f$ be a real valued functions defined on a set $E$. If $f_n\to f$ pointwise on $E$ and there is a real-valued sequence $a_n$ such that $a_n\to 0$ and $|f_n(x)-f(x)|\le a_n \ \forall x \in E$. Show that $f_n\to f$ uniformly. I would like to know if my proof holds, please. I also have a question on the statement in the end. Thank you in advance for help!
First, as $f_n\to f$ pointwise, then we have $\forall x \in E:\forall \epsilon>0 \ \exists N \ \forall n>N:$ $|f_n(x)-f(x)|<\epsilon$.
Then, as $a_n\to 0$ as $n\to\infty$, we have: $\forall \epsilon>0 \ \exists N' \ \forall n\ge N':$ $|a_n|<\epsilon$
Moreover, $|f_n(x)-f(x)|\le a_n \ \forall x \in E$. So, $\forall \epsilon>0 \ \forall n\ge n_0:=\max(N,N') \ \forall x:$ $|f_n(x)-f(x)|\le|a_n|<\epsilon$. So, $f_n\to f$ uniformly.
I'm not sure that I have to use $\max(N,N')$. I think that using only $N'$ the inequality might work, as the pointwise convergence is needed here to ensure simply that the limit of $f_n$ exists and as $f_n$ is bounded by $a_n$ independently of $n$. Is it correct?
You don't need the pointwise convergence hypothesis. The second hypothesis alone implies uniform convergence.
To see it, take $\epsilon \gt 0$. As $a_n \to 0$, you can find $N \in \mathbb N$ such that for $n \ge N$ you have $0 \le a_n \le \epsilon$. And then for $n \ge N$ you also have $\vert f_n(x) - f(x) \vert \le a_n \le \epsilon$ for all $x \in E$.