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

Can $2^n$ + $2^m$ be expressed as $2^x$ where $x$ is a function of $n$ & $m$?

I'm sure that this would require logarithms to find the answer but my maths is very rusty. Can anyone point me at the solution please? If this can't be done can someone explain why not please?

share|cite|improve this question
$x = \log_2(2^n + 2^m) = \min\{n,m\}\log_2(1 + 2^{\max\{n,m\} - \min\{m,n\}})$. – Neal Dec 3 '12 at 4:24
(Note that you can't do it for $m,n,x$ integers: $2 + 4 = 6$.) – Neal Dec 3 '12 at 4:25
@Neal As for the integer case $2^m+2^n$ is a power of 2 iff $m=n$. A proof of uniqueness can be derived from looking at the binary expansion. – peoplepower Dec 3 '12 at 4:49
@peoplepower That's a really clever idea for a proof. A+. – andybenji Dec 3 '12 at 5:10
up vote 1 down vote accepted

Without loss of generality, we can take $n\ge m$

Let $r=n-m,$ so $r\ge0$

$2^n+2^m=2^m(1+2^r)$ will is odd if $r>0$

So, $r=0,$ consequently, $n=m, 2^n+2^m=2\cdot 2^m=2^{m+1}$

More generally, $a^{m+r}+a^m=a^m(1+a^r)$ where $a,m,r$ are natural numbers

But $(1+a^r,a)=1$ if $r>0$

So, $r=0, a^{m+r}+a^m=2a^m$

If $a^x=2a^m,a^{x-m}=2\implies a=2,x=m+1$

share|cite|improve this answer
thank you so much. – Preet Sangha Dec 3 '12 at 10:35

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.