Videos
How do I type floor function in LaTeX?
The LaTeX code for โ is \lfloor and that for โ is \rfloor. Hence, to get โxโ you can type \lfloor x \rfloor.
Is the floor function continuous?
No, the floor function is not continuous: its points of discontinuity are all integer numbers.
How do I calculate the floor of a number?
To determine the floor of a number:
- If your number is an integer, it is equal to its floor. In other words, you're done!
- If you're dealing with a non-integer, then write down the integers that are smaller than your number.
- Pick the greatest among the integers you've found in the previous step.
- That's it! You've calculated the floor of your number.
The graph is a little misleading. It only includes the "flat" parts, not the "diagonal" segments connecting them.
The complete graph is the union of the horizontal half-open segments
$$\left(\bigcup_{n\in\mathbb{N}}[n^2,n^2+n)\times\{n\}\right)\cup\left(\bigcup_{n\in\mathbb{N}}(n^2-n,n^2]\times\{-n\}\right)$$
The first union comprises segments above the x-axis, and the second comprises those below the x-axis. As you move to the right, each segment is one unit longer and one unit higher (lower, for segments below the x-axis) than the previous segment. There is a longer and longer gap between segments. Ignore the diagonal "connectors" in your graph and it is right.
floor(x/y) is the integer $n$ satisfying:
$$n \le \frac{x}{y} < n + 1$$
If $n = y$, then:
$$y \le \frac{x}{y} < y + 1$$
If $y > 0$, then:
$$y^2 \le x < y^2 + y$$ $$\frac{-1 + \sqrt{1+4x}}{2} < y \le \sqrt{x}$$
If $y < 0$, then:
$$y^2 \ge x > y^2 + y$$ $$y^2 + y < x \le y^2$$ $$-\sqrt{x} \le y < \frac{-1 - \sqrt{1+4x}}{2}$$
So, you get a graph that's similar to $y = \pm \sqrt{x}$ (with both positive and negative branches), except that $y$ takes on only nonzero integer values.