Ceiling

Use

The Ceiling() function returns the next highest multiple, rounding up towards infinity.

The default multiple is 1, but the optional second input specifies a multiple to be rounded to. E.g. Ceiling(5.6, 0.25) = 5.75. The multiple is expected to be unitless.

Units

Numbers with units will be rounded based on those units. This means that the unit a number has at the point of calculation will affect the answer.

For example, Ceiling(5.8ft) to mm and Ceiling(5.8 ft to mm) will return values that are not equal.

Examples
  • Ceiling(1.8)  = 2
  • Ceiling(1.8, 0.7)  = 2.1
  • Ceiling(1.2)  = 2
  • Ceiling(-1.8)  = -1
  • Ceiling(3.2 ft)  = 4ft
  • Ceiling(3.2 ft) to mm  = 1219.2 mm
  • Ceiling(3.2 ft to mm)  = 976 mm
  • Ceiling(5.33 ft, 0.25)  = 5.5 ft
  • Ceiling(5.33 ft to ft in, 0.25)  = 5 ft 4 in

Function

Ceiling(value)

value

Ceiling(value, multiple)

value
multiple

Ceiling is included by default in each file as part of the Math library.

 

See also: