Perfect refiners for permutation group backtracking algorithms

Backtrack search is a fundamental technique for computing with finite permutation groups, which has been formulated in terms of points, ordered partitions, and graphs. We provide a framework for discussing the most common forms of backtrack search in a generic way. We introduce the concept of perfect refiners to better understand and compare the pruning power available in these different settings. We also present a new formulation of backtrack search, which allows the use of graphs with additional vertices, and which is implemented in the software package Vole. For each setting, we classify the groups and cosets for which there exist perfect refiners. Moreover, we describe perfect refiners for many naturally-occurring examples of stabilisers and transporter sets, including applications to normaliser and subgroup conjugacy problems for 2-closed groups.


Introduction
A careful backtrack search through the elements of a symmetric group is the fastest general purpose technique, in practice, for solving many computational problems in finite permutation groups.This includes finding normalisers and intersections of subgroups, and stabilisers of sets and graphs.
At the heart of these backtracking algorithms are refiners.Refiners are functions which are used to prune redundant parts of the search.They provide the main facility for taking into account the structural aspects of the problem at hand, and making clever deductions.Better refiners are more likely to prune more efficiently, and can reduce search times by orders of magnitude.Refiners, therefore, are an obvious and ongoing target of further research (see for example Jefferson et al., 2019a for recent work in this area), and they are the focus of this article.
Roughly speaking, backtracking algorithms organise permutations as bijective maps on sets of combinatorial structures.The first version was originally formulated by Sims, organised around a base and strong generating set (see Sims, 1971).Two decades later, Leon reformulated this in terms of ordered partitions (Leon, 1991(Leon, , 1997)), and thereby obtained significantly improved performance in many cases.This technique was enhanced with orbital graphs in Theißen (1997), Jefferson et al. (2019a).More recently, this use of orbital graphs inspired a reformulation in Jefferson et al. (2021) around labelled digraphs.
The motivation for organising a search around more sophisticated structures is to allow some sets of permutations to be represented with greater fidelity, so that refiners can prune more effectively.However, when choosing the appropriate search infrastructure for a particular problem, we need to keep in mind that more complicated structures do not always offer better pruning, that they are more expensive to compute with, and that it is easy to find relatively small cases where all existing backtracking algorithms exhibit poor performance.This holds especially for subgroup conjugacy and normaliser problems.It is therefore important to develop tools for understanding which problems are well suited to which kinds of backtrack search and refiners, and to understand the limitations of the existing techniques, with the aim of developing improvements.
This article has three main purposes.Firstly, we introduce the concept of perfect refiners, which are those with maximal pruning power within a given search framework.This concept is also meant to initiate a discussion of the quality of refiners, both within and across various backtrack search techniques.Secondly, we describe an extension to the graph backtracking technique that permits the use of graphs with additional vertices, and which enables many more perfect refiners than previous techniques.There already is an implementation available, in Vole (Chang et al., 2021).Finally, we partially classify, and give examples of, perfect refiners in each setting of backtrack search.
Our results show that graph backtracking and extended graph backtracking admit perfect refiners for many natural problems.This goes some way to explaining the experimental data in Jefferson et al. (2021, Section 9), which demonstrated that many problems could be solved without actual backtracking happening during the search.Furthermore, we find that extended backtracking enables improved refiners for normaliser and conjugacy problems.In particular, we give refiners for normalisers and conjugacy within the extended graph backtracking framework that are perfect in some cases.
This article is organised as follows.In Section 2, we present some necessary background definitions and notation; in particular, we briefly describe backtrack search in finite symmetric groups.We then give definitions and results about arbitrary refiners in Section 3 and perfect refiners in Section 4. In Section 5, we examine perfect refiners for stabiliser and transporter problems.In Section 6, we introduce extended graph backtracking.In Section 7, we compare the various kinds of backtrack search and their potentials for perfect refinement.In Section 8, we give examples of perfect refiners for many natural problems.We conclude with some final remarks in Section 9.
Acknowledgements The results discussed here build on work in Jefferson et al. (2021), and we include elements of an earlier draft of that article (Jefferson et al., 2019, Section 5.1).We therefore thank the VolkswagenStiftung (Grant no.93764) and the Royal Society (Grant code URF\R\180015) again for their financial support of this earlier work.For financial support during the more recent advances, we thank the DFG (Grant no.WA 3089/9-1) and again the Royal Society (Grant codes RGF\EA\181005 and URF\R\180015).

