Suppose I have a hexagonal tile. Each edge can be connected to any subset of the other edges (including none). Connections are undirected, so a->b implies b->a, but they're not necessarily transitive - eg, a->b, b->c does not imply a->c. The graph resulting from the connected edges need not be connected - there can be multiple distinct subgraphs.


As far as I can tell, this is a special case of counting undirected, labelled 6 vertex graphs. This would be simple - there are $5+...+1=15$ possible edges, each of which can be present or absent, leading to $2^{15}$ possible graphs.


However, tiles are isomorphic with respect to rotation, and the above formula will generate every distinct rotation. The number of isomorphic graphs varies with the symmetry of the graph, so we can't simply divide the total by 6, either.


How can I compute the number of distinct graphs for this problem?



Counting distinct undirected, partially labelled graphs
This is a job for Burnside's lemma. What you're trying to count is *orbits* of 6-vertex graphs under a certain action of the 6-element cyclic group, which I'll denote $Z\_{6}$. By Burnside's lemma, this is equal to the average number of fixed points of elements of $Z\_{6}$, so really we just need to count those fixed points and then do some arithmetic.


It turns out that these numbers of fixed points are actually quite easy to describe. $Z\_{6}$ has one element of order $1$, two of order $3$, two of order $6$, and one of order $2$. We consider them order by order.


* Order 1: All $2^{15}$ graphs are fixed by the identity.
* Order 2: There are three "diameter" edges which are sent to themselves by the rotation of order 2; the other twelve edges are interchanged in pairs. Thus, there are nine orbits of edges under the action of this element, and thus $2^{9}$ graphs which are fixed by it.
* Order 3: Every edge is part of a triple of distinct edges which are sent to each other cyclically by any rotation of order three. Thus, there are five of these orbits, so there are $2^{5}$ graphs fixed by such an element.
* Order 6: The diameters mentioned previously form an orbit of length 3 under the action of a rotation of order 6; the remaining edges form two orbits of length 6. Thus, there are three total orbits, and therefore there are $2^{3}$ graphs fixed by each of these elements.


Now we hit it with Burnside's lemma. Let $N$ be the total number of graphs up to $Z\_{6}$-equivalence; by the lemma, we have


\[ N = \frac{1}{6} (2^{15} + 2^{9} + 2 \cdot 2^{5} + 2 \cdot 2^{3}) = 5560. \]


(To do this in more generality, you'd want to bring in some algebraic heavy machinery; a combination of Pólya theory and generating functions is the usual way to go.)


