Documentation

LeanPool.DomainTheory.Neighborhood.Exercise624

Exercise 6.24 (Scott 1981, PRG-19, §6) — a double fixed point for a system #

of domain equations

EXERCISE 6.24. Show that there must exist domains satisfying DD + (D × E) and ED + E, by using a double fixed-point method. First decide what the underlying set of tokens should be, and then define D and E by simultaneous fixed points. (Syntactical domains as in 6.23 may very well require several simultaneous equations.)

This is the simultaneous analogue of Exercise 6.20/6.21: there the conclusion was a single Γ with Γ = tok(T({Γ})), so that {Γ} ◁ T({Γ}) and Theorem 6.14 applies; here we produce a pair (Γ_D, Γ_E) of token sets that solve the two coupled token equations simultaneously, so that the two singleton systems sit as subsystems of the two right-hand sides at once — exactly the joint hypothesis the simultaneous form of Theorem 6.14 needs.

Deciding the tokens #

Both D and E are taken to be -free neighbourhood systems over the single token type Str = {0,1}* (Scott's uniform category of Exercise 6.19). The two right-hand sides are built from the uniform sum + (ScottSys.sum) and product × (ScottSys.prod), whose master (token set) is in both cases the tagged union {Λ} ∪ 0·(…) ∪ 1·(…). Writing tok(𝒟) = 𝒟.master and {Γ} for the one-neighbourhood system singletonSys Γ, the two token recursions are

so fTok p q = gTok p (gTok p q) (the product D × E and the sum D + E have the same tagged master shape).

The double fixed point #

The pair map Φ(p, q) = (fTok p q, gTok p q) is iterated from the bottom pair ({Λ}, {Λ}) (pIter); its two component unions

Γ_D = ⋃ₙ (Φⁿ).₁, Γ_E = ⋃ₙ (Φⁿ).₂

solve fTok Γ_D Γ_E = Γ_D and gTok Γ_D Γ_E = Γ_E (fTok_GammaD_GammaE, gTok_GammaD_GammaE). Both fTok/gTok are fully additive (built from insert, embBit, ), and — crucially — every token of fTok/gTok references at most one of the two coordinates, so each membership is witnessed at a single finite stage (no directedness merge is needed). This is the elementary token-level continuity that makes the Kleene union a fixed point.

The conclusion ({Γ_D} ◁ D + (D×E) and {Γ_E} ◁ D + E) #

Setting D = {Γ_D}, E = {Γ_E}, the fixed-point equations say exactly that Γ_D (resp. Γ_E) is the master of D + (D×E) (resp. D + E), so the singleton systems are subsystems of the two right-hand sides — Dsol_subsystem, Esol_subsystem. These two facts together are the hypotheses of the simultaneous Theorem 6.14, which then yields the required isomorphisms DD + (D×E) and ED + E.

Everything is choice-free (#print axioms ⊆ {propext, Quot.sound}).

The two token recursions gTok and fTok #

gTok p q = tok((D + E)) for D = {p}, E = {q}: the tagged union {Λ} ∪ 0p ∪ 1q. It is also the master of the product {p} × {q} (sum and product share the master shape over {0,1}*).

Equations
Instances For

    fTok p q = tok((D + (D×E))) for D = {p}, E = {q}: {Λ} ∪ 0p ∪ 1(gTok p q), equivalently gTok p (gTok p q).

    Equations
    Instances For
      theorem Domain.Neighborhood.Exercise624.gTok_mono {p p' q q' : Set ExampleB.Str} (hp : p p') (hq : q q') :
      gTok p q gTok p' q'

      gTok is monotone in both arguments.

      theorem Domain.Neighborhood.Exercise624.fTok_mono {p p' q q' : Set ExampleB.Str} (hp : p p') (hq : q q') :
      fTok p q fTok p' q'

      fTok is monotone in both arguments.

      Token-level continuity over a chain: a membership reaches a single finite #

      stage

      theorem Domain.Neighborhood.Exercise624.mem_gTok_iUnion {a b : Set ExampleB.Str} {w : ExampleB.Str} (hw : w gTok (⋃ (n : ), a n) (⋃ (n : ), b n)) :
      ∃ (n : ), w gTok (a n) (b n)

      Additivity of gTok. Every token of gTok (⋃ₙ aₙ) (⋃ₙ bₙ) already lies in some gTok aₙ bₙ — each token references at most one coordinate.

      theorem Domain.Neighborhood.Exercise624.mem_fTok_iUnion {a b : Set ExampleB.Str} {w : ExampleB.Str} (hw : w fTok (⋃ (n : ), a n) (⋃ (n : ), b n)) :
      ∃ (n : ), w fTok (a n) (b n)

      Additivity of fTok. Every token of fTok (⋃ₙ aₙ) (⋃ₙ bₙ) already lies in some fTok aₙ bₙ. The nested true-branch (the product copy 0p inside 1(gTok p q)) still references at most one coordinate, so a single finite stage suffices.

      The simultaneous Kleene iteration Φⁿ({Λ}, {Λ}) #

      The pair iteration Φ(p, q) = (fTok p q, gTok p q) from the bottom pair ({Λ}, {Λ}).

      Equations
      Instances For

        The first component of the double fixed point, Γ_D = ⋃ₙ (Φⁿ).₁.

        Equations
        Instances For

          The second component of the double fixed point, Γ_E = ⋃ₙ (Φⁿ).₂.

          Equations
          Instances For

            Each stage sits inside the colimit Γ_D (choice-free; avoids Set.subset_iUnion).

            Each stage sits inside the colimit Γ_E (choice-free).

            The double fixed point #

            First equation of the double fixed point: fTok Γ_D Γ_E = Γ_D, i.e. tok(D + (D×E)) = Γ_D for D = {Γ_D}, E = {Γ_E}.

            Second equation of the double fixed point: gTok Γ_D Γ_E = Γ_E, i.e. tok(D + E) = Γ_E.

            theorem Domain.Neighborhood.Exercise624.exists_double_fixedPoint :
            ∃ (Γd : Set ExampleB.Str) (Γe : Set ExampleB.Str), [] Γd [] Γe fTok Γd Γe = Γd gTok Γd Γe = Γe

            The double fixed point (token level). There is a pair of token sets (Γ_D, Γ_E), both containing Λ, that solve the two coupled token equations tok(D + (D×E)) = Γ_D and tok(D + E) = Γ_E simultaneously.

            The two solution systems and the simultaneous subsystem facts #

            The first right-hand side D + (D × E).

            Equations
            Instances For

              The master (token set) of D + (D×E) is fTok Γ_D Γ_E — definitionally, the sum/product masters expand to the tagged-union shape gTok/fTok.

              The master (token set) of D + E is gTok Γ_D Γ_E.

              {Γ_D} ◁ D + (D × E). The singleton system D = {Γ_D} is a subsystem of D + (D×E): by the fixed point its only neighbourhood Γ_D is the master of D + (D×E).

              {Γ_E} ◁ D + E. The singleton system E = {Γ_E} is a subsystem of D + E: by the fixed point its only neighbourhood Γ_E is the master of D + E.

              Exercise 6.24 (object level). By the double fixed-point method there exist -free systems D, E over {0,1}* such that {D} ◁ D + (D×E) and {E} ◁ D + E simultaneously. These two facts are exactly the joint hypothesis of the simultaneous Theorem 6.14, which then yields the required isomorphisms DD + (D×E) and ED + E.