A |
|
= |
|
(e | + aj(a1+...+aj) |
|
). |
N |
|
(z,u,x1,x2,...,xr)= |
|
æ ç ç è |
1 + |
|
ö ÷ ÷ ø |
( A | \ {a}) |
|
= (a1+...+a |
|
) |
|
W (a |
|
+...+ar) |
|
. |
æ ç ç è |
|
fn zn |
ö ÷ ÷ ø |
W |
æ ç ç è |
|
gn zn |
ö ÷ ÷ ø |
= |
|
æ ç ç è |
|
|
fkgn-k |
ö ÷ ÷ ø |
zn. |
(N |
|
(z,u,x1,...,x |
|
) W N |
|
(z,u,x |
|
,...,xr)) |
æ ç ç è |
1+ |
|
ö ÷ ÷ ø |
. |
E | [C |
|
]= |
|
|
æ ç è |
1-e |
|
ö ÷ ø |
, with | P |
|
= |
|
pj. |
|
|
||||||||||||||||||||||||||||||||||||||||||||||
|
|
E | [L] |
|
= |
|
n log n +O(n) and E | [R] |
|
= |
|
log n +O(1) |
In order to assess the relevance of these theoretical analyses, a simulation campaign was undertaken on Herman Melville's novel, Moby Dick. Its conclusions are [1]:
array-trie (standard) list-trie bst-trie (tst)
Pointers r/H S n 2/H S n 3/H S n Path length 1/H S nlog n C S*/H S nlog n C S/H S nlog n Search 1/H S log n C S*/H S log n C S/H S log n
Ternary search tries are an efficient data structure from the information theoretic point of view since a search costs typically about log n comparisons. List-tries require about 3 times as many comparisons. For an alphabet of cardinality 26, the storage cost of ternary search tries is about 9 times smaller than standard array-tries.
This document was translated from LATEX by HEVEA.