# Spacing numbers in two equations equally

I have this weird requirement, to align two sets of numbers, one under another, in groups of three.

Here is how it should look:

I tried the following:

\begin{align*}
x_F &= 1.368 &808 & 107 & 853 & 223 &5… \text{ — Approximate answer;}\\
x_T &= 1.368 &808 & 107 & 821 & 372 &6… \text{ — true (correct) value.}
\end{align*}

but all I get is this:

As you can see for some reason 808107 does not want to separate!

P.S.: Bonus points if you give me a hint on how to align that text on the right too!

-
\num{} command from siunitx may be? Or, if you prefer manually, just add \, where you want that tiny space. By the way that's not a correct way of using align. In your code, only the & before the = should be there, the other aligning/spacing shouldn't be obtained in that way. And what do you exactly want to align in the right? –  Manuel Mar 6 '13 at 21:41
otherwise alignat –  cmhughes Mar 6 '13 at 21:46

There are a number of ways to obtain this, but siunitx provides this in the most consistent (and manageable) way possible:

\documentclass{article}
\usepackage{siunitx,amsmath}% http://ctan.org/pkg/{siunitx,amsmath}
\begin{document}
\begin{align*}
x_F &= 1.368 &808 & 107 & 853 & 223 &5\ldots \text{ -- Approximate answer;}\\
x_T &= 1.368 &808 & 107 & 821 & 372 &6\ldots \text{ -- true (correct) value.}
\end{align*}
\begin{alignat*}{6}
x_F &= 1.368 &\,& 808 &\,& 107 &\,& 853 &\,& 223 &\,& 5\ldots \text{ -- Approximate answer;}\\
x_T &= 1.368 &\,& 808 &\,& 107 &\,& 821 &\,& 372 &\,& 6\ldots \text{ -- true (correct) value.}
\end{alignat*}
\begin{align*}
x_F &= \num{1.3688081078532235}\ldots \text{ — Approximate answer;}\\
x_T &= \num{1.3688081078213726}\ldots \text{ — true (correct) value.}
\end{align*}
\end{document}

The above alignat inserts a \, (\thinspace) at at the required alignment locations. However, by default, \num from siunitx has a three-digit separation. Moreover, the code is legible, and easily modifiable.

This naturally leads to a correct left-alignment of the text.

-

You can use the fact that the default math font uses digits that are all the same width, so you only need one alignment point.

\documentclass{article}

\usepackage{amsmath}

\begin{document}

\begin{align*}
x_F &= 1.368 \,808 \, 107 \, 853 \, 223 \,5\ldots \quad \text{ --- Approximate answer;}\\
x_T &= 1.368 \,808 \, 107 \, 821 \, 372 \,6\ldots \quad \text{ --- true (correct) value.}
\end{align*}

\end{document
-