The upcoming new generation of optical spectrographs on four-meter-class
telescopes will provide invaluable information for reconstructing the history
of star formation in individual galaxies up to redshifts of about 0.7. We aim
at defining simple but robust and meaningful physical parameters that can be
used to trace the coexistence of widely diverse stellar components: younger
stellar populations superimposed on the bulk of older ones. We produce spectra
of galaxies closely mimicking data from the forthcoming Stellar Populations at
intermediate redshifts Survey (StePS), a survey that uses the WEAVE
spectrograph on the William Herschel Telescope. First, we assess our ability to
reliably measure both ultraviolet and optical spectral indices in galaxies of
different spectral types for typically expected signal-to-noise levels. Then,
we analyze such mock spectra with a Bayesian approach, deriving the probability
density function of r- and u-band light-weighted ages as well as of their
difference. We find that the ultraviolet indices significantly narrow the
uncertainties in estimating the r- and u-band light-weighted ages and their
difference in individual galaxies. These diagnostics, robustly retrievable for
large galaxy samples even when observed at moderate signal-to-noise ratios,
allow us to identify secondary episodes of star formation up to an age of ~0.1
Gyr for stellar populations older than ~1.5 Gyr, pushing up to an age of ~1 Gyr
for stellar populations older than ~5 Gyr. The difference between r-band and
u-band light-weighted ages is shown to be a powerful diagnostic to characterize
and constrain extended star-formation histories and the presence of young
stellar populations on top of older ones. This parameter can be used to explore
the interplay between different galaxy star-formation histories and physical
parameters such as galaxy mass, size, morphology, and environment