EN
My tools

Truth Table Generator

Generate the truth table of a logic expression with AND, OR, NOT, XOR, NAND, NOR, → and ↔: tautology check, minterms, maxterms and canonical SOP/POS.

Operators: AND ∧ & ·, OR ∨ | +, NOT ¬ ! ~, XOR ⊕ ^, NAND ↑, NOR ↓, → (->, implies), ↔ (<->, iff). T/F or 1/0 are constants. Terms side by side mean AND: A'B, A B or (A+B)(C+D); AB without a space is one variable. Up to 8 variables.
Show values as
Classification
Contingency: true in 1 of 4 rows
Expression read as
(p → q) ∧ ¬q
Variables
p, q
Minterms (rows where true)
Σm(0)
Maxterms (rows where false)
ΠM(1, 2, 3)
Canonical SOP (sum of products)
(¬p ∧ ¬q)
Canonical POS (product of sums)
(p ∨ ¬q) ∧ (¬p ∨ q) ∧ (¬p ∨ ¬q)

Row numbers count in binary with p as the most significant bit, so row 0 is all false; minterm and maxterm numbers use the same order.

Truth table (4 rows)
pqp → q¬q(p → q) ∧ ¬q
FFTTT
FTTFF
TFFTF
TTTFF
My tools →
Advertisement

A truth table lists every combination of true and false values for the variables in a logical expression and shows the result for each. This generator reads expressions written with words or symbols, shows the value of every sub-expression column by column, and tells you whether the expression is a tautology, a contradiction or a contingency. It also lists the minterms and maxterms and writes the canonical sum-of-products and product-of-sums forms used in digital logic.

How to use this tool

  1. Type the expression, for example (p → q) ∧ ¬q or (A and B) or not C.
  2. Choose T/F or 1/0 and whether to show sub-expression columns.
  3. Read the classification and the full truth table.
  4. Copy the minterms, maxterms, SOP or POS form for circuit design or proofs.

Formula

Rows = 2ⁿ for n variables · A → B ≡ ¬A ∨ B · A ↔ B ≡ (A → B) ∧ (B → A) · A ↑ B ≡ ¬(A ∧ B) · A ↓ B ≡ ¬(A ∨ B)

Precedence from strongest to weakest: NOT, AND (and NAND), XOR, OR (and NOR), implication, biconditional; implication groups to the right. Use brackets when in doubt. Minterm k is the row whose variable values spell k in binary; the canonical SOP ORs together one AND term per true row.

Example

For (p → q) ∧ ¬q the four rows give F, F, F, T only when p and q are both false (row 0), so it is a contingency with minterm Σm(0) and SOP (¬p ∧ ¬q). This is why modus tollens works: whenever p → q and ¬q hold, ¬p holds too. p ∨ ¬p is true in every row, a tautology.

Frequently asked questions

How is A → B evaluated?

It is false only when A is true and B is false. When A is false the implication is "vacuously" true, which surprises many people at first.

Why are my variables in alphabetical order?

Columns are sorted alphabetically so that row numbers, minterms and maxterms follow the usual convention, with the first variable as the most significant bit.

Does it simplify the expression?

It gives the canonical (unsimplified) SOP and POS forms. For a minimal form, group the minterms on a Karnaugh map or use the Quine–McCluskey method.

Last updated:

Cite or embed this tool
APA

kakaoCalc. (2026, November 9). Truth Table Generator. https://kakao.mobile/tools/truth-table/

MLA

“Truth Table Generator.” kakaoCalc, 9 Nov. 2026, kakao.mobile/tools/truth-table/.

Paste this code into your page. The widget runs in your visitors' browsers, shows no ads and keeps a link back to this page. Embedding terms

Advertisement