Skip to content
Free public beta until December 4, 2026: every course is open, no card needed. After that, the first chapter of each course stays free and full access is a one-time $39 ($19 for up to 100 founding members chosen for helpful feedback). Your progress is kept. How the beta works

fixed-point number

A whole number with an agreed scale, so that it can stand for a fraction without floating-point hardware.

A fixed-point number stores a value v as the integer q = v × 2^n for a fixed number of fraction bits n, so addition is integer addition and a product must be shifted right by n to return to the same scale.

Examples

  • 21.5 °C stored as the integer 5504 with an agreed scale of 256 lets the ESP32-C6, which has no floating-point unit, filter it with integer instructions.

  • Two Q15 numbers 0.5 × 0.5 multiply as (16384 * 16384 + 2^14) >> 15 = 8192, which is 0.25.

Read the full section →