When can we write $\lim_{n \rightarrow \infty} \int_{0}^{n} f(x) dx=\int_{0}^{\infty} f(x) dx$? Intuitively, this is quite sensible as we are partitioning the interval $(0,\infty)$ as an increasing interval of $n$. But does this result hold true everytime?
Also, it is known that $\int_{0}^{n} f(x) dx$ exists for all $n$.
If n is only an integer and we're imagining a sequence, then I have a counterexample to that proposition. Let $f(x) = \cos(\pi x)$. Then, $$\lim_{n\to\infty}\int_0^n \cos(\pi x)dx = \lim_{n\to\infty}0=0$$ But the quantity $\int_0^\infty \cos(\pi x) dx$ does not exist.