I am trying to exhibit a Borel-measurable function which is positive on [0,1], i.e.
$$ f: [0,1]\rightarrow (0,\infty) $$
But which has lower Riemann integral equal to 0. Here the lower Riemann integral is defined as supremum over all lower Riemann sums.
I guessed that the following function might work, which essentially takes every rational number and "rounds down" the numerator to 1:
$$ f(x) = \begin{cases} 1/q & \text{ if } x = p/q \in \mathbb Q \text{ and } (p,q)=1 \\\\ x & \text{ if } x\not\in\mathbb Q \\\\ 1 & \text{ if } x = 0 \end{cases} $$
On any partition we can find a point which gets arbitrarily small, so I think I have correctly found a function which is positive and Riemann-integrates to 0. What I am unsure of is whether this function is Borel-measurable.
Suppose we take an open disc in the the codomain and apply the inverse image of $f$. We need to know that this is a Borel set. Certainly the inverse image of $(y-\varepsilon, y+\varepsilon)$ contains all irrationals in that interval. And I imagine it contains all rationals of the form $1/q$ for some sufficiently large $q$. But none of this sounds like any Borel set that I know of.
Let $A \Delta B$ denote the symmetric difference $(A \setminus B)\cup (B \setminus A)$. It is helpful to observe that $f^{-1}((a,b)) \Delta (a,b)$ is a countable set (since $\{x: f(x) \neq x\}$ is countable). Let $A=f^{-1}((a,b))$ and $B=(a,b)$. Then $A =B \Delta (A\Delta B)$ (which is a set theoretic identity). Now $B$ is meaurable and $A\Delta B$ is measurable, so $B \Delta (A\Delta B)$ is measurable.