gives the line graph of the graph g.
uses rules to specify the graph g.
- Each vertex in LineGraph[g] corresponds to an edge in g.
- For an undirected graph g, two vertices in LineGraph[g] are adjacent if their corresponding edges share a common vertex.
- For a directed graph g, two vertices in LineGraph[g] are adjacent if their corresponding edges are connected, i.e. the target of one edge is the source of the other edge.
- The vertices in LineGraph[g] are taken to be successive integers starting at 1.
- LineGraph works with undirected graphs, directed graphs, and multigraphs.
Introduced in 2010
(8.0)| Updated in 2015