Abstract
For an ordered file of records with uniformly distributed key values, we examine an existing batched searching algorithm based on recursive use of interpolation searches. The algorithm, called Recursive Batched Interpolation Search (RBIS) in this paper, uses a divide-and-conquer technique for batched searching. The expected-case complexity of the algorithm is shown to beO(m loglog (2n/m) +m), wheren is the size of the file andm is the size of the query batch. Simulations are performed to demonstrate the savings of batched searching using RBIS. Also, simulations are performed to compare alternative batched searching algorithms which are based on either interpolation search or binary search. When the file's key values are uniformly distributed, the simulation results confirm that interpolation-search based algorithms are superior to binary-search based algorithms. However, when the file's key values are not uniformly distributed, a straight-forward batched interpolation search deteriorates quickly as the batch size increases, but algorithm RBIS still outperforms binary-search based algorithms when the batch size passes a threshold value.
Similar content being viewed by others
References
Armenakis, A. C., Garey, L. E., and Gupta, R. D.:An adaption of a root finding method to searching ordered disk files, BIT 25 (1985), 562–568.
Burton, F. W. and Lewis, G. N.:A robust variation of interpolation search, Inform. Process. Lett. 10(4, 5) (1980), 198–201.
Hardy, G. H., Littlewood, J. E., and Polya, G.:Inequalities, 2nd ed., Cambridge University Press, 1959.
Knuth, D. E.:The Art of Computer Programming, Vol. 3:Sorting and Searching, Addison-Wesley, Reading, Mass., 1973.
Lang, S. D.:Batched Interpolation Search, Research Report CS-89-09, University of Central Florida, Department of Computer Science, Orlando, Florida, USA (1989).
Lang, S. D. and Deo, N.Recursive batched binary searching of sequential files, to appear in The Computer Journal.
Lewis, G. N., Boynton, N. J., and Burton, F. W.:Expected complexity of fast search with uniformly distributed data, Inform. Process. Lett. 13 (1) (1981), 4–7.
Li, J.-Z. and Wong, H. K. T.:Batched interpolation searching on databases, Proc. 1987 IEEE Data Engineering Conference, Los Angeles (1987), 18–24.
Manolopoulos, Y., Kollias, J. G., and Hatzopoulos, M.:Sequential vs. binary batched searching, The Computer Journal 29 (4) (1986), 368–372.
Manolopoulos, Y., Kollias, J. G., and Burton, F. W.:Batched interpolation search, The Computer Journal 30 (6) (1987), 565–568.
Perl, Y., Itai, A., and Avni, H.:Interpolation search — a log log N search, Comm. ACM 21 (7), (1978), 550–553.
Santoro, N. and Sidney, J. B.:Interpolation — binary search, Inform. Process. Lett. 20 (4) (1985), 179–181.
Willard, D. E.:Searching unindexed and nonuniformly generated files in loglogN time, SIAM J. Comput. 14 (4) (1985), 1013–1029.
Yao, A. C. and Yao, F. F.:The complexity of searching ordered random table, Proc. 17th FOCS, Houston (1976), 173–176.
Author information
Authors and Affiliations
Rights and permissions
About this article
Cite this article
Lang, S.D. Analysis of recursive batched interpolation search. BIT 30, 42–50 (1990). https://doi.org/10.1007/BF01932130
Received:
Revised:
Issue Date:
DOI: https://doi.org/10.1007/BF01932130