Hilbert's Hotel Paradox Calculator

Explore how an infinite hotel can always accommodate new guests, even when fully occupied

Enter the number of new guests arriving (0, any positive integer, or type "infinity" for infinitely many)

How to Use This Calculator

1

Enter Number of New Guests

Enter how many new guests need accommodation. Try 1 guest, then try a larger number, or use "infinitely many" to see the infinite case.

2

Calculate Strategy

Click the button to see how the hotel manager can accommodate the new guests by reassigning existing guests to new rooms.

3

Understand the Paradox

Observe how an infinite hotel can always make room, no matter how many new guests arrive, even infinitely many!

Formula & Strategy

New Room for Guest in Room n: n + k

where k = number of new guests (for finite case)

For One New Guest:

Guest in room n → moves to room n + 1

The new guest takes room 1.

For k New Guests:

Guest in room n → moves to room n + k

New guests take rooms 1 through k.

For Infinitely Many New Guests:

Guest in room n → moves to room 2n

New guests take all odd-numbered rooms: 1, 3, 5, 7, 9, ...

Example (1 new guest):

Guest in room 1 → room 2, room 2 → room 3, room 3 → room 4, etc.

New guest → room 1

About Hilbert's Hotel Paradox

Hilbert's Hotel Paradox is a thought experiment proposed by German mathematician David Hilbert in the 1920s. It illustrates counterintuitive properties of infinite sets and demonstrates that infinity behaves very differently from finite numbers.

The Setup

Imagine a hotel with infinitely many rooms, numbered 1, 2, 3, 4, ... The hotel is completely full - every room has exactly one guest. Now, a new guest arrives and requests a room. Can they be accommodated?

The Solution

Yes! The manager moves each guest from room n to room n + 1. This frees up room 1 for the new guest. Since there are infinitely many rooms, every existing guest gets a new room, and the new guest gets room 1.

The same strategy works for any finite number of new guests: move each existing guest from room n to room n + k (where k is the number of new guests), and assign the new guests to rooms 1 through k.

The Infinite Case

Even more remarkably, if infinitely many new guests arrive (one for each natural number), they can still all be accommodated! The manager moves each existing guest from room n to room 2n, freeing up all odd-numbered rooms (1, 3, 5, 7, ...) for the infinitely many new guests.

Why This Seems Paradoxical

In the finite world, if a hotel is full, no new guests can be accommodated without evicting someone. Hilbert's Hotel shows that with infinite sets, you can always make room by reassigning elements. This is possible because:

  • Infinity + 1 = Infinity
  • Infinity + k = Infinity (for any finite k)
  • Infinity + Infinity = Infinity

Mathematical Significance

Hilbert's Hotel demonstrates that:

  • Countable Infinity: The set of natural numbers has the same cardinality as many of its proper subsets
  • Bijections: There exist bijections (one-to-one correspondences) between the set of natural numbers N and N union any new element
  • Infinite Set Properties: Infinite sets don't follow the same arithmetic rules as finite numbers

Variations of the Paradox

  • Infinitely Many Buses: If infinitely many buses each carrying infinitely many guests arrive, they can all be accommodated using more sophisticated pairing functions
  • Uncountable Guests: If uncountably many guests arrive (like the real numbers), they cannot all be accommodated - this shows that not all infinities are equal
  • Negative Room Numbers: The paradox can be extended to include rooms numbered with all integers, not just natural numbers

Real-World Applications

While Hilbert's Hotel is a thought experiment, the underlying mathematics applies to:

  • Set Theory: Understanding cardinality and bijections
  • Computer Science: Infinite data structures and lazy evaluation
  • Mathematical Logic: Formalizing concepts of infinity
  • Analysis: Working with infinite series and limits

Frequently Asked Questions

How is this possible if the hotel is full?

This only works because the hotel has infinitely many rooms. In a finite hotel, once it's full, no more guests can be accommodated. But with infinite rooms, we can always "shift" guests to make room by moving them to higher-numbered rooms.

What if infinitely many buses arrive, each with infinitely many guests?

They can still all be accommodated! This requires a more complex pairing function. One strategy uses prime powers: guest from bus b, seat s goes to room 2^b × 3^s. This ensures no two guests are assigned the same room.

Does this mean all infinities are the same?

No! Hilbert's Hotel works because we're dealing with countable infinity (the natural numbers). If uncountably many guests arrive (like the real numbers), they cannot all be accommodated - this shows that the set of real numbers is "larger" than the set of natural numbers.

Can this happen in real life?

No, Hilbert's Hotel is a mathematical thought experiment. Real hotels are finite. However, the mathematical principles it illustrates are real and fundamental to understanding infinity in mathematics.

What's the key insight from this paradox?

The key insight is that infinite sets don't follow the same rules as finite sets. A set can have the same cardinality as a proper subset of itself. This is impossible for finite sets but a defining property of infinite sets.