FUNCTION REFERENCE

pow2

Power of two.

Power of two.

Syntax

pow2(X)

Syntax

pow2(F, E)

pow2(X) gives 2.^X. pow2(F,E) gives F.*2.^E, with E truncated toward zero.

Example

pow2(3)   % 8

Differences from MATLAB: Real double 2-D arrays, one output. F and E must have equal shapes or one must be a scalar.

These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.