Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

Quantum Information

127 missions · 63 completed

The study of information encoded in the states of quantum systems, where the qubit, superposition, and entanglement replace the classical bit and measurement is inherently probabilistic. Governed by the constraints of quantum mechanics, it underpins quantum computing and cryptography and the theory of optimal quantum measurements.

Missions

Open64Completed63All127
🏆Completed
Captain: Elsie66

Grover's AlgorithmResearch Paper

Motivation

Searching an unsorted list of NNN items for a single marked entry takes Θ(N)\Theta(N)Θ(N) queries classically — there is no way to do better than checking items one at a time. Grover's algorithm (Grover 1996) shows that a quantum computer solves the same problem in Θ(N)\Theta(\sqrt N)Θ(N​) queries, a quadratic speedup that applies to any problem expressible as unstructured search over a black-box oracle (this includes brute-forcing NP-complete problems and inverting one-way functions, which is why post-quantum cryptography doubles key lengths to compensate). Unlike Shor's algorithm, Grover's algorithm is provably optimal: Bennett–Bernstein–Brassard–Vazirani (1997) showed Ω(N)\Omega(\sqrt N)Ω(N​) queries are necessary for any quantum algorithm solving unstructured search, so the quadratic speedup is the best any quantum algorithm can achieve on this problem.

Setting

Model an NNN-item database as the standard basis of E=CNE = \mathbb{C}^NE=CN (EuclideanSpace ℂ (Fin N)), with inner product ⟨x,y⟩=∑ixi‾ yi\langle x,y\rangle = \sum_i \overline{x_i}\,y_i⟨x,y⟩=∑i​xi​​yi​. Fix a marked index w0∈{0,…,N−1}w_0 \in \{0,\dots,N-1\}w0​∈{0,…,N−1}. The algorithm starts in the uniform superposition

∣s⟩=1N∑i∣i⟩,|s\rangle = \frac{1}{\sqrt N}\sum_{i} |i\rangle,∣s⟩=N​1​i∑​∣i⟩,

a unit vector assigning equal amplitude to every item. Two reflections drive the search:

  • the oracle O=I−2∣w0⟩⟨w0∣O = I - 2|w_0\rangle\langle w_0|O=I−2∣w0​⟩⟨w0​∣, which flips the sign of the amplitude on the marked item and leaves every other basis state fixed;
  • the diffusion operator D=2∣s⟩⟨s∣−ID = 2|s\rangle\langle s| - ID=2∣s⟩⟨s∣−I ("inversion about the mean"), the reflection about ∣s⟩|s\rangle∣s⟩.

One Grover iterate is G=D OG = D\,OG=DO. The algorithm applies GGG some number of times to ∣s⟩|s\rangle∣s⟩ and measures; a measurement outcome equal to w0w_0w0​ counts as success.

Formalization targets

Milestone — the iterate is an isometry

∥Gx∥=∥x∥for every x∈E\|G x\| = \|x\| \quad \text{for every } x \in E∥Gx∥=∥x∥for every x∈E

OOO and DDD are each reflections about a unit vector, hence isometries; their composition GGG is therefore norm-preserving on the whole space, not just at ∣s⟩|s\rangle∣s⟩ — the minimal fact needed for GGG to be a legitimate quantum operation.

Milestone — the rotation formula

⟨w0,Gks⟩=sin⁡((2k+1)θ),θ:=arcsin⁡ ⁣(1N)\langle w_0, G^k s\rangle = \sin\bigl((2k+1)\theta\bigr), \qquad \theta := \arcsin\!\left(\tfrac{1}{\sqrt N}\right)⟨w0​,Gks⟩=sin((2k+1)θ),θ:=arcsin(N​1​)

The geometric heart of the algorithm (Nielsen & Chuang, Quantum Computation and Quantum Information, Section 6.1.2): restricted to the real two-dimensional subspace spanned by ∣w0⟩|w_0\rangle∣w0​⟩ and the component of ∣s⟩|s\rangle∣s⟩ orthogonal to it, GGG acts as rotation by a fixed angle 2θ2\theta2θ. Each iterate therefore advances the amplitude on the marked state along sin⁡((2k+1)θ)\sin((2k+1)\theta)sin((2k+1)θ), exactly as claimed, with θ=arcsin⁡(1/N)\theta = \arcsin(1/\sqrt N)θ=arcsin(1/N​) the rotation's initial offset (since ⟨w0,s⟩=1/N\langle w_0, s\rangle = 1/\sqrt N⟨w0​,s⟩=1/N​ at k=0k=0k=0).

