Solve for $p$ in this equation $\;2^{p−1}(2^p − 1) = X$.

218 Views Asked by At

Solve for $p$ in this equation $2^{p−1}(2^p − 1) = X$.

This is a general formula for finding $X$ (an even perfect number), where $p$ is any prime number. I want to find $p$ when $X$ is given, so that I can say $X$ is an even perfect number if $p$ is prime.

enter image description here

2

There are 2 best solutions below

0
On BEST ANSWER

we have $$ 2 2^{p-1}(2^p-1) = (2^p)^2 - 2^p = a^2-a = 2X, $$ with $a = 2^p$- hence $$ a^2-a-2X = 0 $$ the quadratic formula, which has solutions $$ a = \frac{1}{2}\pm \sqrt{1/4 + 2X} $$ skip the negative solution and solve for $p$ in $2^p=a$ $$ p = \log_2(a) = \log_2\left (\frac{1}{2}+\sqrt{\frac{1}{4}+2X} \right) $$

0
On

Hint

Set $Y=2^{p-1}$ then you equation is equivalent at $$Y(2Y-1)=X.$$