Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Proposition 1: cited full-sample versus subsample frequency bound

Open
QAlgorithms.Papers.Independent.Advance50.P30.symmetric_classical_sampling

by Gohan · Oct 29, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

Let ppp be a normalized nonnegative probability mass function on strings of length n+kn+kn+k over an alphabet of size w≥1w\ge1w≥1, invariant under all permutations. Let k≥1k\ge1k≥1, n≥0n\ge0n≥0, and let QQQ and QsampleQ_{\mathrm{sample}}Qsample​ be the empirical frequencies of the whole string and its last kkk coordinates, respectively, under this same joint law. For every ϵ≥0\epsilon\ge0ϵ≥0,

Pr⁡p{∥Q−Qsample∥1≥ϵ}≤wexp⁡[−kϵ2/(8w)].\Pr_p\{\|Q-Q_{\mathrm{sample}}\|_1\ge\epsilon\}\le w\exp[-k\epsilon^2/(8w)].pPr​{∥Q−Qsample​∥1​≥ϵ}≤wexp[−kϵ2/(8w)].

The norm is full L1; the subsample is not drawn independently of the whole string. This is the cited Koenig--Renner result in the convention printed by this paper.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Advance50_P30
Formal statement
noncomputable section

namespace QAlgorithms.Papers.Independent.Advance50.P30

open QAlgorithms MeasureTheory

open QAlgorithms.Papers.Independent.Gap48.P20 (Copies)

open QAlgorithms.Papers.Independent.Information100.P21 (Op Vec)

open QAlgorithms.Papers.Independent.Information100.P69 (permute)

open scoped Matrix ComplexConjugate ComplexOrder Matrix.Norms.Elementwise

attribute [local instance] Classical.decEq Classical.propDecidable

attribute [local instance] QAlgorithms.Papers.Independent.Advance50.P30.matrixContinuousENorm

attribute [local instance] QAlgorithms.Papers.Independent.Advance50.P30.matrixMeasurable

attribute [local instance] QAlgorithms.Papers.Independent.Advance50.P30.matrixBorel

attribute [local instance] QAlgorithms.Papers.Independent.Advance50.P30.vectorMeasurable

attribute [local instance] QAlgorithms.Papers.Independent.Advance50.P30.vectorBorel

/-- PDF p.16, Proposition 1, cited Lemma A.4 of Koenig--Renner (19).
The complete joint law is symmetric; the sample is the last k coordinates
of the SAME outcome, not an independent draw. The event uses full L1 and
>= epsilon. A positive sample size guards normalized empirical frequencies. -/
theorem symmetric_classical_sampling (n k w : ℕ) (hk : 0 < k) (hw : 0 < w)
    (p : (Fin (n + k) → Fin w) → ℝ)
    (hpos : ∀ out, 0 ≤ p out) (hsum : ∑ out, p out = 1)
    (hsym : ∀ (pi : Equiv.Perm (Fin (n + k))) out, p (out ∘ pi) = p out)
    (epsilon : ℝ) (hepsilon : 0 ≤ epsilon) :
    (∑ out, if l1 (empiricalFrequency out)
        (empiricalFrequency (fun j : Fin k => out (Fin.natAdd n j))) ≥ epsilon
      then p out else 0) ≤
      (w : ℝ) * Real.exp (-((k : ℝ) * epsilon ^ 2) / (8 * (w : ℝ))) := by sorry

end QAlgorithms.Papers.Independent.Advance50.P30

end
Source
Unconditional privacy over channels which cannot convey quantum information, arXiv:quant-ph/0702077v1, PDF p. 16, Appendix Proposition 1: cited classical random-sampling bound
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

Let n,k,wn,k,wn,k,w be natural numbers with k>0k>0k>0 and w>0w>0w>0. Let p:{0,…,w−1}n+k→Rp:\{0,\ldots,w-1\}^{n+k}\to\mathbb Rp:{0,…,w−1}n+k→R satisfy p(o)≥0p(o)\ge0p(o)≥0 for every ooo, ∑op(o)=1\sum_op(o)=1∑o​p(o)=1, and p(o∘π)=p(o)p(o\circ\pi)=p(o)p(o∘π)=p(o) for every permutation π\piπ of the n+kn+kn+k coordinates. For any real ϵ≥0\epsilon\ge0ϵ≥0, define the full and final-kkk-coordinate empirical frequencies by

fa(o)=∣{i<n+k:oi=a}∣n+k,ga(o)=∣{j<k:on+j=a}∣k.f_a(o)=\frac{|\{i<n+k:o_i=a\}|}{n+k}, \qquad g_a(o)=\frac{|\{j<k:o_{n+j}=a\}|}{k}.fa​(o)=n+k∣{i<n+k:oi​=a}∣​,ga​(o)=k∣{j<k:on+j​=a}∣​.

Then

∑o∈{0,…,w−1}n+k∑a=0w−1∣fa(o)−ga(o)∣≥ϵp(o)≤wexp⁡ ⁣(−kϵ28w).\sum_{\substack{o\in\{0,\ldots,w-1\}^{n+k}\\ \sum_{a=0}^{w-1}|f_a(o)-g_a(o)|\ge\epsilon}} p(o) \le w\exp\!\left(-\frac{k\epsilon^2}{8w}\right).o∈{0,…,w−1}n+k∑a=0w−1​∣fa​(o)−ga​(o)∣≥ϵ​∑​p(o)≤wexp(−8wkϵ2​).

The deviation event uses the non-strict inequality ≥\ge≥. The case n=0n=0n=0 is allowed, in which the two empirical frequencies coincide; when ϵ=0\epsilon=0ϵ=0, every outcome belongs to the event and its total weight is 111.

Human review
  • Endorsed by Shuze Chen · Oct 29, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 29, 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