Changing signed integer 16 bit format to binary format.

9 次查看(过去 30 天)
How can I express the BIGGEST NEGATIVE number and SMALLEST POSITEVE number of a signed integer 16 bit format?
I know the range of singed integer 16 bit format is from -32768 to 32767, but...
Q1.I am not sure which value is the biggest negative and smallest positive.
Q2. Also, if there is negative integer value, how can I convert negative to binary?

采纳的回答

Walter Roberson
Walter Roberson 2020-4-14
dec2bin(typecast(intmin('int16'),'uint16'))
dec2bin(typecast(intmax('int16'),'uint16'))
  6 个评论

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Workspace Variables and MAT-Files 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by