[Tex/LaTex] \bar below symbol

symbols

Is there a command like \bar{...} but such that the bar is placed below the symbol?

Of course there is \underline{...} but then the line is adapted to the width of the symbol and I don't want that (compare with the difference between \overline{...} and \bar{...}).

I need this for math mode.

Best Answer

The accents package has the feature you're looking for:

\usepackage{accents}
\newcommand{\ubar}[1]{\underaccent{\bar}{#1}}

Why the \newcommand? Because you might change your mind or find a new way to underline a symbol, so you can just modify the definition instead of hunting through the document for occurrences of \underaccent{\bar}.