Truth Table to Expression Generator

Convert any truth table into a logical expression. Generate Boolean formulas in Disjunctive Normal Form (DNF) or Conjunctive Normal Form (CNF) from your custom truth table.

Variables: p, q
pqOutput

Click on the output values to toggle between true (⊤) and false (⊥)

Understanding Boolean Synthesis

Disjunctive Normal Form (DNF)

DNF represents a formula as an OR of ANDs (sum of products). For each row where the output is true, we create a minterm that ANDs together all variables, negating those that are false. These minterms are then ORed together to form the complete expression.

Conjunctive Normal Form (CNF)

CNF represents a formula as an AND of ORs (product of sums). For each row where the output is false, we create a maxterm that ORs together all variables, negating those that are true. These maxterms are then ANDed together to form the complete expression.

Applications of Truth Table Synthesis

Converting truth tables to logical expressions is a fundamental technique in computer science and digital electronics. This tool helps with:

  • Digital circuit design - Create Boolean equations for logic gates from desired input-output behavior
  • Software development - Generate conditional logic from specification tables
  • Academic studies - Learn and practice Boolean algebra and propositional logic
  • Logic optimization - Compare DNF and CNF forms to find simpler equivalent expressions