Quantum Computing Unveiled
Quantum Superposition
The Idea of 'And'
In classical computing, a bit is a simple switch: it's either 0 or 1. There's no in-between. Quantum mechanics, however, operates differently. A quantum bit, or qubit, can exist in a combination of states simultaneously. This property is called superposition.
Think of a spinning coin. While it's in the air, it's not definitively heads or tails. It's in a state that encompasses both possibilities. Only when it lands and we measure it does it collapse into a single, definite outcome. A qubit in superposition is like that spinning coin. It holds the potential for being a 0 and a 1 at the same time.
Superposition allows a quantum system to exist in a linear combination of multiple states until it is measured.
The Maths of Many States
We represent the state of a qubit using a notation called Dirac notation, or ket notation. The two basis states, equivalent to a classical 0 and 1, are written as and . A qubit in superposition is described as a linear combination of these two states.
The probability of measuring the qubit as a 0 or a 1 is determined by the square of the magnitude of its amplitude. For the state to be valid, the sum of these probabilities must equal 1.
So, if and , then and . This means there is a 50% chance of measuring a 0 and a 50% chance of measuring a 1.
Superposition in Action
Superposition is what gives quantum computers their immense potential. Since one qubit can represent both 0 and 1, a system of qubits can represent states all at once. This ability to process a vast number of possibilities simultaneously is known as quantum parallelism.
To create a superposition, we use quantum gates. The most fundamental of these is the Hadamard gate.
The Hadamard gate takes a qubit in a definite state ( or ) and puts it into an equal superposition. If you apply it to a qubit in the state, you get a new state where the probabilities of measuring 0 or 1 are equal.
Applying it to a state also creates an equal superposition, but with a crucial difference in phase.
One of the earliest and clearest demonstrations of quantum parallelism is the Deutsch-Jozsa algorithm. This algorithm determines whether a given function is 'constant' (always returns 0 or always returns 1) or 'balanced' (returns 0 for half the inputs and 1 for the other half).
A classical computer would need to check, in the worst case, more than half of the inputs to be certain. Thanks to superposition, a quantum computer can solve this problem in a single operation. It uses Hadamard gates to prepare the input qubits in a superposition of all possible input values, then evaluates the function just once on this superposition state.
What is the defining characteristic of a qubit in a state of superposition?
A qubit is in the state . What is the probability of measuring the qubit and finding it in the state?

