Skip to content
ComputeVerse.ai

Digital Logic Design

Truth Table Generator

Type a Boolean expression (or a minterm list) and get the complete truth table, the canonical Σm and ΠM forms, and an instant read on tautologies and contradictions.

About this calculator

The truth table is the ground truth of combinational logic: every claim about a Boolean function — equivalence, minimality, hazard-freedom — is ultimately settled by these 2ⁿ rows. This generator builds the table from either direction: type an expression in standard notation (AND by adjacency, OR as +, NOT as an apostrophe, XOR as ^) and every row is evaluated; or enter a minterm list Σm and the table is laid out directly.

The parser follows the textbook precedence — NOT binds tightest, then AND, then XOR, then OR — which is precisely where most hand-derived tables go wrong: AB + C′ parses as (A·B) + (C′), not A·(B + C)′, and the tool exists partly so that discrepancy surfaces immediately. Malformed input gets a positioned, human-readable message, not a shrug.

Alongside the table you get the two canonical summaries every later step consumes: the minterm list Σm (rows where F = 1) and the maxterm list ΠM (rows where F = 0), in the MSB-first numbering used across this toolkit. The table itself is interactive — click any output cell to cycle it through 0, 1, and don't-care — which quietly turns the generator into a truth-table editor whose edits carry into the minterm list, ready to paste into the Karnaugh solver or the simplifier.

Constant results are called out honestly: a function that evaluates to 1 on every row is a tautology (the expression simplifies away entirely), all-zeros a contradiction — usually a sign that a term was mistyped.

Design notes & common mistakes

  • Precedence errors are the classic truth-table bug: AB + C' is (A·B) + (C'), never A·(B + C)'. When in doubt, parenthesize — the parser honors every grouping you write.
  • A' applies to the single variable; (A + B)' complements the whole subexpression. Chained postfix (A'' = A) is legal and sometimes revealing.
  • The MSB-first row numbering (A is the heaviest bit) must match between tools — a minterm list carried to another convention silently describes a different function.
  • A tautology or contradiction from a nontrivial-looking expression usually means a typo'd literal, not a profound identity.

Assumptions

  • Two-valued Boolean algebra (0/1); don't-cares are display and minimization states, not a third logic level.
  • 2 to 5 variables named A–E, MSB-first row numbering.
  • An expression using fewer variables than the padded table simply ignores the extra columns (they appear for completeness).

When to use this calculator

Appropriate for

  • Generating the full truth table and canonical Σm/ΠM forms from a Boolean expression or minterm list
  • Checking operator-precedence assumptions by seeing every row evaluated
  • Editing outputs directly to build a function for the minimization tools

Not suitable for

  • Functions of more than 5 variables, where a 2ⁿ-row table stops being human-readable
  • Simplification — this enumerates and evaluates; the simplifier and K-map solver minimize
  • Multi-output systems entered as a single table (enter each output function separately)

What this calculator does not cover

  • Up to 5 variables (32 rows) — larger tables stop being human-readable and belong to simulation, not tabulation.
  • One output function per table; multi-output systems are entered one function at a time.
  • The generator evaluates and enumerates; it does not simplify — that is the Boolean Simplifier and K-map Solver's job (one click away with the same inputs).
  • As with every calculator on this site: results are preliminary and educational, are not verified for any specific installation, and must be reviewed against the applicable code edition and stamped by a licensed Professional Engineer before real-world use.

Frequently asked questions

What operator precedence does the parser use?

The textbook order: NOT binds tightest, then AND, then XOR, then OR. So AB + C' means (A·B) + (C') and A + B^C means A + (B^C). Parentheses override everything, and using them liberally is good practice regardless.

How are the rows numbered?

MSB-first: with variables A, B, C the row index is 4A + 2B + C, so row 6 is A=1, B=1, C=0. This matches the Σm numbering used by every minimization tool here — conventions that silently differ between tools are how wrong circuits get built.

Can I edit the table directly?

Yes — click any output cell to cycle it through 0, 1, and × (don't-care). The tool switches to minterm-list mode with your edited table, which also makes the edited function shareable by URL and ready for the K-map solver.

References

  • Mano, M. M. & Ciletti, M., Digital Design, 6th ed., Ch. 2 (Boolean algebra, truth tables, canonical forms)
  • Roth, C. H. & Kinney, L., Fundamentals of Logic Design, 7th ed., Ch. 2–3

Related calculators

Get the ComputeVerse.ai quick reference

A free engineering quick-reference PDF, plus a note when new calculators launch across the library — one or two emails a month, nothing else.