Skip to content

Commit 6d3b623

Browse files
committed
export JuMP model from zero-sum game solutions
1 parent be67142 commit 6d3b623

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
- Optimize allocations in Minimal Spanning Tree.
44
- Export JuMP model from assigment problems.
5+
- Export JuMP model from zero-sum games.
6+
57

68

79
### 0.2.6

src/game.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,13 @@ A structure to hold the result of a game.
3333
3434
- `probabilities`: Probabilities of the strategies
3535
- `value`: Value of the game
36+
- `model::JuMP.Model`: The JuMP model used to solve the game.
3637
3738
"""
3839
struct GameResult
3940
probabilities::Any
4041
value::Any
42+
model::JuMP.Model
4143
end
4244

4345

@@ -95,7 +97,7 @@ function game_solver(gamematrix::Matrix{<:Real}; verbose::Bool = false)::GameRes
9597

9698
gamevalue = JuMP.value(g) #objective_value(model)
9799

98-
result = GameResult(values, gamevalue)
100+
result = GameResult(values, gamevalue, model)
99101

100102
return result
101103

0 commit comments

Comments
 (0)