2

Following this answer to the question "Is a prime number still prime in a different base?", I would like to understand more generally why the operation of "change of base" (or radix conversion) does not affect the intrinsic "properties" of numbers (e.g. their decompositions as a product or sum of other numbers).

I think this is equivalent to asking why a change of base preserves the operations of addition and multiplication -- or more formally: "why is radix representation a ring isomorphism"?

A hand-wavy intuition is that, since the representation of a positive natural number $n$ in base $b$ can be obtained as: $$ \forall\ n\geq 1,\quad n = \sum_{k=0}^{L-1} d_k b^k $$ where $L = 1 + \lfloor\log_b(n)\rfloor$ and $$ \begin{align} d_0 &= n\mod{b} \\ \forall\ 0\leq k<L,\quad d_{k+1} &= \frac{n - \sum_{i=0}^k d_i b^i}{b^{k+1}}\mod{b} \end{align} $$ it seems to depend directly on the properties of the modulus itself, to preserve addition and multiplication (which it does). In other words, this seems to be yet another consequence of the Euclidean algorithm. However, I am not sure how to:

  • Actually prove that the modulus preserves addition and multiplication;
  • Relate this property formally to the "change of base" operation.

I am not a category theorist, and I only have a basic understanding of number theory; if at all possible, it would be great if the explanation remained as easy to understand as possible.

Jonathan H
  • 2,233
  • 16
  • 29
  • 2
    Addition and multiplication of the base-$b$ representations are defined to be compatible with the addition and multiplication of the numbers. – Daniel Fischer Jun 11 '18 at 14:07
  • 1
    Perhaps it is simpler to consider the counting operation with different bases, and why the choice of radix doesn't interfere with correct counting. – hardmath Jun 11 '18 at 14:11
  • To elaborate on Daniel's comment ever so slightly: the mapping $n\to r(n)$ you learned about in Bill's answer (which you linked to) is defined to be a ring isomorphism. (You define $r(n)+r(m)$ and $r(n)\cdot r(m)$ so that the map is an isomorphism.) In this sense, I don't see why Bill thinks it's non-trivial. It's rather like defining a map on the basis of a vector space and then extending it to a homomorphism "by linearity." One doesn't then need to check that the result is a homomorphism; it is one by construction. This is not an artful dodge, as you comment below. – symplectomorphic Jun 11 '18 at 14:20
  • @hardmath I think this might be what I am actually asking. – Jonathan H Jun 11 '18 at 14:21
  • @symplectomorphic I find your comment very helpful, but although it is now clear to me that the radix representation is defined to have these properties, it is still unclear why their "concrete implementation" using Euclide's algorithm actually verifies these properties. Am I running in circles? – Jonathan H Jun 11 '18 at 14:32
  • It's not the "radix representation" per se that is "defined to have these properties," but rather the operations on the radix representations ($+$ and $\cdot$ for the representations). You aren't running in circles. You're just not carrying the argument all the way through. If the map $r$ is an isomorphism, then any arithmetic properties (such as gcd) are preserved by passing to representations, and vice versa. – symplectomorphic Jun 11 '18 at 14:45
  • 1
    A final abstract comment. If you have a ring $(S, +_S, \cdot_S)$ and a bare set $T$ and a set isomorphism $\phi$ (bijection) between $S$ and $T$, then you can make $T$ into a ring by using the isomorphism to transport $+_S$ and $\cdot_S$ to $T$. (Just define $t_1+_Tt_2$ to be $\phi^{-1}(t_1)+_S\phi^{-1}(t_2)$.) That's all that's going on here. – symplectomorphic Jun 11 '18 at 14:54
  • Typo (I'm writing on my phone): the sum of the $t$'s should be the image (under $\phi$) of what I wrote. – symplectomorphic Jun 11 '18 at 15:14

2 Answers2

4

Let us talk non-negative numbers. Addition and multiplication can be defined, starting from the Peano axioms, with no reference to any base.

If you then decide to write down numbers with respect to a particular base $b$, all you do is to implement addition and multiplication algorithms (along the familiar lines of base $10$) with respect to that particular base $b$.

  • So basically I got it backwards; as Daniel Fisher said in comment, the radix representation is defined to be compatible with the operations of addition and multiplication, which themselves are independent of any base. This seems an awfully convenient way (though legitimate I guess) to evade the question of why this actually works. – Jonathan H Jun 11 '18 at 14:12
  • 1
    It was grappling with questions such as yours that led Peano and other mathematicians to define addition and multiplication (and more fundamental concepts such as equality and the successor function) in a way that is independent of how numbers are represented. If we didn't have a representation-independent definition of arithmetic then we would have to check that the rules of arithmetic in each representation were consistent with those in some favoured "canonical" representation - say base 10 for example. – gandalf61 Jun 11 '18 at 15:05
  • See also @symplectomorphic comments for further explanations. – Jonathan H Jun 11 '18 at 15:06
  • @gandalf61 I agree, but it still seems odd to me that the radix representation preserves arbitrary decompositions as products or sums. Again, I am not a number/category theorist, but I can see (very loosely) relations between radix representation / polynomials / linear algebra / continuous fractions / Galois field; and Euclide's algorithms seems to always pop up around all very basic questions. I find this very odd, and I feel that there is a bigger picture that I might be missing. – Jonathan H Jun 11 '18 at 15:19
2

When we represent a number in a base $b$, all that we are doing is providing a way of describing it. The number ten, for instance, is $10$ in base $10$, $1010$ in base $2$ and $X$ in roman numerals. But it is always the same number. Therefore, the choice of base cannot possibly affect the number itself.