Evaluating Boolean expressions
Evaluating a formula means plugging in the values and working out the sub-formulas from the inside out. Operator precedence is what matters.
Rules
- Brackets first, from the inside out
- Precedence: ¬ before ∧ before ∨ before → before ↔
- ¬ applies only to what directly follows it
- Writing down each sub-formula avoids mistakes
Your turn
Three problems on this topic. Any equivalent formula counts.
- 1 · Evaluate a formula
- 2
- 3
Evaluate the formula for A = 0, B = 0, C = 1.
F = (B ⊕ C ⊕ (A ∧ C)) → A
Value of F
Worked example
Evaluate the formula for A = 1, B = 0, C = 0.
F = B → (C → (C ⊕ A ⊕ B))
Worked solution
- 1A ⊕ B = 1
- 2C ⊕ A ⊕ B = 1
- 3C → (C ⊕ A ⊕ B) = 1
- 4B → (C → (C ⊕ A ⊕ B)) = 1
Typical mistake: Work brackets from the inside out; ¬ applies only to what directly follows it.
Common questions
Does ∧ bind tighter than ∨?
Yes, like multiplication before addition: A ∨ B ∧ C means A ∨ (B ∧ C).
