[Tex/LaTex] Underline at the same level

fontsizetext-decorationsvertical alignment

I want to underline alpha's and beta's, but at the same level. I mean, I don't want
but . Maybe there is already a command that make it but I couldn't find it. The second image was obtained with the following command :

$\newlength{\espa}
\settowidth{\espa}{$\alpha$}\rlap{\underline{\hspace{\espa}}}\alpha,
\settowidth{\espa}{$\beta$}\rlap{\underline{\hspace{\espa}}}\beta$

which is hardly working but not totally. In normal math mode, no pbm. In scriptsize (or tiny or anything else) math mode, no pbm. But if I am in math mode within an exponent, then the \settowidth command does not seem to take into account that I am in sciptsize mode and, as a matter of fact, the underline is too long (e.g. ).

Any idea ?

Best Answer

$\underline{\smash{\beta}}$

will do the trick.