Re: getting nth prime
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


sci.crypt archive

Re: getting nth prime

From: Christian Siebert <iBBiS@gmx.de>
Date: Mon Apr 24 2006 - 19:04:22 CEST

> > Is there ne algorithm other than Earosthene Sieve to find the Nth
> > prime number
>
> No, the distribution of primes is not well characterized other than
> with limits and gross generalizations.
To be exact, the answer "No" is false. Reason: there exist many
algorithms to generate prime numbers. It would be easy to construct an
algorithm that returns the Nth prime number which is based on the trial
division method and not some kind of sieve ... ;-)

So maybe we should reformulate the original question:

Is there a _more efficient_ algorithm other than the Sieve of
Eratosthenes to find the Nth prime number? (With "more efficient" I
mean something better than a constant factor.)

Regards,
   Christian
Received on Mon May 1 02:04:00 2006