Chris MacLellan, and Daniel W. Peterson. Statistical Primality Testing Miller-Rabin and pseudoprimes Frobenius test and pseudoprimes Composites which.

Presentation on theme: "Chris MacLellan, and Daniel W. Peterson. Statistical Primality Testing Miller-Rabin and pseudoprimes Frobenius test and pseudoprimes Composites which."— Presentation transcript:

Chris MacLellan, and Daniel W. Peterson

Statistical Primality Testing Miller-Rabin and pseudoprimes Frobenius test and pseudoprimes Composites which fool both tests

Strong Candidates p-1|n-1 and p+1|n+1 for all p|n Must have at least 5 prime factors Prefer composites with odd numbers of factors.

Construction by Primes Implications of q|p-1 q^2|p-1 is harder to “regulate” Attempt to enforce restrictions on p

Regulating 2 2|p-1 and 2|p+1 Either 4|n-1 or 4|n+1 Restrict to 3 mod 8 or 5 mod 8 Check that congruences work 3*3 ≡ 5*5 ≡ 1 mod 8 3*3*3 = 27 ≡ 3 mod 8

Regulating 3 Either 3|p-1 or 3|p+1 We don’t want both

Sieve Conditions Sieve through primes Include only primes p ≡ 3 mod 8 Include only primes p ≡ 2 mod 3 Include only primes where p-1 and p+1 are square-free (excepting 2) ‏

Sieving Methods Sieve of Eratosthenes Jumping Sieve

Sieve of Eratosthenes The way that we sieved numbers was originally like the sieve of Eratosthenes. We would fill an array full of numbers and start moving through and crossing numbers off. When you use this method you run into memory problems, and it's slow.

Jumping Sieve This method is significantly more effective for this application. We use the probabilistic nextprime() function to give us the next prime number. We analyze that number and check it against the sieve conditions. If it passes we write it to file, if it doesn't we use the nextprime() function to get the next prime (and repeat test, etc...).

Psuedo-code n = 2; loop infinitely{ if testconditions(n) = true write n to file n = nextprime(n); }

Test the results Once we let the test run for an adequate amount of time we'd stop it and load the numbers into a hill climbing program. This program then takes random subsets of these numbers, multiplies them together, and test how likely they are to fool the Miller-Rabin and Frobenius primality tests.

Future Keep finding ways to tweak the test conditions Find ways to make the sieve run faster Run the sieve for extended periods of time Continue testing the sieved numbers

Download ppt "Chris MacLellan, and Daniel W. Peterson. Statistical Primality Testing Miller-Rabin and pseudoprimes Frobenius test and pseudoprimes Composites which."

Similar presentations