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.
Stationary Ergodic Sources and Universal Coding
1 · Prerequisites
- Absolute and Conditional Convergence; Rearrangement; Products
- Areas of Elementary Plane Figures
- Binary Operations, Monoids, Groups and Subgroups
- Compactness
- Compactness in Metric Spaces
- Completeness, Completion, and Uniform Continuity
- Complex Lp Spaces and Test-Function Conventions
- Conditional Expectation
- Construction of the Natural Numbers
- Construction of the Real Numbers via Cauchy Sequences
- Construction of the Real Numbers via Dedekind Cuts
- Continuity, IVT, EVT, and Uniform Continuity
- Cosets, Index and Lagrange's Theorem
- Countability and Uncountability
- Decidable, Recognizable, and Enumerable Languages
- Density Separability and Convolution in Lᵖ
- Divisibility, Euclidean Domains, Principal Ideal Domains and Unique Factorisation
- Filters and Ultrafilters
- Finite Counting, Factorials and Binomial Coefficients
- Finite Probability Spaces and Random Variables
- Formal Languages, Encodings, and Decision Problems
- Foundations of the Real Numbers for Analysis
- Fubini and Change of Variables
- Ideals, Quotient Rings and the Isomorphism Theorems for Rings
- Kolmogorov Complexity and Algorithmic Randomness
- Lebesgue Measure on Euclidean Space
- Limits of Real Functions
- limsup, liminf, and Subsequential Limits
- Linear Independence, Bases and Dimension
- Linear Recurrences and Rational Generating Functions
- Linear Transformations, Rank-Nullity and Quotient Spaces
- Measurable Functions and Simple Approximation
- Measure Preserving Transformations and Poincare Recurrence
- Measure-Preserving Systems and Mixing Criteria
- Measures and Their Basic Properties
- Metric Spaces
- Mixed Partials, Taylor Formulae, and Extrema
- Modes of Convergence Egorov and Lusin
- Monotone Functions, Discontinuities, and Continuity Sets
- Monotone Sequences, Bolzano-Weierstrass, and Cauchy Completeness
- Normal Subgroups and Quotient Groups
- Order, Zorn's Lemma, and the Axiom of Choice
- Outer Measure and the Caratheodory Extension Theorem
- Pointwise Extended-Real Function Products
- Polynomial Rings, the Division Algorithm and Roots
- Power Series and Real-Analytic Functions
- Probability Spaces Random Variables and Expectation
- Properties of the Integral and the Working FTC
- Quantum Communication and Fingerprinting
- Relations, Functions, and Quotients
- Rings, Subrings, Integral Domains and Fields
- Rⁿ as a Normed Space; Vector-Valued Functions
- Roots, Rational Powers, and Classical Inequalities
- Sequences and Limits
- Sequences and Series of Functions; Uniform Convergence
- Series: Convergence and the Nonnegative Tests
- Sigma Algebras and Borel Sets
- Signed and Complex Measures Hahn and Jordan
- Simple Field Extensions and the Construction of the Complex Numbers
- Strong Laws of Large Numbers
- Subspaces, Products, and Quotients
- Suprema and Infima
- The Derivative and the Mean Value Theorems
- The Ergodic Theorems of von Neumann and Birkhoff
- The Exponential Function
- The Integral Logarithm and the Equivalence of Its Characterisations
- The Lebesgue Integral and the Convergence Theorems
- The Logarithm and General Powers
- The Lᵖ Spaces Holder Minkowski and Riesz Fischer
- The Radon Nikodym Theorem and Lebesgue Decomposition
- The Riemann Integral in Rᵐ and Jordan Content
- The Riemann Integral: Definition and Integrability
- The Topology of Euclidean Space
- The Total Derivative in ℝᵐ → ℝⁿ
- The ZFC Axioms and the Basic Set Constructions
- Topological Spaces and Continuity
- Topology of ℝ
- Triangularisation, Generalised Eigenspaces and Jordan Canonical Form
- Turing Machines, Configurations, and Computation
- Vector Spaces, Linear Subspaces, Span and Direct Sums
2 · Summary
This page uses two-sided finite-alphabet path laws and the left shift for stationary sources, with the convention . 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 ; equality and convergence are not asserted. The LZ77 previous-match theorem proves in probability and, for , 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
Finite-alphabet stationary source
Definition
Consider a finite nonempty alphabet , a probability measure on , and the left shift .
The shift is measurable on the product sigma-algebra. Call stationary when it is measure preserving under this shift, precisely the condition in Measure-preserving transformations and systems.
For a stationary , call the source ergodic when each event satisfying has ; by Ergodicity relative to an invariant measure this is exactly ergodicity of the probability system.
Facts & Assumptions
Given: A finite nonempty alphabet , a probability measure on , and the left shift .
Measure-preserving transformations and systems: preserves exactly when for each measurable event .
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].
A basic product cylinder restricts only finitely many coordinates. Its inverse image under 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, is measurable on that sigma-algebra. Call stationary when it is measure preserving under this measurable shift, precisely the condition in [F1].
For a stationary , call the source ergodic when each event satisfying has ; by [F2] this is exactly ergodicity of the probability system.
Finite-block information and entropy in bits
Definition
Consider a finite alphabet and a random block with law on .
Define for . The denominator is positive because , is strictly increasing, and 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 , define its information in bits by ; values on zero-probability blocks may be set to because they are never sampled.
Define block entropy in bits by Finite summation and Finite distributions, entropy, divergence, and stochastic matrices show this equals . Thus the library's entropy interface stays in nats while this page's information and coding rates use bits. For any probability law on a finite set, put , and write for a finite-valued random variable . For finite-valued , also define conditional entropy by ; zero-probability conditioning values are omitted.
Facts & Assumptions
Given: A finite alphabet and a random block with law on .
Finite distributions, entropy, divergence, and stochastic matrices: the existing finite entropy is nats, with .
The natural logarithm as the inverse of the exponential function and Order, continuity, range, and the product, quotient, and reciprocal laws for the natural logarithm: is the natural logarithm, is strictly increasing, and .
Proof
Given: The finite law and [F1]–[F2].
Define for . The denominator is positive because , is strictly increasing, and by [F2]. For every positive-probability block , define its information in bits by ; values on zero-probability blocks may be set to because they are never sampled.
Define block entropy in bits by Finite summation and [F1] show this equals . Thus the library's entropy interface stays in nats while this page's information and coding rates use bits. For any probability law on a finite set, put , and write for a finite-valued random variable . For finite-valued , also define conditional entropy by ; zero-probability conditioning values are omitted.
Binary prefix codes on finite supports
Definition
Let be a finite nonempty message set. A binary prefix code on is an injective assignment such that no assigned string is a proper initial segment of another assigned string. Write for its codeword lengths. For a probability vector on , its expected length is
The empty string is permitted only when 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
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.
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.
Triangular averages of finite-past information converge to the infinite-past average
Statement
If nonnegative integrable-envelope functions converge -almost everywhere to , proves the triangular averages of tend to zero -almost everywhere and in on a finite measure-preserving system.
Facts & Assumptions
Given: A finite-measure-preserving system , with , and finite-valued measurable functions with -almost everywhere and .
Birkhoff pointwise ergodic theorem: time averages of an integrable function in a measure-preserving system converge almost surely to an integrable limit.
Ergodic averages converge in Lp on finite-measure spaces: on a finite-measure space, the time averages converge in to their Birkhoff limit.
Measure-preserving transformations and systems: , so every preserves .
Dominated convergence: pointwise convergence under an integrable envelope implies convergence of integrals.
Integral invariance under measure-preserving maps: if preserves and is measurable, then , including infinite values.
The Lebesgue integral is linear on : the integral is linear on .
Proof
Given: The hypotheses and [F1]–[F7].
For each , put . Then -almost everywhere and almost everywhere, since as a pointwise limit. Dominated convergence [F4] gives .
Since almost everywhere and , [F4] gives . By [F3, F5], , so linearity [F7] makes the integral of the absolute triangular error by Cesaro averaging. Thus the error tends to zero in .
Fix . For , . Hence for , the average of is bounded by the first terms divided by , plus . The first part tends to zero almost everywhere. By [F1], the second part converges almost everywhere to the Birkhoff limit ; by [F2], the averages converge to in . By [F3, F5, F7], every average has integral . Thus [F6] and the convergence give . Therefore and .
Apply step 2.1 to every integer on the intersection of the resulting countably many full-measure sets. The limsup of the left side is at most for each . Since decreases pointwise, the averages and their limits decrease almost everywhere. They are nonnegative and bounded by the integrable ; dominated convergence [F4] gives . Thus almost everywhere, and the limsup is zero. Therefore almost everywhere.
By [F1]–[F2], the Birkhoff averages of converge almost everywhere and in 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 , respectively. Hence both modes of convergence hold with the same limit.
Finite KL nonnegativity for subprobability references
Statement
Proves for and, for finite probability weights and positive-on-support reference weights with , proves by an explicit finite argument without choice.
Facts & Assumptions
Given: A finite probability vector and nonnegative reference weights with whenever and .
The integral logarithm for : , with oriented limits.
If on and both are integrable then ; and : if integrable functions obey a pointwise order on an interval with increasing endpoints, their integrals obey the same order.
The natural logarithm as the inverse of the exponential function: is the natural logarithm, the inverse of .
Order, continuity, range, and the product, quotient, and reciprocal laws for the natural logarithm: is strictly increasing and .
The integral with oriented limits: and : reversing the integration endpoints changes the sign.
Proof
Given: The finite weights and hypotheses above.
The integral logarithm is the natural logarithm by [F3] and [F5]. If , then on , so [F2]–[F4] give . If , then on , so ; [F3] and [F7] give . At , [F6] gives equality. Therefore for all .
Apply step 1.1 to for every with . Then Dividing by 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.
Finite-block LZ78 incremental prefix code
Definition
Input: A finite alphabet of size , an integer , a word (with denoting the empty word when ), and a terminator not in . Fix an injective -bit symbol field for . 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.
-
Start with dictionary and unread text . While text remains, let be the longest dictionary word prefixing the unread text, let be its dictionary index, and let be the next symbol. Output the record and remove the prefix from the unread text. If , append as the next dictionary entry; if , stop without inserting the terminal phrase.
-
Serialize each parent index by the Elias-delta code of . Put and . Emit zeros, then the -bit binary expansion of , then the final bits of the -bit binary expansion of . Append the fixed-width symbol field for . Concatenate these records in parser order, including the final marker record.
-
To decode an encoded block, start with dictionary . Count the leading zeros before the first of an index header as and set . Read the following bits; together with that first , these are the -bit binary expansion of . Read the next bits and prepend to recover ; put . Read the next bits as , and emit . Append that phrase to the dictionary when , then read the next record. At the first , 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 ↗.
Asymptotically mean stationary sources
Definition
Consider a measurable alphabet , a probability law on with its product sigma-algebra, and the measurable left shift .
The law is asymptotically mean stationary (AMS) when for every measurable event the limit exists and the resulting set function is a probability measure.
The resulting law is called the stationary mean when it is invariant under , in the sense of Measure-preserving transformations and systems. If is strictly shift invariant, then each summand ; hence . Tail events are handled by the separate domination lemma, not by this invariant-event identity.
Call the AMS source ergodic when its stationary mean 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 itself is stationary. For finite discrete alphabets these conventions agree with Finite-alphabet stationary source.
Facts & Assumptions
Given: A measurable alphabet , a law on its two-sided product space, and the left shift .
Measure-preserving transformations and systems: a probability law is invariant under a measurable shift exactly when for every measurable event .
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.
Inverse images of product cylinders under are product cylinders; since these generate the product sigma-algebra, is measurable. The law is asymptotically mean stationary (AMS) when for every measurable event the limit exists and the resulting set function is a probability measure.
For each measurable , the Ces`aro averages for and differ by The numerator has absolute value at most , so its quotient tends to zero. Taking limits, which exist by step 1.1 for both events, gives . Thus the Ces`aro limit is stationary in the sense of [F1].
The resulting law is called the stationary mean when it is stationary in the sense of [F1]. If is strictly shift invariant, then each summand ; hence . Tail events are handled by the separate domination lemma, not by this invariant-event identity.
Call the AMS source ergodic when its stationary mean is ergodic as a measure-preserving system under the same shift. This is a property of the mean, not a claim that itself is stationary.
Fixed-length lossless block codes and error probability
Definition
Consider a finite nonempty alphabet , a positive integer , a probability law on , and a rate in bits per symbol. A rate- fixed-length block code consists of a nonempty message set , an encoder , and a decoder . Thus and every message is a binary word of the same length.
The code is lossless when for every ; equivalently, is injective and is its inverse on the image. For a code with block error, define its success set by and its error probability by . The encoder restricted to is injective, so .
Facts & Assumptions
Given: A finite nonempty alphabet , a positive integer , a probability law on , and a rate .
Finite-alphabet stationary source: the source alphabet is finite.
Proof
Given: The finite block domain, rate- message set, and encoder and decoder maps in the Definition.
If for every , then is injective: implies . Conversely, if 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.
If and , then . Thus restricted to is injective, and the finite set has cardinality at most . Its error probability is by definition.
Finite-state compressibility of an individual sequence
Definition
Consider a finite alphabet and a one-sided infinite sequence .
An information-lossless -state encoder consists of a finite state set , an initial state, an update map , and an output map . It is information-lossless when for each initial state the map from finite input words to (concatenated output, final state) is injective.
Let be its concatenated output length and set , over information-lossless encoders with at most states. Define finite-state compressibility . The infima are nonincreasing in and bounded below by zero, so the limit in the equivalent notation exists.
Facts & Assumptions
Given: A finite alphabet and a one-sided infinite sequence .
Finite-alphabet stationary source: the source alphabet is a finite nonempty set.
Proof
Given: The finite-state coding convention in the statement.
An information-lossless -state encoder consists of a finite state set , an initial state, an update map , and an output map . It is information-lossless when for each initial state the map from finite input words to (concatenated output, final state) is injective.
The encoder class is nonempty: let and choose distinct -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 be an encoder's concatenated output length and set , over information-lossless encoders with at most states. Define finite-state compressibility . The infima are nonincreasing in and bounded below by zero, so the limit in the equivalent notation exists.
Information rate of a general finite-alphabet process
Definition
Consider a finite alphabet and a process law on ; is as in Finite-block information and entropy in bits.
Define the upper information rate and, when the limsup and liminf agree, the information rate . This definition does not assume stationarity.
Since has at most values, ; consequently the upper information rate is defined and lies in , and whenever the information-rate limit exists it lies in the same interval.
Facts & Assumptions
Given: A finite alphabet and a process law on ; is as in Finite-block information and entropy in bits.
Finite-block information and entropy in bits: is the Shannon entropy of the length- block law.
Finite KL nonnegativity for subprobability references: for a finite probability law and a positive reference probability law , .
Proof
Given: The process and finite-block entropy [F1].
Define the upper information rate and, when the limsup and liminf agree, the information rate . This definition does not assume stationarity.
Every positive block probability is at most one, so the finite-sum formula in [F1] gives . Let and compare the block law with the uniform law on the nonempty finite set . By [F2], Hence . Consequently the upper information rate is defined and lies in , and whenever the information-rate limit exists it lies in the same interval.
LZ77 previous-match length and recurrence time
Definition
Consider a finite alphabet and a two-sided sequence .
For positive integers , define the backward recurrence time of the current length- block by with 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 by where the maximum is interpreted as when the set is unbounded. The empty match of length zero is always allowed. For a periodic sequence, can be infinite; the recurrence-time theorem will only be used to infer the logarithmic inverse relation in probability when .
Facts & Assumptions
Given: A finite alphabet and a two-sided sequence .
Finite-alphabet stationary source: the source coordinates are indexed over and shifted by .
Proof
Given: The sequence and positive integers .
Define the backward recurrence time of the current length- block by with 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 by with maximum when the set is unbounded. The set is nonempty because it contains ; if a length- block matches at offset , 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.
For a periodic sequence, can be infinite; the recurrence-time theorem will only be used to infer the logarithmic inverse relation in probability when .
Finite-past information densities
Definition
Consider a stationary finite-alphabet source with law and alphabet .
For , let , with trivial. For each , define by averaging over the finite atoms of , and put on the event , with arbitrary value on its null complement.
The selected probability is positive almost surely: on each atom with , implies . Thus 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 with law and alphabet .
Finite-alphabet stationary source: the shift on preserves . [F2] Finite-block information and entropy in bits: for , ; the information of a positive-probability block is its negative bit logarithm.
Proof
Given: The source and conventions [F1]–[F2].
For , let , with trivial. For each , define by averaging over the finite atoms of , and put on the event , with arbitrary value on its null complement.
The selected probability is positive almost surely: on each atom with , implies . Thus is finite almost surely; [F1] identifies the same distributions after shifting any finite window.
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 and a binary prefix code with lengths on its positive support, describing one known source block.
Binary prefix codes on finite supports: the codewords are prefix-free.
Kraft inequality and effective prefix-code allocation: binary prefix-free code lengths satisfy ; conversely any finite computable list of positive lengths with Kraft sum at most one has a prefix-free allocation.
Finite KL nonnegativity for subprobability references: for probability weights and reference weights positive on their support with , the bit-log sum is nonnegative, without choice.
Proof
Given: The source and code in the statement.
Put on the positive support. By [F3], , so [F4] gives . Thus every such code has expected length at least . 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.
Assume now that the support has at least two points. Then every positive , so is a positive integer. It satisfies , so the finite binary Kraft criterion gives a prefix code. Also , hence its expected length is less than .
For singleton support step 1.1 gives . 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 . Empty support cannot occur for a probability vector.
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 .
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.
Finite KL nonnegativity for subprobability references: finite KL is nonnegative against a subprobability reference, and division by gives nonnegative bit divergence without an axiom of choice.
Proof
Given: The variables and entropy convention [F1].
On every positive-probability block, factor its probability into successive conditional probabilities by repeated use of . Taking and averaging over the finite support yields The term is .
For finite random variables , the same factorization gives . Terms with contribute zero, so no conditional law on a null event affects the identity.
For finite , fix any with . The conditional mutual information at that value is 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 gives .
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 on , entropy-rate candidate , a target rate , and normalized self-information from Finite-block information and entropy in bits. Assume in probability.
Finite-block information and entropy in bits: on positive-probability blocks.
Fixed-length lossless block codes and error probability: a rate- code has message set , encoder , decoder , and injective on its success set.
Proof
Given: The AEP convergence and finite-block coding convention [F1]–[F2].
If , then the nonnegative variable stays at distance at least from , contradicting convergence in probability; hence . Let and choose with . Define . On , each word has probability at least , so . The AEP gives .
For all sufficiently large , , since . Fix an enumeration of the finite alphabet once, and let be its first symbol. For each such , order lexicographically, take in lexicographic order, and map the th typical block to the th binary word. Define by this assignment on and by otherwise. Define to return each typical block on its assigned message and on all remaining messages. This is a rate- code in the sense of [F2], and every block in is decoded correctly. Its error is at most . For the finitely many earlier , take constant at the all-zero message and constant at .
Let and choose with . For any rate- code, its success set has at most words by [F2]. Split it according to whether . The probability of successful words in that part is at most , while the other part has total probability tending to zero by the AEP. Thus success probability tends to zero. At neither conclusion is asserted.
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 over a finite alphabet , any parsing into distinct nonempty phrases, and a fixed context . The empty word may have the empty parsing. In the LZ78 specialization, include the terminator in . An order- Markov kernel consists of probability rows on for every ; denotes the product of its successive row probabilities while reading from context and updating the context with each symbol.
Losslessness and prefix property of the explicit LZ78 code: ordinary complete LZ78 phrases are distinct, and the terminal phrase contains the unique marker.
Finite-block information and entropy in bits: finite words have ordinary finite-alphabet probability laws.
Proof
Given: The distinct parsing, order- kernel and fixed initial context.
For each phrase start , let be its preceding context, using for the initial boundary; write . For each pair let count phrases of that length and context. Markov factorization gives .
Group the logarithm by with ; groups of count zero contribute zero. Concavity of gives 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 .
Summing all groups and negating yields the Ziv inequality 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.
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 on a measurable space , a measurable map , and an AMS stationary mean as in Asymptotically mean stationary sources.
Asymptotically mean stationary sources: for every measurable , and is stationary.
Fatou's lemma: for nonnegative measurable functions , .
Proof
Given: The AMS probability system and [F1]–[F2].
If is strictly invariant, then for every , so [F1] gives . Thus the two laws agree on strictly invariant events.
Fix measurable with and set . Stationarity gives for each , hence by countable subadditivity. Also because removing the first term of a limsup does not change it. Step 1.1 yields .
Apply [F2] to . Since and by step 2.1, Fatou gives Thus , and nonnegativity implies . This is asymptotic domination of by its stationary mean.
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 .
Finite-block LZ78 incremental prefix code: each record is (parent dictionary index, next symbol); the final record contains the unique terminator .
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].
Every dictionary entry is an ordinary word over . 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 records, at a final marker record. If an ordinary phrase were already in the dictionary, it would be a longer dictionary prefix than the selected , contradicting the longest-prefix rule. Thus ordinary inserted phrases are distinct; the terminal phrase contains and is distinct from them.
For a parent index , put , and . The Elias-gamma code of consists of zeros followed by the -bit binary expansion of . Its first reveals , after which exactly more bits complete . Append the final bits of the binary expansion of to form its Elias-delta code; the decoder restores the leading of and then returns . 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 the codes are respectively , , and , so the case has an empty suffix but still a nonempty header. Appending a fixed-width -bit symbol field gives an unambiguously delimited nonempty record.
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.
The exact index length is . At phrase number , the parent satisfies , hence and . Since , its length is at most . Thus, writing , the output records, including the final marker record, have total bit length at most . This is , with the same bound valid for every small index including . The final record is encoded and counted even though its phrase is not inserted into the dictionary.
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 and .
Finite-alphabet stationary source: every shifted finite block has the same law as the original block.
Finite-block information and entropy in bits: is the Shannon entropy of the length- block.
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.
Information rate of a general finite-alphabet process: for a finite-alphabet process, .
Proof
Given: The source and [F1]–[F3].
By the chain rule, . The inequality follows because conditioning cannot increase entropy, and stationarity makes . Thus is subadditive.
Fix and write with . Repeated subadditivity gives , where and the finitely many are bounded by . Hence . Since , taking the infimum over proves the limit exists and equals .
For each , put , with for the empty past. By the conditioning monotonicity in [F3], is nonincreasing; it is bounded below by zero, so it has a limit . The chain rule gives By stationarity [F1], . Therefore by Ces`aro convergence. Comparing with the limit from step 2.1 yields , the limit of finite-past conditional entropies. By [F4], is finite and lies in , including deterministic sources with .
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 and measurable map whose stationary mean asymptotically dominates ; and the future-tail sigma-algebra for the coordinate process.
The Axiom of Choice: AC is used only for the countable family of Lebesgue decompositions and tail preimages below.
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.
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.
Asymptotically mean stationary sources: the stationary mean is invariant under .
Proof
Given: AC, an AMS law with stationary mean , and with .
For each , define the probability measure . By [F2] and countable choice [A1], write , where . The singularity in [F2] and the carrier convention [F3] give a measurable with on which is concentrated.
Put . Then , so [F1] gives . For every measurable , Thus the absolutely continuous approximations have error tending to zero uniformly over .
Since , for every choose a measurable with . Stationarity [F4] gives , so . Step 2.1 then gives . Hence . The tail preimages form a countable family; no uncountable simultaneous version selection is made.
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 over a finite alphabet of size , and the block-reset LZ78 code of Finite-block LZ78 incremental prefix code.
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 .
Losslessness and prefix property of the explicit LZ78 code: the explicit code has phrase-index cost plus a fixed symbol cost.
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.
Finite KL nonnegativity for subprobability references: finite KL against any subprobability reference is nonnegative in bits, and for .
Proof
Given: The sequence, LZ78 parser and finite-state coding convention.
Parse into phrases. Let be the ordinary phrases inserted into the dictionary; they are distinct by [F1]. If the terminal phrase is , its source portion is an existing dictionary word of depth at most . For , at most distinct ordinary phrases have length at most , while longer phrases consume at least source symbols each. Thus and .
Fix an information-lossless encoder with at most states. For each of the ordinary phrases , record its starting state , output word , and ending state . The tuples are distinct: equality for two different phrase strings with the same initial state would contradict injectivity in [F3]. If is uniform on the phrases and has mean , then The two state entropies are at most , by [F4] applied to the uniform law on each state set. Conditional on , there are at most possible binary strings, so .
If , then . If , compare the finite-support law of with the geometric weights restricted to that support. The reference weights sum to at most one, so nonnegative relative entropy [F4] gives because for , as the derivative of is nonnegative. The same upper bound holds when . Thus . If , this error is ; if , the same lower bound is immediate. The output on these phrases is at most its total block output, so
By [F2], the LZ78 description length is at most , including the terminal record. Since , step 3.1 yields
The inequality holds for every fixed -state information-lossless encoder. Taking the infimum over such encoders and then over proves that the LZ78 limsup rate is at most the finite-state compressibility . This is the one-sided individual-sequence optimality claim; equality or convergence of the LZ78 rate is not asserted.
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 with alphabet , and the finite-past probabilities and information variables of Finite-past information densities.
Finite-alphabet stationary source: the shift preserves the path law.
Finite-past information densities: on finite atoms and almost surely.
Finite entropy chain rule and monotonicity under conditioning: block entropy is the sum of successive conditional entropies.
Entropy-rate limit for a stationary finite-alphabet source: converges to the entropy rate .
The monotone class generated by an algebra equals the sigma-algebra it generates: finite-past cylinder identities extend to the sigma-algebra they generate.
Dominated convergence: almost-sure convergence under an integrable envelope implies convergence of integrals.
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].
Choose the null-set versions allowed by [F2] to be zero where , so each is nonnegative without changing any almost-sure claim. For each , is a martingale in for , because the finite-atom conditional averages satisfy the tower identity when the partition is refined. It is bounded between zero and one.
For rationals , the buy-at-, sell-at- strategy applied to this bounded martingale has expected gain zero; each completed upcrossing earns at least , and an unfinished final holding loses at most one. Therefore the expected number of completed upcrossings by time is at most . 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 then converges to some .
For every finite-past cylinder , the tower identity gives for all . Since and almost surely, [F6] gives the same identity with . For fixed , the finite measures and 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 . Thus is a conditional probability of given the full past.
The event belongs to . The conditional-probability identity from step 3.1 gives Summing over the finite alphabet shows almost surely, so almost surely.
For and , let be the first with . On each event , the tower identity gives Summing over and then yields for . For each integer , so [F7] and the tail bound give . Since and almost surely, [F6] also gives .
By stationarity [F1] and the chain rule [F3], Cesàro convergence and step 5.1 give ; [F4] identifies this limit as . This also covers zero-probability transitions, which are never observed.
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- block entropy , and the infimum of expected lengths among binary prefix codes describing one known length- block on its positive-probability support.
Finite-block information and entropy in bits: is the entropy of the finite block law.
Entropy lower and Shannon upper bounds for finite prefix codes: for every finite source, bit.
Proof
Given: The source, code class and entropy conventions [F1]–[F3].
Apply [F2] to each finite block law: . 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.
Divide by and use [F3]. Since , both bounds converge to , so . No ergodicity is needed because the argument uses only stationary block entropies.
If the source is deterministic, then 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.
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 over , entropy rate , and from Finite-past information densities.
Convergence and integrable envelope for finite-past information: almost surely, , and .
Triangular averages of finite-past information converge to the infinite-past average: under the integrable envelope, and have the same almost-sure limit.
Birkhoff pointwise ergodic theorem: time averages of converge almost surely to an invariant integrable limit.
Ergodic averages converge in Lp on finite-measure spaces: those averages converge in on the probability space.
Proof
Given: The source and [F1]–[F4].
The chain rule for finite block probabilities gives, almost surely, The equality holds on positive-probability blocks; their complement has probability zero.
By [F3]–[F4], converges almost surely and in to an invariant random variable . By [F2] and step 1.1, the difference between and tends to zero almost surely and in . This proves both asserted modes of convergence.
The convergence [F4] implies ; the limit is therefore finite and has mean equal to the stationary entropy rate. It need not be constant without ergodicity.
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 on a finite nonempty alphabet, its bit entropy rate , 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 for this coding alphabet and .
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 output records its length is at most .
Distinct-phrase count and Ziv inequality: for a distinct parsing and any order- kernel , .
Convergence and integrable envelope for finite-past information: the finite-past conditional entropy tends to .
Expected lossless prefix-code rate for stationary sources: the optimal expected prefix-code rate tends to .
Finite KL nonnegativity for subprobability references: finite KL against any subprobability reference is nonnegative in bits, and for .
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.
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 , so the stated terminated algorithm is defined, including for an originally singleton source with . Let be the number of phrases in parsing over the augmented alphabet , and let count phrases of length and preceding -symbol context . The phrases are distinct. For , at most phrases have length at most , while longer phrases use at least symbols. Thus uniformly over input words.
Let be the empirical law of a uniformly selected phrase. Since phrase lengths sum to , , and has at most values. If , compare the finite-support law of with the geometric weights , , restricted to that finite support. The restricted weights have sum at most one, so nonnegative relative entropy [F5] gives because for (the derivative of is ). The case has . Comparing with the uniform law on its support and using [F5] gives ; [F6] gives . Since , is increasing on this range for all large , so for each fixed .
The explicit code length satisfies . Since combine [F2] with step 2.1. The Ziv inequality holds for every fixed initial context, so apply it pointwise with . The index redundancy and symbol fields are uniformly for fixed , giving
For the kernel in step 3.1 use the augmented alphabet and . Define a probability row by the finite conditional law of given on positive-probability contexts and by any fixed point mass on for zero-probability contexts. Set and ; after choose any stochastic row. Stationarity and the conditional-entropy definition give since . Thus [F3] and step 3.1 give after .
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 . Together with step 4.1 this proves convergence to . The proof uses stationarity but not ergodicity.
Conditional block information rate given the infinite past
Statement
For each , constructs the conditional law of 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 with bit entropy rate , and .
Convergence and integrable envelope for finite-past information, Proof steps 5.1–6.1: the finite-past one-symbol probabilities converge to ; the realized information is nonnegative, integrable, and has mean .
The multiplication rule and finite chain rule for conditional probability: a finite joint probability factors into successive conditional probabilities on positive-probability prefixes.
The monotone class generated by an algebra equals the sigma-algebra it generates: identities on the algebra of finite-past cylinders extend to .
Monotone convergence for the integral: integrals of increasing nonnegative measurable functions converge to the integral of their pointwise limit.
Dominated convergence: bounded almost-surely convergent functions on a probability space converge in integral when dominated by an integrable function.
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.
For , and each word , define on each positive-probability atom of as the conditional average of there; on null atoms use the uniform vector on . Refining the past partition shows that for fixed , is a martingale bounded in . For rational , hold one unit after the martingale first falls to at most , sell it when the martingale next reaches at least , 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 , and an unfinished holding loses at most one because the martingale stays in . Thus the expected completed upcrossing count through any horizon is at most . 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 .
For each , the limits are nonnegative and sum to one because there are finitely many words and every is a probability vector. They are -measurable. Every finite-past cylinder belongs to the conditioning sigma-algebra for all sufficiently large ; [F5], with majorant one on the probability space, then gives . For fixed , the finite measures and 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 . Thus is a conditional probability version of the block given the full past.
Fix a positive-probability atom of the -past partition. Applying [F2] to and its successive intersections with the realized symbol events factors into the one-symbol conditional probabilities on the refined atoms . By stationarity, the factor for is , because the past at the shifted point is exactly at the original point . Therefore, almost surely on the realized block, For fixed , each factor converges almost surely as to , since the convergence in [F1] holds almost surely and each preserves . The left side converges to by step 1.1. The realized one-symbol limits are positive almost surely by [F1] and stationarity, so
Apply [F6] to . By [F1] its integral is , so the right side of step 2.2 divided by converges almost surely to . This proves the asserted conditional block-information rate and uses no choice axiom.
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 .
Componentwise Shannon–McMillan–Breiman theorem: normalized block self-information converges almost surely to an invariant random variable of mean .
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].
By [F1], the normalized block information converges almost surely to an invariant with . Since the source is ergodic, [F2] makes a constant almost surely.
The expectation of a constant equals that constant, so almost surely. Therefore almost surely. For this says the normalized information tends to zero; no positive-rate assumption is used.
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 , and from Finite-past information densities.
The Axiom of Choice: AC is assumed only for the published finite-measure Birkhoff-limit identification used below.
Componentwise Shannon–McMillan–Breiman theorem: the block information limit is the Birkhoff limit of .
Finite-measure identification of the Birkhoff limit: under AC, the Birkhoff limit integrates like the function over every strict invariant event.
Conditional expectation given a sigma algebra: conditional expectation is characterized by measurability and equality of integrals on all events in the conditioning sigma-algebra.
Strict and mod-null invariant sigma-algebras: the strict invariant sigma-algebra consists of events satisfying .
Proof
Given: AC, the source, and the strict invariant sigma-algebra.
The function is integrable by [F1]. Apply [F2] to its Birkhoff limit on the probability-preserving shift: has an -measurable representative and for every .
These are exactly the defining tests in [F3] for . Hence 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.
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 , a target rate , and fixed-length binary block codes as in Fixed-length lossless block codes and error probability.
Ergodic Shannon–McMillan–Breiman theorem: almost surely, hence in probability.
AEP criterion for fixed-rate lossless coding: information convergence in probability gives vanishing error above and vanishing success below .
Dominated convergence: bounded almost-surely convergent indicators converge in expectation.
Proof
Given: The source, its entropy rate and coding convention.
Almost-sure convergence in [F1] implies convergence in probability: for each , 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.
Apply [F2] with this AEP limit. For every there are rate- codes with block error tending to zero; for every , every rate- code sequence has success probability tending to zero. At no boundary conclusion follows from the theorem.
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 of size ; an AMS law on with stationary mean ; and suppose is stationary ergodic with entropy rate .
The Axiom of Choice: AC is inherited only through the local tail-domination proof, which uses countably many Lebesgue decompositions.
Asymptotically mean stationary sources: is AMS with stationary mean .
A null future-tail event under the stationary mean is null under the AMS law: a -null future-tail event is also -null.
Ergodic Shannon–McMillan–Breiman theorem: under , normalized cylinder self-information converges almost surely to .
The first Borel-Cantelli lemma for measures: events with summable probabilities occur only finitely often almost surely.
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.
Dominated convergence: bounded almost-surely convergent functions on a probability space converge in integral.
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.
If , the source path is deterministic, every block has probability one, and , so the claim holds. Assume henceforth . Fix . For each prefix , the finite conditional probabilities form a bounded martingale as the conditioning sigma-algebras increase. For each rational in , the buy-at-, sell-at- strategy has expected gain zero; every completed upcrossing earns at least and the final unsold position loses at most one. Thus the expected upcrossing count through any horizon is at most . 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 implies converges almost surely.
For each finite future cylinder , the conditional-probability identity gives . As increases these conditional probabilities converge almost surely and lie in , so [F7] gives the same identity with . The finite future cylinders form an algebra generating . The finite measures and 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 is a version of the conditional probability of the prefix event given the full future. Therefore Since there are finitely many prefixes, the realized-prefix conditional probability converges to a positive value almost surely. Consequently, for fixed , and the same holds for under .
For each integer , use the fixed- limits for and both measures to choose a deterministic , increasing with , such that Let , taking for the finitely many initial where the set is empty. Then , , and [F5] implies that the prefix-to-suffix log-probability boundary divided by tends to zero almost surely under both and . Under , the finite conditional-probability identity gives almost surely for all sufficiently large . By [F4] and the boundary convergence just proved, the right side tends to . Its failure event is in the future-tail sigma-algebra: for every fixed , all sufficiently large have , so the suffix terms depend only on coordinates from onward. Thus [F3] gives
For each and , summing over suffix words gives where the event is evaluated at the observed suffix . For example, on the first event , and summing over its words proves the first inequality; the second is symmetric. For any fixed , all sufficiently large have , so the forward-ratio limsup event is measurable with respect to coordinates from onward. By [F5], the reverse-ratio violations occur only finitely often -almost surely, while the forward-ratio violation limsup is a -null tail event and hence is -null by [F3]. Applying this for every positive rational yields Interpret a ratio with positive numerator and zero denominator as . The observed -suffix has positive -probability almost surely for every ; the forward-ratio limsup argument also excludes zero -suffix probabilities for all sufficiently large , -almost surely.
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 -suffix log probabilities have the same normalized limit; and step 3.1 identifies the latter as . Therefore The argument includes and makes no claim of an exponential convergence rate. AC is used only through [A1], [F3].
Stationary-ergodic LZ77 phrase-length theorem
Statement
For a stationary ergodic finite-alphabet source with bit entropy rate , define using LZ77 previous-match length and recurrence time. Then in probability. If , the inverse window length satisfies in probability as integer .
Facts & Assumptions
Given: A stationary ergodic finite-alphabet source with bit entropy rate , the recurrence distance and inverse window phrase length of LZ77 previous-match length and recurrence time.
Ergodic Shannon–McMillan–Breiman theorem: almost surely.
Kac return-time formula without invertibility: for a positive-measure set in an ergodic probability-preserving system, the integral over of its first positive return time is .
Conditional block information rate given the infinite past: almost surely, with finite-past conditional averages defining the displayed versions.
LZ77 previous-match length and recurrence time: and , with maximum if unbounded; the empty match is allowed.
Proof
Given: The source, entropy rate and definitions above.
Fix and put . By [F1], the current block belongs to with probability tending to one, and because its word probabilities sum to at most one. For , let . On , is the first positive return to under the inverse shift, which is also measure-preserving and ergodic. Hence [F2] gives . On , for , so integrating and using [F2] yields . Summing over and adding the atypical-block probability proves .
Suppose and choose . Fix a past and a current word . Write for their concatenation on coordinates and ; every coordinate used in a match of the current block at positive offset lies in this range. For any fixed offset , the match equations determine at most one word : for the right side is fixed by the past, and for it equals the already determined letter . Therefore at most words have for any positive integer .
Put and, for each past , let . By [F3], the actual block lies outside with probability tending to zero. For fixed , let be the words whose recurrence offset is at most ; step 1.2 gives . Splitting its conditional mass into and its complement gives The first term is at most , and the integral of the second term over pasts is exactly by the conditional-law property in [F3]. Therefore , so the lower tail below vanishes.
If , the lower tail below is impossible because . If , step 2.1 handles , while larger lower-tail thresholds are also impossible. Together with step 1.1 this proves in probability. Kac recurrence makes finite almost surely for every , after intersecting the countably many full-measure recurrence events.
For and all sufficiently large integer , fix and set , . Step 3.1 implies and : choose with and apply convergence in probability at these indices. Since a match of length is also a match of length , . Thus with probability tending to one, . Divide by and let to obtain in probability.
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 ; and a target rate with the fixed-length code convention of Fixed-length lossless block codes and error probability.
The Axiom of Choice: AC is inherited only through the AMS information-AEP tail-domination prerequisite.
Shannon–McMillan limit for finite-alphabet AMS ergodic sources: normalized self-information under the AMS block law converges almost surely, hence in probability, to .
AEP criterion for fixed-rate lossless coding: an information AEP gives the fixed-rate achievability and converse.
Dominated convergence: bounded almost-surely convergent indicators converge in expectation.
Proof
Given: AC and the source and hypotheses above.
Almost-sure convergence in [F1] implies convergence in probability by [F3] applied to the bounded deviation indicators.
Apply [F2]. Every rate admits fixed-length codes with block error tending to zero, and for every 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
- Robert M. Gray, Entropy and Information Theory, corrected edition
- Robert M. Gray, Entropy and Information Theory, corrected author-hosted first edition
- Stanford EE376C, Lempel-Ziv Compression lecture notes
- Ioannis Kontoyiannis, Recurrence and Waiting Times in Stationary Processes and Their Applications in Data Compression, Stanford University dissertation
- Thomas M. Cover and Joy A. Thomas, Elements of Information Theory, 2nd ed.
- Robert M. Gray, Probability, Random Processes, and Ergodic Properties
- Satyadev Nandakumar, IIT Kanpur LZ78 lecture transcription (2014)
- Paul H. Algoet and Thomas M. Cover, “A Sandwich Proof of the Shannon–McMillan–Breiman Theorem,” Annals of Probability 16 (1988), 899–909