public void computeRoutes() { //RandomSearch randomSearcher = new RandomSearch (); //solution = randomSearcher.computeRoutes (1000); GeneticSearch geneticSearch = new GeneticSearch(100); solution = geneticSearch.computeRoutes(10000); solution.debugSolution(); }
public void TestSearch() { var testSubject = new GeneticSearch(new GeneticProblem(), HeelsToJesus, Mutate) { NumberOfGenerations = 4 }; var resultState = testSubject.Search(); var testResult = resultState as EightDigitString; Assert.IsNotNull(testResult); foreach (var myVal in GeneticProblem.MyTestValues) { Assert.IsTrue(testResult.IsGe(myVal)); } }
public void TestSearch() { var testSubject = new GeneticSearch(new GeneticProblem(), HeelsToJesus, Mutate) { NumberOfGenerations = 4 }; var resultState = testSubject.Search(); var testResult = resultState as EightDigitString; Assert.IsNotNull(testResult); foreach (var myVal in GeneticProblem.MyTestValues) { Assert.IsTrue(testResult.IsGe(myVal)); } }