Section 3: Floating-Point Numbers Flashcards
1
Q
Q: What is the structure of an IEEE-754 single-precision floating-point number?
A
A:
1. 1-bit sign (0 = positive, 1 = negative).
2. 8-bit exponent (biased by 127).
3. 23-bit mantissa (fraction part, with an implicit leading 1).
2
Q
Q: How is the exponent represented in IEEE-754?
A
A: By adding a bias (e.g., 127 for single precision) to the actual exponent value.
3
Q
Q: How is the number −2.625^10 represented in IEEE-754?
A
A:
1. Sign = 1 (negative).
2. Normalized binary: 10.10102→1.010102⋅2110.10102→1.010102⋅21.
3. Exponent: 1+127=128→100000002.
4. Mantissa: 010100…(fill23bits).
Binary: 1 10000000 01010000000000000000000.