An Adaptable and Extensible Geometry Kernel

  • Susan Hert
  • Michael Hoffmann
  • Lutz Kettner
  • Sylvain Pion
  • Michael Seel
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 2141)


Geometric algorithms are based on geometric objects such as points, lines and circles. The term Kernel refers to a collection of representations for constant-size geometric objects and operations on these representations. This paper describes how such a geometry kernel can be designed and implemented in C++, having special emphasis on adaptability, extensibility and efficiency. We achieve these goals following the generic programming paradigm and using templates as our tools. These ideas are realized and tested in CGAL [9], the Computational Geometry Algorithms Library.


Computational geometry library design generic programming 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Andrew, A. M. Another efficient algorithm for convex hulls in two dimensions. Inform. Process. Lett. 9,5 (1979), 216–219.MATHCrossRefGoogle Scholar
  2. 2.
    Austern, M. H.Generic Programming and the STL. Addison-Wesley, 1998.Google Scholar
  3. 3.
    Baker, J. E., Tamassia, R., AND Vismara, L. GeomLib: Algorithm engineering for a geometric computing library, 1997. (Preliminary report).Google Scholar
  4. 4.
    Barton, J. J., AND Nackman, L. R.Scientific and Engineering C++. Addison Wesley, Reading, MA, 1997.Google Scholar
  5. 5.
    Brönnimann, H., Burnikel, C., AND Pion, S. Interval arithmetic yields efficient dynamic filters for computational geometry. In Proc. 14th Annu. ACM Sympos. Comput. Geom. (1998), pp. 165–174.Google Scholar
  6. 6.
    Brönnimann, H., Kettner, L., Schirra, S., AND Veltkamp, R. Applications of the generic programming paradigm in the design of CGAL. In Generic Programming—Proceedings of a Dagstuhl Seminar (2000), M. Jazayeri, R. Loos, and D. Musser, Eds., LNCS 1766, Springer-Verlag.CrossRefGoogle Scholar
  7. 7.
    Burnikel, C., Mehlhorn, K., AND Schirra, S. The LEDA class real number. Technical Report MPI-I-96-1-001, Max-Planck Institut Inform., Saarbrücken, Germany, Jan. 1996.Google Scholar
  8. 8.
    International standard ISO/IEC 14882: Programming languages-C++. American National Standards Institute, 11 West 42nd Street, New York 10036, 1998.Google Scholar
  9. 9.
    CGAL, the Computational Geometry Algorithms Library.
  10. 10.
    Coplien, J. O. Curiously recurring template patterns. C++ Report (Feb. 1995), 24–27.Google Scholar
  11. 11.
    De Berg, M., VAN Kreveld, M., Overmars, M., AND Schwarzkopf, O.Computational Geometry: Algorithms and Applications. Springer-Verlag, Berlin, 1997.MATHGoogle Scholar
  12. 12.
    Fabri, A., Giezeman, G.-J., Kettner, L., Schirra, S., AND Schönherr, S. The CGAL kernel: A basis for geometric computation. In Proc. 1st ACM Workshop on Appl. Comput. Geom. (1996), M. C. Lin and D. Manocha, Eds., vol. 1148 of Lecture Notes Comput. Sci., Springer-Verlag, pp. 191–202.Google Scholar
  13. 13.
    Fabri, A., Giezeman, G.-J., Kettner, L., Schirra, S., AND Schönherr, S. On the design of CGAL, the computational geometry algorithms library. Software-Practice and Experience 30 (2000), 1167–1202.MATHCrossRefGoogle Scholar
  14. 14.
    Fortune, S., and Van Wyk, C. J. Static analysis yields efficient exact integer arithmetic for computational geometry. Acm Trans. Graph. 15, 3 (July 1996), 223–248.Google Scholar
  15. 15.
    Giezeman, G.-J.PlaGeo, a library for planar geometry, and SpaGeo, a library for spatial geometry. Utrecht University, 1994.Google Scholar
  16. 16.
    IEEE Standard for binary floating point arithmetic, ANSI/IEEE Std 754-1985. New York, NY, 1985. Reprinted in SIGPLAN Notices, 22(2):9–25, 1987.Google Scholar
  17. 17.
    Josuttis, N. M.The C++ Standard Library, A Tutorial and Reference. Addison-Wesley, 1999.Google Scholar
  18. 18.
    Karamcheti, V., Li, C., Pechtchanski, I., AND Yap, C.The CORE Library Project, 1.2 ed., 1999.
  19. 19.
    Kettner, L. Using generic programming for designing a data structure for polyhedral surfaces. Comput. Geom. Theory Appl. 13 (1999), 65–90.MATHGoogle Scholar
  20. 20.
    Mehlhorn, K., AND Näher, S.LEDA: A Platform for Combinatorial and Geometric Computing. Cambridge University Press, Cambridge, UK, 2000.Google Scholar
  21. 21.
    Musser, D. R., AND Stepanov, A. A. Generic programming. In 1st Intl. Joint Conf. of ISSAC-88 and AAEC-6 (1989), Springer LNCS 358, pp. 13–25.Google Scholar
  22. 22.
    Musser, D. R., AND Stepanov, A. A. Algorithm-oriented generic libraries. Software-Practice and Experience 24,7 (July 1994), 623–642.Google Scholar
  23. 23.
    Myers, N. C. Traits: A new and useful template technique. C++ Report (June 1995).
  24. 24.
    Schirra, S. A case study on the cost of geometric computing. In Proc. Workshop on Algorithm Engineering and Experimentation (1999), vol. 1619 of Lecture Notes Comput. Sci., Springer-Verlag, pp. 156–176.Google Scholar
  25. 25.
    Shewchuk, J. R. Adaptive precision floating-point arithmetic and fast robust geometric predicates. Discrete Comput. Geom. 18,3 (1997), 305–363.MATHCrossRefMathSciNetGoogle Scholar
  26. 26.
    Stroustrup, B.The C++ Programming Language, 3rd Edition. Addison-Wesley, 1997.Google Scholar
  27. 27.
    Veldhuizen, T. Techniques for scientific C++. Technical Report 542, Department of Computer Science, Indiana University, 2000.
  28. 28.
    Yap, C. K., AND Dubé, T. The exact computation paradigm. In Computing in Euclidean Geometry, D.-Z. Du and F. K. Hwang, Eds., 2nd ed., vol. 4 of Lecture Notes Series on Computing. World Scientific, Singapore, 1995, pp. 452–492.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2001

Authors and Affiliations

  • Susan Hert
    • 1
  • Michael Hoffmann
    • 2
  • Lutz Kettner
    • 3
  • Sylvain Pion
    • 4
  • Michael Seel
    • 1
  1. 1.Max-Planck-Institut für InformatikSaarbrückenGermany
  2. 2.Institute for Theoretical Computer ScienceETH ZurichZurichSwitzerland
  3. 3.University of North Carolina at Chapel HillUSA
  4. 4.INRIASophia AntipolisFrance

Personalised recommendations