Collapsing the Superposition: The Mathematics of Quantum Computing
By: Kaushik Chatterjee
Tags: Quantum Physics, Mathematics, Technology, Linear Algebra, Quantum Computing

We think of bits as 1’s and 0’s. Really, bits could be anything with 2 states: true/false; on/off; heads/tails. A classical computer simply quantifies these bits as integers since that’s all a computer can store and process. Qubits, however, are an entirely different beast: they’re vectors. This is because a qubit really represents the probability that its bitstate is either 0 or 1; rather than only being 0 or 1, they can exist as any value between 0 and 1 until they are measured (we’ll touch on this in a bit).

In quantum mechanics, we represent vectors using Dirac notation, which makes quantum computations clearer and more concise. |ψ⟩ denotes a unit column vector and ⟨ψ| denotes a corresponding row vector. ⟨ψ| is the Hermitian transpose of |ψ⟩, which is found be transposing |ψ⟩ and taking the complex conjugate of every entry, represented as ψ†. We represent the classical bits 0 and 1 as column vectors |0⟩ and |1⟩:

Notice how the 1 is in the 0th position for |0⟩ and in the 1st position for |1⟩

Why are qubits vectors? In quantum mechanics, the properties of electrons, more precisely its spin, are unknown until we actually measure its state. Similarly, in quantum computing, the state of a qubit exists as a superposition of all possible states, with an assigned probability of it being 0 or 1; until the qubit is measured (see below), it is both 0 and 1, but with a certain likelihood of collapsing to 0 versus 1. A qubit in a state of superposition is a linear combination of the infinite states that exist between 0 and 1. This can be visualized on a Bloch sphere.

The Bloch sphere enables us to visualize the qubit, which is a 2-dimensional complex vector as a 3-dimensional real-valued vector.

So, when we perform specific operations upon a qubit, we can force it into a superposition, where it is no longer only 0 or only 1; rather, it exists as a certain probability of both. These operations can be thought of as rotating the unit vector around the Bloch sphere in a 3-dimensional real vector space. A vector space is simple the space in which a vector resides in. A simple 2-dimensional vector lies in the vector space ℝ³.

When a qubit is actually measured, it will always be either 0 or 1. The act of measuring the qubit has caused the quantum superposition to collapse, and the qubit’s state is now analogous to classical bits’. Informally, we can consider measuring a qubit as ‘observing’ it. Once a qubit’s superposition has been collapsed, it will remain in that state indefinitely. The value it collapses to depends upon its configuration, which is known as its quantum interference. A qubit can be restored to a superposition state via a quantum gate, which performs an operation upon one or more qubits.

More generally, a qubit’s state can be represented as |ψ⟩ = α|0⟩ + β|1⟩, where α and β are complex numbers (numbers of the form a + bi) denoting the respective probability that the qubit will collapse to either 0 or 1. These coefficients satisfy the equation|α|²+|β|² = 1, as the sum of all probabilities in a system must be 1. Thus, if the qubit has a 50% chance of collapsing to 0 and a 50% of chance of collapsing to 1, α =1/√2 and β=1/√2.

As seen in the Bloch sphere, |0⟩ and |1⟩ form the basis vectors of the vector space that describes the qubit’s state. α and β can thus be seen as the rotations applied to a vector in a complex vector space. We often arrange α and β in a column vector known as a quantum states vector as shown below:

A single qubit isn’t of much practical use, with a modern calculator subjugating it. The true power of quantum computing is with using and manipulating many qubits. Multiple qubits of a single quantum state are denoted as a tensor product. If we let α|0⟩ + β|1⟩ and γ|0⟩ + δ|1⟩ be two qubits’ states, then we can represent their system’s state as follows:

What every element of this column vector represents is the probability that the quantum system will collapse to a value of 0, 1, 2, or 3. In general, if we have n qubits we can represent 2ⁿ-1 states. While we can always take the tensor product of 2 single-qubit states, not all two-qubit states can be denoted as a tensor product. In fact, such a system is said to be entangled.