Permutation graphs and the Abelian sandpile model, tiered trees and non-ambiguous binary trees

A permutation graph is a graph whose edges are given by inversions of a permutation. We study the Abelian sandpile model (ASM) on such graphs. We exhibit a bijection between recurrent configurations of the ASM on permutation graphs and the tiered trees introduced by Dugan et al. [10]. This bijection allows certain parameters of the recurrent configurations to be read on the corresponding tree. In particular, we show that the level of a recurrent configuration can be interpreted as the external activity of the corresponding tree, so that the bijection exhibited provides a new proof of a famous result linking the level polynomial of the ASM to the ubiquitous Tutte polynomial. We show that the set of minimal recurrent configurations is in bijection with the set of complete non-ambiguous binary trees introduced by Aval et al. [2], and introduce a multi-rooted generalization of these that we show to correspond to all recurrent configurations. In the case of permutations with a single descent, we recover some results from the case of Ferrers graphs presented in [11], while we also recover results of Perkinson et al. [16] in the case of threshold graphs.


Introduction
In the Abelian sandpile model (ASM) on a graph, each vertex has a number of "grains". If a vertex has at least as many grains as its degree is then it can be toppled, donating one grain to each of its neighbors. If a (nonempty) sequence of topplings from a configuration c of grains leads to c again, then c is said to be recurrent.
In this paper we study the ASM on permutation graphs. For a permutation π = π 1 π 2 . . . π n this is the graph whose vertices are the integers 1, 2, . . . , n with an edge between i and j if and only if i < j and π i > π j , that is, if π i and π j form an inversion in π.
This paper generalizes the results in [11], where the recurrent configurations on Ferrers graphs were classified in terms of decorated EW-tableaux, since Ferrers graphs are isomorphic to permutation graphs of permutations with a single descent We extend the bijection in [11] between recurrent configurations on Ferrers graphs and the intransitive trees of Postnikov [17], to bijectively connect recurrent configurations of permutation graphs and the tiered trees introduced by Dugan et al. [10], of which the intransitive trees are a special case.
In [2], Aval et al. introduced the so-called complete non-ambiguous binary trees (CNABs), which arise from certain 0/1 fillings of square Ferrers diagrams. We show that the set of minimal recurrent configurations on permutation graphs is in bijection with CNABs. We then generalize the CNABs, which have a canonical root vertex, to a multirooted version, which we show to be in bijection with all recurrent configurations on the corresponding permutation graphs.
We also show that our results extend those of Perkinson et al. [16], connecting parking functions and labeled spanning trees of threshold graphs, which are a subset of permutation graphs.
The paper is organized as follows. In Section 2 we recall necessary definitions and provide a link between tiered trees and spanning trees of permutation graphs. In Section 3 we exhibit a bijection between tiered trees and recurrent configurations of the ASM on permutation graphs. We show how the level statistic and canonical toppling of a recurrent configuration can be read from the corresponding tree, and interpret the level statistic as the external activity of the tree. This provides a new proof, in the case of permutation graphs, of the famous result linking the level polynomial of the ASM to the ubiquitous Tutte polynomial (see Proposition 3.5). In Section 4 we recall the definition of complete non-ambiguous binary trees introduced by Aval et al. [2], show that these are in bijection with the set of minimal recurrent configurations of the ASM and introduce a generalization that we show to correspond to all recurrent configurations. Finally, in Section 5 we study two special cases of permutation graphs, namely Ferrers graphs (corresponding to permutations with a single descent) and threshold graphs, and recover results from [11] and [16] respectively.

Definitions and Preliminaries
For any positive integer n, we let [n] := {1, . . . , n} and S n be the set of permutations of [n].
2.1. Permutation graphs. To a permutation π = π 1 · · · π n ∈ S n , we associate a graph G π as follows. The vertex set of π is [n] and the edges are the pairs (π i , π j ) such that i < j and π i > π j , that is, (i, j) is an inversion of π. Such a graph is called a permutation graph.
A permutation π ∈ S n is said to be indecomposable if there exists no positive integer k < n such that {π 1 , . . . , π k } = [k]. The following is well known, see for example [14,Lemma 3.2].
Fact 2.1. A permutation graph G π is connected if and only if π is indecomposable. Figure 1 shows the graphs associated with the permutations π = 23541 and π ′ = 23154. Note that π ′ can be decomposed as 231-54, while π is indecomposable. Thus the graph G π is connected, while G π ′ is not. Since we will be analyzing the ASM on permutation graphs, and the ASM is only defined on connected graphs, we will from now on only deal with permutation graphs of indecomposable permutations unless otherwise specified.
2.2. Tiered trees. Tiered trees were introduced in [10] as a generalization of the intransitive trees introduced by Postnikov [17], the latter of which have exactly two tiers. Definition 2.2. A tiered tree of size n is a pair (T, t) where: • T is a labeled tree on [n].
• t is a surjective mapping from [n] → [k] for some k such that for any edge (i, j) of T with i > j we have t(i) < t(j).
The function t is called the tiering function of the tiered tree (T, t), and the integer k is its number of tiers. A tiered tree is said to be fully tiered if its number of tiers equals its number of vertices, that is, k = n, or equivalently, if its tiering function is a bijection.
Remark 2.3. The condition t(i) < t(j) is reversed in [10]. This corresponds to replacing the function t with k + 1 − t. The reason we reverse this condition is to make the link between tiered trees and permutation graphs simpler.

