If you know matrix theory, it is easy to master quantum computing.
After reading this post, you will know the basic of quantum computing.
0. Why is so?
You will see some strange notations like ∣0⟩, and not that math operations. The reason is that quantum computing is from physics. Those physicists like to express their ideas easily without showing off their math.
1. Qubit
Quantum particle is in two states simultaneously.
A Qubit is in superposition if it is both in ∣0⟩ and ∣1⟩ where
∣0⟩=(1;0)∣1⟩=(0;1)∣ϕ⟩=α∣0⟩+β∣1⟩
2. Quantum Collapsing
When we measure a quantum system, it will collapse from superposition (many possibilities) into one measured state.
Just recall the famous thought experiment: Schrödinger’s cat.
3. Probability of measuring
∣ϕ⟩=α∣0⟩+β∣1⟩
The probability of measuring ∣0⟩ is ∣α∣2. Note that α can be a complex number.
4. The Strange Notation
∣ϕ⟩=α∣0⟩+β∣1⟩
We call the RHS Dirac Notation. This is so called ket vectors that represent a quantum state.
Bloch Sphere
∣ϕ⟩=cos2θ+sin2θeiϕ∣1⟩
where θ is the angle between the vector and z-axis and ϕ is the angle between the vector and x-axis.
5. Quantum Circuits
X, Y, Z Gates:
X(Y,Z)
flip the qubit π radians around x(y, z)-axis.
X=(1,0;0,1),Y=(0,−i;i,0),Z=(1,0;0,−1)
Hadamard Gates
H=21(1,1;1,−1)
Apply H, we have
∣0⟩→∣+⟩→∣0⟩∣1⟩→∣−⟩→∣1⟩
where
∣+⟩=21(∣0⟩+∣1⟩)
∣−⟩=21(∣0⟩−∣1⟩)
CNOT/ Controlled X Gate
CNOT Quantum Circuit:
q0 ───●──── (Control qubit)
q1 ───⊕──── (Target qubit: flips if q0 = 1)
Look at the following relationship:
∣00⟩→∣00⟩∣01⟩→∣01⟩∣10⟩→∣11⟩∣11⟩→∣10⟩
6. No-Cloning Theorem
This theorem says that we cannot an exact quantum state.
7. Tensor Product (by ChatGPT)
Tensor product is one of the most important tools in quantum computing. We use tensor product to assemble different quantum systems into one system.