DMS-Notes
DMS-Notes
Module 1
Mathematical Logic
Content
From the above examples we note that 1, 2, 3 are proposition, whereas 4 and 5 are not the
propositions.
Logical Connectives and Truth table:
New propositions are obtained by starting with given propositions with the aid of words or
phrases like ‘not’, ‘and’, ‘if … then, and ‘if and only if’. Such words or phrases are called
Logical connectives.
1. Negation:
A proposition is obtained by inserting the word ‘not’ at an appropriate place in the given
proposition is called the negation of the given proposition.
The negation of a Proposition p is denoted by ¬ p (read ‘not p’). For any Proposition p, if p
is true, then ¬ p is false, and if p is false, then ¬ p is true. i.e., If the truth value of a proposition
p is 1 then the truth value of ¬ p is 0 and If the truth value of a proposition p is 0 then the truth
value of ¬ p is 1.
Example:
p: 4 is an even number.
¬ p: 4 is not an even number.
Truth table for Negation
p ¬p
0 1
1 0
2. Conjunction:
A compound proposition obtained by combining two given propositions by inserting the
word ‘and’ in between them is called the conjunction of the given proposition.
The conjunction of two propositions p and q is denoted by p ˄ q (read ‘p and q’). The
conjunction p ˄ q is true only when p is true and q is true, in all other cases it is false. i.e., the
truth value of the conjunction p ˄ q is 1 only when the truth value of p is 1 and truth value of
q is 1, in all other cases the truth value of p ˄ q is 0.
Example:
p: √2 is an irrational number.
q: 9 is a prime number.
p q p˄q
0 0 0
0 1 0
1 0 0
1 1 1
3. Disjunction:
A compound proposition obtained by combining two given propositions by inserting the word
‘or’ in between them is called the disjunction of the given propositions.
The disjunction of two propositions p and q is denoted by p ˅ q (read ‘p or q’). The disjunction
p ˅ q is false only when p is false and q is false, in all other cases it is true. i.e., the truth value
of the disjunction p ˅ q is 0 only when the truth value of p is 0 and truth value of q is 0, in all
other cases the truth value of p ˅ q is 1.
Example:
p: All triangles are equilateral.
q: 2+5=7.
p ˅ q: All triangles are equilateral or 2+5=7.
Truth table for Disjunction
p q p˅q
0 0 0
0 1 1
1 0 1
1 1 1
4. Exclusive Disjunction:
We require that the compound proposition “p or q” to be true only when either p is true or q
is true but not both. The exclusive or is denoted by the ⊻.
The compound proposition p ⊻ q (read as either p or q but not both) is called as exclusive
disjunction of the propositions p and q. i.e., p ⊻ q = (p ˄ ¬ q) ⅴ (q ˄ ¬ p)
Example:
p:9 is a prime number
q: all triangles are isosceles.
p ⊻ q: Either 9 is prime number or all triangles are isosceles, but not both
Truth table for Exclusive Disjunction
p q p⊻q
0 0 0
0 1 1
1 0 1
1 1 0
5. Conditional:
A compound proposition obtained by combining two given propositions by using the words
‘if’ and ‘then’ at appropriate places is called a conditional.
The Conditional “If p, then q” is denoted by p → q and the Conditional “If q, then p” is
denoted by q → p. The Conditional p → q is false only when p is true and q is false, in all
other cases it is true. i.e., the truth value of the conditional p → q is 0 only when the truth
value of p is 1 and the truth value of q is 0, in all other cases the truth value of p → q is 1.
Example:
p: 3 is a prime number.
q: 9 is a multiple of 6
Truth table for Conditional
6.
p q p→q
0 0 1
0 1 1
1 0 0
1 1 1
Biconditional:
Let p and q be two sample propositions then the conjunction of the conditionals p → q and q
→ p is called the biconditional of p and q. It is denoted by p ↔ q and it is same as (p → q) ˄
(q → p) is read as “If p then q and if q then p”.
Truth table for Biconditional
0 0 1 1 1
0 1 1 0 0
1 0 0 1 0
1 1 1 1 1
Problems:
1. Construct the truth tables for the following propositions.
(i). p ˄ (¬ q) (ⅱ). (¬ p) ˅ q (ⅲ). p → (¬ q) (ⅳ). (¬ p) ⊻ (¬ q)
Solution:
The desired truth tables are obtained by considering all possible combinations of the
truth values of p and q. the combined form of required truth table is given below
p q ¬p ¬q p ˄ (¬ q) (¬ p) ˅ q p → (¬ q) (¬ p) ⊻ (¬ q)
0 0 1 1 0 1 1 0
0 1 1 0 0 1 1 1
1 0 0 1 1 0 1 1
1 1 0 0 0 1 0 0
2. Let p, q and r be propositions having truth values 0, 0 and 1 respectively. Find the truth
values if the following compound propositions:
(ⅰ). (p ˅ q) ˅ r (ⅱ). (p ˄ q) ˄ r (ⅲ). (p ˄ q) → r
(ⅳ). p → (q ˄ r) (ⅴ). p ˄ (q → r) (ⅵ). p → (q →¬ r)
Solution:
(i) Since both p and q are false then (p ˅ q) is also false. Since r true it follows that (p ˅ q) ˅ r
is true. Thus, the truth value of (p ˅ q) ˅ r is 1.
(ii) Since both p and q are false, (p ˄ q) is false. Since (p ˄ q) is false and r is true (p ˄ q) ˄ r is
false. Thus, the truth value of (p ˄ q) ˄ r is 0.
(iii) Since (p ˄ q) is false and r is true, (p ˄ q) → r is true. Thus, the truth value of (p ˄ q) → r
is 1.
(iv) Since q is false and r is true, (q ˄ r) is false. Also, p is false, therefore p → (q ˄ r) is true.
Thus, the truth value of p → (q ˄ r) is 1.
(v) Since r is true and q is false (q → r) is true. Also, p is false. Therefore, p ˄ (q → r) is false.
Thus, the truth value of p ˄ (q → r) is 0
(vi) Since r is true, ¬ r is false. Since q is false, q → (¬ r) is true. Also, p is false. Therefore,
p → (q →¬ r) is true. Thus, the truth value of p → (q→¬ r) is 1.
3. Indicate how many rows are needed in the truth table for the compound proposition
(p ˅ (¬ q)) ↔ ((¬ r) ˄ s) → t. Find the truth value of the proposition if p and r, are true
and q, s, t, are false.
Solution:
The given compound proposition contains five primitives p, q, r, s, t. Therefore, the number of
possible combinations of the truth values of these components which we have to consider is
25=32. Hence 32 rows are needed in the truth table for the given compound proposition.
Next, suppose that p and r, are true and q, s, t are false, then ¬ q is true and ¬ r is false. Since p
is true and ¬ q is true, (p ˅ (¬ q)) is true on the other hand, since ¬ r is false and s is false, ¬ r
˄ s is false. Also, t is false. Hence ((¬ r) ˄ s) →t is true.
Since (p ˅ (¬ q)) is true and ((¬ r) ˄ s) → t is true, it follows that the truth values of the given
propositions (p ˅ (¬ q)) ↔ ((¬ r ˄ s) → t is 1.
(vi) If a circle is not a conic then √5 is a real number and if √5 is a real number then a
circle is not a conic.
0 0 0 1 0 1 0 0
0 0 1 0 0 1 1 0
0 1 0 1 0 1 0 0
0 1 1 0 0 1 1 1
1 0 0 1 0 1 1 0
1 0 1 0 0 1 1 0
1 1 0 1 1 1 1 1
1 1 1 0 1 0 1 1
☻Tautology and Contradiction:
A compound proposition which is true for all possible truth values of its components is called
a tautology.
A compound proposition which is false for all possible truth values of its components is called
Contradiction or an absurdity.
A compound proposition that can be true or false is called a contingency. In other words, a
contingency is a compound proposition which is neither a tautology nor a contradiction.
Problems:
1. Show that for any proposition p and q, the compound proposition p → (p ˅ q) is a tautology
and the compound proposition p ˄ (¬ p ˄ q) is called contradiction.
Solution:
Let us first prepare the truth tables for p → (p ˅ q) and p ˄ (¬ p ˄ q). these truth tables are
shown below in the combined form.
p q p˅q p → (p ˅ q) ¬p (¬ p ˄ q) p ˄ (¬ p ˄ q)
0 0 0 1 1 0 0
0 1 1 1 1 1 0
1 0 1 1 0 0 0
1 1 1 1 0 0 0
From the above table we note that, for all possible values of p and q the compound proposition
p → (p ˅ q) is true and the compound proposition p ˄ (¬ p ˄ q) is false.
Therefore p ˄ (¬ p ˄ q) is contradiction and p → (p ˅ q) is tautology.
Solution:
The following truth table gives the required result.
p q r p→q q→r (p → q) ˄ (q → r) p→r (p → q) ˄ (q → r) → (p → r)
0 0 0 1 1 1 1 1
0 0 1 1 1 1 1 1
0 1 0 1 0 0 1 1
0 1 1 1 1 1 1 1
1 0 0 0 1 0 0 1
1 0 1 0 1 0 1 1
1 1 0 1 0 0 0 1
1 1 1 1 1 1 1 1
0 0 0 1 1 1 0 1
0 0 1 1 1 1 0 1
0 1 0 1 0 0 1 1
0 1 1 1 1 1 1 1
1 0 0 0 1 0 1 1
1 0 1 1 1 1 1 1
1 1 0 0 0 0 1 1
1 1 1 1 1 1 1 1
0 0 0 1 1 1 0 1 1
0 0 1 1 1 1 1 1 1
0 1 0 1 1 1 1 1 1
0 1 1 1 1 1 1 1 1
1 0 0 0 0 0 0 0 1
1 0 1 0 1 1 1 1 1
1 1 0 1 0 1 1 1 1
1 1 1 1 1 1 1 1 1
Solution:
The following truth table gives the required result.
0 0 0 1 1 1 1 1
0 0 1 1 1 1 1 1
0 1 0 1 0 0 1 1
0 1 1 1 1 1 1 1
1 0 0 0 1 0 0 1
1 0 1 0 1 0 1 1
1 1 0 1 0 0 0 1
1 1 1 1 1 1 1 1
0 0 0 1 1 1 0 0 1
0 0 1 1 1 1 0 0 1
0 1 0 1 0 0 1 0 1
0 1 1 1 1 1 1 1 1
1 0 0 0 1 0 1 0 1
1 0 1 1 1 1 1 1 1
1 1 0 0 0 0 1 0 1
1 1 1 1 1 1 1 1 1
p q r ¬r p˅q (p ˅ q) → r ¬ (p ˅ q) ¬ r → ¬ (p ˅ q) (p ˅ q) → r ↔ (¬ r →
¬ (p ˅ q))
0 0 0 1 0 1 1 1 1
0 0 1 0 0 1 1 1 1
0 1 0 1 1 0 0 0 1
0 1 1 0 1 1 0 1 1
1 0 0 1 1 0 0 0 1
1 0 1 0 1 1 0 1 1
1 1 0 1 1 0 0 0 1
1 1 1 0 1 1 0 1 1
0 0 0 1 1 1 1 1 1
0 0 1 1 1 1 1 1 1
0 1 0 1 1 0 1 1 1
0 1 1 1 1 1 1 1 1
1 0 0 0 0 1 1 1 1
1 0 1 0 1 1 1 1 1
1 1 0 1 0 0 0 0 1
1 1 1 1 1 1 1 1 1
☻Logic equivalence:
Two statement s1, s2 are said to be logically equivalent, and we write s1↔s2, when the statement
s1 is true (respectively false) if and only if the statement s2 is true (respectively false). Or the
biconditional s1↔s2 is a tautology
Problems:
p q ¬p ¬p˅q p→q
0 0 1 1 1
0 1 1 1 1
1 0 0 0 0
1 1 0 1 1
From the column 4 and 5 of the above truth table, we find that ¬ p ˅ q and p → q has the same
truth values of p and q. Therefore (p → q)⇔( ¬ p) ˅ q.
p q ¬p ¬q p→¬q q→¬p
0 0 1 1 1 1
0 1 1 0 1 1
1 0 0 1 1 1
1 1 0 0 0 0
From the column 5 and 6 of the above truth table, we find that p → ¬ q and q → ¬ p has the
same truth values of p and q. Therefore (p →¬ q)⇔ (q → ¬ p).
3. For any two propositions p, q Prove that (p ⊻ q)⇔(p ˅ q) ˄ ¬ (p ˄ q).
Solution: The following truth table gives the required result.
p q (p ˅ q) (p ⊻ q) (p ˄ q) ¬ (p ˄ q) (p ˅ q) ˄ ¬ (p ˄ q)
0 0 0 0 0 1 0
0 1 1 1 0 1 1
1 0 1 1 0 1 1
1 1 1 0 1 0 0
From the column 4 and 7 of the above truth table, we find that (p ⊻ q) and (p ˅ q) ˄ ¬ (p ˄ q)
has the same truth values of p and q. Therefore (p ⊻ q)⇔(p ˅ q) ʌ¬ (p ˄ q).
4. For any propositions p, q, r. Prove that [(p → (q → r)]⇔ [(p ˄¬ r) → ¬ q)]
Solution: The following truth table gives the required result.
p q r ¬q ¬r q→r p ˄¬ r p → (q → r) (p ˄¬ r) → ¬ q)
0 0 0 1 1 1 0 1 1
0 0 1 1 0 1 0 1 1
0 1 0 0 1 0 0 1 1
0 1 1 0 0 1 0 1 1
1 0 0 1 1 1 1 1 1
1 0 1 1 0 1 0 1 1
1 1 0 0 1 0 1 0 0
1 1 1 0 0 1 0 1 1
From the column 8 and 9 of the above truth table, we find that [p → (q → r)] and [(p ˄¬ r) →
¬ q)] has the same truth values of p and q. Therefore [(p → (q → r)]⇔ [(p ˄¬ r) → ¬ q)].
5. Show that the compound propositions p ˄ ((¬ q) ˅ r) and p ˅ (q ˄ (¬ r)) are not logically
equivalent.
Solution: The following truth table gives the required result
p q r ¬q ¬r ¬q˅r q˄¬r p ˄ ((¬ q) ˅ r) p ˅ (q ˄ (¬ r))
0 0 0 1 1 1 0 0 0
0 0 1 1 0 1 0 0 0
0 1 0 0 1 0 1 0 1
0 1 1 0 0 1 0 0 0
1 0 0 1 1 1 0 1 1
1 0 1 1 0 1 0 1 1
1 1 0 0 1 0 1 0 1
1 1 1 0 0 1 0 1 1
From the last two rows we note that p ˄ ((¬ q) ˅ r) and p ˅ (q ˄ (¬ r)) do not have the same
values in all possible situations. Therefore, they are not logically equivalent.
The Laws of Logic:
For any primitive statements p, q, r any tautology To and any contradiction Fo
0 0 0 0 0 0 0 0
0 0 1 0 0 0 1 0
0 1 0 0 0 1 0 0
0 1 1 1 1 1 1 1
1 0 0 0 1 1 1 1
1 0 1 0 1 1 1 1
1 1 0 0 1 1 1 1
1 1 1 0 1 1 1 1
From columns 5 and 8 of the above table, we find that {p ˅ (q ˄ r)} and {(p ˅ q) ˄ (p ˅ r)}
has same truth values in all possible situations. Therefore, p ˅ (q ˄ r)⇔(p ˅ q) ˄ (p ˅ r).
Similarly, we can prove p ˄ (q ˅ r)⇔(p ˄ q) ˅ (p ˄ r).
0 0 1 1 0 1 1
0 1 1 0 1 0 0
1 0 0 1 1 0 0
1 1 0 0 1 0 0
From columns 5 and 8 of the above table, we find that ¬ (p ˅ q) and ¬ p ˅ ¬ q has same truth
values in all possible situations. Therefore, ¬ (p ˅ q) ⇔ ¬ p ˄ ¬ q.
Similarly, we can prove ¬ (p ˄ q) ⇔ ¬ p ˅ ¬ q
Law for the negation of a conditional:
Given a conditional p → q, its negation is obtained by using the following law.
¬ (p → q)⇔[p ˄ (¬ q)]
Proof:
The following table gives the truth values of ¬ (p → q) and p ˄ (¬ q) for all possible truth
values of p and q.
p q p→q ¬ (p → q) ¬q p ˄ (¬ q)
0 0 1 0 1 0
0 1 1 0 0 0
1 0 0 1 1 1
1 1 1 0 0 0
We note that ¬ (p → q) and p ˄ (¬ q) have same truth values in all possible situations. Hence,
¬ (p → q)⇔[p ˄ (¬ q)].
Problems:
1. Simplify the following compounds propositions using the laws of logic.
(ⅰ) p ˅ q ˄ [ ¬ {(¬ p) ˄ q}] (ⅱ) p ˅ q ˄ [ ¬ {(¬ p) ˅ q}]
(ⅲ) ¬ [ ¬ {(p ˅ q) ˄ r} ˅ (¬ q)]
Solution:
(i) p ˅ q ˄ [ ¬ {(¬ p) ˄ q}]
= p ˅ q ˄ {(¬ ¬ p) ˅ (¬ q)} By De Morgan’s law
= p ˅ q ˄ {p ˅ (¬ q)} By Law of double negation
= p ˅ {q ˄ (¬ q)} By Distributive law
= p ˅ Fo By Inverse law
=p By Identity law
(ⅰ) [p ˅ q ˅ (¬ p ˄ ¬ q ˄ r)]⇔ p ˅ q ˅ r
Because (u → v) ⇔ (¬ u ⅴ v)
⇔ (¬ p ⅴ ¬ q) ⅴ r Associative law
⇔ (p ˄ q) ⅴ r De-Morgan’s law
⇔ (p ˄ q) →r Because (u → v) ⇔ (¬ u ⅴ v)
Duality:
Let s be a statement. If s contains no logical connectives other than ˄ and ⅴ, the dual of s
denoted by sd, is the statement obtained from s by replacing each occurrence of ˄ and ⅴ by ⅴ
and ˄ respectively, and each occurrence of To and Fo by Fo and To, respectively.
Example: Given the primitive statements p, q, r and the compound statements
s: (p ˄ (¬ q)) ⅴ (r ˄ To)
Principle of Duality:
Let s and t be two statements that contains no logical connections than ˄ and ⅴ. If s⇔t, then
sd⇔td.
Problems:
1. Write duals of the following propositions.
(i). p → q (ii). (p → q) → r (iii). p → (q → r)
⇔ [ (p ˄ ¬ q) ⅴ r]d
⇔ (p ⅴ ¬ q) ˄ r
⇔ ¬ p ˄ (¬ q ˄ r)
2. Write duals of the following propositions.
(i). q → p (ii). (p ⅴ q) ˄ r (iii). (p ˄ q) ⅴT0
(iv). p → (q ˄ r) (v). p ↔ q (vi). p ⊻ q
⇔ (¬ p ˄ q) ⅴ (¬ q ˄ p)
The compound proposition ¬ (p ⅴ q) is read as “Not p or q” and also denoted by (p ↓ q). The
symbol ↓ is called the NOR connective.
Truth table
p q p↑q p↓q
0 0 1 1
0 1 1 0
1 0 1 0
1 1 0 0
Where p ↑ q = ¬ (p ˄ q) ⇔ ¬ p ⅴ ¬ q and p ↓ q = ¬ (p ⅴ q) ⇔¬ p ˄ ¬ q
Problems:
1. For any propositions p, q Prove the following
(i). ¬ (p ↓ q) ⇔ ¬ p ↑ ¬ q (ii). ¬ (p ↑ q) ⇔ ¬ p ↓ ¬ q
Solution: Using definition, we find that
i. ¬ (p ↓ q) ⇔ ¬ [ ¬ (pⅴq)]
⇔ ¬ [ ¬ p ˄ ¬ q]
⇔¬ p ↑ ¬ q
ii. ¬ (p ↑ q) ⇔ ¬ [ ¬ (p ˄ q)]
⇔ ¬ [ ¬ p ⅴ ¬ q]
⇔ ¬p↓¬q
2. For any propositions p, q, r Prove the following
(i). p ↑ (q ↑ r) ⇔ ¬ pⅴ (q ˄ r) (ii). (p ↑ q) ↑ r ⇔ (p ˄ q) ⅴ¬ r
(iii). p ↓ (q ↓ r) ⇔ ¬ p ˄ (q ⅴr) (iv). (p ↓ q) ↓ r ⇔ (p ⅴ q) ˄ ¬ r
Solution: Using definition, we find that
(i). p ↑ (q ↑ r) ⇔ ¬ [p ˄ (q ↑ r))]
⇔ ¬ [p ˄ ¬ (q ˄ r)]
⇔ ¬ p ⅴ ¬ [ ¬ (q ˄ r)]
⇔ ¬ pⅴ (q ˄ r)
(ii). (p ↑ q) ↑ r ⇔ ¬ [(p ↑ q) ˄ r]
⇔ ¬ [¬ (p ˄ q) ˄ r]
⇔ ¬ [¬ (p ˄ q)] ⅴ ¬ r
⇔ (p ˄ q) ⅴ¬ r
(iii). p ↓ (q ↓ r) ⇔ ¬ [p ⅴ (q ↓ r))]
⇔ ¬ [p ⅴ ¬ (q ⅴ r)]
⇔ ¬ p ˄ ¬ [ ¬ (q ⅴ r)]
⇔ ¬ p ˄ (q ⅴr)
(iv). (p ↓ q) ↓ r ⇔ ¬ [(p ↓ q) ⅴ r]
⇔ ¬ [¬ (p ⅴ q) ⅴ r]
⇔ ¬ [¬ (p ⅴ q)] ˄ ¬ r
⇔ (p ⅴ q) ˄ ¬ r
Converse, Inverse and Contrapositive:
Consider a conditional p → q then:
1. q → p is called the converse of p → q.
2. ¬ p →¬ q is called the inverse of p → q.
3. ¬ q →¬ p is called the contrapositive of p → q.
Truth table for converse, inverse and contrapositive
p q ¬p ¬q p→q q→p ¬ p→¬ q ¬ q →¬ p
0 0 1 1 1 1 1 1
0 1 1 0 1 0 0 1
1 0 0 1 0 1 1 0
1 1 0 0 1 1 1 1
Problems:
1. State the converse inverse and contrapositive of
i) If the triangle is not isosceles, then it is not equilateral
ii) If the real number x2 is greater than zero, then x is not equal to zero.
iii) If a quadrilateral is a parallelogram, then its diagonals bisect each other.
Solution:
(i) p: Triangle is not isosceles and q: Triangle is not equilateral.
Implication: p → q. if triangle is not isosceles then it is not equilateral.
Converse: q → p. if a triangle is not equilateral then it is not isosceles.
Inverse: ¬ p →¬ q. if a triangle is isosceles then it is equilateral.
Contrapositive: ¬ q→¬ p: if a triangle is equilateral then it is isosceles.
(ii) p: A real number x2 is greater than zero and q: x is not equal to zero.
Implication: p → q. if a real number x2 is greater than zero then, x is not equal to zero.
Converse: q → p. if a real number x is not equal to zero then, x2 is greater zero.
Inverse: ¬ p→¬ q. if a real number x2 is not greater than zero then, x is equal to zero.
Contrapositive: If a real number x is equal to zero then, x2 is not greater than zero
(ⅰii) p: If Quadrilateral is a parallelogram and q: its Diagonals Bisects each other.
Implication: p → q. If Quadrilateral is a parallelogram, then its diagonals bisects each
other.
Converse: q → p. If the diagonals of the Quadrilateral bisect each other, then it is a
parallelogram.
Inverse: ¬ p →¬ q. If Quadrilateral is not a parallelogram, then its diagonals do not bisect
each other.
Contrapositive: ¬ q→¬ p: If the diagonals of the Quadrilateral do not bisect each other,
then it is a not a parallelogram.
2. Write down the following statements in the ‘Necessary and Sufficient Condition’
Language.
i) If the triangle is not isosceles, then it is not equilateral
ii) If the real number x2 is greater than zero, then x is not equal to zero.
iii) If a quadrilateral is a parallelogram, then its diagonals bisect each other.
Solution:
Necessary Condition Language:
(i). For a triangle to be non-isosceles it is necessary that is not equilateral.
(ii). A necessary condition for a real number x2 to be greater than zero is that x is not equal to
zero.
(iii). A necessary condition for a quadrilateral to be a parallelogram is that its diagonals bisect
each other.
Necessary Condition Language:
(i). A sufficient condition for a triangle to be not equilateral is that it is not isosceles.
(ii). For a real number x, the condition x2 to be greater than zero is sufficient for x to be not
equal to zero.
(iii). A sufficient condition for the diagonals of a quadrilateral to bisect each other is that the
quadrilateral is a parallelogram.
☻Rules of inference:
Let us consider the implication (p1 ˄ p2 ˄ …. ˄ pn) → q
Here n is a positive integer, the statements p1, p2, …. pn are called the premises of the argument
and q is called the conclusion of the argument.
We write the above argument in the following tabular form:
𝑝1
𝑝2
𝑝3
⋮
⋮
𝑝𝑛
∴q
The preceding argument is said to be valid if whenever each of the premises p1, p2, …. pn is
true, then the conclusion q is likewise true.
i.e., (p1 ˄ p2 ˄ …. ˄ pn) → q is valid when (p1 ˄ p2 ˄ …. ˄ pn) ⇒ q
It is to be emphasized that in an argument, the premises are always taken to be true whereas
the conclusion may be true or false. The conclusion is true only in the case of valid argument.
There exist rules of logic which can be employed for establishing the validity of arguments.
These rules are called Rules of Inference.
(because (p →¬ q) ⇔ (¬ ¬ q → ¬ p))
(because (¬ r → p) ⇔ (¬ p → r))
∴ r ¬q→¬r ∴ (p ⅴ q) → r
∴ ¬r
Solution:
(i). Since p ˄ q is true, both p and q are true. Since p is true and p → (q → r) is true, q → r
Should be true. Since q is true and q → r is true, r should be true. Hence the given argument is
valid.
(ii). The premises p → ¬ q and ¬ q → ¬ r together yields the premise p → ¬ r. since p is true,
this premise p → ¬ r establishes that ¬ r is true. Hence the given argument is valid.
(iii) We note that
(p → r) ˄ (q → r) ⇔ (¬ p ⅴ r) ˄ (¬ q ⅴ r)
⇔ (r ⅴ¬ p) ˄ (r ⅴ¬ q) By Commutative law
⇔ r ⅴ (¬ p ˄ ¬ q) By Distributive law
⇔ (p ⅴ q) → r
This Logical equivalence shows that the given argument is valid.
9. Test whether the following arguments are valid:
pⅴr ¬qⅴ¬s
∴ qⅴs ∴ ¬ (p ˄ r)
Solution:
(i) We note that
(p → q) ˄ (r → s) ˄ (p ⅴ r) ⇔ (p → q) ˄ (r → s) ˄ (¬ p → r)
⇔ (p → q) ˄ (¬ p → r) ˄ (r → s) By Commutative law
⇔ (p → q) ˄ (¬ p → s) Using Rule of Syllogism
⇔ (¬ q → ¬ p) ˄ (¬ p → s) Using Contrapositive
⇔ (¬ q → s) Using Rule of Syllogism
⇔qⅴs
This Logical equivalence shows that the given argument is valid.
(ii) We note that
(p → q) ˄ (r → s) ˄ (¬ q ⅴ ¬ s) ⇔ (p → q) ˄ (r → s) ˄ (q → ¬ s)
⇔ (p → q) ˄ (q → ¬ s) ˄ (r → s) By Commutative law
⇔ (p → ¬ s) ˄ (r → s) Using Rule of Syllogism
⇔ (p → ¬ s) ˄ (¬ s → ¬ r) Using Contrapositive
⇔ (p → ¬ r) Using Rule of Syllogism
⇔ ¬ p ⅴ¬ r)
⇔ ¬ (p ˄ r)
This Logical equivalence shows that the given argument is valid.
10. Show that the following argument is not valid:
p
pⅴq
q → (r → s)
t→r
∴¬s→¬t
Solution:
Here p is true (premise) and (p ⅴ q) is true (premise). Therefore, q may be true or false.
Suppose q is false. Then, since q → (r → s) is true (premise), r → s must be false. This
means that r must be true, and s must be false. Since r is true and t → r is true (premise), t may
be true or false. Suppose t is true, then ¬ t is false. Since s must be false, ¬ s must be true.
Consequently, ¬ s → ¬ t is false.
Thus, when q is false and t is true, the given conclusion does not follow from the given
premise. As such, the given argument is not valid argument.
☻Open statement:
A declaration statement is an open statement
i. If it contains one or more variables.
ii. If it is not statement.
iii. But it becomes statement when the variables in it are replaced by certain allowable
choices.
Example: “The number x+2 is an even integer” is denoted by P(x) then ¬ P(x) may be read as
“The number x+2 is not an even integer”.
Quantifiers:
The words “all”, “every”, “some”, “there exist” are associated with the idea of a quantity such
words are called quantifiers.
1. Universal quantifiers:
The symbol Ɐ has been used to denote the phrases “for all” and “for every” in logic “for
each” and “for any” are also taken up to equivalent to these. These equivalent phrases are
called universal quantifiers.
2. Existential quantifiers:
The symbol ∃ has been used to denote the phrases “there exist”, “for some” and “for at
least one” each of these equivalent phrases is called the existential quantifiers.
≡ ∃ x, [ ¬ p(x) ⅴ q(x)]
≡ ∃ x, [p(x) ˄ ¬ q(x)}]
We note that
Ɐ x, [p(x) → q(x)] ˄ {Ɐ x, [q(x) → r(x)]} ˄ ¬ r(c)
⇒ {Ɐ x, [p(x) → r(x)] ˄ ¬ r(c)}, By Rule of Syllogism
⇒ {[p(c) → r(c)] ˄ ¬ r(c)}, By Rule of Universal Specification
⇒ ¬ p(c) By Modus Tollens Rule
This proves that the given argument is valid.
8. Prove that the following argument is valid.
Ɐ x, [p(x) ⅴ q(x)]
∃ x, ¬ p(x)
Ɐ x, [¬ q(x) ⅴ r(x)]
Ɐ x, [s(x) → ¬ r(x)]
∴ ∃ x, ¬ s(x)
Solution:
We note that
Direct proof:
Module 2
Properties of Integers & Principles of Counting
Content
Fundamental Principles of Counting: The Rules of Sum and Product, Permutations, Combinations – The
Binomial Theorem, Combinations with Repetition.
☻Mathematical Induction:
Every non empty subset of 𝑍 +contains a smallest element. (we often express this by saying that 𝑍+ is well
ordered).
Let 𝑆(𝑛) denote an open mathematical statement that involves one or more occurrences of the variable n.
Which represents a positive integer
(b) If whenever 𝑆(𝑘)is true (for some particular but arbitrarily chosen 𝑘 ∈ 𝑍+), then 𝑆 (𝑘 + 1)is true,
then 𝑆(𝑛) is true for all 𝑛 ∈ 𝑍+.
Proof:
Let 𝑆(𝑛) be such an open statement satisfying conditions (a) and (b) and let 𝐹 = {𝑡 ∈ 𝑍 +/ 𝑆(𝑡) is false}. We
wish to prove that 𝐹 = ∅ so to obtain a contradiction we assume that 𝐹 ≠ ∅. Then by the well-ordering
Principle, F has a least element. Since 𝑆(1) is true. It follows that 𝑆 ≠ 1. so 𝑠 > 10, and consequently 𝑠 −
1 ∈ 𝑍+. With 𝑠 − 1 ∉ 𝐹, 𝑆(𝑠 − 1) we have true. So, by condition (b) it follows that 𝑆((𝑠 − 1) + 1) = 𝑆(𝑠)
is true, contradicting 𝑠 ∈ 𝐹. This contradiction arose from the assumption that 𝐹 ≠ ∅. Consequently 𝐹 = ∅.
Problems:
Solution:
Induction step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
𝑛(𝑛+1)(2𝑛+1)
2. Prove that, for each 𝑛 ∈ 𝑍+ ∑𝑛𝑖=1 𝑖2 =
6
OR
𝑛(𝑛+1)(2𝑛+1)
Prove that, for each 𝑛 ∈ 𝑍+, 12 + 22 + 32 + ⋯ ⋯ ⋯ + 𝑛2 =
6
Solution:
Induction Step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
assume that the following statement is true.
𝑘(𝑘+1)(2𝑘+1)
𝑆(𝑘) = 12 + 22 + 32 + ⋯ ⋯ ⋯ + 𝑘2 = .
6
𝑘 (2𝑘+1)
= (𝑘 + 1) { + (𝑘 + 1)}
6
1
= (𝑘 + 1){𝑘(2𝑘 + 1) + 6(𝑘 + 1)}
6
1
= (𝑘 + 1){2𝑘2 + 𝑘 + 6𝑘 + 6}
6
1
= (𝑘 + 1){2𝑘2 + 7𝑘 + 6}
6
1
= (𝑘 + 1)(𝑘 + 2)(2𝑘 + 3)
6
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
Solution:
Basic step: For 𝑛 = 1, 𝑆(𝑛) reads (1!) ≥ 21−1 which is obviously true. Thus 𝑆(𝑛) is verified for 𝑛 = 1.
Induction step: We assume that 𝑆(𝑛) is true for 𝑛 = 𝑘, where 𝑘 is an integer ≥ 1; that is, we assume that
2𝑘 = 2 ∙ 2𝑘−1 ≤ 2 ∙ 𝑘!
= (𝑘 + 1)!
(𝑘 + 1)! ≥ 2𝑘
This is precisely the statement 𝑆(𝑛) for 𝑛 = 𝑘 + 1. Thus, on the assumption that 𝑆(𝑛)is true for 𝑛 = 𝑘 ≥ 1,
We have proved that 𝑆(𝑛) is true for 𝑛 = 𝑘 + 1.
Hence, by mathematical induction, it follows that the statement 𝑆(𝑛) is true for all integers 𝑛 ≥ 1.
4. Prove that every positive integer 𝑛 ≥ 24 can be written as a sum of 5’s and/or 7’s.
Solution:
Induction step: We assume that 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 ≥ 24. Then
𝑘 = (7 + 7 + ⋯ ⋯ ) + (5 + 5 + ⋯ ⋯ )
Suppose this representation of 𝑘 has 𝑟 number of 7’s and 𝑠 number of 5’s. Since 𝑘 ≥ 24 we should have
𝑟 ≥ 2 and 𝑠 ≥ 2.
= {⏟ ¸) + (7 + 7) + (⏟5_+ 5_
(7_+ 7_+ ⋯_⋯ +_⋯ ⋯¸)} + 1
𝑟−2 𝑠
= {⏟
(7 + 7_ ( 5 + 5_
+_⋯ ⋯¸) + ⏟ +_⋯ ⋯¸)}
𝑟−2 𝑠+3
This shows that 𝑘 + 1is sum of 7’s and 5’s. Thus, 𝑆(𝑘 + 1) is true.
Solution:
Induction step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
1
= (𝑘 + 1)(𝑘 + 2) { 𝑘 + 1}
3
1
= (𝑘 + 1)(𝑘 + 2)(𝑘 + 3)
3
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
𝑛(2𝑛−1)(2𝑛+1)
6. Prove, by mathematical induction that 12 + 32 + 52 + ⋯ ⋯ ⋯ + (2𝑛 − 1)2 = for all
3
integers 𝑛 ≥ 1.
Solution:
Induction Step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
assume that the following statement is true.
𝑘(2𝑘−1)(2𝑘+1)
𝑆(𝑘) = 12 + 32 + 52 + ⋯ ⋯ ⋯ + (2𝑘 − 1)2 = .
3
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
Solution:
Induction step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
= (𝑘 + 1){2𝑘2 + 7𝑘 + 6𝑘 + 18}
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
8. Prove that every positive integer greater than or equal to 14 can be written as a sum of 3’s and/or 8’s.
Solution:
Induction step: We assume that 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 ≥ 14. Then
𝑘 = (3 + 3 + ⋯ ⋯ ) + (8 + ⋯ ⋯ )
Suppose this representation of 𝑘 has 𝑟 number of 3’s and 𝑠 number of 8’s. Since 𝑘 ≥ 14 we should have
𝑟 ≥ 2 and 𝑠 ≥ 2.
𝑘 + 1 = {⏟
(3 + 3_ (8_+ ⋯ ⋯¸)} + 1
+_⋯ ⋯¸) + ⏟
𝑟 𝑠
This shows that 𝑘 + 1is sum of 3’s and 8’s. Thus, 𝑆(𝑘 + 1) is true.
Induction step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
1 1 1 1 𝑘 1
𝑆(𝑘) = + + ⋯⋯ ⋯+ + = 6𝑘+4 +
2∙5 5∙8 (3𝑘−1)(3𝑘+2) (3𝑘+2)(3𝑘+5) (3𝑘+2)(3𝑘+5)
𝑘(3𝑘+2)(3𝑘+5)+(6𝑘+4)
= (6𝑘+4)(3𝑘+2)(3𝑘+5)
9𝑘3+21𝑘2+16𝑘+4
= (6𝑘+4)(3𝑘+2)(3𝑘+5)
(𝑘−1)(3𝑘+2)2
= (6𝑘+4)(3𝑘+2)(3𝑘+5)
(𝑘+1)(3𝑘+2)
=
(6𝑘+4)(3𝑘+5)
This is precisely the statement 𝑆(𝑘 + 1). Thus, on the basis of the assumption that 𝑆(𝑛) is true for 𝑛 = 𝑘 ≥
1, the truth ness of 𝑆(𝑛) for 𝑛 = 𝑘 + 1 is established.
10. Prove by mathematical induction that, for every positive integer 𝑛, 5 divides 𝑛5 − 𝑛
Solution:
5 divides 15 − 1
Induction step: We assume that the statement 𝑆(𝑛) is true for 𝑛 = 𝑘 where 𝑘 is an integer ≥ 1; that is, we
This means that 𝑘5 − 𝑘 is a multiple of 5; that is 𝑘5 − 𝑘 = 5𝑚, for some positive integer m.
This shows that (𝑘 + 1)5 − (𝑘 + 1) is a multiple of 5; that is, 5 divides (𝑘 + 1)5 − (𝑘 + 1).
This is precisely the statement 𝑆(𝑛) for 𝑛 = 𝑘 + 1. Thus, on the assumption that 𝑆(𝑛)is true for 𝑛 = 𝑘 ≥ 1,
We have proved that 𝑆(𝑛) is true for 𝑛 = 𝑘 + 1.
☻Recursive Definition:
In recursive method, first few terms of the sequence must be indicated explicitly and in the second part the
rule which will enable us to obtain new term if the sequence from the terms already known must be indicated.
Problems:
𝑎1 = 7, 𝑎𝑛 = 2𝑎𝑛−1 + 1 for 𝑛 ≥ 2.
𝑎𝑛 = 2𝑎𝑛−1 + 1 = 2{2𝑎𝑛−2 + 1} + 1
= 2{2(2𝑎𝑛−3 + 1) + 1} + 1 = 23𝑎𝑛−3 + 22 + 2 + 1
⋯⋯⋯
⋯⋯⋯
2𝑛−1 −1
This becomes 𝑎𝑛 = 7 ∙ 2𝑛−1 + = 8 ∙ 2𝑛−1 − 1
2−1
2. Obtain the recursive definition for the sequence {𝑎𝑛} is each of the following cases.
Solution:
We observe that 𝑎2 − 𝑎1 = 5 = 2 ∙ 1 + 3, 𝑎3 − 𝑎2 = 7 = 2 ∙ 2 + 3, 𝑎4 − 𝑎3 = 9 = 2 ∙ 3 + 3
We observe that 𝑎2 − 𝑎1 = 3 = 2 ∙ 1 + 1, 𝑎3 − 𝑎2 = 5 = 2 ∙ 2 + 1, 𝑎4 − 𝑎3 = 7 = 2 ∙ 3 + 1
(vi). Here 𝑎1 = 3, 𝑎2 = 1, 𝑎3 = 3, 𝑎4 = 1, … … …
3. The Fibonacci numbers are defined recursively by 𝐹0 = 0, 𝐹1 = 1 and 𝐹𝑛 = 𝐹𝑛−1 + 𝐹𝑛−2 for 𝑛 ≥ 2
Evaluate 𝐹2 to 𝐹10
Solution:
𝐹2 = 𝐹1 + 𝐹0 = 1 + 0 = 1
𝐹3 = 𝐹2 + 𝐹1 = 1 + 1 = 2
𝐹4 = 𝐹3 + 𝐹2 = 2 + 1 = 3
𝐹5 = 𝐹4 + 𝐹3 = 3 + 2 = 5
𝐹6 = 𝐹5 + 𝐹4 = 5 + 3 = 8
𝐹7 = 𝐹6 + 𝐹5 = 8 + 5 = 13
𝐹8 = 𝐹7 + 𝐹6 = 13 + 8 = 21
𝐹9 = 𝐹8 + 𝐹7 = 21 + 13 = 34
𝐹10 = 𝐹9 + 𝐹8 = 34 + 21 = 55
Note: The Sequence formed by the Fibonacci numbers is called the Fibonacci sequence.
4. The Lucas numbers are defined recursively by 𝐿0 = 2, 𝐿1 = 1 and 𝐿𝑛 = 𝐿𝑛−1 + 𝐿𝑛−2 for 𝑛 ≥ 2
Evaluate 𝐿2 to 𝐿10
Solution:
𝐿2 = 𝐿1 + 𝐿0 = 1 + 2 = 3
𝐿3 = 𝐿2 + 𝐿1 = 3 + 1 = 4
𝐿4 = 𝐿3 + 𝐿2 = 4 + 3 = 7
𝐿5 = 𝐿4 + 𝐿3 = 7 + 4 = 11
𝐿6 = 𝐿5 + 𝐿4 = 11 + 7 = 18
𝐿7 = 𝐿6 + 𝐿5 = 18 + 11 = 29
𝐿8 = 𝐿7 + 𝐿6 = 29 + 18 = 47
𝐿9 = 𝐿8 + 𝐿7 = 47 + 29 = 76
𝐿10 = 𝐿9 + 𝐿8 = 76 + 47 = 123
Note: The Sequence formed by the Lucas numbers is called the Lucas sequence.
1 𝑛 𝑛
1−√5
5. For the Fibonacci sequence 𝐹0, 𝐹1, 𝐹2, … … … …. Prove that 𝐹𝑛 = [( 1+√5) − ( )]
√5 2 2
Solution:
Thus, the required result is true for 𝑛 = 0 and 𝑛 = 1. We assume that the result is true for 𝑛 = 0, 1, 2, … . 𝑘,
where 𝑘 ≥ 1. Then, we find that
𝐹𝑘+1 = 𝐹𝑘 + 𝐹𝑘−1
𝑘
1+√5 1−√5 𝑘 1 𝑘−1 𝑘−1
𝐹𝑘+1 = 1 [( ) −( ) ]+ [(1+√5 ) −(
1−√5 ) ] using the assumption made
√5 2 2 √5 2 2
1 𝑘+1 𝑘+1
𝐹𝑘+1 = [( 1+√5) −(
1−√5
) ]
√5 2 2
This shows that the required result is true for 𝑛 = 𝑘 + 1. Hence by mathematical induction, the result is true
for all non – negative integers n.
☻The Rules of Sum and Product:
Rule of sum:
Suppose two tasks 𝑇1 and 𝑇2 are to be performed. if the task 𝑇1 can be performed in m different ways and the
task 𝑇2 can be performed in n different ways and if these two tasks cannot be performed simultaneously, then
one of the two tasks (𝑇1 or 𝑇2) can be performed in 𝑚 + 𝑛 ways.
Example: Suppose 𝑇 1 is the task of selecting a prime no. < 10 and 𝑇 2 is the task of selecting an even number
< 10. then 𝑇1 can be performed in 4 ways and 𝑇2 can be performed in 4 ways. But since 2 is both a prime and
an even number < 10 the task T1 or 𝑇2 can be performed in 4 + 4 – 1 = 7 ways.
Rule of product:
Suppose two tasks are to be performed one after the other. If 𝑇1 can be performed in 𝑛1 different ways, and
for each of these ways 𝑇2 can be performed in 𝑛2different ways. then both of the tasks can be performed in
𝑛1 ∗ 𝑛2 different ways.
Example: Suppose a person has 8 shirts and 5 ties. Then He has 8 * 4 = 40 different ways of choosing a shirt
and a tie.
Problems:
1. Cars of a particular manufacturer come in 4 models, 12 colours, 3 engine sizes and 2 transmission
types (a) how many distinct cars can be manufactured? (b) of these how many have the same colour?
Solution:
(a) By the product rule, it follows that the number of distinct cars that can be manufactured is 4*12*3*2 =288
(b) for any chosen colour, the number of distinct cars that can be manufactured is 4*3*2=24
2. A bit is either 0 or 1. A byte is a sequence of 8 bits. Find (i) the number of bytes. (ii) the number of
bytes that begin with 11 and end with 11. (iii) The number of bytes that begin with 11 and do not end
with 11. (iv) the number of bytes that begin with 11 or end with 11.
Solution:
(i) Since each byte contains 8 bits and each bit is 0 or 1, the number of bytes is 28 = 256
(ii) In a byte beginning and ending with 11, there occur 4 open positions. These can be filled un 24 = 16 ways.
Therefore, there are 16 bytes which begin and end with 11.
(iii) These occur 6 open positions in a byte beginning with 11. these positions can be filled is 2 6 = 64 ways.
thus, there are 64 bytes that begin with 11. since there are 16 bytes that begin and end with 11, the number
of bytes that begin with 11 but do not end with 11 is 64-16 = 48.
(iv) As in (iii) the numbers of bytes that end with 11 is 64. Also, the number of bytes that begin and end with
11 is 16. Therefore, the number of bytes that begin or end with 11 is 64 + 64 = 16 = 112.
Here we consider number of the form 𝑥 𝑦 𝑧, where each of 𝑥, 𝑦, 𝑧 represents a digit under the given
restrictions. Since 𝑥 𝑦 𝑧 has to be even, z has to be 0, 2, 4, 6 or 8. If 𝑧 is 0, then 𝑥 has 9 choices and 𝑦 𝑧 has
2, 4, 6, 8 (4 choices) then 𝑥 has 8 choices (Note that 𝑥 cannot be 0). Therefore, 𝑧 and 𝑥 can be chosen in
1 × 9 + 4 × 8 = 41 ways. For each of these ways, 𝑦 can be chosen in 8 ways.
Solution:
We note that 441000 = 23 × 32 × 53 × 72. Therefore, every divisor of 𝑛 = 441000 must be of the form
𝑑 = 2𝑝 × 3𝑞 × 5𝑟 × 7𝑠 where 0 ≤ 𝑝 ≤ 3, 0 ≤ 𝑞 ≤ 2, 0 ≤ 𝑟 ≤ 3, 0 ≤ 𝑠 ≤ 2.
Thus, for a divisor d, p can be chosen in 4 ways, q in 3 ways, r in 4 ways and s in 3 ways. Accordingly, the
number of possible d’s is 4 × 3 × 4 × 3 = 144. Of these, two divisors (namely 1 and 𝑛) are not proper
divisors. Therefore, the number of proper divisors of the given number is 144 − 2 = 142.
5. How many among the first 100,000 positive integers contain exactly one 3, one 4 and one 5 in their
decimal representations?
Solution:
The number 100000 does not contain 3 or 4 or 5. Therefore, we have to consider all possible positive integers
with 5 places that meet the given conditions. In a 5-place integer the digit 3 can be in any one of the 5 places.
Subsequently, the digit 4 can be in any one of the 4 remaining places. Then the digit 5 can be in any one of
the 3 remaining places. There are 2 places left and either of these may be filled by 5 digits (digits from 0 to
9 other tan 3, 4, 5). Thus, there are 5 × 4 × 3 × 7 × 7 = 2940 integers of the required type.
☻Permutations:
Suppose that we are given 𝑛 distinct objects and wish to arrange r of these objects in a line. Since there are
𝑛 ways of choosing the first object, and after this done 𝑛 − 1 ways of choosing the second object…. And
finally, 𝑛 − 𝑟 + 1 ways of choosing 𝑟𝑡ℎ object, it follows by the product rule of counting (stated in the
preceding section) that the number of different arrangements, or permutations (as they are commonly called)
is 𝑛(𝑛 − 1)(𝑛 − 2) ⋯ ⋯ ⋯ (𝑛 − 𝑟 + 1). We denote this number by 𝑃(𝑛, 𝑟) and is referred to as the number
of permutations of size 𝑟 of 𝑛 objects.
𝒏!
𝑷(𝒏, 𝒓) =
(𝒏 − 𝒓)!
Generalization
Suppose it is required to find the number of permutations that can be formed from a collection of 𝑛 objects
of which 𝑛1 are of one type , 𝑛 2 are of a second type ,……… 𝑛𝑘 are of 𝑘𝑡ℎ type, with 𝑛1 + 𝑛2 + ⋯ ⋯ +
𝑛𝑘 = 𝑛. Then, the number of permutations of the objects is
𝒏!
𝒏𝟏! 𝒏𝟐! ⋯ ⋯ 𝒏𝒌!
Problems:
1. Four different mathematics books, five different computer science books and two different control
theory books are to be arranged in a shelf. How many different arrangements are possible if (a) The
books in each particular subject must be together? (b) Only mathematics books must be together?
Solution:
(a) The mathematics books can be arranged among themselves in 4! Ways, the computer science books in
5! Ways the control theory books in 2! Ways, and the three groups in 3! Ways. Therefore, the number of
possible arrangements is 4! * 5! * 2! * 3! = 34560.
(b) Consider the 4 mathematics boos as one single book. Then we have 8 books which can be arranged in 8!
Ways. In all of these ways the mathematics books are together. But the mathematics books can be arranged
among themselves in 4! Ways. Hence, the number of arrangements is 8! * 4! = 967680
2. Find the number of permutations of the letters of the word MASSASAUGA. In how many of these,
all four ‘A’s are together? How many of them begin with S?
Solution:
The given word has 10 letters of which 4 are A, 3 are S and 1 each are M, U and G. Therefore, the required
number of permutations is
10!
= 25200
4! ∗ 3! ∗ 1! ∗ 1! ∗ 1!
It is a permutation all A’s are to be together, we treat all of A’s as one single letter. Then the letters to be
permuted read (AAAA), S, S, S, M, U, G (which are 7 in number) and the number of permutations is
7!
= 840
1! ∗ 3! ∗ 1! ∗ 1! ∗ 1!
For permutations beginning with S, there occur nine open positions to fill, where two are S, four are A, and
one each of M, U, G. The number of such permutations is
9!
= 7560
2! ∗ 4! ∗ 1! ∗ 1! ∗ 1!
3. (a) How many arrangements are there for all letters in the word SOCIOLOGICAL?
(b) In how many of these arrangements (i) A and G are adjacent? (ii) all the vowels are adjacent?
Solution:
(a) The given word has 12 letters of which three are O, two each are C, I, L and one each are S, A, G.
Therefore, the number of arrangements of these letters is
12!
= 25200
3! ∗ 2! ∗ 2! ∗ 2! ∗ 1! ∗ 1! ∗ 1!
(b)
(i) If, in an arrangement, A and G are to be adjacent, we treat A and G together as a single letter, say X so
that we have three numbers of O’s, two each of C, L, I and one each of S and X, totalling 11 letters. These
can be arranged in 11!
Ways
3!∗2!∗2!∗2!∗1!
Further the letters A and G can be arranged among themselves in two ways.
Further, since the given words contains 3 O’s, two I’s and one A, the letters A, O, I (clubbed as Y) can be
arranged among themselves is 6! Ways.
3!∗2!∗1!
7! 6!
Therefore, the total number of arrangements in this case is × = 75600
2!∗2!∗1!∗1!∗1! 3!∗2!∗1!
4. How many Positive integers n can we form using the digits 3, 4, 4, 5, 5, 6, 7 if we want n to exceed
5,000,000?
Solution:
Here n must be of the form 𝑛 = 𝑥1𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7
Where 𝑥1, 𝑥2, … … , 𝑥7 are the given digits with 𝑥1 = 5, 6 𝑜𝑟 7. Suppose we take 𝑥1 = 5. Then where
𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which contains two 4’s and one each of 3, 5, 6, 7.
The number of such arrangements is
6!
= 360
1! 2! 1! 1! 1!
Similarly, we take 𝑥1 = 6. Then where 𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which
contains two each of 4 & 5 and one each of 3 & 7. The number of such arrangements is
6!
= 180
1! 2! 2! 1!
Similarly, we take 𝑥1 = 7. Then where 𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which
contains two each of 4 & 5 and one each of 3 & 6. The number of such arrangements is
6!
= 180
1! 2! 2! 1!
Accordingly, by the Sum Rule, the number of 𝑛’s of the desired type is 360 + 180 + 180 = 720.
5. How many numbers greater than 1,000,000 can be formed by using the digits 1, 2, 2, 2, 4, 4, 0?
Solution:
Where 𝑥1, 𝑥2, … … , 𝑥7 are the given digits with 𝑥1 = 1, 2 𝑜𝑟 4. Suppose we take 𝑥1 = 1. Then where
𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which contains three 2’s and two 4’s. The number
of such arrangements is
6!
= 60
3! 2!
Similarly, we take 𝑥1 = 2. Then where 𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which
contains two 2’s and two 4’s. The number of such arrangements is
6!
= 180
2! 2!
Similarly, we take 𝑥1 = 4. Then where 𝑥2𝑥3𝑥4𝑥5𝑥6𝑥7 is an arrangement of the remaining 6 digits which
contains three 2’s and one 4. The number of such arrangements is
6!
= 120
3! 1!
Accordingly, by the Sum Rule, the number of 𝑛’s of the desired type is 60 + 180 + 120 = 360.
☻Combinations:
Suppose we are interested in selecting (choosing) a set of 𝑟 objects from a set of 𝑛 ≥ 𝑟 objects without regard
to order. The set of 𝑟 objects being selected is traditionally called a Combination of 𝑟 objects (or briefly 𝑟-
combination).
The total number of combinations of 𝑟-different objects that can be selected from 𝑛 different objects can be
obtained by proceeding in the following way. Suppose this number is equal to 𝐶, say; that is, suppose there
is a total of 𝐶 number of combinations of 𝑟 different objects chosen from 𝑛 different objects. Take any one
of these combinations. The 𝑟 objects in this combination can be arranged in 𝑟! Different ways. Since there
are 𝐶 combinations, the total number of permutations is 𝐶 ∙ 𝑟!. But this is equal to 𝑃(𝑛, 𝑟). Thus,
𝑷(𝒏,𝒓) 𝒏!
𝑪(𝒏, 𝒓) = = for 𝟎 ≤ 𝒓 ≤ 𝒏
𝒓! (𝒏−𝒓)! 𝒓!
Problems:
1. A certain question paper contains two parts A and B each containing 4 questions. How many different
ways a student can answer 5 questions by selecting at least 2 questions from each part?
Solution: The different ways a student can select his 5 questions are.
(i) 3 questions from part A and 2 questions from part B. this can be done in 𝐶(4, 3) ∗ 𝐶(4, 2) = 24 ways.
(ii) 2 questions from part A and 3 questions from part B. this can be done in 𝐶(4, 2) ∗ 𝐶(4, 3) = 24 ways.
Therefore, the total number of ways a student can answer 5 questions under given restrictions is 24 + 24 =
48.
Proof:
𝑛! 𝑛!
(i). 𝐶(𝑛, 𝑟 − 1) + 𝐶(𝑛, 𝑟) = +
(𝑟−1)! (𝑛−𝑟+1)! 𝑟! (𝑛−𝑟)!
𝑛! 1 1
= { + }
(𝑟−1)! (𝑛−𝑟)! 𝑛−𝑟+1 𝑟
𝑛! 𝑛+1
= ∙
(𝑟−1)! (𝑛−𝑟)! 𝑟 (𝑛−𝑟+1)
(𝑛+1)!
=
𝑟! (𝑛−𝑟+1)!
= 𝐶(𝑛 + 1, 𝑟)
𝑚! 𝑛!
(ii). 𝐶(𝑚, 2) + 𝐶(𝑛, 2) = +
(𝑚−2)! ∙ 2 (𝑛−2)! ∙2
1
= {𝑚(𝑚 − 1) + 𝑛(𝑛 − 1)}
2
1
= {𝑚2 + 𝑛 2 − 𝑚 − 𝑛}
2
1
= (𝑚 + 𝑛)(𝑚 + 𝑛 − 1) − 𝑚𝑛
2
(𝑚+𝑛)!
= − 𝑚𝑛
2 (𝑚+𝑛−2)!
= 𝐶(𝑚 + 𝑛, 2) − 𝑚𝑛
3. A woman has 11 close relatives and she wishes to invite 5 of them to dinner. In how many ways can
she invite them in the following situations:
(i). There is no restriction on the choice.
(ii). Two particular persons will not attend separately.
(iii). Two particular persons will not attend together.
Solution:
(i). Since there is no restriction on the choice of invitees, five out of 11 can be invited in
11!
𝐶(11, 5) = = 462 ways
6! 5!
(ii). Since two particular persons will not attend separately, they should both be invited or not invited.
Suppose if both of them are invited, then three are more invitees are to be selected from the remaining 9
relatives. This can be done in
9!
𝐶(9, 3) = = 84 ways
6! 3!
Suppose if both of them are not invited, then five invitees are to be selected from the remaining 9 relatives.
This can be done in
9!
𝐶(9, 5) = = 126 ways
5! 4!
Therefore, the total number of ways in which the invitees can be selected in this case is 84 + 126 = 210.
(iii). Since two particular persons (Say 𝑃1 & 𝑃2) will not attend together, only one of them can be invited or
none of them can be invited. The number of ways of choosing the invitees with 𝑃1 invited is
9!
𝐶(9, 4) = = 126 ways
5! 4!
Similarly, the number of ways of choosing the invitees with 𝑃2 invited is 126 ways
If both 𝑃1 & 𝑃2 are not invited, then the number of ways of inviting the invitees is
9!
𝐶(9, 5) = = 126 ways
5! 4!
Therefore, the total number of ways in which the invitees can be selected in this case is
126 + 126 + 126 = 378.
4. Find the number of arrangements of all the letters in TALLAHASSEE. How many of these
arrangements have no adjacent A’s?
Solution:
The number of letters in the given word is 11 of which 3 are A’s, 2 each are L’s, S’s, E’s and 1 each are T
and H. Therefore, the number of arrangements (permutations) of the letters in the given word is
11!
= 831600
3! 2! 2! 2! 1! 1!
In each of these arrangements, there are 9 possible locations for the three A’s. These locations can be chosen
in 𝐶(9, 3) ways. Therefore, the number of arrangements having no adjacent A’s is
9!
5040 × 𝐶(9, 3) = 5040 × = 5040 × 84 = 423360
3! 6!
5. A committee of 12 is to be selected from 10 men and 10 women. In how many ways can the selection
be carried out if
(a) there are no restrictions?
(b) there must be six men and six women?
(c) there must be an even number of women?
(d) there must be more women than men?
(e) there must be at least eight men?
Solution:
20!
𝐶(20, 12) = = 125970
12! 8!
(b). For 6 men out of 10 and 6 women out of 10. These are two different stages of selection that's why product
rule is used
10! 10!
𝐶(10, 6) × 𝐶(10, 6) = × = 44100
6! 4! 6! 4!
(c). 2, 4, 6, 8 or 10 can be the number of women in committee and corresponding to that men will be 10, 8,
6, 4 and 2.
𝐶(10, 2) × 𝐶(10, 10) + 𝐶(10, 4) × 𝐶(10, 8) + 𝐶(10, 6) × 𝐶(10, 6) + 𝐶(10, 8) × 𝐶(10, 4) + 𝐶(10, 10) ×
𝐶(10, 2) = 63090
(e). Number of men can be 8, 9 or 10 in this case and respectively number of women can be 4, 3 and 2.
Binomial Theorem:
𝑛
On the basic properties of 𝐶(𝑛, 𝑟) = ( ) is that it is the coefficient of 𝑥𝑟𝑦𝑛−𝑟 and 𝑥𝑛−𝑟𝑦𝑟 in the expansion
𝑟
of the expression (𝑥 + 𝑦)𝑛, where 𝑥 and 𝑦 are real numbers. In other words,
(𝑥 + 𝑦)𝑛 = ∑𝑛 𝑛 𝑛 𝑟−𝑛𝑦𝑟
𝑟 𝑛−𝑟 = ∑ 𝑛
𝑟=0 ( ) 𝑥 𝑦 (
𝑟=0 𝑟 ) 𝑥
𝑟
This result is known as the binomial theorem for a positive integral index.
Multinomial Theorem:
For positive integers n and k the coefficient of 𝑥𝑛1 𝑥𝑛2 𝑥𝑛3 … … . . 𝑥𝑛𝑘 in the expansion of
1 2 3 𝑘
(𝑥1 + 𝑥2 + 𝑥3 + ⋯ ⋯ ⋯ + 𝑥𝑘 )𝑛 is 𝑛!
𝑛1! 𝑛2! 𝑛3!……𝑛 𝑘!
Problems:
2 15
(iii) 𝑥0 in the expansion of (3𝑥2 − )
𝑥
Solution:
By the Binomial theorem, we have (𝑥 + 𝑦)𝑛 = ∑𝑛 𝑛 𝑟 𝑛−𝑟 = ∑𝑛 𝑛 𝑟−𝑛 𝑟
𝑦
𝑟=0 ( ) 𝑥 𝑦 𝑟=0 ( ) 𝑥
𝑟 𝑟
12
(i). (2𝑥 − 3𝑦)12 = ∑12 𝑟 12−𝑟
𝑟=0 ( ) (2𝑥) (−3𝑦)
𝑟
12 𝑟( )12−𝑟 𝑟 12−𝑟
= ∑12 𝑥 𝑦
𝑟=0 ( ) 2 −3
𝑟
In the expansion, the coefficient of 𝑥 9 𝑦 3 (which corresponds to 𝑟 = 9) is
12 12−9 = −29 × 33 × 12!
( ) 2 9(−3 ) 9! ∙3!
9
12×11×10
= −29 × 33 ×
6
= −(210 × 33 × 11 × 10)
10
(ii). 𝑥3(1 − 2𝑥)10 = ∑10 𝑟 10−𝑟
𝑟=0 ( ) (−2𝑥) 1
𝑟
10
𝑥3(1 − 2𝑥)10 = ∑10 𝑟 𝑥𝑟+3
𝑟=0 ( 𝑟 ) (−2)
Solution:
4
(i). The general term is the expansion of (2𝑥 − 𝑦 − 𝑧)4 is ( ) (2𝑥)𝑛1(−𝑦)𝑛2 (−𝑧)𝑛3
𝑛1 , 𝑛2 , 𝑛3
4 4
( ) (2𝑥)1(−𝑦)1(−𝑧)2=( ) (2)(−1)(−1)2𝑥𝑦𝑧2
1, 1, 2 1, 1, 2
4 4!
This shows that the required coefficient is ( ) (2)(−1)(−1)2 = × (−2) = −12
1, 1, 2 1! 1! 2!
6
(ii). The general term is the expansion of (2𝑥3 − 3𝑥𝑦2 + 𝑧2)6 is ( ) (2𝑥3)𝑛1 (−3𝑥𝑦2)𝑛2 (𝑧2)𝑛3
𝑛1 , 𝑛2 , 𝑛3
6 6
( ) (2𝑥3)3(−3𝑥𝑦2)2(𝑧2)0 = ( ) (2)3(−3)2(1)0𝑥11𝑦4
3, 2, 0 3, 2, 0
6 6!
This shows that the required coefficient is ( ) (2)3(3)2 = × 72 = 4320
3, 2, 0 3! 2!
7
(iii). The general term is the expansion of (3𝑥 − 2𝑦 − 4𝑧) 7 is ( ) (3𝑥)𝑛1(−2𝑦)𝑛2(−4𝑧)𝑛3
𝑛1 , 𝑛2 , 𝑛3
For 𝑛1 = 2, 𝑛2 = 2, 𝑛 3 = 3 this becomes
7 7
( ) (3𝑥)2(−2𝑦)2(−4𝑧)3=( ) (3) 2(−2)2(−4)3𝑥2𝑦2𝑧 3
2, 2, 3 2, 2, 3
This shows that the required coefficient is
7 ) (3)2(−2)2(−4)3 =
7!
( × 9 × 4 × (−64) = −483840
2, 2, 3 2! 2! 3!
16
( (𝑎)𝑛1(2𝑏)𝑛2(−3𝑐)𝑛3(2𝑑)𝑛4(5)𝑛5
𝑛1, 𝑛2, 𝑛3, 𝑛4, 𝑛5 )
16 16
( ) (𝑎)2(2𝑏)3(−3𝑐)2(2𝑑) 5(5)4 = ( ) (2)3(−3)2(2)5(5)4𝑎2𝑏3𝑐2𝑑5
2, 3, 2, 5, 4 2, 3, 2, 5, 4
16 ) (2)3(−3)2(2)5(5)4 =
16!
× 28 × 32 × 54 =
16!
( × 25 × 3 × 53
2, 3, 2, 5, 4 2! 3! 2! 5! 4! (4!)2
8 𝑛1 𝑛2 𝑛3 𝑛4
(
𝑛1, 𝑛 , 𝑛3 , 𝑛42 ) (2𝑤) (−𝑥) (3𝑦) (−2𝑧)
8 ) (2)3(−1)2(3)1(−2)2) =
8!
( × 23 × 3 × 22 = 161280
3, 2, 1, 2 3! 2! 1! 2!
☻Combinations with repetitions:
Suppose we wish to select, with repetition, a combination of r objects from a set of n distinct objects. The
(𝑛+𝑟−1)!
number of such selections is given by 𝐶(𝑛 + 𝑟 − 1, 𝑟) ≡ ≡ 𝐶(𝑟 + 𝑛 − 1, 𝑛 − 1).
𝑟! (𝑛−1)!
𝐶(𝑛 + 𝑟 − 1, 𝑟) ≡ 𝐶(𝑟 + 𝑛 − 1, 𝑛 − 1) represents the number of ways in which r identical objects can be
distributed among 𝑛 distinct containers.
Problems:
1. In how many ways we can distribute 10 identical marbles among 6 distinct containers?
Solution:
The selection consists in choosing with repetitions 𝑟 = 10 marbles for 𝑛 = 6 distinct containers
15!
The required number is 𝐶(6 + 10 − 1, 10) = 𝐶(15, 10) = = 3003
10! 5!
Solution:
𝑥 1 + 𝑥2 + 𝑥3 + ⋯ + 𝑥6 = 9 − 𝑥7
where 9 − 𝑥7 ≤ 9 so that 𝑥7 is non negative integer. Thus, the required number in the number of nonnegative
solutions of the equation.
x1 + x2 + x3 + ……+ x7 = 9
15!
This number is 𝐶(7 + 9 − 1, 9) = 𝐶(15, 9) = = 5005
9! 6!
3. In How many ways can we distribute 7 apples and 6 oranges among 4 children so that each child gets
at least 1 apple?
Solution:
Suppose we first give 1 apple to each child. This exhausts 4 apples. The remaining 3 apples can be distributed
among 4 children in 𝐶(4 + 3 − 1, 3) = 𝐶(6, 3) ways. Also, 6 oranges can be distributed among the 4
children in 𝐶(4 + 6 − 1, 6) = 𝐶(9, 6) ways. Therefore, by the product rule, the number ways of distributing
the given fruits under the given condition is
6! 9!
𝐶(6, 3) × 𝐶(9, 6) = × = 20 × 84 = 1680
3! 3! 6! 3!
Solution:
The 12 symbols can be arranged in 12! Ways. For each of these arrangements, there are 11 positions between
the 12 symbols. Since there must be at least three spaces between successive symbols, 33 of the 45 spaces
will be used up. The remaining 12 spaces are to be accommodated in 11 positions. This can be done in
𝐶(11 + 12 − 1, 12) = 𝐶(22, 12) ways. Consequently, by the product rule, the required number is
22!
12! × 𝐶(22, 12) = 12! × = 3.097445 × 1014
12! × 10!
5. In how many ways can one distribute eight identical balls into four distinct containers so that (i) no
container is left empty? (ii) the fourth container gets an odd number of balls?
Solution:
(i). First, we distribute one ball in to each container. Then we distribute the remaining 4 balls into 4
containers. The number of ways of doing this is the required number. This number is
7!
𝐶(4 + 4 − 1, 4) = 𝐶(7, 4) = = 35
4! × 3!
(ii). If the fourth container has o get an odd number of balls, we have to put 1 or 3 or 5 or 7 balls into it.
Suppose we put 1 ball into the fourth container and the remaining 7 balls can be put into the remaining three
containers in
Similarly, we put 3 balls into the fourth container and the remaining 5 balls can be put into the remaining
three containers in
Similarly, we put 5 balls into the fourth container and the remaining 3 balls can be put into the remaining
three containers in
Similarly, we put 7 balls into the fourth container and the remaining 1 ball can be put into the remaining
three containers in
Thus, the total number of ways of distributing the given balls so that the fourth container gets an odd number
of balls is
9! 7! 5! 3!
𝐶(9, 7) + 𝐶(7, 5) + 𝐶(5, 3) + 𝐶(3, 1) = + + + = 36 + 21 + 10 + 3 = 70
7!×2! 5!×2! 3!×2! 1!×2!
Solution:
Solution:
Solution:
Given 𝑥 1 + 𝑥2 + 𝑥3 + 𝑥4 + 𝑥5 = 30
Module 3
Relations & Functions
Content
(f). Surjective or onto: A function 𝑓: 𝐴 → 𝐵 is called onto if for every element b of B there is an
element a of A such that 𝑓(𝑎) = 𝑏
In other words. 𝑓 is an onto function from A to B if every element of B has a Preimage in A.
(g). Bijective or one-to-one correspondence: A function which is both one-to-one and onto is
called Bijective.
Problems:
1. Let 𝐴 = {1,2,3,4,5,6,7}, 𝐵 = {𝑤, 𝑥, 𝑦, 𝑧}. Find the number of Onto Functions from A to B.
Solution: Given 𝑚 = |𝐴| = 7 & 𝑛 = |𝐵| = 4
n
𝑃(7,4) = ∑ (−1)k( 4 )(4 − k)7 = 8400
4−k
k=0
☻Pigeonhole Principle:
If 𝑚 pigeons occupy 𝑛 pigeon holes and if 𝑚 > 𝑛, then two or more pigeons occupy the same
pigeonhole.
Generalization:
If 𝑚 pigeons occupy 𝑛 pigeonholes, then at least one pigeonhole must contain (𝑝 + 1) or more
(𝑚−1)
pigeons, where 𝑝 = ⌊ ⌋
𝑛
Problems:
1. ABC is an equilateral triangle whose sides are of length 1cm each. If we select 5 points
inside the triangle, prove that at least 2 of these points are such that the distance between
them is less than 1 cm.
2
Solution:
Consider the triangle DEF formed by the mid points of the sides BC, CA and AB of the given
triangle ABC. Then the triangle ABC is partition into 4 small equilateral triangles, each of which
has sides equal to 1 cm treating each of these four portions as a pigeonhole and 5 points chosen
2
inside the triangle as pigeons, we find by using the pigeonhole principle that at least one portion
1
must contain two or more points. Evidently the distance between such points is < cm.
2
2. A magnetic tape contains a collection of 5 lakh strings made up to four or fewer number of
English Letters can all the strings is the collection be distinct?
Solution:
Each place is an n letter string can be filled in 26 ways. Therefore, the possible number of strings
made up of n letters is 26𝑛 consequently, the total number of different possible strings made up of
four or fewer letter is 264 + 263 + 262 + 26 = 4,75,254.
Therefore, if there are 5 lakh strings in the tape, then at least one string is repeated. Thus, all the
strings in the collection cannot be distinct.
3. Shirts numbered consecutively from 1 to 20 are worn by 20 students of a class. When any
3 of these students are chosen to be a debating team from the class, the sum of their shirt
numbers is used as a code number of the team. Show that if any 8 of the 20 are selected,
then from these 8 we may form at least two different teams having the same code number.
Solution:
From the 8 of the 20 students selected the numbers of teams of 3 students that can be formed is
8𝐶 =56. According to the way in which the code number of a team is determined, we note that the
3
smallest possible code number is 1 + 2 + 3 = 6 and the largest possible code number is 18 +
19 + 20 = 57. Thus, the code number vary from 6 to 57, and these are 52 in number. As such
only 52 code number are available for 56 possible teams, consequently by the pigeonhole principle,
at least two different teams will have the same code number.
☻Composition of functions:
Consider three non-empty sets A, B, C and the functions 𝑓: 𝐴 → 𝐵 and 𝑔: 𝐵 → 𝐶. the composition
of these two functions is defined as the function 𝑔𝑜𝑓: 𝐴 → 𝐶 with (𝑔𝑜𝑓)(𝑎) = 𝑔{𝑓(𝑎)} for all
𝑎𝜖𝐴.
Problems:
1. Consider the function 𝑓 and 𝑔 defined by 𝑓(𝑥) = 𝑥3 and 𝑔(𝑥) = 𝑥2 + 1 Ɐ 𝑥𝜖𝑅 find
𝑔𝑜𝑓, 𝑓𝑜𝑔, 𝑓2 and 𝑔2
Solution:
Here, both f and g are defined on R, therefore all of the functions 𝑔𝑜𝑓, 𝑓𝑜𝑔, 𝑓2 = 𝑓𝑜𝑓and 𝑔2 =
𝑔𝑜𝑔 are defined on R and we find
(𝑔𝑜𝑓)(𝑥) = 𝑔{𝑓(𝑥)} = 𝑔(𝑥3) = (𝑥3)2 + 1 = 𝑥6 + 1
(𝑓𝑜𝑔)(𝑥) = 𝑓{𝑔(𝑥)} = 𝑓(𝑥2 + 1) = (𝑥2 + 1)3
𝑓2(𝑥) = (𝑓𝑜𝑓)(𝑥) = 𝑓{𝑓(𝑥)} = 𝑓(𝑥3) = (𝑥3)3 = 𝑥9
𝑔2(𝑥) = (𝑔𝑜𝑔)(𝑥) = 𝑔{𝑔(𝑥)} = 𝑔(𝑥2 + 1) = (𝑥2 + 1)2 + 1
Solution:
We check that for any 𝑥𝜖𝑅
(𝑔𝑜𝑓)(𝑥) = 𝑔[𝑓(𝑥)] = 𝑔(2𝑥 + 5)
= 1/2(2𝑥 + 5 − 5) = 𝑥 = 𝐼𝑅(𝑥)
(𝑓𝑜𝑔)(𝑥) = 𝑓[𝑔(𝑥)] = 𝑓{1/2(𝑥 − 5)}
= 2{1/2(𝑥 − 5)} + 5 = 𝑥 = 𝐼𝑅(𝑥)
☻Properties of Functions:
Theorem 1: A function 𝑓: 𝐴 → 𝐵 is invertible if and only if one-to-one and onto.
Proof: Suppose that f is invertible then there exists a unique function 𝑔: 𝐵 → 𝐴 such that 𝑔𝑜𝑓 =
𝐼𝐴 and 𝑓𝑜𝑔 = 𝐼𝐵Take any 𝑎1, 𝑎2 𝜖 𝐴 then
𝑓(𝑎1) = 𝑓( 𝑎2) ⇒ 𝑔{𝑓(𝑎1)} = 𝑔{𝑓( 𝑎2)}
⇒ (𝑔𝑜𝑓)( 𝑎1) = (𝑔𝑜𝑓)( 𝑎2)
⇒ 𝐼𝐴(𝑎1) = 𝐼𝐴( 𝑎2)
⇒ 𝑎1 = 𝑎2
This prove 𝑓 is one-to-one
Next, take any 𝑏 𝜖 𝐵. Then 𝑔(𝑏) 𝜖 𝐴 and 𝑏 = 𝐼𝐵(𝑏)
= (𝑓𝑜𝑔)(𝑏) = 𝑓{𝑔(𝑏)}.
Thus, 𝑏 is the image of an element 𝑔(𝑏) 𝜖 𝐴 under f. therefore, f is onto as well.
Conversely, suppose that f is one-to-one and onto then for each 𝑏 𝜖 𝐵 there is a unique 𝑎 𝜖 𝐴 such
that 𝑏 = 𝑓(𝑎) now consider the function 𝑔: 𝐵 → 𝐴 defined by 𝑔(𝑏) = 𝑎 then
(𝑔𝑜𝑓)(𝑎) = 𝑔{𝑓(𝑎)} = 𝑔(𝑏) = 𝑎 = 𝐼𝐴(𝑎) and (𝑓𝑜𝑔)(𝑏) = 𝑓{𝑔(𝑏)} = 𝑓(𝑎) = 𝑏 = 𝐼𝐵(𝑏)
These show that f is invertible with g as the inverse. This completes the proof of the theorem.
1, if i = j
δij== {
0, if i ≠ j
☻Digraph of a relation:
Let V be a finite nonempty set. A directed graph G on V is made up of the elements of V, called
the vertices or nodes of G, and a subset E, of 𝑉 × 𝑉 that contains the edges or arcs, of G. The set
V is called the vertex set of G, the set E edge set. We then write 𝐺 = (𝑉, 𝐸) to denote the graph.
If 𝑎, 𝑏 ∈ 𝑉 and (𝑎, 𝑏) ∈ 𝐸 then there is an edge from 𝑎 to 𝑏 vertex 𝑎 is called the origin or source
of the edge with 𝑏 the terminus or terminating vertex and we say that 𝑏 is adjacent from 𝑎 and that
𝑎 is adjacent to 𝑏. In addition, if 𝑎 ≠ 𝑏, then (𝑎, 𝑏) ≠ (𝑏, 𝑎). An edge of the form (𝑎, 𝑎) is called
a loop.
Problems:
1. Let 𝐴 = {1,2,3,4} and let R be the relation on A defined by 𝑥𝑅𝑦 if and only if 𝑦 = 2𝑥.
a) Write down R as asset of ordered pairs.
b) Draw the digraph of R.
c) Determine the in-degrees and out-degrees of the vertices in the digraph.
Solution:
a) We observe that for 𝑥, 𝑦 ∈ 𝐴, (𝑥, 𝑦) ∈ 𝑅 if and only if 𝑦 = 2𝑥. thus 𝑅 = {(1,2), (2,4)}.
b) The digraph of R is as shown below
c) From the above digraph, we note that 3 is an isolated vertex and that for the vertex 1,2,4 the in-
degrees and out-degrees are as shown in the table
Vertex 1 2 4
In-degree 0 1 1
Out-degree 1 1 0
3. Find the relation represented by the digraph given below. Also write down its matrix.
Solution:
By examining the given digraph which has 4 vertices, we note that the relation R represented by it
is defined on the set 𝐴 = {1,2,3,4} and is given by 𝑅 = {(1,2), (1,4), (2,2), (2,3), (4,1), (4,4)}.
The matrix of R is
0101
0110
𝑀𝑅 = [ ]
0000
1001
☻Properties of Relations:
1. Reflexive relation:
A relation R on a set A is said to be reflexive, if (𝑎, 𝑎) ∈ 𝑅, for all 𝑎 ∈ 𝐴.
Example: ≤
2. Irreflexive relation:
A relation is said to be irreflexive, if (𝑎, 𝑎) ∉ 𝑅 for any 𝑎 ∈ 𝐴.
Example: < , >
3. Symmetric Relation:
A relation R on a set is said to be symmetric, If (𝑏, 𝑎) ∈ 𝑅 whenever (𝑎, 𝑏) ∈ 𝑅 for all 𝑎, 𝑏 ∈ 𝐴.
A relation which is not symmetric is called an Asymmetric relation.
Example: If 𝐴 = {1,2,3} and 𝑅1 = {(1,1), (1,2), (2,1)}, 𝑅2 = {(1,2), (2,1), (1,3)}
𝑅1 is symmetric and 𝑅2 is asymmetric.
4. Antisymmetric relation:
A relation R on a set A is said to be antisymmetric, if whenever (𝑎, 𝑏) ∈ 𝑅 and (𝑏, 𝑎) ∈ 𝑅 then
𝑎 = 𝑏.
Example: is less than or equal to.
5. Transitive Relation:
A relation on a set A is said to be transitive if whenever (𝑎, 𝑏) ∈ 𝑅 and (𝑏, 𝑐) ∈ 𝑅 then (𝑎, 𝑐 ) ∈ 𝑅
for all 𝑎, 𝑏, 𝑐 ∈ 𝐴.
Examples:
1. Determine nature of the relations.
[1] 𝐴 = {1,2,3}, 𝑅1 = {(1,2), (2,1), (1,3), (3,1)}
- Symmetric but not reflexive.
[2] 𝑅2 = {(1,1), (2,2), (3,3), (2,3)}
- Reflexive but not symmetric.
[3] 𝑅3 = {(1,1), (2,2), (3,3)}
- Reflexive and symmetric.
[4] 𝑅4 = {(1,1), (2,2), (3,3), (2,3), (3,2)}
- Both reflexive and symmetric.
[5] 𝑅5 = {(1,1), (2,3), (3,3)}
- Neither reflexive nor symmetric
2. If 𝐴 = {1,2,3,4}, 𝑅1 = {(1,1), (2,3), (3,4), (2,4)} is transitive 𝑅2 = {(1,3), (3,2)} is not
transitive.
☻Equivalence relation:
A relation that is reflexive, symmetric and transitive.
Problems:
1. A relation R on a set 𝐴 = {𝑎, 𝑏, 𝑐} is represented by the following matrix.
101
𝑀𝑅 = [0 1 0] determine whether R is an Equivalence relation.
001
Solution: 𝑅 = {(𝑎, 𝑎), (𝑎, 𝑐), (𝑏, 𝑏), (𝑐, 𝑐)} we note that (𝑎, 𝑐) ∈ 𝑅 but (𝑐, 𝑎) ∉ 𝑅
∴ R is not symmetric
∴R is not equivalence
2. For a fixed integer 𝑛 > 1 prove that the relation congruent modulo 𝑛 is an equivalence
relation on the set of all integers 𝑍.
Solution: For 𝑎, 𝑏 ∈ 𝑧, we say that 𝑎 is congruent to 𝑏 modulo 𝑛 if 𝑎 − 𝑏 is a multiple of n or
equivalently, 𝑎 − 𝑏 = 𝑘𝑛 for some 𝑘 ∈ 𝑍.
Let us denote this relation by 𝑅 so that 𝑎𝑅𝑏 means 𝑎 ≡ 𝑏 (𝑚𝑜𝑑 𝑛) we have to prove that 𝑅 is
an equivalence relation.
We note that for every 𝑎 ∈ 𝑍, 𝑎 − 𝑎 = 0 is a multiple of 𝑛 ie, 𝑎 ≡ 𝑎(𝑚𝑜𝑑 𝑛), 𝑎𝑅𝑎
R is reflexive. Next for all 𝑎, 𝑏 ∈ 𝑧
𝑎𝑅𝑏 → 𝑎 ≡ 𝑏 𝑚𝑜𝑑 𝑛.
→ 𝑎 − 𝑏 is a multiple of 𝑛
→ 𝑏 − 𝑎 is a multiple of 𝑛
→ 𝑏 ≡ 𝑎 𝑚𝑜𝑑 𝑛
→ 𝑏𝑅𝑎
R is symmetric.
Lastly, we note that for all 𝑎, 𝑏, 𝑐 ∈ 𝑍
𝑎𝑅𝑏 and 𝑏𝑅𝑐 ⇒ 𝑎 ≡ 𝑏(𝑚𝑜𝑑 𝑛) and 𝑏 ≡ 𝑐(𝑚𝑜𝑑 𝑛)
= 𝑎 − 𝑏 and 𝑏 − 𝑐 are multiples of 𝑛
= (𝑎 − 𝑏) + (𝑏 − 𝑐) = (𝑎 − 𝑐) is a multiple of 𝑛
= 𝑎 ≡ 𝑐( 𝑚𝑜𝑑 𝑛) = 𝑎𝑅𝑐
R is transitive. This proves that R is equivalence relation.
☻Equivalence Class:
Let R be an equivalence relation on a set A and 𝑎 ∈ 𝐴. Then the set of all those elements
𝑥 of A which are related to a by R is called the equivalence class of a with respect to R.
𝑎 ̅ = [𝑎] = 𝑅(𝑎) = {𝑥 ∈ 𝐴|(𝑥, 𝑎) ∈ 𝑅}
Example:
𝑅 = {(1,1), (1,3), (2,2), (3,1), (3,3)} defined on the set 𝐴 = {1,2,3} we find elements 𝑥 of A for
which (𝑥, 1) ∈ 𝑅 are 𝑥 = 1, 𝑥 = 3. Therefore {1,3} is the equivalence class of 1
i.e., [1] = {1,3}, [2] = [2], [3] = {1,3}
☻Partition of a set:
Let A be a non-empty set suppose that there exist non-empty subsets A1,A2,A3,…… AK of A such
that the following two conditions hold.
1) A is the union of 𝐴1, 𝐴2, 𝐴3, … … 𝐴𝐾 that is 𝐴 = 𝐴1𝑈𝐴2𝑈𝐴3, … 𝑈𝐴𝐾
2) Any two of the subsets 𝐴1, 𝐴2, 𝐴3, … … 𝐴𝐾 are disjoint i.e., 𝐴𝑖 ꓵ 𝐴𝑗 = ф
for 𝑖 ≠ 𝑗 then the set 𝑃 = { 𝐴1, 𝐴2, 𝐴3, … … 𝐴𝐾} is called a partition of A. also
𝐴1, 𝐴2, 𝐴3, … … 𝐴𝐾 are called the blocks or cells of the partition.
A partition of a set A with 6 blocks is as shown below
A Hasse diagram is a graphical rendering of a partially ordered set displayed via the cover
relation of the partially ordered set with an implied upward orientation. A point is drawn for each
element of the poset, and line segments are drawn between these points according to the following
two rules:
1. If 𝑥 < 𝑦 in the poset, then the point corresponding to 𝑥 appears lower in the drawing than the
point corresponding to 𝑦.
2. The line segment between the points corresponding to any two elements 𝑥 and 𝑦 of the poset is
included in the drawing iff 𝑥 covers 𝑦 or 𝑦 covers 𝑥 .
Problems:
1. Let 𝐴 = {1,2,3,4} and 𝑅 = {(1,1), (1,2), (2,2), (2,4), (1,3), (3,3), (3,4), (1,4), (4,4)}.
Verify that R is a partial order on A. also write down the Hasse diagram for R.
Solution:
We observe that the given relation R is reflexive and transitive. Further R does not contain
ordered pairs of the form (𝑎, 𝑏) and (𝑏, 𝑎) with 𝑏 ≠ 𝑎. R is antisymmetric as such R is a partial
order on A.
The Hasse diagram for R must exhibit the relationships between the elements of A as defined by
R. if (𝑎, 𝑏) ∈ 𝑅 there must be an upward edge from a to b.
2. Let 𝐴 = {1,2,3,4,6,8,12} on A, define the partial ordering relation R by 𝑥𝑅𝑦 if and only
if 𝑥/𝑦 draw the Hasse diagram for R.
Solution:
𝑅 = {(1,1), (1,2), (1,3), (1,4), (1,6), (1,8), (1,12), (2,2), (2,4), (2,6), (2,8), (2,12),
(3,3), (3,6), (3,12), (4,4), (4,8), (4,12), (6,6), (6,12), (8,8), (12,12)}.
The Hasse diagram for this R is as shown below.
Solution:
By observing the given diagraph, we note that
𝑅 = {(1,1), (2,2), (3,3), (4,4), (1,2), (1,3), (1,4), (2,4)}
☻External elements in Posets:
Upper bond of a subset B of A: an element 𝑎 ∈ 𝐴 is called an upper bound of a subset B of A
if 𝑥𝑅𝑎 for all 𝑥 ∈ 𝐵.
Lower bound of a subset B of A: an element 𝑎 ∈ 𝐴 is called lower bound of a subset B is A if
𝑎𝑅𝑥 for all 𝑥 ∈ 𝐵.
Supremum (LꓴB): An element 𝑎 ∈ 𝐴 is called the LꓴB of a subset B of A if the following two
conditions hold.
i) A is an upper bound of B.
ii) If 𝑎𝐼 is an upper bound of B then 𝑎𝑅𝑎𝐼.
Infimum (GLB): An element 𝑎 ∈ 𝐴 is called the GLB of a subset B of A if the following two
conditions hold
i) A is a lower bound of B.
ii) If 𝑎𝐼 is a lower bound of B then 𝑎𝐼𝑅𝑎.
Problems:
1. Consider the Hasse diagram of a Poset (A, R) given below.
2. Consider the Poset whose Hasse diagram is shown below. Find LꓴB and GLB of 𝐵 =
{𝑐, 𝑑, 𝑒}
By examining all upward paths from 𝑐, 𝑑, 𝑒 is the given Hasse diagram. We find that LꓴB (𝐵) =
𝑒. by examining all upward paths to 𝑐, 𝑑, 𝑒 we find that 𝐺𝐿𝐵(𝐵) = 𝑎.
☻Lattice:
Let (A, R) be a Poset this Poset is called a lattice. For all 𝑥, 𝑦 ∈ 𝐴 the elements 𝐿ꓴ𝐵 {𝑥, 𝑦} and
𝐺𝐿𝐵 {𝑥, 𝑦} exist is A.
Example: Let (𝐴, 𝑅) be Poset. The Poset is called a.
1). Consider the set N of all-natural numbers and let R be the partial order “less than or equal to”
then for any 𝑥, 𝑦 ∈ 𝑁, we note that 𝐿ꓴ𝐵 {𝑥, 𝑦} = 𝑀𝑎𝑥{𝑥, 𝑦} and 𝐺𝐿𝐵 {𝑥, 𝑦} = 𝑚𝑖𝑛{𝑥, 𝑦} and
both of these belong to 𝑁. Therefore, the Poset (𝑁, ≤ ) is a lattice.
2). Consider the Poset (𝑍+, ∣) where 𝑍+ is set of all positive integer & ∣ is the divisibility set. We
can check that for any 𝑎, 𝑏 ∈ 𝑍+, the least common multiple of 𝑎 & 𝑏 is the 𝐿ꓴ𝐵 {𝑎, 𝑏} & the
GCD of 𝑎 & 𝑏 is 𝐺𝐿𝐵 {𝑎, 𝑏}. Since these belongs to 𝑍+ we infer that (𝑍+, ∣) is a lattice.
3). Consider the poset where Hasse Diagram is
By examining the Hasse diagram, we note that 𝐺𝐿𝐵 {3, 4} does not exist.
∴ The poset is not a Lattice
BCS405A
Discrete Mathematical Structures
(For the 4th Semester Computer Science and Engineering Stream)
Module 4
THE PRINCIPLE OF INCLUSION &
EXCLUSION, RECURRENCE RELATIONS
Content
Generalization:
The principle of inclusion – exclusion as given by expression
̅ = 𝑆0 − 𝑆1 + 𝑆2 − 𝑆3 + ⋯ + (−1)𝑛 𝑆𝑛
𝑁
The number of elements in 𝑆 that satisfy none of the conditions 𝐶1, 𝐶2 ...... 𝐶𝑛. The following
expression determines the number of elements in S that satisfy exactly m of the n conditions
(0 ≤ 𝑚 ≤ 𝑛 ≤);
𝑚+1 𝑚+2 𝑛−𝑚 𝑛
𝐸𝑚 = 𝑆𝑚 − ( ) 𝑆𝑚+ + ( ) 𝑆𝑚+1 … . +(−1) ( ) 𝑆𝑛
1 2 𝑛−𝑚
Problems:
1. Out of 30 students in a hostel, 15 study History, 8 study Economics, and 6 study
Geography. It is known that 3 students study all these subjects. Show that 7 or more
students’ study none of these subjects.
Solution:
Let ‘S’ denote the set of all students in the hostel and 𝐴1, 𝐴2, 𝐴3 denotes the set of students who
study History, Economics and Geography, respectively.
Given, 𝑆1 = ∑|𝐴𝑖| = 15 + 8 + 6 = 29 and
𝑆3 = |𝐴1 ∩ 𝐴2 ∩ 𝐴3| = 3
The number of students who do not study any of the three subjects is |𝐴̅1 ∩ 𝐴̅2 ∩ 𝐴̅3|
|𝐴 ∩ 𝐴̅2 ∩ 𝐴̅3| = |𝑆|−∑|𝐴𝑖| + ∑|𝐴𝑖 ∩ 𝐴𝑗| − 𝛴|𝐴1 ∩ 𝐴2 ∩ 𝐴3|
= |𝑆| − 𝑆1 + 𝑆2 − 𝑆3
= 30 − 29 − 𝑆2 − 3 = 𝑆2 − 2
Where, 𝑆2 = ∑|𝐴𝑖 ∩ 𝐴𝑗|
|𝐴 ∩ 𝐴̅2 ∩ 𝐴̅3| ≥ 9 − 2 = 7.
4. In how many ways 5 number of a’s, 4number of b’s and 3 number of c’s can be
arranged so that all the identical letters are not in a single block?
Solution:
The given letters are 5+4+3 = 12 in number of which 5 are a’s, 4are b’s, and 3 are c’s. If S is
the set of all permutations (arrangements) of these letters, we’ve,
12!
|𝑆| =
5! 4! 3!
Let A1 be the set of arrangements of the letters where the 5 a’s are in a single block.
The number of such arrangements is,
8!
|𝐴1| =
4! 3!
Similarly, if A2 is the set of arrangements of the letters where the 4 b’s are in a single block
and A3 is the set of arrangements of the letters where the 3 c’s are in a single block
We have,
9! 10!
|𝐴2 | = and |𝐴3 | = 5!4!
5!3!
Likewise,
5! 6! 7!
|𝐴1 ∩ 𝐴2| = , |𝐴1 ∩ 𝐴2| = , | 𝐴2 ∩ 𝐴3| =
3! 4! 5!
| 𝐴1 ∩ 𝐴2 ∩ 𝐴3| = 3!
The required number of arrangements is,
5. In how many ways can the 26 letters of the English alphabet be permuted so that none
of the patterns CAR, DOG, PUN (or) BYTE occurs?
Solution:
Let S denote the set of all permutations of the 26 letters. Then |S|= 26!
Let A1 be the set of all permutations in which CAR appears. This word, CAR consists of three
letters which from a single block.
The set A1 therefore consists of all permutations which contains this single block and the 23
remaining letters. |A1| = 24!
Similarly, if A2 , A3 , A4 are the set of all permutations which contain DOG, PUN and BYTE
respectively.
We have, |𝐴2| = 24! |𝐴3| = 24! |𝐴4| = 23!
Likewise, |𝐴1 ∩ 𝐴2| = |𝐴1 ∩ 𝐴3| = |𝐴2 ∩ 𝐴3| = (26 − 6 + 2)! = 22!
|𝐴1 ∩ 𝐴4| = |𝐴2 ∩ 𝐴4| = |𝐴3 ∩ 𝐴4| = (26 − 7 + 2) = 21!
| 𝐴1 ∩ 𝐴2 ∩ 𝐴3| = (26 − 9 + 3)! = 20!
| 𝐴1 ∩ 𝐴2 ∩ 𝐴4| = | 𝐴1 ∩ 𝐴3 ∩ 𝐴4| = | 𝐴2 ∩ 𝐴3 ∩ 𝐴4| = (26 − 10 + 3)! = 19!
| 𝐴1 ∩ 𝐴2 ∩ 𝐴3 ∩ 𝐴4| = (26 − 13 + 4)! = 17!
Therefore, the required number of permutations is given by,
|𝐴 ∩ 𝐴̅2 ∩ 𝐴̅3 ∩ 𝐴̅4| = |𝑆| − ∑|𝐴𝑖| + ∑|𝐴𝑖 ∩ 𝐴𝑗| − ∑|𝐴𝑖 ∩ 𝐴𝑗 ∩ 𝐴𝑘| + | 𝐴1 ∩ 𝐴2 ∩ 𝐴3 ∩ 𝐴4|
Let A1 , A2 , A3 , A4 , A5 be the set of permutations in which O’s, R’s, E’s, N’s appear in pairs
respectively.
13!
Then, |𝐴 | = for i = 1, 2, 3, 4, 5
𝑖 (2!)4
12!
Also, |𝐴 ∩ 𝐴 | = , |𝐴 ∩ 𝐴 ∩ 𝐴 | = 11!
𝑖 𝑗 (2!)3 𝑖 𝑗 𝑘 (2!)2
10!
|𝐴 ∩ 𝐴 ∩ 𝐴 ∩ 𝐴 | = , | 𝐴 ∩ 𝐴 ∩ 𝐴 … … ∩ 𝐴 | = 9!
𝑖 𝑗 𝑘 𝑝 (2!) 1 2 3 5
From these,
14! 13!
𝑆0 = 𝑁 = |𝑆| = 5, 𝑆1 = 𝐶(5, 1) ×
(2!) (2!)4
12! 11!
𝑆2 = 𝐶(5, 2) × , 𝑆3 = 𝐶(5, 3) ×
(2!)3 (2!)2
10!
𝑆4 = 𝐶(5, 4) × , 𝑆5 = 𝐶(5, 5) × 9!
(2!)1
Accordingly, the number of permutations where these is no pair of consecutive identical letter
is,
1 2 3 4
𝐸 = 𝑆 − ( )𝑆 + ( )𝑆 − ( )𝑆 + ( )𝑆 − ( 5 )𝑆
0 0 1 2 3 4 5
1 2 3 4 5
5 13! 5 10!
= 14! − ( ) × 5 12! 5 11! + ( ) × − ( 5 ) × 9!
+( )× −( )×
(2!)5 1 (2!)4 2 (2!)3 3 (2!)2 4 (2!)1 5
The number of permutations where there are exactly two pairs of consecutive identical letters,
3 4
𝐸2 = 𝑆2 − ( ) 𝑆3 + ( ) 𝑆4 − ( 5 ) 𝑆5
1 2 3
5 12! 3 5 11! 5 5 ) × 9!
=( )× − ( )( ) × 4 5 10!
+ ( )( ) × − ( )(
2 (2!)3 1 3 (2!)2 2 4 (2!)1 3 5
The number of permutations where there are at least three pair of consecutive identical letter
is,
3 4
𝐸3 = 𝑆3 − ( ) 𝑆4 + ( ) 𝑆5
2 3
5 11! 3 5 10! 4 5
=( )× +( )( )× − ( ) ( ) × 9!
3 (2!)2 2 4 (2!)1 2 5
☻Derangements:
A permutation of n distinct objects in which none of the objects is in its natural place is called
a derangement.
Formula for 𝑑𝑛
The following is the formula for 𝑑𝑛 for 𝑛 ≥ 1:
1 1 1 (−1)𝑛
𝑑𝑛 = 𝑛! {1 − + − + ⋯⋅ + }
1! 2! 3! 𝑛!
𝑛
(−1)𝑘
= 𝑛! × ∑
𝑘!
𝑘=0
1 1
For example, 𝐷 = 2! [1 − + ]=1
2 1! 2!
1 1 1 1 1
𝐷 = 3! [1 − + − ] = 1 (1 − 1 + − ) = 2
3 1! 2! 3! 2 6
2. From the set of all permutations of n distinct objects, one permutation is chosen at
random. What is the probability that it is not a derangement?
Solution:
The number of permutations of n distinct objects is 𝑛!. The number of derangements of these
objects is 𝑑𝑛.
The probability that a permutation chosen is not a derangement,
𝑑𝑛 1 1 1 (−1)𝑛
𝑃 =1− = 1 − {1 − + − + ⋯+ }
𝑛! 1! 2! 3! 𝑛!
1 1 (−1)𝑛
=1− − + ⋯+
2! 3! 𝑛!
3. In how many ways can the integers 1, 2, 3….10 be arranged in a line so that no even
integer is in its natural place.
Solution:
Let A1 be the set of all permutations of the given integer where 2 is in its natural place. A2 be
the set of all permutations in which 4 is in its natural place, and so on. The number of
permutations where no even integer is in its natural place is |𝐴 ∩ 𝐴̅2 ∩ 𝐴̅3 ∩ 𝐴̅4 ∩ 𝐴̅5|. This
is given by,
|𝐴 ∩ 𝐴̅2 … … ∩ 𝐴̅5| = |𝑆| − 𝑆1 + 𝑆2 − 𝑆3 + 𝑆4 − 𝑆5
We note that |S|=10!
Now, the permutations in A1 are all of the form 𝑏1, 𝑏3, 𝑏4 … 𝑏10 where 𝑏1𝑏3𝑏4 … . 𝑏10is a
permutation of 1,3, 4, 5, …. 10 as such |A1| = 9!
Similarly, |𝐴2|= |𝐴3| = |𝐴4|= |𝐴5| = 9!
So that, 𝑆1 = 𝛴|𝐴𝑖| = 5 × 9! = 𝐶(5, 1) × 9!
The permutations in 𝐴1 ∩ 𝐴2 are all of the form 𝑏1 2 𝑏3 4 𝑏5 𝑏6 … 𝑏10 where
𝑏1𝑏3𝑏5 𝑏6 … . 𝑏10 is a permutations of 1, 3, 5, 6, …10 . As such |𝐴1 ∩ 𝐴2| = 8!
Similarly, each of |𝐴𝑖 ∩ 𝐴𝑗| = 8! Are there are 𝐶(10, 2) such terms, 𝑆2 = 𝛴|𝐴𝑖 ∩ 𝐴𝑗| =
𝐶(5, 2) × 8!
Like wise 𝑆3 = 𝐶(5, 3) × 7!, 𝑆4 = 𝐶(5, 4) × 6!, 𝑆5 = 𝐶(5, 5) × 5!
Accordingly, Expression (1) gives the required number as,
|𝐴̅1 ∩ 𝐴̅2 … … ∩ 𝐴̅5|
= 10! − 𝐶(5, 1) × 9! + 𝐶(5, 2) × 8! − 𝐶(5, 3) × 7! + 𝐶(5, 4) × 6! − 𝐶(5, 5) × 5!
= 2170680
𝑛
4. Prove that, for any positive integer 𝑛, 𝑛! = ∑𝑛
𝑘=0 (
𝑘 ) 𝑑𝑘
Solution:
For any positive integer n, the total number of permutations of 1, 2, 3, … . 𝑁 is 𝑛!. In each such
permutations there exists 𝐾 (where 0 ≤ 𝑘 ≤ 𝑛 ) elements which are in their natural positions
called fixed elements, and n-k elements which are not in their original positions. The k element
𝑛
ca be chosen in ( ) ways and the remaining n-k elements can then be chosen in 𝑑
𝑛−𝑘 ways.
𝑘
𝑛
Hence there are ( ) permutations of 1, 2, 3, …. n with k fixed elements and n-k deranged
𝑘
𝑑𝑛−𝑘
elements. As k varies from 0 to 𝑛, we count all of the n! permutations of 1, 2, 3 … . 𝑛.
𝑛
Thus, 𝑛! = ∑𝑛
𝑘=0 (𝑘) 𝑑𝑛−1
𝑛 𝑛 𝑛 𝑛
= (0) 𝑑𝑛 + (1) 𝑑𝑛−1 + (2) 𝑑𝑛−2 + ⋯ + ( ) 𝑑0
𝑛 𝑛
= ∑𝑛 𝑛 )𝑑 −= ∑ 𝑛
(
𝑘=0 𝑛 − 𝑘 𝑘 𝑘=0 (𝑘) 𝑑𝑘
☻Rook Polynomials:
Consider a board that resembles a full chess board or a part of chess board. Let n be the number
of squares present in the board. Pawns are placed in the squares of the board such that not more
than one pawn occupies a square.
Then, according to the pigeonhole principle, not more than n pawns ca be used. Two pawns
placed on a board having 2 (or) more squares are said to capture (or take) each other if they
(pawns) are in the same row or in the same column of the board. For 2 ≤ 𝑘 ≤ 𝑛, let 𝑟𝑘 denote
the number of ways in which k paws can be placed on a board such that no two pawns capture
each other – that is, no two pawns are in the same row or in the same column of the board.
Then the polynomial: 1 + 𝑟1 𝑥 + 𝑟2 𝑥2 + ⋯ + 𝑟𝑛 𝑥𝑛 is called the rook polynomial for the board
considered. If the board is denoted by 𝑟(𝑐, 𝑥). thus, by definition,
𝑟(𝑐, 𝑥) = 1 + 𝑟1 𝑥 + 𝑟2 𝑥2 + ⋯ + 𝑟𝑛 𝑥𝑛 … … … … …(1)
While defining this polynomial, it has been assumed that 𝑛 ≥ 2. In the trivial case where 𝑛 =
1 (i.e., in the case where a board contains only one square), 𝑟2 , 𝑟3 …are identically zero and the
rook polynomial 𝑟(𝑐, 𝑥) is defined by,
𝑟(𝑐, 𝑥) = 1 + 𝑥 … … … … . . (2)
the expression (1) and (2) can be put in the following combined form which holds for a board
c with 𝑛 ≥ 1 squares.
𝑟(𝑐, 𝑥) = 1 + 𝑟1 𝑥 + 𝑟2 𝑥2 + ⋯ + 𝑟𝑛 𝑥𝑛 … … … … …(3)
Here, 𝑟1 = 𝑛 = number of squares in the board.
Problems:
1. Consider the board containing 6 squares,
1 2
4 5 6
Solution:
For this board 𝑟1 = 6 we observed that 2 non- capturing rooks can have the following
positions: (1, 3), (1, 5), (1, 6), (2, 3), (2, 4), (2, 6), (3, 4), (3, 5). These positions are 8 in
number. therefore 𝑟2 = 8.
Next, 3 mutually non-capturing rooks can be placed only in the following two positions:
(1, 3, 5), (2, 3, 4).
Thus 𝑟3 = 2 we find that four (or) more mutually non-capturing rooks cannot be placed on
the board.
Thus 𝑟4 = 𝑟5 = 𝑟6 = 0. Accordingly, for this board, the rook polynomial is,
𝑟0(𝑐, 𝑥) = 1 + 6𝑥 + 8𝑥2 + 2𝑥3
2. Consider the board containing 8 squares (marked 1 to 8)
1 2 3
4 5
6 7 8
Solution:
For this board, 𝑟1 = 8
In this board, the positions of 2 non-capturing rooks are
(1, 5), (1, 7), (2, 4), (2, 5), (2, 6), (2, 8), (3, 4), (3, 6), (3, 7), (4, 8), (5, 6), (5, 7).
These are 14 numbers, therefore 𝑟2 = 14. The positions of 3 mutually non-capturing rooks
are (1, 5, 7), (2, 4, 8), (2, 5, 6), (3, 4, 7).
These are 4 in number, therefore 𝑟3 = 4.
We check that the board has no positions for more than 3 mutually non-capturing rooks.
Hence, 𝑟4 = 𝑟5 = 𝑟6 = 𝑟7 = 𝑟8 = 0.
Thus, for this board, the rook polynomial is,
𝑟(𝑐, 𝑥) = 1 + 8𝑥 + 14𝑥2 + 4𝑥3.
3. Find the rook polynomial for the 3 * 3 board by using the expansion formula.
Solution:
The 3 X 3 board let us mark the square which is at the centre of the board. The boards D and E
appear as shown below (the shaded parts are the deleted parts),
D E
For the board D, we find that 𝑟1 = 4, 𝑟2 = 2, 𝑟3 = 𝑟4 = 0
𝑟(𝐷, 𝑥) = 1 + 4𝑥 + 2𝑥2
The board E is the same as the one considered (3 X 3) As such for this board,
𝑟(𝐸, 𝑥) = 1 + 8𝑥 + 14𝑥2 + 4𝑥3
Now, the expansion formula gives
3 4
5 6
7 8
9 10 11
Solution:
We note that the given board C is made up of two disjoint sub-boards 𝐶1 and 𝐶2, where 𝐶1 is
the 2 X 2 board with squares numbered 1 to 4 and 𝐶2, is the board with squares numbered 5 to
11.
Since 𝐶1 is the 2 X 2 board we’ve.
𝑟(𝐶1, 𝑥) = 1 + 4𝑥 + 2𝑥2
We note that 𝐶2 is the same as the board considered (3 X 3 board). We’ve,
𝑟(𝐶2, 𝑥) = 1 + 7𝑥 + 10𝑥2 + 2𝑥3
Therefore, the product formula yields the rook polynomials for the given board as,
𝑟(𝐶1, 𝑥) = 𝑟(𝐶1, 𝑥) × 𝑟(𝐶2, 𝑥)
= (1 + 4𝑥 + 2𝑥2)(1 + 7𝑥 + 10𝑥2 + 2𝑥3
= 1 + 11𝑥 + 40𝑥2 + 56𝑥3 + 28𝑥4 + 4𝑥5
5. Four persons 𝑃1, 𝑃2, 𝑃3, 𝑃4 who arrive late for a dinner party find that only one chair at
each of five tables 𝑇1, 𝑇2, 𝑇3, 𝑇4 and 𝑇5 is vacant. 𝑃1will not sit at 𝑇1 or 𝑇2, 𝑃2 will not
sit at 𝑇2, 𝑃3 will not sit at 𝑇3 or 𝑇4, and 𝑃4 will not sit at 𝑇4 or 𝑇5. Find he number of
ways they can occupy the vacant chairs.
Solution:
Consider the board shown below, representing the situation. The shaded in the first now
indicate that tables 𝑇1, and 𝑇2 are forbidden for 𝑃1 and so on.
T1 T2 T3 T4 T5
P1
P2
P3
P4
For the board made up of shaded squares in the above figure. The rook polynomial is given by,
this is the number of handshakes in the party when 𝑛 ≥ 2 persons are present.
Where A and B are arbitrary real constants as the general equation of the relation (1).
Case 2: The two roots k1 and k2 of equation (2) are equal and real, with k as the common value.
Then we take,
𝑎𝑛 = (𝐴 + 𝐵𝑛)𝑘𝑛 … … … (4)
where A and B are arbitrary real constants, as the general solution of the relation (1).
case 3: The two roots k1 and k2 of equations (2) are complex. Then k1 and k2 are complex
conjugates of each other, so that if 𝑘1 = 𝑝 + 𝑖𝑞, then 𝑘2 = 𝑝 + 𝑖𝑞 and we take,
𝑎𝑛 = 𝑟𝑛(𝐴 cos 𝑛𝜃 + 𝑏 sin 𝑛𝜃).......... (5)
where A and B are arbitrary complex constants,
𝑎
𝑟 = |𝑘1 | = |𝑘2 | = √𝑝2 + 𝑞2 𝑎𝑛𝑑 𝜃 = 𝑡𝑎𝑛−1 ( ) as the general solution of the relation (1).
𝑏
Problems:
1. Solve the recurrence relation
𝑎𝑛 − 6𝑎𝑛−1 + 9𝑎𝑛−2 = 0 𝑓𝑜𝑟 𝑛 ≥ 2, 𝑔𝑖𝑣𝑒𝑛 𝑡ℎ𝑎𝑡 𝑎𝑜 = 5, 𝑎1 = 12
Solution:
The characteristics equation for the given relation is,
𝑘2 − 6𝑘 + 9 = 0, (𝑜𝑟) (𝑘 − 3)2 = 0
Whose roots are 𝑘1 = 𝑘2 = 3. Therefore, the general solution for 𝑎𝑛is,
𝑎𝑛 = (𝐴 + 𝐵𝑛)3𝑛
Where A and B are arbitrary constants using the given initial conditions 𝑎0 = 5 and 𝑎1 = 12
in equation, we get 5 = 𝐴 and 12 = 3(𝐴 + 𝐵) solving these we get, 𝐴 = 5 and 𝐵 = −1
Putting these values in equation we get,
𝑎𝑛 = (5 − 𝑛)3𝑛
This is the solution of the given relation, under the given initial condition.
Module 5
INTRODUCTION TO GROUP THEORY
Content
S.No Topic
1 Definitions and Examples of Particular Groups Klein 4-group
4 permutation groups,
5 Subgroups
6 cyclic groups
Definitions, properties,
Homomrphisms,
Isomorphisms,
Cyclic Groups,
Cosets, and Lagrange’s Theorem.
Elements of CodingTheory,
The Hamming Metric,
The Parity Check, and Generator Matrices.
Group Codes:
Any group can be given the discrete topology. Since every map from a discrete space is
continuous, the topological homomorphisms between discrete groups are exactly the group
homomorphisms between the underlying groups. Hence, there is an isomorphism between
the category of groups and the category of discrete groups. Discrete groups can therefore be
identified with their underlying (non-topological) groups. With this in mind, the term
discrete group theory is used to refer to the study of groups without topological structure, in
contradistinction to topological or Lie group theory. It is divided, logically but also
technically, into finite group theory, and infinite group theory.
There are some occasions when a topological group or Lie group is usefully endowed with
the discrete topology, 'against nature'. This happens for example in the theory of the Bohr
com pactification, and in group cohomology theory of Lie groups.
Properties:
Since topological groups are homogeneous, one need only look at a single point to determine
if the group is discrete. In particular, a topological group is discrete if and only if the
singleton containing the identity is an open set.
A discrete group is the same thing as a zero-dimensional Lie group (uncountable discrete
groups are not second-co untable so authors who require Lie groups to satisfy this axiom do
not regard these groups as Lie groups). The identity component of a discrete group is just the
trivial subgroup while the group of components is isomorphic to the group itself.
Since the only Hausdorff topology on a finite set is the discrete one, a finite Hausdorff
topological group must necessarily be discrete. It follows that every finite subgroup of a
Hausdorff group is discrete.
Other properties:
Examples:
• Frieze groups and wallpaper groups are discrete subgroups of the i sometry group of
the Euclidean plane. Wallpaper groups are cocompact, but Frieze groups are not.
Group homomorphism:
Image of a Group homomorphism(h) from G(left) to H(right). The smaller oval inside H is
In mathematics, given two groups (G, *) and (H, ·), a group homomorphism from (G, *) to
(H, ·) is a function h : G → H such that for all u and v in G it holds that
where the group operation on the left hand side of the equation is that of G and on the right
hand side that of H.
From this property, one can deduce that h maps the identity element eG of G to the identity
element eH of H, and it also maps inverses to inverses in the sense that
-1
h(u ) = h(u) - 1.
Hence one can say that h "is compatible with the group s tructure".
Older notations for the homomorphism h(x) may be xh, though this may be confused as an
index or a general subscript. A more recent trend is to write group homomorphisms on the
right of their arguments, omitting brackets, so that h( x) becomes simply x h. This approach is
especially prevalent in areas of group theory where automata play a role, since it accords
better with the convention that automata read words from left to right.
In areas of mathematics where one considers groups endowed with additional structure, a
homomorphism sometimes means a map which respects not only the group structure (as
above) but also the extra structure. For example, a homomorphism of topological groups is
often required to be continuous.
If the homomorphism h is a bijection, then one can show that its inverse is also a group
homomorphism, and h is called a group isomorphism; in this case, the groups G and H are
called is omorphic: they differ only in the notation of their elements and are identical for all p
ractical purposes.
If G and H are abelian (i.e. commutative) groups, then the set Hom(G, H) of all group
homomorphisms from G to H is itself an abelian group: the sum h + k of two
homomorphisms is defined by
(h + k) o f = (h o f) + (k o f) and g o (h + k) = (g o h) + (g o k).
This shows that the set End(G) of all endomorphisms of an abelian group forms a ring, the
endomorphism ring of G. For example, the endomorphism ring of the abelian group
consisting of the direct sum of m copies of Z/nZ is isomorphic to the ring of m-by-m
matrices with entries in Z/nZ. The above compatibility also shows that the category of all
abelian groups with group ho momorphisms forms a preadditive category; the existence of
direct sums and well-behaved kernels makes this category the prototypical example of an
abelian category.
Cyclic group
In group theory, a cyclic group is a group that can be generated by a single element, in the
sense that the group has an element g (called a "generator" of the group) such that, when
written multiplicatively, every element of the group is a power of g (a multiple of g when the
notation is additive).
Definition
The six 6th complex roots of unity form a cyclic group under multiplication. z is a primitive
element, but z2 is not, because the odd powers of z are not a power of z2.
For example, if G = { g0, g1, g2, g3, g4, g5 } is a group, then g6 = g0, and G is cyclic. In fact,
G is essentially the same as (that is, isomorphic to) the set { 0, 1, 2, 3, 4, 5 } with addition
modulo 6. For example, 1 + 2 = 3 (mod 6) cor responds to g1·g2 = g3, and 2 + 5 = 1 (mod 6)
corresponds to g2·g5 = g7 = g1, and so on. One can use the isomorphism φ defined by φ(gi) =
i.
For every positive integer n there is exactly one cyclic group (up to isomorphism) whose
order is n, and there is exactly one infinite cyclic group (the integers under addition). Hence,
the cyclic groups are the simplest groups and they are completely classified.
The name "cyclic" may be m isleading: it is possible to generate infinitely many elements
and not form any literal cycles; that is, every gn is distinct. (It can be said that it has one
infinitely long cycle.) A group generated in this way is called an infinite cyclic group, and is
isomorphic to the additive group of integers Z.
Furthermore, the circle group (whose elements are uncountable) is not a cyclic group—a
cyclic group always has countable elements.
Since the cyclic groups are abelian, they are often written additively and denoted Zn.
However, this notation can be problematic for number theorists because it conflicts with the
usual notation for p-adic number rings or localization at a prime ideal. The quotient notations
Z/nZ, Z/n, and Z/(n) are standard alternatives. We adopt the first of these here to avoid the
collision of notation. See also the section Subgroups and notation below.
One may write the group multiplicatively, and denote it by Cn, where n is the order (which
can be ∞). For example, g3g4 = g2 in C5, whereas 3 + 4 = 2 in Z/5Z.
Properties
The fundamental theorem of cyclic groups states that if G is a cyclic group of order n then
every subgroup of G is cyclic. Moreover, the order of any subgroup of G is a divisor of n and
for each positive divisor k of n the group G has exactly one subgroup of order k. This
property characterizes finite cyclic groups: a group of order n is cyclic if and only if for every
divisor d of n the group has at most one subgroup of order d. Sometimes the e quivalent s
tatement is used: a group of order n is cyclic if and only if for every divisor d of n the group
has exactly one subgroup of order d.
Every finite cyclic group is i somorphic to the group { [0], [1], [2], ..., [n - 1] } of integers
modulo n under addition, and any infinite cyclic group is isomorphic to Z (the set of all
integers) under addition. Thus, one only needs to look at such groups to understand the
properties of cyclic groups in general. Hence, cyclic groups are one of the simplest groups to
study and a number of nice p roperties are known.
• G is abelian; that is, their group operation is com mutative: gh = hg (for all h in G).
This is so since g + h mod n = h + g mod n.
• If n is finite, then gn = g0 is the identity element of the group, since kn mod n = 0 for
any integer k.
• If n = ∞, then there are exactly two elements that generate the group on their own:
namely 1 and -1 for Z
• If n is finite, then there are exactly φ(n) elements that generate the group on their
own, where φ is the Euler totient function
• Every subgroup of G is cyclic. Indeed, each finite subgroup of G is a group of { 0,
1, 2, 3, ... m - 1} with addition m odulo m. And each infinite subgroup of G is mZ for
some m, which is bijective to (so is omorphic to) Z.
• Gn is isomorphic to Z/nZ (factor group of Z over nZ) since Z/nZ = {0 + nZ, 1 +
nZ, 2 + nZ, 3 + nZ, 4 + nZ, ..., n - 1 + nZ} { 0, 1, 2, 3, 4, ..., n - 1} under
addition modulo n.
More generally, if d is a divisor of n, then the number of elements in Z/n which have order d
is φ(d). The order of the residue class of m is n / gcd(n,m).
If p is a prime number, then the only group (up to isomorphism) with p elements is the cyclic
group Cp or Z/pZ.
The direct product of two cyclic groups Z /nZ and Z/mZ is cyclic if and only if n and m are
coprime. Thus e.g. Z/12Z is the direct product of Z/3Z and Z/4Z, but not the direct product
of Z/6Z and Z/2Z.
The definition immediately implies that cyclic groups have very simple group presentation
C∞ = < x | > and Cn = < x | xn > for finite n.
A primary cyclic group is a group of the form Z/pk where p is a prime number. The fun
damental theorem of abelian groups states that every finitely generated abelian group is the
direct p roduct of finitely many finite primary cyclic and infinite cyclic groups.
Z/nZ and Z are also commutative rings. If p is a prime, then Z/pZ is a finite field, also
denoted by Fp or GF(p). Every field with p elements is isomorphic to this one.
The units of the ring Z/nZ are the numbers coprime to n. They form a group under
multiplication modulo n with φ(n) elements (see above). It is written as (Z/nZ)×. For
example, when n = 6, we get (Z/nZ)× = {1,5}. When n = 8, we get (Z/nZ)× = {1,3,5,7}.
The group (Z/pZ)× is cyclic with p - 1 elements for every prime p, and is also written
(Z/pZ)* because it consists of the non-zero elements. More generally, every finite
s ubgroup of the mu ltiplicative group of any field is cyclic.
Examples
In 2D and 3D the symmetry group for n-fold rotational symmetry is Cn, of abstract group
type Zn. In 3D there are also other symmetry groups which are algebraically the same, see
Symmetry groups in 3D that are cyclic as abstract group.
Note that the group S1 of all rotations of a circle (the circle group) is not cyclic, since it is not
even countable.
The nth roots of unity form a cyclic group of order n under multiplication. e.g., 0 = z3 - 1
= (z - s0)(z - s1)(z - s2) where si = e2πi / 3 and a group of {s0,s1,s2} under mul tiplication is
cyclic.
The Galois group of every finite field extension of a finite field is finite and cyclic;
conversely, given a finite field F and a finite cyclic group G, there is a finite field extension
of F whose Galois group is G.
Representation
The cycle graphs of finite cyclic groups are all n-sided polygons with the elements at the
vertices. The dark vertex in the cycle graphs below stand for the identity element, and the
other vertices are the other elements of the group. A cycle consists of successive powers of
either of the elements connected to the identity element.
C1 C2 C3 C4 C5 C6 C7 C8
The rep resentation theory of the cyclic group is a critical base case for the representation
theory of more general finite groups. In the complex case, a representation of a cyclic group
d ecomposes into a direct sum of linear c haracters, making the connection between
character theory and repre sentation theory transparent. In the positive ch aracteristic case,
the indecomposable repre sentations of the cyclic group form a model and inductive basis for
the rep resentation theory of groups with cyclic Sylow subgroups and more generally the
representation theory of blocks of cyclic defect.
All subgroups and quotient groups of cyclic groups are cyclic. Specifically, all subgroups of Z
are of the form mZ, with m an integer ≥0. All of these subgroups are different, and apart from
the trivial group (for m=0) all are isomorphic to Z. The lattice of subgroups of Z is isomorphic
to the dual of the lattice of natural numbers ordered by divisibility. All factor groups of Z are
finite, except for the trivial exception Z/{0} = Z/0Z. For every positive divisor d of n, the
quotient group Z/nZ has precCSEly one subgroup of order d, the one generated by the residue
class of n/d. There are no other subgroups. The lattice of subgroups is thus isomorphic to the
set of divisors of n, ordered by divisibility. In particular, a cyclic group is simple if and only if
its order (the number of its elements) is prime.
Using the quotient group formalism, Z/nZ is a standard notation for the additive cyclic group
with n elements. In ring terminology, the s ubgroup nZ is also the ideal (n), so the quotient
can also be written Z/(n) or Z/n without abuse of notation. These alternatives do not conflict
with the notation for the p-adic integers. The last form is very common in informal
calculations; it has the additional advantage that it reads the same way that the group or ring
is often described verbally, "Zee mod en".
Endomorphisms
The endomorphism ring of the abelian group Z/nZ is isomorphic to Z/nZ itself as a ring.
Under this isomorphism, the number r corresponds to the endomorphism of Z/nZ that maps
each element to the sum of r copies of it. This is a bijection if and only if r is
coprime with n, so the automorphism group of Z/nZ is isomorphic to the unit group (Z/nZ)×
(see above).
Similarly, the endomorphism ring of the additive group Z is isomorphic to the ring Z. Its
automorphism group is iso morphic to the group of units of the ring Z, i.e. to {-1, +1} C2.
A group is called virtually cyclic if it contains a cyclic subgroup of finite index (the number
of cosets that the subgroup has). In other words, any element in a virtually cyclic group can
be arrived at by applying a member of the cyclic subgroup to a member in a certain finite set.
Every cyclic group is virtually cyclic, as is every finite group. It is known that a finitely
generated discrete group with exactly two ends is virtually cyclic
(for instance the product of Z/n and Z). Every abelian subgroup of a Gromov hyperbolic
group is virtually cyclic.
Group isomorphism
In abstract algebra, a group isomorphism is a function between two groups that sets up a
one-to-one corre spondence between the elements of the groups in a way that respects the
given group operations. If there exists an isomorphism between two groups, then the groups
are called isomorphic. From the standpoint of group theory, isomorphic groups have the
same p roperties and need not be distinguished.
Given two groups (G, *) and (H, ), a group isomorphism from (G, *) to (H, ) is a
bijective group homomorphism from G to H. Spelled out, this means that a group
i somorphism is a bijective function such that for all u and v in G it holds
that
The two groups (G, *) and (H, ) are isomorphic if an isomorphism exists. This is
written:
Often shorter and more simple notations can be used. Often there is no ambiguity about the
group operation, and it can be omitted:
Sometimes one can even simply write G = H. Whether such a notation is possible without
confusion or ambiguity depends on context. For example, the equals sign is not very suitable
when the groups are both subgroups of the same group. See also the examples.
Conversely, given a group (G, *), a set H, and a bijection , we can make H
a group (H, ) by defining
.
If H = G and = * then the bijection is an automorphism (q.v.)
In tuitively, group theorists view two iso morphic groups as follows: For every element g of a
group G, there exists an element h of H such that h 'behaves in the same way' as g (operates
with other elements of the group in the same way as g). For instance, if g generates G, then
so does h. This implies in particular that G and H are in bijective cor respondence. So the
definition of an isomorphism is quite natural.
Examples
f(x) = ex
• The group of integers (with addition) is a subgroup of , and the factor group
1
/ is is omorphic to the group S of complex numbers of absolute value 1 (with
mul tiplication):
An isomorphism is given by
for every x in .
• Generalizing this, for all odd n, Dih2n is isomorphic with the direct product of Dihn
and Z2.
• If (G, *) is an infinite cyclic group, then (G, *) is isomorphic to the integers (with the
addition operation). From an algebraic point of view, this means that the set of all
integers (with the addition operation) is the 'only' infinite cyclic group.
Some groups can be proven to be isomorphic, relying on the axiom of choice, while it is
even theoretically impossible to construct concrete isomorphisms. Examples:
• The group ( , + ) is isomorphic to the group ( , +) of all complex numbers with
addition.
• The group ( , ·)* of non-zero complex numbers with multiplication as operation is
isomorphic to the group S1 mentioned above.
Properties
• The kernel of an isomorphism from (G, *) to (H, ) , is always {eG} where eG is the
identity of the group (G, *)
• If (G, *) is a locally finite group that is isomorphic to (H, ), then (H, ) is also
locally finite.
• The previous examples illustrate that 'group properties' are always preserved by
i somorphisms.
Cyclic groups
Define
, so that . Clearly, is
bijective.
Then
Consequences
From the definition, it follows that any isomorphism will map the identity
element of G to the identity element of H,
f(eG) = eH
for all u in G, and that the inverse map is also a group isomorphism.
The relation "being isomorphic" satisfies all the axioms of an equivalence relation. If f is an
isomorphism between two groups G and H, then everything that is true about G that is only
related to the group s tructure can be translated via f into a true ditto s tatement about H, and
vice versa.
Automorphisms
An isomorphism from a group (G,*) to itself is called an automorphism of this group.
Thus it is a bijection such that
An au tomorphism always maps the identity to itself. The image under an au tomorphism of a
conjugacy class is always a conjugacy class (the same or another). The image of an element
has the same order as that element.
The composition of two automorphisms is again an automorphism, and with this operation
the set of all automorphisms of a group G, denoted by Aut(G), forms itself a group, the au
tomorphism group of G.
For all Abelian groups there is at least the automorphism that replaces the group elements by
their inverses. However, in groups where all elements are equal to their inverse this is the
trivial automorphism, e.g. in the Klein four-group. For that group all permutations of the
three non-identity elements are automorphisms, so the automorphism group is i somorphic to
S3 and Dih3.
In Zp for a prime number p, one non-identity element can be replaced by any other, with cor
responding changes in the other elements. The automorphism group is isomorphic to Z p - 1.
For example, for n = 7, multiplying all elements of Z7 by 3, modulo 7, is an automorphism of
order 6 in the automorphism group, because 36 = 1 ( modulo 7 ), while lower powers do not
give 1. Thus this automorphism generates Z6. There is one more automorphism with this
property: multiplying all elements of Z7 by 5, modulo 7. Therefore, these two correspond to
the elements 1 and 5 of Z6, in that order or conversely.
The automorphism group of Z6 is isomorphic to Z2, because only each of the two elements 1
and 5 generate Z6, so apart from the identity we can only interchange these.
For Abelian groups all automorphisms except the trivial one are called outer automorphisms.
Non-Abelian groups have a non-trivial inner automorphism group, and possibly also outer
automorphisms.
Coding theory is studied by various scientific di sciplines — such as info rmation theory,
electrical engineering, mathematics, and computer science — for the purpose of designing
efficient and reliable data transmission methods. This typically involves the removal of r
edundancy and the correction (or detection) of errors in the transmitted data. It also includes
the study of the properties of codes and their fitness for a specific application.
The first, source encoding, attempts to compress the data from a source in order to transmit it
more efficiently. This practice is found every day on the Internet where the common "Zip"
data compression is used to reduce the network load and make files smaller. The second,
channel encoding, adds extra data bits to make the transmission of
data more robust to dis turbances present on the transmission channel. The ordinary user may
not be aware of many applications using channel coding. A typical music CD uses the Reed-
Solomon code to correct for scratches and dust. In this application the transmission channel
is the CD itself. Cell phones also use coding techniques to correct
for the fading and noCSE of high frequency radio transmission. Data modems, t elephone
transmissions, and NASA all employ channel coding techniques to get the bits through, for
example the turbo code and LDPC codes.
The hamming metric:
3- bit binary cube for finding Two example distances: 100->011 has distance 3 (red
Hamming distance path); 010->111 has distance 2 (blue path)
4- bit binary h ypercube for finding Hamming distance
Two example dis tances: 0100->1001 has distance 3 (red path); 0110->1110 has distance 1
(blue path)
In information theory, the Hamming distance between two strings of equal length is the
number of positions at which the corresponding symbols are different. Put another way, it
Parity-check matrix
The rows of a parity check matrix are parity checks on the codewords of a code. That is, they
show how linear combinations of certain digits of each codeword equal zero. For example,
the parity check matrix
DEPT
specifies that for each codeword, digits 1 and 2 should sum to zero and digits 3 and 4 should
sum to zero.
The parity check matrix for a given code can be derived from its generator matrix (and vice-
versa). If the generator matrix for an [n,k]-code is in standard form
because
GHT = P - P = 0.
Negation is performed in the finite field mod q. Note that if the characteristic of the
underlying field is 2 (i.e., 1 + 1 = 0 in that field), as in binary codes, then - P = P, so the
negation is unnecessary.
Parity check
If no error occurs during transmission, then the received codeword r is identical to the t
ransmitted codeword x:
The receiver multiplies H and r to obtain the syndrome vector , which indicates
whether an error has occurred, and if so, for mul which codeword bit. Performing this
tiplication (again, entries modulo 2):
Since the syndrome z is the null vector, the receiver can conclude that no error has occurred.
This conclusion is based on the observation that when the data vector is multiplied by , a
change of basis occurs into a vector subspace that is the kernel of . As long as nothing
happens during transmission, will remain in the kernel of and the mul tiplication will yield
the null vector.
Coset
Only when H is normal will the right and left cosets of H coincide, which is one definition of
normality of a subgroup.
( �-1
A coset is a left or right coset of some subgroup in G. Since Hg = g�g Hg�), the right
cosets Hg (of H�and the left cosets g �(� Hg�(of the conjugate subgroup g-1Hg�are the
-1
) g ) )
same. Hence it is not meaningful to speak of a coset as being left or right unless one first
specifies the underlying s ubgroup.
For abelian groups or groups written additively, the notation used changes to g+H and H+g
respectively.
Examples
The additive cyclic group Z4 = {0, 1, 2, 3} = G has a subgroup H = {0, 2} (isomorphic to Z2).
The left cosets of H in G are
0 + H = {0, 2} = H
1 + H = {1, 3}
2 + H = {2, 0} = H
3 + H = {3, 1}.
There are therefore two distinct cosets, H itself, and 1 + H = 3 + H. Note that every
H in G partition G. Since Z4 is an abelian group, the right cosets will be the same as the left.
Another example of a coset comes from the theory of vector spaces. The elements
(vectors) of a vector space form an Abelian group under vector addition. It is not hard to
show that subspaces of a vector space are subgroups of this group. For a vector space V, a s
ubspace W, and a fixed vector a in V, the sets
are called affine subspaces, and are cosets (both left and right, since the group is Abelian). In
terms of geometric vectors, these affine subspaces are all the "lines" or "planes" parallel to
the subspace, which is a line or plane going through the origin.
General properties
Any two left cosets of H in G are either identical or disjoint — i.e., the left cosets form a
partition of G such that every element of G belongs to one and only one left coset.[1] In
particular the identity is in precCSEly one coset, and that coset is H itself; this is also the only
coset that is a subgroup. We can see this clearly in the above examples.
The left cosets of H in G are the equivalence classes under the equivalence relation on G
given by x ~ y if and only if x -1y �H. Similar statements are also true for right cosets.
Index of a subgroup
All left cosets and all right cosets have the same order (number of elements, or cardinality in
the case of an infinite H), equal to the order of H (because H is itself a coset). Furthermore,
the number of left cosets is equal to the number of right cosets and is
known as the index of H in G, written as [G : H�. ]Lagrange's theorem allows us to
compute the index in the case where G and H are finite, as per the formula:
This equation also holds in the case where the groups are infinite, although the meaning may
be less clear.
Cosets and normality
If H is not normal in G, then its left cosets are different from its right cosets. That is, there is
an a in G such that no element b satisfies aH = Hb. This means that the partition of G into the
left cosets of H is a different partition than the partition of G into right cosets of H. (It is
important to note that some cosets may coincide. For example, if a is in the center of G, then
aH = Ha.)
On the other hand, the subgroup N is normal if and only if gN = Ng for all g in G. In this
Lagrange's theorem, in the mat hematics of group theory, states that for any finite group G,
the order (number of elements) of every subgroup H of G divides the order of G. The
theorem is named after Joseph Lagrange.
This can be shown using the concept of left cosets of H in G. The left cosets are the
equivalence classes of a certain equivalence relation on G and therefore form a partition of G.
Specifically, x and y in G are related if and only if there exists h in H such that x = yh. If we
can show that all cosets of H have the same number of elements, then each coset of H has
precCSEly |H| elements. We are then done since the order of H times the number of cosets is
equal to the number of elements in G, thereby proving that the order H divides the order of G.
Now, if aH and bH are two left cosets of H, we can define a map f : aH → bH by setting f(x) =
ba-1x. This map is b ijective because its inverse is given by
f -1(y) = ab-1y.
This proof also shows that the quotient of the orders |G| / |H| is equal to the index [G : H]
(the number of left cosets of H in G). If we write this statement as
|G| = [G : H] · |H|,
then, seen as a statement about cardinal numbers, it is equivalent to the Axiom of choice.
an = e.
This can be used to prove Fermat's little theorem and its generalization, Euler's theorem.
These special cases were known long before the general theorem was proved.
The theorem also shows that any group of prime order is cyclic and simple.
Lagrange's theorem raCSEs the converse question as to whether every divisor of the order of a
group is the order of some subgroup. This does not hold in general: given a finite group G and
a divisor d of |G|, there does not necessarily exist a subgroup of G with order d. The smallest
example is the alternating group G = A4 which has 12 elements but no subgroup of order 6. A
CLT group is a finite group with the property that for every divisor of the order of the group,
there is a subgroup of that order. It is known that a CLT group must be solvable and that every
supersolvable group is a CLT group: however there exists solvable groups which are not CLT
and CLT groups which are not super solvable.
There are partial converses to Lagrange's theorem. For general groups, Cauchy's theorem
guarantees the existence of an element, and hence of a cyclic subgroup, of order any prime
dividing the group order; Sylow's theorem extends this to the existence of a s ubgroup of
order equal to the maximal power of any prime dividing the group order. For
s olvable groups, Hall's theorems assert the existence of a subgroup of order equal to any
unitary divisor of the group order (that is, a divisor coprime to its cofactor).
Group Co des: Deco ding wthi Coset L ead ers, Hamming Matrices
R ings a nd Mod ular Arithmetic: The Ring Structure – Definition and E xampl es, Ring P
ro pe rt ies and Sub str uctures, The I ntegers Mod ulo n
In computer science, group codes are a type of code. Group codes consist of n linear block
codes which are subgroups of Gn, where G is a finite Abelian group.
Construction
Group codes can be constructed by special generator matrices which resemble generator
matrices of linear block codes except that the elements of those matrices are endomorphisms
of the group instead of symbols from the code's alphabet. For example, consider the
generator matrix
The elements of this matrix are 2x2 matrices which are endomorphisms. In this scenario,
each codeword can be represented as where g1,...gr are the generators of
G.
In the field of coding theory, a coset leader is defined as a word of minimum weight in any
particular coset - that is, a word with the lowest amount of non-zero entries. Sometimes there
are several words of equal minimum weight in a coset, and in that case,
any one of those words may be chosen to be the coset leader.
Coset leaders are used in the construction of a standard array for a linear code, which can
then be used to decode received vectors. For a received vector y, the decoded message is y -
e, where e is the coset leader of y. Coset leaders can also be used to construct a fast decoding
strategy. For each coset leader u we calculate the syndrome uH′. When we receive v we
evaluate vH′ and find the matching syndrome. The corresponding coset leader is the most
likely error pattern and we assume that v+u was the codeword sent.
Example
1. The first row lists all codewords (with the 0 codeword on the extreme left)
2. Each row is a coset with the coset leader in the first column
3. The entry in the i-th row and j-th column is the sum of the i-th coset leader and the j-
th codeword.
For example, the [n,k]-code C3 = {0, 01101, 10110, 11011} has a standard array as follows:
Because each possible vector can appear only once in a standard array some care must be
taken during cons truction. A s tandard array can be created as follows:
Hamming matrices
Hamming codes can be computed in linear algebra terms through matrices because Hamming
codes are linear codes. For the purposes of Hamming codes, two Hamming matrices can be
defined: the code generator matrix and the parity-check matrix
:
and
As mentioned above, rows 1, 2, & 4 of should look familiar as they map the data bits
to their parity bits:
The remaining rows (3, 5, 6, 7) map the data to their position in encoded form and there is
only 1 in that row so it is an identical copy. In fact, these four rows are linearly independent
and form the identity matrix (by design, not coincidence).
Also as mentioned above, the three rows of should be familiar. These rows are used to
compute the syndrome vector at the receiving end and if the s yndrome vector is the null
vector (all zeros) then the received word is error-free; if non-zero then the value indicates
which bit has been flipped.
The 4 data bits — assembled as a vector — is pre-multiplied by (i.e., ) and taken modulo 2 to
yield the encoded value that is transmitted. The original 4 data bits are converted to 7 bits
(hence the name "Hamming(7,4)") with 3 parity bits added to ensure even parity using the
above data bit coverages. The first table above shows the mapping between each data and
parity bit into its final bit position (1 through 7) but this can also be presented in a Venn
diagram. The first diagram in this article shows three circles (one for each parity bit) and
encloses data bits that each parity bit covers. The second diagram (shown to the right) is
identical but, instead, the bit positions are marked.
For the remainder of this section, the following 4 bits (shown as a column vector) will be
used as a running example:
Ring theory
In mathematics, ring theory is the study of rings— algebraic s tructures in which addition
and multiplication are defined and have similar properties to those familiar from the integers.
Ring theory studies the structure of rings, their representations, or, in different language,
modules, special classes of rings (group rings, division rings, universal enveloping algebras),
as well as an array of properties that proved to be of interest both within the theory itself and
for its applications, such as homological properties and pol ynomial identities.
Commutative rings are much better understood than noncommutative ones. Due to its
intimate connections with algebraic geometry and algebraic number theory, which provide
many natural examples of co mmutative rings, their theory, which is considered to
be part of commutative algebra and field theory rather than of general ring theory, is quite
different in flavour from the theory of their nonco mmutative counterparts. A fairly recent
trend, started in the 1980s with the development of noncommutative geometry and with the
discovery of quantum groups, attempts to turn the situation around and build the theory of
certain classes of noncom mutative rings in a geometric fashion as if they were rings of
functions on (non-existent) 'noncommutative spaces'.
Elementary introduction
Definition
Formally, a ring is an Abelian group (R, +), together with a second binary operation * such
that for all a, b and c in R,
a * (b * c) = (a * b) * c
a * (b + c) = (a * b) + (a * c)
(a + b) * c = (a * c) + (b * c)
also, if there exists a mult iplicative identity in the ring, that is, an element e such that for all
a in R,
a*e=e*a=a
then it is said to be a ring with unity. The number 1 is a common example of a unity.
The ring in which e is equal to the additive identity must have only one element. This ring is
called the trivial ring.
Rings that sit inside other rings are called subrings. Maps between rings which respect the ring
operations are called ring homomorphisms. Rings, together with ring homomorphisms, form a
category (the category of rings). Closely related is the notion of ideals, certain subsets of rings
which arCSE as kernels of homomorphisms and can serve to define factor rings. Basic facts
about ideals, homomorphisms and factor rings are recorded in the i somorphism theorems and
in the Chinese remainder theorem.
Non-commutative rings resemble rings of matrices in many respects. Following the model of
algebraic geometry, attempts have been made recently at defining non-commutative
geometry based on non-commutative rings. Non-commutative rings and associative algebras
(rings that are also vector spaces) are often studied via their categories of modules. A module
over a ring is an Abelian group that the ring acts on as a ring of endomorphisms, very much
akin to the way fields (integral domains in which every non-zero element is invertible) act on
vector spaces. Examples of non- commutative
rings are given by rings of square matrices or more generally by rings of endomorphisms of
Abelian groups or modules, and by monoid rings.
if their dif ference a - b is an integer multiple of n. The number n is called the modulus of the
co ngruence. An equivalent definition is that both numbers have the same remainder when
divided by n.
For example,
because 38 - 14 = 24, which is a multiple of 12. For positive n and non-negative a and b,
congruence of a and b can also be thought of as asserting that these two numbers have the
same remainder after dividing by the modulus n. So,
because both numbers, when divided by 12, have the same remainder (2). E quivalently, the
fractional parts of doing a full division of each of the numbers by 12 are the same: 0.1666...
(38/12 = 3.1666..., 2/12 = 0.1666...). From the prior definition we also see that their
difference, a - b = 36, is a whole number (integer) multiple of 12 (n = 12, 36/12 = 3).
A remark on the notation: Because it is common to consider several congruence relations for
different moduli at the same time, the modulus is incorporated in the notation. In spite
of the ternary notation, the congruence relation for a given modulus is binary. This would
have been clearer if the notation a ≡n b had been used, instead of the common traditional
notation.
The properties that make this relation a congruence relation (respecting addition, s
ubtraction, and mult iplication) are the following.
If
and
then:
•
•
•
Multiplicative group of integers modulo n
In modular arithmetic the set of congruence classes relatively prime to the modulus n form a
group under multiplication called the multiplicative group of integers modulo n. It is also
called the group of primitive residue classes modulo n. In the theory of rings, a branch of
abstract algebra, it is described as the group of units of the ring of integers modulo n. (Units
refers to elements with a multiplicative inverse.)
Group axioms
It is a straightforward exercCSE to show that under multiplication the congruence classes (mod
n) which are relatively prime to n satisfy the axioms for an abelian group.
Because a ≡ b (mod n) implies that gcd(a, n) = gcd(b, n), the notion of congruence classes
(mod n) which are relatively prime to n is well- defined.
Since gcd(a, n) = 1 and gcd(b, n) = 1 implies gcd(ab, n) = 1 the set of classes relatively
prime to n is closed under multiplication.
The natural mapping from the integers to the congruence classes (mod n) that takes an
integer to its congruence class (mod n) is a ring homomorphism. This implies that the class
containing 1 is the unique multiplicative identity, and also the associative and commutative
laws.
Notation
The ring of integers (mod n) is denoted or (i.e., the ring of integers modulo the ideal
nZ = (n) consisting of the multiples of n) or by . Depending on the
author its group of units may be written (for
German Einheit = unit) or similar notations. This article uses
111
Structure
Powers of 2
Modulo 2 there is only one relatively prime congruence class, 1, so is
trivial.
Modulo 8 there are four relatively prime classes, 1, 3, 5 and 7. The square of each of
these is 1, so the Klein four-group.
Modulo 16 there are eight relatively prime classes 1, 3, 5, 7, 9, 11, 13 and 15.
is the 2-torsion subgroup (ie. the square of each element is 1),
so is not cyclic. The powers of 3, {1,3,9,11} are a subgroup of order 4, as are
the powers of 5, {1,5,9,13}. Thus
The pattern shown by 8 and 16 holds[1] for higher powers 2k, k > 2:
is the 2-torsion subgroup (so is not cyclic)
112
Similarly, the group of units is the direct p roduct of the groups corresponding
to each of the prime power factors:
Order
Exponent
The exponent is given by the Carmichael function λ(n), the least common multiple of the
orders of the cyclic groups. This means that if a and n are relatively prime,
Generators
Since all the n = 1, 2, ..., 7 are cyclic, another way to state this is: If n < 8
then has a primitive root. If n ≥ 8 has a primitive root unless n is
divisible by 4 or by two distinct odd primes.
In the general case there is one generator for each cyclic direct factor.
Table
This table shows the structure and generators of for small values of n. The
generators are not unique (mod n); e.g. (mod 16) both {-1, 3} and {-1, 5} will work. The
generators are listed in the same order as the direct factors.
For example take n = 20. means that the order of is 8 (i.e. there are 8 numbers less than 20
and coprime to it); λ(20) = 4 that the fourth power of any number relatively prime to 20 is ≡ 1
(mod 20); and as for the generators, 19 has order 2, 3
has order 4, and every member of is of the form 19a × 3b, where a is 0 or 1
and b is 0, 1, 2, or 3.
The powers of 19 are {±1} and the powers of 3 are {3, 9, 7, 1}. The latter and their negatives
(mod 20), {17, 11, 13, 19} are all the numbers less than 20 and prime to it. The fact that the
order of 19 is 2 and the order of 3 is 4 implies that the fourth power of every
member of is ≡ 1 (mod 20).