Package behaviour

Class TournamentSelection

java.lang.Object
behaviour.TournamentSelection
All Implemented Interfaces:
SelectionBehaviour

public class TournamentSelection extends Object implements SelectionBehaviour
a selection behaviour
  • Constructor Details

    • TournamentSelection

      public TournamentSelection()
  • Method Details

    • select

      public <T extends Number> List<List<T>> select(List<? extends List<T>> population, List<T> fitnessOfPopulation)
      One good selection criteria is Tournament Selection, which randomly picks two individuals and runs a virtual tournament. The one having the higher fitness coefficient wins.
      Specified by:
      select in interface SelectionBehaviour
      Type Parameters:
      T - extends Number
      Parameters:
      population - the current population
      fitnessOfPopulation - the fitness scores of current population
      Returns:
      new parents