Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Nonuniform private inputs have lower entropy cost

Proved
QAlgorithms.Papers.Independent.Intakethird100.P47.nonuniform_input_entropy

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

prove2quantum

Let AAA and BBB be independent private binary settings, each with probability r∈[0,1]r\in[0,1]r∈[0,1] of input zero. Let h2(r)=−rlog⁡2r−(1−r)log⁡2(1−r)h_2(r)=-r\log_2r-(1-r)\log_2(1-r)h2​(r)=−rlog2​r−(1−r)log2​(1−r), with 0log⁡0=00\log 0=00log0=0, and let H(A,B)H(A,B)H(A,B) be Shannon entropy in bits. Then

H(A,B)=2h2(r),r≠12 ⟹ H(A,B)<2.H(A,B)=2h_2(r),\qquad r\ne\tfrac12\ \Longrightarrow\ H(A,B)<2.H(A,B)=2h2​(r),r=21​ ⟹ H(A,B)<2.

In particular r∗=(5−1)/2r_*=(\sqrt5-1)/2r∗​=(5​−1)/2 lies strictly between zero and one and has H(A,B)<2H(A,B)<2H(A,B)<2. This is the asymptotic Shannon randomness cost of the independent input source, not a finite-seed length or a security statement for correlated adversarial randomness.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Intakethird100_P47
Formal statement
namespace QAlgorithms.Papers.Independent.Intakethird100.P47

open scoped ComplexConjugate

open scoped BigOperators

/-- IV B / VII A, PDF pp.6,8–9: nonuniform independent private settings cost less
Shannon entropy than two fair bits; the ideal chosen bias is included explicitly.
This is a population entropy statement, not an exact finite random-seed length. -/
theorem nonuniform_input_entropy :
    (∀ r : ℝ, 0 ≤ r → r ≤ 1 →
      pairEntropy (binarySettingLaw r r) = 2 * binEntropy2 r ∧
      (r ≠ 1 / 2 → pairEntropy (binarySettingLaw r r) < 2)) ∧
    (0 < (Real.sqrt 5 - 1) / 2 ∧ (Real.sqrt 5 - 1) / 2 < 1) ∧
    pairEntropy (binarySettingLaw ((Real.sqrt 5 - 1) / 2) ((Real.sqrt 5 - 1) / 2)) < 2 := by sorry

end QAlgorithms.Papers.Independent.Intakethird100.P47
Source
Device-independent quantum key distribution based on measurement inputs, arXiv:1308.6447v3, PDF p. 6, IV B / VII A: nonuniform inputs require less randomness
Read-back

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

For r∈[0,1]r\in[0,1]r∈[0,1], define q0=rq_0=rq0​=r, q1=1−rq_1=1-rq1​=1−r, and the pair law wAB(r)=qAqBw^{(r)}_{AB}=q_Aq_BwAB(r)​=qA​qB​ on A,B∈{0,1}A,B\in\{0,1\}A,B∈{0,1}. For a pair law jjj, write H(j)=−∑A,BjABlog⁡(jAB)/log⁡2H(j)=-\sum_{A,B}j_{AB}\log(j_{AB})/\log2H(j)=−∑A,B​jAB​log(jAB​)/log2, where log⁡\loglog is the natural logarithm and a zero entry contributes zero. Write h2(r)=[−rlog⁡r−(1−r)log⁡(1−r)]/log⁡2h_2(r)=[-r\log r-(1-r)\log(1-r)]/\log2h2​(r)=[−rlogr−(1−r)log(1−r)]/log2, with the same zero-term convention. The declaration asserts the conjunction of these claims: for every real rrr with 0≤r≤10\le r\le10≤r≤1, including r=0r=0r=0 and r=1r=1r=1,

H(w(r))=2h2(r),r≠12 ⟹ H(w(r))<2;H(w^{(r)})=2h_2(r), \qquad r\ne\frac12\ \Longrightarrow\ H(w^{(r)})<2;H(w(r))=2h2​(r),r=21​ ⟹ H(w(r))<2;

the number g=(5−1)/2g=(\sqrt5-1)/2g=(5​−1)/2 satisfies 0<g<10<g<10<g<1; and H(w(g))<2H(w^{(g)})<2H(w(g))<2.

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