Catch that mouse!

A mouse lives inside a wall and has three holes that he travels between. You have a flashlight and want to shine it on the mouse.

At time t = 1 t = 1 the mouse will be at one of the holes with probability 1 3 \frac{1}{3} . For each integer i > 1 , i > 1, at time t = i , t = i, the mouse moves to a hole different from the one it was at for time t = i 1 , t = i-1, with probability 1 2 \frac{1}{2} of moving to either hole.

For each integer time t = 1 , 2 , , t = 1, 2, \ldots, you choose one of the three holes and shine your light in it. Let E E be the expected time you take to shine your flashlight onto the mouse for the first time. Using an optimal strategy, the smallest possible value of E E can be expressed as a b \frac{a}{b} where a a and b b are coprime positive integers. What is the value of a + b ? a + b?

Details and assumptions

If E E is an integer, then a b = E 1 . \frac{a}{b} = \frac{E}{1}.


The answer is 10.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

5 solutions

We label the holes A , B , C A,B,C in some order and show that the best strategy is choosing one hole and sticking to it.

Clearly, at t = 1 t = 1 , the probability of finding the mouse is 1 3 \frac{1}{3} . Let's assume we pointed our flashlight at hole B B . If we use the alleged best strategy (that is, if we continue to point the flashlight at B B ), the probability of finding the mouse at t = 2 t = 2 is 2 3 1 2 = 1 3 \frac{2}{3}\cdot\frac{1}{2} = \frac{1}{3} because the mouse was not in B B at t = 1 t=1 (which has a probability of 2 3 \frac{2}{3} of happening) and so it has a probability of 1 3 \frac{1}{3} of being in B B at t = 2 t=2 .

If we use a different strategy (that is, if we switch which hole we are pointing our flashlight at), the probability changes to only 2 3 1 4 = 1 6 \frac{2}{3} \cdot \frac{1}{4} = \frac{1}{6} . To illustrate this, assume we switch to A A at t = 2 t = 2 . If the mouse was in A A at t = 1 t=1 (which has a probability of 1 2 \frac{1}{2} of being the case, since the mouse was not in B B and must therefore have been in either A A or C C ), then it can't possibly be in A A at t = 2 t=2 because the mouse switches holes every time t t increases. If the mouse was in C C at t = 1 t=1 , then it has a probability of 1 2 \frac{1}{2} of being in A A at t = 2 t=2 . This gives a total probability of 2 3 ( 1 2 0 + 1 2 1 2 ) = 1 6 \frac{2}{3}(\frac{1}{2}\cdot 0 + \frac{1}{2} \cdot \frac{1}{2}) = \frac{1}{6} for the mouse being in A A at t = 2 t=2 .

This argument can of course be extended to other times. If we select a hole at time t = i t = i and do not find the mouse, the probability that the mouse will be in that hole at t = i + 1 t = i + 1 is twice the probability that it is in each of the other two holes, and so picking a single hole and sticking to it is the best possible strategy. QED

\\

We proceed to find the expected value of the amount of time it takes to find the mouse using this strategy. The probability that we find the mouse at t = 1 t = 1 is 1 3 \frac{1}{3} . With probability 2 3 \frac{2}{3} , we will have to check the hole again, and so the probability of finding the mouse at t = 2 t=2 is 2 3 1 2 \frac{2}{3} \cdot \frac{1}{2} . In general, the probability of finding the mouse at time t = i , i > 1 t = i, i>1 is 2 3 1 2 i 1 \frac{2}{3} \cdot \frac{1}{2^{i-1}} . Thus, our desired expected value is 1 3 1 + 2 3 ( i = 2 ( 1 2 i 1 i ) ) \frac{1}{3} \cdot 1 + \frac{2}{3} (\sum_{i=2}^{\infty} (\frac{1}{2^{i-1}} \cdot i)) . We evaluate the sum using simple arithmetic/geometric sequence techniques and find that it is equal to 3 3 .

Thus, a b = 1 3 + 2 3 3 = 7 3 a + b = 10 \frac{a}{b} = \frac{1}{3} + \frac{2}{3} \cdot 3 = \frac{7}{3} \to a + b = \fbox{10} .

More simply, the optimal strategy is just one where if at t = n t = n the mouse is at hole A A , at t = n + 1 t = n+1 you don't shine the flashlight at hole A A .

Michael Tong - 7 years, 8 months ago
Johan de Ruiter
Sep 15, 2013

At t 1 t_1 , we can not do better than probability 1 3 \frac{1}{3} . If we don't find the mouse, we keep shining our flashlight into the same hole until we find it.

Given that we didn't find the mouse at time t i t_i , it will appear in our hole at time t i + 1 t_{i+1} with probability 1 2 \frac{1}{2} . We can not do better than that - not even if we know exactly where the mouse was as at time t i t_i .

