Binary logarithm

Exponent of a power of two

Binary logarithm

In mathematics, the binary logarithm (log2 n) is the power to which the number 2 must be raised to obtain the value n. That is, for any real number x, x = log 2 ⁡ n ⟺ 2 x = n . {\displaystyle x=\log _{2}n\quad \Longleftrightarrow \quad 2^{x}=n.} For example, the binary logarithm of 1 is 0, the binary logarithm of 2 is 1, the binary logarithm of 4 is 2, and the binary logarithm of 32 is 5.

From Wikipedia, under CC BY-SA. More on occurri.