Mod2.1
Mod2.1
ALGEBRAIC STRUCTURES
SETS
DEFINITION
A set is an unordered collection of objects.
DEFINITION
The objects in a set are called 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.
NOTE
Sets to be denoted using uppercase letters. Lowercase letters are usually used to denote elements
of sets.
EXAMPLE
1.The set V of all vowels in the English alphabet can be written as V = {a, e, i, o, u}.
2. The set O of odd positive integers less than 10 can be expressed by O = {1, 3, 5, 7, 9}.
3. Although sets are usually used to group together elements with common properties, there is
nothing that prevents a set from having seemingly unrelated elements. For instance, {a, 2, Fred,
New Jersey} is the set containing the four elements a, 2, Fred, and New Jersey.
4. The set {N, Z, Q, R} is a set containing four elements, each of which is a set. The four
elements of this set are N, the set of natural numbers; Z, the set of integers; Q, the set of rational
numbers; and R, the set of real numbers.
EQUAL SETS
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.
EMPTY SET
There is a special set that has no elements. This set is called the empty set, or null set, and is
denoted by ∅. The empty set can also be denoted by { } .
NOTE
1.It does not matter if an element of a set is listed more than once, so {1, 3, 3, 3, 5, 5, 5, 5} is the
same as the set {1, 3, 5} because they have the same elements.
2. A set with one element is called a singleton set.
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.
Showing that A is a Subset of B, To show that A ⊆ B, show that if x belongs to A then x also
belongs to B.
EXAMPLE
1.The set of all odd positive integers less than 10 is a subset of the set of all positive integers less
than 10.
2.The set of rational numbers is a subset of the set of real numbers.
PROPER SUBSET
A set A is called proper subset of the set B. If (i) A is subset of B and (ii) B is not a subset A i.e.,
A is said to be a proper subset of B if every element of A belongs to the set B, but there is atleast
one element of B, which is not in A. If A is a proper subset of B, then we denote it by A B.
cardinality
Let S be a set. If there are exactly n distinct elements in S where n is a nonnegative integer, we
say that S is a finite set and that n is the cardinality of S. The cardinality of S is denoted by |S|.
EXAMPLE
1.Let A be the set of odd positive integers less than 10. Then |A| = 5.
2. Let S be the set of letters in the English alphabet. Then |S| = 26.
3.The null set has no elements, it follows that |∅| = 0.
INFINITE
A set is said to be infinite if it is not finite.
EXAMPLE
The set of positive integers is infinite.
UNIVERSAL SET
The universal set U, which contains all the objects under consideration.
POWER SET
Given a set S, the power set of S is the set of all subsets of the set S. The power set of S is
denoted by P(S).
2. What is the power set of the empty set? What is the power set of the set {∅}?
Solution: The empty set has exactly one subset, namely, itself.
Consequently, P(∅) = {∅}.
The set {∅} has exactly two subsets, namely, ∅ and the set {∅} itself.
c ∈ C. Hence, A × B × C = {(0, 1, 0), (0, 1, 1), (0, 1, 2), (0, 2, 0), (0, 2, 1), (0, 2, 2), (1, 1, 0), (1,
1, 1),(1, 1, 2), (1, 2, 0), (1, 2, 1), (1, 2, 2)}
PRACTICE PROBLEMS
1. List the members of these sets.
a) {x | x is a real number such that x 2 = 1}
b) {∅}
c) {∅,{∅}}
d) {∅,{∅},{∅,{∅}}}
4. Find the power set of each of these sets, where a and b are distinct elements.
a) {a}
b) {a, b}
c) {∅,{∅}}
5. Find A2 if
a) A = {0, 1, 3}.
b) A = {1, 2, a, b}
Answer
1. a) {1,-1}; b) {1,2,3,4,5,6,7,8,9,10,11}; c) {0, 1, 4, 9, 16, 25, 36, 49, 64, 81}
2. a){3n / n = 0, 1, 2, 3, 4}; b) { x / 3 x 3}
3. a)0; b)1; c)2; d)3
4. a) {∅,{a}} ; b) {∅, {a}, {b}, {a,b}}; c) {∅,{0},{{0}},{0,{0}}}
5. a) {(0,0), (0,1),(0,3),(1,0), (1,1),(1,3), (3,0),(3,1),(3,3)}
b) {(1,1),(1,2),(1,a),(1,b),(2,1), (2,2),(2,a),(2,b),(a,1),( (a,2),(a,a),(a,b),(b,1), (b,2),
(b,a),(b,b)}
SET OPERATIONS
EXAMPLE
Let A = {1, 3, 5, 7, 9} and B = {2, 4, 6, 8, 10}. Because A ∩ B = ∅, A and B are disjoint.
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. It is denoted by A ∪ B = {x | x ∈ A ∨ x ∈
B}.
EXAMPLE
1.The union of the sets {1, 3, 5} and {1, 2, 3} is the set {1, 2, 3, 5}; that is, {1, 3, 5} ∪ {1, 2, 3}
= {1, 2, 3, 5}.
2. The union of the set of all computer science majors at your school and the set of all
mathematics majors at your school is the set of students at your school who are majoring either
in mathematics or in computer science (or in both)
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. It is denoted by A ∩ B = {x | x ∈ A ∧ x ∈ B}.
EXAMPLE
1. The intersection of the sets {1, 3, 5} and {1, 2, 3} is the set {1, 3}; that is, {1, 3, 5} ∩ {1, 2, 3}
= {1, 3}.
2. The intersection of the set of all computer science majors at your school and the set of all
mathematics majors is the set of all students who are joint majors in mathematics and computer
science.
DIFFERENCE OF SETS
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. It is denoted by A – B thus: A – B = {x | x ∈ A and x B}.
EXAMPLE
The difference of {1, 3, 5} and {1, 2, 3} is the set {5}; that is, {1, 3, 5} − {1, 2, 3} = {5}. This is
different from the difference of {1, 2, 3} and {1, 3, 5}, which is the set {2}
COMPLEMENT OF A SET
Let U be the universal set. The complement of the set A, denoted by A , is the complement of A
with respect to U. Therefore, the complement of the set A is U – A. It is denoted by A thus
A {x U / x A}.
EXAMPLE
1.Let A = {a, e, i, o, u} (where the universal set is the set of letters of the English alphabet). Then
A = {b, c, d, f, g, h, j, k, l, m, n, p, q, r, s, t, v, w, x, y,z}.
2. Let A be the set of positive integers greater than 10 (with universal set the set of all positive
integers). Then A = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}.
DISJOINT SETS
Two sets are called disjoint if their intersection is the empty set.
VENN DIAGRAM
A venn diagram is a pictorial representation of the set. The universal set U is normally
represented by a rectangle and its subsets as circles inside it. Venn diagram are useful in
understanding relations among sets and operations on set.
PRACTICE PROBLEMS
NOTE
Functions are sometimes also called mappings or transformations.
EXAMPLE
Let X = {1, 2, 3}, Y = {p, q, r} and f = {(1, q), (2, p), (3, r)} then f(1) = q, f(2) = p, f(3) = r.
Clearly f is a function from X to Y.
DEFINITION
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. Also, if f is a function from A to B, we say that f maps A to B.
EXAMPLE
1. If the function f is defined by f(x) = x 2 + 1 on the set {−2, −1, 0, 1, 2}, find the range of f.
Solution:
f(−2) = (2)2 + 1 = 5
f(−1) = (1) 2 + 1 = 2
f(0) = 0 + 1 = 1
f(1) = 1 + 1 = 2
f(2) = 4 + 1 = 5
Therefore, the range of f = {1, 2, 5}
2. Let R be the relation with ordered pairs (Abdul, 22), (Brenda, 24), (Carla, 21), (Desire, 22), (Eddie, 24),
and (Felicia, 22). Here each pair consists of a graduate student and this student’s age. Specify a function
determined by this relation.
Solution: If f is a function specified by R, then f (Abdul) = 22, f (Brenda) = 24, f (Carla) = 21, f (Desire) = 22,
f (Eddie) = 24, and f (Felicia) = 22. (Here, f (x) is the age of x, where x is a student.)
For the domain, we take the set {Abdul, Brenda, Carla, Desire, Eddie, Felicia}.
The range of the function we have specified is the set of different ages of these students, which is the
set {21, 22, 24}.
ONE-TO-ONE (INJECTIVE)
A function f is said to be one-to-one, or an injective, if and only if f (a) = f (b)implies that a = b
for all a and b in the domain of f. i.e distinct elements should have distinct images A function is
said to be injection if it is one-to-one.
EXAMPLE
Determine whether the function f from {a, b, c, d} to {1, 2, 3, 4, 5} with f (a) = 4, f (b) = 5, f (c)
= 1, and
f (d) = 3 is one-to-one.
Solution:
The function f is one-to-one because f takes on different values at the four elements of its domain.
Solution:
The function f : Z → Z given by f(x) = x 2 , x ∈ Z is not a one-to-one function. This is because
both 3 and -3 have 9 as their image, which is against the definition of a one-to-one function.
3. Determine whether the function f (x) = x + 1 from the set of real numbers to itself is one-to-
one. Solution:
The function f (x) = x + 1 is a one-to-one function.
A function f from A to B is called onto, or a surjective, if and only if for every element b ∈ B
there is an element a ∈ A with f (a) = b. A function f is called surjection if it is onto.
EXAMPLE
1. Let f be the function from {a, b, c, d} to {1, 2, 3} defined by f (a) = 3, f (b) = 2, f (c) = 1, and f
(d) = 3. Is f an onto function?
Solution:
All three elements of the codomain are images of elements in the domain, we see that f is onto.
2. Is the function f (x) = x + 1 from the set of integers to the set of integers onto?
Solution:
This function is onto, because for every integer y there is an integer x such that f (x) = y. To see
this, note that f (x) = y if and only if x + 1 = y, which holds if and only if x = y − 1.
BIJECTIVE
The function f is a one-to-one correspondence, or a bijection, if it is both one-to-one and onto.
We also say that such a function is bijective.
EXAMPLE
1.Let f be the function from {a, b, c, d} to {1, 2, 3, 4} with f (a) = 4, f (b) = 2, f (c) = 1, and f (d)
= 3. Is f a bijection?
Solution:
The function f is one-to-one and onto. It is one-to-one because no two values in the domain are
assigned the same function value. It is onto because all four elements of the codomain are images
of elements in the domain. Hence, f is a bijection.
2.Show that a mapping f : R → R defined by f(x) = 2x + 1 for x ∈ R is a bijective map from R to
R.
Solution:
⇒f(x) = f(y)
⇒ 2x + 1 = 2y + 1
⇒x=y
⇒ 2x + 1 = y
⇒ x = (y-1)/2
Clearly, x = (y-1)/2∈ R
Thus, every element in the codomain has pre-image in the domain.
This implies that f is onto.
Hence, f is a bijective map.
INVERSE FUNCTION
Let f be a one-to-one correspondence from the set A to the set B. The inverse function of f is the
function that assigns to an element b belonging to B the unique element a in A such that f (a) = b.
The inverse function of f is denoted by f 1 . Hence, f 1 (b) = a when f (a) = b.
NOTE:
A one-to-one correspondence is called invertible because we can define an inverse of this
function. A function is not invertible if it is not a one-to-one correspondence, because the inverse
of such a function does not exist.
EXAMPLE
1. Let f be the function from {a, b, c} to {1, 2, 3} such that f (a) = 2, f (b) = 3, and f (c) = 1.
Is f invertible, and if it is, what is its inverse?
Solution:
The function f is invertible because it is a one-to-one correspondence.
The inverse function f 1 reverses the correspondence given by f , so
f 1(1) c, f 1(2) a and f 1 (3) b .
2. Let f be the function from R to R with f (x) = x 2 . Is f invertible?
Solution:
Because f (−2) = f (2) = 4, f is not one-to-one. If an inverse function were defined, it
would have to assign two elements to 4. Hence, f is not invertible.
(Note we can also show that f is not invertible because it is not onto.)
3. f : R → R is defined by f(x) = ax + b, for a, b ∈ R and a 0 . Show that f is invertible
and find the inverse of f.
Solution
(i) First we shall show that f is one-to-one
Let x 1 , x 2 ∈ R such that f( x 1 ) = f( x 2 )
⇒ a x1 + b = a x 2 + b
⇒ a x1 = a x 2
⇒ x1 = x 2
∴ f is one-to-one.
(ii) To show that f is onto.
Let y ∈ R(codomain) such that y = f(x) for some x ∈ R.
⇒ y = ax + b
⇒ ax = y − b
⇒ x = (y-b)/a
Given y ∈ R(codomain), there exists an element x = (y-b)/a ∈ R such that f(x) = y.
∴ f is onto
xb
⇒ f is invertible and f 1 x
a
IDENTITY FUNCTION
Let X be any set and f be a function such that f : X → X is defined by f(x) = x for all x ∈ X.
Then, f is called the identity function or identity transformation on X. It can be denoted by I or
IX .
⇒x=y
⇒ I X is one-to-one
COMPOSITION OF FUNCTIONS
Let g be a function from the set A to the set B and let f be a function from the set B to the set C.
The composition of the functions f and g, denoted for all a ∈ A by f ◦ g, is defined by (f ◦ g)(a) =
f (g(a)).