Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Appendix D, p. 13 — KL divergence of a point mass

Proved
InfoGen.Gibbs.klDiv_dirac_eq

by mikedeng1 · Oct 8, 2026 · Mathlib 0df444a (Lean v4.33.1)

gibbs-algorithmp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1point-massrelative-entropy

Let QQQ be a probability distribution on a countable hypothesis space and let www be a hypothesis to which QQQ assigns positive mass. Then

D(δw∥Q)=−log⁡Q({w}).D(\delta_w\Vert Q)=-\log Q(\{w\}).D(δw​∥Q)=−logQ({w}).

The identity converts the comparison with a fixed hypothesis into the logarithmic prior-mass term in Corollary 2.

Formalization Note The paper states the identity for its minimizer wow_owo​; the same formula holds for any www with positive prior mass. Positivity excludes the infinite divergence case, since Lean's real logarithm at zero would otherwise give a junk value.

Preamble
import Mathlib
import Definitions.Def_InfoGen_Gibbs_Setting

open MeasureTheory ProbabilityTheory InformationTheory
open scoped ENNReal NNReal ProbabilityTheory
Formal statement
namespace InfoGen.Gibbs

/-- The last sentence of Appendix D, PDF p. 13. -/
theorem klDiv_dirac_eq {W : Type*} [MeasurableSpace W]
    [Countable W] [MeasurableSingletonClass W]
    (Q : Measure W) [IsProbabilityMeasure Q] (w : W)
    (hQ : Q {w} ≠ 0) :
    klDiv (Measure.dirac w) Q =
      ENNReal.ofReal (-Real.log (Q {w}).toReal) := by sorry

end InfoGen.Gibbs
Source
Xu & Raginsky, arXiv:1705.07809v2, App. D, final sentence after (D.15), p. 13
Human review
  • Endorsed by Shuze Chen · Oct 8, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 8, 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