Fully tiered trees and permutation graphs.
Lemma 2.4. Let T = (T, t) be a tiered tree. Then there exists a fully tiered tree T ′ = (T, t ′ ).
Proof. Let T = (T, t) be a tiered tree. For ℓ ∈ [k], we let P ℓ := t −1 (ℓ) be the set of vertices at tier ℓ in T . By definition, the P ℓ form a partition of [n]. We define t ′ : where ℓ is such that i ∈ P ℓ . In words, the function t ′ keeps the relative ordering of tiers, and orders vertices inside each tier in increasing order, as illustrated in Figure 2 below. We claim that t ′ is a tiering function for the tree T , and that (T, t ′ ) is fully tiered. Let (i, j) be an edge of T with i < j, and let ℓ, m be such that i ∈ P ℓ and j ∈ P m . Since t is a tiering function, this implies that t(i) = ℓ > m = t(j). Now by construction, Equation (1) implies that t ′ (i) > t ′ (j), as desired.
It is clear from Equation (1) that t ′ assigns a unique positive number no greater than n to each i, which implies that t ′ is a bijection, so (T, t ′ ) is fully tiered. Lemma 2.4 states that any tiered tree can be viewed as a fully tiered tree in a sense. As such, from now on, we only consider fully tiered trees, and call these simply tiered trees. The following proposition establishes a link between tiered trees and permutation graphs.
Proposition 2.5. Let T be a labeled tree on [n] and π ∈ S n . Then T is a spanning tree of G π if and only if (T, π −1 ) is a tiered tree.
Proof. Suppose that T is a spanning tree of G π . This means that if (i, j) is an edge of T with i > j, then i appears before j in π, which implies π −1 (i) < π −1 (j). This is exactly the condition that (T, π −1 ) is a tiered tree. The converse follows in the same way.
2.4. The Abelian sandpile model. The ASM is a dynamic process on a graph which has attracted considerable attention through the years, and remains a constant source of new and interesting research topics.
Let G = (V, E) be a finite, connected, loop-free, undirected graph with vertex set V = [n] for some n. Let d i = d i (G) be the degree of the vertex i in G. We will consider the sandpile model on the graph G with a distinguished vertex s ∈ [n], called the sink. We indicate that by writing this as the pair (G, s).
A configuration on (G, s) is a vector c = (c 1 , . . . , c n ) ∈ Z n + that assigns the number c i to vertex i. We think of c i as the number of 'grains of sand' at the vertex i. Configs (G) is the set of all configurations on (G, s). Let α i ∈ Z n be the vector with 1 in the i-th position and 0 elsewhere.
We say that a vertex i is stable in a configuration c = (c 1 , . . . , Unstable vertices may topple. We define the toppling operator T i corresponding to the toppling of an unstable vertex i ∈ [n] in a configuration c ∈ Configs (G) by where the sum is over all vertices adjacent to i. In words, when a vertex i topples, it sends one grain of sand along each incident edge to its neighbors. We write c i − → c ′ to indicate that the vertex i is unstable in c and that T i (c) = c ′ .
It is possible to show (see for instance [9, Section 5.2]) that starting from any configuration c and toppling unstable vertices, one eventually reaches a stable configuration c ′ . Moreover, c ′ does not depend on the order in which unstable vertices are toppled in this sequence. Definition 2.6. A configuration c ∈ Configs (G) is recurrent on (G, s) if it satisfies the following three conditions: (1) We have c s = d s .
(2) The configuration c is stable, that is, In words, the third condition states that there is an ordering of the vertices such that starting from c, every vertex can be toppled (exactly) once in this order. The fact that after making these topplings one returns to the configuration c is guaranteed by the following argument: On every edge (i, j) of G, toppling i sends one grain from i to j while toppling j sends one grain from j to i. Thus, toppling every vertex exactly once leaves the initial configuration unchanged.
Let Rec s (G) be the set of recurrent configuration on a graph G with sink s. Given c ∈ Rec s (G), define the level of c to be where |E| denotes the number of edges of G. From [15,Thm. 3.5] we have that if G = (V, E) is a graph and c ∈ Rec s (G), then 0 ≤ level (c) ≤ |E| − |V | + 1. The level of a recurrent configuration is thus always a non-negative integer. The level polynomial of a graph (G, s) is the generating function of the level statistic over the set of recurrent configurations on that graph: x level(c) .
Finally, we define the notion of canonical toppling. Given a recurrent configuration c ∈ Rec s (G), the canonical toppling of c is the ordered set partition P = P 0 , . . . , P k of [n] where P 0 = {s} and for i ≥ 1, P i is the set of (non-sink) unstable vertices resulting from the toppling of all vertices in P 0 , . . . , P i−1 . The fact that this gives a partition of [n] is guaranteed by Condition (3) of Definition 2.6. For c ∈ Rec s (G), we denote by CanonTop(c) the canonical toppling of c.
Example 2.7. Let π = 3421 and G 3421 be the corresponding permutation graph, as illustrated in Figure 3. Fix s = 3 to be the sink vertex (represented as a square), and consider the configuration c = (1, 2, 2, 1) (grains are represented as red dots next to their vertex). We have c 3 = 2 = d 3 and c i < d i for i = 3 so the first two conditions of Definition 2.6 are satisfied. We show that the third condition is also satisfied, and simultaneously determine the canonical toppling.

3.
A bijection from trees to recurrent configurations of the ASM 3.1. The bijection. Let π ∈ S n and T be a spanning tree of G = G π , that is, such that (T, π −1 ) is a tiered tree by Proposition 2.5. Let s ∈ [n] be a distinguished vertex of G. We view the tree T as being rooted at s. Given i ∈ [n], we define the height of i in T to be its distance to the root s, and denote it h(i). If i = s, the parent of i is the next vertex encountered on the unique path from i to s, and we denote this p(i). For k ≥ 1, we define T (k) := {i ∈ n : h(i) = k} to be the set of vertices at height k in T , with analogous definitions for T (>k) , T (≥k) , etc. Finally, we let N G (i) be the set of neighbors of i in the graph G. For i ∈ [n], we let: In words, λ i is the set of neighbors of i in G at height strictly greater than i in T , µ i is the set of neighbors of i in G at the same height as i in T , and ν i is the set of neighbors of i in G at height one less than i, and whose labels are strictly smaller than the parent of i. Although it would be natural to combine λ i and µ i into one number, this definition facilitates our proof of the following theorem. Note that these definitions all depend on the choice of a distinguished vertex s, though for lightness of notation we do not make this explicit.

That is, the canonical toppling of c(T ) is given by the breadth-first search of T .
Before we prove this result, let us examine one example in depth.
Example 3.2. Let π = 514362. The associated permutation graph G = G π is represented on the left of Figure 4. We take s = 3 to be the sink. Let T be the spanning tree of G on the right of Figure 4. We represent T as a tree rooted at the distinguished vertex 3, and compute the corresponding configuration c(T ): For i = 1, there are no vertices at height greater than h(1) = 2 in T , and none of the other two vertices at height 2 are neighbors of 1 in G, so that λ 1 = µ 1 = 0. In fact, the parent of 1 in T is its only neighbor in G, so that we also have ν 1 = 0, and thus c 1 = 0. Now consider the vertex i = 2. In T there are three vertices at height greater than h(2) = 1, which are 1, 4, 6. Of these, 4 and 6 are neighbors of 2 in G, so that λ 2 = 2. Similarly, 5 is the other vertex at height 1 in T , and is a neighbor of 2 in G, so that µ 2 = 1. Finally, the parent of 2 in T is the only vertex at height 1 − 1 = 0, so ν 2 = 0. Thus, Similarly, c 3 = 3 + 0 + 0 = 3. Now for i = 4, we have λ 4 = 0 (there are no vertices at a greater height in T ), µ 4 = 0 (neither 1 nor 6 are neighbors of 4 in G). But both 2 and 5 are neighbors of 4 in G with height equal to h(4) − 1 in T , and the parent of 4 in T is 5, so that ν 4 = 1, and thus c 4 = 0 + 0 + 1 = 1. Finally, we can see that c 5 = 2 + 1 + 0 = 3, and c 6 = 0 + 0 + 0 = 0. Thus, we have c(T ) = (0, 3, 3, 1, 3, 0).
We check that c(T ) is recurrent using Definition 2.6, and also establish that the canonical toppling of c(T ) is given by the breadth-first search (BFS) of T . The vertex degree sequence of G is given by (1,4,3,3,4,1), and the BFS of T is 3−25−146 with dashes separating the sets of vertices at different heights. Start from the configuration c = c(T ) = (0, 3, 3, 1, 3, 0). We have c 3 = d 3 and c j < d j for j = 3, as desired. Therefore we initially topple vertex 3. This leads to the configuration (0, 4, 0, 2, 4, 0). In this configuration, vertices 2 and 5 are unstable. We topple these, which leads to the configuration (1, 1, 2, 4, 1, 1). In this configuration, vertices 1,4 and 6 are unstable. We topple these, which leads back to the initial configuration (0, 3, 3, 1, 3, 0). Thus, by Definition 2.6 the configuration c(T ) is recurrent, and we have moreover shown that CanonTop c T = 3 − 25 − 146, which is exactly the BFS of T .
Finally, the graph G has 8 edges, so that on the one hand On the other hand, we have which gives the desired result. T Figure 4. The graph G associated with the permutation π = 514362 (left) and a spanning tree T of G represented as rooted at the distinguished vertex 3 (right). Configuration on G corresponding to T shown with red dots.
Proof of Theorem 3.1. Let T be a spanning tree of T , and c := c(T ) the corresponding configuration. We first show that c is recurrent, and that CanonTop(c) = T (0) , T (1) , . . ., using Definition 2.6.
(1) The sink s is the unique vertex at height 0 in T , so that λ s = |N G (s)| = d s , and We now show that, starting from the configuration c, for any k ≥ 1, if we topple the vertices of T (0) , . . . , T (k−1) , then the set of non-sink unstable vertices is exactly T (k) . Combined with the above, this shows that c is recurrent, and that CanonTop(c) = T (0) , T (1) , . . .. Let k ≥ 1 and let c ′ be the configuration reached from the initial configuration c after toppling the vertices of T (0) , . . . , T (k−1) . We need to show that , since the second term of the sum is the number of grains vertex i receives through toppling T (0) , . . . , T (k−1) . Thus This completes the first part of the proof, namely that c is recurrent, and that CanonTop(c) = It remains to show that φ T C is a bijection. To do this, we exhibit its inverse. Let c ∈ Rec s (G), and write CanonTop(c) = P 0 , P 1 , . . . for the canonical toppling of c, with P 0 = {s}. We construct a spanning tree T = T (P ) of G from this as follows. The levels of T are such that for all j ≥ 0 we have T (j) = P j . To define T it is then sufficient to define a parent map p : [n] \ {s} → [n] such that for any j ≥ 1 and i ∈ P j , we have p(i) ∈ N G (i) ∩ P j−1 . That this intersection is nonempty follows from the definition of the canonical toppling, since for i to topple in P j it must have received some grains through the toppling of P j−1 .
Fix some j ≥ 1 and i ∈ P j . The definition of the canonical toppling implies the following property: Starting from c, the vertex i is stable after toppling the vertices from P 0 , . . . , P j−2 , and becomes unstable after toppling those of P j−1 . For k ≥ 0, let N (<k) G (i) be the set of neighbors of i in G which are in P 0 ∪· · ·∪P k−1 . The previous property can then be summarized in the following two inequalities: We then define p(i) to be the (r i + 1)-th largest element of N G (i) ∩ P j−1 , and let T = φ CT (c) be the spanning tree of G resulting from this construction. We now show that φ CT is the inverse of φ T C .
First, let T be a spanning tree of G and set T ′ := φ CT (φ T C (T )). By construction, we have T (k) = T ′(k) for all k ≥ 0, so we only need to show that for any This shows that φ CT (φ T C (T )) = T for any spanning tree T . Since it is well known that the number of recurrent configurations for the ASM on a graph G is equal to a number of spanning trees of G (see for instance [18,Section 3.2]), this is sufficient to conclude that φ T C is a bijection, with φ CT its inverse. Remark 3.3. Theorem 3.1, combined with Proposition 2.5, provides a bijection between the set of (fully) tiered trees on [n] and the (disjoint) union of the sets of recurrent configurations for the ASM over all (connected) permutation graphs on n vertices. In particular, we have that the number of (fully) tiered trees on [n] is given by the sum π |Rec s (G π ) |, where the sum is over all indecomposable permutations of length n, and s is some fixed (but arbitrary) sink in [n].

3.2.
A Tutte-descriptive activity. Let π ∈ S n be a permutation, G = G π its permutation graph, and s ∈ [n] a distinguished vertex of G. Given a spanning tree T , we interpret the level statistic of the corresponding recurrent configuration c(T ) ∈ Rec s (G) as the external activity of the spanning tree T . Definition 3.4. Let G = (V, E) be a graph, T a spanning tree of G, and ≺ a total order on the edges E of G. An edge e / ∈ T is said to be externally active if it is the maximal edge for ≺ in the unique cycle contained in T ∪ {e}. An edge e ∈ T is said to be internally active if it is the maximal edge for ≺ in the unique cocycle contained in T \ {e}, that is, in the set of edges connecting the two connected components of T \ {e}. The external, resp. internal, activity of T is its number of externally, resp. internally, active edges, and is denoted by ext(T ), resp. int(T ).
In light of this, Theorem 3.1 can be interpreted as a bijection between recurrent configurations and spanning trees of a graph, mapping the level of a configuration to the external activity of the corresponding tree. This bijection is different from those already existing in the literature, such as [5,7].
Recall that the Tutte polynomial of a (connected) graph G = (V, E) is defined by where for S ⊆ E, cc(S) denotes the number of connected components of the subgraph (V, S). The level and Tutte polynomial of a graph are related by the following well-known result. This result was initially proved by López [15], following a conjecture by Biggs. Subsequent combinatorial (bijective) proofs have been given, for instance, by Cori and Le Borgne [7], and Bernardi [5]. The aim of the remainder of this section is to show that Theorem 3.1 gives a new bijective proof in the case of permutation graphs.
Let G = G π be a permutation graph with sink s. We first show that for a spanning tree T of G, we can construct an order ≺ T on the edges of G such that level (φ T C (T )) = ext(T ). We then show that the order map T →≺ T is Tutte-descriptive in the sense introduced by Courtiel in [8]. Let T be a spanning tree of G. As usual, we root T at s. The following algorithm defines an order ≺ T of E. This order ≺ T is similar to that introduced by Gessel and Sagan in [13], though where theirs is based on a depth-first search of T ours is based on a breadth-first search, since vertices are visited in that order.
Example 3.7. Let π = 514362 so that G π is the graph on the left in Figure 4, and consider the spanning tree T on the right in that figure. We initially set k = 0 and v = 3 which is the only vertex at height 0 in T . Proceeding to Step (3), we have S = {(3, 2), (3,4), (3,5)}. We order these (3, 5) ≺ (3, 4) ≺ (3, 2). We then mark 3 as visited, and return to Step (2). Since there are no unvisited vertices left at height 0, we move to height 1.
We now prove Theorem 3.8.  (i, j) is not an edge of T ) the construction in Algorithm 3.6 implies that (i, j) ≺ T (p(j), j) . Since the edge (p(j), j) is contained in the unique cycle of T ∪ {(i, j)}, this means that e is not externally active, which is a contradiction. Hence we must have i < p(j), as desired.
Conversely, suppose that h(i) = h(j) or h(i) = h(j) − 1 and i < p(j). Note that the unique cycle of T ∪ {(i, j)} is formed of the union of the paths i ↔ i ∧ j and j ↔ i ∧ j and of the edge e, where i ∧ j is the greatest common ancestor of i and j in the tree T . If h(i) = h(j) or h(i) = h(j) − 1, then all vertices of those paths other than i and j are visited before i and j in the construction of Algorithm 3.6, which implies that all edges of the paths i ↔ i ∧ j and j ↔ i ∧ j are ordered in ≺ T before (i, j), and thus that edge is externally active by definition. This completes the proof. Theorem 3.8 states that the level of the configuration corresponding to a spanning tree T via Theorem 3.1 can be interpreted as the external activity of T for a specific order ≺ T of the edges of G. We now show that this order is Tutte-descriptive in the sense introduced by Courtiel [8].
Definition 3.11. Let G = (V, E) be a graph, and suppose we have a mapping Ψ : T →≺ T from the set of spanning trees of G to the set of total orders on E. We say that the mapping Ψ is Tutte- where the sum is over all spanning trees of G, and int(T ), resp. ext(T ), is the number of internally, resp. externally, active edges for the order ≺ T .
Remark 3.12. In fact, Courtiel in [8] introduces a more general notion of Tutte-descriptive activity. Our notion above corresponds to what he calls tree-compatible order maps.
Theorem 3.13. Let G = G π be a permutation graph, with sink s. Then the mapping T →≺ T , where ≺ T is the order defined by Algorithm 3.6, is Tutte-descriptive.
Proof. This follows from [8,Theorem 5.3] in analogous fashion to the proof of [8, Proposition 7.9], with the slight adjustments necessary to take into account that Algorithm 3.6 provides an order map based on a breadth-first, rather than depth-first, search.
Combining Theorems 3.8 and 3.13 gives a new combinatorial proof of the link between the level polynomial and the Tutte polynomial in Proposition 3.5 in the case of permutation graphs.

