# Proof that the sum of the cubes of any three consecutive positive integers is divisible by three. [duplicate]

So this question has less to do about the proof itself and more to do about whether my chosen method of proof is evidence enough. It can actually be shown by the Principle of Mathematical Induction that the sum of the cubes of any three consecutive positive integers is divisible by 9, but this is not what I intend to show and not what the author is asking. I believe that the PMI is not the authors intended path for the reader, hence why they asked to prove divisibility by 3. So I did a proof without using the PMI. But is it enough?

It's from Beachy-Blair's Abstract Algebra Section 1.1 Problem 21. This is not for homework, I took Abstract Algebra as an undergraduate. I was just going through some problems that I have yet to solve from the textbook for pleasure.

Question: Prove that the sum of the cubes of any three consecutive positive integers is divisible by 3.

So here's my proof:

Let a $\in$ $\mathbb{Z}^+$

Define $$S(x) = x^3 + (x+1)^3 + (x+2)^3$$

So,

$$S(a) = a^3 + (a+1)^3 + (a+2)^3$$

$$S(a) = a^3 + (a^3 + 3a^2 + 3a + 1) + (a^3 +6a^2 + 12a +8)$$

$$S(a) = 3a^3 + 9a^2 + 15a + 9$$

$$S(a) = 3(a^3 + 3a^2 + 5a + 3)$$

Hence, $3 \mid S(a)$.

QED

• It’s just fine, if you want to prove that $S(a)$ is divisible by $3$. Apr 8, 2013 at 0:09
• Simpler: $\rm\ mod\ 3\!:\ 0^3\!+1^3\!+2^3\equiv 0 + 1 + 8\equiv 0\ \$ Apr 8, 2013 at 0:10
• Even simpler if you use $2\equiv -1$. Apr 8, 2013 at 0:10
• @MathGems: So does the modular arithmetic, if one hasn’t yet enountered it. Apr 8, 2013 at 0:12
• @Derek For divisibility problems your first instinct should be modular arithmetic. It often simplifies such problems, because working with equations (congruences) is usually simpler than working with relations (divisibility). Apr 8, 2013 at 0:51

Your solution is fine, provided you intended to prove that the sum is divisible by $3$.

If you intended to prove divisibility by $9$, then you've got more work to do!

If you're familiar with working $\pmod 3$, note @Math Gems comment/answer/alternative. (Though to be honest, I would have proceeded as did you, totally overlooking the value of Math Gems approach.)

• Yes, I intended to show divisibility by 3. My comment was just that it is possible to show by 9 as well, but that was not what I intended to show. Apr 8, 2013 at 0:26
• Well, you did just fine, and as I mentioned, I would have proceeded in the same direction ;-) Apr 8, 2013 at 0:28
• Nice Amy $_{+}^{+}..._{+}^{+}$ Apr 8, 2013 at 6:01

If you are familiar with modular arithmetic, there are even much faster proofs, see the comments.

Or, instead of $x,x+1,x+2$, you could start out from $x-1,x,x+1$. But no more evidence is needed than yours.

You have actually done enough work to show that the sum of the $3$ cubes is divisible by $9,$ not juat by $3,$ but you haven't explained that step: Note that (mod $9$), $S(a)$ is the same as $3(a^{3}+5a).$ But $a^{3}-a$ is divisible by $3$ for all integers $a,$ as you can see by checking $(3b-1)^{3}$ and $(3b+1)^{3}$ for integers $b.$ Hence $S(a) = 18a +9b$ for some integer $b.$

• Note $\rm\,\ x^3\!+\!(x\!+\!1)^3+(x\!+\!2)^3 = 3(x^3\!-\!x) + 9(x\!+\!1)^2\ \$ Apr 8, 2013 at 1:15
• I was taking where the proposer had got to as my starting point, and commenting on what he had achieved, not trying to point out the quickest proof. Apr 8, 2013 at 6:19

As was already mentioned, modular arithmetic is the most efficient way to solve this problem, but, if you really want to avoid it, you can still get by with slightly easier computation (smaller coefficients). Introduce a name, say $y$, for the middle one of the three integers, rather than the smallest. So you'd add $(y-1)^3+y^3+(y+1)^3$, which leads to a fair amount of cancellation and no coefficients bigger than 6.

Any 3 consecutive numbers will always be of the form 3k-1,3k,3k+1.So 3k-1 ≡ -1mod 3. Where mod a ≡ x mod y means that x is the reminder obtained when a is divided by y.(3k-1)^3 ≡ -1 mod 3 . Similarly, 3k ^3 ≡ 0 mod 3. (3k+1)^3 ≡ 1 mod 3. Therefore (3k-1)^3 + (3k)^3 + (3k+1)^3 ≡ -1 + 0 + 1 mod 3 ≡ 0 mod 3. Hence it is always divisible by 3.

I like the three consecutive integers to be $k -1$, $k$,$\, k + 1$, the sum of whose cubes are $3k(k^2 + 2)$, but that is just a matter of taste.

Your approach and deduction is absolutely fine Just for the sake of completeness, here is an alternative prove

Known

$$(a+b+c)^3 = a^{3} + b^{3} + c^{3} + 3 a^{2} b + 3 a^{2} c + 3 a b^{2} + 3 a c^{2} + 3 b^{2} c + 3 b c^{2} + 6 a b c$$ $$= a^{3} + b^{3} + c^{3} + 3f(a,b,c)$$

Let $a=k-1,b=k,c=k+1$,then, $a,b,c$ represents consecutive numbers

So we have $$(a+b+c)^3=(k-1+k+k+1)^3=(3k)^3=27k^3$$ Thus $$a^{3} + b^{3} + c^{3} = (a+b+c)^3 - 3\cdot f(a,b,c) = 27k^3-3\cdot f(a,b,c)$$ $$\Rightarrow a^{3} + b^{3} + c^{3}=3\cdot(9k^3-f(a,b,c))$$

The set (unordered) of three consecutive numbers in module 3 is { 0, 1, -1 }

(-1)^3 = -1 (mod 3) [ equivalent: 2^3 = 2 (mod 3) ]

(0)^3 = 0 (mod 3)

(1)^3 = 1 (mod 3)

The sum of the three cubes is 0 (mod 3).