3
$\begingroup$

I was asked to find divisibility tests for 2,3, and 4.

I could do this for 2 and 3, but for 4.

I could come only as far as:

let $a_na_{n-1}\cdots a_1a_0$ be the $n$ digit number.

Now from the hundredth digit onwards, the number is divisible by 4 when we express it as sum of digits.

So, the only part of the proof that's left is to prove that $10a_1+a_0$ is divisible by 4.

So if we show that this happens only when the number $a_1a_0$ is divisible by 4, the proof is complete.

So the best way to show it is by just taking all combinations of $a_1,a_0$ or is there a better way?

  • 0
    If $a_1$ is even, then the number is divisible by $4$ if and only if $a_0$ is divisible by $4$ ($a_0=0$, $4$, or $8$). If $a_1$ is odd, then the number is divisible by $4$ if and only if $a_0$ is even and not divisible by $4$ ($a_0=2$ or $a_2=6$). This because $20$ is a multiple of $4$, and $10$ leaves a remainder of $2$.2011-11-13
  • 0
    $10a_1 + a_0$ is by definition the number represented by the decimal string "$a_1a_0$", so I don't see any problem. Indeed, a number is divisible by 4 iff the number represented by the last 2 digits is.2011-11-13
  • 0
    @kira. $a_na_{n-1}\cdots a_1a_0$ is an $(n+1)$-digit number (not $n$-digit).2011-11-13
  • 0
    Why not just say $a_1a_0$ is divisible by 4? This would be an elementary "test". You could also use $a_1a_0$ is div. by 2 and the quotient is div. by 2.2011-11-13
  • 0
    @matt ya sorry for the mistake2011-11-13
  • 0
    and @arturo, that worked well than the answer given below although both intend to mean the same. thx guys2011-11-13

1 Answers 1

1

Note that $10a_1+a_0\equiv2a_1+a_0$ (mod 4). So for divisibility by 4, $a_0$ must be even and in this case $2a_1+a_0=2(a_1+\frac{a_0}{2})$. So, $a_1$ and $\frac{a0}{2}$ must be of same parity (means both are either even, or odd).