Photo Class Reference
[Example scripts (models)]
Inherits Example.
Detailed Description
Example: Placing people on a photoA group of people wants to take a group photo. Each person can give preferences next to whom he or she wants to be placed on the photo. The problem to be solved is to find a placement that satisfies as many preferences as possible.
Definition at line 61 of file photo.cc.
Public Member Functions | |
Photo (const Options &opt) | |
Actual model. | |
Photo (bool share, Photo &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 PhotoSpec & | spec |
Photo specification. | |
IntVarArray | pos |
Person's position on photo. | |
IntVar | sat |
Number of satisfied preferences. |
Constructor & Destructor Documentation
|
Actual model.
|
|
Constructor for cloning s.
|
Member Function Documentation
|
Copy during cloning.
Implements Gecode::Space. |
|
Print solution.
Reimplemented from Example. |
|
Add constraint for next better solution.
|
Member Data Documentation
|
Photo specification.
|
|
Person's position on photo.
|
|
Number of satisfied preferences.
|
The documentation for this class was generated from the following file:
- examples/photo.cc (Revision: 3517)