[Tex/LaTex] How to typeset inclusion arrow

arrowssymbols

I would like to know what is the best way to do an inclusion arrow, using xy or tikz. I know that there is a command for an arrow, like \to, for inclusions, but this is not expansible.

What do you use?

Best Answer

The mathtools package gives you extansible hook-arrows which some authors use for inclusions:

\documentclass{article}
\usepackage{mathtools}

\begin{document}

\[
A\xhookrightarrow{} B\qquad A\xhookrightarrow{f\circ g} B\qquad
A \xhookrightarrow[(f\circ g)\circ h]{} B
\]

\end{document}

enter image description here

You can also use \xrightarrow from amsmath if you want an extensible "standard" arrow with super/subscripts:

\documentclass{article}
\usepackage{amsmath}

\begin{document}

\[
A\rightarrow{} B\qquad A\xrightarrow{f\circ g} B\qquad
A \xrightarrow[(f\circ g)\circ h]{} B
\]

\end{document}

enter image description here