Logic as a Tool Chapter 1: Understanding Propositional Logic 1.3 - - PowerPoint PPT Presentation

logic as a tool chapter 1 understanding propositional
SMART_READER_LITE
LIVE PREVIEW

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.3 - - PowerPoint PPT Presentation

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.3 Logical equivalence Negation normal form of propositional formulae Valentin Goranko Stockholm University September 2016 Goranko Logical equivalence of propositional formulae


slide-1
SLIDE 1

Goranko

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.3 Logical equivalence Negation normal form of propositional formulae

Valentin Goranko Stockholm University September 2016

slide-2
SLIDE 2

Goranko

Logical equivalence of propositional formulae

Propositional formulae A and B are logically equivalent, denoted A ≡ B, if they obtain the same truth value under any truth valuation (of the variables occurring in them).

slide-3
SLIDE 3

Goranko

Logical equivalence of propositional formulae

Propositional formulae A and B are logically equivalent, denoted A ≡ B, if they obtain the same truth value under any truth valuation (of the variables occurring in them). Examples: ¬(p ∧ q) ≡ ¬p ∨ ¬q

slide-4
SLIDE 4

Goranko

Logical equivalence of propositional formulae

Propositional formulae A and B are logically equivalent, denoted A ≡ B, if they obtain the same truth value under any truth valuation (of the variables occurring in them). Examples: ¬(p ∧ q) ≡ ¬p ∨ ¬q p q ¬ (p ∧ q) ¬ p ∨ ¬ q T T F T T T F T F F T T F T T F F F T T T F F T T F F T T F T F T F F T F F F T F T T F

slide-5
SLIDE 5

Goranko

Logical equivalence of propositional formulae

Propositional formulae A and B are logically equivalent, denoted A ≡ B, if they obtain the same truth value under any truth valuation (of the variables occurring in them). Examples: ¬(p ∧ q) ≡ ¬p ∨ ¬q p q ¬ (p ∧ q) ¬ p ∨ ¬ q T T F T T T F T F F T T F T T F F F T T T F F T T F F T T F T F T F F T F F F T F T T F p ∧ (p ∨ q) ≡ p ∧ p ≡ p

slide-6
SLIDE 6

Goranko

Logical equivalence of propositional formulae

Propositional formulae A and B are logically equivalent, denoted A ≡ B, if they obtain the same truth value under any truth valuation (of the variables occurring in them). Examples: ¬(p ∧ q) ≡ ¬p ∨ ¬q p q ¬ (p ∧ q) ¬ p ∨ ¬ q T T F T T T F T F F T T F T T F F F T T T F F T T F F T T F T F T F F T F F F T F T T F p ∧ (p ∨ q) ≡ p ∧ p ≡ p p q p ∧ (p ∨ q) p ∧ p T T T T T T T T T T T F T T T T F T T T F T F F F T T F F F F F F F F F F F F F

slide-7
SLIDE 7

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A

slide-8
SLIDE 8

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B.

slide-9
SLIDE 9

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B. ◮ ≡ is an equivalence relation, i.e., reflexive, symmetric, and transitive.

slide-10
SLIDE 10

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B. ◮ ≡ is an equivalence relation, i.e., reflexive, symmetric, and transitive. ◮ Moreover, ≡ is a congruence with respect to the propositional connectives, i.e.:

slide-11
SLIDE 11

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B. ◮ ≡ is an equivalence relation, i.e., reflexive, symmetric, and transitive. ◮ Moreover, ≡ is a congruence with respect to the propositional connectives, i.e.: ⊲ if A ≡ B then ¬A ≡ ¬B, and

slide-12
SLIDE 12

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B. ◮ ≡ is an equivalence relation, i.e., reflexive, symmetric, and transitive. ◮ Moreover, ≡ is a congruence with respect to the propositional connectives, i.e.: ⊲ if A ≡ B then ¬A ≡ ¬B, and ⊲ if A1 ≡ B1 and A2 ≡ B2 then (A1 • A2) ≡ (B1 • B2), where • ∈ {∧, ∨, →, ↔}.

slide-13
SLIDE 13

Goranko

Some basic properties of logical equivalence

