Removed some unused things in the simulation box and replaced the pointer to the geometry with a local copy to the necessary information to build the minimum box.