Arithmetics of cardinalities: if $|A|=|C|$ and $|B|=|D|$ then $|A\times B|=|D\times C|$

Suppose that $A, B, C$, and $D$ are sets with the cardinalities related as $|A|=|C|$ and $|B|=|D|$. Prove that the cardinality of $A\times B$ is equal to the cardinality of $D\times C$.

I know that I must prove the bijection of the function $f: A \times B \to C \times D$, but I am not sure how to say this? Can anyone help me?


Solution 1:

Since you have $|A| = |C|$, consider a bijection $f : A \to C$. Similarly, consider a bijection $g : B \to D$.

Now a bijection $h: A \times B \to C \times D$ should be given by $(a, b) \mapsto (f(a), g(b))$.

To show injective, consider: $h(a_{1}, b_{1}) = h(a_{2}, b_{2})$. We have $h(a_{1}, b_{1}) = (f(a_{1}), g(b_{1})) = (f(a_{2}), g(b_{2}))$. As $f, g$ are bijective, we have $a_{1} = a_{2}$ and $b_{1} = b_{2}$. So $h$ is injective.

Showing surjectivity is quite similar. Pick $(c, d) \in C \times D$. Since $f, g$ are surjective, there exist $a \in A$ and $b \in B$ such that $f(a) = c$ and $g(b) = d$. Thus, $h(a, b) = (c, d)$ and we have surjectivity.