Alphabeta Math
Pipeline-generated
How statement and proof provenance work

The first chip identifies the source of the statement or construction; the second identifies the source of its local proof or verification.

  • Literature-sourced: the exact statement appears in a cited source; only wording and notation differ.
  • AI-adapted: a semantically identical restatement of literature-sourced material, modulo indexing, notation, and boundary cases adopted by the library.
  • AI-generated: a genuinely novel statement formulated by AI, with no source for the claim itself.

These labels describe origin, not correctness: citations and verification chips remain separate evidence.

✓ 14 results · all verified · 2 also independently AI-judged
Every result on this page is machine-checked by a proof checker and read in full and owner-audited; the judge is an additional, independent cross-model AI review of the proofs. The 12 not AI-judged were verified by owner audit (typically over a confirmed judge false positive), not failures.

Stationary Ergodic Sources and Universal Coding

1 · Prerequisites

2 · Summary

This page uses two-sided finite-alphabet path laws and the left shift for stationary sources, with the convention H2(p)=Hnat(p)/ln⁡2. Existing finite-distribution entropy is in nats; information densities, entropy rates, and code rates here are in bits per symbol. General-process rates use a limsup; stationarity supplies the limit.

The componentwise SMB proof is choice-free through the finite-past martingale and Birkhoff average. Its conditional-expectation identification is a separate AC corollary. The AMS extension states its inherited AC use through the tail-domination proof. Fixed-rate coding is stated strictly above and below the entropy rate, with no boundary claim at equality. The full-past conditional block information rate is built from finite-past martingale limits and is proved choice-free.

LZ78 uses an explicit Elias-delta parent index, fixed-width alphabet symbols, and a terminal marker. The expected-rate result is for every stationary source and does not assume ergodicity. The individual-sequence theorem is the one-sided finite-state bound lim sup⁡LLZ/n≤ρFS; equality and convergence are not asserted. The LZ77 previous-match theorem proves n−1log⁡2Rn→h in probability and, for h>0, its inverse window-length limit; its proof uses Kac return-time integrals, SMB, and a conditional-block counting bound.

No pair-specific design section was found. The current IT05 plan summary governs this scope.

Source trail

  • Robert M. Gray, Entropy and Information Theory, corrected edition (source), Ch. 8 §§8.2–8.4, printed pp.153–164: stationary, componentwise, and AMS entropy theorem proofs; Ch. 11 §§11.2, 11.4 for source coding.
  • Robert M. Gray, Probability, Random Processes, and Ergodic Properties (source), §6.3, printed pp.130–132: AMS stationary-mean asymptotic domination, the RN decomposition estimate, and null future-tail transfer.
  • Paul H. Algoet and Thomas M. Cover, “A Sandwich Proof of the Shannon–McMillan–Breiman Theorem,” Annals of Probability 16 (1988), 899–909 (source), Theorem 4, PDF pp.8–9: generalized AEP for AMS sources by likelihood-ratio sandwich.
  • Thomas M. Cover and Joy A. Thomas, Elements of Information Theory, 2nd ed. (source), Ch. 2 source coding and prefix bounds; Ch. 13 §§13.4–13.5, printed pp.440–456: LZ78, Ziv inequality, finite-state bound, and LZ77 recurrence coding.
  • MIT OpenCourseWare 6.441, Chapter 8: Compressing Stationary Ergodic Sources (source), §8.2, PDF pp.93–95: full finite-order Markov approximation proof of stationary ergodic SMB.
  • Stanford EE376C, Lempel-Ziv Compression lecture notes (source), §§1.3–1.5, PDF pp.4–9: LZ78 Ziv inequality and expected universality proof; finite-state and LZ77 theorem statements.
  • Satyadev Nandakumar, IIT Kanpur LZ78 lecture transcription (2014) (source), §§1.3–1.5, PDF pp.4–9: individual-sequence LZ78 bound and finite-state optimality argument.
  • Northeastern University, Lempel–Ziv Lecture 3–4 (source), Definition and theorem statement for greedy LZ77 phrase lengths; proof is not supplied in these notes.
  • Ioannis Kontoyiannis, Recurrence and Waiting Times in Stationary Processes and Their Applications in Data Compression, Stanford University dissertation (full text), Chapter 3 §§3.1–3.2, PDF pp.50–57 (printed pp.35–42): the backward recurrence definition, Theorem 3.1 and Corollary 3.1(a), and the complete proof of Theorem 3.1. The local recurrence proof reproduces the relevant upper-tail Kac/SMB and lower-tail conditional-counting arguments, then proves the inverse window-length statement.
  • A. D. Wyner and J. Ziv, “Some asymptotic properties of the entropy of a stationary ergodic data source with applications to data compression,” IEEE Transactions on Information Theory 35 (1989), 1250–1258 (bibliographic record). The primary text could not be inspected after the publisher/mirror/archive routes in the coverage ledger; it is dropped only as evidentiary support. The theorem remains fully covered by the dissertation treatment and local proof.

3 · Logical flowchart

4 · Definitions, theorems and proofs

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Finite-alphabet stationary source

Definition

Consider a finite nonempty alphabet A, a probability measure P on AZ, and the left shift T(x)j=xj+1.

The shift is measurable on the product sigma-algebra. Call P stationary when it is measure preserving under this shift, precisely the condition in Measure-preserving transformations and systems.

For a stationary P, call the source ergodic when each event E satisfying T−1E=E has P(E)∈{0,1}; by Ergodicity relative to an invariant measure this is exactly ergodicity of the probability system.

Facts & Assumptions

Given: A finite nonempty alphabet A, a probability measure P on AZ, and the left shift T(x)j=xj+1.

[F1]

Measure-preserving transformations and systems: T preserves P exactly when P(T−1E)=P(E) for each measurable event E.

[F2]

Ergodicity relative to an invariant measure: a probability-preserving system is ergodic when each strictly invariant event has probability zero or one.

Proof

Given: The objects in the statement and the conventions [F1]–[F2].

1.1givenF1algebra

A basic product cylinder restricts only finitely many coordinates. Its inverse image under T imposes the same restrictions on the coordinates shifted by one, so is again a product cylinder and is measurable. Since product cylinders generate the product sigma-algebra and inverse image preserves complements and countable unions, T is measurable on that sigma-algebra. Call P stationary when it is measure preserving under this measurable shift, precisely the condition in [F1].

2.1F2step 1.1algebra∎

For a stationary P, call the source ergodic when each event E satisfying T−1E=E has P(E)∈{0,1}; by [F2] this is exactly ergodicity of the probability system.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Finite-block information and entropy in bits

Definition

Consider a finite alphabet A and a random block X0n−1 with law pn on An.

Define log⁡2t:=ln⁡t/ln⁡2 for t>0. The denominator is positive because 2>1, ln⁡ is strictly increasing, and ln⁡1=0 by The natural logarithm as the inverse of the exponential function, Order, continuity, range, and the product, quotient, and reciprocal laws for the natural logarithm. For every positive-probability block x, define its information in bits by In(2)(x)=−log⁡2pn(x); values on zero-probability blocks may be set to +∞ because they are never sampled.

Define block entropy in bits by Hn(2):=EIn(2)(X0n−1)=Hnat(pn)/ln⁡2. Finite summation and Finite distributions, entropy, divergence, and stochastic matrices show this equals −∑x:pn(x)>0pn(x)log⁡2pn(x). Thus the library's entropy interface stays in nats while this page's information and coding rates use bits. For any probability law p on a finite set, put H2(p):=Hnat(p)/ln⁡2=−∑x:p(x)>0p(x)log⁡2p(x), and write H2(U):=H2(PU) for a finite-valued random variable U. For finite-valued U,V, also define conditional entropy by H2(U∣V)=∑v:P(V=v)>0P(V=v)H2(PU∣V=v); zero-probability conditioning values are omitted.

Facts & Assumptions

Given: A finite alphabet A and a random block X0n−1 with law pn on An.

[F1]

Finite distributions, entropy, divergence, and stochastic matrices: the existing finite entropy is Hnat(p)=−∑xp(x)ln⁡p(x) nats, with 0ln⁡0=0.

Proof

Given: The finite law and [F1]–[F2].

1.1F2givenalgebra

Define log⁡2t:=ln⁡t/ln⁡2 for t>0. The denominator is positive because 2>1, ln⁡ is strictly increasing, and ln⁡1=0 by [F2]. For every positive-probability block x, define its information in bits by In(2)(x)=−log⁡2pn(x); values on zero-probability blocks may be set to +∞ because they are never sampled.

2.1F1F2step 1.1algebra∎

Define block entropy in bits by Hn(2):=EIn(2)(X0n−1)=Hnat(pn)/ln⁡2. Finite summation and [F1] show this equals −∑x:pn(x)>0pn(x)log⁡2pn(x). Thus the library's entropy interface stays in nats while this page's information and coding rates use bits. For any probability law p on a finite set, put H2(p):=Hnat(p)/ln⁡2=−∑x:p(x)>0p(x)log⁡2p(x), and write H2(U):=H2(PU) for a finite-valued random variable U. For finite-valued U,V, also define conditional entropy by H2(U∣V)=∑v:P(V=v)>0P(V=v)H2(PU∣V=v); zero-probability conditioning values are omitted.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Binary prefix codes on finite supports

Definition

Let M be a finite nonempty message set. A binary prefix code on M is an injective assignment c:M→{0,1}∗ such that no assigned string is a proper initial segment of another assigned string. Write ℓ(m):=∣c(m)∣ for its codeword lengths. For a probability vector p on M, its expected length is Lp(c):=∑m∈Mp(m)ℓ(m).

The empty string is permitted only when M is a singleton. In that case it describes one known source block, or a known number of copies of the sole message; the message count is part of the framing convention. For arbitrary concatenations whose message count is not supplied, require every codeword to be nonempty. Thus a singleton source can retain a zero-bit code for one known block without claiming unknown-count decoding.

Facts & Assumptions

Given: The finite message set and code assignment in the Definition.

Proof

1.1givenalgebra

One codeword determines its message by injectivity. In the singleton empty-word case, a known count determines the unique message list, whereas distinct unknown counts all give the same empty string. In particular, the empty string describes one known block with length zero.

2.1givenstep 1.1algebra∎

If all codewords are nonempty, at most one codeword can prefix an unread concatenation, because any two such prefixes would be comparable by the prefix relation and injectivity excludes equal codewords for different messages. Remove that nonempty codeword and repeat; the finite unread length decreases, so this recovers the complete message list without a supplied count.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Triangular averages of finite-past information converge to the infinite-past average

Statement

If nonnegative integrable-envelope functions gk converge μ-almost everywhere to g, proves the triangular averages of (gk−g)∘Tk tend to zero μ-almost everywhere and in L1(μ) on a finite measure-preserving system.

Facts & Assumptions

