It is well known that the sequence $\operatorname{frac}(na)$ , where $\operatorname{frac}$ denotes the fractional part and $n$ runs over the positive integers, is dense in $[0,1]$.
Suppose, I have an irrational number $a$ and two rational numbers $s,t$ with $0<s<t<1$. Then, there must be a positive integer $n$ with $s<\operatorname{frac}(na)<t$.
How can I efficiently calculate the smallest positive integer $n$ with the desired property ?
I tried the best approximations related to the continued fraction of $a$, but these only help to find integers $m,n$ , such that $|na-m|$ is very small.
I also thought about the possibility of using the lindep-command of PARI/GP, but the problem is that I need integers with $na-m-u\approx 0$ , where $u$ could, for example be $\frac{s+t}{2}$. But as far as I know, I cannot fix the coefficient belonging to $u$ to be $-1$, in which case I could find possible solutions.
But even if this were possible, the solution might not give the smallest value $n$ doing the job.
Any ideas?