I'm trying to show that $\int_{-\infty}^{\infty}\Big(\sum_{n=1}^{\infty}n\chi_{(\frac{1}{n+1},\frac{1}{n}]}\Big)d\mu = \infty$ where $\mu$ is the Lebesgue measure.
Approach:
I swap the sum and the integral (justified by the fact that we have a non-negative function).
Then I am slightly confused.
To evaluate this integral I need to be able to write it as a simple function. In the examples I've seen the function has always been written as a finite linear combination of indicator functions.
i.e. $$f(x)=\sum_{n=1}^{N}b_{n}\chi_{B_{n}}(x)$$ where $B_{n}$ is a measurable set and $b_{n} \in \mathbb{R}$ and $\int f d\mu:= \sum_{n=1}^{N} b_{n}\mu(B_{n}).$
Here it seems to be the case that $N=\infty$ and therefore it would be an infinite linear combination. Is this allowed?