Given: A finite-measure-preserving system (Ω,F,μ,T), with μ(Ω)<∞, and finite-valued measurable functions gj≥0 with gj→g μ-almost everywhere and G:=sup⁡jgj∈L1(μ).

[F1]

Birkhoff pointwise ergodic theorem: time averages of an integrable function in a measure-preserving system converge almost surely to an integrable limit.

[F2]

Ergodic averages converge in Lp on finite-measure spaces: on a finite-measure space, the time averages converge in L1 to their Birkhoff limit.

[F3]

Measure-preserving transformations and systems: μ(T−1E)=μ(E), so every Ti preserves μ.

[F4]

Dominated convergence: pointwise convergence under an integrable envelope implies convergence of integrals.

[F5]

Integral invariance under measure-preserving maps: if T preserves μ and f≥0 is measurable, then ∫f∘T dμ=∫f dμ, including infinite values.

[F6]

The modulus of an integral is bounded by the integral of the modulus: for every f∈L1(μ), ∣∫f dμ∣≤∫∣f∣ dμ.

[F7]

The Lebesgue integral is linear on L1(μ): the integral is linear on L1(μ).

Proof

Given: The hypotheses and [F1]–[F7].

1.1F4givenalgebra

For each K, put UK=sup⁡j≥K∣gj−g∣. Then UK↓0 μ-almost everywhere and 0≤UK≤2G almost everywhere, since g≤G as a pointwise limit. Dominated convergence [F4] gives ∫UK dμ→0.

1.2F3F4F5F7givenalgebra

Since gi→g almost everywhere and ∣gi−g∣≤2G, [F4] gives ∫∣gi−g∣ dμ→0. By [F3, F5], ∫∣gi−g∣∘Ti dμ=∫∣gi−g∣ dμ, so linearity [F7] makes the integral of the absolute triangular error n−1∑i<n∫∣gi−g∣ dμ→0 by Cesaro averaging. Thus the error tends to zero in L1(μ).

2.1F1F2F3F5F6F7step 1.1

Fix K. For i≥K, ∣gi−g∣≤UK. Hence for n>K, the average of ∣gi−g∣∘Ti is bounded by the first K terms divided by n, plus n−1∑i=Kn−1UK∘Ti. The first part tends to zero almost everywhere. By [F1], the second part converges almost everywhere to the Birkhoff limit UK∗; by [F2], the averages converge to UK∗ in L1(μ). By [F3, F5, F7], every average has integral ∫UK dμ. Thus [F6] and the L1 convergence give ∣∫UK dμ−∫UK∗ dμ∣≤∥AnUK−UK∗∥1→0. Therefore UK∗∈L1(μ) and ∫UK∗ dμ=∫UK dμ.

3.1F4step 1.1step 2.1algebra

Apply step 2.1 to every integer K on the intersection of the resulting countably many full-measure sets. The limsup of the left side is at most UK∗ for each K. Since UK decreases pointwise, the averages and their limits UK∗ decrease almost everywhere. They are nonnegative and bounded by the integrable U1∗; dominated convergence [F4] gives ∫inf⁡KUK∗ dμ=lim⁡K∫UK∗ dμ=lim⁡K∫UK dμ=0. Thus inf⁡KUK∗=0 almost everywhere, and the limsup is zero. Therefore n−1∑i<n∣gi−g∣(Tiω)→0 almost everywhere.

4.1F1F2step 3.1step 1.2algebra∎

By [F1]–[F2], the Birkhoff averages of g converge almost everywhere and in L1(μ) to their Birkhoff limit. Steps 3.1 and 1.2 show the triangular averages differ from these averages by quantities tending to zero almost everywhere and in L1(μ), respectively. Hence both modes of convergence hold with the same limit.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Finite KL nonnegativity for subprobability references

Statement

Proves ln⁡t≤t−1 for t>0 and, for finite probability weights p and positive-on-support reference weights q with ∑iqi≤1, proves ∑i:pi>0pilog⁡2(pi/qi)≥0 by an explicit finite argument without choice.

Facts & Assumptions

Given: A finite probability vector p=(pi) and nonnegative reference weights qi with qi>0 whenever pi>0 and ∑iqi≤1.

[F1]

Finite-block information and entropy in bits: log⁡2t=ln⁡t/ln⁡2 and ln⁡2>0.

[F2]

The integral logarithm L(x):=∫1xdtt for x>0: L(t)=∫1tdu/u, with oriented limits.

[F4]

If f≤g on [a,b] and both are integrable then ∫abf≤∫abg; and m(b−a)≤∫abf≤M(b−a): if integrable functions obey a pointwise order on an interval with increasing endpoints, their integrals obey the same order.

[F5]

The natural logarithm as the inverse of the exponential function: log⁡ is the natural logarithm, the inverse of exp⁡.

Proof

Given: The finite weights and hypotheses above.

1.1F2F3F4F5F6F7algebra

The integral logarithm is the natural logarithm by [F3] and [F5]. If t>1, then 1/u≤1 on [1,t], so [F2]–[F4] give ln⁡t=∫1tdu/u≤t−1. If 0<t<1, then 1/u≥1 on [t,1], so ∫t1du/u≥1−t; [F3] and [F7] give ln⁡t=−∫t1du/u≤t−1. At t=1, [F6] gives equality. Therefore ln⁡t≤t−1 for all t>0.

2.1F1step 1.1givenalgebra∎

Apply step 1.1 to t=qi/pi for every i with pi>0. Then ∑i:pi>0piln⁡(pi/qi)=−∑i:pi>0piln⁡(qi/pi)≥∑i:pi>0(pi−qi)=1−∑i:pi>0qi≥0. Dividing by ln⁡2>0 gives the same nonnegativity for the bit-log sum. Thus finite KL nonnegativity against a subprobability reference, as well as the logarithm inequality used to prove it, follows from finite sums and elementary integral bounds; no choice axiom enters.

AlgorithmAlgorithm: AI-adaptedProof: Not applicableprecheck pendingOpen item page →

Finite-block LZ78 incremental prefix code

Definition

Input: A finite alphabet A of size q≥2, an integer n≥0, a word x0n−1∈An (with x0−1 denoting the empty word when n=0), and a terminator # not in A. Fix an injective sq:=⌈log⁡2(q+1)⌉-bit symbol field for A∪{#}. The alphabet convention is that of Finite-alphabet stationary source. Output, when the procedure terminates: a finite terminated binary record stream; prefix codes use Binary prefix codes on finite supports.

  1. Start with dictionary D[0]=ϵ and unread text x0n−1#. While text remains, let w be the longest dictionary word prefixing the unread text, let i be its dictionary index, and let c be the next symbol. Output the record (i,c) and remove the prefix wc from the unread text. If c≠#, append wc as the next dictionary entry; if c=#, stop without inserting the terminal phrase.

  2. Serialize each parent index i≥0 by the Elias-delta code of m=i+1. Put b=⌊log⁡2m⌋+1 and d=⌊log⁡2b⌋+1. Emit d−1 zeros, then the d-bit binary expansion of b, then the final b−1 bits of the b-bit binary expansion of m. Append the fixed-width symbol field for c. Concatenate these records in parser order, including the final marker record.

  3. To decode an encoded block, start with dictionary D[0]=ϵ. Count the leading zeros before the first 1 of an index header as z and set d=z+1. Read the following d−1 bits; together with that first 1, these are the d-bit binary expansion of b. Read the next b−1 bits and prepend 1 to recover m; put i=m−1. Read the next sq bits as c, and emit D[i]c. Append that phrase to the dictionary when c≠#, then read the next record. At the first c=#, stop without insertion and remove the terminal marker from the decoded text. The decoder is specified on valid encoded streams and is not supplied the source length or record count.

Ordinary inserted phrases are dictionary entries; the final phrase containing # is an output record but is not a dictionary entry. Termination, distinctness of ordinary complete phrases, losslessness, the prefix property and the exact index-length bound are proved in Losslessness and prefix property of the explicit LZ78 code ↗.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Asymptotically mean stationary sources

Definition

Consider a measurable alphabet (A,B), a probability law P on AZ with its product sigma-algebra, and the measurable left shift T(x)j=xj+1.

The law P is asymptotically mean stationary (AMS) when for every measurable event E the limit Pˉ(E)=lim⁡N→∞1N∑j=0N−1P(T−jE) exists and the resulting set function is a probability measure.

The resulting law Pˉ is called the stationary mean when it is invariant under T, in the sense of Measure-preserving transformations and systems. If E is strictly shift invariant, then each summand P(T−jE)=P(E); hence P(E)=Pˉ(E). Tail events are handled by the separate domination lemma, not by this invariant-event identity.

Call the AMS source ergodic when its stationary mean Pˉ is ergodic as a measure-preserving system under the same shift. This uses Ergodicity relative to an invariant measure and is a property of the mean, not a claim that P itself is stationary. For finite discrete alphabets these conventions agree with Finite-alphabet stationary source.

Facts & Assumptions

Given: A measurable alphabet (A,B), a law P on its two-sided product space, and the left shift T.

[F1]

Measure-preserving transformations and systems: a probability law is invariant under a measurable shift exactly when P(T−1E)=P(E) for every measurable event E.

[F2]

Ergodicity relative to an invariant measure: ergodicity of a probability-preserving system means that every strictly invariant measurable event has probability zero or one.

Proof

Given: The law, shift, and product sigma-algebra.

1.1givenalgebra

Inverse images of product cylinders under T are product cylinders; since these generate the product sigma-algebra, T is measurable. The law P is asymptotically mean stationary (AMS) when for every measurable event E the limit Pˉ(E)=lim⁡N→∞1N∑j=0N−1P(T−jE) exists and the resulting set function is a probability measure.

2.1givenstep 1.1F1algebra

For each measurable E, the Ces`aro averages for T−1E and E differ by 1N∑j=0N−1P(T−(j+1)E)−1N∑j=0N−1P(T−jE)=P(T−NE)−P(E)N. The numerator has absolute value at most 1, so its quotient tends to zero. Taking limits, which exist by step 1.1 for both events, gives Pˉ(T−1E)=Pˉ(E). Thus the Ces`aro limit is stationary in the sense of [F1].

3.1F1step 1.1step 2.1algebra

The resulting law Pˉ is called the stationary mean when it is stationary in the sense of [F1]. If E is strictly shift invariant, then each summand P(T−jE)=P(E); hence P(E)=Pˉ(E). Tail events are handled by the separate domination lemma, not by this invariant-event identity.

4.1F2step 3.1algebra∎

Call the AMS source ergodic when its stationary mean Pˉ is ergodic as a measure-preserving system under the same shift. This is a property of the mean, not a claim that P itself is stationary.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingjudge pass (gpt-6-luna)Open item page →

Fixed-length lossless block codes and error probability

Definition

