1 Logic

1.6 Useful logical equivalences

1.6.1 Distributivity

The property that for all numbers a,b,c we have a×(b+c)=a×b+a×c is called distributivity of × over +. Similar rules hold for and .

Theorem 1.6.1.

Let ϕ, ψ, and θ be WFFs. Then

  1. 1.

    (ϕ(ψθ))((ϕψ)(ϕθ)), and

  2. 2.

    (ϕ(ψθ))((ϕψ)(ϕθ)).

Proof.

Here are the truth tables for the four WFFs:

ϕ ψ θ (ϕ(ψθ)) ((ϕψ)(ϕθ))
T T T T T
T T F T T
T F T T T
T F F F F
F T T F F
F T F F F
F F T F F
F F F F F
ϕ ψ θ (ϕ(ψθ)) ((ϕψ)(ϕθ))
T T T T T
T T F T T
T F T T T
T F F T T
F T T T T
F T F F F
F F T F F
F F F F F

The last two columns are the same in both tables, so the formulas are logically equivalent. ∎

1.6.2 Double negation

Theorem 1.6.2.

Let ϕ be a WFF. Then ¬¬ϕϕ.

Proof.

Let v be a truth assignment for the propositional variables involved in ϕ. If v(ϕ)=T then v(¬ϕ)=¬v(ϕ)=F and so v(¬¬ϕ)=¬v(¬ϕ)=¬F=T. Similarly if v(ϕ) is false so is v(¬¬ϕ). Therefore under any truth assignment v we have v(ϕ)=v(¬¬ϕ). ∎

1.6.3 De Morgan’s laws

Theorem 1.6.3.

Let ϕ and ψ be WFFs. Then

  1. 1.

    ¬(ϕψ)(¬ϕ¬ψ), and

  2. 2.

    ¬(ϕψ)(¬ϕ¬ψ).

You might find it clearer to write the right hand sides of these equivalences as (¬ϕ)(¬ψ) and (¬ϕ)(¬ψ), even though these are not well-formed formulas. From now on I will add or remove brackets from formulas where it helps to make them clearer or more readable even if it means that they are not strictly WFFs.

Proof.

Again, proving this is simply a matter of checking the possibilities for the truth values of ϕ and ψ under any assignment. In a table:

ϕ ψ ¬(ϕψ) (¬ϕ¬ψ)
T T F F
T F F F
F T F F
F F T T

The final columns are the same, so the two formulas have the same truth value no matter what truth assignment is used and are therefore logically equivalent. ∎

De Morgan’s laws can be generalized to more than two WFFs.

Theorem 1.6.4.

For any n and any WFFs ϕ1,,ϕn we have

  1. 1.

    ¬(ϕ1ϕn)¬ϕ1¬ϕn, and

  2. 2.

    ¬(ϕ1ϕn)¬ϕ1¬ϕn.

While ϕ1ϕ2ϕ3, for example, isn’t a WFF, every way of adding brackets to make it into one produces a logically equivalent WFF because of the associativity of , Theorem 1.5.1 part 3. Therefore it’s OK for us to omit brackets here for the sake of making the formula easier to read.