Stay organized with collections
Save and categorize content based on your preferences.
C++ Reference: class CircuitCoveringPropagator
Note: This documentation is automatically generated.
This constraint ensures that the graph is a covering of all nodes by
circuits and loops, such that all circuits contain exactly one distinguished
node. Those distinguished nodes are meant to be depots.
This constraint does not need ExactlyOnePerRowAndPerColumn() to be correct,
but it does not propagate degree deductions (only fails if a node has more
than one outgoing arc or more than one incoming arc), so that adding
ExactlyOnePerRowAndPerColumn() should work better.
TODO(user): Make distinguished nodes an array of Boolean variables,
so this can be used for facility location problems.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-08-06 UTC."],[[["\u003cp\u003eThe \u003ccode\u003eCircuitCoveringPropagator\u003c/code\u003e class ensures that a graph is covered by circuits and loops, with each circuit containing exactly one designated depot node.\u003c/p\u003e\n"],["\u003cp\u003eThis constraint does not require \u003ccode\u003eExactlyOnePerRowAndPerColumn()\u003c/code\u003e for correctness, but it benefits from its inclusion for better performance because it does not propagate degree deductions, and will only fail if a node has more than one outgoing or incoming arc.\u003c/p\u003e\n"],["\u003cp\u003eThe class includes methods like \u003ccode\u003eIncrementalPropagate\u003c/code\u003e, \u003ccode\u003ePropagate\u003c/code\u003e, \u003ccode\u003eRegisterWith\u003c/code\u003e, and \u003ccode\u003eSetLevel\u003c/code\u003e to manage and control the circuit propagation process.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eCircuitCoveringPropagator\u003c/code\u003e class constructor takes a graph, a vector of distinguished nodes, and a model as arguments, as well as being automatically generated.\u003c/p\u003e\n"]]],["The `CircuitCoveringPropagator` class ensures a graph covers all nodes with circuits/loops, each containing a single distinguished node (depot). It doesn't require `ExactlyOnePerRowAndPerColumn()` but works better with it. The class methods include: `CircuitCoveringPropagator` (constructor), `IncrementalPropagate`, `Propagate`, `RegisterWith`, and `SetLevel`. It can be used for facility location problems. Key actions are to ensure graph coverage and the propagation of the constraint.\n"],null,["# CircuitCoveringPropagator\n\nC++ Reference: class CircuitCoveringPropagator\n==============================================\n\n\nNote: This documentation is automatically generated.\nThis constraint ensures that the graph is a covering of all nodes by circuits and loops, such that all circuits contain exactly one distinguished node. Those distinguished nodes are meant to be depots. \n\nThis constraint does not need ExactlyOnePerRowAndPerColumn() to be correct, but it does not propagate degree deductions (only fails if a node has more than one outgoing arc or more than one incoming arc), so that adding ExactlyOnePerRowAndPerColumn() should work better. \n\nTODO(user): Make distinguished nodes an array of Boolean variables, so this can be used for facility location problems.\n\n| Method ||\n|--------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------|\n| [`CircuitCoveringPropagator`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/circuit.h#L174) | \u003cbr /\u003e Arguments: `std::vector\u003cstd::vector\u003cLiteral\u003e\u003e graph, const std::vector\u003cint\u003e& distinguished_nodes, Model* model` \u003cbr /\u003e |\n| [`IncrementalPropagate`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/circuit.h#L180) | Return type: `bool ` Arguments: `const std::vector\u003cint\u003e& watch_indices` \u003cbr /\u003e |\n| [`Propagate`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/circuit.h#L179) | Return type: `bool ` \u003cbr /\u003e |\n| [`RegisterWith`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/circuit.h#L181) | Return type: `void ` Arguments: `GenericLiteralWatcher* watcher` \u003cbr /\u003e |\n| [`SetLevel`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/circuit.h#L178) | Return type: `void ` Arguments: `int level` \u003cbr /\u003e |"]]