OctoInform Beta

OpenAI preprint, September 2026 · §3. Arithmetic, walks, and entropy · §3

Entropy conventions: Natural-log HH, H(X∣Y)H(X \mid Y), and I(X;Y∣Z)I(X; Y \mid Z), together with versions for arbitrary codomains agreeing with HH on finite codomains

Entropy and conditional mutual information on finite laws.

Hover over a blue or green term in the text, or a node in the graph, to find it in the other. Select it to read its declaration both in Lean and in words.

The setting

Take a finite sample space carrying a probability law and random variables defined on it. Measuring how much information one variable gives about another, conditioned on a third, requires fixing natural-log conventions for entropy and conditional mutual information, both for variables with finite codomains and for variables with arbitrary codomains, where the entropy is computed from the sets on which the variable is constant.

Finite probability laws

A finite probability law pp on a finite set SS is a function p:S→ℝp \colon S \to \mathbb{R} such that p(s)≥0p(s) \ge 0 for all s∈Ss \in S and ∑s∈Sp(s)=1\sum_{s \in S} p(s) = 1.✦ Given a finite probability law pp on SS and a map f:S→Tf \colon S \to T to a finite set TT, the pushforward law f*pf_* p is the finite probability law on TT assigning to each t∈Tt \in T the total mass ∑s∈f−1(t)p(s)\sum_{s \in f^{-1}(t)} p(s).✦

Shannon entropy

For a function q:S→ℝq \colon S \to \mathbb{R} on a finite set SS, the Shannon entropy sum of qq is ∑s∈S(−q(s)log⁡q(s)),\sum_{s \in S} \bigl(-q(s)\log q(s)\bigr),(1)✦ taken with natural logarithms and the convention 0log⁡0=00\log 0 = 0. For a finite probability law pp on SS, the entropy H(p)H(p) of the law pp is the Shannon entropy sum (1) evaluated at pp.✦

Fiber entropy

For a finite probability law pp on a finite sample space Ω\Omega and a variable X:Ω→αX \colon \Omega \to \alpha taking values in an arbitrary set α\alpha, the fiber entropy Hf(X)H_f(X) with respect to pp is the Shannon entropy of the law of XX on the finitely many values that XX takes.✦ Given a finite probability law pp on a finite sample space Ω\Omega and two variables X:Ω→αX \colon \Omega \to \alpha and Y:Ω→βY \colon \Omega \to \beta with arbitrary codomains α\alpha and β\beta, the fiber conditional entropy Hf(X∣Y)H_f(X \mid Y) is Hf(X∣Y)=Hf(X,Y)−Hf(Y),H_f(X \mid Y) = H_f(X, Y) - H_f(Y),(2)✦ where (X,Y)(X, Y) in (2) denotes the paired variable ω↦(X(ω),Y(ω))\omega \mapsto (X(\omega), Y(\omega)).

The claim

Definition. Let pp be a finite probability law on a finite sample space Ω\Omega. For a variable X:Ω→αX \colon \Omega \to \alpha taking values in a finite set α\alpha, the entropy of XX is H(X)=H(X*p)H(X) = H(X_* p).✦ For variables X:Ω→αX \colon \Omega \to \alpha and Y:Ω→βY \colon \Omega \to \beta taking values in finite sets α\alpha and β\beta, the conditional entropy H(X∣Y)H(X \mid Y) is H(X∣Y)=H(X,Y)−H(Y).H(X \mid Y) = H(X, Y) - H(Y).(3)✦ Using the conditional entropy (3), for variables X:Ω→αX \colon \Omega \to \alpha, Y:Ω→βY \colon \Omega \to \beta, and Z:Ω→γZ \colon \Omega \to \gamma taking values in finite sets α\alpha, β\beta, and γ\gamma, the conditional mutual information I(X;Y∣Z)I(X; Y \mid Z) is I(X;Y∣Z)=H(X∣Z)−H(X∣Y,Z).I(X; Y \mid Z) = H(X \mid Z) - H(X \mid Y, Z).(4)✦ Alongside (4), for variables X:Ω→αX \colon \Omega \to \alpha, Y:Ω→βY \colon \Omega \to \beta, and Z:Ω→γZ \colon \Omega \to \gamma taking values in arbitrary sets α\alpha, β\beta, and γ\gamma, the fiber conditional mutual information If(X;Y∣Z)I_f(X; Y \mid Z) is If(X;Y∣Z)=Hf(X∣Z)−Hf(X∣Z,Y).I_f(X; Y \mid Z) = H_f(X \mid Z) - H_f(X \mid Z, Y).(5)✦ For every variable X:Ω→αX \colon \Omega \to \alpha taking values in a finite set α\alpha, the fiber entropy agrees with the entropy: Hf(X)=H(X).H_f(X) = H(X).(6)✦

In the paper, the result reads: for a finite variable XX with law μ\mu (corresponding to X*pX_* p), H(X)=−∑xμ(x)log⁡μ(x)H(X) = -\sum_x \mu(x)\log \mu(x) with 0log⁡0=00\log 0 = 0, conditional entropy and conditional mutual information take their usual finite-alphabet forms with I(X;Y∣Z)=H(X∣Z)−H(X∣Y,Z)I(X; Y \mid Z) = H(X \mid Z) - H(X \mid Y, Z), and when residue maps are selected randomly, those maps are fixed first to compute entropy in the walk-sampling experiment and averaged over only afterward.

What is checked

The entropy H(X)H(X), the conventions (3), (4), and (5), and the identity (6) are stated over finite probability laws on a finite sample space Ω\Omega, pushforward laws on finite sets, Shannon entropy sums with natural logarithms, and fiber entropies for variables taking values in arbitrary sets.