Lecture 12: $PoL$, $PoLR$, $PoC$ categories

Lecture 12

Preorders \(S = (\underbrace{\vert S \vert}_{\text{set}}, \underbrace{≤_S}_{\text{refl. trans. rel. on } \vert S \vert})\)

\[ℐ(S) = \lbrace u ⊆ \vert S \vert \; \mid \; ∀ a ∈ u, \, ∀ a' ∈ \vert S \vert \quad a' ≤_S a ⟹ a' ∈ u\rbrace\]
  • $(ℐ(S), ⊆)$: lattice
  • $C ⊆ ℐ(S)$
  • $\bigcup C ∈ ℐ(S)$

PoL:

  • Obj: preorders
  • Morphisms: linear maps that commute with lubs for all $C ⊆ ℐ(S)$ (so $f$ monotone)
\[\vert S ⊸ T \vert = \vert S \vert × \vert T \vert\] \[(a,b) ≤_{S ⊸ T} (a', b') \text{ if } a ≥_S a' \text{ and } b ≤_T b'\]

Th:

\[tr: \begin{cases} PoL(S, T) &⟶ ℐ(S ⊸ T) \\ f &⟼ \lbrace (a, b) ∈ \vert S \vert × \vert T \vert \; \mid \; b ∈ f(↓ a)\rbrace \end{cases}\\ \\ fun: \begin{cases} ℐ(S ⊸ T) &⟶ PoL(S, T) \\ u &⟼ \lbrace b ∈ \vert T \vert \; \mid \; ∃ a ∈ u; (a,b) ∈ t\rbrace \end{cases}\]

are such that:

\[tr \circ fun = id\\ fun \circ tr = id\]

And if $f, f’ ∈ PoL(S, T)$, then

\[tr(f) ⊆ tr(f') ⟺ ∀ u ∈ ℐ(S), f(u) ⊆ f'(u)\]

NB: it’s similar to stable functions that we have already seen

$PoLR$ is the cat

  • Obj: Preorders
  • $PolR(S, T) = ℐ(S ⊸ T)$

    • relational composition:

      \[s ∈ PolR(S, T) \quad t ∈ PolR(T, U)\\ ts = \lbrace (a,c) \; \mid \; ∃ b; (a, b)∈ s, (b,c) ∈ t \rbrace\\ fun(ts) = fun(t) \circ fun(s)\]
    • identity:

      \[id_S \; ≝ \; \lbrace (a, a') ∈ \vert S \vert × \vert S \vert \; \mid \; a' ≤_S a\rbrace\\ fun(id_S): ℐ(S) ⟶ ℐ(S) \text{ is the identity}\]

Fact: $fun$ and $tr$ define an isomorphism between $Pol$ and $PolR$

NB: in $PoL$, an iso $S ⟶ S’$ is a $f ∈ PoL(S, S’)$ which is a bijection.

$S ≅ S’$ and $S$ and $S’$ are quite different as preorders.

Ex: $1 ≅ \underbrace{(ℕ, ℕ × ℕ)}_{\; ≝ \; 1’}$

\[ℐ(1') = \lbrace ∅, ℕ\rbrace\\ ℐ(1) = \lbrace ∅, \lbrace A \rbrace\rbrace\]

A strong isomorphism from $S$ to $S’$ is a bijection

\[θ: \vert S \vert ⟶ \vert S' \vert\]

st \(a ≤_S a' ⟺ θ(a) ≤_S θ(a')\)

Then

\(\widehat θ = \lbrace (a, a') ∈ \vert S \vert × \vert S' \vert \; \mid \; a' ≤_S θ(a) \rbrace ∈ ℐ(S ⊸ S')\) and $fun(\widehat θ)$ is an iso $S ⟶ S’$ in $PoL$.

\[S ≃ S' \text{ strong isomorphism}\]

Notation: $s ∈ PoLR(S, T), \; u ∈ ℐ(S)$:

\[\underbrace{su}_{= \lbrace b ∈ \vert T \vert \; \mid \; ∃ a ∈ u; (a, b) ∈ s \rbrace} = fun(s)(u)\]

Tensor Product

\[S_1 ⊗ S_2 = (\vert S_1 \vert × \vert S_1 \vert, ≤_{S_1} × ≤_{S_2})\\ (a_1, a_2) ≤_{S_1 ⊗ S_2} (a'_1, a'_2) \qquad \text{ if } a_i ≤_{S_i} a'_i \quad i = 1, 2\] \[u_i ∈ ℐ(S_i) \quad \text{ for } i=1,2\] \[u_1 ⊗ u_2 \; ≝ \; u_1 × u_2 ∈ ℐ(S_1 ⊗ S_2)\]

Fact: if $t, t’ ∈ PolR(S_1 ⊗ S_2, T)$, then

\[t=t' ⟺ ∀ u_i ∈ ℐ(S_i), t(u_1 ⊗ u_2) = t'(u_1 ⊗ u_2)\]

Let $s_i ∈ PoLR(S_i, T_i)$ for $i=1, 2$.

\[\underbrace{s_1 ⊗ s_2}_{\; ≝ \; \lbrace((a_1, a_2), (b_1, b_2)) \; \mid \; (a_i, b_i) ∈ s_i \quad i=1, 2\rbrace} ∈ PoLR(S_1 ⊗ S_2, T_1 ⊗ T_2)\\\]

check that

\[s_1 ⊗ s_2 ∈ ℐ((S_1 ⊗ S_2) ⊸ (T_1 ⊗ T_2))\]
  • $∀ u_i ∈ S_i$:

    \[(s_1 ⊗ s_2)(u_1 ⊗ u_2) = (s_1 u_1) ⊗ (s_2 u_2)\]
  • $∀ t_i ∈ PoLR(T_i, U_i)$:

    \[(t_1 s_1) ⊗ (t_2 s_2) = (t_1 ⊗ t_2)(s_1 ⊗ s_2)\]

NB:

  • in $PoL$: $ℐ(S_1 ⊗ S_2) = ℐ(S_1) × ℐ(S_2)/\sim$, where $(∅, u_2) \sim (u_1, ∅)$

  • the analogy with linear algebra doesn’t go far:

    • we can’t do changes of basis
    • basis vectors are prime elements in order theory, whereas they have nothing special in linear algebra
\[⊗: PoLR^2 ⟶ PoLR \text{ is a functor}\]

(cf. picture)

Symmetric monoidal structure

$1 \; ≝ \; (\lbrace \ast\rbrace, =)$

\[\vert 1 ⊗ S \vert = \lbrace \ast\rbrace × \vert S \vert ≃ \vert S \vert \qquad \text{strong iso}\] \[1 ⊗ S ≃ S \qquad \text{ so } 1 ⊗ S \overset{λ}{≅} S\\ S ⊗ 1 ≃ S \qquad \text{ so } S ⊗ 1 \overset{ρ}{≅} S\\ (S_1 ⊗ S_2) ⊗ S_3 ≃ S_1 ⊗ (S_2 ⊗ S_3) \qquad \text{ so } (S_1 ⊗ S_2) ⊗ S_3 \overset{α}{≅} S_1 ⊗ (S_2 ⊗ S_3)\\ S_1 ⊗ S_2 ≃ S_2 ⊗ S_1 \qquad \text{ so } S_1 ⊗ S_2 \overset{σ}{≅} S_2 ⊗ S_1\]

All the required diagrams commute on the strong (left) side, and so the corresponding isos statisfy the required coherence properties.

⟹ $PoLR$ is a SMCC.

NB: If $f: ℐ(S_1) × ℐ(S_2) ⟶ ℐ(T)$ is bilinear, then we can define the bilinear trace:

\[tr_2(f) \; ≝ \; \lbrace (a_1, a_2, b) \; \mid \; b ∈ f(↓a_1, ↓a_2) \rbrace\]

$tr_2$ is a bij from $PoL_2(S_1, S_2; T)$ to $PoLR(S_1 ⊗ S_2, T)$

PoLR is closed

with $(S ⊸ T, ev)$, as object of linear morphism

\[ev ∈ PoLR((S ⊸ T) ⊗ S, T) \qquad ⊛ \\ ev \; ≝ \; \lbrace (((a, b), a'), b') ∈ ((\vert S \vert × \vert T \vert) × \vert S \vert) × \vert S \vert \; \mid \; b' ≤_T b \quad \text{ and } \quad a' ≥_S a\rbrace\]

Facts:

  1. $ev ∈ ℐ((S ⊸ T) ⊗ S ⊸ T)$ that is, $⊛$ holds
  2. $ev(t ⊗ u) = tu$

  3. If $s ∈ PoLR(U ⊗ S, T)$, then

    \[cur(s) \; ≝ \; \lbrace (a, (b, c)) \; \mid \; ((a, b), c) ∈ s\rbrace\]

    satisfies

    • $cur(s) ∈ PoLR(U, S ⊸ T)$
    • it satisfies the universal property of the exponential

If $w ∈ ℐ(U)$ and $u ∈ ℐ(S)$:

\[\underbrace{cur(s)}_{∈ ℐ(U ⊸ (S ⊸ T))} w u = \underbrace{s}_{∈ ℐ(U ⊗ S, T)} (w ⊗ u)\]

$\star$-autonomy

$⊥ = 1$

\[η_S: S ⟶ (S ⊸ ⊥) ⊸ ⊥\]

defined as

\[cur(e) \text{ where } e: S ⊗ (S ⊸ ⊥) \overset{σ}{⟶} (S ⊸ ⊥) ⊗ S \overset{ev}{⟶} ⊥\]

Fact:

\[η_S = \widehat θ\]

where

\[θ: S ≃ ((S ⊸ ⊥) ⊸ ⊥)\]

$S^{op}$: the preorder is reversed

\[S ⊸ ⊥ ≃ S^{op}\]

Indeed: $\vert S ⊸ ⊥ \vert = \vert S \vert × \lbrace \ast\rbrace$ where \((a, \ast) ≤_{S ⊸ ⊥} (a', \ast) ⟺ a' ≤_S a\)

Let $S^⊥ \; ≝ \; S^{op}$

Then

\[S_1 ⅋ S_2 = (S_1^⊥ ⊗ S_2^⊥)^⊥ = S_1 ⊗ S_2\]

Additives

$(S_i)_{i ∈ I}$

\[S = \&_{i ∈ I} S_i = (\bigcup\limits_{i ∈ I} \lbrace i\rbrace × \vert S_i \vert, ≤_S)\] \[(i, a) ≤_S (i', a') ⟺ i=i' \text{ and } a ≤_{S_i} a'\] \[ℐ(\&_{i ∈ I} S_i) ≅ \prod\limits_{ i ∈ I } ℐ(S_i)\]

Projections

\[pr_i ∈ PoLR(\&_{j ∈ I} S_j, S_i)\\ pr_i \; ≝ \; \lbrace ((i, a'), a) \; \mid \; a, a' ∈ \vert S_i \vert \qquad a ≤_{S_i} a'\rbrace\]

Fact:

\[fun(pr_i): \begin{cases} \prod\limits_{ j ∈ I } ℐ(S_j) &⟶ ℐ(S_i) \\ \vec{u} &⟼ u_i \end{cases}\]

If $(s_i)_{i ∈ I}$, where $s_i ∈ PoLR(T, S_i)$ for $i ∈ I$:

\[⟨s_i⟩_{i ∈ I} ∈ PoLR(T, \&_{j ∈ I} S_j)\\ ⟨s_i⟩_{i ∈ I} \; ≝ \; \lbrace (b, (i, a)) \; \mid \;(b, a) ∈ s_i\rbrace\]

it is the unique $t ∈ PoLR(T, \&_{j ∈ I} S_j)$ st for all $i ∈ I$:

\[\begin{xy} \xymatrix{ T \ar[r]^{ t } \ar[d]_{ s_i } & \&_{j ∈ I} S_j \\ S_i \ar@{<-}[ru]_{pr_i} & } \end{xy}\] \[fun(⟨s_i⟩_{i ∈ I}): \begin{cases} ℐ(T) &⟶ ℐ(\&_{j ∈ I} S_j) ≅ \prod\limits_{ j ∈ I } ℐ(S_j) \\ u &⟼ (s_i u)_{i ∈ I} \end{cases}\]

Terminal object: $⊤ = \&_{j ∈ ∅} S_j$

\[\vert T \vert = (∅, ∅) \text{ is the terminal object}\]

Sum

\[\bigoplus\limits_{i ∈ I} S_i = (\&_{i ∈ I} S_i^⊥)^⊥ = \&_{i ∈ I} S_i\]

Products and coproduct coincide. Same in linear algebra, but only for finite co/products.

Scott continuity

$f: ℐ(S) ⟶ ℐ(T)$ is Scott-continuous iff

  1. $f$ is monotone
  2. for all $D ⊆ ℐ(S)$ directed ($D ≠ ∅$ and $∀ u, u’ ∈ D, ∃ u’’ ∈ D; u, u’ ⊆ u’’$), one has:

    \[f(\bigcup D) = \bigcup\limits_{u ∈ D} f(u)\]
\[Tr(f) = \lbrace(u^0, b) \; \mid \; u^0 ⊆_{fin} \vert S \vert, b ∈ \vert T \vert, b ∈ f(↓ u^0)\rbrace\]

where

\[↓u^0 = \lbrace a ∈ \vert S \vert \; \mid \; ∃ a' ∈ u^0; a ≤_S a'\rbrace\]

NB: recall that we had, for linear functions:

\[tr(f) = \lbrace (a, b) \; \mid \; a ∈ \vert S \vert, b ∈ f(↓a)\rbrace ⟶ \text{ not the same definition!}\]

Fact: \(Tr(f) ∈ ℐ(!S ⊸ T)\)

where \(!S = (𝒫_fin(\vert S \vert), ≤_{!S})\)

and

\[u^0 ≤_{!S} u^1 ⟺ ↓ u^0 ⊆ ↓ u^1\]

that is:

\[∀ a ∈ u^0, ∃ a' ∈ u^1; a ≤_S a'\]

For instance: $∀ u^0 ∈ \vert !S \vert, ∅ ≤_{!S} u^0$

Example: $S = (\lbrace 1, 2\rbrace, ≤_S)$ where $1 <_S 2$

\(!S = (\lbrace ∅, \lbrace 1\rbrace, \lbrace 2\rbrace, \lbrace 1, 2\rbrace\rbrace)\) where

\[∅ ≤_{!S} \lbrace 1 \rbrace ≤_{!S} \lbrace 2 \rbrace ≤_{!S} \lbrace 1, 2 \rbrace ≤_{!S} \lbrace 2 \rbrace\]

Let $s ∈ ℐ(!S ⊸ T)$.

\[Fun(s): \begin{cases} ℐ(S) &⟶ 𝒫( \vert T \vert) \\ u &⟼ \lbrace b ∈ \vert T \vert \; \mid \; ∃ u^0; (u^0, b) ∈ s \text{ and } u^0 ⊆ u\rbrace \end{cases}\]

Fact: $Fun(s)(u) ∈ ℐ(T)$ for all $u ∈ ℐ(S)$. $Fun(s)$ is Scott-continuous.

Why? Because: if $D ⊆ ℐ(S)$ directed and $u^0 ⊆ \vert S \vert$ finite then

\[u^0 ⊆ \bigcup D ⟺ ∃ u ∈ D \quad u^0 ⊆ u\]

$PoC$: the cat of preorders and Scott-continous functions.

\[PoC(S, T) \overset{Tr}{⟶} PoLR(!S, T) = ℐ(!S ⊸ T)\\ PoLR(!S, T) = ℐ(!S ⊸ T) \overset{Fun}{⟶} PoC(S, T)\]

Fact: $Fun \circ Tr = id$ and $Tr \circ Fun = id$

\[Tr(f) ⊆ Tr(f') ⟺ ∀ u ∈ ℐ(S), \quad f(u) ⊆ f'(u)\]

Let $u ∈ ℐ(S)$. Define $u^! ∈ ℐ(!S)$.

\[u^! \; ≝ \; \lbrace u^0 ∈ \vert !S \vert \; \mid \; \underbrace{u^0 ⊆ u}_{\text{ or } !u^0 ⊆ u \text{ since } u \text{ is an initial segment}} \rbrace\]

Indeed, $u^! ∈ ℐ(!S)$, because if $u^0 ∈ u^!$, we have $↓ u^0 ⊆ u$. Let $u^1 ∈ \vert !S \vert$ st $u^1 ≤_{!S} u^0$, that is $↓ u^1 ⊆ ↓ u^0 ⊆ u$, so $↓ u^1 ⊆ u$, and $u^1 ∈ u^!$.

Let $s ∈ PoLR(!S, T)$.

\[Fun(s)(u) = su^!\] \[Fun(s): \begin{cases} ℐ(S) &⟶ ℐ(T) \\ u &⟼ \lbrace b \; \mid \; ∃ \underbrace{u^0 ⊆ u}_{u^0 ∈ u^!}; (u^0, b) ∈ s \rbrace \end{cases}\]

Consequence: $s, s’ ∈ PoLR(!S, T)$:

\[s=s' ⟺ ∀ u ∈ ℐ(S), su^! = s' u^!\]

Let $s ∈ PoLR(S, T)$. $!s ∈ PoLR(!S, !T)$:

\[!s \; ≝ \; \lbrace (u^0, v^0) \; \mid \; ∀ b ∈ v^0, ∃ a ∈ u^0; (a, b) ∈ s\rbrace\]

Let’s prove that $!s ∈ PoLR(!S, !T) = ℐ(!S ⊸ !T)$.

Let $(u_0, v_0) ∈ !s$, let $(u_1, v_1) ∈ \vert !S ⊸ !T \vert$ st

\[(u_1, v_1) ≤_{!S ⊸ !T} (u_0, v_0)\]

Prove that $(u_1, v_1) ∈ !s$. Let $b ∈ v_1$. We have:

\[v_1 ≤_{!T} v_0\]

so there exists $b’ ∈ v_0$ st $b ≤_T b’$.

But $(u_0, v_0) ∈ !s$, so there exists $a’ ∈ u_0, \; (a’, b’) ∈ s$

We have \(u_0 ≤_{!S} u_1 \text{ so } ∃ a ∈ u_1; a' ≤_S a\)

As $(a’, b’) ∈ s$, it comes that $(a, b) ∈ s$.

Fact: for all $u ∈ ℐ(S)$, \(!s u^! = (su)^!\)

$!$ is functorial: $s: S ⟶ T, t: T ⟶ U$

\[!(ts) = (!t)(!s)\\ !(ts) u^! = ((ts)u)^! = (t(su))^! = !t (su)^! = (!t)(!s)u^!\\ \, \\ (!id)u^! = (id u)^! = u^! = id u^!\\ ⟹ !id = id\]

We want a comonad structure:

$der_S ∈ PoLR(!S, S)$:

\[der_S \; ≝ \; \lbrace (u^0, a) \; \mid \; ∃ a' ∈ u^0; a ≤_S a'\rbrace\]

Recall that in $Coh$: $der_E = \lbrace (\lbrace a\rbrace, a) \; \mid \; a ∈ \vert E \vert\rbrace$

\[der_S u^! = u\]

And $dig_S ∈ PoLR(!S, !!S)$:

\[dig_S \; ≝ \; \lbrace (u^0, U^0) \; ∈ \vert !S \vert × \vert !!S \vert \; \mid \; ∀ u^1 ∈ U^0; u^1 ≤_{!S} u^0\rbrace\]

Fact: $∀ u ∈ ℐ(S)$:

\[dig_S u^! = u^{!!}\]

with the commutativity of

\[\begin{xy} \xymatrix{ !S \ar[r]^{dig_S} \ar[d]_{dig_S} & !!S \ar[d]^{dig_{!S}} \\ !!S \ar[r]_{!dig_S} & !!S } \end{xy}\]

Seely isos

\[!⊤ \; ≝ \; (\lbrace ∅ \rbrace, =) ≃ 1 \; ≝ \; (\lbrace \ast \rbrace)\] \[S = !(S_1 \& S_2)\\ \vert S \vert = 𝒫_{fin}(\lbrace 1\rbrace × \vert S_1\vert ∪ \lbrace 2 \rbrace × \vert S_2 \vert) ≃ 𝒫_{fin}(\vert S_1 \vert) × 𝒫_{fin}(\vert S_2 \vert) = \vert !S_1 ⊗ !S_2 \vert\] \[θ: \vert !(S_1 \& S_2) \vert \overset{≃}{⟶} \vert !S_1 ⊗ !S_2 \vert\]

$θ$ is a preorder iso between $!(S_1 \& S_2)$ and $!S_1 ⊗ !S_2$.

$\widehat θ$ is the required $m^2_{S_1, S_2}$

$PoLR_!$ is a CCC \(PoLR_! ≅ PoC \text{ iso of CCC}\)

$PoLR_!$:

  • Objects: those of $PoLR$
  • Morphisms: \(PoLR_!(S, T) = PoLR(!S, T) \overset{Fun}{⟶} PoLR(S,T)\\ PoLR(S,T) \overset{Tr}{⟶} PoLR_!(S, T)\) \(s ∈ PoLR_!(S, T) \qquad t ∈ PoLR_!(T, U)\\ t \circ_! s = t (!s) dig_S\\ !S \overset{dig_S}{⟶} !!S \overset{!s}{⟶} !T \overset{t}{⟶} U\)

$u ∈ ℐ(S)$

\[Fun(t \circ_! s)(u) = (t \circ_! s)u^!\\ = (t (!s) dig_S) u^!\\ = t (!s) u^{!!} = t (su^!)^! = t (Fun(s)(u))^!\\ = Fun(t)(Fun(s)(u))\] \[Fun(t \circ_! s) = Fun(t) \circ Fun(s)\\ Fun(der_S)(u) = der_S u^! = u ⟹ Fun(der_S) = id\]

So we have the isomorphism

\[Φ: \begin{cases} PoLR_! &⟶ PoC \\ S &⟼ S\\ s ∈ PoLR_!(S, T) &⟼ Fun(s)\\ \end{cases}\]

Fixpoints

  1. Fixpoints of functions
  2. Fixpoints of types

Ex: $N \; ≝ \; (ℕ, =)$ (trivial preorder). Find $S$ such that

\[S \;=\; (!(N ⊸ S))^⊥\]

Why? We have the strong isomorphism:

\[N ≃ 1 ⊕ N\]

So

\[N ⊸ S ≃ (1 ⊕ N) ⊸ S ≃ S \& (N ⊸ S)\]

indeed:

\[(1 ⊕ N)^⊥ ⅋ S = (⊥ \& N^⊥) ⅋ S ≃ (⊥ ⅋ S) \& (N^⊥ ⅋ S) ≃ S \& (N ⊸ S)\]

Thus:

\[!(N ⊸ S) ≃ !(S \& (N ⊸ S)) ≃ !S ⊗ !(N ⊸ S)\]

and

\[S = (!(N ⊸ S))^⊥ ≃ (!S)^⊥ ⅋ (!(N ⊸ S))^⊥ = (!S)^⊥ ⅋ S = !S ⊸ S\]

So $S = D_∞$ is the Scott-model of the pure $λ$-calculus (of $β$ and $η$ rewriting) and of $λμ$-calculus (classical $λ$-calculus).

\[F: \begin{cases} Po_{⊆} &⟶ Po_{⊆} \\ S &⟼ (!(N ⊸ S))^⊥ \end{cases}\]

$D_∞$ is the least fixpoint of $F$:

\[∅ ⊆ F(∅) ⊆ F^2(∅) ⊆ ⋯\]

Leave a comment