# clarification on binary and decimal representations of integers

This is from the book: Elementary number theory, David M. Burton, page 69.

Given an integer $b>1$, any positive integer $N$ can be written uniquely in terms of powers of $b$ as $$N=a_{m}b^{m}+a_{m-1}b^{m-1}+\cdots +a_{2}b^{2}+a_{1}b+a_{0},$$ where the coefficients $a_{k}$ can take on the $b$ different values $0,1,2,\dots,b-1$.

For the Division Algorithm yields integers $q_{1}$ e $a_{0}$ satisfying $$N=q_{1}b+a_{0},\,0\leq a_{0}< b.$$ If $q_{1}\geq b,$ we can divide once more, obtaining $$q_{1}=q_{2}b+a_{1},\, 0\leq a_{1}< b.$$ Now substitute >for $q_{1}$ in the earlier equation to get $$N=(q_{2}b+a_{1})b+a_{0}=q_{2}b^{2}+a_{1}b+a_{0}$$ As long as $q_{2}\geq b,$ we can continue in the same fashion. Going one more step: $q_{2}=q_{3}b+a_{2}$, where $0\leq a_{2}<b$; hence $$N=q_{3}b^{3}+a_{2}b^{2}+a_{1}b+a_{0}$$ Because $N>q_{1}>q_{2}>\cdots \geq 0$ is a strictly decreasing sequence of integers, this process must eventually terminate, say, at the $(m-1)$th stage, where $$q_{m-1}=q_{m}b+a_{m-1},\,0\leq a_{m-1}<b$$ and $0\leq q_{m}<b$. Setting $a_{m}=q_{m}$, we reach the representation $$N=a_{m}b^{m}+a_{m-1}b^{m-1}+\cdots +a_{2}b^{2}+a_{1}b+a_{0}$$ which was our aim.

After that the author proves the uniqueness.

My question is, once the integers $a_{i}$ and $q_{i}$ are unique, is this not enough to ensure the uniqueness of the representation?

-

The uniqueness of the integers $a_i$ and $q_i$ means that there is a unique base-$b$ representation of $N$ that is obtainable by the described algorithm — that is, the algorithm doesn't involve any arbitrary choices. It doesn't rule out the possibility that there could be some other representation that was not so obtainable.
On the other hand, one way of proving uniqueness would be to argue that any representation of $N$ must be obtainable by applying the algorithm.