Ejemplo n.º 1
0
 def setUp(self):
     self.G1 = example_graphs.example_graph1()
     self.G2 = example_graphs.example_graph2()
     self.G3 = example_graphs.example_graph3()
     self.G4 = example_graphs.example_graph4()
Ejemplo n.º 2
0
import pprint
import openpg
import isomorphic
import example_graphs as examples

p = pprint.PrettyPrinter(indent=4, depth=4)

G1 = examples.example_graph1()
G2 = examples.example_graph2()
G3 = examples.example_graph3()

#fo1 = G1.outer_face()
#fo1.set_initial_edge(G1.find_node_xy(0,0), G1.find_node_xy(1,0))
#fo2 = G2.outer_face()
#fo2.set_initial_edge(G2.find_node_xy(1,0), G2.find_node_xy(2,0))

G1.print_info(verbose=True)
G2.print_info(verbose=True)
G3.print_info(verbose=True)

print('---------- Normalizing -------------')
G1.normalize()
G1.print_info(verbose=True)

G2.normalize()
G2.print_info(verbose=True)

G3.normalize()
G3.print_info(verbose=True)

print('------ Checking isomorphism  -----')
Ejemplo n.º 3
0
import pprint
import openpg
import isomorphic
import example_graphs as examples

p = pprint.PrettyPrinter(indent=4, depth=4)

G1 = examples.example_graph1()
G2 = examples.example_graph2()
G3 = examples.example_graph3()

#fo1 = G1.outer_face()
#fo1.set_initial_edge(G1.find_node_xy(0,0), G1.find_node_xy(1,0))
#fo2 = G2.outer_face()
#fo2.set_initial_edge(G2.find_node_xy(1,0), G2.find_node_xy(2,0))

G1.print_info(verbose=True)
G2.print_info(verbose=True)
G3.print_info(verbose=True)

print('---------- Normalizing -------------')
G1.normalize()
G1.print_info(verbose=True)

G2.normalize()
G2.print_info(verbose=True)

G3.normalize()
G3.print_info(verbose=True)

print('------ Checking isomorphism  -----')
Ejemplo n.º 4
0
	def setUp(self):
		self.G1 = example_graphs.example_graph1()
		self.G2 = example_graphs.example_graph2()
		self.G3 = example_graphs.example_graph3()
		self.G4 = example_graphs.example_graph4()