X = pow2(Y)X = pow2(F
X = pow2(Y)returns a matrix
Xwhose elements are the corresponding elements of
Yraised to the power 2.
Ycan also be a vector or a scalar.
X = pow2(F,E), for a real matrix
F and a matrix of integers
X(i,j) = F(i,j).*
(2.^E(i,j)). The result is computed quickly by simply adding
E to the floating-point exponent of
This function corresponds to the ANSI C function
ldexp() and the IEEE floating-point standard function
X = pow2(F,E)yields the following values:
F E X
1/2 1 1
pi/4 2 pi
-3/4 2 -3
1/2 -51 eps
1-eps/2 1024 realmax
1/2 -1021 realmin
(c) Copyright 1994 by The MathWorks, Inc.