# Math Help - [SOLVED] seemingly simple Riemann integral

1. ## [SOLVED] seemingly simple Riemann integral

Define $f(x)=x$ if $x$ is rational and $f(x)=0$ if $x$ is irrational. Compute $\overline{\int_0^1}f\;dx$ and $\underline{\int_0^1}f\;dx$.
Okay, so clearly $\underline{\int_0^1}f\;dx=0$ (since $m_i=0$), so we can concentrate on $\overline{\int_0^1}f\;dx$.

The problem is, I am having trouble interpreting my textbook on how to calculate this. According to it,

$\overline{\int_0^1}f\;dx=\inf\{U(P,f)$ : $P$ a partition of $[a,b]\}$.

Okay, that's all very well. But how in the world do we compute that? Thus far, I have not been able to find a way.

Any help would be much appreciated. Thanks!

2. On any subinterval in the partition $\mathcal{P}$ there a rational number, $r$, and an irrational, $\gamma$.
So $f(r)=r$ and $f(\gamma)=0$ giving the upper and lower values. (There are no other values.)

3. Originally Posted by Plato
On any subinterval in the partition $\mathcal{P}$ there a rational number, $r$, and an irrational, $\gamma$.
So $f(r)=1$ and $f(\gamma)=0$ giving the upper and lower values. (There are no other values.)
Thanks, but I do not see how that is correct. $f(r)=r$, not $1$ (unless of course $r=1$).

So for any subinterval, $M_i(f)=x_i$. And that means

$U(P,f)=\sum_{i=1}^{n}x_i(x_i-x_{i-1})$.

I don't see how I can choose $P$ to get this equal to zero.

4. Originally Posted by hatsoff
Thanks, but I do not see how that is correct. $f(r)=r$, not $1$ (unless of course $r=1$).

So for any subinterval, $M_i(f)=x_i$. And that means

$U(P,f)=\sum_{i=1}^{n}x_i(x_i-x_{i-1})$.

I don't see how I can choose $P$ to get this equal to zero.
You are correct. I misread the definition of the function.

Since $\underline{\int_0^1}f\;dx=0$, then if $f\in R(x)$ we will know $\overline{\int_0^1}f\;dx=0$.

Choose $\epsilon>0$ and partition $P$ with $n\geq1/\epsilon$ intervals such that $x_i=i/n$. Then $1/n\leq\epsilon$ and

$U(P,f)-L(P,f)=\sum_{i=1}^{n}x_i(x_i-x_{i-1})-0=\sum_{i=1}^{n}\frac{i}{n}(\frac{1}{n})=\frac{1}{ n}\leq\epsilon$.

This shows (I think) that $f$ is integrable, which means that

$\overline{\int_0^1}f\;dx=0$.

Do I have any errors in logic here?

6. Originally Posted by hatsoff
$U(P,f)-L(P,f)=\sum_{i=1}^{n}x_i(x_i-x_{i-1})-0=\sum_{i=1}^{n}\frac{i}{n}(\frac{1}{n})=\frac{1}{ n}\leq\epsilon$.
How did you get $\sum_{i=1}^{n}\frac{i}{n}(\frac{1}{n})=\frac{1}{n}$?
It seems to be $\frac{1}{n^2}\frac{n(n+1)}{2}$

7. Originally Posted by Plato
How did you get $\sum_{i=1}^{n}\frac{i}{n}(\frac{1}{n})=\frac{1}{n}$?
It seems to be $\frac{1}{n^2}\frac{n(n+1)}{2}$
Oops. I'm clumsy with those summations, as you can see.

But how about this: Could we say that since $g:[0,1]\to R$ defined by $g(x)=x$ (no matter whether or not $x$ is rational) is integrable, then we know

$\overline{\int_0^1}g\;dx=\overline{\int_0^1}f\;dx= \frac{1}{2}$.

And so then $f$ is not integrable.

Does that look fine?

8. Originally Posted by hatsoff
Okay, so clearly $\underline{\int_0^1}f\;dx=0$ (since $m_i=0$), so we can concentrate on $\overline{\int_0^1}f\;dx$.

The problem is, I am having trouble interpreting my textbook on how to calculate this. According to it,

$\overline{\int_0^1}f\;dx=\inf\{U(P,f)$ : $P$ a partition of $[a,b]\}$.

Okay, that's all very well. But how in the world do we compute that? Thus far, I have not been able to find a way.

Any help would be much appreciated. Thanks!
I thought $\overline{\int_0^1}f\;dx=\sup\{U(P,f)$

9. Originally Posted by manjohn12
I thought $\overline{\int_0^1}f\;dx=\sup\{U(P,f)$
Quite right, thanks. I do not believe that affects my solution, however.

So, what say you all? Is my $g(x)=x$ solution viable? If so, I'll mark this thread as solved.

10. Originally Posted by hatsoff
Quite right, thanks. I do not believe that affects my solution, however. So, what say you all? Is my $g(x)=x$ solution viable? If so, I'll mark this thread as solved.
Frankly I am puzzled by your having been given this problem.
I will elaborate, there is a standard theorem which is not given is most basic developments of the Riemann Integral: if the set of discontinuities is not countable then the function is not integrable.

What is the set of discontinuities for this function?

11. The set at which f is discontinuous is countable no? the set is just the rationals in [0,1].

12. Originally Posted by KZA459
The set at which f is discontinuous is countable no? the set is just the rationals in [0,1].
Given that $\frac{{\sqrt 2 }}{2} = \gamma \in [0,1]$ then $\gamma$ is a irrational number.
Any rational number, $q$ that is ‘close to' $\gamma$, then $q$ is approximately equal to $\gamma$.
Now consider $f(\gamma)=0~\& f(r)=r\approx \gamma$. Is continuity possible at $x=\gamma$?