Piecewise Continuous Function with One-Sided Limits is Darboux Integrable

Theorem
A piecewise continuous function $f$ defined on an interval $\left[{a \,.\,.\, b}\right]$ is Riemann integrable.

Proof
We shall use proof by induction on the number of intervals.

Since $f$ is piecewise continuous, there exists a finite subdivision $\left\{{x_0, \ldots, x_n}\right\}$ of $\left[{a \,.\,.\, b}\right]$, $x_0 = a$ and $x_n=b$, such that $f$ is continuous on $\left({x_{i−1} \,.\,.\, x_i}\right)$ for every $i \in \left\{{1, \ldots, n}\right\}$.

Note that $n$ is the number of intervals $\left({x_{i−1} \,.\,.\, x_i}\right)$ defined from the subdivision $\left\{{x_0, \ldots, x_n}\right\}$.

We start with the case $n=1$, the base case.

We need to prove that the theorem is true for this case.

When $n=1$ the subdivision $\left\{{x_0,x_1}\right\}$, $x_0 = a$ and $x_1=b$, is part of the definition of the piecewise continuity of $f$.

According to this definition, $f$ is continuous on $\left({a \,.\,.\, b}\right)$, and $\displaystyle \lim_{x \to a+} f\left({x}\right)$ and $\displaystyle \lim_{x \to b-} f\left({x}\right)$ exist.

By Integrability Lemma for Functions Continuous on Open Intervals (see below), $f$ is Riemann integrable on $\left[{a \,.\,.\, b}\right]$.

This finishes the proof for the case $n=1$.

Assume that the theorem is true for some $n$, $n \geq 1$.

To finish the proof of the theorem, it is sufficient to prove that the theorem is true for the case $n+1$.

Consider a function $f$ and a subdivision $P$ = $\left\{{x_0, \ldots, x_{n+1}}\right\}$ of $\left[{a \,.\,.\, b}\right]$, $x_0 = a$ and $x_{n+1} = b$, so that $f$ is continuous on $\left({x_{i−1} \,.\,.\, x_i}\right)$ for every $i \in \left\{{1, \ldots, n+1}\right\}$.

We intend to prove that $f$ is piecewise continuous on $\left[{a \,.\,.\, x_n}\right]$ and $\left[{x_n \,.\,.\, b}\right]$.

We know that $f$ is continuous on $\left({x_{i−1} \,.\,.\, x_i}\right)$ for every $i \in \left\{{1, \ldots, n}\right\}$.

Also, the one-sided limits $\displaystyle \lim_{x \to x_{i−1}+} f\left({x}\right)$ and $\displaystyle \lim_{x \to x_i-} f\left({x}\right)$ exist for every $i \in \left\{{1, \ldots, n}\right\}$.

Therefore, all the requirements for $f$ to be piecewise continuous on $\left[{x_0 \,.\,.\, x_n}\right]$ for the subdivision $\left\{{x_0, \ldots, x_n}\right\}$ of $\left[{x_0 \,.\,.\, x_n}\right]$ are satisfied.

As $x_0 = a$, we have shown that $f$ is piecewise continuous on $\left[{a \,.\,.\, x_n}\right]$.

Since $f$ is piecewise continuous on $\left[{a \,.\,.\, b}\right]$ with respect to the subdivision $P$, $f$ is continuous on $\left({x_n \,.\,.\, x_{n+1}}\right)$.

Also, the one-sided limits $\displaystyle \lim_{x \to x_n+} f\left({x}\right)$ and $\displaystyle \lim_{x \to x_{n+1}−} f\left({x}\right)$ exist.

Therefore, all the requirements for $f$ to be piecewise continuous on $\left[{x_n \,.\,.\, x_{n+1}}\right]$ for the subdivision $\left\{{x_n, x_{n+1}}\right\}$ of $\left[{x_n \,.\,.\, x_{n+1}}\right]$ are satisfied.

As $x_{n+1} = b$, we have shown that $f$ is piecewise continuous on $\left[{x_n \,.\,.\, b}\right]$.

We now conclude by using the induction hypothesis to show that $f$ is integrable.

Since $f$ is piecewise continuous on $\left[{a \,.\,.\, x_n}\right]$, and the number of intervals $\left({x_{i−1} \,.\,.\, x_i}\right)$ defined from the subdivision $\left\{{x_0, \ldots, x_n}\right\}$ equals $n$, $f$ is integrable on $\left[{a \,.\,.\, x_n}\right]$ by the induction hypothesis.

