cpsat-primer icon indicating copy to clipboard operation
cpsat-primer copied to clipboard

Suggestions for Chapter 5: Advanced Modelling

Open leonlan opened this issue 6 months ago • 4 comments

  • [x] Structure: It could be beneficial to rearrange the topics here: specifically, I suggest putting the Intervals section right after Tour constraints. Scheduling is one of the most used applications of OR-Tools, while automaton/reservoir constraints seem more niche to me.

  • [ ] Question: There are a lot of different interval variable creation methods (fixed size, optional, etc.). Are they different from each other or is it just a simple interface? For instance, you can also pass constant values to the start/end/size arguments in new_interval_var. I would assume that preprocessing takes care of the redundancies but I'm not sure about that.

    The new_optional_interval_var is the most expressive but also the most expensive, while the new_fixed_size_interval_var is the least expressive and the easiest to optimize.

  • [ ] Content: In my opinion, it is a bit much to describe all types of intervals here. Only keeping variable-sized interval variables should be enough to explain the concept of interval variables, while the fixed-size types can be briefly mentioned in a line or two afterwards (and the reason when to use fixed-size intervals). (Note: My perspective mostly comes from OR-Tools' machine scheduling examples which don't use fixed-size intervals.)

leonlan avatar Aug 06 '24 09:08 leonlan