How to rewrite such modulo $\displaystyle \left \lfloor \frac{x}{n} \right \rfloor \equiv 0 \pmod d$ (using modular arithmetic) with $n<x$ and $n,x,d\in \mathbb{N}$? I actually need to get $\displaystyle n\equiv ?(\mod ?)$ (if possible). Thank you.
2026-03-29 11:41:35.1774784495
Modulo operation with floor function
648 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
The condition $n < x$ rules out the possibility that $\left\lfloor \frac xn \right\rfloor = 0.$ The fact that $x$ and $n$ are both non-negative rules out the possibility that $\left\lfloor \frac xn \right\rfloor < 0.$ So we only need to be concerned with $n$ such that $\left\lfloor \frac xn \right\rfloor$ is a positive multiple of $d.$
Consider $n$ such that $\left\lfloor \frac xn \right\rfloor = d.$ This occurs when $nd \leq x < nd + n = n(d+1).$ That is, $n \leq \frac xd$ and $n > \frac x{d+1}.$
Similarly, $\left\lfloor \frac xn \right\rfloor = 2d$ occurs when $2nd \leq x < 2nd + n = 2n(d+1).$ That is, $n \leq \frac x{2d}$ and $n > \frac x{2(d+1)}.$
In general, the solution set for $n$ is the set of integers $n$ such that $n \leq \frac x{kd}$ and $n > \frac x{k(d+1)}$ for some positive integer $k.$
For example, let $x = 18$ and $d = 3.$ For $k = 1$ we have $n \leq\frac{18}{3}=6$ and $n > \frac{18}{4} = 4.5,$ hence $n = 5$ and $n = 6$ are solutions. For $k=2$ we have $n \leq\frac{18}{6}=3$ and $n > \frac{18}{8} = 2.25,$ hence $n = 3$ is a solution. For $k=3$ we have $n \leq\frac{18}{9}=2$ and $n > \frac{18}{12} = 1.5,$ hence $n = 2$ is a solution. For $k=4$ we have $n \leq\frac{18}{12}=1.5$ and $n > \frac{18}{16} = 1.125,$ hence there is no solution, and similarly there is no solution for any $k > 4.$ So for this example the solution set is $n \in \{2,3,5,6\}.$
For $x=100,$ $d=5$ the solution set is $n \in \{1,2,4,5,10,17,18,19,20\}.$
This problem does not appear to be conducive to writing the solution in the form $$n \equiv \text{something} \pmod{ \text{something else}}.$$ Instead, the solution set may include "runs" of consecutive integers, where the "runs" may be of varying lengths.
We know the number of solutions is finite since you specified $n < x,$ but presumably you expected that condition to be included in the solution. The problem with the idea of writing $n \equiv \ldots$ is really that $\frac xn$ is highly non-linear in $n$, and you don't get any of the regular spacing of solutions that would make $n \equiv \ldots$ a useful notation.