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

Parsing errors on MIPLIB mps files when using CoinUtils library. #197

Open
JoD opened this issue Sep 5, 2022 · 5 comments
Open

Parsing errors on MIPLIB mps files when using CoinUtils library. #197

JoD opened this issue Sep 5, 2022 · 5 comments

Comments

@JoD
Copy link

JoD commented Sep 5, 2022

Over at Exact we're using CoinUtils as parser for .mps and .lp files. This works most of the time, but for some MIPLIB mps files, CoinUtils raises errors. More info on https://gitlab.com/JoD/exact/-/issues/19 .

Any idea on what's going on? Is this behavior a non-adherence to the mps standard by MIPLIB, a bug in the CoinUtils parser, or an incorrect use of the parser on Exact's side?

@jjhforrest
Copy link
Contributor

jjhforrest commented Sep 5, 2022 via email

@JoD
Copy link
Author

JoD commented Sep 5, 2022

The ideal case would be to have these "indicators" in fitting data structures, but I can imagine this breaks a bit too much of the row-column view of the problem that's currently used.

The second-best case would be a proper calculation of the big-M, based on the bounds of the variables. You did not mention this. Is this hard? Perhaps when some of the variables are unbounded?

The "recognizable value for M" would work in a pinch. I'm a bit worried about a user using this "flag-coefficient" unintentionally. But maybe this can be minimized by using inf or NaN or some other floating point special case value. If we need an actual number, we could go for -0 or the largest possible double or the smallest possible double (in the epsilon sense: 0.00...01).

In any case, thanks for the insight! I had no idea it was some unsupported extension to the mps format.

@JoD
Copy link
Author

JoD commented Sep 5, 2022

What do you mean with

Except for the case x+y+z==c the CoinUtils version would be an approximation to the correct version.

?

@jjhforrest
Copy link
Contributor

jjhforrest commented Sep 5, 2022 via email

@JoD
Copy link
Author

JoD commented Sep 5, 2022

Indicators don't seem to work like that - the implicit big M should be calculated at all stages of code.

Is this for the continuous case? If all variables are integral, I guess one calculation of the big M would be sufficient? I.e., Any large value would do? In any case, I trust your judgment here.

As to x+y+z==b - with <= or >= you can have a reasonable modified constraint - with == the new constraint would be infeasible.

So if I understand correctly, if we have binary1 -> (x+y+z==c), then the proposed transcription x+y+z==c+M*binary1 would not approximate the original, while for >= or =< it would? So in the == case, it would be necessary to check the M-flag to avoid incorrect answers?

Would it make sense to split the == into its >= and =< components and add the constraints for binary1 -> (x+y+z>=c) and binary1 -> (x+y+z=<c)?

Apologies for all these questions, and thanks for your explanations so far!

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

2 participants