Anda di halaman 1dari 215

NOTES

SUBJECT: DISCRETE MATHEMATICS


SUBJECT CODE: NMCA-114

BRANCH: MCA
SEM:1ST
SESSION: 2014-15
Evaluation scheme:
Subject
Code
NMCA114

Name of
Subject
Discrete
mathematics

Periods
L T P
3 1 0

Evaluation Scheme
CT TA TOTAL ESE
30 20
50
100

Subject
Total
150

Credit
4

Dr. B. K. Sharma
Ms. Saroj Bala
MCA Department
AKGEC,GZB.

INDEX
UNIT-1
Set Theory, Relations, Functions and Notion of Proof
1.1.
1.2
1.3
1.4
1.5
1.6
1.7
1.8
1.9
1.10
1.11
1.12
1.13.

Set
Subsets
Set Operations :
Laws of Algebra of Sets:
Other Important Results in Set Theory
VENN DIAGRAM
Some More Results on Set Theory
Cartesian Product of
Partitions or Quotient Sets
Index Set
Relation
Different Methods of representation of a relations:
Properties of Relations (or classification of Relations) f relations on a set.
1.13.1 Reflexive and irreflexive relations
1.13.2 Symmetric, antisymmetric and asymmetric relations
1.13.3Transitive Relation
1.14
Equivalence Relation
1.15
Power of a Relation
1.16
Closures of Relation
1.17
Equivalence class or Equivalence set
1.18
Properties of Equivalence classes
1.19
Relation induced by a Partition of a set
1.20
Quotient Set
1.21
Functions
1.21.1 Function of a single
1.21.2 Difference between a Relation and a Function
1.21.3 Identity Function
1.21.4 Constant Function
1.21.5 Inverse Mapping
1.21.6 Real Valued mapping or function
1.22 Product or Composition of Mapping
1.23 Different forms of function
1.24. Types of functions
1.24.1. One-to-one function or mapping or injective mapping
1.24.2 Many one function or mapping
1.24.3 Surjective or Onto mapping or
1.24.4. Into function or mapping:
1.24.4.1 One-One-into mapping
1.24.4.2 Many one into mapping
1.24.5. Bijective mapping or one to one and onto mapping:
1.24.6. Many-one onto mapping:
1.25
Mathematical Induction :

UNIT-2
Algebraic Structure
2.1
2.2
2.3
2.4
2.5
2.6.
2.7
2.8
2.9
2.10
2.11.
2.12.
2.13.
2.14
2.15
2.16
2.17
2.18
2.19
2.20
2.21.
2.22.

2.23.
2.24
2.25
2.26
2.27

Binary Relation
Properties of Binary Operations
Algebraic Structure :
Semi-group :
Group :
Abelian Group or Commutative Group
Finite and Infinite Group:
Order of a group
Composition table for finite sets
Addition Modulo m
Congruence modulo
Multiplication Modulo m
Permutations
Group of Permutation
Cyclic Permutation or cycle
Order of an element in a group
Subgroups of a group
2.17.1. Properties of Subgroups
Cyclic Groups
Normal Subgroup
Isomorphism & Homomorphism
Group Homomorphism and Group Isomorphism
Rings
2.22.1 Commutative Ring
2.22.2. Ring with Unity
2.22.3. Null Ring or Zero Ring:
2.22.4. Properties of a Ring
2.22.6 Cancellation laws in a ring
Integral Domain:
Field
Division Ring or Skew field
Sub-Ring:
Sub-Field :

UNIT-3
Lattices and Boolean algebra
3.1
3.2
3.3
3.4
3.5
3.6
3.7

Partial Order Relation


Hasse Diagrams of Partially Ordered Sets
Minimal, Maximal, first and last elements of S
Upper and Lower Bounds
Lattices
Boolean Algebra
Logic Gates and Circuits

Unit-4
Propositional and Predicate Logic
4.1
4.2
4.3
4.4
4.5
4.6
4.7
4.8
4.9

Propositions:
Connectives
Tautology and Contradiction
Logical Equivalence
Converse, inverse and contra positive of the Conditional statements
Rule of precedence
Equivalence of Formula
Argument
Quantifiers

Unit-5
Trees and Graphs, Recurrence Relation and Combinatorics
5.1
5.2
5.3
5.4
5.5
5.6.
5.7
5.8.
5.9

Graph
Walk
Different types of graphs
Trees
Binary Tree :
Coloring
Recurrence Relation
Methods of solving Recurrence relations
Combinatorics

UNIT-1:
Set Theory, Relations, Functions and Notion of Proof

1.1.
Set : Any well defined collection of distinct objects is called a set. The objects in a set can be numbers,
people, letters, rivers, countries etc. The objects in a set are called the elements or members of the set.
Examples :

1. The set of numbers 4, 6, 8, 10.


2. The set of letters a, e, i, o, u.

Notation Sets are usually denoted by capital letters or upper case letters A, B, C, X, Y, ., and the elements in a
set are denoted by lower case letters a, b, c, x, y,

Representation of sets

There are two ways of writing down a set, tabular form and set builder form.
Tabular form or Roaster form of a set - In this form all the members of the set are listed. These members are
separated by commas and enclosed in braces { }.
Example If the elements of a set A are 2, 5, 7, 8, 11, then it can be written in tabular form as A = {2, 5, 7, 8, 11}.
Representation of the set in this way is known as tabular form of a set.

Set-builder form of a set. In this form a set is defined by starting the properties which are satisfied by its
elements. Here the rule governing the membership of the set is stated.
Example A set of all even positive integers is written in set-builder form as
B = { x : x is even positive integer}
or

B = { x | x is even positive integer}

and this is read B is a set of numbers x such that x is an even positive integer.

Cardinality or Cardinal Number of a set :The number of elements in a set A is also called the number or cardinal
number of the set and is denoted as n (A) or O (A) or |A|. If n (A) = n (B), A & B are said to be equivalent sets.

Example: If S = {3, 5, 7, 9, 11}, then the cardinal number of this set is 5 because there are only five elements in this
set and we write n (S) = |S| = 5.

Finite and Infinite Sets : A set is called finite if it has n distinct elements where n N. Such a set consists of a
specific number of different elements. In such a set the process of counting different members comes to an end.
Otherwise a set is infinite.
Example: A = { 2, 4, 6 } is an infinite set and B = {x | x is an Indian citizen} is a finite set.

Equality of Sets :If every member of set A is a member of set B and every member of set B is also a member of set
A, then two sets A and B are said to be equal and we write A = B
we given below examples of equal sets.
(1) If A = {1, 2, 3, 4, 5} and B = {3, 1, 2, 4, 5}, then A = B, because every member of set A is a member of set B
and every member of set B is a member of set A.
Null Set or Void Set or Empty Set : A set which contain no element is called a Null set. It is denoted by the symbol
or { }.
Examples:

(1)

The set of integers between 9/4 and 11/4

(2)

The set of integers that are less than 4 and greater than 8.

Singleton Set: A set containing only one element is called a singleton set, e.g. A = {3} and B = {0} are both singleton
sets.

1.2

Subsets: If every member in a set A is also a member of set B, then A is said to be a subset of B. We write
this relation as A Band read A is contained in B or more precisely it is written as A B.

Examples of Subsets
(1) If A = {2, 4, 6} and B = {3, 2, 4, 5, 6} then A is a subset of B because every member of A is also a member of B.

Equality of set and Subsets:If A and B are two sets, then A = B if and only if A B and B A or A = B A B and
B A.

Superset: If A is a subset of B, then B is said to be the superset of A. This relation is written as B A


which reads B contains A or B is superset of A.If A is not a subset of B then it is written as A B or B A

Proper Subset:If B is a subset of A and B is not equal to A then B is said to be a proper subset of A.
Note - Some authors have made a distinction in the symbols used for subset and proper subset. If B is a subset
of A, they write it symbolically as B A and if B is a proper subset it is written as B A.
For example:

If A = {1, 3, 4, 5, 6} and B = {3, 6, 5}, then

B A and B A,

So it is written as B A i.e. B is a proper subset of A.


The null set is a proper subset of every other set except itself.

Comparability:Two sets A and B are said to be comparable if A B or B A or A = B


i.e. if one of the two set is a subset of the other set.
A and B are not comparable if A B and B A and A B.In this case there will be at least one element in each set
which is not a member of the other set.
Examples of comparable and not comparable sets.
(1) If A = {x, y, z} and B = {a, y, x, b, z} then A and B are comparable as A is a sub-set of B.
(2) If A = {2, 3} and B = {3, 4, 5}, then A and B are not comparable because neither A is a sub set of B nor is B a sub
set of A.

Disjoint Sets: If no element of A is a member of B and no element of B is a member of A, then A and B are said to
be disjoint sets.In such a case the two sets A and B have no elements in common.
Example of disjoint sets. The following pairs of sets A and B are disjoints sets.
A = {1, 3, 5} and B = {2, 4, 6},
A = {x : x is positive} and B = {x : is negative},
(1)
and

A = {x : x is an Indian man}.
B = {x : x is an Indian woman}.

Set of sets or Family of sets:It is a set of elements which are sets themselves. For example the set A = {{2, 3}, {3},
{5, 6, 7}, } is a set whose members {2, 3}, {3}, {5, 6, 7} and are sets themselves. We say that A is a set of sets or
family of sets or class of sets.
Example of set of sets:A = {{1, 3, 5}, {2, 4, 6, 8}, {9}} is a family of sets.

Universal Set or Universe of Discourse:The set of which all sets under investigation are sub-sets is called Universal
set. The universal set is generally denoted by U.
Example of Universal Set
1. All the person in the world constitute the universal set for the purpose of population studies.
2. In the study of plane geometry, all the points in the plane constitute a universal set.
Power Set:The set containing all the sub-sets of a given set A as its elements is called a power set of A and is
A
denoted by 2 or P(A). P(S) = {T : T S}, and S both P(S).
Examples: If A = {3, 4}, then all the sub-sets of A are {3, 4}, {3}, {4},
A

Hence its power set is 2 ={ {3, 4}, {3}, {4}, }


Number of element in power set :If the number of elements in any set is n then the number of elements in its
n
n
n
n
n
power set is
Cn + Cn-1 + Cn-2 + + C1 + 1 = 2 .

1.3 Set Operations :Like the processes of addition, subtraction, multiplication and division in the number
systems, there are certain fundamental operations on sets which are described below:

Union of sets: The Union of two sets A and B is the set of all elements which belong to A or to B or to both A and
B. The union of A and B is denoted by A B and is read A union B
The union of A and B can also be written as A B = { x : x A or x B}.
Example . If A = {1, 2, 3, 4} and B = {5, 2, 4, 6} then A B = {1, 2, 3, 4, 5, 6}.

Intersection of sets The intersection of two sets A and B is the set of elements which belong to A as well as to B
and it is denoted by A B.
It is the set of all elements which are common to A and B.
The intersection of A and B is also written as A B = { x : x A and x B}
Examples of Intersection of sets:
If A = {3, 4, 6, 8} and B = {2, 6, 8, 4} then

A B = {4, 6, 8}

Difference of Sets : The difference of two sets A and B is the set of elements which belong to set A but do not
belong to set B. This is denoted by A B or A ~ B or A \ B
and is read A difference B or A minus B
A B can be written as A B = {x | x A, x B}.

It is also called the complement of B with respect to A


Examples of difference of two sets :
If A = {1, 3, 5, 7, 9}, and B = {3, 4, 5, 8} then A B = {1, 7, 9}.

Complement of a set: The complement of a set A is the set of elements which do not belong to A. It is, therefore,
c
the difference of the universal set and the set A. The complement of a set A is denoted by A or A .
Examples of Complement of a set :
If P = {x | x is odd natural number}
and = {x | x is natural number}
then A = {x | x is even natural number}.
If = {1, 2, 3, ..9, 10} and
then

A = {2, 4, 6, 8, 10}

A = - A = {x | x , x A}
= {1, 3, 5, 7, 9}

Symmetric difference of two sets : Symmetric difference of two sets A and B is given by
A B or A B = (A B) (B A)
Similarly, B A or B A = (B A) (A B),
Hence

AB=BA

It is the set of all elements that belong to A or to B but not to both A and B

1.4 Laws of Algebra of Sets:

Idempotent laws
1.

a.

AA=A

b.

AA=A

Associative laws

2.

a.

(A B) C = A (B C)

b.

(A B) C = A (B C).

Commutative laws
3.

a.

AB=BA

b.

AB=BA

Distributive laws
4.

a.

A (B C) = (A B) (A C)

b.

A (B C) = (A B) (A C)

Identity laws
5

a.

A=A

b.

AU=A

a.
b.

AU=U
A=

Involution law
7.

(A) = A

Complement laws
8.

a.

A A = U

b.

A A =

a.

U =

b.

= U

De Morgans law
10

a.

(A B) = A B

b.

(A B) = A B

11

a.

A (B C) = (A B) (A C)

b.

A (B C) = (A B) (A C)

If E is any identity of algebra of sets, then the dual E of E is the expression obtained by replacing each occurrence
of , , U and in E by , , and U respectively [All bs are duals of as] known as principle of DUALITY.

1.5

Other Important Results in Set Theory

1.
2.
3.
4.

Number of elements belonging to A or B or both = n (A B)


Number of elements not belonging to either of the two = n (A B)
Number of elements belonging to both A & B = n (A B)
n (A B) = n (A) + n (B) n (A B)
= n (A) + n (B),
if n (A B) =

5.
6.
7.
8.

n (A B) = n (A) n (A B) = number of elements belonging to A only


n (B A) = n (B) n (A B) = number of elements belonging to B only
n (A B) = n (A B) + n (B A) + n (A B)
n (A B) = n (A) + n(B) n (A B)
n (S) n (A B) = n (B A) + n (A B) n (A B).

9.

n (A B) = n (S) n (A B) [Neither belong to A nor to B i.e. belonging to neither of the two.]


c

10.

=U

11.

U =

12.

AA =U

13.

AA =

14

(a)

(b)

15.

16.

AB=A=&B=
AB=AB
c

(c).

AB=AB

(a)

x A and x B x A B

(b)

x A or x B x A B

(c)

x A or x B x A B

(d)

x A and x B x A B
c

ABB A

17.

A (B C) = (A B) (A C)

18.

A B = A B and B A = B A

Example: Prove that (A B) C = A (B C)


Solution Let S = (A B) C and T = A (B C) we have to prove that S = T
Let x S,

then

x (A B) or x C

If x (A B),

then

x A or x B.

Hence x S implies that

x A or x (B C)

i.e. x A (B C)
or x T.
\ S T.

.(1)

again let y T, then y A or y (B C).


if y (B C),

then

y B or y C,

Hence y T

implies that

i.e.

y (A B) or y C

or

y (A B) C

or

y S.

T S.

or

(A B) C = A (B C).

y A or y B or y C

.(2)

Note - Similarly, we can prove that


(A B) C = A (B C)

1.6

VENN DIAGRAM

Geometrical figures (diagrams) used to represent sets are called Venn-Diagrams.


John Venn, an English Mathematician developed the idea of using geometrical figures to represent sets.
Another mathematician Euler also used diagrams to represent sets and therefore these diagrams are also called
Venn-Euler diagrams.
In a Venn diagram, generally, the universal set is represented by a rectangle and all other sets under consideration
by bounded areas (generally, a circle) within the rectangle.

The adjacent diagram shows a Universal set U.

The adjacent diagram shows two


disjoint sets A and B, A B = .

The following figures show that the sets A and B are overlapping sets and the shaded portion represents A B.

In the following figures the shaded portion represents A B.

In the following figures the shaded portion represents the complement of A i.e A

The following diagrams represent subsets,

(i)

(ii)

U
B

(B A)

(A B)

Example: Given universal set U = {a, b, c, d, e, f, g}


A = {b, c, d e} and B = {a, b, e}.
Draw Venn-diagram to represent the relationship between the given sets.
Use the diagram to find the following sets :
(i) A

(ii) A B

(iii) B A

U
Solution. The given sets A and B are overlapping sets,
as A B = {b, e}.

A
d

B
b

Therefore, the Venn-diagram representing

the relationship between the given sets will be as


shown alongside :
(i)

A = {elements of universal set, which are not in A}


= {a, f, g}

(ii) A B = {elements of A, which are not in B}


= {c, d}
(iii) B A = {x : x B and x A}

= {a}

Example : If n (U) = 60, n (A) = 27, n (B) = 19 and n (A B) = 31 : Use Venn-diagram to find :
(i) n (A B)

(ii) n (A B)

Solution
Let n (A B) = x
Since n (A) = 27, \ n (A B) = 27 x
[ n (A B) = n (A) n (A B)]

U(60)
A(27)

B(19)

Since n (B) = 19, \ n (B A) = 19 x


[since (B A) = n (B) n (A B)]
As shown in diagram, n (A B) = 31 is written outside A and B.

27 x

19 - x

Since n (U) = 60,


\

27 x + x + 19 x + 31 = 60,

x = 17

Therefore,
(i) n (A B) = x = 17
(ii) n (A - B) = 27 x = 27 17 = 10

31

Example: It is found that out of 100 students, 18 can drive neither a Scooter nor a Car, while 25 can drive both
these and 55 of then can drive a Scooter. How many can drive a Car.
Solution : Let A and B denote the set of students who can drive scooter and car respectively
18 or 100 n (A B) = 18
So, n (A B) = 82. Now n (A B) = n (A) + n (B) n (A B)
giving

82 = 55 + n (B) 25 giving n (B) = 52

18

55 - 25 25
= 30

Example: The operation Union () is distributive over the operation of intersection ()


X (Y Z) = (X Y) (X Z)

or
Proof. Let x X (Y Z)
x X or x (Y Z)

x X or (x Y and x Z)
(x X or x Y) and (x X or x Z)
x (X Y) and x (X Z)
x (X Y) (X Z).
So

X (Y Z) (X Y) (X Z)

Similarly let

(1)

y (X Y) (X Z)

(y X or y Y) and ( y X or y Z)
(y X or y Y) and y X or y (YZ)
y X (Y Z)
So

(X Y) (X Z) X (Y Z)

(2)

n (U) n (A B) =

From (1) and (2)


X (Y Z) = (X Y) (X Z) or X (Y Z) (X Y) (X Z)

Example: To prove that


(i)

X (Y Z) = (X Y) (Z X)

Proof :
Let x X (Y Z)
x X or x (Y Z)
x X or (x Y and x Z)
(x X or x Y) and (x X or x Z)
x (X Y) and x (X Z)
x (X Y) and x (X Z)
x (X Y) and x (Z X)
x(XY) - (Z X)
again let y (X Y) (Z X)
X (Y Z) (X Y) (Z X)

..(1)

y (X Y) and y (Z X)
(y X or y Y) and (y Z and y X)
y X or (y Y and y Z)
y X or y (Y Z)
y X (Y Z)
(X Y) (Z X) X (Y Z) (2)
From (1) & (2) we have
X (Y Z) = (or ) (X Y) (Z X)

Example: To prove that


X (Y Z) = (X Y) (X Z)
X (Y Z) (X Y) (X Z)

Proof:
and

(X Y) (X Z) X (Y - Z)
x X (Y Z)

Let
x X and x (y Z)

x X and (X Y or x Z)
(x X and x Y) or (x X and x Z)
x (X Y) (X Z)
X (Y Z) (X Y) (X Z)

so

..(1)

y (X Y) (X Z)

again let

y (X Y) or y (X Z)
(y X and y Y) or (y X and y Z)
y X and (y Y or y Z)
y and y Y Z from note 4 on page 238
y X (Y Z)
So

(X Y) (X Z) X (Y Z)

.(2)

From (1) and (2), X (Y Z) = (X Y) (X Z).

1.7 Some More Results on Set Theory

1.

To prove
If A B and B C; then A C
Proof: Let x A x B (as A B)

x C (as B C)

So any element of A is also on element of C Hence A C.


2.

To prove A A B and B A B
Proof: Let x A x A B
Hence A A B
Similarly B A B

3.

To prove
(i) A A = A

(ii) A = A

(iii) A U = U
Proof: (i) We know

AAA

Also

xAAxA

So

AAA

Hence

AA=A

(ii)

AA
x A x A or

Also

4.

xA

So

AUU

Hence

A U = U.

To prove If A B then A B = B
Proof:

BAB

Also

x A B x A or x B

So
Hence
5.

x B as A B.
ABB
AB=B

To prove If
Proof: Let

A B then A B = A
x A B x A and x B
x A as A B

So

ABA

again let

y A y B (as A B)

so

y A B.

i.e.

AAB

.(1)

(2)

From (1) and (2), A B = A


6.

To prove (A) = A
Proof:

x A x A x (A )

so

A (A)

Again let

y (A ) y A y A

So

(A) A

.(1)

.(2)

From (1) & (2)


7.

(A ) = A

To prove
(i) =
Proof: Let
so
Again let
So

x x x

.(1)

y y y

(2)

From (1) and (2)


= .

1.8 Cartesian Product of Sets :Before explaining Cartesian Product of sets, we shall define ordered pair

Ordered Pair :An ordered pair, generally denoted by (x, y), is a pair of elements x and y of two sets, which is
ordered in the sense such that (x, y) (y, x) when x y and x and y are known as the first and second coordinates
of the ordered pair (x, y). The ordered pairs (3, 5) and (5, 3) are different because they represent different point in
the coordinate plane.

Cartesian Product of two sets:The Cartesian product of two sets A and B is the set of all those ordered pairs whose
first coordinate is an element of set A and the second coordinate is an element of set B. It is denoted by A x B and is
read as A cross B or product set of A and B.
Thus
A B = {(x, y) : x A and y B}
Similarly
Therefore

B A = {(x, y) : x B and y A}
ABBxA

Examples: If A = {2, 3, 5} and B = {3, 4}, then


A B = { (2, 3), (2, 4), (3, 3), (3, 4), (5, 3), (5, 4)}
and

B A = { (3, 2), (3, 3), (3, 5), (4, 2), (4, 3), (4, 5)}

In a similar way, the Cartesian product for n sets A1, A2, . . . . . . . . An is defined as
A1 A2 . . . . . . . . . An = { (x1, x2, . . . . . . ., xn) : x1 A1, x2 A2, . . . . . .xn An}

Example : If A = {1, 2}, B = {x, y, z}, z = {3, 4}, find A B c.


Solution

3
x
4
3
1

y
4

3
z

4
ABC=

3
x
4
3
2

3
z

4
= { (1, x, 3), (1, x, 4), (1, y, 3), (1, y, 4), (1, z, 3), (1, z, 4),

(2, x, 3), (2, x, 4), (2, y, 3), (2, y, 4), (2, z, 3), (2, z, 4)}

Example : If A, B, C be three non empty sets, then prove that:


A (B C) = (A B) (A C)
Solution:- A (B C) = {(x, y) : x A and y (B C)}
(by def. of Cartesian product of sets)
= {(x, y) : x A and (y B or y C)}
= {(x, y) : (x A and y B) or (x A and y C)}
(distribution of and over or)
= {(x, y) : (x, y) A B or (x, y) A C}
= (A B) (A C)

Example :- Prove that


A (B C) = (A B) (A C)
Solution

A (B C) = {(x, y) : x A and y (B C)}


= {(x, y) : x A and (y B and y C)}
= {(x, y) : (x A and y B) and (x A and y C)}
= {(x, y) : (x, y) (A x B) and (x, y) (A x C)}
= (A B) (A C).

1.9 Partitions or Quotient Sets

Let S be a non empty set, A partition of S is a subdivision of S into non overlapping, non empty subsets.
Or a partition of S is a collection {Ai} of non empty subsets of S such that
(a) Each a in S belongs to one of the Ai.
(b) The sets of {Ai} are mutually disjoint i.e. if
Ai Aj then Ai Aj =

Venn diagram of set S


into five cells A1, A2, A3,
A4, A5

A1

A3
A2

Subsets in a partition are called Cells or blocks

Example :- Consider following collection of subsets of


S = {1, 2, 3, 4, 5, 6, 7, 8, 9}

(i)
(ii)
(iii)
(iv)
(v)
(vi)
(vii)
(i)
(ii)
(iv)

[{1, 3, 5}, {2, 6}, {4, 8, 9}]


[{1, 3, 5}, {2, 4, 6, 8}, {5, 7, 9}]
[{1, 3, 5}, {2, 4, 6, 7}, {8, 9}]
[{1, 3, 6}, {2, 8}, {5, 7, 9}]
[{1, 5, 7}, {2, 4, 8, 9}, {3, 5, 6}]
[{2, 4, 5, 8}, {1, 9}, {3, 6, 7}]
[{1, 2, 7}, {3, 5}, {4, 6, 8, 9}, {3, 5}]

is not a partition of S since 7 S does not belong to any of the sub sets.
is not a partition of S since {1, 3, 5} and {5, 7, 9} are not disjoint.
is not a partition of S since 4 S does not belong to any cell.

(v)
is not a partition of S since 5 S belongs to two distinct cells.
(iii) & (vi) & (vii) is a partition

1.10 Index Set

If T is a non empty set and to each element t T, there corresponds a set Ct, then we say that each t T indexes a
Ct and the set T used in this sense is called an Index set.
The collection A of all these sets is called the indexed family of set.
Symbolically A = {At : t T}
Where At is a set corresponding to an element t T (for all t)
Example : Let the indexed set T = {a, b, c, d} and corresponding to each element a, b, c, and d we have the sets
Ca = {2, 3},

Cb = {2, 3, 4, 5},

Cc = {4, 5, 6},

Cd = {2, 4, 6, 8}

then the indexed family of set A = {Ca, Cb, Cc, Cd}

1.11 Relation : Let A denote the set of all living human males and B denote the set of all living human females,
then we can define a relation R (father) between the two sets A and B. If x A and y B, then x is related to y by
the relation R if x is the father of y.
This relation is written as x R y. Here R is a relation from A to B (because any element or member of A can
be the father of an element or member of B and not vice versa).
Similarly we can define a relation R1 from A to B so that x R1 y means that x is a son of y.
Thus, if A and B are two non empty sets then the set of ordered pairs (x, y) such that x A and y B and
the first coordinate of every ordered pair of the set is related to the second coordinate according to a given
relation, then the set of ordered pairs is called a relation from A to B. Thus the relation R from A to B is a subset of
A B. We write it x R y or (x, y) R.
Symbolically, if R is a relation from A to B then
R = {(x, y) : x A, y B and x R y}
x R y means that x is related to y according to the relation defined.

It should be noted that the set of ordered pairs ( which is a subset of A B) is called the relation and not the verbal
phrase, that defines the relationship between the two elements x and y.

Example :- If A = {2, 3, 4} and B = {p, q}

then A B = {(2, p), (2, q), (3, p), (3, q), (4, p), (4, q)}

Now any subset of A B can be a relation.


Thus R = {(2, p), (3, q), (4, p)} is a relation from A to B.
Here 2Rp, 3Rq, 4Rp i.e. first coordinate of every ordered pair bears the same relationship (defined by R) with the
second coordinate of the corresponding ordered pair in R.
Example :- If A = {1, 5, 6} and B = {2, 6, 7} then find the relation from A to B defined by is less than.
Solution A B = {(1, 2), (1, 6), (1, 7), (5, 2), (5, 6), (5, 7), (6, 2), (6, 6), (6, 7)}
The required relation R A B and R shall contain those ordered pairs of A B in which the first coordinate x is
less than the second coordinate y of the corresponding ordered pair i.e. x R y.
Therefore R = {(1, 2), (1, 6), (1, 7), (5, 6), (5, 7), (6, 7)}

R relative set of an element:If R is a relation from A to B and x A, then we define R (x), the R relative set of x
to be the set of all y belonging to the set B with the property that x is R related to y symbolically, R(x) = {y B : x
R y}.
Similarly if A1 A then R(A1), the R relative set of the set A1 is the set of all y belonging to B with the property that
x is R related to y for some x in A1 , symbolically,
R(A1) = {y B : x R y for some x in A1}
R(A1) is the union of the sets R (x) where x A1.

Example:- If A = {a, b, c, d}, and R = {(a, a), (a, b), (b, c), (c, a), (d, c), (c, b)}
Then R(a) = {a, b}, R(b) = {c}
If A1 = {c, d} then R(A1) = {a, b, c}.

Domain and Range of a relation

The set of first coordinates of every element (ordered pair) of R is called the domain of R and the set of
second coordinates of every element (ordered pair) of R is called Range of R. Symbolically we can write: If R is a
relation from A to B, then domain of R = d (R) = {x : x A and (x, y) R}
and range of R = r (R) = {y : y B, (x, y) R}
If A = B, and R is a relation in A then
d (R) = {x : x A and (x, y) R}
r (R) = {y : y A and (x, y) R}

Example :- If R = {(1, r), (2, s), (3, r)}


then

d (R) = {1, 2, 3}
r (R) = {r, s}

Relation on A: If R is a relation from a set A to itself i.e. if R is a subset of A A or A , then we say that R is a
relation on A or a relation in A. It is also called a binary relation on A, Symbolically R = {(x, y) : x, y A and x R y}
Example :- Let A = {1, 2, 3, 4}. Find the relation on A (i.e. from A to A) defined by
a b (a divides b).
Solution Here R A A shall contain all those elements (ordered pairs) (a, b) of A A in which the first coordinate
a of the ordered pair divides the second coordinate b of the same ordered pair. Thus
R {(1, 1),(1, 2),(1, 3),(1, 4),(2, 1),(2, 2),(2, 3),(2, 4),(3, 1),(3, 2),(3, 3),(3, 4),(4, 1),(4, 2),(4, 3),(4, 4)}
= {(1, 1), (1, 2), (1, 3), (1, 4), (2, 2), (2, 4), (3, 3), (4, 4)}

Inverse relation

-1

If R is a relation from a set A to a set B, then the inverse of R (denoted by R ) is the relation from the set B
to set A which contains all the elements (ordered pairs) of R in which first and second coordinates of each ordered
-1
pair are interchanged. It means that R shall consist of all those ordered pairs which if reversed shall belong to R.
Symbolically
-1

R = {(y, x) : (x, y) R}
Example :- Inverse of the relation R = {(2, x), (3, y), (5, z)} is given by
-1

R = {(x, 2), (y, 3), (z, 5)}

-1

It is evident from the definitions of R and R that


-1

domain of R = range of R
-1

range of R = domain of R
-1

Also if R is a relation on A i.e. R A A, then R is also a relation on A.

Total number of distinct relations from a set A to a set B:Let the number of elements in the sets A and B be m and
n respectively. Then the number of elements in the product set A B is mn. Hence the number of elements in the
mn
mn
power set of A B shall be 2 . It means A B has 2 distinct subsets. Since every subset is a relation from A to B,
mn
the number of different relations from A to B shall be 2 .
Example :- Find number of relations from A = {a, b, c} to B = {1, 2}.
Solution n (A B) = 3 2 = 6
6

Therefore the number of subsets in A B = 2


6

and the number of relations in A B = 2

1.12

Different Methods of representation of a relations:

There are five main methods to represent a relation R from a set A to set B.
Roaster Method :In this method all the elements (ordered pairs) of the relation are enclosed within braces.
Example :- Let A = {1, 2, 3} and B = {x, y, z}
then R = {(1, y), (1, z), (3, y)}.

Matrix Method (for finite set A)


A rectangular array is formed whose rows are labeled with the elements of set A and whose columns are
labeled with the elements of set B. If an element x A is R related to the element y B, then a 1 is written
against x in the column of y (i.e. in the cell (x, y)). If x A is not related to y B, then a 0 is written in the cell (x, y).
The array is called the matrix of the relation or relation matrix M.
Entries M(x, y) =

if xRy

0 if x

y.

Example :- The relation R = {(1, y), (1, z), (3, y)} from the set A = {1, 2, 4}, to set B = {x, y, z} can be represented in
matrix form as follows
Entries

Arrow diagram:The elements of sets A and B are written in two disjoint plane figures (circles, rectangles, discs etc)
and then arrows are drawn from x A to y B if x is Rrelated to y.
Example:- The same relation R = {(1, x), (1, z), (3, y)} from set A = {1, 2, 3} to set B = {x, y, z} has been represented
below by arrow diagram

Digraph of a relation on sets:When a relation is from a finite set A to itself then it can be represented by a digraph
also. First the elements of the set A are written down. Then arrows are drawn from each element x to each
element y (x, y A) whenever x is R related to y.

Example :- Let the set A = {4, 5, 6, 7} and the relation R on A = {(4, 5), (5, 5), (6, 5), (6, 7), (7, 4), (7, 6)} this relation
can be represented by a digraph as shown below-

Set Builder form: In this method the rule that associates the first and second coordinates of each ordered pair is
given e.g. Relation from A to B given by
R = {(x, y) : x A and y B, x < y}
where A = {1, 2, 4}, B = {2, 3, 5}

Composition of Relations: If A, B and C are three non empty sets and R and S are the relations from A to B and B to
C respectively, then R A B and S B C.Then we define a relation from A to C denoted by R o S ( or S o R as
used by certain authors) given by
R o S = {(x, z) : there exists some y B such that (x, y) R and (y, z) S}
This relation is called a composition of R and S or a composite relation of R and S.
Example :- Let A = {3, 4, 5, 6}, B = {p, q, r, s}, C = {x, y, z} and also
R = {(3, p), (4, s), (5, p), (5, q), (5, s)} and S = {(q, x), (q, z), (r, y), (s, z)}
Find composition of R and S.
Solution:- From the arrow diagrams of R and S given in the figure, there is an arrow from 4 to s followed by an
arrow from s to z. Thus
4Rs and sSz therefore 4 (R o S)z or 4 (S o R)z
i.e. there is a path from 4 to z
similarly there is a path from 5 to x and 5 to z i.e
5(R o S)x and 5(R o S)z
No other element of A is connected to C.
Hence R o S =[(4, z), (5, x), (5, z)}

Alternative Method to solve the same question by Matrix Method


Representing the two relations R and S by matrix MR and MS respectively, we have

MR =

q r

0 0

MS =

Multiplying the two matrices MR and MS we get

MR . MS = MRoS =

