【24h】

Optimal Partitioning for Dual Pivot Quicksort

机译:Dual Pivot Quicksort的最佳分区

获取原文

摘要

Dual pivot quicksort refers to variants of classical quicksort where in the partitioning step two pivots are used to split the input into three segments. This can be done in different ways, giving rise to different algorithms. Recently, a dual pivot algorithm due to Yaroslavskiy received much attention, because it replaced the well-engineered quicksort algorithm in Oracle's Java 7 runtime library. Nebel and Wild (ESA 2012) analyzed this algorithm and showed that on average it uses 1.9n In n + O(n) comparisons to sort an input of size n, beating standard quicksort, which uses 2n In n + O(n) comparisons. We introduce a model that captures all dual pivot algorithms, give a unified analysis, and identify new dual pivot algorithms that minimize the average number of key comparisons among all possible algorithms up to lower order or linear terms. This minimum is 1.8n In n + O(n).
机译:双枢轴快速排序是指经典快速排序的变体,其中在分区步骤中,使用两个枢轴将输入分为三个部分。这可以通过不同的方式来完成,从而产生不同的算法。最近,由于Yaroslavskiy的双重枢纽算法引起了广泛关注,因为它取代了Oracle Java 7运行时库中精心设计的quicksort算法。 Nebel和Wild(ESA 2012)分析了该算法,结果表明,平均而言,它使用1.9n In n + O(n)比较来对大小为n的输入进行排序,超过了使用2n In n + O(n)比较的标准快速排序。我们引入了一个模型,该模型可以捕获所有双重枢纽算法,进行统一分析,并确定新的双重枢纽算法,该算法将所有可能算法之间的键比较的平均次数最小化,直到低阶或线性项为止。该最小值为1.8n In n + O(n)。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号