So we wait 1 1 second at first, after which with probability 2 3 \frac{2}{3} we're not done yet. From that point onwards there is an expected waiting time x x of 2 2 seconds ( x = 1 + x 2 x=1+\frac{x}{2} , so x = 2 x=2 ).

E = 1 + 2 3 × 2 = 7 3 E = 1 + \frac{2}{3} \times 2 = \frac{7}{3}

Michael Tong
Sep 20, 2013

It is easy to see that the probability of getting the mouse on the first second is 1 3 \frac{1}{3} , on the second second it is 2 3 ( 1 2 ) \frac{2}{3} (\frac{1}{2}) , on the third second it is 2 3 ( 1 2 ) 2 \frac{2}{3} (\frac{1}{2})^2 and so on if you play optimally (That is, if at t = 2 t = 2 the mouse is at hole 3 3 , you don't then point the flashlight on hole 3 3 at t = 3 t = 3 ). So we need to compute

1 3 + 2 ( 2 3 ) ( 1 2 ) + 3 ( 2 3 ) ( 1 2 ) 2 + . . . \frac{1}{3} + 2(\frac{2}{3})(\frac{1}{2}) + 3(\frac{2}{3})(\frac{1}{2})^2 + ...

Pull out 1 3 \frac{1}{3} and 2 3 ( 1 2 + ( 1 2 ) 2 + ( 1 2 ) 3 + . . . ) \frac{2}{3}(\frac{1}{2} + (\frac{1}{2})^2 + (\frac{1}{2})^3 + ...) . The latter expression, as it is geometric with r < 1 |r| < 1 , equals 2 3 ( 1 2 1 1 2 ) = 2 3 \frac{2}{3}( \frac{\frac{1}{2}}{1 - \frac{1}{2}}) = \frac{2}{3} . Now, the leftover sum is the following: 2 3 ( 1 2 + 2 ( 1 2 ) 2 + 3 ( 1 2 ) 3 + . . . ) \frac{2}{3}(\frac{1}{2} + 2(\frac{1}{2})^2 + 3(\frac{1}{2})^3 + ...)

This sum can be written as an infinite sequence of infinite geometric sequences, namely S 1 = 2 3 ( 1 2 + ( 1 2 ) 2 + ( 1 2 ) 3 + . . . ) , S 2 = 2 3 ( ( 1 2 ) 2 + ( 1 2 ) 3 + . . . . . . ) S_1 = \frac{2}{3}(\frac{1}{2} + (\frac{1}{2})^2 + (\frac{1}{2})^3 + ...), S_2 = \frac{2}{3}((\frac {1}{2})^2 + (\frac{1}{2})^3 + ... ...) .

Using the formula for infinite geometric sequences this equals

2 3 ( 1 2 1 2 + ( 1 2 ) 2 1 2 + . . . ) \frac {2}{3} (\frac {\frac {1}{2}}{\frac {1}{2}} + \frac{(\frac{1}{2})^2}{\frac{1}{2}} + ...)

Modifying it further, this sequence equals 2 3 ( 1 + 1 2 + ( 1 2 ) 2 + . . . ) \frac{2}{3}(1 + \frac{1}{2} + (\frac{1}{2})^2 + ...) . Now it is clear that this sequence is ALSO geometric, giving us 2 3 ( 1 1 1 2 ) = 4 3 \frac{2}{3}(\frac{1}{1 - \frac{1}{2}}) = \frac {4}{3} .

Now, adding this back to the two components of the equation we pulled out, we get E = 4 3 + 1 3 + 2 3 = 7 3 a + b = 10 E = \frac {4}{3} + \frac{1}{3} + \frac {2}{3} = \frac{7}{3} \rightarrow a + b = 10 .

Sanjay Meena
Sep 17, 2013

Simple problem if you understand it,

it's *1+ 2 3 \frac{2}{3} 2= 7 3 \frac{7}{3} **

7+3=10

...................................................................................................................

Zi Song Yeoh - 7 years, 8 months ago

Care to explain?

Daniel Chiu - 7 years, 8 months ago

A bit more explanation, please!

Assuming that you got the result that the spotlight remains constant without justification, you still have to calculate 1 3 + 2 3 k = 2 k 2 k 1 \frac{1}{3} + \frac{2}{3}\sum \limits_{k=2}^{\infty } \frac{k}{2^{k-1}} .

Sreejato Bhattacharya - 7 years, 8 months ago
Ganesh Sundaram
Sep 17, 2013

Optimal strategy is to keep observing at the same hole itself.

The probability of observing the mouse at a particular hole at t = 1 t=1 is 1/3.

If not observed in that hole, with probability 2/3, from one of the other two holes, the mouse can appear with equal probability of 1/2 in the hole being looked at or the other of the two other holes. Thus the probability of observing the mouse at t = 2 t=2 is 2 3 × 1 2 . \frac{2}{3} \times \frac{1}{2}.

Probability of not finding the mouse at the given hole at t = 2 t=2 is the same as above. This process can be repeated once again, and the probability of finding the mouse at t = 3 t=3 at the hole being observed at is 2 3 × 1 2 × 1 2 = 2 3 × 1 2 2 . \frac{2}{3} \times \frac{1}{2} \times \frac{1}{2} = \frac{2}{3} \times \frac{1}{2^2}. This process goes ad infinitum.

Thus expected observing time is given by the series t = 1 3 × 1 + 2 3 × 1 2 × 2 + 2 3 × 1 2 2 × 3 + . \langle t \rangle = \frac{1}{3} \times 1 + \frac{2}{3} \times \frac{1}{2} \times 2 + \frac{2}{3} \times \frac{1}{2^2} \times 3 + \cdots. This sum can be expressed in the form t = 1 3 + 2 3 ( n = 1 n + 1 2 n ) \langle t \rangle = \frac{1}{3} + \frac{2}{3} \left( \sum_{n=1}^\infty \frac{n+1}{2^n} \right)

The sum in the parenthesis can be evaluated using standard tricks with geometric ratio variable x = 1 / 2 x = 1/2 S ( x ) = n = 1 ( n + 1 ) x n = x n = 1 x n + 1 = x x 2 1 x . S(x) = \sum_{n=1}^\infty (n+1) x^n = \frac{\partial}{\partial x} \sum_{n=1}^\infty x^{n+1} = \frac{\partial}{\partial x} \frac{x^2}{1-x}. Thus, with S ( x ) = 2 x 1 x + x 2 ( 1 x ) 2 , S ( 1 / 2 ) = 3. S(x) = \frac{2x}{1-x} + \frac{x^2}{(1-x)^2}, \qquad S(1/2) = 3.

Therefore the expected time of first observation of the mouse is t = 1 3 + 2 3 × 3 = 2 1 3 = 7 3 . \langle t \rangle = \frac{1}{3} + \frac{2}{3} \times 3 = 2 \frac{1}{3} = \frac{7}{3}.

The difficult part of this problem is explaining why the optimal strategy is indeed to "keep observing at the same hole itself". That needs to be clearly explained.

Calvin Lin Staff - 7 years, 8 months ago

Log in to reply

I don't understand why the optimatl strategy is keeping it at the same hole. Can't the optimal strategy also involve switching holes (though not going to the hole that it is impossible for the mouse to be in) since the probability is the same for all holes that were not just used (and each event is independent of the last)?

Michael Tong - 7 years, 8 months ago

I did make some the calculations, for the case when we do not look into the same hole, which I did not present.

If the observer did not spot the mouse at a chosen hole, then instead of choosing to observe the same hole, he looked in to one of the two other holes, the probability of observing the mouse when a different hole is chosen is lesser than if he chose the same hole. This is especially true given that appearance of a mouse in three holes is dependent on history, that is if the mouse appears at a particular hole at a given instant then it cannot appear again in the same hole at the next instance of observation. A proof:

Let us name the holes A, B, C. The first choice of observation be A. And for the case the mouse did not appear first, probability of observing the mouse at A at t = 2 is given above (1/3).

Other possibilities of observation is choice B and C and probabilities of mouse present in one of them at t=1 is 1/2 given that the mouse not found at A at t = 1.

By symmetry, probability of finding mouse at t = 2 either in B or C is the same. So, let us do the calculations for looking into B.

Case 1: mouse was at B at t = 1 with conditional probability 1/2. Then the contribution to probability of finding the mouse at B at t = 2 from this possibility is zero.

Case 2: mouse was at C at t = 1 with the conditional probability 1/2. Then at t = 2, mouse can jump to A or B with equal probability of 1/2.

Thus the probability of observing the mouse at B at t = 2 is ( Pr. of not finding at A at t = 1 ) × ( Pr. of being at C at t = 1 given that it was not found at A at t = 1 ) × ( Pr. of jumping to B at t = 2 ) (\text{Pr. of not finding at A at } t = 1) \times (\text{Pr. of being at C at } t=1 \\ \text{ given that it was not found at A at } t = 1) \times \\ (\text{Pr. of jumping to B at } t = 2) which equals 2 3 × 1 2 × 1 2 = 1 6 , \frac{2}{3} \times \frac{1}{2} \times \frac{1}{2} = \frac{1}{6}, which is only half of the situation for observing at A again at t = 2.

Ganesh Sundaram - 7 years, 8 months ago

Log in to reply

I did not realize that Mr. Sotiri K has already written up the solution. Only after posting this I looked into his solution. Nevertheless this posting can serve as a more verbose explanation.

Ganesh Sundaram - 7 years, 8 months ago

It doesn't matter to the strategy whether you switch hole or not, as long as you don't look in the hole the mouse was just at. It has exactly the same chance of appearing in either of the two places it could appear, so you do equally well by checking either one.

Matt McNabb - 7 years, 8 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...