Background and notation
In this section, we give some notation and definitions, and we introduce background concepts including backtrack search in the symmetric group.Our terminology and notation closely follows that of Jefferson et al. (2021).
Sets and lists feature prominently in this article: a set is an unordered duplicate-free collection of objects, whereas a list has an ordering, and may contain duplicates.If L and K are lists, then |L| denotes the number of elements in L, L K denotes the concatenation of L and K , and if i ∈ {1, . . ., |L|}, then L[i] denotes the element of L in the i-th position.
Throughout this article, is a nonempty finite set, and Sym( ) is the symmetric group on .We denote any action of Sym( ) by exponentiation.Given an action of Sym( ) on a set O, we iteratively define an action of Sym( ) induced on the set of all subsets of O, and on the set of all finite lists with elements in O.In more detail, for all x 1 , . . ., x k ∈ O and g ∈ Sym( ), we define {x 1 , . . ., Let O be a set on which Sym( ) acts.We define Stacks(O) to be the set of all finite lists with entries in O (we call these lists stacks), and Stacks(O) Stacks(O) to be the set of all functions from Stacks(O) to itself.If x, y ∈ O, then the transporter set from x to y in Sym( ) is denoted by Transp(x, y) := {g ∈ Sym( ) : x g = y}, and the stabiliser of x in Sym( ) is the subgroup Stab(x) := Transp(x, x) of all permutations in Sym( ) that fix x under the action.Note that for all h ∈ Sym( ), Transp(x, The setwise stabiliser of a collection x 1 , .The backtrack search techniques considered in this article are organised around lists of points, ordered partitions, and graphs.An ordered partition of a set V is a list of nonempty disjoint subsets of V whose union is V .A graph on a set V is a pair (V , E) of vertices V and a set of 2-subsets of V called edges.Similarly, a digraph on V is a pair (V , A) of vertices V and a set of ordered pairs in V called arcs.The action of Sym(V ) on the sets of all graphs and digraphs on V is defined, respectively, by (V , E) g := (V , E g ) and (V , A) g := (V , A g ) for all g ∈ Sym(V ), edge sets E, and arc sets A. A labelled digraph is a digraph with an assignment of a label to each vertex and arc.See Jefferson et al. (2021, Section 2.1) for more information.Whenever, in this article, we write that '(V , E) is a graph', then this means that V is the set of vertices and E is the set of edges as explained above.In the same way, we use the remaining notation introduced here without further explanation.

Classical backtracking, partition backtracking, and graph backtracking
We briefly summarise the concept of backtrack search in Sym( ), and introduce some terminology.Let U 1 , . . ., U k be subsets of Sym( ) for some k ∈ N, and suppose that we wish to search for the intersection For this technique to be useful in practice, it should be computationally cheap, for each i ∈ {1, . . ., k}, to determine whether any given element of Sym( ) is contained in U i .
Many typical search problems can be formulated in this way.For example, if U 1 is a subgroup of Sym( ) given by generators and U 2 := Transp( , ) for some graphs and with vertex set , then searching for an element of U 1 ∩ U 2 solves the graph isomorphism problem for and in U 1 .
Let O be a set on which Sym( ) acts (such as itself, or the set of all ordered partitions of ).In this paper we will present all search techniques in a common framework.The fundamental idea of this framework is to organise a backtrack search for U 1 ∩ • • • ∩ U k around a pair of stacks of objects in O.At any point in the algorithm, when the pair of stacks is (S, T ) for some S, T ∈ Stacks(O), the set of permutations being searched is Transp(S, T ).The stacks are initially empty, which means that the search begins with the whole symmetric group.In each step down into the recursion, new stacks are appended to the existing ones.This may be done by a refiner, in an attempt to remove redundant parts of the search space (Section 3), or by a splitter, in order to divide the search space into smaller parts that can be searched recursively (see Jefferson et al., 2021, Section 6).
For such a backtrack search to be practical, the set O should be easy to compute with, and in particular, it should be relatively cheap to compute stabilisers and transporter sets in Sym( ) of elements in O, or at least to obtain close overapproximations of them (see Jefferson et al., 2021, Section 5).On the other hand, the set O should be sufficiently rich and varied that refiners can construct stacks in O that encode useful information about the problem at hand.So far, backtrack search in finite symmetric groups has been formulated and implemented in several settings.We use the term classical backtracking for the case that O = ; this is essentially the original backtrack search in Sym( ) introduced in Sims (1971), although presented differently.Partition backtracking is backtrack search where the objects are ordered partitions of ; this is essentially the technique introduced in Leon (1991).We use the term graph backtracking when the objects are labelled digraphs on (Jefferson et al., 2021).In Section 6, we introduce an advancement of this latter technique, which we call extended graph backtracking.

Refiners for backtrack search
Throughout this section and Sections 4 and 5, we let O be a set on which Sym( ) acts, so that the setting is backtrack search organised around stacks in O.In particular, all definitions and results are relative to the set O, even if we do not explicitly repeat that every single time.
In practice, we focus on refiners for subsets of Sym( ) that are subgroups, cosets of subgroups, or empty.
We remark that any pair of functions in Stacks(O) Stacks(O) is a refiner for the empty set and that it is necessary to include the empty set as a possibility because, for example, it is common to search for transporter sets, which may be empty.
Let ( f L , f R ) be a refiner for a set U ⊆ Sym( ), let S, T ∈ Stacks(O) with |S| = |T |, and suppose that we are part way through a search for an intersection of subsets of Sym( ) that includes U , with Transp(S, T ) as the current search space.In this situation, the aim of applying this refiner to the stacks S and T is to prune elements of Sym( ) \ U from the current search space, by moving to the transporter set corresponding to the lengthened stacks S f L (S) and T f R (T ).By ( * ), Transp(S f L (S), T f R (T )) retains the elements of Transp(S, T ) that are in U , but on the other hand, Transp(S f L (S), T f R (T )) is contained in Transp(S, T ), perhaps properly, and may therefore lack some elements of Transp(S, T ) that are not in U .In particular, if Transp(S f L (S), T f R (T )) is empty, then the search can backtrack.
Leon used the term P-refinement in his work on partition backtracking (Leon, 1991(Leon, , 1997) ) for a similar concept that is essentially compatible with our notion of a refiner, although he presents it in a significantly different fashion.Definition 3.1 matches the notion of a refiner used in Jefferson et al. (2021, Section 5).
We remark that the definition of a refiner guarantees no particular success at pruning.For example, if ι is the identity map on Stacks(O), and if ε is the constant map on Stacks(O) whose image is the empty stack in Stacks(O), then (ι, ι) and (ε, ε) are refiners for every subset of Sym( ), even though neither performs any pruning.Thus it is desirable to have a measure of the quality of a refiner.In the following section we introduce perfect refiners, which are those that have maximal pruning power.
To simplify some forthcoming exposition, we introduce a way of applying permutations to functions in Stacks(O) Stacks(O) .It is straightforward to verify that this defines an action of Sym( ).Stacks(O) .
The following results show the close relationships between the two functions that comprise a refiner for a subgroup (Lemma 3.4) or more generally for a coset of a subgroup (Lemma 3.5).We note that Lemma 3.5 is a reformulation of Jefferson et al. (2021, Lemma 4.6) that uses Notation 3.2.Lemma 3.4 (Lemma 4.4 in Jefferson et al., 2021;cf. Leon, 1991, Lemma 6 andLeon, 1997, Prop 2) By Lemmas 3.4 and 3.5, a refiner for a group or coset is built from a single function from Stacks(O) to itself.The following lemma gives equivalent conditions for such a function to yield a refiner (always with respect to the set O, as mentioned earlier): Lemma 3.6.Let G ≤ Sym( ) and f ∈ Stacks(O) Stacks(O) .The following are equivalent: Proof.Suppose that (i) holds and let S ∈ Stacks(O) and x ∈ G.By Definition 3.1, G ∩ Transp(S, S x ) ⊆ Transp( f (S), f (S x )).Then (ii) holds, since x ∈ G ∩ Transp(S, S x ).Conversely, suppose that (ii) holds and let S, T ∈ Stacks(O).If x ∈ G ∩ Transp(S, T ), then T = S x , and since f (S) x = f (S x ) by assumption, it follows that x ∈ Transp( f (S), f (T )).Therefore (i) holds by Definition 3.1.
The equivalence of (ii) and (iii) is clear from Notation 3.2 and the definition of Stab( f ).
Next, we show a way for refiners to be combined to give a refiner for an intersection of sets.
Proof.We show that the set U ∩ V and the pair of functions We remark that the operation is associative, and that we may repeatedly apply Lemma 3.8 to obtain a refiner for any finite intersection of sets, given a refiner for each set.Stacks(O) , and suppose that

Perfect refiners
Definition 4.2.Refiners with the property ( ) from Lemma 4.1 are called perfect refiners (with respect to O, which we will usually omit).
We give several examples of perfect refiners in Section 8.Note that a refiner for a set U ⊆ Sym( ) is also a refiner for any proper subset of U , but never a perfect refiner.The equation '|S| = |T |' in ( ) is included for convenience: in principle, two stacks of different lengths (whose transporter set is empty) could be extended to stacks with nonempty transporter set.However, a refiner is only ever applied to pairs of stacks of equal lengths, so we remove the need to deal with this complication.
During a search, a perfect refiner for U can be used to extend the stacks S and T (representing the current search space Transp(S, T )) to obtain the potentially-smaller search space Transp(S, T ) ∩ U .
Thus a perfect refiner for U allows U to be represented with full fidelity, and no effort must be wasted considering elements of Sym( ) that are not in U .In other words: Perfect refiners are the refiners with maximal pruning power.
A perfect refiner therefore needs to be applied at most once in any branch of search, and should therefore be applied at the root node to avoid unnecessary repetition.It is for this reason that perfect refiners often comprise constant functions in practice; see Lemma 4.3.
given with a perfect refiner, then the search can terminate at the root node without splitting or backtracking.This is because the search begins with S and T being empty stacks, and so their transporter set is initially Sym( ).Applying the perfect refiners in turn then gives stacks with transporter set In the following lemmas, we see that constructing a perfect refiner for a set U is equivalent to finding a pair of stacks in O with transporter set U .It follows that the existence of a perfect refiner for any given subset of Sym( ), in backtrack search organised around stacks in O, depends on the choice of O.But as before, we will not always add "with respect to O".

B). Let f A and f B be constant functions on Stacks(O) with images A and B, respectively. Then
Proof.The pair of functions satisfy the condition in Definition 3.1, since for all S, T ∈ Stacks(O):

, and suppose there exists A ∈ Stacks(O) such that G ≤ Stab( A). Define f A to be the constant function on Stacks(O) with image A. Then
then this refiner is perfect.Lemma 4.5.Let U ⊆ Sym( ).There exists a perfect refiner for U if and only if U = Transp(S, T ) for some S, T ∈ Stacks(O).In particular, there exists a perfect refiner for a group G ≤ Sym( ) if and only if G = Stab(S) for some S ∈ Stacks(O).
Proof.Let ( f L , f R ) be a perfect refiner for U and let S be the empty stack in Stacks(O).Note that Transp(S, S) = Sym( ).Then U = Transp( f L (S), f R (S)) by Definition 4.2.The converse implication follows from Lemma 4.3.
Corollary 4.6.If there exists a perfect refiner for a subset U ⊆ Sym( ), then either U is empty, or U is a subgroup, or a coset of a subgroup, of Sym( ).
In particular, there exists a perfect refiner for a group G ≤ Sym( ) if and only if there exist perfect refiners for one, and hence all, cosets of G in Sym( ).
Proof.We prove that for all x, y ∈ Sym( ), ( ) is a perfect refiner for G y.The lemma follows from this by choosing y := 1 G and by Lemma 3.5. Let ) is a perfect refiner for G y by ( ).The converse implication follows by symmetry.
The following lemma shows that combining perfect refiners with the operation of Notation 3.7 preserves perfectness.This implies that the collection of groups and cosets which have perfect refiners is closed under intersection.
Proof.We show that condition ( ) from Lemma 4.1 holds, for the set U ∩ V and the pair of functions

