Mathematics and Darts!

In this blog post I am going to talk about one of my favorite math problems. When I first solved this problem, I developed a method that can be generalized to a lot of other similar problems. The problem is as follows:
Alice and Bob take turns throwing darts at a dartboard (with Alice going first). At each turn, Alice will try to get it closer to the center than Bob's last throw and vice versa. The game ends when one of the players doesn't get it closer than the other player's previous throw. Alice and Bob are equally skilled at throwing darts and they are guaranteed to hit the dart board.
What is the probability that Alice wins?
To help you visualize this problem, I created a simple program in Racket (then compiled it to JavaScript using whalesong.) You can visualize the game being played by pressing the Right Arrow Key (make sure the frame is in focus). You can speed up the simulation by pressing the Space Bar (you can pause the simulation by pressing it again.)

 

In the above simulation, the red circles indicate the location of Alice's throws, and the green circles indicate the location of Bob's throws (the exact location is not shown, only the distance from the center). Alice goes first so she cannot lose on the first turn. Then Bob goes and he must get it within the red circle that Alice just established. If he succeeds, then Alice must get her next throw within the green circle that Bob just established. The score is recorded in the top corners, with Alice's score in the top left and Bob's score in the top right.

If you run the simulation long enough, you'll probably notice that Alice has an advantage in this game. Let's find out why!


Comments

Post a Comment

Popular posts from this blog

Multi-Core Programming with Java

Beat the Streak: Day Three

Efficiently Remove Duplicate Rows from a 2D Numpy Array