centertableaux
Deterministic stack-sorting for set partitions
Abstract.
A sock sequence is a sequence of elements, which we will refer to as socks, from a finite alphabet. A sock sequence is sorted if all occurrences of a sock appear consecutively. We define equivalence classes of sock sequences called sock patterns, which are in bijection with set partitions. The notion of stack-sorting for set partitions was originally introduced by Defant and Kravitz. In this paper, we define a new deterministic stack-sorting map for sock sequences that uses a -avoiding stack, where pattern containment need not be consecutive. When , we show that our stack-sorting map sorts any sock sequence with distinct socks in at most iterations, and that this bound is tight for . We obtain a fine-grained enumeration of the number of sock patterns of length on distinct socks that are -stack-sortable under , and we also obtain asymptotics for the number of sock patterns of length that are -stack-sortable under . Finally, we show that for all unsorted sock patterns , the map cannot eventually sort all sock sequences on any multiset unless every sock sequence on is already sorted.
1. Introduction
1.1. Stack-sorting algorithms
There is a long history of research on sorting with restricted data structures. In particular, Knuth first introduced the concept of a stack-sorting machine in The Art of Computer Programming [19], which uses a stack data structure to sort sequences. Given an input sequence, one can push elements from the input onto the stack and pop elements off the stack to the output subject to the constraint that the element being popped out of the stack must be the element that was most recently pushed onto the stack. Thus, the stack grants sorting power through choices between pushes and pops. A stack-sorting algorithm is a rule for deciding whether to push or pop at each step in the sorting process. There has since been much work on various stack-sorting algorithms inspired by Knuth’s stack-sorting machine, including West’s deterministic stack-sorting algorithm [4, 11, 13, 22], pop-stack-sorting [1, 2, 21], deterministic stack-sorting for words [14], sorting with pattern-avoiding stacks [3, 5, 6, 16], stack-sorting Coxeter groups [10, 12], and more.
In the setting where our sequences are permutations, we say that a sequence is sorted when it is the identity permutation. Given a stack-sorting algorithm, it is natural to ask how many passes through the stack are needed to sort the input object. We say that our input object is -stack-sortable if there is some stack-sorting algorithm that sorts the input in at most iterations. We say that our input object is -stack-sortable under if it can be sorted by at most iterations of a given stack-sorting algorithm . Knuth [19] characterized the permutations that are -stack-sortable as exactly the permutations that avoid the pattern . This characterization launched the growing field of permutation patterns research that exists today. In general, the set of permutations that are -stack-sortable is closed under pattern containment. However, given the nondeterminism of Knuth’s stack-sorting machine, it is very difficult to characterize or enumerate such permutations when . For example, Pierrot and Rossin only recently proved that there is a polynomial time algorithm for deciding whether or not a given permutation is -stack-sortable [20]. This motivated West to define a deterministic stack-sorting algorithm [22], which uses -avoiding stacks. West’s stack-sorting map is easier to analyze. For example, all permutations of length are -stack-sortable under West’s stack-sorting map. Furthermore, we can explicitly characterize all permutations that require all iterations of West’s stack-sorting map to become sorted.
Beyond the permutation setting, Defant and Kravitz recently generalized the notion of stack-sorting to set partitions [15]. In this paper, we continue the investigation of stack-sorting of set partitions. More generally, we define sock sequence to be a sequence of elements, which we refer to as socks, from a finite alphabet. We say a sock sequence is sorted if all occurrences of a sock appear consecutively in the sequence. We also define equivalence classes on sock sequences called sock patterns, which are in bijection with set partitions. We will study stack-sorting on sock sequences and sock patterns.
As in the permutation setting, one can characterize which sock patterns are -stack-sortable. Defant and Kravitz showed that a sock pattern is -stack-sortable if and only if there is a -avoiding word representation of [15]. However, the nondeterminism of stack-sorting sock patterns makes analyzing the number of stacks needed to sort them difficult. This motivates us to look at deterministic stack-sorting algorithms, which we believe may shed light on the nondeterministic setting. Inspired by both West’s -avoiding stack-sorting map and Defant and Zheng’s work on consecutive pattern-avoiding stacks [16], we define and study novel pattern-avoiding stack-sorting maps on sock sequences. Our notion of pattern avoidance is identical to Klazar’s notion of pattern avoidance for set partitions [17, 18]. However, our notion of pattern avoidance within the stack differs in that we do not only consider consecutive pattern avoidance. We formally define these pattern-avoiding stack-sorting algorithms in Section 2.
1.2. Main results
We give special attention to one such pattern-avoiding stack-sorting map for sock sequences. We define a foot-sorting map, denoted , based on pattern avoidance in the stack. The name foot-sorting comes from Defant and Kravitz’s original paper on the topic [15], in which feet are used in place of stacks. We show that every sock sequence eventually becomes sorted under a finite number of iterations of . Moreover, any sorted sock sequence stays sorted after applying . Thus our map is a noninvertible sorting operator.
When looking at any noninvertible combinatorial dynamical system, it is natural to ask how many objects require a given number of iterations to reach a periodic point. For sorting operators in particular, it is natural to ask how many objects become sorted after applying a fixed number of sorting operations. For example, Defant enumerated the -stack-sortable permutations [12, 9, 11], West enumerated the - and -stack-sortable permutations [22], and Claesson, Dukes, and Steingrimsson enumerated the -stack-sortable permutations [7].
Thus, we begin by taking an enumerative approach to studying . We state and prove an enumeration of sock patterns of length that are -stack-sortable under , and we further extend this result to a refined enumeration that is parameterized by the number of distinct socks in the sock pattern. In particular, we have the following closed forms.
Theorem 1.1.
Let denote the number of sock patterns of length that are -stack-sortable under . Let be the corresponding generating function. Then we have
Theorem 1.2.
Let denote the number of sock patterns of length and containing distinct socks that are -stack-sortable under . Let be the corresponding multivariate generating function. Then we have
We then take a separate approach to studying these pattern-avoiding stack-sorting operators, namely through investigating periodic points for general patterns . In particular, we show in Proposition 5.2 that for any unsorted sock pattern and for any multiset of socks such that not all sock sequences on are already sorted, there always exists a sock sequence on that never gets sorted by .
1.3. Outline of the paper
In Section 2, we provide background discussion on sock sequences and stack-sorting algorithms that we use throughout the paper. In Section 3, we describe the action of our foot-sorting map and prove a tight upper bound on the number of iterations of required to sort an arbitrary sock sequence. In Section 4, we prove the explicit enumerations of sock patterns that are -stack-sortable under stated in Theorem 1.1 and Theorem 1.2. In Section 5, we study the behavior of general -avoiding stack-sorting maps through periodic points. In Section 6, we raise some natural future directions for the investigation of deterministic stack-sorting for set partitions.
2. Preliminaries
In this section, we provide definitions and notation for the discussion of stack-sorting sock sequences.
2.1. General notation for sock sequences
Fix an arbitrary infinite alphabet . Throughout, we will use the standard Latin alphabet to refer to distinct elements of . We call these elements of socks. A sock sequence is a sequence of socks in . Let denote the (infinite) set of sock sequences on .
Let be a sock sequence. Let denote the length of the sock sequence. We say that a sock sequence is empty if , and nonempty otherwise. Let denote the concatenation of sock sequences (where is potentially empty). Let denote the sock sequence consisting of occurrences of sock . Let denote the number of distinct socks appearing in sock sequence .
2.2. Sock patterns as sequences
We first introduce the following definition, which will help us develop the notion of sock patterns.
Definition 2.1.
Let be a sock sequence on the alphabet . Then define as the set of distinct socks in .
We can now define an equivalence relation on sock sequences, where two sock sequences and are equivalent if and only if there exists a bijection such that . Thus, two sock sequences are equivalent if one can be obtained from the other by renaming the socks. For example, the sock sequences and are equivalent. A sock pattern is an equivalence class on sock sequences under our equivalence relation. This also gives us a notion of pattern avoidance. We say that a sock sequence avoids a sock pattern if no subsequence of socks forms a sock sequence in the class .
We can also introduce the following notion of standardization to obtain a natural representative of each equivalence class.
Definition 2.2.
The standardization of a sock sequence is an injective renaming of the socks in such that the socks appearing for the first time from left to right form the alphabetical sequence .
Example 2.1.
Let . Then the standardization of is .
We say that a sock sequence is standardized if it is equal to its own standardization. We see then that two sock sequences are equivalent exactly when they have the same standardization. When referring to a sock pattern, we will use the unique standardized sock sequence in the equivalence class as our representative.
In the traditional setting of stack-sorting permutations, one can think of permutations as sequences on the base set for some . In the setting of sock sequences, we instead define our base set to be a multiset of socks. We can then think of sock sequences as sequences on the multiset .
Definition 2.3.
Let be a multiset of socks. Let be the set of sock sequences consisting of all socks in (equivalently, the set of sock sequences on ).
Example 2.2.
Let . Then .
Note that it will often be natural to consider the entire set at once, as is closed under any stack-sorting map. For example, to study a stack-sorting map , we can ask which sock sequences within get sent to each other, which sock sequences within eventually become sorted under repeated iterations of , which sock sequences within are periodic points, etc.
Finally, the following notation will help us connect sock sequences to set partitions.
Definition 2.4.
Let be any sock sequence on . For any sock , define , i.e. the set of indices at which sock occurs in .
2.3. Sock patterns as set partitions
Sock patterns of length are in bijection with set partitions on . For example, the sock pattern represented by the standardized sock sequence corresponds to the set partition . Let denote the set of all set partitions on . Then the bijection is
where the subsets in the set partition correspond to the indices at which a fixed sock occurs in . Note that Klazar’s notion of pattern avoidance for set partitions [17, 18] corresponds to our notion of pattern avoidance for sock patterns.
2.4. A novel stack-sorting map
We define a deterministic stack-sorting algorithm for sock sequences based on pattern avoidance of sock patterns. This sorting algorithm is inspired by the consecutive pattern-avoiding stacks defined by Defant and Zheng [16]. Here, we consider pattern containment in a more general sense, where a pattern need not occur consecutively within the stack.
Definition 2.5.
Let denote the stack-sorting map given by the following procedure. Suppose we are given an input sequence read from left to right. Throughout the procedure, we consider the sequence of socks obtained from reading the stack from top to bottom. At each point in time, we do one of the following operations:
-
(1)
If there are remaining socks to push and pushing the leftmost sock from our input sock sequence onto the top of the stack does not create an pattern in , then we do so.
-
(2)
Otherwise, we pop the topmost sock off of our stack.
The procedure continues until the output contains all socks in the original input. Let denote the output sock sequence.
Example 2.3.
Let . Then the following diagram illustrates the state of the stack at each step in the algorithm. Our output sock sequence is , which we note is sorted.

