MHB What is the Proof for the Floor Function Challenge II Involving Primes?

AI Thread Summary
The discussion centers on proving the equation involving the floor function and two different primes, a and b. The equation states that the sum of the floor functions of multiples of a divided by b equals (a-1)(b-1)/2. Participants express admiration for the clarity of the solution provided by a user named Euge. Another member mentions having an alternative solution and plans to share it later to encourage further engagement with the problem. The conversation highlights the collaborative nature of exploring mathematical challenges within the community.
anemone
Gold Member
MHB
POTW Director
Messages
3,851
Reaction score
115
Let $a$ and $b$ be two different primes. Prove that
$\displaystyle\left\lfloor\dfrac{a}{b} \right\rfloor+\left\lfloor\dfrac{2a}{b} \right\rfloor+\left\lfloor\dfrac{3a}{b} \right\rfloor+\cdots+\left\lfloor\dfrac{(b-1)a}{b} \right\rfloor=\dfrac{(a-1)(b-1)}{2}$.
 
Mathematics news on Phys.org
For every $k \in \{1,2,\ldots,b-1\}$, $ka$ is not divisible by $b$ (or else $b$ divides $k$, which cannot happen). So for fixed $k$,

$\displaystyle \frac{ka}{b} - 1 < \left\lfloor\frac{ka}{b}\right\rfloor < \frac{ka}{b}$,

$\displaystyle \frac{(b-k)a}{b} - 1 < \left\lfloor\frac{(b-k)a}{b}\right\rfloor < \frac{(b-k)a}{b}$.

Adding the two inequalities, we get

$\displaystyle a - 2 < \left\lfloor\frac{ka}{b}\right\rfloor + \left\lfloor\frac{(b-k)a}{b}\right\rfloor < a$.

This forces

$\displaystyle \left\lfloor\frac{ka}{b}\right\rfloor + \left\lfloor\frac{(b-k)a}{b}\right\rfloor = a - 1$

Therefore

$\displaystyle \left\lfloor\frac{a}{b}\right\rfloor + \left\lfloor\frac{2a}{b}\right\rfloor + \cdots + \left\lfloor\frac{(b-1)a}{b}\right\rfloor$

$\displaystyle = \dfrac{\left\lfloor\frac{a}{b}\right\rfloor + \left\lfloor\frac{(b-1)a}{b}\right\rfloor}{2} + \dfrac{\left\lfloor\frac{2a}{b}\right\rfloor + \left\lfloor\frac{(b-2)a}{b}\right\rfloor}{2} + \cdots + \dfrac{\left\lfloor\frac{(b-1)a}{b}\right\rfloor + \left\lfloor\frac{a}{b}\right\rfloor}{2}$

$\displaystyle = \frac{a-1}{2} + \frac{a-1}{2} + \cdots + \frac{a-1}{2} (b-1\; \text{times})$

$\displaystyle = \frac{(a-1)(b-1)}{2}$.
 
Euge said:
For every $k \in \{1,2,\ldots,b-1\}$, $ka$ is not divisible by $b$ (or else $b$ divides $k$, which cannot happen). So for fixed $k$,

$\displaystyle \frac{ka}{b} - 1 < \left\lfloor\frac{ka}{b}\right\rfloor < \frac{ka}{b}$,

$\displaystyle \frac{(b-k)a}{b} - 1 < \left\lfloor\frac{(b-k)a}{b}\right\rfloor < \frac{(b-k)a}{b}$.

Adding the two inequalities, we get

$\displaystyle a - 2 < \left\lfloor\frac{ka}{b}\right\rfloor + \left\lfloor\frac{(b-k)a}{b}\right\rfloor < a$.

This forces

$\displaystyle \left\lfloor\frac{ka}{b}\right\rfloor + \left\lfloor\frac{(b-k)a}{b}\right\rfloor = a - 1$

Therefore

