# Homework Help: Base representation ~

1. Jan 28, 2010

### sty2004

base representation plz help~

It is known that if asks+as-1ks-1+...+a0 is a representation of n to the base k, then 0<n<=ks+1-1.

Now suppose n=asks+as-1ks-1+...+a0 and m=btkt+bt-1kt-1+...+b0 with as,bt not equal to 0, are two different representations of n and m to base k, respectively. Without loss of generality we may assume t>=s. Without using Theorem 1-3(existance and uniqueness of such representation of an integer), prove directly that m not equal to n.

Many many thanks~~~

2. Jan 28, 2010

### telesyn

Re: base representation plz help~

We consider the difference :
$$D = m-n = c_tk^t + c_{t-1}k^{t-1} + ... + c_0$$
Where $$c_i = b_i - a_i$$ ( $$i$$ from $$1$$ to $$t$$, and $$a_i = 0$$ if $$i > s$$)

Due to the fact that $$a_sa_{s-1}...a_1$$ and $$b_tb_{t-1}...b_1$$ are two different representations, $$c_i$$ must not equal to 0 for every i, otherwise $$a_i = b_i$$ for all $$i$$.

Choose $$j$$ is the largest number such that $$c_j$$ is different from
If $$c_j > 0$$,then:
$$D >= k^j -(k-1)(k^{j-1} + ... 1) = k^j -(k^j-1) = 1 >0$$
If $$c_j < 0$$, similarly $$-D > 0$$

We always have $$D$$ different from 0

Good luck.