liveBook · Manning

Mantissa

As explained in Quantization and Fast Inference

The part of a floating-point representation that stores the number's significant digits.

A mantissa stores a floating-point number’s significant digits. In the representation value = mantissa × 2^exponent, the exponent sets the scale; the mantissa carries the detail at that scale. section 2.1

This moving scale lets one format represent both small and large values: a fixed-point grid fine enough for small numbers may overflow on large ones, while a grid sized for large values can erase small ones. Mantissa precision is therefore distinct from the range enabled by the exponent. section 2.1

Quantizing a toy mantissa

With four fractional bits, the mantissa is rounded to multiples of 1/16. For 0.10 ≈ 1.60 × 2⁻⁴, rounding 1.60 to 1.625 gives a reconstructed value of 0.1015625. section 2.1

Table 2.2 Quantize only the mantissa to the nearest multiple of 1/16
True Value
(Approx) mantissa × 2^exp
Quantized mantissa
Reconstructed value
0.01
1.28 × 2⁻⁷
1.3125 × 2⁻⁷
0.01025390625
0.10
1.60 × 2⁻⁴
1.6250 × 2⁻⁴
0.1015625
1.00
1.00 × 2⁰
1.0000 × 2⁰
1.0
3.00
1.50 × 2¹
1.5000 × 2¹
3.0

Compare the original and reconstructed values to see how mantissa rounding affects numbers at different exponents. section 2.1

Floating-point’s adaptive representation supports wide magnitude ranges, but inference may not use all its precision. Its variable spacing, exponent alignment, normalization, and rounding also contribute to computation and data-movement costs. section 1.3.1

How Quantization and Fast Inference covers it

How deep it goes
Derives mantissa quantization with a toy binary format and numerical examples, while stopping short of IEEE-754 encoding details.
Examples
Uses a four-fractional-bit toy format to reconstruct 0.01, 0.10, 1.00, and 3.00 after mantissa quantization.
What you can do after
Understand how exponent-dependent spacing preserves detail across magnitudes and how mantissa rounding changes represented values.
How it connects
Links mantissa precision to exponents, floating-point, fixed-point, and quantization.

Also explained in

Compare how 7 books explain mantissa →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Quantization and Fast Inference. The section links point to the parts of the book it draws on.