RosettaCodeData/Task/Pierpont-primes/00-TASK.txt
2023-07-01 13:44:08 -04:00

28 lines
1.3 KiB
Text

A Pierpont prime is a prime number of the form: <big>'''2<sup>''u''</sup>3<sup>''v''</sup> + 1'''</big> for some non-negative integers <big>''' ''u'' '''</big> and <big>''' ''v'' '''</big>.
A Pierpont prime of the second kind is a prime number of the form: <big>'''2<sup>''u''</sup>3<sup>''v''</sup> - 1'''</big> for some non-negative integers <big>''' ''u'' '''</big> and <big>''' ''v'' '''</big>.
''The term "Pierpont primes" is generally understood to mean the first definition, but will be called "Pierpont primes of the first kind" on this page to distinguish them.
;Task:
:* Write a routine (function, procedure, whatever) to find Pierpont primes of the first & second kinds.
:* Use the routine to find and display here, on this page, the first '''50 Pierpont primes of the first kind'''.
:* Use the routine to find and display here, on this page, the first '''50 Pierpont primes of the second kind'''
:* If your language supports large integers, find and display here, on this page, the '''250<sup>th</sup> Pierpont prime of the first kind''' and the '''250<sup>th</sup> Pierpont prime of the second kind'''.
;See also:
:* '''[[wp:Pierpont_prime|Wikipedia - Pierpont primes]]'''
:* '''[[oeis:A005109|OEIS:A005109 - Class 1 -, or Pierpont primes]]'''
:* '''[[oeis:A005105|OEIS:A005105 - Class 1 +, or Pierpont primes of the second kind]]'''
<br>