Force Gap to forget graph automorphism groups
I'm interested in computing and storing a huge number of graphs. For each graph I compute, I temporarily need to compute its automorphism group -- but I don't need to, and don't want to, remember that automorphism group. It looks like sage deals with graphs on its own but calls Gap to deal with automorphism groups.
The problem is that Gap, not sage, exceeds it permitted memory. Why? Here is a (silly) example of what I'm talking about: running
mylist=; count = 1; while True: g = graphs.RandomGNP(6, .5); aut = g.automorphism_group(); mylist.append(g); if aut.order() > 1: print "Graph number %s has nontrivial automorphisms!"%(count); count += 1;
gives me after some hours
RuntimeError: Gap produced error output Error, exceeded the permitted memory (`-o' command line option)
How can I force sage/gap to forget the automorphism groups attached to the graphs (but remember the graphs)? Ideally Gap should only need to store one automorphism group at a time.