# Pólya enumeration theorem

The Pólya enumeration theorem, also known as the Redfield–Pólya Theorem, is a theorem in combinatorics that both follows and ultimately generalizes Burnside's lemma on the number of orbits of a group action on a set. The theorem was first published by John Howard Redfield in 1927. In 1937 it was independently rediscovered by George Pólya, who then greatly popularized the result by applying it to many counting problems, in particular to the enumeration of chemical compounds.

The Pólya enumeration theorem can also be incorporated into symbolic combinatorics and the theory of combinatorial species.

## A simplified, unweighted version

Let X be a finite set and let G be a group of permutations of X (or a finite symmetry group that acts on X). The set X may represent a finite set of beads, and G may be a chosen group of permutations of the beads. For example, if X is a necklace of n beads in a circle, then rotational symmetry is relevant so G is the cyclic group Cn, while if X is a bracelet of n beads in a circle, rotations and reflections are relevant so G is the dihedral group Dn of order 2n. Suppose further that Y is a finite set of colors — the colors of the beads — so that YX is the set of colored arrangements of beads, and suppose that there are ${\displaystyle \left|Y\right|=t}$ colors. (More formally, a given "coloring" is a function ${\displaystyle X\to Y}$.) Then the Pólya enumeration theorem counts the number of orbits under G of colored arrangements of beads by the following formula:

${\displaystyle |Y^{X}/G|={\frac {1}{|G|}}\sum _{g\in G}t^{c(g)}}$

where ${\displaystyle \left|Y\right|=t}$ and c(g) is the number of cycles of the group element g as a permutation of X.

## The full, weighted version

In the more general and more important version of the theorem, the colors are also weighted in one or more ways, and there could be an infinite number of colors provided that the set of colors has a generating function with finite coefficients. In the univariate case, suppose that

${\displaystyle f(x)=f_{0}+f_{1}x+f_{2}x^{2}+\cdots }$

is the generating function of the set of colors, so that there are fn colors of weight n for each n ≥ 0. In the multivariate case, the weight of each color is a vector of integers and there is a generating function f(a,b,...) that tabulates the number of colors with each given vector of weights.

The enumeration theorem employs another multivariate generating function called the cycle index:

${\displaystyle Z_{G}(t_{1},t_{2},\ldots ,t_{n})={\frac {1}{|G|}}\sum _{g\in G}t_{1}^{j_{1}(g)}t_{2}^{j_{2}(g)}\cdots t_{n}^{j_{n}(g)}.}$

Here the kth weight jk(g) is the number of k-cycles of g as a permutation of X. The theorem then says that the generating function F of colored arrangements is the cycle index, composed with the generating function f of the colors, composed with powers of the variables of f:

${\displaystyle F(x)=Z_{G}(f(x),f(x^{2}),f(x^{3}),\ldots ,f(x^{n}))}$

or in the multivariate case:

${\displaystyle F(a,b,\ldots )=Z_{G}(f(a,b,\ldots ),f(a^{2},b^{2},\ldots ),f(a^{3},b^{3},\ldots ),\ldots ,f(a^{n},b^{n},\ldots )).}$

To reduce to the simplified version, if there are t colors of weight 0, then

${\displaystyle |Y^{X}/G|=Z_{G}(t,t,\ldots ,t).}$

In the celebrated application of counting trees (see below) and acyclic molecules, an arrangement of "colored beads" is actually an arrangement of arrangements, such as branches of a rooted tree. Thus the generating function f for the colors is derived from the generating function F for arrangements, and the Pólya enumeration theorem becomes a recursive formula.

## Examples

### Graphs on three and four vertices

A graph on m vertices can be interpreted as an arrangement of colored beads. The arrangement X is the set of ${\displaystyle {\binom {m}{2}}}$ possible edges, while the set of colors Y = {black,white} corresponds to edges that are present (black) or absent (white). The Pólya enumeration theorem can be used to calculate the number of graphs up to isomorphism with a fixed number of vertices, or the generating function of these graphs according to the number of edges they have. For the latter purpose, we can say that a black or present edge has weight 1, while an absent or white edge has weight 0. Thus ${\displaystyle f(t)=1+t}$ is the generating function for the set of colors. The relevant symmetry group is ${\displaystyle G=S_{m}}$, the symmetric group on m letters; an isomorphism class of graphs is equivalent to an orbit of graphs under this group. It acts as a subgroup of ${\displaystyle S_{\binom {m}{2}}}$, the group of permutations of all of the edges.

