Regular ring lattice#
 regular_ring_lattice[vert_type](size: int, degree: int) undirected_network[vert_type] #

template<integer_network_vertex VertT>
undirected_network<VertT> regular_ring_lattice(VertT size, VertT degree)#
Generates a regular ring lattice of size size
and degree degree
. A
ringlike structure that if arranged in a circle, each vertex would be connected
to \(degree/2\) vertices before and after it.
The parameter degree
needs to be an even number and degree
needs
to be smaller than size
, otherwise the function fails by raising a
ValueError
exception in Python or a std::invalid_argument
exception
in C++.