Consider a finite nonempty alphabet A, a positive integer n, a probability law Pn on An, and a rate R≥0 in bits per symbol. A rate-R fixed-length block code consists of a nonempty message set M⊆{0,1}⌊nR⌋, an encoder e:An→M, and a decoder d:M→An. Thus ∣M∣≤2⌊nR⌋ and every message is a binary word of the same length.

The code is lossless when d(e(x))=x for every x∈An; equivalently, e is injective and d is its inverse on the image. For a code with block error, define its success set by S={x∈An:d(e(x))=x} and its error probability by Pn(Sc). The encoder restricted to S is injective, so ∣S∣≤∣M∣≤2⌊nR⌋.

Facts & Assumptions

Given: A finite nonempty alphabet A, a positive integer n, a probability law Pn on An, and a rate R≥0.

[F1]

Finite-alphabet stationary source: the source alphabet is finite.

Proof

Given: The finite block domain, rate-R message set, and encoder and decoder maps in the Definition.

1.1F1givenalgebra

If d(e(x))=x for every x∈An, then e is injective: e(x)=e(y) implies x=d(e(x))=d(e(y))=y. Conversely, if e is injective, its inverse on the image is well-defined; a decoder is lossless exactly when it agrees with that inverse there, and its values off the image are irrelevant.

2.1givenstep 1.1algebra∎

If x,y∈S and e(x)=e(y), then x=d(e(x))=d(e(y))=y. Thus e restricted to S is injective, and the finite set S has cardinality at most ∣M∣≤2⌊nR⌋. Its error probability is Pn(Sc) by definition.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingjudge pass (gpt-6-luna)Open item page →

Finite-state compressibility of an individual sequence

Definition

Consider a finite alphabet A and a one-sided infinite sequence x=x0x1⋯.

An information-lossless s-state encoder consists of a finite state set S, an initial state, an update map g:S×A→S, and an output map f:S×A→{0,1}∗. It is information-lossless when for each initial state the map from finite input words to (concatenated output, final state) is injective.

Let LE(x0n−1) be its concatenated output length and set ρs(x)=inf⁡Elim sup⁡nLE(x0n−1)/n, over information-lossless encoders with at most s states. Define finite-state compressibility ρFS(x)=inf⁡s≥1ρs(x). The infima are nonincreasing in s and bounded below by zero, so the limit in the equivalent notation lim⁡s→∞ρs(x) exists.

Facts & Assumptions

Given: A finite alphabet A and a one-sided infinite sequence x=x0x1⋯.

[F1]

Finite-alphabet stationary source: the source alphabet is a finite nonempty set.

Proof

Given: The finite-state coding convention in the statement.

1.1F1givenalgebra

An information-lossless s-state encoder consists of a finite state set S, an initial state, an update map g:S×A→S, and an output map f:S×A→{0,1}∗. It is information-lossless when for each initial state the map from finite input words to (concatenated output, final state) is injective.

2.1givenstep 1.1constructalgebra∎

The encoder class is nonempty: let t=max⁡(1,⌈log⁡2∣A∣⌉) and choose distinct t-bit labels for the finitely many source symbols. Use one state with the identity update and emit each symbol's label. The output splits into fixed-width labels and therefore uniquely determines every finite input word. Let LE(x0n−1) be an encoder's concatenated output length and set ρs(x)=inf⁡Elim sup⁡nLE(x0n−1)/n, over information-lossless encoders with at most s states. Define finite-state compressibility ρFS(x)=inf⁡s≥1ρs(x). The infima are nonincreasing in s and bounded below by zero, so the limit in the equivalent notation lim⁡s→∞ρs(x) exists.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Information rate of a general finite-alphabet process

Definition

Consider a finite alphabet A and a process law P on AN0; Hn:=H(X0n−1) is as in Finite-block information and entropy in bits.

Define the upper information rate h‾(P):=lim sup⁡n→∞Hn/n and, when the limsup and liminf agree, the information rate h(P):=lim⁡n→∞Hn/n. This definition does not assume stationarity.

Since X0n−1 has at most ∣A∣n values, 0≤Hn≤nlog⁡2∣A∣; consequently the upper information rate is defined and lies in [0,log⁡2∣A∣], and whenever the information-rate limit exists it lies in the same interval.

Facts & Assumptions

Given: A finite alphabet A and a process law P on AN0; Hn:=H(X0n−1) is as in Finite-block information and entropy in bits.

[F1]

Finite-block information and entropy in bits: Hn is the Shannon entropy of the length-n block law.

[F2]

Finite KL nonnegativity for subprobability references: for a finite probability law p and a positive reference probability law q, ∑x:p(x)>0p(x)log⁡2(p(x)/q(x))≥0.

Proof

Given: The process and finite-block entropy [F1].

1.1F1givenalgebra

Define the upper information rate h‾(P):=lim sup⁡n→∞Hn/n and, when the limsup and liminf agree, the information rate h(P):=lim⁡n→∞Hn/n. This definition does not assume stationarity.

2.1F1F2givenstep 1.1algebra∎

Every positive block probability is at most one, so the finite-sum formula in [F1] gives Hn≥0. Let N=∣A∣n and compare the block law pn with the uniform law q(x)=1/N on the nonempty finite set An. By [F2], 0≤∑x:pn(x)>0pn(x)log⁡2pn(x)q(x)=−Hn+log⁡2N. Hence Hn≤log⁡2N=nlog⁡2∣A∣. Consequently the upper information rate is defined and lies in [0,log⁡2∣A∣], and whenever the information-rate limit exists it lies in the same interval.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

LZ77 previous-match length and recurrence time

Definition

Consider a finite alphabet A and a two-sided sequence x∈AZ.

For positive integers n,W, define the backward recurrence time of the current length-n block by Rn(x)=inf⁡{j≥1:(x−j,…,x−j+n−1)=(x0,…,xn−1)}, with Rn=+∞ if the set is empty. The start offset is positive, so the current block is not counted as its own match.

Define its previous-match phrase length in a window of width W by LW(x)=max⁡({0}∪{n≥1:Rn(x)≤W}), where the maximum is interpreted as +∞ when the set is unbounded. The empty match of length zero is always allowed. For a periodic sequence, LW can be infinite; the recurrence-time theorem will only be used to infer the logarithmic inverse relation in probability when h>0.

Facts & Assumptions

Given: A finite alphabet A and a two-sided sequence x∈AZ.

[F1]

Finite-alphabet stationary source: the source coordinates are indexed over Z and shifted by T(x)j=xj+1.

Proof

Given: The sequence and positive integers n,W.

1.1F1givenalgebra

Define the backward recurrence time of the current length-n block by Rn(x)=inf⁡{j≥1:(x−j,…,x−j+n−1)=(x0,…,xn−1)}, with Rn=+∞ if the set is empty. The start offset is positive, so the current block is not counted as its own match.

2.1F1step 1.1algebra

Define its previous-match phrase length in a window of width W by LW(x)=max⁡({0}∪{n≥1:Rn(x)≤W}), with maximum +∞ when the set is unbounded. The set is nonempty because it contains 0; if a length-m block matches at offset j, every shorter positive prefix also matches at the same offset, so the matched lengths form an initial segment. The empty match of length zero is always allowed.

3.1step 2.1algebra∎

For a periodic sequence, LW can be infinite; the recurrence-time theorem will only be used to infer the logarithmic inverse relation in probability when h>0.

DefinitionDefinition: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Finite-past information densities

Definition

Consider a stationary finite-alphabet source (Xi)i∈Z with law P and alphabet A.

For k≥0, let Fk=σ(X−k,…,X−1), with F0 trivial. For each a∈A, define pk(a)=P(X0=a∣Fk) by averaging over the finite atoms of Fk, and put gk=−log⁡2pk(X0) on the event pk(X0)>0, with arbitrary value on its null complement.

The selected probability is positive almost surely: on each atom B∈Fk with P(B)>0, P(X0=a∣B)=0 implies P(B∩{X0=a})=0. Thus gk is finite almost surely; Finite-alphabet stationary source identifies the same distributions after shifting any finite window.

Facts & Assumptions

Given: A stationary finite-alphabet source (Xi)i∈Z with law P and alphabet A.

[F1]

Finite-alphabet stationary source: the shift on AZ preserves P. [F2] Finite-block information and entropy in bits: for t>0, log⁡2t=ln⁡t/ln⁡2; the information of a positive-probability block is its negative bit logarithm.

Proof

Given: The source and conventions [F1]–[F2].

1.1givenalgebra

For k≥0, let Fk=σ(X−k,…,X−1), with F0 trivial. For each a∈A, define pk(a)=P(X0=a∣Fk) by averaging over the finite atoms of Fk, and put gk=−log⁡2pk(X0) on the event pk(X0)>0, with arbitrary value on its null complement.

2.1F1step 1.1algebra∎

The selected probability is positive almost surely: on each atom B∈Fk with P(B)>0, P(X0=a∣B)=0 implies P(B∩{X0=a})=0. Thus gk is finite almost surely; [F1] identifies the same distributions after shifting any finite window.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Entropy lower and Shannon upper bounds for finite prefix codes

Statement

For a finite distribution, proves every binary prefix code has expected length at least H and constructs a prefix code with expected length less than H+1 bit.

Facts & Assumptions

Given: A finite probability vector p and a binary prefix code with lengths ℓ(x) on its positive support, describing one known source block.

[F1]

Finite-block information and entropy in bits: H(p)=−∑p(x)>0p(x)log⁡2p(x).

[F2]

Binary prefix codes on finite supports: the codewords are prefix-free.

[F3]

Kraft inequality and effective prefix-code allocation: binary prefix-free code lengths satisfy K:=∑x2−ℓ(x)≤1; conversely any finite computable list of positive lengths with Kraft sum at most one has a prefix-free allocation.

[F4]

Finite KL nonnegativity for subprobability references: for probability weights p and reference weights r positive on their support with ∑xr(x)≤1, the bit-log sum ∑xp(x)log⁡2(p(x)/r(x)) is nonnegative, without choice.

Proof

Given: The source and code in the statement.

1.1F1F2F3F4givenalgebra

Put r(x)=2−ℓ(x)>0 on the positive support. By [F3], ∑xr(x)≤1, so [F4] gives 0≤∑xp(x)log⁡2(p(x)/r(x))=−H(p)+∑xp(x)ℓ(x). Thus every such code has expected length at least H(p). If the support has one point, one known block can be described by length zero and both entropy and optimal expected length are zero; no unknown message-count decoding is claimed.

2.1F1F3step 1.1algebra

Assume now that the support has at least two points. Then every positive p(x)<1, so ℓ(x)=⌈−log⁡2p(x)⌉ is a positive integer. It satisfies ∑x2−ℓ(x)≤∑xp(x)=1, so the finite binary Kraft criterion gives a prefix code. Also ℓ(x)<−log⁡2p(x)+1, hence its expected length is less than H(p)+1.

3.1F1F2step 1.1step 2.1algebra∎

