Two Random Walks

Bug A A starts on the origin on the coordinate plane and makes 3 3 random unit moves only in the four compass directions (Up, Down, Left, Right). Bug B B starts on coordinate ( 1 , 0 ) (1,0) and makes two random unit moves only in the four compass directions. The probability that bug B B is closer or equal in distance to the origin with bug A A can be expressed as p q \dfrac{p}{q} for positive coprime integers p , q . p,q. Find p + q p+q .

Image credit: DoMathTogether


The answer is 443.

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.

1 solution

Ivan Koswara
Apr 3, 2014

Observe that the first move of A doesn't affect anything; we can rotate the grid so A moves to the right, and all the distances remain equal. In addition, A and B don't interact with each other, so let's as well put A and B on the same starting point, ( 1 , 0 ) (1,0) , moving two steps randomly.

image image

It can be verified that the numbers in red, green, and blue above are the number of ways to get to that node with exactly two steps; all other nodes have zero ways to reach in exactly two steps from the central red node. From here, we can also observe that there are three distinct distances: 1 \sqrt{1} (pink), having 9 9 ways to arrive there; 5 \sqrt{5} (orange), having 6 6 ways to arrive there; 9 \sqrt{9} (purple), having 1 1 way to arrive there. Note that there are 16 16 ways in total, so the probability for each distance is simply the number of ways to arrive with that distance divided by 16 16 .

Thus the rest is immediate. For each distance, compute the probability that B arrives to that distance and multiply it with the probability that A arrives to that distance or more.

P = 9 16 ( 9 + 6 + 1 16 ) + 6 16 ( 6 + 1 16 ) + 1 16 1 16 P = \frac{9}{16} \cdot \left( \frac{9+6+1}{16} \right) + \frac{6}{16} \cdot \left( \frac{6+1}{16} \right) + \frac{1}{16} \cdot \frac{1}{16}

= 9 16 + 6 7 + 1 1 16 16 = \frac{9 \cdot 16 + 6 \cdot 7 + 1 \cdot 1}{16 \cdot 16}

= 187 256 = \frac{187}{256}

And so p + q = 187 + 256 = 443 p+q = 187+256 = \boxed{443} .

Great solution! I love your insight on how the first move of A does not affect anything. Definitely deserves an upvote.

Daniel Liu - 7 years, 2 months ago

I solved it the same way. A fun question!

Nicolas Bryenton - 7 years, 1 month ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...