Truth Tables Explained
← All articles

Truth Tables Explained

5 min

Definition

A truth table lists every possible combination of input values for a logic circuit, alongside the resulting output for each combination. With N binary inputs there are exactly 2^N rows — for example, 2 inputs give 4 rows, 3 inputs give 8 rows.

Building one by hand

To build a truth table for an expression like A·B + ¬C:

  • List all input variables (A, B, C) and create one column per variable.
  • Enumerate every combination of 0s and 1s — counting in binary is the easiest way to avoid missing one.
  • Add a column for each sub-expression, evaluating left to right (¬C first, then A·B, then the sum).
  • The final column is your circuit's output for every possible input state.

From table to gates

Every row where the output is 1 corresponds to one product term (a minterm). Adding all the minterms together with OR gives you a Boolean expression — the Sum-of-Products form — that you can build directly from AND, OR and NOT gates.

This is exactly the reverse of what the Truth Table tool in Boolflow does: build your circuit visually, and it derives the table for you automatically, for any combinational circuit with up to 10 inputs.

Why it matters

Truth tables are the ground truth for verifying digital logic. Before exporting a design to Verilog or VHDL, checking the generated truth table against the behaviour you intended is the fastest way to catch a wiring mistake.

Generate a truth table automatically