You can edit almost every page by Creating an account and confirming your email.

Graph join

From EverybodyWiki Bios & Wiki






File:Wheel graphs.svg
Wheel graphs Wn formed by the join of K1 and Cn
File:Complete graph K5.svg
Complete graph K5 formed by the join: K5 = K4 + K1

In the mathematical field of graph theory, the graph join (also called the sum of graphs in some literature, particularly in Spanish-language sources) is a binary operation on graphs. The operation consists of taking the union of the vertex sets and the edge sets of both graphs, plus the set of edges that connect the vertices of the first graph with the vertices of the second graph. It is a commutative operation for unlabeled graphs.

Formal definition

Let G1 = (V1, E1) and G2 = (V2, E2) be two graphs. The join of G1 and G2, denoted G1 + G2 or G1G2, is the graph G′ = (V′, E′) where:

  • V′ = V1V2
  • E′ = E1E2 ∪ { {x, y} : xV1, yV2 }

In other words, the join operation takes the disjoint union of the two graphs and adds all edges between vertices of the first graph and vertices of the second graph.[1]

Examples

Notable examples of graph joins include:

Properties

The graph join operation has the following properties:

  • Commutativity: For unlabeled graphs, G1 + G2G2 + G1.[1]
  • Connectivity: The join of any two nonempty graphs is always a connected graph.[2]
  • The join of two graphs with n and m vertices respectively has n + m vertices and |E1| + |E2| + nm edges.

Applications

The set-theoretic union approach used in graph join operations has found applications in various fields:

Set-theoretic resolution (Union)

When graphs are represented as a matrix of n columns, where each column represents a vertex and the n rows of each column represent the edges (memory address of the vertex to which it points), this matrix being not necessarily square, and having all the graphs to be joined in a list, an algorithm using a set-theoretic union approach can be described as follows:

  1. Traverse the list of graphs looking for the graph with the largest number of vertices. If there is more than one graph with the same maximum number of vertices, choose by order of entry.
  2. Once located at the graph with the largest number of vertices, create a new graph called GraphSum as an identical copy of the first selected graph (also creating it as a matrix).
  3. Move to the next graph with the largest number of vertices and locate its first vertex V (the first column of the matrix). Simultaneously, take GraphSum and search for V in its vertices. If that vertex is not found in GraphSum, add the entire column (the vertex with its edges) to GraphSum. However, if V is found in GraphSum, only add the edges of V that are not already in that vertex of GraphSum.
  4. Once all vertices of the graph being added to GraphSum have been traversed, select the next graph (by order of number of vertices) and repeat step 3 until all graphs in the list have been joined.

See also

References

  1. 1.0 1.1 Harary, Frank (1969). Graph Theory. Reading, MA: Addison-Wesley. ISBN 978-0-201-02787-7. Search this book on
  2. Chartrand, Gary; Lesniak, Linda; Zhang, Ping (2010). Graphs & Digraphs (5th ed.). Chapman and Hall/CRC. ISBN 978-1-4398-0381-8 Check |isbn= value: checksum (help). Search this book on
  3. Ameisen, Emmanuel (2025). "Circuit Tracing: Revealing Computational Graphs in Language Models". Anthropic.

es:Suma de grafos


This article "Graph join" is from Wikipedia. The list of its authors can be seen in its historical and/or the page Edithistory:Graph join. Articles copied from Draft Namespace on Wikipedia could be seen on the Draft Namespace of Wikipedia and not main one.