# If a function is Riemann integrable, then it is Lebesgue integrable and 2 integrals are the same?

Is is true that if a function is Riemann integrable, then it is Lebesgue integrable with the same value? If it's true, how to prove it? If it's false, what is a counterexample?

If you are talking about proper Riemann integrals, i.e. $f : [a,b] \to \Bbb{R}$ is bounded and the interval $[a,b]$ is compact, then this is true.

EDIT: In the following, all integrals $\int \dots \, dx$ are to be unterstood as the Riemann integral $\int_a^b \dots \, dx$. All integrals $\int \dots \, d\lambda(x)$ are to be understood as the Lebesgue integral $\int_{[a,b]} \dots \, \lambda(x)$.

For a proof, use that there are sequences $(\varphi_n)_n$ and $(\psi_n)_n$ of Riemann step functions such that $\varphi_n \leq f \leq \psi_n$ and

$$\int \varphi_n \, dx \to \int f \, dx \leftarrow \int \psi_n \, dx.$$

Depending on your exact definition of the Riemann integral, this is either a direct consequence, or an easy consequence of the definition.

By changing to $\max\{ \varphi_1, \dots, \varphi_n \}$ and $\min\{\psi_1, \dots, \psi_n\}$, we can assume w.l.o.g. that the sequences $(\varphi_n)_n$ and $(\psi_n)_n$ are increasing/decreasing.

On Riemann step functions $\gamma : [a,b] \to \Bbb{R}$, the Lebesgue integral and the Riemann integral coincide (why?). Hence,

$$\int |\psi_n - \varphi_n| \, d\lambda(x) = \int \psi_n - \varphi_n \, dx \to \int f\, dx - \int f \, dx = 0. \qquad (\dagger)$$

By monotonicity, also $\varphi_n \to \varphi$ and $\psi_n \to \psi$ pointwise with $\varphi_1 \leq \varphi \leq f \leq \psi \leq \psi_1$.

By dominated convergence,

$$\int |\psi_n - \varphi_n| \, d\lambda(x) \to \int |\psi - \varphi| \, d\lambda(x).$$

By $(\dagger)$, we get $\int|\psi- \varphi|\, d\lambda(x) = 0$ and hence $\psi = \varphi$ almost everywhere.

Because of $\varphi \leq f \leq \psi$, we get $f = \varphi = \psi$ almost everywhere, so that $f$ is Lebesgue measurable with

$$\int f \, d\lambda(x) = \int \psi \, d \lambda(x) = \lim_n \int \psi_n \, d\lambda = \lim \int \psi_n \, dx = \int f \, dx.$$

This completes the proof.

For improper Riemann integrals, the claim is false however, as (cf. the answer by Peter) the example of $$\frac{\sin(x)}{x}$$ shows.

The point here is that Lebesgue integrability of $f$ implies integrability of $|f|$, whereas for the (improper) Riemann integral it can happen that $f$ is integrable, although $|f|$ is not.

Finally, one can even show (using a variant of the proof above) that a bounded function $f : [a,b] \to \Bbb{R}$ is Riemann integrable if and only if the set of discontinuities of $f$ is a set of Lebesgue measure zero.

• What did you mean by "improper Riemann integrals"? Commented Aug 3, 2015 at 21:06
• @Bearandbunny : Improper integrals are limits as the either or both of the bounds of integration approach something. If the integral $\displaystyle\int_{[0,\infty)} \frac{dx}{1+x^2}$ is viewed as a Lebesgue integral, then it is NOT improper, because it is not defined by first defining $\displaystyle\int_0^a \frac{dx}{1+x^2}$ and then taking a limit as $a\to\infty$. But $\displaystyle\int_0^\infty \frac{\sin x} x\, dx$ can only be viewed as an improper integral because the integrals of both the positive and negative parts are infinite. ${}\qquad{}$ Commented Aug 4, 2015 at 3:18
• @MichaelHardy: Learn a lot. Thanks. Commented Aug 4, 2015 at 4:05
• @Ovi: Well, both :) depending on your exact definition of the Lebesgue integral. Some authors only define $\int f$ if $\int |f|<\infty$, and some authors only require at least one of $\int f_+$ or $\int f_-$ to be finite. In the case of $f(x)=\sin(x)/x$, neither condition is satisfied. Commented Mar 29, 2018 at 5:31
• @PhomueX aren't the conditions $\int |f| < + \infty$ and $\int f^+, \int f^- < + \infty$ equivalent? Because $|f| = f^+ + f^-$ and both $f^+,f^- \geq 0$ so $f^+,f^- \leq |f|$ and hence their integrals. Commented Jul 2, 2020 at 8:12