Optimal-Time Move Structure Construction

Abstract

The move structure represents a permutation π of [0,n) as a covering set of O(r) disjoint intervals (contiguous subsets of [0,n)), where r is the minimum number of intervals whose values permute together. Formally, r = 1 + |\i∈ [1,n) : π(i) - 1 ≠ π(i-1)\|. The move structure takes O(r) words of space. Given the index of the interval containing i, it allows computing π(i) and the index of the interval containing π(i) in O(1)-time. Therefore, for permutations where r n, it allows their representation and navigation in significantly compressed space. The previous best O(r)-space move structure construction algorithm takes O(r r)-time. In this paper, we describe a construction algorithm achieving optimal O(r)-time and space. We also show that using our improved algorithm within a recent previous work allows the computation of the longest common prefix array in O(r)-working space and optimal O(n)-time given the run-length-encoded Burrows-Wheeler transform. Finally, we implement our improved move structure construction algorithm and find that it is faster than the previous best algorithm while using comparable memory.

0

Turn this paper into a full lesson

ArcXiv compiles a staged curriculum from this paper: 8-12 lessons across beginner → advanced, synthesised section guides, visuals, flashcards, a quiz, exercises, and on-demand deep dives per section. Grounded in the abstract, never invented.

Discussion (0)

Sign in to join the discussion.

Loading comments…