Patterns in random binary search trees

Ž . ABSTRACT: In a randomly grown binary search tree BST of size n, any fixed pattern occurs with a frequency that is on average proportional to n. Deviations from the average case are highly unlikely and well quantified by a Gaussian law. Trees with forbidden patterns occur with an exponentially small probability that is characterized in terms of Bessel functions. The results obtained extend to BSTs a type of property otherwise known for strings and combinatorial tree models. They apply to paged trees or to quicksort with halting on short subfiles. As a consequence, various pointer saving strategies for maintaining trees obeying the random BST model can be precisely quantified. The methods used are based on analytic models, especially bivariate generating function subjected to singularity perturbaŽ . tion asymptotics. Q 1997 John Wiley & Sons, Inc. Random Struct. Alg., 11, 223]244 1997

[1]  James Allen Fill,et al.  On the distribution of binary search trees under the random permutation model , 1996, Random Struct. Algorithms.

[2]  Leonidas J. Guibas,et al.  Periods in Strings , 1981, J. Comb. Theory, Ser. A.

[3]  Feller William,et al.  An Introduction To Probability Theory And Its Applications , 1950 .

[4]  W. Wasow Asymptotic expansions for ordinary differential equations , 1965 .

[5]  Zhicheng Gao,et al.  Central and local limit theorems applied to asymptotic enumeration IV: multivariate generating functions , 1992 .

[6]  Jean Vuillemin,et al.  A unifying look at data structures , 1980, CACM.

[7]  D. Knuth,et al.  Mathematics for the Analysis of Algorithms , 1999 .

[8]  H. Daniels Saddlepoint Approximations in Statistics , 1954 .

[9]  Philippe Flajolet,et al.  Page usage in a quadtree index , 1992, BIT Comput. Sci. Sect..

[10]  P. Flajolet,et al.  The average case analysis of algorithms : Saddle Point Asymptotics , 1994 .

[11]  Philippe Flajolet,et al.  An introduction to the analysis of algorithms , 1995 .

[12]  Pierre Nicodème Compact Balanced Tries , 1992, IFIP Congress.

[13]  David Aldous,et al.  Asymptotic Fringe Distributions for General Families of Random Trees , 1991 .

[14]  Donald E. Knuth,et al.  The art of computer programming: sorting and searching (volume 3) , 1973 .

[15]  Danièle Gardy Methode de col et lois limites en analyse combinatoire , 1992, Theor. Comput. Sci..

[16]  Edward A. Bender,et al.  Central and Local Limit Theorems Applied to Asymptotic Enumeration II: Multivariate Generating Functions , 1983, J. Comb. Theory, Ser. A.

[17]  Edward A. Bender,et al.  Central and Local Limit Theorems Applied to Asymptotic Enumeration , 1973, J. Comb. Theory A.

[18]  Charles M. Grinstead,et al.  Introduction to probability , 1999, Statistics for the Behavioural Sciences.

[19]  A. Markushevich Analytic Function Theory , 1996 .

[20]  Hosam M. Mahmoud,et al.  Analysis of the Space of Search Trees under the Random Insertion Algorithm , 1989, J. Algorithms.

[21]  Jean-Marc Steyaert,et al.  Patterns and Pattern-Matching in Trees: An Analysis , 1984, Inf. Control..

[22]  Luc Devroye Universal Limit Laws for Depths in Random Trees , 1998, SIAM J. Comput..

[23]  Hsien-Kuei Hwang,et al.  Théorèmes limites pour les structures combinatoires et les fonctions arithmétiques , 1994 .

[24]  Conrado Martínez,et al.  Statistics under the BST model , 1992 .

[25]  Philippe Flajolet,et al.  Analytic Variations on the Common Subexpression Problem , 1990, ICALP.

[26]  Hosam M. Mahmoud,et al.  Evolution of random search trees , 1991, Wiley-Interscience series in discrete mathematics and optimization.

[27]  Philippe Flajolet,et al.  General combinatorial schemas: Gaussian limit distributions and exponential tails , 1993, Discret. Math..

[28]  Philippe Flajolet,et al.  Varieties of Increasing Trees , 1992, CAAP.

[29]  Wojciech Rytter,et al.  Analysis of algorithms and data structures , 1991, International computer science series.

[30]  Philippe Flajolet,et al.  Search costs in quadtrees and singularity perturbation asymptotics , 1994, Discret. Comput. Geom..

[31]  Conrado Martínez,et al.  Randomization of Search Trees by Subtree Size , 1996, ESA.

[32]  Philippe Flajolet,et al.  Deviations from uniformity in random strings , 1988 .

[33]  Henry C. Thacher,et al.  Applied and Computational Complex Analysis. , 1988 .

[34]  Michael Drmota,et al.  Systems of functional equations , 1997, Random Struct. Algorithms.