The areas / V21. Dynamics, ergodic theory and information theory
Mathlib.InformationTheory.Coding.PrefixFree
4 declarations. Mathlib docs · Source
def InformationTheory.IsPrefixFree E1 #
{α : Type u_1} → Set (List α) → Prop
A set of words is prefix-free if two words in the set cannot be distinct when one is a prefix of the other.
theorem InformationTheory.IsPrefixFree.anti E1 #
∀ {α : Type u_1} {S T : Set (List α)}, InformationTheory.IsPrefixFree S → T ⊆ S → InformationTheory.IsPrefixFree T
Any subset of a prefix-free set is prefix-free.
theorem InformationTheory.IsPrefixFree.isUniquelyDecodable E1 #
∀ {α : Type u_1} {S : Set (List α)}, InformationTheory.IsPrefixFree S → [] ∉ S → InformationTheory.IsUniquelyDecodable S
A prefix-free code not containing the empty word is uniquely decodable.
theorem InformationTheory.IsPrefixFree.isUniquelyDecodable_of_nontrivial E1 #
∀ {α : Type u_1} {S : Set (List α)},
InformationTheory.IsPrefixFree S → S.Nontrivial → InformationTheory.IsUniquelyDecodable S
A nontrivial prefix-free code is uniquely decodable.