◮ Logical equivalence is reducible to logical consequence: A ≡ B iff A | = B and B | = A ◮ Logical equivalence is reducible to logical validity: A ≡ B iff | = A ↔ B. ◮ ≡ is an equivalence relation, i.e., reflexive, symmetric, and transitive. ◮ Moreover, ≡ is a congruence with respect to the propositional connectives, i.e.: ⊲ if A ≡ B then ¬A ≡ ¬B, and ⊲ if A1 ≡ B1 and A2 ≡ B2 then (A1 • A2) ≡ (B1 • B2), where • ∈ {∧, ∨, →, ↔}.

Theorem (Equivalent replacement)

Let A, B, C be any propositional formulae p be a propositional variable. If A ≡ B then C(A/p) ≡ C(B/p), where C(X/p) is the result of simultaneous substitution of al occurrences of p by X.

slide-14
SLIDE 14

Goranko

Some important logical equivalences

  • Idempotency:

p ∧ p ≡ p; p ∨ p ≡ p.

slide-15
SLIDE 15

Goranko

Some important logical equivalences

  • Idempotency:

p ∧ p ≡ p; p ∨ p ≡ p.

  • Commutativity:

p ∧ q ≡ q ∧ p; p ∨ q ≡ q ∨ p.

slide-16
SLIDE 16

Goranko

Some important logical equivalences

  • Idempotency:

p ∧ p ≡ p; p ∨ p ≡ p.

  • Commutativity:

p ∧ q ≡ q ∧ p; p ∨ q ≡ q ∨ p.

  • Associativity:

(p ∧ (q ∧ r)) ≡ ((p ∧ q) ∧ r); (p ∨ (q ∨ r)) ≡ ((p ∨ q) ∨ r). Note that this property allows us to omit the parentheses in multiple conjunctions and disjunctions.

slide-17
SLIDE 17

Goranko

Some important logical equivalences

  • Idempotency:

p ∧ p ≡ p; p ∨ p ≡ p.

  • Commutativity:

p ∧ q ≡ q ∧ p; p ∨ q ≡ q ∨ p.

  • Associativity:

(p ∧ (q ∧ r)) ≡ ((p ∧ q) ∧ r); (p ∨ (q ∨ r)) ≡ ((p ∨ q) ∨ r). Note that this property allows us to omit the parentheses in multiple conjunctions and disjunctions.

  • Absorption:

p ∧ (p ∨ q) ≡ p; p ∨ (p ∧ q) ≡ p.

slide-18
SLIDE 18

Goranko

Some important logical equivalences

  • Idempotency:

p ∧ p ≡ p; p ∨ p ≡ p.

  • Commutativity:

p ∧ q ≡ q ∧ p; p ∨ q ≡ q ∨ p.

  • Associativity:

(p ∧ (q ∧ r)) ≡ ((p ∧ q) ∧ r); (p ∨ (q ∨ r)) ≡ ((p ∨ q) ∨ r). Note that this property allows us to omit the parentheses in multiple conjunctions and disjunctions.

  • Absorption:

p ∧ (p ∨ q) ≡ p; p ∨ (p ∧ q) ≡ p.

  • Distributivity:

p ∧ (q ∨ r) ≡ (p ∧ q) ∨ (p ∧ r); p ∨ (q ∧ r) ≡ (p ∨ q) ∧ (p ∨ r).

slide-19
SLIDE 19

Goranko

Other useful logical equivalences

slide-20
SLIDE 20

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡
slide-21
SLIDE 21

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤;
slide-22
SLIDE 22

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡
slide-23
SLIDE 23

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
slide-24
SLIDE 24

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡
slide-25
SLIDE 25

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A;
slide-26
SLIDE 26

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡
slide-27
SLIDE 27

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
slide-28
SLIDE 28

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡
slide-29
SLIDE 29

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤;
slide-30
SLIDE 30

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡
slide-31
SLIDE 31

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
slide-32
SLIDE 32

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
slide-33
SLIDE 33

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
  • A ↔ B ≡ (A → B) ∧ (B → A)
