Version:

Computes the base 2 logarithm of the input elements.

## Syntax

c = log2(a)
[f, e] = log2(a)

## a

Scalar or array of any dimension of floating point or complex numbers.

## c

Base 2 logarithm of the elements in a. c returns complex numbers for negative or complex elements in a. c is an array of the same size as a.

## f

Binary mantissa of the elements in a. f is an array of the same size as a.

## e

Binary exponent of the elements in a. e is an array of the same size as a.