2

I can't seem to get the text precisely over the arrow, only on the top right corner of this specifics arrows, I know I can use $\xrightarrow^{f}$ to get the text over this type of arrow, but I can't find the way to do it with $\rightarrow tail$ and $\twoheadrightarrow$

1
  • Welcome to TeX.SX! Please note, it is recommended to always add a minimal but working example (MWE) to your questions. We need such a MWE to reproduce your problem and to test our suggestions. We also would use it to show you a solution. So instead of let everyone of us make such a MWE, you should add it to your question. This would help us to help you. However: Have you tried \stackrel? Commented Jul 14, 2017 at 5:57

2 Answers 2

2

You can use \overset:

\documentclass{article}
\usepackage{amsmath,amssymb}
\begin{document}

  \[
     X \overset{f}\rightarrow Y \qquad
     U \overset{g}\twoheadrightarrow V.
  \]

\end{document}

This produces:

enter image description here

The difference between this and using \xrightarrow is that \xrightarrow will extend the length of the arrow so that it is long enough for whatever you are putting above the arrow. In the code above the length of the arrows is fixed.

2

Maybe the \xhookrightarrow and a below-defined \xdbheadrightarrow is what you want?

\documentclass[12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
 \usepackage{amssymb}
\usepackage{lmodern, mathtools}
\usepackage{old-arrows} 

\makeatletter
\newcommand{\xdbheadrightarrow}[2][]{%
  \ext@arrow 0099\xdbheadfill@{#1}{#2}}%
\newcommand{\xdbheadfill@}{%
  \arrowfill@\relbar\relbar{\mathrel{\vphantom{\rightarrow}\smash{\twoheadrightarrow}}}}
\makeatother

\begin{document}

\[ 0 \longrightarrow M \xhookrightarrow[\text{monomorphism}]{f} N \xdbheadrightarrow[\text{epimorphism}]{g} P \longrightarrow 0 \]

\end{document} 

enter image description here

You must log in to answer this question.

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