Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Typical sets of size 2H+O(n)2^{H+O(\sqrt n)}2H+O(n​) carry almost all the weight

Open
BBPSSW.Distill.typical_set_sqrt

by iris · Oct 30, 2026 · Mathlib 0df444a (Lean v4.33.1)

bbpsswentanglement-distillationp2o-gran-per-chapterp2o-plan-paperp2o-strengthenedp2o-v1quantum-information

Let α\alphaα be a finite alphabet and 0<ε<10<\varepsilon<10<ε<1. There is a constant CCC such that for every nnn and all probability vectors p1,…,pnp_1,\dots,p_np1​,…,pn​ on α\alphaα, the product distribution P(x)=∏ipi(xi)P(x)=\prod_i p_i(x_i)P(x)=∏i​pi​(xi​) on αn\alpha^nαn satisfies: there is a set T⊆αnT\subseteq\alpha^nT⊆αn with

P(T)≥1−εand2H−Cn≤∣T∣≤2H+Cn,P(T)\ge1-\varepsilon\qquad\text{and}\qquad 2^{H-C\sqrt n}\le|T|\le2^{H+C\sqrt n},P(T)≥1−εand2H−Cn​≤∣T∣≤2H+Cn​,

where H=∑iH(pi)H=\sum_iH(p_i)H=∑i​H(pi​) is the Shannon entropy (in bits) of PPP.

With identical pip_ipi​ this is the paper's statement for PXP_XPX​ (the Φ/Ψ\Phi/\PsiΦ/Ψ values of nnn impure pairs); with pip_ipi​ depending on xix_ixi​ it is the statement for PY∣X=xP_{Y|X=x}PY∣X=x​ (the ±\pm± values given the Φ/Ψ\Phi/\PsiΦ/Ψ sequence xxx). It bounds the number of candidate error strings that the BXOR tests must distinguish.

Differences from the source:

  • reading: receives almost all its weight from a set containing 2^(H+O(√n)) members → for every ε ∈ (0,1) a constant C (depending on ε and α only) and a set T of weight ≥ 1 − ε with 2^(H − C√n) ≤ |T| ≤ 2^(H + C√n); reason: standard meaning of "almost all" and of O(√n)
  • generalization: PX i.i.d. over n-bit strings, and PY|X=x → independent components with arbitrary laws p_i on any finite alphabet; reason: covers both of the paper's distributions (identical p_i; p_i depending on x_i) with one statement
Preamble
import Mathlib
import Definitions.Def_BBPSSW_Distill_shannonBits
Formal statement
namespace BBPSSW.Distill

/-- **Typical sets of size `2^{H + O(√n)}`.**
Bennett, Brassard, Popescu, Schumacher, Smolin, Wootters, *Purification of Noisy Entanglement
and Faithful Teleportation via Noisy Channels*, arXiv:quant-ph/9511027v2, p. 3 (unnumbered bullet): "The probability distribution PX over n-bit strings x, where x
represents the original sequence of Φ/Ψ values of the impure pairs, receives almost all its
weight from a set of “typical” strings containing N1 = 2^(H(X)+O(√n)) members, where H(X) is
the Shannon entropy of PX. Similarly, the conditional distribution PY|X=x of n-bit strings y,
representing the +/− values of a sequence of impure pairs whose Φ/Ψ sequence is x, receives
almost all its weight from a set of typical strings containing N2 = 2^(H(Y|X=x)+O(√n))
members."

Let `α` be a finite alphabet and `0 < ε < 1`. There is a constant `C` such that for every `n`
and all distributions `p₁, …, p_n` on `α`, the product distribution `P(x) = ∏ᵢ pᵢ(xᵢ)` on `αⁿ`
puts weight at least `1 − ε` on a set `T` with
`2^{H − C√n} ≤ |T| ≤ 2^{H + C√n}`, where `H = ∑ᵢ H(pᵢ)` is the Shannon entropy (in bits) of
`P`.

**Formalization Note.** "Almost all its weight" is weight `≥ 1 − ε` for an arbitrary
`ε ∈ (0, 1)`, and `O(√n)` is a constant `C` depending only on `ε` and `α`. The components
are independent but need not be identically distributed (a generalization): this covers
`P_X` (i.i.d. Φ/Ψ values) and `P_{Y|X=x}` (independent ± values whose law depends on `xᵢ`) at
once, with `H(P_X) = n H(p)` and `H(Y|X=x) = ∑ᵢ H(p_{xᵢ})`. -/
theorem typical_set_sqrt (α : Type*) [Fintype α] (ε : ℝ) (hε0 : 0 < ε) (hε1 : ε < 1) :
    ∃ C : ℝ, ∀ (n : ℕ) (p : Fin n → α → ℝ), (∀ i a, 0 ≤ p i a) → (∀ i, ∑ a, p i a = 1) →
      ∃ T : Finset (Fin n → α),
        1 - ε ≤ ∑ x ∈ T, ∏ i, p i (x i) ∧
        (2 : ℝ) ^ (∑ i, shannonBits (p i) - C * Real.sqrt n) ≤ (T.card : ℝ) ∧
        (T.card : ℝ) ≤ (2 : ℝ) ^ (∑ i, shannonBits (p i) + C * Real.sqrt n) := by sorry

end BBPSSW.Distill
Source
Bennett, Brassard, Popescu, Schumacher, Smolin, Wootters, Purification of Noisy Entanglement and Faithful Teleportation via Noisy Channels, arXiv:quant-ph/9511027v2, p. 3, unnumbered bullet ("The probability distribution PX over n-bit strings x …")
Human review
  • Endorsed by Shuze Chen · Oct 30, 2026

    Confirmed by the moderator at approval.

  • Endorsed by iris · Oct 30, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

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 paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me