Documentation

LeanPool.DomainTheory.Neighborhood.Definition72

Definition 7.2 (Scott 1981, PRG-19, Β§7) β€” computable maps and computable #

elements

Following Dana Scott, Lectures on a Mathematical Theory of Computation, PRG-19, Lecture VII, Computability in effectively given domains.

Definition 7.2. Given two recursively presented domains π’Ÿ = {Xβ‚™ ∣ n ∈ β„•} and β„° = {Yβ‚˜ ∣ m ∈ β„•}, an approximable mapping f : π’Ÿ β†’ β„° is said to be computable iff the relation Xβ‚™ f Yβ‚˜ is recursively enumerable in n and m.

Why r.e. (and not recursive)? Scott answers by degenerating π’Ÿ to the one-point domain {Ξ”}: then f is just a single element y = f({Ξ”}) ∈ |β„°|, and the condition reduces to the index set {m ∣ Yβ‚˜ ∈ y} being r.e. A finite element has a recursive index set, but an infinite element can only be approximated "a little at a time" β€” its approximations can be listed (r.e.) but membership need not be decidable. So 7.2 already incorporates the notion of a computable element (IsComputableElement).

We model IsComputableMap as REPredβ‚‚ (fun n m ↦ Xβ‚™ f Yβ‚˜) over the choice-free recursion theory of Recursive.lean (REPred = projection of a recursively decidable relation; see that file for why we roll our own and reject Mathlib's classical recursion theory).

Proposition 7.3 is then formalized in full:

Two further faithful facts:

Everything here is βŠ† {propext, Quot.sound} (choice-free): it is built only from the choice-free deciders of Definition 7.1 and the choice-free r.e. layer of Recursive.lean.

Definition 7.2 (Scott 1981, PRG-19) β€” computable map. Relative to computable presentations P of V and Q of W, an approximable map f : V β†’ W is computable iff its neighbourhood relation Xβ‚™ f Yβ‚˜, transported to the integer indices, is recursively enumerable.

Equations
Instances For

    Definition 7.2 (Scott 1981, PRG-19) β€” computable element. Specializing to f : πŸ™ β†’ W, the condition becomes: the index set {m ∣ Yβ‚˜ ∈ y} of the element y ∈ |W| is recursively enumerable. We take this as the definition of a computable element.

    Equations
    Instances For

      The identity map is computable (the identity half of Proposition 7.3). The relation Xβ‚™ I Xβ‚˜ is Xβ‚™ βŠ† Xβ‚˜ (incl_computable), which is recursively decidable, hence recursively enumerable.

      theorem Domain.Neighborhood.comp_isComputable {Ξ± : Type u_1} {Ξ² : Type u_2} {Ξ³ : Type u_3} {V : NeighborhoodSystem Ξ±} {W : NeighborhoodSystem Ξ²} {U : NeighborhoodSystem Ξ³} {P : ComputablePresentation V} {Q : ComputablePresentation W} {R : ComputablePresentation U} {f : ApproximableMap V W} {g : ApproximableMap W U} (hf : IsComputableMap P Q f) (hg : IsComputableMap Q R g) :

      Proposition 7.3 (Scott 1981, PRG-19) β€” composition of computable maps is computable. For X (g∘f) Z ↔ βˆƒ Y, X f Y ∧ Y g Z, surjectivity of the middle presentation Q lets the witness Y range over indices l (Y = Yβ‚—); the resulting βˆƒ l, Xβ‚™ f Yβ‚— ∧ Yβ‚— g Zβ‚– is recursively enumerable by reindexing (REPred.comp), conjunction (REPred.and), and existential projection (REPred.proj).

      Proposition 7.3 (consequence) (Scott 1981, PRG-19). "If f : π’Ÿ β†’ β„° is computable and x ∈ |π’Ÿ| is computable, then f(x) ∈ |β„°| is also computable." Here f(x) = {Yβ‚˜ ∣ βˆƒ Xβ‚™ ∈ x, Xβ‚™ f Yβ‚˜} (toElementMap); surjectivity of P lets the witness X range over indices n, and the resulting βˆƒ n, Xβ‚™ ∈ x ∧ Xβ‚™ f Yβ‚˜ is r.e. by REPred.and/REPred.proj.

      Every finite (principal) element is computable (Scott's remark after 7.2: "If y were finite, the set of indices would be recursive"). For the finite element ↑Xβ‚™, the index set {m ∣ Xβ‚™ βŠ† Xβ‚˜} is a recursive slice of incl_computable (fix the first index to n by the primitive-recursive reindex m ↦ ⟨n, m⟩), hence r.e.