Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 5: both wiretap converses via stochastic preprocessing

Open
QAlgorithms.Papers.Independent.Intake100.P73.wiretap_converse

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

prove2quantum

Let B=(Bn)\mathbf B=(B^n)B=(Bn) and E=(En)\mathbf E=(E^n)E=(En) be arbitrary sequences of classical discrete channels with common input alphabet XnX_nXn​ and output alphabets Yn,ZnY_n,Z_nYn​,Zn​. A wiretap code has a positive finite message count, stochastic encoders and pairwise disjoint Bob decoding regions; messages are uniform. Let ϵB\epsilon_BϵB​ be its average Bob error, IE=M−1∑iD(EQi∥M−1∑jEQj)I_E=M^{-1}\sum_iD(E_{Q_i}\|M^{-1}\sum_jE_{Q_j})IE​=M−1∑i​D(EQi​​∥M−1∑j​EQj​​), and dE=[M(M−1)]−1∑i≠jd(EQi,EQj)d_E=[M(M-1)]^{-1}\sum_{i\ne j}d(E_{Q_i},E_{Q_j})dE​=[M(M−1)]−1∑i=j​d(EQi​​,EQj​​), with dE=0d_E=0dE​=0 when M=1M=1M=1. The capacities Cd,CIC_d,C_ICd​,CI​ are the suprema of the liminf ordinary log message rates of code sequences with ϵB→0\epsilon_B\to0ϵB​→0 and, respectively, dE→0d_E\to0dE​→0 or IE/n→0I_E/n\to0IE​/n→0. They include the operational zero-rate baseline. All distances are full L1 and all rates are in nats.

For an input-law sequence p=(pn)\mathbf p=(p_n)p=(pn​) and channel sequence W\mathbf WW, put Tn(a)=Ppn(x)Wxn(y){n−1log⁡[Wxn(y)/Wpnn(y)]>a}T_n(a)=\mathbb P_{p_n(x)W_x^n(y)}\{n^{-1}\log[W_x^n(y)/W_{p_n}^n(y)]>a\}Tn​(a)=Ppn​(x)Wxn​(y)​{n−1log[Wxn​(y)/Wpn​n​(y)]>a}. Define I‾(ϵ∣p,W)=inf⁡{a:lim inf⁡nTn(a)≤ϵ}\underline I(\epsilon\mid\mathbf p,\mathbf W)=\inf\{a:\liminf_nT_n(a)\le\epsilon\}I​(ϵ∣p,W)=inf{a:liminfn​Tn​(a)≤ϵ} and I‾(ϵ∣p,W)=inf⁡{a:lim sup⁡nTn(a)≤ϵ}\overline I(\epsilon\mid\mathbf p,\mathbf W)=\inf\{a:\limsup_nT_n(a)\le\epsilon\}I(ϵ∣p,W)=inf{a:limsupn​Tn​(a)≤ϵ}. At ϵ=1\epsilon=1ϵ=1 use the strict tail bound <1<1<1. Spectra and numerical extrema are extended-valued.

For possibly infinite spectra, interpret L−UL-UL−U by the finite-threshold cut

D(L,U)=sup⁡{a−b:a,b∈R, a<L, U<b}.\mathcal D(L,U)=\sup\{a-b:a,b\in\mathbb R,\ a<L,\ U<b\}.D(L,U)=sup{a−b:a,b∈R, a<L, U<b}.

Let AnA_nAn​ range over all auxiliary alphabet sequences, let Qn:An→P(Xn)Q^n:A_n\to\mathcal P(X_n)Qn:An​→P(Xn​) range over all stochastic preprocessors, and let pn∈P(An)p_n\in\mathcal P(A_n)pn​∈P(An​) be arbitrary. Use the same QnQ^nQn before both channels, so (BnQn)a(y)=∑xQan(x)Bxn(y)(B^nQ^n)_a(y)=\sum_x Q_a^n(x)B_x^n(y)(BnQn)a​(y)=∑x​Qan​(x)Bxn​(y) and similarly for Eve. Let

