0% found this document useful (0 votes)
13 views

Lecture 3

The document summarizes key concepts about truth tables and logical statements: (1) It provides examples of truth tables for logical statements involving connectives like negation, conjunction, and disjunction. (2) It defines logical concepts like tautology, contradiction, and discusses De Morgan's laws. (3) It discusses conditional statements and their relationships - a conditional statement is equivalent to its contrapositive but not its inverse or converse.

Uploaded by

mehtab Khan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

Lecture 3

The document summarizes key concepts about truth tables and logical statements: (1) It provides examples of truth tables for logical statements involving connectives like negation, conjunction, and disjunction. (2) It defines logical concepts like tautology, contradiction, and discusses De Morgan's laws. (3) It discusses conditional statements and their relationships - a conditional statement is equivalent to its contrapositive but not its inverse or converse.

Uploaded by

mehtab Khan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

Discrete Structure

Lecture: 3

September 19, 2022

Lecture: 3 Discrete Structure 1/10


Truth Tables for:
(1) ∼ p ∧ q
(2) ∼ p ∧ (q∨ ∼ r)
(3) (p ∨ q) ∧ ∼ (p ∧ q)

Truth table for the statement form ∼ p ∧ q

p q ∼p ∼p∧ q
T T F F
T F F F
F T T T
F F T F

Lecture: 3 Discrete Structure 2/10


Truth table for the statement form ∼ p ∧ (q∨ ∼ r)

Lecture: 3 Discrete Structure 3/10


Truth table for the statement form (p ∨ q) ∧ ∼ (p ∧ q)

Double Negative Property


p ∼p ∼(∼ p)
T F T
F T F

Lecture: 3 Discrete Structure 4/10


Example 1
“It is not true that I am not happy”
Let p = “I am happy”
then ∼ p = “I am not happy”
and ∼(∼ p) = “It is not true that I am not happy”
Since ∼(∼p) ≡ p
Hence the given statement is equivalent to:
“I am happy”

Example 2
Show that ∼(p∧q) and ∼p ∧ ∼q are not logically equivalent

Lecture: 3 Discrete Structure 5/10


Definition 3 (DE MORGAN’S LAWS)
(1) The negation of an and statement is logically equivalent to
the or statement in which each component is negated.
Symbolically ∼(p ∧ q) ≡ ∼p ∨ ∼q.
(2) The negation of an or statement is logically equivalent to the
and statement in which each component is negated.
Symbolically: ∼(p ∨ q) ≡ ∼p ∧ ∼q.
Truth table for ∼(p ∨ q) ≡ ∼p ∧ ∼q

Lecture: 3 Discrete Structure 6/10


Example 4
Give negations for each of the following statements:
(1) The fan is slow or it is very hot.
Negation: The fan is not slow and it is not very hot.
(2) Akram is unfit and Saleem is injured
Negation: Akram is not unfit or Saleem is not injured

Example 5 (Inequalities and De Morgan’s Law)


Use DeMorgan’s Laws to write the negation of
-1 < x ≤ 4
for some particular real number x.
-1 < x ≤ 4 means x >-1 and x ≤ 4
By DeMorgan’s Law, the negation is:
x >-1 and x ≤ 4 is equivalent to
x ≤ -1 or x >4

Lecture: 3 Discrete Structure 7/10


Definition 6 (TAUTOLOGY)
A tautology is a statement form that is always true regardless of
the truth values of the statement variables. A tautology is
represented by the symbol “t”

Example 7
The statement form p ∨ ∼ p is tautology:

p ∼p p∨ (∼ p)
T F T
F T T

p∨ (∼ p)=t

Lecture: 3 Discrete Structure 8/10


Definition 8 (Contradiction)
A Contradiction is a statement form that is always False regardless
of the truth values of the statement variables. A Contradiction is
represented by the symbol “c”

Example 9
The statement form p ∧ ∼ p is Contradiction:

p ∼p p∧ (∼ p)
T F F
F T F

p∧ (∼ p)=c

Lecture: 3 Discrete Structure 9/10


Exercises

Q.1: Use De Morgan’s laws to find the negation of each of the


