Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Non-Nash output from gambit-lp on extensive game #134

Closed
tturocy opened this issue Apr 1, 2014 · 1 comment · Fixed by #423
Closed

BUG: Non-Nash output from gambit-lp on extensive game #134

tturocy opened this issue Apr 1, 2014 · 1 comment · Fixed by #423
Labels
Milestone

Comments

@tturocy
Copy link
Member

tturocy commented Apr 1, 2014

On the following game, the output of gambit-lp on the extensive game is not Nash. This error has been in place at least since revision f21b0a0 in September 2010; I cannot reliably compile earlier versions although the git blame for the relevant files indicates no changes since before 2006; this error has probably been around quite a long time. Other methods return the correct equilibrium (which is unique). At the moment, I have no leads on where this may be going wrong

EFG 2 R "Untitled Extensive Game" { "Villain" "Hero" }
""

c "Villain's card" 1 "" { "Flush" 0.01 "Air" 0.99 } 0
p "Turn" 1 1 "" { "Bet Turn with Flush" "Check Turn wish Flush" } 0
p "" 2 1 "" { "Call Turn" "Fold Turn" } 0
c "River Card" 2 "" { "Blank" 0.5 "Straight or Boat" 0.5 "Boat" 0 } 0
p "River" 1 2 "" { "Bet River with Flush" "Check River with Flush" } 0
p "" 2 2 "" { "Call River" "Fold River" } 0
t "" 1 "" { 5, -4 }
t "" 2 "" { 2, -1 }
t "" 3 "" { 2, -1 }
t "" 4 "" { 0.5, 0.5 }
t "" 5 "" { 1, 0 }
t "" 6 "" { 1, 0 }
t "" 7 "" { 0.75, 0.25 }
p "Turn" 1 3 "" { "Bluff Turn" "Doesn't Bluff Turn" } 0
p "" 2 1 "" { "Call Turn" "Fold Turn" } 0
c "River Card" 3 "" { "Blank" 0.5 "Straight or Boat" 0.5 "Boat" 0 } 0
p "River" 1 4 "" { "Bluff River" "Doesn't Bluff River" } 0
p "" 2 2 "" { "Call River" "Fold River" } 0
t "" 8 "" { -4, 5 }
t "" 9 "" { 2, -1 }
t "" 10 "" { -1, 2 }
t "" 11 "" { 0.5, 0.5 }
t "" 12 "" { 1, 0 }
t "" 13 "" { 1, 0 }
t "" 14 "" { 0.25, 0.75 }
``
@tturocy tturocy added the bug label Apr 1, 2014
@tturocy tturocy added this to the gambit-16.0.3 milestone Jan 25, 2022
@tturocy tturocy changed the title non-Nash output from gambit-lp on extensive game BUG: Non-Nash output from gambit-lp on extensive game Oct 11, 2023
@tturocy
Copy link
Member Author

tturocy commented Nov 9, 2023

Based on some other issues we have recently dealt with, I got to wondering whether it was the presence of zero-probability chance actions that was the problem. I experimented with the game below, which is the same game with the zero-probability action deleted. gambit-lp still returns non-Nash output, but importantly (1) it's different non-Nash output than the original game and (2) the output doesn't enforce sum-to-one at least information set.

These observations lead me to believe very circumstantially that the problem may be in the construction of the sequence form tableau.

At this point, it is worth observing that there is very similar code in both LCP and LP for constructing the sequence form tableau, as well as a Sfg class in solvers/enumpoly which is used to construct the systems of polynomials. It would be useful to unify these, as, in essence, the same logic appears in all three places, and further useful to expose the sequence form as a concept in its own right rather than having it embedded implicitly inside algorithms.

The above would be a good idea even if the problem here is not per se with the sequence form implementation, although it seems somehow less plausible that there would be some unknown bug in the LP solver, in particular that it would return incorrect output even in rational precision. Not impossible, but the behaviour described above seems to point the finger at the inputs.

EFG 2 R "Untitled Extensive Game" { "Villain" "Hero" }
""

c "Villain's card" 1 "" { "Flush" 0.01 "Air" 0.99 } 0
p "Turn" 1 1 "" { "Bet Turn with Flush" "Check Turn wish Flush" } 0
p "" 2 1 "" { "Call Turn" "Fold Turn" } 0
c "River Card" 2 "" { "Blank" 1/2 "Straight or Boat" 1/2 } 0
p "River" 1 2 "" { "Bet River with Flush" "Check River with Flush" } 0
p "" 2 2 "" { "Call River" "Fold River" } 0
t "" 1 "" { 5, -4 }
t "" 2 "" { 2, -1 }
t "" 3 "" { 2, -1 }
t "" 4 "" { 0.5, 0.5 }
t "" 6 "" { 1, 0 }
t "" 7 "" { 0.75, 0.25 }
p "Turn" 1 3 "" { "Bluff Turn" "Doesn't Bluff Turn" } 0
p "" 2 1 "" { "Call Turn" "Fold Turn" } 0
c "River Card" 3 "" { "Blank" 1/2 "Straight or Boat" 1/2 } 0
p "River" 1 4 "" { "Bluff River" "Doesn't Bluff River" } 0
p "" 2 2 "" { "Call River" "Fold River" } 0
t "" 8 "" { -4, 5 }
t "" 9 "" { 2, -1 }
t "" 10 "" { -1, 2 }
t "" 11 "" { 0.5, 0.5 }
t "" 13 "" { 1, 0 }
t "" 14 "" { 0.25, 0.75 }

tturocy added a commit that referenced this issue Dec 14, 2023
This corrects a bug in formulating the LP tableau for the sequence form.
Specifically, there was a missing parenthesis in setting tableau entries; the effect of this is that
the tableau was incorrect in the case of a game which had a chance node that was not the
root node.

This closes #134
tturocy added a commit that referenced this issue Dec 14, 2023
This corrects a bug in formulating the LP tableau for the sequence form.
Specifically, there was a missing parenthesis in setting tableau entries; the effect of this is that
the tableau was incorrect in the case of a game which had a chance node that was not the
root node.

This closes #134
tturocy added a commit that referenced this issue Dec 15, 2023
This corrects a bug in formulating the LP tableau for the sequence form.
Specifically, there was a missing parenthesis in setting tableau entries; the effect of this is that
the tableau was incorrect in the case of a game which had a chance node that was not the
root node.

This closes #134
tturocy added a commit that referenced this issue Dec 15, 2023
This corrects a bug in formulating the LP tableau for the sequence form.
Specifically, there was a missing parenthesis in setting tableau entries; the effect of this is that
the tableau was incorrect in the case of a game which had a chance node that was not the
root node.

This closes #134
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant