Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

How can I label $\rightleftarrows$ above the top arrow and below the bottom arrow?

share|improve this question
    
A tip: You can use backticks ` to mark your inline code as I did in my edit. –  doncherry Apr 8 '12 at 8:39
    
Thanks doncherry –  j4fj49 Apr 8 '12 at 8:45

3 Answers 3

I don't know which package defines \rightleftarrows but this shows how to get labels over and under one of the standard arrows.

Edit updated to use the requested arrow

\documentclass{article}

\usepackage{amssymb}

\begin{document}

\[a \mathrel{\mathop{\rightleftarrows}^{\mathrm{over}}_{\mathrm{under}}} b\]

\end{document}

enter image description here

share|improve this answer
    
That would be amssymb. –  percusse Apr 8 '12 at 11:01
    
@percusse ah thanks I should have known that:-) updated answer –  David Carlisle Apr 8 '12 at 11:10
    
Is there a way to this not in amssymb? Because my work is on Wordpress, and I either use their built-in Latex or mathurl.com, neither of which support amssymb I am sure. Sorry to trouble you. –  j4fj49 Apr 8 '12 at 12:23
    
the code for the under and over label does not use any package at all, \mathrel and \mathop are primitives and \mathrm is standard LaTeZ (or you could use \rm in plain TeX) So if you can use the arrow in wordpress you should be able to use labels too. But you need something to define the arrow as it is not built in to latex. –  David Carlisle Apr 8 '12 at 12:27
    
I guess that means that Wordpress supports some sort of package because that arrow showed up. –  j4fj49 Apr 8 '12 at 12:31

If you want an extensible arrow, you can use the trick found in Herber Voß's Mathmode (texdoc mathmode or http://texdoc.net/pkg/mathmode):

\documentclass{article}
\usepackage{amsmath}
\makeatletter
\newcommand\xleftrightarrow[2][]{\ext@arrow 0099{\longleftrightarrowfill@}{#1}{#2}}
\def\longleftrightarrowfill@{\arrowfill@\leftarrow\relbar\rightarrow}
\makeatother
\begin{document}
$a\xleftrightarrow[under]{over}b$
\end{document}

enter image description here

share|improve this answer
    
I added a link to texdoc.net because I didn't seem to be able to get Mathmode on my MiKTeX 2.9, hope that's alright. –  doncherry Apr 8 '12 at 13:10
    
And congratulations to your answer No. 2000! I'll be lucky if I can keep my own rep to about a tenth of yours :) –  doncherry Apr 8 '12 at 14:31

I found a simple solution that works for me:

A \overset{F}{\underset{G}\rightleftarrows} X 
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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