Does $\{f_n\}$ converge uniformly on $(0,1) $ and $(0,\infty)?$ 
Let $g_n(x)=\sin^2(x+\frac{1}{n}),x\in (0,\infty)$
  and $f_n(x)=\int _0^x g_n(t) dt$.
Then show that $\{f_n\}$ converges uniformly on $(0,1)$.
  Does $\{f_n\}$ converge uniformly on $(0,\infty)?$.

$f(x)=\lim_{n\to \infty}f_n(x)=\lim_{n\to \infty}\int _0^x g_n(t) dt=\int _0^x\lim_{n\to \infty}\sin ^2(t+\frac {1}{n})=\int_0^x \sin^2 t$ [Since $\int$ and $\sin^2x$ are continuous functions].
Hence $f(x)=\int _0^x \sin ^2 t dt$.
Now $\sup_{(0,\infty)} |f_n(x)-f(x)|=\sup_{(0,\infty)}|\int _0^x \{\sin ^2(t+\frac{1}{n})-\sin^2 t\}|\le \sup_{(0,\infty)} \int _0^x |\{\sin ^2(t+\frac{1}{n})-\sin^2 t\}|$
Taking $|\{\sin ^2(t+\frac{1}{n})-\sin^2 t\}|=|\sin (t+\frac{1}{n})-\sin t||\sin (t+\frac{1}{n})+\sin t|\le 2\frac{1}{n}$
Hence $\sup_{(0,\infty)} |f_n(x)-f(x)|\le \sup_{(0,\infty)} 2\frac{x}{n}$
Hence if $x\in (0,1)\implies  \sup_{(0,\infty)} |f_n(x)-f(x)|\le \frac{2}{n}\to 0$
Hence $f_n$ converges uniformly on $(0,1)$.
But $f_n$ does not converge uniformly on $(0,\infty)$ because I can choose $x$ quite large such that $\frac{x}{n}>1$.
Please validate.

Note that
$$\int_0^x \sin^2(t +1/n) \, dt = \frac{x}{2} - \frac{1}{4}\sin(2x+2/n) + \frac{1}{4} \sin (2/n),$$
and
$$\int_0^x \sin^2(t) \, dt = \frac{x}{2} - \frac{1}{4}\sin(2x) .$$
Hence,
$$|f_n(x) - f(x)| \leqslant \frac{1}{4}\left|\sin(2x+2/n) - \sin(2x) \right|+ \frac{1}{4} |\sin(2/n)| \leqslant \frac{1}{2n} + \frac{1}{4}|\sin(2/n)|$$
We have uniform convergence on $(0,\infty)$.
