Modular Arithmetic
Lesson · Beginner
Number Theory
Definition
a is congruent to b modulo m if and only if their difference is divisible by m:
Properties
Proof
Since
and
we have
Proof
If
then
Since
we also have
Therefore
Proof
Since
we have
and since
we have
Adding these two divisibilities
so
Proof
Since
we obtain
and
Therefore
and
Proof
Since
we have
and since
we have
Adding the two divisibilities
so
Subtracting the two divisibilities
so
Also
and
Adding these
so
Proof
Using Property 5 repeatedly
multiplied by itself n times gives
Proof
Let
and write
where
(⇒)
Since
we have
Hence
so
Since
Euclid's Lemma gives
Therefore
(⇐)
If
then
Multiplying by d
Multiplying by c'
which is equivalent to
Proof
Since
we have
Because
it follows that
Therefore
Find the remainder when
is divided by 7.
Find the remainder when
is divided by 6.
Find the remainder when
is divided by
a) 7
b) 9
c) 13
a)
b)
c)
Prove that the remainder of a perfect square divided by 3 is 0 or 1.
Prove that an odd perfect square divided by 8 has remainder 1.
Prove that the remainder of a perfect square divided by 4 is 0 or 1.
Prove that
has no integer solutions.
But
Impossible.
From
you cannot always cancel c and conclude
For example
because
But
If
then cancellation modulo m is valid.
From
you generally cannot simply reduce n modulo m.
For example, there is no general rule
For example
is perfectly correct.
But if the question asks for the remainder when 17 is divided by 5, the answer is
not −3.
The usual remainder is