AFTD Auto-Formalizing Theoretical Domains

hellinger_mutual_information

def

For finite types U and V, the Hellinger mutual information of a joint distribution p on U × V is defined as ∑ u, ∑ v, (Real.sqrt (p u v) - Real.sqrt ((∑ v', p u v') * (∑ u', p u' v)))^2, the squared Hellinger distance between p and the product of its marginals.

Statement

noncomputable def hellinger_mutual_information {U V : Type*} [Fintype U] [Fintype V]
    (p : U → V → ℝ) : ℝ
Defined in
scout/2610-21231-on-the-subadditivity-of-mutual-f-information.md:94
Verified
12 Nov 2026
Axioms
none listed
Used by 4

Read back from the Lean

Given finite types $U$ and $V$, and a real-valued function $p : U \to V \to \mathbb{R}$, hellinger_mutual_information p is defined as the sum over all $u \in U$ and $v \in V$ of $$\left(\sqrt{p(u, v)} - \sqrt{\left(\sum_{v' \in V} p(u, v')\right) \left(\sum_{u' \in U} p(u', v)\right)}\right)^2$$

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- The Hellinger mutual information of a joint distribution on finite sets. -/
noncomputable def hellinger_mutual_information {U V : Type*} [Fintype U] [Fintype V]
    (p : U → V → ℝ) : ℝ := ∑ u, ∑ v, (Real.sqrt (p u v) - Real.sqrt ((∑ v', p u v') * (∑ u', p u' v))) ^ 2
See it in the graphDiscuss this resultChallenge it