What the topic is about
Equivalent formulas of logic: De Morgan’s laws, replacing A → B by ¬A ∨ B, the distributive laws and simplifying expressions such as A ∨ (A ∧ B) ≡ A. Equivalence can be checked with a truth table.
Where it leads
Equivalent forms of logical formulas simplify conditions in programs, circuits in electronics and database queries. Programmers use De Morgan’s laws every day, and at university this is the first topic of discrete maths.
How to solve
- ¬(A ∧ B) ≡ ¬A ∨ ¬B and ¬(A ∨ B) ≡ ¬A ∧ ¬B: negation turns “and” into “or”.
- A → B ≡ ¬A ∨ B ≡ ¬B → ¬A.
- When in doubt, compare both formulas for every set of values.
A worked example
1 is true, 0 is false, ∧ means "and", ∨ means "or", ¬ means "not". Which formula is equivalent to this one?
¬((B ∧ ¬C) ∨ A)
Answer: (¬B ∨ C) ∧ ¬A
- De Morgan's laws: ¬(A ∧ B) ≡ ¬A ∨ ¬B, ¬(A ∨ B) ≡ ¬A ∧ ¬B.
- ¬((B ∧ ¬C) ∨ A) ≡ (¬B ∨ C) ∧ ¬A
Typical mistakes
- Writing ¬(A ∧ B) as ¬A ∧ ¬B.
- Thinking that A → B is the same as B → A.
How to tell it is learnt
- Uses De Morgan’s laws and replaces an implication.
- Expands brackets by the distributive laws.
- Checks equivalence with a truth table.
How to help at home
Put a house rule into logic: “if the homework is not done, then no phone”. How can it be said without “if”? Check with a table.
A game without a phone
Take a rule from life with “and”, “or”, “not” (“do not be late and do not forget your indoor shoes”) and rewrite it by De Morgan’s law (“it is not true that you were late or forgot the shoes”). Is the meaning the same? Check with a table.
