Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::sat::DisjunctiveWithTwoItems Class Reference

#include <disjunctive.h>

Inheritance diagram for operations_research::sat::DisjunctiveWithTwoItems:
operations_research::sat::PropagatorInterface

Public Member Functions

 DisjunctiveWithTwoItems (SchedulingConstraintHelper *helper)
 
bool Propagate () final
 
int RegisterWith (GenericLiteralWatcher *watcher)
 
- Public Member Functions inherited from operations_research::sat::PropagatorInterface
 PropagatorInterface ()=default
 
virtual ~PropagatorInterface ()=default
 
virtual bool IncrementalPropagate (const std::vector< int > &)
 

Detailed Description

This is an optimization for the case when we have a big number of such pairwise constraints. This should be roughtly equivalent to what the general disjunctive case is doing, but it dealt with variable size better and has a lot less overhead.

Definition at line 393 of file disjunctive.h.

Constructor & Destructor Documentation

◆ DisjunctiveWithTwoItems()

operations_research::sat::DisjunctiveWithTwoItems::DisjunctiveWithTwoItems ( SchedulingConstraintHelper * helper)
inlineexplicit

Definition at line 395 of file disjunctive.h.

Member Function Documentation

◆ Propagate()

bool operations_research::sat::DisjunctiveWithTwoItems::Propagate ( )
finalvirtual

This will be called after one or more literals that are watched by this propagator changed. It will also always be called on the first propagation cycle after registration.

We can't propagate anything if one of the interval is absent for sure.

Note
this propagation also take care of the "overload checker" part. It also propagates as much as possible, even in the presence of task with variable sizes.
Todo
(user): For optional interval whose presence in unknown and without optional variable, the end-min may not be propagated to at least (start_min
  • size_min). Consider that into the computation so we may decide the interval forced absence? Same for the start-max.

Task 0 must be before task 1.

Task 1 must be before task 0.

Reason for precedences if both present.

Reason for the bound push.

Reason for precedences if both present.

Reason for the bound push.

Implements operations_research::sat::PropagatorInterface.

Definition at line 252 of file disjunctive.cc.

◆ RegisterWith()

int operations_research::sat::DisjunctiveWithTwoItems::RegisterWith ( GenericLiteralWatcher * watcher)

Definition at line 313 of file disjunctive.cc.


The documentation for this class was generated from the following files: