Layers( gamma, V )
Layers( gamma, V, G )
This function returns a list whose i-th element is the set of vertices of gamma at distance i-1 from V, which may be a vertex set or a singleton vertex.
The optional parameter G, if present, is assumed to be a subgroup of Aut(<gamma>) which fixes V setwise. Including such a G can speed up the function.
gap> Layers( JohnsonGraph(4,2), 6 ); [ [ 6 ], [ 2, 3, 4, 5 ], [ 1 ] ]
GAP 3.4.4