IndSet Class Reference
[Example scripts (models)]
Inherits Example.
Detailed Description
Example: Independent Sets in a Graph
Definition at line 65 of file ind-set.cc.
Public Member Functions | |
IndSet (const Options &opt) | |
Actual model. | |
IndSet (bool share, IndSet &s) | |
Constructor for cloning s. | |
virtual Space * | copy (bool share) |
Copy during cloning. | |
virtual void | print (void) |
Print solution. | |
void | constrain (Space *s) |
Add constraint for next better solution. | |
Protected Attributes | |
const Graph & | g |
Graph used. | |
BoolVarArray | v |
Whether vertex included in independent set. | |
IntVar | k |
How many elements has indipendent set. |
Constructor & Destructor Documentation
|
Actual model.
Definition at line 75 of file ind-set.cc. |
|
Constructor for cloning s.
Definition at line 87 of file ind-set.cc. |
Member Function Documentation
|
Copy during cloning.
Implements Gecode::Space. Definition at line 93 of file ind-set.cc. |
|
Print solution.
Reimplemented from Example. Definition at line 99 of file ind-set.cc. |
|
Add constraint for next better solution.
Definition at line 109 of file ind-set.cc. |
Member Data Documentation
|
Graph used.
Definition at line 68 of file ind-set.cc. |
|
Whether vertex included in independent set.
Definition at line 70 of file ind-set.cc. |
|
How many elements has indipendent set.
Definition at line 72 of file ind-set.cc. |
The documentation for this class was generated from the following file:
- examples/ind-set.cc (Revision: 3517)