# Is below function Riemann integrable?

$$f(x) = \begin{cases} \frac{1}{x^2} & \text{for x rational} \\ -\frac{1}{x^2} & \text{for x irrational} \\ \end{cases}$$

Is it integrable from $$1$$ to $$\infty$$?

A book says it is, citing the reason that $$|f(x)|$$ is integrable and any absolutely integrable function is integrable.

But I am having doubt because I feel that for any partition P Upper Darboux Sum and Lower Darboux Sum are negative of each other, and they are non-zero. So, they will not converge to the same limit.

Any help in this regard is appreciated.

• You're right about the upper and lower sums. Jul 29 '19 at 10:16

It is not true that Riemann integrability of $$|f|$$ implies that of $$f$$. Perhaps the book is talking about Lebesgue integral in which case this implications holds for all measurable functions $$f$$. This function is not Riemann integrable.
• Yeah, you're right. Easily fixable, though. Multiply by 2, add $1$. If you want to integrate over some unbounded interval, you can also multiply by $\frac1{1+x^2}$ or something too. Jul 29 '19 at 10:37
• Multiply by $2$ and add $1$? Jul 29 '19 at 11:43