A simple linear-time algorithm for in situ merging
Information Processing Letters
The Computer Journal - Special issue on models and architectures
Journal of Algorithms
MFCS '90 Selected papers of the 15th international symposium on Mathematical foundations of computer science
In-place sorting with fewer moves
Information Processing Letters
Asymptotically efficient in-place merging
Theoretical Computer Science
Nordic Journal of Computing
A Meticulous Analysis of Mergesort Programs
CIAC '97 Proceedings of the Third Italian Conference on Algorithms and Complexity
Optimizing stable in-place merging
Theoretical Computer Science
An in-place sorting with O(nlog n) comparisons and O(n) moves
Journal of the ACM (JACM)
FCT'09 Proceedings of the 17th international conference on Fundamentals of computation theory
Sorting by merging or merging by sorting?
SWAT'06 Proceedings of the 10th Scandinavian conference on Algorithm Theory
Hi-index | 5.23 |
We present an algorithm for asymptotically efficient k-way merging. Given an array A containing k sorted subsequences A"1,...,A"k of respective lengths n"1,...,n"k, where @?"i"="1^kn"i=n, our algorithm merges A"1,...,A"k into a single sorted sequence in-place and in linear time, performing c"k@?n+o(n) element comparisons and 3@?n+o(n) element moves, where c"k=@?lgk@?+2@?(1-2^@?^l^g^k^@?/k), which is a constant satisfying lgk@?c"k@?@?lgk@? and, moreover, bounded by c"k@?lgk+0.0861. The algorithm does not merge stably, however, it does not require that the elements in A are all distinct.