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

outerapproximation cannot find vertices correctly #52

Closed
shizejin opened this issue Sep 17, 2017 · 4 comments
Closed

outerapproximation cannot find vertices correctly #52

shizejin opened this issue Sep 17, 2017 · 4 comments

Comments

@shizejin
Copy link
Member

Hi @cc7768, I was trying to replicate the result of the example demonstrated at the bottom of the notebook A Recursive Formulation of Repeated Games, but failed:

julia> using Games

julia> pd_payoff = [9.0 1.0
                    10.0 3.0]
2×2 Array{Float64,2}:
  9.0  1.0
 10.0  3.0

julia> A = Player(pd_payoff)
2×2 Player{2,Float64}:
  9.0  1.0
 10.0  3.0

julia> B = Player(pd_payoff)
2×2 Player{2,Float64}:
  9.0  1.0
 10.0  3.0

julia> pd = NormalFormGame((A, B))
2×2 NormalFormGame{2,Float64}

julia> rpd1 = RepeatedGame(pd, 0.9)
Games.RepeatedGame{2,Float64}(2×2 NormalFormGame{2,Float64}, 0.9)

julia> hp_pts1 = outerapproximation(rpd1; nH=128, maxiter=750, tol=1e-8);

julia> hp_pts1
7×2 Array{Float64,2}:
 9.63111  4.7454 
 9.0      9.0    
 3.25054  9.85285
 3.0      9.80302
 2.1328   3.95681
 3.0      3.0    
 9.80302  3.0    

Plot it out:

2017-09-17 10 28 46

The vertex [2.1328, 3.95681] should not appear here.

I wonder if this is caused by the mistake that would occur when doing transformation between Hrep and Vrep by polyhedron. JuliaPolyhedra/Polyhedra.jl#48

@cc7768
Copy link
Member

cc7768 commented Sep 18, 2017

Thanks for opening this @shizejin -- That point definitely should not be there.

I will try and have a closer look at this soon and determine whether there might be a bug in computing the hyperplanes or whether it comes from the issue you raised in Polyhedra (thank you @blegat for always being so responsive!).

@blegat
Copy link

blegat commented Sep 18, 2017

No problem ! It is always helpful to get tricky test cases ;)

@oyamad
Copy link
Member

oyamad commented Nov 24, 2017

@shizejin Has this been resolved?

@shizejin
Copy link
Member Author

shizejin commented Dec 1, 2017

I believe this problem has been solved by JuliaPolyhedra/Polyhedra.jl#49 and JuliaPolyhedra/Polyhedra.jl#51. @oyamad

@shizejin shizejin closed this as completed Dec 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants