I am trying to solve the following question:
$f:[a,b]\to\mathbb{R}$ is integrable. Also if $f$ is continuous in a point $c\in [a,b]$ then $f(c)=0$.
Show that $X=\{x\in [a,b] : f(x)\neq 0\}$ has empty interior.
My attempt: Assuming that $X$ has nonempty interior, $\forall x\in X$, there exists some $\delta$ such that $(x-\delta,x+\delta)\subset X$. Now by hypothesis, $f$ is not continuous on $(x-\delta,x+\delta)$. One can get any contradiction according to the fact that $f$ is integrable?
If someone can offer any other solution will be thankful.
Since $f$ is integrable, for any $\epsilon > 0$ there exists a partition $P = (x_0,x_1, \ldots,x_m)$ of $[a,b]$ such that the difference of upper and lower Darboux sums satisfies
$$U(P,f) - L(P,f) = \sum_{j=1}^m \omega(f,[x_{j-1},x_j])(x_j - x_{j-1}) < \epsilon,$$
where $ \omega(f,[x_{j-1},x_j])= \sup_{x,y \in [x_{j-1},x_j]} |f(x) - f(y)|$ is the oscillation of $f$ on the interval $[x_{j-1},x_j]$.
Let $\omega_f(x) = \lim_{\delta \to 0}\omega(f,[x- \delta,x+\delta])$ denote the oscillation at a point $x$. Since $f$ is continuous at $x$ if and only if $\omega_f(x) = 0$, the set of discontinuity points is given by
$$D_f = \bigcup_{k=1}^\infty D_k =\bigcup_{k=1}^\infty \left\{x\in [a,b]:\omega_f(x) \geqslant \frac{1}{k} \right\}$$
Since $f(x)=0$ at any point in $[a,b]$ where $f$ is continuous, we have $X = D_f$.
Suppose $X$ has nonempty interior. By the Baire category theorem, one of the sets $D_m$ must have nonempty interior and there exists an interval $[\alpha, \beta]\subset D_m$. We have $\omega_f(x) \geqslant 1/m$ for all $x \in [\alpha, \beta]$ and $\omega(f,I) \geqslant 1/m$ for any interval $I$ that intersects $[\alpha,\beta]$.
Choosing $\epsilon < (\beta - \alpha)/m$, we get a contradiction
$$\epsilon > \sum_{j=1}^m \omega(f,[x_{j-1},x_j])(x_j - x_{j-1}) \geqslant \sum_{[x_{j-1},x_j]\cap [\alpha,\beta]\neq \emptyset} \omega(f,[x_{j-1},x_j])(x_j - x_{j-1})\geqslant \frac{\beta-\alpha}{m}$$