# Downarrow whose length I can specify manually

Is there a way to draw a $\Downarrow$ command of a custom length? I need a double arrow. I am sure such a command exists.

I also need this symbol to be able to align inside align environment using &.

\Downarrow is expandable. See:

\documentclass{article}

\begin{document}

$\left\Downarrow\frac{a}{b}\right.$
\end{document}


If you give material of a specified height, this arrow will expand (near) to this value, e.g. (suggested by Gonzalo Medina)

\newcommand\vardarrow[1]{\left\Downarrow\rule{0pt}{#1}\right.}.

• I tried to define this newcommand in the preamble and then used \vardarrow{20pt} and i got an error saying: Missing \begin{document}. ...1]{\left\Downarrow\rule{Opt{#1}\right.}.
– 71GA
Apr 25 '13 at 6:09

You can't get precise height, because of how \left works, but the difference will be small.

\documentclass{article}

\newcommand{\xDownarrow}[1]{%
\ensuremath{%
\left\Downarrow\vbox to #1{}\right.\kern-\nulldelimiterspace
}%
}

\begin{document}
\xDownarrow{1cm}\rule{0.4pt}{1cm}
\end{document}


The rule is just for comparison.