We can think about output sock sequences as belonging to the image of map . Note that this sorting procedure preserves the multiset of socks, and therefore also induces a map for any multiset of socks . Furthermore, sorting with and then renaming socks with a bijection yields the same sock sequence as renaming socks with a bijection and then sorting with , so this sorting procedure also induces a map from sock patterns to sock patterns. We call this particular stack-sorting map a foot-sorting map, which we investigate in more detail in Section 3.
More generally, we can define analogous stack-sorting maps for any pattern .
Definition 2.6.
Let denote the stack-sorting map given by the following procedure. Suppose we are given an input sequence read from left to right. Throughout the procedure, we consider the sequence of socks obtained from reading the stack from top to bottom. At each point in time, we do one of the following operations:
-
(1)
If there are remaining socks to push and pushing the leftmost sock in our input sequence onto the top of the stack does not create a pattern in , then we do so.
-
(2)
Otherwise, we pop the topmost sock off of our stack.
The procedure continues until the output contains all socks in the original input. Let denote the output sock sequence.
Again, this general sorting procedure preserves the sets of sock sequences for any multiset of socks and also induces a map from sock patterns to sock patterns.
3. The foot-sorting map
In this section, we study the behavior of the foot-sorting map introduced in Definition 2.5. We begin by presenting a quick but useful lemma that tells us what the action of our foot-sorting map looks like recursively.
Lemma 3.1.
Let be a sock sequence where and are integers, and are nonempty sock sequences not containing . Then
Proof.
We show directly what happens to input sock sequence . By definition, we first push the first occurrences of onto the stack. We then have the following for all . We i) push all socks in onto the stack, which only contains occurrences of . This results in getting sorted by independently, since contains no occurrences of and therefore does not interact with the occurrences of at the bottom of the stack. We then ii) must pop all remaining socks in in the stack before pushing the next occurrences of , to avoid having the pattern occur in the stack. Finally, we iii) push the next consecutive occurrences of in our input. After rounds of this process, we are left with in our input, in our output, and exactly occurrences of on our stack. Again, we push all socks in and independently sort them. If , we finally pop all remaining socks in in the stack and all occurrences of at the bottom of the stack, giving us as our final output. If , we pop all remaining socks in in the stack before pushing the next occurrences of , and finally pop all occurrences of in the stack to obtain . Thus our output always becomes , as desired. ∎
Given how our foot-sorting map acts on sock sequences, we can provide an upper bound on the number of iterations of required to sort any sock sequence. In the permutation setting, we have that any permutation of length is -sortable under West’s stack-sorting map, which is linear in the number of distinct elements of the permutation sequence, and furthermore this bound is tight. It turns out that any sock sequence on distinct socks is -sortable under , which is also linear in the number of distinct elements appearing in our sequence. We also show that this bound is tight.
Theorem 3.2.
Let be any sock sequence on multiset . Let be the number of distinct socks in . Then is -sortable under . Furthermore, for any there exists a sock sequence such that is not -sortable under .
Proof.
Say that a sock is clumped if all occurrences of that sock appear consecutively. Then we can see that any sock that is clumped stays clumped under ; if we can push one of the clumped socks onto the stack and avoid the pattern , then we can push all of them onto the stack. Likewise, once we must pop a clumped sock out of the stack, then all of the socks can constitute the last sock in the pattern , so they must all be popped out together.
We claim that each application of adds at least one more clumped sock. In particular, if the first sock is not clumped, then by Lemma 3.1, one application of clumps together all occurrences of sock and sends them to the back of the output sock sequence. If the first sock is already clumped, then we have where is some sock sequence. Then , and we can use the same argument on . Thus, the first sock that is not already clumped becomes clumped under . Because socks that are clumped stay clumped in any subsequent application of , we need at most stacks to sort .
To show that this bound is tight for any , consider the sock sequence where is a sock for all and contains exactly two copies of each distinct sock . We will show that is not -sortable under . To do so, we claim that the after iterations of for, our sock sequence becomes where is a sock sequence of length containing only single occurrences of socks, and , and are sock sequences of lengths and . We prove this by induction on .
Our base case is easily verifiable; , which we can rewrite in the form where and are empty, , and , which are all of the correct form. Now we assume our hypothesis holds up to iteration , and show that it remains true after iteration . Indeed, if we write , we have
which we can rewrite as , where , , and . Then we can verify that , , , and , as desired.
Given the claim, we now have that is nonempty for all sufficiently large . The cannot be sorted until is empty, which takes at least iterations as desired. ∎
Note that this notion of nonconsecutive pattern avoidance for our deterministic stack-sorting maps (and more generally ) is necessary for our maps to have nice properties like the above. Suppose, instead we defined an analogous stack-sorting map (and more generally that only considers consecutive pattern avoidance in the procedure given by Definition 2.6. Then one example of a sock sequence that never gets sorted by applying iterations of would be (in fact, and ). Moreover, for any , we have sock sequences that never get sorted by applying iterations of . Indeed, we will see in Proposition 5.2 that for any pattern , there always exists an unsorted sock sequence that avoids and therefore alternates between and under iterations of , neither of which are sorted. Therefore, under the consecutive pattern avoidance regime, there would be no stack-sorting map that eventually sorts any sock sequence.
4. Enumerating -stack-sortable sock patterns under
In this section, we prove our main enumerative results. We first provide a proof of Theorem 1.1 and then derive asymptotics based on the closed form. Then we generalize our argument to prove Theorem 1.2.
We first discuss the notion of appending two sock patterns. Observe that under our notion of equivalence between sock sequences, even if sock sequences and are equivalent and sock sequences and are equivalent, it does not necessarily follow that the sock sequence is equivalent to the sock sequence . For example, suppose , and . Then we can have and , which are not the same sock pattern. The sock pattern is determined by how we explicitly assign sock names to the occurrence of and the occurrence of , up to standardization.
We are now ready to prove Theorem 1.1.
Proof of Theorem 1.1.
We use Lemma 3.1. Let be a -stack-sortable sock pattern under where for any . Note that in order for
to be sorted, we must have that for all , each individually is a -stack-sortable sock pattern under .
Then given any fixed , we only need to consider their relationship to each other in the full sock pattern. In particular, we claim that for any and nonempty sock patterns that are each -stack-sortable under , there are exactly two possible sock patterns that are -stack-sortable under . To see this, we must have , as otherwise the subsequence in contains either or as a subsequence and is not sorted. We then consider the following two cases:
-
i)
If , then there is exactly one way to assign sock names to and up to standardization. Namely, we can assign any sock names such that the socks in and are disjoint, and then standardize.
-
ii)
If , then again there is exactly one way to assign sock names to and up to standardization. Namely, we assign the same name to the last element that appears in and to the first element that appears in , and consider all other socks in and disjoint.
Then we can see that up to equivalence, is determined by the sock patterns together with the choice for of whether or not and share a sock, for a total of choices. We can now consider the cases where and separately, which allows us to write the following relation on :
(1) | ||||
(2) | ||||
(3) | ||||
(4) |
To see why Equation 1 holds, we can consider the coefficient of for any . On the left-hand side, this is by definition. On the right-hand side, we have two main terms. The first term counts the unique sock pattern with length that is -stack-sortable under when , namely . The second term contributes a sum of over all possible lengths with for and such that . This counts the number of sock patterns that are -stack-sortable under when , since we can take any nonempty sock patterns that are independently -stack-sortable under and append them in ways.
Corollary 4.1.
We have , where is a constant and is the inverse of the smallest positive root of .
Proof.
For any power series and , let denote the coefficient of in the series . We wish to find asymptotics for .
Let . Note that to obtain asymptotics for , it suffices to compute asymptotics for the coefficients of the power series of at , since we can verify that
contributes only constant terms to .
In particular, we define , where is the smallest positive root of (and thus the singularity of with smallest magnitude). Then we have that the smallest singularity of occurs at , so we can write where and is analytic in some disk where . Let . Then Darboux’s Theorem [8, 23] tells us that
Plugging in and gives us
Note that , which is well-defined and computable. We can also compute using Stirling’s approximation as follows:
Thus, we have
where is a constant, , and is the smallest solution to , as desired. ∎
We can extend the previous result to a more refined enumeration of the -stack-sortable sock patterns under of a given length based on the number of distinct socks that appear. We can thus define a -analogue for the statistic , and find a closed form for its generating function as stated in Theorem 1.2. Our proof is analogous to the proof of Theorem 1.1.
Proof of Theorem 1.2.
Let denote the number of sock patterns of length that are -stack-sortable under and have distinct socks. Again, for to be -stack-sortable, we must have that are individually -stack-sortable under for all (where the are potentially nonempty). Furthermore, if has distinct socks, then we have to choose how to cover those socks across the sock patterns .
We again split into two cases. When , we have that there is exactly one sock pattern of length that is -stack-sortable under , namely . This pattern contains one distinct sock, so we can capture these sock patterns in the sum .
Now suppose , so we have a nonzero number of nonempty sock patterns . Suppose has length and distinct socks for . For each nonempty , we can again either choose to i) have the first sock of be the same as the last sock of , or ii) have (and therefore ) have disjoint socks from . In the former, the total number of distinct socks added by appending is , and in the latter, the total number of distinct socks added by adding is . Thus, our contributions to look like the product of either or terms over all , which we can factor as . We can thus write the following relation on :
We can now easily solve this quadratic in to get the closed form
as desired. ∎
After obtaining a closed form and asymptotics for the number of -stack-sortable sock patterns of a given length, it is natural to ask whether or not there is a simple way to describe what -stack-sortable sock sequences look like. It turns out that even though we know recursively what the map behaves like, we cannot easily characterize the set of -stack-sortable sock sequences. The following example shows that sortability is not closed under containment, that is, there exist sock sequences and such that is contained in , is not -stack-sortable, and is -stack-sortable. Take and . Then is unsorted and is sorted. Therefore, the set of -stack-sortable sock sequences under cannot be characterized as all sock sequences that avoid some fixed set of sock patterns. Note that this contrasts with the original nondeterministic setting that Defant and Kravitz introduced based on Knuth’s stack-sorting machine [15]. The lack of a pattern avoidance characterization of -stack-sortable sock patterns is due to the determinism of the stack-sorting procedure here. It is worth mentioning that the set of -stack-sortable permutations under West’s stack-sorting map is also not closed under permutation pattern containment when [22].
5. General -avoiding stack-sorting algorithms
In this section, we study the behavior of for general beyond the pattern . A natural question to ask is whether or not will always sort any arbitrary sock sequence in . The following proposition tells us that is the only such map.
Proposition 5.1.
The only for which eventually sorts all sock sequences is .
Proof.
Note that for any such that , then and thus will never sort . Thus, we only need to consider when . There are two patterns of length two, namely and . We can easily verify that the sock sequence gets taken to itself and to its reverse under and , respectively. ∎
The question above is not particularly interesting, since we simply show that there exist short sock sequences that cannot be sorted by when is sufficiently large. We would like to say something stronger. In the permutation setting, it makes sense to group permutations of a given length (since passes through the stack will never change the length of the input permutation) and say something about the existence of unsortable permutations for all . Similarly, in the sock sequence setting, we group sock sequences on a given multiset . Now we can ask for which do we have that any sock sequence within will eventually become sorted under . We have the following proposition, which tells us that for an infinitely large class of , the map cannot eventually sort all sock sequences in any (unless every sock sequence of is already sorted).
Proposition 5.2.
Let be an unsorted sock pattern that is not of the form . Then for any multiset of socks such that not all sock sequences in are sorted, there exists a sock sequence that is not -stack-sortable under for any .
Proof.
It suffices to show that there exists an unsorted sock sequence such that , as applying to any sock sequence that avoids just reverses . Suppose that consists of distinct socks . Without loss of generality, suppose there are at least two copies of . We know that contains because it is unsorted. Thus we can consider the following cases for and in each case we explicitly construct a sock sequence that avoids both and :
Case 1: contains or . Let be a sorted sock sequence. Consider the sock sequence
obtained by swapping the last and the first . Then avoids both and because the only occurrence of would either consist of the last two occurrences of or the first two occurrences of , both of which only contain one sock between them.
Case 2: contains or . Then we consider the sock sequence
This cannot contain an occurrence of because the only opportunity to contain as a pattern is to contain one of the occurrences of at the beginning and the last occurrence . Then there would be no more socks on either end of the sock sequence to represent the sock not equal to in the pattern . For the same reason, cannot contain an occurrence of .
Note that these cases are exhaustive, as we assume is not of the form . Therefore we have found a sock sequence that avoids and for all possible , as desired. ∎
6. Further Directions
In this final section, we propose several questions and directions for future study. We hope that continued investigation of deterministic stack-sorting maps for sock sequences, whether based on pattern avoidance or not, is fruitful and yields implications for the nondeterministic setting. We provide possible directions along the lines of characterization and enumeration.
Recall that we have shown that the foot-sorting map can sort any sock sequence on socks in at most iterations. Furthermore, we provided a construction to show that this bound is tight. We may ask whether there are other sock sequences for which the bound is tight.
Question 1.
What are all sock sequences on socks that are not -sortable under ?
It could be interesting to characterize the sock sequences on distinct socks that are not -stack-sortable. Beyond -sortable, it would also be interesting to characterize the sock sequences that are -stack-sortable and not -stack-sortable for other values of . For example, while there is no pattern avoidance characterization of the -stack-sortable sock sequences, it would be interesting to see whether or not there is still some nice characterization.
Along the lines of characterization, it could also be interesting to characterize an alternate class of periodic points. When looking at , we know that all sock sequences eventually get sorted, and thus the only periodic points are the sorted sock sequences, which are precisely those avoiding the sock pattern . Any sock sequence avoiding and is a periodic point under with period two. Recall that we have also shown in Proposition 5.2 that for almost all , we can find an unsorted periodic point avoiding and that has period two. It is natural to ask whether or not there are periodic points under with period greater than two when . It could be interesting to determine for which there exist periodic points under with period greater than two, and to characterize such periodic points.
Also recall that we have an enumeration of the sock patterns of length that are -stack-sortable under . Because we do not have a nice way to understand what the -stack-sortable sock sequences look like, nor do we understand how to count the number of preimages in general, it is not immediately clear how to enumerate even -stack-sortable sock patterns.
Question 2.
How many sock patterns of length are -stack-sortable under for ?
Another line of investigation would be to look at other deterministic sorting algorithms, such as considering analogous sorting maps that avoid multiple sock patterns at once. It could be interesting to investigate the behavior of alternative deterministic stack-sorting algorithms on sock sequences in general.
7. Acknowledgments
This work was done at the University of Minnesota Duluth with support from Jane Street Capital, the National Security Agency, and the CYAN Undergraduate Mathematics Fund at MIT. The author is grateful to Joe Gallian and Colin Defant for directing the Duluth REU program and for the opportunity to participate. The author is also grateful to Mitchell Lee, Noah Kravitz, Maya Sankar, and Yelena Mandelshtam for helpful discussions and their guidance throughout the research process.
References
- [1] M. D. Atkinson and J.-R. Sack, Pop-stacks in parallel, Inform. Process. Lett. 70 (1999), 63–67.
- [2] David Avis and Monroe Newborn, On pop-stacks in series, Utilitas Math. 19 (1981), 129–140.
- [3] Katalin Berlow, Restricted stacks as functions, Discrete Math. 344 (2021), Paper No. 112571, 11.
- [4] Miklós Bóna, A survey of stack-sorting disciplines, Electron. J. Combin. 9 (2003), Article 1, 16.
- [5] Giulio Cerbai, Sorting Cayley permutations with pattern-avoiding machines, Australas. J. Combin. 80 (2021), 322–341.
- [6] Giulio Cerbai, Anders Claesson, and Luca Ferrari, Stack sorting with restricted stacks, J. Combin. Theory Ser. A 173 (2020), 105230, 19.
- [7] Anders Claesson, Mark Dukes, and Einar Steingrímsson, Permutations sortable by passes through a stack, Ann. Comb. 14 (2010), 45–51.
- [8] G. Darboux, Mémoire sur l’approximation des fonctions de très-grands nombres, et sur une classe étendue de développements en série., Journal de Mathématiques Pures et Appliquées (1878), 5–56 (fre).
- [9] Colin Defant, Counting 3-stack-sortable permutations, J. Combin. Theory Ser. A 172 (2020), 105209, 26.
- [10] Colin Defant, Pop-stack-sorting for Coxeter groups, Comb. Theory 2 (2022), Paper No. 11, 30.
- [11] Colin Defant, Stack-Sorting and Beyond, ProQuest LLC, Ann Arbor, MI, 2022, Thesis (Ph.D.)–Princeton University.
- [12] Colin Defant, Stack-sorting for Coxeter groups, Comb. Theory 2 (2022), Paper No. 18, 49.
- [13] Colin Defant, Troupes, cumulants, and stack-sorting, Advances in Mathematics 399 (2022), 108270.
- [14] Colin Defant and Noah Kravitz, Stack-sorting for words, Australas. J. Combin. 77 (2020), 51–68.
- [15] Colin Defant and Noah Kravitz, Foot-Sorting for Socks, November 2022, arXiv:2211.02021 [math].
- [16] Colin Defant and Kai Zheng, Stack-sorting with consecutive-pattern-avoiding stacks, Adv. in Appl. Math. 128 (2021), Paper No. 102192, 33.
- [17] Martin Klazar, Counting pattern-free set partitions. I. A generalization of Stirling numbers of the second kind, European J. Combin. 21 (2000), 367–378.
- [18] Martin Klazar, Counting pattern-free set partitions. II. Noncrossing and other hypergraphs, Electron. J. Combin. 7 (2000), Research Paper 34, 25.
- [19] Donald E. Knuth, The art of computer programming. Vol. 4A. Combinatorial algorithms. Part 1, Addison-Wesley, Upper Saddle River, NJ, 2011.
- [20] Adeline Pierrot and Dominique Rossin, 2-stack sorting is polynomial, Theory Comput. Syst. 60 (2017), 552–579.
- [21] Rebecca Smith and Vincent Vatter, A stack and a pop stack in series, Australas. J. Combin. 58 (2014), 157–171.
- [22] Julian West, Permutations with forbidden subsequences, and, stack-sortable permutations, Thesis, Massachusetts Institute of Technology, 1990, Accepted: 2005-08-10T22:33:11Z.
- [23] Herbert S. Wilf, generatingfunctionology, third ed., A K Peters, Ltd., Wellesley, MA, 2006.