Talk:Penta-power prime seeds: Difference between revisions

From Rosetta Code
Content added Content deleted
(n must be odd)
 
No edit summary
Line 1: Line 1:
Just thought I'd mention, the Penta-power prime seeds must be odd as n^0+n+1 = n+2 can only be prime if n is odd if n >= 1. --[[User:Tigerofdarkness|Tigerofdarkness]] ([[User talk:Tigerofdarkness|talk]]) 08:33, 20 August 2022 (UTC)
Just thought I'd mention, the Penta-power prime seeds must be odd as n^0+n+1 = n+2 can only be prime if n is odd if n >= 1. --[[User:Tigerofdarkness|Tigerofdarkness]] ([[User talk:Tigerofdarkness|talk]]) 08:33, 20 August 2022 (UTC)

: Right... and this is probably most efficiently implemented as a sequence of tests, one for each polynomial -- the smaller polynomials filter out so much that parallelism costs more than it would contribute. The stress here is primality testing on large numbers (the task requires testing 83 bit unsigned integers and the stretch goal requires testing 94 bit unsigned integers).
: Most (not all) tasks of this nature put primality testing of integers larger than 2^63 in the stretch goal. --[[User:Rdm|Rdm]] ([[User talk:Rdm|talk]]) 16:55, 20 August 2022 (UTC)

Revision as of 16:55, 20 August 2022

Just thought I'd mention, the Penta-power prime seeds must be odd as n^0+n+1 = n+2 can only be prime if n is odd if n >= 1. --Tigerofdarkness (talk) 08:33, 20 August 2022 (UTC)

Right... and this is probably most efficiently implemented as a sequence of tests, one for each polynomial -- the smaller polynomials filter out so much that parallelism costs more than it would contribute. The stress here is primality testing on large numbers (the task requires testing 83 bit unsigned integers and the stretch goal requires testing 94 bit unsigned integers).
Most (not all) tasks of this nature put primality testing of integers larger than 2^63 in the stretch goal. --Rdm (talk) 16:55, 20 August 2022 (UTC)