Prime number proof

105 Views Asked by At

Given that $n>2$. Prove that if $2^n-1$ is prime then $2^n+1$ is composite or vice versa. I looked on wikipedia on Fermat number and Mersenne prime, but I still don't know how they work.

3

There are 3 best solutions below

5
On

Clearly you can't prove that $2^n-1$ composite implies $2^n+1$ is prime. Take $n=6$, for example. Going the other way, think about divisibility by $3$.

1
On

At least one of $2^n-1$ and $2^n+1$ must be divisible by $3$, and neither of them is $3$. Thus, at least one of them is composite.

0
On

Hint $\ a\mid (a\!-\!1)^n\!\pm 1\ $ since $ $ mod $\ a\!:\ (a\!-\!1)^n \equiv (-1)^n\equiv \pm 1$

e.g. $\,\ 10\mid 9^n\pm1\, $ is a well-known case (power's of $9$ end with digit $1$ or $9)$

Your case can be viewed as the analogy in radix $\,3.$