fast Modular exp algorithm to find probable primes