Generated on Mon May 10 06:46:53 2010 for Gecode by doxygen 1.6.3

Golf Class Reference
[Scripts for problems]

Example: Golf tournament More...

List of all members.

Public Types

enum  { MODEL_PLAIN, MODEL_SYMMETRY }
 

Model variants.

More...
enum  { PROP_PLAIN, PROP_DECOMPOSE }

Public Member Functions

SetVargroup (int w, int g)
 Return group number g in week w.
const SetVargroup (int w, int g) const
 Return group number g in week w.
 Golf (const SizeOptions &opt)
 Actual model.
virtual void print (std::ostream &os) const
 Print solution.
 Golf (bool share, Golf &s)
 Constructor for copying s.
virtual Spacecopy (bool share)
 Copy during cloning.

Public Attributes

int groups
 Number of groups in a week.
int playersInGroup
 Number of players in a group.
int weeks
 Number of weeks.
int players
 Overall number of players.
SetVarArray groupsS
 The sets representing the groups.

Parameters for golf tournaments



static const Tournament t []
 Tournaments.
static const unsigned int n_examples = sizeof(t) / sizeof(Tournament)
 Number of tournaments.

Detailed Description

Example: Golf tournament

Schedule a golf tournament. This is problem 010 from csplib.

Definition at line 77 of file golf.cpp.


Member Enumeration Documentation

anonymous enum

Model variants.

Enumerator:
MODEL_PLAIN 

A simple model.

MODEL_SYMMETRY 

Model with symmetry breaking.

Definition at line 80 of file golf.cpp.

anonymous enum
Enumerator:
PROP_PLAIN 

Propagation using intersection propagators.

PROP_DECOMPOSE 

Propagation using union and complement propagators.

Definition at line 84 of file golf.cpp.


Constructor & Destructor Documentation

Golf::Golf ( const SizeOptions opt  )  [inline]

Actual model.

Definition at line 106 of file golf.cpp.

Golf::Golf ( bool  share,
Golf s 
) [inline]

Constructor for copying s.

Definition at line 258 of file golf.cpp.


Member Function Documentation

SetVar& Golf::group ( int  w,
int  g 
) [inline]

Return group number g in week w.

Definition at line 97 of file golf.cpp.

const SetVar& Golf::group ( int  w,
int  g 
) const [inline]

Return group number g in week w.

Definition at line 101 of file golf.cpp.

virtual void Golf::print ( std::ostream &  os  )  const [inline, virtual]

Print solution.

Reimplemented from Gecode::Driver::ScriptBase< BaseSpace >.

Definition at line 233 of file golf.cpp.

virtual Space* Golf::copy ( bool  share  )  [inline, virtual]

Copy during cloning.

Definition at line 265 of file golf.cpp.


Friends And Related Function Documentation

const Tournament t[] [related]
Initial value:
  { {8,4,9},
    {5,3,7},
    {4,3,2}
  }

Tournaments.

Definition at line 60 of file golf.cpp.

const unsigned int n_examples = sizeof(t) / sizeof(Tournament) [related]

Number of tournaments.

Definition at line 66 of file golf.cpp.


Member Data Documentation

Number of groups in a week.

Definition at line 88 of file golf.cpp.

Number of players in a group.

Definition at line 89 of file golf.cpp.

Number of weeks.

Definition at line 90 of file golf.cpp.

Overall number of players.

Definition at line 91 of file golf.cpp.

The sets representing the groups.

Definition at line 94 of file golf.cpp.


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