Floating-Point Basics: Binary Normalisation, Worked Examples and Exam Patterns

Connect sign, significand, exponent and bias through one continuous toy-format example. Then see exactly why 0.1 needs rounding and how spacing changes with scale.

KnowledgeGate Team

Exam prep & CS education

Updated 11 Sep 20265 min read

A floating-point word looks like an arbitrary row of bits until sign, significand, exponent and bias are connected to one value formula. The same toy-format example converts, encodes, decodes and checks -13.25, then rounds 0.1 precisely. A 10-bit toy format makes those relationships explicit; IEEE 754 uses different field widths and reserved exponent patterns.

Floating-point representation stores scale as well as digits

Scientific notation separates digits from scale: 6250 = 6.25 x 10^3. Binary floating point uses the same idea with base 2:

value = (-1)^s x significand x 2^e

Here, s controls the sign, the significand carries the significant binary digits, and e sets the scale. The significand is often informally called the mantissa. Normalisation moves the binary point to a standard position and adjusts the exponent, without changing the value.

Normalised non-zero binary values follow this form:

(-1)^s x 1.f x 2^(E - bias)

f is the stored fraction, E is the unsigned stored exponent, and the actual exponent is e = E - bias. The leading 1 is implicit only for normalised non-zero values.

Fixed point stores the point at a fixed position: 1101.01₂ = 13.25. Floating point stores the same value as a significand and scale: 1.10101₂ x 2^3.

Binary normalisation of 13.25, step by step

Convert the integer and fraction separately:

  • 13 = 8 + 4 + 1 = 1101₂.

  • 0.25 x 2 = 0.5, so the first fractional bit is 0.

  • 0.5 x 2 = 1.0, so the next fractional bit is 1.

Therefore, 0.25 = 0.01₂, and 13.25 = 1101.01₂. Move the point three places left:

1101.01₂ = 1.10101₂ x 2^3

Check the magnitude by expanding it:

1.10101₂ = 1 + 1/2 + 1/8 + 1/32 = 1.65625

Then 1.65625 x 8 = 13.25. Apply the sign separately:

-13.25 = (-1)^1 x 1.10101₂ x 2^3

Normalise the magnitude first. A negative sign does not mean taking two's complement of the entire word.

Encode and decode -13.25 in a toy floating-point format

Fix the format as 1 sign bit, 4 exponent bits with bias 7, and 5 fraction bits: s | EEEE | fffff. The toy format is defined for normalised finite values. The all-zero and all-one exponent patterns have no assigned IEEE meaning in this toy format.

For -13.25, the normalised form gives:

  1. Sign: s = 1.

  2. Actual exponent: e = 3.

  3. Stored exponent: E = e + bias = 3 + 7 = 10 = 1010₂.

  4. Stored fraction: write 1.10101₂, omit the implicit leading 1, and store f = 10101.

The complete 10-bit word is 1 | 1010 | 10101.

Now decode it independently. E = 1010₂ = 10, so e = 10 - 7 = 3. The significand 1.10101₂ is 1.65625. Therefore:

(-1)^1 x 1.65625 x 2^3 = -1.65625 x 8 = -13.25

The toy-format word 1 | 1010 | 10101 broken into sign, stored exponent 10 and fraction 10101, decoding to -13.25.

Precision, spacing and why decimal 0.1 is rounded

Five stored fraction bits give six bits of significand precision because the leading 1 is implicit. At e = 0, adjacent normalised values include 1.00000₂ = 1 and 1.00001₂ = 1.03125. Their gap is 2^-5 = 0.03125.

At e = 3, that gap scales to 2^(3-5) = 0.25. The next representable value after 8.0 is therefore 8.25.

Decimal 0.1 repeats in binary:

0.1₁₀ = 0.0001100110011...₂ = 1.100110011...₂ x 2^-4

Keep the five fraction bits 10011. The next discarded bit is 0, so round-to-nearest leaves 1.10011₂ x 2^-4 unchanged. Its value is:

1.10011₂ = 1 + 1/2 + 1/16 + 1/32 = 1.59375

1.59375 / 16 = 0.099609375

The absolute error is 0.1 - 0.099609375 = 0.000390625. This result belongs to the stated toy format and rounding mode, not to the default encoding of a production language.

Two binary number lines showing the spacing widen from 0.03125 near 1 to 0.25 near 8, with decimal 0.1 rounding to 0.099609375.

Range, zero and special values need separate rules

Exponent width mainly controls range, fraction width controls precision, and spacing depends on both precision and the current exponent. In this toy format, every exponent pattern represents a normalised finite value, so zero, subnormal, infinity and NaN require separate rules.

IEEE-style formats distinguish several categories. For actual standard layouts and bit patterns, Floating point representation: IEEE 754 format works through encoding and arithmetic, while Floating Point in COA: IEEE 754 Worked Examples focuses on standard bit-field encode-decode examples. The 10-bit model here isolates bias, precision and spacing without IEEE 754's reserved exponent semantics.

Category

Leading-bit treatment

Purpose

Normalised finite

Implicit leading 1

Ordinary non-zero finite values

Subnormal

No implicit leading 1

Values close to zero

Zero

Not a normalised significand

Exact signed zero

Infinity

Special category

Overflow or infinite results

NaN

Special category

Invalid or undefined numeric results

Floating-point traps that produce plausible wrong answers

The most common errors are procedural:

  • Treating stored E as actual e. First read 1010₂ = 10, then subtract: e = 10 - 7 = 3.

  • Storing the leading 1. In 1.10101₂, store only 10101 for a normalised value.

  • Applying two's complement. Set s = 1 and retain the magnitude fields 1010 | 10101.

  • Stopping after rounding. Decode 1 | 1010 | 10101 back to -13.25, and decode the approximation of 0.1 to 0.099609375.

  • Assuming every decimal fraction is inexact. 0.5 = 0.1₂ and 0.25 = 0.01₂ terminate exactly, while 0.1₁₀ repeats.

Use three checks every time: confirm normalisation, subtract the bias correctly, and reverse-decode the final word.

Floating-point exam patterns: conversion, encoding and spacing

Recurring question forms include decimal-to-binary conversion, normalisation, biased-exponent encoding, decoding bit fields, identifying exact versus rounded values, and finding the next representable number.

Try these timed self-checks:

  • Check A: Decode 0 | 1001 | 01000. Here E = 9, e = 9 - 7 = 2, and 1.01000₂ = 1.25. The value is 1.25 x 4 = 5.0.

  • Check B: What follows 8.0 in this format? The gap at e = 3 is 0.25, so the answer is 8.25.

  • Check C: Which of 0.5, 0.25 and 0.1 are exact? The first two terminate in binary. 0.1 repeats and must be rounded.

For a full problem, follow this order:

  1. Identify the field convention.

  2. Convert and normalise.

  3. Add the bias when encoding or subtract it when decoding.

  4. Apply the sign.

  5. Decode once as a check.

Addressing Modes and Instruction Formats is a separate next step for decoding instruction fields in computer organisation.

Floating-point basics: the short version and next step

The chain is compact: 13.25 = 1.10101₂ x 2^3; bias 7 turns actual exponent 3 into stored 10 = 1010₂; and 1 | 1010 | 10101 decodes to -13.25. With five fraction bits, decimal 0.1 becomes 0.099609375 in this toy format.

Once you can reverse-decode an answer, practise by changing the sign, exponent and fraction fields and checking each decoded value. For a sequenced CS study path, use GATE Guidance by Sanchit Sir, or browse the wider GATE CS Exam Preparation Courses & Test Series category.