Logo
All chapters
Volume II: Digital Logic  ›  Combinational Logic

Decimal Adder (BCD)

Adds decimal digits in BCD, correcting by +6 when a digit exceeds 9.

PrevBinary Adder–Subtractor
NextBinary Multiplier

Description

An adder that keeps results in binary-coded-decimal form. Financial and display systems compute directly in decimal to avoid rounding. Add as 4-bit binary; if the digit exceeds 9 (or carries), add 6 to correct it.

  • Valid BCD digits are 0000–1001; binary sums can reach 1111.
  • If the sum is 1010–1111 or produces a carry, add 0110 (6).
  • The correction generates the proper decimal carry to the next digit.
  • What: An adder that keeps results in binary-coded-decimal form.
  • Why: Financial and display systems compute directly in decimal to avoid rounding.
  • How: Add as 4-bit binary; if the digit exceeds 9 (or carries), add 6 to correct it.
  • Where: Calculators, point-of-sale, instruments with decimal displays.
  • When: When decimal accuracy and direct display matter more than density.
  • Analogy — Like an odometer that must skip the 'fake' numbers: binary counts 10–15 too, but decimal has no such digits, so adding 6 jumps over the six illegal codes back onto a valid digit.

At a glance

What

An adder that keeps results in binary-coded-decimal form.

Why

Financial and display systems compute directly in decimal to avoid rounding.

How

Add as 4-bit binary; if the digit exceeds 9 (or carries), add 6 to correct it.

Where

Calculators, point-of-sale, instruments with decimal displays.

When

When decimal accuracy and direct display matter more than density.

Think of it like…

Like an odometer that must skip the 'fake' numbers: binary counts 10–15 too, but decimal has no such digits, so adding 6 jumps over the six illegal codes back onto a valid digit.

The +6 correction

  • Valid BCD digits are 0000–1001; binary sums can reach 1111.
  • If the sum is 1010–1111 or produces a carry, add 0110 (6).
  • The correction generates the proper decimal carry to the next digit.

Why add 6

Binary sumDecimalAction
0–10010–9valid, no fix
1010–111110–15add 0110, carry out
carry set>15add 0110, carry out

Black-box view

A (BCD)B (BCD)CinBCD Adderblack boxS (BCD)Cout

Inputs on the left → outputs on the right · particles show signal direction

Underlying 4-bit binary add

▶ live simulator
A = 11
1bit weight 2^30bit weight 2^21bit weight 2^11bit weight 2^0
B = 6
0bit weight 2^31bit weight 2^21bit weight 2^10bit weight 2^0
carry in
1100
(cin=0)
Sum = 1
·bit weight 2^3·bit weight 2^2·bit weight 2^11bit weight 2^0

Carry out = 1 · the glowing column is the full-adder stage currently computing; carry ripples right→left.

The 5 Whys

  1. 1

    Why a BCD adder? To compute in decimal without binary conversion.

  2. 2

    Why avoid conversion? Decimal fractions don't always map exactly to binary.

  3. 3

    Why does +6 fix it? It skips the 6 invalid 4-bit codes (1010–1111).

  4. 4

    Why generate a decimal carry? So multi-digit decimal addition chains correctly.

  5. 5

    Root cause: BCD trades density for exact, display-ready decimal arithmetic.

Cheat sheet

Working principle

  • Add as 4-bit binary; if the digit exceeds 9 (or carries), add 6 to correct it.
  • An adder that keeps results in binary-coded-decimal form.

Key facts

  • Valid BCD digits are 0000–1001; binary sums can reach 1111.

Why it exists

  • Root cause: BCD trades density for exact, display-ready decimal arithmetic.
PrevBinary Adder–Subtractor
NextBinary Multiplier