Skip to content

How to turn all integer variables into reals? #4578

Discussion options

You must be logged in to vote

Disclaimer:

  • I never used this API
  • I think it's depreated

That being said:

  • A: In 99.9% of use-cases it's much more clever (and predictable) to just add a is_model_relaxed boolean-flag to your model-building code
    • This can imply that you do model your problem twice which might seem strange, but this approach is still the correct one in many use-cases (most safe and most explicit)

Howewer:

  • According to linear_solver.proto#L59 there are two more options:
    • B: Just switch / mutate solver-type to one only supporting continuous models
      • Might lead to use of a different solver which in some corner-cases can lead to problems (e.g. different behaviour in different numercial-trouble situations;…

Replies: 4 comments 4 replies

Comment options

You must be logged in to vote
1 reply
@SYury
Comment options

Answer selected by SYury
Comment options

You must be logged in to vote
1 reply
@SYury
Comment options

Comment options

You must be logged in to vote
2 replies
@SYury
Comment options

@sschnug
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants