/// <summary> /// Reset for an iteration. /// </summary> public void ResetAndKill() { totalFitAdjustment = 0; averageFitAdjustment = 0; Object[] speciesArray = Population.Species.ToArray(); for (int i = 0; i < speciesArray.Length; i++) { ISpecies s = (ISpecies)speciesArray[i]; s.Purge(); if ((s.GensNoImprovement > ParamNumGensAllowedNoImprovement) && Comparator.IsBetterThan(bestEverScore, s.BestScore)) { Population.Species.Remove(s); } } }