Goal

∃ k,1−1N  ≤  ∣⟨w0,Gks⟩∣2\exists\, k,\quad 1 - \tfrac1N \;\le\; \bigl|\langle w_0, G^k s\rangle\bigr|^2∃k,1−N1​≤​⟨w0​,Gks⟩​2

Some number of iterations drives the probability of measuring the marked item above 1−1/N1-1/N1−1/N. The goal is stated existentially, without fixing kkk to a specific rounded formula: the rotation angle (2k+1)θ(2k+1)\theta(2k+1)θ can be made to land within θ\thetaθ of π/2\pi/2π/2 by an appropriate integer kkk, and at that point sin⁡2((2k+1)θ)≥cos⁡2θ=1−sin⁡2θ=1−1/N\sin^2((2k+1)\theta) \ge \cos^2\theta = 1-\sin^2\theta = 1 - 1/Nsin2((2k+1)θ)≥cos2θ=1−sin2θ=1−1/N. Pinning kkk down to an explicit closed form (e.g. the nearest integer to π/(4θ)−1/2\pi/(4\theta) - 1/2π/(4θ)−1/2) is one valid strategy, but is not required by the statement — any correct choice of kkk, and any correct proof it works, closes the goal.

Significance

Grover's algorithm is the second landmark quantum algorithm after Shor's, and the one with the widest applicability: because it treats the search space as a black box, it accelerates any brute-force search — SAT solving, collision finding, and generic key search among them — which is the concrete reason NIST's post-quantum cryptography standards double symmetric key lengths rather than replacing them outright. The mathematics itself has been fully settled since 1996, including matching optimality lower bounds; nothing here is open. What this mission adds is a machine- checked derivation of the amplitude formula and success bound directly from the definitions of the oracle and diffusion operators as concrete linear operators on EuclideanSpace ℂ (Fin N) — Mathlib has the finite-dimensional inner product space and rank-one operator machinery this needs (InnerProductSpace.rankOne, EuclideanSpace.single), but no existing formalization of the algorithm itself.

Difficulty

The obvious first attempt tries to track the full NNN-dimensional state vector through kkk iterations. This is intractable in general: GGG's action on an arbitrary basis vector depends on its overlap with both ∣w0⟩|w_0\rangle∣w0​⟩ and ∣s⟩|s\rangle∣s⟩. The move that makes the problem tractable is recognizing that GGG preserves the two-dimensional real subspace span{∣w0⟩,∣s⟩}\mathrm{span}\{|w_0\rangle, |s\rangle\}span{∣w0​⟩,∣s⟩} — everything orthogonal to this plane is fixed by both OOO and DDD, and inside the plane GGG is exactly a rotation matrix by angle 2θ2\theta2θ. Establishing this invariance and then tracking only the rotation angle (rather than the full vector) is the standard reduction, and the one this mission's milestones are built around; skipping it and attempting a direct NNN-dimensional induction does not scale.

Formalization scope

Works over a general N:NN:\mathbb NN:N together with a marked index w0:Fin Nw_0 : \mathrm{Fin}\,Nw0​:FinN — no assumption that NNN is a power of two, since the rotation argument is agnostic to how the NNN basis states are physically encoded into qubits (that encoding is a separate, unrelated concern from the search dynamics proved here). Supplying w0 : Fin N already forces N≥1N \ge 1N≥1; no separate nonemptiness hypothesis is added. The oracle and diffusion operators are built directly from Mathlib's InnerProductSpace.rankOne rather than an ad-hoc pointwise definition, so their reflection structure (and hence unitarity) is visible from the definition itself. A trivializing formalization is ruled out explicitly: the goal is stated as an existential over kkk rather than a fixed closed-form iteration count, so a correct proof must still exhibit a genuine successful kkk and establish the bound — it cannot be discharged by an unrelated or degenerate choice. Contributions extending this to multiple marked items, or proving the matching Ω(N)\Omega(\sqrt N)Ω(N​) lower bound (Bennett–Bernstein–Brassard–Vazirani 1997), are welcome as follow-up missions.

