phobos ~master (2024-10-03T07:50:27Z)
Dub
Repo
log2
std
math
exponential
Calculates the base-2 logarithm of x:
log
2
x
Special Values
x
log2(x)
divide by 0?
invalid?
±0.0
-∞
yes
no
<0.0
NaN
no
yes
+∞
+∞
no
no
real
log2
(real x)
double
log2
(double x)
pragma(
inline
, true) @
safe
pure nothrow @
nogc
double
log2
(
double
x
)
float
log2
(float x)
Meta
Source
See Implementation
std
math
exponential
aliases
FP_ILOGB0
FP_ILOGBNAN
functions
exp
exp2
expm1
frexp
ilogb
ldexp
log
log10
log1p
log2
logb
pow
powmod
scalbn
Calculates the base-2 logarithm of x: log2x