2

I'd like to know how to make two arrows: one above another where the lower arrow is the dashed one.

I came up with a code like this:

$$
    f_n \overset{\rightarrow}\dashrightarrow f
$$

which evaluates to:

enter image description here

And I would like it to look like this:

enter image description here

There is a thread where it was discussed how to print arrows like these above a letter (linked), but the solution was quite long.

I believe there must be an easier way to do it.

Notes:

2

For MathJax, the following might be useful, \substack puts the symbols over each other, \textstyle enlarges the font, \mathrel fixes the horizontal spacing:

f_n\mathrel{\substack{\textstyle\rightarrow\\\textstyle\dashrightarrow}} f

Result image from MathJax Live Demo:

Result MathJax

But it would look quite ugly in LaTeX:

Result LaTeX

  • \longrightarrow would be better, but the then the arrow would be a little bit too large.

  • The arrow heads are quite different. And they are different from \rightrightarrows.

  • Depending on the other arrows in your document, it might be wise to redraw all arrows in TikZ or other drawing package to get a consistent appearance of the arrows.

2

You could accomplish this with tikz:

\documentclass{article}
\usepackage{tikz}

\begin{document}
\[ f_n\; \tikz{\draw[dashed, ->] (0,0) -- ++(0.35cm, 0);\draw[->] (0,0.125cm) -- ++(0.35cm,0);}\; f \]

\end{document}

Or make it a macro:

\documentclass{article}
\usepackage{tikz}

\newcommand{\stackedarrow}{\ensuremath{\;}\tikz{\draw[dashed, ->] (0,0) -- ++(0.35cm, 0);\draw[->] (0,0.125cm) -- ++(0.35cm,0);}\ensuremath{\;}}

\begin{document}
\[ f_n \stackedarrow f \]

\end{document}

Either way will look identical, like this: stackedarrow

I know this doesn't satisfy the "easier way to do it", but it works!

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.