Cache-Oblivious Red-Blue Line Segment Intersection

  • Lars Arge
  • Thomas Mølhave
  • Norbert Zeh
Part of the Lecture Notes in Computer Science book series (LNCS, volume 5193)


We present an optimal cache-oblivious algorithm for finding all intersections between a set of non-intersecting red segments and a set of non-intersecting blue segments in the plane. Our algorithm uses \(O(\frac{N}{B}\log_{M/B}\frac{N}{B}+T/B)\) memory transfers, where N is the total number of segments, M and B are the memory and block transfer sizes of any two consecutive levels of any multilevel memory hierarchy, and T is the number of intersections.


  1. 1.
    Aggarwal, A., Vitter, J.S.: The Input/Output complexity of sorting and related problems. Comm. ACM 31(9), 1116–1127 (1988)CrossRefMathSciNetGoogle Scholar
  2. 2.
    Arge, L.: External memory data structures. In: Abello, J., Pardalos, P.M., Resende, M.G.C. (eds.) Handbook of Massive Data Sets. Kluwer Academic Publishers, Dordrecht (2002)Google Scholar
  3. 3.
    Arge, L., Brodal, G.S., Fagerberg, R.: Cache-oblivious data structures. In: Mehta, D., Sahni, S. (eds.) Handbook on Data Structures and Applications. CRC Press, Boca Raton (2005)Google Scholar
  4. 4.
    Arge, L., Vengroff, D.E., Vitter, J.S.: External-memory algorithms for processing line segments in geographic information systems. Algorithmica 47, 1–25 (2007)MATHCrossRefMathSciNetGoogle Scholar
  5. 5.
    Bender, M.A., Cole, R., Raman, R.: Exponential structures for cache-oblivious algorithms. In: Widmayer, P., Triguero, F., Morales, R., Hennessy, M., Eidenbenz, S., Conejo, R. (eds.) ICALP 2002. LNCS, vol. 2380, pp. 195–207. Springer, Heidelberg (2002)CrossRefGoogle Scholar
  6. 6.
    Brodal, G.S., Fagerberg, R.: Cache oblivious distribution sweeping. In: Widmayer, P., Triguero, F., Morales, R., Hennessy, M., Eidenbenz, S., Conejo, R. (eds.) ICALP 2002. LNCS, vol. 2380, pp. 426–438. Springer, Heidelberg (2002)CrossRefGoogle Scholar
  7. 7.
    Chiang, Y.-J., Goodrich, M.T., Grove, E.F., Tamassia, R., Vengroff, D.E., Vitter, J.S.: External-memory graph algorithms. In: Proc. SODA, pp. 139–149 (1995)Google Scholar
  8. 8.
    Frigo, M., Leiserson, C.E., Prokop, H., Ramachandran, S.: Cache-oblivious algorithms. In: Proc. FOCS, pp. 285–298 (1999)Google Scholar
  9. 9.
    Goodrich, M.T., Tsay, J.-J., Vengroff, D.E., Vitter, J.S.: External-memory computational geometry. In: Proc. FOCS, pp. 714–723 (1993)Google Scholar
  10. 10.
    Vitter, J.S.: External memory algorithms and data structures: Dealing with MASSIVE data. ACM Comp. Surveys 33(2), 209–271 (2001)CrossRefGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2008

Authors and Affiliations

  • Lars Arge
    • 1
  • Thomas Mølhave
    • 1
  • Norbert Zeh
    • 2
  1. 1.MADALGO, Department of Computer ScienceUniversity of AarhusDenmark
  2. 2.Faculty of Computer ScienceDalhousie UniversityHalifaxCanada

Personalised recommendations