++ed by:

1 non-PAUSE user.

Kevin Ryde
and 1 contributors

# NAME

Graph::Maker::Kneser - create Kneser graphs

# SYNOPSIS

`````` use Graph::Maker::Kneser;
\$graph = Graph::Maker->new ('Kneser', N => 8, K => 3);``````

# DESCRIPTION

`Graph::Maker::Kneser` creates `Graph.pm` graphs of Kneser graphs. Each vertex is a K-many subset of the integers 1 to N. Edges are between vertices with all integers distinct. Vertex names are the list of integers separated by commas, such as "1,5,6,8".

K=1 is the complete-N graph. Vertex names are the same as `Graph::Maker::Complete` (integers 1 to N).

N=5,K=2 is the Petersen graph.

N=2*K-1 is the "odd" graph K.

K > N/2 has no edges since the K-many subsets are each more than half of 1..N so are never disjoint

# FUNCTIONS

`\$graph = Graph::Maker->new('Kneser', key => value, ...)`

The key/value parameters are

``````    N   =>  integer
K   =>  integer
graph_maker => subr(key=>value) constructor, default Graph->new``````

Other parameters are passed to the constructor, either `graph_maker` or `Graph->new()`.

If the graph is directed (the default) then edges are added both forward and backward between vertices. Option `undirected => 1` creates an undirected graph and for it there is a single edge between vertices.

# HOUSE OF GRAPHS

House of Graphs entries for the graphs here include

N=4, K=2, https://hog.grinvin.org/ViewGraphInfo.action?id=484
N=5, K=2, https://hog.grinvin.org/ViewGraphInfo.action?id=660 (Petersen, odd 3)
N=6, K=3, https://hog.grinvin.org/ViewGraphInfo.action?id=19271