TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When using the following code I get unsightly spaces (following the opening parentheses, after the = and between the x' and y'):

[$](\quad \overline{x+y})=\quad \overline{x}\quad \overline{y}[/$]

Bad spacing

What am I doing wrong?

If it helps, I am using Anki with its default header and footer settings:



Also, please forgive me if I am unclear or have duplicated a question; I am new to TeX and unfamiliar with the terminology.

share|improve this question
That did the trick. I assumed that it was a requisite prefix to \overline. Cheers! – somehume Oct 23 '11 at 6:28
In the previous example, this was included merely to separate the difference instances of negation. – Werner Oct 23 '11 at 6:46
That made sense to me as soon as I read your comment to remove them, thank you! – somehume Oct 23 '11 at 6:49
up vote 4 down vote accepted

LaTeX provides a number of ways to print skips (blanks, or whitespace):

\def\thinspace{\kern .16667em }
\def\negthinspace{\kern-.16667em }
\def\enspace{\kern.5em }

The above are in addition to using \hspace{<len>} that you can use to print whitespace of length <len>. In your specific example, \quad skips "forward" by exactly 1em, which leaves the blank spaces you witness. Removing them leaves the correct typesetting:

enter image description here


With the introduction of some of these spaces, you can also improve the presentation by inserting (say) a \thinspace between the x and y:

enter image description here


For completeness, here's a table from Herbert Voss' mathmode document that illustrates some of the well-known spacing techniques/commands (Section 11.2 Additional horizontal spacing, Table 7, p 29):

enter image description here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.