Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Multiples of Three

  1. Apr 18, 2010 #1

    Char. Limit

    User Avatar
    Gold Member

    Why is it that if the sum of the digits of a number is divisible by three, the number itself is also divisible by three?

    I've tried to do it, but I can't get anywhere. This is the best I have.

    Start with an integer x, which can also be written thus...


    Which gives us the digits of x. So, why is it that if...

    [tex]\frac{\sum_{i=1}^{n} x_i}{3} \in \mathbb{Z}[/tex]


    [tex]\frac{x}{3} \in \mathbb{Z}[/tex]

    for an n-digit number x?
  2. jcsd
  3. Apr 18, 2010 #2


    User Avatar
    Science Advisor
    Homework Helper

    Because you're working in base 10, and 10 = 1 (mod 3). If you were working in base 8, then the sum of the digits would be divisible by 7 iff the original number was.
  4. Apr 18, 2010 #3
    You should understand congruences:
    1 \equiv 1 (\textrm{mod} \, 3) \\
    10 \equiv 1 (\textrm{mod} \, 3) \\
    10^{2} \equiv 1 (\textrm{mod} \, 3) \\
    \cdots \\
    10^{n} \equiv 1 (\textrm{mod} \, 3)
    Multiplying each of the congruences by [tex]a_{n}[/tex], where [tex]a_{n}[/tex] is the nth digit from the right (the first one being labeled by [tex]a_{0}[/tex]), and having in mind that:

    x = \overline{a_{n} \cdots a_{1} a_{0}} = a_{n}*10^{n} + \cdots a_{1}*10 + a_{0}


    x \equiv (a_{n} + \cdots + a_{1} + a_{0}) (\textrm{mod} \, 3)

    Similarly, you can derive other criteria for divisibility.
  5. Apr 18, 2010 #4

    Char. Limit

    User Avatar
    Gold Member

    Thanks for the answers, I get it now. It makes total sense when you think about congruence, I guess.
  6. Apr 19, 2010 #5


    User Avatar

    Staff: Mentor

    Actually it is more like number (written in base 10) is divisible by 9 if sum of digits is divisible by 9, 3 is just a side effect.

    In general, this rule works for numbers in base n being divisible by n-1 if sum of digits is divisible by n-1.
  7. Apr 19, 2010 #6

    Char. Limit

    User Avatar
    Gold Member

    So the divisible-by-three rule would also work in base four, base seven, and any base 3n+1 then...

Share this great discussion with others via Reddit, Google+, Twitter, or Facebook