comfort-graph
Version 0.0.0.2 revision 0 uploaded by HenningThielemann.
Package meta
- Synopsis
- Graph structure with type parameters for nodes and edges
- Description
This graph structure is based on Data.Map and allows any Ord type for nodes and allows directed, undirected and more edge types. There is no need to map nodes to integer numbers. This makes handling in applications much more comfortable, thus the package name.
Currently the package does not contain any advanced algorithm, just the data structure and some manipulation functions.
The edge type can be freely chosen. This allows great flexibility but it is a bit more cumbersome to do in Haskell 98. Examples of edge types:
DirEdge
: Edges in a directed graphUndirEdge
: Edges in an undirected graphEitherEdge
: For graphs containing both directed and undirected edgesYou may define an edge type with an additional identifier in order to support multiple edges between the same pair of nodes.
Using type functions on the node type you may even define an edge type for nodes from a Cartesian product, where only "horizontal" and "vertical" edges are allowed.
For examples see the
linear-circuit
package and its tests. TheResistorCube
test demonstrates non-integer node types and theTree
test demonstrates multigraphs.The package is plain Haskell 98.
Related packages:
fgl
: standard package for graph processing with many graph algorithms but cumbersome data structure with Int numbered nodes
- Author
- Henning Thielemann
- Bug reports
- n/a
- Category
- Data
- Copyright
- n/a
- Homepage
- http://hub.darcs.net/thielema/comfort-graph
- Maintainer
- haskell@henning-thielemann.de
- Package URL
- n/a
- Stability
- n/a