Is there any way proving that :
$Q=[0,1]^2, f:Q\rightarrow \mathbb{R} $ defined by:
$f(x)=0$ if $x∉\mathbb{ Q}^2 $
and if $x=(\frac {n_1}{m_1} , \frac {n_2}{m_2})$ (where $n_1,m_1,n_2,m_2 \in \mathbb{Z}$ and $gcd(m_1,n_1)=1,gcd(m_2,n_2)=1$ ) then:
$f(x)=\frac{1}{m_1}+\frac{1}{m_2}$
Is Riemann integrable by Lebesgue differentiation theorem?
Also, how can I prove that $\int_Q f = 0$?
Edit:
I understand that Lebesgue differentiation theorem ins't useful here, how can I show that $f$ is continuous?
Claim 1: $f$ is continuous at $x \not \in \mathbb{Q}^2$.
Proof: Take any $x = (x_1,x_2) \not \in \mathbb{Q}^2$. We wish to show given any $\epsilon > 0$, we can find a small enough ball around $x$ so that $f(y) < \epsilon$ for any $y$ in that ball. First consider all $\frac{n_1}{m_1} \in \mathbb{Q}$ with $|x_1-\frac{n_1}{m_1}| < 1$ and $\frac{1}{m_1} \ge \frac{\epsilon}{2}$. The number of such $r$ is finite since for any $m_1 \le \frac{2}{\epsilon}$, there are only finitely many $n_1$ so that $x_1-\frac{n_1}{m_1} < 1$. Similarly, the number of $\frac{n_2}{m_2} \in \mathbb{Q}$ with $|x_2-\frac{n_2}{m_2}| < 1$ and $\frac{1}{m_2} \ge \frac{\epsilon}{2}$ is finite. Therefore, we can take a small enough ball $B$ around $x$, so that for any $y = (\frac{n_1}{m_1},\frac{n_2}{m_2}) \in B\cap\mathbb{Q}^2$, we have $\frac{1}{m_1}+\frac{1}{m_2} < \epsilon$, and so $f(y) < \epsilon$ for any $y \in B$.
From this claim, it follows $f$ is Riemann integrable, since it is continuous almost everywhere ($\mathbb{Q}^2$ has Lebesgue measure $0$). Further, $f = 0$ almost everywhere and so $\int f = 0$.
Lebesgue Differentiation Theorem doesn't seem too relevant.