Γ=max⁡{0,sup⁡(An),p,QD(I‾(1∣p,BQ),I‾(0∣p,EQ))}.\Gamma=\max\left\{0,\sup_{(A_n),\mathbf p,\mathbf Q}\mathcal D\bigl(\underline I(1\mid\mathbf p,\mathbf B\mathbf Q),\overline I(0\mid\mathbf p,\mathbf E\mathbf Q)\bigr)\right\}.Γ=max{0,(An​),p,Qsup​D(I​(1∣p,BQ),I(0∣p,EQ))}.

Then both converse inequalities hold:

Cd(B,E)≤Γ,CI(B,E)≤Γ.C_d(\mathbf B,\mathbf E)\le\Gamma,\qquad C_I(\mathbf B,\mathbf E)\le\Gamma.Cd​(B,E)≤Γ,CI​(B,E)≤Γ.

The optimization is over arbitrary stochastic channels and arbitrary auxiliary laws and alphabets, without alphabet growth or memorylessness assumptions. This is a converse for both secrecy criteria.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Intake100_P73
Formal statement
noncomputable section

namespace QAlgorithms.Papers.Independent.Intake100.P73

open Filter

open scoped BigOperators ENNReal Topology

attribute [local instance] Classical.propDecidable Classical.decEq

universe u

/-- Hayashi, PDF p.9, Lemma 5, (32)–(33): both converses optimize arbitrary
auxiliary alphabets, laws and stochastic preprocessing. The proof's displayed
R=... gives only the stated R<=...; no equality hypothesis is inserted. -/
theorem wiretap_converse {X Y Z : ℕ → Type u} [∀ k, Nonempty (X k)]
    (B : (k : ℕ) → X k → Y k → ℝ≥0∞) (E : (k : ℕ) → X k → Z k → ℝ≥0∞)
    (hB : ∀ k, IsDiscreteStochastic (B k)) (hE : ∀ k, IsDiscreteStochastic (E k)) :
    generalSecrecyCapacity false B E ≤ preprocessedBound B E ∧
    generalSecrecyCapacity true B E ≤ preprocessedBound B E := by sorry

end QAlgorithms.Papers.Independent.Intake100.P73

end
Source
General non-asymptotic and asymptotic formulas in channel resolvability and identification capacity and their application to wire-tap channel, arXiv:cs/0503088v2, PDF p. 9, Lemma 5, (32)–(33): general wiretap converse via preprocessing
Read-back

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

For every three families of types (Xk),(Yk),(Zk)(X_k),(Y_k),(Z_k)(Xk​),(Yk​),(Zk​) in the same universe, with each XkX_kXk​ nonempty, and every pair of kernel families Bk:Xk×Yk→[0,∞]B_k:X_k\times Y_k\to[0,\infty]Bk​:Xk​×Yk​→[0,∞] and Ek:Xk×Zk→[0,∞]E_k:X_k\times Z_k\to[0,\infty]Ek​:Xk​×Zk​→[0,∞] satisfying ∑yBk(x,y)=1\sum_yB_k(x,y)=1∑y​Bk​(x,y)=1 and ∑zEk(x,z)=1\sum_zE_k(x,z)=1∑z​Ek​(x,z)=1 for every k,xk,xk,x, both inequalities Cdist≤PC_{\mathrm{dist}}\le PCdist​≤P and CKL≤PC_{\mathrm{KL}}\le PCKL​≤P hold, with the following definitions. Write nk=k+1n_k=k+1nk​=k+1. A code at index kkk consists of a positive integer mkm_kmk​, probability mass functions uk,iu_{k,i}uk,i​ on XkX_kXk​ for 1≤i≤mk1\le i\le m_k1≤i≤mk​, and pairwise disjoint sets Dk,i⊆YkD_{k,i}\subseteq Y_kDk,i​⊆Yk​. Define

