This library holds a great source of functions (that are still being added to) to help you manipulate numbers in Lua so they can be easier to work with.
math.abs math.acos math.max math.min math.random math.pi math.sqrt