Algorithmic Solutions > LEDA > LEDA Guide > Graphs and Related Data Types > Associate Information with Graphs > Face Arrays

Face Arrays

The data type face_array<E> can be used to associate additional (LEDA and user defined) information of type E with the faces of a graph.

Example of how to use a face array for a graph

Strengths

  • more efficient access than with Face Maps
  • there can be an arbitrary number of Face Arrays for a graph
  • Face Arrays can be defined at any point in a program

Disadvantages

  • less efficient than Parameterized Graphs
  • only works well for static graphs: A new face will not have a corresponding entry in the Face Array (explicit init() is necessary)
  • cost of declaring a Face Array is proportional to the number of faces in the graph

Tips

  • Face Arrays are primarily useful for static graphs.

See also:

Parameterized Graphs

Face Maps


Associate Information with Graphs

Graphs and Related Data Types

Arrays


Manual Entries:

Manual Page Face Arrays

User Defined Parameter Types




Please send any suggestions, comments or questions to leda@algorithmic-solutions.com
© Copyright 2001-2003, Algorithmic Solutions Software GmbH