Selected references

  • L. K. Grover, A fast quantum mechanical algorithm for database search, STOC 1996. https://arxiv.org/abs/quant-ph/9605043
  • M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, Cambridge University Press, 2000, Section 6.1.
  • C. H. Bennett, E. Bernstein, G. Brassard, and U. Vazirani, Strengths and Weaknesses of Quantum Computing, SIAM J. Comput. 26 (1997). https://arxiv.org/abs/quant-ph/9701001
8 thms1 active user
CombinatoricsQuantum Error Correction·Captain: Winningatmath

Bivariate-Bicycle Codes: New [[336,20,12]] and [[360,24,12]] Codes and Certified DistancesResearch Paper

Motivation

A quantum memory stores logical qubits in many physical qubits so that errors can be detected and corrected. The overhead of doing so, measured by how many physical qubits are spent per logical qubit at a given error-correcting power, is one of the main costs of fault-tolerant quantum computation. Bivariate-bicycle (BB) codes are currently the leading low-overhead family: the gross code [[144,12,12]][[144,12,12]][[144,12,12]] of Bravyi et al. (Nature, 2024) stores 12 logical qubits at distance 12 using 144 data qubits, roughly a tenth of the overhead of a surface code with the same distance, and it is the basis of a published hardware roadmap. The search for higher-rate members of the family is active, and the claims made in it are claims about the exact distance of explicit finite codes. These are finite but very large computations, and they are rarely checked independently.

Timeline.

  • 2004 — MacKay, Mitchison and McFadden introduce bicycle codes: CSS codes built from a pair of circulant matrices.
  • 2013 — Kovalev and Pryadko generalize the construction to commuting pairs of group-algebra elements (generalized bicycle codes).
  • 2024 — Bravyi, Cross, Gambetta, Maslov, Rall and Yoder define BB codes over Zl×Zm\mathbb Z_l\times\mathbb Z_mZl​×Zm​ and give the ladder [[72,12,6]][[72,12,6]][[72,12,6]], [[90,8,10]][[90,8,10]][[90,8,10]], [[108,8,10]][[108,8,10]][[108,8,10]], [[144,12,12]][[144,12,12]][[144,12,12]], [[288,12,18]][[288,12,18]][[288,12,18]], with [[360,12,≤24]][[360,12,\le 24]][[360,12,≤24]] left with only an upper bound.
  • 2026 — An evolutionary search by Cruz-Benito et al. (arXiv:2606.02418) reports [[288,16,12]][[288,16,12]][[288,16,12]] as its best indecomposable weight-6 code at distance 12.
  • 2026 — Daugherty, Ryan and Ward give two new [[336,20,12]][[336,20,12]][[336,20,12]] codes and a new [[360,24,12]][[360,24,12]][[360,24,12]] code. They certify the exact distances of the whole ladder, establish d=24d=24d=24 for [[360,12]][[360,12]][[360,12]], and show by enumeration that no connected three-term weight-6 BB code with n≤360n\le 360n≤360 and k≥20k\ge 20k≥20 has distance 13 or more.

Setting

Fix positive integers l,ml,ml,m and let G=Zl×ZmG=\mathbb Z_l\times\mathbb Z_mG=Zl​×Zm​. The monomial xiyjx^iy^jxiyj of the ring F2[x,y]/(xl−1, ym−1)\mathbb F_2[x,y]/(x^l-1,\,y^m-1)F2​[x,y]/(xl−1,ym−1) is identified with (i,j)∈G(i,j)\in G(i,j)∈G. A polynomial PPP with coefficients in F2\mathbb F_2F2​ is identified with its support, the finite set of monomials with coefficient 111. The circulant of PPP is the G×GG\times GG×G binary matrix with a 111 in row ggg, column hhh exactly when h−g∈Ph-g\in Ph−g∈P.

Given two polynomials A,BA,BA,B, the BB code BB(A,B)\mathrm{BB}(A,B)BB(A,B) acts on n=2lmn=2lmn=2lm qubits, arranged in two blocks indexed by GGG. Its check matrices are

HX=[ A∣B ],HZ=[ BT∣AT ],H_X=[\,A\mid B\,],\qquad H_Z=[\,B^{\mathsf T}\mid A^{\mathsf T}\,],HX​=[A∣B],HZ​=[BT∣AT],

