Source author record

Karol Pokorski

Explore this author’s publications, collaborators and research topics. This catalog record has not been claimed by its author.

ResearcherUnclaimed source record

Catalog footprint

Research overview

1works
2topics
2close collaborators

Published work

1 publications

preprint2021arXiv

Strictly In-Place Algorithms for Permuting and Inverting Permutations

We revisit the problem of permuting an array of length nn according to a given permutation in place, that is, using only a small number of bits of extra storage. Fich, Munro and Poblete [FOCS 1990, SICOMP 1995] obtained an elegant O(nlog⁡n)\mathcal{O}(n\log n)-time algorithm using only O(log⁡2n)\mathcal{O}(\log^{2}n) bits of extra space for this basic problem by designing a procedure that scans the permutation and outputs exactly one element from each of its cycles. However, in the strict sense in place should be understood as using only an asymptotically optimal O(log⁡n)\mathcal{O}(\log n) bits of extra space, or storing a constant number of indices. The problem of permuting in this version is, in fact, a well-known interview question, with the expected solution being a quadratic-time algorithm. Surprisingly, no faster algorithm seems to be known in the literature. Our first contribution is a strictly in-place generalisation of the method of Fich et al. that works in Oε(n1+ε)\mathcal{O}_{\varepsilon}(n^{1+\varepsilon}) time, for any ε>0\varepsilon > 0. Then, we build on this generalisation to obtain a strictly in-place algorithm for inverting a given permutation on nn elements working in the same complexity. This is a significant improvement on a recent result of Guśpiel [arXiv 2019], who designed an O(n1.5)\mathcal{O}(n^{1.5})-time algorithm.

Research graph

See the researcher in context

Open full explorer

Inspect adjacent papers, topics, institutions and collaborators without losing the researcher page.

Building this map preview

BZPEER is loading the nearby papers, people, topics and institutions for this page.