Puzzles
Integer part
Let \(\lfloor x\rfloor \) denote the integer part of \(x\) (eg. \(\lfloor 7.8\rfloor =7\)).
When are the following true:
a) \(\lfloor x+1\rfloor = \lfloor x\rfloor + 1\)
b) \(\lfloor nx\rfloor = n\lfloor x\rfloor\) (where \(n\) is an integer)
c) \(\lfloor x+y\rfloor = \lfloor x\rfloor +\lfloor y\rfloor \)
d) \(\lfloor xy\rfloor = \lfloor x\rfloor \lfloor y\rfloor \)
Show answer & extension
Hide answer & extension
a) Always
b) When \(n<\frac{1}{f_x}\), where \(f_x\) is the fractional part of \(x\).
c) When the fractional parts of \(x\) and \(y\) add up to less than one.
d) Let \(f_x\) and \(f_y\) be the fractional parts of \(x\) and \(y\) (respectively).
$$\lfloor xy\rfloor = \lfloor (\lfloor x\rfloor +f_x)(\lfloor y\rfloor +f_x)\rfloor $$
$$=\lfloor \lfloor x\rfloor \lfloor y\rfloor +f_x\lfloor y\rfloor +f_y\lfloor x\rfloor +f_yf_x\rfloor $$
$$=\lfloor x\rfloor \lfloor y\rfloor +\lfloor f_x\lfloor y\rfloor +f_y\lfloor x\rfloor +f_yf_x\rfloor $$
This will be equal to \(\lfloor x\rfloor \lfloor y\rfloor \) when \(\lfloor f_x\lfloor y\rfloor +f_y\lfloor x\rfloor +f_yf_x\rfloor =0\).
For this to be true, it is necessary (but not sufficient) that \(f_y<\frac{1}{x}\) and \(f_x<\frac{1}{y}\).
Extension
Show that
$$\lfloor x\rfloor +\left\lfloor x+\frac{1}{n}\right\rfloor +\left\lfloor x+\frac{2}{n}\right\rfloor +...+\left\lfloor x+\frac{n-1}{n}\right\rfloor =\lfloor nx\rfloor.$$