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

Prove that the equation $n^a + n^b = n^c$, with $a,b,c,n$ positive integers, has infinite solutions if $n=2$, and no solution if $n\ge3$.

share|cite|improve this question
(I know the answer, and I think it is nice enough to be worth posting) – mau Aug 2 '10 at 13:07
AFAIK, the theorem was first stated by <a href="">Egbert B. Gebstadter</a>. – mau Aug 3 '10 at 7:15
up vote 33 down vote accepted

So this is fermats last theorem upside down? It occurs to me if we have two binary numbers we may add them to get another power of two,

+ --------

but if we had two numbers in base 3, say

+ -------

we would not have so much luck.

share|cite|improve this answer
Wow, this is an easy and elegant solution for an apparently difficult problem. – Beska Aug 2 '10 at 14:54
This is awesome! – BBischof Aug 2 '10 at 17:14
Word to the wise: any Diophantine equation in which you can make all the terms only divisible by the same primes is easy. For example, it is very easy to solve variants of FLT of the form x^a + y^b = z^c provided a, b, c don't share too many common factors because one can just take x, y, z to be powers of the same integer. – Qiaochu Yuan Aug 2 '10 at 17:29
@Bill: Why do you think this is not a proof? It's saying that if we add two numbers of the form 10… in base n > 2, we get either 20… if they're equal or 10…10… otherwise, and in neither case do we get a number of the form 10…. Seems a sufficiently detailed proof to me. – ShreevatsaR Aug 2 '10 at 21:02
muad could have written: for the case n>=3, if we write n^a, n^b and n^c in base n, they will be of the form 1000..000, with the number of 0 in their expansion be equal to a, b, and c respectively. Now, the expression of the sum n^a + n^b written in base n is either is a number of the form 1000...0001000...000 if a != b or 2000...000 if a=b; in neither case we have a number of the form 1000....000. If n=2 and a=b, the sum becomes 1000...000 with a+1 zeroes, so this is a solution. // The procedure is the same. Or do you want a proof like in Principia Mathematica? – mau Aug 5 '10 at 13:48

Wlog $\,a \le b$. Dividing by $n^a$ yields $\,1 + n^{b-a} = n^{c-a}$ $\Rightarrow$ $b=a\ $ (else $\,n\mid1)\,$ $\Rightarrow$ $\, n = 2,\, c = a\!+\!1$.

share|cite|improve this answer
I am assuming the word Wlog stands for without loss of generality here. – Muhammad Alkarouri Feb 25 '12 at 19:04
Yes, that's what it means. – Bill Dubuque Jan 29 '14 at 15:37

If $n=2$ we can take $a=k, b=k, c=k+1$ for any $k \in \mathbb{N}$.

Let $n \ge 3$. We can assume that $a, b, c \ge 0$ because if not we could multiply left and right side by $n^k$ to make them positive.

Now it's clear that $c \ge a$ and $c \ge b$. Then we have $n^a | n^c$, hence $n^a | n^a + n^b$ and $a \le b$. In the same way $b \le a$. So $a = b$. Hence $2n^a = n^c$ and $n=2$.

share|cite|improve this answer
Man I hope they get this formula thing figured out soon. This answer looks like complete gibberish to me (I assume it's because all the the relevant formulae are just invisible). – Beska Aug 2 '10 at 14:54

Assuming $b>a$:


share|cite|improve this answer
The $<n^{b+1}$ needs to be a $lt n^{b+1}$ for $a=1$, and I cannot see why it works for $n=2$ from this – Tobias Kienzler Aug 2 '10 at 14:29
@Tobias For n=2 it works only if a<b -- and for n=2 one indeed has infinitely many solutions (of the form a=b=c-1). (And I couldn't understand the first part of your comment.) – Grigory M Aug 2 '10 at 14:36
sorry, I was on a wrong track there, please ignore that comment – Tobias Kienzler Aug 3 '10 at 7:29

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.