# Is there some nomenclature to get the integer value of a fraction?

There is some math nomenclature to represent the integer value of a fraction?

Say,

$$x \in \mathbb{R},\, \textbf{foo}(x) = \text{integer part of }x$$

Then

$$x = 1.823,\, \textbf{foo}(x) = 1$$

• Worth noting is that this isn't the "integer value" of the fraction. It is the fraction truncated to the nearest integer. Commented Jun 6, 2013 at 14:02
• @ZettaSuro, not the nearest integer, surely, as the nearest integer to $1.823$ is $2$. Commented Jun 6, 2013 at 14:04
• @vadim123 but then that wouldn't be truncating, so $1$ would be the nearest integer that $1.823$ can be truncated to. Commented Jun 6, 2013 at 14:07

The integer part of $x$ is given by the somewhat ugly-looking $$\text{sgn}(x)\lfloor |x| \rfloor$$ which some authors abbreviate as $[x]$. $\text{sgn}(x)$ denotes the signum function. The floor function $\lfloor\cdot\rfloor$works as expected for positive $x$, but $\lfloor -1.5\rfloor=-2$, which is not the expected $-1$ integer part of $-1.5$.