Perfect refiners for stabilisers and transporter sets
Many computations that are commonly performed with backtrack search can be formulated as stabiliser or transporter problems.This includes computing normalisers, determining subgroup conjugacy, solving graph isomorphism, and finding sets that are phrased in such terms, like set stabilisers. Therefore Theorem 5.3.Let and be sets on which Sym( ) acts, let π : → be a Sym( )-invariant function, and let x, y ∈ .Then the following statements hold: (i) Transp(x, y) ⊆ Transp(π (x), π(y)).In particular, Stab(x) ≤ Stab(π (x)), and any refiner for Transp(π (x), π(y)) is a refiner for Transp(x, y).
Theorem 5.3 suggests a strategy for systematically constructing refiners for the stabilisers and transporter sets of objects in a set on which Sym( ) acts, which is the foundation of our approach in Section 8.More precisely, given such a set , we identify another set on which Sym( ) acts, and for which we have identified refiners for all stabilisers and transporter sets.We then define an injective Sym( )-invariant function π : → .The desired refiners are then inherited via π as described in Theorem 5.3, with Corollary 5.1 providing the base of this recursive procedure.In Section 8, we also make frequent use of the following lemma, which shows that the operation can be used to construct refiners for the stabilisers and transporter sets of lists.This means that lists do need not to be considered separately from the objects that they contain.Lemma 5.5.Let n ∈ N with n ≥ 2. For each i ∈ {1, . . ., n}, let x i and y i be objects from a set on which Sym( ) acts, and let ( f L,i , f R,i ) be a refiner for Transp(x i , y i ).
i=1 Transp(x i , y i ), the result follows from Lemmas 3.8 and 4.8.
Corollary 5.6.Let be a set on which Sym( ) acts.Then there exist perfect refiners for all stabilisers and for all transporter sets of objects in if and only if there exist perfect refiners for all stabilisers and transporter sets of finite lists in .