File:AllGraphsOnThreeVertices.png
All graphs on three vertices.
File:NonisomorphicGraphsOnThreeVertices.png
Nonisomorphic graphs on three vertices.

The 8 graphs on three vertices without quotienting by symmetry are shown at the right. There are four isomorphism class of graphs, also shown at the right.

The cycle index of the permutation group of the edges is

${\displaystyle Z_{G}(t_{1},t_{2},t_{3})={\frac {t_{1}^{3}+3t_{1}t_{2}+2t_{3}}{6}}.}$

Thus, according to the enumeration theorem, the generating function of graphs on 3 vertices up to isomorphism is

${\displaystyle F(t)=Z_{G}(t+1,t^{2}+1,t^{3}+1)={\frac {(t+1)^{3}+3(t+1)(t^{2}+1)+2(t^{3}+1)}{6}},}$

which simplifies to

${\displaystyle F(t)=t^{3}+t^{2}+t+1.}$

Thus there is one graph each with 0 to 3 edges.

File:NonisomorphicGraphsOnFourVertices.png
Isomorphism classes of graphs on four vertices.

The cycle index of the edge permutation group for graphs on four vertices is:

${\displaystyle Z_{G}(t_{1},t_{2},t_{3},t_{4})={\frac {t_{1}^{6}+9t_{1}^{2}t_{2}^{2}+8t_{3}^{2}+6t_{2}t_{4}}{24}}.}$

Hence

${\displaystyle F(t)=Z_{G}(1+t,1+t^{2},1+t^{3},1+t^{4})={\frac {(t+1)^{6}+9(t+1)^{2}(t^{2}+1)^{2}+8(t^{3}+1)^{2}+6(t^{2}+1)(t^{4}+1)}{24}}\,}$

which simplifies to

${\displaystyle F(t)=t^{6}+t^{5}+2t^{4}+3t^{3}+2t^{2}+t+1.}$

These graphs are shown at the right.

### Rooted ternary trees

The set T3 of rooted ternary trees consists of rooted trees where every node has exactly three children (leaves or subtrees). Small ternary trees are shown at right. Note that ternary trees with n vertices are equivalent to trees with n vertices of degree at most 3. In general, rooted trees are isomorphic when one can be obtained from the other by permuting the children of its nodes. In other words, the group that acts on the children of a node is the symmetric group S3. We define the weight of such a ternary tree to be the number of nodes (or non-leaf vertices).

File:TernaryTrees.png
Ternary trees on 0, 1, 2, 3 and 4 vertices. (Leaves not shown except for the tree on zero vertices (green)).

We can view a rooted, ternary tree as a recursive object which is either a leaf or three branches which are themselves rooted ternary trees. These branches are equivalent to beads; the cycle index of the symmetric group S3 that acts on them is then

${\displaystyle Z_{S_{3}}(t_{1},t_{2},t_{3})={\frac {t_{1}^{3}+3t_{1}t_{2}+2t_{3}}{6}}.}$

The Polya enumeration theorem then yields a functional equation for the generating function T(x) of the rooted ternary trees:

${\displaystyle T(x)=1+x{\frac {T(x)^{3}+3T(x)T(x^{2})+2T(x^{3})}{6}}.}$

This is equivalent to the following recurrence formula for the number tn of rooted ternary trees with n nodes:

${\displaystyle t_{0}=1}$

and

${\displaystyle t_{n+1}={\frac {1}{6}}\left(\sum _{a+b+c=n}t_{a}t_{b}t_{c}+3\sum _{a+2b=n}t_{a}t_{b}+2\sum _{3a=n}t_{a}\right)}$