For singleton support step 1.1 gives L∗(p)=H(p)=0<H(p)+1. For support of size at least two, taking the infimum over all prefix codes in step 1.1 and using the code constructed in step 2.1 proves H(p)≤L∗(p)<H(p)+1. Empty support cannot occur for a probability vector.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Finite entropy chain rule and monotonicity under conditioning

Statement

Proves the finite-alphabet entropy chain rule and that conditioning on additional finite-valued variables cannot increase conditional entropy, in bits.

Facts & Assumptions

Given: Finite-valued random variables X0,…,Xn−1.

[F1]

Finite-block information and entropy in bits: block entropy is Shannon entropy in bits of the finite joint law, with zero terms omitted by convention.

[F2]

Finite KL nonnegativity for subprobability references: finite KL is nonnegative against a subprobability reference, and division by ln⁡2>0 gives nonnegative bit divergence without an axiom of choice.

Proof

Given: The variables and entropy convention [F1].

1.1F1givenalgebra

On every positive-probability block, factor its probability into successive conditional probabilities by repeated use of P(A∩B)=P(A)P(B∣A). Taking −log⁡2 and averaging over the finite support yields H(X0n−1)=∑i=0n−1H(Xi∣X0i−1). The i=0 term is H(X0).

2.1F1step 1.1algebra

For finite random variables U,V, the same factorization gives H2(U,V)=H2(U)+H2(V∣U). Terms with P(U=u)=0 contribute zero, so no conditional law on a null event affects the identity.

3.1F1F2step 2.1algebra∎

For finite U,V,W, fix any v with P(V=v)>0. The conditional mutual information at that value is ∑wP(w∣v)D2(PU∣v,w∥PU∣v)≥0 by [F2]; if a conditional reference probability is zero, every positive-weight conditional law also assigns that outcome zero, so all displayed divergences are defined on their supports. Averaging over v gives H2(U∣V)−H2(U∣V,W)≥0.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

AEP criterion for fixed-rate lossless coding

Statement

For any finite-alphabet source with -n^{-1}log2 P(X^n) converging in probability to h, proves vanishing block error is achievable for R>h and impossible for R<h.

Facts & Assumptions

Given: Finite block laws pn on An, entropy-rate candidate h, a target rate R≥0, and normalized self-information In(Xn)/n from Finite-block information and entropy in bits. Assume In(Xn)/n→h in probability.

[F1]

Finite-block information and entropy in bits: In(x)=−log⁡2pn(x) on positive-probability blocks.

[F2]

Fixed-length lossless block codes and error probability: a rate-R code has message set M⊆{0,1}⌊nR⌋, encoder e:An→M, decoder d:M→An, and e injective on its success set.

Proof

Given: The AEP convergence and finite-block coding convention [F1]–[F2].

1.1F1givenalgebra

If h<0, then the nonnegative variable In(Xn)/n stays at distance at least −h from h, contradicting convergence in probability; hence h≥0. Let R>h and choose ϵ>0 with h+ϵ<R. Define Tn={x:pn(x)>0, In(x)≤n(h+ϵ)}. On Tn, each word has probability at least 2−n(h+ϵ), so ∣Tn∣≤2n(h+ϵ). The AEP gives P(Xn∈Tn)→1.

2.1F2step 1.1algebra

For all sufficiently large n, ∣Tn∣≤2⌊nR⌋, since R−h−ϵ>0. Fix an enumeration of the finite alphabet A once, and let a0 be its first symbol. For each such n, order Tn lexicographically, take Mn={0,1}⌊nR⌋ in lexicographic order, and map the jth typical block to the jth binary word. Define en by this assignment on Tn and by en(x)=0⌊nR⌋ otherwise. Define dn to return each typical block on its assigned message and a0n on all remaining messages. This is a rate-R code in the sense of [F2], and every block in Tn is decoded correctly. Its error is at most P(Xn∉Tn)→0. For the finitely many earlier n, take en constant at the all-zero message and dn constant at a0n.

3.1F1F2givenalgebra∎

Let 0≤R<h and choose ϵ>0 with R+ϵ<h. For any rate-R code, its success set Sn has at most 2⌊nR⌋ words by [F2]. Split it according to whether In(x)>n(R+ϵ). The probability of successful words in that part is at most 2nR2−n(R+ϵ)=2−nϵ, while the other part has total probability tending to zero by the AEP. Thus success probability tends to zero. At R=h neither conclusion is asserted.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Distinct-phrase count and Ziv inequality

Statement

For any distinct finite parsing over a finite alphabet and any order-k Markov kernel, proves the finite-block likelihood inequality grouped by phrase length and preceding context.

Facts & Assumptions

Given: A finite word y0m−1 over a finite alphabet B, any parsing y1,…,yN into distinct nonempty phrases, and a fixed context s∈Bk. The empty word may have the empty parsing. In the LZ78 specialization, include the terminator in B. An order-k Markov kernel consists of probability rows Q(⋅∣u) on B for every u∈Bk; Q(y∣u) denotes the product of its successive row probabilities while reading y from context u and updating the context with each symbol.

[F1]

Losslessness and prefix property of the explicit LZ78 code: ordinary complete LZ78 phrases are distinct, and the terminal phrase contains the unique marker.

[F2]

Finite-block information and entropy in bits: finite words have ordinary finite-alphabet probability laws.

Proof

Given: The distinct parsing, order-k kernel and fixed initial context.

1.1F1F2givenalgebra

For each phrase start i, let ui∈Bk be its preceding context, using s for the initial boundary; write ℓi=∣yi∣. For each pair (ℓ,u) let cℓ,u count phrases of that length and context. Markov factorization gives Q(y0m−1∣s)=∏iQ(yi∣ui).

2.1F1step 1.1algebra

Group the logarithm by (ℓ,u) with cℓ,u>0; groups of count zero contribute zero. Concavity of log⁡2 gives ∑i:(ℓi,ui)=(ℓ,u)log⁡2Q(yi∣u)≤cℓ,ulog⁡2(1cℓ,u∑iQ(yi∣u)). Within this group the phrase strings are distinct by the given parsing hypothesis (supplied by [F1] for the LZ78 specialization), so their conditional probabilities sum to at most one; therefore the group contribution is at most −cℓ,ulog⁡2cℓ,u.

3.1F2step 2.1algebra∎

Summing all groups and negating yields the Ziv inequality −log⁡2Q(y0m−1∣s)≥∑ℓ,ucℓ,ulog⁡2cℓ,u. For the augmented LZ78 specialization, the terminal phrase has the unique symbol # and cannot equal any ordinary phrase; [F1] supplies distinctness of the remaining phrases. For the empty parsing, both sides are zero. Zero kernel probabilities on an observed word make the left side +∞, and the inequality is then immediate.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

The stationary mean asymptotically dominates an AMS law

Statement

For an AMS law P with stationary mean Pbar, proves P(T^{-n}G) tends to zero for every event G with Pbar(G)=0.

Facts & Assumptions

Given: A probability measure P on a measurable space (Ω,F), a measurable map T, and an AMS stationary mean Pˉ as in Asymptotically mean stationary sources.

[F1]

Asymptotically mean stationary sources: Pˉ(G)=lim⁡NN−1∑j<NP(T−jG) for every measurable G, and Pˉ is stationary.

[F2]

Fatou's lemma: for nonnegative measurable functions fn, ∫lim inf⁡nfn dP≤lim inf⁡n∫fn dP.

Proof

Given: The AMS probability system and [F1]–[F2].

1.1F1given

If B is strictly invariant, then P(T−jB)=P(B) for every j, so [F1] gives Pˉ(B)=P(B). Thus the two laws agree on strictly invariant events.

2.1F1step 1.1algebra

Fix measurable G with Pˉ(G)=0 and set B=lim sup⁡nT−nG=⋂N⋃n≥NT−nG. Stationarity gives Pˉ(T−nG)=0 for each n, hence Pˉ(B)=0 by countable subadditivity. Also T−1B=B because removing the first term of a limsup does not change it. Step 1.1 yields P(B)=0.

3.1F2step 2.1algebra∎

Apply [F2] to fn=1(T−nG)c. Since lim inf⁡n(T−nG)c=Bc and P(Bc)=1 by step 2.1, Fatou gives 1=P(Bc)=∫lim inf⁡nfn dP≤lim inf⁡n(1−P(T−nG))=1−lim sup⁡nP(T−nG). Thus lim sup⁡nP(T−nG)≤0, and nonnegativity implies P(T−nG)→0. This is asymptotic domination of P by its stationary mean.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

Losslessness and prefix property of the explicit LZ78 code

Statement

Proves the specified parser terminates on every finite input, its ordinary complete phrases are distinct, and its finite-block LZ78 record stream is prefix-free and decodes the original block exactly, including the explicit terminal symbol.

Facts & Assumptions

Given: The LZ78 parser and terminated record convention of Finite-block LZ78 incremental prefix code, over an alphabet of size q≥2.

[F1]

Finite-block LZ78 incremental prefix code: each record is (parent dictionary index, next symbol); the final record contains the unique terminator #.

[F2]

Binary prefix codes on finite supports: nonempty prefix-free component codewords can be parsed in a concatenation without knowing the message count; the empty singleton exception applies only with a known count or one known block.

Proof

Given: The algorithm and symbol/record conventions [F1]–[F2].

1.1F1givenalgebra

Every dictionary entry is an ordinary word over A. While unread text remains it ends in #, which no dictionary word contains; the root is a prefix and the finite dictionary therefore has a longest matching prefix with a following symbol. Each iteration removes at least one symbol, so from the finite input followed by # the parser terminates after at most n+1 records, at a final marker record. If an ordinary phrase wc were already in the dictionary, it would be a longer dictionary prefix than the selected w, contradicting the longest-prefix rule. Thus ordinary inserted phrases are distinct; the terminal phrase contains # and is distinct from them.

1.2F1F2givenconstruct

For a parent index i≥0, put m=i+1, b=⌊log⁡2m⌋+1 and d=⌊log⁡2b⌋+1. The Elias-gamma code of b consists of d−1 zeros followed by the d-bit binary expansion of b. Its first 1 reveals d, after which exactly d−1 more bits complete b. Append the final b−1 bits of the binary expansion of m to form its Elias-delta code; the decoder restores the leading 1 of m and then returns i=m−1. Thus the gamma header determines exactly how many suffix bits to read. No codeword can be a proper prefix of another, because identical headers determine the same suffix length. For m=1,2,4 the codes are respectively 1, 0100, and 01100, so the case b=1 has an empty suffix but still a nonempty header. Appending a fixed-width ⌈log⁡2(q+1)⌉-bit symbol field gives an unambiguously delimited nonempty record.

2.1F1F2step 1.1step 1.2algebra

