Find $$\lim_{n \to \infty} \int_0^1 \frac{\cos\left (\frac{x^2}{n}\right)}{1+x^2} dx$$
What I've done is use a theorem I found online, Dini's Theorem. The interval $[0,1]$ is compact, and since
$$\lim_{n\to \infty} f_n=\lim_{n\to \infty}\frac{ \cos\left (\frac{x^2}{n}\right)}{1+x^2} = \frac{1}{1+x^2}=f$$ then $f_n$ converges pointwise to $f$. Furthermore, $f_n$ is continuous on $[0,1]$ for each $n \in \mathbb{N}$ and $f$ is also continous on $[0,1]$. Since $f_n$ is monotonally increasing in $[0,1]$, then $f$ converges uniformly to $f$ in $[0,1]$.
Now, each $f_n$ is integrable in $[0,1]$, and the sequence $(f_n)_{n=1}^{\infty}$ is bounded. Thus, we can exchange the limit and the integral and get
$$\lim_{n \to \infty} \int_0^1 \frac{\cos\left (\frac{x^2}{n}\right)}{1+x^2} dx = \int_0^1 f dx = \frac{\pi}{4}$$
My question then is
Is my reasoning correct? Is there a way of proving the uniform convergence of $(f_n)_{n=1}^{\infty}$ to $f$ using only the definition of uniform convergence?
Thanks in advance!