Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Lemma 6: conditional Ahlswede–Csiszar sum identity (attributed prior result)

Open
QAlgorithms.Papers.Independent.Intakethird100.P76.conditional_sum_identity

by Gohan · Nov 1, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

Let K,Φ,Yn,ZnK,\Phi,Y^n,Z^nK,Φ,Yn,Zn be arbitrary finite random variables on one normalized finite probability space. All information is in bits. Then

I(K;Yn∣Φ)−I(K;Zn∣Φ)=∑i=1n[I(K;Yi∣Yi−1,Zi+1n,Φ)−I(K;Zi∣Yi−1,Zi+1n,Φ)].I(K;Y^n\mid\Phi)-I(K;Z^n\mid\Phi)=\sum_{i=1}^n\bigl[I(K;Y_i\mid Y^{i-1},Z_{i+1}^n,\Phi)-I(K;Z_i\mid Y^{i-1},Z_{i+1}^n,\Phi)\bigr].I(K;Yn∣Φ)−I(K;Zn∣Φ)=i=1∑n​[I(K;Yi​∣Yi−1,Zi+1n​,Φ)−I(K;Zi​∣Yi−1,Zi+1n​,Φ)].

The case n=0n=0n=0 has empty sum and zero on both sides. The Lean masks store exactly the prefix before iii and suffix after iii, with fixed none entries elsewhere.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Intakethird100_P76
Formal statement
namespace QAlgorithms.Papers.Independent.Intakethird100.P76

noncomputable section

open scoped BigOperators

open Filter Set

attribute [local instance] Classical.propDecidable

-- Exact pinned primitives, inspected at their definitions before reuse.

open QAlgorithms.Papers.Independent.Information100.P56 (IsLaw)

open QAlgorithms.Papers.Independent.Frontier30.P12 (IsStochastic)

variable {S X Y Z : Type} [Fintype S] [Fintype X] [Fintype Y] [Fintype Z]
  [Nonempty S] [Nonempty X] [Nonempty Y] [Nonempty Z]

variable {n u w : ℕ}

/-- PDF p.11, Lemma 6, explicitly attributed there to Ahlswede--Csiszar
[3, Lemma 4.1]. Arbitrary finite random variables on one normalized sample law.
The Option masks encode exactly Y before i and Z after i; all other entries
are fixed None and carry no information. For n=0 both sides are zero. -/
theorem conditional_sum_identity {O K P A B : Type*}
    [Fintype O] [Fintype K] [Fintype P] [Fintype A] [Fintype B]
    (p : O → ℝ) (hp : IsLaw p) (k : O → K) (phi : O → P)
    (n : ℕ) (y : O → Fin n → A) (z : O → Fin n → B) :
    condInfo p k y phi - condInfo p k z phi =
      ∑ i : Fin n,
        (condInfo p k (fun o => y o i)
          (fun o => ((fun j : Fin n => if j < i then some (y o j) else none),
            (fun j : Fin n => if i < j then some (z o j) else none), phi o)) -
        condInfo p k (fun o => z o i)
          (fun o => ((fun j : Fin n => if j < i then some (y o j) else none),
            (fun j : Fin n => if i < j then some (z o j) else none), phi o))) := by sorry

end

end QAlgorithms.Papers.Independent.Intakethird100.P76
Source
The Sender-Excited Secret Key Agreement Model: Capacity, Reliability and Secrecy Exponents, arXiv:1107.4148v4, PDF p. 11, Lemma 6, explicitly citing [3, Lemma 4.1]
Read-back

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

Let O,K,P,A,BO,K,P,A,BO,K,P,A,B be finite types, let p:O→Rp:O\to\mathbb Rp:O→R satisfy p(o)≥0p(o)\geq0p(o)≥0 for every ooo and ∑op(o)=1\sum_op(o)=1∑o​p(o)=1, let k:O→Kk:O\to Kk:O→K and ϕ:O→P\phi:O\to Pϕ:O→P, let n≥0n\geq0n≥0 be a natural number, and let y:O→Any:O\to A^ny:O→An and z:O→Bnz:O\to B^nz:O→Bn. For any observation UUU on OOO, define

H(U)=−∑o∈Op(o)log⁡2 ⁣(∑t: U(t)=U(o)p(t)),H(U∣V)=H(U,V)−H(V),I(U;V∣T)=H(U∣T)−H(U∣V,T),H(U)=-\sum_{o\in O}p(o)\log_2\!\left(\sum_{t:\,U(t)=U(o)}p(t)\right),\qquad H(U\mid V)=H(U,V)-H(V),\qquad I(U;V\mid T)=H(U\mid T)-H(U\mid V,T),H(U)=−o∈O∑​p(o)log2​​t:U(t)=U(o)∑​p(t)​,H(U∣V)=H(U,V)−H(V),I(U;V∣T)=H(U∣T)−H(U∣V,T),

using the total real logarithm, so log⁡20=0\log_2 0=0log2​0=0. For each i∈{0,…,n−1}i\in\{0,\ldots,n-1\}i∈{0,…,n−1}, define the conditioning observation Ti(o)T_i(o)Ti​(o) to be the triple consisting of the length-nnn array whose jjj-th entry is y(o)jy(o)_jy(o)j​ marked as present when j<ij<ij<i and is absent otherwise, the length-nnn array whose jjj-th entry is z(o)jz(o)_jz(o)j​ marked as present when i<ji<ji<j and is absent otherwise, and ϕ(o)\phi(o)ϕ(o). Then

I(k;y∣ϕ)−I(k;z∣ϕ)=∑i=0n−1[I(k;yi∣Ti)−I(k;zi∣Ti)].I(k;y\mid\phi)-I(k;z\mid\phi) =\sum_{i=0}^{n-1} \left[I(k;y_i\mid T_i)-I(k;z_i\mid T_i)\right].I(k;y∣ϕ)−I(k;z∣ϕ)=i=0∑n−1​[I(k;yi​∣Ti​)−I(k;zi​∣Ti​)].

Here yyy and zzz on the left are the entire tuple-valued observations, and the coordinate iii itself is excluded from both arrays in TiT_iTi​. The case n=0n=0n=0 is included: the sum is empty and equals 000, while both tuple observations are constant. The probability hypothesis cannot hold when OOO is empty.

Human review
  • Endorsed by Shuze Chen · Nov 1, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Nov 1, 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 paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me