You are on page 1of 19

MA11: Lecture 4

Logic and Proof


Propositional Logic
Propositions
Connectives
∧∨¬⇒⇔
Truth Tables

. – p.1/19
What is logic?

What is a proof?

. – p.2/19
Propositions

A proposition is a statement which is either


true (T) or false (F)
but not both.

Atomicproposition cannot be split further in to simpler


propositions.

They are usually represented by lower case letters, such


as p, q and r.

. – p.3/19
Examples

All of
• Burt can step forward.
• Ernie likes programming.
• 2+2=4
• 3+4=8
are propositions, whereas
• Take a step forward.
• Add two and two together.
• What is three plus four?
• x+y =5

are not.

. – p.4/19
Connectives

Connectives are links which can combine propositions to


create more complex logical expressions (called compound
propositions) which represent more complicated situations.

The use of connectives is similar to the use of connecting


words in natural language.

. – p.5/19
Conjunction

The conjunction of two propositions, p, q , is denoted


p ∧ q
which represents the proposition
p and q

Conjunction is used in the following:


• Burt can step forward and Burt can step right.
• Ernie likes programming and 2 + 2 = 4.
• 3 × 3 = 9 and 3 + 3 = 6.

. – p.6/19
Disjunction

The disjunction of two propositions, p, q , is denoted


p ∨ q
which represents the proposition
p or q

Disjunction is used in the following:


• Burt can step forward or Burt can step right.
• Burt can step forward or Ernie likes programming.
• 3 × 3 = 9 or 3 + 3 = 6.

. – p.7/19
Truth Tables

The truth value (T or F) of a compound proposition can


be determined from the truth values of its constituent
propositions and represented in a truth table.

Taking and and or as examples:

p q p∧q p q p∨q
T T T T T T
T F F T F T
F T F F T T
F F F F F F

. – p.8/19
Negation

The negation of a proposition p is denoted


¬p (or often p )
which represents the proposition
not p

Negation is used in the following:


• It is not the case that Burt can step forward.
• It is not the case that 3 + 4 = 8.
• It is not the case that 3 × 3 = 9.

Some alternative wordings are also valid, e.g. Burt cannot step forward, 3 + 4 6= 8.

. – p.9/19
Negation

The truth table for ¬ is


p ¬p
T F
F T

Note that
¬ is a unary connective (it only has one proposition
associated with it).
∧ and ∨ are binary connectives (they need two).

. – p.10/19
The Conditional Proposition

Given two propositions, p, q , the conditional proposition is


denoted
p ⇒ q (or often p → q )
which represents the proposition
if p then q (often written as p implies q )

The conditional is used in the following:


• If Burt can step forward then Burt tries to step forward.
• If Ernie likes programming then 3 + 4 = 8.
• If 3 × 3 = 9 then 3 + 3 = 9.

Some alternative wordings are also valid, e.g. Burt tries to step forward if Burt can step forward.

. – p.11/19
The Conditional Proposition
The truth table for ⇒ is
p q p⇒q
T T T
T F F
F T T
F F T

In the last two rows, p ⇒ q is said to be vacuously true.


A more appropriate English language interpretation
might be “it is possible that if p then q ”.
q ⇒ p is said to be the converse of p ⇒ q .

. – p.12/19
Necessity or Sufficiency

Consider a situation where p ⇒ q is known to be true:

p q p⇒q
T T T
F T T
F F T

In this case
p is a sufficient condition for q
(It is enough to know that p is true to know that q is true)

q is a necessary condition for p


(q must be true for p to have a chance of being true)

. – p.13/19
Example

Consider the propositions


p : It is raining.
q : It is cloudy.
and the statement p ⇒ q:

If it is raining then it is cloudy.

. – p.14/19
The Biconditional Proposition

Given two propositions, p, q , the biconditional proposition is


denoted
p ⇔ q (or often p ↔ q )
which represents the proposition
p if and only if q

The biconditional is used in the following:


• Burt steps forward if and only if Burt can step forward.
• 2 + 2 = 4 if and only if 3 + 4 = 8.
• 3 × 3 = 10 if and only if 3 × 3 + 4 = 16.

. – p.15/19
The Biconditional Proposition

The truth table for ⇔ is


p q p⇔q
T T T
T F F
F T F
F F T

p ⇔ q is the same as q ⇔ p.
p ⇔ q is true if p is the same as q , false if they are
different.

. – p.16/19
Necessity and Sufficiency

Consider a situation where p ⇔ q is known to be true:

p q p⇔q
T T T
F F T

In this case
p is necessary and sufficient for q
(p is equivalent to q, sometimes written p ≡ q)

. – p.17/19
Example

Consider the propositions


p : It is thundery.
q : There is lightening.
and the statement p ⇔ q.

It is thundery if and only if there is lightening.

. – p.18/19
Summary

A proposition is a statement which is either true or false.

It can be written in an abstract mathematical form.

Propositions can be linked to create more complex


statements...

...whose truth or falsity can be determined from


knowledge of the simple cases and the way they are
linked.

. – p.19/19

You might also like