# Prove that card$( \bigcup \{A_n : n\in \mathbb{N}\} ) \leq$ card$(\mathbb{R})$

If card$$(A_n)\leq$$ card$$(\mathbb{R}), \forall n \in \mathbb{N}$$ show that card$$( \bigcup \{A_n : n\in \mathbb{N}\} ) \leq$$ card$$(\mathbb{R})$$

My attemp:

If card$$(A_n)\leq$$ card$$(\mathbb{R})$$ for each $$n\in\mathbb{N}$$ exist $$f_n:A_n\to\mathbb{R}$$ an injective function.

First case. If $$\bigcup \{A_n : n\in \mathbb{N}\}$$ is such that $$A_n \cap A_m = \emptyset, n\neq m$$

Let $$g: \bigcup \{A_n : n\in \mathbb{N}\}\to\mathbb{R}$$ defined as

$$g(x)= \left\{ \begin{array}{lcc} f_1(x) & \textit{if} & x \in A_1 \\ \\ f_2(x) & \textit{if} & x \in A_2\\ \hspace{0.5cm}\vdots \\ f_m(x) & \textit{if} & x \in A_m \\ \hspace{0.5cm}\vdots \\ \end{array} \right.$$

Since each $$f_n$$ is an injective function and $$A_n \cap A_m = \emptyset, n\neq m$$ then $$g$$ is an injective function. Therefore card$$( \bigcup \{A_n : n\in \mathbb{N}\} ) \leq$$ card$$(\mathbb{R})$$

But, what happens with the case when $$A_n \cap A_m \neq \emptyset$$ for some $$n, m \in \mathbb{N}$$?

• Even if the sets $A_n$ are pairwise disjoint, the sets $f_n[A_n]$ need not be pairwise disjoint, so $g$ need not be injective. There may be $x\in A_0$ and $y\in A_1$ such that $f_0(x)=f_1(y)$, even if $A_0\cap A_1=\varnothing$. – Brian M. Scott Apr 2 at 2:50

I’ll assume that you know that for each $$n\in\Bbb Z$$ there is a bijection $$h_n:\Bbb R\to(n,n+1)\,.$$

Define

$$\varphi:\bigcup_{n\in\Bbb N}A_n\to\Bbb N:x\mapsto\min\{k\in\Bbb N:x\in A_k\}\,,$$

and let

$$g:\bigcup_{n\in\Bbb N}A_n\to\Bbb R:x\mapsto (h_{\varphi(x)}\circ f_{\varphi(x)})(x)\,.$$

Now show that $$g$$ is injective.

What you are assuming in your argument is not that $$\{A_n : n\in\mathbb{N}\}$$ are pairwise disjoint but that $$\{ f_n(A_n): n\in \mathbb{N}\}$$ are pairwise disjoint. We can reduce the problem to this case.

Choose your favourite bijection $$g(x)$$ between $$\mathbb{R}$$ and the interval $$(0,1)$$. You can find some in this site. Then for any $$n$$ let $$g_n(x)=(g\circ f_n)(x)+n$$, where $$f_n$$ are the injections that you describe. Then $$g_n$$ is an injection into $$(n,n+1)$$. Finally you apply your argument with the $$g_n$$ instead of $$f_n$$.