Integer Multiplication Well-Defined

From ProofWiki
Jump to: navigation, search

Theorem

Integer multiplication is well-defined.


Proof

Let us define $\left[\!\left[{\left({a, b}\right)}\right]\!\right]_\boxtimes$ as in the formal definition of integers.

That is, $\left[\!\left[{\left({a, b}\right)}\right]\!\right]_\boxtimes$ is an equivalence class of ordered pairs of natural numbers under the congruence relation $\boxtimes$.

$\boxtimes$ is the congruence relation defined on $\N \times \N$ by $\left({x_1, y_1}\right) \boxtimes \left({x_2, y_2}\right) \iff x_1 + y_2 = x_2 + y_1$.


In order to streamline the notation, we will use $\left[\!\left[{a, b}\right]\!\right]$ to mean $\left[\!\left[{\left({a, b}\right)}\right]\!\right]_\boxtimes$, as suggested.


We need to show that $\left[\!\left[{a, b}\right]\!\right] = \left[\!\left[{p, q}\right]\!\right] \land \left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{r, s}\right]\!\right] \implies \left[\!\left[{a, b}\right]\!\right] \times \left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{p, q}\right]\!\right] \times \left[\!\left[{r, s}\right]\!\right]$.


We have $\left[\!\left[{a, b}\right]\!\right] = \left[\!\left[{p, q}\right]\!\right] \land \left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{r, s}\right]\!\right] \iff a + q = b + p \land c + s = d + r$ by the definition of $\boxtimes$.


From the definition of integer multiplication, we have:

$\forall a, b, c, d \in \N: \left[\!\left[{a, b}\right]\!\right] \times \left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{ac + bd, ad + bc}\right]\!\right]$.


So, suppose that $\left[\!\left[{a, b}\right]\!\right] = \left[\!\left[{p, q}\right]\!\right]$ and $\left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{r, s}\right]\!\right]$.


Both $+$ and $\times$ are commutative and associative on $\N$. Thus:

\(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\) \(\displaystyle \) \(\displaystyle \left({ac + bd + ps + qr}\right) + \left({pc + qc + pd + qd}\right)\) \(\displaystyle \) \(\displaystyle \)                    
\(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(=\) \(\displaystyle \) \(\displaystyle \left({a + q}\right) c + \left({b + p}\right) d + p \left({c + s}\right) + q \left({d + r}\right)\) \(\displaystyle \) \(\displaystyle \)                    
\(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(=\) \(\displaystyle \) \(\displaystyle \left({b + p}\right) c + \left({a + q}\right) d + p \left({d + r}\right) + q \left({c + s}\right)\) \(\displaystyle \) \(\displaystyle \)          as $a + q = b + p, c + s = d + r$          
\(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(=\) \(\displaystyle \) \(\displaystyle bc + pc + aq + ad + pd + pr + qc + qs\) \(\displaystyle \) \(\displaystyle \)                    
\(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(\displaystyle \) \(=\) \(\displaystyle \) \(\displaystyle \left({ad + bc + pr + qs}\right) + \left({pc + qc + pd + qd}\right)\) \(\displaystyle \) \(\displaystyle \)                    


So we have $ac + bd + ps + qr = ad + bc + pr + qs$ and so, by the definition of $\boxtimes$, we have:

$\left[\!\left[{ac + bd, ad + bc}\right]\!\right] = \left[\!\left[{pr + qs, ps + qr}\right]\!\right]$


So, by the definition of integer multiplication, this leads to:

$\left[\!\left[{a, b}\right]\!\right] \times \left[\!\left[{c, d}\right]\!\right] = \left[\!\left[{p, q}\right]\!\right] \times \left[\!\left[{r, s}\right]\!\right]$


Thus integer multiplication has been shown to be well-defined.

$\blacksquare$