|q⟩
Bad Qubits
Play
Quest
Questions
Learn
Playground
☕
← Question Bank
Multiple choice
Once Shor's algorithm has found an even order r of a modulo N (with a^(r/2) not congruent to -1 mod N), the identity a^r - 1 = (a^(r/2) - 1)(a^(r/2) + 1) = 0 (mod N) is used. How is a non-trivial factor of N then extracted?
🔬 try it before you answer
Take r itself, which always equals one of the prime factors of N
Multiply r by a to obtain a prime factor of N
Compute a^r mod N, whose value is one of the prime factors
Compute gcd(a^(r/2) - 1, N) and gcd(a^(r/2) + 1, N); at least one is a proper factor of N
Check answer