Truth table

A truth table is a mathematical table used in logic—specifically in connection with Boolean algebra, boolean functions, and propositional calculus—which sets out the functional values of logical expressions on each of their functional arguments, that is, for each combination of values taken by their logical variables (Enderton, 2001). In particular, truth tables can be used to show whether a propositional expression is true for all legitimate input values, that is, logically valid.

A truth table has one column for each input variable (for example, P and Q), and one final column showing all of the possible results of the logical operation that the table represents (for example, P XOR Q). Each row of the truth table contains one possible configuration of the input variables (for instance, P=true Q=false), and the result of the operation for those values. See the examples below for further clarification. Ludwig Wittgenstein is often credited with inventing the truth table in his Tractatus Logico-Philosophicus,[1] though it appeared at least a year earlier in a paper on propositional logic by Emil Leon Post.[2]

Unary operations

There are 4 unary operations:

  • Always true
  • Never true, unary falsum
  • Unary Identity
  • Unary negation

Logical true

The output value is always true, regardless of the input value of p

Logical True
p T
T T
F T

Logical false

The output value is never true: that is, always false, regardless of the input value of p

Logical False
p F
T F
F F

Logical identity

Logical identity is an operation on one logical value p, for which the output value remains p.

The truth table for the logical identity operator is as follows:

Logical Identity
p p
T T
F F

Logical negation

Logical negation is an operation on one logical value, typically the value of a proposition, that produces a value of true if its operand is false and a value of false if its operand is true.

The truth table for NOT p (also written as ¬p, Np, Fpq, or ~p) is as follows:

Logical Negation
p ¬p
T F
F T


Other Languages