Skip to content

Boolean function: meaning and examples

A Boolean function maps each combination of n binary inputs to one binary output. It is the mathematical object a truth table describes, and many different expressions can denote the same function.

A Boolean function of n variables is a rule f from n-tuples of truth values to a truth value; there are 2 to the power 2 to the n of them, so 16 functions of two variables and 256 of three. The function is the thing, the expression is a name for it: A XOR B XOR C, its sum of minterms and its Karnaugh cover are three names for one function. Equivalence of expressions is identity of functions, and the truth table is the canonical way to write a function down.

The artefact on this page is the three-input parity function, A XOR B XOR C, true exactly when an odd number of its inputs are true, as the engine's reading says, including the case where all three are. Its 8-row table reads false, true, true, false, true, false, false, true: true on rows 1, 2, 4 and 7. The satisfiable check holds with the witness A = FALSE, B = FALSE, C = TRUE, and the tautology check is violated with the counterexample A = FALSE, B = FALSE, C = FALSE.

Boolean functions are the subject matter of switching theory, named after George Boole, and the unit of specification in hardware, where a design is a set of them. In programming a predicate is a Boolean function of its arguments; in a philosophy course, a truth function is the same thing under another name. The term is confused with a Boolean expression, which is a particular way of writing a function, and with a Boolean variable, which is an input rather than a mapping.

Example

f := A XOR B XOR C · output

Exact checks

Always true (tautology)? No Counterexample: A = F, B = F, C = F · Exhaustively checked and solver cross-checked · 1 rows
Always false (contradiction)? No Counterexample: A = F, B = F, C = T · Exhaustively checked and solver cross-checked · 2 rows
Can be true? Yes Example assignment: A = F, B = F, C = T · Exhaustively checked and solver cross-checked · 2 rows

Truth table (8 rows)

Boolean function: meaning and examples
#ABCf
0FALSEFALSEFALSEFALSE
1FALSEFALSETRUETRUE
2FALSETRUEFALSETRUE
3FALSETRUETRUEFALSE
4TRUEFALSEFALSETRUE
5TRUEFALSETRUEFALSE
6TRUETRUEFALSEFALSE
7TRUETRUETRUETRUE

Plain-language reading

Beginnerf is true exactly when an odd number of A, B, and C are true (1 or 3 of them).
In every other case, f is false.
About the operators:
- A chain of XORs is true when an odd number of its parts are true. With three parts, all three being true also counts: it does not mean “exactly one”.
Intermediatef is true exactly when an odd number of A, B, and C are true (1 or 3 of them).
In every other case, f is false.
Advancedf is true exactly when an odd number of A, B, and C are true (1 or 3 of them) [parity: n-ary exclusive disjunction ⊕].
In every other case, f is false.
Formal notation: A ⊕ B ⊕ C

The common slip

Treating two expressions as two functions because they look different. A XOR B XOR C and Σm(A, B, C; 1, 2, 4, 7) are one function with two names, and the equivalence check settles such questions on every row; the number of functions is finite, the number of expressions is not.

Questions

How many Boolean functions of three variables are there?

256, one for each way of filling the 8-row output column with TRUE and FALSE. The parity function on this page is one of them, and its complement, true on the even rows, is another.

Related

Guides

See also

Glossary

Generated from the Tangibool engine, semantics tangibool-semantics/1, engine 1.0.0, build . Every table, map, simplification and verdict on these pages was computed by the Tangibool engine when the site was built, and every claim was re-checked by the same exact checker the app uses. Limits are stated where they apply. © 2026 Foreranger LTD.