where AAA and BBB also denote their circulants. Because GGG is abelian, HXHZT=AB+BA=0H_XH_Z^{\mathsf T}=AB+BA=0HX​HZT​=AB+BA=0 over F2\mathbb F_2F2​, so this is a CSS code. Its parameters are:

  1. the number of logical qubits k=n−rank⁡HX−rank⁡HZk=n-\operatorname{rank}H_X-\operatorname{rank}H_Zk=n−rankHX​−rankHZ​, with ranks over F2\mathbb F_2F2​;
  2. the Z-distance dZd_ZdZ​, the least Hamming weight of a vector v∈F2nv\in\mathbb F_2^nv∈F2n​ with HXv=0H_Xv=0HX​v=0 and v∉row⁡(HZ)v\notin\operatorname{row}(H_Z)v∈/row(HZ​) (a nontrivial Z-logical);
  3. the X-distance dXd_XdX​, defined dually: HZv=0H_Zv=0HZ​v=0 and v∉row⁡(HX)v\notin\operatorname{row}(H_X)v∈/row(HX​).

The code is [[n,k,d]][[n,k,d]][[n,k,d]] when dX=dZ=dd_X=d_Z=ddX​=dZ​=d. Each check of a code built from two three-term polynomials touches six qubits (weight 6). The Tanner graph joins each qubit to the X- and Z-checks acting on it, and the code is connected when this graph is connected.

Formalization targets

Goal: the three new codes

BBZ2×Z84 ⁣(1+y+xy5,  1+y4+y62)=[[336,20,12]],\mathrm{BB}_{\mathbb Z_2\times\mathbb Z_{84}}\!\left(1+y+xy^{5},\;1+y^{4}+y^{62}\right)=[[336,20,12]],BBZ2​×Z84​​(1+y+xy5,1+y4+y62)=[[336,20,12]], BBZ2×Z84 ⁣(1+y+xy5,  1+y20+y46)=[[336,20,12]],\mathrm{BB}_{\mathbb Z_2\times\mathbb Z_{84}}\!\left(1+y+xy^{5},\;1+y^{20}+y^{46}\right)=[[336,20,12]],BBZ2​×Z84​​(1+y+xy5,1+y20+y46)=[[336,20,12]], BBZ6×Z30 ⁣(1+y+xy2,  1+y8+x2y16)=[[360,24,12]],\mathrm{BB}_{\mathbb Z_6\times\mathbb Z_{30}}\!\left(1+y+xy^{2},\;1+y^{8}+x^{2}y^{16}\right)=[[360,24,12]],BBZ6​×Z30​​(1+y+xy2,1+y8+x2y16)=[[360,24,12]],

each with dX=dZ=12d_X=d_Z=12dX​=dZ​=12 (Table 9 of the source). Each new code is also a milestone on its own.

Milestones

  • Lemma 1 (minimality). In any parity system, no nonempty proper subset of a minimum-weight logical is even on every check.
  • Table 3, the certified ladder. [[72,12,6]][[72,12,6]][[72,12,6]], [[90,8,10]][[90,8,10]][[90,8,10]], [[108,8,10]][[108,8,10]][[108,8,10]], [[144,12,12]][[144,12,12]][[144,12,12]], [[288,12,18]][[288,12,18]][[288,12,18]] and [[360,12,24]][[360,12,24]][[360,12,24]], all with dX=dZd_X=d_ZdX​=dZ​, for the polynomials of Bravyi et al.
  • Section 6, the weight-6 envelope. Every connected BB code built from two three-term polynomials with n≤360n\le 360n≤360 and k≥20k\ge 20k≥20 has a nontrivial X- or Z-logical of weight at most 12. In words, none has distance 13 or more.

Significance

The result. The new codes encode 25% and 50% more logical qubits at distance 12 than the best weight-6 code reported by evolutionary search, with figures of merit kd2/nkd^2/nkd2/n of 8.57 and 9.60. The ladder distances turn published values, several of them previously supported only by heuristic searches or upper bounds, into exact statements. In particular d([[360,12]])=24d([[360,12]])=24d([[360,12]])=24 settles an upper bound left open by Bravyi et al. The envelope statement is a negative result: within this family and size range, distance 12 is the ceiling at k≥20k\ge 20k≥20.

Formalizing it. In the source, each lower bound on a distance is a DRAT refutation or a replayable proof tree, checked by external programs. Only the pruning lemma (Lemma 1) has a machine-checked proof, in Lean 4. A complete formalization would make the code parameters kernel-checked facts about explicit Mathlib objects, independent of every external checker. Upper bounds on distance and the values of kkk are finite linear-algebra facts. Lower bounds are exhaustive statements over (nw)\binom{n}{w}(wn​)-sized spaces and are the core of the work.

