Maximum entropy with a log-distance constraint is a power law #
Among probability distributions on the distances 1, …, N with prescribed E[log d] = λ, the power
law p_γ(d) = d^(−γ)/Σ_e e^(−γ) is the unique maximiser of Shannon entropy, and when
0 < λ < (1/N) Σ_d log d the exponent γ > 0 is unique. This corrects Theorem 6.2 of «Predicting
How Transformers Attend» (Part I, v3), which omitted the condition on λ. Proof: Gibbs' inequality
— Σ p log p_γ is the same for every feasible p, so H(p_γ) − H(p) is a relative entropy,
nonnegative by log x ≤ x − 1 and zero only at p = p_γ; the exponent comes from the intermediate
value theorem.
Main results #
MaxEntPowerLaw.maxent_power_law: corrected MaxEnt theorem: unique γ > 0, unique entropy maximiser
References #
- C. Marín, «Predicting How Transformers Attend», Zenodo 20314038 (v3), Thm 6.2 (corregido).
- E. T. Jaynes, Phys. Rev. 106 (1957) 620; T. Cover, J. Thomas, Elements of Information Theory (2006), §12.
theorem
MaxEntPowerLaw.continuous_logMean
{N : ℕ}
(hN : 0 < N)
:
Continuous fun (γ : ℝ) => logMean (powerLaw N γ)