# What is the cartesian product of cartesian products?

If I have four sets $A$, $B$, $C$ and $D$, what is the meaning of $(A \times B) \times (C \times D)$?
Can I define it to be a matrix, such that the first index of each element will be given by its order in the bigger cartesian product i.e.$(A \times B) \times (C \times D)$, and the second index will be given by its order within the smaller cartesian product i.e. $(A \times B)$ or $(C \times D)$?

By definition $(A\times B)\times(C\times D)$ is the set of all ordered pairs of ordered pairs of the form

$$\big\langle\langle a,b\rangle,\langle c,d\rangle\big\rangle\;,$$

where $a\in A,b\in B,c\in C$, and $d\in D$. You’ve described the set of $2\times 2$ matrices of the form

$$\begin{bmatrix}a&b\\c&d\end{bmatrix}\;,$$

where $a\in A,b\in B,c\in C$, and $d\in D$. There is a natural bijection between these two sets given by

$$\big\langle\langle a,b\rangle,\langle c,d\rangle\big\rangle\mapsto\begin{bmatrix}a&b\\c&d\end{bmatrix}\;,$$

but the two sets are not equal, simply because a $2\times 2$ matrix is not an ordered pair of ordered pairs: the set of matrices is not the same thing as the Cartesian product.

• Thanks. But what is the main reason behind the unequality? Jan 13, 2017 at 12:48
• I mean can't we generate all kinds of matrices by extending the ordered pairs in the question to the n-tuples? Jan 13, 2017 at 12:53
• @Nabin: Formally a $2\times 2$ matrix simply isn’t an ordered pair of ordered pairs. Jan 13, 2017 at 12:56
• @Nabin A 2x2 matrix and an ordered pair of ordered pairs (henceforth, OPOP) are two mathematically distinct objects. The set of 2x2 matrices and the set of OPOPs are not equal, but they are isomorphic, in that the bijection Brian.M.Scott mentions allows you to losslessly convert a 2x2 matrix to an OPOP. This fact is what allows you, for example, to represent a matrix as an OPOP in a computer program. Jan 13, 2017 at 13:41
• @Nabin Note that there is also a quite obvious bijection with ordered quadruples, $\langle \langle a,b\rangle,\langle c,d\rangle\rangle\mapsto \langle a,b,c,d\rangle$, which a yet again different objects ... Jan 13, 2017 at 19:05

Cartesian product of cartesian products is a set of tuples of tuples. $$(A \times B) \times (C \times D) = \left\{((a,b),(c,d))|a\in A, b\in B, c\in C, d\in D\right\}$$

$(A \times B)\times (C \times D))=\{(u,v): u \in A \times B, v \in C \times D\}=\{((a,b),(c,d)):a \in A, b \in B, c \in C, d \in D\}$.

The meaning of $(A\times B)\times(C\times D)$ is that of a set of ordered pairs of ... ordered pairs, the first pair with the first element from $A$ and the second from $B$, and the second pair with the first element from $C$ and the second from $D$.

An example would be this: if $A=B=C=D=\mathbb{R}$, then $(A\times B)\times (C\times D)$ can represent the set of all segments on the cartesian plane, each segment being represented as a pair of points, with each point in turn represented as a pair of coordinates: $(x_1,y_1),(x_2,y_2)$.

You can certainly represent it as a matrix as long as all four sets are at most countably infinite - so not in the segments example above! What's really important is not to confuse $((A\times B)\times(C \times D))$ with $A \times B \times C \times D$; the former is a set of pairs of pairs, the second is a set of $4$-uples.