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

incorrect printing of variable indices with Gurobi 10.0.3 #9

Open
dimpase opened this issue Nov 15, 2023 · 0 comments
Open

incorrect printing of variable indices with Gurobi 10.0.3 #9

dimpase opened this issue Nov 15, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@dimpase
Copy link
Member

dimpase commented Nov 15, 2023

          You can also test installed  Gurobi backend in SAGE_ROOT, by running
./sage -tp src/sage/numerical/

which works for me. What doesn't quite work is the only other place that tests with Gurobi (if available):

sage -t --warn-long 53.9 --random-seed=148439558831923248819587417992715184495 src/sage/combinat/matrices/dancing_links.pyx
**********************************************************************
File "src/sage/combinat/matrices/dancing_links.pyx", line 1038, in sage.combinat.matrices.dancing_links.dancing_linksWrapper.to_milp
Failed example:
    p.show()                                                              # needs sage.numerical.mip
Expected:
    Maximization:
    <BLANKLINE>
    <BLANKLINE>
    Constraints:...
      one 1 in 0-th column: 1.0 <= x_0 + x_1 <= 1.0
      one 1 in 1-th column: 1.0 <= x_0 + x_2 <= 1.0
      one 1 in 2-th column: 1.0 <= x_0 + x_1 <= 1.0
      one 1 in 3-th column: 1.0 <= x_3 <= 1.0
    Variables:
      x_0 is a boolean variable (min=0.0, max=1.0)
      x_1 is a boolean variable (min=0.0, max=1.0)
      x_2 is a boolean variable (min=0.0, max=1.0)
      x_3 is a boolean variable (min=0.0, max=1.0)
Got:
    Maximization:
    <BLANKLINE>
    <BLANKLINE>
    Constraints:
      one 1 in 0-th column: 1.0 <= x_ + x_ <= 1.0
      one 1 in 1-th column: 1.0 <= x_ + x_ <= 1.0
      one 1 in 2-th column: 1.0 <= x_ + x_ <= 1.0
      one 1 in 3-th column: 1.0 <= x_ <= 1.0
    Variables:
      x_ = x_0 is a boolean variable (min=0.0, max=1.0)
      x_ = x_1 is a boolean variable (min=0.0, max=1.0)
      x_ = x_2 is a boolean variable (min=0.0, max=1.0)
      x_ = x_3 is a boolean variable (min=0.0, max=1.0)
**********************************************************************
1 item had failures:
   1 of   8 in sage.combinat.matrices.dancing_links.dancing_linksWrapper.to_milp
    [244 tests, 1 failure, 4.10 s]
----------------------------------------------------------------------
sage -t --warn-long 53.9 --random-seed=148439558831923248819587417992715184495 src/sage/combinat/matrices/dancing_links.pyx  # 1 doctest failed

So something is weird with printing constraints (no index!):

...
one 1 in 3-th column: 1.0 <= x_ <= 1.0
...

Originally posted by @dimpase in #8 (comment)

@dimpase dimpase added the bug Something isn't working label Nov 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant