Lecture 19: Modular numbers

Congruence mod m

Equivalence classes

Given any equivalence relation  ∼  on a set A, can break A up into several groups of interrelated elements.

Definition: if x ∈ A, then the equivalence class of x (written [x] ∼ ) is the set of all elements of A that are related to x. If  ∼  is clear from context I will often omit it and just write [x].

The set of all equivalence classes of elements of A is written A /  ∼  and is pronounced "A mod  ∼ ".

Examples:

Modular numbers

We used the notion of equivalence classes to define the "modular numbers". The set of integers mod m (written Zm) is the set of all integers modulo the "congruent mod m" relation.

Example: - Z5 = {[0], [1], [2], [3], [4]} - Z3 = {[0], [1], [2]} = {{…, 6,  − 3, 0, 3, 6, 9, …}, {…,  − 5,  − 2, 1, 4, 7, …}, {…,  − 4,  − 1, 2, 5, 8, …}}

In general, Zm has m elements.

In future lectures, we will discuss how to add, multiply, exponentiate and divide equivalence classes.