 
Summary: Math 2020 Spring 2011
Solving Discrete Problems P. Achar
Notes on Chapter 6: Division with Remainder
Theorem (Division with Remainder). Let n N and m Z. There exist unique integers q, r Z such that
m = nq + r and 0 r < n. ()
Proof. The proof is two parts: (1) existence of q and r such that () is true, and (2) uniqueness of q and r.
We'll start with existence. Consider the set
S = {m + an : a Z} Z0.
Step 1a. S = .
Proof of Step 1a. We'll consider two cases: m 0 and m < 0. If m 0, let's take a = 1. Then, since
n > 0, we have m + an = m + n 0, so m + an is an element of S. This shows that S = .
If m < 0, then let's take a = m. In this case, we have m + an = m  mn = m(1  n). Since n 1, we
know that 1  n 0. We also have m < 0 by assumption, so it follows that m(1  n) 0. This shows that
m + an S, so again, S = .
Note that for all c S, we have 0 c. Therefore, applying Proposition 2.33 (a variant of the Well
Ordering Principle) to the set S and the integer 0, we learn that S has a smallest element. Let
r = the smallest element of S.
Since r S, there is some a Z such that r = m + an. Let
q = a.
From these definitions, it follows that m = nq + r. To complete the existence part of the proof, we must
