Draft — mutable and not usable as a dependency; its citation marks the draft state.

Lax765601.AperiodicMealy

Aperiodic Mealy machines are exactly the compositions of flip-flops

concepts/Lax765601/AperiodicMealy.lean · lax-765601

proven

Loading review…

Sign in with ORCID

Community review

Flags

Each flag is tied to a public ORCID identity and explains why this concept may be incorrect.

No flags have been submitted.

    Community review

    Flag this concept

    State precisely what appears incorrect. This explanation will be public under your ORCID name.

    No source line selected.

    Concept map

    Proven claimDefinitionThis conceptRelated conceptA → B: B builds on A

    Evidence

    Each proof establishes this claim relative to its assumptions.

    In the paper

    Theorem

    A function computed by a Mealy machine is aperiodic if and only if it is computed by a composition of flip-flop Mealy machines (Theorem A.2.8 of Transducers). This answers the question what the class (Flip-flop)(\mathrm{Flip\text{-}flop})^* of compositions of one kind of prime is; for the other kind, (Reversible)(\mathrm{Reversible})^* is the class of reversible machines (Lemma A.2.6).

    The two implications are separate results, each with its own proof: AperiodicOfFlipFlopsAperiodicOfFlipFlops (a composition of flip-flops is aperiodic) and FlipFlopsOfAperiodicFlipFlopsOfAperiodic (an aperiodic Mealy function decomposes into flip-flops); this statement is their conjunction.

    Lean source view on GitHub

    1import Lax765601.PrimeMealyMachines
    2import Lax765601.Aperiodicity
    3
    4/-!
    5---
    6title: Aperiodic Mealy machines are exactly the compositions of flip-flops
    7type: theorem
    8---
    9A function computed by a Mealy machine is aperiodic if and only if it is
    10computed by a composition of flip-flop Mealy machines (Theorem A.2.8 of
    11*Transducers*). This answers the question what the class
    12(Flip-flop)(\mathrm{Flip\text{-}flop})^* of compositions of one kind of prime is; for the
    13other kind, (Reversible)(\mathrm{Reversible})^* is the class of reversible machines
    14(Lemma A.2.6).
    15
    16The two implications are separate results, each with its own proof:
    17`AperiodicOfFlipFlops` (a composition of flip-flops is aperiodic) and
    18`FlipFlopsOfAperiodic` (an aperiodic Mealy function decomposes into flip-flops);
    19this statement is their conjunction.
    20
    21# Formalization notes
    22
    23The theorem in the book ends with the sentence "moreover, this property can be
    24decided, given a Mealy machine that computes ff". That sentence is *not*
    25formalised: the characterisation the book's decision procedure rests on, Lemma
    26A.2.11, is, but the enumeration of the state transformations arising from input
    27strings that turns it into an algorithm is not written down. Both alphabets are
    28assumed finite.
    29-/
    30
    31namespace Lax765601.AperiodicMealy
    32
    33open Lax765601.MealyMachine Lax765601.CompositionClosure Lax765601.PrimeMealyMachines Lax765601.Aperiodicity
    34
    35/-- A function computed by a Mealy machine is aperiodic if and only if it is a
    36composition of flip-flop Mealy machines. -/
    37axiom aperiodic_iff_compClosure_flipFlop {A B : Type} [Finite A] [Finite B]
    38 {f : List A → List B} (hf : IsMealy f) :
    39 Aperiodic f ↔ CompClosure FlipFlopFam A B f
    40
    41end Lax765601.AperiodicMealy
    42
    Show Proof

    Formalization notes

    The theorem in the book ends with the sentence "moreover, this property can be decided, given a Mealy machine that computes ff". That sentence is not formalised: the characterisation the book's decision procedure rests on, Lemma A.2.11, is, but the enumeration of the state transformations arising from input strings that turns it into an algorithm is not written down. Both alphabets are assumed finite.

    Used by

    none

    From Mathlib

    none

    Community review

    Discussion

    Ask a question or add context. Endorsements and structured flags are kept in the review panel above; your ORCID profile must share a public name.

    0 comments

    Loading discussion…