  We analyze the dynamics of a homogeneous and isotropic universe in the
Einstein--Cartan theory of gravity. The spin of fermions produces spacetime
torsion that prevents gravitational singularities and replaces the big bang
with a nonsingular big bounce. We show that a closed universe exists only when
a particular function of its scale factor and temperature is higher than some
threshold value, whereas an open and a flat universes do not have such a
restriction. We also show that a bounce of the scale factor is double: as the
temperature increases and then decreases, the scale factor decreases,
increases, decreases, and then increases.
