Properties of the Cartesian product of indexed sets

elementary-set-theory

Given the indexed sets $(X_i)_{i\in I}$, one usually defines their Cartesian product as:
$$\prod_{i\in I} X_i =_\text{def}\;
\left\{ f: f\in \left(\bigcup_{i\in I} X_i\right)^I \wedge\; \forall i \in I\; f(i)\in X_i\right\}
\label{cart1}\tag{1}$$

For $I=\{1,2\}$, it seems natural to set:
$$
X_1\times X_2 =_\text{def}\; \prod_{i\in \{1,2\}} X_i
$$

Then one expects, for $I=\{1\ldots n\}$:
$$\prod_{i=1}^{n} X_i = \left(\prod_{i=1}^{n-1} X_i\right) \times X_n
\label{cart2}\tag{2}$$

I am unable to derive \ref{cart2}. In fact, the generic element of
$
\prod\limits_{i=1}^{3} X_i
$
is:

$$
\{(1, f(1)), (2, f(2)), (3, f(3))\}, \text{ where $f$ is a function in }
\left(\bigcup_{i\in \{1,2,3\}} X_i\right)^{\{1,2,3\}}\;;
$$

while the generic element of:
$$
\left(\prod_{i=1}^{2} X_i\right) \times X_3
$$
is:

$$
\{(1, f(1)), (2, f(2))\}, \text{ where $f$ is a function in }
\left( \left(\prod_{i=1}^{2} X_i\right) \cup X_3\right)^{\{1,2\}}\;.
$$

So:
$$
\prod_{i=1}^{3} X_i \neq \left(\prod_{i=1}^{2} X_i\right) \times X_3
\label{cart3}\tag{3}
$$

If that is correct, it extends to the Cartesian power:
$$
X^{n+1} =
X^{n} \times X
$$

If \ref{cart3} is wrong, please, tell me how to prove the equality.
If \ref{cart3} is correct, can we properly define \ref{cart1} a Cartesian product, given that the standard/expected Cartesian product properties are missing?

UPDATE

The point of my question is:
since the infinite CP is a generalisation of the ordinary CP, for a finite index set:

$$\prod_{i\in \{1\ldots n\}} X_i = X_1\times\ldots X_n$$

In words: the finite versions of the infinite CP should work like the ordinary finite version. This might happen with a proper definition of $\times$ for the generalised CP, and apparently not mine above.

In a similar question, @StefanH, wants a CP construction which observes the following properties:

i) it is associative;

ii) $A^0 \times A^n = A^n$

iii) gives a natural choice for $A_0$.

Making the generalised $\times$ associative is the opposite of what I am looking for, because the standard finite CP is not associative. As for ii) and iii), there is no $A^0$ in the standard CP and so no standard behaviour to generalise.

As noted: if the generalised CP (as defined in $\ref{cart1}$) does not share the essential properties enjoyed by the standard CP, then the name 'generalised CP' might be a misnomer.

Best Answer

The equality $$\prod_{i=1}^{n} X_i = \left(\prod_{i=1}^{n-1} X_i\right) \times X_n$$ is simply not true in general (the counter example you provided is valid).

What people usually do is to implicitly identify those two sets using the natural bijection $F : \prod_{i=1}^{n} X_i \longrightarrow \left(\prod_{i=1}^{n-1} X_i\right) \times X_n $ defined as $$ F(f) = \left\{(1, f_{\big|\left\{ k \right\}_{k=1}^{n-1}}), (2, f(n))\right\}$$

You have exactly the same problem if you define the cartesian product as set of ordered pairs, namely it's not associative. Furthermore the ordered pairs definition and functional definition are strictly different according to the standard notion of set equality.

However for the most part this is always ignored (by abuse of notation) since those sets being isomoprphic is good enough for most people using them.

Related Question