public void Setup() { tournamentSel = new TournamentSelection(); crossOver = new CrossOverSpawnFunction(); ga = new GeneticAlgorithm(tournamentSel, crossOver); }
public GeneticAlgorithm(ISelectionFunction selectionFunction, ISpawnIndividualFunction spawnFunction) { this.selectionFunction = selectionFunction; this.spawnFunction = spawnFunction; rand = new Random(); }