# Show that the number $n$ is divisible by $7$ [duplicate]

How can I prove that $n = 8709120$ divisible by $7$? I have tried a couple methods, but I can't show that. Can somebody please help me?

First, you can subtract 7 from the large digits. 8-7=1 and so on, so you are left with $1002120$.
Then, it is true that 1001 is a multiple of 7. So subtract 1001000 from the number, and you have 1120.
Lastly, divide 7 into 112 using short division.

This is equivalent to $1002120$ is divisible by $7$.

As $7|98$, this is equivalent to $22120$ is divisible by $7$, or $1120$ is divisible by 7.

It is true as $112 = 98 + 14 = 7\times 14 + 7\times 2$.

It seems the following.

8709120 is divisible by 7 iff

870912 is divisible by 7 iff

100212 is divisible by 7 iff

112 is divisible by 7 (because 1001 is divisible by 7) iff

42 is divisible by 7

The Divisibility test for 7 is:

A number of the form $10x + y$ is divisible by 7 if and only if $x − 2y$ is divisible by 7, where $y$ is a numeral (0-9).

Knowing this, we can apply the divisibility test onto 8709120. We iterate multiple times to find a small enough number

First Iteration: $870912$

Second Iteration: $87091-4=87087$

Third Iteration: $8708-14=8694$

Third Iteration: $869-8=861$

Third Iteration: $86-2=84$

$84=7\times12$, so we can conclude that $8709120$ is divisible by 7

As $21x-2(10x+y)=x-2y\implies7\mid(10x+y)\iff 7|(x-2y)$

Similarly, $5(10x+y)-49x=x+5y\implies7\mid(10x+y)\iff 7|(x+5y)$

Since $7\cdot 13=91$, we only need to prove that $1000020$, or $100002$, is divisible by $7$: $$10^5+2 \equiv 3^{-1}+2\pmod{7} \equiv 0\pmod{7},$$ since $3\cdot 5\equiv 1\pmod{7}$, or just because $2+\frac{1}{3}=\frac{\color{red}{7}}{3}.$

First, note that

$$1 \equiv 1 (\bmod 7)$$

$$10 \equiv 3 (\bmod 7)$$

$$10^2 \equiv 2 (\bmod 7)$$

$$10^3 \equiv -1 (\bmod 7)$$

$$10^4 \equiv -3 (\bmod 7)$$

$$10^5 \equiv -2 (\bmod 7)$$

$$10^6 \equiv 1 (\bmod 7)$$

$$\ldots$$

So, if the number $n$ has these digits: $n = \overline{...d_7 d_6d_5d_4d_3d_2d_1d_0}$, then $$n \equiv 1\cdot (d_0 - d_3 + d_6 - d_9 + ...) \\ + 3\cdot (d_1 - d_4 + d_7 - d_{10} + ...) \\ + 2\cdot (d_2 - d_5 + d_8 - d_{11} + ...) \\ (\bmod 7)$$

It is easy to apply this test:

$$8709120 \bmod 7 \equiv 1\cdot (0-9+8) + 3\cdot (2-0) + 2\cdot (1-7) = -1+6-12 = -7 \equiv 0 (\bmod 7)$$

Hence, $8709120$ is divisible by $7$.

Without wasting any thoughts on whether it was $101$ or $1001$ or ... that is a multiple of $7$, repeatedly subtract obvious multiples of $7$: $$\underline 8\underline70\underline9120 \to \underline{10}0\underline{21}20\to \underline{30}0020\to\underline{20}020\to\underline{60}20\to\underline{42}0\to 0$$

There is a well-known test for the divisibility of a number by $7$.

$a_k\dots a_1a_0$ is divisible by $7$ if and only if $a_2a_1a_0-a_5a_4a_3+a_8a_7a_6-\dots$ is divisible by $7$.

So split $8709120$ into groups $008,709,120$.

Then calculate $008-709+120=-581$.

$-581\div7=-83\implies8709120$ is divisible by $7$.

For the record, I have asked a related question once, and I used the answer I got to answer yours.

1) $8709120=7000000+1709120$

2) $1709120=1400000+309120$

3) $309120=280000+29120$

4) $29120=28000+1120$

5) $1120=700+420$,

$8709120=7000000+1400000+280000+28000+700+420$ is divisible by $7$.