If $X = A^B + C$, why are C and X always divisible by A the same number of times?

64 Views Asked by At

So I was playing around with numbers in my free time and I stumbled across this neat little trick,
If
$X = A^B + C$
Where
$A$ is any integer
$B$ is an integer greater than $1$
$C$ is not a multiple of $A^B$
Then $X$ and $C$ will both be divisible by $A$ the same number of times.
So for example
$3^3 - 6 = 21$, $6$ and $21$ are only divisible by $3$ once
$2^5 + 8 = 40$, $8$ and $40$ are divisible by $8$

I find this really interesting and was wondering why it works.

3

There are 3 best solutions below

0
On BEST ANSWER

This can be simply explained through algebra and is a property of equations using integers. If you have an equation of the form

$$a=m(b+c)\,\,\,,\,\,\,a,b,c,m\in\mathbb Z\,\,\,,\,\,\,m\neq 0$$

then you can deduce that $a$ must be divisible by $m$ (as any property that applies to one side also applies to the other side of the equation as they're equal).

That's exactly what's happening in the example you give.


First consider the case where $X=A^ix$ where $i\in\mathbb N_0$ and $x$ is not a multiple of $A$, then you can rewrite your equation as

$$X=A^ix=A^B+C$$ $\implies$ $$C=A^ix-A^B$$

If $i\ge B$, then we can conclude

$$C=A^B(A^{i-B}x-1)$$

which means $A^B$ divides $C$, breaking one of your conditions.

Therefore, $i<B$ and we get

$$C=A^i(x-A^{B-i})$$

which means $A^i$ divides $C$.

Now let us consider the case where $C=A^jc$ where $j\in\mathbb N_0$ and $C$ is not a multiple of $A$. Now our equation is

$$X=A^B+A^jc$$

If $j\ge B$ then we can again conclude

$$X=A^B(1-A^{j-B}c)$$

which means $A^B$ divides $C$ breaking one of your conditions.

Therefore, $j<B$ and we get

$$X=A^j(A^{B-j}+c)$$

and so $A^j$ divides $X$.


Now we have shown:

If $A$ divides $X$ exactly $i$ times, then $A$ divides $C$ at least $i$ times.

If $A$ divides $C$ exactly $j$ times, then $A$ divides $X$ at least $j$ times.

Therefore, $A$ divides $X$ and $C$ the same number of times, leading to your conclusion.

0
On

Let $C= k \cdot A^n$ where $n$ is the biggest integer making $k$ an integer. Clearly, $k$ is not a multiple of $A$, and $C$ is divisible by $A$ only $n$ times.

Since $C$ is not a multiple of $A^B$, we must have $n < B$.

Then, $A^B+C = A^B + k \cdot A^n = A^n \big(A^{B-n} +k\big) =X$.

Observe, that $A^{B-n} +k$ is not a multiple of $A$, because $k$ is not a multiple of $A$.

Therefore $X$ also is divisible by $A$ only $n$ times.

0
On

Yes, this is true.

For proving this, let us suppose - $X$ is divisible by $A$, $m$ times $\implies X=p \cdot A^m$, and $C$, $n$ times.$\implies C=q \cdot A^n$

Now let us assume, $B>m,n$

Our equation is -

$$X=A^B+C$$

$$\implies p \cdot A^m=A^B+q \cdot A^n$$

Now if $m> n$, then - $$p \cdot A^m-A^B=q \cdot A^n$$

Here LHS is divisible by $A$ more than $m$ times, on the other hand RHS is divisible only $n$ times, giving us a contradiction. Similarly, the case $m<n$ will be rejected. Hence, the only possibility is $\color{blue}{m=n}3.

Similarly, this result can be proved even if $B<m$ and/or $B<n$.