0% found this document useful (0 votes)
1 views

Relations and Functions Summary

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

Relations and Functions Summary

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

RELATIONS, FUNCTIONS AND COUNTING PROBLEMS

1 Relations

Definition 1 A relation is a set of ordered pairs

Example 1 The follows are relations

a) “Less than” = {(1,2), (3,4), (5,6),. . . }

b) “Greater than” = {(2.1,2), (5.3,4.5), (5.1,2.0),. . . }

c) “equal to” = {(1,1), (2,2), (3,3),. . . }

> If R is a relation, pair (x, y) ∈ R can be written as xRy or “x is related


to y by the relation R”

Exercise 1 Write the following relations on the set {1, 2, 3, 4, 5} as sets of


ordered pairs.

a) The is-less-than relation.


b) The is-divisible-by relation.
c) The is-equal-to relation.
d) The has-the-same-parity-as relation.

Definition 2 Let R be a relation and let A and B be sets. We say R is a


relation on A Iff R ⊆ A × A, and we say R is a relation from A to B Iff
R⊆A×B

Example 2 Let A={1,2,3}, B={4,5,6,7}

a) R= {(1,1), (2,2), (3,3)} on A


b) S= {(1,4), (2,6), (3,5)} A→B
c) T= {(5,4), (7,6), (6,5),(7,5)} on B
d) X= {(5,9), (8,6)} not A→B / B→A

1
1.1 Inverse relations

Definition 3 Let R be a relation. The inverse of R, denoted R−1 , is the


relation formed by reversing the order of all the ordered pairs in R.
R−1 = {(x, y) : (y, x) ∈ R}
> : (R−1 )−1 = R

Example 3 Let S = {(1, 4), (2, 6), (3, 5)}

S −1 = {(4, 1), (6, 2), (5, 3)}

1.2 Properties of relations

Definition 4 Let R be a relation on A

i) If ∀x ∈ A ⇒ xRx, we call R reflexive

ii) If ∀x ∈ A ⇒ xRx, we call R irreflexive

iii) If ∀x, y ∈ A, xRy ⇒ yRx, we call R symmetric

iv) If ∀x, y ∈ A, (xRy ∧ yRx) ⇒ x = y, we call R antisymmetric

v) If ∀x, y, z ∈ A, (xRy ∧ yRz) ⇒ xRz, we call R transitive

Example 4 Let’s consider the relation = (equality) on the integers Z.

a) Is the relation “=” reflexive? 3

b) Is the relation “=” irreflexive? 7

c) Is the relation “=” symmetric? 3

d) Is the relation “=” antisymmetric? 3

e) Is the relation “=” transitive? 3

1.3 Equivalence relations

Definition 5 Let R be a relation on a set A. We say R is an equivalence


relation Iff it is reflexive, symmetric and transitive.

2
Definition 6 Let n be a positive integer. We say x and y are congruent
modulo n, and write x ≡ y(mod n), provided n|(x − y) (or x − y is a multiple
of n)
> Denote “≡” as “is congruent to mod n”

Example 5 a) 3 ≡ 23(mod 5), because 3-23=-20 is divisible by 5


b) 9 6≡ 3(mod 5), because 9-3=6 is not a multiple of 5

≡ is an equivalence relation?

Theorem 1 Let n be a positive integer. The is-congruent-to-mod-n relation


is an equivalence relation on the set of integers

Proof : “is-congruent-to-mod-n” is an equivalence relation

(i) is reflexive?
.
∀x ∈ Z, since x − x = 0..0 ⇒ x ≡ x(mod n).
(ii) is symmetric?
∀x, y ∈ Z, and x ≡ y(mod n) ⇒ x − y = kn ⇒ y − x = (−k)n ⇒ y ≡
x(mod n).
(iii) is transitive? (
x ≡ y(mod n)
∀x, y, z ∈ Z, suppose ⇒ x−y = kn and y −z = mn ⇒
y ≡ z(mon n)
x − z = (k + m)n ⇒ x ≡ z(mod n).

1.4 Equivalence class

Definition 7 Let R be an equivalence on a set A and let a ∈ A. The equiv-


alence class of a, denoted [a], is the set of all elements of A related by R to
a; that is:
[a] = {x ∈ A : xRa}

Propositions 1 Let R be an equivalence relation on a set A

a) Any a ∈ A, then a ∈ [a]


b) Any a, b ∈ A, then aRb iff [a] = [b]
c) Any a, x, y ∈ A. If x, y ∈ [a] then xRy
d) Suppose [a] ∩ [b] 6= ∅. Then [a] = [b]

3
Example 6 Find the requested equivalence class:

a. R = {(1, 1), (1, 2), (2, 1), (2, 2), (3, 3), (4, 4)} on {1, 2, 3, 4}.
Find [1]?

b. R = “has-the-same-birthday-as” (only days and months) on people.


Find [you]?

Corollary 1 Let R be an equivalence relation on a set A. The equivalence


classes of R are nonempty, pairwise disjoint of A whose union is A

Example 7 How many different classes are there?

a. Let R be “is-congruent-to-mod-5 ” on Z.

b. Let R be “has-the-same-birthday-as” on set of days and months.

1.5 Partitions

Definition 8 Let A be a set. A partition on A is a set of nonempty, pairwise


disjoint sets whose union is A

P1

P3

P2
P4 P5

> Elements of a partition are called parts

Example 8 Find all possible partitions of {1,2,3}?

2 1 2 1
3 3

4
2 1 2 1 2 1
3 3 3

How can you partition people in the World?


• live in the same city
• live in the same country
• have the same birth month
• have the same age
• ...

Question: What is the relationship between partition and equivalence re-


lation?

1.6 Partition and equivalence relation

Propositions 2 Suppose R is a relation on set A.

i) If R be an equivalence relation, then all the equivalence classes of R form


a partition of A.

ii) If P is a partition on A, we define a relation:


P
a ≡ b ⇔ ∃P ∈ P|a, b ∈ P,
or
P
≡ is is-the-same-part-as relation
P
The relation ≡ is an equivalence relation on A. The equivalence classes
P
of ≡ are exactly the parts of P.

Example 9 How many possible equivalence relations are there on set {1,2,3,4}?

2 Functions

Definition 9 A relation f is called a function iff (a, b) ∈ f , and (a, c) ∈ f


imply b = c.

> Pair (a,b) is unique in function f for each a.

Example 10 Which relation is function?

5
a) f = {(1, 2), (3, 4), (5, 6), (6, 7)}
⇒ is a function
b) g = {(1, 2), (1, 3), (3, 2)}
⇒ is not a function

2.1 Function notations

Definition 10 Let f be a function, let a be an object. The notation f (a) is


defined provided there exists an object b such that (a, b) ∈ f . In this case,
f (a) equals b. Otherwise, there is no ordered pair of the form (a, _) ∈ f , the
notation f (a) is undefined.

Example 11
f ={(1, 1), (2, 3), (3, 4)}
⇔{f (1) = 1, f (2) = 3, f (3) = 4, f (4) is undef ined, . . .}

Some ways to express functions

• as a set of pairs
f = {(1, 2), (2, 3), (5, 6)}

• as a chart

x f(x)
..
.
3 4
4 5
5 6
6 7
..
.
• Express function as a map

x1 y1
y2
x2

x3 y3

x4 y4
x5 y5

6
• Express function as a set-builder notation
f = {(x, y) : x, y ∈ Z, y = x2 }

2.2 Domain, image of functions


Definition 11 Let f be a function

i) The set of all possible first elements of the ordered pairs in f is called the
domain of f , denoted dom(f )

dom(f ) = {a : ∃b, (a, b) ∈ f }


ii) The set of all possible second elements of the ordered pairs in f is called
the image of f , denoted im(f )
im(f ) = {b : ∃a, (a, b) ∈ f }

Example 12 Find image and domain of the following functions

a) f = {(1, 2), (2, 3), (5, 6)}


⇒ dom(f ) = {1, 2, 5}, im(f ) = {2, 3, 6}

b) f = {(x, y) : x, y ∈ Z, y = x2 }
⇒ dom(f ) = Z, im(f ) = {0, 1, 4, . . . , n2 , . . .}

2.3 One-to-one/onto/bijection functions

Definition 12 Suppose f is a function from set A to set B.

i) A function f is called one-to-one provided that, whenever (x, b), (y, b) ∈


f , we must have x = y.

ii) A function f is called onto provided that, for every b ∈ B there is an


a ∈ A so that f (a) = b.

iii) Let f be a function, f is called a bijection iff it is both one-to-one and


onto.

Example 13 Let A be the set of odd integers, B be the set of even integers.
The function f : A → B, defined by f (x) = x + 1

• f is one-to-one?
• f is onto?

7
Properties 1 Let f : A → B be a function.

i) The inverse relation f −1 is a function iff f is one-to-one.


ii) f is onto B iff im(f ) = B.
iii) The inverse relation f −1 is a function from B to A iff f is one-to-one
and onto B.

Example 14 For each of the following, determine whether the function is


one-to-one, onto, or both. Prove your assertions

a) f : Z → Z, f (x) = 2x
b) f : Z → Z, f (x) = x + 10
c) f : N → N, f (x) = x + 10
d) f : N → N defined by
(
x/2 if x is even
f (x) =
(x − 1)/2 if x is odd

2.4 Composition

Definition 13 Let A, B, and C be sets and let f : A → B and g : B → C.


Composition of g and f , denoted g ◦ f , defined by
(g ◦ f )(a) = g[f (a)]

Example 15 Let f : Z → Z by f (x) = x2 +1 and g : Z → Z by g(x) = 2x−3.


What is g ◦ f (x)?

Propositions 3 1. f −1 ◦ f 6= f ◦ f −1

2. If f : A → B is bijection then

• (f −1 ◦ f )(a) = a, ∀a ∈ A

• (f ◦ f −1 )(b) = b, ∀b ∈ B

3 Collections: Lists and Sets

Definition 14 A list is an ordered sequence of objects

> All the list objects are enclosed in round brackets ( ).

8
Example 16 The follows are lists

(i) S=(0,1,2,3)
(ii) T=(-2,3,2,3,4)

Definition 15 A set is a repetition-free, unordered collection of objects

> All the set objects are enclosed in curly braces { }.

Example 17 The follows are sets

(i) S={0,1,2,3}
(ii) T={3,2,4}
(iii) U = {x ∈ N : x ≤ 20 and 6|x}
(6|x means 6 is a divisor of x)

> List and set differences:

List Set
Object order 3 neglect
Object repetition 3 neglect

Example 18 Notice that

a) (0,1,2), (0,2,1) and (0,1,2,1) are pairwise different.


b) {0,1,2}, {0,2,1} and {0,1,2,1} are the same.

3.1 List and Set Size

(i) Let A be a list (or set). |A| is denoted as the number of list (or set)
elements.
(ii) If A is a list, |A| is called the length of A.
(iii) If A is a set, |A| is called the cardinality of A.
(iv) ( )-empty list, ∅ - empty set.

Example 19 We have

a) S = {0, 1, 2, 3} ⇒ |S| = 4
b) T = {3, 2, 4} ⇒ |T | = 3

9
3.2 Equality of lists, sets

(i) For two lists L1 , L2


(
length of L1 = length of L2
L1 = L2 ⇔
L1 [i] = L2 [i], ∀i = 1, 2, . . .

(ii) For two sets S1 , S2


(
∀x ∈ S1 ⇒ x ∈ S2
S1 = S2 ⇔
∀x ∈ S2 ⇒ x ∈ S1

3.3 Counting List

Problem 1 Suppose we wish to make a two-element list where the entries in


the list may be any in the set S={1, 2, 3, . . . ,n}.

(i) How many such lists are possible?


(ii) In addition, the two numbers on the list must be different. How many
such lists are possible?
(iii) In general, to make k-element lists where the entries in the list are in S
and pairwise different. How many such lists are possible?

Problem 2 Suppose we wish to make a two-element list where the entries in


the list may be any in theset S={1, 2, 3, . . . ,n}.

1) How many such lists are possible?


n2

2) In addition, the two numbers on the list must be different. How many
such lists are possible?
n2 − n = n(n − 1)

