LineGraph - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


GraphTheory

  

LineGraph

  

construct line graph of graph

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

LineGraph(G)

Parameters

G

-

graph

Description

• 

The LineGraph command creates the line graph LG of a given graph G.

• 

If G is undirected, the vertices of LG are the edges of G, and two vertices are connected by an edge if the corresponding edges in G share a vertex.

• 

If G is directed, the vertices of LG are the edges of G, and there is a directed edge from u to v if the target of the edge in G corresponding to u is equal to the source of the edge in G corresponding to v.

Examples

withGraphTheory:

K4CompleteGraph4

K4Graph 1: an undirected graph with 4 vertices and 6 edge(s)

(1)

DrawGraphK4

LLineGraphK4

LGraph 2: an undirected graph with 6 vertices and 12 edge(s)

(2)

DrawGraphL

VerticesL

1-2,1-3,1-4,2-3,2-4,3-4

(3)

EdgesGraphComplementL

1-2,3-4,1-3,2-4,1-4,2-3

(4)

Compatibility

• 

The GraphTheory[LineGraph] command was updated in Maple 2023.

See Also

DrawGraph

Edges

GraphComplement

Vertices