Skip to main content
Log in

A probabilistic analysis of the height of tries and of the complexity of triesort

  • Published:
Acta Informatica Aims and scope Submit manuscript

Summary

We consider binary tries formed by using the binary fractional expansions of X 1, ...,X n, a sequence of independent random variables with common density f on [0,1]. For H n, the height of the trie, we show that either E(Hn)∼21og2 n or E(Hn)=∞ for all n≧2 according to whether ∫f 2(x)dx is finite or infinite. Thus, the average height is asymptotically twice the average depth (which is ∼log2 n when ∫f 2(x)dx>∞). The asymptotic distribution of H n is derived as well.

If f is square integrable, then the average number of bit comparisons in triesort is nlog2 n+0(n), and the average number of nodes in the trie is 0(n).

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Institutional subscriptions

Similar content being viewed by others

References

  1. Devroye, L.: Laws of the iterated logarithm for order statistics of uniform spacings. Ann. Probability 9, 860–867 (1981)

    Google Scholar 

  2. Devroye, L.: A note on the average depth of tries. Computing 28, 367–371 (1982)

    Google Scholar 

  3. Flajolet, Ph., Steyaert, J.M.: A branching process arising in dynamic hashing, trie searching and polynomial factorization. Proceedings of the 9th ICALP Colloquium, Lecture Notes in Computer Science, Vol. 140, pp. 239–251. Berlin-Heidelberg-New York: Springer 1982

    Google Scholar 

  4. Fredkin, E.H.: Trie memory. Comm. ACM 3, 490–500 (1960)

    Google Scholar 

  5. Johnson, N.L., Kotz, S.: Distributions in statistics: Continuous univariate distributions —1. New York: John Wiley 1970

    Google Scholar 

  6. Regnier, M.: On the average height of trees in digital search and dynamic hashing. Information Processing Lett. 13, 64–66 (1982)

    Google Scholar 

  7. Yao, A.C.: A note on the analysis of extendible hashing. Information Processing Lett. 11, 84–86 (1980)

    Google Scholar 

  8. Wheeden, R.L., Zygmund, A.: Measure and Integral. New York: Marcel Dekker 1977

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Additional information

Research of the author was supported in part by FCAC Grant EQ-1678

Rights and permissions

Reprints and permissions

About this article

Cite this article

Devroye, L. A probabilistic analysis of the height of tries and of the complexity of triesort. Acta Informatica 21, 229–237 (1984). https://doi.org/10.1007/BF00264248

Download citation

  • Received:

  • Issue Date:

  • DOI: https://doi.org/10.1007/BF00264248

Keywords

Navigation