Science Fair Project Encyclopedia
These primes are called "safe" because they were once thought to be useful in encryption algorithms such as Diffie-Hellman. It should of course be noted that no prime less than about 1050 is really secure since any modern computer with a suitable algorithm can determine their primality in a reasonable period of time. But the small safe primes are still useful for teaching the principles of the system. There is no special primality test for safe primes the way there is for Fermat primes and Mersenne primes.
With the exception of 5, there are no Fermat primes that are also safe primes. A little reflection will show that given a Fermat prime F, it will turn out that (F - 1)/2 is a power of two.
With the exception of 7, there are no Mersenne primes that are also safe primes. The proof of this is a little more involved, but still within the realm of basic algebra. Accepting as true that p must be prime for 2p - 1 to have a chance to be prime also, it follows that ((2p - 1) - 1)/2 = 2p - 1 - 1, that is, a Mersenne number. But p - 1 is never prime, with the exception of p = 3, corresponding neatly with 23 - 1 = 7.
Just as every term except the last one of a Cunningham chain of the first kind is a Sophie Germain prime, so every term except the first of such a chain is a safe prime. Safe primes ending in 7, that is, of the form 10n + 7, are the last terms in such chains when they occur, since 2(10n + 7) + 1 = 20n + 15.
The contents of this article is licensed from www.wikipedia.org under the GNU Free Documentation License. Click here to see the transparent copy and copyright details