Finding an infinite union of disjoint infinite sets to add up to natural numbers [duplicate]

Formally, your proof can be written as follows.

Let $(p_i)_{i\in\mathbb N}$ be the sequence of all prime numbers, in increasing order (i.e. $p_1=2, p_2=3, p_3=5$ etc.)

For $i\in\mathbb N, i\ge 2$, define $A_i=\{n\in\mathbb N: (p_i\mid n) \land (\forall j>i)(p_j\not\mid n)\}$. In other words, $A_i$ consists of all natural numbers whose largest prime factor is $p_i$.

Also, define $A_1=\{1,2,2^2,2^3,\ldots\}$. Obviously, $A_1$ is the only set containing $1$.

One can see easily that:

  • All $A_i$ are infinite. Namely, $p_i, p_i^2, p_i^3, \ldots\in A_i$.
  • $A_i\cap A_j=\emptyset$ for $i\ne j$. Namely, if $n\in A_i\cap A_j$, then either $n=1$ and so $i=j=1$ or $n$ has a largest prime factor $p_k$, so $i=k=j$.
  • $\bigcup_{i=1}^\infty A_i=\mathbb N$. Namely, $1\in A_1$ and if $n\ge 2$, take the largest prime factor $p_i$ of $n$, and it follows that $n\in A_i$.

Having said all that, here is potentially a simpler solution: $A_i$ is the set of the natural numbers having exactly $i-1$ zeros at the end:

  • $A_1=\{1,2,\ldots,9,11,12,\ldots,19,21,22,\ldots,29,\ldots\}$
  • $A_2=\{10,20,\ldots,90,110,120,\ldots,190,\ldots\}$
  • $A_3=\{100,200,\ldots,900,1100,1200,\ldots,1900,\ldots\}$
  • etc.

You have to be a little more careful with your proof-writing. What you're saying in English is that each $A_i$ is a product of powers of the first $i$ primes. The problem is that, as you've written it, it's not true that $A_i \cap A_j = \varnothing$. It's easy to fix the problem, though; just require in each $A_i$ that $k_i \geq 1$.

Also, as noted above, you need to place $1$ (and possibly $0$) in one of your sets, which you can do arbitrarily.