sagemath / sage

Main repository of SageMath
https://www.sagemath.org
Other
1.34k stars 452 forks source link

Generators for chessboard graphs: King, Queen, Knight, Bishop, Rooks #13306

Closed dcoudert closed 11 years ago

dcoudert commented 12 years ago

This patch implements generators for multi-dimensional chessboard graphs: Queen, King, Knight, Bishop, and Rook graphs. Variations of these graphs can be constructed changing the radius of the ball in which a chess piece can move.

These graphs are useful for testing graph coloring algorithms, hamiltonian cycles, etc.

In addition, this patch creates directory sage/graphs/generators/ to store new generators. The new functions of this patch are located in file sage/graphs/generators/chessboard.py. The functions are then included inside the GraphGenerators class and so accessible like graphs.QueenGraph(...).

APPLY:

Component: graph theory

Keywords: generator

Author: David Coudert

Reviewer: Sebastian Luther, Nathann Cohen

Merged: sage-5.5.beta0

Issue created by migration from https://trac.sagemath.org/ticket/13306