Why Must Quantum Logic Circuits Be Reversible?
Yes, quantum gates must be reversible. Standard classical logic gates erase bits and dump irreversible heat under Landauer’s thermodynamic limit, destroying quantum coherence. Check our Toffoli gate breakdown and uncomputation circuit guide below →
Reversible Computation in Quantum Computing
Mastering Reversibility, Ancilla Bits, and Unitary Logic
1. The Necessity of Reversibility
In classical logic, gates like AND are inherently irreversible. Because they compress two input bits into a single output bit, information is physically destroyed. For example, if an AND gate outputs ‘0’, you cannot distinguish if the original inputs were (0,0), (0,1), or (1,0). This “many-to-one” mapping results in information loss that manifests as heat dissipation.
In quantum computing, thermodynamics and the laws of physics require all operations to be Unitary (U†U = I). This means every quantum gate must be a 1-to-1 (bijective) mapping; no information is ever lost, and the entire computation can be run in reverse to recover the initial state.
The Logic Gap: If the output is 0, the input could be (0,0), (0,1), or (1,0). The path back is lost.
2. Ancilla Bits & Uncomputation
Because we cannot erase information, we use Ancilla bits as temporary “scratch space.” However, if these qubits are left in an arbitrary state, they remain entangled with the computation. Uncomputation (running gates in reverse) resets them to |0⟩, “cleaning” the quantum workspace.
The Toffoli Gate (CCX)
The Toffoli gate is reversible because its mapping is bijective. No two inputs result in the same output.
| Input (A, B, C) | Output (A, B, C ⊕ AB) | Status |
|---|---|---|
| 0, 0, 0 | 0, 0, 0 | Unique |
| 1, 1, 0 | 1, 1, 1 | Flipped (AND) |
| 1, 1, 1 | 1, 1, 0 | Flipped Back |
The Fredkin Gate (CSWAP)
The Fredkin gate is a controlled-swap operation. It swaps the states of the two target qubits (T1 and T2) if and only if the control qubit (C) is in the state |1⟩. It is conservative, meaning it preserves the Hamming weight (number of 1s) from input to output.
Because it is a universal gate, we can simulate all standard classical logic by fixing certain inputs:
- NOT: Set
T1 = 0,T2 = 1. OutputT2becomes NOTC. - AND: Set
T2 = 0. OutputT2becomesCANDT1. - OR: Set
T1 = B,T2 = 1. OutputT1becomesCORB.
3. Mathematics: Unitary vs. Hermitian
Proof: Is Pauli-Y Unitary?
Y = | 0 | -i |
| i | 0 |
Y† = | 0 | -i |
| i | 0 |
Pauli-Y is Unitary (Y†Y = I). Because Y = Y†, it is also Hermitian.
Unitary but NOT Hermitian: The S Gate
S = | 1 | 0 |
| 0 | i |
S† = | 1 | 0 |
| 0 | -i |
Since S ≠ S†, you must apply the S-Dagger (S†) gate to reverse an S rotation.
4. Qiskit Verification
from qiskit import QuantumCircuit, transpile from qiskit_aer import AerSimulator qc = QuantumCircuit(3) qc.x([0, 1]) # Controls to |1> # Toffoli is Hermitian (U = U†), so applying it twice cleans the ancilla qc.ccx(0, 1, 2) # Calculation step qc.ccx(0, 1, 2) # Uncomputation step qc.measure_all() counts = AerSimulator().run(transpile(qc, AerSimulator())).result().get_counts() print(f"Resulting state: {counts}") # Expect {'011': 1024}
Built with Qiskit 1.x • Quantum Series 2025
Deepen your quantum intuition with our step-by-step mathematical and circuit guides:
Why must quantum computing gates be reversible?
Quantum evolution governed by the Schrödinger equation is unitary (U†U = I). Unitary operations preserve the inner product and quantum information, meaning every valid quantum logic operation must have a deterministic inverse.
What is Landauer’s Principle in classical vs quantum computing?
Landauer’s Principle states that erasing one bit of physical information dissipates at least kB T ln(2) of heat into the environment. Reversible computing avoids this fundamental heat limit by preserving bit counts.
Beyond Unitary Gates: Testing Bell’s Inequality with the CHSH Game
While single-qubit reversible gates preserve state vectors through unitary transformations, multi-qubit entangled states reveal quantum non-locality that defies classical physics. Experience how entangled Bell pairs violate local realism, exceeding the classical 75% win limit up to the 85.3% Tsirelson bound in our interactive simulator.
Launch the Interactive CHSH Game Simulator & Bell’s Inequality Guide →
Leave a Reply