math


Fields

math provides one field, pi. It is equivalent to 3.141592653589793.

Methods

Here are the methods provided by this builtin that should be used in an expression rather than as a statement:

Method name Method parameters Method description
round x Rounds x to the nearest integer
abs x Absolute value of x
floor x Rounds x down
ceil x Rounds x up
sqrt x Square root of x
sin x Sine of x
cos x Cosine of x
tan x Tangent of x
asin x Arcsine of x
acos x Arccosine of x
atan x Arctangent of x
log x Natural logarithm of x
log10 x Base-10 logarithm of x
exp x Raises e to the x power
exp10 x Raises 10 to the x power

All trigonometric functions are evaluated in degrees.