Correctness of networkx line digraph construction -
the following python code: import networkx nx g = nx.digraph() g.add_nodes_from([0, 1]) g.add_edges_from([(0,0), (0,1), (1,0), (1,1)]) nx.write_dot(g, 'g.dot') gl = nx.line_graph(g) nx.write_dot(gl, 'gl.dot') creates following dot format graphs: --- g.dot --- digraph { 0 -> 0; 0 -> 1; 1 -> 0; 1 -> 1; } --- gl.dot --- strict digraph { "(0, 1)" -> "(1, 1)"; "(1, 0)" -> "(0, 0)"; "(0, 0)" -> "(0, 1)"; "(1, 1)" -> "(1, 0)"; } should edges: "(1, 0)" -> "(0, 1)"; "(0, 1)" -> "(1, 0)"; "(0, 0)" -> "(1, 1)"; "(1, 1)" -> "(0, 0)"; be in line graph construction? http://en.wikipedia.org/wiki/line_graph#line_digraph nx.line_graph creates strict digraph. strict means there no loops , no repeated edges. "(0, 1...