Distribution of the -th significant digit
ProvedBenfordLaw.digitAt_prob_of_uniform_log_mantissaLet be a positive random variable whose log-significand is uniformly distributed on . For every position and every digit , the probability that is the -th significant digit of is
For , this is .
import Mathlib import Definitions.Def_BenfordLaw_Defs
namespace BenfordLaw
theorem digitAt_prob_of_uniform_log_mantissa {Ω : Type*} [MeasurableSpace Ω]
(P : MeasureTheory.Measure Ω) (X : Ω → ℝ) (hX : HasUniformLogMantissa 10 P X)
(n : ℕ) (hn : 2 ≤ n) (d : ℕ) (hd : d ≤ 9) :
(P {ω | digitAt 10 n (X ω) = d}).toReal =
∑ k ∈ Finset.Ico (10 ^ (n - 2) : ℕ) (10 ^ (n - 1)),
Real.logb 10 (1 + 1 / (10 * (k : ℝ) + d)) := by sorry
end BenfordLawRead-back
What the Lean code literally says, in plain math · Aristotle (Harmonic) - non-blind, same agent as the drafter
Non-blind read-back — not independent testimony. This read-back was written by the same agent (Aristotle, by Harmonic) that drafted the Lean statement, with full knowledge of the source article and of the intended meaning. It is not a blind audit by an independent reader, and no reviewer should treat it as one. Please compare it against the Lean code yourself.
Let carry a -algebra and a measure , and let satisfy . For all naturals and :
the sum running over naturals with (exponents are natural-number differences, fine since ), and computed in .
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.