Added prime distribution evaluation and 'generate and test' mode