[Tex/LaTex] Extra space between number and variable in math mode

math-modespacing

I find that if I typeset $3 q$, I find the 3 and the q a bit too close to each other. I know that I can manually add a thin space by typing: $3 \, q$.

  1. However, I was wondering if there was a way to automate this, i.e. that every time a number precedes a variable, a thin space is added.

    In other words I would like a thin space to be automatically added in $5 q$, but not in $5 7$.

  2. And is it possible to have added in $p q$ too? Do you recommend such practice between two variables that are multiplied? (I don't want to use \cdot as it clutters the display.)

Best Answer

TeX has a finely balanced system of setting spaces between various types of math "atoms". For example, consider the following simple formula:

$y = b + cx$  

equation of a straight line in x-y space with intercept b and slope c

Observe that the distance between y and = (and also between = and b) is slightly larger than that between b and +, which again exceeds that between c and x. This is done on purpose, of course, and the choices involved have proven their desirability over decades.

If you were to systematically increase the spacing between any two "atoms" that are multiplied together (such as c and x in the example above), you should also be willing to increase the spacing between all other types of "atoms" in order to preserve the overall balance. To claim that this would be a rather tricky enterprise would be a rather strong understatement.

In short, it's best not only to get used to TeX's way of typesetting mathematics but also to appreciate it for the high standard it sets. TeX's method is the standard against which all other systems for typesetting mathematics are judged and against which they, regrettably, almost invariably fail.

Related Question