Extending the Miller-Rabin primality test to factor numbers?

987 Views Asked by At

I'm currently using a deterministic version of the Miller-Rabin test (using all bases up to a certain limit). What I'd like to know is if the algorithm can be extended to actually aid in factoring those numbers deemed composite, and if so, how? Thanks!

1

There are 1 best solutions below

1
On

No, it cannot. Only if a number n is a pseudoprime, that is, there is a number a, such that $a^{n-1}=1 (mod n)$ , but n is composite, then the factors can possibly be found. Otherwise, Rabins test can only find out, that a number is not prime.