public virtual void CompletedTest() { AllCycles ac = new AllCycles(RegularPathGraphTest.CompleteGraphOfSize(4), 4, 100); Assert.IsTrue(ac.Completed); Assert.AreEqual(7, ac.Count); }
public virtual void Impractical() { // k12 - ouch AllCycles ac = new AllCycles(RegularPathGraphTest.CompleteGraphOfSize(12), 12, 100); Assert.IsFalse(ac.Completed); }
public virtual void K5Paths() { AllCycles ac = new AllCycles(RegularPathGraphTest.CompleteGraphOfSize(5), 5, 1000); Assert.IsTrue(Compares.AreDeepEqual( new int[][] { new[] { 2, 1, 0, 2 }, new[] { 3, 1, 0, 3 }, new[] { 4, 1, 0, 4 }, new[] { 3, 2, 0, 3 }, new[] { 3, 2, 1, 3 }, new[] { 3, 2, 1, 0, 3 }, new[] { 3, 2, 0, 1, 3 }, new[] { 4, 2, 0, 4 }, new[] { 4, 2, 1, 4 }, new[] { 4, 2, 1, 0, 4 }, new[] { 4, 2, 0, 1, 4 }, new[] { 3, 0, 2, 1, 3 }, new[] { 4, 0, 2, 1, 4 }, new[] { 4, 3, 0, 4 }, new[] { 4, 3, 1, 4 }, new[] { 4, 3, 1, 0, 4 }, new[] { 4, 3, 0, 1, 4 }, new[] { 4, 3, 2, 4 }, new[] { 4, 3, 2, 0, 4 }, new[] { 4, 3, 2, 1, 4 }, new[] { 4, 3, 2, 1, 0, 4 }, new[] { 4, 3, 2, 0, 1, 4 }, new[] { 4, 3, 0, 2, 4 }, new[] { 4, 3, 1, 2, 4 }, new[] { 4, 3, 0, 1, 2, 4 }, new[] { 4, 3, 1, 0, 2, 4 }, new[] { 4, 3, 0, 2, 1, 4 }, new[] { 4, 3, 1, 2, 0, 4 }, new[] { 4, 0, 3, 1, 4 }, new[] { 4, 0, 3, 2, 4 }, new[] { 4, 0, 3, 2, 1, 4 }, new[] { 4, 0, 3, 1, 2, 4 }, new[] { 4, 1, 3, 2, 4 }, new[] { 4, 1, 3, 2, 0, 4 }, new[] { 4, 1, 3, 0, 2, 4 }, new[] { 4, 0, 1, 3, 2, 4 }, new[] { 4, 1, 0, 3, 2, 4 } }, ac.GetPaths())); }
public virtual void K5Size() { AllCycles ac = new AllCycles(RegularPathGraphTest.CompleteGraphOfSize(5), 5, 1000); Assert.AreEqual(37, ac.Count); }
public virtual void K7Size() { AllCycles ac = new AllCycles(RegularPathGraphTest.CompleteGraphOfSize(7), 7, 1000); Assert.AreEqual(1172, ac.Count); }