Difficulty

The upper bound d≤12d\le 12d≤12 needs one explicit weight-12 logical together with a proof that it lies outside the opposite row space. The lower bound d≥12d\ge 12d≥12 asks that no nontrivial logical of weight at most 11 exist among roughly (33611)≈1019\binom{336}{11}\approx 10^{19}(11336​)≈1019 candidate supports. Direct enumeration is out of reach. A SAT encoding with a cardinality constraint is several orders of magnitude slower than the source's pruned search, and the resulting proof objects are large: hundreds of megabytes for the larger ladder codes. Kernel-checking such certificates, or finding structure that avoids them, is the central difficulty. Computing kkk also requires an F2\mathbb F_2F2​-rank of matrices with up to 180 rows and 360 columns, and Mathlib's Matrix.rank is not computable by decide. The envelope statement additionally quantifies over 971 group shapes and every pair of three-term polynomials on each.

Formalization scope

All objects are in the definition file BBCode_Setting. GGG is ZMod l × ZMod m, and a polynomial is a Finset of monomials, which makes it a set of distinct terms. The circulant has entry 1 at (g,h)(g,h)(g,h) iff h−g∈Ph-g\in Ph−g∈P. Qubits are G ⊕ G (left and right blocks). HXH_XHX​ is Matrix.fromCols (circulant A) (circulant B) and HZH_ZHZ​ is Matrix.fromCols (circulant B)ᵀ (circulant A)ᵀ, over ZMod 2. The row space is the ZMod 2-span of the rows, and the weight counts nonzero coordinates. NumLogical A B k states rank⁡HX+rank⁡HZ+k=n\operatorname{rank}H_X+\operatorname{rank}H_Z+k=nrankHX​+rankHZ​+k=n additively, avoiding truncated subtraction. HasZDistance A B d requires both a nontrivial Z-logical of weight exactly ddd and the lower bound for every nontrivial Z-logical, so a code without logicals cannot satisfy it vacuously. IsCode A B n k d bundles n=2lmn=2lmn=2lm, kkk and both distances.

The envelope quantifies over all l,m≥1l,m\ge 1l,m≥1 with 2lm≤3602lm\le 3602lm≤360. The source enumerates 961 shapes; the 10 it omits (lm≤5lm\le 5lm≤5) cannot have k≥20k\ge 20k≥20, so the two ranges are equivalent.

Reusable infrastructure includes computable F2\mathbb F_2F2​ rank certificates (explicit row-echelon or basis witnesses), a verified checker for DRAT or proof-tree certificates, and symmetry lemmas for group translations acting on BB codes. Contributions of any of these, of individual sectors (dXd_XdX​ or dZd_ZdZ​ separately), or of upper and lower bounds as separate lemmas are welcome.

Selected references

  • S. Bravyi, A. W. Cross, J. M. Gambetta, D. Maslov, P. Rall, T. J. Yoder, High-threshold and low-overhead fault-tolerant quantum memory, Nature 627, 778–782, 2024. https://doi.org/10.1038/s41586-024-07107-7 (arXiv: https://arxiv.org/abs/2308.07915)
  • B. W. Daugherty, S. Ryan, G. Ward, New distance-12 bivariate-bicycle codes with 20 and 24 logical qubits: an exhaustive classification and checkable distances to 360 qubits, certificate release v1.0.0, Zenodo, 2026. https://doi.org/10.5281/zenodo.23382175
  • D. J. C. MacKay, G. Mitchison, P. L. McFadden, Sparse-graph codes for quantum error correction, IEEE Trans. Inf. Theory 50(10), 2315–2330, 2004. https://arxiv.org/abs/quant-ph/0304161
  • A. A. Kovalev, L. P. Pryadko, Quantum Kronecker sum-product low-density parity-check codes with finite rate, Phys. Rev. A 88, 012311, 2013. https://arxiv.org/abs/1212.6703
  • J. Cruz-Benito et al., evolutionary search for bivariate-bicycle codes, arXiv:2606.02418, 2026. https://arxiv.org/abs/2606.02418
13 thms0 active usersReviewed
PreviousPage 6 of 6Next

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me