0

Let $f:[0,1]\to \mathbb{R}$, $f(x)=0$ if $x\not\in \mathbb{Q}$ and $f(x)=\frac{1}{q}$ if $x=\frac{p}{q}$, $p,q$ coprime. $p$ integer, $q$ natural.

I want prove that $f$ is Riemann integrable.

I have a doubt. Let $P=\left\{\frac{1}{n},\frac{2}{n},\ldots, \frac{n-1}{n},1\right\}$ a partition.

Now, $U(f,P)=\frac{1}{n}\sum_{i=1}^n M_i=\frac{1}{n} \sum_{i=1}^n\sup\left\{f(x): x\in [\frac{i-1}{n},\frac{i}{n}]\right\}=\frac{1}{n} \sum_{i=1}^{n} \frac{1}{n}=\frac{1}{n} n\frac{1}{n}=\frac{1}{n}\leq \epsilon$ with $n\to \infty$. Therefore $\inf_{P} U(f,P)=0.$

It is correct?...

eraldcoil
  • 3,888

2 Answers2

2

If $x\notin \mathbb{Q}$ and $x_n =\frac{p_n }{q_n}\to x$ $(p_n ,q_n)\in \mathbb{Z}\times\mathbb{Z}$ then of course we have $q_n \to \infty$ and therefore $f(x_n) =q_n^{-1}\to 0$ thus $f$ is continuous at $x.$ Thus the set of points of discontinuity of $f$ has Lebesgue measure zero and therefore $f$ is Riemann integrable.

1

No, it is not correct. You are assming that$$\sup\left\{f(x)\,\middle|\,x\in\left[\frac{i-1}n,\frac in\right]\right\}=\frac1n.$$This is false. Take, for instance, $n=3$ and $i=2$. Then $\dfrac1n=\dfrac13$, but$$\sup\left\{f(x)\,\middle|\,x\in\left[\frac13,\frac23\right]\right\}=f\left(\frac12\right)=\frac12.$$