DOCUMENTATION CENTER SEARCH
Mathematica
>
Bitwise Operations
>
Built-in
Mathematica
Symbol
Integer and Number Theoretic Functions
Tutorials »
|
BitSet
BitClear
BitLength
IntegerDigits
Part
See Also »
|
Bitwise Operations
Cryptographic Number Theory
New in 6.0: Number Theory & Integer Functions
More About »
BitGet
BitGet
[
n
,
k
]
gets the bit corresponding to the coefficient of
in the integer
n
.
MORE INFORMATION
BitGet
[
n
,
k
]
gets the bit
k
places from the right.
BitGet
represents the bits it retrieves as 0 or 1.
EXAMPLES
CLOSE ALL
Basic Examples
(1)
Display coefficients at powers of 2 in the integer 42:
In[1]:=
Out[1]=
Get the bit corresponding to the coefficient at
2
0
:
In[2]:=
Out[2]=
Get the bit corresponding to the coefficient at
2
3
:
In[3]:=
Out[3]=
SEE ALSO
BitSet
BitClear
BitLength
IntegerDigits
Part
TUTORIALS
Integer and Number Theoretic Functions
MORE ABOUT
Bitwise Operations
Cryptographic Number Theory
New in 6.0: Number Theory & Integer Functions
New in 6
© 2008 Wolfram Research, Inc.