slide-34
SLIDE 34

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
  • A ↔ B ≡ (A → B) ∧ (B → A)
  • A → B ≡ ¬A ∨ B
slide-35
SLIDE 35

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
  • A ↔ B ≡ (A → B) ∧ (B → A)
  • A → B ≡ ¬A ∨ B
  • A ∨ B ≡ ¬A → B
slide-36
SLIDE 36

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
  • A ↔ B ≡ (A → B) ∧ (B → A)
  • A → B ≡ ¬A ∨ B
  • A ∨ B ≡ ¬A → B
  • A ∨ B ≡ ¬(¬A ∧ ¬B);

A ∧ B ≡ ¬(¬A ∨ ¬B)

slide-37
SLIDE 37

Goranko

Other useful logical equivalences

  • A ∨ ¬A ≡ ⊤; A ∧ ¬A ≡ ⊥
  • A ∧ ⊤ ≡ A; A ∧ ⊥ ≡ ⊥
  • A ∨ ⊤ ≡ ⊤; A ∨ ⊥ ≡ A
  • ¬A ≡ A → ⊥
  • A ↔ B ≡ (A → B) ∧ (B → A)
  • A → B ≡ ¬A ∨ B
  • A ∨ B ≡ ¬A → B
  • A ∨ B ≡ ¬(¬A ∧ ¬B);

A ∧ B ≡ ¬(¬A ∨ ¬B)

  • A → B ≡ ¬B → ¬A
slide-38
SLIDE 38

Goranko

Important equivalences for negations of propositional formulae

slide-39
SLIDE 39

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
slide-40
SLIDE 40

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
slide-41
SLIDE 41

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
slide-42
SLIDE 42

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
slide-43
SLIDE 43

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)
slide-44
SLIDE 44

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)

≡ ¬((A → B) ∧ (B → A))

slide-45
SLIDE 45

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)

≡ ¬((A → B) ∧ (B → A)) ≡ ¬(A → B) ∨ ¬(B → A)

slide-46
SLIDE 46

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)

≡ ¬((A → B) ∧ (B → A)) ≡ ¬(A → B) ∨ ¬(B → A) ≡ (A ∧ ¬B) ∨ (B ∧ ¬A).

slide-47
SLIDE 47

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)

≡ ¬((A → B) ∧ (B → A)) ≡ ¬(A → B) ∨ ¬(B → A) ≡ (A ∧ ¬B) ∨ (B ∧ ¬A). Using these equivalences, all occurrences of negations in any propositional formula can be driven inwards, so eventually they only

  • ccur in from of propositional variables.
slide-48
SLIDE 48

Goranko

Important equivalences for negations of propositional formulae

  • ¬¬A ≡ A,
  • ¬(A ∧ B) ≡ ¬A ∨ ¬B,
  • ¬(A ∨ B) ≡ ¬A ∧ ¬B,
  • ¬(A → B) ≡ A ∧ ¬B,
  • ¬(A ↔ B)

≡ ¬((A → B) ∧ (B → A)) ≡ ¬(A → B) ∨ ¬(B → A) ≡ (A ∧ ¬B) ∨ (B ∧ ¬A). Using these equivalences, all occurrences of negations in any propositional formula can be driven inwards, so eventually they only

  • ccur in from of propositional variables.

Then the formula is transformed to a negation normal form.

slide-49
SLIDE 49

Goranko

Transformation to negation normal form: example

¬(¬p → (¬q ∧ r))

slide-50
SLIDE 50

Goranko

Transformation to negation normal form: example

¬(¬p → (¬q ∧ r)) ≡ ¬p ∧ ¬(¬q ∧ r)

slide-51
SLIDE 51

Goranko

Transformation to negation normal form: example

¬(¬p → (¬q ∧ r)) ≡ ¬p ∧ ¬(¬q ∧ r) ≡ ¬p ∧ (¬¬q ∨ ¬r)

slide-52
SLIDE 52

Goranko

Transformation to negation normal form: example

¬(¬p → (¬q ∧ r)) ≡ ¬p ∧ ¬(¬q ∧ r) ≡ ¬p ∧ (¬¬q ∨ ¬r) ≡ ¬p ∧ (q ∨ ¬r)