Download Sysquake User Manual

Transcript
LME Reference — logical functions
485
Syntax
v = bitall(A)
v = bitall(A,dim)
b = bitall(v)
Description
bitall(A) performs a bitwise AND on the elements of the columns
of array A, or the elements of a vector. If a second argument dim is
provided, the operation is performed along that dimension. A can be
a double or an integer array. For double arrays, bitall uses the 32
least-significant bits.
Examples
bitall([5, 3])
1
bitall([7uint8, 6uint8; 3uint8, 6uint8], 2)
2x1 uint8 array
6
2
See also
bitany, all, bitand
bitand
Bitwise AND.
Syntax
c = bitand(a, b)
Description
Each bit of the result is the binary AND of the corresponding bits of the
inputs.
The inputs can be scalar, arrays of the same size, or a scalar and
an array. If the input arguments are of type double, so is the result,
and the operation is performed on 32 bits.
Examples
bitand(1,3)
1
bitand(1:6,1)
1 0 1 0 1 0
bitand(7uint8, 1234int16)
2int16