The decoder lookup and dictionary update of [F1] recover each phrase. Since # appears exactly once as the final symbol, decoding stops at the first such field, and a valid terminated codeword cannot be a proper prefix of another valid terminated codeword. Thus the concatenated records form a lossless prefix code on finite input words after termination.

3.1F1step 1.1step 1.2algebra∎

The exact index length is 2d−1+(b−1)=b+2d−2=b+2⌊log⁡2b⌋. At phrase number j≥1, the parent satisfies 0≤i<j, hence m≤j and b≤log⁡2(j+1)+1. Since b≤2log⁡2(j+2), its length is at most log⁡2(j+1)+2log⁡2log⁡2(j+2)+3. Thus, writing sq=⌈log⁡2(q+1)⌉, the N output records, including the final marker record, have total bit length at most N[log⁡2(N+1)+2log⁡2log⁡2(N+2)+3+sq]. This is O(Nlog⁡(N+1)), with the same bound valid for every small index including i=0. The final record is encoded and counted even though its phrase is not inserted into the dictionary.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

Entropy-rate limit for a stationary finite-alphabet source

Statement

Proves that n^{-1}H(X_0,...,X_{n-1}) converges under stationarity and equals the limit of the finite-past conditional entropies.

Facts & Assumptions

Given: A stationary finite-alphabet source (Xi)i∈Z and Hn=H(X0n−1).

[F1]

Finite-alphabet stationary source: every shifted finite block has the same law as the original block.

[F2]

Finite-block information and entropy in bits: Hn is the Shannon entropy of the length-n block.

[F3]

Finite entropy chain rule and monotonicity under conditioning: joint block entropy is the sum of successive conditional entropies, and conditioning on additional finite-valued variables cannot increase conditional entropy.

[F4]

Information rate of a general finite-alphabet process: for a finite-alphabet process, 0≤Hn/n≤log⁡2∣A∣.

Proof

Given: The source and [F1]–[F3].

1.1F1F2F3given

By the chain rule, H(X0n+m−1)=H(X0n−1)+H(Xnn+m−1∣X0n−1)≤Hn+Hm. The inequality follows because conditioning cannot increase entropy, and stationarity makes H(Xnn+m−1)=Hm. Thus (Hn) is subadditive.

2.1F1F2F3step 1.1algebra

Fix k≥1 and write n=ak+r with 0≤r<k. Repeated subadditivity gives Hn≤aHk+Hr, where H0=0 and the finitely many Hr are bounded by klog⁡2∣A∣. Hence lim sup⁡nHn/n≤Hk/k. Since Hn/n≥inf⁡j≥1Hj/j, taking the infimum over k proves the limit exists and equals h=inf⁡k≥1Hk/k.

3.1F1F2F3F4step 2.1algebra∎

