100 prisoners problem
The 100 prisoners problem is a mathematical problem in probability theory and combinatorics. In this problem, 100 numbered prisoners must find their own numbers in one of 100 drawers in order to survive. The rules state that each prisoner may open only 50 drawers and cannot communicate with other prisoners after the first prisoner enters to look in the drawers. If all 100 prisoners manage to find their own numbers, they all survive, but if even one prisoner can't find their number, they all die. At first glance, the situation appears hopeless, but a clever strategy offers the prisoners a realistic chance of survival. Anna Gál and Peter Bro Miltersen first proposed the problem in 2003. Source: e01 Encyclopedia. Licence: CC BY-SA 4.0.
The 100 prisoners problem is a mathematical problem in probability theory and combinatorics. In this problem, 100 numbered prisoners must find their own numbers in one of 100 drawers in order to survive. The rules state that each prisoner may open only 50 drawers and cannot communicate with other prisoners after the first prisoner enters to look in the drawers. If all 100 prisoners manage to find their own numbers, they all survive, but if even one prisoner can't find their number, they all die. At first glance, the situation appears hopeless, but a clever strategy offers the prisoners a realistic chance of survival. Anna Gál and Peter Bro Miltersen first proposed the problem in 2003. \binom{100}{l} \cdot (l-1)! \cdot (100-l)! = \frac{100!}{l}. The probability, that a (uniformly distributed) random permutation contains no cycle of length greater than 50 is calculated with the formula for single events and the formula for complementary events thus given by 1 - \frac{1}{100!} \left( \frac{100!}{51} + \ldots + \frac{100!}{100} \right) = 1 - \left( \frac{1}{51} + \ldots + \frac{1}{100} \right) = 1 - ( H_{100} - H_{50} ) \approx 0.31183, where H_n is the n -th harmonic number. Therefore, using the cycle-following strategy the prisoners survive in a surprising 31% of cases. 1 - ( H_{2n} - H_n ) = 1 - (H_{2n} - \ln 2n) + (H_n - \ln n) - \ln 2. With the Euler–Mascheroni constant \gamma , for n \to \infty \lim_{n \to \infty} (H_n - \ln n) = \gamma holds, which results in an asymptotic survival probability of \lim_{n \to \infty} ( 1 - H_{2n} + H_n ) = 1 - \gamma + \gamma - \ln 2 = 1 - \ln 2 \approx 0.30685. Since the sequence of probabilities is monotonically decreasing, the prisoners survive with the cycle-following strategy in more than 30% of cases independent of the number of prisoners. With the strategy for the original problem: (1 - \ln(2)) \cdot 1 + \sum_{k = \lfloor n/2 \rfloor + 1}^N \frac{1}{k} \left(1-\frac{k}{n}\right) = 1 - \ln(2) + \sum_{\lfloor n/2 \rfloor + 1}^N \frac{1}{k} - \sum_{k = \lfloor n/2 \rfloor + 1}^N \frac{1}{n} = 1 - \ln(2) + \ln(2) - \frac{1}{2} = \frac{1}{2} It is noteworthy that although we receive the same expected values, they are from very different distributions. With the second strategy, some prisoners are simply destined to die or live given a particular permutation, and with the first strategy (i.e., no strategy), there is "truly" a 1/2 chance for every permutation.
Cite this
"100 prisoners problem". 1789161397. e01 Encyclopedia. CC BY-SA 4.0. https://en.wikipedia.org/w/index.php?oldid=1374416199 JSON record · API collection · BibTeX · RIS · CSL-JSON · citation policy