1.8: Examples of Computer Numbers
- Page ID
- 96034
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)
What is \(1.0,2.0 \& 1 / 2\) in hex?
\(1.0=(-1)^{0} \times 2^{(127-127)} \times 1.0\)
Therefore, \(s=0, e=01111111, f=00000000000000000000000\)
bin: 00111111100000000000000000000000
hex: 3 f 800000
\(2.0=(-1)^{0} \times 2^{(128-127)} \times 1.0\)
Therefore, \(s=0, e=10000000, f=00000000000000000000000\)
bin: 010000000100000000000000000000000
hex: 40000000
\(1 / 2=(-1)^{0} \times 2^{(126-127)} \times 1.0\)
Therefore, \(s=0, e=01111110, f=00000000000000000000000\)
bin: 00111111000000000000000000000000
hex: 3f00 0000