Elif Tosun
274b-ab
Spring 2000
CSC 274 Computational Geometry


Back to 274b-ab homepage

CGAL


SUMMARY OF THIS WEEK:

I've downloaded the library in the laptop. And finished the installation. The following is the summary of the 1st chapter of the documentary called "Getting Started with CGAL."


 

    1. OVERVIEW OF CGAL

Geometric Algorithms are used in many application domains such as computer graphics, robotics, geographic information systems, computer vision, etc.

It is not easy to implement these algorithms.

Therefore the computational geometry community itself started to develop a well-designed library: CGAL, Computations Geometry Algorithms Library.

It is developed by 7 different institutions:

 

It contains several different parts:

 

    1. The Elementary Part: -the Kernel
    2. Consists of primitive, constant size geometric objects, such as points, lines, spheres, etc. and predicates on them, such as orientation test for points, intersection tests, etc.

    3. Standard Library
    4. Contains standard geometric algorithms and data structures such as convex hull, smallest enclosing circle, and triangulation.

    5. Support Library
    6. Contains a support library, for example for I/O, visualization, and random generators.

       

      Currently the library contains mainly 2D or 3D objects but in the future it will support objects of arbitrary dimensions.

       

      CGAL is developed for different groups of users:

        • Researchers working on Computational Geometry who use the library to more easily implement and test their own algorithms.
        • Researchers with knowledge of computational geometry who want to use geometric algorithms in applications research areas.
        • Developers working in other research areas and companies who want to use CGAL in possibly commercial applications.

       

      To fulfill the demands of all these different users CGAL is based on a number of design goals such as robustness, generality, efficiency and ease of use.

       

        1. ROBUSTNESS
        2. In geometric algorithms, many decisions are based on geometric predicates. If these predicates are not computed exactly, the algorithm may easily give errors.

          In CGAL the following rule is used:

          "A correct result of an algorithm can only be guaranteed if geometric predicates are evaluated exactly."

          Because of this, in CGAL there is strong emphasis on the specification of algorithms. It is always clear for which inputs and for which number types a correct result is guaranteed.

           

        3. GENERALITY
        4. To make the library as general as possible, C++ templates are heavily used. This allows the user to choose an appropriate number type for doing computations. To some extent it is even possible to replace a CGAL data type with a user defined one.

           

        5. EFFICIENCY
        6. Such a CG library must be efficient to be really useful. Whenever possible the most efficient version of algorithm is used.

          Because a library algorithm cannot be the best solution for every application, so sometimes multiple versions of an algorithm are supplied.

        7. EASE OF USE

      The abundant uses of templates seem to make the library difficult to use for some people, but this can mostly be solved by using appropriate C++ typedefs. The algorithms in the library contain many pre and post condition checks that help a lot when debugging. To facilitate using CGAL with existing code, CGAL types and algorithms are placed in namespace CGAL_.