where a, b and c are nonnegative integers.

The first few values of ${\displaystyle t_{n}}$ are

1, 1, 1, 2, 4, 8, 17, 39, 89, 211, 507, 1238, 3057, 7639, 19241 (sequence A000598 in OEIS)

### Colored cubes

How many ways are there to color the sides of a 3-dimensional cube with t colors, up to rotation of the cube? The rotation group C of the cube acts on the six sides of the cube, which are equivalent to beads. Its cycle index is

${\displaystyle Z_{C}(t_{1},t_{2},t_{3},t_{4})={\frac {t_{1}^{6}+6t_{1}^{2}t_{4}+3t_{1}^{2}t_{2}^{2}+8t_{3}^{2}+6t_{2}^{3}}{24}}.}$

Thus there are

${\displaystyle Z_{C}(t,t,t,t)={\frac {t^{6}+3t^{4}+12t^{3}+8t^{2}}{24}}}$

colorings.

## Proof of theorem

The simplified form of the Pólya enumeration theorem follows from Burnside's lemma, which says that the number of orbits of colorings is the average of the number of elements of ${\displaystyle Y^{X}}$ fixed by the permutation g of G over all permutations g. The weighted version of the theorem has essentially the same proof, but with a refined form of Burnside's lemma for weighted enumeration. It is equivalent to apply Burnside's lemma separately to orbits of different weight.

For clearer notation, let ${\displaystyle x_{1},x_{2},\ldots }$ be the variables of the generating function f of ${\displaystyle Y}$. Given a vector of weights ${\displaystyle \omega }$, let ${\displaystyle x^{\omega }}$ denote the corresponding monomial term of f. Applying Burnside's lemma to orbits of weight ${\displaystyle \omega }$, the number of orbits of this weight is

${\displaystyle {\frac {1}{|G|}}\sum _{g\in G}|(Y^{X})_{\omega ,g}|}$

where ${\displaystyle (Y^{X})_{\omega ,g}}$ is the set of colorings of weight ${\displaystyle \omega }$ that are also fixed by g. If we then sum over all all possible weights, we obtain

${\displaystyle F(x_{1},x_{2},\ldots )={\frac {1}{|G|}}\sum _{g\in G,\omega }x^{\omega }|(Y^{X})_{\omega ,g}|.}$

Meanwhile g has a cycle structure ${\displaystyle j_{1},j_{2},\ldots ,j_{n}}$ which contributes

${\displaystyle t_{1}^{j_{1}(g)}t_{2}^{j_{2}(g)}\cdots t_{n}^{j_{n}(g)}}$

to the cycle index of G. The element g fixes an element of ${\displaystyle Y^{X}}$ if and only if it is constant on every cycle q of g. The generating function by weight of a cycle q of |q| identical elements from the set of objects enumerated by f is

${\displaystyle f(x_{1}^{|q|},x_{2}^{|q|},x_{3}^{|q|},\ldots ).}$

It follows that the generating function by weight of the points fixed by g is the product of the above term over all cycles of g, i.e.

${\displaystyle \sum _{\omega }x^{\omega }|(Y^{X})_{\omega ,g}|=\prod _{q\in g}f(x_{1}^{|q|},x_{2}^{|q|},x_{3}^{|q|},\ldots ),}$

which equals

${\displaystyle f(x_{1},x_{2},\ldots )^{j_{1}(g)}f(x_{1}^{2},x_{2}^{2},\ldots )^{j_{2}(g)}\cdots f(x_{1}^{n},x_{2}^{n},\ldots )^{j_{n}(g)}.}$

Substituting this for ${\displaystyle \sum _{\omega }x^{\omega }|(Y^{X})_{\omega ,g}|\,}$ in the sum over all g yields the substituted cycle index as claimed.

## References

• {{#invoke:Citation/CS1|citation

|CitationClass=journal }}

• {{#invoke:Citation/CS1|citation

|CitationClass=journal }}

• {{#invoke:Citation/CS1|citation

|CitationClass=journal }}

• {{#invoke:citation/CS1|citation

|CitationClass=book }}