For each k≥0, put ak=H(X0∣X−k−1), with a0=H(X0) for the empty past. By the conditioning monotonicity in [F3], (ak) is nonincreasing; it is bounded below by zero, so it has a limit a∞. The chain rule gives Hn=∑i=0n−1H(Xi∣X0i−1). By stationarity [F1], H(Xi∣X0i−1)=H(X0∣X−i−1)=ai. Therefore Hn/n=n−1∑i=0n−1ai→a∞ by Ces`aro convergence. Comparing with the limit h from step 2.1 yields h=a∞, the limit of finite-past conditional entropies. By [F4], h is finite and lies in [0,log⁡2∣A∣], including deterministic sources with h=0.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

A null future-tail event under the stationary mean is null under the AMS law

Statement

Assume AC. If the stationary mean asymptotically dominates P, proves every future-tail event E with Pbar(E)=0 satisfies P(E)=0.

Facts & Assumptions

Given: AC; a probability measure P and measurable map T whose stationary mean Pˉ asymptotically dominates P; and the future-tail sigma-algebra F∞=⋂n≥0σ(Xn,Xn+1,…) for the coordinate process.

[A1]

The Axiom of Choice: AC is used only for the countable family of Lebesgue decompositions and tail preimages below.

[F1]

The stationary mean asymptotically dominates an AMS law: if Pˉ(G)=0, then P(T−nG)→0.

[F2]

Every sigma-finite signed measure admits a Lebesgue decomposition relative to a sigma-finite positive measure: a finite positive measure decomposes into an absolutely continuous part with density and a mutually singular part.

[F3]

Mutual singularity for signed or complex measures and A positive, signed, or complex measure concentrated on a measurable set: a singular positive part is concentrated on a measurable carrier that is null for the reference measure.

[F4]

Asymptotically mean stationary sources: the stationary mean Pˉ is invariant under T.

Proof

Given: AC, an AMS law P with stationary mean Pˉ, and E∈F∞ with Pˉ(E)=0.

1.1A1F2F3given

For each n, define the probability measure Pn(B)=P(T−nB). By [F2] and countable choice [A1], write Pn(B)=∫Bfn dPˉ+σn(B), where fn≥0. The singularity in [F2] and the carrier convention [F3] give a measurable Nn with Pˉ(Nn)=0 on which σn is concentrated.

2.1F1step 1.1algebra

Put N=⋃nNn. Then Pˉ(N)=0, so [F1] gives Pn(N)=P(T−nN)→0. For every measurable B, 0≤Pn(B)−∫Bfn dPˉ=σn(B)≤σn(N)≤Pn(N). Thus the absolutely continuous approximations have error tending to zero uniformly over B.

3.1A1F4step 2.1givenalgebra∎

Since E∈F∞, for every n choose a measurable Bn with E=T−nBn. Stationarity [F4] gives Pˉ(Bn)=Pˉ(T−nBn)=Pˉ(E)=0, so ∫Bnfn dPˉ=0. Step 2.1 then gives P(E)=Pn(Bn)≤Pn(N)→0. Hence P(E)=0. The tail preimages form a countable family; no uncountable simultaneous version selection is made.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

LZ78 finite-state optimality for individual sequences

Statement

For each individual infinite sequence over an alphabet of size at least two, the limsup bit rate of the explicit block-reset LZ78 code is at most its finite-state compressibility.

Facts & Assumptions

Given: A one-sided infinite sequence x∈AN0 over a finite alphabet of size q≥2, and the block-reset LZ78 code of Finite-block LZ78 incremental prefix code.

[F1]

Losslessness and prefix property of the explicit LZ78 code: ordinary complete LZ78 phrases are distinct; the parser terminates with a final phrase containing the unique marker #.

[F2]

Losslessness and prefix property of the explicit LZ78 code: the explicit code has phrase-index cost log⁡2j+O(log⁡log⁡(j+2)) plus a fixed symbol cost.

[F3]

Finite-state compressibility of an individual sequence: an information-lossless finite-state encoder injects each finite input word into its output and final state for a fixed initial state.

[F4]

Finite KL nonnegativity for subprobability references: finite KL against any subprobability reference is nonnegative in bits, and ln⁡t≤t−1 for t>0.

Proof

Given: The sequence, LZ78 parser and finite-state coding convention.

1.1F1givenalgebra

Parse x0n−1# into N phrases. Let c=N−1 be the ordinary phrases inserted into the dictionary; they are distinct by [F1]. If the terminal phrase is w#, its source portion w is an existing dictionary word of depth at most c. For r=⌊12log⁡q(n+1)⌋, at most ∑j=1rqj=O(n) distinct ordinary phrases have length at most r, while longer phrases consume at least r+1 source symbols each. Thus c=O(n/log⁡n) and ∣w∣≤c=o(n).

2.1F1F3F4step 1.1algebra

Fix an information-lossless encoder E with at most s states. For each of the c ordinary phrases yi, record its starting state Si, output word Wi, and ending state Si+1. The tuples (Si,Wi,Si+1) are distinct: equality for two different phrase strings with the same initial state would contradict injectivity in [F3]. If J is uniform on the c phrases and L=∣WJ∣ has mean μ, then log⁡2c=H2(SJ,WJ,SJ+1)≤2log⁡2s+H2(L)+EL. The two state entropies are at most log⁡2s, by [F4] applied to the uniform law on each state set. Conditional on L, there are at most 2L possible binary strings, so H2(WJ∣L)≤EL.

3.1F3F4step 2.1algebra

If μ=0, then H2(L)=0. If μ>0, compare the finite-support law of L with the geometric weights rj=(μ+1)−1(μ/(μ+1))j restricted to that support. The reference weights sum to at most one, so nonnegative relative entropy [F4] gives H2(L)≤−Elog⁡2rL=(μ+1)log⁡2(μ+1)−μlog⁡2μ≤log⁡2(e(μ+1)), because ln⁡(1+x)≤x for x≥0, as the derivative of x−ln⁡(1+x) is nonnegative. The same upper bound holds when μ=0. Thus μ≥log⁡2c−2log⁡2s−log⁡2(e(μ+1)). If μ<log⁡2c, this error is Os(log⁡log⁡(c+2)); if μ≥log⁡2c, the same lower bound is immediate. The E output on these c phrases is at most its total block output, so clog⁡2c≤LE(x0n−1)+Os(clog⁡log⁡(c+2)).

4.1F1F2F3step 1.1step 3.1algebra

By [F2], the LZ78 description length is at most clog⁡2c+O(clog⁡log⁡(c+2))+O(log⁡(c+2)), including the terminal record. Since c=O(n/log⁡n), step 3.1 yields lim sup⁡nLLZ(x0n−1)/n≤lim sup⁡nLE(x0n−1)/n.

5.1F3step 4.1algebra∎

The inequality holds for every fixed s-state information-lossless encoder. Taking the infimum over such encoders and then over s proves that the LZ78 limsup rate is at most the finite-state compressibility ρFS(x). This is the one-sided individual-sequence optimality claim; equality or convergence of the LZ78 rate is not asserted.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Convergence and integrable envelope for finite-past information

Statement

Proves p_k(a) converges almost surely for each symbol, g_k converges on realized paths, and sup_k g_k is integrable with an explicit exponential tail bound.

Facts & Assumptions

Given: A stationary finite-alphabet source X with alphabet A, and the finite-past probabilities and information variables pk,gk of Finite-past information densities.

[F1]

Finite-alphabet stationary source: the shift preserves the path law.

[F2]

Finite-past information densities: pk(a)=P(X0=a∣X−k−1) on finite atoms and gk=−log⁡2pk(X0) almost surely.

[F3]

Finite entropy chain rule and monotonicity under conditioning: block entropy is the sum of successive conditional entropies.

[F4]

Entropy-rate limit for a stationary finite-alphabet source: H(X0n−1)/n converges to the entropy rate h.

[F5]

The monotone class generated by an algebra equals the sigma-algebra it generates: finite-past cylinder identities extend to the sigma-algebra they generate.

[F6]

Dominated convergence: almost-sure convergence under an integrable envelope implies convergence of integrals.

[F7]

Monotone convergence for the integral: integrals of increasing nonnegative functions converge to the integral of their pointwise limit.

Proof

Given: The source and definitions and supplier claims [F1]–[F7].

1.1F2given

Choose the null-set versions allowed by [F2] to be zero where pk(X0)=0, so each gk is nonnegative without changing any almost-sure claim. For each a∈A, pk(a)=E[1{X0=a}∣Fk] is a martingale in k for Fk=σ(X−k,…,X−1), because the finite-atom conditional averages satisfy the tower identity when the partition is refined. It is bounded between zero and one.

2.1F7givenalgebrastep 1.1

For rationals 0≤u<v≤1, the buy-at-u, sell-at-v strategy applied to this bounded martingale has expected gain zero; each completed upcrossing earns at least v−u, and an unfinished final holding loses at most one. Therefore the expected number of completed upcrossings by time N is at most (v−u)−1. By [F7], the total upcrossing count has finite expectation and is finite almost surely. Intersect over the countably many rational pairs and the finite alphabet: each pk(a) then converges to some p∞(a)∈[0,1].

3.1F5F6step 2.1given

For every finite-past cylinder B∈Fm, the tower identity gives ∫Bpk(a) dP=P(B∩{X0=a}) for all k≥m. Since 0≤pk(a)≤1 and pk(a)→p∞(a) almost surely, [F6] gives the same identity with p∞(a). For fixed a, the finite measures B↦∫Bp∞(a) dP and B↦P(B∩{X0=a}) agree on the algebra of finite-past cylinders. Their agreement class is a monotone class by continuity of finite measures, so [F5] extends the identity to every B∈F−. Thus p∞(a) is a conditional probability of X0=a given the full past.

4.1F2step 3.1algebra

The event {p∞(a)=0} belongs to F−. The conditional-probability identity from step 3.1 gives P(X0=a, p∞(a)=0)=∫1{p∞(a)=0}p∞(a) dP=0. Summing over the finite alphabet shows p∞(X0)>0 almost surely, so gk→g∞:=−log⁡2p∞(X0) almost surely.

5.1F2F6F7givenalgebrastep 4.1

For t≥0 and a∈A, let τa be the first k with pk(a)<2−t. On each event {τa=k}∈Fk, the tower identity gives P(X0=a,τa=k)=∫{τa=k}pk(a) dP≤2−tP(τa=k). Summing over k and then a yields P(G>t)≤∣A∣2−t for G=sup⁡kgk. For each integer M≥1, G∧M≤1+∑j=1M−11{G>j}, so [F7] and the tail bound give ∫G dP=lim⁡M∫(G∧M) dP≤1+∣A∣∑j≥12−j<∞. Since gk≤G and g∞≤G almost surely, [F6] also gives ∫gk dP→∫g∞ dP.

6.1F1F2F3F4step 5.1algebra∎

By stationarity [F1] and the chain rule [F3], Hn=∑k=0n−1H(Xk∣X0k−1)=∑k=0n−1H(X0∣X−k−1)=∑k=0n−1∫gk dP. Cesàro convergence and step 5.1 give lim⁡nHn/n=∫g∞ dP; [F4] identifies this limit as h. This also covers zero-probability transitions, which are never observed.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

Expected lossless prefix-code rate for stationary sources

Statement

For every stationary finite-alphabet source, the optimal expected prefix-code length for X^n divided by n converges to the entropy rate.

Facts & Assumptions

Given: A stationary finite-alphabet source, its length-n block entropy Hn, and the infimum Ln∗ of expected lengths among binary prefix codes describing one known length-n block on its positive-probability support.

[F1]

Finite-block information and entropy in bits: Hn is the entropy of the finite block law.

[F2]

Entropy lower and Shannon upper bounds for finite prefix codes: for every finite source, Hn≤Ln∗<Hn+1 bit.

Proof

Given: The source, code class and entropy conventions [F1]–[F3].

1.1F1F2given

Apply [F2] to each finite block law: Hn≤Ln∗<Hn+1. The lower bound includes every finite prefix code; the upper bound is attained within one bit by a Shannon code on the positive-probability support.

2.1F2F3step 1.1algebra

Divide by n and use [F3]. Since 1/n→0, both bounds converge to h, so Ln∗/n→h. No ergodicity is needed because the argument uses only stationary block entropies.

3.1F1F2step 2.1algebra∎

If the source is deterministic, then Hn=0 and the sole positive-probability block can be assigned the empty codeword; the rate is zero. For all other cases the same one-bit additive bound applies.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

Componentwise Shannon–McMillan–Breiman theorem

Statement

For every stationary finite-alphabet source, proves -n^{-1}log_2 P(X_0^{n-1}) converges almost surely and in L1 to the invariant Birkhoff limit of infinite-past information density, with mean equal to the entropy rate in bits.

Facts & Assumptions

Given: A stationary finite-alphabet source X over A, entropy rate h, and gk,g∞ from Finite-past information densities.

[F1]

Convergence and integrable envelope for finite-past information: gk→g∞ almost surely, g∞∈L1, and Eg∞=h.

[F2]

Triangular averages of finite-past information converge to the infinite-past average: under the integrable envelope, n−1∑i<ngi(Tix) and n−1∑i<ng∞(Tix) have the same almost-sure limit.

[F3]

Birkhoff pointwise ergodic theorem: time averages of g∞ converge almost surely to an invariant integrable limit.

[F4]

Ergodic averages converge in Lp on finite-measure spaces: those averages converge in L1 on the probability space.

Proof

Given: The source and [F1]–[F4].

1.1F1givenalgebra

The chain rule for finite block probabilities gives, almost surely, −log⁡2P(X0n−1)=∑i=0n−1−log⁡2P(Xi∣X0i−1)=∑i=0n−1gi(TiX). The equality holds on positive-probability blocks; their complement has probability zero.

2.1F1F2F3F4step 1.1

By [F3]–[F4], Ang∞=n−1∑i<ng∞(TiX) converges almost surely and in L1 to an invariant random variable G∗. By [F2] and step 1.1, the difference between −n−1log⁡2P(X0n−1) and Ang∞ tends to zero almost surely and in L1. This proves both asserted modes of convergence.

3.1F1F4step 2.1algebra∎

The L1 convergence [F4] implies EG∗=Eg∞=h; the limit is therefore finite and has mean equal to the stationary entropy rate. It need not be constant without ergodicity.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

LZ78 expected-rate universality for stationary sources

Statement

For every stationary finite-alphabet source, the expected explicit terminated LZ78 code length per source symbol converges to the entropy rate in bits, without an ergodicity assumption.

Facts & Assumptions

Given: A stationary source X on a finite nonempty alphabet, its bit entropy rate h, and the explicit terminated LZ78 code of Finite-block LZ78 incremental prefix code and Losslessness and prefix property of the explicit LZ78 code. For a singleton source alphabet, adjoin one fixed unused symbol of probability zero before applying the code, with the terminator still distinct; write A for this coding alphabet and q=∣A∣≥2.

[F1]

Losslessness and prefix property of the explicit LZ78 code: the terminated output is a nonempty prefix-free lossless code with no supplied record count; for N output records its length is at most N[log⁡2(N+1)+2log⁡2log⁡2(N+2)+3+⌈log⁡2(q+1)⌉].

[F2]

Distinct-phrase count and Ziv inequality: for a distinct parsing and any order-k kernel Q, −log⁡2Q(x0n−1#∣s)≥∑ℓ,ucℓ,ulog⁡2cℓ,u.

[F3]

Convergence and integrable envelope for finite-past information: the finite-past conditional entropy H2(X0∣X−k−1) tends to h.

[F4]

Expected lossless prefix-code rate for stationary sources: the optimal expected prefix-code rate tends to h.

[F5]

Finite KL nonnegativity for subprobability references: finite KL against any subprobability reference is nonnegative in bits, and ln⁡t≤t−1 for t>0.

[F6]

Finite entropy chain rule and monotonicity under conditioning: finite joint entropy satisfies the chain rule and conditioning cannot increase entropy.

Proof

Given: The stationary source, parser and code length convention.

1.1F2givenalgebra

Adjoining an unused symbol, if necessary, does not change any block probability, block entropy or entropy rate: every word containing the extra symbol has probability zero. Stationarity is retained under the coordinatewise inclusion. The resulting coding alphabet has q≥2, so the stated terminated algorithm is defined, including for an originally singleton source with h=0. Let N be the number of phrases in parsing X0n−1# over the augmented alphabet A∪{#}, and let cℓ,u count phrases of length ℓ and preceding k-symbol context u. The phrases are distinct. For r=⌊12log⁡q+1(n+1)⌋, at most ∑j=1r(q+1)j=O(n) phrases have length at most r, while longer phrases use at least r+1 symbols. Thus N=O(n/log⁡n) uniformly over input words.

2.1F2F5F6step 1.1algebra

Let P^(L=ℓ,U=u)=cℓ,u/N be the empirical law of a uniformly selected phrase. Since phrase lengths sum to n+1, EL=(n+1)/N, and U has at most qk values. If μ=EL>0, compare the finite-support law of L with the geometric weights rj=(μ+1)−1(μ/(μ+1))j, j≥0, restricted to that finite support. The restricted weights have sum at most one, so nonnegative relative entropy [F5] gives H2(L)≤−Elog⁡2rL=(μ+1)log⁡2(μ+1)−μlog⁡2μ≤log⁡2(e(μ+1)), because ln⁡(1+x)≤x for x≥0 (the derivative of x−ln⁡(1+x) is x/(1+x)≥0). The case μ=0 has H2(L)=0. Comparing U with the uniform law on its support and using [F5] gives H2(U)≤klog⁡2q; [F6] gives H2(L,U)≤H2(L)+H2(U). Since N=O(n/log⁡n), x↦xlog⁡((n+1)/x) is increasing on this range for all large n, so NH2(L,U)=O ⁣(nlog⁡log⁡nlog⁡n)+O ⁣(knlog⁡n)=o(n) for each fixed k.

3.1F1F2step 1.1step 2.1algebra

The explicit code length satisfies Ln≤N(log⁡2N+2log⁡2log⁡2(N+2)+C)+N⌈log⁡2(q+1)⌉. Since Nlog⁡2N=∑ℓ,ucℓ,ulog⁡2cℓ,u+NH2(L,U), combine [F2] with step 2.1. The Ziv inequality holds for every fixed initial context, so apply it pointwise with s=X−k−1. The index redundancy and symbol fields are o(n) uniformly for fixed k, giving Ln≤−log⁡2Qk(X0n−1#∣X−k−1)+o(n).

4.1F3step 3.1algebra

For the kernel in step 3.1 use the augmented alphabet A∪{#} and δ=1/(n+1). Define a probability row pk(⋅∣u) by the finite conditional law of X0 given X−k−1=u on positive-probability contexts and by any fixed point mass on A for zero-probability contexts. Set Qk,n(a∣u)=(1−δ)pk(a∣u) and Qk,n(#∣u)=δ; after # choose any stochastic row. Stationarity and the conditional-entropy definition give E[−log⁡2Qk,n(X0n−1#∣X−k−1)]=nH2(X0∣X−k−1)+nlog⁡211−δ+log⁡2(n+1)=nHk+O(log⁡n), since nln⁡(1+1/n)≤1. Thus [F3] and step 3.1 give lim sup⁡nELn/n≤h after k→∞.

5.1F1F4step 4.1algebra∎

By [F1], the LZ78 code is a prefix code, so its expected length is at least the optimal expected prefix-code length for that block. [F4] gives lim inf⁡nELn/n≥h. Together with step 4.1 this proves convergence to h. The proof uses stationarity but not ergodicity.

LemmaStatement: AI-adaptedProof: AI-generatedOpen item page →

Conditional block information rate given the infinite past

Statement

For each n≥1, constructs the conditional law of X0n−1 given the full infinite past by finite-past martingale limits, then proves its realized information per symbol converges almost surely to the entropy rate for every stationary ergodic finite-alphabet source, without choice.

Facts & Assumptions

Given: A stationary ergodic finite-alphabet source X=(Xi)i∈Z with bit entropy rate h, and F−:=σ(Xj:j<0).

[F1]

Convergence and integrable envelope for finite-past information, Proof steps 5.1–6.1: the finite-past one-symbol probabilities converge to p∞(a); the realized information g∞=−log⁡2p∞(X0) is nonnegative, integrable, and has mean h.

[F2]

The multiplication rule and finite chain rule for conditional probability: a finite joint probability factors into successive conditional probabilities on positive-probability prefixes.

[F3]

The monotone class generated by an algebra equals the sigma-algebra it generates: identities on the algebra of finite-past cylinders extend to F−.

[F4]

Monotone convergence for the integral: integrals of increasing nonnegative measurable functions converge to the integral of their pointwise limit.

[F5]

Dominated convergence: bounded almost-surely convergent functions on a probability space converge in integral when dominated by an integrable function.

[F6]

Birkhoff's theorem for an ergodic probability system: for an integrable function on an ergodic probability-preserving shift, its time averages converge almost surely to its integral.

Proof

Given: The source, entropy rate and sigma-algebra above.

1.1F4givenalgebra

For k≥0, n≥1 and each word w∈An, define qk,n(w) on each positive-probability atom of σ(X−k,…,X−1) as the conditional average of 1{X0n−1=w} there; on null atoms use the uniform vector on An. Refining the past partition shows that for fixed n,w, (qk,n(w))k≥0 is a martingale bounded in [0,1]. For rational 0≤u<v≤1, hold one unit after the martingale first falls to at most u, sell it when the martingale next reaches at least v, and repeat. Each finite-horizon gain is a sum of predictable holdings times martingale increments, so its expectation is zero by the martingale property. Every completed upcrossing earns at least v−u, and an unfinished holding loses at most one because the martingale stays in [0,1]. Thus the expected completed upcrossing count through any horizon is at most (v−u)−1. The counts increase with the horizon, so [F4] gives finite expected total count and hence finitely many total upcrossings almost surely for each rational pair. A bounded real sequence that does not converge has distinct liminf and limsup, hence has infinitely many upcrossings of some rational interval strictly between them. A countable intersection over rational pairs, words and lengths therefore gives simultaneous almost-sure limits q∞,n(w).

2.1F3F5step 1.1given

For each n, the limits are nonnegative and sum to one because there are finitely many words and every qk,n is a probability vector. They are F−-measurable. Every finite-past cylinder B belongs to the conditioning sigma-algebra for all sufficiently large k; [F5], with majorant one on the probability space, then gives ∫Bq∞,n(w) dP=P(B∩{X0n−1=w}). For fixed n,w, the finite measures B↦∫Bq∞,n(w) dP and B↦P(B∩{X0n−1=w}) agree on the algebra of finite-past cylinders. Their agreement class is a monotone class by continuity of finite measures, so [F3] extends the identity to every B∈F−. Thus q∞,n(w) is a conditional probability version of the block given the full past.

2.2F1F2step 1.1algebra

Fix a positive-probability atom B of the k-past partition. Applying [F2] to B and its successive intersections with the realized symbol events factors P(X0n−1=w∣B) into the one-symbol conditional probabilities on the refined atoms B∩{X0i−1=w0i−1}. By stationarity, the factor for Xi=wi is pk+i(wi)∘Ti, because the past X−(k+i)−1 at the shifted point Tix is exactly X−ki−1 at the original point x. Therefore, almost surely on the realized block, qk,n(X0n−1)=∏i=0n−1(pk+i(X0)∘Ti). For fixed n, each factor converges almost surely as k→∞ to p∞(X0)∘Ti, since the convergence in [F1] holds almost surely and each Ti preserves P. The left side converges to q∞,n(X0n−1) by step 1.1. The realized one-symbol limits are positive almost surely by [F1] and stationarity, so −log⁡2q∞,n(X0n−1)=∑i=0n−1g∞∘Tialmost surely.

3.1F1F6step 2.2given∎

Apply [F6] to g∞. By [F1] its integral is h, so the right side of step 2.2 divided by n converges almost surely to h. This proves the asserted conditional block-information rate and uses no choice axiom.

CorollaryStatement: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Ergodic Shannon–McMillan–Breiman theorem

Statement

For a stationary ergodic finite-alphabet source, the componentwise information-rate limit is the constant entropy rate.

Facts & Assumptions

Given: A stationary ergodic finite-alphabet source with entropy rate h.

[F1]

Componentwise Shannon–McMillan–Breiman theorem: normalized block self-information converges almost surely to an invariant random variable of mean h.

[F2]

Equivalent invariant-set and invariant-function criteria for ergodicity: every finite-valued invariant measurable function in an ergodic probability system is almost surely constant.

Proof

Given: The source and [F1]–[F2].

1.1F1F2given

By [F1], the normalized block information converges almost surely to an invariant G∗ with EG∗=h. Since the source is ergodic, [F2] makes G∗ a constant almost surely.

2.1F1step 1.1algebra∎

The expectation of a constant equals that constant, so G∗=h almost surely. Therefore −n−1log⁡2P(X0n−1)→h almost surely. For h=0 this says the normalized information tends to zero; no positive-rate assumption is used.

CorollaryStatement: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Invariant conditional-entropy description of the SMB limit

Statement

Under AC, identifies the componentwise SMB limit with E[g_infinity|I], conditional expectation of infinite-past information given the invariant sigma-algebra.

Facts & Assumptions

Given: AC, a stationary finite-alphabet source, its invariant sigma-algebra I={E:T−1E=E}, and g∞ from Finite-past information densities.

[A1]

The Axiom of Choice: AC is assumed only for the published finite-measure Birkhoff-limit identification used below.

[F1]

Componentwise Shannon–McMillan–Breiman theorem: the block information limit is the Birkhoff limit of g∞.

[F2]

Finite-measure identification of the Birkhoff limit: under AC, the Birkhoff limit integrates like the function over every strict invariant event.

[F3]

Conditional expectation given a sigma algebra: conditional expectation is characterized by measurability and equality of integrals on all events in the conditioning sigma-algebra.

[F4]

Strict and mod-null invariant sigma-algebras: the strict invariant sigma-algebra consists of events E satisfying T−1E=E.

Proof

Given: AC, the source, g∞ and the strict invariant sigma-algebra.

1.1A1F1F2F4given

The function g∞ is integrable by [F1]. Apply [F2] to its Birkhoff limit G∗ on the probability-preserving shift: G∗ has an I-measurable representative and ∫EG∗ dP=∫Eg∞ dP for every E∈I.

2.1F1F2F3step 1.1algebra∎

These are exactly the defining tests in [F3] for E[g∞∣I]. Hence G∗=E[g∞∣I] almost surely, and the componentwise SMB limit has this description by [F1]. AC is used only through [F2]; the componentwise SMB theorem itself does not use this identification.

CorollaryStatement: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Fixed-rate source coding theorem for stationary ergodic sources

Statement

For a stationary ergodic finite-alphabet source, fixed-rate lossless coding has vanishing block error above the entropy rate and success probability tending to zero below it.

Facts & Assumptions

Given: A stationary ergodic finite-alphabet source of entropy rate h, a target rate R≥0, and fixed-length binary block codes as in Fixed-length lossless block codes and error probability.

[F1]

Ergodic Shannon–McMillan–Breiman theorem: −n−1log⁡2P(X0n−1)→h almost surely, hence in probability.

[F2]

AEP criterion for fixed-rate lossless coding: information convergence in probability gives vanishing error above h and vanishing success below h.

[F3]

Dominated convergence: bounded almost-surely convergent indicators converge in expectation.

Proof

Given: The source, its entropy rate and coding convention.

1.1F1F3givenalgebra

Almost-sure convergence in [F1] implies convergence in probability: for each ϵ>0, the indicators of deviations by more than ϵ tend almost surely to zero and are bounded by one, so [F3] makes their expectations tend to zero.

2.1F1F2step 1.1∎

Apply [F2] with this AEP limit. For every R>h there are rate-R codes with block error tending to zero; for every R<h, every rate-R code sequence has success probability tending to zero. At R=h no boundary conclusion follows from the theorem.

TheoremStatement: AI-adaptedProof: AI-generatedOpen item page →

Shannon–McMillan limit for finite-alphabet AMS ergodic sources

Statement

Assume AC. For a finite-alphabet AMS source whose stationary mean is ergodic with bit entropy rate h, the normalized self-information -n^{-1}log_2 P(X_0^{n-1}) converges P-almost surely to h.

Facts & Assumptions

Given: AC; a finite nonempty alphabet A of size q; an AMS law P on AZ with stationary mean Pˉ; and suppose Pˉ is stationary ergodic with entropy rate h.

[A1]

The Axiom of Choice: AC is inherited only through the local tail-domination proof, which uses countably many Lebesgue decompositions.

[F1]

Asymptotically mean stationary sources: P is AMS with stationary mean Pˉ.

[F3]
[F4]

Ergodic Shannon–McMillan–Breiman theorem: under Pˉ, normalized cylinder self-information converges almost surely to h.

[F5]

The first Borel-Cantelli lemma for measures: events with summable probabilities occur only finitely often almost surely.

[F6]

The monotone class generated by an algebra equals the sigma-algebra it generates: equality tested on the generating algebra of finite future cylinders extends to its generated sigma-algebra.

[F7]

Dominated convergence: bounded almost-surely convergent functions on a probability space converge in integral.

[F8]

Monotone convergence for the integral: integrals of increasing nonnegative functions converge to the integral of their pointwise limit.

Proof

Given: AC and the AMS source with ergodic stationary mean in the statement.

1.1F8givenalgebra

If q=1, the source path is deterministic, every block has probability one, and h=0, so the claim holds. Assume henceforth q≥2. Fix k≥1. For each prefix u∈Ak, the finite conditional probabilities rn,k(u)=P(X0k−1=u∣Xkn−1),n>k, form a bounded martingale as the conditioning sigma-algebras increase. For each rational a<b in [0,1], the buy-at-a, sell-at-b strategy has expected gain zero; every completed upcrossing earns at least b−a and the final unsold position loses at most one. Thus the expected upcrossing count through any horizon is at most (b−a)−1. The counts increase with the horizon, so [F8] gives finite expected total count and hence finitely many upcrossings almost surely. Since a bounded real sequence that fails to converge has infinitely many upcrossings of some rational interval, countability of the rational pairs, prefixes and fixed k implies rn,k(u) converges almost surely.

2.1F1F6F7step 1.1algebra

For each finite future cylinder B∈σ(Xk,…,Xn−1), the conditional-probability identity gives ∫Brn,k(u) dP=P(B∩{X0k−1=u}). As n increases these conditional probabilities converge almost surely and lie in [0,1], so [F7] gives the same identity with r∞,k(u). The finite future cylinders form an algebra generating σ(Xk,Xk+1,…). The finite measures B↦∫Br∞,k(u) dP and B↦P(B∩{X0k−1=u}) agree on that algebra; their agreement class is a monotone class by continuity of finite measures, so [F6] extends the identity to the full future sigma-algebra. Thus r∞,k(u) is a version of the conditional probability of the prefix event given the full future. Therefore P(X0k−1=u, r∞,k(u)=0)=∫1{r∞,k(u)=0}r∞,k(u) dP=0. Since there are finitely many prefixes, the realized-prefix conditional probability converges to a positive value almost surely. Consequently, for fixed k, bn,kP:=n−1∣log⁡2P(X0k−1∣Xkn−1)∣→0P-a.s., and the same holds for bn,kPˉ under Pˉ.

3.1F1F3F4F5step 2.1algebra

For each integer m, use the fixed-k limits for k≤m and both measures to choose a deterministic N(m), increasing with m, such that P(sup⁡n≥N(m), k≤mbn,kP>1/m)+Pˉ(sup⁡n≥N(m), k≤mbn,kPˉ>1/m)<2−m. Let k(n)=max⁡{m:N(m)≤n, m≤n}, taking k(n)=1 for the finitely many initial n where the set is empty. Then k(n)→∞, k(n)/n→0, and [F5] implies that the prefix-to-suffix log-probability boundary divided by n tends to zero almost surely under both P and Pˉ. Under Pˉ, the finite conditional-probability identity gives −1nlog⁡2Pˉ(Xk(n)n−1)=−1nlog⁡2Pˉ(X0n−1)−bn,k(n)Pˉ almost surely for all sufficiently large n. By [F4] and the boundary convergence just proved, the right side tends to h. Its failure event is in the future-tail sigma-algebra: for every fixed j, all sufficiently large n have k(n)≥j, so the suffix terms depend only on coordinates from j onward. Thus [F3] gives −n−1log⁡2Pˉ(Xk(n)n−1)→hP-a.s.

4.1F3F5step 3.1algebra

For each n and ϵ>0, summing over suffix words w gives Pˉ ⁣(P(w)Pˉ(w)≥2nϵ)≤2−nϵ,P ⁣(Pˉ(w)P(w)≥2nϵ)≤2−nϵ, where the event is evaluated at the observed suffix w=Xk(n)n−1. For example, on the first event Pˉ(w)≤2−nϵP(w), and summing over its words proves the first inequality; the second is symmetric. For any fixed j, all sufficiently large n have k(n)≥j, so the forward-ratio limsup event is measurable with respect to coordinates from j onward. By [F5], the reverse-ratio violations occur only finitely often P-almost surely, while the forward-ratio violation limsup is a Pˉ-null tail event and hence is P-null by [F3]. Applying this for every positive rational ϵ yields n−1log⁡2P(Xk(n)n−1)Pˉ(Xk(n)n−1)→0P-a.s. Interpret a ratio with positive numerator and zero denominator as +∞. The observed P-suffix has positive P-probability almost surely for every n; the forward-ratio limsup argument also excludes zero Pˉ-suffix probabilities for all sufficiently large n, P-almost surely.

5.1A1F1F3F4step 3.1step 4.1algebra∎

Step 3.1 makes the normalized log probability of the P-prefix differ from that of its suffix by a quantity tending to zero; step 4.1 makes the P- and Pˉ-suffix log probabilities have the same normalized limit; and step 3.1 identifies the latter as −h. Therefore −1nlog⁡2P(X0n−1)⟶hP-almost surely. The argument includes h=0 and makes no claim of an exponential convergence rate. AC is used only through [A1], [F3].

TheoremStatement: Literature-sourcedProof: AI-generatedOpen item page →

Stationary-ergodic LZ77 phrase-length theorem

Statement

For a stationary ergodic finite-alphabet source with bit entropy rate h, define Rn=min⁡{j≥1:X−j−j+n−1=X0n−1} using LZ77 previous-match length and recurrence time. Then n−1log⁡2Rn→h in probability. If h>0, the inverse window length satisfies LW/log⁡2W→1/h in probability as integer W→∞.

Facts & Assumptions

Given: A stationary ergodic finite-alphabet source with bit entropy rate h, the recurrence distance Rn and inverse window phrase length LW of LZ77 previous-match length and recurrence time.

[F1]

Ergodic Shannon–McMillan–Breiman theorem: −n−1log⁡2P(X0n−1)→h almost surely.

[F2]

Kac return-time formula without invertibility: for a positive-measure set E in an ergodic probability-preserving system, the integral over E of its first positive return time is 1.

[F3]

Conditional block information rate given the infinite past: −n−1log⁡2P(X0n−1∣F−)→h almost surely, with finite-past conditional averages defining the displayed versions.

[F4]

LZ77 previous-match length and recurrence time: Rn=min⁡{j≥1:X−j−j+n−1=X0n−1} and LW=max⁡({0}∪{n≥1:Rn≤W}), with maximum +∞ if unbounded; the empty match is allowed.

Proof

Given: The source, entropy rate and definitions above.

1.1F1F2givenalgebra

Fix ε>0 and put Sn={w:P(X0n−1=w)≥2−n(h+ε/2)}. By [F1], the current block belongs to Sn with probability tending to one, and ∣Sn∣≤2n(h+ε/2) because its word probabilities sum to at most one. For w∈Sn, let Ew={X0n−1=w}. On Ew, Rn is the first positive return to Ew under the inverse shift, which is also measure-preserving and ergodic. Hence [F2] gives ∫EwRn dP=1. On Ew, 1{Rn>M}≤Rn/M for M=2n(h+ε), so integrating and using [F2] yields P(Ew∩{Rn>M})≤1/M=2−n(h+ε). Summing over Sn and adding the atypical-block probability proves P(Rn>2n(h+ε))→0.

1.2F3F4givenalgebra

Suppose h>0 and choose 0<ε<h. Fix a past x−=(…,x−2,x−1) and a current word w∈An. Write x−⌢w for their concatenation on coordinates i<0 and 0≤i<n; every coordinate used in a match of the current block at positive offset lies in this range. For any fixed offset j≥1, the match equations wi=(x−⌢w)−j+i determine at most one word w: for i<j the right side is fixed by the past, and for i≥j it equals the already determined letter wi−j. Therefore at most m words have Rn≤m for any positive integer m.

2.1F3step 1.2givenalgebra

Put mn=⌊2n(h−ε)⌋ and, for each past x−, let Gn(x−)={w:q∞,n(w∣x−)≤2−n(h−ε/2)}. By [F3], the actual block lies outside Gn(X−) with probability tending to zero. For fixed x−, let Cn(x−,mn) be the words whose recurrence offset is at most mn; step 1.2 gives ∣Cn(x−,mn)∣≤mn. Splitting its conditional mass into Gn(x−) and its complement gives P(Rn≤mn∣X−=x−)≤mn2−n(h−ε/2)+∑w∉Gn(x−)q∞,n(w∣x−). The first term is at most 2−nε/2, and the integral of the second term over pasts is exactly P(X0n−1∉Gn(X−)) by the conditional-law property in [F3]. Therefore P(Rn≤mn)→0, so the lower tail below h−ε vanishes.

3.1F1F2F4step 1.1step 2.1givenalgebra

If h=0, the lower tail below h−ε is impossible because Rn≥1. If h>0, step 2.1 handles 0<ε<h, while larger lower-tail thresholds are also impossible. Together with step 1.1 this proves n−1log⁡2Rn→h in probability. Kac recurrence makes Rn finite almost surely for every n, after intersecting the countably many full-measure recurrence events.

4.1F4step 3.1algebra∎

For h>0 and all sufficiently large integer W, fix 0<δ<1/h and set n−(W)=⌊(1/h−δ)log⁡2W⌋, n+(W)=⌈(1/h+δ)log⁡2W⌉. Step 3.1 implies P(Rn−(W)≤W)→1 and P(Rn+(W)>W)→1: choose η>0 with (h+η)(1/h−δ)<1<(h−η)(1/h+δ) and apply convergence in probability at these indices. Since a match of length n+1 is also a match of length n, Rn≤Rn+1. Thus with probability tending to one, n−(W)≤LW<n+(W). Divide by log⁡2W and let δ↓0 to obtain LW/log⁡2W→1/h in probability.

CorollaryStatement: AI-adaptedProof: AI-generatedprecheck pendingOpen item page →

Fixed-rate lossless coding for AMS ergodic sources

Statement

Assume AC. For a finite-alphabet AMS source with ergodic stationary mean, fixed-rate lossless coding has vanishing block error above the stationary-mean entropy rate and success probability tending to zero below it.

Facts & Assumptions

Given: AC; a finite-alphabet AMS source with ergodic stationary mean and entropy rate h; and a target rate R≥0 with the fixed-length code convention of Fixed-length lossless block codes and error probability.

[A1]

The Axiom of Choice: AC is inherited only through the AMS information-AEP tail-domination prerequisite.

[F1]

Shannon–McMillan limit for finite-alphabet AMS ergodic sources: normalized self-information under the AMS block law converges almost surely, hence in probability, to h.

[F2]

AEP criterion for fixed-rate lossless coding: an information AEP gives the fixed-rate achievability and converse.

[F3]

Dominated convergence: bounded almost-surely convergent indicators converge in expectation.

Proof

Given: AC and the source and hypotheses above.

1.1A1F1F3givenalgebra

Almost-sure convergence in [F1] implies convergence in probability by [F3] applied to the bounded deviation indicators.

2.1F1F2step 1.1∎

Apply [F2]. Every rate R>h admits fixed-length codes with block error tending to zero, and for every R<h every fixed-length code sequence has success probability tending to zero. This conclusion concerns the AMS source law; no stationarity assumption on that law is added.

5 · Examples, counterexamples and false statements

None yet.

Sources