Langlib

Langlib.Classes.RecursivelyEnumerable.Examples.NonHalting

The non-halting language is not recursively enumerable #

This file proves nonHaltingUnaryLanguage_not_RE: the language of all non-halting Turing machines (nonHaltingUnaryLanguage, the complement of haltingUnaryLanguage) is not recursively enumerable.

The argument encodes each partial-recursive code c as the unary word codeUnaryWord c. If the non-halting language were RE, then grammar-membership search after this encoding would make fun c => ¬ (c.eval 0).Dom an REPred, contradicting Mathlib's ComputablePred.halting_problem_not_re.

@[reducible, inline]
Equations
Instances For

    The unary word whose length is the code number of a partial-recursive code.

    Equations
    Instances For

      Preimage of an RE unary language along codeUnaryWord is an REPred.

      The complement of the unary halting language is not RE.

      The unary non-halting language is not recursively enumerable.