3) In general, to make k-element lists where the entries in the list are in S
and pairwise different. How many such lists are possible?
n(n − 1)(n − 2) . . . (n − k + 1) denoted as (n)k

3.4 Subsets

Definition 16 Suppose A and B are sets. We say that A is a subset of B


provided every element of A is also an element of B. The notation A ⊂ B
means A is a subset of B.

10
> Notes:

(i) A ⊃ B ⇔ B ⊂ A
(ii) ∅ ⊂ A, ∀A
(iii) A ⊆ B means A is a subset or equal to B.

Example 20 We have

(i) {2, 3} ⊂ {0, 1, 2, 3}


(ii) {2n : n ∈ N} ⊂ N

3.5 Counting subsets

Problem 3 How many subsets does A = {1, 2, 3} have?

Answer: 8 subsets of A
∅, {1}, {2}, {3}, {1,2}, {1,3}, {2,3}, {1,2,3}

Theorem 2 Let A be a finite set. The number of subsets of A is 2|A|

> Notes:

(i) We denote 2A as the set of all subsets of A.


(ii) |2A | = 2|A|

3.6 Exercise 2

Suppose there are 62 students in discrete maths class. We have to send a


team with at least one student to join a sport event.

(a) How many ways to choose such group are possible?


(b) Suppose all the students are taking part in running or swimming. In the
list of running attendees, we have 45 students of the class and 35 students
in the list of swimming attendees. How many students are taking part in
both running and swimming?

Example 21 Let A be {1,2,3,4,5}.

a) How many subsets of A are possible?


b) How many non-empty subsets of A are possible?

11
c) How many 4-element subsets of A are possible?

Theorem 3 Let A be an n-element set. The number of k-element subsets of


n!
A is C(n, k) = .
(n − k)!.k!

3.7 Counting classes/parts

Problem 4 In how many ways

(i) can the letters in the word “WORD” be rearranged?


(ii) can the letters in the word “DISCRETE ” be rearranged?

Theorem 4 Let R be an equivalence relation on a finite set A. If all the


equivalence classes of R have the same size, m, then the number of equivalence
classes is |A|/m.

Example 22 How many different rearrangements (including nonsensical words


that are called anagrams) can be made from SUCCESS?

Solution:

(i) Let S be the set of all rearrangements of all letters of SUCCESS ⇒


|S| = 7!
(ii) Define “is-the-same-rearrangement-as” as a relation R on S.
|S| 7!
(iii) #anagrams = =
an equivalence class size 3!.2!

3.8 Multisets

Definition 17 A multiset is an unordered collection of objects with repeti-


tion.

> All the set objects are enclosed in angle braces <,>.

Example 23 We have

a) S=<1,2,3>
b) T=<1,2,2,3,3,3>
c) V=<1,1,1,2,3>

12
Definition 18 (1) The cardinality of a multiset is the sum of multiplicities
of its elements.

S=<1,1,2,2,2,3,3> ⇒ |S| = 7

(2) Two multisets are said the same Iff they contain the same elements with
the same multiplicities.
(i) < 1, 1, 2, 3 >=< 1, 2, 3, 1 >
(ii) < 1, 2, 3, 3 >6=< 1, 2, 2, 3 >

3.9 Counting multisets

Problem 5 How many multisets with cardinality equal to k whose elements


belong to an n-element set such as {1,2,. . . ,n}?

Example 24 All the multisets with size 2 we can form from the elements in
{1,2,3} are:

<1,1>, <1,2>, <1,3>, <2,2>, <2,3>, <3,3>

Suppose a multiset of size k with elements drawn from {1,2,3,. . . ,n}, ei is


the i’s multiplicity. We have two correspondences:

f
< 1, . . . , 1, 2, . . . , 2, . . . , n, . . . , n > ←→e1 + e2 + . . . + en = k
| {z } | {z } | {z }
e1 e2 en

g
e1 + e2 + . . . + en = k ←→ ∗, . . . , ∗ | ∗, . . . , ∗ | . . . | ∗, . . . , ∗
| {z } | {z } | {z }
e1 e2 en
(n − 1) − bars and k − stars
> f and g are one-to-one correspondences.

Definition 19 Let n, k ∈ N. The symbol ( nk ) denotes the number of multisets




with cardinality equal to k whose elements belong to an n-element set such as


{1,2,. . . ,n}.

Example 25 We can calculate

(a) ( n1 ) =n


(b) ( 23 ) =4


(c) ( k1 )=1


13
n!
Properties 2 (i) ( nk ) = n+k−1 n
  
k , where k =
k!(n − k)!
(ii) ( nk )=( n−1 n
  
k )+( k−1 )

(iii) Let n be a positive integer and let k be a nonnegative integer. The equation
e1 + e2 + . . . + en = k
has ( nk ) solutions for which e1 , e2 , . . . , en are nonnegative integers.


Counting list and set summary


Let S be a set with n elements.

(1) How many subsets of S are possible?


(2) How many k-element lists are possible where
(i) element repetition is not allowed?
(ii) element repetition is allowed?
(3) How many k-element subsets of S are possible where
(i) element repetition is not allowed?
(ii) element repetition is allowed?

4 Counting functions

Problem 6 Let A and B be finite sets. How many functions from A to B?

Suppose A = {1, 2, . . . , a} and B = {1, 2, . . . , b}. A function f : A −→ B,


then f can be written as
f = {(1, ∗), (2, ∗), . . . , (a, ∗)}, where ∗ ∈ B
.

(i) How many choices for ∗ entries?


(ii) How many f ’s are one-to-one?
(iii) How many f ’s are onto?

14
4.1 Pigeonhole principle

Let A and B be finite sets and let f : A → B.

(i) If |A| > |B|, then f is not one-to-one


(ii) If |A| < |B|, then f is not onto

Example 26 How many functions from {1, 2, 3} to {a, b} are possible where

(i) they are one-to-one?


(ii) they are onto?

4.2 Theorem of counting functions

Theorem 5 Let A and B be finite sets with |A| = a and |B| = b

(i) The number of functions from A to B is ba


(ii) If a ≤ b, the number of one-to-one functions f : A → B is
b!
(b)a = b(b − 1) . . . (b − a + 1) =
(b − a)!
If a > b, the number of functions is zero.
(iii) If a ≥ b, The number of onto functions f : A → B is
b  
j b
X
(−1) (b − j)a
j=0
j

(iv) If a = b, the number of bijiection functions f : A → B is a!. If a 6= b, the


number of such functions is zero.

Example 27 Given 5 distinct lattice points in the plane, at least one of the
line segments determined by these points has a lattice point as its midpoint.

4.3 Permutations

Definition 20 Let A be a set. A permutation on A is a bijection from A to


itself.

