  Background: Energetic quarks in nuclear DIS propagate through the nuclear
medium. Processes that are believed to occur inside nuclei include quark energy
loss through medium-stimulated gluon bremsstrahlung and intra-nuclear
interactions of forming hadrons. More data are required to gain a more complete
understanding of these effects. Purpose: To test the theoretical models of
parton transport and hadron formation, we compared their predictions for the
nuclear and kinematic dependence of pion production in nuclei. Methods: We have
measured charged-pion production in semi-inclusive DIS off D, C, Fe, and Pb
using the CLAS detector and the CEBAF 5.014 GeV electron beam. We report
results on the nuclear-to-deuterium multiplicity ratio for $\pi^{+}$ and
$\pi^{-}$ as a function of energy transfer, four-momentum transfer, and pion
energy fraction or transverse momentum - the first three-dimensional study of
its kind. Results: The $\pi^{+}$ multiplicity ratio is found to depend strongly
on the pion fractional energy $z$, and reaches minimum values of $0.67\pm0.03$,
$0.43\pm0.02$, and $0.27\pm0.01$ for the C, Fe, and Pb targets, respectively.
The $z$ dependences of the multiplicity ratios for $\pi^{+}$ and $\pi^{-}$ are
equal within uncertainties for C and Fe targets but show differences at the
level of 10$\%$ for the Pb-target data. The results are qualitatively described
by the GiBUU transport model, as well as with a model based on hadron
absorption, but are in tension with calculations based on nuclear fragmentation
functions. Conclusions: These precise results will strongly constrain the
kinematic and flavor dependence of nuclear effects in hadron production,
probing an unexplored kinematic region. They will help to reveal how the
nucleus reacts to a fast quark, thereby shedding light on its color structure,
transport properties, and on the mechanisms of the hadronization process.
