23

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?

1 Answer 1

26

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

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .