Package org.jacop.examples.set
Class SocialGolfer
- java.lang.Object
-
- org.jacop.examples.set.ExampleSet
-
- org.jacop.examples.set.SocialGolfer
-
public class SocialGolfer extends ExampleSet
It is a Social Golfer example based on set variables.- Version:
- 4.8
-
-
Field Summary
Fields Modifier and Type Field Description (package private) SetVar[][]
golferGroup
(package private) int
groups
(package private) int
players
(package private) int
weeks
-
Fields inherited from class org.jacop.examples.set.ExampleSet
cost, search, store, vars
-
-
Constructor Summary
Constructors Constructor Description SocialGolfer()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(java.lang.String[] args)
It runs a number of social golfer problems.void
model()
It specifies a standard way of modeling the problem.boolean
search()
It specifies simple search method based on input order and lexigraphical ordering of values.void
setup(int weeks, int groups, int players)
It sets the parameters for the model creation function.-
Methods inherited from class org.jacop.examples.set.ExampleSet
getSearch, getSearchVariables, getStore, printMatrix, searchAllAtOnce, searchAllOptimal, searchMasterSlave, searchMostConstrainedStatic, searchOptimal, searchSmallestDomain, searchWeightedDegree
-
-
-
-
Field Detail
-
weeks
int weeks
-
groups
int groups
-
players
int players
-
golferGroup
SetVar[][] golferGroup
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
It runs a number of social golfer problems.- Parameters:
args
- parameters (none)
-
setup
public void setup(int weeks, int groups, int players)
It sets the parameters for the model creation function.- Parameters:
weeks
- how many weeks to playgroups
- how many groups will playplayers
- how many players will play
-
model
public void model()
Description copied from class:ExampleSet
It specifies a standard way of modeling the problem.- Specified by:
model
in classExampleSet
-
search
public boolean search()
Description copied from class:ExampleSet
It specifies simple search method based on input order and lexigraphical ordering of values.- Overrides:
search
in classExampleSet
- Returns:
- true if there is a solution, false otherwise.
-
-