\section{Introduction}
The presence of interstellar dust plays an important role in various physical and chemical processes that contribute to galactic evolution \citep{Dwek1998, Draine2011}. However, the composition and origin of dust grains in distant galaxies are not yet well understood.
The properties of dust have been studied more extensively in the Milky Way, the Small Magellanic Cloud (SMC) and the Large Magellanic Cloud (LMC) \citep{Fitzpatrick&Massa1986ApJ, Pei1992, Gordon2003}. Characterizing dust at high redshift is more challenging, but crucial for improving our understanding of the early Universe \citep{Watson2015}. Recent observational constrains on the dust properties at early stages of chemical evolution are fundamental for complementing existing models of dust production and evolution \citep{Calura2008, Zhukovska2008, Arrigoni2010, Triani2020}. 

Absorption-line spectroscopy, among the various observational techniques, has proven to be the most powerful tool in determining the composition of the interstellar medium (ISM) of a galaxy \citep{Prochaska1999, Savage1996}. It provides measurements of the column densities of different ions in the gas phase, from which the chemical abundances in the ISM of a galaxy can be determined. However, part of the metals are incorporated into dust grains, an effect called dust depletion, altering the gas-phase relative abundances and challenging the comprehensive study of the ISM \citep{Field1974, Savage1996, Savaglio2003, Jenkins2009, DeCia2016, Roman-Duval2021}. It is therefore crucial to have a thorough understanding of the depletion of metals from the Local Group to high redshifts to be able to enhance our knowledge on the origin of cosmic dust and its composition \citep{Mattsson2019}.

In the Local Group, UV and optical absorption-line spectroscopy towards background stars can provide a detailed insight into the metal abundances of the elements in the ISM \citep{Field1974, York1983,Savage1996,Jenkins2017,Roman-Duval2021}. For distant galaxies, Damped Lyman-$\alpha$ absorbers (DLAs, defined by log~N$(\ion{H}{i})$ $\geq$ 20.3~cm$^{-2}$, e.g. \citet{Wolfe2005}) towards bright background sources such as quasars (QSOs) and gamma-ray bursts (GRBs) are studied in absorption. DLAs predominantly trace galaxies at the low-mass end of the distribution \citep{Ledoux2006, Christensen2014} and studying them is contributing to our understanding of dust depletion, nucleosynthesis, metallicity and molecular content across cosmic time \citep{Prochaska1999, Ledoux2002, Vladilo2002, Prochaska2007, Petitjean2008, Kulkarni2015, DeCia2018, Bolmer2019, Heintz2019a, Heintz2019b}. DLAs remain the best means to estimating elemental abundances in distant galaxies, allowing access to the study of elements in a wide range of environments and physical conditions, regardless of the luminosity of the absorbing galaxy.

DLAs are the largest reservoirs of \ion{H}{i} in the Universe and carry the majority of metals at high-z \citep{Peroux2020}. Among the elements that can be observed in absorption, singly ionized titanium (\ion{Ti}{ii}) is unique. While Ti is an $\alpha$-element it is also highly refractory, and thus heavily depleted into dust grains, much more than even iron (e.g. \citet{Jenkins2009, Ledoux2002}). This gives a special perspective, since Ti can be a tracer of dust but also a tracer of $\alpha$-element enhancement. Titanium is dominant in $\ion{H}{i}$-dominated gas, with negligible contribution from ionized $\ion{H}{ii}$ gas, since its ionization potential is almost equal to that of neutral hydrogen \citep{Viegas1995}. Most of the Ti in the Galactic ISM appears to be depleted into dust grains \citep{Jenkins2009}, however much less is known about Ti depletion in lower metallicity systems, like those found among QSO-DLAs. By constraining Ti at high redshifts we can better understand the chemistry of the gas and the properties of dust in these galaxies. 

\citet{Jenkins2009} used abundances of several elements in Milky Way stars to estimate the overall dust depletion in each line of sight. However, the main assumption of this method is that the metallicity of the gas is solar. This assumption cannot be made for DLAs, because the gas metallicity in these systems can vary and can be significantly lower \citep{Pettini1994}. In addition, \citet{DeCia2021} showed that the ISM metallicity in galaxies is not necessarily uniform.
Instead, \citet{DeCia2016} have characterized the dust depletion of several metals in QSO-DLAs and the Milky Way, without making any assumption on the gas metallicity. In this paper we expand this study and add more elements to the current dust depletion scheme. We study the depletion properties of C, P, O, Cl, Kr, S, Ge, Mg, Si, Cu, Co, Mn, Cr, Ni, Al, Ti, Zn and Fe using the \citet{DeCia2016} formalism, which is based on the observations of relative abundances, in different environments, from the Local Group to distant galaxies. In Section 2 we present the samples that we use for our analysis. In Section 3 we describe the methodology to estimate the dust depletions. We discuss our results in Section 4, and finally summarize and conclude in Section 5.

Throughout the paper we use a linear unit for the column densities N in terms of ions cm$^{-2}$. We refer to relative abundances of elements X and Y as $[X/Y] \equiv$ log$\frac{N(X)}{N(Y)}  -$ log$\frac{N(X)_{\odot}}{N(Y)_{\odot}}$, where reference solar abundances are reported in Table \ref{solabund}. We report 1\,$\sigma$ and 3\,$\sigma$ significance levels for the errors and limits, respectively.

\begin{table}[!h]
\caption{The adopted solar abundances.}
\centering
\begin{tabular}{c c c c}
\hline\hline 
Element & 12 + log(X/H)$_{\odot}$ $^{\rm a}$ & Source $^{\rm b}$\\
\hline
C  & 8.43 & s \\
P & 5.42 & a \\
O  & 8.69 & s \\
Cl & 5.23 & m \\
Kr & 3.12 & t \\
S  & 7.135 & a \\
Zn & 4.61 & m \\
Ge & 3.60 & a \\
Mg & 7.54 & a \\
Si & 7.51 & m \\
Cu & 4.25 & m \\
Co & 4.91 & a \\
Mn & 5.47 & m \\
Cr & 5.63 & a \\
Ni & 6.20 & a \\
Fe & 7.46 & a \\
Al & 6.43 & a \\
Ti & 4.90 & m \\
\hline
\label{solabund}
\end{tabular}
\vspace{-3mm}
\flushleft
{\footnotesize \textbf{Notes:}$^{\rm a}$ Reference solar abundances are adopted from \citet{Asplund2021}. $^{\rm b}$Photospheric (s), meteoritic (m) or average (a) abundances are used based on the recommendations from \citet{Lodders2009}.}
\end{table}

\section{Samples}
\label{sec:samples}
The full sample in this work consists of new column density measurements of QSO-DLAs as well as literature measurements of column densities in the neutral ISM in different galaxies: the Milky Way, the Magellanic Clouds, QSO- and GRB-DLAs.
We use the QSO-DLA sample of \citet{DeCia2016} to make new measurements of Ti and Ni column densities, whenever possible. We only consider systems observed with high spectral resolution (R = 35000-58000), when measuring Ti and Ni column densities. For the Milky Way we use ISM abundances from \citet{Jenkins2009, DeCia2021, Welty2010} and \citet{Phillips1982}. For the LMC we use \citet{Roman-Duval2021}, for the SMC \citet{Welty2010, Tchernyshyov2015, Jenkins2017}, abundances of QSO-DLAs from \citet{Berg2015, DeCia2018} and DLAs towards GRBs from \citet{Bolmer2019}. 

Our sample probes gas in different regions of galaxies spanning a diversity of galaxy types and properties. GRB-DLAs select gas-rich galaxies, like QSO-DLAs, but with active star formation and preferentially piercing through inner parts of these galaxies, while QSO-DLAs can be more peripheral (e.g. \citet{Prochaska2007,Fynbo2008}. The Milky Way and Magellanic Clouds samples are also observations through the inner parts of galaxies. The Magellanic Clouds are in a different phase of their star formation history, with recent bursts of star formation \citep{HarrisZari2009, Indu2011, Crowther2016,Joshi2019, Bestenlehner2020, Hasselquist2021}, probably due to the proximity to the Milky Way and close encounters between the two Magellanic Clouds.

We collect measurements of 18 elements (C, P, O, Cl, Kr, S, Ge, Mg, Si, Cu, Co, Mn, Cr, Ni, Al, Ti, Zn and Fe) from all the samples in order to characterize the dust depletion through the estimation of the relative abundances \citep{DeCia2016, Jenkins2017} of those elements. The different literature samples use different values for the oscillator strengths of the different ions. We homogenize by correcting the column densities to the newest possible oscillator strengths for all the samples. We adopted the oscillator strengths from \citet{Cashman2017} for \ion{Kr}{i}, \ion{Mg}{ii}, \ion{Si}{ii}, \ion{Cu}{ii}, \ion{Co}{ii}, \ion{Mn}{ii}, \ion{Cr}{ii}, \ion{Al}{ii} and \ion{Ti}{ii}, from \citet{Boisse2019} for \ion{Ni}{ii}, from \citet{Kisielius2015Zn} for \ion{Zn}{ii}, from \citet{Kisielius2014S} for \ion{S}{ii} and from \citet{Kurucz2017} for P. For the other metals, if there is no recent change to the oscillator strength, the value from \citet{Morton2003} is used.

\subsection{QSO- and GRB-DLAs}

The QSO-DLA sample is a compilation of new column density measurements and literature measurements \citep{DeCia2018, Noterdaeme2010, Ma2015, Fynbo2017, Noterdaeme2017}. The new QSO-DLA column density measurements are done using a large sample of 70 QSO-DLAs observed at high spectral resolution with the Very Large Telescope (VLT) Ultraviolet and Visual Echelle Spectrograph (UVES) from \citet{DeCia2016}. The procedure that we followed is described in Section \ref{sec:uves_sample}. Additionally, we use the constrained pre-existing measurements of those QSO-DLAs to study the depletion of O, S, Si, Mg, Mn and Cr. The literature sample includes a large QSO-DLA and one GRB-DLA sample. The main QSO-DLA sample is from \citet{DeCia2018}. This contains a QSO-DLA sample observed with UVES from \citet{DeCia2016}, a large QSO-DLA sample from \citet{Berg2015} and a few metal-rich QSO-DLAs from \citet{Ma2015, Fynbo2017, Noterdaeme2010} and \citet{Noterdaeme2017}. The \citet{Berg2015} catalogue includes 395 QSO-DLAs, 44 of which are selected from the \citet{Herbert-Fort2006} catalogue as metal-rich systems and the rest are a literature compilation of column densities of all QSO-DLAs published between 1994 and 2014, with medium/high resolution requirement (R~\textgreater~10\,000). From the full QSO-DLA sample 237 systems have both Zn and Fe constrained measurements. 

Finally, we use a sample of 22 GRB-DLAs at redshifts z > 2 observed with VLT/X-Shooter with medium resolution (R~$\sim$~10\,000) from \citet{Bolmer2019}, of which nine have both Zn and Fe constrained measurements. Our final QSO-DLA sample consists of 139 systems, of which 15 literature  and 13 new measurements are used to constrain the Ti depletion, 73 literature and 23 new measurements are used to constrain the Ni depletion and the rest of the systems are used for the other elements.

\subsection{The Milky Way and the Magellanic Clouds}

We include a sample of ISM metal column densities from the Milky Way, the LMC and the SMC.
The Milky Way sample includes a compilation of elemental abundances from 243 lines of sight in the Milky Way \citep{Jenkins2009}, 25 bright O and B stars observed with the Hubble Space Telescope (HST) Space Telescope Imaging Spectrograph (STIS) with a resolving power of R~$\sim$~30\,000 \citep{DeCia2021} and Al measurements from \citet{Phillips1982}. The SMC sample is composed of elemental abundances towards 19 lines of sight from \citet{Welty2010, Tchernyshyov2015, Jenkins2017}. The LMC sample counts 32 abundances of massive stars observed with HST/STIS from \citet{Roman-Duval2021}. From those, 39 galactic, 16 SMC and 31 LMC lines of sight have Zn and Fe constrained measurements.

\begin{table}[!h]
\caption{Number of Ti and Ni measurements for the Milky Way, QSO-DLAs, the LMC, SMC and GRB-DLAs. References: ($\star$) This work; (1) \citet{Berg2015} ;(2) \citet{Jenkins2009}; (3) \citet{DeCia2021}; (4) \citet{Welty2010}; (5) \citet{Tchernyshyov2015}; (6) \citet{Jenkins2017}; (7) \citet{Roman-Duval2021}; (8) \citet{Bolmer2019}.}
\centering
\begin{tabular}{c c c c}
\hline\hline 
Environments & Ti & Ni & References\\
\hline
Milky Way & 31  & 23 & (2), (3)\\
DLAs & 28 & 98 & ($\star$), (1) \\
LMC & 10 & 29 & (7) \\
SMC & 13 & 12 & (4), (5), (6) \\
GRBs & 1 & 8 & (8) \\
\hline
\label{numberofmeasurements}
\end{tabular}
\end{table}

\section{Methods and Results}
\label{sec:results}

\subsection{New column density measurements - Voigt-profile fitting}
\label{sec:uves_sample}

We determine the column densities of Ti and Ni in QSO-DLAs spectra from UVES/VLT using the Voigt-profile fit method, which decomposes the line profiles in their individual velocity components and fits all transitions simultaneously. Using the Python package VoigtFit\footnote{\url{https://github.com/jkrogager/VoigtFit}} \citep{Krogager2018} we model \ion{Ti}{ii} ($\lambda$1910 $\AA$, $\lambda$3067 $\AA$, $\lambda$3073 $\AA$, $\lambda$3230 $\AA$, $\lambda$3242 $\AA$, $\lambda$3384 $\AA$) and \ion{Ni}{ii} lines ($\lambda$1317 $\AA$, $\lambda$1370 $\AA$, $\lambda$1741 $\AA$), whenever covered by the UVES spectra. To better constrain the fit, we also model transitions of \ion{Fe}{ii}, \ion{Si}{ii} and \ion{Cr}{ii}. In some cases we include \ion{Zn}{ii}, \ion{S}{ii}, \ion{Mn}{ii}, \ion{Mg}{ii} and \ion{P}{ii}. All the velocity profiles of the modelled transitions are shown in Appendix \ref{appsec: fits}.

We adopt the individual velocity components, namely the redshift z and the broadening parameter b, listed in Table F.1 of \citet{DeCia2016}, using as reference \ion{Fe}{ii}. We visually inspect the \ion{Fe}{ii} lines and in the cases where they look saturated we use \ion{Si}{ii} instead. In the cases of Q0347-383, Q0528-250a, Q0528-250b, Q0551-366, Q0841+129c, Q2138-444b and Q2231-002 we add extra components that we identify in the line profile. For Q0102-190a and Q0841+129a, in addition to \ion{Ti}{ii} and \ion{Ni}{ii}, we measure \ion{Zn}{ii} using the transitions $\lambda$2026 $\AA$ and $\lambda$2062 $\AA$ respectively.
The contaminating features are masked out and the continuum level is automatically placed using Chebyshev polynomials. Contaminated lines can bias the  continuum placement and the resulting fit. When needed, the interactive masking is repeated until the fit is reasonable. Due to the high column density of neutral hydrogen in QSO-DLAs, which shields metals against higher ionizations, no ionization corrections are needed to derive the metal abundances. We adopted the newest oscillator strengths from \citet{Cashman2017} for \ion{Ti}{ii}, from \citet{Boisse2019} for \ion{Ni}{ii} and from \citet{Kisielius2015Zn} for \ion{Zn}{ii}. For \ion{Fe}{ii} there is no recent change to the oscillator strength, so the value from \citet{Morton2003} is used.

If there is no detection for \ion{Ti}{ii} or \ion{Ni}{ii}  we estimate the 3$\sigma$ upper limits, given that the lines are not too contaminated and using as reference the line profile of a well constrained transition (\ion{Fe}{ii} or \ion{Si}{ii}). The reference is used to determine the limits of the line profile containing 99$\%$ of the optical depth, within which the upper limit is calculated. 

For some ions (in systems Q0405-443c, Q1117-134 and Q1223+178) the fit does not converge properly although there is a detection. To constrain the fit, in such cases, we fix the line profile, using redshifts z and b-values from a fit of another previously well constrained ion (for example \ion{Fe}{ii} or \ion{Si}{ii}).

The total number of Ti and Ni measurements from all the samples that are used in this paper are summarized in Table \ref{numberofmeasurements}.
The total column densities as well as the upper limits are reported in Table \ref{uvestab}. Out of the 70 QSO-DLAs that were studied we could get a constrained measurement of \ion{Ti}{ii} from only 13 systems, while 18 limits were estimated. \ion{Ni}{ii} was measured in 23 systems and 7 limits were estimated. Combining these to the QSO-DLA literature sample we have in total 28 Ti and 98 Ni constrained measurements.

The velocity profiles of all the \ion{Ti}{ii} and \ion{Ni}{ii} transitions modeled are shown in Appendix \ref{appsec: fits}. The total column densities are used for characterizing the depletion of Ti and Ni with the relative method and are reported in Table \ref{dlastable}.

\begin{table}[!h]
\caption{New UVES QSO-DLA Ti and Ni measurements}
\centering
\small
\setlength\tabcolsep{1pt}
\begin{tabular}{l c c c c c}
\hline\hline 
QSO & $z_{\rm abs}$ & log N(\ion{Fe}{II})&log N(\ion{Zn}{II})&log N(\ion{Ni}{II})&log N(\ion{Ti}{II})\\\hline
Q0010-002  & 2.02484 & 15.18$\pm$0.04 & 12.09$\pm$0.04 & 13.69$\pm$0.03    & \textless{12.38}    \\
Q0058-292  & 2.67142 & 14.75$\pm$0.02 & 12.14$\pm$0.02 & 13.55$\pm$0.08    & 12.30$\pm$0.11      \\
Q0100+130  & 2.30903 & 15.05$\pm$0.02 & 12.34$\pm$0.01 & ... & 12.72$\pm$0.11      \\
Q0102-190a & 2.36966 & 14.44$\pm$0.02 & 11.61$\pm$0.08 & 13.16$\pm$0.07    & 12.20$\pm$0.12      \\
Q0216+080a & 1.76873 & 14.47$\pm$0.02 & 11.87$\pm$0.06 & \textless{13.08}  & \textless{12.22}    \\
Q0347-383  & 3.02485 & 14.35$\pm$0.02 & 12.13$\pm$0.05 & \textless{13.70} & \textless{11.92}    \\
Q0405-443a & 1.91267 & 15.16$\pm$0.02 & 12.34$\pm$0.03 & 13.87$\pm$0.01    & 12.48$\pm$0.02      \\
Q0405-443b & 2.55000 & 15.05$\pm$0.01 & 12.36$\pm$0.04 & 13.76$\pm$0.01    & \textless{12.22}    \\
Q0405-443c & 2.59466 & 15.08$\pm$0.02 & 12.50$\pm$0.01 & 13.80$\pm$0.01    & 12.55$\pm$0.05      \\
Q0458-020  & 2.03956 & 15.33$\pm$0.05 & 13.05$\pm$0.02 & 14.06$\pm$0.03    & \textless{12.72}   \\
Q0528-250a & 2.14105 & 14.78$\pm$0.02 & 12.19$\pm$0.03 & 13.65$\pm$0.01    & 12.62$\pm$0.07      \\
Q0528-250b & 2.81111 & 15.48$\pm$0.01 & 13.01$\pm$0.01 & 14.29$\pm$0.01    & 12.76$\pm$0.06      \\
Q0551-366  & 1.96221 & 15.05$\pm$0.03 & 12.92$\pm$0.03 & 14.09$\pm$0.01    & \textless{12.56}    \\
Q0841+129a & 1.86384 & 14.89$\pm$0.04 & 11.94$\pm$0.11 & 13.60$\pm$0.02    & 12.38$\pm$0.05      \\
Q0841+129b & 2.37452 & 14.72$\pm$0.02 & 12.03$\pm$0.02 & 13.55$\pm$0.01    & \textless{13.06}    \\
Q0841+129c & 2.47622 & 14.48$\pm$0.02 & 11.77$\pm$0.03 & 13.30$\pm$0.02    & \textless{11.94}    \\
Q1111-152  & 3.26552 & 14.82$\pm$0.02 & 12.22$\pm$0.09 & 13.56$\pm$0.01    & ...\\
Q1117-134  & 3.35046 & 14.82$\pm$0.03 & 12.11$\pm$0.05 & \textless{13.53}  & 12.49$\pm$0.05      \\
Q1157+014  & 1.94349 & 15.47$\pm$0.01 & 12.93$\pm$0.01 & 14.19$\pm$0.01    & 12.99$\pm$0.01      \\
Q1209+093  & 2.58437 & 15.36$\pm$0.02 & 12.96$\pm$0.02 & 14.16$\pm$0.04    & \textless{12.60}    \\
Q1223+178  & 2.46607 & 15.21$\pm$0.01 & 12.34$\pm$0.02 & 13.86$\pm$0.05    & 12.73$\pm$0.06      \\
Q1331+170  & 1.77635 & 14.62$\pm$0.02 & 12.44$\pm$0.03 & 13.41$\pm$0.02    & \textless{11.95}    \\
Q1409+095a & 2.01881 & 14.34$\pm$0.02 & 11.60$\pm$0.13 & 13.15$\pm$0.08    & \textless{12.88}    \\
Q1444+014  & 2.08679 & 13.99$\pm$0.03 & 12.02$\pm$0.06 & \textless{12.81}  & \textless{12.43}    \\
Q1451+123a & 2.25466 & 14.42$\pm$0.05 & 11.85$\pm$0.11 & \textless{13.60}  & \textless{12.97}    \\
Q2116-358  & 1.99615 & 14.72$\pm$0.05 & 12.33$\pm$0.08 & 13.61$\pm$0.02    & \textless{12.43}    \\
Q2138-444a & 2.38279 & 14.54$\pm$0.01 & 12.02$\pm$0.08 & \textless{12.90}   & \textless{12.64}    \\
Q2138-444b & 2.85234 & 14.63$\pm$0.02 & 11.81$\pm$0.02 & 13.33$\pm$0.02    & \textless{11.83}    \\
Q2206-199a & 1.92061 & 15.34$\pm$0.01 & 12.70$\pm$0.01 & 14.16$\pm$0.02    & 12.86$\pm$0.02      \\
Q2243-605  & 2.33062 & 14.95$\pm$0.01 & 12.38$\pm$0.02 & 13.83$\pm$0.02    & 12.64$\pm$0.03      \\
Q2332-094a & 2.28749 & 14.23$\pm$0.03 & 12.31$\pm$0.02 & 13.25$\pm$0.04    & ...         \\
Q2343+125  & 2.43123 & 14.51$\pm$0.02 & 12.05$\pm$0.02 & 13.36$\pm$0.03    & \textless{11.97} \\
Q2359-022a & 2.09510  & 14.47$\pm$0.01 & 12.38$\pm$0.08 & \textless{13.59}  & \textless{12.51}   \\
\hline
\label{uvestab}
\end{tabular}
\vspace{-3mm}
\flushleft
{\footnotesize \textbf{Notes:} Upper limits are given at the 3$\sigma$ confidence level. The redshifts and the column densities for Fe and Zn are taken from \citet{DeCia2016}, except for Q0102-190a and Q0841+129a for which we make new Zn measurements.}
\end{table}

\subsection{Estimating the dust depletions}

Metals are missing from the observable gas-phase, and are instead depleted into dust grains. The depletion of an element X, $\delta_{x}$, is defined as
\begin{equation}
    \delta_{X} = [X/H]_{\rm{gas}} - [X/H]_{\mathrm{tot}},
    \label{deltax1}
\end{equation}
where [X/H]$_{\rm{gas}}$ are the observed gas-phase abundances and [X/H]$_{\mathrm{tot}}$ the total (gas + dust) abundances. \citet{DeCia2016} showed that the depletion of an element X can be purely estimated from some relative abundances. In general, the relative abundance of an element X with respect to another element Y ([X/Y]) is more sensitive to the depletion of X, if Y is a volatile element. Thus, the depletion of X can be derived from the observed [X/Zn], after correcting for the mild depletion of Zn, which we discuss below. The depletion of various metals X correlate with the overall strength of the depletion, or dust tracer, e.g. [Zn/Fe], and these correlations are referred to as 'depletion sequences' \citep{DeCia2016}.

To derive the depletion of X from the observed [X/Zn], we assume a depletion of Zn, $\delta_{\rm{Zn}}$ = -0.27 $\times$ [Zn/Fe], as derived from the Milky Way and QSO-DLAs by \citet{DeCia2016}. We also correct for $\alpha$-element enhancement and Mn underabundance, which is further discussed in the next section.
Taking these assumptions into account, $\delta_{X}$ is then derived as
\begin{equation}
    \delta_X = \mathrm{[X/Zn]} + \delta_{Zn} - \alpha_{X},
    \label{deltax}
\end{equation}
where $\alpha_{\rm{X}}$ is the intrinsic [X/Fe]$_{\rm{nucl}}$ due to stellar nucleosynthesis, for example $\alpha$-element enhancement or Mn underabundance.

A good dust tracer can be any relative abundance of two elements ([X/Y]) that have very different refractory properties (i.e. they deplete very differently), yet they follow each other in nucleosynthesis. In this paper, we use [Zn/Fe] as a dust tracer (but other relative abundances such as [Si/Ti] or [O/Si] can be used). [Zn/Fe] is the ratio of two elements with very different degrees of incorporation into dust grains, with Zn being a volatile element and Fe a refractory element. [Zn/Fe] is also called the "depletion factor" and is often used as a tracer of the overall dust depletion in QSO-DLAs \citep{Noterdaeme2008}. Zn and Fe trace each other \citep{Timmes1995} in the metallicity range considered here (-2 $\leq$ [M/H] $\leq$ 0). Indeed, stellar measurements show that [Zn/Fe]~$\sim$~0 in the metallicity range  -2 $\leq$ [M/H] $\leq$ 0 (e.g. \citet{Saito2009, Barbuy2015}, which is appropriate for most QSO-DLAs \citep{DeCia2018}. Outside this metallicity range, [Zn/Fe] appears to be super-solar in metal-poor halo stars \citep{Primas2000,Nissen2004,Nissen2007} and sub-solar in the bulge \citep{Barbuy2015}. Moreover, [Zn/Fe] correlates well with [Si/Ti] (see Fig. A.1. of \citet{DeCia2016}). Si and Ti follow each other nucleosynthetically, and if Zn would not trace Fe then we would see a deviation from the linear relation, but this is not observed. More details on the reliability of [Zn/Fe] as a dust tracer can be found in \citet{DeCia2018}.

\subsection{Corrections for $\alpha$-element enhancement and Mn underabundance}
\label{nucl_corr}

The depletion $\delta_{X}$ is by definition a negative value (eq. \ref{deltax1}). Figure \ref{fig:RelAbund} shows the observed gas-phase relative abundances [X/Zn] against [Zn/Fe], before any dust or $\alpha$-element enhancement corrections. In Fig. \ref{fig:RelAbund} it is evident that, at the offsets of [X/Zn] with [Zn/Fe] = 0 for some elements, [X/Zn] is positive. This is due to an enhancement of the $\alpha$-elements observed in the gas-phase, as a result of the chemical enrichment of the ISM by supernovae. Core-collapse supernovae produce large amounts of the $\alpha$-elements, such as O, Si, S, Mg and Ti, with only a smaller production of Fe-peak elements \citep{Nomoto2006}, which results in an observed overabundance of the $\alpha$-elements with respect to Fe ([$\alpha$/Fe]). On the other hand, Type~Ia supernovae produce mostly the Fe-peak elements and a smaller amount of $\alpha$-elements leading to a linear decrease of [$\alpha$/Fe] until [$\alpha$/Fe] $\sim$ 0. Mn is mostly produced by Type~Ia supernovae, leading to a Mn underabundance compared to Fe before the contribution of SNe~Ia becomes important \citep{Nomoto1997}. We refer to these effects as nucleosynthesis effects, because they are the product of explosive nucleosynthesis in stars enriching the ISM with metals.

We apply corrections to account for effects such as $\alpha$-element enhancement and Mn underabundance. For that we adopt the shapes of the nucleosynthetic curves from \citet{DeCia2016} (see their Fig. 7). In particular, we assume that at lower metallicities - and low [Zn/Fe] there is an $\alpha$-element enhancement and Mn underabundance ($\alpha_{\rm{X},0}$), while at higher metallicities - and large [Zn/Fe] there is a plateau at $\alpha_{\rm{X},0}$ = 0.05. In between, $\alpha_{\rm{X},0}$ decreases linearly with [Zn/Fe]. The shapes of the curves are consistent with the nucleosynthetic patterns observed in the Galaxy (see \citet{Lambert1987, McWilliam1997} for O, Si, Mg and S in galactic stars and in \citet{Wheeler1989, Mishenina2015} and \citet{Battistini2015} for Mn). The values of $\alpha_{\rm{X},0}$ are obtained by the intercepts of the relative abundances [X/Zn] at [Zn/Fe] = 0. Those are $\alpha_{\mathrm{O},0}$ = 0.38 $\pm$ 0.10, $\alpha_{\mathrm{S},0}$ = 0.25 $\pm$ 0.03, $\alpha_{\mathrm{Si},0}$ = 0.26 $\pm$ 0.03, $\alpha_{\mathrm{Mg},0}$ = 0.30 $\pm$ 0.04, $\alpha_{\mathrm{Mn},0}$ = -0.39 $\pm$ 0.03. For Ti we use $\alpha_{\mathrm{Ti},0}$ = 0.29 $\pm$ 0.08, estimated in \citet{McWilliam1997} for the Galaxy, which is identical to the intercept of [Ti/Zn] with [Zn/Fe] = 0 that we measure, $\alpha_{\mathrm{Ti},0}$ = 0.29 $\pm$ 0.03

While the plateau and the overall shape of the $\alpha$-element enhancement and Mn underabundance distribution with metallicity is rather well constrained, the position of the knee (the metallicity where $\alpha_{\rm{X},0}$ starts decreasing) is unknown for QSO-DLAs, and we may expect it at lower metallicities \citep{deBoer2014} because we expect QSO-DLA galaxies to have overall lower stellar masses \citep{Christensen2014, Krogager2017}. For the LMC, the $\alpha$-element knee is not well constrained and could be at similar metallicities as in the Milky Way or down to [M/H] $\sim$ -1.5~dex \citep{deBoer2014}. 
For the Magellanic Clouds and for QSO-DLAs we assume the middle point (at [Fe/H = -1.3]) of the knee position range estimated by \citet{deBoer2014} (see their Fig. 3). The approximate assumption of the position of the $\alpha$-element knee for those environments can be improved with future observations. Nevertheless, the exact positioning of the $\alpha$-element knee has a very small effect on the $\alpha$-element correction and therefore does virtually not affect our results. In addition, we explore the possibility of a different assumption for the Magellanic Clouds, a constant distribution of $\alpha$-element enhancement (and Mn underabundance), as we discuss in Section \ref{subsec: nucl_assump}.

Using these assumptions on the effects of $\alpha$-element enhancement and Mn underabundance, we derive the depletions using eq. \ref{deltax}. Corrections for these effects are taken into account for the derivations of the depletions, but have minimal contribution ($\leq$ 0.4~dex) comparing to the strong dust depletion effects on the gas-phase metal abundances, which can reach up to 3~dex for heavily depleted metals, such as Ti \citep{Jenkins2009}. 

\subsection{Dust-depletion sequences}
In this paper, we follow the methodology of \citet{DeCia2016} to characterize the depletion of several elements in different environments (QSO-DLAs, GRB-DLAs, Milky Way, LMC, SMC), using a literature compilation that includes systems with Zn and Fe constrained measurements. In their methodology, \citet{DeCia2016} use the relative abundance of an element X with respect to a lightly depleted element, such as Zn, P or S, to estimate the dust depletion of element X ($\delta_{\rm{X}}$). The depletion of X correlates linearly with the dust tracer (such as [Zn/Fe]) and thus the dust depletion can then be expressed by a simple linear relation. We characterize the dust depletion of P, S, Si, Mg, Mn and Cr in the above environments and further focus on the dust depletion of Ti and Ni, which have not been characterized before with this method and for which we provide with new column density measurements. We extend our study to additionally characterize the dust depletion of  O, C, Cl, Kr, Ge, Cu, Co and Al for the Milky Way and QSO-DLAs, however only few measurements are available at low levels of depletion (QSO-DLAs) and only two LMC measurements are added to the O depletion sequence.

We fit the dust depletion sequences, as derived from the observed relative abundances and after correcting for the depletion of Zn and for $\alpha$-element enhancement or Mn underabundance, with a linear least-squares approximation taking into account the errors on both x ([Zn/Fe]) and y ($\delta_{X}$) axis ($\sigma_{[Zn/Fe]}$ and $\sigma_{\delta_{X}}$). We use the Python package {\tt scipy.odr}, which performs orthogonal distance regression to the data and aims to find the parameters that minimize the sum of the squared error for each data point. It utilizes the ODRPACK library \citep{Boggs1992}, which implements a modified trust-region Levenberg-Marquardt-type algorithm to estimate the function parameters. The dust depletion can be represented by linear fits to the data as,
\begin{equation}
    \delta_X = A2_X +B2_X \times \mathrm{[Zn/Fe]},
    \label{deltaxcoeff}
\end{equation}
where the A2$_{X}$ and B2$_{X}$ coefficients for all the elements are reported in Table \ref{coefficients}. These are given for two different assumptions on the nucleosynthetic curves of the Magellanic Clouds, one with the knee at [Fe/H = -1.3] and one assuming a constant over- or underabundance plateau. Although, the differences are small we recommend that the second assumption coefficients are used.

Figure \ref{fig:DeplSeq} shows the depletion sequences of the larger coverage elements (P, S, Si, Mg, Mn and Cr). We discuss the elements with limited coverage in Appendix \ref{limited_cov}. For Ti, Ni, P, S, Si, Mg, Mn and Cr we perform fits to the individual environments, but also all the data merged together. We also fit the relative abundances of element X with respect to Zn against [Zn/Fe]. The coefficients A1$_{X}$ and B1$_{X}$ are derived from the linear fit of the observed sequences of relative abundances,
\begin{equation}
    \mathrm{[X/Y]} = A1_X +B1_X \times \mathrm{[Zn/Fe]},
    \label{XZncoeff}
\end{equation}

The best merged fit is shown by the red solid lines in Fig. \ref{fig:TiNi}, from which we derive the coefficients A1$_{X}$, B1$_{X}$, A2$_{X}$ and B2$_{X}$. We report in Tables \ref{titable} and \ref{nitable} the coefficients A2$_{X}$ and B2$_{X}$ for the merged fit and the individual environments, the intrinsic scatter $\sigma_{\delta_{\rm{X}}}$ of the data, estimated as the standard deviation of the x and y-component residuals for each data point, as well as the statistical properties of the fits to the individual sample and the merged data. 

\begin{table*}[!t]
\caption{Coefficients A2$_{X}$ and B2$_{X}$ resulting from the linear merged fit $\delta_{\rm{X}}$ = A2$_{X}$ +B2$_{X}$ $\times  \mathrm{[Zn/Fe]}$ of the depletion sequences seen in Figures~\ref{fig:TiNi}, \ref{fig:DeplSeq}, \ref{fig:DeplSeq_volatile}, the degrees of freedom $\nu$ and the Pearson correlation coefficients r. Exception are Zn and Fe, which are taken from \citet{DeCia2016}. $^a$ r = -1 by construction. The coefficients are given for two assumptions on the knee position for the Magellanic Clouds. We recommend that the one with constant $\alpha_{\rm{X}}$ is used.}
\label{coefficients}
\centering
\begin{tabular}{c|ccc|ccc|c} 
 \hline
 \multirow{3}{*}{X} &
 \multicolumn{3}{c|}{SMC/LMC knee at [$\rm{Fe/H}$] = -1.3} & \multicolumn{3}{c|}{Constant $\alpha_{\rm{X}}$} &  \multirow{3}{*}{$\nu$}\\
 & &&&&&\\
 & A2$_{x}$ & B2$_{x}$ & r & A2$_{x}$ & B2$_{x}$ & r &  \\ \hline\hline
C  & 0.00   & -0.10$\pm$0.10 & -0.10             &         0.00   & -0.10$\pm$0.10 & -0.10  & 3   \\
P & 0.03$\pm$0.05   & -0.21$\pm$0.08 & -0.46 & 0.03$\pm$0.05   & -0.21$\pm$0.08 & -0.46   & 43 \\
O  & 0.00$\pm$0.00   & -0.20$\pm$0.05 & -0.31                        & 0.00$\pm$0.00  & -0.20$\pm$0.05 & -0.50 & 22  \\
Cl & 0.00   & -0.12$\pm$0.09 & -0.80                        & 0.00   & -0.12$\pm$0.09 & -0.80   & 6   \\
Kr & 0.00  & -0.04$\pm$0.09 & -0.53                        & 0.00  & -0.04$\pm$0.09 & -0.53  & 3   \\
S  & 0.01$\pm$0.02   & -0.48$\pm$0.04 & -0.68  & 0.01$\pm$0.02  & -0.48$\pm$0.04 & -0.68 & 99  \\
Zn & 0.00$\pm$0.01   & -0.27$\pm$0.03 & -1.00$^{\rm a}$ & 0.00$\pm$0.01   & -0.27$\pm$0.03 & -1.00$^{\rm a}$ & ... \\
Ge & 0.00   & -0.40$\pm$0.04 & -0.91                        & 0.00   & -0.40$\pm$0.04 & -0.91   & 1   \\
Mg & 0.01$\pm$0.03 & -0.60$\pm$0.04 & -0.86    & 0.01$\pm$0.03  & -0.66$\pm$0.04 & -0.91 & 69  \\
Si & -0.04$\pm$0.02  & -0.72$\pm$0.03 & -0.87   & -0.04$\pm$0.02 & -0.75$\pm$0.03 & -0.88 & 151 \\
Cu & 0.00   & -0.73$\pm$0.04 & -0.87                        & 0.00   & -0.73$\pm$0.04 & -0.87   & 4   \\
Co & 0.00  & -0.89$\pm$0.19 & -0.87                        & 0.00  & -0.89$\pm$0.19 & -0.87   & 6   \\
Mn & 0.07$\pm$0.02   & -1.06$\pm$0.03 & -0.96 & 0.07$\pm$0.02  & -1.03$\pm$0.03 & -0.96 & 93  \\
Cr & 0.12$\pm$0.01   & -1.30$\pm$0.01 & -0.98 & 0.12$\pm$0.01   & -1.30$\pm$0.01 & -0.98   & 192 \\
Ni & 0.07$\pm$0.02   & -1.31$\pm$0.03 & -0.96 & 0.07$\pm$0.02   & -1.31$\pm$0.03 & -0.96   & 168 \\
Fe & -0.01$\pm$0.03  & -1.26$\pm$0.04 & -1.00$^{\rm a}$ &-0.01$\pm$0.03  & -1.26$\pm$0.04 & -1.00$^{\rm a}$ & ...\\
Al & 0.00   & -1.66$\pm$0.35 & -0.69                        & 0.00   & -1.66$\pm$0.35 & -0.69  & 7 \\
Ti & -0.06$\pm$0.03  & -1.64$\pm$0.04 & -0.97                        & -0.07$\pm$0.03 & -1.67$\pm$0.04 & -0.97 & 81 
\\ \hline
\end{tabular}
\end{table*}

\begin{figure*}[!t]
    \centering
    \includegraphics[width=\textwidth]{Figures/allElmerge_P.pdf}
    \caption{Relative abundances of element X with respect to Zn against [Zn/Fe]. The black triangles are for QSO-DLAs, the green dots are for the Milky Way, the purple stars are for the LMC, the blue triangles are for the SMC and the orange diamonds for the GRB-DLAs. The red line shows the linear fit to the data.The slope becomes steeper for elements that are more strongly depleted into dust grains.}
    \label{fig:RelAbund}
\end{figure*}
\begin{figure*}[!t]
    \centering
    \includegraphics[width=\textwidth]{Figures/alldelEl_merge_alpha_cor1_wP.pdf}
    \caption{Dust depletion of element X ($\delta_{X}$) against [Zn/Fe]. The black triangles are for QSO-DLAs, the green dots are for the Milky Way, the purple stars are for the LMC, the blue triangles are for the SMC and the orange diamonds for the GRB-DLAs. The red line shows the linear fit to the data.The slope becomes steeper for elements that are more strongly depleted into dust grains.}
    \label{fig:DeplSeq}
\end{figure*}

\begin{figure*
    \centering
        \includegraphics[width=\textwidth]{Figures/alldelEl_merge_alpha_cor1_constMCs_asym.pdf}
    \caption{Same as Fig. \ref{fig:DeplSeq} for the $\alpha$-elements and Mn after assuming a constant overabundance for the $\alpha$-elements and underabundance plateau for Mn in the Magellanic Clouds.}
    \label{fig:constMCs}
\end{figure*}

\begin{figure*}[!ht]
    \centering
    \includegraphics[width=\textwidth]{Figures/TiNiZn_limits_new2.pdf}
\end{figure*}
\begin{figure*}[!ht]
    \centering
    \includegraphics[width=\textwidth]{Figures/dTiNi_limits_new1.pdf}
    \caption{(Top panels): The relative abundances of Ti and Ni with respect to Zn, against [Zn/Fe]. (Bottom panels): Dust depletion of Ti and Ni against [Zn/Fe] and the linear fits for the QSO-DLAs (black triangles and black dashdotted line), for the Milky Way (green points and green dashed line), for the LMC (purple stars and purple densely dashdotdotted line), for the SMC (blue triangles and blue loosely dashdotted line) and for the GRB-DLAs (orange diamonds and orange dotted line). The 3$\sigma$ upper limits are shown with grey arrows. The red solid line shows the linear fit to the merged data.}
    \label{fig:TiNi}
\end{figure*}

\begin{table*}[!ht]
\caption{Orthogonal distance regression results of the fits for the depletion of Ti in the different environments. The $\chi^{2}$, the reduced $\chi_{\nu}^{2}$, the degrees of freedom $\nu$, the $\chi{_{\nu}}^{2}$ difference between the fit to the individual samples and the merged fit to the individual sample ($\Delta\chi{_{\nu}}^{2}$), the Pearson correlation coefficients r, the p - value and intrinsic scatter $\sigma_{\delta_{\rm{X}}}$.}
\centering
\begin{tabular}{c c c c c c c c c c}
\hline\hline 
Ti & A2$_{\rm{X}}$ & B2$_{\rm{X}}$ &$\chi^{2}$ & $\chi^{2}_{\nu}$ &$\nu$ & $\Delta \chi^{2}_{\nu}$ & r & p~-~value & $\sigma_{\delta_{\rm{Ti}}}$ \\
\hline
Milky Way& 0.02$\pm$0.30 & -1.73$\pm$0.22 & 57.84 & 2.00 & 29 & 0.07 & -0.81 & 4.13e-08 & 0.12\\
QSO-DLAs & -0.17$\pm$0.07& -1.36$\pm$0.19 & 61.24 & 2.36  & 26 & 0.16 & -0.87 & 2.32e-09 & 0.13\\
LMC & -0.53$\pm$0.12  & -1.01$\pm$0.13 &  2.83 & 0.35 & 8 & 0.96 & -0.97&3.00e-06 & 0.05\\
SMC &-0.35$\pm$0.04&-1.11$\pm$0.06 & 0.79 & 0.07 & 11 & 0.86 & -0.99 & 2.90e-10 & 0.02\\
GRB-DLAs & - & -  & - & - & - & - &-&- & -\\
Merged fit  & -0.06$\pm$0.03 & -1.64$\pm$0.04 & 164.49 & 2.03 & 81 & - & -0.97 & $\ll$ & 0.13\\
\hline 
\label{titable}
\end{tabular}
\end{table*}

\begin{table*}[!ht]
\caption{Same as Table \ref{titable} but for Ni.}
\centering
\begin{tabular}{c c c  c  c  c cccc}
\hline\hline
Ni & A2$_{\rm{X}}$ & B2$_{\rm{X}}$ &$\chi^{2}$ & $\chi^{2}_{\nu}$ & $\nu$& $\Delta \chi^{2}_{\nu}$ & r & p~-~value & $\sigma_{\delta_{\rm{Ni}}}$ \\
\hline\hline
Milky Way& 0.33$\pm$0.12  & -1.57$\pm$0.09 & 10.16 & 0.48  & 21 & 0.59 &-0.97& 2.09e-14 & 0.03\\
QSO-DLAs & -0.01$\pm$0.02 &  -1.12$\pm$0.04& 279.04 & 2.91 & 96 & 0.60 &-0.90 & $\ll$ & 0.11 \\
LMC & -0.05$\pm$0.05 & -1.26$\pm$0.05& 4.31 & 0.16 & 27 & 0.25 &-0.98 & 1.07e-19 & 0.03\\
SMC & -0.07$\pm$0.10 &-1.21$\pm$0.16& 1.93 & 0.19 & 10 & 0.18 & -0.94 & 4.53e-06 & 0.04\\
GRB-DLAs & -0.15$\pm$0.15 &-0.90$\pm$0.20& 6.50 & 1.08 & 6 & 0.80 & -0.71 &5.00e-02 & 0.10\\
Merged fit  & 0.07$\pm$0.02 & -1.31$\pm$0.03 & 328.53 & 1.96 & 168 & - & -0.96 &$\ll$ & 0.10\\
\hline
\label{nitable}
\end{tabular}
\end{table*}

\subsection{Titanium depletion}
\label{sec: Tidepletion}

In the current and following Section we focus on Titanium and Nickel, for which we characterize the depletion based on the technique of relative abundances for the first time, using a relatively large dataset that includes our new measurements.

The depletion of Ti is derived from the observed relative abundances of [Ti/Zn] and [Zn/Fe] (Fig. \ref{fig:TiNi}) in 28 QSO-DLAs, 1 GRB-DLA, 10 LMC, 13 SMC and 31 Milky Way systems. Only one constrained measurement of Ti is available for GRB-DLAs, which is included in the merged fit but the individual fit is not performed for this group. The linear regression fits to the Ti depletions in the different environments, as well as the merged fit, are shown in Fig. \ref{fig:TiNi}.

To evaluate the goodness of the fits we estimate the $\chi^{2}$, the reduced $\chi_{\nu}^{2}$, the Pearson correlation coefficients r, the p-value for each fit as well as the difference between the individual datasets and the merged fit ($\Delta \chi^{2}_{\nu}$), reported in Table \ref{titable} and further discussed in \ref{appsec: stats}. 

The most severe titanium depletion can be observed for the Milky Way, where 90 to $\sim$ 99.9$\%$ of titanium is depleted into dust. Indeed we observe $\delta_{\rm{Ti}}$ between $\sim$ -1.4 and -3.1~dex, which is similar to the Ti depletion that \citet{Jenkins2009} estimated for the Milky Way ISM using less data and estimated with an independent method ($\sim$ -1.1 to -3.2~dex). This is an important comparison, because the depletion of Ti is so strong to dominate over other potential effects that may affect different methods in different ways, like $\alpha$-element enhancement, ionization, or metallicity of the ISM. In particular, the consistency of our estimates of the strongest depletion of Ti in the Milky Way with those of \citet{Jenkins2009} confirms that our assumption on the depletion of Zn (to estimate $\delta_{\rm{Ti}}$ from [Ti/Zn]) is in the right range.
The titanium depletion in QSO-DLAs is considerably less and ranges from about 0.003 to -1.5~dex. QSO-DLAs can probe systems with low metallicity and dust content, and in turn, very low dust depletions, all the way down to zero for the cases of dust-free QSO-DLAs. Indeed, even for the most refractory elements, like Ti, dust depletion can be zero. In the Magellanic clouds the range is in between the Milky Way and the QSO-DLAs, ranging from about -1 to -1.9~dex for the LMC and -1 to -1.8~dex for the much smaller sample of the SMC.

The best merged fit coefficients for Ti are A2$_{\rm{Ti}}$ = -0.07 $\pm$ 0.03 and B2$_{\rm{Ti}}$ = -1.67 $\pm$ 0.04. \citet{Wiseman2017} made an approximate estimate on the coefficients of Ti and Ni based only on Milky Way data and are also consistent with our results (private communication). Other studies also find that the strong Ti depletion is most relevant in higher metallicity environments (e.g. \citet{Jenkins2009, Welty2010}. This is consistent with our results, since Ti depletion appears to be stronger in the Milky Way and decreases with decreasing metallicity (Magellanic Clouds, DLAs). The increasing depletion with increasing metallicity is also typically the case for the other metals. We observe, however, a potential departure of the Ti depletion from linearity in the mid-range of metallicities, in the Magellanic Clouds, which is discussed in Sect. \ref{subsec: nucl_assump}.

GRB120327A slightly deviates from the linear fit of the depletion sequence with a low Ti content (log~N($\ion{Ti}{ii})$ = 12.69 $\pm$ 0.08) (see orange diamond in Fig. \ref{fig:TiNi}). This could be due to dust depletion, ionization, nucleosynthesis or a measurement problem, such as line contamination. Low Ti abundance could be caused due to dust depletion, but the effect would be less prominent than what we observe and would be observed for the other metals as well. However, all other metals (Zn, S, Cr, Ni, Fe) for this system fit well the expected depletion pattern.
\ion{Ti}{ii} has a low ionization potential, making it more sensitive to ionization than the other ions (e.g. \ion{Fe}{ii}, \ion{Si}{ii}). There is no evidence for ionization for the DLA towards GRB120327A,
which has a very high \ion{H}{i} column density (log~$N(\ion{H}{i})$ = 22.07 \citep{Bolmer2019}), so \ion{H}{i} should be quite efficient at shielding metals. Nucleosynthesis effects are also ruled out, since we observe an underabundance, opposite to an overabundance that we would expect from $\alpha$-element enhancement. Finally, this does not appear to be a measurement problem (due to the way the Ti column density was measured), because the Ti line profile is well modelled by \citet{Bolmer2019}, but was only based on one transition, which is the weak $\lambda$1910$\AA$ \ion{Ti}{ii} line.

\subsection{Nickel depletion}

We use measurements of Ni from 98 QSO-DLAs, 8 GRB-DLAs, 23 Milky Way, 29 LMC and 12 SMC targets to characterize the depletion of Ni.
The depletions of Ni for the different environments are shown in the right side panels of Fig. \ref{fig:TiNi} and the goodness of the fit parameters are reported in Table \ref{nitable}.

Within the Milky Way, about 90$\%$ to 99$\%$ of Ni is depleted into solid dust grains, similarly to Fe. The highest depletion is observed for the Milky Way, ranging from about -1 to -2.4~dex. The depletion in the LMC ranges from -0.6 to -2~dex. Finally, for the QSO-DLAs is 0.2 to -1.9~dex, for the SMC -0.7 to -1.4~dex and for GRB-DLAs -0.3 to -1.2.

We observe a tight correlation between $\delta_{\rm{Ni}}$ and [Zn/Fe] considering all the environments (QSO-DLAs, GRB-DLAs, Milky Way, LMC) merged, but also individually. The strong linear relation is reflected in the r value of the merged fit (r = -0.96), as well as the high statistical significance (p $\ll$ 10$^{-1}$) and the relatively small intrisic scatter of $\sigma_{\delta_{\rm{Ni}}}$ = 0.10. 

The best merged fit coefficients for Ni are A2$_{\rm{Ni}}$ = 0.07 $\pm$ 0.02 and B2$_{\rm{Ni}}$ = -1.31 $\pm$ 0.03. \citet{Jones2018} also based their work on the observations of relative abundances to estimate the depletion of Ni, however in sub-DLA absorption systems, with measurements tabulated by \citet{Quiret2016}. They find a depletion sequence that is characterized by A2$_{\rm{Ni}}$ = -0.03 $\pm$ 0.06 and B2$_{\rm{Ni}}$ = -1.19 $\pm$ 0.11, but with a relatively large intrinsic scatter $\sigma_{\delta_{\rm{Ni}}}$ = 0.18.

\begin{figure*}
    \centering
        \includegraphics[width=\textwidth]{Figures/TcBx2_fits4_colors_wP.pdf}
    \caption{(Left panel): The merged fits of the dust depletion ($\delta_{X}$) as a function of [Zn/Fe] for all the elements. The elements are sorted by depletion strength. (Right panel): The slopes of the fits of the depletion sequences B2$_{X}$ (or refractory index) as a function of the respective element condensation temperature T$_{c}$. The dust depletion relation with B2$_{X}$ is described by $\delta_X = A2_X +B2_X \times \mathrm{[Zn/Fe]}$. The condensation temperatures T$_{c}$ are compiled by \citet{Lodders2003}. Elements with higher condensation temperatures are more heavily depleted into dust.}
    \label{fig:Tcwfits}
\end{figure*}

\section{Discussion}
\label{sec:disc}

We observe linear sequences of the dust depletion for the majority of the elements from low metallicity QSO-DLAs to the the Milky Way. We note that, while there is a dependence between [X/Zn] and [Zn/Fe] because both ratios have Zn in common, the same linear correlations are also found when using [X/Si] and [X/P] instead of [X/Zn] (see \citet{DeCia2016}). The slopes of these linear relations depend on the condensation temperature of the elements X. Thus, these relations are a result of dust depletion and not a x-y axis dependence.

The linear fits of the depletion sequences to all the available data of each element from all the environments (Milky Way, Magellanic Clouds, QSO- and GRB-DLAs) considered in this study are presented in the left-hand panel of Fig. \ref{fig:Tcwfits}. The fits get steeper for elements that are more strongly depleted into dust grains (refractory elements). In addition, the slope of the depletion sequences, B2$_{X}$, or refractory index, which is a measure of how heavily depleted an element is, decreases with the condensation temperature \citep{Field1974, Savage1996, Jenkins2009, Mattsson2012, Tchernyshyov2015, DeCia2016}. This relation can be observed in the right-hand panel of  Fig. \ref{fig:Tcwfits}, where the condensation temperatures T$_{c}$ are compiled by \citet{Lodders2003}. The slope dependence with the refractory properties of metals confirms that the cause of the observed linear correlation is indeed dust depletion.

\subsection{Chromium}

Figure \ref{fig:RelAbund} shows that the zero intercept (at [Zn/Fe] = 0) of the Cr depletion sequence is not exactly at zero, but instead it is higher by $\sim$ 0.13~dex $\pm$ 0.01. This may suggest that chromium could be partly effected by an $\alpha$-element enhancement.

Chromium belongs to the iron group elements and, like half of the iron group elements, it is mainly produced by Type~Ia supernovae (SNe~Ia) \citep{Nomoto1997, Travaglio2004, KobayashiNomoto2009,Kobayashi2020}. However, Cr is also a product of the $\alpha$ process, synthesized in the incomplete Si burning regions of SN~II during explosive nucleosynthesis \citep{Kobayashi2006, Nomoto2006}.
\citet{Nomoto2006} show that Cr can be copiously produced by core-collapse supernovae, with [X/Fe] $\sim$ 0.1 for progenitor masses up to 20~M$_{\odot}$.
Thus, core-collapse supernovae, which produce the $\alpha$-elements, produce a significant amount of Cr after radioactive decay, leading to a small Cr overproduction. That would explain a small $\alpha$-element enhancement, but not as much as the $\alpha$-elements (O, S, Si, Mg). Indeed, at no depletion ([Zn/Fe = 0]), we observe [Si/Zn] $\sim$ [S/Zn] $\sim$ [Mg/Zn] $\sim$ [Ti/Zn] $\sim$ 0.3~dex and [O/Zn] $\sim$ 0.50~dex (which exclude the fact that Zn can have large $\alpha$-element enhancement amplitude), but instead we observe [Cr/Zn] $\sim$ 0.13~dex $\pm$ 0.01. \citet{Prochaska&Wolfe2002} report a slight overabundance of Cr at low levels of [Zn/Fe] and \citet{Dessauges2006} also report an overabundance of Cr by $\sim$ 0.13~dex, as well as an overabundance of the $\alpha$-elements, consistent with our results. We didn't take into  account this small overabundance when correcting for nucleosynthesis effects, because Cr is not typically considered an $\alpha$-element.

The highly depleted QSO-DLA point at [Zn/Fe] = 1.555 of the Cr depletion sequence seen in Fig. \ref{fig:DeplSeq} is J1211+0833. The host galaxy of this system is found to be a chemically-enriched, evolved, massive, and star-forming disk-like galaxy \citep{Ma2018}. This system is so chemically enriched that is no longer in the low metallicity QSO-DLA regime and enters the high metallicity range of the Milky Way. It does, nevertheless, follow the Cr dust depletion sequence. This further supports our results that the depletion sequences are consistent for all the environments.

\subsection{On the ionization of Sulfur}
\label{subsec: ionS}

In Fig. \ref{fig:RelAbund} we observe that \ion{S}{ii} column densities are higher when observing towards stellar sources (MW, SMC, LMC), compared to the measurements towards background QSOs or GRBs. This difference between measurements of \ion{S}{ii} column densities in local and distant galaxies can be well explained by ionization effects.

The ionization potential of \ion{S}{ii} is the highest (23.4~eV) of the elements considered in this work and is not easily ionized. This means that \ion{S}{ii} can be found in both \ion{H}{i} and \ion{H}{ii} regions, while other elements are easily ionized to their doubly-ionized state in the \ion{H}{ii} regions, thus not contributing to what we measure in the neutral ISM. This \ion{S}{ii} in the \ion{H}{ii} regions can add to what we consider to be present in the foreground \ion{H}{i} gas. At the same time, the \ion{S}{ii} transitions are quite strong, which makes \ion{S}{ii} virtually impossible to measure in lines of sight with large amounts of N~(\ion{H}{i}). This results in \ion{S}{ii} being determined only in
lines of sight with low N~(\ion{H}{i}), which makes the contribution from the star’s \ion{H}{ii} region relatively important. Overall, DLA gas probes only the neutral phase, while the absorbers towards \ion{H}{ii} regions, like in the Milky Way or the Magelanic Clouds, have an increased contribution from \ion{S}{ii} of the \ion{H}{ii} regions.
The case of S is further discussed in \citet{Jenkins2009, Jenkins2017}.

\subsection{Nucloesynthesis as the cause of the deviations observed in the Magellanic Clouds}
\label{subsec: nucl_assump}

In Figures \ref{fig:TiNi} and \ref{fig:DeplSeq} we see a potential bending of the dust depletion sequences for Ti, Mg, S and Mn in the Magellanic Clouds. In particular, Ti, S and Mg have a shallower and Mn a steeper slope in the Magellanic Clouds than in the Milky Way. This potential departure from a linear relation is more pronounced after removing the linear dependency of $\delta_{\rm{Zn}}$ with [Zn/Fe] and correcting for nucleosynthesis, i.e. $\alpha$-element enhancement and Mn underabundance. The deviations are not strictly significant (1.8$\sigma$, 2$\sigma$, 2.5$\sigma$ and 5$\sigma$ for Mg, Ti, Mn and S respectively). A statistical analysis to quantify these deviations is presented in Appendix \ref{appsec: stats}.
The small deviations in relative abundances that we observe in the neutral ISM in the Magellanic Clouds are not randomly distributed among elements. We systematically observe overabundance of $\alpha$-elements (Ti, Mg, S, and difficult to tell for Si) and underabundance of Mn. Therefore, these tentative deviations could be due to $\alpha$-element enhancement and Mn underabundance in the Magellanic Clouds that we did not take into account in our initial assumptions.

The production of $\alpha$-elements is dominated by core-collapse SNe \citep{Kobayashi2006, KobayashiNomoto2009}, while the production of Mn is dominated by SN~Ia \citep{Gratton1989, Feltzing2007, KobayashiNomoto2009}. This makes it quite likely that the deviations we observe are actually caused by nucleosynthesis effects. In our initial analysis, we have corrected for $\alpha$-element enhancement and Mn underabundance assuming a distribution of the [$\alpha$/Fe] with metallicity with a classical plateau - knee distribution (e.g. \citet{McWilliam1997}), also for the Magallanic Clouds. 

As described in Section \ref{nucl_corr}, the exact position of the $\alpha$-element knee is not well constrained in the Magellanic Clouds. However, small changes in the knee position do not affect our results, since the points that deviate from the fit are far from the knee position. In addition, the metallicities of the neutral ISM of the systems that show deviations are in the range where we did not expect $\alpha$-element enhancement (De Cia et al. in prep.).

By assuming instead a constant over- or underabundance plateau, the previously deviating points follow the linear fit. The shapes of the different assumptions on the nucleosynthetic curves for the $\alpha$-elements and for Mn are seen in Fig. \ref{fig:curves_constMCs}. The dust depletion sequences for the $\alpha$-elements and for Mn after correcting for nucleosynthesis effects in the Magellanic Clouds assuming a constant over-or underabundance plateau are seen in Fig. \ref{fig:constMCs}. All elements after the new corrections follow linearity, except for S, which is known to be further enhanced towards \ion{H}{ii} regions by ionization. This could mean that the nucleosynthetic curves for the Magellanic Clouds might be much different from what was previously assumed, and there is only a constant plateau instead. This could be due to a recent burst of star formation in the Magellanic Clouds, which implies their star formation history is likely to be different than in the Milky Way.

The overabundance of $\alpha$-elements and underabundance of Mn in the Magellanic Clouds is also observed and discussed in previous studies \citep{Vladilo2002, Guber2016, Jenkins2017, DeCia2018}. \citet{Hasselquist2021} observe stellar $\alpha$-element enhancement in the Magellanic Clouds and an upturn of the [$\alpha$/Fe] plateau, which they interpret as due to a very recent burst of star formation. The $\alpha$-element enhancement may be local and follow the recent star formation activity. On the other hand, other works did not find a clear [$\alpha$/Fe] plateau in the LMC (e.g., \citet{VanDerSwaelmen2013}). 
It is possible that we observe $\alpha$-element enhancement and Mn underabundance towards limited individual systems, rather than systematically over the whole range of metallicities. Our observations probe the neutral ISM towards hot young OB stars, so they may be more prone to show $\alpha$-element enhancement and Mn underabundance. Additionally, it is possible that $\alpha$-element enhancement can be observed in the neutral ISM towards young stars following a recent star formation burst, while there was no time for a new generation of stars to form and fully show the $\alpha$-element enhancement.

\begin{figure}
    \centering
    \includegraphics[width=\columnwidth]{Figures/nucl_curves_vert.pdf}
    \caption{The assumed nucleosynthetic over- or underabundances $\alpha_{\rm{X}}$ for the $\alpha$-elements X (S, Si, Mg, Ti) and Mn respectively with respect to [Zn/Fe] and metallicity [M/H]. The solid green curve is for the Milky Way, solid purple the LMC curve as adopted from \citet{deBoer2014} and in dashed purple the LMC with a constant over- or underabundance plateau. For the plateau of the $\alpha$-elements we use as reference $\alpha_{\rm{S}}$ = 0.25.}
    \label{fig:curves_constMCs}
\end{figure}

\section{Summary and conclusions} 
\label{sec:conc}
We characterize the dust depletion of several metals in different environments, from the Milky Way, the Magellanic Clouds, and DLAs towards GRBs and QSOs, based on the relative abundances of metals with different refractory properties (or how easily they incorporate into dust grains). We collect all the available literature measurements of metal column densities in these environments, making this a comprehensive study of relative chemical abundances of metals and for different environments. We measure new column densities of Ti and Ni in 70 QSO-DLAs from high-resolution UVES spectra from the sample of \citet{DeCia2016}.

We observe and fit the dust depletion sequences, as well as the relative abundances for all the elements considered in this study. We further focus on the dust depletion of Ti and Ni, for which we also provide with new column density measurements.

We observe a slight deviation from the linear fits of the depletion $\delta_{\rm{X}}$ for Ti, S, Mg and Mn, in the Magellanic Clouds. A potential cause of the anomaly in those elements could be due to the $\alpha$-element enhancement and Mn underabundance in the Magellanic Clouds. By assuming a constant over- (under-) abundance plateau of the $\alpha$-elements (Mn), the deviations disappear and all environments for all the elements follow linearity. The observed $\alpha$-element enhancement and Mn underabundance in the neutral ISM at a wide range of metallcities, is possibly due to recent bursts of star formation in the Magellanic Clouds.

We observe a Cr overabundance of $\sim$ 0.13~dex $\pm$ 0.01 that suggests that it could be affected by an $\alpha$-element enhancement, while Cr is not typically considered an $\alpha$-element.

The column densities of \ion{S}{ii} seem to be higher for local galaxies (Milky Way, SMC, LMC), which can be explained by an additional contribution of their \ion{H}{ii} regions to the measured \ion{S}{II} column densities.

The tendency of each element to be depleted into dust varies depending on its condensation temperature. This dependence confirms that the the depletion sequences are indeed driven by dust depletion, rather than other physical processes.

Overall, the dust depletion of the elements are well described with linear fits to the merged data, despite the small deviations, which statistically are not significant for the merged fit. Nevertheless, the small deviations seem to be due to nucleosynthesis and not dust depletion. The dust depletion sequences are virtually the same for different environments, which implies that dust depletion behaves the same way independently of the environment. This could mean that the process that is mostly responsible for the build up of dust grains is independent from the star-formation history of the different galaxies, which likely changes dramatically from system to system. This suggests that the growth of dust grains in the ISM is an important process of dust formation.

\begin{acknowledgements}
We thank the referee Sandra Savaglio for the detailed and constructive report that improved this manuscript. CK, ADC, JKK and TRH acknowledge support by the Swiss National Science Foundation under grant 185692. KEH acknowledges support from the Carlsberg Foundation Reintegration Fellowship Grant CF21-0103. This paper makes use of the Python code VoigtFit available on \url{https://github.com/jkrogager/VoigtFit}. This research has made use of NASA’s Astrophysics Data System.
\end{acknowledgements}

\bibliographystyle{aa}