bk,i(y)=∑xuk,i(x)Bk(x,y),ek,i(z)=∑xuk,i(x)Ek(x,z),eˉk(z)=1mk∑iek,i(z),βk=1mk∑i∑y∉Dk,ibk,i(y).b_{k,i}(y)=\sum_xu_{k,i}(x)B_k(x,y),\qquad e_{k,i}(z)=\sum_xu_{k,i}(x)E_k(x,z),\qquad \bar e_k(z)=\frac1{m_k}\sum_i e_{k,i}(z),\qquad \beta_k=\frac1{m_k}\sum_i\sum_{y\notin D_{k,i}}b_{k,i}(y).bk,i​(y)=x∑​uk,i​(x)Bk​(x,y),ek,i​(z)=x∑​uk,i​(x)Ek​(x,z),eˉk​(z)=mk​1​i∑​ek,i​(z),βk​=mk​1​i∑​y∈/Dk,i​∑​bk,i​(y).

For probability mass functions f,gf,gf,g, put

L1(f,g)=∑v((f(v)−g(v))++(g(v)−f(v))+),D(f,g)=∑vK(f(v),g(v)),L_1(f,g)=\sum_v\bigl((f(v)-g(v))_++(g(v)-f(v))_+\bigr), \qquad D(f,g)=\sum_vK(f(v),g(v)),L1​(f,g)=v∑​((f(v)−g(v))+​+(g(v)−f(v))+​),D(f,g)=v∑​K(f(v),g(v)),

where (t)+=max⁡{t,0}(t)_+=\max\{t,0\}(t)+​=max{t,0} and

