In
mathematics and
computer science, the
floor and
ceiling functions map a
real number to the largest previous or the smallest following
integer, respectively. More precisely, floor(
x) =
is the largest integer not greater than
x and ceiling(
x) =
is the smallest integer not less than
x.