ladder_graph#

ladder_graph(n, create_using=None)[source]#

Returns the Ladder graph of length n.

This is two paths of n nodes, with each pair connected by a single edge.

Node labels are the integers 0 to 2*n - 1.

(Source code, png)

../../_images/networkx-generators-classic-ladder_graph-1.png

Additional backends implement this function

cugraph : GPU-accelerated backend.