Optimizing stable in-place merging

被引:15
作者
Chen, JC [1 ]
机构
[1] Donghua Univ, Dept Commun, Shanghai 200051, Peoples R China
关键词
in-place algorithms; stable merging; sorting;
D O I
10.1016/S0304-3975(02)00775-2
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
In 2000, Geffert et al. (Theoret. Comput. Sci. 237 (2000) 159) presented an asymptotically efficient algorithm for stable merging in constant extra space. The algorithm requires at most m(1)(t + 1) + m(2)/2' + o(m(1)) comparisons (t = [log(2)(m(2)/m(1))]) and 5m(2) + 12m(1) + o(m(1)) moves, where m(1) and m(2) are the sizes of two ordered sublists to be merged, and in m(1) less than or equal to m(2). This paper optimizes the algorithm. The optimized algorithm is simpler than their algorithm, and makes at most m(1)(t + 1) + m(2)/2' + o(m(1) + m(2)) comparisons and 6m(2) + 7m(1) + o(m(1) + m(2)) Moves. (C) 2002 Elsevier Science B.V. All rights reserved.
引用
收藏
页码:191 / 210
页数:20
相关论文
共 11 条