Prove that this function is integrable and equal to zero

calculusintegrationproof-writingriemann-integration

If $f:[a,b] \to R$ is a bounded function such that $f(x)=0$ except for $x \in \{c_1,c_2,…,c_n\} \subset [a,b]$. Prove that $f$ is integrable in $[a,b]$ and that $\int_a^b f=0$.

I think this can be proved by Riemann criterion or by it's corollary. By finding the upper and lower sums, and since there are only certain points where the function isn't equal to zero its upper and lower sums must be 0.

But the only problem is that I don't know what partition to take, any thoughts?

Is there a way to determine what partition to take in this kind of problems, or it's purely intuition/arbitrary?

Best Answer

It doesn't matter. As long as the longest length in the partition is less than $\min\{c_{k+1}-c_k\}$, each point will be in a single partition. So, in the Riemann sum, only $n$ intervals will give nonzero values, and you can make these contributions as small as you want by making the partition finer.