From galactic nuclei to the halo outskirts: tracing supermassive black
  holes across cosmic history and environments
  We study the mass assembly and spin evolution of supermassive black holes
(BHs) across cosmic time as well as the impact of gravitational recoil on the
population of nuclear and wandering black holes (wBHs) by using the
semi-analytical model LGalaxies run on top of Millennium merger trees. We track
spin changes that BHs experience during both coalescence events and gas
accretion phases. For the latter, we assume that spin changes are coupled with
the bulge assembly. This assumption leads to predictions for the median spin
values of z=0 BHs that depend on whether they are hosted by pseudobulges,
classical bulges or ellipticals, being a ~ 0.9, 0.7 and 0.4, respectively. The
outcomes of the model display a good consistency with z<4 quasar luminosity
functions and the z=0 BH mass function, spin values and black hole-bulge mass
correlation. Regarding the wBHs, we assume that they can originate from both
the disruption of satellite galaxies (orphan wBH) and ejections due to
gravitational recoils (ejected wBH). The model points to a number density of
wBHs that increases with decreasing redshift, although this population is
always ~2 dex smaller than the one of nuclear black holes. At all redshifts,
wBHs are typically hosted in M_{halo}>10^{13} M_{\odot} and M_{stellar}>10^{10}
M_{\odot}, being orphan wBHs the dominant type. Besides, independently of
redshift and halo mass, \textit{ejected} wBHs inhabit the central regions
(<0.3R_{200}) of the host DM halo, while orphan wBHs linger at larger scales
(>0.5R_{200}). Finally, we find that gravitational recoils cause a progressive
depletion of nuclear BHs with decreasing redshift and stellar mass. Moreover,
ejection events lead to changes in the predicted local black hole-bulge
relation, in particular for BHs in pseudobulges, for which the relation is
flattened at M_{bulge}>10^{10.2} M{\odot} and the scatter increase up to ~3dex.
