  We use inelastic hard sphere molecular dynamics simulations and laboratory
experiments to study patterns in vertically oscillated granular layers. The
simulations and experiments reveal that {\em phase bubbles} spontaneously
nucleate in the patterns when the container acceleration amplitude exceeds a
critical value, about $7g$, where the pattern is approximately hexagonal,
oscillating at one-fourth the driving frequency ($f/4$). A phase bubble is a
localized region that oscillates with a phase opposite (differing by $\pi$) to
that of the surrounding pattern; a localized phase shift is often called an
${\em arching}$ in studies of two-dimensional systems. The simulations show
that the formation of phase bubbles is triggered by undulation at the bottom of
the layer on a large length scale compared to the wavelength of the pattern.
Once formed, a phase bubble shrinks as if it had a surface tension, and
disappears in tens to hundreds of cycles. We find that there is an oscillatory
momentum transfer across a kink, and this shrinking is caused by a net
collisional momentum inward across the boundary enclosing the bubble. At
increasing acceleration amplitudes, the patterns evolve into randomly moving
labyrinthian kinks (spatiotemporal chaos). We observe in the simulations that
$f/3$ and $f/6$ subharmonic patterns emerge as primary instabilities, but that
they are unstable to the undulation of the layer. Our experiments confirm the
existence of transient $f/3$ and $f/6$ patterns.
