Abstract
The MatrixTree Theorem is a formula for the number of spanning trees of a graph in terms of the determinant of a certain matrix. We begin with the necessary graphtheoretical background. Let G be a finite graph, allowing multiple edges but not loops. (Loops could be allowed, but they turn out to be completely irrelevant.
Keywords
 Matrix Tree Theorem
 Multiple Edges
 BinetCauchy Theorem
 Reduced Incidence Matrix
 Bottom Left Block
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
This is a preview of subscription content, access via your institution.
Buying options
References
C.W. Borchardt, Ueber eine der Interpolation entsprechende Darstellung der Eliminations–Resultante. J. Reine Angew. Math. (Crelle’s J.) 57, 111–121 (1860)
A. Cayley, Note sur une formule pour la réversion des séries. J. Reine Angew. Math. (Crelle’s J.) 52, 276–284 (1856)
A. Cayley, A theorem on trees. Q. J. Math. 23, 376–378 (1889); Collected Papers, vol. 13 (Cambridge University Press, Cambridge, 1897), pp. 26–28
A. Joyal, Une théorie combinatoire des séries formelles. Adv. Math. 42, 1–82 (1981)
J.W. Moon, in Counting Labelled Trees. Canadian Mathematical Monographs, vol. 1 (Canadian Mathematical Congress, 1970)
J. Pitman, Coalescent random forests. J. Comb. Theor. Ser. A 85, 165–193 (1999)
H. Prüfer, Neuer Beweis eines Satzes über Permutationen. Arch. Math. Phys. 27, 742–744 (1918)
J.J. Sylvester, On the change of systems of independent variables. Q. J. Math. 1, 42–56 (1857); Collected Mathematical Papers, vol. 2 (Cambridge, 1908), pp. 65–85
Author information
Authors and Affiliations
9.1 Appendix: Three Elegant Combinatorial Proofs
In this appendix we give three elegant combinatorial proofs that the number of spanning trees of the complete graph K _{ p } is p ^{p − 2} (Example 9.11). The proofs are given in chronological order of their discovery.
First proof (Prüfer). Given a spanning tree T of K _{ p }, i.e., a tree on the vertex set [p], remove the largest endpoint (leaf) v and write down the vertex a _{1} adjacent to v. Continue this procedure until only two vertices remain, obtaining a sequence \((a_{1},\ldots,a_{p2}) \in {[p]}^{p2}\), called the Prüfer sequence of T. For the tree below, we first remove 11 and then record 8. Next remove 10 and record 1. Then remove 8 and record 4, etc., ending with the sequence (8, 1, 4, 4, 1, 4, 9, 1, 9) and leaving the two vertices 1 and 9.
Second proof (Joyal). A doubly rooted tree is a tree T with one vertex u labelled S (for “start”) and one vertex v (which may equal u) labelled E (“end”). Let t(p) be the number of trees T on the vertex set [p], and let d(p) be the number of doubly rooted trees on [p]. Thus
Let T be a doubly rooted tree. There is a unique path from S to E, say with vertices \(S = b_{1},b_{2},\ldots,b_{k} = E\) (in that order). The following diagram shows such a doubly rooted tree:
Third proof (Pitman). A forest is a graph without cycles; thus every connected component is a tree. A planted forest is a forest F for which every component T has a distinguished vertex r _{ T } (called the root of T). Thus if a component T has k vertices, then there are k ways to choose the root of T.
Let P _{p } be the set of all planted forests on [p]. Let uv be an edge of a forest F ∈ P _{p } such that u is closer than v to the root r of its component. Define F to cover the rooted forest F′ if F′ is obtained by removing the edge uv from F and rooting the new tree containing v at v. This definition of cover defines the covering relation of a partial order on P _{p }. Under this partial order P _{p } is graded of rank p − 1. The rank of a forest F in P _{p } is its number of edges. The following diagram shows the poset P _{3}, with the root of each tree being its top vertex.
Our third proof isn’t an explicit bijection like the first two proofs. On the other hand, it has the virtue of not depending on the names of the vertices. Note that in the first two proofs it is necessary to know when one vertex is larger than another.
Notes for Chap. 9
The concept of tree as a formal mathematical object goes back to Kirchhoff and von Staudt. Trees were first extensively investigated by Cayley, to whom the term “tree” is due. In particular, in [20] Cayley states the formula \(\kappa (K_{p}) = {p}^{p2}\) for the number of spanning trees of K _{ p } and he gives a vague idea of a combinatorial proof. Because of this paper, Cayley is often credited with the enumeration of labelled trees. Cayley pointed out, however, that an equivalent result had been proved earlier by Borchardt [10]. Moreover, this result appeared even earlier in a paper of Sylvester [111]. Undoubtedly Cayley and Sylvester could have furnished a complete, rigorous proof had they had the inclination to do so. The elegant combinatorial proofs given in the appendix are due to Prüfer [89], Joyal [61, Example 12, pp. 15–16], and Pitman [83].
The MatrixTree Theorem (Theorem 9.8) was first proved by Borchardt [10] in 1860, though a similar result had earlier been published by Sylvester [111] in 1857. Cayley [19, p. 279] in fact in 1856 referred to the notyetpublished work of Sylvester. For further historical information on the MatrixTree theorem, see Moon [77, p. 42].
Exercises for Chap. 9

1.
(*) Let G _{ p } be the complete graph K _{p } with one edge removed. How many spanning trees does G _{ p } have?

2.
Let \(\boldsymbol{L} = \boldsymbol{L}(K_{rs})\) be the laplacian matrix of the complete bipartite graph K _{ rs }.

(a)
Find a simple upper bound on rank\((\boldsymbol{L}  rI)\). Deduce a lower bound on the number of eigenvalues of \(\boldsymbol{L}\) equal to r.

(b)
Assume r≠s and do the same as (a) for s instead of r.

(c)
(*) Find the remaining eigenvalues of \(\boldsymbol{L}\).

(d)
Use (a)–(c) to compute \(\kappa (K_{rs})\), the number of spanning trees of K _{ rs }.

(e)
Give a combinatorial proof of the formula for \(\kappa (K_{rs})\), by modifying either the proof of Prüfer or Joyal that \(\kappa (K_{p}) = {p}^{p2}\).

(a)

3.
Let p ≥ 5 and let G _{ p } be the graph on the vertex set \(\mathbb{Z}_{p}\) with edges {i, i + 1} and {i, i + 2}, for \(i \in \mathbb{Z}_{p}\). Thus G _{ p } has 2p edges. Show that \(\kappa (G_{p}) = pF_{p}^{2}\), where F _{ p } is a Fibonacci number (\(F_{1} = F_{2} = 1\), \(F_{p} = F_{p1} + F_{p2}\) for p ≥ 3).

4.
Let \(\overline{C}_{n}\) be the edge complement of the cube graph C _{ n }, i.e., \(\overline{C}_{n}\) has vertex set {0, 1}^{n}, with an edge uv if u and v differ in at least two coordinates. Find a formula for \(\kappa (\overline{C}_{n})\), the number of spanning trees of \(\overline{C}_{n}\). Your answer should be expressed as a simple product.

5.

(a)
(based on a suggestion of Venkataramana) Let G be a bipartite graph with vertex bipartition (A, B). Suppose that deg v = a for all v ∈ A and deg v = b for all v ∈ B. Let \(\boldsymbol{A}\) and \(\boldsymbol{L}\) denote the adjacency matrix and laplacian matrix of G, respectively. Show that if the eigenvalues of \(\boldsymbol{L}\) are \(\lambda _{1},\ldots,\lambda _{p}\), then the eigenvalues of \({\boldsymbol{A}}^{2}\) are \((\lambda _{1}  a)(\lambda _{1}  b),\ldots,(\lambda _{p}  a)(\lambda _{p}  b)\).

(b)
(*) Find the number of spanning trees of the graph \(\mathcal{C}_{n,k}\) of Exercise 2 in Chap. 2.

(a)

6.

(a)
(*) Let G be a finite loopless graph with p vertices. Suppose that the eigenvalues of the Laplacian matrix \(\boldsymbol{L}(G)\) are \(\theta _{1},\ldots,\theta _{p1}\) and θ _{ p } = 0. Let J be the p ×p matrix of all 1’s and let \(\alpha \in \mathbb{R}\). Show that the eigenvalues of \(\boldsymbol{L} +\alpha J\) are \(\theta _{1},\ldots,\theta _{p1},\alpha p\).

(b)
Let G ∪K _{ p } be the graph obtained from G by adding one new edge between every pair of distinct vertices. Express the number of spanning trees of G ∪K _{ p } in terms of \(\theta _{1},\ldots,\theta _{p1}\).

(c)
Suppose that G is simple and let \(\overline{G}\) be the complementary graph, i.e., G and \(\overline{G}\) have the same vertex set, and two distinct vertices are adjacent in G if and only if they are not adjacent in \(\overline{G}\). Express the number of spanning trees of \(\overline{G}\) in terms of \(\theta _{1},\ldots,\theta _{p1}\).

(d)
(*) Let G be simple with p vertices and define the polynomial
$$\displaystyle{P(G,x) =\sum _{F}{x}^{c(F)1},}$$where F ranges over all spanning planted forests of G and where c(F) is the number of components of F. Show that
$$\displaystyle{P(\overline{G},x) = {(1)}^{p1}P(G,x  p).}$$

(a)

7.
(*) Let V be the subset of \(\mathbb{Z} \times \mathbb{Z}\) on or inside some simple closed polygonal curve whose vertices belong to \(\mathbb{Z} \times \mathbb{Z}\), such that every line segment that makes up the curve is parallel to either the xaxis or yaxis. Draw an edge e between any two points of V at distance one apart, provided e lies on or inside the boundary curve. We obtain a planar graph G, an example being
Let G′ be the dual graph G ^{ ∗ } with the “outside” vertex deleted. (The vertices of G′ are the interior regions of G. For each edge e of G, say with regions R and R′ on the two sides of e, there is an edge of G′ between R and R′. See Sect. 11.4 for more information on duals to planar graphs.) For the above example, G′ is given by
Let \(\lambda _{1},\ldots,\lambda _{p}\) denote the eigenvalues of G′ (i.e., of the adjacency matrix \(\boldsymbol{A}(G^{\prime})\)). Show that
$$\displaystyle{\kappa (G) =\prod _{ i=1}^{p}(4 \lambda _{ i}).}$$ 
8.

(a)
Let \(\boldsymbol{L}\) be the laplacian matrix of a graph G on p vertices. We know (via Corollary 9.10) that the coefficient of x in the characteristic polynomial \(\det (\boldsymbol{L}  xI)\) is − pκ(G). Show in fact that the coefficient of x ^{j} is equal to ( − 1)^{j} times the number f _{ j }(G) of planted spanning forests (as defined in the third proof of the Appendix to this chapter) of G with j components.

(b)
Deduce from Theorem 5.12 that the sequence f _{1}(G), f _{2}(G), …, f _{ p }(G) is strongly logconcave.

(c)
(extremely difficult) Let g _{ k }(G) denote the number of spanning forests (but not planted) of G with j components. Show that the sequence g _{1}(G), \(g_{2}(G),\ldots\), g _{ p }(G) is logconcave. (The graph K _{3} shows that this sequence need not be strongly logconcave.)

(a)

9.
Let G be a vertextransitive graph with p vertices. (This means that for any two vertices u, v there is an automorphism \(\varphi\) of G satisfying \(\varphi (u) = v\).) Let \(\boldsymbol{A}\) denote the adjacency matrix of G. Show that for any integer n ≥ 1, \(\mathrm{tr}({\boldsymbol{A}}^{n})\) is divisible by p (where tr denotes trace).

10.

(a)
(moderately difficult) (*) Let G be a (finite) connected graph on a 2melement vertex set V. For any graph with vertices u and v, let μ(u, v) denote the number of edges adjacent to both u and v. Suppose that there is an automorphism \(\varphi : V \rightarrow V\) of G all of whose cycles have length two. (In other words, \(\varphi\) is a fixedpoint free involution.) Define the quotient graph \(G/\varphi\) as follows. The vertices of \(G/\varphi\) are the orbits of \(\varphi\). Thus \(G/\varphi\) has m vertices. Write [v] for the orbit containing vertex v, so \([v] =\{ v,\varphi (v)\}\). Set
$$\displaystyle{\mu ([u],[v]) =\mu (u,v) +\mu (\varphi (u),v).}$$For instance, if G is a 4cycle and \(\varphi\) takes each vertex to its antipode, then \(G/\varphi\) consists of a double edge. If G is a 6cycle and \(\varphi\) takes each vertex to its antipode, then \(G/\varphi\) is a triangle. If G = K _{4}, then \(G/\varphi\) is a double edge (for any \(\varphi\)). If G = K _{3, 3} then \(G/\varphi\) is a 3cycle for any \(\varphi\). Show that 2κ(G) is divisible by \(\kappa (G/\varphi )\), where κ denotes the number of spanning trees.

(b)
(difficult) Show in fact that κ(G) is always divisible by \(\kappa (G/\varphi )\).

(a)

11.

(a)
(difficult) (*) Show that the number s(n, q) of invertible n ×n symmetric matrices over the field \(\mathbb{F}_{q}\) is given by
$$\displaystyle{s(n,q) = \left \{\begin{array}{ll} {q}^{m(m1)}(q  1)({q}^{3}  1)\cdots ({q}^{2m1}  1),&n = 2m  1, \\ {q}^{m(m+1)}(q  1)({q}^{3}  1)\cdots ({q}^{2m1}  1),&n = 2m.\end{array} \right.}$$ 
(b)
Find a formula for the number f(p) of simple graphs on the vertex set [p] with an odd number of spanning trees.

(a)

12.
(*) Let S be a kelement subset of [p]. Show that the number f _{ S }(p) of planted forests on the vertex set [p] with exactly k components, whose set of roots is S, is given by \(f_{S}(p) = k{n}^{nk1}\). Deduce that the total number f _{ k }(p) of planted forests on [p] with k components is given by
$$\displaystyle{f_{k}(p) = k\left ({ p \atop k} \right ){p}^{pk1} = \left ({ p  1 \atop k  1} \right ){p}^{pk}.}$$
Rights and permissions
Copyright information
© 2013 Springer Science+Business Media New York
About this chapter
Cite this chapter
Stanley, R.P. (2013). The MatrixTree Theorem. In: Algebraic Combinatorics. Undergraduate Texts in Mathematics. Springer, New York, NY. https://doi.org/10.1007/9781461469988_9
Download citation
DOI: https://doi.org/10.1007/9781461469988_9
Published:
Publisher Name: Springer, New York, NY
Print ISBN: 9781461469971
Online ISBN: 9781461469988
eBook Packages: Mathematics and StatisticsMathematics and Statistics (R0)