DYNAMIC HASH-TABLES

被引:46
作者
LARSON, PA
机构
[1] Univ. of Waterloo, Waterloo, Ontario, Canada, Canada
关键词
COMPUTER PROGRAMMING - Algorithms;
D O I
10.1145/42404.42410
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
Linear hashing and spiral storage are two dynamic hashing schemes originally designed for external files. This paper shows how to adapt these two methods for hash tables stored in main memory. The necessary data structures and algorithms are described, the expected performance is analyzed mathematically, and actual execution times are obtained and compared with alternative techniques. Linear hashing is found to be both faster and easier to implement than spiral storage. Two alternative techniques are considered: a simple unbalanced binary tree and double hashing with periodic rehashing into a larger table. The retrieval time of linear hashing is similar to double hashing and substantially faster than a binary tree, except for very small trees. The loading times of double hashing (with periodic reorganization), a binary tree, and linear hashing are similar. Overall, linear hashing is a simple and efficient technique for applications where the cardinality of the key set is not known in advance.
引用
收藏
页码:446 / 457
页数:12
相关论文
共 14 条
[1]  
CARTER JL, 1979, J COMPUT SYST SCI, V18, P143, DOI 10.1016/0022-0000(79)90044-8
[2]  
Fagin R., 1979, ACM Transactions on Database Systems, V4, P315, DOI 10.1145/320083.320092
[3]  
Knuth D. E., 1973, ART COMPUTER PROGRAM
[4]  
LARSON P, 1980, 6TH P C VER LARG DAT, P224
[5]  
Larson P.-A., 1978, BIT (Nordisk Tidskrift for Informationsbehandling), V18, P184, DOI 10.1007/BF01931695
[6]   LINEAR HASHING WITH OVERFLOW-HANDLING BY LINEAR PROBING [J].
LARSON, PA .
ACM TRANSACTIONS ON DATABASE SYSTEMS, 1985, 10 (01) :75-89
[7]   PERFORMANCE ANALYSIS OF LINEAR HASHING WITH PARTIAL EXPANSIONS [J].
LARSON, PA .
ACM TRANSACTIONS ON DATABASE SYSTEMS, 1982, 7 (04) :566-587
[8]  
LARSON PA, 1986, CS8621 U WAT TECHN R
[9]  
LITWIN W, 1980, 6TH P INT C VER LARG, P212
[10]  
MARTIN GNN, 1979, 27 U WARW THEOR COMP