An Eulerian circuit is a directed closed trail that visits each edge exactly once.
In 1736, Euler showed that G has an Eulerian circuit if and only if G is connected and the indegree is equal to outdegree at every vertex.
The BEST theorem states that the number ec(G) of Eulerian circuits in a connected Eulerian graph G is given by the formula Here tw(G) is the number of arborescences, which are trees directed towards the root at a fixed vertex w in G. The number tw(G) can be computed as a determinant, by the version of the matrix tree theorem for directed graphs.
Their proof is bijective and generalizes the de Bruijn sequences.
In a "note added in proof", they refer to an earlier result by Smith and Tutte (1941) which proves the formula for graphs with deg(v)=2 at every vertex.