Since $f$ is piecewise continuous on $\left[{x_n \,.\,.\, b}\right]$, and the number of intervals $\left({x_{i−1} \,.\,.\, x_i}\right)$ defined from the subdivision $\left\{{x_n, x_{n+1}}\right\}$ equals 1, $f$ is integrable on $\left[{x_n \,.\,.\, b}\right]$ by the fact that the theorem is true for the base case.

By Additivity with Respect to the Interval of Integration, $f$ is integrable on $\left[{a \,.\,.\, b}\right]$ because the integrals $\displaystyle \int_a^{x_n} f \left(x\right) \ \mathrm d x$ and $\displaystyle \int_{x_n}^b f \left(x\right) \ \mathrm d x$ exist.

Integrability Lemma for Functions Continuous on Open Intervals
Let $f$ be a real function defined on an interval $\left[{a \,.\,.\, b}\right]$, $b>a$.

If $f$ is continuous on $\left({a \,.\,.\, b}\right)$ and $\displaystyle \lim_{x \to a+} f\left({x}\right)$ and $\displaystyle \lim_{x \to b-} f\left({x}\right)$ exist, then $f$ is Riemann integrable on $\left[{a \,.\,.\, b}\right]$.

Proof
It suffices to show that, for a given positive $\epsilon$, a subdivision $S$ of $\left[{a \,.\,.\, b}\right]$ exists such that


 * $U(S)–L(S)<\epsilon$

where $U(S)$ and $L(S)$ are respectively the upper and lower sums of $f(x)$ on $\left[{a \,.\,.\, b}\right]$ with respect to the subdivision $S$.

We observe that $f$ satisfies the conditions of piecewise continuity with respect to the subdivision $\left\{{a,b}\right\}$ of $\left[{a \,.\,.\, b}\right]$.

By Piecewise Continuous Function is Bounded, a positive bound $K$ exists for $f$ on $\left[{a \,.\,.\, b}\right]$.

Let a positive $\epsilon$ be given, and choose a $\delta$ that satisfies:


 * $0 < \delta < min(\epsilon/(3*2*K), (b-a)/2)$

Since $f$ is continuous on $\left({a \,.\,.\, b}\right)$, $f$ is continuous on $[a+\delta..b-\delta]$ because this interval is a subset of $\left({a \,.\,.\, b}\right)$ as $\delta$ > 0.

By Continuous Function is Riemann Integrable, $f$ is integrable on $[a+\delta..b-\delta]$.

Since $f$ is integrable on $[a+\delta..b-\delta]$, there exists a subdivision $S_\delta$ of $[a+\delta..b-\delta]$ that satisfies:


 * $U(S_\delta)–L(S_\delta)<\epsilon/3$

where $U(S_\delta)$ and $L(S_\delta)$ are, respectively, the upper and lower sums of $f$ on $[a+\delta..b-\delta]$ with respect to the subdivision $S_\delta$.

Define the following subdivision of $\left[{a \,.\,.\, b}\right]$: $S = S_\delta \cup \left\{{a,b}\right\}$.

The upper sum of $f(x)$ on $\left[{a \,.\,.\, b}\right]$ with respect to $S$ is per definition:


 * $U(S) = M_a*\delta + U(S_\delta) + M_b*\delta$

where $M_a$ is the supremum of $f$ on $[a..a+\delta]$, and $M_b$ is the supremum of $f$ on $[b-\delta..b]$.

$M_a$ and $M_b$ exist by the least upper bound property of the real numbers because $f$ is bounded on $[a..a+\delta]$ and $[b-\delta..b]$.

The lower sum of $f(x)$ on $\left[{a \,.\,.\, b}\right]$ with respect to $S$ is per definition:


 * $L(S) = m_a*\delta + L(S_\delta) + m_b*\delta$

where $m_a$ is the infimum of $f$ on $[a..a+\delta]$, and $m_b$ is the infimum of $f$ on $[b-\delta..b]$.

$m_a$ and $m_b$ exist by the greatest lower bound property of the real numbers because $f$ is bounded on $[a..a+\delta]$ and $[b-\delta..b]$.

Define the sum

Define the sum

Therefore, $U'$ and $L'$ satisfy:


 * $U' \geq U(S)$


 * $L' \leq L(S)$

From these two inequalities follows:

Hence


 * $U(S)–L(S)< \epsilon$