# Housing crisis in heaven

Heaven has a countably infinite number of cloud for people to stay, each of which has a good soul living on it.

A countably infinite number of infinite universes are extinguished by God (their beta period had expired). So, a countably infinite number of groups of good souls (each of which are countably infinite in size) were knocking on the doors of heaven. Each person, in each group was carrying a little ticket, from $\ge 1$ (which one receives before passing the pearly gates).

How will God and his dear mother accomodate all these people on a cloud of their own without creating any new clouds?

• From reading the answer I think that the ticket each person gets is the one from their original heaven, is that right? So there will be multiple people holding the 1 ticket? The way I first read it I was rather confused because I thought that each of the new people got a ticket as they arrived in this heaven number from 1 which meant each of the new people had a unique number which makes the problem rather easy (to the extent my first thought on reading the question was "Why will god have any problem accommodating these people?") – Chris Jul 11 '17 at 16:13

This is a restatement of Hilbert's paradox of the Grand Hotel, in particular the Infinitely many coaches with infinitely many guests each problem.

The solution is to take each person's ticket, and assign them a cloud number based on their original universe number and their original cloud number. You can calculate the new number from the older two numbers using a pairing function. One such function is the Cantor pairing function:

new cloud number = (1/2)*(A+B)*(A+B+1)+B


where A is your old universe number and B is your old cloud number.

• well, that was too easy... but at least it's on the site now – d'alar'cop Oct 16 '14 at 14:36