net.sourceforge.cilib.problem
Class CooperativeOptimisationProblemAdapter

java.lang.Object
  extended by net.sourceforge.cilib.problem.OptimisationProblemAdapter
      extended by net.sourceforge.cilib.problem.CooperativeOptimisationProblemAdapter
All Implemented Interfaces:
Serializable, OptimisationProblem, Problem, Cloneable

public class CooperativeOptimisationProblemAdapter
extends OptimisationProblemAdapter

TODO test this class.

Author:
Theuns Cloete
See Also:
Serialized Form

Field Summary
 
Fields inherited from class net.sourceforge.cilib.problem.OptimisationProblemAdapter
dataSetBuilder, fitnessEvaluations
 
Constructor Summary
CooperativeOptimisationProblemAdapter(CooperativeOptimisationProblemAdapter copy)
           
CooperativeOptimisationProblemAdapter(OptimisationProblem p, CooperativeEntity c, int d, int o)
          Creates an OptimisationProblemAdapter that has the specified dimension starting at the given offset (index) position of the full given problem.
 
Method Summary
protected  Fitness calculateFitness(Type solution)
          Determine the Fitness of the current Problem instance based on the provided solution.
 DomainRegistry getBehaviouralDomain()
          Returns the domain component that describes the search space of the needed behavioral characteristics of the problem.
 CooperativeOptimisationProblemAdapter getClone()
          Create a cloned copy of the current object and return it.
 int getDimension()
           
 DomainRegistry getDomain()
          Returns the domain component that describes the search space for this problem.
 int getOffset()
           
 void updateContext(CooperativeEntity c)
           
 
Methods inherited from class net.sourceforge.cilib.problem.OptimisationProblemAdapter
accept, changeEnvironment, getChangeStrategy, getDataSetBuilder, getFitness, getFitnessEvaluations, setChangeStrategy, setDataSetBuilder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CooperativeOptimisationProblemAdapter

public CooperativeOptimisationProblemAdapter(OptimisationProblem p,
                                             CooperativeEntity c,
                                             int d,
                                             int o)
Creates an OptimisationProblemAdapter that has the specified dimension starting at the given offset (index) position of the full given problem.

Parameters:
p - problem the full problem that is being split up
c - Reference to the CooperativeEntity
d - dimension the dimension that that this sub-problem should be
o - offset the offset (index) position in the full-problem where this sub-problem should start

CooperativeOptimisationProblemAdapter

public CooperativeOptimisationProblemAdapter(CooperativeOptimisationProblemAdapter copy)
Method Detail

getClone

public CooperativeOptimisationProblemAdapter getClone()
Description copied from interface: OptimisationProblem
Create a cloned copy of the current object and return it. In general the created copy will be a deep copy of the provided instance. As a result this operation an be quite expensive if used incorrectly.

Specified by:
getClone in interface OptimisationProblem
Specified by:
getClone in interface Problem
Specified by:
getClone in interface Cloneable
Specified by:
getClone in class OptimisationProblemAdapter
Returns:
An exact clone of the current object instance.
See Also:
Object.clone()

getDimension

public int getDimension()

getOffset

public int getOffset()

updateContext

public void updateContext(CooperativeEntity c)

calculateFitness

protected Fitness calculateFitness(Type solution)
Description copied from class: OptimisationProblemAdapter
Determine the Fitness of the current Problem instance based on the provided solution.

Specified by:
calculateFitness in class OptimisationProblemAdapter
Parameters:
solution - The Type representing the candidate solution.
Returns:
The Fitness of the solution in the current Problem.
See Also:
OptimisationProblemAdapter.getFitness(Type, boolean)

getDomain

public DomainRegistry getDomain()
Description copied from interface: OptimisationProblem
Returns the domain component that describes the search space for this problem.

Returns:
A DomainRegistry object representing the search space.

getBehaviouralDomain

public DomainRegistry getBehaviouralDomain()
Description copied from interface: OptimisationProblem
Returns the domain component that describes the search space of the needed behavioral characteristics of the problem. This is mainly used for ECs, however, the use of behavioral parameters with PSO will be investigated.

Returns:
The domain of the behavioral component


Copyright © 2009 CIRG. All Rights Reserved.