What is the difference between the Optimised Generator and the Classical Generator?
(the markdown in brackets, i.e., (name
) refer to the variable name in the code)
We try to minimise 'randomly' guessing candidates (c) for primes by selecting numbers with certain prime-like properties.
delta
) is a sequence of small exponents, p
) is a sequence of small prime numbers, t
, C
), alfi
) of random numbers and theta
) is a sequence of theti
) which are sequences of
Where
(This is as a result of the Chinese Remainder Theorem)
Now, like the classical generators, we generate
Files:
Naive Generator - Naive/Basic Implementation of Prime Number Generator
Classical Generator - Using some basic Number Theory theorems to make improvements to the Naive Generator
Optimised Generator - Using further number theory concepts to minimise random guessing and maximise accuracy
Composite Test - Miller-Rabin Deterministic Composite Test (more tests to be added soon!)
PrimeHelpers - List of functions to used in the generators.
HelperFunctions - List of useful array (and non-array) functions to avoid redundancy and make code cleaner
Misc. Files:
Primes1.txt - List of primes up until
MakeListOfPrimes - Imports Primes.txt
CodeDump - Temporary local repository of the code.