for G in graphs(8):
L = G.laplacian_matrix().eigenvalues()
L.sort()
show(L)
G.show()
Using this code I have been able to generate all graphs on 8 vertices. Now I need the connected graph with exactly two cycle (https://en.wikipedia.org/wiki/Cycle_(graph_theory)) whose algebraic connectivity (https://en.wikipedia.org/wiki/Algebraic_connectivity) is smallest among all connected graphs on 8 vertices which contains exactly two cycle. How we can solve this problem.