English
Related papers

Related papers: An in-place, subquadratic algorithm for permutatio…

200 papers

We revisit the problem of permuting an array of length $n$ 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…

Data Structures and Algorithms · Computer Science 2021-01-12 Bartłomiej Dudek , Paweł Gawrychowski , Karol Pokorski

We show that any permutation of ${1,2,...,N}$ can be written as the product of two involutions. As a consequence, any permutation of the elements of an array can be performed in-place in parallel in time O(1). In the case where the…

Data Structures and Algorithms · Computer Science 2015-03-20 Qingxuan Yang , John Ellis , Khalegh Mamakani , Frank Ruskey

We explore various techniques to compress a permutation $\pi$ over n integers, taking advantage of ordered subsequences in $\pi$, while supporting its application $\pi$(i) and the application of its inverse $\pi^{-1}(i)$ in small time. Our…

Data Structures and Algorithms · Computer Science 2009-02-09 Jérémy Barbay , Gonzalo Navarro

We have rediscovered a simple algorithm to compute the mathematical constant \[ \pi=3.14159265\cdots. \] The algorithm had been known for a long time but it might not be recognized as a fast, practical algorithm. The time complexity of it…

Number Theory · Mathematics 2019-12-24 Tsz-Wo Sze

In-place associative integer sorting technique was developed, improved and specialized for distinct integers. The technique is suitable for integer sorting. Hence, given a list S of n integers S[0...n-1], the technique sorts the integers in…

Data Structures and Algorithms · Computer Science 2012-10-08 A. Emre Cetin

The technique of in-situ associative permuting is introduced which is an association of in-situ permuting and in-situ inverting. It is suitable for associatively permutable permutations of {1,2,...,n} where the elements that will be…

Data Structures and Algorithms · Computer Science 2013-01-11 A. Emre Cetin

We give a simple and efficient algorithm for adaptively counting inversions in a sequence of $n$ integers. Our algorithm runs in $O(n + n \sqrt{\lg{(Inv/n)}})$ time in the word-RAM model of computation, where $Inv$ is the number of…

Data Structures and Algorithms · Computer Science 2015-03-05 Amr Elmasry

Given a set $\Pi$ of permutation patterns of length at most $k$, we present an algorithm for building $S_{\le n}(\Pi)$, the set of permutations of length at most $n$ avoiding the patterns in $\Pi$, in time $O(|S_{\le n - 1}(\Pi)| \cdot k +…

Discrete Mathematics · Computer Science 2017-03-20 William Kuszmaul

Given a signed permutation on $n$ elements, we need to sort it with the fewest reversals. This is a fundamental algorithmic problem motivated by applications in comparative genomics, as it allows to accurately model rearrangements in small…

Data Structures and Algorithms · Computer Science 2023-08-31 Bartłomiej Dudek , Paweł Gawrychowski , Tatiana Starikovskaya

The Permutation Pattern Matching problem asks, given two permutations $\sigma$ on $n$ elements and $\pi$, whether $\sigma$ admits a subsequence with the same relative order as $\pi$ (or, in the counting version, how many such subsequences…

Data Structures and Algorithms · Computer Science 2021-08-27 Pawel Gawrychowski , Mateusz Rzepecki

Given two permutations $\sigma$ and $\pi$, the \textsc{Permutation Pattern} problem asks if $\sigma$ is a subpattern of $\pi$. We show that the problem can be solved in time $2^{O(\ell^2\log \ell)}\cdot n$, where $\ell=|\sigma|$ and…

Data Structures and Algorithms · Computer Science 2013-11-01 Sylvain Guillemot , Dániel Marx

In 1937, biologists Sturtevant and Tan posed a computational question: transform a chromosome represented by a permutation of genes, into a second permutation, using a minimum-length sequence of reversals, each inverting the order of a…

Data Structures and Algorithms · Computer Science 2024-04-01 Krister M. Swenson

We present a new algorithm for iterating over all permutations of a sequence. The algorithm leverages elementary~$O(1)$ operations on recursive lists. As a result, no new nodes are allocated during the computation. Instead, all elements are…

Data Structures and Algorithms · Computer Science 2025-09-16 Thomas Baruchel

Previous compact representations of permutations have focused on adding a small index on top of the plain data $<\pi(1), \pi(2),...\pi(n)>$, in order to efficiently support the application of the inverse or the iterated permutation. In this…

Data Structures and Algorithms · Computer Science 2011-08-23 Jérémy Barbay , Gonzalo Navarro

We give an algorithm to compute $N$ steps of a convolution quadrature approximation to a continuous temporal convolution using only $O(N \log N)$ multiplications and $O(\log N)$ active memory. The method does not require evaluations of the…

Numerical Analysis · Mathematics 2011-11-10 Achim Schädle , María López-Fernández , Christian Lubich

Counting inversions is a classic and important problem in databases. The number of inversions, $K^*$, in a list $L=(L(1),L(2),\ldots,L(n))$ is defined as the number of pairs $i < j$ with $L(i) > L(j)$. In this paper, new results for this…

Data Structures and Algorithms · Computer Science 2016-12-28 Saladi Rahul

The rotation of multi-dimensional arrays, or tensors, is a fundamental operation in computer science with applications ranging from data processing to scientific computing. While various methods exist, achieving this rotation in-place…

Data Structures and Algorithms · Computer Science 2025-12-02 Dexin Chen

The move structure represents a permutation $\pi$ 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 +…

Data Structures and Algorithms · Computer Science 2026-04-27 Nathaniel K. Brown , Ahsan Sanaullah , Shaojie Zhang , Ben Langmead

We describe a new algorithm that computes the n-th Bernoulli number in n^(4/3 + o(1)) bit operations. This improves on previous algorithms that had complexity n^(2 + o(1)).

Number Theory · Mathematics 2013-05-02 David Harvey

Permutation patterns and pattern avoidance have been intensively studied in combinatorics and computer science, going back at least to the seminal work of Knuth on stack-sorting (1968). Perhaps the most natural algorithmic question in this…

Data Structures and Algorithms · Computer Science 2019-08-14 Benjamin Aram Berendsohn , László Kozma , Dániel Marx
‹ Prev 1 2 3 10 Next ›