Math Functions
abs
Returns the absolute value of x.
Examples:
Supported Signatures
acos
Returns the arc cosine of x.
Examples:
Supported Signatures
asin
Returns the arc sine of x.
Examples:
Supported Signatures
atan
Returns the arc tangent of x.
Examples:
Supported Signatures
atan2
Returns the arc tangent of y / x.
Examples:
Supported Signatures
cbrt
Returns the cube root of x.
Examples:
Supported Signatures
ceil
This is an alias for ceiling().
Examples:
Supported Signatures
ceiling
Returns x rounded up to the nearest integer.
Supported Signatures
cos
Returns the cosine of x.
Examples:
Supported Signatures
cosh
Returns the hyperbolic cosine of the given value.
Examples:
Supported Signatures
degrees
Converts angle x in radians to degrees.
Examples:
Supported Signatures
exp
Returns Euler’s number raised to the power of x.
Examples:
Supported Signatures
floor
Returns x rounded down to the nearest integer.
Supported Signatures
is_nan
Determine if x
is not-a-number.
Examples:
Supported Signatures
ln
Returns the natural logarithm of x.
Examples:
Supported Signatures
log
Returns the base b logarithm of x.
Examples:
Supported Signatures
log10
Returns the base 10 logarithm of x.
Examples:
Supported Signatures
log2
Returns the base 2 logarithm of x.
Examples:
Supported Signatures
mod
Returns the modulus (remainder) of n divided by m.
Supported Signatures
pi
Returns the constant Pi.
Examples:
Supported Signatures
pow
This is an alias for power().
Supported Signatures
power
Returns x raised to the power of p.
Examples:
Supported Signatures
radians
Converts angle x in degrees to radians.
Examples:
Supported Signatures
rand
This is an alias for random().
Supported Signatures
Note: rand() is volatile, i.e. might return a different value for the same input.
random
Returns a pseudo-random value in the range 0.0 <= x < 1.0.
Examples:
Supported Signatures
Note: random() is volatile, i.e. might return a different value for the same input.
round
Returns x rounded to the nearest integer.
Examples:
Supported Signatures
sign
Returns the signum function of x, that is.
Supported Signatures
sin
Returns the sine of x.
Examples:
Supported Signatures
sinh
Returns the hyperbolic sine of x.
Examples:
Supported Signatures
sqrt
Returns the square root of x.
Examples:
Supported Signatures
tan
Returns the tangent of x.
Examples:
Supported Signatures
tanh
Returns the hyperbolic tangent of x.
Examples:
Supported Signatures
truncate
Returns x rounded to integer by dropping digits after decimal point.
Examples:
Supported Signatures