# Proving that $2^{2^n} + 5$ is always composite by working modulo $3$

By working modulo 3, prove that $2^{2^n} + 5$ is always composite for every positive integer n.

No need for a formal proof by induction, just the basic idea will be great.

The basic idea is, work modulo 3. What happens, modulo 3, when you raise 2 to an even power?

• I have no idea actually, I'm pretty new to mod arithmetic Commented Aug 14, 2012 at 13:09
• You're not supposed to have an idea, you're supposed to actually do it! Raise 2 to an even power! See what happens modulo 3! Raise 2 to another even power! See what happens modulo 3! Repeat, until you do have an idea! Then try to prove it! Commented Aug 14, 2012 at 13:16

Obviously $2^2 \equiv 1 \pmod 3$.

If you take the above congruence to the power of $k$ you get $$(2^2)^k=2^{2k} \equiv 1^k=1 \pmod 3$$ which means that $2$ raised to any even power is congruent to $1$ modulo $3$.

What can you say about $2^{2k}+5$ then modulo 3?

It is good to keep in mind that you can take powers of congruences, multiply them and add them together.

If you have finished the above, you have shown that $3\mid 2^{2k}+5$. Does this imply that $2^{2k}+5$ is composite?

• Then $2^{2k} + 5 ≡ 0 mod 3$ so $3|2^{2k}+5$ and thus $2^{2k}+5$ can't be prime and is composite. Correct? Commented Aug 14, 2012 at 13:43
• What you wrote is correct. Maybe you should also mention that $2^{2k}+5>3$. (If you know that $3<s$ and $3\mid s$ then $s$ is composite. If you omit the condition that $3<s$, then this is not true, since you can take $s=3$, which is prime.) Commented Aug 14, 2012 at 13:46
• Got it! Thank you sir. Commented Aug 14, 2012 at 13:49
• Thanks @RossMillikan, I've corrected that. Commented Aug 14, 2012 at 14:24

Hint: Rewrite the base using the fact that $2\equiv -1 \bmod 3$.

In order to work out this problem, we start by noticing $2^2\equiv 1 ~~~(\text{mod } 3)$.

What this means is $2^2$ (which is $4$) is $1$ greater than some multiple of $3$ (that multiple, in this case is obviously, $3$)

So if $2^2\equiv 1 ~~~(\text{mod } 3)~~\implies (2^2)^n\equiv (1)^n ~~~(\text{mod } 3)\implies 2^{2n}\equiv 1~~(\text{mod } 3)$,
Again, this means that any even power of $2$ is $1$ greater than some multiple of $3$.

So if $2^{2n}$ is $1$ greater than some multiple of $3$ (another way to say this is that $2^{2n}$ leaves a remainder of $1$ when divided by $3$), then what can you say about $2^{2n}+5$?.

To answer this, forget about $2^{2n}$ and just think about the remainder (i.e $1$). This is how modular arithmetic makes our live a lot easier. If $2^{2n}$ is $1$ greater than some multiple of $3$, then $2^{2n}+5$ should be $1+5=6$ greater than that multiple of $3$, right? But you know that $6$ is, by itself, a multiple of $3$. So, this should mean that $3|2^{2n}+5$.

A more formal (and a neat) argument could be:
$3|2^{2n}-1\implies 3|2^{2n}+5$, since $2^{2n}+5=(2^{2n}-1+6)$

Now since it has been shown that $2^{2n}+5$ is infact a multiple of $3$, it should be apparent that $2^{2n}+5$ is after all, composite.

I Hope it helps!

• Weird explanation and weird disclaimer: what "technical jargon" did Gerry's answer use? Idea, work, raise...? The only technicallity there is modulo 3, which is both (1) boringly elementary, and (2) even the OP uses it...and of course, so do you. So what technical jargon did you avoid using that the other two answers did? Commented Aug 14, 2012 at 18:04
• First of all, please do note that I am not comparing my answers with others. Now that I read my answer, I realize that I badly phrased my little disclaimer :) What I mean to say is I have included parts like "...this means that any even power of 2 is 1 greater than some multiple of 3..." in my answer which are obvious. So I guess I need to edit/ delete the disclaimer, eh?
– user11470
Commented Aug 14, 2012 at 18:11
• I didn't say anything about you "comparing", but about you implying that your answer won't be "technical" as the other ones, whereas it actually was. That's all. Nothing to be too touchy about. Commented Aug 14, 2012 at 18:35

$2^(2n) +5$ is the same as $4^{n} +5 =(3+1)^n +5$
If you expanded the $(3+1)^n$ part , every term would be divisible by $3$ (except the last term $1$) The entire expression would be of the form $(3m +1) +5 = 3m +6$ which is divisible by $3$.

• Heavily recommended: to take a peek at the LaTeX section to properly write mathematics in this forum Commented Aug 14, 2012 at 18:38
• To expand a little on DonAntonio's comment: For some basic information about writing math at this site see e.g. here, here and here. Commented Aug 15, 2012 at 5:31

Separate 5 into 2 and 3 and take 2 with the power term. Take 2 common from there and you will be left with: $$2(2^{2^n-1}+1)+3$$ we know that numbers of form $$a^n+b^n$$ are always divisible by a+b if n is odd. So number is composite and divisible by 3 for all n