Download Z/mZ AS A NUMBER SYSTEM As useful as the congruence notation

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Birkhoff's representation theorem wikipedia , lookup

Quadratic equation wikipedia , lookup

Cubic function wikipedia , lookup

Elementary algebra wikipedia , lookup

Quartic function wikipedia , lookup

Factorization of polynomials over finite fields wikipedia , lookup

System of linear equations wikipedia , lookup

History of algebra wikipedia , lookup

Factorization wikipedia , lookup

Eisenstein's criterion wikipedia , lookup

Equation wikipedia , lookup

Chinese remainder theorem wikipedia , lookup

Addition wikipedia , lookup

Fundamental theorem of algebra wikipedia , lookup

System of polynomial equations wikipedia , lookup

Transcript
Z/mZ AS A NUMBER SYSTEM
BRIAN OSSERMAN
As useful as the congruence notation is, it can still be cumbersome to state certain ideas purely in
terms of congruence of integers. For instance, we had the following statement on linear congruences
in one variable:
Theorem 1. Given a, b ∈ Z and m ∈ P, suppose that (a, m) = d. Then:
(i) If d - b, then the congruence ax ≡ b (mod m) has no solutions.
(ii) If d | b, then the congruence ax ≡ b (mod m) has exactly d distinct solutions.
We had explained that “distinct solutions” refers to solutions which are distinct modulo m, since
x0 ≡ x (mod m), then x is a solution if and only if x0 is a solution. Intuitively, we know what we
mean by the above statement (hopefully), but, it is still somewhat imprecise, insofar as we think
of solutions as being integers. That is, if x ≡ x0 (mod m), we don’t consider them as distinct
solutions, but they are still distinct integers, so a precise wording is difficult. One could say “if
d | b, and x1 , . . . , xn ∈ Z is a maximal set of solutions to the congruence ax ≡ b (mod m) which
are pairwise incongruent modulo m, then n = d.” But this doesn’t capture the idea that any such
set of x1 , . . . , xd are equivalent modulo m. We could say “if d | b, then there are exactly d distinct
remainders when we divide solutions to the congruence ax ≡ b (mod m) by m.” But this is wordy
and arguably the reliance on remainders is artificial.
This awkwardness is addressed by introducing the generalized number system Z/mZ.
Congruence classes. A preliminary definition is:
Definition 2. Given a ∈ Z, the congruence class of a modulo m, denoted [a]m ,1 is the subset
of Z consisting of all integers modulo m. A congruence class modulo m is a subset of Z which
is of the form [a]m for some a ∈ Z.
Note that a congruence class is just a subset of Z, so if a ≡ b (mod m), then the congruence
classes [a]m and [b]m are the same. And conversely, if [a]m = [b]m , then a ≡ b (mod m). It follows
in particular that if two congruence classes modulo m are distinct, then they must not have any
elements in common, so (as noted in Section 4.1 of the textbook), for any m ∈ P, the congruence
classes modulo m divide Z into m disjoint subsets. Put differently, for any r1 , . . . , rm a complete
system of residues modulo m, the congruence classes [r1 ]m , . . . , [rm ]m are disjoint, and together
they cover all of Z.
Example 3. If m = 2, the congruence classes consist of the even integers and the odd integers.
Now, if we are trying to solve a congruence such as ax ≡ b (mod m), we can rephrase our prior
observations on the solutions as saying that if x is a solution, then every element of [x]m is a
solution, so really we should be thinking of solutions in terms of congruence classes modulo m.
This leads to a more elegant rephrasing of (ii) of Theorem 1 as follows: “if d | b, then there are
exactly d congruence classes modulo m of solutions to the congruence ax ≡ b (mod m).”
1the textbook uses [x] for a real number x to denote the greatest integer less than or equal to x; however, we
prefer the notation bxc for this, which in any case we will rarely use.
1
Operations on congruence classes. Now, an important part of what’s going on here is that
addition and multiplication are well-defined on the level of congruence classes – that is, we can
rephrase our first few results regarding congruences as saying that if [a]m = [c]m and [b]m = [d]m ,
then [a + b]m = [c + d]m , [a − b]m = [c − d]m , and [ab]m = [cd]m . This means that if we want
to define [a]m + [b]m = [a + b]m , the result doesn’t depend on the choice of a and b, only on the
subsets [a]m and [b]m . We then make similar definitions for subtraction and multiplication, and
obtain operations on the congruence classes themselves.
Example 4. While the above paragraph may seem very abstract, it reduces to something familiar
in the case m = 2. The statements “an even plus an even is even,” “an even plus an odd is odd,”
“an even times an odd is even,” and so forth are precisely examples of what we have described:
that is, they give rules for adding and multiplying even and odd numbers which tell us whether the
result is even or odd, without knowing anything more than whether the original numbers were even
or odd. This is precisely what it means to say that the operations are well-defined on congruence
classes.
Warning 5. Declaring [a]m · [b]m = [ab]m is not the same thing as saying that [a]m · [b]m is the set of
products c · d where c ∈ [a]m and d ∈ [b]m . The latter set is contained in [ab]m , but is not typically
equal. For instance, if a = 2 and b = 3 and m = 5, then [2]m · [3]m = [6]m = [1]m , which contains
1. But 1 cannot be written as c · d with c ∈ [2]m and d ∈ [3]m .
At this point, we can think of the collection of congruence classes modulo m as forming some
sort of alternative number system:
Definition 6. Given m ∈ P, the integers modulo m, denoted Z/mZ, is the set of congruence
classes modulo m. It has operations +, −, · induced by the corresponding operations on Z as
described above.
Thus, this is a fully functional “number system” complete with basic operations. It inherits
commutativity, associativity, and the distributive law from Z. We also note that [a]m + [0]m = [a]m
and [a]m · [1]m = [a]m for any a ∈ Z, so it even has additive and multiplicative identities.
One often pictures Z/mZ similarly to a clock, with m numbers (labeled from 0 to m − 1, or 1 to
m) spread out around a circle. Adding [1]m moves from each number to the next.
From congruences to equations. Instead of thinking of a congruence ax ≡ b (mod m) as a
congruence on integers, we can instead think of it as an equation in Z/mZ, writing it as
[a]m x = [b]m ,
where now we are looking for solutions x in Z/mZ, rather than Z. Note that here it is no longer
a congruence, but an equation. However, the equation occurs in Z/mZ, rather than in Z. (This
approach also emphasizes that only the congruence classes of a and b modulo m matter, rather
than the particular integers we chose to represent them)
In this context, we can simplify (ii) of Theorem 1 even further: “if d|b, then the equation
[a]m x = [b]m in Z/mZ has exactly d solutions.”
We can similarly think of polynomials with coeffficients in Z/mZ, and it makes sense to consider
their roots as elements of Z/mZ as well. Notice that one of your homework problems can be
rephrased in these terms as follows:
Theorem 7. If p is prime, and f (x) is a polynomial with coefficients in Z/pZ and degree d, then
f (x) has at most d roots in Z/pZ.
Notice also that this theorem fails in Z/mZ if m is not prime: indeed, we already saw that the
polynomial x2 − 1 can have an arbitrarily large number of roots, depending on the number of prime
divisors of m.
2