We examine the propagation of 2-dimensional relativistic jets through the
stellar progenitor in the collapsar model for gamma-ray bursts. In agreement
with previous studies, we find that relativistic jets are collimated by their
passage through the stellar mantle. Interaction of these jets with the star and
their own cocoons also causes mixing that sporadically decelerates the flow. We
speculate that this mixing instability is chiefly responsible for the variable
Lorentz factor needed in the internal shock model and for the complex light
curves seen in many GRBs. In all cases studied, the jet is shocked deep inside
the star following a brief period of adiabatic expansion. The jet that finally
emerges from the star thus has a moderate Lorentz factor, modulated by mixing,
and a very large internal energy. In a second series of calculations, we follow
the escape of that sort of jet. Because of the large ratio of internal to
kinetic energy in both the jet and its cocoon, the opening angle of the final
jet is significantly greater than at breakout. A small amount of material
emerges at large angles, but with a Lorentz factor still sufficiently large to
make a weak GRB. This leads us to propose a "unified model" in which a variety
of high energy transients, ranging from x-ray flashes to "classic" GRBs, may be
seen depending upon the angle at which a standard collapsar is observed. We
also speculate that the breakout of a relativistic jet and its collision with
the stellar wind will produce a brief transient with properties similar to the
class of "short-hard" GRBs. Implications of our calculations for GRB light
curves, the luminosity-variability relation, and the GRB-supernova association
are also discussed. (Abridged)Comment: 40 pages, 16 figures, To appear in vol. 586, ApJ, March 20, 200