# Unsure of how to create a particular diagram for slice/coslice categories

I'm using Tikz-cd and trying to follow this http://www.jmilne.org/not/Mtikz.pdf but I can't seem to get a diagram like this (taken from Algebra Chapter 0 by Aluffi)

The diagram I'm most concerned with is the morphism diagram below that I cannot figure out.

Much appreciated.

It is very simple with tikz-cd:

\documentclass{article}
\usepackage{amsmath,tikz-cd}

\begin{document}

\begin{tikzcd}
&& A \\
Z_1 \arrow[r,"\sigma"]
\arrow[urr,bend left,"f_1"]
\arrow[drr,bend right,swap,"g_1"] &
Z_2 \arrow[ur,"f_2"]
\arrow[dr,swap,"g_2"] \\
&& B
\end{tikzcd}

\end{document}


Left and right refers to the side of the arrow just like when we talk about river banks (from source to end). The label is placed by default on the left side, but swap allows to change this.

The r means "the target is the cell at the right", whereas urr means "the target is the cell two steps on the right and one step up". You have to imagine the objects in a grid like a matrix. In this case a 3 by 3 matrix.

The historic alternative, which probably the author used, is Xy-pic.

\documentclass{article}
\usepackage{amsmath}
\usepackage[all,cmtip]{xy}

\begin{document}

\xymatrix@R-1pc{
&& A \\
Z_1 \ar[r]^\sigma
\ar@/^1pc/[urr]^{f_1}
\ar@/_1pc/[drr]_{g_1} &
Z_2 \ar[ur]^{f_2}
\ar[dr]_{g_2} \\
&& B
}

\end{document}


• Thank you! These look very clean compared to what I was trying. – Gengar Sep 28 '16 at 19:12