K(a,b)={b,a=0,+∞,a>0, b=0,bmax⁡{0,(a/b)log⁡(a/b)−a/b+1},a>0, b>0.K(a,b)= \begin{cases} b,&a=0,\\ +\infty,&a>0,\ b=0,\\ b\max\{0,(a/b)\log(a/b)-a/b+1\},&a>0,\ b>0. \end{cases}K(a,b)=⎩⎨⎧​b,+∞,bmax{0,(a/b)log(a/b)−a/b+1},​a=0,a>0, b=0,a>0, b>0.​

The point masses are finite real numbers, and the sums are taken in [0,∞][0,\infty][0,∞]. Set

δk=1mk∑iD(ek,i,eˉk),λk={0,mk=1,1mk(mk−1)∑i∑j≠iL1(ek,i,ek,j),mk>1.\delta_k=\frac1{m_k}\sum_iD(e_{k,i},\bar e_k), \qquad \lambda_k= \begin{cases} 0,&m_k=1,\\ \displaystyle\frac1{m_k(m_k-1)}\sum_i\sum_{j\ne i}L_1(e_{k,i},e_{k,j}),&m_k>1. \end{cases}δk​=mk​1​i∑​D(ek,i​,eˉk​),λk​=⎩⎨⎧​0,mk​(mk​−1)1​i∑​j=i∑​L1​(ek,i​,ek,j​),​mk​=1,mk​>1.​

The quantity CdistC_{\mathrm{dist}}Cdist​ is max⁡{0,sup⁡r}\max\{0,\sup r\}max{0,supr}, where the supremum ranges over rates r=lim inf⁡k(log⁡mk)/nkr=\liminf_k(\log m_k)/n_kr=liminfk​(logmk​)/nk​ of code sequences satisfying βk→0\beta_k\to0βk​→0 and λk→0\lambda_k\to0λk​→0; CKLC_{\mathrm{KL}}CKL​ instead requires βk→0\beta_k\to0βk​→0 and δk/nk→0\delta_k/n_k\to0δk​/nk​→0. These convergences are in [0,∞][0,\infty][0,∞]. To define PPP, range over all families of types AkA_kAk​ in the same universe as Xk,Yk,ZkX_k,Y_k,Z_kXk​,Yk​,Zk​, all families of probability mass functions pkp_kpk​ on AkA_kAk​, and all assignments Qk(a)Q_k(a)Qk​(a) of a probability mass function on XkX_kXk​ to each a∈Aka\in A_ka∈Ak​. Form the kernels

B~k(a,y)=∑xQk(a)(x)Bk(x,y),E~k(a,z)=∑xQk(a)(x)Ek(x,z).\widetilde B_k(a,y)=\sum_xQ_k(a)(x)B_k(x,y), \qquad \widetilde E_k(a,z)=\sum_xQ_k(a)(x)E_k(x,z).Bk​(a,y)=x∑​Qk​(a)(x)Bk​(x,y),Ek​(a,z)=x∑​Qk​(a)(x)Ek​(x,z).

For V=B~V=\widetilde BV=B or E~\widetilde EE, put qkV(v)=∑apk(a)Vk(a,v)q^V_k(v)=\sum_ap_k(a)V_k(a,v)qkV​(v)=∑a​pk​(a)Vk​(a,v). Define ℓkV(a,v)\ell^V_k(a,v)ℓkV​(a,v) as −∞-\infty−∞ when Vk(a,v)=0V_k(a,v)=0Vk​(a,v)=0, as +∞+\infty+∞ when Vk(a,v)>0V_k(a,v)>0Vk​(a,v)>0 and qkV(v)=0q^V_k(v)=0qkV​(v)=0, and otherwise as log⁡(Vk(a,v)/qkV(v))\log(V_k(a,v)/q^V_k(v))log(Vk​(a,v)/qkV​(v)). Thus a simultaneous zero uses the −∞-\infty−∞ branch. Let

TkV(t)=∑a,v: t<ℓkV(a,v)/nkpk(a)Vk(a,v),LA,Q,p=inf⁡{t∈R:lim inf⁡kTkB~(t)<1},HA,Q,p=inf⁡{t∈R:lim sup⁡kTkE~(t)≤0}.T^V_k(t)=\sum_{a,v:\ t<\ell^V_k(a,v)/n_k}p_k(a)V_k(a,v),\qquad L_{A,Q,p}=\inf\{t\in\mathbb R:\liminf_kT^{\widetilde B}_k(t)<1\},\qquad H_{A,Q,p}=\inf\{t\in\mathbb R:\limsup_kT^{\widetilde E}_k(t)\le0\}.TkV​(t)=a,v: t<ℓkV​(a,v)/nk​∑​pk​(a)Vk​(a,v),LA,Q,p​=inf{t∈R:kliminf​TkB​(t)<1},HA,Q,p​=inf{t∈R:klimsup​TkE​(t)≤0}.

The tail sums are real probability masses. Finally, define

P=max⁡{0, sup⁡A,Q,p sup⁡{a−b: a,b∈R, a<LA,Q,p, HA,Q,p<b}}.P=\max\left\{0,\ \sup_{A,Q,p}\ \sup\{a-b:\ a,b\in\mathbb R,\ a<L_{A,Q,p},\ H_{A,Q,p}<b\}\right\}.P=max{0, A,Q,psup​ sup{a−b: a,b∈R, a<LA,Q,p​, HA,Q,p​<b}}.

Every infimum and supremum defining rates or thresholds is in the extended real line, so empty infima are +∞+\infty+∞ and empty suprema are −∞-\infty−∞; in particular the inner supremum uses strict real bounds even when either spectrum is infinite. All limits are as k→∞k\to\inftyk→∞. There are no finiteness assumptions on any of the type families, and no additional restriction on the auxiliary types AkA_kAk​ beyond their universe and the supplied probability mass functions. Code size 111 is allowed and has λk=0\lambda_k=0λk​=0; the first index has length 111.

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

    Confirmed by the moderator at approval.

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