0% found this document useful (0 votes)
6 views10 pages

Algebra First Chapter 2023

The document provides an overview of logic, focusing on statements, propositional variables, logical connectives, and truth tables. It explains concepts such as conjunction, disjunction, negation, implications, and equivalences, along with tautologies and logical equivalences. Additionally, it discusses quantifiers and proof techniques, emphasizing the importance of direct reasoning in establishing logical conclusions.

Uploaded by

linahanaizi6
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views10 pages

Algebra First Chapter 2023

The document provides an overview of logic, focusing on statements, propositional variables, logical connectives, and truth tables. It explains concepts such as conjunction, disjunction, negation, implications, and equivalences, along with tautologies and logical equivalences. Additionally, it discusses quantifiers and proof techniques, emphasizing the importance of direct reasoning in establishing logical conclusions.

Uploaded by

linahanaizi6
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Logic

H.C
16 septembre 2023

Logic is the science of thinking correctly.

1 Statements. Logical connectives.


1.1 Statement (Proposition).
Definition 1.1.1 A statement (or proposition) is a sentence which declare something.
A statement is a sentence that can be true or false, but not both simultaneously.
An atomic statement expresses a single idea.

A statement admits two logical values : T or 1 when the statement is true, F or 0 when the
statement is false.

Example 1.1.1 1. 17 is a prime number (T ).


2. George Washington was the first president of United states (T ).
3. 5 > 6 (F ).
4. Let x a real number, the statement x > 3, must be true or false.
5. Every square is a rectangle (T ).
6. Tomorrow it will rain, is not an assertion.

Example 1.1.2 1. Turn the computer off


2. Stop the bus !
3. Have you done it ?
are not statements they are either questions or instructions and they cannot be given a
truth value.

Definition 1.1.2 1.2 Propositional Variables


Each proposition will be represented by a propositional variable. We use the notations P, Q, R, S
etc. for the statement variables.
Each variable can take one of two values : true or false.

1
Lecture Notes Algèbre 1

1.3 Propositional connectives ∧, ∨, ⇒, ⇔.


We use logical connectives to form compound statements, We have some operations on the
class of statements, namely ‘and’, ‘or’, ‘If ..., then ...’, ‘if and only if’ (briefly iff), ‘implies’, and
‘not’. These operations are called the propositional connectives.

1.3.1 Conjunction
1. Logical AND : P ∧ Q
2. Read "P and Q."
3. P ∧ Q is true if both P and Q are true.
4. Also called logical conjunction.
The propositional connective "and" is used to conjoin two statements. The conjunction of a
statement P and a statement Q is written as "P and Q". The symbol "∧" is also used for
"and". Thus, "P ∧ Q" also denotes the conjunction of P and Q.

1.3.2 Disjunction
1. Logical OR : P ∨ Q.
2. Read "P or Q."
3. P ∨ Q is true if at least one of P or Q are true (inclusive OR)
4. Also called logical disjunction.
The propositional connective "or" is used to obtain the disjunction of two statements. The
disjunction of a statement "P " and a statement "Q" is written as "P or "Q". The symbol "∨
is also used for "or". The disjunction of a statement "P " and a statement "Q" is also written
as "P ∨ Q".

1.3.3 Negation, Logical NOT : qP


Usually "not" is used at a suitable place in a statement to obtain the negation of the
statement. The negation of a statement "P " is denoted by qP or P .
1. Read “not P ”
2. qP is true if and only if P is false.
3. Also called logical negation.

1.3.4 Conditional statement


A statement of the form "If P , then Q" is called a conditional statement. The statement
"P " is called the antecedent or the hypothesis, and "Q" is called the consequent or the conclu-
sion. If P , then Q is also expressed by saying that Q is a necessary condition for P . An other
way to express it is to say that P is a sufficient condition for Q.

Page 2
Lecture Notes Algèbre 1

