# Automatically-adjusted spacing for scientific notation in siunitx

With the input

[ n=CV = \SI{3.29e-3}{\micro\mol\per\L} \times \SI{8e-4}{L} = \SI{2.63}{\micro\mol} \]


I get output

As you see the spacing is not quite right - I really want the spacing of the scientific notation to be tighter, the terms 8 \times 10^-6 grouped together so it maintains its distinctness.

Edit: I noticed an arithmetic error; I left out e-06 on the RHS of the equation, but that's beside the point! :P

@aghsmith + @ Joseph Wright: Current accepted solution (2) compared with original (1).

It may be as good as it gets but I still have reservations about reading a page full of these kinds of scientific notations mixed with operators, numbers and units. The different terms meld into each other and it is difficult to discern discrete terms. Aghsmith's solution offers an improvement, but I can't help thinking more could be done with the spacing.

Solution accepted but still open to further suggestions for improvements, assuming I don't have the luxury of omitting or units or using dots for multiplication signs. I have thought about using \quad to increase the spacing between terms but that is too much manual effort...

-
instead of the second \times, try \cdot which gives a small dot. – Tom Bombadil Sep 7 '11 at 9:41
Personally, I'd add brackets in this case, or more usually omit the units in the calculations. – Joseph Wright Sep 7 '11 at 9:41
@ Tom Bombadil: The Tom Bombadil of Tolkien LoTR fame? Using a mix of dots and crosses is a great idea. – ptrcao Sep 7 '11 at 10:43
@Joseph Wright: Brackets might have to suffice. :) I'm not allowed to leave out the units unfortunately. :P – ptrcao Sep 7 '11 at 11:02
@ptrcao. siunitx is meant for typesetting units - the request looks more like a calculation, which is unsurprisingly more awkward to handle. In many ways, this is a question more of style than of code. – Joseph Wright Sep 7 '11 at 11:07
show 1 more comment

Use the tight-spacing=true option:

 \documentclass{article}
\usepackage{amsmath}
\usepackage{siunitx}

\begin{document}

$n=CV = \SI[tight-spacing=true]{3.29e-3}{\micro\mol\per\L} \times \SI[tight-spacing=true]{8e-4}{L} = \SI[tight-spacing=true]{2.63}{\micro\mol}$

\end{document}


or you can put that in the package options, or options just for the local environment:

  \sisetup{tight-spacing=true}

-