jmetal.operators.crossover
Class HUXCrossover

java.lang.Object
  extended by jmetal.core.Operator
      extended by jmetal.operators.crossover.Crossover
          extended by jmetal.operators.crossover.HUXCrossover
All Implemented Interfaces:
java.io.Serializable

public class HUXCrossover
extends Crossover

This class allows to apply a HUX crossover operator using two parent solutions. NOTE: the operator is applied to the first encodings.variable of the solutions, and the type of the solutions must be Binary or BinaryReal

See Also:
Serialized Form

Field Summary
 
Fields inherited from class jmetal.core.Operator
parameters_
 
Constructor Summary
HUXCrossover(java.util.HashMap<java.lang.String,java.lang.Object> parameters)
          Constructor Create a new instance of the HUX crossover operator.
 
Method Summary
 Solution[] doCrossover(double probability, Solution parent1, Solution parent2)
          Perform the crossover operation
 java.lang.Object execute(java.lang.Object object)
          Executes the operation
 
Methods inherited from class jmetal.core.Operator
getParameter, setParameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HUXCrossover

public HUXCrossover(java.util.HashMap<java.lang.String,java.lang.Object> parameters)
Constructor Create a new instance of the HUX crossover operator.

Method Detail

doCrossover

public Solution[] doCrossover(double probability,
                              Solution parent1,
                              Solution parent2)
                       throws JMException
Perform the crossover operation

Parameters:
probability - Crossover probability
parent1 - The first parent
parent2 - The second parent
Returns:
An array containing the two offsprings
Throws:
JMException

execute

public java.lang.Object execute(java.lang.Object object)
                         throws JMException
Executes the operation

Specified by:
execute in class Operator
Parameters:
object - An object containing an array of two solutions
Returns:
An object containing the offSprings
Throws:
JMException