4

In math mode, I tried to type in $$\overline{a}+\overline{b}$$, and this happened:

enter image description here

Obviously, the lines over a and b look different. How do I fix this?

Troy
  • 13,741
Eric Lee
  • 143

1 Answers1

4

I wouldn't worry about the height and use \bar instead of \overline. Compare the results below: odd numbered lines have no adjustment, even numbered lines have \vphantom{b} to raise the bar; the first two lines use \overline, the next ones use \bar.

\documentclass[twocolumn]{article} % twocolum just for a smaller picture
\usepackage{amsmath}

\begin{document}

\begin{gather}
\overline{a}+\overline{b} \\
\overline{a\vphantom{b}}+\overline{b} \\
\bar{a}+\bar{b} \\
\bar{a\vphantom{b}}+\bar{b}
\end{gather}

\end{document}

enter image description here

egreg
  • 1,121,712