I'm having a bit of trouble with this integral and I'm not sure if I'm correct.
Let $f_n(x) = \cos(x) (1 - \frac{\lvert x \rvert}{n} )^n $ when $ \lvert x \rvert < n $ and $0$ when $ \lvert x \rvert \ge n$.
I'm asked to find the limit of $$\lim_{n\to \infty}\int_{-\infty}^{\infty}f_n(x)\,dx$$
Here is my attempt: Since $f_n$ is an even function, I need to find $$2\lim_{n\to \infty}\int_{0}^{\infty}f_n(x)\,dx$$
meaning, $$2\lim_{n\to \infty} \lim_{M\to \infty} \int_{0}^{M}f_n(x)\,dx$$
Since for $ M > n $, $ f_n = 0$, we are left with $$2\lim_{n\to \infty} \lim_{M\to \infty} \int_{0}^{n}f_n(x)\,dx$$ meaning $$2\lim_{n\to \infty}\int_{0}^{n}f_n(x)\,dx$$
Since $ f_n $ converges pointwise to $ f(x) = \cos(x) e^{-x} $ on any finite interval $[0,b]$, and since on the intevral $[0, \infty]$ we know $ \lvert f_n \rvert < (1 - \frac{x}{n})^n $ with $ \int_{0}^{\infty}(1 - \frac{x}{n})^n dx$ converges, then I can say that $\lim_{n\to \infty}\int_{0}^{\infty}f_n(x)\,dx = \int_{0}^{\infty}f(x)\,dx $. Using Integration by parts twice I can see that $2\int_{0}^{\infty}f(x)\,dx = 1$.
Is this correct?