Divisibility Trick for 11

elementary-number-theory

I am trying to prove the 11 alternating sum divisibility trick. I know that $10\equiv -1\pmod{11}$ so for every power of $10$ in a number, we should be able to substitute in $(-1)$ like so:

$$ a(10^n) + b(10^{(n-1)}+\cdots+ c(10) + d \equiv a(-1)^{n} + b(-1)^{n-1}+\cdots+c(-1)+d\pmod{11}$$

What I am having trouble understanding is the fact that starting from the left, we are taking an alternating sum of the digits $(a – b + \cdots$ ). Since each power of $10$ will always become a power of $(-1)$, how can we always use an alternating sum from the left side? That seems like it would change the underlying nature of what is happening with the mod depending on whether we have an even or odd number of digits in the number. For example, when we have a three digit number $a(-1)^3+b(-1)^2+c = -a+b-c$ but according to the rule we have $a-b+c$ verses when we have a four digit number $a(-1)^4+b(-1)^3+c(-1)^2+d = a-b+c-d$ which works with the rule.

Am I missing something obvious? Do I possibly just have the alternating sum rule written incorrectly in my notes?

Thanks!

Best Answer

You end with a $+$ for the final digit for the correct residue mod $11$. If you start from the left and pick the wrong sign for that but alternate anyway, it doesn't matter as the results will be each other's negative and if one is $0$ mod $11$ so is the other. So for divisibility it's equivalent.

Related Question