# Prove that f is integrable on [0,2]

Let \begin{align} f(x)=\left\{\begin{matrix}1,\:\: 0\leq x\leq 1,\\ 0,\:\:1<x\leq 2. \end{matrix}\right. \end{align}

Prove that $f$ is integrable on $\left[0,2\right]$, and find the value of \begin{align} \int_0^2 f\left(x\right)\:dx. \end{align}

In order to show that $f$ is integrable I think I need to use the following theorem:

The bounded function $f$ is integrable on $\left[a,b\right]$ if and only if for every positive number $\epsilon$ there exists a partition $P$ of $\left[a,b\right]$ such that $|U\left(f,P\right) - L\left(f,P\right)|<\epsilon$.

The problem is that I'm not sure how to actually use this theorem to show it, I dont understand how I can find the value of the integral either, any tips solution? thanks!

• This is a step function, so it is integrable by definition. – Crostul Feb 6 '15 at 22:34
• Draw the graph of $f$ to get a sense of what's going on. There are partitions $P$ of the interval $[0,2]$ such that $U(f,P) - L(f,P) = 0$. Hint: One such partition has just two subintervals! – Simon S Feb 6 '15 at 22:39
• I disagree, I haven't seen it as definition. – Aaron Maroja Feb 6 '15 at 22:39
• @AaronMaroja: I think Crostul must be speaking about Lebesgue integrals. One of the possible sequences of definitions leading up to that start by stipulating that the indicator function of a finite interval is integrable with the integral being its length. (On the other hand, since the OP isn't specifying which kind of integral here, the reasonable assumption will be that he's speaking about Riemann integrals). – Henning Makholm Feb 6 '15 at 22:50
• @HenningMakholm I see, you are right. I believe so as well, the OP must be referring to Riemann integral. I've seen the proof in real analysis of a step function being Riemann-integrable, that's the only reason I disagreed at first. – Aaron Maroja Feb 6 '15 at 22:52

## 3 Answers

This function is integrable by definition because \begin{align} \int_0^2 f\left(x\right)\:dx=\int_0^1\:dx+\int_{1+}^2 0\:dx=1. \end{align}

• @user3788063: Some people prefer treating the $dx$ as if it were just a factor to multiply with, and in that case multiplying with $1$ doesn't change anything and can be omitted. In the same convention one can write things like $\int_0^1\frac{dx}{x+2}$ as a short form of $\int_0^1\frac{1}{x+2}dx$, and there are even some (in particular physicists) who write $\int_a^b dx\,f(x)$ instead of $\int_a^b f(x)\,dx$. – Henning Makholm Feb 6 '15 at 22:58
• @HenningMakholm I sometimes do that as well, i.e. re-write integrals with the $dx$ before the integrand. Especially if I'm integrating by parts in Stieljes integrals, just helps me keep track of things. – jm324354 Feb 6 '15 at 23:22

In your case there isn't much to be done because $$\int_{0}^{2} f = \int_{0}^{1}f + \underbrace{\int_{1}^{1+\epsilon}f}_{= 0} + \underbrace{\int_{1+\epsilon}^{2}}_{= 0 }f = 1$$

notice that $$\underline{\int}_{1}^{1+\epsilon}f = \overline{\int}_{1}^{1+\epsilon}f = 0$$

And it's possible to show that every step-function $f: [a,b] \to \mathbb R$ is integrable and its integral is given by

$$\int_{a}^{b} f(x) dx = \sum_{i=1}^{n} c_i (t_i- t_{i-1})$$

where $f$ is constant at $c_i$ on the intervals $(t_{i-1}, t_i)$.

• Because at first you have your function defined on $1< x \leq 2$, then you would need to check this case. Well, if you notice we have the inferior sum and superior sum are the same on $1 \leq x < 1 + \epsilon$. I would also suggest that you sketch a graph of your function. – Aaron Maroja Feb 6 '15 at 22:49
• Sorry, lower sum and upper sum. – Aaron Maroja Feb 6 '15 at 22:52

You probably have a theorem giving you $$\int_0^2 f(x)\,dx = \int_0^1 f(x)\,dx + \int_1^2 f(x)\,dx$$

Here, the first term on the right-hand side is $1$ because the integrand is constant on $[0,1]$, so every Riemann sum is $1$.

For the second term, the only term is a Riemann sum that can be different from $0$ is the first, if we select $1$ as the representative point in the first interval. But in that case the term in question is the length of the first interval, so it can be made as small as we like by selecting a sufficiently fine division.

So the second term is 0 and the entire integral must be 1.