Quantum Algorithms
Reference pages for every algorithm in the Qubibyte simulator. Each page has the default static Qubi, a circuit diagram, and the expected state for that circuit.
|qn-1 ... q0⟩ with q0 the least significant bit (rightmost), matching the simulator. Qubi rotation and CP/P angles are multiples of π.
Entanglement
Bell State
Two-qubit circuit that prepares a maximally entangled Bell pair. Measuring one qubit determines the other.
EntanglementGHZ State
Equal superposition of all-zero and all-one. The n-qubit form of a Bell pair.
EntanglementW State
Equal superposition of every single-excitation basis state. Entanglement survives the loss of one qubit.
Building blocks
State Preparation
Prepares arbitrary superpositions and probability distributions over computational basis states with exact amplitudes.
ConceptQubit Preparation
Prepares independent single-qubit probabilities of being in the |1⟩ state using single-qubit rotations.
ConceptPhase Kickback
A controlled gate can move a target eigenvalue onto the control. This is the engine inside DJ, Grover, and QPE.
ConceptPhase Oracle
Marks one computational basis state with a −1 phase using X-conjugated multi-controlled Z.
ConceptSWAP Test
Estimates |⟨ψ|φ⟩|² with a controlled-SWAP and one ancilla. Does not measure the data states in Z.
Communication
Superdense Coding
Alice sends two classical bits by transmitting one qubit of a shared Bell pair.
CommunicationQuantum Teleportation
Moves an unknown qubit state from q0 to q2 using a Bell pair and two classical bits. The original is destroyed.
CommunicationQuantum Steganography
Hides a secret bit in the phase of a Bell pair. Bob decodes with the cover key. The reduced state Eve sees does not reveal s.
Core algorithms
Deutsch-Jozsa
One oracle query decides whether a Boolean function is constant or balanced.
AlgorithmBernstein-Vazirani
Recovers a hidden n-bit string s from f(x) = s·x (mod 2) in one query.
AlgorithmGrover's Algorithm
Unstructured search by amplitude amplification. Optimal iteration count is round(π/4 · √(N/M) − 1/2).
AlgorithmQuantum Fourier Transform
Maps the computational basis to the Fourier (frequency) basis. Subroutine of QPE and Shor.
AlgorithmInverse QFT
Exact adjoint of the QFT. Readout step of phase estimation.
AlgorithmQuantum Phase Estimation
Estimates φ in U|ψ⟩ = e^{2πiφ}|ψ⟩. Counting q0 is the LSB of the binary readout.
AlgorithmShor's Algorithm
Period finding with a real modular multiplier. The counting register shows all r peaks, and continued fractions plus a gcd give the factors.
Error correction
Parameter playground
Change defaults (Bell type, Grover target, QPE unitary) and copy Qubi or open the simulator. Dedicated pages keep a fixed default circuit so the write-up stays exact.