0% found this document useful (0 votes)
2 views24 pages

Module-3 Propositional Logic

The document outlines the study material for the Discrete Mathematics course (PCC-CSM405) for B. Tech CSE students in their 4th semester at Brainware University. It covers topics in propositional logic, including definitions, connectives, tautologies, contradictions, contingencies, and propositional equivalences, along with examples and truth tables. The document serves as a comprehensive guide for understanding the fundamentals of propositional logic and its applications.

Uploaded by

vamitew605
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)
2 views24 pages

Module-3 Propositional Logic

The document outlines the study material for the Discrete Mathematics course (PCC-CSM405) for B. Tech CSE students in their 4th semester at Brainware University. It covers topics in propositional logic, including definitions, connectives, tautologies, contradictions, contingencies, and propositional equivalences, along with examples and truth tables. The document serves as a comprehensive guide for understanding the fundamentals of propositional logic and its applications.

Uploaded by

vamitew605
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/ 24

Programme Name and Semester: B.

Tech CSE (AIML_DS_General), 4th semester


Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Study Material
(Discrete Mathema cs (PCC-CSM405)

_____________________________________________________________________________________________

Table of Contents

Module III:
Propositional Logic

Sl no. Topic Page no.


1. Introduction 2
2. Proposition 2
3. Connec ves 2
4. Toutology 4
5. Contradic ons 5
6. Propositional Equivalences 6
7. Normal Forms 8
8. Practice question 20
9. References 24

Department of Mathema cs
Brainware University, Kolkata 1
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Module 3 Propositional Logic

P ropositional logic, also known as sentential logic or statement logic, is a branch of classical logic that deals
with the logical relationships between propositions (statements) that are either true or false. In propositional
logic, the basic building blocks are simple propositions, and complex propositions are formed by combining
these using logical connectives.

Proposi onal Logic is concerned with statements to which the truth values, “true” and “false”, can be assigned. The
purpose is to analyses these statements either individually or in a composite manner.

Defini on: A proposi on is a collec on of declara ve statements that has either a truth value "true” or a truth value
"false". A proposi onal consists of proposi onal variables and connec ves. We denote the proposi onal variables
by capital le ers (A, B, etc). The connec ves connect the proposi onal variables.

Truth value of a Proposi on:

(1) Let p: 4+5=10. p is proposi on which is false So p takes the Truth value F or 0.

(2) q: Every ac on has an equal and opposite reac on. This is a proposi on which is true. So, the truth value of q is
T or 1.

Note: The le ers p, q, … etc. are also known as proposi onal variables because these may take the two different
values T or F.

Connectives: In propositional logic generally, we use five connectives which are


● OR (∨), AND (∧),
● Nega on/ NOT (¬/∽)
● Implication / if-then (→)
● If and only if (⟷)
1. OR (∨):The OR operation of two propositions A and B (written as A∨B) is true if at least any
of the proposi onal variable A or B is true.

The truth table is as follows –

A B A∨B

T T T

T F T

F T T

F F F

Department of Mathema cs
Brainware University, Kolkata 2
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

2. AND (∧): The AND operation of two propositions A and B (written as A∧B) is true if both the
proposi onal variable A and B is true.

The truth table is as follows –

A B A∧B

T T T

T F F

F T F

F F F

3. Nega on (¬/∼) − The negation of a proposition A (written as ¬A) is false when A is


true and is true when A is false.

The truth table is as follows −

A ∼A

T F

F T

4. Implica on / if-then (→): An implication A→B is the proposition “if A, then B”. It is false
if A is true and B is false. The rest cases are true.

The truth table is as follows −

A B A→ B

T T T

T F F

Department of Mathema cs
Brainware University, Kolkata 3
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F T T

F F T

5. If and only if (↔): A↔B is bi-condi onal logical connec ve which is true when p and q are same, i.e. both are
false or both are true.

The truth table is as follows −

A B A↔B

T T T

T F F

F T F

F F T

Tautologies
A Tautology is a formula which is always true for every value of its proposi onal variables.

Example − Prove [(A→B) ∧A] →B is a tautology

The truth table is as follows −

A B A→ B (A → B) ∧ [(A → B) ∧ A]
A →B

T T T T T

T F F F T

F T T F T

F F T F T

As we can see every value of [(A→B) ∧A] →B is "True", it is a tautology.

Contradictions
A Contradic on is a formula which is always false for every value of its proposi onal variables.
Department of Mathema cs
Brainware University, Kolkata 4
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Example − Prove (A∨B) ∧[(∼A) ∧(∼B)] is a contradic on

The truth table is as follows −

A B A ∨ ∽A ∼B (∼ A) ∧ ( ∼ (A ∨ B) ∧ [( ∼ A) ∧
B B) (∼ B)]

T T T F F F F

T F T F T F F

F T T T F F F

F F F T T T F

As we can see every value of (A∨B) ∧[(∼A) ∧(∼B)] is “False”, it is a contradic on.

Contingency
A Con ngency is a formula which has both some true and some false values for every value of its proposi onal
variables.

Example − Prove (A∨B) ∧(∼A) a con ngency

The truth table is as follows −

A B A∨B ∼A (A ∨ B) ∧ (∼ A)

T T T F F

T F T F F

F T T T T

F F F T F

Department of Mathema cs
Brainware University, Kolkata 5
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

As we can see every value of (A∨B)∧(∽A) has both “True” and “False”, it is a contingency.

Propositional Equivalences

Two statements X and Y are logically equivalent if any of the following two
conditions hold −
●The truth tables of each statement have the same truth values.
●The bi-condi onal statement X↔Y is a tautology.
Example − Prove ∼(A∨B)and[(∽A)∧(∼B)] are equivalent

Testing by 1st method (Matching truth table)


A B A∨B ∼(A ∨ B) ∼A ∼B [(∼ A) ∧ (∼ B)]

T T T F F F F

T F T F F T F

F T T F T F F

F F F T T T T

Here, we can see the truth values of (A∨B)and[( A)∧( B)] are same, hence the statements are
equivalent.
Testing by 2nd method (Bi-conditionality)
A B ∼ (A ∨ B ) [(∼A) ∧ (∼ B)] [∼ (A ∨ B)] ↔ [(∼ A ) ∧ (∼ B)]

T T F F T

T F F F T

F T F F T

F F T T T

As [∼ (A∨B)]↔[( ∼A)∧( ∼B)] is a tautology, the statements are equivalent.


Department of Mathema cs
Brainware University, Kolkata 6
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Inverse, Converse, and Contra-positive


Implication / if-then (→) is also called a conditional statement. It has two parts −
● Hypothesis, p
● Conclusion, q
As mentioned earlier, it is denoted as p→q

Example of Condi onal Statement − “If you do your homework, you will not be punished.”
Here, "you do your homework" is the hypothesis, p, and "you will not be punished" is
the conclusion, q.

Inverse − An inverse of the conditional statement is the negation of both the


hypothesis and the conclusion. If the statement is “If p, then q”, the inverse will be
“If not p, then not q”. Thus the inverse of p→q is ∽p→∽q

Example − The inverse of “If you do your homework, you will not be punished” is “If
you do not do your homework, you will be punished.”

Converse − The converse of the conditional statement is computed by interchanging


the hypothesis and the conclusion. If the statement is “If p, then q”, the converse
will be “If q, then p”. The converse of p→q is q→p.

Example − The converse of "If you do your homework, you will not be punished" is "If
you will not be punished, you do your homework”.

Contra-posi ve − The contra-positive of the conditional is computed by interchanging


the hypothesis and the conclusion of the inverse statement. If the statement is “If
p, then q”, the contra-positive will be “If not q, then not p”. The contra-positive
of p→q is ∽q→∽p

Example − The Contra-positive of " If you do your homework, you will not be
punished” is "If you are punished, you did not do your homework”.

● When we were looking at proposi onal logic opera ons, we defined several things using and/or/not.
o For example:

p⊕q ≡(p∨q)∧¬(p∧q)

p→q ,≡¬p∨q

p↔q≡(p→q)∧(q→p)≡(¬p∨q)∧(¬q∨p).

● We did that to help us understand the new symbols in terms of things we already knew.
o But it is also nice to have a standard defini on of the operators we can use.
o When proving equivalences, it let us apply equivalences we already had that used and/or/not.

● We also had some equivalence rules that helped us rearrange proposi ons so we could get at the parts we
needed:

Department of Mathema cs
Brainware University, Kolkata 7
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Name Equivalences

Double Nega on ¬(¬p)≡p

p∨q≡q∨p
Commuta ve
p∧q≡q∧p

(p∨q)∨r≡p∨(q∨r)
Associa ve
(p∧q)∧r≡p∧(q∧r)

p∨(q∧r)≡(p∨q)∧(p∨r)
Distribu ve
p∧(q∨r)≡(p∧q)∨(p∧r)

¬(p∧q)≡¬p∨¬q
De Morgan's Law
¬(p∨q)≡¬p∧¬q

Normal Forms

● Remember that we also called “or” “disjunc on” and “and” “conjunc on”.
● A clause that contains only ∨ is called a disjunc ve clause and only ∧ is called a conjunc ve clause.
o Nega on is allowed, but only directly on variables.
o p∨¬q∨r: a disjunc ve clause
o ¬p∧q∧¬r: a conjunc ve clause
o ¬p∧¬q∨r: neither
● If we put a bunch of disjunc ve clauses together with ∧, it is called conjunc ve normal form.
o For example: (p∨r)∧(¬q∨¬r)∧q is in conjunc ve normal form.
● Similarly, pu ng conjunc ve clauses together with ∨, it is called disjunc ve normal form.
o For example: (p∧¬q∧r)∨(¬q∧¬r) is in disjunc ve normal form.

● More examples:
o (p∧q∧¬r∧s)∨(¬q∧s)∨(p∧s) is in disjunc ve normal form.
o (p∨q∨¬r∨s)∧(¬q∨s)∧¬s is in conjunc ve normal form.
o (p∨r)∧(q∧(p∨¬q)) is not in a normal form.
o ¬p∨q∨r and ¬p∧q∧r are in both normal forms.

● It turns out we can turn any proposi on into either normal form.
o We can use the definitions to get rid of →, ↔, and ⊕.
o Use DeMorgan's laws to move any ¬ in past parens, so they sit on the variables.
o Use double nega on to get rid of any ¬¬ that showed up.
o Use the distribu ve rules to move things in/out of parens as we need to.

● For example, conver ng to conjunc ve normal form:

¬((¬p→¬q)∧¬r)≡¬((¬¬p∨¬q)∧¬r) [defini on]

≡¬((p∨¬q)∧¬r) [double nega on]


Department of Mathema cs
Brainware University, Kolkata 8
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

≡¬(p∨¬q)∨¬¬r [DeMorgan's]

≡¬(p∨¬q)∨r [double nega on]

≡(¬p∧¬¬q)∨r [DeMorgan's]

≡(¬p∧q)∨r [double nega on]

≡(¬p∨r)∧(q∨r) [distribu ve]

o It was actually in disjunc ve normal form in the second-last step.

● Why would we want to convert to a normal form?


o May be easier to prove equivalence: to show A≡B, convert both to normal form, and then re-write
one proof backwards.
o Maybe we simplify a lot: if we end up with (p∨¬p∨⋯) terms, we know they are true.
o Proving theorems about all proposi ons: only have to handle boolean expressions in a normal form
and that covers every proposi on.
o Shows that we can use circuitry to calculate any boolean expression with two layers of logic gates.

● Another example:

(p→q)→(¬r∧q)≡¬(p→q)∨(¬r∧q) [defini on]

≡¬(¬p∨q)∨(¬r∧q) [defini on]

≡(¬¬p∧¬q)∨(¬r∧q) [DeMorgan's]

≡(p∧¬q)∨(¬r∧q) [double nega on]

o At this point, it's in DNF. Con nuing…

(p→q)→(¬r∧q)≡(p∧¬q)∨(¬r∧q) [as above]

≡(p∨(¬r∧q))∧(¬q∨(¬r∧q)) [distribu ve]

≡(p∨(¬r∧q))∧(¬q∨¬r)∧(¬q∨q) [distribu ve]

≡(p∨(¬r∧q))∧(¬q∨¬r)∧T [nega on]

≡(p∨(¬r∧q))∧(¬q∨¬r) [iden ty]

≡(p∨¬r)∧(p∨q)∧(¬q∨¬r [distribu ve]


Department of Mathema cs
Brainware University, Kolkata 9
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Exercise: Find the truth table for 𝑃 ↔ 𝑄


Answer:

P Q P↔Q

T T T

T F F

F T F

F F T

Exercise: Construct a truth table for the formula ~𝑃 ∧ (𝑃 → 𝑄).


Answer:

P Q ~P P→ ~P ∧ (P →
Q Q)

T T F T F

T F F F F

F T T T T

F F T T T

Exercise: Construct a truth table for (P → Q) ∧ (Q → R).

Answer:

P Q R P→ Q→ (P → Q) ∧ (Q →
Q R R)

T T T T T T

T T F T F F

T F T F T F

T F F F T F

Department of Mathema cs
Brainware University, Kolkata 10
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F T T T T T

F T F T F F

F F T T T T

F F F T T T

Exercise: Show that (P → Q) ∨ (Q → P ) is a tautology.

Answer:

P Q P→Q Q→ (P → Q) ∨ (Q → P
Exercise: Verify the distribu ve Law
P ) 𝑝⋀(𝑞⋁𝑟) ≡ (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)
T T T T T Solu on: We are using truth table to verify
the law
T F F T T
The truth table of 𝑝 ∧ (𝑞 ∨ 𝑟)
F T T F T

F F T T T

p q r q∨ 𝑟 𝑝 ∧ (𝑞 ∨ 𝑟)

T T T T T

T F T T T

F T T T F

F F T T F

F T F T F

F F F F F

T T F T T

T F F F F

The truth table of (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)

p q r q∧ 𝑞 𝑝∧𝑟 (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)

T T T T T T

T F T F T T

F T T F F F

F F T F F F

Department of Mathema cs
Brainware University, Kolkata 11
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F T F F F F

F F F F F F

T T F T F T

T F F F F F

From the above we see the two proposi ons 𝑝 ∧ (𝑞 ∨ 𝑟) and (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟) have same truth table.

Exercise: Verify the D’Morgan’s law∼ (𝑝 ∨ 𝑞) ≡ (∼ 𝑝) ∧ (∼ 𝑞)

Solu on: We are using truth table to verify the law

The truth table of ∼ (𝑝 ∨ 𝑞)

p q 𝑝∨𝑞 ∼ (𝑝 ∨ 𝑞)

T T T F

F F F T

T F T F

F T T F

The truth table of (∼ 𝑝) ∧ (∼ 𝑞)

p q ∼𝑝 ∼𝑞 (∼ 𝑝) ∧ (
∼ 𝑞)

T T F F F

F F T T T

T F F T F

F T T F F

The above two table are iden cal.

Theorem: 𝑝 → 𝑞 ≡∼ 𝑝 ∨ 𝑞

Proof: Truth table for 𝑝 → 𝑞

p q 𝑝→𝑞

T T T

T F F

F T T

Department of Mathema cs
Brainware University, Kolkata 12
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F F T

Truth table for ∼ 𝑝 ∨ 𝑞

p q ∼𝑝 ∼𝑝∨𝑞

T T F T

T F F F

F T T T

F F T T

We see the truth tables of 𝑝 → 𝑞 and ∼ 𝑝 ∨ 𝑞 are same. Hence the theorem is proved.

Theorem: 𝑝 ↔ 𝑞 ≡ (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

Proof:

Truth table for 𝑝 ↔ 𝑞

p q 𝑝↔𝑞

T T T

T F F

F T F

F F T

Truth table for (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

p q 𝑝→𝑞 𝑞→𝑝 (𝑝 → 𝑞)⋀(𝑞


→ 𝑝)

T T T T T

T F F T F

F T T F F

Department of Mathema cs
Brainware University, Kolkata 13
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F F T T T

We see both the two truth tables are iden cal. So 𝑝 ↔ 𝑞 ≡ (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

Example: Find the truth tables of the followings: (i) ∼ (𝑝 ∧∼ 𝑞) (ii) (𝑝 → 𝑞) ↔ (∼ 𝑞 →∼ 𝑝) (iii) [(p∧ 𝑞) ∨ (∼
𝑟)] ↔ 𝑝
Solu on:

(i) Truth table for ∼ (𝑝 ∧∼ 𝑞)

p q ∼𝑞 𝑝 ∧∼ 𝑞 ∼ (𝑝 ∧∼ 𝑞)

T T F F T

T F T T F

F T F F T

F F T F T

(ii) Truth table for (𝑝 → 𝑞) ↔ (∼ 𝑞 →∼ 𝑝)

p q ∼𝑝 ∼𝑞 𝑝→𝑞 ∼𝑞→ (𝑝 → 𝑞) ↔ (∼ 𝑞 →∼ 𝑝)
∼𝑝

T T F F T T T

T F F T F F T

F T T F T T T

F F T T T T T

(iii) Truth table for [(p∧ 𝑞) ∨ (∼ 𝑟)] ↔ 𝑝

p q r p⋀𝑞 ∼𝑟 (p⋀𝑞) ∨ ∼ [(p∧ 𝑞) ∨ (∼ 𝑟)] ↔


𝑟 𝑝

T T T T F T T

T T F T T T T

T F T F F F F

F T T F F F T

T F F F T T T

Department of Mathema cs
Brainware University, Kolkata 14
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F T F F T T F

F F T F F F T

F F F F T T F

Exercise: Verify the distribu ve Law 𝑝⋀(𝑞⋁𝑟) ≡ (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)

Answer:

We are using truth table to verify the law

The truth table of 𝑝 ∧ (𝑞 ∨ 𝑟)

p q r q∨ 𝑟 𝑝 ∧ (𝑞 ∨ 𝑟)

T T T T T

T F T T T

F T T T F

F F T T F

F T F T F

F F F F F

T T F T T

T F F F F

The truth table of (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)

p q r q∧ 𝑞 𝑝∧𝑟 (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟)

T T T T T T

T F T F T T

F T T F F F

F F T F F F

F T F F F F

F F F F F F

T T F T F T

T F F F F F

From the above we see the two proposi ons 𝑝 ∧ (𝑞 ∨ 𝑟) and (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟) have same truth table.

Department of Mathema cs
Brainware University, Kolkata 15
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Exercise: Verify the D’Morgan’s law∼ (𝑝 ∨ 𝑞) ≡ (∼ 𝑝) ∧ (∼ 𝑞).

Answer: We are using truth table to verify the law

The truth table of ∼ (𝑝 ∨ 𝑞)

p q 𝑝∨𝑞 ∼ (𝑝 ∨ 𝑞)

T T T F

F F F T

T F T F

F T T F

The truth table of (∼ 𝑝) ∧ (∼ 𝑞)

p q ∼𝑝 ∼𝑞 (∼ 𝑝) ∧ (
∼ 𝑞)

T T F F F

F F T T T

T F F T F

F T T F F

The above two table are iden cal.

Theorem1:𝑝 → 𝑞 ≡∼ 𝑝 ∨ 𝑞

Proof: Truth table for 𝑝 → 𝑞

p q 𝑝→𝑞

T T T

T F F

F T T

F F T

Truth table for ∼ 𝑝 ∨ 𝑞

p q ∼𝑝 ∼𝑝∨𝑞

T T F T

T F F F

F T T T

Department of Mathema cs
Brainware University, Kolkata 16
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

F F T T

We see the truth tables of 𝑝 → 𝑞 and ∼ 𝑝 ∨ 𝑞 are same. Hence the theorem is proved.

Theorem 2: 𝑝 ↔ 𝑞 ≡ (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

Proof: Truth table for 𝑝 ↔ 𝑞

p q 𝑝↔𝑞

T T T

T F F

F T F

F F T

Truth table for (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

p q 𝑝→𝑞 𝑞→𝑝 (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

T T T T T

T F F T F

F T T F F

F F T T T

We see both the two truth tables are iden cal. So 𝑝 ↔ 𝑞 ≡ (𝑝 → 𝑞)⋀(𝑞 → 𝑝)

Example: Find the truth tables of the followings: (i) ∼ (𝑝 ∧∼ 𝑞) (ii) (𝑝 → 𝑞) ↔ (∼ 𝑞 →∼ 𝑝) (iii) [(p∧ 𝑞) ∨ (∼
𝑟)] ↔ 𝑝
Solu on:

(i)

p q ∼𝑞 𝑝 ∧∼ 𝑞 ∼ (𝑝 ∧∼ 𝑞)

T T F F T

T F T T F

F T F F T

F F T F T

Department of Mathema cs
Brainware University, Kolkata 17
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

(ii)

p q ∼𝑝 ∼𝑞 𝑝→𝑞 ∼𝑞→ (𝑝 → 𝑞) ↔ (∼ 𝑞 →∼ 𝑝)
∼𝑝

T T F F T T T

T F F T F F T

F T T F T T T

F F T T T T T

(iii) Truth table for [(p∧ 𝑞) ∨ (∼ 𝑟)] ↔ 𝑝

p q r p⋀𝑞 ∼𝑟 (p⋀𝑞) ∨ ∼ [(p∧ 𝑞) ∨ (∼ 𝑟)] ↔


𝑟 𝑝

T T T T F T T

T T F T T T T

T F T F F F F

F T T F F F T

T F F F T T T

F T F F T T F

F F T F F F T

F F F F T T F

Department of Mathema cs
Brainware University, Kolkata 18
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

Questions for Practice.


A. MCQ Answer Type Questions:

1.
Express ¬(𝑝 ∨ 𝑞) ∨ (𝑝 ∧ ¬𝑞) in simplest form

a. p b. p

c.
q d.

2. Identify the negation of  xy , p ( x, y )

a.
x  y ,  p ( x , y ) b. x y , p ( x, y )

c. x y , p ( x, y ) d. none of these

3. Select the correct option. The statement [~p v (p → q)] → ~p is


a. Tautology b. Contingency
c. Contradiction d. None of these
4. Identify the contrapositive of "p  q " .

a. p q b. q  p
q  p q  p
c. d.

5. Identify the truth value of the statement x2 = x holds for all real values of x.
a. T b. F
c. Neither T nor F d. none of these

6. If p:”Ashok is rich” and q:”Kamal is poor” then express the symbolic form of the statement
“Either Ashok or Kamal is rich”.

a.
pq b.
p  q

c. p  q d. ( p  q )
7. For the statement p and q, ( p  q ) can be converted to

Department of Mathema cs
Brainware University, Kolkata 19
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

a.
p  q b. p  q

c. ( p  q ) d. None of these

8. p  q   p  q  r
If , then illustrate the value of r

a. pq b. p

c.
q p d.
q
9. Select the correct option. A statement T is called tautology if
a. T is true for all possible values of its b. T is false for all values of its
variables variables
c. T is true as well as false for few d. None of these
possible values of its variables
10. Illustrate the negation of “All students live in dormitories”
a. All students do not live in b. No student live in dormitories.
dormitories.
c. One student does not live in d. Some students do not live in
dormitories. dormitories.
11. Let P: We should be honest., Q: We should be dedicated., R: We should be overconfident.
Then ‘We should be honest or dedicated but not overconfident.’ is best expressed by
a. ~P V ~Q V R b. P ∧ ~Q ∧ R
c. P V Q ∧ R d. P V Q ∧ ~R
12. Let P: If Sahil bowls, Saurabh hits a century. Q: If Raju bowls , Sahil gets out on first ball.
Now if P is true and Q is false then identify the correct statement.
a. Raju bowled and Sahil got out on first b. Raju did not bowled
ball
c. Sahil bowled and Saurabh hits a d. Sahil bowled and Saurabh got out
century
13. 2
“ ∀𝑥 ∈ ℝ such that x  4 ” can be expressed as
2 b. Some real numbers have square 4
a. If x is real number then x  4
c. Square of no real number is 4 d. None of these
14. Estimate the Truth value of the proposition “All the angles of an equilateral triangle are
equal”
a. True b. False

Department of Mathema cs
Brainware University, Kolkata 20
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

c. Not a proposition d. None of these


15. Let P(x) states “x is wealthy” and Q(x) states “x is married”. Domain is “all men”, then
xP  x 
can be illustrated as
a. All men are wealthy b. At least one man is wealthy
c. No man is wealthy d. None of these
16. p   p  q 
Select the correct option.

a. p b. q

c. pq d. None of these


17. Inverse of “ p  q ” can be expressed as

a. pq b. p  q

c.
p  q d.
q  p
18. Converse of “ p  q ”can be expressed as

a. p  q b. q  p

c.
q  p d.
q  p
19. Select the correct option. p → q is logically equivalent to
a. ¬p ∨ ¬q b. p ∨ ¬q
c. ¬p ∨ q d. ¬p ∧ q

U  0,1, 2,3, 4,5,6 V  10,1, 2,3, 4,5,6 W  1, 2,3, 4,5,6


and   be
20. P x
Let , and
" x  10" . Identify the set such that xP  x  has truth values F.

a. U b. V

c. W d. None of these

B. Short Answer Type Questions:

1. Illustrate Tautology with an example.

Department of Mathema cs
Brainware University, Kolkata 21
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

2. Illustrate Contradiction with an example.

3. Show that the following compound proposition is a Tautology (using truth table)
 p  q    q  r    p  r .

4. Show that the following compound proposition is a Tautology (using truth table) (𝑝 → (𝑞 →
𝑝)).

5. Describe Logical equivalence with example.

6. If p: Today is Friday
q: It is raining
r: It is hot
Cite the following Symbol
(i) ∽ 𝑞 → (𝑟 ⋀ 𝑝) (ii) (𝑝⋀ ∽ 𝑞) →∽ 𝑟.

7. If p is true and q is false then cite the truth value of (𝑝 ∧ 𝑞) → (𝑝 ⋁ 𝑞).

8. Cite the truth table for the proposition: 𝑝 ↔ 𝑞.

9. Cite the truth table for the proposition: ∼ (𝑝 ∨ 𝑞).

10. Cite the truth table for the proposition: 𝑝 → 𝑞.

C. Long Answer Type Questions:

1. Use the truth tables method to deduce if (~𝑝 ∨ 𝑞) ∧ (𝑞 → (~𝑟 ∧ ~𝑝)) ∧ (𝑝 ∨ 𝑟) is


always true or not.

Department of Mathema cs
Brainware University, Kolkata 22
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

2. Calculate the truth table for (𝑝⋀𝑞) ∨ ~𝑟 .

3. Identify the truth table for (𝑝 ∨ 𝑞)⋀~𝑟.

4. Use truth tables to illustrate the following commutative laws.


a) p q q p
b) p q q p.

5. Use truth tables to illustrate the associative laws


a) (p q) r = p (q r)
b) (p q) r = p (q r).

6. Deduce that ((p q) (q r)) (pr) is a tautology.

7. Deduce that ((p q) (p r)) (q r) is a tautology.

8. Deduce that (p q) (r s) and (p r) (q s) are not logically equivalent.

9. Let’s consider a propositional language where


A = “Angelo comes to the party”,
B = “Bruno comes to the party”,
C = “Carlo comes to the party”,
D = “Davide comes to the party”.
Transform the following sentences in propositional language:
1. “If Davide comes to the party then Bruno and Carlo come too”
2. “Carlo comes to the party only if Angelo and Bruno do not come”
3. “Davide comes to the party if and only if Carlo comes and
Angelo doesn’t come”
4. “If Davide comes to the party, then, if Carlo doesn’t come then
Angelo comes”
5. “Carlo comes to the party provided that Davide doesn’t come,
but, if Davide comes, then Bruno doesn’t come”.

Department of Mathema cs
Brainware University, Kolkata 23
Programme Name and Semester: B. Tech CSE (AIML_DS_General), 4th semester
Course Name (Course Code): Discrete Mathema cs (PCC-CSM405_ PCC-CSD405_ PCC-CSG405)
Academic Session: 2024-25

10. Deduce that p → q and ∼q → ∼p are logically equivalent by using truth table as well as
without using the truth table.

References:
1. “Discrete Mathematics and Its Applications”, Kenneth H. Rosen, McGraw-Hill.
2. “Discrete Mathematics with Applications”, Susanna S Epp, Wadsworth Publishing Co. Inc, 4th edition
3. “Elements of Discrete Mathematics: a computer oriented approach”, C L Liu and Mohapatra, McGraw
Hill, 3rd edition.
4. “Discrete Mathematical Structures and its Application to Computer Science”, J P Trembley, R
Manohar, TMG Edition, Tata McGraw-Hill.
5. “Discrete Mathematics”, Norman L Biggs, Oxford University Press, 2nd Edition.
6. “Discrete Mathematics”, Schaum’s Outlines Series, Semyour Lipschutz and Marc Lipson

Department of Mathema cs
Brainware University, Kolkata 24

You might also like