Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

A.1 Eq.(18): total variation as overlap deficit

Open
QAlgorithms.Papers.Independent.Bridge50.P44.tv_overlap

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

prove2quantum

Let PPP and QQQ be normalized discrete probability laws on the same alphabet ZZZ. Their nonnegative mass functions have absolutely convergent sums equal to one. With D(P,Q)=12∑z∣P(z)−Q(z)∣D(P,Q)=\frac12\sum_z|P(z)-Q(z)|D(P,Q)=21​∑z​∣P(z)−Q(z)∣,

D(P,Q)=1−∑z∈Zmin⁡{P(z),Q(z)}.D(P,Q)=1-\sum_{z\in Z}\min\{P(z),Q(z)\}.D(P,Q)=1−z∈Z∑​min{P(z),Q(z)}.

This identity expresses total variation as the deficit of common probability mass and applies to finite or countably supported laws.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Bridge50_P44
Formal statement
noncomputable section

open scoped BigOperators Matrix ComplexOrder

namespace QAlgorithms.Papers.Independent.Bridge50.P44

open QAlgorithms

open QAlgorithms.RealRegisters (Hilbert)

open QAlgorithms.Papers.Independent.Dependency50.P33 (State traceSize)

open QAlgorithms.Papers.Independent.Dependency50.P24 (cqState)

open QAlgorithms.Papers.Independent.Frontier18.P08 (partialTraceFirst)

open QAlgorithms.Papers.Independent.Information100.P76 (maximallyMixed)

open QAlgorithms.Papers.Independent.Frontier18.P08 (conditionalEntropyNats)

attribute [local instance] Classical.propDecidable

attribute [local instance] Classical.decEq

/-- PDF p.36, Eq.(18): total variation is the deficit of overlap mass. -/
theorem tv_overlap {Z : Type*} (p q : Z → ℝ)
    (hp : IsDiscreteLaw p) (hq : IsDiscreteLaw q) :
    discreteTV p q = 1 - ∑' z, min (p z) (q z) := by sorry

end QAlgorithms.Papers.Independent.Bridge50.P44

end
Source
Cryptographic security of quantum key distribution, arXiv:1409.3525v1, PDF p. 36, A.1 Eq.(18): total variation as overlap deficit
Read-back

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

For every arbitrary index type ZZZ and functions p,q:Z→Rp,q:Z\to\mathbb Rp,q:Z→R, assume that each function is everywhere nonnegative, is summable, and has sum 111. Then their total variation distance, defined here as 12∑z∈Z∣p(z)−q(z)∣\frac12\sum_{z\in Z}|p(z)-q(z)|21​∑z∈Z​∣p(z)−q(z)∣, equals 1−∑z∈Zmin⁡{p(z),q(z)}1-\sum_{z\in Z}\min\{p(z),q(z)\}1−∑z∈Z​min{p(z),q(z)}. No finiteness or countability assumption is imposed on ZZZ; if ZZZ is empty, the normalization hypotheses cannot hold.

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