Speed up connectivity computation in extruded output

Rather than doing python loops over the whole mesh, build the
connectivity using some numpy primitives.  Reordering for quads is now
much simpler as well.