bit_getΒΆ
bit_get returns a bit value.
-
b = bit_get(m, nBit)
-
b = bit_get(m, nBit, cast)
Return Value
b is 0 (bit not set) or 1 (bit set).
Parameters
-
m
m ist eine Matrix.
-
nBit
nBit is the bit position starting with 0. For 32-Bit values all bits can be used (0..31). For 64 bit values only the bits 0 to 52 can be used.
-
cast
cast is one of the following values:
CAST_INT8 (0) CAST_UINT8 (1) CAST_INT16 (2) CAST_UINT16 (3) CAST_INT32 (4) CAST_UINT32 (5) CAST_INT64 (6) CAST_UINT64 (7) default value.
Comment
UniScript uses double precision floating-point values. When casted to a
CAST_INT64
or CAST_UINT64
only the lower 53 Bits
(Bit 0 .. Bit 52) can be used.
Example
b = bit_get(m, 50)
History
Version | Description |
---|---|
R2013.10 | New. |
See also
Overview Bit Functions, bit_set, bit_and, bit_or, bit_xor, bit_not, bit_lshift, bit_rshift
id-230125