[Tex/LaTex] \nearrow and \swarrow together

arrowsmath-mode

I'm trying to get an arrow that has an arrow head pointing north east and south west, so like \updownarrow but rotated. I can't seem to find this in LaTeX at all. It has to go inside an equation environment.

Any ideas?

Best Answer

The powerful \ooalign wins; TeX is able to figure out the widths itself.

\documentclass{article}
\usepackage{amsmath}

\DeclareRobustCommand{\neswarrow}{%
  \mathrel{\text{\ooalign{$\swarrow$\cr$\nearrow$}}}%
}

\begin{document}

$a\neswarrow b_{\neswarrow}$

\end{document}

enter image description here

See \subseteq + \circ as a single symbol ("open subset") for more information about \ooalign.