logic the study of correct reasoning. propositions a proposition is a statement that is either true...
TRANSCRIPT
Logic
The study of correct reasoning
Propositions
A proposition is a statement that is either true or false
Examples
• Today is Monday
• All humans respire
• Joseph is 6 years old
• 5 < 3
• Joyce is sick
• Jorge studies Spanish
• The sun orbits the earth
• All flowers are pink
• 3 6 3
• is a rational number
Are the following propositions?
• Get in the car
This is a command and does not have a true or false response.
• What have you been doing?
This is a question and therefore is not a proposition
• Mathematics is better than English
This is an opinion and is not a proposition
We can represent propositions by using letters like p, q and r
For example
p: There are elephants in Thailand
q: Bangkok is in England False (F)
True (T)
We can write down the truthfulness or falsity of a proposition. This is called its truth value.
Negation (Not) p
The negation of a proposition can be stated by “not” or “it is not the case that...”
p: All lions are fierce
Consider the proposition
:p It is not the case that all lions are fierce
:p Not all lions are fierce
The negation can be represented by
:p Some lions are not fierce
Note that the proposition ‘No lions are fierce’ is NOT the negation of ‘All lions are fierce’. As the proposition ‘All lions are fierce is false if only one lion is not fierce’.
or
or
Consider the proposition
p: The bottle of wine is full
The negation is
The bottle of wine is not full:p
Note we might be tempted to write here that the ‘bottle of wine is empty’. However if it is not completely empty it is not full.
TF
FT
p p
Negation (Not) can be represented by a truth table
p
If the proposition is true then the negation is false
and if the proposition is false then the negation is true
Note that in logic and , the complement of A, in set theory are equivalent
p 'A
Conjunction
Two propositions p and q can be joined together by using the word ‘and’ between them. This is written as
The resulting compound proposition is called a conjunction.
.p q
Consider the following propositions
p: Renzo likes Maths
q: Rafael likes football
:p q Renzo likes Maths and Rafael likes football
Consider the following propositions
p: Paul is Tall
q: Ploy is from Thailand
:p q Paul is tall and Ploy is from Thailand
Consider the following propositions
p: Mr Willis is a Mathematics teacher
q: Mr Astill is a Mathematics teacher
:p q Mr Willis and Mr Astill are both Mathematics teachers
The truth table for a conjunction
FFF
FTF
FFT
TTT
qp p q
When both individual propositions are true then the truth value of the conjunction is true, otherwise the conjunction value will be false.
Note that in logic and , the intersection of sets, in set theory are equivalent
Disjunction
Two propositions p and q can be joined together by using the word ‘or’ between them. This is written as
The resulting compound proposition is called a disjunction.
.p q
Consider the following propositions
p: Bangkok is the capital of Thailand
q: Lima is the capital of England
:p q Bangkok is the capital of Thailand or Lima is the capital of England
T
F
T
Note the ‘or’ in the statement means only one of the propositions has to be true for the whole statement to be true
Consider the following propositions
p: Bangkok is the capital of Cambodia
q: Lima is the capital of England
:p q Bangkok is the capital of Cambodia or Lima is the capital of England
F
F
F
Note since both propositions are false then the disjunction is false.
The truth table for a disjunction
FFF
TTF
TFT
TTT
qp p q
The disjunction value will be true when either one or the other or both propositions are true.
Note that in logic and , the union of sets, in set theory are equivalent
Implication ‘if ….. then …..’
Implication is written as and can be read asp q
• If p then q
• p only if q
• p implies q
• p is a sufficient condition for q
• q if p
• q whenever p
• q is a necessary condition for p
The truth table for an implication
TFF
TTF
FFT
TTT
qp p q
In the formula p is the antecedent while q is referred as the consequent.
,p q
The truth table needs some explaining.
Consider the following propositions
p: It is raining
q: I carry an umbrella
If it is raining then I carry an umbrella:p q
T
T
T
p: It is raining
q: I carry an umbrella
If it is raining then I carry an umbrella:p q
T
F
F
The implication is false as it is raining and I am not carrying an umbrella
p: It is raining
q: I carry an umbrella
If it is raining then I carry an umbrella:p q
p: It is raining
q: I carry an umbrella
If it is raining then I carry an umbrella:p q
F
T
T
The implication is true, as if it is not raining, I may still be carrying my umbrella. Maybe I think it will rain later, or maybe I am going to use it as a defensive weapon!
TFF
TTF
FFT TTT
qp p q
F
F
T
The implication is true, as if it is not raining, I am not carrying the umbrella
p: It is raining
q: I carry an umbrella
If it is raining then I carry an umbrella:p q
The converse is: q p
If I carry an umbrella then it is raining
The inverse is: p q
If it is not raining then I will not carry an umbrella
The contrapositive is: q p
If I do not carry an umbrella then it is not raining
Equivalence ‘if and only if’
Equivalence is written as and can be read asp q
It is raining if and only if I carry an umbrella
Mathematicians abbreviate ‘if and only if’ as ‘iff’
p: We will play badminton
q: The sports hall is not being used
:p q We will play badminton if and only if the sports hall is not being used.
p: Andrea will pass maths
q: The exam is easy
:p q Andrea will pass maths if and only if the exam is easy
The truth table for an equivalence
TFF
FTF
FFT
TTT
qp p q
The truth value of equivalence is true only when all the propositions have the same truth value
T
T
T
T
F
FI brought you the Mars bar even though you didn’t win the game of Cray Pots. I lied the equivalence statement is false.
F
T
FI did not buy you the Mar bar so I lied and therefore the equivalence statement is false.
TFF
FTF
FFT TTT
qp p q
F
F
T
The equivalence is true as I did not buy you a Mars bar and you did not win Cray Pots
p: I will buy you a Mars bar
q: You win the game of Cray Pots
I will buy you a Mars bar if and only if you win a game of Cray Pots:p q
p: I will buy you a Mars bar
q: You win the game of Cray Pots
I will buy you a Mars bar if and only if you win a game of Cray Pots:p q
p: I will buy you a Mars bar
q: You win the game of Cray Pots
I will buy you a Mars bar if and only if you win a game of Cray Pots:p q
Consider the following propositions
p: I will buy you a Mars bar
q: You win the game of Cray Pots
I will buy you a Mars bar if and only if you win a game of Cray pots
:p q
Tautology
A tautology is a compound proposition that is always true regardless of the individual truth values of the individual propositions.
A compound proposition is valid if it is a tautology
Contradiction
A contradiction is a compound proposition that is always false regardless of the individual truth values of the individual propositions
FF
TF
FT
TT
qp q p q
FF
TF
FT
TT
qp
T
F
T
F
q
F
F
T
F
p q
FF
TF
FT
TT
qp
T
F
T
F
q p q
Creating longer propositions
Construct a truth table for p q
Identify the propositions and connectives p, q, and
as these become the headings of the table.
q
p q
FF
TF
FT
TT
qp
T
F
T
F
q p q
FF
TF
FT
TT
qp
T
F
T
F
q
F
F
T
F
p q
Create a truth table for p q r
FFF
TFF
FTF
FFT
TTF
TFT
FTT
TTT
rqp q r p q r
T
F
F
T
F
FF
F
FFF
FTF
FFT TTT
qp p q
T
F
F
T
F
TT
T
TFF
TTF
FFT TTT
qp p q
Show that the statement is logically valid. p p q
To show that a combined proposition is logically valid, you must demonstrate that it is a tautology.
A tautology is a statement that always tells the truth
In order to show that is
a tautology we must create a truth table
p p q
p q
T T
T F
F T
F F
p p q p p q
F
F
T
T
TFF
TTF
FFT TTT
qp p q
T
F
T
T
T
T
T
T
The statement is true for all truth values given to p and q
p p q Therefore is logically valid.
Translating English Sentences
p p qp q p q p q
not p
it is not the case that p
p and q p or q if p then q
p implies q
if p, q
p only if q
p is a sufficient condition for q
q if p
q whenever p
q is a necessary condition for p
p if and only if q
It is not raining
p: It is raining p
Renzo and Rafael both did the IB
p: Renzo did the IB
q: Rafael did the IB
p q
If there is a thunderstorm then Sam cannot use the computer
p: There is a thunderstorm
q: Sam uses the computer
p q
x is not an even number or a prime number
p: x is a even number
q: x is a prime number
p q
If it is raining then I will stay at home. It is raining. Therefore I stayed at home.
p: It is raining
q: I stay at home
p q
p q p q
p q p
If it is raining then I will stay at home
If it is raining then I will stay at home. It is raining
If it is raining then I will stay at home. It is raining. Therefore I stayed at home.
If I go to bed late then I feel tired. I feel tired. Therefore I went to bed late.
p: I go to bed late
q: I feel tired
p q
p q q p
p q q
If I go to bed late then I feel tired.
If I go to bed late then I feel tired. I feel tired.
If I go to bed late then I feel tired. I feel tired. Therefore I went to bed late.
I earn money if and only if I go to work. I go to work. Therefore I earn money.
p: I earn money
q: I go to work
p q
p q q p
p q q
I earn money if and only if I go to work.
I earn money if and only if I go to work. I go to work.
I earn money if and only if I go to work. I go to work. Therefore I earn money.
If I study then I will pass my IB Mathematics. If I pass my IB Mathematics I will get my IB Diploma. I study. Therefore I will get my IB Diploma.
p : I Study
q : I will pass my IB Mathematics
r : I will get my IB Diploma
p q
p q q r
If I study then I will pass my IB Mathematics
If I study then I will pass my IB Mathematics. If I pass my IB Mathematics I will get my IB Diploma
p q q r p
p q q r p r
If I study then I will pass my IB Mathematics. If I pass my IB Mathematics I will get my IB Diploma. I study.
If I study then I will pass my IB Mathematics. If I pass my IB Mathematics I will get my IB Diploma. I study. Therefore I will get my IB Diploma.
TF
FT
p p
FFF
FTF
FFT
TTT
qp p q
FFF
TTF
TFT
TTT
qp p q
TFF
FTF
FFT
TTT
qp p q
TFF
TTF
FFT
TTT
qp p q
Negation Conjunction Disjunction
EquivalenceImplication