1.3.5 Implication
A statement of the form P implies Q (in symbol P ⇒ Q) is called an implication. The
statement P ⇒ Q and the statement ‘If P , then Q’ are logically same, for (as we shall see) the
truth values of both the statements are always same. Again, "P " is called the antecedent or
the hypothesis, and "Q" is called the consequent or the conclusion.

1.3.6 Equivalence
A statement of the form P if and only if Q (briefly P iff Q) is called an equivalence. P
implies and implied by Q (in symbol P ⇔ Q) is logically same as P if and only if Q. We also
express it by saying that P is a necessary and sufficient condition for Q.

1.4 Truth Tables


Truth Tables Given a collection of propositional components, say P, Q, and R, we can assign
truth values to these components. For example, we can assign the truth values of P, Q, R to be
T, F, T respectively, where T means “true” while F means “false.” The truth value of a sentence
in propositional logic can be evaluated from the truth values assigned to its components. We
shall explain what this “means” by using truth tables.
The truth table of a statement P , is given by the table :

P
T or 1
F or 0
qP or P is true if and only if P is false. The truth table of a statement qP , is given by the
table :
P P
T F
F T
1. The truth functional rule for the conjunction P ∧ Q.
P ∧ Q is true if both P and Q are true, and The truth table of the proposition P ∧ Q is
given by :
P Q P ∧Q
T T T
T F F
F T F
F F F

2. The truth functional rule for the disjunction P ∨ Q.


P ∨ Q is true if at least one of P or Q are true (inclusive OR), and The truth table of

Page 3
Lecture Notes Algèbre 1

the proposition P ∨ Q is given by :

P Q P ∨Q
T T T
T F T
F T T
F F F

3. The truth functional rule for ‘If P , then Q (P ⇒ Q).


The statement "P ∨ Q" is denoted P ⇒ Q, that we read P implies Q. The statement
formula "If P , then Q " (P ⇒ Q) is false in only one case when P is true but Q is false.
Take, for example, the statement ‘If a student works hard, then he will pass.’ The truth
of this statement says that if some student works hard, then he will pass. If there is some
student who has not worked hard, then whether he passes, or he fails, the truth of the
statement remains unchallenged.
4. The statement P ⇔ Q is the conjunction of the statement P ⇒ Q and the Q ⇒ P.

We summarize in a truth table, as follows :

P Q P P ∧Q P ∨Q P ∨Q P ⇒Q Q⇒P P ⇔Q
T T F T T T T T T
T F F F T F F T F
F T T F T T T F F
F F T F F T T T T

We notice that P ⇐⇒ Q is true when P and Q have the same logical value.

Let P, Q and R be three propositions. Then


— P ⇐⇒ P.
— P ∧ Q ⇐⇒ P ∨ Q .
— P ∨ Q ⇐⇒  P ∧ Q. 
— P =⇒ Q ⇐⇒ P ∧ Q
— P =⇒ Q ⇐⇒ Q =⇒ P
— P ∧ (Q ∨ R) ⇐⇒ (P ∧ Q) ∨ (P ∧ R) .
— P ∨ (Q ∧ R) ⇐⇒ (P ∨ Q) ∧ (P ∨ R) .

Proof 1.4.1 It is enough to establish the truth table of the propositions in question.

2 Tautology and Logical Equivalences


A propositional sentence is a tautology if it is always true. For example, one can see from
the following truth table that the sentence P ∨ P is a tautology.
A statement formula is called a tautology if its truth value is always T irrespective of the
truth values of its atomic statement variables. A statement formula is called a contradiction

Page 4
Lecture Notes Algèbre 1

if its truth value is always F irrespective of the truth values of its atomic statement variables.
Thus, the negation of a tautology is a contradiction, and the negation of a contradiction is a
tautology. The Example :

Example 2.0.1 1.

P Q P P ∨Q (P ∨ Q) ∧ P (P ∨ Q) ∧ P ⇒ Q
T T F T F T
T F F T F T
F T T T T T
F F T F F T

is a tautology.
2. P ∧ P is a contradiction.

Example 2.0.2 1. ∀x, (P (x) ⇒ Q(x)) ⇔ ∃x/ (P (x) ∧ Q(x)) is a tautology.


2. [(P ⇒ Q) ∧ (Q ⇒ R)] ⇔ (P ⇒ R) is a tautology.
(verify by making truth table).

The statement formula A is said to be logically equivalent to B if A ⇔ B is a tautology. In


mathematics and logic, we do not distinguish logically equivalent statements. They are taken
to be same. If A is logically equivalent to B, we may substitute B for A and A for B in any
course of discussion or derivation.

Example 2.0.3 P ⇒ Q is logically equivalent to P ∨ Q.

1. Using truth tables, we concluded that

(P ∧ Q) ⇔ P ∨ Q.

2. We can also use truth tables to show that

(P ∨ Q) ⇔ P ∧ Q.

These two equivalences are called Morgan’s Laws.

3 Quantifiers
The symbols ∀ and ∃ are called quantifiers because they refer in some sense to the quantity
(i.e., all or some) of the variable that follows them. Symbol ∀ is called the universal quantifier
and ∃ is called the existential quantifier. Statements which contain them are called quantified
statements. A statement beginning with ∀ is called a universally quantified statement, and one
beginning with ∃ is called an existentially quantified statement.

Page 5
Lecture Notes Algèbre 1

3.1 Existential Quantifier


Consider the statement "There is a man who is immortal". More generally, we have state-
ments of the form "There exists x, P (x)", where P (x) is a statement involving x. The symbol
"∃" stands for "there exists", and it is called the existential quantifier. The statement
∃x ∈ E/P (x) is a true statement when we can find at least one x of E for which P (x) is true.
We read « there exists x belonging to E such that P (x) (be true) »
Example 3.1.1 1. A function f which vanishes at x0 ∈ R becomes :

∃x0 ∈ R/ f (x0 ) = 0.

In order to specify that f vanishes into a single value, we add an exclamation point :

∃!x0 ∈ R / f (x0 ) = 0.
1
2. ∃x ∈ R/ x (x − 1) < 0 is a true statement. (For example x = 2
verifies the property).
3. ∃x ∈ R/ x2 = −4 is a false statement (no squared real will give a negative number).

3.2 Universal quantifier


Consider the statement " For every river, there is an origin. " This can be rewritten as "
For every x, (x is a river implies x has an origin)." More generally, we have statements of the
form "For every x, P (x)", where P (x) is a statement involving x. The symbol "∀" is used for
"for every", and it is called the universal quantifier.

3.3 Negation of a Statement Formula Involving Quantifiers


Consider the statement "Every river has an origin". This can be rephrased as :
∀x, (x is a river ⇒ x has an origin). When can this statement be false ? It is false if and only
if there is a river which has no origin. Similarly, consider the statement "Every man is mortal".
This can also be rephrased as ∀x, (x is a man ⇒ x is mortal). Again this statement can be
challenged if and only if there is a man who is immortal. Now, consider the statement "There
is a river which has no origin". To say that this statement is false is to say that "Every river
has an origin". This prompts us to have the truth functional rule for the statement formulas
involving quantifiers as given by the following table :

∀x, (P (x) ⇒ Q(x)) ∃x/(P (x) ∧ Q(x))


T F
F T
Thus,
∀x, (P (x) ⇒ Q(x)) ⇔ ∃x/(P (x) ∧ Q(x))
where P (x) and Q(x) are valid statements involving the symbol x, is always a true statement.
Also
∃x/(P (x) ∧ Q(x)) ⇔ ∀x, (P (x) ⇒ Q(x))
is always a true statement.

Page 6
Lecture Notes Algèbre 1

The negation of quantifiers


