Tuesday, May 15, 2012

[rwcxbwbv] Pierpont primes

Pierpont primes are of the form 2^m * 3^n + 1.  Because of their special form, they can be easily tested for primality using the Lucas primality test (not Lucas-Lehmer).  Trial division can also be greatly accelerated by precomputed tables of remainders.

Here is some Haskell code investigating Pierpont primes, including the classic lazy list exercise of generating in order all numbers of Pierpont form. Also there are some disorganized log files enumerating the largest Pierpont prime less than each power of two up to 2^9787, and a few larger.

The original motivation was, can all the known Pierpont primes be compiled into a table, much like the Mersenne and Fermat primes?  Unlike the other two, there are probably millions to billions of Pierpont primes with the reach of current limits of computing.  But disk space is cheap.  In the end, I concluded that computing is the prohibitive limiting factor due to a much larger search area than Mersenne prime searching.

No comments :