math
module reference
index
- Modulo operator.
- Multiply values.
- Add values.
- Subtract values.
- Divide values.
- Raise to a power.
- Get the absolute value.
- Inverse cosine function (radians).
- Add values.
- Inverse sine function (radians).
- Inverse tangent function (radians).
- Inverse tangent function (two argument version).
- Round towards positive infinity.
- Cosine function (radians).
- Hyperbolic cosine function (radians).
- Divide values.
- Check whether val is even.
- *e* number raised to a power.
- Round towards negative infinity.
- Positive infinity constant.
- Logarithm with given base.
- Logarithm with base 10.
- Find the maximum.
- Find the minimum.
- Linearly interpolate.
- Modulo operator.
- Multiply values.
- Check whether val is odd.
- The pi constant.
- Raise to a power.
- Sine function (radians).
- Hyperbolic sine function (radians).
- Square root function.
- Subtract values.
- Tangent function (radians).
- Hyperbolic tangent function (radians).
- The tau constant.
details
- Modulo operator.
(% num div)
(mod num div)
Calculate remainder of division by
div
. - Multiply values.
(* a b [c…])
(mul a b [c…])
- Add values.
(+ a b [c…])
(add a b [c…])
Sum all arguments.
- Subtract values.
(- a b [c…])
(sub a b [c…])
Subtract all other arguments from
a
. - Divide values.
(/ a b [c…])
(div a b [c…])
Divide
a
by all other arguments. - Raise to a power.
(^ base exp)
(pow base exp
Raise
base
to the powerexp
. - Get the absolute value.
(abs val)
- Inverse cosine function (radians).
(acos cos)
- Add values.
(+ a b [c…])
(add a b [c…])
Sum all arguments.
- Inverse sine function (radians).
(asin sin)
- Inverse tangent function (radians).
(atan tan)
- Inverse tangent function (two argument version).
(atan2 y x)
- Round towards positive infinity.
(ceil val)
- Cosine function (radians).
(cos alpha)
- Hyperbolic cosine function (radians).
(cosh alpha)
- Divide values.
(/ a b [c…])
(div a b [c…])
Divide
a
by all other arguments. - Check whether val is even.
(even val [div])
true
if dividingval
bydiv
has remainder zero.div
defaults to 2. - *e* number raised to a power.
(exp exp)
- Round towards negative infinity.
(floor val)
- Positive infinity constant.
- Logarithm with given base.
(log val [base])
- Logarithm with base 10.
(log10 val)
- Find the maximum.
(max a b [c…])
Return the highest of arguments.
- Find the minimum.
(min a b [c…])
Return the lowest of arguments.
- Linearly interpolate.
(mix a b i)
Interpolate between
a
andb
usingi
in range 0-1. - Modulo operator.
(% num div)
(mod num div)
Calculate remainder of division by
div
. - Multiply values.
(* a b [c…])
(mul a b [c…])
- Check whether val is odd.
(odd val [div])
true
if dividingval
bydiv
has remainder one.div
defaults to 2. - The pi constant.
- Raise to a power.
(^ base exp)
(pow base exp
Raise
base
to the powerexp
. - Sine function (radians).
(sin alpha)
- Hyperbolic sine function (radians).
(sinh alpha)
- Square root function.
(sqrt val)
- Subtract values.
(- a b [c…])
(sub a b [c…])
Subtract all other arguments from
a
. - Tangent function (radians).
(tan alpha)
- Hyperbolic tangent function (radians).
(tanh alpha)
- The tau constant.