TOPICS
Search

Connected Graph


A connected graph is an undirected graph in which any two distinct vertices are joined by a graph path. Equivalently, the graph, viewed as a topological space, is connected. An undirected graph that is not connected is said to be disconnected. This definition takes the null graph and singleton graph to be connected, while empty graphs on n>=2 vertices are disconnected.

According to West (2001, p. 150), the singleton graph K_1, "is annoyingly inconsistent" since it is connected but for consistency in discussing connectivity, it is considered to have vertex connectivity kappa(K_1)=0.

If A is the adjacency matrix of a finite simple graph G, then entry (i,j) of A^k is the number of k-walks from vertex i to vertex j. As a result, such a graph on n>1 vertices is connected iff

 sum_(k=1)^(n-1)A^k

has no zero off-diagonal entries.

A finite connected simple graph on n>=1 vertices satisfies

 sum_(i=1)^nrho(v_i)>=2(n-1),

where rho(v_i) is the vertex degree of vertex v_i. Equality holds iff the graph is a tree. The inequality is necessary but not sufficient for a finite simple graph to be connected.

A graph may be tested in the Wolfram Language to see if it is a connected graph using ConnectedGraphQ[g].

ConnectedGraphs

The numbers of connected unlabeled graphs on n=1, 2, ... vertices are 1, 1, 2, 6, 21, 112, 853, 11117, 261080, ... (OEIS A001349), the first few of which are illustrated above.

The total numbers of unlabeled graphs on n vertices, not necessarily connected, are given by the Euler transform of the preceding sequence, 1, 2, 4, 11, 34, 156, 1044, 12346, ... (OEIS A000088; Sloane and Plouffe 1995, p. 20). More generally, suppose a graph property holds iff it holds for every connected component. If a_n counts connected unlabeled graphs on n vertices with that property, then its Euler transform b_n counts all unlabeled graphs with the property. This application of the Euler transform is called Riddell's formula.

The numbers of connected labeled graphs on n vertices are 1, 1, 4, 38, 728, 26704, ... (OEIS A001187), and the total numbers of labeled graphs on n vertices, not necessarily connected, are given by the exponential transform of the preceding sequence: 1, 2, 8, 64, 1024, 32768, ... (OEIS A006125; Sloane and Plouffe 1995, p. 19).

An efficient enumeration of connected graphs on n vertices can be done using the program geng (part of nauty) by B. McKay using the syntax geng -c n. However, since the order in which graphs are returned by the geng program changes as a function of time as improvements are made, the canonical ordering given on McKay's website is used here and in GraphData.

If a simple graph G is disconnected, then its graph complement G^_ is connected (Skiena 1990, p. 171; Bollobás 1998). However, the converse is not true, as can be seen using the example of the cycle graph C_5 which is connected and isomorphic to its graph complement.

A finite simple graph on more than k vertices is k-connected when its vertex connectivity satisfies kappa(G)>=k, where k is a positive integer. Every such graph has minimum vertex degree at least k. In particular, 1-connected graphs are exactly the connected graphs on at least two vertices.

For a finite connected simple graph on n>=1 vertices, the maximum difference between its edge count and vertex count is (n; 2)-n=n(n-3)/2, attained by the complete graph K_n.


See also

Algebraic Connectivity, Biconnected Graph, Degree Sequence, Disconnected Graph, Edge Connectivity, Euler Transform, k-Connected Graph, Network, Planar Connected Graph, Polyhedral Graph, Polynema, Regular Graph, Riddell's Formula, Scale-Free Network, Sequential Graph, Steinitz's Theorem, Tait's Hamiltonian Graph Conjecture, Vertex Connectivity Explore this topic in the MathWorld classroom

Explore with Wolfram|Alpha

References

Bollobás, B. Modern Graph Theory. New York: Springer-Verlag, 1998.Cadogan, C. C. "The Möbius Function and Connected Graphs." J. Combin. Th. B 11, 193-200, 1971.Chartrand, G. "Connected Graphs." §2.3 in Introductory Graph Theory. New York: Dover, pp. 41-45, 1985.Harary, F. Graph Theory. Reading, MA: Addison-Wesley, p. 13, 1994.Harary, F. and Palmer, E. M. "Connected Graphs." §1.2 in Graphical Enumeration. New York: Academic Press, pp. 6-9, 1973.McKay, B. "Graphs." https://users.cecs.anu.edu.au/~bdm/data/graphs.html.Skiena, S. "Connectivity." §5.1 in Implementing Discrete Mathematics: Combinatorics and Graph Theory with Mathematica. Reading, MA: Addison-Wesley, pp. 171-180, 1990.Sloane, N. J. A. Sequences A000088/M1253, A001187/M3671, A001349, and A006125/M1897 in "The On-Line Encyclopedia of Integer Sequences."Sloane, N. J. A. and Plouffe, S. The Encyclopedia of Integer Sequences. San Diego, CA: Academic Press, 1995.Tutte, W. T. Connectivity in Graphs. Toronto, Canada: Toronto University Press, 1967.West, D. B. Introduction to Graph Theory, 2nd ed. Englewood Cliffs, NJ: Prentice-Hall, 2001.

Referenced on Wolfram|Alpha

Connected Graph

Cite this as:

Weisstein, Eric W. "Connected Graph." From MathWorld--A Wolfram Resource. https://mathworld.wolfram.com/ConnectedGraph.html

Subject classifications