Stay organized with collections
Save and categorize content based on your preferences.
C++ Reference: class DualBoundStrengthening
Note: This documentation is automatically generated.
This detects variables that can move freely in one direction, or that can
move freely as long as their value do not cross a bound.
TODO(user): This is actually an important step to do before scaling as it can
usually reduce really large bounds!
Method |
CanFreelyDecreaseUntil | Return type: int64_t Arguments: int ref The given ref can always freely decrease until the returned value.
Note that this does not take into account the domain of the variable.
|
CannotDecrease | Return type: void Arguments: absl::Span<const int> refs, int ct_index = -1 All constraints should be mapped to one of more call to these functions.
|
CannotIncrease | Return type: void Arguments: absl::Span<const int> refs, int ct_index = -1 |
CannotMove | Return type: void Arguments: absl::Span<const int> refs, int ct_index = -1 |
NumDeletedConstraints | Return type: int Reset on each Strengthen() call.
|
ProcessLinearConstraint | Return type: void Arguments: bool is_objective,
const PresolveContext& context,
const LinearProto& linear, int64_t min_activity,
int64_t max_activity, int ct_index = -1 |
Reset | Return type: void Arguments: int num_variables Reset the class to a clean state.
This must be called before processing the constraints.
|
Strengthen | Return type: bool Arguments: PresolveContext* context Once ALL constraints have been processed, call this to fix variables or
reduce their domain if possible.
Note that this also tighten some constraint that are the only one blocking
in one direction. Currently we only do that for implication, so that if we
have two Booleans such that a + b <= 1 we transform that to = 1 and we
remove one variable since we have now an equivalence relation.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-08-06 UTC.
[null,null,["Last updated 2024-08-06 UTC."],[],["The `DualBoundStrengthening` class detects variables with directional freedom or bound-limited movement. Key actions include: identifying how far a variable can decrease freely (`CanFreelyDecreaseUntil`), marking variables that cannot decrease/increase/move (`CannotDecrease`, `CannotIncrease`, `CannotMove`), and recording the number of deleted constraints (`NumDeletedConstraints`). It processes linear constraints (`ProcessLinearConstraint`), resets its state (`Reset`), and tightens variable domains and constraints once all constraints are processed (`Strengthen`). This process is important to reduce large bounds before scaling.\n"],null,[]]