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.

I am looking for a solution for dashed down arrow. Have already tried packages like lucidabr and MnSymbol, but these turn my whole stuff upside down, producing a lot errors like

"Something is not ok in line XY".

I have also tried \rotatebox for \dashrightarrow (which is available in ams), and it just didn't do neither the rotation nor the placing..

I was thinking, maybe the best if I can produce it for myself.

Any help?

share|improve this question
    
Can we see the symbol in context? How should the symbol behave like (an relational symbol, a binary operator)? Where should the baseline be? –  Gonzalo Medina Oct 10 '12 at 22:29
    
Yes, I want it in context like '$\alpha:a|b$' where this $|$ should be the dashed downarrow.. –  Berci Oct 10 '12 at 23:01
1  
Related: tex.stackexchange.com/questions/14386/… –  egreg Oct 10 '12 at 23:20
add comment

1 Answer

up vote 9 down vote accepted

Basic Solution:

Now sure exactly what problem you had with using \rotatebox, but it seems to work if used as \rotatebox{-90}{$\dashrightarrow$}:

enter image description here

Notes:

  • Depending on the actual application this might need to be raised vertically, and that can be down with \raisebox:

    \newcommand{\dashdownarrow}{\raisebox{2.0ex}{\rotatebox{-90}{$\dashrightarrow$}}}
    
  • If it is a binary/relational operator than you can enclose the symbol in \mathbin{}/\mathrel{}:

    \newcommand{\dashdownarrow}{\mathbin{\raisebox{2.0ex}{\rotatebox{-90}{$\dashrightarrow$}}}}
    

Use \mathcoice to auto resize:

As per Gonzalo Medina 's suggestion, to be able to use this for different math sizes such as in subscripts, you can use \mathchoice to ensure that the symbol also adjusts in size depending on the surrounding math environment:

enter image description here

Code:

\documentclass{article} 
\usepackage{amssymb} 
\usepackage{graphicx} 

\newcommand\dashdownarrowi{\mathchoice%
    {\rotatebox[origin=c]{-90}{$\displaystyle\dashrightarrow$}}%
    {\rotatebox[origin=c]{-90}{$\displaystyle\dashrightarrow$}}%
    {\rotatebox[origin=c]{-90}{$\scriptstyle\dashrightarrow$}}%
    {\rotatebox[origin=c]{-90}{$\scriptscriptstyle\dashrightarrow$}}%
} 

\newcommand{\dashdownarrow}{\mathrel{\dashdownarrowi}} 

\begin{document} 
    $A\dashdownarrow B\quad M_{A\dashdownarrow B}\quad L_{M_{A\dashdownarrow B}}$ 
\end{document} 

Use \text{} for auto resizing (and change size):

egreg had provided a simpler way to get the same effect and that is by enclosing the symbol in \text{}, allows it to re size appropriately:

enter image description here

Notes:

  • In this version I added \scalebox so that you can make the symbol smaller -- adjust the scale factor to suit.
  • If you desire to move it vertically you can use \raisebox{<length>}{}.

Code:

\documentclass{article} 
\usepackage{amsmath} 
\usepackage{amssymb} 
\usepackage{graphicx} 

\newcommand\ddaaux{\rotatebox[origin=c]{-90}{\scalebox{0.70}{$\dashrightarrow$}}} 
\newcommand\dashdownarrow{\mathrel{\text{\ddaaux}}}

\begin{document} 
    $A\dashdownarrow B\quad M_{A\dashdownarrow B}\quad L_{M_{A\dashdownarrow B}}$ 
\end{document} 
share|improve this answer
    
Or \newcommand\dashdownarrow{\mathrel{\mathpalette\ddaaux\relax}} and then \newcommand\ddaaux[2]{\rotatebox[origin=c]{-90}{$#1\dashrightarrow$}} –  egreg Oct 10 '12 at 22:59
    
Or, with amsmath, \newcommand\dashdownarrow{\mathrel{\text{\ddaaux}}} and \newcommand\ddaaux{\rotatebox[origin=c]{-90}{$\dashrightarrow$}} –  egreg Oct 10 '12 at 23:00
    
Thanks, I'm going to try these all.. @Peter: I would prefer a bit smaller arrow, if possible. –  Berci Oct 10 '12 at 23:02
    
@egreg: Ingenious!! Don't think I have seen that trick before. Will update solution for egreg's suggestion, and also smaller arrow. –  Peter Grill Oct 10 '12 at 23:06
    
Well, for me, it's not rotating the right arrow but places it in a very odd place:( Is it possible that the xdvi viewer is the faulty? –  Berci Oct 10 '12 at 23:06
show 5 more comments

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.