1. The negation of « ∀x ∈ E, P (x) » is « ∃x ∈ E/ P (x) ».
2. The negation of « ∃x ∈ E/ P (x) » is « ∀x ∈ E, P (x) ».

Example 3.3.1 1. The negation of « ∀x ∈ [1, +∞[, (x2 ≥ 1) » is the statement


« ∃x ∈ [1, +∞[/ (x2 < 1)».
2. The negation of « ∀x ∈] − ∞, 0[, ( a < b ⇒ a2 > b2 ) » is the statement
« (∃x ∈] − ∞, 0[/ (a < b et a2 ≤ b2 )».

Remark
The order of quantifiers is very important. For example both logical sentences :

∀x ∈ Z, ∃x0 ∈ Z / x + x0 = 0, ∃x0 ∈ Z / ∀x ∈ Z, x + x0 = 0
are different. The first is true, the second is false.

4 Analyzing Proof Techniques


4.1 Direct reasoning (Direct proof)
In direct proof, the conclusion is established by logically combining the axioms, definitions,
and earlier theorems.
When we want to prove a conditional statement P implies Q, we assume that P is true, and
follow implications to get to show that Q is then true.

Example 4.1.1 Direct proof can be used to prove that the sum of two even integers is always
even :
Consider two even integers x and y. Since they are even, they can be written as x = 2a and
y = 2b, respectively, for some integers a and b. Then the sum is x + y = 2a + 2b = 2(a + b).
Therefore x + y has 2 as a factor and, by definition, is even. Hence, the sum of any two even
integers is even. This proof uses the definition of even integers and the distributive property.

4.2 Proof by Cases (Proof by Exhaustion) :


In this method, we evaluate every case of the statement to conclude its truthiness.

Proof by exhaustion means breaking a statement down into a series of individual cases and
proving each one separately. It is the disjunction or case-by-case method.

Example 4.2.1 Show that for x ∈ R, |x + 1| ≤ x2 + x + 1.


Let x ∈ R. We distinguish two cases.
First case : x ≥ 1. Then |x − 1| = x − 1. Let’s then calculate x2 − x + 1 − |x − 1|.
x2 − x + 1 − |x − 1| = x2 − x + 1 − (x − 1) = x2 − 2x + 2 = (x − 1)2 + 1 ≥ 0.

So x2 − x + 1 − |x − 1| ≥ 0 and so x2 − x + 1 ≥ |x − 1|.

Page 7
Lecture Notes Algèbre 1

Second case : x < 1. Then |x − 1| = −(x − 1). We obtain

x2 − x + 1 − |x − 1| = x2 − x + 1 + (x − 1) = x2 ≥ 0.

and so x2 − x + 1 ≥ |x − 1|.
Conclusion. In all cases |x + 1| ≤ x2 + x + 1.

4.3 Proof by Contrapositive :

Proof by contraposition infers the statement "if P then Q" by establishing the logically
equivalent contrapositive statement : "if not Q then not P ", it is a reasoning which consists of
showing the statement P =⇒ Q using the following equivalence : P =⇒ Q ⇐⇒ Q =⇒ P.
Example 4.3.1 . Let n ∈ N. Show that if n2 is odd then n is odd.
Proof 4.3.1 We assume that n is not odd and we show that then n2 is not odd.
Since n is not odd, it is even and therefore there exists k ∈ N, such that n = 2k. Then
n2 = (2k)2 = 4k 2 = 2 (2k 2 ). And so n2 is even.
Conclusion : We have shown that if n is even then n2 is even. By contraposition this is
equivalent to : n2 is odd then n is odd.

4.4 Proof by Contradiction

In proof by contradiction, also known by the Latin phrase reductio ad absurdum (by
reduction to the absurd), it is shown that if some statement is assumed true, a logical contra-
diction occurs, hence the statement must be false.
Absurd reasoning is based on the following principle :
We assume both that P is true and that Q is false and we look for a contradiction. So if P is
true then Q must be true and therefore « P√ =⇒ Q» is true.
A famous example involves the proof that 2 is an irrational number (See Tutorial series).
1
Example 4.4.1 Let a, b ∈ ]0, +∞[ . Show that b ≤ a =⇒ b
≥ a1 .
Proof 4.4.1 .Suppose that 1b < a1 , then a1 − 1b > 0 which corresponds to b−a ab
> 0, this is
impossible since b − a ≤ 0 and ab > 0, this contradicts our previous statement.
Therefore, if b ≤ a alors 1b ≥ a1 .

4.5 Proof by Counterexample :


Definition 4.5.1 A proof by counterexample is a method of showing that a general statement
is false by finding a single example that contradicts it.
For a given general statement, there may be many possible counterexamples, but the existence
of just one is sufficient to disprove the statement.
If we want to show that an statement of the type « ∀x ∈ E, (P (x)) » is true then we must
show that for each x of E, P (x) is true. On the other hand for show that this assertion is false,
it suffices to find x ∈ E such that P (x) is false. Finding such x is finding a counterexample to
the assertion « ∀x ∈ E, P (x) ».

Page 8
Lecture Notes Algèbre 1

Example 4.5.1 Show that the following assertion is false « Every positive integer is the sum
of three squares ».

Proof 4.5.1 A counterexample is the number 7 : the squares less than 7 are 0, 1, 4 but with
three of these numbers we cannot make 7.

4.6 Proof by induction :


The Principle of Mathematical Induction (PMI)
Let P (n) be a statement about the positive integer n. If the following are true :
1. Base Case : We need to show that p(n) is true for the smallest possible value of n,
show that p(n0 ) is true.
2. Induction Hypothesis : Assume that the statement p(n) is true for any positive integer
n = k, for k ≥ n0 .
3. Inductive Step : Show that the statement p(n) is true for n = k + 1.
4. Conclusion : We recall that by induction, P (n) is true for all n ∈ N.

Example 4.6.1 For every positive integer n,

1 + 2 + · · · + n = n(n + 1)/2

Proof :
1. Base case : If n = 1, 1 + · · · + n = 1, and n(n + 1)/2 = 11
2. Inductive Step :
Suppose that for a given n

1 + 2 + · · · + n = n(n + 1)/2( inductive hypothesis) (4.1)

Our goal is to show that :

1 + 2 + · · · + n + (n + 1) = [n + 1]([n + 1] + 1)/2

i.e.
1 + 2 + · · · + n + (n + 1) = (n + 1)(n + 2)/2
Add n + 1 both sides to equation (4.1), we get :

1 + 2 + · · · + n + (n + 1) = n(n + 1)/2 + (n + 1)
= n(n + 1)/2 + 2(n + 1)/2
= (n + 2)(n + 1)/2

Example 4.6.2 Show that for any natural number n ≥ 4, we have 2n < n! .
Let us show by induction on the integer n ≥ 4, that the property P (n) : 2n < n! is true.
— Base case : For n = 4, we have 2n = 16 and n! = 4! = 24, which shows that 24 < 4! .
Thus, P (n) is true for n = 4.

Page 9
Lecture Notes Algèbre 1

— Inductive Step : Assume that P (n) is true and show that P (n + 1) is true, which
amounts to assuming that 2n < n! and to show that 2n+1 < (n + 1)! .
We therefore assume that 2n < n! , then 2n+1 = 2.2n < 2(n! ), as n ≥ 4, then n > 2 and
also n + 1 > 2, which leads to

2n+1 < 2(n! ) < (n + 1).n! = (n + 1)! .

So if 2n < n! then 2n+1 < (n + 1)! , which shows that P (n) =⇒ P (n + 1).
— In conclusion, by induction on n ≥ 4, we have 2n < n! .

Page 10

You might also like