Baeza-Yates, R. A.: A Fast Set Intersection Algorithm for Sorted Sequences.. In: Sahinalp, S. C.; Muthukrishnan, S. & Dogrusoz, U. (Hrsg.):

*Proceedings of the 15th Annual Symposium on Combinatorial Pattern Matching, CPM 2004*. 2004, S. 400-408

[Volltext] [Kurzfassung]
[BibTeX]
This paper introduces a simple intersection algorithm for two sorted sequences that is fast on average. It is related to the multiple searching problem and to merging. We present the worst and average case analysis, showing that in the former, the complexity nicely adapts to the smallest list size. In the later case, it performs less comparisons than the total number of elements on both inputs when n = agr m (agr > 1). Finally, we show its application to fast query processing in Web search engines, where large intersections, or differences, must be performed fast.