gives the graph union of the graphs g1 and g2.
gives the graph union of g1, g2, ….
uses rules vw to specify the graph g.
- GraphUnion gives a new graph obtained from a set of two or more directed or undirected graphs obtained by separately taking the union of the original vertex and edge sets. For edges with the same vertex labels in different graphs, GraphUnion keeps only one of them. The resulting graph keeps the vertex labels of the unique original edges.
- Related functions include GraphDisjointUnion, GraphIntersection, and GraphDifference. Unlike GraphUnion, GraphDisjointUnion keeps all edges even if multiple edges exist in different graphs that have the same vertex labels. GraphIntersection gives the graph obtained from the union of vertex sets and intersection of edge sets of the original graphs. GraphDifference gives the graph obtained from the union of vertex sets of two graphs and the complement of the second graph’s edge set with respect to the first. GraphComplement gives the graph that has the same vertex set as a given graph, but with edges corresponding to absent edges in the original (and vice versa).
Introduced in 2010
(8.0)| Updated in 2015