Pattern-avoiding permutations are a central object of study in both combinatorics and theoretical computer science. In this paper we design a data structure that can store any size-$n$ permutation $\tau$ that avoids an arbitrary (and unknown) fixed pattern $\pi$ in the asymptotically optimal $O(n \lg{s_\pi})$ bits, where $s_\pi$ is the Stanley-Wilf limit of $\pi$. Our data structure supports $\tau(i)$ and $\tau^{-1}(i)$ queries in $O(1)$ time, sidestepping the lower bound of Golynski (SODA 2009) that holds for general permutations. Comparable results were previously known only in more restricted cases, e.g., when $\tau$ is separable, which means avoiding the patterns 2413 and 3142. We also extend our data structure to support more complex geometric queries on pattern-avoiding permutations (or planar point sets) such as rectangle range counting in $O(\lg\lg{n})$ time. This result circumvents the lower bound of $\Omega{(\lg{n}/\lg\lg{n})}$ by P\u{a}tra\c{s}cu (STOC 2007) that holds in the general case. For bounded treewidth permutation classes (which include the above-mentioned separable class), we further reduce the space overhead to a lower order additive term, making our data structure succinct. This extends and improves results of Chakraborty et al. (ISAAC 2024) that were obtained for separable permutations via different techniques. All our data structures can be constructed in linear time.
翻译:避免模式排列是组合数学与理论计算机科学研究的核心对象。本文设计了一种数据结构,能够以渐近最优的 $O(n \lg{s_\pi})$ 比特存储任意规模为 $n$ 且避免任意(未知)固定模式 $\pi$ 的排列 $\tau$,其中 $s_\pi$ 是 $\pi$ 的 Stanley-Wilf 极限。该数据结构支持在 $O(1)$ 时间内完成 $\tau(i)$ 和 $\tau^{-1}(i)$ 查询,从而绕过了 Golynski(SODA 2009)针对一般排列所证明的下界。此前类似结果仅适用于更受限的情形,例如当 $\tau$ 为可分离排列(即避免模式 2413 和 3142)时。我们还将该数据结构扩展至支持对避免模式排列(或平面点集)进行更复杂的几何查询,例如在 $O(\lg\lg{n})$ 时间内完成矩形范围计数。这一结果突破了 Pătrașcu(STOC 2007)针对一般情况所证明的 $\Omega{(\lg{n}/\lg\lg{n})}$ 下界。对于有界树宽排列类(包含上述可分离类),我们进一步将空间开销降低至低阶附加项,使数据结构达到简洁表示。这扩展并改进了 Chakraborty 等人(ISAAC 2024)通过不同技术针对可分离排列获得的结果。我们提出的所有数据结构均可在线性时间内构建完成。