The naive way to draw an hooked arrow in a diagram with XY-matrix is \ar@{^{(}->}. But it comes out that the hook is bigger respect the one of \hookrightarrow.

How can I fix this difference?

many thanks.

  • 1
    This TikZ-method might help: tex.stackexchange.com/questions/68676/inclusion-arrow-in-tikz? – c.p. Nov 19 '14 at 11:34
  • 3
    No way that I know with Xy-pic. The gigantic (and badly spaced) hook is one of the weaknesses of the package. Maybe a definition using low level graphics can be made, but my suggestion is to try tikz-cd, for commutative diagrams. – egreg Nov 19 '14 at 12:00

The hooked arrow in xy is one of the ugly parts of this package. It just looks wrong. You could write this issue to the maintainer (if still active) or you switch to the more modern and much easier (to read) tikz-cd. In my MWE I am showing both in order to show the difference between their hooked arrows:

% arara: pdflatex


\[\xymatrix{A\ar@{^{(}->}[r]& B}\]
    A \arrow[hook]{r} & B   

enter image description here

The latter is equal to the 'normal' \hookrightarrow.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.