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 BST's 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 functions subjected to singularity perturbation asymptotics.
F(z,y):= |
|
fn,kykxn = |
|
l(t) y |
|
z|t|, |
F(z,y)=- |
|
, w(z,y)=Am(L zm+1)-zBm(L zm+1), |
Pr | { | wu[t]=k||t|=n | } | =au(0)-n-1· |
|
æ ç ç è |
1+O( |
|
) |
ö ÷ ÷ ø |
, µ=- |
|
. |
|
½ ½ ½ ½ ½ ½ |
Pr |
ì í î |
|
£ x |
ü ý þ |
- |
|
ó õ |
|
e |
|
dw |
½ ½ ½ ½ ½ ½ |
< |
|
. |
|
½ ½ ½ ½ |
sn Pr{Wn=ëµn+xsnû} - |
|
e |
|
½ ½ ½ ½ |
® 0, |
|
G(z,y) =yG2(z,y)+(1-y) |
|
æ ç ç è |
|
ö ÷ ÷ ø |
, |
µn= |
|
-1, sn2= |
|
|
(n+1). |
Kn £4log 2 |
|
+O |
æ ç ç è |
|
ö ÷ ÷ ø |
. |
This document was translated from LATEX by HEVEA.