# Exchanging limits and integrals

Let $\{f_i\}$ be a sequence of pointwise discontinuous functions whose limit is Dirichlet's function. I read that

$$\lim_{n\to\infty}\int f_n(x)dx \not= \int \lim_{n\to\infty} f_n(x)dx$$

as the right hand side attempts to integrate Dirichlet's function, which is not (Riemann) integrable. I get that part.

I don't really understand why the left hand makes sense though. I see that for any finite $i$, $f_i$ it is discontinuous on a non-dense set, so it's integrable, but when $i$ goes to infinity it seems to me like this integral shouldn't exist.

I guess one confusion is it seems like $\frac{d}{dx}(\lim_{n\to\infty}\int f_n(x)dx)$ should equal $\lim_{n\to\infty}f_n(x)$ which I suppose can't be true, but it doesn't seem obvious why.

-
Take a look at the Dominated Convergence Theorem – Patrick Li Oct 5 '12 at 14:04
@Patrick: Not sure I understand. I get that they may be Lebesgue integrable; I just don't understand why it's not Riemann integrable. – Xodarap Oct 5 '12 at 14:14

## 1 Answer

Probably, what you read talks about sequences of function like $$f_n:x\in [0, 1]\to \begin{cases} 1 &\text {if x = r_i for some 1 \leq i \leq n}\\ 0 &\text{otherwise} \end{cases}$$ where $\{r_n\}_1^\infty$ is a sequence of all rational numbers belonging to the interval $[0, 1]$.

Each function $f_n$ is Riemann integrable and $$\int_0^1 f_n(t)dt = 0$$ therefore the limit on the left side exists and is $0$.

-
Yes, this is the example. But by the fundamental theorem, $\lim_{n\to\infty}\int_a^b f_n(t)dt = \lim_{n\to\infty} F_n(b)-F_n(a)$ - it seems like if this $F$ exists, its derivative should be dirichlet's function. – Xodarap Oct 7 '12 at 14:49