Functions 3-13
Examples: 5.1 = 5, 2.3 = 2, 8.6 = 8, -3.2 = -4, -7.1 = -8, √5 = 2, -2 = -2.
The domain of floor function is R and its range is Z.
3.7.3 Ceiling Function
The ceiling function g: R → R is defined by g(x) = x, when x is the least integer greater than
or equal to x. Thus, g(x) = x = n, where n - 1 < x ≤ n.
Examples: 5.1 = 6, 2.3 = 3, 8.6 = 9, -3.2 = -3, -7.1 = -7, √5 = 3, -2 = -2.
Note 3.1 The floor and ceiling functions are often used in the study of algorithms. The floor of x
rounds down x while ceiling of x rounds up. If x is not an integer, then the floor of x is the nearest
integer to the left of x and ceiling of x is the nearest integer to the right of x. The programming
languages C and ...