Truth Table Generator
Easily calculate the truth table for any compound logical proposition. Simply write the expression using your preferred logical connectives (¬, ∧, ∨, →, ↔, etc.) and the tool will generate the table.
Instructions for use
You can use either your keyboard or the virtual keyboard to type the logical expression. Once you have it, press "Generate table" or the "enter" key. You can choose between the letter format (T/F) or the binary format (1/0).
Quick examples
Click on any proposition to generate its truth table:
- (p → q) ∧ (q → p)
- ¬p ∧ q → ¬r
- p ∧ q → r
- (p ∧ q) ∨ r
- (p ∧ q) → p
- ¬p ∧ q → ¬r
- ¬[(p ∧ q) ∧ ¬(p ∨ q)]
- (¬p ∨ ¬q) → ¬r
- ¬(p ∨ q) ↔ (¬p ∧ ¬q)
- (p → q) ∧ (q → r) → (p → r)
- {[(p ⊕ q) ∧ (s ↔ r)] ∧ (q → s)} ⊕ ¬(q ∧ s)
Propositional variables
The following options are valid:
- Lowercase letters: a, b, c, d, p, q, r… (except 'v', 'f').
- Capital letters: A, B, C… P, Q, R… (except 'F', 'T').
Logical operators
Logical connectives have a standard symbol and other accepted symbols, you can see them in the following table.
| Operator | Standard symbol | Allowed shortcuts |
|---|---|---|
| Negation | ¬ | ~, !, not |
| Conjunction | ∧ | &, &&, ^, and, AND |
| Disjunction | ∨ | v, or, OR |
| Exclusive Disjunction | ⊕ | xor, ⊻ |
| Implication | → | ->, =>, ⇒, imp, IMP |
| Biconditional | ↔ | <->, <=>, ==, iff, IFF, ⇔ |
Grouping symbols
You can use parentheses ( ), square brackets [ ], and curly braces { } to group clauses. If you do not use any, the following hierarchy is handled internally:
- Negation (¬).
- Conjunction (∧).
- Inclusive disjunction (∨) and exclusive disjunction (⊕).
- Conditional (→).
- Biconditional (↔).
For example, the proposition ¬p ∧ q ∨ r → s ↔ p is interpreted as {[(¬p ∧ q) ∨ r ] → s } ↔ p or, using only parentheses: (((¬p ∧ q) ∨ r ) → s ) ↔ p.
Constants
- Tautology (True): T, ⊤, 1
- Contradiction (False): F, ⊥, 0

Leave a Reply