Complex numbers
Much of the work in Shor’s algorithm depends on a matrix known as the QFT. Using the QFT, Eve can find the period of a sequence and use that period to decrypt Bob’s message. The QFT uses complex numbers to perform its magic, so this section covers some facts about complex numbers.
Complex number basics
Imaginary numbers were first described by Girolamo Cardano in 1545. The best-known imaginary number is , also known as i, and sometimes in Python code, j
. The worst part of imaginary numbers is their name. If we called them “super numbers” instead of “imaginary numbers,” people wouldn’t be so suspicious of them. It’s true that imaginary numbers don’t arise naturally in day-to-day situations. So, for most people, imaginary numbers don’t exist. But scientists rely on imaginary numbers all the time. Imaginary numbers are very useful.
A complex number is a number with two parts. One of those parts...