Advertisement

Analysis of Quickfind with Small Subfiles

  • Conrado Martínez
  • Daniel Panario
  • Alfredo Viola
Conference paper
Part of the Trends in Mathematics book series (TM)

Abstract

In this paper we investigate variants of the well-known Hoare’s Quickfind algorithm for the selection of the j-th element out of n when recursion stops for subfiles whose size is below a predefined threshold and a simpler algorithm is run instead. We provide estimates for the combined number of passes, comparisons and exchanges under three policies for the small subfiles: insertion sort and two variants of selection sort, but the analysis could be easily adapted for alternative policies. We obtain the average cost for each of these variants and compare them with the costs of the standard variant which does not use cutoff. We also give the best explicit cutoff bound for each of the variants.

Keywords

Average Cost Cutoff Function Optimal Sampling Strategy Quicksort Algorithm Pivot Selection 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. [1]
    Anderson, D., and Brown, R. Combinatorial aspects of C.A.R. Hoare’s FIND algorithm. Australasian Journal of Combinatorics 5 (1992), 109–119.MathSciNetzbMATHGoogle Scholar
  2. [2]
    Hoare, C. Find (Algorithm 65). Communications of the ACM. (1961), 321–322.Google Scholar
  3. [3]
    Hoare, C. Quicksort. Computer Journal 5 (1962), 10–15.MathSciNetzbMATHCrossRefGoogle Scholar
  4. [4]
    HWANG, H.-K., AND TSAI, T.-H. Quickselect and Dickman function. Combinatorics, Probability and Computing (2002). To appear.Google Scholar
  5. [5]
    Kirschenhofer, P., Prodinger, H., And Martínez, C. Analysis of Hoare’s FIND algorithm with median-of-three partition. Random Structures 14 Algorithms 10 (1997), 143–156.zbMATHCrossRefGoogle Scholar
  6. [6]
    Knuth, D. Mathematical analysis of algorithms. In Information Processing ‘71, Proc. of the 1971 IFIP Congress (Amsterdam, 1972), North-Holland, pp. 19–27.Google Scholar
  7. [7]
    Knuth, D. The Art of Computer Programming: Sorting and Searching, 2nd ed., vol. 3. Addison-Wesley, Reading, Mass., 1998.Google Scholar
  8. [8]
    Martínez, C., and Roura, S. Optimal sampling strategies in Quicksort and quickselect. SIAM Journal on Computing 31, 3 (2001), 683–705.MathSciNetzbMATHCrossRefGoogle Scholar
  9. [9]
    Sedgewick, R. The analysis of Quicksort programs. Acta Informatica 7 (1976), 327–355.MathSciNetCrossRefGoogle Scholar
  10. [10]
    Sedgewick, R. Implementing Quicksort programs Communications of the ACM 21 (1978), 847–856.zbMATHCrossRefGoogle Scholar
  11. [11]
    Sedgewick, R. Quicksort. Garland, New York, 1978.Google Scholar
  12. [12]
    Sedgewick, R., and Flajolet, P. An Introduction to the Analysis of Algorithms. Addison-Wesley, Reading, Mass., 1996.Google Scholar

Copyright information

© Springer Basel AG 2002

Authors and Affiliations

  • Conrado Martínez
    • 1
  • Daniel Panario
    • 2
  • Alfredo Viola
    • 3
  1. 1.Departament de Llenguatges i Sistemes InformàticsUniversitat Politècnica de CatalunyaBarcelonaSpain
  2. 2.School of Mathematics and StatisticsCarleton UniversityOttawaCanada
  3. 3.Instituto de ComputaciónUniversidad de la RepúblicaMontevideoUruguay

Personalised recommendations