Module 1 Introduction To Number Theory and Relations
Module 1 Introduction To Number Theory and Relations
Study Material
(Discrete Mathematics (BBS00008)
_____________________________________________________________________________________________
Table of Contents
Module I:
Introduction to Number Theory and Relations
Department of Mathematics
Brainware University, Kolkata 1
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Introduction:
S et theory is a foundational branch of mathematical logic that studies sets, which are collections of distinct
objects. Developed in the late 19th and early 20th centuries, set theory provides a formal language and
framework for describing and analyzing mathematical and logical concepts.
Sets: A set is a well-defined collection of distinct objects, considered as an object in its own right. The objects within
a set are called elements. Sets are typically denoted by curly braces, and elements are listed inside. For example, if A
is the set of natural numbers less than 5, it can be written as A={1,2,3,4}.
Z or I – Set of integers
Representation of Sets:
A set is described in the following two ways:
1. Roster Form:
In Roster form, all the elements of a set are listed.
For example, the set of natural numbers less than 5.
Natural Number = 1, 2, 3, 4, 5, 6, 7, 8,….
Natural Number less than 5 = 1, 2, 3, 4
Therefore, the set is N = { 1, 2, 3, 4 }
Solution:
2=2x1
4=2x2
6=2x3
Department of Mathematics
Brainware University, Kolkata 2
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
8=2x4
● Infinite set:
A = (1, 2, 3, 4 } is an infinite set.
● Equivalent set:
Two finite sets A and B are equivalent if n(A) = n(B)
● Equal sets:
Two sets A and B are equal iff A = B
● Power set: The family of all the subsets of set S is called the power set of S.
It is denoted by P(S) i.e., P(S) = {T: T ⊆ S}
Proper Subsets:
If A is a proper subset of B, then A ⊂ B.
a. If A ⊆ B, we may have B ⊆ A
b. But if A ⊂ B, we cannot have B ⊂ A.
Question: Find the power set of Z = {2, 7, 9} and a total number of elements.
Solution: Given, Z = {2, 7, 9}
Total number of elements in power set = 2n
Here, n = 3 (number of elements in set Z)
So, 23 = 8, which shows that there are eight elements of power set of Z
Therefore,
P(Z) = {{}, {2}, {7}, {9}, {2, 7}, {7, 9}, {2, 9}, {2, 7, 9}}
Operations on Sets:
● Union of sets: Let A and B be two sets. Then, A ∪ B= {x : x ∈ A or x ∈ B}.
∴A ⊆ A ∪ B, B ∪ A and A ∪ B = B ∪ A
A ∩ B= {x : x ∈ A and x ∈ B)
∴ A ∩ B ⊆ A, A ∩ B ⊆ B and A ∩ B = B ∩ A
a. A–B≠B–A
b. The sets A – B, B – A and A ∩ B are disjoint sets.
c. A – B ⊆ A and B – A ⊆ B
d. A – φ = A and A – A = φ
It is denoted by A – B or A ~ B or A\B or CAB (complement of B in A).
Department of Mathematics
Brainware University, Kolkata 4
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
● A Δ B = (A – B) ∪ (B – A) = (A ∪ B) – (A ∩ B)
● Complement of a set:
The complement of A with respect to U is denoted by A' or Ac or C(A) or U – A
i.e., A' = {x ∈ U : x ∉ A}
i. (A')' = A
ii. X' = φ
iii. φ'=X
iv. A ∩ A' = φ
v. A ∪ A' = X
vi. If A ⊆ B, then B' ⊆ A'
ii. A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C)
i. A ∩ (B − C) = (A ∩ B) − (A ∩ C)
De-Morgan’s laws:
iii. A − (B ∩ C) = (A − B) ∪ (A − C)
iv. A − (B ∪ C) = (A − B) ∩ (A − C)
If set A and set B are two sets then the cartesian product of set A and
i. A × (B∪ C) = (A × B) ∪ (A ×C)
ii. A × (B ∩ C) = (A × B) ∩ (A ×C)
iii. A ×(B − C) = (A × B) − (A × C)
iv. If A ⊆ B, then (A ×C) ⊆ (B×C)
v. If A ⊆ B, then (A × B) ∩ (B× A) = A2
vi. If A ⊆ B and C ⊆ D then A × C ⊆ B× D
vii. (A × B) ∩ (S ×T) = (A ∩S) ×(B ∩ T) ,
Department of Mathematics
Brainware University, Kolkata 6
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Relation:
If R is a relation from A to B then R ⊆ A × B ie, R ⊆ {(a,b):a ∈ A,b ∈ B}
Notes: Number of possible relations from A to B is = 2mn [if o(A) = m and o(B) = n]
Inverse Relation:
The inverse of R, denoted by R–1 is a relation from B to A and is defined by,
Thus,
i. (a, b) ∈ R ⇔ (b, a) ∈ R–1 ∀ a ∈ A, b ∈ B
ii. Dom (R–1) = Range (R)
iii. Range (R–1) = Dom (R)
iv. (R–1)–1 = R
Equivalence Relation:
A relation R on a set ‘A’ is said to be equivalence relation on a iff
1. It is reflexive i.e.,(a, a) ∈ R ∀ a ∈ A
Antisymmetric: A relation R on a set ‘A’ is said to antisymmetric i.e.,(a, b) ∈ R and (b, a) ∈ R, then a = b.
Question: Let R be the relation on the set R of all real numbers defined by a R b if and only if |a − b| ≤ 1. Then
check if R is reflexive, symmetric, anti-symmetric, or transitive.
Solution:
|a − a| = 0 < 1
Department of Mathematics
Brainware University, Kolkata 7
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Therefore, a R a ∀ a ∈ R
Therefore, R is reflexive.
Again a R b, |a − b| ≤ 1 ⇒ |b − a| ≤ 1 ⇒ b R a
Therefore, R is symmetric.
Composition of two Relations: If A, B and C are three sets such that R ⊆ A × B and S ⊆ B × C, then SoR ⊆ A × C
and (SoR)–1 = R– 1oS–1. It is clear that aRb, bSc ⇒ a(SoR)c .
Partial Order Relations:
A relation R on a set A is called a partial order relation if it satisfies the following three properties:
Question: Show whether the relation (x, y) ∈ R, if, x ≥ y defined on the set of positive integers is a partial order
relation.
Solution: Consider the set A = {1, 2, 3, 4} containing four positive integers. Find the relation for this set such as R =
{(2, 1), (3, 1), (3, 2), (4, 1), (4, 2), (4, 3), (1, 1), (2, 2), (3, 3), (4, 4)}.
Reflexive: The relation is reflexive as for every a ∈ A. (a, a) ∈ R, i.e. (1, 1), (2, 2), (3, 3), (4, 4) ∈ R.
Transitive: The relation is transitive as whenever (a, b) and (b, c) ∈ R, we have (a, c) ∈ R.
Division Algorithm: Given integers a and d, with d > 0, there exists unique integers q and r, with 0 ≤ r < d, such
that a = qd + r.
(Notation: We call a the dividend, d the divisor, q the quotient, and r the remainder.)
Department of Mathematics
Brainware University, Kolkata 8
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Proof. Suppose a and d are integers, and d > 0. We will use the well-ordering principle to obtain the quotient q
and remainder r. Since we can take q = a if d = 1, we shall assume that d > 1. Let S be the set of all natural numbers
of the form a−kd, where k is an integer. In symbols
S = {a – kd | k ∈ Z and a − kd ≥ 0}. If we can show that S is nonempty, then the well-ordering principle will give us a
least element of S, and this will be the remainder r we are looking for. There are two cases.
Case 2: a < 0. In this case, we can set k = a. Then a − kd = a − ad = a(1 − d). Since a < 0 and d > 1, a(1 − d) > 0; hence
is an element of S. Thus, S 6= ∅, and so S has a least element r = a − qd for some integer q. Thus, a = qd + r and r ≥
0. We are left to show (i) r < d and (ii) q and r are unique.
(ii) Suppose integers q 0 and r 0 satisfy a = q 0d + r 0 and 0 ≤ r 0 < d. Without loss of generality, we may assume r 0
≥ r, so that 0 ≤ r − r 0 < d. Since a = q 0d + r 0 = qd + r, r − r 0 = d(q 0 − q). This means that d divides r − r 0 , which
implies either r − r 0 ≥ d or r − r 0 = 0. But but we know 0 ≤ r − r 0 < d. Thus, r 0 = r, which, in turn, implies q 0 = q.
That is, q and r are unique.
Prime Number: If p is an integer greater than 1, then p is a prime number if the only divisors of p are 1 and p.
Composite Number: A positive integer greater than 1 that is not a prime number is called composite.
Fundamental Theorem of Arithmetic: Every positive integer greater than one can be written uniquely as a product
of primes, where the prime factors are written in non-decreasing order
Greatest Common Divisor and Least Common Multiple:
Given integers a and b
(1) The greatest common divisor of a and b, denoted GCD (a, b), is the largest positive integer d such that d|a and
d|b.
(2) The least common multiple of a and b, denoted LCM (a, b), is the smallest positive integer m such that a|m
and b|m.
(3) a and b are called relatively prime if GCD (a, b) = 1.
(4) The integers 𝑎1 , 𝑎2 , 𝑎3 , . . . , an are called pairwise relatively prime if GCD(𝑎𝑖 , 𝑎𝑗 ) = 1 for 1 ≤ i < j ≤ n.
Department of Mathematics
Brainware University, Kolkata 9
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Proof: Divide a by b obtaining a quotient q and a reminder r, then a = bq + r , 0 ≤ r < b . If d is a common divisor of
a and b then it must be a divisor of r = a−bq. Conversely, if d is a common divisor of b and r then it must divide a
= bq + r. So the set of common divisors of a and b and the set of common divisors of b and r are equal, and the
greatest common divisor will be the same. The Euclidean algorithm is a follows. First we divide a by b, obtaining a
quotient q and a reminder r. Then we divide b by r, obtaining a new quotient q0 and a reminder r0 . Next we divide
r by r0 , which gives a quotient q00 and another remainder r00. We continue dividing each reminder by the next
one until obtaining a zero reminder, and which point we stop. The last non-zero reminder is the gcd.
Example: Assume that we wish to compute gcd(500, 222). Then we arrange the computations in the following
way:
500 = 2 · 222 + 56 → r = 56
222 = 3 · 56 + 54 → r’= 54
56 = 1 · 54 + 2 → r’’ = 2
54 = 27 · 2 + 0 → r’’’ = 0
The last nonzero remainder is r’’ = 2, hence gcd(500, 222) = 2.
Furthermore, if we want to express 2 as a linear combination of 500 and 222, we can do it by working backward:
2 = 56 − 1 · 54 = 56 − 1 · (222 − 3 · 56) = 4 · 56 − 1 · 222 = 4 · (500 − 2 · 222) − 1 · 222 = 4 · 500 − 9 · 222
Introduction:
Existence of Solutions:
Department of Mathematics
Brainware University, Kolkata 10
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Applications:
Department of Mathematics
Brainware University, Kolkata 11
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Department of Mathematics
Brainware University, Kolkata 12
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Department of Mathematics
Brainware University, Kolkata 13
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Department of Mathematics
Brainware University, Kolkata 14
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Department of Mathematics
Brainware University, Kolkata 15
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Practice Problem:
1. Select the correct option from the following that is not true for a partial order relation.
a. It must be antisymmetric b. It must be symmetric
c. It must be transitive d. It must be reflexive
Department of Mathematics
Brainware University, Kolkata 16
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
Department of Mathematics
Brainware University, Kolkata 17
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
a. 2n (n+1) / 2 b. 2n(n - 1)
c. 2n d. 2n+2
10. Select the correct option. Division Algorithm states
a. 𝑎 = 𝑞𝑏 + 𝑟, where 0 ≤ 𝑟 < 𝑏 b. 𝑎 = 𝑞𝑏 + 𝑟, where 0 < 𝑟 < 𝑏
c. 𝑎 = 𝑞𝑏 + 𝑟, where 𝑟 > 𝑏 d. 𝑎 = 𝑞𝑏 + 𝑟, where 𝑟 < 0
11. Select the correct option. If 𝑆 = {∅} then power set of S is
a. {∅} b. ∅
c. {∅, {∅}} d. None of these
12. Select the correct option. The Division Algorithm is applicable to the numbers
a. Only positive integers b. All integers
c. rational numbers d. None of these
13. Observe and find out the singleton set from the following.
a. A = { x : 3 x2 − 27= 0 , x ∈ Q } b. B = { x : x2− 1 = 0 , x ∈ R }
c. C = { x : 30 x − 59 = 0 , x ∈ N} d. D = { x : x2 − 1 = 0 , x ∈ N }
14. If 𝑎 = −17 and 𝑏 = 5, then identify the quotient and remainder according to the Division
Algorithm.
a. 𝑞 = −4, 𝑟 = 3 b. 𝑞 = −3, 𝑟 = 2
c. 𝑞 = −5, 𝑟 = 8 d. 𝑞 = 3, 𝑟 = 2
15. If A and B are sets and A∪ B= A ∩ B, then select the correct option.
a. A = Φ b. B = Φ
c. A = B d. none of these
16. Predict the number of elements in the power set of the set {a, b}.
a. 2 b. 4
c. 6 d. 8
17. Select the correct option. Let N be the set of natural numbers and R be the relation in N
defined as R = {(a, b) : a = b – 2, b > 6}.
a. (2, 4) ∈ R b. (8, 7) ∈ R
c. (3, 8) ∈ R d. (6, 8) ∈ R
18. A survey shows that 70% of the Indian like mango whereas 82% like apple. Interpret the
range of x if x% of Indian like both mango and apples.
Department of Mathematics
Brainware University, Kolkata 18
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
a. x = 52 b. 52 x 70
c. x = 70 d. 70 x 82
19. Select the correct option. If 𝑋 ∪ {3,4} = {1,2,3,4,5,6}, then
a. Smallest set X = {1,2,5,6} b. Smallest set X= {1,2,3,5,6}
c. Smallest set X= {1,2,3,4} d. Greatest set X= {1,2,3,4}
20. If two sets A and B are having 43 elements in common, then select the number of elements
in the set A∩ B
a. 43 b. 43
2
43 86
c. 43 d. 2
21. In a certain town 30% families own a scooter and 40% on a car 50% own neither a scooter
nor a car 2000 families own both a scooter and car consider the following statements in this
regard
(1) 20% families own both scooter and car
(2) 35% families own either a car or a scooter
(3) 10000 families live in town
Identify the correct statements from the above.
a. 2 and 3 b. 1 and 2
c. 1 and 3 d. 1, 2 and 3
22.
n P P P ( A) =
If set A is an empty set then illustrate the value of
a. 6 b. 16
c. 2 d. 4
23. If 𝑎 ≡ 2 (𝑚𝑜𝑑 5) and 𝑏 ≡ 3 (𝑚𝑜𝑑 5), then identify the value of (𝑎 + 𝑏) mod 5.
a. 0 b. 1
c. 2 d. 3
24. Identify the value of 𝑥 for 25 ≡ 𝑥 (𝑚𝑜𝑑 7).
a. 4 b. 5
c. 3 d. 111
25. A = ( x, y ) : y = e x , x R B = ( x, y ) : y = e − x , x R
Let , then predict the correct option.
Department of Mathematics
Brainware University, Kolkata 19
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
a. A B = b. A B
c. A B = R d. A B = A
26. Let R be a reflexive relation of a finite set A having n elements and let there be m ordered
pairs in R. Then observe the correct option.
a. mn b. m n
c. m = n d. None of these
27.
Let R be a relation on N defined by
R = (1 + x,1 + x2 ) : x 5, x N . Select the correct
option.
d. 2 − 1
2 9
c. 3
30. For m, n N , n | m means that n is a factor of m, then classify the relation | from the
following.
a. Reflexive and symmetric b. Transitive and symmetric
c. Reflexive, transitive and symmetric d. Reflexive, transitive and not
symmetric
31. A = 1, 2,3, 4,5
Select the correct option. The relation is defined on the set by
= ( x, y ) | x2 − y 2 16 is given by
a. {(1,1), (2,1), (3,1), (4,1), (2,3)} b. {(2,2), (3,2), (4,2), (2,4)}
Department of Mathematics
Brainware University, Kolkata 20
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
a. 12 b. 6
c. 18 d. 24
34. R = ( a, b ) , ( b, c ) A = a, b, c
Given the relation in the set then identify the
minimum number of ordered pairs that need to be added to R make it an equivalence
relation.
a. 5 b. 6
c. 7 d. 8
35.
Let R be the relation over the set N N and is defined by ( a, b ) R ( c, d ) a + d = b + c
then classify the relation R.
a. Reflexive only b. Symmetric only
c. Transitive only d. An equivalence relation
36.
Select the correct option. If S is defined on R by ( x, y ) S xy 0 then S is
a. An equivalence relation b. Reflexive only
c. Symmetric only d. Transitive only
37. Select the correct option. A linear Diophantine equation in two variables has the form:
a. 𝑎𝑥 2 + 𝑏𝑦 = 𝑐, where 𝑎, 𝑏, 𝑐 ∈ ℤ b. 𝑎𝑥 + 𝑏𝑦 = 𝑐, where 𝑎, 𝑏, 𝑐 ∈ ℤ
Department of Mathematics
Brainware University, Kolkata 21
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
c. 2 d. Infinitely many
40. Identify the condition for the equation 𝑎𝑥 + 𝑏𝑦 = 𝑐 to have integer solutions.
a. 𝑐 must be even b. 𝑎 = 𝑏
c. gcd(𝑎, 𝑏) ∕ 𝑐 d. 𝑎𝑏 ∕ 𝑐
41. Select the correct option. If 𝑎𝑥 + 𝑏𝑦 = 𝑐 has one integer solution, then:
Department of Mathematics
Brainware University, Kolkata 22
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
3. Identify the GCD of 252 and 105 using the Euclidean Algorithm.
8. Let 𝐴 = {1,2,3} and let 𝑅 = {(1,1), (2,2), (3,3), (1,2), (2,1)}. Examine if 𝑅 is an equivalence
relation on 𝐴.
9. Let 𝑅 on ℤ be defined as 𝑎𝑅𝑏 if and only if 𝑎 ≡ 𝑏 (𝑚𝑜𝑑 5). Show that 𝑅 is an equivalence
relation.
Department of Mathematics
Brainware University, Kolkata 23
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
1.
State the partial order relation. Examine if the subset relation ⊆ on power set 𝑃(𝑆) a partial
order.
3. Identify the Hasse diagram for the power set of {𝑎, 𝑏} ordered by inclusion.
4. Discuss a linear Diophantine equation in two variables. Discuss the condition for its
solvability. Also, identify all integer solutions of the equation 15𝑥 + 21𝑦 = 6.
5. Examine if the relation R = {(p, q): |p-q| is even} is an equivalence relation on the set P= {3,
4, 5,6}.
6.
Consider A = {2, 3, 4, 5} and R = {(5, 5), (5, 3), (2, 2), (2, 4), (3, 5), (3, 3), (4, 2), (4, 4)}, then
examine if R is an Equivalence Relation.
7. Examine that cube of any integer can be written in the form 9k, 9k + 1 or 9k − 1 for some k ∈
Z, Z is the set of all integers.
9. Identify the solution of the system of linear congruences using Chinese Remainder Theorem:
𝑥 ≡ 2 (𝑚𝑜𝑑 3), 𝑥 ≡ 3 (𝑚𝑜𝑑 4), 𝑥 ≡ 2 (𝑚𝑜𝑑 5).
10. Identify the solution of the system of linear congruences using Chinese Remainder Theorem:
𝑥 ≡ 1 (𝑚𝑜𝑑 7), 𝑥 ≡ 2 (𝑚𝑜𝑑 8), 𝑥 ≡ 3 (𝑚𝑜𝑑 9).
Department of Mathematics
Brainware University, Kolkata 24
Programme Name and Semester: B. Tech CSE (AIML_AIR_CYS), 3rd semester
Course Name (Course Code): Discrete Mathematics (BBS00008)
Academic Session: 2025-26
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 Mathematics
Brainware University, Kolkata 25