Extended graph backtracking, with extra vertices
With graph backtracking, a search in Sym( ) is organised around stacks of labelled digraphs on the vertex set .Although this technique gives significantly smaller search sizes in some cases (Jefferson et al., 2021, Section 9), and enables some important perfect refiners (Section 8.2), the requirement that the digraphs have vertex set limits the possibilities for perfect refiners.This is shown explicitly in Corollary 7.3.
In this section, we introduce an extension to graph backtracking, which accommodates digraphs that are allowed to have additional vertices.The technique requires only a small adjustment to the theory of graph backtracking, and has already been implemented in Vole (Chang et al., 2021).In fact the necessary concepts from Jefferson et al. (2021) extend naturally, and re-stating and re-proving the corresponding definitions and results do not give any new insights, which is why we do not include these technical details in this article.Instead, we discuss the extended graphs themselves, and their stacks, in much detail, because this is necessary for formulating and examining refiners in this setting.
We require some additional definitions and notation for the rest of this article.We fix as an infinite well-ordered set containing , where α < β for all α ∈ and β ∈ \ .
In practice, and in the forthcoming examples, we use := {1, . . ., n} for some n ∈ N, and := N.
For any subset V of that contains , we regard Sym( ) and Sym(V \ ) as subgroups of Sym(V ), by identifying each permutation of V that fixes V \ pointwise with its restriction to , and identifying each permutation of V that fixes pointwise with its restriction to V \ .In this way, Sym( ) and Sym(V \ ) inherit from Sym( ) an action on the set of all labelled digraphs on V .Furthermore, since we regard Sym( ) and Sym(V \ ) as subgroups of Sym(V ), they commute, and this means that Sym( ) permutes the set of orbits of Sym(V \ ) on labelled digraphs on V .For a labelled digraph on V , we use the notation for the orbit of under Sym(V \ ).The action of Sym( ) is then given by ( ) g := g for all labelled digraphs on V and all g ∈ Sym( ).
We define an extended graph on to be an orbit of Sym(V \ ) on the set of labelled digraphs on V , for some finite set V with ⊆ V ⊆ .This will be illustrated in Example 6.1.An extended graph stack on is any list of extended graphs on .We remark that different entries in an extended graph stack are allowed to be defined in relation to different subsets of .Extended graph backtracking in Sym( ) is then backtrack search organised around extended graph stacks on .

Table 1
This table shows the subgroups of Sym( ), and the cosets of subgroups of Sym( ), for which there exists a perfect refiner, in various kinds of backtracking.For a subset ⊆ , we identify Sym( ) with the pointwise stabiliser of \ in Sym( ), and for a partition { 1 , . . ., k } of , we identify Sym( 1 ) × • • • × Sym( k ) with the corresponding internal direct product in Sym( ).

Backtracking
The subgroups of Sym( ), and their cosets, with perfect refiners Reference Classical Sym( ) for any subset ⊆ . -Partition -Graph Any 2-closed subgroup of Sym( ).Proof.Suppose that U = V and let g be the restriction to of some x ∈ T .Then since Transp( , ), then g = h for some h ∈ Sym(V \ ).Thus g is the restriction of gh −1 ∈ T to .Lemma 6.2 implies that we do not need to enumerate whole orbits of labelled digraphs in order to compute stabilisers and transporter sets of extended graphs.In practice, we construct extended graphs that consist of labelled digraphs where the labels used for vertices in are never used for vertices in \ .This guarantees that any permutation that maps one such labelled digraph to another necessarily preserves as a set.Therefore, in the notation of Lemma 6.2, the set T is simply the transporter set in Sym(V ) from to .

The groups and cosets with perfect refiners
By Lemmas 4.5 and 4.7, the task of finding a perfect refiner for a subgroup of Sym( ), or for a coset of a subgroup, is equivalent to finding a stack whose stabiliser in Sym( ) is the corresponding group.In this section, and for each setting of backtracking, we classify the groups (and correspondingly the cosets of subgroups) for which there exists a perfect refiner.This information is summarised in Table 1.
It follows from these classifications that, in a sense, partition backtracking inherits the perfect refiners of classical backtracking, that graph backtracking inherits the perfect refiners of partition backtracking, and that extended graph backtracking inherits the perfect refiners of graph backtracking.This can be shown constructively: it is straightforward to map lists of points to lists of ordered partitions, and lists of ordered partitions to lists of labelled digraphs, in injective Sym( )-invariant ways.As mentioned in Remark 5.4, perfect refiners can then be translated via these maps. 1 for classical backtracking (stabilisers in Sym( ) of lists in ) and partition backtracking (stabilisers in Sym( ) of lists of ordered partitions of ) are trivial to verify.

