Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

1And in Conclusion…\dots

The IEEE 754 standard defines a binary representation for floating point values using three fields.

"IEEE 754 single-precision field layout across 32 bits: 1 sign bit at the most significant position, 8 exponent bits, and 23 significand bits."

Single-Precision (32-bit) Floating Point Representation (reprint of Figure 3 from this section). The leftmost bit is the most significant bit; the rightmost bit is the least significant bit.

Value=(−1)Sign×2Exp−Bias×1.Significand2\text{Value} = (−1)^{\text{Sign}} × 2^{\text{Exp}-\text{Bias}} × 1.\text{Significand}_2
Value=(−1)Sign×2Exp−Bias+1×0.Significand2\text{Value} = (−1)^{\text{Sign}} × 2^{\text{Exp}-\text{Bias}+1} × 0.\text{Significand}_2

When translating between binary and decimal floating point values, we must remember that there is a bias for the exponent.

Biased ExponentSignificand fieldDescription
0 (0000000)all zeroszero
0 (0000000)nonzeroDenormalized numbers, aka denorms
1 – 254anythingNormalized floating point (mantissa has implicit leading 1)
255 (1111111)all zerosinfinity
255 (1111111)nonzeroNaNs

The IEEE 754 single-precision exponent field has values from 0 to $255 (reprint of Table 1 from this section).

2Textbook Readings

P&H 3.5, 3.9

3Additional References

4Exercises

Check your knowledge!

4.1Conceptual Review