Math functions Flashcards
abs()
return absolute value
exp()
calculate exponent of e
fmod()
returns the floating point remainder (modulo) of the division
log10()
base-10 logarithm
log()
natural logarithm
max()
find highest value
min()
find lowest value
pi()
get value of pi
pow(base, exp)
exponential expression
sqrt()
square root
is_finite()
check finite value
is_infinite()
check infinite value
is_nan()
check not a number
base_convert()
convert number between bases
decbin()
convert to binary
bindec()
convert to decimal
dechex()
convert to hexadec
hexdec()
convert to decimal
decoct()
convert to octal
octdec()
convert to decimal
deg2rad()
convert to radian
rad2deg()
convert to degree
getrandmax()
show largest possible random value
mt_getrandmax()
show largest possible random value
rand()
generate a random integer
mt_rand()
generate a random integer
srand()
seed the random generator
mt_srand()
seed the random generator
lcg_value()
returns a pseudo random number in the range of (0, 1)
ceil()
round fractions up
floor()
round fractions down
round()
round a float
sin()
sine
sinh()
hyperbolic sine
asin()
arc sine
asinh()
inv. hyperbolic sine
cos()
cosine
cosh()
hyperbolic cosine
acos()
arc cosine
acosh()
inv. hyperbolic cosine
tan()
tangent
tanh()
hyperbolic tangent
atan()
arc tangent
atanh()
inv. hyperbolic tangent
atan2()
arc tangent of 2 var
hypot()
calculate hypotenuse