Constructed by Dirichlet as an example of a function which is not Riemann integrable. It can be defined on any interval a ≤ x ≤ b by f(x) = 1 if x is rational and f(x) = 0 if x is irrational. By choosing the points of a partition to be rational or irrational, a Riemann sum can have limit b–a or 0 as the partition’s norm converges to 0. However, f is Lebesgue integrable as the rationals have measure 0, and so f has Lebesgue integral 0.