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

[docs] fix bounds in big-M examples of tips_and_tricks.jl #3721

Merged
merged 2 commits into from
Apr 2, 2024
Merged

Conversation

odow
Copy link
Member

@odow odow commented Apr 2, 2024

Follow-up to #3720

@remi-garcia how is this?

Copy link

codecov bot commented Apr 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.42%. Comparing base (af30cde) to head (2e6afd9).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3721   +/-   ##
=======================================
  Coverage   98.42%   98.42%           
=======================================
  Files          43       43           
  Lines        5825     5825           
=======================================
  Hits         5733     5733           
  Misses         92       92           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@remi-garcia
Copy link
Contributor

It is better, it is consistent that way. But I am wondering why in

In addition, if the variables involved have finite domains, then JuMP can automatically reformulate an indicator into a mixed-integer program.

variables must have a finite domain and not just upper bounds in case of <= and lower bounds in case of >=.

I will try to have a look at the JuMP reformulation as I think that it is possible to have JuMP to automatically reformulate an indicator into a mixed-integer program whenever there is the right bound and not just with finite domains.

@odow
Copy link
Member Author

odow commented Apr 2, 2024

I will try to have a look at the JuMP reformulation as I think that it is possible to have JuMP to automatically reformulate an indicator into a mixed-integer program whenever there is the right bound and not just with finite domains.

Yes, that's possible. I just went with the simplest thing.

The relevant bridge is https://github.com/jump-dev/MathOptInterface.jl/blob/master/src/Bridges/Constraint/bridges/indicator_to_milp.jl

@odow odow merged commit 617f961 into master Apr 2, 2024
11 checks passed
@odow odow deleted the odow-patch-1 branch April 2, 2024 19:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants