bitget() and MSB/LSB

8 ビュー (過去 30 日間)
David C
David C 2011 年 9 月 28 日
Hi,
I would like to clarify the functionality of bitget(). In the documentation, it is noted that "The output of bitget is independent of the endian settings of the computer you are using."
Question: Would bitget(binaryVector,1) always return the LSB of binaryVector, regardless of whether my machine is big-endian or little-endian?
Thanks, David

採用された回答

Jan
Jan 2011 年 9 月 28 日
Yes. BITGET is not influenced by the endianess of the machine. Therefore bitget(x, 1) and mod(x, 2) are equivalent, if x is a non-negative integer.
  1 件のコメント
David C
David C 2011 年 10 月 2 日
Thanks Jan!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGraphics Object Properties についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by