All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Probability
Elemental game (Posted on 2005-06-16) Difficulty: 5 of 5
This game is similar to "rock, paper, scissors" in that two players independently pick one of the six things, and if one thing somehow "beats" the other, then that player wins. If both players pick the same thing, they repeat until someone wins.

Life grows on Earth.
Water douses Fire.
Air resists Cold.
Life drinks Water.
Fire consumes Air.
Cold freezes Water.
Earth smothers Fire.
Life breathes Air.
Fire and Earth both warm Cold.
Air and Water both erode Earth.
Fire and Cold both destroy Life.
Water displaces Air.

A program that plays this game has a single set of probabilities for picking each of the six things. Assuming that the program's opponent knows what these probabilities are, what probabilities will give the program the best chances of winning?

What if the rules of the game are changed so that "Water displaces Air" is replaced with "Air ripples Water"?

  Submitted by Tristan    
Rating: 3.6667 (6 votes)
Solution: (Hide)
The program cannot win more than 50% of the time because its opponent may always copy the program's strategy and win half the time by symmetry. In order for the best strategy to achieve this maximum, any one choice made by the opponent should have no more than 50% chance to win. In fact, since the opponent can win 50% by symmetry, we can show that the opponent has exactly 50% chance to win if he chooses any of the elements that the program occasionally may choose.

Let the optimal probability of picking each thing be named by the first letter. If the opponent picks, for example, Life, his chance of winning is shown by the following equation:
(E+W+A)/(1-L)

Since we know this must be less than 1/2, we can simplify:
1/2 ≥ (E+W+A)/(1-L)
1/2 - L/2 ≥ E+W+A
1/2 ≥ L/2 + E+W+A
1 ≥ L + 2(E+W+A)

If L isn't 0, then ≥ can be changed to = (referring to the last sentence of the first paragraph). Already, we can set up a system of 6 equations, and solve for the optimal probabilities. The rest of the problem is figuring out an efficient way of solving the six inequalities. There are many ways to do this, and you may look to the comments to see other users’ thoughts.

I personally solved this by using a calculator to calculate inverse matrices. The matrix multiplication looked like this for the first version of the game:

[1 2 2 2 0 0] [L]   [1]
[0 1 2 2 2 0] [W]   [1]
[0 0 1 2 0 2] [A] = [1]
[0 0 0 1 2 2] [E]   [1]
[2 0 2 0 1 2] [F]   [1]
[2 2 0 0 0 1] [C]   [1]
This method has its flaws, since it solves it as if there were no inequalities, which is only a correct assumption if all the variables are greater than zero. I had to do guesswork to find out which variables were zero.

The results:
In the first version of the game, the program's best strategy is to never pick Air, and pick each of the other elements 1/5 of the time. In the second version, the program should never pick Earth, but pick Water and Fire 1/3 of the time each, and the rest of the elements 1/9 of the time each.

Comments: ( You must be logged in to post comments.)
  Subject Author Date
solution question???Jason2005-07-14 03:32:58
No Subjectjeremy2005-07-02 06:13:26
re: Compliments, and correctionsTristan2005-06-22 01:11:32
Some ThoughtsCompliments, and correctionsSteve Herman2005-06-21 19:32:05
re(3): First part solution? / Second part solutionyocko2005-06-21 08:59:11
second solutionBob Smith2005-06-21 01:42:11
re(2): First part solution? / Second part solutionMatt2005-06-20 17:11:16
SolutionBoth solutionsFederico Kereki2005-06-20 15:56:44
re: First part solution? / Second part solutionyocko2005-06-20 04:17:39
Some ThoughtsPerhaps a solution...strange ods (even for me)Cougar Draven2005-06-20 02:14:54
First part solution?Matt2005-06-17 04:59:57
re: Expected resultSteve Herman2005-06-17 03:49:51
Expected resultFederico Kereki2005-06-17 02:29:42
re: Spoiler: Computers can be beat!Steve Herman2005-06-17 01:30:57
SolutionSpoiler: Computers can be beat!Steve Herman2005-06-17 01:03:13
Some ThoughtsHow to solve thisOld Original Oskar!2005-06-16 22:36:27
Some ThoughtsRanking the ElementsJer2005-06-16 20:10:33
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information