Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can i prove the statement that if the difference of cubes of two consecutive integers is an integral power of 2, then the integer with power 2 can be written as the sum of squares of two different integers.

For example:

$$8^3 - 7^3 = 13^2 = 12^2 + 5^2$$

Any help appreciated.


share|cite|improve this question
This is true of any odd square... See… – Brandon Carter Jun 21 '13 at 20:58
@BrandonCarter i want to know how can i prove this. – SHOBHIT GAUTAM Jun 21 '13 at 21:01
up vote 1 down vote accepted

We can see that $$n^3-(n-1)^3=3n^2-3n+1.$$ By looking at congruences modulo 4, we see that $$n^3-(n-1)^3=1\pmod 4.$$ Recalling that you assumed that the difference was a square, you can apply Fermat's theorem cited above to conclude.

share|cite|improve this answer
Thanks for that. – SHOBHIT GAUTAM Jun 21 '13 at 21:40

Im pretty sure youve heard of an identity $$ a^3-b^3=(a-b)*(a^2 + b^2 + ab) $$
If the above is a perfect square then it must be of form $a+b=n$ and $a^2 + b^2 + ab = n x^2$.

Now you can proceed. I think this method is good for an approach.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.