Division Theorem/Proof 3

Theorem
For every pair of integers $a, b$ where $b \ne 0$, there exist unique integers $q, r$ such that $a = q b + r$ and $0 \le r < \left|{b}\right|$.


 * $\forall a, b \in \Z, b \ne 0: \exists! q, r \in \Z: a = q b + r, 0 \le r < \left|{b}\right|$

Existence
Consider the progression:
 * $\ldots, a - 3 b, a - 2 b, a - b, a, a + b, a + 2 b, a + 3 b, \ldots$

which extends in both directions.

Then by the Well-Ordering Principle, there must exist a smallest non-negative element, denoted by $r$.

So $r = a - q b$ for some $q \in \Z$.

$r$ must be in the interval $\left[{0, b}\right)$ because otherwise $r-b$ would be smaller than $r$ and a non-negative element in the progression.

Uniqueness
Suppose we have another pair $q_0$ and $r_0$ such that $a = b q_0 + r_0$, with $0 \le r_0 < b$.

Then $b q + r = b q_0 + r_0$.

Factoring we see that $r - r_0 = b \left({q_0 - q}\right)$, and so $b \mathop \backslash \left({r - r_0}\right)$.

Since $0 \le r < b$ and $0 \le r_0 < b$, we have that $-b < r - r_0 < b$.

Hence, $r - r_0 = 0 \implies r = r_0$.

So now $r - r_0 = 0 = b \left({q_0 - q}\right)$ which implies that $q = q_0$.

Therefore the solution is unique.