Uploaded by seif1442004

Lecture1

advertisement
Propositions
Important Logical Properties and Relations
Propositional Logic
Haythem O. Ismail
Haythem O. Ismail
Lecture 1
1 / 28
Propositions
Important Logical Properties and Relations
Objectives
By the end of this lecture you will be able to
1
Determine whether a given sentence is a statement.
2
Use the language of (propositional) formal logic.
3
Construct the truth table of a statement of (propositional) logic.
4
Determine whether a given statement is a tautology, a
contradiction, or neither.
5
Determine whether two statements are logically equivalent.
Haythem O. Ismail
Lecture 1
2 / 28
Propositions
Important Logical Properties and Relations
Outline
1
Propositions
2
Important Logical Properties and Relations
Haythem O. Ismail
Lecture 1
3 / 28
Propositions
Important Logical Properties and Relations
Outline
1
Propositions
2
Important Logical Properties and Relations
Haythem O. Ismail
Lecture 1
4 / 28
Propositions
Important Logical Properties and Relations
Smullyan’s Puzzle of the Politicians
A certain convention numbered 100 politicians. Each politician was
either crooked or honest. We are given the following two facts.
1
At least one of the politicians was honest.
2
Given any two of the politicians, at least one of the two was
crooked.
Can it be determined from these two facts how many of the politicians
were honest and how many were crooked?
Haythem O. Ismail
Lecture 1
5 / 28
Propositions
Important Logical Properties and Relations
Solution
Only one honest politician.
Why?
Write your argument here:
Haythem O. Ismail
Lecture 1
6 / 28
Propositions
Important Logical Properties and Relations
Statements (a.k.a “Propositions”)
A statement (in any language you can imagine) is a sentence that
is either true or false—a sentence with a truth value.
For example
Whales are mammals.
Whales are fish.
There is a man with a red cloak in outside the room.
are example of statements. (Why?)
On the other hand
Are whales mammals?
Open the door.
He has a red cloak.
x + 2 = 4.
are not statements. (Why?)
Haythem O. Ismail
Lecture 1
7 / 28
Propositions
Important Logical Properties and Relations
Statements (a.k.a “Propositions”)
A statement (in any language you can imagine) is a sentence that
is either true or false—a sentence with a truth value.
For example
Whales are mammals.
Whales are fish.
There is a man with a red cloak in outside the room.
are example of statements. (Why?)
On the other hand
Are whales mammals?
Open the door.
He has a red cloak.
x + 2 = 4.
are not statements. (Why?)
Haythem O. Ismail
Lecture 1
7 / 28
Propositions
Important Logical Properties and Relations
Statements (a.k.a “Propositions”)
A statement (in any language you can imagine) is a sentence that
is either true or false—a sentence with a truth value.
For example
Whales are mammals.
Whales are fish.
There is a man with a red cloak in outside the room.
are example of statements. (Why?)
On the other hand
Are whales mammals?
Open the door.
He has a red cloak.
x + 2 = 4.
are not statements. (Why?)
Haythem O. Ismail
Lecture 1
7 / 28
Propositions
Important Logical Properties and Relations
Atomic and Compound Statements
Statements are either atomic (like the ones we’ve seen so far) or
compound.
An atomic statement is one whose truth value can only be
determined empirically.
In formal logic, atomic statements are represented by
propositional variables: p, q, r, s, . . ..
A compound statement is made up of smaller statements (atomic
or compound) held together by a logical connective.
Its truth value depends on the truth values of its parts in a way
determined by the logical connective.
We shall consider five forms of compound statements.
Haythem O. Ismail
Lecture 1
8 / 28
Propositions
Important Logical Properties and Relations
Negation
Negations use a unary connective, ¬, which operates on a
statement to produce another (compound) statement.
If p is a statement, then ¬p is the negation of p, read “not p” or
“it is not the case that p”.
Example
If p represents the statement “whales are mammals”, then
¬p represents the negation “it is not the case that whales are
mammals”.
The truth table for ¬ defines how the truth value of ¬p is
determined by the truth value of p.
Haythem O. Ismail
Lecture 1
9 / 28
Propositions
Important Logical Properties and Relations
Negation
Negations use a unary connective, ¬, which operates on a
statement to produce another (compound) statement.
If p is a statement, then ¬p is the negation of p, read “not p” or
“it is not the case that p”.
Example
If p represents the statement “whales are mammals”, then
¬p represents the negation “it is not the case that whales are
mammals”.
The truth table for ¬ defines how the truth value of ¬p is
determined by the truth value of p.
Haythem O. Ismail
Lecture 1
9 / 28
Propositions
Important Logical Properties and Relations
Negation
Negations use a unary connective, ¬, which operates on a
statement to produce another (compound) statement.
If p is a statement, then ¬p is the negation of p, read “not p” or
“it is not the case that p”.
Example
If p represents the statement “whales are mammals”, then
¬p represents the negation “it is not the case that whales are
mammals”.
The truth table for ¬ defines how the truth value of ¬p is
determined by the truth value of p.
Haythem O. Ismail
Lecture 1
9 / 28
Propositions
Important Logical Properties and Relations
Truth Table for ¬
p
F
T
Haythem O. Ismail
¬p
T
F
Lecture 1
10 / 28
Propositions
Important Logical Properties and Relations
Conjunction
This binary connective is denoted by ∧, and (very) roughly
corresponds to the English “and”.
If p and q are statements, then p ∧ q is a conjunction, and both q
and q are conjuncts.
Example
If p represents “whales are mammals”, and
q represents “whales are big”, then
p ∧ q represents the conjunction “whales are mammals and whales are
big”.
Haythem O. Ismail
Lecture 1
11 / 28
Propositions
Important Logical Properties and Relations
Conjunction
This binary connective is denoted by ∧, and (very) roughly
corresponds to the English “and”.
If p and q are statements, then p ∧ q is a conjunction, and both q
and q are conjuncts.
Example
If p represents “whales are mammals”, and
q represents “whales are big”, then
p ∧ q represents the conjunction “whales are mammals and whales are
big”.
Haythem O. Ismail
Lecture 1
11 / 28
Propositions
Important Logical Properties and Relations
Truth Table for ∧
p
F
F
T
T
q
F
T
F
T
p∧q
Do it yourself!
Haythem O. Ismail
Lecture 1
12 / 28
Propositions
Important Logical Properties and Relations
Disjunction
The connective is denoted by ∨, and corresponds to the English
“or” (in the inclusive sense).
If p and q are statements, then p ∨ q is a disjunction, and both p
and q are disjuncts.
Example
If p represents “whales are fish”, and
q represents “mammals swim”, then
p ∨ q represents the disjunction “whales are fish or mammals swim”.
Haythem O. Ismail
Lecture 1
13 / 28
Propositions
Important Logical Properties and Relations
Disjunction
The connective is denoted by ∨, and corresponds to the English
“or” (in the inclusive sense).
If p and q are statements, then p ∨ q is a disjunction, and both p
and q are disjuncts.
Example
If p represents “whales are fish”, and
q represents “mammals swim”, then
p ∨ q represents the disjunction “whales are fish or mammals swim”.
Haythem O. Ismail
Lecture 1
13 / 28
Propositions
Important Logical Properties and Relations
Truth Table for ∨
p
F
F
T
T
q
F
T
F
T
p∨q
Do it yourself!
Haythem O. Ismail
Lecture 1
14 / 28
Propositions
Important Logical Properties and Relations
The Exclusive “or”
Not a common basic connective in logical languages.
The connective is denoted by ⊕, and corresponds to the English
“or” (in the exclusive sense).
If p and q are statements, then p ⊕ q is their exclusive or (xor).
Example
If p represents “whales are fish”, and
q represents “whales are mammals”, then
p ⊕ q represents the disjunction “whales are fish or whales are
mammals”.
How are ∨ and ⊕ different?
Haythem O. Ismail
Lecture 1
15 / 28
Propositions
Important Logical Properties and Relations
The Exclusive “or”
Not a common basic connective in logical languages.
The connective is denoted by ⊕, and corresponds to the English
“or” (in the exclusive sense).
If p and q are statements, then p ⊕ q is their exclusive or (xor).
Example
If p represents “whales are fish”, and
q represents “whales are mammals”, then
p ⊕ q represents the disjunction “whales are fish or whales are
mammals”.
How are ∨ and ⊕ different?
Haythem O. Ismail
Lecture 1
15 / 28
Propositions
Important Logical Properties and Relations
The Exclusive “or”
Not a common basic connective in logical languages.
The connective is denoted by ⊕, and corresponds to the English
“or” (in the exclusive sense).
If p and q are statements, then p ⊕ q is their exclusive or (xor).
Example
If p represents “whales are fish”, and
q represents “whales are mammals”, then
p ⊕ q represents the disjunction “whales are fish or whales are
mammals”.
How are ∨ and ⊕ different?
Haythem O. Ismail
Lecture 1
15 / 28
Propositions
Important Logical Properties and Relations
Truth Table for ⊕
p
F
F
T
T
q
F
T
F
T
p⊕q
Do it yourself!
Haythem O. Ismail
Lecture 1
16 / 28
Propositions
Important Logical Properties and Relations
Material Implication
The connective is denoted by →, and (very) roughly corresponds
to the English “if . . . then . . .”.
If p and q are statements, then p → q is a material implication or
a conditional statement.
p is called the antecedent and q the consequent.
Example
If p represents “whales are mammals”, and
q represents “whales give birth”, then
p → q represents the conditional “if whales are mammals then whales
give birth”.
Haythem O. Ismail
Lecture 1
17 / 28
Propositions
Important Logical Properties and Relations
Material Implication
The connective is denoted by →, and (very) roughly corresponds
to the English “if . . . then . . .”.
If p and q are statements, then p → q is a material implication or
a conditional statement.
p is called the antecedent and q the consequent.
Example
If p represents “whales are mammals”, and
q represents “whales give birth”, then
p → q represents the conditional “if whales are mammals then whales
give birth”.
Haythem O. Ismail
Lecture 1
17 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Related Terms
Given p → q
p → q can be read “p only if q”.
p is a sufficient condition for q.
q is a necessary condition for p.
q → p is the converse of p → q.
¬q → ¬p is the contrapositive of p → q.
¬p → ¬q is called the inverse of p → q.
Haythem O. Ismail
Lecture 1
18 / 28
Propositions
Important Logical Properties and Relations
Truth Table for →
p
F
F
T
T
q
F
T
F
T
p→q
Do it yourself! (Warning: The F → T case is not very intuitive.)
Haythem O. Ismail
Lecture 1
19 / 28
Propositions
Important Logical Properties and Relations
Bi-conditionals
The connective is denoted by ↔, and corresponds to the English
“if and only if”.
If p and q are statements, then p ↔ q is a bi-conditional.
Example
If p represents “whales are mammals”, and
q represents “whales give birth”, then
p ↔ q represents the bi-conditional “whales are mammals if and only
if whales give birth”.
Haythem O. Ismail
Lecture 1
20 / 28
Propositions
Important Logical Properties and Relations
Bi-conditionals
The connective is denoted by ↔, and corresponds to the English
“if and only if”.
If p and q are statements, then p ↔ q is a bi-conditional.
Example
If p represents “whales are mammals”, and
q represents “whales give birth”, then
p ↔ q represents the bi-conditional “whales are mammals if and only
if whales give birth”.
Haythem O. Ismail
Lecture 1
20 / 28
Propositions
Important Logical Properties and Relations
Truth Table for ↔
q
F
T
F
T
p↔q
Haythem O. Ismail
Lecture 1
p
F
F
T
T
Do it yourself!
21 / 28
Propositions
Important Logical Properties and Relations
Truth Tables for Complex Statements
Simon says:
Horses cannot fly and, if pigs can sing, then either horses can fly or
elephants can dance.
Under what conditions would Simon be telling the truth?
Do it yourself.
Haythem O. Ismail
Lecture 1
22 / 28
Propositions
Important Logical Properties and Relations
Outline
1
Propositions
2
Important Logical Properties and Relations
Haythem O. Ismail
Lecture 1
23 / 28
Propositions
Important Logical Properties and Relations
Tautologies and Contradictions
A tautology is a statement that is true under any truth assignment
to its propositional variables.
Example
1
p ∨ ¬p
2
(p ∧ p) ↔ p
3
p → (q → p)
A contradiction is a statement that is false under any truth
assignment to its propositional variables.
Example
1
p ∧ ¬p
2
p ↔ ¬(p ∨ p)
Haythem O. Ismail
Lecture 1
24 / 28
Propositions
Important Logical Properties and Relations
Tautologies and Contradictions
A tautology is a statement that is true under any truth assignment
to its propositional variables.
Example
1
p ∨ ¬p
2
(p ∧ p) ↔ p
3
p → (q → p)
A contradiction is a statement that is false under any truth
assignment to its propositional variables.
Example
1
p ∧ ¬p
2
p ↔ ¬(p ∨ p)
Haythem O. Ismail
Lecture 1
24 / 28
Propositions
Important Logical Properties and Relations
Tautologies and Contradictions
A tautology is a statement that is true under any truth assignment
to its propositional variables.
Example
1
p ∨ ¬p
2
(p ∧ p) ↔ p
3
p → (q → p)
A contradiction is a statement that is false under any truth
assignment to its propositional variables.
Example
1
p ∧ ¬p
2
p ↔ ¬(p ∨ p)
Haythem O. Ismail
Lecture 1
24 / 28
Propositions
Important Logical Properties and Relations
Tautologies and Contradictions
A tautology is a statement that is true under any truth assignment
to its propositional variables.
Example
1
p ∨ ¬p
2
(p ∧ p) ↔ p
3
p → (q → p)
A contradiction is a statement that is false under any truth
assignment to its propositional variables.
Example
1
p ∧ ¬p
2
p ↔ ¬(p ∨ p)
Haythem O. Ismail
Lecture 1
24 / 28
Propositions
Important Logical Properties and Relations
Contingencies
A statement is falsifiable if it is not a tautology.
A statement is satisfiable if it is not a contradiction.
A statement is a contingency if it is both falsifiable and
satisfiable.
Example
1
p
2
p→q
3
p ∨ (q ∧ ¬r)
Haythem O. Ismail
Lecture 1
25 / 28
Propositions
Important Logical Properties and Relations
Contingencies
A statement is falsifiable if it is not a tautology.
A statement is satisfiable if it is not a contradiction.
A statement is a contingency if it is both falsifiable and
satisfiable.
Example
1
p
2
p→q
3
p ∨ (q ∧ ¬r)
Haythem O. Ismail
Lecture 1
25 / 28
Propositions
Important Logical Properties and Relations
Contingencies
A statement is falsifiable if it is not a tautology.
A statement is satisfiable if it is not a contradiction.
A statement is a contingency if it is both falsifiable and
satisfiable.
Example
1
p
2
p→q
3
p ∨ (q ∧ ¬r)
Haythem O. Ismail
Lecture 1
25 / 28
Propositions
Important Logical Properties and Relations
Contingencies
A statement is falsifiable if it is not a tautology.
A statement is satisfiable if it is not a contradiction.
A statement is a contingency if it is both falsifiable and
satisfiable.
Example
1
p
2
p→q
3
p ∨ (q ∧ ¬r)
Haythem O. Ismail
Lecture 1
25 / 28
Propositions
Important Logical Properties and Relations
Contingencies
A statement is falsifiable if it is not a tautology.
A statement is satisfiable if it is not a contradiction.
A statement is a contingency if it is both falsifiable and
satisfiable.
Example
1
p
2
p→q
3
p ∨ (q ∧ ¬r)
Haythem O. Ismail
Lecture 1
25 / 28
Propositions
Important Logical Properties and Relations
Exercise
Example
For each of the following statements, determine whether it is a
tautology, a contradiction, or neither.
1
(p ∧ (p → q)) → q.
2
(¬p ∧ ¬q) ∧ (p ∨ q).
3
(p → q) → (q → p).
Haythem O. Ismail
Lecture 1
26 / 28
Propositions
Important Logical Properties and Relations
Logical Equivalence
Two statements p and q are logically equivalent, denoted p ≡ q,
if and only if p ↔ q is a tautology.
Some important logical equivalences:
See Tables 2, 6, 7, and 8 of the text.
Haythem O. Ismail
Lecture 1
27 / 28
Propositions
Important Logical Properties and Relations
Exercise
Example
Prove the following.
1
p → q ≡ ¬p ∨ q
2
p → q ≡ ¬q → ¬p.
3
p ∧ (p ∨ q) ≡ p.
Haythem O. Ismail
Lecture 1
28 / 28
Download