Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am currently reading the sci-fi novel Manifold: Time by Stephen Baxter, which contains the following problem.

You are given a box which has either 10 marbles or 1000 marbles. By pressing a lever on the box, one marble is randomly taken out and given to you. You know that there is exactly one red marble.

After pressing the lever three times, you obtain a red marble. The book claims that this information implies, using Bayes' theorem, that the probability that there are 10 marbles in the box is 2/3.

Can anyone explain how this computation actually works out, or at least how one is supposed to set up Bayes' equation to get this answer? Thanks.

share|cite|improve this question

Let $N$ be the unknown number of marbles in the box.

The question is ambiguous on whether (i) you press the lever three times and obtain the red marble on one of the three tries, or (ii) you press the lever three times and obtain the red marble only on the third try.

Assuming the latter case, the probability that you get the red marble on the third try is $$P(k=3|N=n)=\frac{n-1}n\cdot\frac{n-2}{n-1}\cdot\frac1{n-2}=\frac1n.$$ So $P(k=3|N=10) = 1/10$ and $P(k=3|N=1000) = 1/1000$. By Bayes' theorem, $$\begin{align} P(N=10|k=3)&=\frac{P(k=3|N=10)P(N=10)}{\sum_n P(k=3|N=n)P(N=n)}\\ &= \frac{\frac1{10}P(N=10)}{\frac1{10}P(N=10) + \frac1{1000}P(N=1000)}. \end{align}$$

This only turns out to be $\frac23$ if your prior on the box having ten marbles is $P(N=10)=\frac1{51}$.

share|cite|improve this answer
Also, you are taking a view on what he means that "after pressing the level three times..." Basically, your reading is no different than if he said, "after pressing the lever once." I suspect he means that you get a red marble in one of the first three lever presses. You still don't get the 2/3 probability, though – Thomas Andrews Jan 5 '13 at 22:35
@Thomas: Yes, I should have been more explicit. I thought about it for a bit, then decided that if (in real life) someone pressed the lever once and got a red marble, they would not press it two more times unless they were acting out a probability theory exercise. – Rahul Jan 5 '13 at 22:39
@Thomas: Would you say the same thing if the question read "After pressing the lever eleven times, you obtain a red marble"? – Rahul Jan 5 '13 at 22:49
Probably. As I said, the language is ambiguous, so your reading is not wrong, it's just that $3$ is a red herring in that reading. Hardly impossible, however, that this is what he meant. – Thomas Andrews Jan 5 '13 at 23:01
Also, if the problem said $11$, then $11$ would not be a red herring, which would make it more likely he meant after the eleventh press. – Thomas Andrews Jan 5 '13 at 23:07

Something doesn't sound complete about this problem the way it is posited. No prior is known. The probability of N=10 if the author says the probability is $\frac{2}{3}$ works out only if the prior is $\frac{1}{51}$ as mentioned above.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.