Example 28 Let A = {1, 2, 3, 4, 5} and f : A → A by f = {(1, 2), (2, 4), (3, 5), (4, 3), (5, 1)
is a permutation on A

15
> f is expressed in a matrix:
 
1 2 3 4 5
f=
2 4 5 3 1

Properties 3 Let Sn be the set of all permutations on {1, 2, . . . , n}.

(i) |Sn | = n!
(ii) ∀π, σ ∈ Sn , π ◦ σ ∈ Sn
(iii) ∀π ∈ Sn , π −1 ∈ Sn and π ◦ π −1 = ι where ι(i) = i ∀i = 1, 2, . . . , n

4.4 Cycle notation

Definition 21 Let π ∈ Sn , a cycle by π is a sequence written as (x1 , x2 , . . . , xk )


where x0i s are pairwise different in {1, 2, . . . , n} and xi+1 = π(xi ), π(xn ) = x1
 
1 2 3 4 5
Example 29 Let π =
1 3 4 5 2
Find cycles of π?
π has two cycle: (1) and (2,3,4,5)

> π is expressed by using cycle notation as


π = (1)(2, 3, 4, 5)
or
π = (2, 3, 4, 5)
Composition symbol ◦ is omitted.

4.5 Transposition

Definition 22 A permutation τ ∈ Sn is called a transposition provided τ has


only a cycle of the form (i, j), where 1 ≤ i < j ≤ n

1 2 3 4 5
Example 30 π = , ⇒ π = (1, 2) is a transposition
2 1 3 4 5

Properties 4 If τ ∈ Sn is a transposition, then τ ◦ τ = ι and τ = τ −1

4.6 Permutation decomposition

Theorem 6 Let π be any permutation on a finite set. Then π can be ex-


pressed as the composition of transpositions defined on that set.

16
 
1 2 3 4 5
Example 31 Let σ =
4 5 2 3 1
σ = (1, 4, 3, 2, 5)
= (1, 5) ◦ (1, 2) ◦ (1, 3) ◦ (1, 4)

or σ = (1, 4) ◦ (4, 3) ◦ (2, 3) ◦ (2, 5)


any way else?

Properties 5 Let π be any permutation on a finite set and π is decomposed


into transpositions as
π = τ1 ◦ τ2 ◦ . . . ◦ τa

(i) π −1 = τa ◦ τa−1 ◦ . . . ◦ τ1
(ii) If π is decomposed by another way such as
π = σ1 ◦ σ2 ◦ . . . ◦ σb ,
then a and b have the same parity.

Definition 23 Let π be a permutation on a finite set.

i) π is called even provided it can be written as the composition of an even


number of transpositions.
ii) π is called odd provided it can be written as the composition of an odd
number of transpositions.

Example 32 Let
 
1 2 3 4 5
σ=
4 5 3 2 1
Is σ even or odd?

4.7 Exercises

1. For each of the following relations defined on the set {1, 2, 3, 4, 5}, de-
termine whether the relation is reflexive, irreflexive, symmetric, antisym-
metric, and/or transitive.
a) R = {(1, 1), (2, 2), (3, 3), (4, 4), (5, 5)}
b) R = {(1, 2), (2, 3), (3, 4), (4, 5)}
c) R = {(1, 1), (1, 2), (1, 3), (1, 4), (1, 5)}
d) R = {(1, 1), (1, 2), (2, 1), (3, 4), (4, 3)}

17
e) R = {1, 2, 3, 4, 5} × {1, 2, 3, 4, 5}
2. For each of the following relations on the set of human beings, please
determine whether the relation is reflexive, irreflexive, symmetric, anti-
symmetric, and/or transitive.
a) has-the-same-last-name-as.
b) is-the-child-of.
c) has-the-same-parents-as (i.e., same mother and father)
d) is-married-to.
e) is-an-ancestor-of.
.
f) R = {(a, b)|a, b ∈ N, a|b} >(a|b ⇔ b..a)
.
g) R = {(a, b)|a, b ∈ Z, a − b..10}
3. Let us say that two integers are near one another provided the absolute
value of their difference is 2 or smaller (i.e., the numbers are at most 2
apart). For example, 3 is near to 5, 10 is near to 9, but 8 is not near to
4. Let R stand for this is-near-to relation. Please do the following:
a) Write down R as a set of ordered pairs. Your answer should look like
this:
R = {(x, y) : . . .}
b) Prove or disprove: R is reflexive.
c) Prove or disprove: R is irreflexive.
d) Prove or disprove: R is symmetric.
e) Prove or disprove: R is antisymmetric.
f) Prove or disprove: R is transitive.
4. For each of the following relations, find R−1 .
a) R = {(1, 2), (2, 3), (3, 4)}
b) R = {(1, 1), (2, 1), (3, 1)}
c) R = {(x, y) : x, y ∈ Z, x − y = 1}
d) R = {(x, y) : x, y ∈ N, x|y}
e) R = {(x, y) : x, y ∈ Z, xy > 0}
5. Which of the following are equivalence relations?
a. R = {(1, 2), (2, 3), (3, 1)} on set {1,2,3}.
b. | on Z (a|b ⇔ b is divisible by a).
c. ≤ on Z.

