Generate a graph from the Barabási–Albert (BA) model. We apply a layout after the graph is generated.