$\displaystyle \left\lfloor\frac{a}{b}\right\rfloor + \left\lfloor\frac{2a}{b}\right\rfloor + \cdots + \left\lfloor\frac{(b-1)a}{b}\right\rfloor$

$\displaystyle = \dfrac{\left\lfloor\frac{a}{b}\right\rfloor + \left\lfloor\frac{(b-1)a}{b}\right\rfloor}{2} + \dfrac{\left\lfloor\frac{2a}{b}\right\rfloor + \left\lfloor\frac{(b-2)a}{b}\right\rfloor}{2} + \cdots + \dfrac{\left\lfloor\frac{(b-1)a}{b}\right\rfloor + \left\lfloor\frac{a}{b}\right\rfloor}{2}$

$\displaystyle = \frac{a-1}{2} + \frac{a-1}{2} + \cdots + \frac{a-1}{2} (b-1\; \text{times})$

$\displaystyle = \frac{(a-1)(b-1)}{2}$.

Wow...what terrific solution, so impressively laid out...well done, Euge! And thanks for participating.:)

I have at hand a solution that tackles the problem entirely differently and I would post it days later, in case there are more members want to play with this problem.
 
Solution of other:

The statement involves two independent variables, $a$ and $b$ and $\dfrac{a}{b},\,\dfrac{2a}{b},\,\dfrac{3a}{b},\cdots,$ respectively. We might want to approach it using geometry approach.

Consider the case $a=5$ and $b=7$. The points $(k,\,\dfrac{5k}{7})$ where $k=1,\,2,\,\cdots,\,6$ each lie on the line $y=\dfrac{5k}{7}$ and $\displaystyle \sum_{k=1}^6\left\lfloor\dfrac{5k}{7} \right\rfloor$ equals the number of lattice points interior to the triangle with vertices $(0,\,0)$, $(7,\,0)$ and $(7,\,5)$. By symmetry, this number is one-half the number of lattice points in the rectangle with vertices $(0,\,0)$, $(0,\,5)$, $(7,\,0)$ and $(7,\,5)$. There are $4\times 6=24$ lattice points in that rectangle, which means the triangle with vertices $(0,\,0)$, $(7,\,0)$ and $(7,\,5)$ contains 12 interior lattice points.

The same goes through in the general case. The condition that $a$ and $b$ have no common factor assures us that none of the lattice points in the interior of the rectangle will fall on the line $y=\dfrac{ax}{b}$. Thus,

$\displaystyle \sum_{k=1}^{b-1}\left\lfloor\dfrac{ka}{b} \right\rfloor=\dfrac{\text{total number of lattice poins in the interior of the rectangle}}{2}=\frac{(a-1)(b-1)}{2}$.
 
Interestingly done anemone. Reminds me of a post I made long ago in http://mathhelpboards.com/number-theory-27/quadratic-reciprocity-9722.html at the number theory forum.
 
Seemingly by some mathematical coincidence, a hexagon of sides 2,2,7,7, 11, and 11 can be inscribed in a circle of radius 7. The other day I saw a math problem on line, which they said came from a Polish Olympiad, where you compute the length x of the 3rd side which is the same as the radius, so that the sides of length 2,x, and 11 are inscribed on the arc of a semi-circle. The law of cosines applied twice gives the answer for x of exactly 7, but the arithmetic is so complex that the...
Is it possible to arrange six pencils such that each one touches the other five? If so, how? This is an adaption of a Martin Gardner puzzle only I changed it from cigarettes to pencils and left out the clues because PF folks don’t need clues. From the book “My Best Mathematical and Logic Puzzles”. Dover, 1994.
Thread 'Imaginary Pythagoras'
I posted this in the Lame Math thread, but it's got me thinking. Is there any validity to this? Or is it really just a mathematical trick? Naively, I see that i2 + plus 12 does equal zero2. But does this have a meaning? I know one can treat the imaginary number line as just another axis like the reals, but does that mean this does represent a triangle in the complex plane with a hypotenuse of length zero? Ibix offered a rendering of the diagram using what I assume is matrix* notation...
Back
Top