|
FRODO Version 2.19.1
An open-source framework for Distributed Constraint Optimization (DCOP)
|
Creates a linear ordering among variables. More...

Classes | |
| class | MaxWidthMinDom |
| A linear ordering heuristic that chooses first variables with highest numbers of links with previous variables, breaking ties by minimizing domain size. More... | |
Public Member Functions | |
| CentralLinearOrdering (Element parameters, DCOPProblemInterface< V, U > problem) | |
| The constructor called in "statistics gatherer" mode. | |
| CentralLinearOrdering (DCOPProblemInterface< V, U > problem, Element parameters) | |
| Constructor. | |
| void | reset () |
| void | setSilent (boolean silent) |
| void | setQueue (Queue queue) |
| void | getStatsFromQueue (Queue queue) |
| Collection< MessageType > | getMsgTypes () |
| void | notifyIn (Message msg) |
| Public Member Functions inherited from frodo2.communication.IncomingMsgPolicyInterface< T > | |
| default void | notifyIn (Message msg, Object toAgent) |
| Notifies the listener of an incoming message. | |
Static Public Attributes | |
| static MessageType | START_MSG_TYPE = AgentInterface.START_AGENT |
| The type of the message telling the module to start. | |
| static final MessageType | REPORT_MSG_TYPE = new MessageType ("VarOrdering", "CentralLinearOrdering", "VarOrderReport") |
| The type of messages sent by agents to the dictator with information on their variables. | |
Protected Member Functions | |
| void | init () |
| Parses the problem. | |
| abstract void | reportVars () |
| Sends all necessary information about variables to the dictator. | |
| abstract String[] | chooseOrder () |
Protected Attributes | |
| Queue | queue |
| This module's queue. | |
| DCOPProblemInterface< V, U > | problem |
| The problem. | |
| boolean | started = false |
| Whether the module has already started the algorithm. | |
| String | dictator |
| The name of the agent that chooses the variable order. | |
| Map< String, String > | owners |
| Who owns each agent. | |
| String | myID |
| This agent's ID. | |
Private Member Functions | |
| void | printOrder (List< String > order) |
| Prints the input linear order in DOT format. | |
Private Attributes | |
| boolean | silent = false |
| Whether the stats gatherer should display the resulting linear order. | |
| Set< String > | allAgents |
| The sets of all agents in the problem. | |
| int | countdown = 0 |
| The number of reports we are still waiting for from other agents. | |
Static Private Attributes | |
| static final MessageType | TEMP_OUTPUT_MSG_TYPE = new MessageType ("VarOrdering", "CentralLinearOrdering", "VarOrderNoSpace") |
| The type of the message notifying the agent of the chosen ordering, excluding the spaces. | |
Creates a linear ordering among variables.
All agents report their variables (along with possible heuristic-related information) to the first agent in lexicographic order, and this agent then centrally chooses a linear order on all variables, and broadcasts the result to all agents.
| <V> | the type used for variable values |
| <U> | the type used for utility values |
| frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.CentralLinearOrdering | ( | Element | parameters, |
| DCOPProblemInterface< V, U > | problem ) |
The constructor called in "statistics gatherer" mode.
| problem | the overall problem |
| parameters | the description of what statistics should be reported (currently unused) |
References problem.
| frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.CentralLinearOrdering | ( | DCOPProblemInterface< V, U > | problem, |
| Element | parameters ) |
Constructor.
| problem | this agent's problem |
| parameters | the parameters for CentralLinearOrdering |
References problem.
|
abstractprotected |
| Collection< MessageType > frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.getMsgTypes | ( | ) |
| void frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.getStatsFromQueue | ( | Queue | queue | ) |
|
protected |
Parses the problem.
References frodo2.algorithms.AgentInterface< V extends Addable< V > >.AGENT_FINISHED, allAgents, frodo2.solutionSpaces.ProblemInterface< V extends Addable< V >, U extends Addable< U > >.getAgent(), frodo2.solutionSpaces.ProblemInterface< V extends Addable< V >, U extends Addable< U > >.getAgents(), frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getMyVars(), myID, reportVars(), and frodo2.communication.Queue.sendMessageToSelf().
Referenced by notifyIn().

| void frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.notifyIn | ( | Message | msg | ) |
Implements frodo2.communication.IncomingMsgPolicyInterface< T >.
References frodo2.algorithms.AgentInterface< V extends Addable< V > >.AGENT_FINISHED, frodo2.communication.MessageType.equals(), init(), notifyIn(), REPORT_MSG_TYPE, and frodo2.algorithms.varOrdering.linear.OrderMsg< V extends Addable< V >, U extends Addable< U > >.STATS_MSG_TYPE.
Referenced by notifyIn().

|
private |
|
abstractprotected |
Sends all necessary information about variables to the dictator.
Referenced by init().
| void frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.reset | ( | ) |
Implements frodo2.algorithms.StatsReporter.
| void frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.setQueue | ( | Queue | queue | ) |
Implements frodo2.communication.MessageListener< T >.
References queue.
| void frodo2.algorithms.varOrdering.linear.CentralLinearOrdering< V extends Addable< V >, U extends Addable< U > >.setSilent | ( | boolean | silent | ) |
Implements frodo2.algorithms.StatsReporter.
References silent.
|
private |
The sets of all agents in the problem.
Referenced by init().
|
private |
The number of reports we are still waiting for from other agents.
|
protected |
The name of the agent that chooses the variable order.
|
protected |
This agent's ID.
Referenced by init().
|
protected |
Who owns each agent.
|
protected |
The problem.
Referenced by CentralLinearOrdering(), CentralLinearOrdering(), and printOrder().
|
protected |
This module's queue.
Referenced by getStatsFromQueue(), and setQueue().
|
static |
The type of messages sent by agents to the dictator with information on their variables.
Referenced by getMsgTypes(), and notifyIn().
|
private |
Whether the stats gatherer should display the resulting linear order.
Referenced by setSilent().
|
static |
The type of the message telling the module to start.
Referenced by getMsgTypes().
|
protected |
Whether the module has already started the algorithm.
|
staticprivate |
The type of the message notifying the agent of the chosen ordering, excluding the spaces.
Referenced by getMsgTypes().