First page Back Continue Last page Graphics
Rules based
Some problems present graphs that are too large to store in their entirety.
- Chess and Go are two such examples
Instead of storing actually edges we can store, code or otherwise implement rules that define what is connected to what.
- In chess we know that one board state is adjacent to another if we can move from one to other with a single, well defined, valid move.
Each graph node then is an object that contains:
- A reference to a object that contains the label, state or information for the node.
- A linked list of references to other nodes (these are the edges.
In any case it is important to choose your implementation wisely on the basis of the project and goal’s requirements and your available resources.