# Finding a subset $D$ such that the restriction of $f$ to $D$ is not Riemann-integrable

For $$\mathbf{I}$$ a generalized rectangle in $$\mathbb{R}^{n}$$, define $$f : \mathbf{I} \rightarrow \mathbb{R}$$ to be the function with constant value $$1$$. Find a subset $$D$$ of $$\mathbf{I}$$ such that the restriction $$f : D \rightarrow \mathbb{R}$$ is not integrable.

I was thinking of taking $$D$$ to be the set of points in $$\mathbf{I}$$ with all $$n$$ components rational and coming up with a density argument to prove non-integrability, but I haven't been able to do so.

Also, I've learned about Jordan content, but I haven't learned about measure zero sets.

I haven't been able to make much progress, and I would appreciate some sort of help.

• Seems like your $D$ is in the right direction, because what would a Riemann integral over a discrete set be if not the sum of the values of the function at its points? Apr 26, 2019 at 7:00

The Riemann integral $$\int_D f$$ is by definition $$\int_I f \chi_D$$ where $$\chi_D$$ is the indicator function taking the value $$1$$ for $$x \in D$$ and $$0$$ otherwise.
If $$D$$ is the subset of $$I$$ where for $$x = (x_1,\ldots,x_n)$$ the first component $$x_1$$ is rational, then $$f \chi_D$$ is not Riemann integrable. Any subrectangle of a partition of $$I$$ contains points in and not in $$D$$ where the integrand takes the values $$1$$ and $$0$$, respectively. Hence all lower sums equal $$0$$ and all upper sums equal the content of $$I$$ and the difference cannot be made arbitrarily small.