Non zero entries in this matrix tell us which elements are related in R o S
Therefore R o z ={(4, z), (5, x), (5, z)}
Example :- R and S are relations on A = {1, 2, 3}
R = {(1, 1), (1, 2), (2, 3), (3, 1), (3, 3)
S = {(1, 2), (1, 3), (2, 1), (3, 3)}
2

then find R o S and S (=S o S)


Solution (a) To find R o S,
R o S : F or each pair (a, b) R find all pairs (b, c) S. Then (a, c) R o S
so R o S = {(1, 2), (1, 3), (1, 1), (2, 3), (3, 2), (3, 3)}
or use diagrammatic or matrix method.

(b) S = S o S = {(1, 1), (1, 3), (2, 2), (2, 3), (3, 3)}
A

Use of Boolean Matrix to find Composition of Relation

Boolean Matrix and Boolean product: A Boolean matrix is an m x n matrix


whose entries are either zero or one. Suppose A = [aij] is a m x p Boolean
matrix and B = [bij] is a p x n Boolean matrix. The Boolean product of two
Boolean matrices A and B denoted by A B, is the m n Boolean matrix C =
[cij] defined by
cij =

if aik = 1 and bkj = 1 for some k, 1 k p

otherwise

Multiplication is similar to ordinary matrix multiplication which is explained below :


th

th

1. Select say i row of A and j column of B and arrange them side by side.
2. Compare corresponding entries. If even a single pair of corresponding entries consist of two 1s, then cij = 1,
otherwise cij = 0

For example if A =

then A B =

and B =

Matrix representation of composition of relation

If R is a relation on a set A and represented by n x p Boolean matrix MR, S is another relation on A


represented by p x m Boolean matrix MS, then the composite relation RoS represented by MR o S is equal to the
Boolean product MR RS
i.e. MRoS = MR MS

For example if A = {x, y, z} and R and S are relation on A whose Boolean matrix are given by

MR =

Ms =

then the composite relation RoS is represented by the Boolean matrix MRoS given by

MRoS = MR MS =

= {(x, x), (x, z), (y, x), (y, y), (y, z), (z, y), (z, z)}

Theorem:- Let A, B, C, D be sets, R1 is relation from A to B, R2 is a relation from B to C and R3 is a relation from C to
D, then
(R1oR2)oR3 = R1o(R2 o R3)
The relation (R1 o R2) o R3 is determined by Boolean matrix M(R1 o R2) o R3 .(1)
and the relation R1o(R2 o R3) is determined by MR1o (R2 o R3) (2)
Now M(R1 o R2)oR3 = M(R1 o R2) MR3 = (MR1 MR2) MR3 ..(3)
and MR1 o(R2 o R3) = MR1 MR2oM3 = MR1 (MR2 MR3) (4)
We know that Boolean matrix multiplication is associative.
Hence the R.H.S of (3) = R.H.S of (4)
or L.H. S. of (3) = L.H.S. of (4)
or M(R1oR2)oR3 = MR1 o(R2oR3)
Thus (R1oR2)oR3 = R1 o (R2 o R3)
-1

-1

Theorem : If R and S are the inverse of the relations R and S respectively, then
-1

-1

-1

-1

-1

-1

(RoS) = S oR or (SoR) = R oS

Proof:- Let A, B and C be three non empty sets such that R is a relation from A to B and S is a relation from B to C.
It means that R A B, S B C RoS A C
-1

Therefore (RoS) C A
-1

Now (z, x) (RoS) (x, z) (RoS)


$y B : (x, y) R, (y, z) S [ by def. of composition]
-1

-1

-1

-1

(y, x) R , (z, y) S
(z, y) S , (y, x) R
-1

-1

(z, x) S oR
-1

[by definition of composition]


-1

-1

It means that (z, x) (RoS) (z, x) S oR


-1

-1

-1

Therefore (RoS) S oR

.(1)
-1

-1

-1

Similarly we can prove that S oR (RoS) .(2)


Hence by (1) & (2) it is proved that
-1

-1

-1

(RoS) = S oR

Identity Relation in a set :Let A be a non empty set and IA be a relation in A defined such that IA = {(x, y) : x, y A
and x = y}, then IA is called an identity relation in A. IA shall be a set of all ordered pairs (x, y) belonging to A x A for
which x = y
Example :- If A = {3, 4, 5}, then IA = {(3, 3), (4, 4), (5, 5)}
It is clear from here that domain of IA = range of IA = A

Universal Relation: A relation R in a set A is called universal relation if R = A x A


For example if A = {1, 2, 3}, then
R = {(1, 1), (1, 2), (1, 3), (2, 1), (2, 2), (2, 3), (3, 1), (3, 2), (3, 3)} is a universal relation.

1.13.
Properties of Relations (or classification of Relations) There are several important properties that are
used to classify relations on a set, We shall discuss some of these important properties and corresponding classes
of relations on a set.

1.13.1 Reflexive and irreflexive relations

Reflexive:If A is a non empty set and R is a binary relation on A, then R A x A. The relation R on a set is called
reflexive if every element of A is R-related to itself i.e. xRx, " x R. or (x, x) R " x R
Example :- Let A = {2, 3, 4, 5} and R = {(2, 2), (2, 3), (3, 2), (3, 3), (4, 4), (5, 2), (5, 5)}
+

Example :- Let I be the set of positive integers and R is defined as divides (i.e. a|b). Is this relation R reflexive?
+

Solution Since x|x " x I i.e every element of the set divides itself or every element of I is related to itself by the
+
relation R (i.e. xRx " x I ), the given relation is reflexive.

Irreflexive or Anti-Reflexive relation: A relation is irreflexive if x


related to itself.

x, " x A i.e no element of the set A is R-

Example :- If R = {(x, y) A x A | x y}, then R is irreflexive with respect to the relation defined by , since (x, x)
R"xA
Example :- If R = f A x A, then R is not reflexive since (x, x) R " x A (as empty set has no elements) But R is
irreflexive.

1.13.2 Symmetric, antisymmetric and asymmetric relations

Symmetric relation:If A be a non empty set and R be a binary relation on A such that xRy yRx; " (x, y) R
i.e. (x, y) R (y, x) R, then R is called a symmetric relation in A.
It means that a relation R on A is said to be symmetric if (y, x) R whenever (x, y) R for x, y A. In a
symmetric relation x is related to y (xRy) implies that y is related to x (yRx)
More precisely a relation R on a set A is symmetric if whenever xRy then yRx (x, y A). In a symmetric relation
there must not exist a pair of distinct elements x, y A such that xRy but y R x. i.e., R is not symmetric if we have a
pair of distinct elements x and y A such that xRy but y x i.e. (x, y) R but (y, x) R.

Example:- If A = {2, 3, 4}, then the relation given by


R1 = {(2, 2), (2, 3), (2, 4), (3, 3), (3, 4), (4, 4), (3, 2), (4, 2), (4, 3)} is a symmetric relation on A. But the relation given
by R2 = {(2, 2), (2, 3), (2, 4), (3, 3), (3, 4), (4, 4)} is not a symmetric relation in A, since (2, 3) R while (3, 2) R and
(2, 4) R but (4, 2) R, (3, 4) R but (4, 3) R.
Example :- If L is a set of all straight lines on a plane and R is a relation on L defined as:
R = {(x, y) : x, y L and x ^ y}, then R is a symmetric relation in A, since if x ^ y and (x, y) R, then y is also ^ x and
(y, x) R or xRy yRx

Antisymmetric relation : Let A be a set and R be a relation such that


A relation R on A is antisymmetric if whenever xRy and yRx, then x = y. In an antisymmetric relation
whenever x y, then either xRy or yRx. It means that in an antisymmetric relation there must not exist any pair of
distinct elements x and y (x y; x, y A) such that xRy ((x, y) R) and yRx ((y, x) R) i.e. R is not antisymmetric if
there exists a pair of distinct elements x and y in A (x y) such that xRy and yRx [i.e. (x, y) R and (y, x) R]
Example :- If A = {1, 2, 3, .} and R = {(x, y) : x, y A and x | y}, then R is an antisymmetric relation, since there
are no pairs of distinct elements x and y in A such that x/y and y/x. (Note that x and y are distinct element) or xRy
and yRx x = y i.e. If x, y R, then x/y and y/x is possible only if x = y.

Caution

It should be noted that the terms symmetric and antisymmetric are not opposite. A relation can have both of these
properties or may lack both these properties as we shall see in the examples given ahead in this section.
If a relation contains some pair of the form (x, y) where x y, then such a relation can not be both symmetric and
antisymmetric.

Asymmetric relation :A relation R on a set A is asymmetric if whenever xRy i.e (x, y) R, then y x i.e. (y, x) R.
Similarly R is not asymmetric if there exists a pair of elements x and y in A such that xRy and yRx i.e. (x, y) R and
also (y, x) R (even for x = y)
Example :- Let A be the set of positive integers and R = {(x, y) A x A : x < y}
[Here R is the relation less then] then we see that if x < y then y
asymmetric.

x i.e. if xRy then y

x. so the relation is

Example :- Let A denote the set of positive integers and R = {(x, y) A x A : x divides y}. If we take x = y=5 then xRy
and yRx, therefore R is not asymmetric.
Relationship between symmetric, asymmetric or antisymmetric relation to the matrix of the corresponding
relation :
1. If MR = [mij] is the matrix of a symmetric relation R, then MR shall be a symmetric matrix i.e. MR = MRT and each
pair of entries, symmetrically placed about the main diagonal are either both 0 or both 1 as shown in the following
matrix.
0

2. If MR = [mij] is the matrix of an asymmetric relation, then the main diagonal of MR consists entirely of zeros as
shown below

3. If MR = [mij] is the matrix of an antisymmetric relation, then if i j, then mij = 0 or mji = 0 as shown below:

Digraphs of symmetric, asymmetric and antisymmetric


relations
1.
2.
3.

Digraph of a symmetric relation:- In the digraph of a symmetric relation, if there is an edge from vertex i
to vertex j then there will be an edge from vertex j to vertex i.
Digraph of an asymmetric relation:- Such a diagraph can not simultaneously have an edge from vertex i
to vertex j and an edge from vertex j to vertex i. There can be no cycles of length 1 .
Digraph of an antisymmetric relation:- In such a graph, for different vertices i and j there cannot be an
edge from vertex i to vertex j and an edge from vertex j to vertex i. No such condition is imposed for i = j
which means that there can be cycles of length 1.

Example :- If R1 and R2 are two distinct symmetric relations on a set A, then prove that R1 R2 is a symmetric
relation on A.
Solution Let (x, y) be any element of R1 R2 then (x, y) R1 R2
(x, y) R1 R2
(y, x) R1 or (y, x) R2 since R1 & R2 are symmetric
(y, x) R1 R2
It means that (x, y) R1 R2 (y, x) R1 R2.
Hence R1 R2 is a symmetric relation on A.

1.13.3Transitive Relation:A relation R on a set is transitive if xRy and yRz xRz. It means that if (x, y) R and (y, z)
R then (x, z) R
Similarly a relation R on a set A is not transitive if there exists x, y and z in A such that xRy and yRz, but x
such x, y, z does not exist, then R is transitive.

z. If

Example :- If A = {2, 3, 4} and R = {(2, 3), (2, 4), (3, 4)} then R is a transitive relation in A, since 2R3 (i.e. (2, 3) R ),
3R4 (i.e. (3, 4) R) and 2R4 (i.e (2, 4) R)
Example :- If A is a set of straight lines in a plane then the relation R defined by || (is parallel to ) is transitive, since
for x, y, z A, if x || y or xRy and y || z or yRz, then x || z or xRz.

Matrix of a transitive relation: If MR is the matrix of a


relation, then R is transitive relation if (MR) 2 has a 1 in any
position then MR must also have a 1 in the same position.
Example:- If the matrix of a transitive relation R defined on a set A = {1, 2, 3} is given by

MR =

then R is transitive, since (MR)


same position.

,
2

= MR and therefore if (MR)

has a 1 in any position, then MR must have 1 in the

Circular Relation :A relation R is said to be circular if (x, y) R and (y, z) R (z, x) R

1.14
Equivalence Relation :A relation R on a set A is said to be an equivalence relation if R is reflexive
symmetric and transitive.Therefore in order to prove any relation on a given set to be an equivalence relation we
shall have to prove that the relation satisfies all the three properties of being reflexive, symmetric and transitive.
Example :- If A is set of all the triangles in a plane and the relation R on A is defined as follows:
R = {(x, y) A x A : x is congruent to y} then prove that R is an equivalence relation.
Proof:- (a) To prove that R is reflexive:- Since x y " x, y A, therefore x x i.e. xRx or (x, x) R. Hence
R is reflexive.
(b) To prove that R is symmetric:- For any x, y A, (x, y) R x y
y = x or (y, x) R

Hence R is symmetric.
(c) To prove that R is transitive:- " x, y, z A, we have (x, y) R and (y, z) R means that
x y and y z
x z or (x, z) R
therefore R is transitive.
Example :- Let L be a set of straight lines in a plane, which one of the following two relations is an equivalence
relation?
(a) R1 = {(x, y) : x, y L and x || y}
(b) R2 = {(x, y) : x, y L and x ^y}
Solution (a) (i) " x L, x is parallel to itself i.e. xRx so R1 is reflexive.
(ii) " x, y L, x || y y || x i.e. xR1y yR1x, so R1 is symmetric.
(iii) " x, y, z L, x || y and y || z x || z i.e xR1y and yR1z xR1z
so R1 is transitive. Therefore R1 is an equivalence relation.
(b) " x L, x is not perpendicular to itself so R2 is not reflexive.
Hence R2 is not an equivalence relation.

Example :- If A = {0, 1, 2, 3, } and R = {(x, y) : x y = 8k, k is an integer}


(xRy iff x y is divisible by 8), then prove that R is an equivalence relation.
Solution " x A, x x is divisible by 8 or x x = 8k i.e. xRx. So R is reflexive.
"x, y A, if x y is divisible by 8, then y x is also divisible by 8 i.e. xRy yRx
So R is symmetric. Again " x, y, z if x y and y z both are divisible by 8, then x z = (x y) + (y z) is also divisible
by 8 i.e xRy and yRz xRz. So R is transitive.
Therefore R is an equivalence relation.

Example :- If A is the set of real numbers and R is the relation on A defined as follows:
R = {(x, y) A x R : x y is an integer}
or xRy iff x y is an integer
Prove that R is an equivalence relation.

Solution Since x x = 0 A "x A, so xRx thus R is reflexive.


Again if x y is an integer, then y x = - (x y) is also an integer. It means (x y) A (y x) A or xRy yRx.
So R is symmetric.
Now let x, y, z A. If (x y) and (y z) both are integers then x z = (x y) + (y z) being sum of two integers is
also an integer. It means that (x y) R and (y z) R (x z) R or xRy and yRz xRz. So R is transitive.
Consequently R is an equivalence relation.

Example :- Let A be the set of all integers and a relation R is defined as


R = {(x, y) : x y (mod m)}, m divide a b. where m is a positive integer. Prove that R is an equivalence relation.
Solution (i) Since x x is divisible by m, therefore x x (mod m) i.e. xRx. Thus R is reflexive.
(ii) If x, y A and x y is divisible by m, then y x = - (x y) is also divisible by m i.e. x y (mod m) y x (mod y)
or xRy yRx So R is symmetric.
(iii) If x, y, z A and also x y as well as y z both are divisible by m then x z =
(x y) + (y z) shall also be divisible by m.
or x y (mod m) and y z (mod m).
x z (mod m)
i.e. xRy and yRz xRz
So R is transitive.
Hence by (i), (ii) & (iii) R is an equivalence relation.
Note:- The relation x y (mod m) read as x is congruent to y mod m can also be written as x = r mod m and y = r
mod m which means that x and y yield the same remainder r when divided by m.

-1

Example :- If R is an equivalence relation on A, then prove that R is also equivalence relation on A.


-1

-1

Solution Let x A. As R is a reflexive relation, (x, x) R which implies that (x, x) R So R is reflexive.
(ii) Let x, y R. As R is symmetric relation. (x, y) R (y, x) R
-1

-1

LHS of (1) (y, x) R & RHS of (1) (x, y) R


-1

So R is symmetric.
(iii) Let x, y, z A, As R is a transitive relation.
(x, y) R and (y, z) R (x, z) R

..(1)

-1

-1

-1

which means that (y, x) R and (z, y) R (z, x) R


-1

-1

-1

or (z, y) R and (y, x) R (z, x) R


-1

So R is transitive.
-1

Hence by (i), (ii) and (iii) R is an equivalence relation.

1.15 Power of a Relation

The power of a relation is defined from the definition of composition of two relations.
n

If R is a relation on the set A, then power R , n = 1, 2, 3 are defined inductively by


1

n+1

R = R; R

= R oR
2

In this way R = RoR; R = R oR = (RoR)oR and so on,

Theorem :- The relation R on a set A is transitive if and only R R for n = 1, 2, 3.


n

Proof:- Let R R for n = 1, 2, 3, .


2

Taking n = 2, R R. Now let (x, y) R and (y, z) R, then by definition of composition (x, z) R [=RoR] as shown
below

RoR = {x,z}

or (x.z) R

Thus (x, y) R and (y, z) R (x, z) R .(1)


2

and R R (given) so (x, z) R ..(2)

From (1) & (2) (x, y) R and (y, z) R (x, z) R.


2

So R is transitive. Thus R R R is transitive. We can use the method of Mathematical induction to prove the
theorem.

1.16 Closures of Relation

Definition Let R be a relation on a set A. The relation R may or may not possess some property P (such as
reflexivity, symmetry, or transitivity). Let S be a relation possessing a property P and containing the set R (i.e. R
S) such that S is a subset of every relation possessing the same property P and containing R. Then the set S is called
the closure of R with respect to the property P.

Example :- Let A = {2, 3, 4} and a relation R defined on A be given by R = {(2, 2), (2, 3), (3, 2), (4, 3)} Clearly R is not
reflexive. We want to make R reflexive by including the minimum number of ordered pairs of A A to R. This can
be done by including only two elements (ordered pairs) (3, 3) and (4, 4) to R. The new relation S so obtained is
given by
S = {(2, 2), (2, 3), (3, 2), (4, 3), (3, 3), (4, 4)}.
Clearly S is reflexive, contains R and is a subset of any other reflexive relation containing R. Therefore S is reflexive
closure of R.
Similarly the symmetric closure of R = {(2, 2), (2, 3), (3, 3), (3, 4), (4, 2), (4, 3)} on A = {2, 3, 4} is given by
S = {(2, 2), (2, 3), (3, 3), (3, 4), (4, 2), (4, 3), (3, 2), (2, 4)} which is obtained on adding (3, 2), (2, 4) to R. Clearly this S
is symmetric, contains R and is a subset of any symmetric relation containing R.
In a similar way transitive closure of R = {(1, 2), (2, 3), (3, 3)} defined on A = {1, 2, 3} is given by S = {(1, 2), (2, 3), (3,
3), (1, 3)}
Note:- It takes a lot of time to find transitive closure of R when A has a large number of elements.

1.17

Equivalence class or Equivalence set

Let R be an equivalence relation on a non-empty set A. Also let a be any element in A. Then the set of all those
elements of A which are R-related to a is called equivalence class or equivalence set of a with respect to R, and is
denoted as [a] or a or Aa. Symbolically
[a] = {x : x A and (a, x) R i.e aRx}

or [a] = {x : x A and (x, a) R i.e xRa}


(aRx = xRa as R is symmetric)

Example :- Let A = {0, 1, 2, 3, ..} and R is an equivalence relation defined as follows:


R = {(x, y) : x y = 3m, m is any integer}, or x y is divisible by 3.
[0] = { x : x A and 0Rx i.e 0 x = 3m}
or {x : x A and xR0 i.e x 0 = 3m}
= {x : x A and x = 0 + 3m, m is an integer}
={0, 3, 6, 9, 12, 15, }
[1] = {x : x A and x R1} = {x : x A and x = 1 + 3m}
= {1, 4, 7, 10, 13, 16, }
[2] = {x : x A and x R2} = {x : x A and x = 2 + 3m}
={2, 5, 8, 11, 14, 17, }
[3] = {x : x A and xR3}= {x : x A and x = 3 + 3m}
= {3, 6, 9, 12, 15, 18, }
Hence we see that [3] = [0]
It can be seen that [4] = [1], [5] = [2] & so on. Thus we have only 3 distinct equivalence classes.

Example :-Let A be a set of all integers and R is an equivalence relation defined by


R = {(x, y) : x y (mod 3) or x y divisible by 3} x, y A
[0] or A0 = {x : x A and 0Rx or xR0}
= {x : x A and x 0 = 3m, m is an integer}
= { x : x A and x = 0 + 3m}
= {, -9, -6, -3, 0, 3, 6, 9, .}
Similarly
[1] or A1 = {x : x A and x = 1 + 3m}
= {.., -8, -5, -2, 1, 4, 7, 10, ..}

[2] or A2 = {x : x A and x = 2 + 3m}


= {, -7, -4, -1, 2, 5, 8, 11, .}
[3] or A3 = {x : x A and x = 3 + 3m}
= {, -9, -6, -3, 0, 3, 6, 9, 12, .} = [0]
[4] = [1], [5], = [2] and so on.
All these equivalence classes satisfy certain properties which have been discussed in the next section.

1.18

Properties of Equivalence classes

Let R be an equivalence relation defined on a non empty set A. If a and b are two arbitrary elements of A, then
(i) a [a], (ii) If b [a] then [b] = [a]
(iii) [a] = [b] if and only if aRb or (a, b) R
(iv) Either the two equivalence classes with respect to R are identical or disjoint i.e. either [a]=[b] or [a] [b] = .
We shall prove each of these four properties as follows:
Proof:- (i) Equivalence class [a] consists of all those elements of set A that are R-related with the elements a A.
a is R related to a (as R is reflexive)
Therefore [a] contain a i.e a [a]
(ii) As b [a], so bRa. (by definition of equivalence class) (1)
Let x be any arbitrary elements of [b], then x [b]
which means xRb

.(2)

From (1) & (2) xRb and bRa .(3)


As R is transitive, xRb and bRa xRa
or x [a]. Thus x [b] x [a].
Therefore [b] [a] ..(4)
Similarly by taking y as any arbitrary elements of [a], we can prove [a] [b] (5)
From (4) & (5)
[a] = [b]

(iii) Let [a] = [b]. we shall prove aRb


we know that aRa (as R is reflexive). So a [a] But as [a] = [b]
therefore a [b] aRb.
Conversely let aRb. We shall prove that [a] = [b]
Suppose x is an arbitrary element of [a]. Then x [a] or xRa. But aRb.
Hence xRb (as R is transitive) or x [b].
or x [a] x [b]
Hence [a] [b]
Similarly by taking of as any arbitrary elements of [b] we can prove that
[b] [a] .(2)
From (1) & (2) [a] = [b]
(iv) If [a] [b] = then it is alright, but if
[a] [b] then we have to prove that [a] = [b]
As [a] [b] , there must exist an elements x such that x [a] [b] which implies that x [a] and x [b]
xRa and xRb
aRx and xRb (since R is symmetric)
aRb [a] = [b] by (iii)

1.19

Relation induced by a Partition of a set

We have already defined Partition of a set in the chapter on Set Theory. In brief partition of a non-empty set A is a
set P of non empty subsets of S (say A1, A2, A3, ..)
i.e. P = {A1, A2, A3, .} such that
(a) Union of all these subsets in P is the set S i.e. {A1 A2 A3, .} = S
(b) Intersection of every pair of distinct subsets of S P is a null set.
For example if S = {2, 3, 4, 5, 6, 7, 8, 9} and its subsets A1 = {2, 4}, A2 = {8, 9}, A3 = {3, 6, 7}, A4 = {5}
The set P = {A1, A2, A3, A4} is a partition of S as A1 A2 A3 A4 = S and either Ai = Aj or Ai Aj = .

Corresponding to any partition on a set A, we can define a relation R in A such that xRy if and only if x and y belong
to the same subset of A (belonging to the partition). This relation R is said to be induced by the partition.

1.20
Quotient Set:Let A be a non empty set and R be an equivalence relation defined in A. Then the set of
mutually disjoint equivalence classes into which A is partitioned relative to the equivalence relation R is called the
Quotient set of A for the equivalence relation R and is denoted by A/R or `A. The collection of all equivalence
classes of elements of set A denoted by A/R or A/~ is called the Quotient of A by R or ~.
The collection of all equivalence classes of elements of set A under an equivalence relation R denoted by A/R is
called the Quotient set of A by R or simply a partition. Thus it is a collection of non empty subsets of A such that
(a) Each elements of A belongs to one of the sets in P.
(b) The intersection of every pair of two distinct elements of P is null set.
For example:- Let A ={a, b, c, d, e , f, g, h}
if A1 = {a, b, c, d}, A2 = {a, c, e, f, g, h}
A3 = {a, c, e, g}, A4 = {f, h}, A5 = {b, d} then {A1, A2} is not a quotient set since A1 A2 . {A2, A4} is not a quotient
set since f A2, f A4.
{A3, A4, A5} is a quotient set
{A2, A5} is also a quotient set.

1.22Functions
1.21.1 Function of a single variable :Suppose A & B are two non empty sets of real numbers. A rule that associates
to every elements x A, a unique element y B is called a function or mapping from the set A to the set B. Rule is
denoted by f and we write f : A B and read, f is a function from A to B
Set A is called Domain of f.
Set B is called Co-domain of f
and f(x) = {f (x) : x A} is called Range of f from A to B or R = {(y) : y B and y = f(x) , " x A} is called Range of f.
x is called independent variable
y is called dependent variable
In fact R is the image set of f from A to B.
If x A and the rule f associates x to an unique element y B such that y = f(a), then y is called f-image of x and x
is called pre-image of y in A.

Important : It is not necessary that each element of the set B shall be the image of an element in the set A, but it is
necessary that every elements of A must have one and only one image in the set B.

Domain, Co-domain and Range of a function


Domain of the function f is set A
Co-domain of the function f is set B.
x A corresponds to y B then y is image of x under f or y = f (x)
Range of f = {f (x) : x A} B.
1.21.2 Difference between a Relation and a Function

Let A and B be two sets and f be a function from A to B. f is a subset of A x B such that each x A appears in one
and only one ordered pair belonging to f.
Therefore f is a subset of A x B satisfying the following two conditions.
(a) No x A can have more than one f-image in the set B or we can say there cannot be two or more distinct
second coordinates corresponding to any first coordinate in the set of ordered pairs A x B e. g (x, y1) and (x, y2) can
not be the elements of A x B.
In relation an element in A can have more than one f -image in B.
(b) Every element in A must have an image in B. This condition is not necessary for a relation. Thus every function
is a relation but every relation is not a function.
(c) If R is a relation from A to B, then domain of R may be a subset of A. But if f is a function from A to B, then
domain of f is equal to A.

Example :- Let A = {a, b, c} and B = {2, 3, 4, 8} then (i) the subset R of A x B given by R = {(a, 2), (b, 2), (c, 8)} is a
function from A to B.
(ii) the subset S1 of A x B given by
S1 = {(a, 2), (a, 4), (b, 3), (c, 8)} is a relation but not a function because the same element a A is associated with
two elements 2, 4 B.
(iii) the subset S2 of A x B given by S2 = {(a, 4), (b , 8)} is a relation but not a function because an element c A is
not associated with any element of B .

Example :- Find domain and range of the function defined by

x for x < 0
f(x) =

x for 0 x 1
1/x for x > 1

Also find f(-3), f(1/3) and f(2).

Solution Since f(x) is defined for all x R, therefore domain of f is R


2

For x < 0, f(x) = x > 0


2

f(x) = x shall be any value in the open interval ] 0, [, For 0 x 1, f(x) = x whose value lies in the closed interval
[0, 1].
For x > 1, f(x) = 1/x whose value shall lie in the open interval
R = Union of ]0, [ U [0, 1] U ] 0, 1[

] 0, 1[, Thus the required range of f shall be given by

= ] 0, [

Also -3 < 0 f (-3) = (-3) = 9


0 <1/3 < 1 f (1/3) = 1/3
2 > 1 f (2) = 1/2

1.21.3 Identity Function: If A is a non empty set and f is a function such that f: A A defined by f (x) = x, " x A.
Then f is called identity function.
It is one-one & onto . Every element of A is its f-image.

1.21.4 Constant Function

f : A B defined by f (x) = c is called a constant function. It is not one one as f (2) = c, f (3) = c.
Also it is onto as range of f = co domain of f = {c}
Here every element of the domain is assigned to the same element of the co domain

1.21.5 Inverse Mapping

--1

If a function f : A B is one one onto mapping from A to B, Then f = {(y, x) : (x, y) f} is called inverse mapping
of f.
Note:- Inverse of f is possible only
-1

(a) if f is one-one, otherwise the same element of B shall be associated with more than one element of A in f and
-1
then f is not a function.
(b) f is onto, otherwise there will exist elements in B which will not be associated with any element of A in f
-1
therefore f shall not be a function.

-1

and

We can represent the inverse of a function f diagrammatically as follows:


A

--1

f : A B

f :BA

1.21.6 Real Valued mapping or function

A function is said to be real valued if a set is mapped into a set of real number e.g.f (x) = sin x, f (x) = log x

Graph of a function:Let f : A B be a function, then the graph of f, generally denoted by f is defined as set of
*
ordered pairs (x, y) A x B such that y = f (x). The graph of f is given by
f = {(x, y) A B : y = f (x)}
2

For example : - if f : R R is a function given by f (x) = x + 1 " x R then


*

f = {(x, y) R x R : y = x + 1}
= {(1, 2), (2, 5), (3, 10), (-1, 2), (-2, 5), ..}
2

-1

-1

Example :- If the function f : R R be defined by f (x) = x , then find out (i) f (9) (ii) f (-9)
2

Solution f : R R, f (x) = x , x R

-1

(iii) f (9, 16)

-1

(i) f (9) = {x R : f(x) = 9 }


[i.e. To find pre image of 9 or a number whose image is 9]
2

= {x R : x = 9} = {x R : x = 3}
= {3, -3}
-1

(ii) Again f (-9) = {x R : f (x) = -9}


2

= {x R : x = -9}
= {x R : x = 3i}
= f as 3i R
-1

(iii) f (9, 16) = {x R : f (x) = 9, f (x) = 16} = {x R : x = 9, x = 16}= {+3, -3, +4, -4}
2

-1

Example :- If the map f : C C is given by f (x) = x , then find f (-5)


-1

Solution f (-5) = {z C : f (z) = -5}


2

= {z C : z = i5} = {i5, -i5}


Transformation or operators:
If the domain and co domain of a function f are both the same set, say A i.e f : A
A then f is called an Operator or transformation on the set A.

Equal functions:Two functions f and g defined on the same domain A are said to be equal if
f(x) = g (x) " x A and we write f = g.
2

Example :- If f (x) = x + 2 where x is any real number and g (x) = x + 2 where x is any complex number then f g
because the domains of f and g are different.
2

Example :- Let A = {2, 3} and B = {2, 4, 5, 9}. Let a function f be defined from A to B by f (x) = x and g = {(2, 4). (3,
9)}, then f = g because f and g both have the same domain = {2, 3} and each of them assigns the same image to
each element in the domain.

1.22 Product or Composition of Mapping

Let A, B, C, be three sets and f and g be two functions such that f : A B and g: B C.
It means that the function (or mapping) f maps an element x A into an element y B where y = f (x) " x A.
Also the function g maps an element y B to an element z C, where z = g (y) " y B.
So g (y) = g (f (x))

Thus we have a mapping which maps an element x A to an element g (f(x)) C. It is called the composition or
product of functions f and g in that order and is denoted by gof or simply gf. It is also called composite mapping of
f and g. Hence we say that if f : A B, g : B C then the composite mapping from A to C is given by
(gof)(x) = g (f(x)), " x A.

Theorem Let A, B, C and D be four sets and f, g, h be three functions such that f : A B, g : B C, h : C D then
(hog)of = ho(gof)
Proof:- We have by definition of composites of mapping that
((hog)of)(x) = (hog)(f (x)) = (ho (go (f (x)))
= (ho (gof)) (x)
Hence ((hog)of) = ho (gof)
We may also define Composition of Functions as follows:
Let f : X Y and g : Y Z be two function. The composite relation gof such that
gof = {(x, z)/ (x X) (z Z) ($ y) (y Y) y = f (x) z = g (y))} is called the composition of functions or relative
product of f and g or left composition of g with f, Range Rf of f is a subset of domain of g which is Y i.e. Rf Dg
otherwise gof is empty.
For the existence of fog it is necessary that Rg Df

Example :- X = {1, 2, 3}, Y = {p, q}, Z = {a, b}


f : X Y is f = {(1, p), (2, p), (3, q)} and g : Y Z is g = {(p, b), (q, b)} Find gof.
Solution gof = {(1, b), (2, b), (3, b)}

f:XY

g:YZ

Diagrammatic representation of f, g and (gof)

f
X

g
Y

gof
Z

x1

y1

x2

y2

x3

x4

x1

z1

z1

x2

z2

y3

z2

x3

z3

y4

z3

x4

y5

Diagrammatic representation of f, g, h and (hog)of


(hog)of

hog

ho(gof)
2

Example :- It the functions f : R R and g : R R are defined by f (x) = x + 2 and g (x) = 2x + 1, then evaluate (fog)
(x), (gof) (x).
Solution (fog) (x) = f (g (x)) = f (2x + 1) = f (y), where 2x + 1 = y
2

= y + 2 = (2x + 1) + 2 = 4x + 4x + 3
2

(gof) (x) = g (f (x)) = g (x + 2) = g (z), z = x + 2


2

= 2z + 1 = 2 (x + 2) + 1 = 2x + 5.
Example :- Let f (x) = x + 2, g (x) = x 2, h (x) = 3x for x R.
find gof, fog, fof, fohog.
Solution gof = {(x, x) / x R} = g (f (x)) = g (x + 2) = (x + 2) 2 = x
fog = {(x, x) / x R} = gof
fof = {(x, x + 4) / x R} = f (f(x)) = f (x + 2) = (x + 2) + 2 = x + 4

(foh)og = fo(hog) = fohog = foh(x-2) = f(3(x-2)) = 3(x-2) +2 = 3x - 4


1.23 Different forms of function

Algebraic Function :It consists of a finite number of terms involving powers and roots of the independent variable
x and the fundamental operations (+, -, *, / )
3

e.g. 4x 7x + 3x + 2, (3x 1) , 3x + 7 / (2x + 1)

ns

Three types of Algebraic F

(a) Polynomials or Rational Integral Function


n
n-1
n-2
It is of the form a0x + a1x + a2x + + an where n is a +ve integer.
a0, a1, a2 are real constants.
5

e.g. 4x 2x + 7x 5x + 11

(b) Rational Function


It is of the form f1(x) / f2(x) where f1(x) and f2(x) are polynomials in x
3

e.g. 3x + 5x 2/x 5x + 7

(c) Irrational Function


2
1/2
1/3
1/4
2/3
It involves radicals e.g. 2x 7x + 5, (2x 3) + (5x + 1) / (x 5) (2x 1)

Transcendental Function

It is a function which is not algebraic.

ns

Four types of Transcendental F

(a) Trigonometric functions e.g. sinx, tan4x,


-1

(b) Inverse trigonometrical functions e.g. sin x,

(c) Exponential function it involves e , a , x

(d) Logarithmic function e.g. logax, loge(sinx)

Other functions

Single Valued Function : y= x , y = sinx, corresponding to one value of x we get one value of y.
-1

Many valued Functoin : y = cos x


for x = , y = p/3, 5p/3, -p/3, .
or y = 2np p/3, n I
Even function : f (x) = f (-x). e.g.cosx
Odd function : f (-x) = -f (x) e.g. sinx
2

Explicit Function : When y is expressed directly in terms of x, y = ax + bx + c

Implicit Function : f (x, y) = 0, either variable is an implicit function of the other


2

ax + 2hxy + by + c =0

1.24. Types of functions

1.24.1. One-to-one function or mapping or injective mapping

A mapping or function f : A B is said to be injective if for each pair of distinct elements of A, their f-images (in B)
are also distinct. It means that f : A B is injective if for x1, x2 A, (x1 x2) f (x1) f (x2) in B.

Example:- The function f (x) = 2x + 1. where x is a real number is injective as for any pair of values of x say x1 and x2
A, f (x1) = 2x1 + 1 f (x2) = 2x2 + 1. The diagrammatic representation of an injective function shall be of the
following form.

x1

y1

x2

1.24.2 Many one function or mapping


A mapping f : A B is many one if two or more different elements in A have the same f-image in B i.e x1, x2 A
and x1 x2 f (x1) = f (x2)
2

Example:- The mapping {-2, 2, 3, 4} {4, 9, 16} defined by f (x) = x is many one because two different elements in
A (i.e. -2, 2) have the same f-image in B (i.e. 4).

-2

1.24.3 Surjective or Onto mapping or Surjection :A mapping f from a non empty set A to another non empty set
B i.e f : A B is said to onto or Surjective if " y B there exists x A such that y = f (x). It means every element in
B has its pre image in A. Each element in B shall have one pre image (in case of one to one mapping) or more than
one (in case of many one mapping) pre images in A.

x1

y1

x1
y1
x2
y2

manyone onto mapping

one to one onto mapping

Example :- Let f(x) = x + 1 (x is any integer), then the domain and range of f shall be the set of integers
f : Z Z.
Every element y in codomain set Z shall have its image (= y 1) in the domain set z.

1.24.4. Into function or mapping:A mapping f : A B (of a non empty set A to a non-empty set B) is said to be
into mapping if there exists at least one element of the codomain set B which is not the f-image of any element in
A.
Example :- If the mapping f is defined by f (x) = 2x, where x is any integer then the domain set A shall be the set of
all integers while the set f (x) shall be the set of all even integers which is a proper subset of the set of all integers.
Thus there will be elements in codomain set (odd integers) which will not have any pre-image in the domain set A.

Example :- Similarly the function defined by f (x) = x (x is any integer) is also into mapping because the domain set
is set of all integers {0, 1, 2, ..} and set f (x) set is set of positive integers only set of all integers (codomain
set) and there will be elements in codomain set (negative integers) which will not have their pre-image in domain
set.

Diagrammatically it can be represented as follows :

x1

y1

x2

y2

1.24.4.1 One-One-into mapping :A mapping which is one-to-one and into is called one-one into mapping from A
to B. It means that(a) f (x1) f (x2) if x1 x2 i.e. f images of two distinct elements in A shall be the two distinct
elements in B.and (b) there exists at least one element in B which is not the f-image of any element in A.
into
It is written as f : A

1-1
1.24.4.2 Many one into mapping :A mapping f : A B is said many one into if
(a) f (x1) = f (x2) x1 x2, x1, x2 A
(b) there is at least one element y B which is not the f-image of any element of A.
Example :- If A = {-1, 1, -3,3, 4} and B ={1, 9, 16} prove that f : A B = {(x, y) : y =

1.24.5. Bijective mapping or one to one and onto mapping:A mapping or function which is one to one and onto
is called a Bijective mapping. It is written as

onto
A

B
11

Example :- If A = {p, q, r} and B = {a, b, c} then f = {(p, a), (q, c), (r, b)} is a bijective mapping.
We given below the diagrammatic representation of one one onto functions, f1, f2, f3, f4 are four functions. f1 : A
B, f2 : B C, f3 : C D and f4 : D E. All these four functions have been represented by arrow diagrams and
nature of each of these is also discussed here.

1.24.6. Many-one onto mapping: A function f : A B which is many one and onto is called many one onto
mapping. In such a mapping (a) f (x1) = f (x2) x1 x2, x1, x2 A
and (b) " y B, there exists some x A such that f (x) = y
Example :- If A = {3, 4, 5}, B = {x, y}, then f = {(3, x), (4, y), (5, y)} is a many one onto mapping.

Example :- If A and B are two non empty sets and a function f : AB is one-to-one onto, then prove that the
-1
inverse function f : BA is also one to-one onto.

Solution Let x1, x2 A and f (x1) = y, f (x2) = y2, y1, y2 B; then x1 = f


follows

-1

x1 = f (y1)

-1

(y1) and x2 = f

f (x1) = y1
f
-1

As f is one-one
y1 y2 or f (x1) f (x2) x1 x2

-1

-1

(y2). we can represent this as

-1

-1

-1

f (y1) f (y2) which means that y1 y2 f (y1) f

--1

-1

(y2), therefore the inverse function f is one-to-one.


-1

Again as f is onto, therefore " x A there exists a unique y B such that f (x) = y, which implies x = f (y). It
-1
-1
means that corresponding to each x A we have a pre image f (y) in B. Therefore f is onto function
-1
Consequently f is one to one onto function.

Example :- Let Q be the set of all rational numbers and f : QQ be a function defined by f (x) = 3x + 5, x Q, then
prove that f is one to one onto. Also find inverse of f.
Solution (i) To prove f is one to one
If x1, x2 Q, (domain of f), then
f (x1) = f (x2) 3x1 + 5 = 3x2 + 5
x1 = x2, which prove that f is one one.
(ii) To prove f is onto
Let y Q (co domain of f), then y = f (x), x Q (domain of f)
y = 3x + 5 or x = (y 5)/3 (1)
As y is rational, so y 5/3 is also rational.
From (1) we have f (x) = f ((y 5)/3) = y
Thus any arbitrary element y in Q (in co domain set) is the f-image of the element (y 5)/3 Q (domain set) i.e.
every element in the co domain set has its pre image in domain set. Therefore f is onto.
-1

Now as f is one-one, f has an inverse function f : QQ.


If y is the image of x under the function f, then y = f (x) = 3x + 5. Hence x will be the image of y under the
inverse function
-1

x = f (y) = (y 5)/3 (y Q).

1.25
Let

Mathematical Induction :

P (n) be a proposition on an integer variable n. Then P (n) is true for all integers n s if and only if the
following two conditions are both satisfied :
(i)

P (s ) is true ,

ii)

If

P (k ) , where k s , is assumed to be true, then P (k + 1) is true .

Example: Prove by induction that

2 + (3 2) + (4 2 2 ) + ... + ( n + 1)2 n -1 = n 2 n

(*)

for all integers n 1.


b) Show that
2n

(r + 1)2r -1 = n2n (2n+1 - 1)

r =n+1

Solution: Basic Step: This is to prove the result true when n = 1:


1-1

Left hand side of equation (*) = (1 + 1)2

=2

Right hand side of equation (*) = 1 2 = 2.


So equation (*) is true when n = 1.
Inductive Hypothesis: We assume the result is true when n = k, i.e. we assume that

2 + (3 2) + (4 2 2 ) + ... + ( k + 1)2 k -1 = k 2 k .
Inductive step: We want to prove the result true when n = k + 1, i.e. we want to show that

2 + (3 2) + (4 2 2 ) + ... + ( k + 1 + 1)2 k +1-1 = ( k + 1)2 k +1


2 + (3 2) + (4 2 2 ) + ... + ( k + 1)2 k -1 + ( k + 2)2 k = ( k + 1)2 k +1 .

i.e. that
But,

2 + (3 2) + (4 2 2 ) + ... + ( k + 1)2 k -1 + ( k + 2)2 k = k 2 k + (k + 2)2 k (using the assumption)

So

2 + (3 2) + (4 2 2 ) + ... + ( k + 1)2 k -1 + ( k + 2)2 k = 2 k ( k + ( k + 2))

i.e.

2 + (3 2) + (4 2 2 ) + ... + (k + 1)2 k -1 + ( k + 2)2 k = 2 k (2 k + 2)

i.e.

2 + (3 2) + (4 2 2 ) + ... + ( k + 1)2 k -1 + ( k + 2)2 k = 2 k 2( k + 1)

So we have

2 + (3 2) + (4 2 2 ) + ... + (k + 1)2 k -1 + ( k + 2)2 k = 2 k +1 ( k + 1) as required.

Therefore the equation is true when n = k + 1.


So the equation is true for all integer values n 1.

Example: Prove that 2

Solution: Let f(n) = 2

4 n+1

4 n+1

+ 3 is a multiple of 5 for any positive integer n.

+3.
5

Step 1: Prove f(1) is a multiple of 5. But f(1) = 2 + 3 = 35 (which is a multiple of 5).


Step 2: We assume f(k) is a multiple of 5. We want to prove that f(k + 1) is a multiple of 5.
First we try to simplify:
f(n + 1) - f(n) = 2

4( n+1) +1

+ 3 - ( 24 n+1 + 3 ) = 2 4 n +5 - 2 4 n +1 = 2 4 n +1 (2 4 - 1) = 15 2 4 n +1

Therefore:
f(k + 1) f(k) = 15 2
So, f(k + 1) = 15 2

4 k +1

4 k +1

+ f (k ) .

Multiple of 5

Assumed to be a
multiple of 5

So, f(k + 1) is a multiple of 5.


Therefore by induction, f(n) must be a multiple of 5 for all positive integers n.

UNIT-2
Algebraic Structure
2.1 Binary Relation

A binary operation is a function which associates a unique element of the set A to every ordered pair of elements
of A. It means that if A is a non empty set, then any function (denoted by say *): A A A is called a binary
operation on A. The binary operation * on set A and the ordered pair (a, b) A A, *(a, b) is denoted by a * b.
If a binary operation is applied to the two elements of an ordered pair (a, b) A, then the resulting element a * b
shall also belong to the same set A. Such an operation is said to be closed. Thus a binary operation on a set A is
always closed on A, but it may not be closed on a subset of A.
For examples:- (a) The operations of addition (+) and multiplication () are binary operations on the set of integers
Z, since " a, b Z, a + b Z and (a b) Z.
(b) The operations of and are binary operations on the power set of a non empty set S, since A B P(S) and
A B P(S) " A, B S.

2.2 Properties of Binary Operations

1. If * is a binary operation on a set A, then


(a) Closure property:- if a, b A,
a*bA
(b) Associative:- if a, b, c A,
(a * b) * c = a * (b * c)
(c) Identity Element:- If e A and a A,
a*e=a=e*a

(d) Inverse of an element:- if e, a A and b A such that a * b = e = b * a, then b is called an inverse of a


-1
and we write b = a .
(e) Commutative:- if a, b A then a * b = b * a

2.3 Algebraic Structure : A non empty set G along with one or more binary operations is called an algebraic
structure.

Example :- If G is a non empty set and * and 0 are binary operations, then (G, *), (G, *, 0), (G, 0) are all algebraic
structures.
(N, +), (I, +), (I, -) and (R, +, ) are all algebraic structures, since (a) addition is a binary operation for the set N as
well as the set I . (b) Subtraction is a binary operation for the set I (c) addition and multiplication are binary
operations for the set R.

2.4 Semi-group : An algebraic structure (G, *), where G is a non-empty set and * is a binary operation, is said to be
a semi-group if the binary operation * is associative in G i.e.
(a * b) * c = a * (b * c), " a, b, c G.

Example :- Let N be the set of natural numbers and addition is the binary operation w.r.t N., then addition is an
associative operation on N. Therefore (N, +) is a semi group.
Similarly the algebraic structures (N, ), (I, +) and (R, +) are semi groups.

2.5 Group :A non empty set G along will an operation denoted by *. i.e. (G, *) is called a group if the operation *
satisfies the following postulates.

1. Closure property:- It means that the operation * is a binary operation i.e. a * b G, " a, b G
2. Associativity Property:- (a * b) * c = a * (b * c) " a, b, c G.

3. Existence of identity:-There must exist an element e (called identity) in set G such that a * e = a = e * a, " a
G. The identity element e will be the same for every element of G.
[Existence of either left identity or right identity is sufficient]
4. Existence of Inverse:- Every element a of G possesses an inverse element. It means that there exists an elements
-1
-1
-1
b G such that b * a = e = a * b. This element b is called the inverse of a (=a ). Thus b = a . Therefore a * a = e =
-1
a*a

2.6. Abelian Group or Commutative Group

An algebraic structure (G, *) which satisfies all the four properties mentioned above and also a fifth property
stated below is called an abelian group.

5. Commutativity property:- It means a * b = b * a, " a, b G.


Note:-If it is given that * is a binary operation, then the closure property is automatically satisfied and in order that
(G, *) may be a group, the properties (2) (4) have to be satisfied.
Some times only the symbol G is used to denote the algebraic structure if there is no confusion regarding the
operation *.

2.7 Finite and Infinite Group:If the non empty set G of the group (G, *) consists of a finite number of distinct
elements, the group is called a finite group, otherwise it is an infinite group.

2.8 Order of a group:The number of elements in a finite group is called the order of the group. The order of an
infinite group is infinite. Order of a group is denoted by o(G).
The group of the smallest order for a given operation or simply the smallest group is the group in which the set G
consists of the identity element e alone i.e. G = {e}.

Example :- Prove that the set I of all integers {------- -3, -2, -1, 0, 1, 2, 3, -----} is a group will respect to the operation
of addition of integers.
Solution:- We shall have to show that the algebraic structure (I, +) satisfies all the four postulates of a group.
1. Closure property - We know that a + b I " a, b I, therefore the set I is closed with respect to the operation
of addition or addition satisfies the closure property for I.

2. Associativity It is know that addition is an associative operation for the set I.


3. Existence of identity- We have an integer 0 such that a + 0 = a = 0 + a, " a I. Therefore the integer 0 is an
identity for the set I with respect to the operation of addition.
4. Existence of inverse- " a I, -a I. and (-a) + a = 0 = a + (-a), therefore corresponding to each element a I,
there exists an inverse (-a) I. Thus (I, +) is a group.

Theorem (Uniqueness of identity): The identity element in a group is unique.


Proof:- Identity element in a group (G, *) means the identity element G with respect to the binary operation *.
Let (G, *) be a group. Also let e1 and e2 are identity element of G i.e. e1 , e2 G.
e1= e1* e2 = e2
Hence the identity element of G is unique.

-1

-1 -1

-1

Theorem : If a is the inverse of a , then (a ) = a i.e. the inverse of (a ) is a.

Proof:- Let G be a non empty set and a A. Also let e be the identity for G. Let the binary operation be *. Then
-1

a *a=e
-1 -1

-1

(by definition of inverse)


-1 -1

-1 -1

-1 -1

-1

-1 -1

or [(a ) * (a )] * a = (a )
-1 -1

-1 -1

or a = (a )

(applying associative property on L.H.S and definition of identity on R.H.S)


-1 -1

or e * a = (a )

-1

(operating both sides by (a ) which belongs to A as a G)

or (a ) * [a * a] = (a ) * e

-1

(by inverse property as (a ) is inverse of a )


(by definition of identity)

-1 -1

or (a ) = a
Note:- Some times the notation for operation is not used e.g. instead of a * b, we write ab in case no confusion is
created by it.

Theorem :- The inverse of the product of two elements of a group G is equal to the product of the inverses taken in
the reverse order. i.e.
-1

-1

-1

(ab) = b a " a, b G
Note:- Here by product of two elements a, b we mean a b = a * b, (* is any binary operation). Thus we have to
prove that

-1

-1

-1

(a * b) = b * a " a, b G.
-1

-1

Proof:-Let a, b, G and a and b are inverse of a and b respectively. Let e be the identity element.
-1

Then a * a = e = a * a
-1

and b * b = e = b * b
-1

-1

-1

-1

-1

Now (a * b) * (b * a ) = (a * b * b ) * a
-1

= [a * (b * b )] * a
= [a * e] * a

-1

-1

-1

(by definition of inverse)


-1

-1

-1

(as * is associative)

= (a) * a

(by definition of identity)

=e

(by definition of inverse) (1)

-1

-1

Again (b * a ) * (a * b) = b * [a * (a * b)]
-1

(by associativity)

-1

= b * (a * a) * b]
-1

= b * (e) * b

(by definition of inverse)

-1

= b * (e * b)
-1

= b * b (by definition of identity)


=e

(by definition of inverse) (2)

Form (1) and (2) we have


-1

-1

-1

-1

(b * a ) * (a * b) = e = (a * b) * (b * a )
-1

-1

-1

-1

Therefore, by definition of inverse, we can say that b * a is the inverse of a * b or (a * b) = b * a


[The rule given in this theorem is known as the reversal rule]

Theorem 5:- (Cancellation law holds in a group)


In a group (G, *) if a, b, c G then
a * b = a * c b = c (Left cancellation law)
and b * a = c * a b = c (right cancellation law)
-1

Proof:- If a is the inverse of a G and e is identity for G, then


-1

a *a=e=a*a

-1

We have a * b = a * c

-1

-1

-1

-1

-1

-1

or a * (a * b) = a * (a * c) (operating on left, both sides by a )


or (a * a) * b = (a * a) * c (using associativity property)
or e * b = e * c

(by definition of inverse)

or b = c (by definition of identity)


Again if b * a = c * a, then
-1

-1

-1

(b * a) * a = (c * a) * a
-1

(operating on right, both the sites by a )


-1

or b * (a * a ) = c * (a * a )
or b * e = c * e

(by associativity)

(by definition of inverse)

or b = c (by definition of identity)


Example :- Show that the set A of complex numbers of absolute value 1 form a group under multiplication of
complex numbers.
2

Solution:- Let A = {x + iy : x, y R, x + y = 1}
or A = {z C : |z| = 1}, where C is the set of complex numbers.
Closure property:- |z1 . z2| = |z1| . |z2| C which satisfies the closure property.
Associativity :- Multiplication is associative in set of complex numbers.
Existence of identity:- As 1 + 0i = 1 C and 1. (x + iy) = x + iy. So 1 is the multiplication identity.
Existence of inverse:- 1/ |z| = 1 C, therefore inverse of z is 1/z.
Thus the given set forms a group under multiplication.

Theorem :-If a and b are two elements of a group G, then the equations a x = b and y a = b have unique solutions in
G.
-1

-1

-1

Proof:- Let (G, *) be the group and e be its identity element. Since a G, therefore a G and a * a = e = a * a .
-1

-1

Again, Since a G and b G (given), therefore a * b G (* being a binary operation) ..(1)


The given equation is a x = b or a * x = b (2)
-1

Putting x = a * b in L.H.S of eq. (2), we have


-1

-1

a * (a * b) = (a * a ) * b = e * b = b = R.H.S.
-1

-1

-1

It means that x = a * b is a solution of eq (2) and a * b G, from (1) i.e. x = a * b G is a solution of the eq. a *
x = b.

Now we have to show that the solution is unique. If possible let x = x1 and x = x2 be the two solutions of the same
equation a x = b (or a * x = b). Then x1 and x2 shall satisfy this equation i.e. a * x1 = b and a * x2 = b or a * x1 = a * x2
which, by left cancellation law gives x1 = x2. Hence the solution is unique.
-1

-1

Again we have to prove that y a = b or y * a = b has a unique solution in G. Since b G and a G, therefore b * a
-1
-1
-1
G (* being binary operation). Putting y = b * a in the L.H.S. of the eq. y * a = b, we have (b * a ) * a = b * (a * a)
-1
= b * e = b. It means that y = b * a is a solution in G of the eq. y a = b. To show that this solution is unique. If
possible let y = y1 and y = y2 be the two solutions of the same equation y a = b (or y * a = b), than y1 * a = b and y2 *
a = b or y1 * a = y2 * a, which by right cancellation law gives y1 = y2. Hence the solution is unique.

Theorem8:- A group in which each element is the inverse of itself is an abelian group.
Proof:- Let (G, *) be a group, and a, b G. Therefore a * b G (since G is a group and * is binary operation.).
-1

-1

Now a = a and b = b (given) (1)


-1

Also (a * b) = (a * b) (given, since a * b G) ..(2)


-1

-1

-1

We have (a * b) = b * a (property of a group)


= b * a (by (1))

..(3)

From (2) & (3) we have a * b = b * a. So the operation * is commutative and the group (G, *) is an ablian group.

Theorem :- The left identity is also the right identity in a group.


Proof:- It means that if it is given that e is the left identity of a group (G, *) i.e. e * a = a, " a G, then we have to
prove that e is also its right identity i.e. a * e = a, " a G.
Thus our problem is :
Given that e * a = a ..(1)
To prove that a * e = a ..(2)
-1

-1

As a G, its inverse a G and a * a = e.(3)


-1

-1

Now a * (a * e) = (a * a) * e (by associativity)


= e * e (by definition of inverse)
= e (by definition of identity)
-1

= a * a (by (3))
-1

-1

Therefore a * (a * e) = a * a
or a * e = a

(by left cancellation law)

which proves the theorem as required in (2) that e is also the right identity.
[Here we have assumed that left inverse exists as given in (3)]
+

Example :-Let Q denote the set of all positive rational numbers and * is an operation defined as a * b = ab/2 " a,
+
b Q+, then prove that (Q , *) is an ablian group.
Solution:1. Closure property:- " a, b Q, we know that a * b = ab/2 Q+, therefore the set Q+ is closed with respect to the
given operation *.
2. Associativity:- Let a, b, c Q+, then (a * b) * c = (ab/2) * c = (ab/2.c)/2 = abc/4
+

and a * (b * c) = a * (bc/2) = (a.bc/2)/2 = abc/4. Therefore (a * b) * c = a * (b * c) " a, b, c Q . Thus the property


+
of associativity is satisfied by Q with respect to the given operation *.
+

3. Existence of left identity:- Let e Q be the left identity for all elements of Q , then " a Q , we have e * a = a
or e a/2 = a
I

II
+

From I and II we get e = 2 and 2 Q i.e. 2 is the left identity. Thus 2 is the identity for the group Q with respect to
the given operation.
+

4 Existence of left inverse: - Let b Q be the left inverse of an element a Q , then b * a = 2


or ba/2 = 2
I

II
+

From I and II we have b = 4/a i.e. 4/a is the left inverse of a. Thus corresponding to each element a Q , its inverse
+
+
element = 4/a Q . Therefore inverse element exists for each element of Q .
5 Commutativity:- For any two elements a, b Q+ we have a * b = ab/2 and b * a = ba/2 = ab/2. Thus a * b = b * a,
+
" a, b Q . Therefore the commutativty property is satisfied.
+

Hence (Q , *) is an abelian group.

Example:- If a binary operation * defined for a set of real numbers is given by a * b = a + b + ab " a, b R, then
find out the identity element in R and also determine the inverse of a R.
Solution:-Let e be the required identity element. Then " a R, we have e * a = a = a * e.
or e + a + ea = a = a + e + ae
I

II

III

Now form I and II or II and III, we get

e = 0/(1 + a) = 0 (if a -1)


Thus the identity element for all elements in R (except 1) is 0. Again let b R be the inverse of a R then b * a =
0 = a * b (a -1)
or b + a + ba = 0 = a + b + ab
I

II

III

From I and II or II and III we have


b = -a/ (1+a). Thus the inverse of an element a R is a/(1+a) (if a -1).

Example :- Show that the set of all positive rational numbers does not form a group with respect to the binary
operation * defined by a * b = a/b.
Solution:1. Closure property It is satisfied (as the operation is a binary operation) for the set of positive rational number
+

2. Associativity Let a, b, c R , then (a * b) * c = (a/b) * c = a/bc


and a * (b * c) = a * (b/c) = ac/b
Thus (a * b) * c a * (b * c)
+

Therefore Associativty property is not satisfied. Hence (R , *) is not a group.

Example:-Show that the set G = {a + b2 : a, b Q} is a group with respect to addition.


Solution:1. Closure property Let x and y be any two elements in G such that x = a + b2 and y = c + d2, a, b, c,d Q, then
x + y = (a + c) + (b + d) 2.
Now a + c an b + d each being sum of two rational numbers are themselves rational numbers i.e. a + c Q and b +
d Q. Thus x + y G " x, y G. Hence the closure property is satisfied.
2. Associativity Since elements of G are all real numbers and the operation of addition is associative for the set of
real numbers (& hence for the set of rational numbers).
3. Existence of left identity- Let e = 0 + 02 be the le iden ty for an element x = a + b2, a,b Q, then e + x = (0 +
02) + (a + b2) = a + b2 = x i .e. the le iden ty exists. Thus e = 0 + 02 is the iden ty element for G with respect
to the operation of addition.
4. Existence of left inverse- a,b Q -a, -b Q,
So a + b2 G -a - b2 G

and (a + b2) + (-a - b2) = 0 + 02


Thus a - b2 is the le inverse for a + b2.
Hence G is a group with respect to addition.

Example 15:- Show that the set of matrices

cosa

-sina

sina

cosa

Aa =

where a is a real number, forms a group under multiplication.


Solution:- Let M denote the set of matrics

cosa

-sina

sina

cosa

Aa =

where a R. We have to prove that (M, ) is a group.


1. Closure property Let Aa, Ab M, (a, b, R), then

cosa -sina

cosb

-sinb

sinb

cosb

Aa . Ab =
sina

cosb

cos (a + b)

-sin (a + b)

= Aa+b
cos (a + b)

sin (a+b)

As a + b being sum of the two real numbers is also a real numbers, Aa+b M. therefore the set M is closed with
respect to matrix multiplication.
2. Associativity Matrix multiplication is associative.
3. Existence of left identity As 0 R, therefore

A0 =

cos0

-sin0

sin0

cos0

belongs to M. Also for Aa M, we have A0 . Aa = A0+a or Aa. Thus A0 M is the left identity element for each
element Aa M.
4. Existence of left inverse- If a R, then -a R and therefore Aa M A-a M. Let Ab M be the left inverse
of Aa M then Ab . Aa = Ao or Aa+b = Ao or a + b = 0 or b = - a. Therefore A-a Ma is the left inverse of Aa G. It
means each element of M possesses left inverse. Hence (M, ) is a group.

2.9 Composition table for finite sets

The tabular form in which a binary operation in a finite set is represented is known as composition table.
Let A = {a1, a2, .an} be a finite set and the symbol * denotes a binary composition in the set A such
that ai, aj A ai * aj A. The elements of the set A are written in the top most row as well as the first column of
the composition table. The value of (ai * aj) is placed at the intersection of ith row and jth column as shown below.
Each element of the set A is written once in each row and each column.

a1

a2

an

a1

a1*a1

a1*a2

a1*an

a2

a2*a1

a2*a2

..

a2*an

an

an*a1

an*a2

an*an

..

Example :- Show that the four fourth roots of unity viz 1, -1, i, -i form a group with respect to multiplication.
Solution:- We represent the set A = {1, -1, i, -i} with respect to composition of multiplication in the composition
table as follows:

multiplication

-1

-i

-1

-1

-1

-1

-i

-i

-1

-i

-1

-i

Now we shall prove that (A, ) is a group.


(1) Closure property:- As all the entries in the composition table belong to A, it is concluded that A is closed
with respect to multiplication
(2) Associativity:- Elements of A are all complex numbers and multiplication of complex numbers is
associative.
(3) Existence of left identity:- Corresponding to each element ai A in the first column we have an element 1 A
in the topmost row such that 1.(ai) = ai = ai (1) [e.g. 1.(1) = 1, -1.1= -1, 1 (i) = i, 1(-i) = -i] Thus 1 A is the left
identity element in A i.e. left identity exists.[This fact is easily recognized by the fact that the column entries below
the element 1 coincides with the first row or the row entries against 1 coincides with the topmost row]

4. Existence of left inverse:- It is evident from the composition table that corresponding to each element ai A in
the first column there exists an element aj A in the topmost row such that aj.ai = 1 (the identity element) i.e.
left inverse exists " ai A. It means that corresponding to every element ai A its inverse aj A exists.
[1 is the inverse of 1, -1 is the inverse of -1, -i is the inverse of i, i is the inverse of i]
5. Commutativity:- Multiplication of complex numbers is commutative.
6. Also the number of elements in A is 4, so the group is finite.
Therefore (A, x) is a finite abelian group.

Example :-Show that the four matrices

-1

-1

-1

-1

form a finite abelian group with respect to matrix multiplication.

Solution:- Let the given matrices be denoted by A1, A2, A3 and A4 respectively. Also let M denote the set of these
four matrices i.e. M = {A1, A2, A3, A4}.
Now we arrange the elements of the set M in the form of composition table & fill in the entries by calculating the
value of products.

e.g.

A1. A1 =

A1 A2 =

=
0

+1

+1

-1

= A1
0

-1
=

0
= A2

and so on
Multiplication

A1

A2

A3

A4
A4

A1

A1

A2

A3

A2 A2

A1

A4

A3

A3 A3

A4

A1

A2

A4 A4

A3

A2

A1

Now we shall show that (M, ) is a group.


1. Closure property:- All the entries in the composition table belongs to M, so M is closed with respect to
multiplication.
2. Associativity:- It is known that matrix multiplication is an associative operation.
3. Existent of identity:- Corresponding to each element Ai M we have an element A1 M such that Ai. A = Ai = A.
Ai for i = 1, 2, 3, 4. (as is evident from the table)
i.e. A1 A1 = A1 = A1A1, A2A1 = A2 = A1A2
A3A1 = A3 = A1A3, A4A1 = A4 = A1A4
therefore A1 is the left identity. [It is also clear form the fact that the first row and first column of the composition
table coincides]
4. Existence of inverse:- It is easily seen from the composition table that the inverse elements for A1, A2, A3 and A4
are A1, A2, A3, A4 respectively. [It is easily verified from the fact that each of the main diagonal elements of the
table is A1, the identity] Thus M is a group with respect to multiplication.
5. Commutative property:- We see from the composition table that the entries in the first, second, third and
fourth rows coincide with the entries in the first, second, third and fourth column respectively. Therefore we have

Ai. Aj = Aj Ai. Hence the composition in M is commutative. Also the number of elements in M is finite (=4). Hence M
is an abelian group of order 4 with respect to multiplication.

2.10 Addition Modulo m

If a and b are any integer and m is a fixed positive integer then addition module m written as a + mb is the least
non negative remainder (which is also an integer say r) which is obtained when the ordinary sum of a and b (=a + b)
is divided by m thus a + mb = r, 0 r < m.
Division algorithm:- If we divide any integer a by any other integer b, then
a = bq + r where 0 r < |b|
(i.e. r is non negative) q is the quotient
example : -262/3 = - [262/3] = -[3(87) + 1]
= 3 (-87) 1 = 3 (-87) 3 + 3 1
= 3 (-88) + 2

Example :- 16 + 56 = 2 (= least non negative remainder (integer) obtained on dividing 16 + 6 by 5 Similarly 7 + 92 =


0, 4 + 41=0, -25 + 65 = 4 (= the least non negative integral remainder obtained on dividing -25 + 5 i.e -20 by 6.

2.11. Congruence modulo

If a and b are two integers such that a b is divisible by a fixed positive integer or m |(a b), then a b (mod m)
which is read as a is congruent to b modulo m.
e.g. 11 5 (mod 3) as 11 5 = 6 is divisible by 3
-22 3 (mod 5) as -22 3 = -25 is divisible by 5
It means that a b (mod m) a b = km (where k is an integer) or a = b + km.

Example :- Prove that if a b (mod m), then a + mc = b + mc, where a, b, c are integers & m is a positive integer.
Proof:- a b (mod m) a b = km (k being some integer) a = b + km.

Now a + mc = (b + km) + mc = the least non negative remainder when (b + km) + c is divided by m = the least non
negative remainder when b + c is divided by m, since km is already divisible by m.
= b + mc.
Hence proved.
Example :- If 9 1 (mod 4), then 9 + 46 = 1 + 46 = 3
Note:- 1. a + mb = (a + b) (mod m) = the least non negative integer obtained on dividing a + b by m e.g. 7 + 46 = 13
(mod 4) = 1
2. 13 (mod 4) = 1 can be written as 13 1 (mod 4) It means that (a + b) (mod m) = r can be written as
a + b r (mod m).
3.

a + mb = b + ma

2.12. Multiplication Modulo m

If a and b are any integers and m is a fixed positive integer, then multiplication modulo m written as a mb is the
least non negative remainder (which is also an integer) obtained on dividing the ordinary product of a and b (=ab)
by m,
Thus a mb = r, 0 r <m.
For example 11 73 = 5.

Example :- Prove that if a b (mod m), then


a mc = b x mc, where a, b, c are any integers and m is a fixed positive integers.
Proof:- a b (mod m) a b = km (k being some integer)
a = b + km.
Now a x mc = (b + km) mc = the least non negative remainder obtained on dividing (b + km)c or bc + kmc by m.
= least non negative remainder obtained on dividing bc by m (as kmc is already divisible by m)
= b mc Hence proved.

Example:- If 11 3 (mod 4), then 11 45 = 3 45 = 3


Note: 1. a mb = ab (mod m)
e.g. 6 43 = (63) (mod 4) = 18 (mod 4)
2. (a b) (mod m) or ab (mod m) = r can be written as ab r (mod m) e.g. 15 (mod 4) = 3 can be written 15 3
(mod 4).
3. a mb = b ma

2.13. Permutations

If P = {a1, a2, ..an} is a finite set having n distinct elements, then a one to one mapping (f) of P onto itself is
called permutation of degree n.

Degree of permutation:- It is the number of elements in the finite set P.


Symbolically we can say that if f : P P is one-one onto then the mapping f is called permutation.
Let f (a1) = b1, f(a2) = b2, f (a3) = b3, .., f (an) = bn where {b1, b2, b3, ..bn} = {a1, a2, a3, ..an}. It should be
noted here that since the mapping is onto therefore b1, b2, b3, .bn are nothing but some arrangement of a1, a2,
a3, .an. It means that each value or element in {b1, b2, .bn} shall definitely be an element in the set {a1, a2,
an}. Both the sets are the same with different arrangement. e.g. If the set P = {a1, a2, a3} = {1,2, 3} then the set
of bs can be obtained by arranging the elements of P in any way. It can be any one of the following six sets {1, 2,
3}, {2, 1, 3}, {1, 3, 2}, {3, 2, 1}, {2, 3, 1}, {3, 1, 2}. We can write the permutation in the form given below
f = (a1

a2

a3..an)

(f(a1) f(a2) f(a3) f(an))


or
(a1

a2

a3 an)

(b1

b2

b3 .bn)

where b1 = f (a1), b2 = f (a2), b3 = f (a3) ..bn = f (an). It should be noted that since the function f is a onto ,
therefore any b shall be some a.
If P = {1, 2, 3} is a finite set having 3 elements then
f=

123
123

, g=

123
231

etc.

are all permutations of degree 3.

Equal permutations:- Two permutation f and g are said to be equal if f(a) = g(a) " a P.
For example if

f=

1 2 3 4 and g =

2 4 3 1

2 4 1 3

4 3 1 2

then we see that f(1) = 2 = g(1), f(2) = 4 = g (2), f (3) = (1) = g(3) and f (4) = 3 = g (4) therefore f =g

Interchange of Column:- The interchange of any number of columns of a permutation does not change it.

For example f =

1 2 3 4
2 4 1 3

3 2 1 4
1 4 2 3

in which first and third column have been interchange.


Similarly
a1 a2 a3 ..an
f=

b1 b2 b3 ...bn

an-1 an a1an-2
= bn-1 bn b1 ...bn-2

an a1 a2
=

bn b1 .b2

Number of Permutation:- If the number of elements in the set P is n, then the total number of distinct
permutations shall be n! . Pn, the set of all permutations of degree n shall have n distinct elements. This set Pn is
called the symmetric set of permutation of degree n. Symbolically Pn = {f : f is a permutation of degree n}.P3 the set
of all (= 3! = 6) permutation of degree 3 is given by

P3 =

Identity Permutation:- Let P be a finite set having n elements and I is a one-one mapping such that each element
is replaced by the element itself, then I is called the identity permutation of degree n.

3.n

a1 a2 ..an

For example I =

or
1 2

3 ....n

a1 a2an

is the identity permutation of degree n.

In I =

1 3 2

= 1 2

1 3 2

1 2

each is an identity permutation of degree 4.

2.13..1 Product or Composition of two Permutation

The product P1 P2 of two permutation P1 and P2 means the result of applying first P1 and then P2.
[Note:- Some authors define the product P1 P2 as the result of applying first P2 and then P1]
Product by definition I:- The product (as given by definition I) is easily obtained by writing P2 in such a way that
entries in its first row follows the order of entries appearing in the second row of P1. It should be noted that in
changing the order of entries of first row of P2, the order of entries of the second row of P2 is also adjusted so that
the rearranged P2 must remain equal to the original P2.
Then the product P2 P1 shall be the permutation whose first row is the first row of P1 and whose second
row is the second row of rearranged P2.

For example if P1 =

1 2 3
and P2 =

1 2

3 1 4

then the rearranged

P2 =

4 1

2 3

1 2 3

and then P2P1 =

1 2 3

4 1 2

.
3 1 4

4 1

2 3

.
2 3 1 4

(after rearranging P2)

first row of P1
=
second row of rearranged P2

2.14 Group of Permutation

Theorem 1:- The set Pn of all permutations on the set A = {a1, a2, ..an} is a finite group of order n with respect to
the composition of product of permutations or composite of permutations.

a1 a2 an
Proof:- Let f =

b1 b2 .. bn

be a permutation of degree n. The elements in the second row of f are


simply the arrangement of the n elements in its first row. The total number of such arrangements is n , and
corresponding to each arrangement we shall have one permutation. Therefore the total number of permutation or
the number of distinct elements in Pn shall be n! . Now we shall prove that Pn forms a group, the given
composition being product of permutation.

1. Closure property:- We know that if f1 and f2 are any two permutations each of order n, then f1f2 is also a
permutation of order n and therefore f1, f2 Pn Pn (f1f2)also Pn, " f1 and f2 Pn, Thus Pn is closed with respect
to the operation product of permutations.

2. Associativity:-

Let f1 =

a1 a2 .an
b1 b2 ..bn

b1 b2 .bn
, f2 =

c1 c2 .cn

c1 c2 ... cn
and f3 =

d1 d2dn

Associativity:- If f1, f2 and f3 are three permutation each belonging to Pn then we shall prove that for any element r
A. ((f3f2)f1)r = f3(f2f1)r
We have ((f3f2)f1) (r) = (f3f2)(f1 (r))
= f3 (f2 (f1(r))) .(1)
and f3(f2f1) (r) = f3 ((f2f1) (r))
= f3 (f2 (f1 (r)) ..(2)
From (1) & (2) the associativity property is proved.

3. Existence of identity:- The permutation I defined by I (r) = r, " r A is the identity element of Pn.
If Pi is any other element of Pn, then for any r A,
PI(r) = P(I (r)) = P(r)
and IP(r) = I (P(r)) = P(r)
Therefore the identity element exists and is given by I = a1 a2 an
a1 a2an
-1

4. Existence of inverse:- Let P Pn, then since P is a one-one mapping of A onto itself, P is also defined as a oneone mapping of A onto itself.
-1

-1

-1

Therefore P Pn and P P = I = PP [ If P = 1 2 .n
a1 a2..an

-1

then P =

a1 a2 .an
1

2n

which proves the existence of inverse for each element P Pn


Therefore Pn forms a group with respect to the operation of product of permutations.
Note:- 1. The group of all n permutation of a set with n elements is called a symmetric group of degree n. (n is a
positive integer)
2. Any group whose elements are permutations is called a permutation group.

2.15 Cyclic Permutation or cycle

Let A be a set having n distinct elements and f be a permutation of degree n on the set A. Now if we arrange m
elements (out of n elements of A) in a row in such a manner that (i) the f-image of each element in the row is the
element which follows it (ii) the f image of the last element is the first element and (iii) the remaining n-m
elements of the set A are left unchanged by f, then f is called a cyclic permutation or a cycle of length m or an mcycle.
For example:- the permutation f =

1 2 6 3 5 4
2 4 6 1 5 3

is a cycle of length 4 which can be represented by (1 2 4 3). Hence each element of the bracket (1 2 4 3) has been
replaced by the element following it, the last element 3 being replaced by the first element 1. 1 is replaced by 2, 2
is replaced by 4,4 is replaced by 3 and 3 is replaced by 1. The rest of the element 6 and 5 are left unchanged.

The permutation g = 1 2 3 4 5

is a cycle of length 5 and can be represented as (1 2 3 4 5 )

2 3 4 5 1

The permutation 1 2 3 4

is a cycle of length 3 and can be represented by (1 2 3)

2 3 1 4

The permutation f =

1 2 3 4 5
1 3 2 5 4

is not a cycle.

f = (2 4 5 7) A (having 10 distinct elements means that f (2) = 4, f (4) = 5, f (5) = 7, f (7) = 2 and f (j) = j for j 2, 4,
5, 7

Different permutation represented by a cycle


Suppose we have a cycle of length 4 represented by (1 3 4 6) then this cycle can be used to represented
permutation of different degrees.
If we want to represent a permutation f1 of degree 7 on a set A = {1, 2, 3, 4, 5, 6, 7}

f1 =

1 3 4 6 2 5 7
3 4 6 1 2 5 7

Similarly the permutation f2 of degree 6 on the set A = {1, 2, 3, 4, 5, 6} represented by the cycle (3, 6, 4) shall be
given by f2 =
3 6 4 1 2 5
6 4 3 1 2 5

[First we write in the upper row, the elements 3, 6, 4 in this order and then the remaining elements 1, 2, 5 of the
set A. Then in the second row, we replace 3 by 6, 6 by 4 and 4 by 3 according to the cycle (3 6 4) and after this we
replace the remaining elements of the first row by the same elements in the same order.]
Permutation of degree 5 on the set {1, 2, 3, 4, 5} represented by the cycle (1 3 5 4) shall be

1 3 5 4 2
3 5 4 1 2

Equality of cycle :If the places of the elements in a cycle are changed, in such a way that their cyclic order remain
unchanged, then the cycle does not change.
For example (1 3) = (3 1), (3 4) = (4 3), (1 2 3) = (2 3 1) = (3 1 2)
or (1 2 3 4 ) = (2 3 4 1) = (3 4 1 2)
= ( 4 1 2 3)

Transposition:A cycle of length 2 is called a transposition. The cycle (2 4) is a transposition and the permutation of
degree 4 on the set {1, 2, 3, 4} represented by this cycle shall be given.

2 4 1 3
f=

4 2 1 3

1 2 3 4
1 4 3 2

Cycle of length one :In the permutation corresponding to such a cycle, the image of the element included in the
cycle shall be the element itself and the remaining elements of the set A shall remain unchanged. Therefore the
permutation represented by a cycle of length 1 shall be the identity permutation.

Multiplication of cycles:In order to multiply cycles, we multiply the permutation represented by them. For
example

(1 2 3) (4 6 5) = 1 2 3 4 5 6
2 3 1 4 5 6

4 6 5 1 2 3
6 5 4 1 2 3

1 2 3 4 5 6
=

2 3 1 6 4 5

Similarly (1) (3 4 5) = (3 4 5)

Disjoint cycles:Two cycles having no symbol in common are called disjoint cycles.

Some observations on cycles


1.

Product of two disjoint cycles is commutative.

2.

Inverse of a cyclic permutation


-1

(1 2 3n) = (n n-1 2 1)
-1

-1 -1

3.

If f and g are two cyclic permutation then (fg) = g f

4.

Every cycle can be represented as a product of transpositions in an infinite number of ways e.g. (a1 a2
an)
= (a1 a2) (a1 a3) .(a1 an)
or (2 3 5 4) = (3 5) (3 5) (3 2)

5.

A permutation is said to be even if it can be expressed as a product of an even number of transpositions,


otherwise it is said to be an odd permutation.

2.16 Order of an element in a group

If (G, *) is a group, then order of an element a G is defined as the least positive integer n if it exists, such that a =
a * a * a..n times = e, the identity element. It is denoted by 0(a). If no such number n exists then order of a is
zero or infinity.
e = e, so 0(e) = 1
If 0(a) = 1, then a = a = e

Example :- Find order of each element of the group (G, *) where G = {1, -1, i, -i} the composition being simple
multiplication.
Solution:- We have already seen that the identity element of the group is 1. Now 0(1) = 1.
1

Now (-1) = -1, (-1) =(-1)*(-1)= 1 (identity element)


so 0(-1) = 2
1

(i) = i, (i) = i * i = -1, (i) = 1 so 0(i) = 4


1

(-i) = -i, (-i) = -1, (-i) = i, (-i) = 1, so 0(-i) = 4

Example :- Find order of 1 and 3 of the group (G, *) where G = {0, 1, 2, 3, 4, 5} and the composition * is addition
modulo 6.
Solution:- We know 0 is the identity element so 0(0) = 1.

Now (1) = 1, 1 = 1 + 61 = 2, 13 = 1 + 61 + 61
4

= 1 + 62 = 3, (1) = 1 + 61 + 61 + 61
5

= 1 + 31 = 4, (1) = 1 + 61 = 1 + 64 = 5
6

(1) = 1 + 61 = 1 + 65 = 0 so 0(1) = 6
Again 31 = 3, 32 = 3 + 63 = 0 so 0(3) = 2

2.17 Subgroups of a group: Let (G, *) be a group. A nonempty subset H of G is called a sub-group of G if
(a) a * b H " a, b H i.e.. * is a binary operation on H.
(b) (H, *) is itself a group.
For example (Z, +) is a subgroup of (Q, +), (R, +) and (C, +).
Similarly (Z, +), (Q, +), and (R, +) are all subgroups of (C, +).

Theorem :- If (H, *) is a subgroup of (G, *) then the identity element in (H, *) is the same as in (G, *)
Proof:- Let e be the identity element in (G, *) and h the identity element in (H, *), then
h * a = a * h = a " a H (1)
As H G, so a G and therefore a * e = e * a = a
From (1) & (2) h * a = e * a (2)
or h = a (by right cancellation law)
Hence identity element in the group (H, *) is also e.

Theorem :- The inverse of any element of a subgroup is the same as the inverse of the same element regarded as
the element of the group.
Proof:- Let e be the identity of G as well as H.
Let a H. Let b be the inverse of a in H and c be the inverse of a in G. Then b * a = e and c * a = e. Therefore in G,
we have b * a = c * a or b = c (by right cancellation law)
-1

Note:- 1. Since (H, *) is a group, therefore " a H, a H.


Therefore we can say that (H, *) is a subgroup of (G, *) if and only if (a) e H (b) a, b H a * b H (c) a H
-1
a H.

2. Instead of saying that (H, *) is a sub-group of (G, *), we generally say that H is a sub-group of G provided that
there is no confusion about the binary operation.

Theorem :-Necessary and sufficient condition for (H, *) being a sub group of (G, *). If H is a non-empty subset of a
-1
group G, then (H, *) is a subgroup of (G, *) if and only if a, b H a * b H.
Proof:-1

-1

(i) Let (H, *) be a subgroup of (G, *), then a, b H a, b H a * b H (since


* is a binary operation).
-1

(ii) Conversely, as H is non empty set, there must exist an element a H and then a * a = e H (as H is a group).
-1
-1
-1
Again for any a H, e * a = a H. Also if a, b H, then a * b H (given).
-1 -1

So a * (b ) = a * b H.
or H is closed under the operation *. Hence H is a subgroup.

2.17.1. Properties of Subgroups

Theorem :- Let G be a group, H be a subgroup of G and K be a subgroup of H. Then K is a subgroup of G.


-1

Proof:- Since K is a subgroup of H, K and a * b K " a, b K. Therefore K is a subgroup of G.

Theorem 5:- If H and K are two subgroups of G then H K is also a subgroup of G.


Proof:- Let e be the identity of G. Then e will also be the identity element in H as well as in K.
H, e K.
Thus e H K and H K
-1

Let a, b H, a * b H (as H is subgroups of G)


-1

Similarly a, b K, a * b K
-1

Thus a * b H K
Hence H K is a subgroup of G.

Theorem :- The normaliser of an element a in a group (G, *) is a subgroup.

i.e. e

Proof:- As a G and e * a = a * e, therefore e is an element in the set of Normaliser N(a). Thus N(a) . So N(a) is
a non empty set of G. Let x1, x2 N(a).
-1

To prove that N(a) is a subgroup of G we have to prove that x1, x2 N(a) then x1 * x2 N(a) which is necessary &
-1
sufficient condition for a subgroup, which means that we have to prove that (x1 * x2 ) commutes with a. Thus we
have to prove that
-1

-1

(x1 * x2 ) * a = a * (x1 * x2 ) (1)


Now as x1, x2 N(a). It means x1 * a = a * x1 and x2 * a = a * x2 .(2)
-1

-1

-1

-1

Therefore x1 * a = a * x1 and x2 * a = a * x2 ..(3)


-1

[by the property of group that if a G commutes with x G, then a also commutes with x.]
-1

-1

From (3) we conclude that x1 , x2 N(a) [since these commutes with a].(4)
-1

-1

Now we have (x1 * x2 ) * a = x1 * (x2 * a)


-1

= x1 * (a * x2 ) .by (3)
-1

=(x1* a) * x2

-1

=(a * x1) * x2

-1

=a * (x1 * x2 )
Which proves (1)

Theorem :- The centre of a group (G, *) is a subgroup of (G, *)


Proof:- Let Z(G) be the centre of (G, *). The identity element e commutes with every element of G i.e. e * a = a, "
a G, therefore e is an element of Z(G). Thus Z(G) .
i.e. Z(G) is a non empty set.
-1

Let x1, x2 Z(G). In order to prove Z(G) as a sub group we shall have to show that x1 * x2 Z(G).
-1

-1

or (x1 * x2 ) * g = g * (x1 * x2 ), " g G (1)


Now x1, x2 Z(G), we have x1 * g = g * x1 and x2 * g = g * x2 " g G
-1

-1

(x1 * x2 ) * g = x1 * (x2 * g)
-1

=x1 * (g * x2 )
-1

= (x1 * g) * x2

-1

=(g * x1) * x2

-1

=g * (x1 * x2 )
which proves (1)

2.18 Cyclic Groups

First we shall define integral power of an element in a group and then define cyclic group.

Integral powers
Let (G, *) be a group and a G, then we define
0

a = e (the identity element of G)


1

0+1

=a *a=e*a=a

1+1

=a*a

a =a
a =a
-2

2 -1

-1

-1

a = (a ) = (a * a) = a * a
In general a
-n

n+1

-1

= a * a, n N {0}

n -1

and a = (a ) , n N

Cyclic group

A group (G, *) is called cyclic if for some element a G every element x G is of the form a , where n is some
integer.
The element a is called the generator of G. We write G = {a} or G = (a). The elements of G shall be of the form
-3

-2

-1

..a , a , a , a (=e), a, a , a ..
There can be more than one generator of a cyclic group.
2

For example the multiplication group (G, *), where G ={1, -1, i, -i} is cyclic as G can be written as {i, i , i , i }. Hence i
is the generator.
2

We can also write G = {-i, (-i) , (-i) , (-i) }. Here i is also a generator of G.

Similarly multiplicative group {1, w, w } is cyclic with w and w as generators.


Also the group G = ({0, 1, 2, 3, 4, 5}, +6) is cyclic having 1 as well as 5 as generators.

2.19 Normal Subgroup

A subgroup N of a group is called a normal subgroup of G if N * x = x * N " x G and it is written as N G.


Any group G has two normal subgroups {e} and G itself, since {e} x = {e} = x{e} and for any x G, G x = G = x G.

2.20 Isomorphism & Homomorphism

Definition:Let (X, *) and (Y, 0) be two algebraic system of the same type in the sense that both * and 0 are binary
(n-ary) operations.
A mapping g : X Y is called a homomorphism or simply morphsim from (X, *) to (Y, 0) if for any x1, x2 X,
g (x1 * x2) = g (x1) 0 g (x2)
If such a function g exists, then it is customary to call (Y, 0) a homomorphic image of (X, *). g(x) Y.
This definition of homomorphism is not restricted to algebraic system with one binary operation. It can be
extended to any two algebraic systems of the same type.

Definition:Let g be a homomorphism from (X, *) to (Y, ). If g: XY is onto, then g is called an epimorphism. If g:


XY is one-to-one then g is called monomorphism. If g:X Y is one-to-one onto, then g is called an isomorphism
and (X, *) and (Y, ) are said to be isomorphic. The mapping g preserves the composition in X and Y.

2.21. Group Homomorphism and Group Isomorphism

Now we shall confine in our further discussion to group as an algebraic system. We give below the definitions for
groups only.

Definitions:Let (G, *) and (G, ) be two groups. A mapping f : G G is called a group homomorphism from (G, *)

to (G, ) if for any x1, x2 G, we have f (x1 * x2) = f (x1) f (x2). It will be seen in the following discussion that the
group homomorphism preserves the composition in G and G. It also preserves identities, inverses and subgroups.
A group homomorphism is called a monomorphism if the mapping is one-to-one.
A group homomorphism is called epimorphism if the mapping f is onto.
A group homomorphism is called isomorphism if the mapping is one-to-one and onto.
Thus if (G, *) and (G, ) are two group, then a mapping f : GG is called an isomorphism if
(i) f is one-to-one (ii) f is onto and (iii) f is a homomorphism. G and G are called isomorphic groups or G is said to
be isomorphic to G and it is written as G @ G.
It means that for the function f to be Homomorphic, the results obtained in either of the following two cases must
be the same or equal.
1. If we apply the operation * of the group (G, *) between any two elements x1 and x2 (both belonging to G) to
obtain the result x1 * x2 and then apply the function f on this result to obtain the final result f (x1 * x2).
or 2. If we apply the function f to the elements x1, x2 G to get the f images as f (x1) and f (x2) respectively and
then apply the operation of the group (G, ) between these two f-images to get the final result f(x1) f(x2).

We can represent this concept of homomorphism diagrammatically also as follows-

Diagrammatic representation of homomorphic function

f:
(G, *)

(G, )

Apply f to get f-image


x1

f(x1)

Apply f to get f-image


x2

f(x2)

f(x1*x2)

f(x1)f(x2)

(x1 * x2)
Applying function f

or operate with function f

Result I

Result II

is equal to

for f to be homomorphic

Endomorphism and Automorphism

A homomorphism form a group (G, *) to (G, *) is called an endomorphism, and an isomorphism from a group (G,
) to (G, ) is called an automorphism.

Kernel:If f is a group homomorphism from (G, *) to (G, ), then the set of elements of G which are mapped into e
the identity of the group (G, ) is called the kernel of the homomorphism f and is denoted by ker (f).

Example :- If R is the additive group of real numbers and R+ the multiplicative group of positive real numbers, then
x
prove that the mapping f : RR+ defined by f(x) =e ," x R is an isomorphism of R onto R+.
x

Solution:- e is always a positive real unique number " x R. Thus f : RR+


x1

x2

x1

x2

(i) To prove that f is one to one:- " x1, x2 R, f(x1) = f(x2) e = e loge = loge x1log e = x2log e x1 = x2
which means that two elements in R have the same f-images in R+ only if they are equal i.e. distinct element in R
have distinct f -images in R+. Thus f is one to one.
(ii) To prove that f is onto:- Let y be any element of R+, then log y is a real number (positive, zero or negative) i.e.
logy R.
logy

Now f(log y) = e = y. Thus y R+ that there exist its image log y in R i.e. f(log y) = y. Therefore each element
R+ has its pre image in R. Thus f is onto.

(iii) To prove that f is homomorphism (R, +) (R, ).


x1

x2

Let x1, x2 R, their images e , e R+. Now if we apply the operation + of the first group between x1 and x2 and
x
then operate the result with the function f(x) = e we get the following result
+
x1, x2

f(x) = e
(x1 + x2)

x
x1+x2

x1

x2

= e .e .(1)

Again if we apply the operation of the second group between the f-images of x1 and x2 in R+. We get following
result.
x
x1

e ,e

x2

x1

x2

e . e (2)

From (1) & (2) both the results are the same i.e. f preserves the composition in R and R+. Thus f is homomorphism.
Consequently the mapping f : R R+ is an isomorphism of R onto R+.
Note:- The homomorphism of f : R1 R+ can also be shown diagrammatically as given below.
x

f:e

Group (R+, )

Group( R, +)

Applying f = e

x1

x1

Applying f = e

x2

x2

(x1+ x2)

x1

x2

(x1+ x2)

or e
(x1 + x2)
x
Applying f = e

Result I = Result II

Example :- If there are two groups (i) additive group of integers (I, +) and (ii) additive group of even integers (2I, +),
and f is a mapping from (I, +) (2I, +) defined by f(x) = 2x, x I, then prove that f is an isomorphic mapping.
Solution:- (i) Since f(x1) = f(x2) 2x1 = 2x2 or x1 = x2 therefore f is one-to-one mapping.
(ii) 2x 2I, f(x) = 2x 2I, it follows that f is onto mapping.
(iii) f(x1 + x2) = 2(x1 + x2) = 2x1 + 2x2 = f(x1) + f(x2) " x1, x2 I, hence f is homomorphism mapping. Consequently f is
an isomorphic mapping.

Example:- If (G, *) is a group and IG : G G defined by IG(x) = x, " x G is identity mapping on G, prove that IG : G
G is an isomorphism.
Solution:- (i) Since IG(x1) = x1 and IG(x2) = x2, x1 x2 G then IG(x1) = IG(x2) x1 = x2 which proves that IG is one-to-one
mapping.
(ii) Since IG(x) = x and IG : G G it means that corresponding to each value x codomain there exists a value in the
domain of G. Hence IG is onto.
(iii) Also IG(x1*x2) = x1 * x2 = IG(x1) * IG(x2). Thus I is homomorphism. Hence IG is isomorphism.

Theorem :- Let (G, *) and (G, ) be two groups and also let f : G G be an isomorphism, then f
also an isomorphism.
-1

-1

Proof:-As f is isomorphism it is one to one onto and therefore f is also one-one-onto. Now to prove
-1
isomorphism, we have to prove only that f is a homomorphism.

: G G is

-1

as an

As f is one to one onto therefore corresponding to x1, x2 G we have x1, x2 G such that f(x1) = x1 and f(x2) = x2.
-1
-1
-1
-1
Thus f (x1) = x1 and f (x2) = x2. We know that f(x1 * x2) = f(x1) f(x2) = x1 x2 f (x1 x2) = x1* x2 = f (x1) f
1
-1
(x2). Therefore f : G G is a homomorphism.
Theorem:- Let (G1, 1), (G2, 2) and (G3, 3) be three groups. Also let f : G1 G2 and f2 : G2 G3 be
homomorphism, then f2 f1 : G1 G3 is also a homomorphism.
Proof:-Let x1, x2 G1, then
(f2 f1) (x1 x2) = f2(f1(x1 x2))
=f2(f1(x1) 2 f1(x2))
=f2((f1(x1)) 3 f2(f1(x2))
=(f2 f1)(x1) 3 (f2 f1) (x2)
Hence f2 f1 is homomorphism.

Theorem - Let f be a homomorphic (or isomorphic) function or mapping of a group G = (G, *) into a group G = (G,
*) then
(i) f-image of identity e of G is the identity e of G i.e. f(e) = e
-1

-1

(ii) f image of the inverse of an element a of G is the inverse of f-images of a i.e. f(a ) = [f(a)]
Proof:- a G
e G therefore a * e = e * a = a .(1)
(identity property)
f(a) G
e G

therefore f(a) * e = e * f(a) = f(a) ..(2)


(identity property)

Now e * f(a) = f(a) .by (2)


= f(e * a) .by (1)
= f(e) * f(a) (3)
[by Homomorphic property that if a, b (G, *), then f(a), f(b) (G, o) then f(a * b) = f(a) o f(b) (preservation of
operation)]
or e = f(e), by right cancellation rule.

(G, *)

f(a)

(G, *)

(ii) We have proved that


-1

e = f (e) = = f (a * a ) by inverse property .(1)


-1

(a, a G whose identity is e)


-1

-1

-1

= f(a) * f(a ) [by Homomorphic property a, a G & f(a), f(a ) G]


-1

-1

or f(a) * f(a ) = e (identity of G), Therefore inverse of f(a) is f(a )

-1

-1

-1

-1

i.e. [f(a)] = f(a ) or f(a ) = [f(a)]

f(a)

-1

f(a )

e
Theorem :-Let (G, *) and (G, o) be two groups and H be a subgroup of G. If f : G G is a homomorphism, then
f(H) is a subgroup of G.
Proof:- The identity of G = identity of H = e(say) since H is a subgroups of G. Therefore identity e of (G, ) = f(e)
and e f(H). It means f(H) is a non empty set.
For x, y H, we have x, y f(H) such that x = f(x) and y = f(y). Since H is a sub group of G and x, y H, we have x
-1
o y H. Again as f is a homomorphism, we have
-1

-1

-1

-1

F(x o y ) = f(x) o f(y ) = f(x) o [f(y)] = x o (y)

Therefore x o y f (H) and consequently f (H) is a subgroup of G.

Theorem :- Let (G, *) and (G, ) be two groups and H be a subgroup of G. If f : GG is a homomorphism, then f
(H) of a subgroup of G.

-1

Proof:- As e G is in H and f(e) = e, and f (H) = {x G: f(x) = H}


-1

-1

we have e f (H) so f (H) .


-1

-1

Let x1, x2 f (H) then f(x1) and f(x2) H and since H is a subgroup of G, we have f(x1) o (f(x2)) H . Again as f is
homomorphism, we have
-1

-1

f(x1) o f(x2 ) H or f(x1 o x2 ) H


-1

-1

-1

or x1 o x2 f (H). Thus f (H) is a sub group of G.

Theorem :-The kernel of a homomorphism f from a group (G, *) to (G, ) is a subgroup of (G, *).
Proof:- Since f(e) = e, therefore e ker (f). It x1, x2 ker (f), i.e. f(x1) = f(x2) = e then
f(x1 * x2) = f(x1) f(x2) = e e = e.

-1

-1

-1

Thus x1 * x2 ker (f). Again if x1 ker (f), then f(x1 ) = [f (x1)] = (e) = e.
-1

Therefore x1 ker (f) and ker (f) is a subgroup of (G, *).

2.22. Rings :Let R be a non empty set equipped with two binary operations denoted by * and o respectively, then
the algebraic structure (R, *, o) is called a ring if it satisfies the following postulates.
1. The first operation * is associative i.e. (a * b) *c= a* (b * c) " a, b, c R
2. The first operation is commutative i.e. a * b = b * a " a, b R
3. There exists an elements o R for the first operation such that

o * a = a, " a R

4. To each element a R there exists an element (-a) R such that

(-a) * (a) = o

5.The second operation o is associative i.e. ao(boc)= (a o b) o c, " a, b, c R


6. The second operation o is distributive over the first operation * i.e
a o (b * c) = a o b * a o c (left distributive law)
and (b * c) o a = b o a * c o a (right distributive law)," a, b, c R.
Note:- In place of notation * and o we may use the notation and or + and also.
Important:- It is clear that the postulates (1) (4) are the requirements that R is an abelian group with respect to
the first operation * and hence both the cancellation laws hold good for the first operation * in R.

2.22.1

Commutative Ring: It is a ring R in which the second operation o is commutative i.e. a o b = b o a " a, b,
R.

2.22.2. Ring with Unity:It is a ring R which contains an identity element 1 R for the second operation o or if in a
ring R there exists an element denoted by 1 such that 1 o a = a o 1 = a, " a R then R is called a Ring with Unity.

2.22.3. Null Ring or Zero Ring:The set R consisting of a single element 0 (identity element) and equipped with two
binary operation defined 0 * 0 = 0 and 0 o 0 = 0 is called null ring.

2.22.4. Properties of a Ring

In a ring R, " a, b, c R
(a)
ao0=0oa=0
(b)
a o (-b) = - (a o b) = (-a) o b
(c)
(-a) o (-b) = a o b
(d)
a o (b c) = a o b a o c
(e)
(b c) o a = b o a c o a
Proof:- (a) a o 0 = a o (0 * 0)
[since 0 * 0 = 0, 0 being identity in R for *]
=ao0*ao0
or 0 * a o 0 = a o 0 * a o 0 [since a o 0 = 0 * a o 0 as a o 0 R and 0 is identity for * in R]
or 0 = a o 0 [by right cancellation law which holds in a ring for the first operation *] ..(1)
Similarly 0 o a = (0 * 0) o a = 0 o a * 0 o a
or 0 * 0 o a = 0 o a * 0 o a
or 0 = 0 o a (by right cancellation law).(2)
From (1) & (2) we have a o 0 = 0 o a = 0
(b) we know that a o [(-b) * b] = a o 0 (since o is identity in R for *)
or a o (-b) * a o b = 0 [since a o 0 = 0 by result (a)
or a o (-b) = -a o b [since in a ring R, a * b a = -b]
Similarly (-a o a) o b = 0 o a
or (-a) o b * a o b = 0
or (-a) o b = -(a o b)
(c) We know that (-a) o (-b) = -[(-a) o b]

[since a o (-b) = -(a o b)]

= -[-(a o b)] (since (-a) o b = -(a o b)]


=aob

(since R is a group w.r.t * in which (-a) = a)

(d) a o (b c) = a o [b * (-c)]
= a o b * a o (-c) = a o b * [-(a o c)]
=aobaoc
(e) (b c) o a = [b * (-c)] o a = b o a * (-c) o a
= b o a * [-(c o a)]

=boacoa

Examples of Rings

How to prove an algebraic structure (R, *, 0) to be a Ring:


The various steps to be followed are given below:
1. First prove that the two operations * and 0 are binary operations, if it is given that the two operation are binary
operations, then proceed to step 2.
2. Prove that R is an abelian group with respect to one of the two operation say *. It is achieved by proving that the
first four postulates of 4.1 are satisfied.
3. Then prove the satisfaction of fifth and sixth postulate of section 4.1 with respect to the operation 0.
4. To prove it a commutative ring, the condition given in section 4.1.1 has to be satisfied.
5. To prove it to be Ring with unity, the condition given in section 4.1.2 has to be satisfied.

Example :- If (R, *, 0) is a ring such that a = a, a R then prove that


(i)
a * a = 0, a R i.e. each element of R is its own addition inverse.
(ii)
a*b=0a=b
(iii)
R is a commutative ring.
2
Solution:- (i) a R a * a R (* being binary operation), As a = a,
2

we have (a * a) = (a * a)
(a * a) (a * a) = a * a
((a * a) a) * ((a * a) a) = a * a

by distributive law

((a a) *(a a) ) * ((a a) *(a a) = a * a


2

(a * a) * (a * a) = a * a [as a = a a = a is given]
(a * a) * (a * a) = (a * a) * 0, since a + = a
(a * a) = 0 (by left cancellation law)
(ii) a * b = 0 a * b = a * a (proved in (i))
b = a (by left cancellation law
2

(iii)Given that (a * b) = a * b

(a * b) o (a * b) = a * b
((a * b) o a) * ((a * b) o b) = a * b
[(a o a) * (b o a)] * [(a o b) * (b b)] = a * b
[a * ( b a)] *[a b * b] = a * b ( as a a =a , b b)
or (a * b) *[ (b o a) * (a o b)] = a * b * (by associativity)
(b o a) * (a o b) = 0 (by left cancellation law)
a o b = b o a (by (ii)). So R is commutative.

Example :- Prove that set I of all integers is a ring with respect to addition and multiplication of integers as the ring
composition.
We have to prove the (I, +, ) is a ring
Solution:- 1. It is known that a + b I " a, b, I. Therefore addition and multiplication are binary operations.
2. We have already proved that the set I of all integers is an abelian group for the composition of addition +.
This proves the first four postulates of section 4.1.
3. We know that multiplication of integers is associative.
4. We also known that multiplication is distributive over addition in the set I i.e.
a (b + c) = ab + ac

" a, b, x I

and (b + c) a = ba + ca
It satisfies the sixth postulate.
Therefore (R, + , ) is a ring.
Now since a + 0 = 0 = 0 + a " a I zero is the zero element or identity for addition.

Example:- Prove that (I, +, ) is a cumulative ring with unity.


We have already proved that (I, +, ) is a ring.
As the multiplication of integers is a commutative composition, it is a cumulative ring. Also, since 1 a = a 1 = a
" a I, 1 is the identity for the second operation of multiplication. Thus 1 is a ring with unity.

2.22.5. Zero divisors

Let R be a ring. An element a R is said to be a left zero divisor if there exists an element b 0 R such that a b
= 0 (zero element or identity element for the operation *)
Similarly if an element b 0 R exists such that b o a = 0, then element a is said to be the right zero divisor.
or we can say that if corresponding to a non zero element a R, there exists a non zero element b R such that
either a o b = 0 or b o a = 0 then the element a is said to be the zero divisor or divisor of zero. In such a case the
ring R is said to be a ring with zero divisors.
Again if the product of no two non zero element of R is zero (means zero element or identity element for the
operation *) i.e. if a o b = 0 a = 0 or b = 0, then the ring R is said to be a ring without zero divisors.
[Note:- Zero on the R.H.S means the zero element for the operation *]
Example :-If M is a set of 2 2 matrices with their elements as integers and the two compositions are addition and
multiplication of matrices, then (M, +, ) is a ring with zero divisors as seen below
Here the zero element is the null matrix

0=

If A =

1 0

and

B=

0 0

Then

1 0
0 0

= 0

Thus the product of two non zero element of the ring is equal to the zero element of the ring. Hence M is a ring
with zero divisors.

Example :- If M = {0, 1, 2, 3, 4, 5}, then the ring (M, +6, x6) is ring with zero divisor as seen below
Here the zero element is 0 (zero) and the product (x6) of two non zero elements is zero
3 = 0, 3 x6 4 = 0

i.e. 2 x6

But if M = {0, 1, 2, 3, 4} then the ring (M, +5, x5) is not a ring with zero divisor or it is a ring with out zero divisor as
the product (x5) of no two non zero elements is zero.

2.22.6 Cancellation laws in a ring

Theorem :- A ring is without zero divisors if and only if the cancellation laws hold in R.
Proof:- Let R be with out zero divisor. It means that the product (the result obtained on applying second operation)
of no two non zero elements in the ring is zero i.e. a, b R, then a o b = 0 either a = 0 or b = 0.
Now let a, b, c R such that a 0 and a o b = a o c
Then a ob = a o c (a o b a o c) = 0
a o (b c) = 0
As a 0 and R is without zero divisors therefore b c = 0 or b = c.
Thus a o b = a oc b = c which means that left cancellation law holds. Similarly it can be shown that right
cancellation law also holds.
Conversely that cancellation laws hold in R. If possible, let a o b = 0 when a 0, b 0 i.e. R is with zero
divisor.
Then we have a o b = a o 0 (since a o 0 = 0 by properties of a Ring)
As a 0 a o b = a o 0 b = 0

(by left cancellation law)

which is against our assumption. Thus we get a contradiction. Therefore R is without zero divisor.

2.23. Integral Domain: A ring which (i) is commutative (ii) has unit element and (iii) is without zero divisors, is
called an integral domain.

Example :- Show that the ring ({0, 1, 2, 3, 4)} +5 , 5 is an integral domain.


Solution:- We have already proved in example 7 that this ring is a commutative ring with unit element. Now from
the composition table it is seen that " a, b R, a b = 0 either a = 0 or b.
Hence it is without zero divisor. Consequently the given ring is an integral domain.

Theorem :- A commutative ring R is an integral domain, if and only if, for any non zero element x R, x o a = x o b
a = b where a, b R.
Proof:- Suppose that R is a commutative ring and x o a = x o b a = b where x 0. x, a, b R.

(1)

Putting a = x1 and b = 0 in (1), we have for x 0 xox1 = x o 0 x1 = 0 which means that R is without zero divisor.
Thus R is an integral domain.
Conversely let R be an integral domain.
x o a = x o b x o (a b) =0. Since R is an integral domain, x 0, therefore a b = 0 or a = b.

2.24 Field:A ring (R, *, o) with at least two elements is called a field if
(i) it is commutative (ii) it possesses a unit element and (iii) it is such that each non-zero element possesses an
inverse with respect to the operation 0.

Example: The ring (Q, +, .) of rational numbers is a field, because it is commutative ring with unity and each non
zero element (=p/q) possesses an inverse (=q/p).
(ii) The ring ({0, 1, 2, 3, 4)} +5, x5) is also a field.
Note:- A field has no zero divisor. Thus in a field the product of two non zero elements is a non zero element.

Theorem :- Every field is an integral domain.


Proof:- As a field F is a commutative ring with unity therefore for a field to be an integral domain the field should
have no zero divisors, which we shall prove as follows.
Let a , b F, a 0 such that a o b = 0
-1

As a = 0, a must exist.
-1

-1

Now a o b = 0 a o (a o b) = a o 0
-1

(a o a) o b = 0 1 o b = 0
b=0
-1

-1

-1

Similarly for a o b = 0 where b 0 we have (a o b) o b = a o b (as b 0, so b exists)


-1

a o (b o b ) = 0 a o 1 = 0 a = 0
Thus a o b = 0 a = 0 or b = 0. Therefore F is a field with no zero divisions and hence is an integral domain.

Note:- Converse of the above theorem is not true. For example, the ring of integers is an integral domain but it is
not a field because each non zero element (except 1 and -1) has no inverse in the set of integers.

Example:- Show that the set of numbers of the form a + b2 with a and b as rational numbers is a field under the
operation of addition and multiplication real numbers.
Solution:- Let R = {a + b2, a, b Q} be the given set, Let (a1 + b12) and (a2 + b22) R, where a1, a2, b1, b2 Q
We have (a +b12) + (a +b22 ) = (a1 +a2) + (b1+ b2)2 R, since a1 + a2 and b1 + b2 Q
Similarly (a1 + b12) (a2 + b22) = (a1a2 + 2b1b2) + (a1b2 + a2b1) 2 R
Since a1 a2 + 2b1b2 and a1b2 + a2b1 Q
Therefore R is closed with respect to addition and multiplication.
The elements in R are real numbers. We know that addition and multiplication of real numbers is associative as
well as commutative.
Also it is clear that 0 + 02 is the additive identity of R and (-a) + (-b) 2 is the additive inverse for an element a +
a2 R. Thus each element in R possesses an additive inverse.
We also know that multiplication distributives over addition in the set of real numbers.
Also (1 + 02) R is the multiplication identity for a + b2 thus R is a commutative ring with unity. Zero element of
the ring is 0 + 02 and unit element is 1 + 02. To prove it to be a field we have still to prove that each non zero
element of R possess a multiplicative inverse.
Let a + b2 be any non zero element of R. (both a and b are not zero)
2

Thus 1/( a + b2 ) = (a - b2)/(a + b2) (a - b2) = (a- b2)/(a 2b )


2

= a/ (a 2b ) + (-b) / (a 2b ) 2
2

Now as a and b are rational numbers, a 2b 0 (otherwise a = 0, b = 0). Therefore a/a 2b and b/a 2b
2
2
2
2
both are non zero and have a / (a 2b ) + (-b) / (a 2b )2 is a non zero element of R and is the mul plica ve
inverse of a + b2. Thus the given algebraic structure is a field.

2.25 Division Ring or Skew field :A ring with at least two elements is called a division ring or a skew field if it (i)
has unity (ii) is such that each non zero element possesses inverse under the second operation 0.
It means that a commutative divisions ring is a field. Every field is a division ring.

Examples :- The set Q =

where a, b are complex and `a, `b are

-b

their conjugates is a skew field with respect to matrix addition and multiplication. Zero of this ring is the zero
matrix. This ring is non commutative since the two element

-i

and

0
-1

do not commute

Theorem :-A ring R is a division ring if and only if the equation a o x = b and y o a = b have unique solution in R
where a 0, a, b R.
Proof:- Let R be a division ring. As non zero elements of R are invertible (possesses inverse), R is a group will
respect to the operation 0. Therefore the equations a o x = b and y o b = b have unique solution provided b 0. In
case b = 0, then a 0, a o x = b and y o a x = 0 and y =0 (since R has no zero divisor).
Conversely let a o x = b and y o a = b have unique solution in R and (R, *, 0) is a ring where a 0, a, b R. If b = a,
then a o x = a and y 0 a = a.
2

Thus a o x = a o (x o x) = (a o x) o x = a o x
2

or x = x or x = 1 (since x 0). Similarly we can show that y = 1. Hence R is a ring with unity. Also a o x = 1 and y o a
-1
= 1 a (a c). Hence R is a division ring.

Theorem :- A division ring has no divisor of zero.


-1
1

Proof:- Let R be a division ring and x1, x2 R such that x1 o x2 = 0 and x1 0. Therefore by definition of ring, x
-1
exists and x 1 R where
-1

x1 o x = x

-1
1

o x1 = 1
-1
1

x2 = 1 o x2 = (x

o x1) o x2 = x

-1

-1
1

o (x1 o x2) = x

o 0 = 0.

It means that for x1 0, x1 o x2 = 0 x2 = 0. Hence R is without zero divisor.

2.26 Sub-Ring:Let the algebraic structure (R, *, 0) be a ring. If S R such that (S, *, 0) is also a ring with respect to
the operations on R, then S is called sub ring of R.
Example:- (i) Set of integers is a sub ring of the set of rational numbers with respect to the same operations.
(ii) the set of even integers is a sub ring of the set of integers under the operations of addition and multiplication.

2.27 Sub-Field :Let the algebraic structure (F, *, 0) be a field. If S F such that (S, *, 0) is also a field with respect to
the operations of F then is S is called sub-field of F.

Example :-Field of rational numbers is a field of the field of real numbers.

UNIT-3
Lattices and Boolean algebra
3.1 Partial Order Relation
A binary relation R in a nonempty set S is called a Partial Order Relation or a Partial Ordering in S iff R is
(a) Reflexive i.e. a R a " a S
(b) Antisymmetric i.e. a R b and b R a a = b
a,bS
(c) Transitive i.e. a R b and b R c a R c
a,b,c S
A partial order relation is generally denoted by .
If is a partial order relation then the ordered pair ( P , ) is called Partially Ordered set or Poset.
It should be clear that these three conditions may or may not hold for all pairs of elements of the nonempty set S in
a Poset. There may be pairs of elements that may not satisfy all the three conditions. If any two elements a , b S
satisfy all the three conditions then we write a b which is read as a precedes b or b succeeds a .
Comparability
Let a and b be two elements in a partially ordered set S with respect to a certain relation R (called partial order
relation). Then a and b are said to be comparable if a b or b a i.e. either a R b or b R a or we can say that one of
them precedes the other. Otherwise a and b are said to be non comparable and is denoted as a b (neither a b
nor b a ). In a partially order set it is not necessary that all the pairs of the element are comparable.
Totally Ordered set or Chain
If every pair of elements of S is comparable, then the set S is said to be totally ordered or linearly ordered set or
Chain or Toset with respect to the given relation and the relation is said to be simple ordering or linear ordering on
S.
Every subset of a linearly ordered set is linearly ordered.

(a) Let S be a set of positive integers ( = N) and the relation R be divides i.e. a R b or
a b if a | b (a divides
b) , then ( N , ) is a poset and the relation (divides) is a partial order relation because all the three
conditions are satisfied.
(b) Let S be a collection of sets, then the relation of set inclusion is a partial order of S and ( S, ) is a poset.
(c) The set of all statement or the set of all statement formulae in a certain number of variables form a poset under
the ordering of tautological implication.
3.2 Hasse Diagrams of Partially Ordered Sets
Suppose S is a partially order set with respect to the relation i.e. ( S , ) is a poset. Then we write any two
elements a , b S as
a < b read as a strictly precedes b if a b and a b
b > a read as b strictly succeeds a if b a and b a
Immediate predecessor and successor.
Let (S, ) be a poset and a, b S.
We say that a is an immediate predecessor of b or b is an immediate successor of a or b is a cover of a written as a <
< b if a < b and no element of the set S lies between a and b. It means there exits no elements c S such that a < c <
b.
Immediate predecessor or successor may or may not exist.
Hasse Diagram
The Hasse diagram of a finite partially order set S is a diagram whose vertices represent the elements of S and if b is
an immediate successor of a (a < < b) in S then an edge or line is drawn directed from a to b. Instead of drawing a
line directed from a to b we take b at a higher level than a and join a and b by a straight line.
3.3 Minimal, Maximal, first and last elements of S
Let S be a partially order set so that (S, ) is a poset.
An element a S is called a minimal element of S, if no other element of S strictly precedes a, although the element
a may strictly precede other elements of S.
An element b S is called a maximal element of S, if no other element strictly succeeds b. although b may strictly
succeed other elements of S .
If the set S is infinite, then it may not have any minimal or maximal element. For example there is non maximal and
minimal element in the set of integers or the set of real numbers with respect to the relation (less than or equal to).
The poset (N, ) has minimal element but no maximal element.
If the set S is finite it must have at least one minimal element and at least one maximal element.
An element a S is called a first element or least element or zero of S if a precedes all other elements in S or a is
predecessor of all other element in S i.e. a x , " x S. It is generally denoted by 0. An element b is called last or
greatest element or unity of S if b succeeds all other elements of S (or b is the successor of all other elements of S)
or all other elements of S precedes i.e. y b " y S
It is generally denoted by 1.
Example: if A is a poset of non negative real numbers with the usual partial order (less than or equal to), then 0 is
its least elements.
(b) if A= {a,b,c,} and the poset B= P(A) the power set of A with Partial order relation inclusion (). Then j is a
least element of A and the set A is the greatest element.
Maximal and Greatest Elements, Minimal and Least Elements
A maximal element of set A does not precede any other element of set A, but it is not necessary that all the other
elements of set A shall precede it. Some of the elements may precede it while some may not precede it.
A greatest element also does not precede any other element of the set A, but it is necessary that all the other
elements of set A shall precede it i.e. greatest element succeeds all the other elements of set A.
Maximal elements may be one or more than one for a set while the greatest element can not be more than one:
Similarly the minimal element of set A does not succeed any other element of set A, but it is not necessary that all
the other elements of set A shall succeed it.
A least element of set A also does not succeed any other element of the set A , but it is necessary that all the other
elements of set A shall succeed it i.e. a least element precedes all the other elements of the set.
Minimal elements can be one or more than one but the least element can not be more than one.
In the following Hasse diagram (i) the maximal elements are d , f and g but there is no greatest element.
Similarly in the diagram (ii) the minimal elements are a and b but there is no least element.

e
d

f
c

e
b

(i)

b
( ii )

Example. Set S = {2,3,6,12,24,36}


Relation : x y if
Immediate predecessors :
12 < < 24 , 12 << 36 , 6 << 12 , 2 << 6 , 3 << 6
24
Minimal Elements : 2 and 3
Maximal Elements : 24 and 26
First Element : No element (since neither 23 nor 32)
Last Element : No element (since neither 2436 nor 3624)

x/y then Hasse diagram is as shown below:


36
12
6

3.4 Upper and Lower Bounds


Let (S, ) be a poset. Also let A S. An element u S is said to be the upper bound of A if u succeeds
every element of A or if every element of A precedes u i.e. x u, " x A.
Similarly an element l S is called the lower bound of A if l precedes every other element in A i.e. if l y, " y A.
These upper and lower bounds may or may not exist for a subset A of a partially ordered set S, Moreover even if
these bounds exist they may or may not belong to the subset A.
Also these bounds need not be unique.
Examples :- Let S = {1,2,3,----------------, 10} and the partially ordered relation be divides, then its Hasse diagram
shall be as shown below
8
10
6
4
9
5

2
1

If we take a subset A = {2,7} then A has no upper bound since there is no element u of S such that every element of
A i.e. 2 and 7 precedes u. its lower bound is 1 as 1 S, precedes every element of A.
If we take the subset A = {1,2,3}, then 6 is its upper bound as every element of A divides 6 and 1 is its lower bound.
Note :- If A has an upper bound, then A is said to be bounded above and if A has a lower bounded it is said to be
bounded below. A is said to be bounded if it has an upper bound and a lower bound.
Least Upper Bound ( or Supremum) and Greatest lower Bound (or Infimum)
If A is a subset of a partially ordered set S , then an element s S is called a least upper bound (lub) or supremum of
A if
(i)
s is an upper bound of A
(ii)
s u whenever u is an upper bound of A i.e. s precedes every other upper bound of A. It is denoted by
sup(A).
Similarly an element i S is called a greatest lower bound (glb) or infimum of A if
(i)
i is a lower bound of A
(ii)
l i whenever l is a lower bound of A i.e. i succeeds every other lower bound of A. It is denoted by inf(A).
Greatest and Least Elements of Subset A
if A S, then an element a is called the largest or the greatest element of A if
(i)
a is an upper bound of A
(ii)
aA
or an upper bound of A which is in A is called the largest element of A.
Similarly an element b is called the least or smallest element of A if
(i)
b is a lower bound of A
(ii)
bA
or a lower bound of A which is in A is called the least element of A.
If a is the largest element of A it is an upper bound of A and any upper bound u of a set A satisfies the condition that
all other elements of A must precede this upper bound u.
Now as a A, therefore a u i.e. a is the least upper bound or the supremum. Thus the greatest element is always
the supremum. Also a least element is always the infimum.
Well Ordered Set
Definition : A partially ordered set S is said to be Well ordered if every subset of S has first element or least
element.
Example :- Set N of positive integers with the partial order relation (less than or equal to) is a well ordered set.
Theorem:- A well ordered set is linearly ordered.
Proof:- Consider any two elements a , b S. By definition the set [a,b] has a least element. Therefore a and b are
comparable. This is true for every pair of elements belonging to S. Therefore S is a linearly ordered set.
Some other properties of Well Ordered Sets The following properties of a Well Ordered set follow directly from
its definition.
Every subset of a well ordered set is well ordered.
Every element a S other than a least element has an immediate successor. Because if M(a) denote the set of
elements which strictly succeed a, then the least element or first element of M(a) shall be the immediate
successor of a.
All finite linearly ordered set each having the same number n of elements are well ordered and are all isomorphic to
each other.
If A is well ordered and B is isomorphic to A, then B is well ordered.
Example:- (A linearly ordered set which is not well ordered)
The set Z of integers with partial order relation (less then or equal to) is linearly ordered and every element has an
immediate predecessor and an immediate successor, but Z itself has no least element or first element. Therefore Z is
not well ordered.
Isomorphism

Suppose (A, )and ( A , ) are two posets and f: A A is a one to one correspondence between A
and A. The function f is called an Isomorphism from
(A , ) to (A, ) if, for every a and b A, a b if and
only if f (a) f(b).
If f: A A is an isomorphism, then (A , ) and (A, ) are called isomorphic posets.
3.5 Lattices
Definition (i) In terms of poset
A lattice is a poset (L , ) in which every subset {a, b} of L , consisting of two elements has a least upper
bound (lub) or supremum and a greatest lower bound (glb. ) or infimum. lub of the subset {a,b } is denoted by a b
and is called the join of a and b. glb of the subset { a, b } is denoted a b and is called the meet of a and b.
(ii)
In terms of algebraic structure
We can also define lattice in terms of algebraic structure as follows:
Let L be a non empty set closed under two binary operations denoted by (called join ) and (called
meet). Then L or (L, , ) is a lattice if the following axioms are satisfied " elements a,b,c L :
1.
Commutative laws
(i)
ab =ba
(ii)
ab =ba
2.
Associative laws
(i)
a ( b c ) = (a b ) c
(ii)
a ( b c ) = (a b ) c
3.
Absorption laws
(i)
a (a b) = a
(ii)
a ( a b) = a
Bounded Lattice
A lattice (L, ) is said to be bounded if it has a last or greatest element denoted by I and a first or least denoted by o.
o is said to be the lower bound and I is said to be the upper bound. o x and x I " x L.
Example. The lattice (P(S) , ) of all subsets of a set S under the partial order Containment (or set inclusion) is
bounded. Its greatest element is S and least element isf.
Properties of Bounded Lattice
If L is a bounded lattice , then for all a A
oaI
Where o is the least element and I is the greatest element [ since least element precedes all the elements of the
set A and all the elements of set A precedes the greatest element]
For a bounded lattice
(i)
a o = a, since o, a a.
(ii)
a o = o, since o and a both succeeds o.
(iii)
similarly a I = I
(iv)
aI=a
(v)
every finite lattice L is bounded.
Distributive Lattice
A lattice L is called distributive if for any elements a, b, c L
the following distributive properties are satisfied.
1. a (b c) = (a b) (a c)
2. a (b c) = (a b) (a c)
if L does not satisfied these properties then it is said to be non distributive .
Example of distributive Lattice
if S is a set , then lattice of its power set P(S) under the partial order (set inclusion) is distributive. Join or
supremum of a subset of two elements P(S) is their union and meet or infimum of a subset of two elements
P(S) is their intersection i.e. A,B P(S)
A B = A B and A B = A B
Also these two operations of union and intersection distributes over each other. Therefore the lattice P(S) is
distributive.

Complement of an element in a bounded lattice


Suppose L is a bounded lattice with greatest element I and least element o. let a L.
An element a L is called a complement of a
If a a = I and a a = o
Note:- 1
o = I and I = o
2 An element a in a bounded lattice need not have a complement.
3 An element a in a bounded lattice may have more than one complements.
4 An element a in a bounded distributive lattice can not have more than one complement ( we shall
prove this property).
Examples of Complements in a lattice:1. The lattice L = P(S) power set of S is such that every element has a complement, since A L, then its
complement A has the properly that A A = S and A A = F where S is the greatest element and F the least
element.
2. In the lattice whose Hasse diagram is given below, every element has a complement. The complements of 3 are
1 and 2.
I
1
3
2
o
Theorem:- The complement of an element a in a bounded distributive lattice, if it exits, is unique.
Proof:- Let a1 and a2 be the complement of a L
Then , a a1 =I, a a2 = I---------------(1)
a a1 = o, a a2 = o -----------(2)
Now we have,
a1 = (a1 o) = a1 (a a2 ) from (2)
= (a1 a) (a1 a2 ), by distributive law
= (a a1 ) (a1 a2 ), by commutative law
= I (a1 a2 ) by (1)
= a1 a 2
Similarly ,

= a2 = a2 o = a2 (a a1 )
= (a2 a) (a2 a1 )
= (a a2 ) (a1 a2 )
= I (a1 a2 )
= a1 a 2
therefore a1 = a2

Complemented lattice
If a lattice L is bounded and every element in L has a complement, then the lattice L is called a complemented
lattice.
Example of complemented lattice:1. The lattice L=P(S) of the power set of S is complemented.
2. The lattice whose Hasse diagrams is given here is complemented lattice. Complements are not unique. O and I
are unique complements of each other. Each of the elements a, b and c is the complement of the other two.
I
a

3.6 BOOLEAN ALGEBRA


Definition
A Boolean algebra is an algebraic structure which consists of a non empty set B, equipped with two binary
operations (denoted by and or + and or * and o), one unary operation (denoted by / ) and two specially
defined elements o and I (in B) and which satisfy the following five laws for all values of a, b, c, B.
1. Commutative laws:(i) a b = b a or a + b = b + a
(ii) a b = b a or a b = b a
2. Associative laws:
(i) a (b c) = (a b) c or a + (b + c) = (a + b) + c
(ii) a (b c) = (a b) c or a (b c) = (a b) c
3. Distributive laws:
(i) a (b c) = (a b) (a c) or a + (b c) = (a + b) (a + c)
(ii) a (b c) = (a b) (a c) or a (b + c) = a b + a c
4. Identity laws:
(i) a 0 = a = 0 a or a + 0 = a = 0 + a
a I = a = I a or a I = a = I a
Here 0 is the identity for the operation or + (called join or sum) and I is the identity element for the operation
or (called meet or product)
5. Complementation laws:
(i) a a = I or a + a = I (the identity for or operation)
(ii) a a = 0 or a a = 0 (the identity for or + operation)
Example:- Let (B, +, ) be an algebraic structure. + and are two operations for the set B = {0, 1} defined as follows
+

Prove that the given set B with defined

binary operations is a Boolean algebra.

Solution:1. Closure property is satisfied as all the elements in the two tables belong to B, i.e. The set B is closed with respect
to the two binary operations.
2. Commutativity property is also satisfied because of the symmetry in both the tables about the leading
diagonals.
3. Associativity property is also satisfied as we can see from the table that (1 + 0) + 1 = 1 + 1 = 1
and 1 + (0 + 1) = 1 + 1 = 1
consequently 1 + (0 + 1) = (1 + 0) + 1
Thus associativity is satisfied for +.
Also (1 0) 1 = 0 1 = 0 and 1 (0 1) = 1 0 = 0
consequently (1 0) 1 = 1 (0 1)
Thus associativity is satisfied for .
4. Distributive property is also satisfied as we can see form the table that
1 + ( 0 1) = 1 + 0 = 1

giving 1 + (0 1) = (1 + 0) (1 + 1)

and (1 + 0) (1 + 1) = 1 + 1 = 1 i.e. + distributes over


Again 1 (0 + 1) = 1 1 = 1

giving 1 (0 + 1) = (1 0) + (1 1)

and (1 0) + (1 1) = 0 + 1 = 1

i.e. distributes over +.

5. Identity laws: As 0 + 0 = 0 and 1 + 0 = 1 = 0 + 1. Therefore 0 is the identity for + operation. Again 01 = 0 = 10


and 11 = 1 = 11. Therefore 1 is the identity for operation, Unique identities exist for both the operations.
6. Complementation laws: 0 + 1 = 1 = 1 + 0
01 = 0 = 10
Therefore 1 is the complement of 0 for both operations.
Also 1 + 0 = 1 = 0 + 1
and 10 = 0 = 01

Therefore 0 is the complement of 1 for both operations. Hence complements exist for each element. Therefore (B,
+, ) is Boolean algebra.
Duality
Definition:- The dual of any statement in a Boolean algebra B is the statement which is obtained by interchanging
the operation + and (or and ) and also interchanging their identity elements 0 and 1 in the original statement.
For example the dual of a + 1 = 1 is a0 = 0, the dual of (0a) + (b1) = b is ( 1 +a)(b + 0) = b.

Principle of Duality:-The dual of any theorem in a Boolean algebra is also a theorem.

Boolean Expressions:-

Let (B, +, , /) or (B, , , /) be a Boolean algebra, where B = {x1, x2..} is a non empty set, + or and or
are two binary operations, / is a unary operation. 0 is the identity element for the operation + or and 1 or I is the
identity for the operation or . Then x1, x2, are called variables. A variable xi can assume the value xi or its
complemented value xi. 0 and I also belongs to B.

Definition
1. Literal : A literal is a variable or a complemented variable such as x, x, y, y & so on x2, x2 are two literals
involving one variable x2.
2. Boolean Expression : Let B = (X, , , , 0, I) be a Boolean algebra. A Boolean expression in variables x1, x2 .xk
each taking their values in the set X is defined recursively as follows:
(1) Each of the variables x1, x2, ..xk as well as the elements 0 and I of B are Boolean expressions.
(2) If X1 and X2 are previously defined Boolean expressions, then X1 X2, X1 X2 and X1 are also Boolean
expressions. E.g. x1, x3 are Boolean expressions by (1) and (2)
x1 x3 is also Boolean expressions by (2)
x1 x3 is also Boolean expressions by (2)
(x1 x2) (x1 x3) is also Boolean expressions by (2) repeatedly
A Boolean expression in x1, x2, ..xn is denoted as X = X(x1, x2, xn).
3. Minterms :

A Boolean expression in k variables x1, x2, .xk is called a minterm if it is of the form y1 y2 yk. where
each yj is a literal (i.e. either are xi or xi) for 1 i k and yi yj for i j.
It means a minterm in k variables is a product or meet of exactly k distinct variables e.g. x1 x2 is a minterm in two
variables x1 and x2.
Sum of products expression
Definition:- A Boolean expression E is called a sum-of-products expression if E is a fundamental product or the sum
of two or more fundamental products none of which is contained in another.
[Note:- such type of fundamental products are called distinct minterm]
Definition:- Let E be any Boolean expression. A sum-of-products form of E is an equivalent Boolean sum-ofproducts expression.
Example:- Consider E1 = xz + yz + xyz
and E2 = xz + xyz + xyz
Although E1 is a sum of products it is not a sum-of-products expression, as product xz is contained in the product
xyz. However by absorption law, E1 can be expressed as
E1 = xz + yz + xyz = xz + xyz + yz
= xz + yz
This gives a sum-of-product expression from for E1, E2 is already a sum-of-product expression.
Example :- E = ((xy)z) ((x + z)(y + z))
= ((xy) + z) ((x +z) + (y + z)) by De-Morgans laws
= (xy + z) (xz + yz) By involution
= xyxz + xyyz + xzz + yzz

By distributive law

[sum of products]
= xyz + xyz + xz + 0 By commutative, idempotent & complement laws.
[each term is a fundamental product or zero, but xz is contained in xyz]
= xyz + xz + xyz = xyz + xz (By absorption law & identity law)
[a sum of product expression]

Alternative definition of sum of product expression: Sum of product expression is a sum (or join) of distinct
minterms (i.e. fundamental products none of which is contained in the other.)

Disjunctive Normal Form (DNF) or Complete sum-of-product forms or disjunctive canonical form
A Boolean expression involving k variables is in disjinctive normal form (DNF) if it is a join or sum of distinct
minterms each involving exactly k variables e.g. the Boolean expression in 2 variables.
X(x1, x2) = (x1 x2) (x1 x2) (x1 x2) .(1)
is in DNF, as it a join of 3 distinct minterms each involving exactly 2 variables.

Complete disjunctive normal form


n

A DNF in n variables which contains 2 terms is called the complete DNF in n variables. For example a complete
DNF in two variables is xy + xy + xy + xy and complete DNF in three variables is xyz + xyz + xyz + xyz + xyz +
xyz + xyz + xyz
A complete D.N.F. is identically 1.
Example:- Obtain a disjunctive normal form for the expression
X(x1, x2, x3) = (x1 x2) (x1 x3) ..(1)
Solution:- x1 x2 = (x1 x2) I (Identity law)
= (x1 x2) (x3 x3)

(complementation law)

= (x1 x2 x3) (x1 x2 x3)

(Distributive law) (2)

Also x1 x3 = (x1 x3) I (Identity law)


= (x1 x3) (x2 x2) (complementation law)
= (x1 x3 x2) (x1 x3 x2)

(distributive law)

= (x1 x2 x3) (x1 x2 x3) (commutativity law) .(3)


Therefore putting values from (2) & (3) we have from (1)
X(x1, x2, x3) = (x1 x2 x3) (x1 x2 x3) (x1 x2 x3) (x1 x2 x3) which is an DNF.

Maxterm
A Boolean expression in k variables x1, x2, .xk is called maxterm if it is of the form y1 y2 .. yk i.e. a join
or sum of exactly k distinct variables (i.e. literals none of which involves the same variables) where each yj is a
literal (either xi or xi) for 1 i k and yi yj for i j.
Conjunctive Normal Form (CNF)

A Boolean expression in k variables is in CNF if it is a meet or product of distinct maxterms, each involving all the k
variables.
Example:- The Boolean expression,
X(x1, x2, x3) = (x1 x2 x3) (x1 x2 x3) (x1 x2 x3) is in CNF as it is the meet or product of 3 distinct
maxterms each involving 4 variables.
Example:- Obtain CNF of Boolean expression
X(x1, x2, x3) = (x1 x2) (x1 x3) (1)
Solution:- (x1 x2) = x1 x2 = (x1 x2) 0
= (x1 x2) (x3 x3)
= (x1 x2 x3) (x1 x2 x3) .(2)
[applying De-Morgan, Identity, Complementation & distributive laws respectively)
Similarly (x1 x3) = (x1 x2 x3) (x1 x2 x3) ..(3)
Using (2) & (3) we get R.H.S. of (1) as
= (x1 x2 x3) (x1 x2 x3) (x1 x2 x3) (x1 x2 x3) which is in CNF.
n

Complete Conjunctive normal Form:- A CNF in n variables which contains 2 factors is called Complete CNF in n
variables.
For example Complete CNF in 2 variables x, y is (x + y) (x + y) (x + y) (x + y) and complete CNF in 3 variables x, y, z
is (x + y + z) (x + y + z) (x + y + z) (x + y + z) (x + y + z) (x + y + z) (x + y + z) (x + y + z)

Equivalent Boolean Expressions:Definition:- Two Boolean expression are equivalent if and only if their respective canonical forms are identical.
Reduction of Boolean Expression to simpler forms
Simpler form means, that the expression has fewer connectives and all the literals involved are distinct.
Example:- Reduce to simpler form, the Boolean expressions
(a) X(x1, x2) = (x1 x2) (x1 x2)
(b) X(x1, x2, x3) = (x1 x2) (x1 x2 x3) (x1 x3)
Solution:- (a) R.H.S. = ((x1 x2) x1) x2 (Associative law)
= (x1 x2) x2

(Absorptions law)

= x1 (x2 x2)

(Associative law)

= x1 0

(Complementation law)

=0

(Identity law)

(b) R.H.S. = [x1 {x2 (x2 x3)}] (x1 x3) (Distributive law)
= [x1 {(x2 x2) (x2 x3)}] (x1 x3)

(Distributive law)

= [x1 {I (x2 x3)}] (x1 x3) (Complementation law)


= [x1 (x2 x3)] (x1 x3) (Identity law)
= [(x1 x2) (x1 x3)] (x1 x3) (Distributive law)
= [(x1 x2) (x1 x3)] (x1 x3) (x1 x3)
= (x1 x2 x3) (x1 x3)

(Idempotent & Associative law)

= (x1 [(x2 x3) x3)]

(Distributive law)

= x1 x3

(Absorption law)

3.7 Logic Gates and Circuits

Logic circuits are structures made of certain elementary circuits called logic gates. It is a machine containing one or
more input devices and only one output device. Each input device sends a signal in binary digits 0 and 1. The
following figure shown a box which consists of a number of electric switches or logic gates, wired together in some
specified way. Each line entering the box form left represents an independent power source called input (out of
which some or all lines may supply voltage to the box at a particular time). A single line coming out of the box gives
the final output which depends on the nature of input.

Input power
line

Circuit Box

Output line

Thus a gate may be considered as on or off according to whether the output level is 1 or 0 respectively.

Types of Logic Gates:


1. AND gate:- Let x1 and x2 be the Boolean variables (each having value 0 or 1) representing the two inputs. An
AND-gate receives two inputs x1 and x2 to give an out-put denoted by x1 x2 or x1 x2 whose value depends upon
the values of x1 and x2 both. The nature of the output for inputs x1 and x2 in AND-gate can be represented in
tabular form as given below.

Logic Table for AND-gate


x1

x2

x1 x2 or x1x2

It is clear from this table that output voltage of the gate is 1 only when the input voltage of each of the two inputs
is 1. it is zero otherwise.
The standard pictorial representation of an AND-gate is shown below:

x1

x1 x2

x2

2. OR-gate:- If x1 and x2 denote the two inputs then the output of such a gate is represented by x1 x2 or x1 + x2
whose value ( 0 or 1) depend upon the values of the inputs x1 and x2 as shown in the following logic table

Logic Table for OR-gate

x1

x2

x1 x2 or x1 + x2

It is clear from this table that the output voltage of an OR-gate is at level 1 whenever the level of any one or both
of the inputs wires is 1.
The standard diagrammatic representation of OR-gate is shown below

x1 x2

x1
x2

3. NOT-gate:- It is such a type of gate that receives an input x (whose value may be 0 or 1) and produces an output
denoted by x (whose value shall be 1 or 0 according to as the value of x is 0 or 1 respectively) as shown in the
following logic table.
X

Its standard diagrammatic representation is shown below

All these gates are elementary gates. We can design a logic circuit by using different combinations of these
elementary gates in which output of any of these gates is used as input of the other gate.

4. NAND gate:- This gate is equivalent to a combination of AND gate followed by a NOT gate. A NAND-gate
receives two inputs x1 and x2 to give an output denoted by (x1 x2) or (x1x2) whose value depends upon the
values of x1 and x2. the nature of output for input x1 and x2 in this gate can be represented in tabular form as given
below.
Logic Table for NAND-gate
X1

x2

NAND (x1x2)

Its standard representation is just like that of AND gate followed by a circle as shown below:

x1
y
x2

5. NOR gate:- It is equivalent to an OR-gate followed by a NOT gate. The tabular representation of the output value
y of two inputs x1 and x2 to a NOR-gate is shown below:

Logic Table for Nor-gate


X1

x2

NOR (x1 + x2)

Its standard representation is just like that of OR-gate followed by a circle as shown below:

(x1 x2)

x1
x2

Representation of Logic circuits by Boolean Expressions:-

In the following logic circuit the inputs are x1, x2 and x3. Output is y.

x1.x2

(x1. x2)

x1
x2

x1
x1

(x1. x2) + x1 + x3
x1 + x3

x3

A dot (as in the input line of x1 indicates the point where input line splits and its bit signal is sent in more than one
direction.
Hence we see that the inputs x1 and x2 are converted by AND-gate into an output x1x2 which serves as input for
NOT-gate to give the outputs as (x1x2). .(1)

Again the x1 serving is input for NOT-gate gives x1 as output. This x1 along with x3 serves as input for a OR-gate to
give x1 + x3 as output. This x1 + x3 along with previous out (x1x2) in (1) serve as input for an OR-gate to give
(x1x2) + (x1 + x3) as the final output. Various Boolean expressions and their corresponding Logic circuits are
shown below:

Boolean Functions
We have seen that the last column of logic table of a Boolean expression gives the value of the output Y of circuit
represented by the given Boolean expression, for different set of values of the input variables x1, x2 ..xn.
Therefore the output expression Y = X(x1, x2, xn) defines output values as functions of input bits. This
function gives a relation between inputs to the circuit and its outputs.
Let X(x1, x2) = x1 x2 be a Boolean expression where x1 and x2 can take values in B = {0, 1}. We can calculate the
values of this expression for different pairs of values of x1 and x2 by using Boolean algebra as represented in the
following table

x1

x2

x1

x1 x2

This gives the Boolean function for the expression (x1 x2) which may be denoted as f : B B such functions are
called Boolean functions.

Equivalent Boolean Expressions


The two Boolean expressions given by
X = X(x1, x2, .xn) and Y = Y(x1, x2, ..xn) in n variables are said to be equivalent over the Boolean
algebra B = {0, 1}, if both the expressions X and Y define the same Boolean function B.
It means that
X(e1, e2, ..,en) = Y(e1, e2,.,en) " ei {0, 1}

For this we find out the values of the two Boolean functions corresponding to two given expressions X and Y. If the
values of these functions are identical then the two Boolean expressions are equivalent. This will be more clear
form the example given here.

Example:- Show that the following two Boolean expressions are equivalent over the two element algebra B = {0, 1}
X = (x1x2) + (x1x3) and Y = x1(x2 + x3)
Solution:- Let f and g be the Boolean functions corresponding to X1 and X2 respectively. The values of these two
Boolean functions are calculated below in tables.
3

X1 involves three variables. So the corresponding function f shall be a three variable function i.e. f : B B which is
defined as
f(e1, e2, e3) = (e1e2) + (e1e3), e1, e2, e3 B.

Table calculation of value of f(e1, e2, e3) or f(x1, x2, x3)

x1 or e1

x2 or e2

x3 or e3

x1x2 or
e1e2

x3 or e3

x1x3 or
e1e3

(x1x2) + (x1x3) or
(e1e2) + (e1e3)

Similarly the value of g is calculated as follows:

Table - Calculation of value of g(e1, e2, e3)

x1 or e1

x2 or e2

x3 or e3

x3 or e3

x2 + x3 or e2 +
e3

x1(x2 + x3) or
e1(e2 + e3)

As the last columns of the two tables are identical, the two expressions x1 and x2 are equivalent.

Karnaugh Maps
Karnaugh maps are pictorial devices or graphical methods to determine the prime implicants and minimal form of
Boolean expressions involving not more than six variables. Thus it gives us a visual method for simplifying sum of
product expressions. We know that a minterm is a fundamental product involving all the variables and a complete
sum of products expression or D.N.F is a sum of distinct minterms.
Two fundamental products P1 and P2 are said to be adjacent if P1 and P2 have the same variables and
differ in exactly one literal. It means that there must be an uncomplemented variable in one product and
complemented variable in the other product. The sum of two such adjacent products P1 and P2 shall be equal to a
fundamental product with one less literal as explained in the examples given below:
In each of the following two examples P1 and P2 are adjacent.
Example:- P1 = xyz, P2 = xyz
P1 + P2 = (x + x)yz = 1yz = yz
Application of Karnaugh map to simplify a complete sum of product expression involving two variables:The map consists of a square divided into four sub-squares as shown in fig (a) below. Let the two
variables be x and y. The map is considered like a Venn diagram. Variable x is represented by points in the upper
half of the map as shown by shaded portion in fig (b) and x is represented by the points in the lower half of the
map (shown unshaded in the same fig (b)). Similarly y is represented by the points in the left half of the map as
shown by shaded portion in fig (c) and y shall be represented by the points in the right half of the map (shown by
unshaded portion in the same fig (c)).

In this way the four possible minterms involving two variables i.e. xy, xy, xy, xy shall represented
by the points in the four sub-squares in the map as shown below in fig (d).

xy

xy

xy

xy

fig (a)

fig (b)

fig (c)

fig (d)

Since a complete sum-of-products expression is a sum of minterms, it can be represented in a Karnaugh map by
placing checks in the appropriate squares. We may also place any number say 1 in these squares.
After representing the complete sum-of-product expression on the Karnaugh map, we can determine
(i) a prime implicant of the given expression which will be either a pair of adjacent squares (minterms) or or an
isolated square which is not adjacent to any other square of E(x , y).
(ii) a minimal sum-of-products form of E(x, y) which will consist of a minimal number of prime implicants covering
all the squares of E(x, y). It means that whenever there are checks (or 1s) in two adjacent squares in the map, the
minterms represented by these squares can be combined into a product involving just one of the two variables.
For example, xy and xy are represented by two adjacent squares which taken together form the right half of
the map (which in represented by y). Therefore xy + xy is minimized to y. If we have check in all the four
subsquares, the four minterms shall be represented by the expression 1 involving none of the variables. We draw
loops or circle covering the block of sub-squares in the map that represent minterms that can be combined and
then find out the corresponding sum of products. Our aim is to identity the largest possible blocks and to include
all the checks or 1s with the smallest number of blocks using the largest blocks first and always using the largest
possible blocks.
Example:- Use Karnaugh maps to determine the prime implicants and a minimal sum-of-products form for each of
the following complete sum-of-products expressions
(i) E1 = xy + xy
(ii) E2 = xy + xy
(iii) E3 = xy + xy + xy

Solution:- Karnaugh maps showing checks of minterms for the three given expressions are shown below.

x
x

E1

E2

E3

The grouping of minterms as shown above, using Karnaugh maps, is represented in the following figures

E1

E2

E3

(i) E1 consists of only one prime implicant comprising of two adjacent squares which are represented by a single
variable x. So the only prime implicant of E1 is x. Therefore the minimal sum-of-product form of E1 = x.
(ii) E2 consists of two isolated squares representing xy and xy shown by two loops therefore xy and xy are
the two prime implicants of E2. Thus E = xy + xy is the minimal sum of product form of E2.
(iii) The squares containing all the minterms xy, xy and xy of E3 contains two two pairs of adjacent squares
covered by two loops. The vertical pair of adjacent squares (represented by one loop) represents the variable y
and the horizontal pair of adjacent squares (represented by another loop) represents x. Thus y and x are the
prime implicants of E3. The minimal sum-of-products form of E3 = x + y.
Application of Karnaugh map to simplify a complete sum-of-products expression involving three variables:-

The map consists of a rectangle divided into eight squares as shown below. Let the variables be x, y and z.
The variable x is represented by the points in the upper half of the map and x is represented by the points in the
lower half of the map. y is represented by the points in the left half of the map and y by the points in the right half
of the map. z is represented by the points in left and right quarters of the map and z by the points in middle half of
the map as shown below:

yz

yz yz yz

x
or

All the eight minterms involving three variables i.e. xyz, xyz, xyz, xyz, xyz, xyz, xyz, xyz
are represented by the points in a square as shown below.

yz

yz

yz

yz

xyz

xyz

xyz

xyz

xyz

xyz

xyz

xyz

In the Karnaugh map with three variables a basic rectangle denotes either (i) a square or (ii) two adjacent squares
or (iii) four squares which form a one-by-four rectangle or two-by-two rectangle.

These basic rectangles correspond to fundamental products of (i) three or (ii) two or (iii) one literal,
respectively. Also the fundamental product represented by a basic rectangle is the product of just those literal that
appear in every square of the rectangle.
In order that every pair of adjacent products are geometrically adjacent, the left and right edges of the map are
identified by converting the map in the form of a hollow cylinder with left and right edges coinciding.
As in case of two variables we represent a complete sum-of-product expression by placing checks in the
appropriate squares of the Karnaugh map. Then a prime implicant of E shall be a maximal basic rectangle (a basic
rectangle not contained in any larger basic rectangle of E).
A minimal sum-of-products form for E shall comprise of a minimal number of maximal basic rectangles of E which
taken together include all the squares of E.
Application of Karnaugh map to simplify sum of product expressions involving four variables:Karnaugh map for expressions involving four variables is a square divided into sixteen small squares to
represent the sixteen possible minterms in four variables as shown below:

wx

wxyz

wxyz

Wxyz

wxyz

wxyz

wxyz

wxyz

wxyz

wx

wxyz

wxyz

wxyz

wxyz

wx

wxyz

wxyz

wxyz

wxyz

wx

yz

yz

yz

yz

By definition of adjacent squares, each square is adjacent to four other squares. The simplification of a sum-ofproducts expression in four variables is achieved by identifying those group of 2, 4, 8, or 16 squares that represent
minterms which can be combined.

Unit-4
Propositional and Predicate Logic

4.1 Propositions:
Those declarative sentences that are either universally true or universally false but not both are called statements,
or propositions.
Consider the following sentences
1. Lucknow is capital of Uttar Pradesh.

2. Kolkata is capital of Gujrat.


3. 2 + 3 = 5
4. 3 + 4 = 9
5. 7 > 5
6. 9 < 4
7. x + y > 0 for x > 0, y > 0
2

8. x = 3 is a solution of x = 9.
9. Prime Minister of India has to be a man.
10. 101 + 1 = 110 (in decimal system)
11. 101 + 1 = 110 (in binary system)
12. Women are more intelligent than men.
13. What is your name?
14. Watch the movie.
Here we can say that the facts mentioned in sentences 1, 3, 5, 7, 8 and 11 are true or more correctly are
universally true and the facts mentioned in sentences 2, 4, 6, 9 and 10, are universally false. The sentence 12 is not
universally true. Some people will say it is true while others may say that it is false. The sentences 13 and 14 are
not declarative.
By truth value of a proposition we mean whether it is, true or false. The truth values of true and false are
denoted by T and F respectively and the proposition are generally represented by lower case letters like p, q, r
etc.
If we represent the statement
The sun rises in the East by p and the statement 3 + 7 > 20 by q, then we can write
p:

The sun rises in the East.

q:

3 + 7 > 20

and say that the truth values of p and q are T and F respectively.

Primitive or Atomic or Simple propositions or Statements

The propositions that cannot be broken into simple propositions are called primitive propositions.

Molecular or Compound propositions or Statements

These are the propositions P(p, q, ..) that are composed of sub-propositions and various connectives,
like and, or, not etc. Such a proposition can be broken into simpler propositions. Truth value of a compound
proposition is completely determined by the truth values of its sub-propositions together with the way in which it
is connected to form the compound proposition or we can define a proposition P(p, q, ..) as an expression
constructed from logical variables p, q, .., which take on the value True (T) or False (F) and the logical
connectives , , , .

Example : (1) The sun rises in the east and sets in the west. It has two sub-propositions viz. p: The sun rises in the
east and q: The sun sets in the west and a connective and.
(2) 3 + 7 > 2 or 4 + 5 < 11 has two sub-proportions p: 3 + 7 > 2 and q: 4 + 5 < 11 and a connective or.

Logic :Logic may be defined as the procedure employed in mathematical proofs which are based on sound
reasoning. Logic is the weapon we need to convince others, that, granting our postulates are valid, certain
conclusions must be valid.

Logical Connectives (Basic Logic operations)

The words and, or if.., then, if and only if (denoted by , , , respectively) that serve to
connect two simple statements to form a third compound statement are called logical connectives.
The name of various logical connectives and the symbols to denote them are given below:
Connectives

Symbols

Negation (= not)

~ or / or

Conjunction (= and)

Disjunction (= or) *

Exclusive disjunction ( = or) *

or

Implication (= If.., then)

or

Equivalence or Biconditional (- if and only if)

Truth values of compound statements

The compound statement is first broken into simple or primitive statements each being represented by p, q, r etc
and then the given compound propositions is represented in symbolic form. Then its truth value is calculated as
given in the following discussion.
Suppose our compound statement is Kolkata is in East Bengal and Delhi is in India. Its primitive
propositions can be written as
p:

Kolkata is in East Bengal

q:

Delhi is in India.

The symbolic representation of the given compound statements is p q. Here truth value of p is T and that of q is
T.
Similarly the symbolic representation of the compound statement 4 + 3 = 9 or 7 + 3 < 15 shall be p q (where p:
4 + 3 = 9 and q: 7 + 3 < 15). Here p is F and q is T.
The symbolic representation of 7 + 3 5 and 4 + 3 = 7 shall be ~ p q where p: 7 + 3 = 5 and q: 4 + 3 = 7. Here p
is F and q is T.
The symbolic representation of If it rains, then I shall use umbrella is p q where p: it rains and q: I shall use
umbrella. The symbolic representation of x + y > 0, if and only if x > 0, y > 0 shall be p q where p: x + y > 0 and q:
x > 0, y > 0.

4.2 Connectives
Truth values of compound propositions using different connective have been calculated below:

(1) Conjunction, p q It is a compound proposition formed by combining two primitive propositions by the word
and. It is called conjunction of the original propositions represented by p & q respectively & is written as p q.
p q being a proposition has a truth value which depends only on the truth values of p and q. The following table
gives the truth value of p q for different combination of truth values of p and q.
Table Truth Table for p q

pq

p q is true only if p is

true and q is true

We give belong a few compound statements (p q) and their truth values (enclosed in circles).
(a) Kolkata is in Bengal and Delhi is in India (T)
(b) Lucknow is capital of U.P. and 3 + 2 = 6 (F)
(c) London is in China and 4 + 3 = 7 (F)
(d) 7 + 4 = 8 and 5 + 10 = 7. (F)

(2) Disjunction, p q:- It is a compound proposition obtained by combining two propositions by the word Or. It
is called disjunction of the original propositions & is written as p q & read p or q. Its truth value depends upon
the truth values of p and q as shown below:
Table Truth table for p q

pq

p q is false only if p is false & q is false.

We give below a few compound statements and their truth values (enclosed in circles)
(a) Kolkata is in Bengal or Delhi is in India (T)
(b) Lucknow is capital of U.P. or 3 + 2 = 6 (T)
(c) London is in China or 4 + 3 = 7 (T)
(d) 7 + 4 = 8 or 5 + 10 = 7 (F)

(3) p q: The exclusive disjunction of two propositions p and q is the statement Either p or q, but not both p
and q & is denoted by p q.
Table Truth Table for

pq

p is not true if both p & q are true or both p & q are false.

Example:- Find truth value of the following exclusive disjunction 2 + 3 = 7 or Mohan is an Engineer.
rd

Solution:- p q. As p is always false, so truth value depends on the truth value of q. Form 3 row If q is true
then p q is true.
th

From 4 row If q is false then p q is false.

(4) Negation, p:- Negation of statement p can be formed by writing It is not the case that or It is false
that .. before p or by inserting the word not and is written as p or ~p & read not p. Its truth value
depends upon the truth value of p as given below:

Table . Truth value of p


P

If p: Delhi is capital of India, then


p: Delhi is not capital of India.
p: It is false that Delhi is capital of India.
p: It is not the case that Delhi is capital of India.
If q: 3 + 2 = 7
q: 3 + 2 7
q: It is false that 3 + 2 = 7

Truth Set or Solution set of open sentence


If we consider the sentence x + 3 > 7then we can not find out the truth value of this sentence, since it will depend
upon the value of x. But if we are given that x + 3 > 7 where x set of whole numbers, then we can say that for the
set of values of x = 5, 6, 7, 8, .i.e. x 5, x W, the given statement x + 3 > 7 is true.
Such a sentence is known as open sentence and the set of values of the unknown quantity e.g. x for which the
truth value of this open sentence is T is called Truth set or solution set. In this case the solution set is given by {x
: x 5, x W} or {5, 6 ,7 ,8, ..}

Example:- Prepare truth tables fot the following propositions:


(a) p (~q)
Solution (a):-

(b) ~(p ~q)


Truth Table for p (~q)

~q

p ~q

Truth table for Proposition (p q)

(b)

p q

- (p q)

4.3 Tautology and Contradiction

Tautologies are composite the propositions P (p, q, .) which contain only T in the last column of their truth tables
or that are true for any truth values of their variables.
e.g. p p (p or not p) is a tautology as shown below:

p p

Tautology is the statement formula which is true regardless of the truth values of the statements which replaces
the variables in it. (also called a Universally valid formula or a logical truth)
If A and B are two tautologies then their conjunction A B will be a tautology.
A B if A B is a tautology
( is also written as and then is another as

A statement A is said to tautologically imply a statement B if & only if A B is a tautology and is denoted by A
B
A B means that A B is a tautology
A B means that A is a tautology

Both equivalence & implications are transitive


If A B & B C, then A C
& A B & B C then A B & B C are tautologies.
Hence (A B) (B C) is also a tautology.

Contradictions are those proposition P (p, q, .) that contains only F in the last column of their truth table or
which are false for any truth values of its variables.
e.g. p p (p and not p) is a contradiction.

pp

Negation of tautology is a contradiction & vice versa.

Theorem (Principle of Substitution) : If P (p, q, .) is a tautology, then P(P1, P2, ) is also a tautology for any
propositions P1, P2, .. or P1(p, q,), P2(p, q, ) because P(p, q,) is independent of truth values of its variables
p, q ,..

Example:- Prove that the sentence It is wet or it is not wet is a tautology.


Solution:- Sentence can be symbolized by p ~ p where p symbolizes the sentence It is wet. Its Truth table is
given below:
P

~p

p~p

As resultant column contains T everywhere, therefore the given proposition is tautology.


Example 9:- Prove that (~ p q) (p ~q) is a contradiction.

Solution:- Truth table for the given proposition

~p

~q

~pq

p ~q

(~p q) (p ~q)

Since F appears in every row of the last column, therefore the given proposition is a contradiction.

4.4 Logical Equivalence

Two propositions P(p, q, ..) and Q(p, q, ..) are said to be logically equivalent or simply equivalent or equal.
if they have identical truth tables and is written as
P(p, q, .) Q(p, q, ..)
as shown below truth tables of (p q) and p q are identical. Hence (p q) p q

pq

~ (p q)

pq

Also when a conditional p q & its converse q p are both true, the statement p & q are said to be logically
equivalent.

Identity laws
(1) p T p, p T T
(2) p F F, p F p

pT

pT

p F

pF

Hence T is the identity element for the operation (conjunction) and F is the identity element for the operation
(disjunction).

Logical Implications
(1)
(2)

Conditional
Biconditional

(1) Conditional sentences. (If ..then) or Implications

1. If it rains, then there will be no game.


or It rains implies the game will be cancelled.
2. If ABC is a triangle, then AB + BC > AC
The connective if then may be replaced by implies.
or
Logical symbol of an implication is p q read as If p, then q or p implies q is the symbolic representation of
a conditional statement.

Examples: x = 3 x = 9 (2) A B x A, x B
Antecedent is that component of a conditional statement that is expressed by the if clause (the variables p at
the tail).
Consequent is that component of a conditional statement that is expressed by the then clause (the variable q at
the head).

Example:- If 5 + 4 = 9, then 9 4 = 5

antecedent

consequent

Example:- Ordinary sentences written in the if .then form.


We will go out if the weather improves If the weather improves, then we will go out.
I will get A grade if I work hard If I work hard, then I will get A grade.
Conditional statement is a statement of the form If p then q denoted by p q and read as p implies q or p
only if q or A compound sentence using the connective If ., then is called a conditional statement.
Truth table for p q

pq

p q is false only when antecedent is true and consequent is false.

pqpq
Now we shall show that p q is logically equivalent to p q and logically equivalent to q p with the help
of truth tables

As the
q, q p
identical,
we

pq

qp

pq

Example:- Test if the following two statements written on two restaurants are equivalent or not
1. Good food is not cheap

columns for p
and p q are
conclude that
p q
q p p
q

2. Cheap food is not good.


Solution:- Let p denote the food is good, and q denote the food is cheap
Statement 1 is : p q

we will show below that truth table

Statement 2 is : q p

for both the statements are the same.

Identical
Hence p q q
Both the sentences

p q

qp

4.5
Converse,
positive of the Conditional statements

columns
q.
are equivalent.

inverse and contra

1.
The converse of a given conditional is a new conditional formed by interchanging the antecedent and
consequent of the given conditional. q p is the converse of p q

Truth table of the converse

pq

qp

2. The Inverse of a given conditional is a new conditional whose antecedent is the negation if the original
antecedent and whose consequent is the negation of the original consequence. The inverse of p q is p q
read as not p implies not q or if not p, then not q.

Truth table of the Inverse

~p

~q

pq

~p ~q

3. The Contrapositive of a given conditional is a new conditional whose antecedent is the negation of the original
consequent and whose consequent is the negation of the original antecedent.
e.g.: original: p q
contrapositive: ~ q ~ p read as not q implies not p or if not q, then not p
It is the inverse of the converse of a given conditional or is the converse of the inverse.

Statement:

If x + 3 = 8, then x = 6

Converse:

If x = 6, then x + 3 = 8

Inverse:

If x + 3 8, then x 6

Contrapositive: If x 6, then x + 3 8

Truth tables for the four implications

pq

q p

~p

~q

~p ~q

~q ~p

Same
Same

Equivalent Forms
(1)

PP

(2)

P PP

(3)

(P P) Q Q

(4)

PPQQ

(5)

(P Q) ( P Q)

(6) P (Q R) P ( Q R) by (5)
P ( Q R)
(7) Q R (Q R) (R Q)

means implies or

again by (5)
( means biconditional )

( Q R) ( R Q) or (Q R) ( Q R)
(8) P Q ( P Q)

DeMorgains Law

(9) P Q ( P Q) These can be used to remove either conjunction or disjunctions.

(2) Biconditional Statements (The Connective If and only if)


Statement I can go to Delhi if and only if I am cured would mean two things viz.
(1) I can go to Delhi if I am cured (p q)

(2) I am cured if I can go to Delhi (q p)


Where p represents If I am cured
Where q represents I can go to Delhi

Definition: If p and q represents any statements, the biconditional p q means


( p q) and (q p)
(p q) (q p)

or

Truth table of p q

pq

qp

(p q) (q p)

pq

p q is true when both p & q are either true or both false (i.e. equivalent) If and only if is sometimes
abbreviated as iff.

4.6 Rule of precedence

Order of preference in which the connectives are applied in a formula of propositions having no brackets is as
follows:
(i) ~

Negation

(ii)

Conjunction

(iii) and Disjunction & exclusive disjunction (any one of these two can be preferred to the other)
Example:- Truth values of (p q) r are the same as that of p (q r).
(iv) and conditional & biconditional.

Example:- Write down the truth values (or table) of p q ~ r r q .


Solution:- (i) First find truth value of ~ r.
(ii) then find truth value of (q ~ r)

(iii) then find truth value of ( r q)


(iv) then find truth value of either p (q ~ r), or of (q ~ r) (r q). (we chosen to apply first)
(v) & finally find truth value of the remaining one as shown in the truth table given below:
Truth table of p q ~ r r q
P

~r

q~r

rq

pq~r

pq~rrq

4.7 Equivalence of Formula


Two statement formulae P and Q in variables p1, p2, pn (n 1) are said to be equivalent if they have the same
truth value. Such formulae are considered as the same for all logical purposes.
We give below a list of such standard equivalent formulae. They serve as laws of Algebra of propositions.
Hence T denotes tautology and F denotes contradiction.

Laws of Algebra of propositions


Idempotent laws
1.(a)

ppp

1.(b)

ppp

Associative laws
2(a)

(p q) r p (q r)

2(b)

(p q) r p (q r)

3(b)

pqqp

Commutative laws
3(a)

pqqp

Distributive laws
4(a)

p (q r) (p q) (p r)

4(b) p (q r) (p q) (p r)

Identity laws
5(a) p F F
6(a)

5(b)

pTp

6(b)

pFp

pT=T

Complement laws
7(a)

ppT

7(b) p p F

8(a)

TF

8(b)

FT
~qqF

Involution laws
9

pp

DeMorgans laws
10(a)

(p q) p q

Absorption laws
p (p q) p,

p (p q) p

Detachment laws
((p q) p) q
Disjunctive Addition
p (p q)
Conjunctive simplification
(p q) p
Chain rule
(p q) (q r) (p r)
Disjunctive simplification
((p q) ( p) q
Conditional rules
(p q) (( p) q)

10(b)

(p q) p q

(p q) q p
Equivalence rules
(p q) (p q) (q p)
(p q) ((p q) (( p) ( q))
( (p q)) (p ( q))
Implication rules
(p q) ((p r) (q r))
(p q) ((p r) (q r))
Contrapositive Inference
((p q) ( q)) ( p)

Duality Law:- Two formulae A and A are said to be duals of each other if either can be obtained from the other by
replacing and and and .
The two connections and are said to be dual to each other. If any formula contains T and F, then its
dual is obtained by interchanging T & F in addition to the change explained above
Example:- Duals of (P Q) R is (P Q) R.

Example:- Use laws to prove that


~ (~ p q) (p q) p
Solution:- L.H.S. (p ~ q) (p q)

by DeMorgans law

p (~ q q)

by distribution law

pF

where F denote a contradiction

by identity law.

4.8 Argument
It is an assertion that a given set of proposition P1, P2, ., Pn called premises yields (has a consequence) another
proposition Q called the conclusion and is denoted by P1, P2, ..,Pn
Q

Valid Argument: An argument P1, P2, Pn


..Pn are true.

Q is said to be valid if Q is true whenever all the premises P1, P2,

Fallacy:- It is an argument which is not valid. Now P1, P2, Pn are true simultaneously if & only if proposition P1
P2, Pn is true. Hence we have the following theorem:

Theorem:- The argument P1, P2, ..Pn


P2 . Pn) Q is a tautology.

Q is valid if & only if Q is true whenever P1 P2 . Pn is true or (P1

Procedure to prove the validity of an argument:If P and Q are two statement formulae, then we say that Q
logically follows P or Q is a valid conclusion or consequence of the premise P if and only if P Q is a tautology. If
we are given a set of premises P1, P2, Pn, and a conclusion Q, than it is possible to determine whether the
conclusion Q logically follows from the given premises P1, P2, ..,Pn. by constructing the truth table.
The conclusion Q is said to logically follow from the given premises P1, P2, .,Pn if either of the following
condition is satisfied.
(1) Q is true whenever all the premises are simultaneously true.
or (2) Q is true whenever the conjunction P1 P2 .. Pn is true.
or (3) (P1 P2 Pn) Q is a tautology.
Logical Implication:- For any propositions P(p, q,.) and Q(p, q,.), the following three statements are
equivalent.
(i) P(p, q,..) logically implies Q(p, q,.) i.e. P(p, q,.) Q(p, q,..)
(ii) The argument P(p,q,..)

Q(p, q,.) is valid

(iii) The proposition P(p, q,.) Q(p, q,) is a tautology.


Any one of the above is possible
If Q(p, q,.) is true whenever P(p, q,) is true

Example: - To prove p p q, or p

p q we shall prove that p q is true whenever p is true as shown below:P

pq

p is true in row 1 and 2 in which p q is also true. Therefore p implies p q.

Example:- The following argument is a fallacy:


p q, q
p because p q and q are both true in row 3 but in this
case p is false. Hence it is a fallacy.

Example:- Prove that the argument p q, p,

q is a fallacy.

Solution:- Here premises are P1:- p q, P2:- p and conclusion is Q:- q


Truth Table

pq

pq

(p q) p

[(p q) p] q

Hence the given argument is a fallacy because


(1) Conclusion q is not always true where all the propositions of the premises i.e. p q and p are true
simultaneously (i.e. row 3)
or (2) Conclusion q is not always true where conjunction of the propositions of premises i.e. (p q) p is true
(i.e. row 3)
or (3) [(p q) p] q is not tautology.

Example:- Find if the following argument is valid or not.


If it rains, he will be sick
It did not rain
He was not sick.

Solution:- Let p denote it rains & q denote he is sick. The argument translated into symbolic from shall become
p q, p
q which has been proved to be a fallacy in example.

Four Rules of Inference

1.
2.
3.
4.

Law of Detachment:- [(p q) p] q


Law of Contraposition or Modus tollens:- p q, q
p
Law of Hypothetical Syllogism:- (p q) (q r) (p r
Law of Disjunctive Syllogism:[(p q) (~ p)] q

4.9 Quantifiers

Quantifiers are such words as all, some, none


Two Types of Quantifiers :
(1) Universal Quantifiers Those which refer to all the elements of a certain set. e.g. all, any, every, each none,
no.
(2) Existential Quantifiers Those which assert that there exists at least one element in a certain set. e.g. some, at
least one.

Symbols used for Quantifiers


(a)

for Universal Quantifiers ("x) read as for all x or for every x

Examples Every whole number is equal to itself is written as


For all x in W, x = x or " x W, x = x, where W is set of whole numbers.
(2) For all x, y and z in N is written as " x, y, z N, where N is a set of natural numbers.
(3) For all x in whole numbers, x + 0 = x is written as " x W, x + 0 = x
(b) for Existential Quantifiers:- ($x) read as There exist an x

Examples There exist an x in whole numbers such that x < 1 is written as $ x W, x < 1
(2) There exists an n in whole numbers such that nn = 1 is written as
$ n W, n n = 1
Note:- An open sentence like x is a bird is neither true nor false. The statement after quantifying an open
sentence may be judged either true or false and is therefore a statement.

Propositional Function

Definition:- A propositional function or a predicate in a variable x is a sentence p(x) involving x that becomes a
proposition when we give x a definite value from the set of values it can take. Such functions are denoted by p(x)
or q(x) etc.

The set of values x can take is called the Universe of discourse.


If p(x) is x > 6, then p(x) is not a proposition But when we give x particular values say x = 8 or x = 0, then we get
propositions > 6 (is greater than 6 ) is the predicate.
Hence p(8) is a true proposition and p(0) is a false proposition.
Note:- A predicate is usually not a proposition, But of course every proposition is a propositional function in the
same way that every real number is a real valued function, namely the constant function.

Some Propositional Function:Let A be a given set (say a set of positive integers N) and p(x) be an expression defined on A (say p(x) is x + 2 < 7)
with the property that p(a) is true or false for each a A
which means p(x) becomes a statement (with a truth value) whenever any element a A is substituted for the
variables x.
e.g. p(1) is true as 1 + 2 < 7
p(2) is true as 1 + 2 < 7

Then set A is called the DOMAIN of p(x), set Tp of all elements of A for which p(a) is true is called the TRUTH SET of
p(x)
Tp = {1, 2, 3, 4} = {x : x A, p(x) is true}
= {x : p(x)}.
P(x) is called a PROPOSITIONAL FUNCTION
or an OPEN SENTENCE or CONDITION

Other examples:

(a) Let p(x) be x + 3 > 7 defined on the set N of positive integers then its truth set Tp = {x : x N, x + 3 > 7} = {5, 6,
7, 8,..}. i.e. integers 5. i.e. p(x) is true for all positive integers equal to or greater than 5.
(b) Let p(x) be x + 6 < 3 defined again on N. Then its truth set Tp = {x : x N, x + 6 < 3} = = empty set. So p(x) is
not true for any positive integer in N.
Statement Formulae are the compound statements derived from the primitive statements like P, Q called
variables by using connectives & parentheses.

PQ

(P Q) (P)

P (Q)

Formula has no truth value until & unless the statement variables in a formula are replaced by definite statements
that have truth value. Statement formula is not a statement, however a statement can be derived from it by
replacing the variables by statements. A statement Formula is an expression which is a string, consisting of
variables (capital letters with or without subscripts), parentheses and connectives symbol.
Not every string of these symbols is a formula.

A well formed formula can be generated by the following rules.


1. A statement variables standing alone is a well formed formula.
2. If A is a well formed formula then A is a well formed formula.
3. If A and B are well formed formulae then (A B), (A B), (A B) an (A B) are well formed formula.
4. A string of symbols containing the statement variables, connectives, and parentheses are well formed formulae
iff it can be obtained by finitely many applications of the rule 1, 2 & 3.

The following are well formed formulae


(P Q)

(P Q) (P (P Q))

(P (Q R)) (((P Q) (Q R)) (P R))

The following are not well defined formulae


1. (P Q) (Q)

as Q is not a well formed formula

2. (P Q)
3. (P Q) Q ) one parenthesis in the beginning is missing.

Substitution Instance:- A formula A is called a substitution instance of another formula B if A can be obtained
from B by substituting formula for some variables of B, with the conditions that the same formula is substituted for
the same variable each time it occurs.

Example- B: P (J P)

Substitute R S for P in B we get


A: (R S) (J (R S))
Then A is a substitution instance of B. Note that (R S) (J P) is not the substitution instance of B because P in
J P has not been replaced by R S.
Any substitution instance of a tautology is also a tautology.

Quantifiers related to Propositional Functions:(A) Universal Quantifiers


Statement 1:- p(x) is a propositional function defined on set A (" x A), p(x) or simply "x p(x) are read as For
every x in A, p(x) is true statement or simply For all x, p(x)
Statement - 2
Tp = {x : x A, p(x)} = A
i.e. truth set of p(x) is the entire set A. Both of the statements are equivalent to each other.
Rule:- If {x : x A, p(x)} = A, then "x p(x) is true, otherwise "x p(x) is False.

Examples (1) The proposition ("n N) (n + 9 > 8) is true since {n : n + 9 > 8} = {1, 2, 3, ..} = N.
(2) The proposition ("n N) (n + 3 > 8) is False, since {n : n + 3 > 8} = {6, 7, 8, .} N.

(B) Existential Quantifier


Statement 1. p(x) is a propositional function defined on set A, ($x A) p(x) or $x p(x), read as There exist an x
in A such that p(x) is a true statement or For some x, p(x)
The above statement is equivalent to the following statement 2.
Statement 2. Tp = {x : x A, p(x) . i.e. Truth set of p(x) is not empty.
Rule:- If {x : p(x)} or {x : x A, p(x)} , then $x, p(x) is True, otherwise $x p(x) is False.
Example (1) The proposition ($ n N) (n + 5 < 8) is True since {n : n + 5 < 8} = {1, 2} .
(2) The proposition ($ n N) (n + 8< 4) is false since {n: n + 8 < 4} = .
Example:using M(x): x is man, Q(x) : x is a mortal

A(x): x is a flower, R(x): x is red.


I(x): x is an integer, P(x): x is either positive or negative the various sentences & their symbolic representation are
given below:Sentences & their paraphrases

Symbolic representation

(1) All man are mortal.

("x) (M(x) Q(x))

or
For all x, if x is a man, then x is a mortal.
(2) Every flower is red.
or
For all x, if x is a flowers, then x is red.

("x) (A(x) R(x))

(3) Any integer is either positive or negative.


or
For all x, if x is an integer, then x is either positive or negative. ("x) (I(x) P(x))

Some other Predicate Formula:(1) If P(x): x is a person


F(x, y): x is the father of y
M(x, y): x is the mother of y.
To write the statement x is the father of the mother of y we name a person called z as the mother of y Now we
want to say, that x is the father of z and z is the mother of y, which is symbolized as
$ (z) (P(x) F(x, z) M(z, y))
(2) If P(x): x is a person
L(x): x is a lover
R(x, y): x loves y.
To write All the person loves a lover
It can be symbolized as
("x) (P(x) "y (P(y) L(y) R(x, y)))
("x) and (x) both means the same thing.

(3) using G(x): x is a tree.


M(x): x is a man
Symbolic representation of the statement All men are trees shall be ("x) (M(x) G(x))

Negation of Quantified statements:-

Statement: All birds are dogs ("x M) (x is a dog) .(1)


where M represent set of birds.
Negation of this Statement: (1) It is not the case that all birds are dogs.
~("x M) ( x is a dog) ..(2)
or Equivalently
(2) There exists at least one bird who is not a dog.
($x M) ( x is not a dog) ..(3)
(1) (2) i.e. ~ ("x M) (x is dog) ($x M) ( x is not dog) .(4)
or if p(x) denotes x is a dog we can write the above equivalence relation (4) as
~ ("x M) p(x) ($x M) ~ p(x) ..(5)
Negation of "x p(x) is It is not true (not the case) that for all x, p(x) is true.
or ~ ("x p(x)) ($x) ~p(x). .(6)
or there exists atleast one value of x for which p(x) is not true.
This is true for any proposition. We can write (6) as
~ ("x A) p(x) ($x A) ~p(x) .(7)
This is called De Morgan law or Theorem.
and can be written in the form of following two equivalent statements
(1) It is not true that, for all a A, p(a) is true.
(2) There exists an a A such that p(a) is false.
Similarly we have an analogous Theorem for Negation of a proposition containing existential Quantifiers.
Statement: There exist an x in A such that p(x) is true ($x A) p(x) ..(8)

Negation of this Statement:- (1) It is not the case that there exists an x in A such that p(x) is true or
~ ($x A) p(x)
or equivalently
(2) For all x in A p(x) is not true ("x A)~p(x)
i.e. ~ ($x A) p(x) ("x A) ~ p(x) De Morgan Law.
The following two statements are equivalent
(1) It is not true that for some a A, p(a) is true.
(2) For all a A, p(x) is false.

Example:- Find truth values of


2

(a) (x 0) ($y) (y = x) True


(b) ("x) ($! y) (xy = 0)
2

True
2

(c) ("x) ($! y) (y = x ) False eg. x = -1, no y satisfy y = x .

Unit-5
Trees and Graphs, Recurrence Relation and Combinatorics

5.1 Graph:
A Graph denoted by G consists of
(a) A nonempty set V={v1, v2, v3, } of elements vi called vertices or nodes or points or junctions.
(b) a set E={e1, e2,e3, .} of elements ei called edges or arc or line or branches.

Such that each edge ek is associated with an unordered pair (vi, vj) of vertices. Vertices vi and vj are called end
vertices of the edge ek.
We may also define a graph G consisting of
(a)
(b)
(c)

a nonempty set V={v1, v2, v3, } of elements vi called vertices


A set E={e1, e2, e3, .} of elements ei called edges. and
A function f that assigns to each edge ek a subset {vi, vj} of v Where vi, vj, ev (vi and vj may be the same
also)
We write G= (V, E, f), simply G=(V,E) and f (ek)={vi, vj}

Representation of a graph

A Graph is generally represented by a diagram on a surface with vertices represented by points and edge represented
by line segment, (straight or curved and of any length). This diagram is also called graph.
The following figure gives diagrammatic representation of the graph G={V, E, f} where
V=[ v1, v2, v3, v4},

E={e1, e2, e3, e4, e5, e6} and

(e1)={v1, v2}

(e4)={v2, v4}
(e2)={v4, v3}

(e5)={v1, v2}

(e3)={v1, v3}

(e6)={v3, v3}

e5

e1

v1
e3

v2

end vertices of e1 are v1 and v2

end vertices of e5 are v1 and v2


end vertices of e3 are v1 and v3
end vertices of e6 are v3 and v3
v4
end vertices
of e2 are v3 and v4

e4

v3
e6

e2

end vertices of e4 are v2 and v4

Self loop:- It is an edge of the graph which has the same vertex as both end vertices e.g. edge e6 (having v3 as its
both end vertices) are self loops.

Parallel edges:- Those edges that are associated with the same pair of vertices are called parallel edges. eg. edges
e1 and e5 (both associated with same pair of vertices v1 and v2) are parallel edges. Parallel edges in a graph are also
called multiple edges.
Incidence and degree:-An edge is said to be incident with (on to ) each one of its end vertices e.g. vertices v3 and v4
are incident vertices of edge e2 and the edge e2 is said to be incident with the vertices v3 and v4.
Adjacent edge:-Non parallel edges that are incident with a common vertex are said to be adjacent to each other
e.g. e2 and e4 are adjacent to each other.
Degree or valency of vertex:-The number of edges that are incident with a vertex vi with self loop counted twice, is
called the degree of the vertex vi and written as d(vi).
d(v1) = 3

d(v4) =2

d(v2) =3

d(v3) =4

Edges in series:-Two edges with a common vertex in a graph are said to be in series if their common vertex is of
degree two e.g. the two edges e2 and e4 are in series.
Isolated vertex: - An Isolated vertex in a graph is a vertex having no edge incident on it and is therefore a vertex
whose degree is zero e.g. vertices v6 and v7 in fig below.
Pendant vertex: A pendant vertex or an end vertex in a graph is a vertex will degree one, e.g. vertex v3 in fig below.

e2
v2

v7

e1
e7
v3

v6

e6

e3

v1
v4

e4

v5

e5

Adjacent Vertex: End vertices of the same edge are said to be adjacent vertices e.g. vertex v4 & vertex v5 are said
to be adjacent to each other.
Digraph:- Directed graph or digraph G consists of
(a) a non empty set V = {v1, v2, v3, } of elements vi called vertices,
(b) a set E=[e1, e2, e3, ..} of elements ei called edges
such that each edge is associated with an ordered pair of vertices (vi, vj) . Clearly E is a subset of the
product set V V.
or
We may say that a digraph G consists of
(a)
(b)
(c)

A non empty set V of elements vi called vertices.


A set E of elements ei called edges and
A mapping f that maps every element of set E on to some ordered pair of vertices (vi, vj) a subset
of V V We write G = (V, E, f,) or simply G = (V, E)
A digraph is also represented diagrammatically vertices being represented by points and edges being
represented by line segments between the vertices with an arrow directed from the starting vertices vi to end
vertex vj as shown in fig

vi

ek

vj

ek is associated with (vi, vj) and not with (vj, vi) i.e. f (ek) = (vi, vj)

Incidence in digraph
If G = (V, E, f) is a digraph and ek is a directed edge associated with an ordered pair (vi, vj) of vertices, then in
the diagrammatic representation given in fig ,

vi
(a)
(b)
(c)
(d)
(e)
(f)
(g)

ek

vj

ek begins at vi and ends at vj.


vi is called the origin or initial point of ek and vj is called the destination or terminal point of ek.
vi is called predecessor of vj and vj is called successor of vi.
vi is called adjacent to vj and vj is called adjacent from vi
ek is said to be incident out of vi (initial vertex) and incident into vj (terminal vertex).
An edge having the same initial and terminal vertices is called a self loop (vi = vj)
Two edges associated with the same ordered pair of vertices are said to be parallel.

Parallel edges in digraph


In case of a directed graph parallel edges are those edges whose end vertices are the same and also their
directions are the same i.e. there are the edges that are associated will the same ordered pair of vertices

e2
v1

v2
e1
e6

e3

v4

e5

v3

e7

e1 and e2 are parallel edges [being associated will


ordered pair of vertices (v1, v2)], while e6 and e7 are not
parallel edged become e6 is associated with {v1, v3} while
e7 is associated with {v3, v1}, that are not the same
ordered pair of vertices.

e4
A given digraph has a unique undirected graph while an undirected graph may have different orientations
possible.

Degree of vertex in a digraph

(a) Out degree of a vertex vi in a digraph. It denotes the number of edges beginning at or incident out of the
vertex vi and is written as d+ (vi)
(b) In degree of a vertex vi in a digraph. It denotes the number of edges ending at or incident into vi and is
written as d (vi)
Source and Sink
Source: - A vertex in a digraph with zero in degree is called a source e.g. vertex v6.
Sink:- A vertex in a digraph with zero out degree is called a sink e.g. vertex v7 .
Pendant vertex in digraph
Pendant vertex in a digraph is a vertex whose
(a)
(b)

In degree is one and out degree is zero e.g. v7 or


In degree is zero and out degree is one e.g. v6
or

d+ (a pendant vertex ) + d (the same pendant vertex) = 1

5.2 Walk
Walk is defined as a finite alternating sequence of vertices and edges, beginning and ending with vertices, such
that each edge is incident with the vertices preceding and following it. Vertices as well as edges may be
repeated. Length of a walk is the number of edges it contains, with repeated edges counted.
Open Walk: A walk is open if its initial (Starting) and final (Ending) vertices are different.
Closed walk: A walk is closed if its initial and final vertices are the same.
Example:
In the following graph with 5 vertices and 7 edges x1 x5 walk of length 4 is W1 = {x1, e1, x2, e6, x4,
e3, x3, e5, x5 } Similarly x1 x5 walk of length 8 in the same graph is

e4

x4

e3

x3

e5
e2

x5

e7

e6

e1
x2

x1
W2 = {x1, e1, x2, e2, x3, e3, x4, e6, x2, e7, x5, e5, x3, e3,
x4, e4, x5 }. Here e3 has been repeated.
As the initial vertices is x1 and end vertex is x5, the
walk is called x1-x5 walk.

Both the above walks are open walks because their initial and end vertices are different.
W3 = {x2, e7, x5, e5, x3, e2, x2} is a closed walk because the initial and end vertices are the same.
W4 = {x1, e1, x2, e7, x5, e5, x3, e3, x4, e4, x5, e7, x2, e1, x1} is also closed walk.
TRAIL
A trail is an open walk in which no edge is repeated. Vertices can be repeated in a trail.
In the above graph, the sequence {x1, e1, x2, e7, x5, e5, x3, e2, x2} is a trail in which vertex x2 has been repeated
but no edge has been repeated.
CIRCUIT
A circuit is a closed trail or a circuit is a closed walk in which no edge is repeated. Vertices may however be
v2
repeated.

e1
e6

v1

e15
e5

e8

v7
e1

v6

e2

e7

e1

v8
e1

e9
e1

v3

Here, in this fig the sequence


{v6, e6, v2, e7, v7, e12, v5,
e14, v8, e10, v7, e11, v6}
is a v6 v6 circuit in which
no edge is repeated, but
vertices v6 & v7 have been
repeated.

PATH
A path is trail with no repeated vertex or a path is an open walk in which neither any edge nor any vertex is
repeated. It is also called an elementary path.
In the above Fig., the sequence {v6, e15, v1, e4, v4, e3, v3, e9, v8, e10, v7 } is a path of length 5 in which neither any
edge nor any vertex is repeated.
It should be noted that if all the vertices in a walk are distinct, then edges also could not be repeated. For this
very reason, a path is always a trail but every trail is not a path (because the vertices may be repeated in a
trail).
CYCLE A cycle is a circuit in which no vertex is repeated except the initial vertex, which is also the end vertex of the
sequence, or a cycle is closed walk in which neither any edge nor any vertex except the initial vertex, is repeated.
In the fig. the sequence
{v6, e11, v7, e10, v8, e14, v5, e13, v3, e3, v4, e4, v1, e1, v2, e6, v6} is a cycle of length 8.
Degree of a vertex in cycle
From the definition of cycle each of its vertices including the initial or terminal vertex, is preceded as well as
followed by exactly one edge. It means that exactly two edges are incident with every vertex of a cycle.
Therefore the degree each vertex of a cycle is two.
Concepts of walk, trail, circuit, cycle and path in a Digraph

walk : A walk in a digraph or a directed walk from vertex vi to vj is defined as a finite alternating sequence of
vertices and directed edges, beginning with vertex vi, and ending with vertex vj, such that each edge is
oriented from the vertex preceding it to the vertex following it.
semi walk : A semi walk in a digraph is a walk in the corresponding undirected graph, but it is not a directed
walk.
Examples: In this fig. v5, e10, v3,

e5

e6, v4, e3, v1, e1, v3 is directed walk,

e4

e1

v1

while v5, e10, v3, e9, v5, e7, v4 is a


semi walk and not a directed walk as

v2

v3
e2

e3

e9

e6

e10

e8

the edge e9 is not oriented from v3 to


v5 but from v5 to v3. The sequence
v5, e7, v4, e3, v1, e1, v3, e6, v4 is a

v4

e7

v5

directed walk

open-directed walk : An open-directed walk is a directed walk whose initial and final vertices are distinct.
closed directed walk : A closed directed walk is a directed walk whose initial and end vertices are the same.
Circuit : A circuit in a digraph is a closed directed walk in which no directed edge is repeated, It is a close directed
trail.
directed path : A directed path or a path in digraph is a trail with no repeated vertex. It is an open directed walk in
which neither any directed edge nor any vertex is repeated. The sequence v5, e8, v3, e6, v4, e3 v1 is a directed path in
fig. but v5, e7, v4, e6, v3, e1, v1 is a semi path.
Cycle : A Cycle in a digraph is a directed circuit in which no vertex is repeated except the initial vertex, which is also
the end vertex of the sequence. It is a closed walk in which neither any directed edge nor any vertex, except the
initial vertex is repeated.
The sequence v1, e1, v3, e6, v4, e3, v1 is a directed cycle in fig.
The sequence v1, e1, v3, e6, v4, e2, v1 is not a directed cycle. It is a semi cycle.
Length of the walk or path in a digraph is the number of edges contained in it.
Distance between two vertices
The length of the shortest distance between any two vertices vi and vj of a connected graph G is called the
distance between the vertices vi, and vj. It is denoted by d(vi, vj)

Diameter of the graph


The maximum of all the distances between any pair of vertices of a connected graph is called the diameter of
the graph & is denoted by D, So D = max. d(vi, vj) where vi, vj G
Example: The different paths from vi to vj in following graph are:
(v1, e1, v6, e9, e5), (v1, e1, v6, e10, v2, e8, v5), (v1, e2, v2, e10, v6, e9, v5), (v1, e2, v2, e8, v5), (v1, e2, v2, e3, v3, e7, v5), (v1,
e2, v2, e3, v3, e5, v4, e6, v5) etc the shortest path from vi to v5 are (v1, e2, v2, e8, v5) and (v1, e1, v6, e9, v5) each
being of length 2.
Hence d(v1, v5) = 2

v6

e11

v5

e9

e6
v4

e1
v1

e10

e8

e7

e5
e4

e2
v2

e3

v3

5.3 Different types of graphs


Simple graph: It is graph that has neither a self loop nor parallel edges.
Multi graph:
Trivial graph:

Multi graphs are undirected graphs that may contain multiple edges but not loops.
It is a finite graph with one vertex and no edges i.e. a single point.

Null graph: Null graph (Discrete graph) is


a graph whose edge set is empty.

v4

v2

v1

In such a graph every vertex is


an isolated vertex and there is no

v3

edge.
The vertex set is not empty.

v5

Connected and Disconnected graphs


A graph G is said to be connected if we can reach any vertex from any other vertex by travelling along the
edges. It means that in a connected graph there is at least one walk between every pair of its vertices.
A graph, which is not connected, is a disconnected graph.

Connected graph

Disconnected graphs
(Consisting of two components)

A null graph of more than one vertex is a disconnected graph.


A graph with one vertex is considered to be a connected graph, because in a disconnected graph there must
exist at least two distinct vertices, which are not joined by edges.
Components
A disconnected graph consists of two or more connected graphs, E each of these graphs is called a
component.
A sub graph H of the graph G = (V, E) is called a component.
(a) if H is connected and is not a sub graph of any other connected sub graph of G.
and (b) if K is a complete connected sub graph of G, and
H is connected in K, then H = K.
A component is always maximal connected sub graph of G. The two number of components in a graph G is
generally denoted by c(G)
Cycle

Cycle denoted by Cn (n 3) is a graph of n vertices v1, v2, .., vn and edges {v1, v2}, {v2, v3}, ., {vn-1, vn}, {vn, v1}
v1

v2

v2

v1

v2
v1
v1

v3
v6

v3

v5
v3

v2

C3

v3

v4

C4

v4

C5

v4

v5

C6

Wheel
Wheel denoted by Wn is graph obtained by adding an additional vertex to the cycle Cn (n>=3) and connecting
this new vertex to each of the n vertices of Cn by new edges.

W3

W4

W5

W6

Regular Graph : Regular graph is a graph in which all vertices are of equal degree.
Complete Graph Kn
It is a simple graph with n vertices such that every vertex is joined to every other vertex by an edge. As every
vertex is joined to every other vertex through one edge, the degree of every vertex is 1 and number of edges
in n(n-1)/2.

K1

K2
K3

K4

K5

Finite graph:- It is a graph having a finite number of vertices and a finite number of edges.
Infinite graph: It is graph a having an infinite number of vertices & an infinite number of edges.
Planar Graph: It is a graph whose geometrical representation can be shown on a plane surface such that no two of
its edges intersect.

Euler graph and Hamiltonian graph


Euler graph:
It is a graph that contains an Euler line. An Euler line is a closed trail (or circuit) containing all the
edges of the graph G.
A cycle C6 is a Euler graph. The following graph is also an Euler graph in which the Euler line is {v1, v5, v3, v1, v2,
v3, v4, v5, v6, v1}
v
1

vv6

v2

v5

v3
v4

v3

Hamiltonian Graph:
It is a graph G that contains a Hamiltonian cycle. A Hamiltonian cycle is a closed trail (or
v5
circuit) containing every vertex
of the graph G exactly once except the initial vertex which is also the
terminating vertex. The following two graphs are Hamiltonian cycle shown through arrows.
v2
v3
v5

v2
v8
v4

v4

v7

v6

Hamiltonian cycle is

Hamiltonian cycle is

{v1, v2, v3, v4, v5,v1}

{v1, v2, v3, v4, v5, v6, v7, v8, v1}

Weighted graph
Graphs that have numbers (called weight) assigned to each of its edges are called weighted graphs. These are used
to model computer network. Weights may represent the costs, response time over the lines or distances.
If we represent the cities by vertices and the roads between them by edges, we get a graph. If we associate a real
number wi with every edge ei such that wi represent the distance or length (in km) of the road represent by
the edge ei then such a graph is called a weighted graph with wi as the weight of the edge ei.
Bipartite Graph

A graph G = (V, E) is said to be bipartite if its vertex set V can be partitioned into two non empty disjoint
subsets V1 and V2 such that every edge in set E (G) has one end vertex in the set V1 and the other end vertex
is the set V2. No edge of G can join two vertices of the same subset V1 or V2.
Complete Bipartite graph , denoted by km,n is a graph whose vertex set V is partitioned into two disjoint subsets V1
and V2 consisting of m and n vertices respectively. Each edge of the graph connects a vertex of V1 to a vertex
of V2. Every vertex of V1 is adjacent to every vertex of V2.
Example: C6 is bipartite graph, because its vertex set V can be partitioned in to two sets V1 = {v1, v2, v3} and V2 = {v2,
v4, v6} and also every edge in C6 join a vertex in set V1 to a vertex in set V2 as shown below:
v1

v2

v3

v4

v5
v6

Example: K3 is not bipartite, because if we divide its vertex set V into two disjoint sets V1 and V2 then one of these
two sets V1 and V2 must contain two vertices connected with each other which is not admissible in a bipartite
graph.
Star graph denoted by K1,n is a complete bipartite graph in which | V1 | = 1 and | V2 | = n

K1, 6

Sub Graphs
Sub graph:Let G = ( V(G), E(G)) be a graph with vertex set V (G) and edge set E(G) then a graph H(V(H), E(H)) is said to be
a sub graph of graph G if

(i) All the vertices of H are in G i.e. V(H) V(G).


(ii) All the edges of H are in G i.e. E(H) E(G)
(iii) Each edge of H has the same end vertices in H as in G.
v2
v2
a

b
b

c
v5

v5

v1

v6

v6

v3
a

v4

v4

[Graph G]

[Sub Graph H]

Sub Graph of a digraph: Consider the following two digraphs G and H


e1

v1

v4

v4

e4
e4

e2

e3

e8

e6

e6
e5
v3
v2

v3
v2

G
H

e5

e7

e7

V(G) = {v1, v2, v3, v4}


E(G) = {e1, e2, e3, e4, e5, e6, e7, e8}
V(H) = {v2, v3, v4} V (G) and E(H) = {e4, e5,e6, e7} E (G)
Also each directed edge of H has the same ordered pair of end vertices in H and G. Then the digraph H is
called the sub graph of the digraph G.

Hence a digraph H = ( V(H), E(H) ) is a sub graph of a digraph G = ( V(G), E(G) ) if


(i)

All the vertices of H are in G i.e. V(H) V(G).

(ii) All the directed edges of H are in G i.e. E(H) E(G)


(iii) Each directed edge of H has the same pair of ordered end vertices in H as in G.
Isomorphism
Two graphics G1 and G2 are said to be isomorphic to each other if there is a one to one correspondence
between their vertices and between their edges so that the incidence relationship is maintained.
It means that if in graph G1 an edge ek is incident with vertices vi and vj then in graph G2 its corresponding
edge ek must be incident with the vertices vi and vj that correspondent to the vertices vi and vj respectively.
The following two graphs G1 and G2 are isomorphic graphs.

In fact isomorphic graphs are the same graphs drawn differently. The difference has in the names or labels of
their vertices and edges.
The incidence relationship between vertices and edges in G1 is preserved by the incidence relationship
between corresponding vertices and edges in G2.

Isomorphic Digraphs
Two digraphs are said to be isomorphic if,
(a) Their corresponding undirected graphs are isomorphic.
(b) Directions of the corresponding edges also agree.
Isomorphism may also be defined as follows:
Isomorphism from a graph G1 = (V1, E1) to G2 = (V2, E2) is defined as mapping

f : V1V2 such that

(a) f is one one and onto


(b)
edge vi vj E1 if and only if f (vi) . f(vj) E2
where f(vi) and f(vj) are the images of vi and vj respectively in graph G2
Some properties of isomorphic graphs
1. Number of vertices in isomorphic graphs is the same.
2. Number of edges in isomorphic graphs is also the same.
3. Each one of the isomorphic graphs has an equal number of vertices with a given degree.
This property is utilized in identifying two non-isomorphic graphs by writing down the degree.

Homomorphism graphs
Let G1 be a given graph. Another graph G2 can be obtained from this graph by dividing an edge of G1 with
additional vertices. Two graphs G1 and G2 are said to be Homeomorphic if these can be obtained from the
same graph or isomorphic graphs by this method.

Self complementary Graph


A graph G is said to be self complementary if it is isomorphic to its complement G.

5.4 Trees

A tree is a connected graph without any cycles and is therefore a simple graph having neither a self loop nor
parallel edges or A tree is a connected acyclic graph.
Trees with directed edges :
A directed tree or a tree with directed edges is a connected digraph that has no cycleneither a directed cycle nor
a semicycle. Such a tree with n vertices has (n 1) directd edges and possesses properties similar to those with
undirected edges.
Rooted Tree:
A tree in which any one vertex is distinguished from all the other vertices is called a rooted tree and the
distinguished vertex is called the root of the tree. Root is generally marked by enclosing the vertex within a triangle
or a circle as follows :

Rooted trees each with 4 vertices

Trees without roots are generally termed as trees, free trees or non-rooted trees.
Leaves : Any vertex of a rooted tree T other than the roots is called a leaf of T. In figure below, we have five leaves
v3, v4, v7, v8 and v9.
v0

v1

v2

v5

v4

v6

v10
v8

v3

v7

v9

Sub-tree : If v is a vertex in a tree T = (V, E), then a subgraph T' = (V', E') of T in which V' includes v and all the
descendents of v, and E' contains edges in all directed paths initiating from v is called a sub-free. The root of this
subtree is son of v.

Ordered rooted tree :


A rooted tree whose subtrees are placed in a definite order is called an ordered rooted tree. These subtrees also
are ordered trees.
Properties of a tree with n vertices :
1. It is an acyclic and connected graph.
2. It is connected and has n 1 edges.
3. It is acyclic and has n 1 edges.
4. There is exactly one path between every pair of vertices in G.
5. It is a minimally connected graph.

Theorems on properties of trees :


Theorem: There is one and only one path between every pair of vertices of a tree.
Proof : (a) As a tree T is defined as a connected graph, there must exist at least one path between every pair
f vertices of T.
Existence of more than one (two or more) distinct paths between any two vertices v1 and v2 of T shall
create a cycle in T which is not acceptable for a tree.
(b)
Hence there can not be two or more than two paths between any pair of vertices of a tree. By
(a) & (b) there is one and only one path between every pair of vertices of a tree.

virtue of

Theorem: A tree with n vertices has (n 1) edges.


Proof (by induction) : We can see that the theorem is true for n = 1 [], n = 2 [ ], n = 3
We assume that the theorem is true for all trees with less than n (upto n 1) vertices. Now we shall show
that if it is true upto n 1 vertices, it is also true for n vertices as follows :

Let vi and vj be the end vertices of an edge eK in a tree T. By definition, there is no other path between vi
and vj except eK.
Deletion of eK from T shall make T eK as a disconnected graph consisting of two components say T1 and T2.
As there is no cycle in T, there must not be any cycle in T1 and T2 also. So T1 as well as T2 is an acyclic connected
graph and hence each is a tree.
Let the number of vertices in T1 and T2 be p and q respectively. As deletion of eK from T does not affect the
number of vertices in T, the number of vertices in T1 and T2 taken together shall be the same as in T.
i.e p + q = n

...(1)

In T1, number of vertices = p (< n), so number of edges in T1 = p 1 (by our assumption that the theorem
holds for less than n vertices).
Similarly in T2, number of vertices = q(< n), so the number of edges in T2 = q 1.
Therefore the total number of edges in T1 and T2
= (p 1) + (q 1)
=p+q2
=n2
As the number of edges in T =

by (1) .....(2)

(number of edges in T1) + (number of edges in T2) + 1

(as one edge eK is deleted from T to convert it into T1 and T2).


=

(n 2) + 1

n 1Hence proved.

by (2)

Theorem: Any connected graph with n vertices and (n 1) edges is a tree.


Proof : Minimum number edges to make graph of n vertices as a connected graph is n 1. We see that removal of
a single edge from the graph G shall make it disconnected. So (n 1) is the minimum number of edges required to
make a graph of n vertices as connected and acyclic. Therefore, a connected graph with n vertices and (n 1)
edges can not have a cycle.
Thus we see that G is a connected graph having no cycles (acyclic) and therefore, G is a tree.
Forest:
It is a graph each of whose component is a tree. Thus it is a collection of trees.

Example: Trees with one, two, three and four vertices have been shown here in the following figures (a), (b), (c)
and (d) respectively.

(a)

(b)

(c)

(d)

Uses of trees :
Trees are generally used :
(i) to represent the geneology of a family.
(ii) to represent a river along with its tributaries and subtributaries.
(iii) in sorting of mail according to pin codes.
(iv) in computer programming and switching theory.

5.5 Binary Tree :


When the trees are levelled, the root v constitute level 0, the neighboring vertices of v constitute level 1, the
neighbors of vertices having level 1 are assigned level 2 and so on.
If the level of any vertex x is i, then its neighboring vertices on the next level (i +1) are called its children or
descendents. The vertices on previous level are called Father or Predecessor.
A rooted levelled tree in which any vertex has at the most two children is called a binary tree. It means that a
vertex of a binary tree can have no child, one child or two children.

If every vertex of a binary tree has either two children or no children, then such a binary tree is called a Full or
Complete binary tree.
v1

Fig shows a binary tree v1 is a root of the tree. The left subtree
consists of the binary tree with root v2 and the right subtree consists
of the binary tree with root v3. Further v2 has its left subtree with root
v4 and right subtree with root v5. Now v4 has its no left subtree. It has
right subtree with root v8. Similarly the subtrees with their roots

v3

v2
v4

v5
v8

v6
v9

v7
v10

corresponding to other vertices also can be defined.

Fig. below depicts a complete or full or strictly binary tree.


v1

v2

v3

v5

v4
v6

v7

In a directed graph we may define a binary tree as a rooted tree in


which each vertex has at most two out-degree.

Some properties of Binary Trees :

1.

The number of vertices x in a binary tree is always odd.

Proof : As only one vertex is of even (= 2) degree and the rest (n 1) vertices of odd degree (1 or 3) and the
number of vertices with odd degree in a graph (including tree) has to be even. Thus n 1 is even which is possible
of n is odd.
2.

p, the number of pendant vertices in a binary tree T with n vertices = n + 1


2

Proof : Total number of vertices in the given binary tree T = n


Number of pendent vertices in T = p
Number of vertices with degree 2 in T = 1
Therefore, number of vertices with degree 3 = n (p + 1) = n p 1
Total number of degrees of all vertices in T.
= number of degrees of p vertices each of degree 1.
+ number of degrees of 1 vertex of degree 2
+ number of degrees of n p 1 vertices each of degree 3.
= (p 1) + (1 2) + [(n p 1) 3]

= 3n 2p 1

(1)

Alternatively, the number of edges in the tree T with n vertices = n 1


The total number of degrees associated with these n 1 edges (and hence n vertices) = 2 (n 1)
= 2n 2

(2)

From (1) and (2)


3n 2p 1 = 2n 2
or

n 2p + 1 = 0

or

n +1 ,
2

...(3)

Binary Search Tree: Binary Search tree is a binary tree in which each internal node x stores an element such that
the element stored in the left subtree of x are less than or equal to x and elements stored in the right subtree
of x are greater than or equal to x. This is called binary-search-tree

Traversal of a binary Tree:


Tree traversal is one of the most common operations performed on tree data structures. It is a way in which each
node in the tree is visited exactly once in a systematic manner. There are many applications that essentially require
traversal of binary trees. For example a binary tree could be used to represent an arithmetic expression as shown
in Fig.
+

*
A

The full binary tree traversal would produce a linear order for the nodes in a binary tree. There are three
ways of binary tree traversal.
(i) In order traversal
(ii) Pre-order traversal
(iii) Postorder traversal
Inorder Traversal :

The inorder traversal of a non-empty tree is defined as follows:


(i) Traverse the left subtree inorder (L).
(ii) Visit the root node (N)
(iii) Traverse the right subtree in order (R).
Example :
A

Inorder traversal of a binary tree is DBFEGAC.


Preorder traversal:
The preorder traversal of a non-empty binary tree is defined as follows:
(i) Visit the root node (N).
(ii) Traverse the left subtree in preorder (L)
(iii) Traverse the right subtree in preorder (R)
Example: The preorder traversal of the binary tree is ABDEFGC.
Postorder Traversal:
The postorder traversal of non-empty binary tree is defined as follows:
(i) Traverse the left subtree in postorder (L).

(ii) Traverse the right subtree in postorder (R).


(iii) Visit the root node (N).
Example: The postorder traversal of a binary tree is DFGEBCA.
Level of a vertex in a full binary tree:
In a binary tree the distance of a vertex vi from the root of the tree is called the level of vi and is denoted by li.
Thus level of the root is zero. Levels of the various vertices in the following tree have been denoted by numbers
written adjacent to the respective vertices.
level 0

level 1

level 1
level 2

level 2

level 3

level 3
level 3

level 4

level 4

level 4

level 4

Number of vertices of different levels in a binary tree:


In a binary tree there will be two edges adjacent to the root vertex v0. Let these edges be v0u1 and v0v1. Levels of
each of the vertices u1 and v1 is 1. So maximum number of vertices of level 0 is 1(=20).
Again there can be either 0 or 2 edges adjacent to each of the vertices u1 and v1. Let these edges u1u2, u1u3,
v1v2 and v1v3 levels of each of the four vertices u2, u3, v2, v3 is 2. So maximum number of vertices of level 2 is
4(=22). In a similar way the levels of the 8 vertices that will be obtained by adding two edges to each of the four
vertices u2, u3, v2, v3 shall be 3. So maximum number of vertices each of level 3 is 8(=23). Not more than two
edges can be added to any of the vertices so obtained to keep the degree of that vertex
as 3.
v0

v1

u1

u2

u3

v2

v3

Proceeding in this way we see that the maximum number of vertices in a n level binary tree at levels 0, 1, 2, 3,
.......... shall be 20, 21, 22, 23, ........ respectively.
whose sum = 20 + 21 + 22 + 23+ ..........+ 2n .
The maximum level of any vertex in a binary tree (denoted by lmax.) is called height of the tree. The
minimum possible height of an n vertex binary tree is [log2(n +1) 1] which is equal to the smallest integer
[log2(n +1) 1] and Max. lmax =

n -1
2

5.6 Coloring
In coloring a map, any two regions having a common border are assigned different colors. In case the number of
regions is large, we are interested in finding out the least number of colors that can be used to color the map so
that adjacent regions do not have the same color.
In order to solve such type of problems a map in a plane is represented by a graph. Each region of the map is
represented by a vertex and two vertices representing two regions with a common border are joined by an edge.
This graph is called dual graph of the map. The problem of coloring the region of a map is converted into the
problem of coloring the vertices of the corresponding dual graph so that no two adjacent vertices in the graph
have the same color.
Example : The graph given in Fig. (a) below has its dual as shown in Fig. (b).

C
D

E
A
(a)

C
E

D
A

C
(b)

The problem of finding out the minimum number of colors required to color the map so that adjacent
regions do not have the same color is equivalent to find the least number of colors required to color the vertices of
the dual graph so that no two adjacent vertices may have the same color.
1. Coloring or proper vertex coloring of a graph: It means painting all the vertices of a graph with
such a way that no two adjacent vertices have the same color.

colors in

2. Properly vertex colored graph: It is a graph whose all vertices have been properly colored. The same graph can
be colored in different ways. Instead of writing the name of the colors we shall denote the different colors by

using different numerals 1, 2, 3, ..... etc. for the sake of convenience e.g. The green, blue, red and black colors may
be represented by the numbers 1, 2, 3 and 4 respectively.
1

1
3

3
1

[The same graph properly coloured in 3 different ways]

Edge colorings
By properly coloring the edges we mean to assign colors to different edges of a graph G such that no two adjacent
edges (two edges incident with the same vertex) receive the same color.
If we assign K colors to each of the edges of a graph G in such a way that no two adjacent edges have the same
color, then it is called a K-edge coloring of G or we say that the graph is K-edge colorable.
Edge chromatic number of G: It denotes the minimum number of colors required to properly color the graph G
and is denoted by '(G).
Examples: A graph which is union of isolated vertices and mutually disjoint edges has edge chromatic number one.

Example : Edge chromatic number of K3, a complete graph of 3 vertices is 3.

Similarly edge chromatic number of K4 and K5 are 4 and 5 respectively.


Chromatic number of a graph
It denotes the minimum number of colors, say K, required for proper coloring of the graph and the graph is
called a K-vertex chromatic graph or K-vertex colorable graph.

As we are dealing with vertex coloring here, so we shall drop using the word vertex with color, coloring or
colorable or chromatic number.

5.7 Recurrence Relation


A formula which defines any term of a sequence in terms of any number of its previous terms or which expresses
any term of a sequence as a function of its previous terms is called recursive and the relation is called a recurrence
relation. For example, the nth terms an of the sequence 3, 8, 13, 18, 23, ............ can be expressed as,
an= an1 + 5, for n

2 and a1 = 3

This formula is called recursive formula and the relation is called the recurrence relation.
To define a sequence recursively, the recursive formula has to be accompanied by information about the beginning
of the sequence as a1 = 3 in the above example. This information is called the initial condition or boundary
condition for the sequence.

Example: The sequence 4, 7, 10, 13 ........................ is defined by recurrence relation


an= an1 + 3, with a1 = 4 (called initial condition).
(b) Fibonacci sequence 1, 1, 2, 3, 5, 8, 13, 21, ...................... defined by recurrence relation
fn =

fn1 + fn2, with f1 = f2 =1 (as initial condition)

Again a formula in which the value of any term of the sequence can be determined with the help of its position
number is called explicit formula.
For example the sequence 1, 4, 9, 16, 25, is described completely by the explicit formula
an= n2, n
The explicit formula is really a solution of the recurrence relation.

Various sequences defined by recursive formula or explicit formula are given below.
Sequences

defined by formula

(i) 5, 10, 20, 40, 80, 160

c1= 5, cn= 2 cn1 2

(ii) 3, 7, 11, 15, 19, 23, ..........

d1=3, dn=dn1 + 4

(Recursive formula)

(iii) 4, 16, 64, 256............

Sn= (4)n, 1

(Explicit formula)

(Recursive formula)

(iv) 87, 82, 77, 72, 67,

tn= 925n 1

(Explicit formula)

Order of the recurrence relation

Order of an= F (an1, an2 ,........ank ) is k


where an depends on one or more of the previous k terms and k is the smallest such integer.
Therefore, if we can compute nth terms of a sequence from the preceding k terms, but not (r1) terms, we define
the order to be k.
We donot define an order for recurrence relations of the form an, = F (an1, an2, .........., n) that depend on each
of its' previous terms.
In Eq. an = F (an1, an2, .........ank)
an1, an2, .......... ank, n are all variable & F is a function.

Degree of a recurrence relation

Degree of a recurrence relation is the degree of F, treated as a polynomial in its variables excluding n. If F is not a
polynomial in its variables, no degree is assigned to the recurrence relation.
A recurrence relation is called Linear, if it is of degree one, it is called Quadratic if its degree is two.
A recurrence relation is called to be Homogeneous, if it contains no terms that depend only on the variable n.
A recurrence relation which is not homogeneous is called non-homogeneous or inhomogeneous.
Generally the term Homogeneous is used for Linear recurrences regardless of its' order.
In case of kth order recurrence, one needs to know the first k terms (a0 a1 ......., ak1, of the sequence in order to
uniquely define the sequence.
Examples of recurrence relations

1. an, = 3 an1 + n2 is non homogeneous of order 1 & degree 1


2. an = n an2 + 2n is non homogeneous of order 2 & degree 1

3. an = + a2n2 is homogeneous of order 2 & no degree

Related Definitions:
(1) A kth order recurrence relation has Initial Conditions provided the values of one or more of the terms a0, a1,
......, ak1 are known.
(2) A function f(n) is said to be a General Solution to the homogeneous recurrence relation if it satisfies the
recurrence equation.
(3) A function of g(n) is said to be a Particular Solution to the recurrence relation if it satisfies the recurrence
equation together with the initial conditions.

5.8 Methods of solving Recurrence relations

1.
2.

Characteristic roots method.


Generating functions method

1. Characteristic root method

Homogeneous & non-homogeneous recurrences and characteristic equation. General form of a linear nonhomogeneous recurrence of order k is :
un = f1(n).un1 + f2(n).un2 + ....... + fk(n).unk + g(n)
where each fi and g is a function of n.
It becomes homogeneous if g is identically zero & non-homogeneous otherwise.
General linear homogeneous equation with constant coefficient is
un = r1 un1 + r2un2 + .......+ rk unk

...(1)

where ri are constants


The characteristic equation or auxiliary equation of linear homogeneous recurrence (1) is the equation.
xk r1xk1 r2xk2 ......... rk1 x rk = 0

...(2)

Roots of characteristic equation (2) are called Characteristic roots of recurrence relation (1).

Example: If recurrence relation is un+2 = 2un un2,


Characteristic equation is xn+2 = 2xn xn2

...(1)

or x4 = 2n2 1
Characteristic roots of this recurrence are 1, 1, 1, 1 or 1 and 1 both with multiplicity 2.

Solution of a linear homogeneous recurrence relation

Solving a recurrence relation means to find a sequence {an} that satisfies it, where an is a function of n.
How to solve a Linear Homogeneous Recurrence relation ?
Theorem: A sequence {un} satisfies the linear, homogeneous recurrence relation with constant coefficients.
un = c1 un1 + c2un2 + ......... + ckunk ( n k)
if and only if each un is a sum of expressions of the form
n

b0 C(n, 0)ai + b1 C(1 + n, 1)ai + .. + bmi-1 C(mi 1 +n, mi 1)ai

where ........ are characteristic roots of multiplicity m1, m2 ........ respectively and bi's are constants.
If the characteristic roots are all distinct i.e. of multiplicity one, the form of the solution sequence is

un

j =1Aj ajn

n0

= A1a1 + A2a2 + A1a1 + .+ Akak

where are characteristic roots and Aj s are constants to be determined by initial conditions.
The method of solution shall be explained with the help of an example.

Example: Solve the sixth order linear homogeneous recurrence relation


un + un1 11un2 13un3 + 26un4 + 20un5 - 24un6 = 0
Solution. : Characteristic equation is :

x6 + x5 11x4 13x3 + 26x2 + 20x 24 = 0


or (x )2 (x 3) (x + 2)3 = 0 having its roots as follows.
root 1 of multiplicity 2
root 3 of multiplicity 1
root 2 of multiplicity 3
To solve it, the value of un is a linear combination of six terms
C(0 + n, 0).1n, c(1 + n, 1).1n ,
C(0 + n, 0).3n,
C(0 + n, 0).(2)n, C(1 + n, 1) (2)n, C(2 + n, 2).(2)n
i.e. un = a.

n+1

C01 + b.

n+1

C11 +c.

n+0

C03 +d

n+0

C0(-2) . + e.

n+1

C1(-2) +f.

n+2

C2(-2)

where a, b, c, d, e, f are constants


n

= a.1 + b.(n+1) 1 + c.3 + d. (-2) +e. (n+1)(-2) + f.((n+2)(n+1)/2!)(-2)


n

un = a + b.(n+1) + c.3 + d. (-2) +e. (n+1)(-2) +f.((n+2)(n+1)/2!)(-2)

...(1)

values of constants a, b, c, d, e, f can be determined if initial conditions (values of any six consecutive terms
of the sequence) are given.
The general solution given in (1) can also written as :
n

un = [(a + b) + b.n]1 + c.3 + [(d + e + f ) + ( e + 3f / 2)n + f / 2 n ](-2)


n

un = [A1 + A2.n]1 + A3.3 + [A4 + A5 n + A6 n ](-2)

.(2)

where A1 , A2 , A3 ,A4 ,A5 ,A6 are new constants such that


A1 = a + b, A2 = b, A3 = c, A4 = d + e + f, A5 = E + 3f/2, A6 = f/2
Values of these constants A1, A2, ....., A6 are determined with the help of initial conditions.
The general solution as given in (2) is more convenient and can be written directly if we know the characteristic
roots.
To find the general solution directly when characteristic roots are known.
Suppose that the characteristic equation corresponding to a given recurrence relation is
2

(x - a1) (x - a2) (x - a3) = 0

It means that the characteristic roots are


x = a1 with multiplicity 1
x = a2 with multiplicity 2
x = a3 with multiplicity 3
Then the general solution is given by
an or un = b1

n+0

C0 a1 + ( b2

n+0

C0 a2 + b3

n+0

C1 a2 )+ ( b4

n+0

C0 a3 + b5

n+0

C1 a3 + b6

n+0

C2 a3 )

where bi's are constants


n

= b1 a1 + [ b2 + b3 (n +1) ]a2 + [ b4 + b5 ( n +1) + b6 (n+2)(n+1)/2]a3


n

= b1 a1 + [ b2 + b3 + b3 n ]a2 + [ (b4 + b5 + b6 ) + { (b5 +(3b6/2))n + (b6/2)n }] a3


n

= A1 a1 + [ A2 + A3 n ]a2 + [ A4 + { (A5n + A6n }] a3


(on putting b1 = A1,
+(3b6/2) = A4,

b2 + b3 = A2,
b6/2 = A4

b3 = A3,
2

b4 + b5 + b6 = A4,

b5

Similarly if we have the characteristic equation as ( x- 3) ( x- 3) ( x- 3) = 0 with characteristic roots as :


x = 3 of multiplicity 2
x = 2 of multiplicity 3
x = 4 of multiplicity 4,
then the general solution of the corresponding can be written directly as :
n

un = (A1 + A2 n) 3 +( A3 + A4 n + A5 n )2 + (A6 + A7 n + A8 n + A9 n )4

where A1, A2, A3, A4, A5, A6, A7, A8, A9 are all constants whose values can be determined with the help of initial
conditions.

Method of Generating Functions:


The Method is illustrated with an example:
Example: Find explicit formula for sequence defined by cn = 3cn12cn2 with initial conditions c1 = 5, c2 = 3 by
using generating function.
Solution of the recurrence relation cn = 3cn-1 2cn-2 with initial condition c1 = 5 and c2 = 3, by using Generating
function:-

Here we are given c1= 5, c2= 3. We shall find the value of c0 by putting n = 2 in the given recurrence relation as:c2 = 3c1 2c0 or c0 = (3c1 c2)/2
or c0 = [3(5) 3]/2 (on putting values of c1 and c2)
= 6,
To solve the recurrence relation
cn = 3cn-1 2cn-2 .(1)
with initial conditions c0 = 6, c1 = 5
n

Multiplying both sides of (1) by z and summing form n = 2 to , we have

cn.Z = 3S cn-1Z - 2S cn-2Z


n=2

n=2

n=2

or A(z) c0 c1Z = 3z(A(z) c0) 2A(z)


2

or A(z) = (c0 + c1z 3c0z)/(1 3z + 2z ) = (6 13z)/(1 2z)(1 z)


(on putting values of c0 and c1)
= -1/(1 2z) + 7/(1 z) (by partial fraction)
Therefore
n

cn = Coefficient of z in A(z)
n

-1

-1

= Coefficient of z in (-1)(1 2Z) + Coefficient of z in 7(1 z)


n

= (-1)2 + 71
n

=72

th

This is the (n + 1) term of the sequence c0, c1, c2, c3 and nth term of the sequence c1, c2, c3,..

Example: Find general solution of the recurrence relation.


an = 3an1
Solution: Characteristic Eq. is x = 3. So, characteristic root is 3 with multiplicity 1.
Therefore the solution is

an = b. C (0 + n, 0). 3n
or

an = b. n+0C0.3n

or

an = b.3n

Example: Determine the constants c1 and c2 such that the recursion un + c1 un1 + c2un2 = 0 has the
characteristic roots 1 -1 .
Solution. : Characteristic equation is
2

x + + c1x + c2 = 0

....(1)

Its roots are 1 + i & 1 i (given)


Sum of roots = (1+ i ) + (1 i ) =2
Sum of roots = - c1/1 = - c1 from eq (1)
So c1 = 2 or c1 = 2
2

Product of roots = (1+ i ) . (1 i ) = 1 i = 1 + 1 = 2


Product of roots = c2 from eq(1)
So c2 = 2
Hence c1 = 2,

c2 = 2

Example: Find explicit formula for sequence defined by cn = 3cn12cn2 with initial conditions c1 = 5, c2 = 3 by
using Characteristic equation.
Solution: After determining the characteristic roots as
x = 2 of multiplicity 1
and

x = 1 of multiplicity 1,

we can directly write down the general solution as


cn = A1 (2)n + A2
or

cn = A1 2n + A2

...(4)

From c1 = 5 (given) we put n = 1 and cn = 5 in (4) to get


5 = A1 2n + A2

...(5)

From c2 = 3 (given) we put n = 2 and cn = 3 in (4) to get


4=

4 A1 + A2

... (6)

Solving equation (5) and (6) we have


A1 = 1 and A2 = 7
Therefore the solution of the given recurrence relation from (4) becomes
Cn = 2n + 7

Example: Solve the recurrence relation. dn = 2dn-1 dn-2


with initial conditions. d1= 1.5 and d2 = 3
Solution:
After determining the characteristic root as x = 1 of multiplicity 2.
We can directly write that the general solution as
n

dn = (A1 + A2 n ) 1
or

dn = A1 + A2 n

...(4)

Again from d1 = 1.5 (given), we put n = 1 and dn = 1.5 n (4) to get


1.5 = A1 + A2

...(5)

Similarly from d2 = 3 (given) we put n = 2 and dn = 3 in (4) to get


3 = A1 + 2A2

...(6)

Solving (5) and (6), we have A2 = 1.5, A1 = 0. Therefore the general solution from (4) becomes
dn = 1.5 n
same as we obtained earlier.

Example: Solve the fibonacci sequence defined as fn = fn-1 + fn-2 with initial conditions f1 = f1 =1

Solution. : Characteristic Eq. is x -x-1 = 0


Characteristic roots are (1 + 5)/2 & (1 - 5)/2 each with multiplicity 1. (say .
General solution. : fn = a1.
n

or fn = a1. a + a2 b

n+1

C 0 a + a2

n+1

C0b

...(1)

For particular solution. put in (1) the initial conditions


f1 = 1 i.e. n = 1, fn = 1 giving 1 =

a1a + a2b

f2 = 1 i.e. n = 2, fn = 1 giving 1 =

a1a + a2b

...(2)
2

...(3)

multiplying (2) by a, we have


2

a = a1. a + a2 ab

. (4)

. (3)

1 = a1. a + a2 b

Solving (3) & (4) , we have


2

Giving a2 = (a -1)/ (ab - b ) = ((((1 + 5)/2) 1) )/ (((1-5)/4) ((1 + 5 -25)/4))


= 2(5 1)/ (25 10)
= (5 1)/(- 5(5-1)) = (-1)/ 5
and a1= (1 a2b) / a = [1 {(-1)(1-5) / 25} ]/ [(1 + 5)/2]
= [( 25 + 1 - 5) / 25] / [ (1 + 5) / 2 ] = 1/5
Hence from (1) fn = 1

1 + 5

- 1
5

1 + 5
2

Example:- Use (i) generating function (ii) Characteristic roots to solve the recurrence relation un = un-1 + un-2, n 3
u1 = 1, u2 = 3.
Solution:- (i) Given recurrence relation is un = un-1 + un-2, n 3 u1 = 1, u2 = 3
From the given relation, we have u2 = u1 + u0
or u0 = u2 u1 = 3 1 = 2
Therefore the given recurrence relation becomes

un = un-1 + un-2 n 2, u0 = 2, u1 = 1 (1)


Multiplying both the sides of the given relation (1) by
n

Z and summing form n = 2 to we get

S unz = S un-1z + S un-2z


n=2

n=2

n=2

or S unz = zS un-1z
n=2

n-1

+ z S un-2z

n=2

n-2

n=2
2

or A(z) u0 u1z = z[A(z) u0] + z A(z)


or A(z) = (u0 + u1z u0z) / 1 z z

= (2 z) / 1 z z (2)
(on putting values of a0 and a1)
2

= (2 z) / (1 - az)(1 - bz), [where a, b are roots of the eq. 1 z z = 0


a = (1 + 5)/2, b = (1 - 5)/2
a + b = 1, ab = -1]
= (2a - 1) / (a - b)(1 - az) + (2b - 1) / (b - a)(1 - bz)
(by partial fractions)

-1

-1

= 1 [(2a - 1)(1 - az) (2b - 1)(1 - bz) ]


a-b
n

Therefore un= Coefficient of z in A(z)


n

-1

-1

or un = 1 [Coeff of z in (2a - 1)(1 - az) Coeff of z in (2b - 1)(1 - bz) ]


a-b

= 1 [(2a - 1)a (2b - 1) b ]


a-b

= 1 [5 [(1 + 5)/2] + 5[(1 - 5)/2]


5
on putting values of a and b
n

=[(1 + 5)/2] + [(1 - 5)/2]

th

This is n term of the sequence u1, u2, u3,.

(ii) By characteristic roots:n

The characteristic equation is x = x

n-1

+x

n-2

or x x 1 = 0 .(1)
Its characteristic roots are
x = (1 + 5)/2 of multiplicity 1.
and x = (1 - 5)/2 of multiplicity 1.
Hence the general solution is

un = A1[(1 + 5)/2] + A2[( 1 - 5)/2]


n

or un = A1a + A2b .(2)


where a = (1 + 5)/2 and b = ( 1 - 5)/2
Putting values u1 = 1 i.e. n = 1 and un = 1 u2 = 3 i.e. n = 2 and un = 3, we have
1 = A1a + A2b.(3)
and

3 = A1a + A2b ..(4)

Solving equations (3) and (4), we have


2

A1 = (b - 3) / (ab - a ) = 1 on putting values of a and b


and

A2 = (1 A1a) / b = 1
n

Hence un = [(1 + 5)/2] + [( 1 - 5)/2]

Example:- Use generating function to solve the recurrence relation

an = an-1 + an-2, n 3, a1 = 1, a2 = 1 directly. (Without calculating a0)


Solution:- The given sequence is an = an-1 + an-2, n 3 (1)
n

Multiplying both the sides of (1) by z and summing up from n = 3 to n = , we get

anz = an-1z + an-2z


n=3

n=3

n=3

= zan-1z

n-1

+ z an-2z

n-2

n=3

(2)

n=3

Now the terms on the L.H.S. is

anz = a3z + a4z +.


n=3
2

= (a1z + a2z + a3z + a4z + ..) a1z a2z

= A(z) a1z a2z .(3)


First term in the R.H.S. of (2) is

zan-1z

n-1

n=3

= z[a2z + a3z + .]
2

= z[(a1z + a2z + a3z + ) a1z]


2

= z[A(z) a1z] = zA(z) a1z (4)


second term in the R.H.S. of (2) is

z an-2z

n-2

= z [a1z + a2z + .]

n=3
2

= z A(z) (5)
Putting values of all the terms from (3), (4) and (5) in (2), we have
2

A(z) a1z a2z = zA(z) a1z + z A(z)

or A(z)[1 z z ] = a1z + a2z a1z


2

2
2

or A(z) = (a1z + a2z a1z ) / (1 z z )


2

= z / (1 z z ), (on putting given values of a1 and a2)


2

Solving 1 z z = 0, we get its two roots as


a = (1 + 5)/2 and b = (1 - 5)/2
From (6) we can write
A(z) = z/(1 - az)(1 - bz)
= 1 [1/(1 - az) 1/(1 - bz)]
a-b
n

Therefore nth terms un = Coefficient of z in the expression of A(z)


n

-1

-1

= 1[Coeff of z in ( 1 - az) Coeff of z in (1 - bz) ]


a-b
n

= 1[a - b ]

n1

a-b
n

= 1/5[{(1 + 5)/2} {(1 - 5)/2} ]


th

This is n term of the sequence a1, a2, a3,

Different methods to determine a Particular solution of non-homogeneous recurrence relations:

Type-1: When g(n) is of the form an , where a is a constant and d N


d

Rule-1: A particular solution of (1) with non-homogeneous part, g(n) = an , where a is a known constant and d N,
is of the form :
(i)
(ii)

A0 + A1 n + A2 n + +Ad n , if 1 is not a characteristic root of (1) ;


A0 nm+ A1 nm+1 + A2 nm+2 +.+ Ad nm+d , if 1 is a characteristic root of (1) with multiplicity m,
where A0, A1, A2, .. Ad are constants.

Example: Find complete solution of the recurrence relation un = 3un-1 4n (n 1)


Solution: The associated homogeneous recurrence relation is

un = 3un-1 ..(1)
n

n-1

The corresponding characteristic equation is x 3x

= 0 or x 3 =

Its characteristic root is x = 3 of multiplicity 1. Therefore the general solution of (1) is


un = B1.3

...(2) (B1 is a constant)

Then we attempt to find the particular solution of the recurrence relation.


1

Here , g(n) = -4n = -4.n , which is of the form (given in type-1). Also 1 is not a characteristic root of (1). As a =
4, d = 1, the particular solution is of the form
un = A0 + A1.n by Rule 1(i)

...(3)

Putting this value of in the given recurrence relation un = 3un-1 4n , we have


A0 + A1n = 3[A0 + A1(n 1)] 4n
0

...(4)
1

Comparing coefficients of n and n in both sides of (4), we have


A0 = 3A0 3A1
and

A1 = 3A1 - 4

...(5)
...(6)

Solving eqs. (5) and (6), we get A1 = 2, A0 = 3. Thus the particular solution (3) becomes
un = 3 + 2n

...(7)

The complete solution shall be the sum of general solution of the associated homogeneous recurrence relation
(given in eq. (2)) and the particular solution (given in (7)) i.e.
n

un = B1.3 + 3 + 2n

Example: Find the complete solution of un = un-1 + n


Solution : The given recurrence relation is
un = un-1 + n, n 0, u1 = 3

...(1)
n

The associated homogeneous recurrence relation shall be un = un-1, whose characteristic equation is x = x
n
1 = 0 and its characteristic root is x = 1 of multiplicity 1. Therefore the general solution is un = B1.1
or un = B1.

...(2)
d

To find particular solution of (1), we see that g(n) = n is of the form a n where a = 1 and d = 1
As the characteristic root is 1, the particular solution by Rule 1 (ii) of Type 1 form is
1

un = A0.n + A1.n

1+1

n-1

or x

or un = A0n + A1.n

...(3)

Putting value of un from (3) is eq. (1), we have


2

A0n + A1n = [A0(n 1) + A1(n 2) ] + n


2

or A0n + A1n = (-A0 + A1) + (A0 2A1 + 1)n + A1n

...(4)

Comparing the coefficients of n0 and n in both sides of eq. (4), we have


0 = -A0 + A1
and

...(5)

A0 = A0 2A1 + 1

...(6)

Solving eqs. (5) and (6), we get A1 = 1/2, A0 = 1/2 . Thus the particular solution from (3) becomes
2

un = (1/2)n + ()n

...(7)

The complete solution of the given recurrence is the sum of soln. given in eqs. (2) and (7). Hence
un = B1 + ()n + ()n

...(8)

The initial condition is u1 . Putting n = 1 and un = 3 in(8), we get . B1= 2


Putting this value of in (8), the required solution is
2

n1

un = 2 + 1n/2 + 1n /2,

Type 2 : When g(n) is of the form ar , where a is a known constant.


Rule-2 : A particular solution of (1) with non-homogeneous part arn (where a is a known constant) is of the form
:
(i) Arn , if r is not a characteristic root of (1) ;
(ii) Anmrn , if r is a characteristic root of (1) with multiplicity m, where A is a constant.

Example: Give complete solution of the recurrence relation un 4un-1 + 3un-2 = 5


Solution. : The given recurrence relation is
un = 4un-1 + 3un-2 + 5

...(1)

The associated homogeneous equation is


un = 4un-1 + 3un-2
2

The characteristic eq. is x + 4x + 3 = 0 or (x 3)(x 1) = 0.

...(2)

Its characteristic roots are


x = 3 of multiplicity 1
and x = 1 of multiplicity 1
Therefore the general solution of eq. (2) is
n

un = B1.3 B2.1
n

or

un = B1.3 + B2

...(3)

n
To find particular solution of (1) we see that g(n) = 5n which is of the type 2 i.e. a.r , a = 1,

r = 5.

Moreover r = 5 is not a characteristic root, therefore by Rule 2 (i) of type 2, the particular solution
n

un = A.5

...(4)

Putting this value of from (4) in (1), we have


n

n-1

A.5 = 4.5

n-2

3.A.5

n-2

+ 5 or dividing by 5

A.5 = 4.A.5 3.A + 25, giving A = 25/8

, we have

...(5)

Putting the value of A in (4) the particular solution becomes


n

n+2

un = 25.5 /8 = 5 /8

...(6)

The complete solution shall be the sum of solution. given in (3) and (6). Hence
n

n+2

un = B1.3 + B2 + 5 /8

Example: Solve the recurrence relation un = 6un-1 9un-2 + 3 .


n

Solution. : The given eq. is un = 6un-1 9un-2 + 3 .

...(1)

Its associated homogeneous eq. is un = 6un-1 9un-2

...(2)

The characteristic eq. is x 6x + 9 = 0 or (x 3) = 0


The characteristic root is x = 3 of multiplicity 2.
n

Therefore the general solution of (2) is un = (B1 + B2.n).3

...(3)
n

To find the particular solution of (1) we see that g(n) = 3 is of type 2 i.e. ar , a = 1, r = 3 and 3 is also characteristic
root. Therefore by Rule 2 (ii), the particular solution is given by
2

un = A.n .3 . Where A is a constant.


Putting this value of un from (4) in eq. (1) we have,

...(4)

n-1

9.A.(n 2) . 3

n-1

9.A.(n 2) + 3

A.n .3 = 6A.(n 1) . 3
A.n .3 = 6A.(n 1) . 3
2

n-2

+ 3 or dividing both sides by we get

or 9A.n = 18A(n 1) 9A(n 2) + 9


2

or A[9n 18(n 1) + 9(n 2) ] = 9


or A[18] = 9 giving A = 1/2
Putting this value of A in eq. (4) the particular solution is given by
2

un = 1(n .3 )/2

...(5)

The required solution is the sum of soln. given in (3) and (5). Hence un = (B1 + B2n)3 + 1(n .3 )/2
Type-3 : When g(n) is of the form g1(n) + g2(n)
Rule-3 : (Superposition Principle) :
If {an} is a solution of is a solution of un = c1un-1 + c2un-2 + +ckun-k + g1(n) and {bn}, is a solution of un =
c1un-1 + c2un-2 + +ckun-k + g1(n), then the solution of
un = c1un-1 + +ckun-k + Ag1(n) + Bg1(n) is given by A.an + B.bn , where A and B are constants.

Example: Solve the recurrence relation un 7un-1 + 16un-2 12un-3 = 2 + 3 ,


u0 = 0, u1 = 1, u2 = 1
n

Solution. : Given relation is un 7un-1 + 16un-2 12un-3 = 2 + 3

...(1)

Associated homogeneous relation shall be


un 7un-1 + 16un-2 12un-3 = 0

...(2)

The characteristic equation shall be


3

x 7x + 16x 12 = 0 or (x 2) (x 3) = 0

...(3)

the characteristic roots shall be


x = 2 of multiplicity m = 2
and x = 3 of multiplicity m = 1
The general solution of (2) shall be
n

un = (B1 + B2.n)2 + B3.3

...(4)

B1, B2, B3 are constants and n 0.


The non-homogeneous part g(n) is of the form
n

g(n) = g1(n) + g2(n) = 2 + 3

...(5)

To find the particular solution corresponding to g1(n) = 2 we see that it is of the type 2 i.e. a.rn where a = 1, r = 2
and also 2 is a characteristic root of multiplicity m = 2.
n

Therefore by rule 2 (ii) the particular solution corresponding to g1(n) = 2n shall be of the form
m n

A1n .r = A1n .2

...(6)

where A1 is a constant.
n
Again to find particular solution corresponding to g2(n) = 3 , we see that it is also of the type 2 i.e. arn where a = 1,
r = 3 and also 3 is a characteristic root of multiplicity m = 1. Therefore by rule 2(ii) particular solution corresponding
n
to g2(n) = 3 shall be of the form.
m n

A2n r = A2.n3

...(7)

where A2 is a constant
n

Therefore by rule 3, the particular solution of g(n) = g1(n) + g2(n) = 2 + 3

shall be the sum of solutions given by


2

un = A1.n .2 + A2.n.3

...(8)

Putting this value of un from eq. (8) in eq. (1) we get


2

A1.n .2 + A2.n.3 7[A1(n 1) .2


n-3
n
n
A2(n 3).3 ] = 2 + 3
2

or A1[n .2 7(n 1) .2
n-3
n
n
3).3 ] = 2 + 3
n-3

n-1

n-1

n-1

+ 16(n 2) . 2

+ A2(n -1).3 ] + 16[A1(n 2) . 2


n-2

n-2

n-3

n-2

n-1

12(n 3) .2 ] + A2[n.3 7(n 1).3

n-3

+ A2.(n 2).3 ] 12[A1(n 3) .2


n-2

+ 16(n 2)3

n-3

12(n

or A1. 2 [n .2 7(n 1) .2 + 16(n 2) .2 12(n 3) ] + A2.3 [n.3 7(n 1).3 + 16(n 2)3 12(n 3)] =
n
n
2 +3
or A1.2

n-3

n-3

[-8] + A2.3 [3] = 2 + 3

or A1.2 + A2.3 = 2 + 3
or A2.3
or

n-2

3 =2 +3
n-2

3 (A2 9) = 2 ( 1 + A1)

..(9)

This equality is true for every value of n 3 which is possible if A2 9 = 0 i.e. A2 = 9 and i.e. 1 + A1 = 0 i.e. A1 = -1.
Putting these values in eq. (1) the particular solution is given by :

un = - 1.n .2 + 9.n3

or

un = -n .2 + 9.n3

....(10)

Hence the complete soln. of eq. (1) is the sum of solution given in(4) and (10) i.e.
n

un = (B1 + B2n)2 + B3.3 n .2 + 9n.3


2

or un = (B1 + B2n n ).2 + (B3 + 9n).3 ...(11)


The initial conditions are u0 = 0, u1 = 1, u2 = 0
Putting these values in (11) we have
0 = B1 + B3 or B1 + B3 = 0
1 = (B1 + 2B2 1).2 + (B3 + 9).3 or 2B1 + 2B2 + 3B3 = -24
0 = (B1 + 2B2 4).4 + (B3 + 18).9 or 4B1 + 8B2 + 9B3 = -146
Solving these three equations we have
B1 = 50 B2 = 13 B3 = 50
Therefore the required complete solution from (11) is
2

un = (50 + 13 n )2 + (9n 50).3

d n

Type-4: When g(n) is of the form a.n .r where a and r are known constants and
Example- Solve the following recurrence relation:
r

ar - 5ar-1 + 6ar-2 = 2 + r
Solution:- Given recurrence relation is
r

ar 5ar-1 + 6ar-2 = 2 + r .(1)


The corresponding homogeneous recurrence relation is
ar 5ar-1 + 6ar-2 = 0 (2)
Its characteristic equation is
2

x 5x + 6 = 0,
whose characteristic roots
x = 3 of multiplicity 1
and

x = 2 of multiplicity 1

Therefore the general solution is given by


r

ar = B13 + B22 .(3)


where B1 and B2 are constants.

Particular Solution corresponding to 2 + r


r

Particular solution corresponding to the first terms g1(r) = 2 shall be of the form
r

A0r2 .(4)
by Rule-2 (i) as 2 is not a characteristic root.
Again Particular solution corresponding to g2(r) = r shall be of the form
A1 + A2r (5)
by rule 1-(i).
r

Then by rule 3, the particular solution of g1(r) + g2(r) = 2 + r shall be of the form
r

ar = A0r2 + A1 + A2r (6)


where A0, A1, A2 are all constants.
Putting this value of ar from eq. (6) in eq. (1) , we have
r

r-1

r-2

A0r2 + A1 + A2.r 5[A0(r 1)2 + A1 + A2(r 1)] + 6[A0(r 2)2 + A1 + A2(r 2)] = 2 + r
r

r-1

r-1

r-2

r-2

or A0r2 + A1 + A2r 5A0r2 5A1 5A2r + 5A02 + 5A2 + 6A0r2 + 6A1 + 6A2r 12A02 12A2 = 2 + r
r-2

r-2

or A0r2 (2 10 + 6) + 2A1 + 2A2r + A02 (10 12) 7A2 = 2 + r


r-2

or 2A1 + 2A2r 2A02 7A2 = 2 + r


r-1

or 2A1 + 2A2r A02 7A2 = 2 + r


r-1

or A02 2 + 2A1 + 2A2r 7A2 r = 0


r-1

or -2 (A0 + 2) + r (2A2 1) + (2A1 7A2) = 0


which is true if
A0 + 2 = 0, 2A2 1 = 0, 2A1 7A2 = 0 giving A0 = - 2, A2 = +1/2 , A1 = 7/4
Putting these values in (6), we get the particular solution as
r

ar = -2r2 + 7/4 + (1r)/2


or

r+1

ar = -r2

+ (1r)/2 + 7/4 .(7)

Combining (3) and (7) the complete solution is


r

r+1

ar = B13 + B22 - r2

+ (1r)/2 + 7/4.(8)

we are also given a0 = 1 i.e. ar = 1 where r = 0.


and

a1 = 1 i.e. ar = 1 where r = 1.

Putting these values in relation (8), we have


1 = B1 + B2 + 7/4 or B1 + B2 = -3/4 .(9)
and 1 = 3B1 + 2B2 7/4 or 3B1 + 2B2 = 11/4 (10)
Solving equation (9) and (10), B1 = 17/4 , B2 = -5
Thus from (8) the complete solution is
r

r+1

ar = (17/4)3 - 5(2 ) - r2

+ r/2 + 7/4

Rule-4 : A particular solution of (1) with non-homogeneous part a.nd., where a and r are known constants and
shall be of the form
(i) , if neither r nor 1 are characteristic roots of (1);
(ii) , if either r or 1 (but not both) is a characteristic root of (1) with multiplicity m;
(iii) , if r and 1 both are characteristic roots of (1) with multiplicities , respectively. are all constants.
Example: If the characteristic roots of a recurrence relation are :
x = 1 of multiplicity 2
x = 1 of multiplicity 3
and x = 2 of multiplicity 5,
n

2+3

then the particular solution corresponding to the non-homogeneous function g(n) = l1.n(-1) shall be A.n .(-1)
5
n
5
n
(A0 + A1n) or n (-1) (AA0 + AA1n) or n (-1) (k0 + k1n) by rule 4 (iii) as 1 and 1 both are characteristic roots.
2

2+5

Similarly the particular solution corresponding to the non-homogeneous function g(n) = l23 .2 shall be An .2n(A0
2
3
+ A1n + A2n + A3n ) by the same rule 4(iii). This can also be written as
7

n .2 .(L0 + L1n + L2n + L3n )


where L0, L1, L2, L3 are constants.

5.9 Combinatorics
Basic Counting Techniques: Some probability problems can be attacked by specifying a sample space S={a1,
a2 ,an }in which each simple event has probability 1/n (i.e. is "equally likely"). Thus, if a compound event

A consists of r simple events, then P(A) =r/n. To use this approach we need to be able to count the number of events
in S and in A.

General Counting Rules: There are two basic rules for counting which can
deal with most problems. The rules are phrased in terms of ``jobs" which are
to be done.
The Addition

1.

Rule: Suppose we can do job 1 in

job 1 or job 2, but not both, in


There are
The Multiplication

2.

ways and job 2 in

ways. Then we can do either

ways. For example, suppose a class has 30 men and 25 women.

ways the prof. can pick one student to answer a question.

Rule: Suppose we can do job 1 in

ways and an unrelated job 2 in

ways. Then

we can do both job 1 and job 2 in


ways. For example, to ride a bike, you must have the chain on
both a front sprocket and a rear sprocket. For a 21 speed bike there are 3 ways to select the front sprocket
and 7 ways to select the rear sprocket.
Example : Five boys and five girls are to be seated in a row. In how many ways can then be seated if
a. No two boys can be seated together
b. John and Mary must be seated together
Solution:
a) As no two boys can be seated together, alternate seats will be taken by girls and boys.
So, No of arrangements = 2(5X5X4X4X3X3X2X2X1X1) =2X5! X 5!

b)

John and Mary must be seated together. They can have 2 seating sequences(JM or MJ)
So, 9! are the no of arrangements of 9 seats(John and Mary are considered 1 seat).
Total no of arrangement of 10 seats = 2 X 9!

Example: In how many ways can a committee consisting of three men and two women be chosen from seven
men and five women?
Solution: The three men can be chosen from the seven men

C3 ways, and the women can be chosen from the

five women in C 2 ways. Hence the committee can be chosen in


7

C3 . 5 C 2 =

7 .6 . 5 5 .4
= 350 ways.
.
3 .2 .1 2 .1

5.10 Pigeon hole principle:


Statement: the pigeonhole principle states that if there are more pigeons than pigeonholes, then there must be at
least one pigeonhole with at least two pigeons in it.

Example : Among any group of 27 English words, there must be at least two that begin with the same letter, since
there are only 26 letters in the English alphabet.
Here, no of pigeons = 27
No of pigeonholes = 26
So, at least one pigeonhole will have two pigeons.
Example : Assume there are three men and five women at a party. Show that if these people are lined up in a row, at
least two women will be next to each other.
Consider the case where the men are placed so that no two men are next to each other and not at either end of the
line. In this case, the three men generate four potential locations (pigeonholes) in which to place women (at either
end of the line or two locations between men within the line). Since there are five women (pigeons), at least one slot
will contain two women who must, therefore, be next to each other. If the men are allowed to be placed next to each
other or at the end of the line, there are even fewer pigeonholes and, once again, at least two women will have to be
placed next to each other.

Anda mungkin juga menyukai