Skip to content

Latest commit

 

History

History
26 lines (18 loc) · 547 Bytes

std-math.md

File metadata and controls

26 lines (18 loc) · 547 Bytes

Math Standard Library

The math standard library will be called math.

math.abs(x)

Returns the absolute value of x. (int/float)

math.exp(x)

Returns e to the power of x.

math.log(x)

Natural log of x

math.pi

Returns the value of π.

math.sqrt(x)

Square root of x.

math.acos(x), math.asin(x), math.atan(x), math.cos(x), math.sin(x), math.tan(x)

Standard trig functions, in radians.

math.ceil(x), math.floor(x)

Ceiling and floor functions.

math.deg(x), math.rad(x)

Covert between radians and degrees.