Cours Notion de Logique en
Cours Notion de Logique en
Baccalaureat science
Prince Moulay Abdellah High School mathematics option
Direction provinciale Anfa
English
Lllll
LOGIC'S NOTION
Directed by : Teacher MSADAR SOUFIANE
Prerequisites :
➢ Everything studied in previous levels
Expected skills :
➢ Use the appropriate type of reasoning for the situation being studied ;
➢ Write clear, logically correct mathematical reasoning and demonstrations.
Extensions :
➢ Continuity in all lessons
Objectives:
➢ Knowing propositions and propositional functions
➢ Knowing the existential quantifier and the universal quantifier
➢ Know the operations on propositions
➢ Be familiar with the different types of logical reasoning
Teaching recommendations :
➢ Propositions, laws of logic and methods of reasoning will be brought together using a variety of activities based on
what the pupils have already learnt and mathematical situations they have already encountered;
➢ Theoretical constructs and excessive use of truth tables should be avoided;
➢ The results relating to logic should be exploited at all appropriate times in the various chapters of the programme.
Programme content :
I. Definitions
II. Operations on proposals
III. Logical laws and reasoning methods
Teaching aids :
➢ The table
➢ Series of exercises and activities n°1
➢ References
➢ Internet
➢ ...
Pr: MSADAR SOUFIANE Chapter 1: Logic concepts
Activity sheet: Logic concepts
Activity ❶
For each of the following statements say :
𝑃 "1 + 3 = 4" ............................................
▪ If it is true 𝑄 "25 is a 𝑚𝑢𝑙𝑡𝑖𝑝𝑙𝑒 of 7" ............................................
▪ If it is false 𝑅 "𝜋 ∈ 𝔻" ............................................
▪ If you can't predict whether it's true or 𝑆 "5+< 3" ............................................
false 𝑈(𝑥) "𝑥 ∈ ℝ: 𝑥 2 − 𝑥 ≥ 0" ............................................
▪ If it doesn't make sense 𝑉(𝑎, 𝑏) 𝑎, 𝑏 ∈ ℝ: 𝑎 < 𝑏" ............................................
Activity ❷
Or 𝑝(𝑥): "𝑥 ∈ ℝ: 𝑥 2 − 𝑥 = 0"
Activity ❸
Determine the truth table for the statement 𝑃̅ 𝑜r 𝑄
Activity ❹
1- Draw up the truth table for the statement (𝑃 ⟹ 𝑄)𝑒𝑡 (𝑄 ⟹ 𝑃)
2- When is the statement (𝑃 ⟹ 𝑄)𝑒𝑡 (𝑄 ⟹ 𝑃) true?
I- Definitions :
1- Proposition-Propositional function :
Definition: (proposition)
A proposition or assertion is a mathematical statement made up of a collection of words and symbols which has a meaning
and to which a truth value can be assigned, either true (V or 1) or false (F or 0), but not both at the same time (principle of
non-contradiction).
Examples:
• "1 < 3" is a true statement
• "-6 is a natural number" is a false statement
• "2 + 4" is not an assertion
Examples:
..........................................................................................................................................................
..........................................................................................................................................................
..........................................................................................................................................................
..........................................................................................................................................................
..........................................................................................................................................................
..........................................................................................................................................................
2- Quantifiers :
From a propositional function 𝑃(𝑥) defined on a set 𝐸we can construct new propositions called quantified propositions,
using the quantifiers "whatever" and "there exists at least".
Definition:
Let "𝑥 ∈ 𝐸, 𝑃(𝑥)" be a propositional function defined on a set 𝐸.
• The universal quantifier is the symbol "∀"which can be used to form the quantified proposition : "∀𝒙 ∈ 𝑬, 𝑷(𝒙)"
Which is true if 𝑃(𝑥) is true for all elements 𝑥 of 𝐸and is false if 𝑃(𝑥) is false for at least one element 𝑥 of 𝐸.
• The existential quantifier is the symbol "∃"reads "there exists at least", which is used to form the quantified
proposition : "∃𝒙 ∈ 𝑬, 𝑷(𝒙)"
Which is true if 𝑃(𝑥) is true for at least one element 𝑥 of 𝐸and is false if 𝑃(𝑥) is false for all elements 𝑥 of 𝐸.
Remarks :
• If the statement "∀𝑥 ∈ 𝐸, 𝑃(𝑥)" is true, then the statement "∃𝑥 ∈ 𝐸, 𝑃(𝑥)" is true.
• If there is one and only one element 𝑥 of 𝐸 such that 𝑃(𝑥) is true, we can write : "∃! 𝒙 ∈ 𝑬, 𝑷(𝒙)" which reads "there
exists a unique 𝑥 of 𝐸 verifying 𝑃(𝑥) "
Examples:
Pr: MSADAR SOUFIANE Chapter 1: Logic concepts
• The proposition "∀𝑥 ∈ ℝ, 𝑥 ≥ 0" is false
• The proposition "∃𝑥 ∈ ℝ, 𝑥 2 = −1" is false (because no real squared will give a negative number)
• The proposition "∃! 𝑥 ∈ ℤ, 𝑥 + 5 = 1" is true
• The proposition "𝑖𝑙 𝑒𝑥𝑖𝑠𝑡𝑒 𝑢𝑛 𝑒𝑛𝑡𝑖𝑒𝑟 𝑛𝑎𝑡𝑢𝑟𝑒𝑙 𝑝𝑎𝑖𝑟 𝑒𝑡 𝑝𝑟𝑒𝑚𝑖𝑒𝑟" is true
• The proposition "∀𝑥 ∈ ℝ ∃𝑦 ∈ ℝ 𝑡𝑒𝑙 𝑞𝑢𝑒 𝑥 < 𝑦" is true
Definition:
The negation of a proposition 𝑃 is the proposition which is true if 𝑃 is false and which is false if 𝑃 is true.
̅ " or "𝑵𝒐𝒏(𝑷)" or "¬𝑷"
It is noted "𝑷
This definition is summarised in a truth table as follows:
𝑷 ̅
𝑷
V F
F V
Examples:
𝑷 ̅
𝑷
√2 ∈ ℚ √2 ∉ ℚ
2−6 = 4 2−6≠4
3<4 3≥4
12 + 5 ≤ 4 12 + 5 > 4
Ownership :
Let "𝑥 ∈ 𝐸, 𝑃(𝑥)" be a propositional function defined on a set 𝐸.
• The negation of the proposition "∀𝑥 ∈ 𝐸, 𝑃(𝑥)" is the proposition "∃𝑥 ∈ 𝐸, 𝑁𝑜𝑛(𝑃(𝑥))"
• The negation of the proposition "∃𝑥 ∈ 𝐸, 𝑃(𝑥)" is the proposition "∀𝑥 ∈ 𝐸, 𝑁𝑜𝑛(𝑃(𝑥))"
Examples:
𝑷 ̅
𝑷
∀𝑥 ∈ ℝ, 𝑥 ≥ 0 ∃𝑥 ∈ ℝ, 𝑥 < 0
2
∃𝑥 ∈ ℝ, 𝑥 = −1 ∀𝑥 ∈ ℝ, 𝑥 2 ≠ −1
∀𝑥 ∈ ℝ ∃𝑦 ∈ ℝ 𝑡𝑒𝑙 𝑞𝑢𝑒 𝑥 < 𝑦 ∃𝑥 ∈ ℝ ∀𝑦 ∈ ℝ 𝑡𝑒𝑙 𝑞𝑢𝑒 𝑥 ≥ 𝑦
Definition:
The conjunction of two propositions 𝑃 and 𝑄 is the proposition which is true only if the two propositions 𝑃 and 𝑄 are true at
the same time, and which is false when at least one of the propositions 𝑃 and 𝑄 is false. It is denoted (𝑷 and 𝑸) or (𝑷 ∧ 𝑸)
Examples:
Determine the truth value of the following statements:
Truth value
PQ P and
P Q
Q
"7 𝑒𝑠𝑡 𝑢𝑛 𝑛𝑜𝑚𝑏𝑟𝑒 𝑖𝑚𝑝𝑎𝑖𝑟" and "4 𝑒𝑠𝑡 𝑢𝑛 𝑛𝑜𝑚𝑏𝑟𝑒 𝑝𝑟𝑒𝑚𝑖𝑒𝑟" V F F
"3 𝑑𝑖𝑣𝑖𝑠𝑒 17" and "25 𝑒𝑠𝑡 𝑢𝑛 𝑚𝑢𝑙𝑡𝑖𝑝𝑙𝑒 𝑑𝑒 7" F F F
"5 𝑒𝑠𝑡 𝑛é𝑔𝑎𝑡𝑖𝑓" and "12 𝑒𝑠𝑡 𝑝𝑜𝑠𝑖𝑡𝑖𝑓" F V F
"2 + 3 = 5" and "∃𝑥 ∈ ℝ, 𝑥 < 0" V V V
Remarks :
• The proposition "𝑃 𝑒𝑡 𝑄" has the same truth value as the statement "𝑄 𝑒𝑡 𝑃".
3- Disjunction of two propositions " ∨ "
Pr: MSADAR SOUFIANE Chapter 1: Logic concepts
Definition:
The disjunction of two propositions 𝑃 and 𝑄 is the proposition that is true if at least one of the two propositions 𝑃 and 𝑄 is
true, and which is false when both propositions 𝑃 and 𝑄 are false at the same time. It is noted (𝑷 or 𝑸) or (𝑷 ∨ 𝑸)
Examples:
Determine the truth value of the following statements:
Truth value
P∨ Q
P Q P or Q
"7 is an odd number " or "4 is a prime number " V F V
"3 𝑑𝑖𝑣𝑖𝑠𝑒 17" or "25 is a 𝑚𝑢𝑙𝑡𝑖𝑝𝑙𝑒 of 7" F F F
"5 i𝑠 𝑛e𝑔𝑎𝑡𝑖ve" or "12 is 𝑝𝑜𝑠𝑖𝑡𝑖ve" F V V
"2 + 3 = 5" or "∃𝑥 ∈ ℝ, 𝑥 < 0" V V V
Remarks :
• The proposition "𝑃 𝑜𝑢 𝑄" has the same truth value as the statement "𝑄 𝑜𝑢 𝑃".
Definition:
Based on two propositions 𝑃 and 𝑄 we obtain the proposition "𝑃̅ 𝑜𝑢 𝑄" which is false if 𝑃 is true and 𝑄 is false and true
otherwise. The proposition "𝑃̅ 𝑜𝑢 𝑄" is called P implies Q and is written "𝑷 ⇒ 𝑸"
Examples:
Determine the truth value of the following statements:
Truth value
P ⇒Q
P Q 𝑷⇒𝑸
"7 is an odd number " ⇒ "4 is a prime number " V F F
"3 𝑑𝑖𝑣𝑖𝑠𝑒 17" ⇒ "25 is a 𝑚𝑢𝑙𝑡𝑖𝑝𝑙𝑒 of 7" F F V
"5 is 𝑛e𝑔𝑎𝑡𝑖𝑓" ⇒ "12 is 𝑝𝑜𝑠𝑖𝑡𝑖𝑓" F V V
"2 + 3 = 5" ⇒ "∃𝑥 ∈ ℝ, 𝑥 < 0" V V V
Remarks :
Definition:
The equivalence of two propositions 𝑃 and 𝑄 is the proposition "𝑷 ⇔ 𝑸" and which is true if 𝑃 and 𝑄 have the same truth
value.
Examples:
Determine the truth value of the following statements:
P ⇔Q Truth value
Pr: MSADAR SOUFIANE Chapter 1: Logic concepts
P Q 𝑷⇔𝑸
"7 is an odd numebr" ⇔ "4 is a prime number " V F F
"3 𝑑𝑖𝑣𝑖𝑠𝑒 17" ⇔ "25 is a 𝑚𝑢𝑙𝑡𝑖𝑝𝑙𝑒 of 7" F F V
"5 is 𝑛e𝑔𝑎𝑡𝑖𝑓" ⇔ "12 is 𝑝𝑜𝑠𝑖𝑡𝑖𝑓" F V F
"2 + 3 = 5" ⇔ "∃𝑥 ∈ ℝ, 𝑥 < 0" V V V
Remarks :
0) 𝑜𝑢 (𝑥 > 0 𝑒𝑡 𝑥 2 − 4 = 0)"
Definition:
A logical law is any proposition composed of several propositions (P, Q, R, ...) linked together by logical connectors
(∨,∧, ⇒, ⟺) and which is always true whatever the truth value of the propositions that make it up.
Examples:
• The proposal "𝑃 ⇒ 𝑃" is a logical law
• The proposal "𝑃 𝑒𝑡 𝑁𝑜𝑛(𝑃)" is not a logical law
• The proposal "𝑁𝑜𝑛(𝑁𝑜𝑛(𝑃)) ⇔ 𝑃" is a logical law
Ownership :
Either 𝑃, 𝑄 𝑒𝑡 𝑅 three proposals
• Morgan's Laws
➢ ̅̅̅̅̅̅̅̅
𝑃 𝑒𝑡 𝑄 ⇔ 𝑃̅ 𝑜𝑢 𝑄̅
➢ 𝑃 𝑜𝑢 𝑄 ⇔ 𝑃̅ 𝑒𝑡 𝑄̅
̅̅̅̅̅̅̅̅̅
• Commutativity
➢ (𝑃 𝑒𝑡 𝑄) ⇔ (𝑄 𝑒𝑡 𝑃)
➢ (𝑃 𝑜𝑢 𝑄) ⇔ (𝑄 𝑜𝑢 𝑃)
➢ (𝑃 ⇔ 𝑄) ⇔ (𝑄 ⇔ 𝑃)
• Distributivity
➢ (𝑃 𝑒𝑡( 𝑄 𝑜𝑢 𝑅)) ⇔ (𝑃 𝑒𝑡 𝑄) 𝑜𝑢 (𝑃 𝑒𝑡 𝑅)
➢ (𝑃 𝑜𝑢 ( 𝑄 𝑒𝑡 𝑅)) ⇔ (𝑃 𝑜𝑢 𝑄) 𝑒𝑡 (𝑃 𝑜𝑢 𝑅)
• Principle of contraposition
➢ (𝑃 ⇒ 𝑄) ⇔ (𝑄̅ ⇒ 𝑃̅)
• Principle of absurdity
➢ ((𝑃̅ ⇒ 𝑄) 𝑒𝑡 (𝑃̅ ⇒ 𝑄̅ )) ⇔ 𝑃
• Principle of case separation
➢ ((𝑃 ⇒ 𝑄) 𝑒𝑡 (𝑃̅ ⇒ 𝑄)) ⇒ 𝑄
• Principle of transitivity of implication
➢ ((𝑃 ⇒ 𝑄) 𝑒𝑡 (𝑄 ⇒ 𝑅)) ⇔ (𝑃 ⇒ 𝑅)
• Principle of transitivity of equivalence
➢ ((𝑃 ⇔ 𝑄) 𝑒𝑡 (𝑄 ⇔ 𝑅)) ⇔ (𝑃 ⇔ 𝑅)
2- Methods of reasoning :
a) Reasoning by the absurd :
Method :
((𝑃̅ ⇒ 𝑄) 𝑒𝑡 (𝑃̅ ⇒ 𝑄̅ )) ⇔ 𝑃
̅" is true and we show that this
To show that the proposition "P" is true, by the absurd, consists in supposing that "P
leads to a contradiction.
We conclude that 𝑃 is true.
Remarks :
• To show, by absurdity, that the proposition "𝑃 ⇒ 𝑄" is true, we assume that "P" and "Non(Q)" are true and show that
this leads to a contradiction.
Example:
Show that √𝟐 ∉ ℚ
We are going to prove that √2 is an irrational number using a proof by the absurd.
In other words, we will consider the inverse and assume that √2 is a rational number.
If √2 ∈ ℚ then it can be written as an integer fraction.
𝑝 𝑝
⟹ ∃(𝑝, 𝑞) ∈ ℤ × ℤ∗ 𝑡𝑒𝑙 𝑞𝑢𝑒 𝑝 ∧ 𝑞 = 1: √2 = (In other words is an irreducible fraction)
𝑞 𝑞
2 2
⟹ 𝑝 = 2𝑞
⟹ 𝑝2 is even
⟹ 𝑝 is even
⟹ ∃ 𝑘 ∈ ℕ: 𝑝 = 2𝑘
Hence 4𝑘 2 = 2𝑞 2 ⟹ 𝑞 2 = 2𝑘 2
⟹ 𝑞 is even
⟹ ∃ 𝑘′ ∈ ℕ: 𝑞 = 2𝑘′
𝑝
So 𝑝 and 𝑞 are divisible by 2, i.e. 𝑝 ∧ 𝑞 ≠ 1 then is not irreducible
𝑞
This contradicts our initial hypothesis.
Application: exercise ❹ in the series
b) Contrapositive reasoning :
Method :
(𝑃 ⇒ 𝑄) ⇔ (𝑄̅ ⇒ 𝑃̅)
Demonstrating that the proposition "𝑃 ⇒ 𝑄" is true, by contraposition, consists in demonstrating that the proposition
"𝑄̅ ⇒ 𝑃̅" is true.
In practice, we assume that 𝑄̅ is true and show that 𝑃̅ is true.
Example:
𝟏 𝟏
Let 𝒂 and 𝒃 be two real numbers. Show that : 𝒂 + 𝒃 > 𝟏 ⇒ (𝒂 > 𝟐 𝒐𝒖 𝒃 > 𝟐)
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
Application: exercise ❼ of the series
Method :
((𝑃 ⇒ 𝑄) 𝑒𝑡 (𝑃̅ ⇒ 𝑄)) ⇒ 𝑄
Pr: MSADAR SOUFIANE Chapter 1: Logic concepts
Let 𝑃(𝑥) be a propositional function defined on a set 𝐸.
Show that 𝑃(𝑥) is true for any element 𝑥 of 𝐸by disjunction of the cases, consists in separating the reasoning
according to all the values that can take 𝑥.
Example:
𝑛(𝑛+1)
Show that "∀𝑛 ∈ ℕ, ∈ ℕ"
2
There are two cases: "n is even" and "n is odd".
- If n is even then "∃𝑘 ∈ ℕ 𝑡𝑒𝑙 𝑞𝑢𝑒: 𝑛 = 2𝑘
𝑛(𝑛+1)
Hence 2
= 𝑘(2𝑘 + 1) which is a natural number
- If n is odd then "∃𝑘 ∈ ℕ 𝑡𝑒𝑙 𝑞𝑢𝑒: 𝑛 = 2𝑘 + 1
𝑛(𝑛+1)
Hence 2 = (𝑘 + 1)(2𝑘 + 1) which is a natural number
𝑛(𝑛+1)
We have shown that for any natural number n that ∈ℕ
2
Application: exercise ❾ in the series
d) Reasoning by equivalence :
Method :
((𝑃 ⇔ 𝑄) 𝑒𝑡 (𝑄 ⇔ 𝑅)) ⇔ (𝑃 ⇔ 𝑅)
To show that the statement "𝑃 ⇔ 𝑄" is true, there are two methods:
• An equivalence sequence is established between 𝑃 and 𝑄preserving the equivalences at each stage, then
proceed as follows : "𝑃 ⇔ ⋯ ⇔ ⋯ ⇔ 𝑄".
• We generally reason by double implications: we show that "𝑃 ⇒ 𝑄" is true, then that "𝑄 ⇒ 𝑃"is also true.
Example:
Show that : (∀ 𝒂, 𝒃 ∈ ℝ∗+ ): 𝒂 + 𝒃 ≥ 𝟐√𝒂𝒃
(∀ 𝑎, 𝑏 ∈ ℝ∗+ ): 𝑎 + 𝑏 ≥ 2√𝑎𝑏 ⟺ (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): 𝑎 + 𝑏 − 2√𝑎𝑏 ≥ 0
⟺ (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): √𝑎2 − 2√𝑎√𝑏 + √𝑏 2 ≥ 0
2
⟺ (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): (√𝑎 − √𝑏) ≥ 0
2
We have therefore shown that the proposition : (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): 𝑎 + 𝑏 ≥ 2√𝑎𝑏 ⟺ (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): (√𝑎 − √𝑏) ≥ 0 is
true
2
And since the proposition (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): (√𝑎 − √𝑏) ≥ 0 is true
Then the proposition (∀ 𝑎, 𝑏 ∈ ℝ∗+ ): 𝑎 + 𝑏 ≥ 2√𝑎𝑏 is also true
Application: exercise ❽ in the series
e) Reasoning by recurrence :
Method :
Let 𝑛0 ∈ ℕ and 𝑃(𝑛) a propositional function defined on ℕ.
To show that "∀𝑛 ≥ 𝑛0 , 𝑃(𝑛)" is true follow these steps:
• We show that 𝑃(𝑛0 ) is true
• We fix 𝑛 ≥ 𝑛0 and assume that 𝑃(𝑛) is true, and then show that 𝑃(𝑛 + 1) is also true.
Then we can conclude that "∀𝑛 ≥ 𝑛0 , 𝑃(𝑛)" is true
Example:
Show by recurrence that : (∀𝒏 ∈ ℕ): 𝟐𝒏 > 𝒏
• For 𝑛 = 0 we have : 20 = 1 therefore 20 > 0 then the proposition is true for 𝑛 = 0
• Suppose that 2𝑛 > 𝑛 is true for 𝑛 ∈ ℕ and show that 2𝑛+1 > 𝑛 + 1 is true
We have : 𝑛 + 1 > 𝑛 then 2𝑛 ≥ 𝑛 + 1 so 2 × 2𝑛 ≥ 2 × (𝑛 + 1) > 𝑛 + 1
Finally 2𝑛+1 > 𝑛 + 1
• Therefore, according to the reasoning by recurrence we have : (∀𝑛 ∈ ℕ): 2𝑛 > 𝑛
Application: exercise ❿ in the series