18
d. “Is-an-anagram-of” on the set of English words. (For example, STOP
is an anagram of POTS because we can form one from the other by
rearranging its letters.)
6. For each of the following equivalence relations, determine the number of
equivalence classes that relation has.
a. Congruence modulo 7 (for the integers).
b. Lives-in-the-same-province-as (for residents of Vietnam).
7. Write out all the possible two-letter “words” one can make using only the
vowels A, E, I, O, and U. How many of these have no repeated letter?
8. Airports have names, but they also have three-letter codes. E.g., the
Hanoi airport code is HAN, and the code FRA is for the Frankfurt airport
in Germany. How many different airport codes are possible?
9. A bit string is a list of 0s and 1s. How many length-k bit strings can be
made?
10. How many different anagrams (including nonsensical words) can be made
from each of the following?
1) DISCRETE
2) MATHEMATICS
3) INFORMATICS
11. Twelve people join hands for a circle dance. In how many ways can they
do this?
12. You wish to make a necklace with 20 different beads. In how many dif-
ferent ways can you do this?
13. One hundred people are to be divided into ten discussion groups with
ten people in each group. In how many ways can this be done?
14. Let A ={1,2,. . . , 100}. How many 10-element subsets of A consist of only
odd numbers?
15. How many partitions, with exactly two parts, can be made of the set
{1,2,3,4}?
Answer the same question for the set {1,2,3,. . . ,n}.
16. Let A be a 100-element set. Which is greater: the number of partitions
of A into 20 parts of size 5 or the number of partitions of A into 5 parts
of size 20?

19
17. Ten married couples are seated around a large circular table. In how
many different ways can they do this, assuming husbands and wives sit
next to one another? Please note that if everyone moves one (or more)
places to the left, the arrangement is not considered to be different.
18. Let A be the set {1,2,3,4,5}.
a) How many ways to partition A into two parts are possible?
b) How many ways to partition A into three parts are possible?
c) How many ways to partition A into four parts are possible?
d) How many possible equivalence relations are there on set A?
19. What multiset is encoded by the stars-and-bars notation *|||***?
20. Please calculate
a) ( 24 )


b) ( 53 )


21. Let n and k be positive integers. Consider this equation:


x1 + x2 + . . . + xn = k
a) How many solutions are there if the variables xi must be nonnegative
integers?
b) How many solutions are there if the variables xi must be positive
integers?
c) How many solutions are there if the variables xi may only take the
values 0 or 1?
22. Let n ∈ N. Then there exist positive integers a and b, with a 6= b, such
as na − nb is divisible by 10.
23. In a meeting of n members, know that anyone shakes hand with at least
one other person. Prove that there exist two people who have the same
number of hand shakes with others in the meeting.
24. Let f = {(1, 2), (2, 3), (3, 4)} and g = {(2, 1), (3, 1), (4, 2)} be functions.
Please answer the following:
a) What is f(2)?
b) What is f(4)?
c) What is dom(f)?
d) What is im(f)?
e) What is f −1 (1)?
f) Prove that g −1 is not a function.

20
g) What is g ◦ f ?
h) What is f ◦ g?
25. Let A={1,2,3,4} and B= {1,2,3}.
a) How many one-to-one functions from A to B are possible?
b) How many onto functions from A to B are possible?
c) How many function f from A to B are possible where f (1) ≥ 1?
26. Let A={1,2,3,4} and B= {1,2,3,4}.
a) How many functions from A to B are possible?
b) How many one-to-one functions from A to B are possible?
c) How many function f from A to B are possible where f(1) is even?
27. Let f and g be permutations on set {1,2,3,4,5,6}, they are defined as
follows:
   
1 2 3 4 5 6 1 2 3 4 5 6
f= g=
4 1 3 2 6 5 6 2 4 3 5 1
Decompose f into transpositions.
a) Find f −1 and g −1 .
b) Calculate f ◦ g and g ◦ f
c) Express f and g by using cycle notation.
d) Decompose f and g into transpositions.
e) Are f and g even or odd?

21

You might also like