Minimal recurrent configurations. Given a graph G and a distinguished vertex s of G, a configuration c ∈ Configs (G) is minimal recurrent if it is recurrent and level (c) = 0.
We denote by Rec min s (G) the set of minimal recurrent configurations for the ASM on G. We show that on permutation graphs, minimal recurrent configurations are uniquely determined by their canonical toppling.
Definition 4.1. Given a permutation π ∈ S n and a distinguished vertex s ∈ [n], we say that an ordered set partition P = P 0 , . . . , P k of [n] is (π, s)-compatible if it satisfies the following three conditions: (1) P 0 = {s}.
(2) For any j ≥ 0, the elements of P j appear in increasing order in π (that is, there is no inversion in π between two elements of P j ). (3) For any j ≥ 1 and i ∈ P j , there exists i ′ ∈ P j−1 such that (i, i ′ ) or (i ′ , i) is an inversion of π.
Example 4.2. Let π = 25341 and s = 3. We wish to compute the set of (π, s)-compatible ordered partitions of [5]. We always have P 0 = {3}. From Condition (3), P 1 must be formed of elements i such that (i, 3) or (3, i) is an inversion of π. There are two such elements: 5 and 1. However, (5, 1) is an inversion of π, so P 1 cannot contain both these elements by Condition (2). Thus we must have P 1 = {1} or P 1 = {5}. We now remark that the only element which forms an inversion with 2 is 1, so that, by Condition (3), 2 must be in the part immediately after that containing 1. Moreover, the part containing 2 must either contain another element, or be the final part of P . Suppose that P 1 = {1}. By the preceding argument, P 2 must contain 2 and at least one other element which forms an inversion with 1. There are two remaining elements which do this: 4 and 5. Since (5, 4) is an inversion, P 2 cannot contain both of these, so we must have P 2 = {2, 4} and P 3 = {5}, or P 2 = {2, 5} and P 3 = {4}. Suppose now that P 1 = {5}. By similar arguments, we must have P 2 = {1} or P 2 = {4}. Using the argument from the previous paragraph, if P 2 = {1}, then we must have P 3 = {2, 4}, and if P 2 = {4}, then we must have P 3 = {1} and P 4 = {2}. Finally, we see that there are four (π, s)-compatible ordered partitions, which we write as blocks separated by dashes, for clarity: . Thus for any j ∈ [k] there are no edges in G between any two vertices of P j . This implies that the elements of P j appear in increasing order in π, so Condition (2) of Definition 4.1 is satisfied. Now let j ≥ 2 and i ∈ T (j) = P j . Let i ′ = p(i) be the parent of i in T , so that i ′ ∈ T (j−1) = P j−1 . Since (i ′ , i) is an edge of T it is also an edge of G, which means that (i ′ , i) or (i, i ′ ) is an inversion of π, as desired. We have thus shown that if c ∈ Rec min s (G π ), then CanonTop(c) is a (π, s)-compatible ordered partition of [n]. This shows that the map of Proposition 4.3 is well defined.
To show that it is a bijection, we define its inverse. Suppose that P = P 0 , . . . , P k is a (π, s)-compatible ordered partition of [n]. We first construct a spanning tree T = T (P ) of G. The tree T will be rooted at s so that for all j ∈ [k] we have T (j) = P j . To define T it is thus sufficient to define the parent map p. For j ≥ 1, and i ∈ P j , we define By Condition (3) of Definition 4.1, p(i) is well defined, that is, N G (i) ∩ P j−1 = ∅. We now define c = φ P C (P ) := φ T C (T (P )), where φ T C is the bijection of Theorem 3.1, and T (P ) is the tree defined above. We show that c is minimal. Let i ∈ [n]. By Condition (2) of Definition 4.1, we have µ i (T ) = 0 since there are no edges in G between any two vertices of T (h(i)) = P h(i) . Moreover, Equation (5) implies that ν i (T ) = 0. Since these are true for any i ∈ [n] it follows from Theorem 3.1 that level (c) = 0, as desired.
Finally, it is straightforward to show that the maps φ P C and φ CP are inverses of each other, which completes the proof.

