How to plot a sparse graph with small cycles ?

asked 2013-03-30 10:52:16 +0200

vdelecroix gravatar image


I have a sparse graph which have few cycles which moreover are small compared to the size of the graph. In other words, my graph looks like a tree. Is there a better way than the default to plot it ?

My graph is precisely the giant component of an random Erdös-Renyi graph with parameter just above 1 as in:

sage: G = graphs.RandomGNP(1000, 1.3 / 1000)
sage: cc = G.connected_components_subgraphs()
sage: giant_comp = cc[0]

On my computer, the default picture has a lot of overlaps:

sage: giant_comp.plot(vertex_labels=False, vertex_size=10)


edit retag flag offensive close merge delete