Mathematica > Mathematics and Algorithms > Discrete Mathematics > Boolean Computation >
Mathematica > Mathematics and Algorithms > Logic & Boolean Algebra > Boolean Computation >

BooleanTable

BooleanTable[bf]
gives a list of truth values for all possible combinations of variable values supplied to the Boolean function bf.
BooleanTable[expr, {a1, a2, ...}]
gives a list of the truth values of the Boolean expression expr for all possible combinations of values of the ai.
BooleanTable[expr, {a1, a2, ...}, {b1, ...}, ...]
gives a nested table of truth values of expr with the outermost level giving possible combinations of the ai.
  • The possible combinations of variable values are given in the order Tuples[{True, False}, n].
  • Boole[BooleanTable[...]] gives 1, 0 values.
  • In BooleanTable[expr, {a1, a2, ...}], etc. any of the variables in expr that are not explicitly among the ai, etc. are left in symbolic form.
  • BooleanTable[expr, vars1, ..., varss] is equivalent to Fold[BooleanTable, expr, {varss, ..., vars1}].
  • BooleanTable[bf, {r1, r2, ...}] gives a list of truth values corresponding to possible values of the r1^(th), r2^(th), ... variables for the Boolean function bf.
  • BooleanTable[bf, {r1, ...}, {s1, ...}, ...] gives a nested table of truth values with the outermost level giving combinations of the ri^(th) variables.
New in 7
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team