Skip to main content
Mathematics LibreTexts

1.7: Special Numbers

  • Page ID
    96033
  • \( \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}}\)

    \begin{array}{ll}\text{Smallest exponent: }\quad \mathrm{e}=00000000 \text{, represents denormal numbers} (1.f \rightarrow 0.f) \end{array}

    \begin{array}{ll}\text{Largest exponent: } \quad &\mathrm{e}=11111111 \text{, represents } \pm \infty \text{, if } \mathrm{f}=0 \\
    &\mathrm{e}=11111111 \text{, represents } \mathrm{NaN} \text{, if } \mathrm{f} \neq 0 \end{array}


    \begin{array}{ll}\text { Number Range: } & \mathrm{e}=11111111=2^{8}-1= \quad \quad &\text{reserved}\\ 
    & \mathrm{e}=00000000=0 \quad \quad &\text{reserved}\\ 
    \text { so, } & \mathrm{p}=\mathrm{e}-127 \text { is } \\ 
    & 1-127 \leq \mathrm{p} \leq 254-127 \\ & -126 \leq \mathrm{p} \leq 127\end{array}

    \begin{array}{ll}\text{Smallest positive normal number} \\
    &= 1.00000000 \cdots \cdot .0000 \times 2^{-126} \\
    &\simeq 1.2 \times 10^{-38} \\
    &\text{bin: 00000000100000000000000000000000} \\
    &\text{hex: 00800000}\\
    &\text{MATLAB: realmin('single')}
    \end{array}

    \begin{array}{ll}\text{Largest positive number} \\
    &=1.11111111 \cdots \cdots \cdot 1111 \times 2^{127} \\
    &=\left(1+\left(1-2^{-23}\right)\right) \times 2^{127} \\
    &\simeq 2^{128} \simeq 3.4 \times 10^{38} \\
    &\text{bin: 01111111011111111111111111111111} \\
    &\text{hex: 7f7fffff} \\
    &\text{MATLAB: realmax('single')} \\
    \end{array}

    \begin{array}{ll}\text{Zero} \\
    &\text{bin: 0000 0000 0000 0000 0000 0000 0000 0000} \\
    &\text{hex: 00000000}
    \end{array}

    \begin{array}{ll}\text{Subnormal numbers} \\
    &\text{Allow 1.f } \rightarrow \text{ (in software)} \\
    &\text{Smallest positive number }=0.00000000 \cdots \cdots 0001 \times 2^{-126}\\
    &=2^{-23} \times 2^{-126} \simeq 1.4 \times 10^{-45}
    \end{array}


    This page titled 1.7: Special Numbers is shared under a CC BY 3.0 license and was authored, remixed, and/or curated by Jeffrey R. Chasnov via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.