4.2.
Complete non-ambiguous binary trees. Non-ambiguous binary trees were introduced and studied in [2] as a special case of the tree-like tableaux from [3]. (1) Every row and every column has a dotted cell.
(2) Except for the top left cell, every dotted cell has either a dotted cell above it in its column or to its left in its row, but not both.
The dot in the top left cell (implied by (1) and (2)) is called the root dot, or simply the root.
Through the remainder of this section, when we talk about a dot to the left/right of another dot we mean in the same row, and similarly in the same column for above/below.
The name non-ambiguous binary tree comes from the fact that by drawing an edge between a dotted cell and the dotted cell immediately above it or to its left, for all dotted cells, one creates a binary tree, embedded in the grid Z 2 . Regarding the dot in the top left cell as a root of the tree, Condition 2 of Definition 4.4 ensures that every other dot has a unique parent.
A NAB is complete if the associated binary tree is complete, that is, every dotted cell has either a dotted cell below it and to its right, or neither of these, and we refer to such complete NABs as CNABs. Figure 5 shows two examples of NABs, with the edges of the associated binary tree drawn in. The left-hand one is complete, while the right-hand one is not. Figure 5. Two examples of NABs. The left-hand one is complete, and thus a CNAB, while the right-hand one is not, since the red vertex in column 1, row 3, has only one child. Proof. Each non-root dot has a dot above it or to its left, but not both. If such a dot has no dot above it, move it to the top row. Otherwise it has no dot to its left, in which case move it to the leftmost column. This moves every dot either to the top row or leftmost column. (We regard dots in the top row and leftmost column as being moved, although they stay put.) Every column has a dot that will be moved up, namely the column's topmost dot, and every row's leftmost dot moves to the leftmost column. This process will therefore leave dots in the entire top row and leftmost column, but nowhere else, which proves the first part.
Given a complete NAB, we trace the above process of moving dots to the top row or leftmost column. For each non-root dot that gets moved to the top row the dot to its left (its parent) has a dot below it, which therefore gets moved into the leftmost column, and conversely. Thus, there must be as many rows as columns.

4.3.
Complete non-ambiguous binary multitrees. Given a permutation π = π 1 π 2 . . . π n let T π be the n × n grid with dots in cells (π i , i), where cell (i, j) is the cell in row i and column j, the northwest corner cell being (1, 1). Definition 4.6. A complete multirooted non-ambiguous binary tree (CMNAB) is obtained from T π , for a permutation π, by adding a further n − 1 dots with the following conditions: (1) Every added dot has a dotted cell below it in its column and to its right in its row.
(2) The graph obtained as in the case of a CNAB is a tree.
The added dots are called internal dots. The set of CMNABs arising from T π is denoted M π , and the tree obtained from M ∈ M π is denoted T (M ).
A CMNAB gives a multirooted tree where the roots are the dots with no dots to the left or above; see Figure 6. We will show that CNABs are precisely the CMNABs with a single root.
Lemma 4.7. A cell (i, j) in T π has a dot to the right and below if and only if there is an edge between i and π j in G π .
Proof. If a cell (i, j) has dots both to the right and below then there is a leaf dot below it in row r > i, so π j = r, and to its right in column c > j, so π c = i < r. Since j < c and π j > π c = i, π j and i form an inversion in π, so (π j , i) is an edge in G π .
Conversely, an edge in G π corresponds to an inversion in π, which in turn corresponds to a pair of leaf dots in π, the leftmost of which is lower than the other, and thus there is a cell above the leftmost one and to the left of the other.
By Lemma 4.7 every cell in T π with an internal dot corresponds to an edge in G π . So we can map the elements of M π to subgraphs of G π , by the map ζ which maps M ∈ M π to the subgraph ζ(M ) of G π with edge set E(ζ(M )) = {(i, π j ) : (i, j) contains an internal dot in M }.
Note that the non-internal dots in M are the leaves of T (M ) and they correspond precisely to the pairs (i, j) where π j = i.
The following lemma is straightforward to prove. Proof. Let π be an n-permutation. By Lemma 4.7 and the fact that every element of M π has n − 1 internal dots, ζ is a map from M π to the set of subgraphs of G π with n − 1 edges. To show that those edges form a spanning tree it therefore suffices to show that they form a connected graph, which follows from Lemma 4.8. Conversely, if S is a spanning tree of G π , place a dot in cell (i, j) of T π for each edge (i, π j ) of S, where i < π j . By Lemma 4.7, this places n − 1 internal dots in T π and each of those dots contributes two edges to the graph in T π , connecting to a dot below and to the right, a total of 2n − 2 edges, in a graph with 2n − 1 vertices. To show that this graph is a tree it again suffices to show that it is connected, which again follows from Lemma 4.8.
If a CMNAB has a unique root then the definition is equivalent to that of a CNAB, as we will now show.  1), thus creating a CNAB, would correspond to replacing the edge (2, 6) by (1,4) in the spanning tree, whereas moving the dot at (2, 1) to (3,1) corresponds to replacing the edge (2, 4) with (3,4). Proof. Suppose M has a dot d with a dot a above and a dot ℓ to the left. Tracing a zig-zag path from d through a to the topmost dot in their column, then to the leftmost dot in that row, and so on, we must end up at a dot with no dot above or to the left, which is a root dot d 1 . Tracing analogously through ℓ we will end up at a root dot d 2 . These two root dots must be distinct, for otherwise we would have traced out a cycle in the tree T (M ). Suppose then that M has (at least) two distinct root dots ℓ and h, which then must be in different rows, say h in a higher row. The unique path from ℓ to h in the tree T (M ) must contain an up-step, but start with a right or a down step. Consider the maximal sequence of right and down steps in the beginning of that path. If the last step in that sequence was a right step the next step must be up, if it was a down step the next step must be left. In either case we have found a dot with a dot to the left and above. Proof. Every row in a CNAB has a unique leaf dot, which is also the unique leaf dot in its column, and this accounts for n dots. The remaining n − 1 dots are internal and satisfy Condition (1) in Definition 4.6, and CNABs satisfy Condition (2) in Definition 4.6, so every CNAB is a CMNAB. Conversely, if a CMNAB M has a single root, then by Lemma 4.10 no dot has a dot to the left and above, and so M satisfies Condition (2) in Definition 4.4 (and Condition (1) by definition) and thus is a CNAB.
We can use the map ζ to map the CNABs on T π to the minimal recurrent configurations on G π . For the following lemma we order the edges of G π reverse lexicographically by coordinates of the corresponding cells in T π (see Definition 3.4 of external activity). Proof. If M has more than one root, then Lemma 4.10 implies there exists a dot d in M with a dot a above and dot ℓ to the left. Let c be the cell that completes the rectangle of a, ℓ and d.
Then c corresponds to an edge external to the spanning tree S and adding it to S creates a cycle with edges corresponding to a, ℓ, c and d, by Lemma 4.8. Since the edge corresponding to c is ordered last of these edges it is externally active.
If e is an externally active edge then adding it creates a cycle in the spanning tree S, which corresponds to a cycle of internal dots in M . Such a cycle must contain a dot with a dot to the left and a dot above. However, as e is externally active it must be ordered last in its cycle in S so the corresponding dot in M is weakly northwest of all other dots in the cycle. Thus the addition of the dot corresponding to e cannot cause one of the pre-existing dots to have a dot to the left and above. Therefore, such a dot must already exist in the cycle, so M has a cell with a dot to the left and a dot above, which implies M is multirooted, by Lemma 4.10.
Note that in this case, unlike in Section 3.2, the order of the edges of G = G π is fixed a priori (it does not depend on the tree T ). It is known (see [19]) that in this case we have where the sum is over all spanning trees of G, and thus by Proposition 3.5 the spanning trees with no external activity are in bijection with the minimal recurrent configurations. Therefore, Proposition 4.11 and Proposition 4.12 imply the following. Remark 4.15. In [10], the authors provided a new interpretation of the sequence A002190 = 1, 1, 4, 33, 456, 9460, . . . in [1] counting complete non-ambiguous binary trees, in terms of fully tiered trees with weight 0. Section 4.1 and Corollary 4.13 provide another two combinatorial interpretations to this sequence: • as the sum π∈Sn |Rec min s (G π ) |, whereS n is the set of indecomposable permutations of length n. • as the number of pairs (π, P ) where π ∈S n and P is a (π, s)-compatible ordered partition of n.

Specialisations
5.1. The Ferrers case. In this section, we are interested in the case where the permutation π has a single descent, in which case the permutation graph G π is a Ferrers graph. In this case the spanning trees of the permutation graph are the intransitive trees introduced by Postnikov [17]. As such, we recover results from [11,Section 5.3].
A Ferrers graph (see [12]) is a bipartite graph whose vertices of each part are labeled t 1 , t 2 , . . . , t k and b 1 , b 2 , . . . , b m , respectively, satisfying the following conditions: (1) If (t i , b j ) is an edge with r ≤ i and s ≤ j, then (t r , b s ) is also an edge.
(2) Both (t 1 , b m ) and (t k , b 1 ) are edges. As illustrated in the example in Figure 7, we think of the vertices t i as "top" vertices, and the b i as "bottom" vertices. Note that when read from left to right the labels on the top vertices are increasing but decreasing for the bottom vertices. Thus, condition (1) above says that a top vertex must have edges to all vertices that any vertex to its right does, and likewise for bottom vertices. Given a Ferrers diagram with rows labeled from top to bottom with t 1 , t 2 , . . . , t k and columns labeled with b 1 , b 2 , . . . , b m from left to right, there is a unique Ferrers graph whose vertices are labeled with the t i and b j and where (t i , b j ) is an edge if and only if the diagram has a cell in row t i and column b j . This correspondence is clearly one-to-one.
Given a permutation π ∈ S n , we say that the pair π i , π i+1 is a descent of π if π i > π i+1 .
Proposition 5.1. Let G be a graph on n vertices. Then G is a Ferrers graph if and only if there exists an indecomposable permutation π with exactly one descent such that G ≃ G π .
Proof. Suppose that π is indecomposable and has a single descent. Then we can decompose π in a unique way as π = π 1 π 2 , where π 1 and π 2 are increasing subsequences of [n] and the last letter of π 1 is strictly greater than the first letter of π 2 . Since π is indecomposable, this implies that the the last letter of π 1 is n, and the first letter of π 2 is 1. Now we let F = F (π) be the Ferrers diagram defined as follows. Label the edges on the South-East border of F from North-East to South-West in the order 1, 2, . . . , n, and let the step labeled k be a South step if k ∈ π 2 and a West step if k ∈ π 1 . This defines a Ferrers diagram since 1 ∈ π 2 . Then the edges of the corresponding Ferrers graph G(F ) are the pairs (i, j) where i is a column label (a West step), j a row label (a South step), and i > j, that is, exactly the inversions of π. Thus G π ≃ G(F ). For the converse, suppose G = G(F ) is the Ferrers graph corresponding to the Ferrers diagram F , whose South-East border is labeled as before. Let π 1 and π 2 be the words formed of West steps and East steps, respectively, of that border, each in increasing order. Then π = π 1 π 2 is a permutation of length n with exactly one descent, and as above, we have G ≃ G π , as desired (that π is indecomposable follows from the fact that a Ferrers graph is connected). Figure 7 illustrates the construction in the proof of Proposition 5.1. Thus, Ferrers graphs can be viewed as permutation graphs where the permutation has a single descent.
Remark 5.2. It is possible for a permutation with more than one descent to yield a Ferrers graph. For instance, the graph corresponding to the permutation 3142 is isomorphic to P 4 , the path graph on 4 vertices, which is a Ferrers graph. Indeed, P 4 is the Ferrers graph corresponding to the diagram whose row lengths are (2, 1), or equivalently, it is isomorphic to the permutation graph G 2413 . We revisit Theorem 3.1 in the context of Ferrers graphs. Let π ∈ S n be an indecomposable permutation with a single descent, and G = G π the corresponding Ferrers graph. We decompose π into π 1 π 2 as before, where π 1 and π 2 are two increasing sequences such that the last letter of π 1 is n and the first letter of π 2 is 1. We write A 1 and A 2 for the unordered set of labels appearing in π 1 and π 2 , respectively. For j ∈ {1, 2}, we setj := 3 − j, so that if j = 1, j = 2 and vice versa.
be a distinguished vertex of G = G π where π has a single descent, and let j ∈ {1, 2} be such that s ∈ A j . Let T be a spanning tree of G, rooted at s. Then for any k ≥ 0, we have: Proof. Any edge e of G is a pair e = (x, y) ∈ A 1 × A 2 . Thus if e = (x, y) ∈ T (k) × T (k+1) is an edge of T , we have that if x ∈ A j then y ∈ Aj and vice versa. Since T (0) = {s} ⊆ A j , the claim follows immediately by induction.
An immediate consequence of Lemma 5.3 is the following. Proof. Given k ≥ 0, Lemma 5.3 implies that G has no edges between two elements of T (k) .
We now show that in this case, there is a one-to-one correspondence between spanning trees of permutation graphs G π where π has a single descent, and the intransitive trees first introduced by Postnikov [17]. Let T be a labeled tree on the vertex set [n]. We say that T is intransitive if all its vertices are either local minima or local maxima. Given a tree T , we denote by LocMin(T ) and LocMax(T ) its set of local minima and maxima, respectively. Thus T is an intransitive tree if and only if LocMin(T ), LocMax(T ) forms a partition of [n].
The following Proposition is essentially a re-writing of Proposition 2.5 in the case of permutations with a single descent, but we give a proof in the current context. Proposition 5.5. Let π be an indecomposable permutation with a single descent. Write π = π 1 π 2 with π 1 and π 2 being, respectively, the increasing ordering of a set A 1 containing n and of a set A 2 containing 1. Let T be a labeled tree on the vertex set [n]. Then T is a spanning tree of G π if and only if T is an intransitive tree with LocMax(T ) = A 1 and LocMin(T ) = A 2 .
Proof. Suppose that T is a spanning tree of G = G π , and let i ∈ A 1 . By construction, if (i, j) is an edge of G, then j ∈ A 2 and i > j. In particular, all neighbors of i in T have labels strictly less than i, so that A 1 ⊆ LocMax(T ). Similarly, we have A 2 ⊆ LocMax(T ), and since A 1 , A 2 forms a partition of [n] this implies that T is an intransitive tree with LocMax(T ) = A 1 and LocMin(T ) = A 2 . The converse follows from the fact that if T is an intransitive tree, all its edges connect a local maximum i to a local minimum j with i > j.
We now restate Theorem 3.1 in this specialized context. Let π be an indecomposable permutation with a single descent. Write π = π 1 π 2 with π 1 and π 2 being, respectively, the increasing ordering of a set A 1 containing n and of a set A 2 containing 1. Let G = G π be the corresponding permutation graph (which is a Ferrers graph by Proposition 5.1). Let s ∈ [n] be a distinguished vertex of G, and T a labeled tree on [n], rooted at s. For i ∈ [n], we define: ν i (T ) := T (h(i)−1) ∩ (p(i), i) , where p(i) is the parent of i in the rooted tree T , and (p(i), i) is the interval [p(i) + 1, i − 1] if p(i) < i, and (p(i), i) = [i + 1, p(i) − 1] if i < p(i). In particular, we recover the bijection between the set of intransitive trees on n vertices and the set of recurrent configurations on Ferrers graphs on n vertices from [11].
Note that the definition ofν in Equation (7) differs slightly from that of ν in Equation (4) in Section 3.1 (the definition ofλ is the same as that of λ, though written slightly differently). This is due to the extra structure of intransitive trees, namely that every vertex is either a local minimum or a local maximum, which allows this simpler formula to be given. There is no additional difficulty in the proof, it merely requires a slight tweaking of the inverse map introduced in the proof of Theorem 3.1.

5.2.
Threshold graphs. Threshold graphs were introduced by Chvátal and Hammer [6] and are defined as those graphs that can be constructed from a graph with one vertex by repeatedly adding an isolated vertex or a vertex that is connected to every already existing vertex. It is easy to see that a threshold graph is the permutation graph of a permutation obtained from the permutation 1 by repeatedly appending or prepending a new largest letter. One example of such a permutation is 86521347; these are exactly the permutations that first decrease and then increase. Note, however that a threshold graph may be disconnected and thus correspond to a decomposable permutation (which will have its largest letter last).
In [16] the authors present a general bijection between the parking functions of a graph and labeled spanning trees. In the case where G is a threshold graph, this bijection maps the degree of the parking function to the number of inversions of the spanning tree (an inversion of a tree T with vertex set [n] is a pair (i, j) such that i > j and j is an ancestor of i in T , relative to a designated root). Parking functions of a graph are essentially the same as recurrent configurations for the ASM, via a simple linear translation, with the degree of a parking function corresponding to the level of a recurrent configuration. Thus, the bijection in [16] can be viewed as a bijection between recurrent configurations on a threshold graph G and spanning trees of G, mapping the level statistic of the configuration to the number of inversions of the trees.
In Section 3.2, we showed that our bijection in Theorem 3.1 can be seen as a bijection between recurrent configurations on a permutation graph G and spanning trees of G, mapping the level of the configuration to the external activity of the tree. It is known that the inversion and external activity statistics are equidistributed over labeled trees on n vertices, and [4] provides a bijective proof of this fact. Since threshold graphs are a special case of permutation graphs, it follows that Theorem 3.1 can be viewed as an extension of the work in [16].