Пример #1
0
 def test_graph_update_eca(self):
     for size in range(2, 7):
         net = ECA(30, size)
         g = net.landscape_graph()
         net.landscape_graph(width=size)
         self.assertEqual(g.graph['width'], size)
Пример #2
0
 def test_graph_eca(self):
     for size in range(2, 7):
         net = ECA(30, size)
         g = net.landscape_graph()
         self.assertEqual(net.volume, g.number_of_nodes())
         self.assertEqual(net.volume, g.number_of_edges())