How can I write this
in LaTex?
Using the tikz-cd package you have the possibility to use shifts (for example, shift right, shift left with a possible value for fine tuning position) to easily typeset this kind of sets of multiple arrows in commutative diagrams.
\documentclass{article}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzcd}
X\ar[r,"f"] & Y\ar[r,shift left,"g_{1}"]\ar[r,shift right,"g_{2}",swap] & Z
\end{tikzcd}
\begin{tikzcd}
X\ar[r,"f"] & Y\ar[r,shift left=1ex,"g_{1}"]\ar[r,shift right=0.4ex,"g_{2}",swap] & Z
\end{tikzcd}
\end{document}
A pstricks solution, with the psmatrix environment:
\documentclass{article}
\usepackage{pstricks-add}
\usepackage{auto-pst-pdf}
\begin{document}
\[ \psset{arrows=->, arrowinset=0.15 , linewidth=0.6pt, labelsep=1.5pt, nodesep=3pt, colsep=1.2cm, shortput=nab}
\everypsbox{\scriptstyle}
\begin{psmatrix}
X & Y & Z
%%%
\ncline{1,1}{1,2}^{f}\ncline[offset=2pt]{1,2}{1,3}^{g_1}\ncline[offset =-2pt]{1,2}{1,3}_{g_2}
\end{psmatrix} \]
\end{document}
tikz-cdoffers an out-of-the-box solution easier than those in the linked post: `\documentclass{article} \usepackage{tikz-cd}\begin{document}
\begin{tikzcd} A\ar[r,"f"] & B\ar[r,shift left,"g_{1}"]\ar[r,shift right,"g_{2}",swap] & C \end{tikzcd}
\end{document}`
– Gonzalo Medina Oct 17 '15 at 13:28