jmetal.operators.crossover
Class HUXCrossover
java.lang.Object
jmetal.core.Operator
jmetal.operators.crossover.Crossover
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
Constructor Summary |
HUXCrossover(java.util.HashMap<java.lang.String,java.lang.Object> parameters)
Constructor
Create a new instance of the HUX crossover operator. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HUXCrossover
public HUXCrossover(java.util.HashMap<java.lang.String,java.lang.Object> parameters)
- Constructor
Create a new instance of the HUX crossover operator.
doCrossover
public Solution[] doCrossover(double probability,
Solution parent1,
Solution parent2)
throws JMException
- Perform the crossover operation
- Parameters:
probability
- Crossover probabilityparent1
- The first parentparent2
- 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