Is the following function $g$ integrable? Is the following function $g$ integrable?
Define $f:\Bbb R\to \Bbb R$ by 
$$f(x)= \begin{cases} \frac{1}{\sqrt x}& 0<x<1\\0 &\text{else}\end{cases}$$
Let $r_n$ be an enumeration of all rationals: define $g:\Bbb R\to \Bbb R$ by 
$$
g(x)=\sum _{n=1}^\infty \frac{1}{2^n}f(x-r_n).
$$
Now surely $f$ is integrable since set of discontinuities of $f$ has measure $0$: how to show that this is true for $g$?
Please help.
 A: If you are talking about integrability in the Lebesgue sense this is quite easy: $\int g(x)\, dx= \int \sum\limits_{k=1}^{\infty} \frac 1 {2^{k}} \int f(x-r_n)\, dx= \int \sum\limits_{k=1}^{\infty} \frac 1 {2^{k}} \int f(x)\, dx=\int f(x)\, dx <\infty$. The second equality is by Fubini/Tonelli (applicable because $f \geq 0$) and the third equality is by translation invariance of Lebesgue measure. Alternate proof of second inequality: $\int \sum g_n =\sum \int g_n $ for any sequence of non-negative measurable functions $\{g_n\}$ because $ \sum\limits_{k=1}^{n} g_k$ increases to $ \sum\limits_{k=1}^{\infty} g_k$ and we can apply Monotone Convergence Theorem. 
A: Are you talking about the Riemann integral or the Lebesgue integral?
If the Lebesgue integral then yes, it's integrable. When you say "Now surely $f$ is integrable since set of discontinuities of $f$ has measure $0$" it almost sounds like you're talking about the Riemann integral. In fact $f$ is not Riemann integrable: The theorem is that if $f:[a,b]\to\Bbb R$ is bounded and continuous except on a set of measure zero then it's Riemann integrable.
