Problem: Let $h_n:[0,\infty]\to\mathbb{R}$ be given by $h_n(x)=\frac{nx}{x+n}$, and let $h:[0,\infty)\to \mathbb{R}$ be given by $h(x)=x$.
(a) Prove that for each $c>0$, $(h_n)$ convergences uniformly to $h$ on the interval $[0,c]$.
(b) Prove that $(h_n)$ does not converge uniformly to $h$ on $[0,\infty)$
My solution/proof:
(a) Let $m_n=\sup|h_n(x)-h(x)|$.
Consider $$\begin{align}|h_n(x)-h(x)|&=\left|\frac{hx}{x+n}-x\right|\\
&=\left|\frac{nx-x(x+n)}{x+n}\right|\\
&=\left|\frac{nx-x^2-nx}{x+n}\right|\\
&=\left|\frac{-x^2}{x+n}\right|\\
&=\frac{|x|^2}{x+n}.\end{align}$$
Now, $x\in[0,c]\to\frac{|x|^2}{|x+n|}\leq\frac{c^2}{n}$.
Therefore, $m_n=\frac{c^2}{n}$. As $n\to \infty$, $m_n\to0$. Now $m_n=\sup{|h_n(x)-h(x)|:x\in[0,c]}$and $m_n\to 0$ as $n\to \infty$. From supremum test, $h_n(x)$ converges to $h(x)$ uniformly on $[0,c]$.
(b) $h_n(x)$ does not converge uniformly to $h$ on $[0,\infty)$. Let $x_n=n\in[0,\infty)$. Now, $$\begin{align}|f_n(x_n)-h(x_n)|&=\left|\frac{nx_n}{x_n+n}-x_n\right|\\ &=\left|\frac{n*n}{n+n}-n\right|\\ &=\left|\frac{n^2}{2n}-n\right|\\ &=\left|\frac{n}{2}-n\right|\\ &=\left|\frac{n}{2}\right|\\&\geq\frac{1}{2}\to|h_n(x_n)-h(x)|\geq \frac{1}{2}\end{align}$$ from Cauchy's Criterion, $h_n$ does not converge uniformly to $h(x)$ on $(0,\infty)$.
Please tell me if my proof is correct. Give an alternate proof if it's not correct. Thank you!