On the adaptiveness of Quicksort. Quicksort was first introduced in 1961 by Hoare. Many variants have been developed, the best of which are among the fastest generic-sorting algorithms available, as testified by the choice of Quicksort as the default sorting algorithm in most programming libraries. Some sorting algorithms are adaptive, i.e., they have a complexity analysis that is better for inputs, which are nearly sorted, according to some specified measure of presortedness. Quicksort is not among these, as it uses Ω(n log n) comparisons even for sorted inputs. However, in this paper, we demonstrate empirically that the actual running time of Quicksort is adaptive with respect to the presortedness measure Inv. Differences close to a factor of two are observed between instances with low and high Inv value. We then show that for the randomized version of Quicksort, the number of element swaps performed is provably adaptive with respect to the measure Inv. More precisely, we prove that randomized Quicksort performs expected O(n(1 + log(1 + Inv/n))) element swaps, where Inv denotes the number of inversions in the input sequence. This result provides a theoretical explanation for the observed behavior and gives new insights on the behavior of Quicksort. We also give some empirical results on the adaptive behavior of Heapsort and Mergesort.

References in zbMATH (referenced in 182 articles , 3 standard articles )

Showing results 1 to 20 of 182.
Sorted by year (citations)

1 2 3 ... 8 9 10 next

  1. Gan, Guojun; Ma, Chaoqun; Wu, Jianhong: Data clustering. Theory, algorithms, and applications (2021)
  2. Halldórsson, Magnús M.; de Lima, Murilo Santos: Query-competitive sorting with uncertainty (2021)
  3. Hoffman, Michael E.; Kuba, Markus: Logarithmic integrals, zeta values, and tiered binomial coefficients (2021)
  4. Albert, Michael; Holmgren, Cecilia; Johansson, Tony; Skerman, Fiona: Embedding small digraphs and permutations in binary trees and split trees (2020)
  5. Bartoszek, Krzysztof: Limit distribution of the quartet balance index for Aldous’s ((\beta\ge0))-model (2020)
  6. De Angelis, Emanuele; Fioravanti, Fabio; Proietti, Maurizio: Transformational verification of Quicksort (2020)
  7. Eberl, Manuel; Haslbeck, Max W.; Nipkow, Tobias: Verified analysis of random binary tree structures (2020)
  8. Edelkamp, Stefan; Weiß, Armin; Wild, Sebastian: QuickXsort: a fast sorting scheme in theory and practice (2020)
  9. Jenny, Patrick: Time adaptive conservative finite volume method (2020)
  10. Lange, Kenneth: Algorithms from THE BOOK (2020)
  11. Lecué, Guillaume; Lerasle, Matthieu; Mathieu, Timlothée: Robust classification via MOM minimization (2020)
  12. Roesler, Uwe: Almost sure convergence to the quicksort process (2020)
  13. Yao, Yukun: Using nonlinear difference equations to study Quicksort algorithms (2020)
  14. Apt, Krzysztof R.; Olderog, Ernst-Rüdiger: Fifty years of Hoare’s logic (2019)
  15. Aumüller, Martin; Dietzfelbinger, Martin; Heuberger, Clemens; Krenn, Daniel; Prodinger, Helmut: Dual-pivot quicksort: optimality, analysis and zeros of associated lattice paths (2019)
  16. Cai, Xing Shi; Holmgren, Cecilia; Janson, Svante; Johansson, Tony; Skerman, Fiona: Inversions in split trees and conditional Galton-Watson trees (2019)
  17. de Gouw, Stijn; de Boer, Frank S.; Bubel, Richard; Hähnle, Reiner; Rot, Jurriaan; Steinhöfel, Dominic: Verifying OpenJDK’s sort method for generic collections (2019)
  18. Moore, J. Strother: Milestones from the Pure Lisp Theorem Prover to ACL2 (2019)
  19. Nguyen Kieu Linh; Song, Chanyoung; Ryu, Joonghyun; Phan Thanh An; Hoang, Nam-Dũng; Kim, Deok-Soo: QuickhullDisk: a faster convex hull algorithm for disks (2019)
  20. Wu, Yan-Xue; Min, Xue-Yang; Min, Fan; Wang, Min: Cost-sensitive active learning with a label uniform distribution model (2019)

1 2 3 ... 8 9 10 next