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

Detailed Description

Definition at line 40 of file no_overlap_2d_helper.h.

#include <no_overlap_2d_helper.h>

Inheritance diagram for operations_research::sat::NoOverlap2DConstraintHelper:
operations_research::sat::PropagatorInterface

Public Member Functions

 NoOverlap2DConstraintHelper (std::vector< AffineExpression > x_starts, std::vector< AffineExpression > x_ends, std::vector< AffineExpression > x_sizes, std::vector< LiteralIndex > x_reason_for_presence, std::vector< AffineExpression > y_starts, std::vector< AffineExpression > y_ends, std::vector< AffineExpression > y_sizes, std::vector< LiteralIndex > y_reason_for_presence, Model *model)
void RegisterWith (GenericLiteralWatcher *watcher, absl::Span< const Literal > enforcement_literals)
bool SynchronizeAndSetDirection (bool x_is_forward_after_swap=true, bool y_is_forward_after_swap=true, bool swap_x_and_y=false)
bool IsOptional (int index) const
bool IsPresent (int index) const
bool IsAbsent (int index) const
Rectangle GetBoundingRectangle (int index) const
Rectangle GetLevelZeroBoundingRectangle (int index) const
bool IsFixed (int index) const
std::pair< IntegerValue, IntegerValue > GetBoxSizesMax (int index) const
std::pair< IntegerValue, IntegerValue > GetLevelZeroBoxSizesMin (int index) const
bool IsEnforced () const
void ResetReason ()
void WatchAllBoxes (int id)
bool PropagateRelativePosition (int first, int second, PairwiseRestriction::PairwiseRestrictionType type)
RectangleInRange GetItemRangeForSizeMin (int index) const
ItemWithVariableSize GetItemWithVariableSize (int index) const
bool ReportConflictFromTwoBoxes (int box1, int box2)
bool ReportConflictFromInfeasibleBoxRanges (absl::Span< const RectangleInRange > ranges)
void AddXSizeMinReason (int index)
void AddYSizeMinReason (int index)
void AddSizeMinReason (int index)
void AddLeftMinReason (int index, IntegerValue lower_bound)
void AddLeftMaxReason (int index, IntegerValue upper_bound)
void AddBottomMinReason (int index, IntegerValue lower_bound)
void AddBottomMaxReason (int index, IntegerValue upper_bound)
void AddPresenceReason (int index)
bool IncreaseLeftMin (int index, IntegerValue new_lower_bound)
bool ReportConflict ()
int NumBoxes () const
bool Propagate () override
SchedulingConstraintHelperx_helper () const
SchedulingConstraintHelpery_helper () const
SchedulingDemandHelperx_demands_helper ()
SchedulingDemandHelpery_demands_helper ()
const CompactVectorVector< int > & connected_components () const
int64_t InProcessingCount () const
int64_t LastLevelZeroChangeIdx () const
Public Member Functions inherited from operations_research::sat::PropagatorInterface
 PropagatorInterface ()=default
virtual ~PropagatorInterface ()=default
virtual bool IncrementalPropagate (const std::vector< int > &)

Constructor & Destructor Documentation

◆ NoOverlap2DConstraintHelper()

operations_research::sat::NoOverlap2DConstraintHelper::NoOverlap2DConstraintHelper ( std::vector< AffineExpression > x_starts,
std::vector< AffineExpression > x_ends,
std::vector< AffineExpression > x_sizes,
std::vector< LiteralIndex > x_reason_for_presence,
std::vector< AffineExpression > y_starts,
std::vector< AffineExpression > y_ends,
std::vector< AffineExpression > y_sizes,
std::vector< LiteralIndex > y_reason_for_presence,
Model * model )
inline

Definition at line 42 of file no_overlap_2d_helper.h.

Member Function Documentation

◆ AddBottomMaxReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddBottomMaxReason ( int index,
IntegerValue upper_bound )
inline

Definition at line 203 of file no_overlap_2d_helper.h.

◆ AddBottomMinReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddBottomMinReason ( int index,
IntegerValue lower_bound )
inline

Definition at line 197 of file no_overlap_2d_helper.h.

◆ AddLeftMaxReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddLeftMaxReason ( int index,
IntegerValue upper_bound )
inline

Definition at line 191 of file no_overlap_2d_helper.h.

◆ AddLeftMinReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddLeftMinReason ( int index,
IntegerValue lower_bound )
inline

Definition at line 177 of file no_overlap_2d_helper.h.

◆ AddPresenceReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddPresenceReason ( int index)
inline

Definition at line 207 of file no_overlap_2d_helper.h.

◆ AddSizeMinReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddSizeMinReason ( int index)
inline

Definition at line 163 of file no_overlap_2d_helper.h.

◆ AddXSizeMinReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddXSizeMinReason ( int index)
inline

Definition at line 161 of file no_overlap_2d_helper.h.

◆ AddYSizeMinReason()

void operations_research::sat::NoOverlap2DConstraintHelper::AddYSizeMinReason ( int index)
inline

Definition at line 162 of file no_overlap_2d_helper.h.

◆ connected_components()

const CompactVectorVector< int > & operations_research::sat::NoOverlap2DConstraintHelper::connected_components ( ) const
inline

Definition at line 234 of file no_overlap_2d_helper.h.

◆ GetBoundingRectangle()

Rectangle operations_research::sat::NoOverlap2DConstraintHelper::GetBoundingRectangle ( int index) const
inline

Definition at line 89 of file no_overlap_2d_helper.h.

◆ GetBoxSizesMax()

std::pair< IntegerValue, IntegerValue > operations_research::sat::NoOverlap2DConstraintHelper::GetBoxSizesMax ( int index) const
inline

Definition at line 108 of file no_overlap_2d_helper.h.

◆ GetItemRangeForSizeMin()

RectangleInRange operations_research::sat::NoOverlap2DConstraintHelper::GetItemRangeForSizeMin ( int index) const

Definition at line 69 of file no_overlap_2d_helper.cc.

◆ GetItemWithVariableSize()

ItemWithVariableSize operations_research::sat::NoOverlap2DConstraintHelper::GetItemWithVariableSize ( int index) const

Definition at line 83 of file no_overlap_2d_helper.cc.

◆ GetLevelZeroBoundingRectangle()

Rectangle operations_research::sat::NoOverlap2DConstraintHelper::GetLevelZeroBoundingRectangle ( int index) const
inline

Definition at line 96 of file no_overlap_2d_helper.h.

◆ GetLevelZeroBoxSizesMin()

std::pair< IntegerValue, IntegerValue > operations_research::sat::NoOverlap2DConstraintHelper::GetLevelZeroBoxSizesMin ( int index) const
inline

Definition at line 112 of file no_overlap_2d_helper.h.

◆ IncreaseLeftMin()

bool operations_research::sat::NoOverlap2DConstraintHelper::IncreaseLeftMin ( int index,
IntegerValue new_lower_bound )
inline

Definition at line 212 of file no_overlap_2d_helper.h.

◆ InProcessingCount()

int64_t operations_research::sat::NoOverlap2DConstraintHelper::InProcessingCount ( ) const
inline

Definition at line 238 of file no_overlap_2d_helper.h.

◆ IsAbsent()

bool operations_research::sat::NoOverlap2DConstraintHelper::IsAbsent ( int index) const
inline

Definition at line 85 of file no_overlap_2d_helper.h.

◆ IsEnforced()

bool operations_research::sat::NoOverlap2DConstraintHelper::IsEnforced ( ) const

Definition at line 301 of file no_overlap_2d_helper.cc.

◆ IsFixed()

bool operations_research::sat::NoOverlap2DConstraintHelper::IsFixed ( int index) const
inline

Definition at line 103 of file no_overlap_2d_helper.h.

◆ IsOptional()

bool operations_research::sat::NoOverlap2DConstraintHelper::IsOptional ( int index) const
inline

Definition at line 77 of file no_overlap_2d_helper.h.

◆ IsPresent()

bool operations_research::sat::NoOverlap2DConstraintHelper::IsPresent ( int index) const
inline

Definition at line 81 of file no_overlap_2d_helper.h.

◆ LastLevelZeroChangeIdx()

int64_t operations_research::sat::NoOverlap2DConstraintHelper::LastLevelZeroChangeIdx ( ) const
inline

Definition at line 239 of file no_overlap_2d_helper.h.

◆ NumBoxes()

int operations_research::sat::NoOverlap2DConstraintHelper::NumBoxes ( ) const
inline

Definition at line 222 of file no_overlap_2d_helper.h.

◆ Propagate()

bool operations_research::sat::NoOverlap2DConstraintHelper::Propagate ( )
overridevirtual

◆ PropagateRelativePosition()

bool operations_research::sat::NoOverlap2DConstraintHelper::PropagateRelativePosition ( int first,
int second,
PairwiseRestriction::PairwiseRestrictionType type )

Definition at line 174 of file no_overlap_2d_helper.cc.

◆ RegisterWith()

void operations_research::sat::NoOverlap2DConstraintHelper::RegisterWith ( GenericLiteralWatcher * watcher,
absl::Span< const Literal > enforcement_literals )

Definition at line 365 of file no_overlap_2d_helper.cc.

◆ ReportConflict()

bool operations_research::sat::NoOverlap2DConstraintHelper::ReportConflict ( )
inline

Definition at line 217 of file no_overlap_2d_helper.h.

◆ ReportConflictFromInfeasibleBoxRanges()

bool operations_research::sat::NoOverlap2DConstraintHelper::ReportConflictFromInfeasibleBoxRanges ( absl::Span< const RectangleInRange > ranges)

Definition at line 124 of file no_overlap_2d_helper.cc.

◆ ReportConflictFromTwoBoxes()

bool operations_research::sat::NoOverlap2DConstraintHelper::ReportConflictFromTwoBoxes ( int box1,
int box2 )

Definition at line 107 of file no_overlap_2d_helper.cc.

◆ ResetReason()

void operations_research::sat::NoOverlap2DConstraintHelper::ResetReason ( )
inline

Definition at line 120 of file no_overlap_2d_helper.h.

◆ SynchronizeAndSetDirection()

bool operations_research::sat::NoOverlap2DConstraintHelper::SynchronizeAndSetDirection ( bool x_is_forward_after_swap = true,
bool y_is_forward_after_swap = true,
bool swap_x_and_y = false )

Definition at line 38 of file no_overlap_2d_helper.cc.

◆ WatchAllBoxes()

void operations_research::sat::NoOverlap2DConstraintHelper::WatchAllBoxes ( int id)
inline

Definition at line 125 of file no_overlap_2d_helper.h.

◆ x_demands_helper()

SchedulingDemandHelper & operations_research::sat::NoOverlap2DConstraintHelper::x_demands_helper ( )

Definition at line 53 of file no_overlap_2d_helper.cc.

◆ x_helper()

SchedulingConstraintHelper & operations_research::sat::NoOverlap2DConstraintHelper::x_helper ( ) const
inline

Definition at line 228 of file no_overlap_2d_helper.h.

◆ y_demands_helper()

SchedulingDemandHelper & operations_research::sat::NoOverlap2DConstraintHelper::y_demands_helper ( )

Definition at line 61 of file no_overlap_2d_helper.cc.

◆ y_helper()

SchedulingConstraintHelper & operations_research::sat::NoOverlap2DConstraintHelper::y_helper ( ) const
inline

Definition at line 229 of file no_overlap_2d_helper.h.


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