# How prove this inequality $|n\sqrt{2009}-m|>\dfrac{1}{kn}$

if $k>\sqrt{2009}+\sqrt{2010}$,show that

for any positive integer numbers $m,n$, have $$|n\sqrt{2009}-m|>\dfrac{1}{kn}$$

My try: $$\Longleftrightarrow(n\sqrt{2009}-m)^2k^2n^2>1$$ $$\Longleftrightarrow (n\sqrt{2009}-m)^2(\sqrt{2009}+\sqrt{2010})^2n^2>1$$

-

We have

$$\lvert n\sqrt{2009} - m\rvert = \frac{\lvert m^2 - 2009n^2\rvert}{n\left(\sqrt{2009} + \frac{m}{n}\right)}.$$

The numerator is an integer, and not $0$, since $2009$ is not a square, so we have the lower bound

$$\frac{1}{n\left(\sqrt{2009} + \frac{m}{n}\right)},$$

and for $m < n\sqrt{2010}$, that immediately yields the desired inequality.

In particular, we need only consider $m > n\sqrt{2009}$, and it is clear that then $\lvert n\sqrt{2009} - m\rvert$ is minimised for $m = \lceil n\sqrt{2009}\rceil$.

So if $n\sqrt{2010} > \lceil n\sqrt{2009}\rceil$ we have $\frac{m}{n} < \sqrt{2010}$ for the minimising $m$, and hence the inequality holds. We certainly have $n\sqrt{2010} > \lceil n\sqrt{2009}\rceil$ if $n(\sqrt{2010} - \sqrt{2009}) \geqslant 1$, so there are only finitely many cases, $n \leqslant 89 = \lfloor \sqrt{2010} +\sqrt{2009}\rfloor$ left to consider.

One could check them all mechanically, but we can reason further. $m = \lceil n\sqrt{2009}\rceil$ implies $m \leqslant 45n$, and since $\sqrt{2009} + 45 < 2(\sqrt{2009} + \sqrt{2010})$, the only chance to get

$$\lvert n\sqrt{2009} - m\rvert \leqslant \frac{1}{n(\sqrt{2009}+\sqrt{2010})}$$

is when $$m^2 - 2009n^2 = 1.\tag{P}$$

$(P)$ is a Pell equation, and if one knows how to solve them, it is readily seen that the fundamental solution ($m = 141012534067201,\; n = 3146065416960$) of $(P)$ has $n > 89$, but let's check it in a different way. $n \leqslant 89$ implies $m = \lceil n\sqrt{2009}\rceil \leqslant 45\cdot 89 = 4005$. A solution of $(P)$ must have in particular $m^2 \equiv 1 \pmod{2009}$. Now, $2009 = 7^2\cdot 41$, so $m^2 \equiv 1 \pmod{2009}$ if and only if both, $m^2 \equiv 1 \pmod{7^2}$ and $m^2 \equiv 1 \pmod{41}$ hold. That means we must have $m \equiv \pm 1 \pmod{7^2}$ and $m\equiv \pm 1 \pmod{41}$. We find $m \equiv 1, \, 491,\, 1518,\,2008 \pmod{2009}$, so $m \in C := \{491, 1518, 2008, 2010, 2500, 3527\}$ are the candidates. But for a solution of $(P)$, we must have $n = \left\lfloor \frac{m}{\sqrt{2009}}\right\rfloor$ and $m = \lceil n\sqrt{2009}\rceil$, and these are not satisfied for $m \in C$, we get the values $\{449,1480,1973,1973,2466,3497\}$ for $\lceil \lfloor m/\sqrt{2009}\rfloor\sqrt{2009}\rceil$ and $m \in C$.

-
If the nearest integer to $n \sqrt{2009}$ is below it then the inequality is always satisfied. Therefore the worst upper bound for $m$ is only $n \sqrt{2009} + \tfrac{1}{2}$. This leaves only $n=1, \ldots, 44$ to be checked. But you cleverly avoided that altogether. –  WimC Oct 6 '13 at 6:42

To start, note that $|(n\sqrt{2009}-m)(n\sqrt{2009}+m)| = |2009n^2-m^2|\ge 1$, since the middle expression is an integer (nonzero since $\sqrt{2009}$ is irrational). Therefore $$|n\sqrt{2009}-m| \ge \frac1{n\sqrt{2009}+m}.$$ Hopefully this can be converted into the desired bound....

-