Given an integer $n$ and a rational $x$ (we may assume that $|x|<1$ if it helps), find the smallest integer $m$ sun that $m>n$ and $x\times m$ is an integer.
I know (or at least believe that I do) how to find the smallest such integer: if $x = \frac{a}{10^b}$, then if $m = 10^{-b} \mathrm {lcm}(10^b,a) < a$ then $m$ is the smallest integer. But I need smallest greater than $n$.
Add 1
After the comment from Ross Millikan, it seems that if one represents $x = \frac{q}{p}$ in lowest terms, then the smallest integer $m > n$ is $m = p \times \lceil n/p\rceil {}$.
Represent $x$ as $\frac ab$, where $a,b\in \Bbb Z$, $b>0$ and $\gcd(a,b)=1$ - that is, $\frac ab $ is $x$ in its lowest terms.
Then with $c:= mx$ and $c\in \Bbb Z$, we have $c=\frac{ma}b$, so $b\mid ma$ and since $a$ and $b$ have no factors in common, we must have $b\mid m$.
So we need $m = kb$, and we can determine the smallest $k$ (and hence the smallest $m$) that gives $m>n$ by taking $n/b$ and increasing to the next integer, so taking $k=\left\lceil \frac {n+1}b \right\rceil$.