Migrate code from domain.py so as much as possible is done in terms of the consecutive arrays. We can then destroy the Python objects after everything has been setup, in order to conserved memory. Tagged regions, edges etc should be done in terms of set-theory, so that each tag maps e.g. to a list of indices.