C++ Reference: class SharedBoundsManager

This documentation is automatically generated.

This class manages a pool of lower and upper bounds on a set of variables in a parallel context.
Method
GetChangedBounds

Return type: void

Arguments: int id, std::vector<int>* variables, std::vector<int64>* new_lower_bounds, std::vector<int64>* new_upper_bounds

When called, returns the set of bounds improvements since the last time this method was called with the same id.

RegisterNewId

Return type: int

Returns a new id to be used in GetChangedBounds(). This is just an ever increasing sequence starting from zero. Note that the class is not designed to have too many of these.

ReportPotentialNewBounds

Return type: void

Arguments: const CpModelProto& model_proto, const std::string& worker_name, const std::vector<int>& variables, const std::vector<int64>& new_lower_bounds, const std::vector<int64>& new_upper_bounds

Reports a set of locally improved variable bounds to the shared bounds manager. The manager will compare these bounds changes against its global state, and incorporate the improving ones.

SharedBoundsManager

Return type: explicit

Arguments: const CpModelProto& model_proto

Synchronize

Return type: void

Publishes any new bounds so that GetChangedBounds() will reflect the latest state.