The classifications in Table
For graph backtracking, we require the notion of the 2-closure of a permutation group.Definition 7. 1 (2-closure, 2-closed;cf. Dixon and Mortimer, 1996, Section 3.2).The 2-closure of a group G ≤ Sym( ) is the largest subgroup of Sym( ) with the same orbits on × as G; it is the pointwise stabiliser in G of the set of all orbital graphs of G.A 2-closed group is one that is equal to its 2-closure.
The 2-closure of any subgroup of Sym( ) that acts at least 2-transitively on is Sym( ).Therefore no proper subgroup of Sym( ) acts at least 2-transitively on and is 2-closed.

Lemma 7.2. Let G be a subgroup of Sym( ). Then G is the stabiliser of a labelled digraph stack on if and
Proof.(⇐) Labelling all vertices and arcs of a digraph with a fixed label preserves its stabiliser.
Thus, if S is a stack of labelled digraphs formed from all the orbital graphs of G in this way, then G = Stab(S).
(⇒) By Jefferson et al. (2021, Lemma 3.6), we may assume that G = Stab( ) for a labelled digraph on .Let A 1 , . . ., A k ⊆ × and B 1 , . . ., B l ⊆ be the orbits of G on the sets of arcs and vertices of , respectively, for some k ∈ N ∪ {0} and l ∈ N.For each i ∈ {1, . . ., k} and j ∈ {1, . . ., l}, we define digraphs i := ( , A i ) and j := ( , {(b, b) : b ∈ B j }).Each such digraph is an orbital graph of G, and so its stabiliser contains G. Furthermore, if a permutation g ∈ Sym( ) stabilises each of these digraphs pointwise, then by construction, g maps each vertex of to a vertex with the same label, and it maps each arc of to an arc with the same label, and so g ∈ Stab( ).Thus we have proved that Since G is the pointwise stabiliser of a subset of its orbital graphs, it is 2-closed.
Corollary 7.3.In graph backtracking, there exists a perfect refiner for a group G ≤ Sym( ) if and only if G is 2-closed.
For extended graph backtracking, we require the following result.
Proposition 7.4 (Bouwer, 1969;Kearnes, 2015).Let G ≤ Sym( ).There exists a finite set V containing and a labelled digraph on V , such that the stabiliser of in Sym(V ) preserves setwise, and the restriction of this stabiliser to is G. Lemma 7.5.Every subgroup of Sym( ) has a perfect refiner in extended graph backtracking.
Proof.Let G ≤ Sym( ), and let be a finite labelled digraph of the kind described in Proposition 7.4 for G.By renaming the vertices that are not in , we may assume that the vertex set of is a subset of the infinite set that we use throughout this article.By Lemma 6.2 and Proposition 7.4, the extended graph stack [ ] has stabiliser G in Sym( ).The result follows by Lemma 4.5.
We primarily include Lemma 7.5 for its theoretical interest.Given a group G, the number of additional vertices required to construct a witness for the result in Proposition 7.4 may be of similar size to |G|, which would normally be impractically large for use in a backtrack search.We are therefore also interested in how many extra vertices are required to represent different groups.

Examples of perfect refiners
In this section, we describe some refiners for the stabilisers and transporter sets of some commonly-occurring objects on which Sym( ) acts.In most cases, we prove that the refiners are perfect, making frequent use of Corollary 5.1, Theorem 5.3, and Lemma 5.5.The results for perfect refiners are summarised in Table 2.As discussed in Section 7, a perfect refiner for a subset of Sym( ) in classical backtracking can be easily converted into a perfect refiner for the same set in partition backtracking, and so on.In this hierarchical sense, each class of objects in Table 2 appears by the 'least' kind of backtracking in which all of their stabilisers and transporter sets have perfect refiners.
A given kind of backtracking may not have perfect refiners for all stabilisers and transporter sets of some class of objects, but it may have perfect refiners for those of an important subclass of the objects.In order to optimise implementations, it is important to understand these special cases well, but a thorough investigation of this topic is beyond the scope of this article.Nevertheless, to demonstrate the principle, we consider sets of subsets of with pairwise distinct sizes in partition backtracking (Section 8.1.2),and sets of nonempty pairwise disjoint subsets of in graph backtracking (Section 8.2.2), even though only extended graph backtracking has perfect refiners for all stabilisers and transporter sets of sets of subsets of (Section 8.3.1).

Examples of perfect refiners in partition backtracking
To justify the part of

Stabilisers and transporters of sets of points
We define a function π from the set of all subsets of to the set of all stacks of ordered partitions of .We define π(∅) to be the empty stack on , and π( ) to be the stack consisting of the ordered partition [ ], and for any nonempty proper subset A of , we define π(A) to be the stack consisting of the ordered partition [A, \ A].Since π is an injective Sym( )-invariant function, Theorem 5.3 and Corollary 5.1 give the desired perfect refiners.

Stabilisers and transporters of sets of subsets with pairwise distinct sizes
We define an injective Sym( )-invariant function σ that maps each set of subsets of with pairwise distinct sizes to a list of subsets of as follows.Let A be any such set.There exists m ∈ N ∪ {0} and subsets A 1 , . . ., A m of , uniquely indexed by increasing size, such that A = {A 1 , . . ., A m }. if and only if it stabilises each of the subsets that it contains.Perfect refiners for the stabilisers and transporters can thus be obtained from σ via Section 8.1.1,Lemma 5.5, and Theorem 5.3.

Examples of perfect refiners in graph backtracking
For the kinds of objects listed by graph backtracking in Table 2, it is easy to find examples for all | | ≥ 4 where the stabiliser in Sym( ) is not a direct product of symmetric groups, which means that the stabiliser has no perfect refiner in partition backtracking (see Table 1).It remains to show that there are perfect refiners in graph backtracking for the stabilisers and transporter sets of these objects.

Graph and digraph automorphisms and isomorphisms
We recall our standard notation for graphs from Section 2. Let π be the function that maps each graph ( , E) to the digraph ( , {(α, β), (β, α) : {α, β} ∈ E}).This means that each edge {α, β} is replaced by the arcs (α, β) and (β, α).In addition, we define x to be some fixed label, and we let σ be the function that maps each digraph on to the labelled digraph on formed by assigning the label x to all of its vertices and arcs.Then π and σ are injective Sym( )-invariant functions, and so Theorem 5.3 and Corollary 5.1 give perfect refiners for all stabilisers and transporter sets in Sym( ) of graphs and digraphs on in graph backtracking.

Stabilisers and transporters of sets of nonempty pairwise disjoint sets
We define a function φ from the set of all subsets of to the set of all digraphs on as follows.Let A := {A 1 , . . ., A k }, for some k ∈ N ∪ {0}, be a set of subsets of , and define φ(A) to be the digraph on that consists of a clique (plus loops) on the vertices of each member of A, i.e.
See Fig. 2 for an example.Then φ is Sym( )-invariant, and so by Theorem 5.3 and Section 8.2.1, we obtain refiners in graph backtracking for the stabilisers and transporter sets of all sets of subsets of .Furthermore, when restricted to sets of nonempty pairwise disjoint subsets of , the function φ is injective and Sym( )-invariant, and so the corresponding refiners are perfect.
Then ψ is injective and Sym( )-invariant, giving perfect refiners in graph backtracking for all centralisers in Sym( ) of elements of Sym( ), and for the transporter sets for permutation conjugacy (see Theorem 5.3 and Section 8.2.1).By Lemma 5.5, this gives perfect refiners for all stabilisers of lists of permutations in Sym( ) under conjugation.The centraliser in Sym( ) of a subgroup of Sym( ) is the pointwise stabiliser of any of its generating sets, and thus we can obtain a perfect refiner in graph backtracking for the centraliser in Sym( ) of any subgroup of Sym( ) given by a generating set.

Examples of perfect refiners in extended graph backtracking
By Lemma 7.5, all stabilisers and transporter sets have perfect refiners in extended graph backtracking, but this knowledge is not necessarily immediately useful: the extended graphs underpinning this lemma may require impractically many additional vertices, and anyway, the construction requires knowing the stabiliser or transporter set in advance.In order to avoid too many additional vertices or circular arguments, we wish to construct refiners in extended graph backtracking using only facts about the relevant objects that can be computed cheaply.
In the forthcoming examples, we specify an extended graph by giving one of the labelled digraphs that it contains.Therefore, in each case, we must prove that this is well-defined.The fixed set of vertices is totally ordered, and we always choose vertices from this set in ascending order.Thus it suffices to show, in each case, that our choices lead to labelled digraphs that differ only by a permutation of their vertices in \ .

Stabilisers and transporters of sets of sets
We define a function φ from the set of all sets of subsets of to the set of all extended graphs on .Let A := {A 1 , . . ., A k } be a set of subsets of , where k ∈ N ∪ {0}, indexed arbitrarily, and let V k := {β 1 , . . ., β k } ⊆ \ comprise the k least elements of \ .We define A to be the labelled digraph on where vertices in are labelled white, and all other vertices and arcs are labelled black.Thus there is a white vertex in A for each member of , and a black vertex for each member of A; each vertex in has arcs to the black vertices corresponding to the members of A that contain it.We define φ(A) := A to be the extended graph containing A (Fig. 4).
The only choice involved in constructing a labelled digraph using the method described above is the indexing of the members of A. Therefore the labelled digraphs produced can differ only by a permutation of the names of the vertices outside of , and φ is well-defined.It is clear that φ is injective and Sym( )-invariant, and so perfect refiners are given by Theorem 5.3 and Corollary 5.1.

Stabilisers and transporters of sets of lists
We define a function π that maps each set of lists in to an extended graph on .Let A := {A 1 , . . ., A k } be a set of nonempty lists in , for some k ∈ N ∪ {0}, indexed arbitrarily.Moreover, let r := k i=1 |A i | be the product of the lengths of these lists, let V r be a set of the least r elements of \ , and let ρ be an arbitrary bijection from {(i, j) : i ∈ {1, . . ., k} and j ∈ {1, . . ., |A i |}} to V r .We define π(A) to be the extended graph that contains the labelled digraph on ∪ V r with arcs where the vertices in are labelled white, and the vertices in V r and all arcs are labelled black.
Each vertex in V r corresponds via ρ to a position in a list in A; the arcs between vertices in V r encode the ordering of each list, and the arcs towards vertices in encode the entry at each position.For a set of lists in that includes the empty list, [ ], we proceed as above, except that the labelled digraph has an additional isolated vertex (the next least element of \ ) with label black.
It is straightforward to see that π is well-defined (once a bijection ρ is fixed), injective, and Sym( )-invariant, and so with this method, it is possible to use Theorem 5.3 and Corollary 5.1 to produce perfect refiners in extended graph backtracking for the stabilisers and transporter sets of any sets of lists in (Fig. 5).In combination with Lemma 7.2, the following lemma implies that for all sets with | | > 3, there exist sets of lists in whose stabilisers and transporter sets do not have perfect refiners in graph backtracking.This result also gives a different constructive proof of Lemma 7.5.However, the method described in this section is impractical for constructing a perfect refiner for an arbitrary subgroup G ≤ Sym( ), since it would produce a labelled digraph with (|G| + 1)| | vertices.
Lemma 8.1.Every subgroup of Sym( ) is the stabiliser in Sym( ) of a set of lists in .
Proof.Let G ≤ Sym( ) and A be an enumeration of .Then G is the stabiliser in Sym( ) of A G .

Stabilisers and transporters of sets of graphs, digraphs, or labelled digraphs
We define a function ψ from the set of all sets of labelled digraphs on to the set of all extended graphs on that is injective and Sym( )-invariant.Therefore ψ can be combined with the functions of Section 8.2.1, via Theorem 5.3, to give perfect refiners in extended graph backtracking for the stabilisers and transporter sets of sets of graphs or digraphs on that are not necessarily labelled.First, we fix labels # and that are not allowed to be used as labels in any labelled digraph on .
Roughly speaking, we build a new labelled digraph from a disjoint union of copies of the k members of A, retaining labels, and adding arcs that anchor each copy, and arcs that maintain the Labelled digraphs 1 and 2 on := {1, 2, 3} with all labels black, and a representative labelled digraph of the extended graph ψ({ 1 , 2 }), with := N and ψ from Section 8.3.3.Vertices and arcs are differently patterned, according to label.The stabiliser in Sym({1, . . ., 11}) of this labelled digraph preserves setwise, and its restriction to is the setwise stabiliser of correspondences between and the vertices of the copies.We give an example in Fig. 6 and discuss the precise construction in the following paragraph.
Let {V 1 , . . ., V k } be an arbitrary partition of the least k| | elements of \ into k parts of size | |, and for each i ∈ {1, . . ., k}, let τ i be an arbitrary bijection from to V i .In addition, let Then we define ψ(A) to be the extended graph that contains the labelled digraph on ∪ where vertices in and arcs ending in are labelled #, vertices in X and arcs ending in X are labelled , and for all α, β ∈ and i ∈ {1, . . ., k}, the vertex τ i (α) has the label of α in i , and the arc (τ i (α), τ i (β)) (if present) has the label of (α, β) in i .
Different choices in the construction lead to labelled digraphs that differ only by a permutation of the vertices in \ , so ψ is well-defined.The injectivity of ψ is guaranteed by the vertices in X and their arcs; these could be omitted for sets of connected labelled digraphs.It is clear that ψ is Sym( )-invariant.(b) The fundamental idea behind this technique can be adapted to build perfect refiners for the stabilisers and transporter sets of extended graphs in extended graph backtracking.

Stabilisers and transporters of sets of labelled digraph stacks
Let ζ be the injective Sym( )-invariant function from the set of all labelled digraphs stacks on to the set of all labelled digraphs on that is given in Computing normalisers and deciding subgroup conjugacy are typical use cases for backtrack search, but existing techniques seem to find these problems particularly difficult.Describing refiners for normalisers has been and continues to be an important area of research, see for example Theißen (1997), Chang (2021).One intuitive explanation for the difficulty is that a normaliser may permute structures of a group (such as orbits) that would be fixed in the context of other search problems, which may reduce the potential for pruning.In the earlier parts of Section 8.3 and in Table 2, we have seen constructions of perfect refiners in extended graph backtracking for the stabilisers and transporter sets in Sym( ) of many kinds of sets of objects that do not have perfect refiners in existing backtracking settings.
This suggests that the extended graph backtracking technique may lend itself well to the development of better refiners for normalisers and for sets of conjugating elements of subgroups.The strategy would be to identify structures that are permuted by the normaliser, and to then develop refiners for the stabilisers and transporter sets of sets of such structures.As a first step, we examine orbital graphs.
Proposition 8.3.Let G, H ≤ Sym( ) and x ∈ Sym( ).If G x = H, then x transports the set of orbital graphs of G to the set of orbital graphs of H.In particular, the normaliser of G in Sym( ) stabilises the set of orbital graphs of G.
Proof.It is routine to verify that if G x = H , then for all α, β ∈ , x transports the orbital graph of G with base-pair (α, β) to the orbital graph of H with base-pair (α x , β x ).
Proposition 8.3 implies that the function μ that maps a subgroup of Sym( ) to its set of orbital graphs is Sym( )-invariant.In Section 8.3.3,we described perfect refiners in extended graph backtracking for the stabilisers and transporter sets of arbitrary sets of digraphs, and so by Theorem 5.3, we can use μ to obtain refiners for the normalisers and sets of conjugating elements of subgroups.However, if | | ≥ 4, then μ is not injective (consider different 2-transitive subgroups of Sym( )), so these refiners are not necessarily perfect.Nevertheless, μ gives many instances of perfect refiners.
For example, it is clear that the set of 2-closed subgroups of Sym( ) is closed under conjugation by Sym( ), and that the restriction of μ to this set is injective.Therefore those refiners are perfect.Furthermore, by Proposition 8.3, the refiner described above for the normaliser of a subgroup G ≤ Sym( ) is perfect if and only if N Sym( ) (G) is equal to the stabiliser in Sym( ) of the set of orbital graphs of G.By Lemma 8.4, these are the subgroups whose normaliser in Sym( ) coincides with the normaliser of its 2-closure.Example 8.5 shows that this includes more than just the 2-closed subgroups of Sym( ).
Lemma 8.4.Let G ≤ Sym( ).The stabiliser in Sym( ) of the set of orbital graphs of G is the normaliser in Sym( ) of the 2-closure of G.
Proof.Let K denote the 2-closure of G.The orbital graphs of G and K coincide by definition, and so N Sym( ) (G) is contained in the stabiliser by Proposition 8.3.Conversely, let x ∈ Sym( ) stabilise the set of orbital graphs of G (and K ) and let g ∈ K .For all orbital graphs of K , x −1 is an orbital graph of K by assumption, and x −1 g = x −1 since g ∈ K .Hence x −1 gx = , and x −1 gx ∈ K .

Closing remarks
We have introduced the concept of perfect refiners, which gives a way of comparing the available pruning power in the various backtracking frameworks and which, within a framework, gives a way of comparing refiners for a given set.This is naturally complemented by the introduction of extended graph backtracking.We have also discussed the existence of perfect refiners in the different frameworks, and given concrete examples of perfect refiners that are implemented in Vole.
This work suggests several obvious questions and directions for further investigation.For any given search problem, which backtracking framework is the most appropriate for solving it, and how should this decision be made?Having decided upon a framework, which refiners should be used?In which other ways can we compare and understand refiners?
One obvious line of inquiry is the development of further methods for comparing different refiners for the same set, and of measuring the 'quality' of a given refiner.The notion of perfectness is binary, and it fails to capture any nuance in the way that a refiner may fail to be perfect.
It would also be useful to better understand the performance implications of using a given refiner in a backtrack search algorithm.Roughly speaking, a perfect refiner for a given set is best possible in terms of search size.On the other hand, like any refiner, a perfect refiner may be impractically expensive to compute with, and this might partially or fully override the search-size advantage.For refiners in extended graph backtracking, we could begin to understand the interplay between these effects by distinguishing refiners according to how many vertices and arcs their extended graphs require.
We have seen in Proposition 7.4 and Lemma 7.5 that every group and coset has a perfect refiner in extended graph backtracking, but that the digraphs in Bouwer (1969), Kearnes (2015) that underpin these results may be impractical for computation.Extended graph backtracking would therefore benefit from a better understanding of the theoretical and practical possibilities for representing groups by digraphs of the kind in Proposition 7.4, because then we could work on finding perfect refiners, or decide that that is infeasible.
As mentioned in Section 8.3.5, extended graph backtracking appears to be well suited to the development of better refiners for use in normaliser and subgroup conjugacy computations.This is already an active area of research, motivated partly by the fact that good algorithms for normaliser search exist (e.g. in MAGMA, see Bosma et al., 1997).Our work in this direction will be continued in the future.
Finally, we note that there is ongoing work to apply the ideas of the graph backtracking and extended graph backtracking frameworks to canonisation algorithms in finite symmetric groups.

Declaration of competing interest
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.

Lemma 4. 3 .
Let U ⊆ Sym( ), and suppose there exist A, B ∈ Stacks(O) such that U ⊆ Transp( A, By an argument similar to that used in the proof of Lemma 3.8, if | f (S)| = |σ (T )|, then the condition holds, so suppose otherwise.Then

Remark 5. 4 .
Let O and O be sets on which Sym( ) acts, let π : Stacks(O) → Stacks(O ) be an injective Sym( )-invariant function, and let U ⊆ Sym( ).Then Lemmas 4.3 and 4.5 and Theorem 5.3(ii) together constructively show that if U has a perfect refiner in backtrack search organised around Stacks(O), then U also has a perfect refiner in backtrack search organised around Stacks(O ).

Fig. 2 .
Fig. 2.An example of the function φ from Section 8.2.2 for the given set of disjoint subsets of := {1, . . ., 10}.To reduce visual clutter, loops are omitted at vertices of non-singleton subsets.

Notation 3.2. For
any f ∈ Stacks(O)Stacks(O)and x ∈ Sym( ), we define f x as follows: f x (S) := f (S x −1 ) x for all S ∈ Stacks(O).
, in order to most successfully solve such problems with backtrack search organised around stacks in O, we require a way of constructing refiners for the appropriate stabilisers and transporter sets.These refiners should be cheap to compute, and ideally, they should be perfect if possible.Lemma 4.3 constructively shows that this task can be reduced to translating the given stabiliser or transporter problem into one concerning stacks in O.For a problem that is already given in terms of Stacks(O), or at least in terms of O, it follows that little to no translation is needed; this is stated explicitly in the following immediate corollary to Lemma 4.3.For each x ∈ O and S ∈ Stacks(O), let [x] be the stack with unique entry x, and let f S be the constant function in Stacks(O) Stacks(O) with image S. Let x, y ∈ O and S, T ∈ Stacks(O).Then ( f [x], f [y]) is a perfect refiner for Transp(x, y), and ( f S , f T ) is a perfect refiner for Transp(S, T ).For other transporter problems, more work is required in order to apply Lemma 4.3, i.e. to construct stacks in O whose own transporter set closely contains (and ideally equals) the given one.The analogous statement holds for stabiliser problems.While this translation can be done on an ad-hoc basis, it is desirable to instead have a systematic method that works for a whole class of objects that we wish to stabilise and to compute transporter sets of.To that end, we present Theorem 5.3.Definition 5.2.Let X and Y be sets on which Sym( ) acts, and let f

Table 2
For the various kinds of backtracking in Sym( ), this table gives some objects on which Sym( ) acts, such that all stabilisers and transporter sets in Sym( ) of these objects have perfect refiners.A constructive argument is given in the reference.This table is not meant to be exhaustive.
Table 2 that relates to partition backtracking, we first show, for each kind of object, and with | | ≥ 5, that not all stabilisers and transporter sets have perfect refiners in classical backtracking.By Corollary 5.6 and Table 1, the following examples suffice: If n ∈ N with n ≥ 5 and := {1, . . ., n}, then the ordered partition [{1, 2}, {3, . . ., n}] of , the subset {1, 2} of , and the set of subsets {{1, 2}, {3, . . .,n}} of have stabiliser Jefferson et al. (2021, Section 3.1).Moreover, let k ∈ N 0 .Then the function that maps any set {S 1 , . . ., S k } of labelled digraph stacks on to the set of labelled digraphs {ζ(S 1 ), . . ., ζ(S k )} is injective and Sym( )-invariant.Thus we can use Theorem 5.3 in combination with Section 8.3.3 to construct perfect refiners in extended graph backtracking for the stabilisers and transporter sets of arbitrary sets of labelled digraphs stacks on .This allows perfect refiners in graph backtracking for the stabilisers and transporter sets of one kind of object to be converted into perfect refiners in extended graph backtracking for the stabilisers and transporter sets of sets of those objects.
Any subgroup of a group K acts on the set of subgroups of K by conjugation and the stabiliser of a subgroup G under conjugation by a subgroup H is the normaliser of G in H , denoted N H (G).