SEARCH THIS BLOG :-)

Monday, 14 December 2015

FORMULA FOR PRIME NUMBERS - NOVELTY - WILLAN'S FORMULA

WILLAN'S FORMULA

Some people say there is no formula for the prime numbers!
This is not quite true. There are a few around.
They are highly inefficient in calculation and unwieldy and not generally well respected formulas.
But they are of some novelty interest from a number theoretic perspective.
One such formula is Willan's Formula.

Let $p_n$ denote the $n$th prime number. Then Willan's Formula is
$$p_n=1+\sum_{m=1}^{2^n} \left\lfloor \sqrt[n]{n}\left( \sum_{x=1}^m\left\lfloor \cos^2\left( \pi{(x-1)!+1 \over x}\right) \right\rfloor \right)^{-1/n}\right\rfloor$$

where floor$(\alpha)$=$\lfloor\alpha\rfloor=$ the greatest integer not greater than $\alpha$ (where $\alpha$ is any real number).
E.g. $\lfloor 2.5 \rfloor = 2$
E.g. $\lfloor 2 \rfloor = 2$
E.g. $\lfloor 1.9 \rfloor = 1$

Using the formula you should get
$p_1=2$,  $p_2=3$, $p_3=5$, $p_4=7$, $p_5=11$ etc

No comments:

Post a Comment