following statements.
(a) Jan is rich and happy.
(b) Carlos will bicycle or run tomorrow
Q.2: Show that each of these conditional statements is a tautology
by using truth tables.

Lecture: 3 Discrete Structure 10/10


CONDITIONAL STATEMENTS OR IMPLICATIONS

• If p and q are statements variables, the conditional of q by p is


“If p then q” or “p implies q” and is denoted p→ q.
• It is false when p is true and q is false; otherwise it is true. The
arrow ”→ ” is the conditional operator,
and in p →q
• the statement p is called the hypothesis (or antecedent) and q is
called the conclusion (or consequent).

Lecture: 3 Discrete Structure 11/10


IMPLICATION LAW

p→q ≡ ∼p∨q

Lecture: 3 Discrete Structure 12/10


Negation of a conditional statement

Since p→q ≡ ∼p∨q , therefore

Statement Reason
∼(p→q)≡ ∼(∼p∨ q)
≡ ∼(∼ p) ∧ ∼q by De Morgan’s law
≡p ∧∼q Double Negative Law

Thus the negation of “if p then q” is logically equivalent to “p and


not q”.

Lecture: 3 Discrete Structure 13/10


The negation of an if-then statement does not start with the word
if.
Example 10
Write negations of each of the following statements:
(1) If Ali lives in Pakistan then he lives in Lahore.
(2) If my car is in the repair shop, then I cannot get to class.
(3) If x is prime then x is odd or x is 2.
(4) If n is divisible by 6, then n is divisible by 2 and n is divisible
by 3.
SOLUTIONS:
(1) Ali lives in Pakistan and he does not live in Lahore.
(2) My car is in the repair shop and I can get to class.
(3) x is prime but x is not odd and x is not 2.
(4) n is divisible by 6 but n is not divisible by 2 or by 3

Lecture: 3 Discrete Structure 14/10


Inverse of a conditional statement

The inverse of the conditional statement p → q is ∼p → ∼q.


Example 11 (Writing Inverse)
(1) If today is Friday, then 2 + 3 = 5.
If today is not Friday, then 2 + 3 6= 5.
(2) If it snows today, I will ski tomorrow.
If it does not snow today I will not ski tomorrow.
(3) If P is a square, then P is a rectangle.
If P is not a square then P is not a rectangle.
(4) If my car is in the repair shop, then I cannot get to class.
If my car is not in the repair shop, then I shall get to the class.

Lecture: 3 Discrete Structure 15/10


A conditional and its inverse are not equivalent as could be seen
from the truth table.

Lecture: 3 Discrete Structure 16/10


Converse of a conditional statement

The converse of the conditional statement p → q is q →p.


WRITING CONVERSE
(1) If today is Friday, then 2 + 3 = 5.
If 2 + 3 = 5, then today is Friday.
(2) If it snows today, I will ski tomorrow.
I will ski tomorrow only if it snows today.
(3) If P is a square, then P is a rectangle.
If P is a rectangle then P is a square.
(4) If my car is in the repair shop, then I cannot get to class.
If I cannot get to the class, then my car is in the repair shop.

Lecture: 3 Discrete Structure 17/10


A conditional and its converse are not equivalent.
That is, → is not a commutative operator.

Lecture: 3 Discrete Structure 18/10


Contrapositive of a conditional Statement
The contrapositive of the conditional statement p → q is
∼q → ∼ p.

Example 12
(1) If today is Friday, then 2 + 3 = 5.
If 2 + 3 =6 5, then today is not Friday.
(2) If it snows today, I will ski tomorrow.
I will not ski tomorrow only if it does not snow today.
(3) If P is a square, then P is a rectangle.
If P is not a rectangle then P is not a square.
(4) If my car is in the repair shop, then I cannot get to class.
If I get to the class, then my car is not in the repair shop.

Lecture: 3 Discrete Structure 19/10


A conditional and its contrapositive are equivalent.
Symbolically, p → q ≡ ∼q → ∼ p.
Example 13
Use truth table to show p→q ≡ ∼q → ∼p.

The last two columns imply that the expressions are equivalent.
Lecture: 3 Discrete Structure 20/10

You might also like