Question: A single alien lands on Earth. After every fixed interval of time the alien undergoes a transformation, which could be any of the four events:
1. The alien does nothing, event probability- 2/6
2. The alien dies, event probability- 1/6
3. The alien replicates itself (2 aliens total), event probability- 2/6
4. The alien replicates itself twice (3 aliens total), event probability – 1/6
What is the probability that the alien would continue to make a large race over an extended period of time?
Answer: The situation can be described by the following illustration-
Assume that the probability of alien race dying out is p. After each of the four cases, the probability of alien race dying out is-
1. p, as it is the probability we assumed
2. 1, as the alien dies out
3. p x p, as now two alien races need to die independently
4. p x p x p, as now three alien races need to die independently
Since we know probability of each other four events,
p = 2p/6+ 1/6 + 2p2/6 + p3/6
This simplifies to
p3 + 2p2 – 4p + 1 = 0
(p – 1).(p2 + 3p – 1) = 0
The solutions of this equation are: 1, -3.3, 0.3. Since probability can’t be negative, -3.3 can’t be the solution. p = 1 can also be discarded. This is because the expected number of aliens after one event is 1 x 2/6 + 0 x 1 /6 + 2 x 2/6 + 3 x 1/6 = 1.5. Since the expected number after first interval is greater than 1, there is chance that the alien can avoid extinction.
Hence, the probability that the alien would continue to make a large race is 1 – 0.3 = 0.7 (note: 0.3 is an approximate solution of the above equation. Otherwise, the exact probability is: 2.5 – 0.5√13).
We can also test this solution using python. The following code simulates the scenario.
import numpy as np import matplotlib.pyplot as plt N_EXPERIMENTS = 500 N_TRIALS = 150 N_INTERVALS = 15 sample_estimate =  for i in range(N_EXPERIMENTS): # number of experiments counter = 0 for j in range(N_TRIALS): # number of trials, to get probability of survival n_aliens = 1 for k in range(N_INTERVALS): # see if alien survives after 20 intervals n_aliens_after = 0 for alien in range(n_aliens): prob = np.random.uniform(0, 1) if prob < 2.0/6: n_aliens_after += 1 # alien does nothing elif prob >= 2.0/6 and prob < 3.0/6: n_aliens_after += 0 # alien dies elif prob >= 3.0/6 and prob < 5.0/6: n_aliens_after += 2 # replicates else: n_aliens_after += 3 # replicates twice n_aliens = n_aliens_after if n_aliens > 0: counter += 1 sample_estimate.append(1.0*counter/N_TRIALS) plt.figure() plt.hist(sample_estimate, bins=20) plt.xlabel('Probability') plt.ylabel('Frequency') plt.show()
Check out a similar puzzle, which involves Markov chain.