Set Theory Notes 1st Semester
Set Theory Notes 1st Semester
Set Theory Notes 1st Semester
Propositions:-
Truth table:-
Statement Negation
Set Theory BS 1st Semester
¬p: Today is not Friday. Or
p: Today is Friday.
¬p: it is not the case that today is Friday.
Note:
The Truth Table for
the Negation of a
o All Some + Not (change in negation case) Proposition.
o All + Not / No / no one Some or Some one
p ¬p
T F
F T
Conjunction (AND)
Disjunction (OR)
Exclusive or (XOR)
Implication (if- then)
Biconditional (if and only if)
Conjunction:-
Set Theory BS 1st Semester
Let p and q be propositions. The conjunction of p and q is the compound
proposition. It is denoted by p ∧ q and read as “p and q.” The conjunction p ∧ q is
true when both p and q aretrue and is false otherwise.
Conditional Statement p → q.
p→ q: “if i am elected, then I will lower the
(p → q) ∧ (q → p).
Example: Let p be the statement “You can take the flight,” and let q be the statement
“You buy a ticket.” Then p ↔ q is the statement
“You can take the flight if and only if you buy a ticket.”
This statement is true if p and q are either both true or both false.
Negation of The Conditional Statement
Change of conditional statement into negation (p→ q).
(if p, then q) change in negation (p and ¬ q)
Write the negation of the following statement
Example:-
What are the contrapositive, the converse, and the inverse of the conditional statement
“The home team wins whenever it is raining?”
Solution: Because “q whenever p” is one of the ways to express the
conditional statement p → q, the original statement can be rewritten as
“If it is raining, then the home team wins.”
The contrapositive is “If the home team does not win, then it is not raining.”
The converse is “If the home team wins, then it is raining.”
The inverse is “If it is not raining, then the home team does not win.”
Exercise 1.1
1. Which of these sentences are propositions? What are the truth values of those that are
propositions?
a) Boston is the capital of Massachusetts.
Yes, T
b) Miami is the capital of Florida.
Yes, F
c) 2 + 3 = 5.
Yes, T
d) 5 + 7 = 10.
Yes, F
e) x + 2 = 11.
No.
f ) Answer this question.
No.
3. What is the negation of each of these propositions?
a) Today is Thursday.
Today is not Thursday.
b) There is no pollution in New Jersey.
There pollution in New Jersey.
c) 2 + 1 = 3.
2 + 1 ≠ 3.
d) The summer in Maine is hot and sunny.
The summer in Maine is not hot or it is not sunny.
4. Let p and q be the propositions
p : I bought a lottery ticket this week.
q : I won the million dollar jackpot.
Express each of these propositions as an English sentence.
a) ¬p
I did not buy a lottery ticket this week.
b) p ∨ q
I bought a lottery ticket this week or I won the million dollar jackpot.
c) p → q
I bought a lottery ticket this week then I won the million dollar jackpot.
d) p ∧ q
I bought a lottery ticket this week and I won the million dollar jackpot.
e) p ↔ q
I bought a lottery ticket this week if only if I won the million dollar jackpot.
f ) ¬p → ¬q
I did not buy a lottery ticket this week then I did not win the million dollar jackpot.
g) ¬p ∧ ¬q
I did not buy a lottery ticket this week and I did not win the million dollar jackpot.
h) ¬p ∨ (p ∧ q)
I did not buy a lottery ticket this week or I bought a lottery ticket this week and I won
the million dollar jackpot.
8. Let p and q be the propositions
p : It is below freezing.
q : It is snowing.
Write these propositions using p and q and logical connectives (including negations).
a) It is below freezing and snowing.
p∧q
b) It is below freezing but not snowing.
p ∧ ¬q
c) It is not below freezing and it is not snowing.
¬p ∧ ¬q
d) It is either snowing or below freezing (or both).
p∨q
e) If it is below freezing, it is also snowing.
p→q
f ) Either it is below freezing or it is snowing, but it is not snowing if it is below
freezing.
(p ∨ q) ∧ (p →¬q)
g) That it is below freezing is necessary and sufficient for it to be snowing.
)q↔p
21 State the converse, contrapositive, and inverse of each of these conditional
statements.
a) If it snows today, I will ski tomorrow.
Converse: “I will ski tomorrow only if it snows today.”
Contrapositive: “If I do not ski tomorrow, then it will not have snowed today.”
Inverse: “If it does not snow today, then I will not ski tomorrow.”
b) I come to class whenever there is going to be a quiz.
Converse: “If I come to class, then there will be a quiz.”
Contrapositive: “If I do not come to class, then there will not be a quiz.”
Inverse: “If there is not going to be a quiz, then I don’t come to class.”
c) A positive integer is a prime only if it has no divisors other than 1 and
itself.
Converse: “A positive integer is a prime if it has no divisors other than 1 and itself.”
Contrapositive: “If a positive integer has a divisor other than 1 and itself, then it is
not prime.”
Inverse: “If a positive integer is not prime, then it has a divisor other than 1 and
itself.”
31. Construct a truth table for each of these compound propositions.
a) p ∧ ¬p
p ¬p p ∧ ¬p
T F F
F T F
b) p ∨ ¬p
p ¬p p ∨ ¬p
T F T
F T T
c) (p ∨ ¬q) → q
p q ¬q p ∨ ¬q (p ∨ ¬q) → q
T T F T T
T F T T F
F T F F T
F F T T F
d) (p ∨ q) → (p ∧ q)
p q p∨q p∧q (p ∨ q) → (p ∧ q)
T T T T T
T F T F F
F T T F F
F F F F T
e) (p → q) ↔ (¬q → ¬p)
p q ¬p ¬q p→q ¬q → ¬p (p → q) ↔ (¬q → ¬p)
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
f ) (p → q) → (q → p)
p q p→q q→p (p → q) → (q → p)
T T T T T
T F F T T
F T T F F
F F T T T
Propositional Equivalences:-
Taotology:-
A compound proposition that is always true, no matter what the truth values of the
propositional variables that occur in it.
Contradiction:-
A compound proposition that is always false.
Contigency:-
A compound proposition that is neither a tautology nor a contradiction.
Logically Equivalence:-
Compound proposition that have same truth values in the all possible cases are
called Logically Equivalent.It is denoted by ≡ the symbole is not a logical connective.
EXAMPLE:- Show that ¬(p ∨ (¬p ∧ q)) and ¬p ∧ ¬q are logically equivalent.
¬(p ∨ (¬p ∧ q)) ≡ ¬p ∧ ¬(¬p ∧ q) by the second De Morgan law
≡ ¬p ∧ [¬(¬p) ∨ ¬q] by the first De Morgan law
≡ ¬p ∧ (p ∨ ¬q) by the double negation law
≡ (¬p ∧ p) ∨ (¬p ∧ ¬q) by the second distributive law
≡ F ∨ (¬p ∧ ¬q) by Second negation law
≡ (¬p ∧ ¬q) ∨ F by the commutative law for disjunction
≡ ¬p ∧ ¬q by the Second identity law
Exercise 1.3
1. Use truth tables to verify these equivalences.
a) p ∧ T ≡ p
b) p ∨ F ≡ p
c) p ∧ F ≡ F
d) p ∨ T ≡ T
e) p ∨ p ≡ p
f)p∧p≡p
p p∧T p∨F p∧F p∨T p∨p p∧p
T T T F T T T
F F F F T F F
b) p ∧ q ≡ q ∧ p.
P q p∧q q∧p
T T T T
T F F F
F T F F
F F F F
6. Use a truth table to verify the first De Morgan law ¬(p ∧ q) ≡ ¬p ∨ ¬q.
7. Show that each of these conditional statements is a tautology by using truth tables.
a) (p ∧ q) → p
p q p∧q (p ∧ q) → p
T T T T
T F F T
F T F T
F F F T
b) p → (p ∨ q)
p q p∨q p → (p ∨ q)
T T T T
T F T T
F T T T
F F F T
c) ¬p → (p → q)
p q ¬p (p → q ¬p → (p → q)
T T F T T
T F T F T
F T F T T
F F T T T
d) (p ∧ q) → (p → q)
p q p∧q p→q (p ∧ q) → (p → q)
T T T T T
T F F F T
F T F T T
F F F T T
e) ¬(p → q) → p
p q p→q ¬(p → q) ¬(p → q) → p
T T T F T
T F F T T
F T T F T
F F T F T
f ) ¬(p → q) → ¬q
p q p→q ¬(p → q) ¬q ¬(p → q) → ¬q
T T T F F T
T F F T T T
F T T F F T
F F T F T T
8. Show that each of these conditional statements is a tautology by using truth tables.
a) [¬p ∧ (p ∨ q)] → q
b) [(p → q) ∧ (q → r)] → (p → r)
c) [p ∧ (p → q)] → q
d) [(p ∨ q) ∧ (p → r) ∧ (q → r)] → r
9.. Show that each conditional statement in Exercise 7 is a tautology without using truth
tables.
10. Show that each conditional statement in Exercise 8 is a tautology without using truth
tables.
11. Use truth tables to verify the absorption laws.
a) p ∨ (p ∧ q) ≡ p
b) p ∧ (p ∨ q) ≡ p
12. Determine whether (¬p ∧ (p → q)) → ¬q is a tautology.
13. Determine whether (¬q ∧ (p → q)) → ¬p is a tautology.
14. Show that p ↔ q and (p ∧ q) ∨ (¬p ∧ ¬q) are logically equivalent.
16. Show that p → q and ¬q → ¬p are logically equivalent.
17. Show that ¬p ↔ q and p ↔ ¬q are logically equivalent.
19. Show that ¬(p ↔ q) and ¬p ↔ q are logically equivalent.
20. Show that(p → q) ∧ (p → r) and p → (q ∧ r) are logically equivalent.
Predicates :-
Consider,
x>3
x=y+3
x is even number.
The statement “x is greater than 3” has two parts. The first part, the variable x, is the
subject of the statement. The second part—the predicate, “is greater than 3”
Bindindg Rariables:-
When a quantifier is used on the variable x or assigned a value to this variable, we say that
this occurrence of the variable is bound.
Free Variable:-
An occurrence of a variable that is not bound by a quantifier or set equal to a particular
value is said to be free.
Scope:-
The part of a logical expression to which a quantifier is applied is called the scope of this
quantifier.
Example:- ∀x(P (x) ∧ Q(x)) ∨ ∃yR(y)
∀x ∃y
Negation of Quantifeirs:-
Example:- Every student in your class has taken a course in calculus.
∀xP (x)
Every Students x in the class, x has taken a course in calculus.
Negation:-
It is not the case that every student in your class has taken a course in calculus ≡ (This is
equivalent to) There is a student in your class who has not taken a course in calculus.
∃x ¬P (x).
Existential:-
There is a student in this class who has taken a course in calculus.
∃x p(x).
Negation of Existential:-
It is not the case that there is a student in this class who has taken a course in calculus.
∀x ¬p(x) ≡ (This is equivalent to) Every student in this class has not taken calculus.
∃x ¬P (x) ≡ ∀x ¬p(x).
Truth Table.
Negation Equivalent When Is Negation When False?
Statement True?
¬∃x p(x) ∀x p(x) For every x, P (x) is There is an x for
false which P (x) is true
¬∀x p(x) ∃x p(x) There is an x for P (x) is true for every
which P (x) is false. x
v) ∃x (3x = 2x)
True.
vi) ∃x (x = −x)
True.
vii) ∀n(n2 ≥ n)
Solution:-
Since for all integers the proposition function n2 ≥ n is True.
Therefor ∀n(n2 ≥ n) is True.
Set:-
Collection of distinct and well-defined objects(elements or members of the set). A set is said
to contain its elements. We write a ∈ A to denote that a is an element of the set A. The
notation a ∈ A denotes that a is not an element of the set A.
Example:- The set V of all vowels in the English alphabet,
O = {1, 3, 5, 7, 9}.
Representation of Set:-
Tabular/roster form:-
V = {a, e, i, o, u}.
O = {1, 3, 5, 7, 9}.
Descriptive form:-
The set V of all vowels in the English alphabet.
The set O of odd positive integers less than 10
Set builder form:-
{x | x ∈ N ∧ x≤5}
{ x | x ∈ N ∧ 10>x>4}
Finite Set:-
Aset having limited elements.
{ a,b,c,d}.
{ 1,3,5,7,9}.
Infinite Set:-
A set having unlimited elements.
{ 1,2,3,4,5,6…}.
A set of even numbers.
Empty Set:-
A set containing no element.
It is represented by ∅ or { }.
Singleton set:-
A set having 1 element.
A={ 1}.
Equal Set:-
Two sets are equal if and only if they have the same elements. Therefore, if A and B are
sets, then A and B are equal if and only if ∀x(x ∈ A ↔ x ∈ B). We write A = B if A and B are
equal sets.
A={a,b,c }
B={ b,c,a}
Subset:-
The set A is a subset of B if and only if every element of A is also an element of B.
We use the notation A ⊆ B to indicate that A is a subset of the set B.
We see that
A ⊆ B if and only if the quantification ∀x(x ∈ A → x ∈ B).
Example:- A={1,2,3,4 },B={1,2,3,4,5}
Superset:-
If A is the subset of B, then set B is called Superset of set.
Proper Subset:-
A set A is said to be a proper subset of set B if every element of set A is also in set B and
there exist at least one element in set B that is not in set A.
It is denoted by A ⊂ B
∀x(x ∈ A → x ∈ B) ∧ ∃x(x ∈ B ∧ x ∈ A).
Example:- A={1,2,3,4 },B={1,2,3,4,5}
Improper subset:-
A subset B consisting of all elements of set A, then it is called improper subset.
It is denoted by A ⊆ B
Example:- A={1,2,3,4},B={1,2,3,4}
Power set:-
Let a set consisting of all possible subset of set A.
It is denoted by P(A).If n is a number of elements in set A, then possible subset of A can be
find by 2n.
Example:- Let A={1,2,3}
Possible subset of set A are 23 = 8.
∅ , { },{1},{2},{3},{1,2},{1,3},{2,3},{1,2,3}.
P(A) = {∅ , { },{1},{2},{3},{1,2},{1,3},{2,3},{1,2,3}}
Operations on Set:-
Union:-
Let A and B be sets. The union of the sets A and B, denoted by A ∪ B, is the set that
contains those elements that are either in A or in B, or in both.
Symbolically:- A ∪ B = {x | x ∈ A ∨ x ∈ B}.
Example:-A={1, 3, 5},B={1, 2, 3}
A∪B={1, 3, 5}∪{1, 2, 3}
={1, 2, 3, 5}
Intersection:-
Let A and B be sets. The intersection of the sets A and B, denoted by A ∩ B, is the set
containing those elements in both A and B.
Symbolically:- A ∩ B = {x | x ∈ A ∧ x ∈ B}.
Example:-A={1, 3, 5},B={1, 2, 3}
A∩B={1, 3, 5}∩{1, 2, 3}
={1,3}
Disjoint set:-
Two sets are called disjoint if their intersection is the empty set.
Example:-A={1, 3, 5},B={2,4,6}
A∩B={1, 3, 5}∩{2,4,6}
={ }
Overlapping set:-
Two sets are called Overlapping if their intersection is the non-empty set.
Example:-A={1, 3, 5},B={1, 2, 3}
A∩B={1, 3, 5}∩{1, 2, 3}
={1,3}
Difference of Set:-
Let A and B be sets. The difference of A and B, denoted by A − B, is the set containing those
elements that are in A but not in B. The difference of A and B is also called the complement
of B with respect to A.
Symbolically:- A − B = {x | x ∈ A ∧ x ∉ B}.
Example:- A={1, 3, 5},B={1, 2, 3}
A − B ={1, 3, 5}− {1, 2, 3}
={5}
Complement of set:-
Let U be the universal set. The complement of the set A, denoted by ̅A or A′, is the
complement of A with respect to U. Therefore, the complement of the set A is U − A.
Symbolically:- A′= U – A={ x | x ∉ A }
Example:- U= {1,2,3,4,5,6,…}, B={1,3,5,7,9}
U – A={1,2,3,4,5,6,…} – {1,3,5,7,9}
{2,4,6,8,10,…}.
A Δ B = { x | x ∈ A/B ∧ B/A }
Cartesian product:-
Let A and B be sets. The Cartesian product of A and B, denoted by A × B, is the set of all
ordered pairs (a, b), where a ∈ A and b ∈ B.
Symbolically :- A × B = {(a, b) | a ∈ A ∧ b ∈ B}.
EXAMPLE:- A = {1, 2} , B = {a, b, c}.
Cardinality of A × B = Cardinality of A × Cardinality of B
A × B = {(1, a), (1, b), (1, c), (2, a), (2, b), (2, c)}.
Laws of Set:-
Laws of Set
Identity Name
A∩U=A Identity laws
A ∪∅= A
A∪U=U Domination laws
A ∩∅=∅
A∪A=A Idempotent laws
A∩A=A
(A′)′ = A Complementation law
A∪B=B∪A Commutative laws
A∩B=B∩A
A ∪ (B ∪ C) = (A ∪ B) ∪ C Associative laws
A ∩ (B ∩ C) = (A ∩ B) ∩ C
A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C) Distributive laws
A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C)
(A ∩ B)′ = A′ ∪ B′ De Morgan’s laws
(A ∪ B)′ = A′ ∩ B′
A ∪ (A ∩ B) = A Absorption laws
A ∩ (A ∪ B) = A
A ∪ A′ = U Complement laws
A∩A=∅
Function:-
Let A and B be sets. A function f from A to B is an assignment of exactly one element of B to
each element of A. We write f (a) = b if b is the unique element of B assigned by the function
f to the element a of A. If f is a function from A to B, we write f : A → B.
“Or”
If f is a function from A to B, we say that A is the domain of f and B is the codomain of f. If f
(a) = b, we say that b is the image of a and a is a preimage of b. The range, or image, of f is
the set of all images of elements of A.
Example:- f : R→ R,
One-to-One/Injection Function:-
one-to-one, or an injunction, f (a) = f (b)implies that a = b for all a and b in the domain of f.
“OR”
A function is said to be one-to-one function if every element of set A has different image in
Set B.
Example:- f:{a,b,c,d}→{1,2,3,4,5} with f (a) = 5, f (b) = 4, f (c) = 1, and f (d) = 3 is one-to-
one.
a 1
b 2
c 3
d 4
5
a 1
b 2
c 3
d
Example:- f : N→R
f(x)=2x+3
f(x)=y
2x+3=y
2x=y-3
𝒚−𝟑
x= 𝟐
x= -1 ∉ N
f(x) is not an onto function because codomain ≠ Rang.
A B
a1 b1
a2 b2
a3 b3
. .
. .
. .
an bm
|A|=m
|B|=n
Cardinality of total function = nm.