nLab Russell universe

Context

Type theory

natural deduction metalanguage, practical foundations

  1. type formation rule
  2. term introduction rule
  3. term elimination rule
  4. computation rule

type theory (dependent, intensional, observational type theory, homotopy type theory)

syntax object language

computational trinitarianism =
propositions as types +programs as proofs +relation type theory/category theory

logicset theory (internal logic of)category theorytype theory
propositionsetobjecttype
predicatefamily of setsdisplay morphismdependent type
proofelementgeneralized elementterm/program
cut rulecomposition of classifying morphisms / pullback of display mapssubstitution
introduction rule for implicationcounit for hom-tensor adjunctionlambda
elimination rule for implicationunit for hom-tensor adjunctionapplication
cut elimination for implicationone of the zigzag identities for hom-tensor adjunctionbeta reduction
identity elimination for implicationthe other zigzag identity for hom-tensor adjunctioneta conversion
truesingletonterminal object/(-2)-truncated objecth-level 0-type/unit type
falseempty setinitial objectempty type
proposition, truth valuesubsingletonsubterminal object/(-1)-truncated objecth-proposition, mere proposition
logical conjunctioncartesian productproductproduct type
disjunctiondisjoint union (support of)coproduct ((-1)-truncation of)sum type (bracket type of)
implicationfunction set (into subsingleton)internal hom (into subterminal object)function type (into h-proposition)
negationfunction set into empty setinternal hom into initial objectfunction type into empty type
universal quantificationindexed cartesian product (of family of subsingletons)dependent product (of family of subterminal objects)dependent product type (of family of h-propositions)
existential quantificationindexed disjoint union (support of)dependent sum ((-1)-truncation of)dependent sum type (bracket type of)
logical equivalencebijection setobject of isomorphismsequivalence type
support setsupport object/(-1)-truncationpropositional truncation/bracket type
n-image of morphism into terminal object/n-truncationn-truncation modality
equalitydiagonal function/diagonal subset/diagonal relationpath space objectidentity type/path type
completely presented setsetdiscrete object/0-truncated objecth-level 2-type/set/h-set
setset with equivalence relationinternal 0-groupoidBishop set/setoid with its pseudo-equivalence relation an actual equivalence relation
equivalence class/quotient setquotientquotient type
inductioncolimitinductive type, W-type, M-type
higher inductionhigher colimithigher inductive type
-0-truncated higher colimitquotient inductive type
coinductionlimitcoinductive type
presettype without identity types
set of truth valuessubobject classifiertype of propositions
domain of discourseuniverseobject classifiertype universe
modalityclosure operator, (idempotent) monadmodal type theory, monad (in computer science)
linear logic(symmetric, closed) monoidal categorylinear type theory/quantum computation
proof netstring diagramquantum circuit
(absence of) contraction rule(absence of) diagonalno-cloning theorem
synthetic mathematicsdomain specific embedded programming language

homotopy levels

semantics

Universes

Contents

Idea

Russell universes or universes à la Russell are types whose terms are types. In type theories without a separate type judgment AtypeA \; \mathrm{type}, only typing judgments a:Aa:A, what would have been type judgments are represented by typing judgments that AA is a term of a Russell universe UU, A:UA:U. Russell universes without a separate type judgment are used in many places in type theory, including in the HoTT book, in Coq, and in Agda.

Formal definition

Without a separate type judgment

Russell universes are formally defined in a two-level type theory. The first level consists of a basic dependent type theory consisting of a type judgment, identity types, and a natural numbers type. The second level only contains term judgments, and is the dependent type theory where the Russell universes live in. To distinguish between the two layers, we shall call the types in the first layer “metatypes”, as the first layer behaves as a metatheory or external theory.

We begin with the formal rules of the first layer. The first layer consists of three judgments: metatype judgments AmetatypeA \; \mathrm{metatype}, where we judge AA to be a metatype, metatyping judgments, where we judge aa to be an element of AA, aAa \in A, and metacontext judgments, where we judge Ξ\Xi to be a metacontext, Ξmetactx\Xi \; \mathrm{metactx}. Metacontexts are lists of metatyping judgments aAa \in A, bBb \in B, cCc \in C, et cetera, and are formalized by the rules for the empty metacontext and extending the metacontext by a metatyping judgment

()metactxΞmetactxΞAmetatype(Ξ,aA)metactx\frac{}{() \; \mathrm{metactx}} \qquad \frac{\Xi \; \mathrm{metactx} \quad \Xi \vdash A \; \mathrm{metatype}}{(\Xi, a \in A) \; \mathrm{metactx}}

The three standard structural rules, the variable rule, the weakening rule, and the substitution rule, are also included in the theory. Let 𝒥\mathcal{J} be any arbitrary judgment. Then we have the following rules:

  • The variable rule:
Ξ,aA,ΩmetactxΞ,aA,ΩaA\frac{\Xi, a \in A, \Omega \; \mathrm{metactx}}{\vdash \Xi, a \in A, \Omega \vdash a \in A}
  • The weakening rule:
Ξ,Ω𝒥ΞAmetatypeΞ,aA,Ω𝒥\frac{\Xi, \Omega \vdash \mathcal{J} \quad \Xi \vdash A \; \mathrm{metatype}}{\Xi, a \in A, \Omega \vdash \mathcal{J}}
  • The substitution rule:
ΞaAΞ,bA,Ω𝒥Ξ,Ω[a/b]𝒥[a/b]\frac{\Xi \vdash a \in A \quad \Xi, b \in A, \Omega \vdash \mathcal{J}}{\Xi, \Omega[a/b] \vdash \mathcal{J}[a/b]}

In addition, there are identity metatypes: the natural deduction rules for identity metatypes are as follows

ΞAmetatypeΞ,aA,bAa= AbmetatypeΞAmetatypeΞ,aArefl A(a)a= Aa\frac{\Xi \vdash A \; \mathrm{metatype}}{\Xi, a \in A, b \in A \vdash a =_A b \; \mathrm{metatype}} \qquad \frac{\Xi \vdash A \; \mathrm{metatype}}{\Xi, a \in A \vdash \mathrm{refl}_A(a) \in a =_A a}
Ξ,xA,yA,px= AyCmetatypeΞ,zAtC[z/x,z/y,refl A(z)/p]ΞaAΞbAΞqa= AbΞJ(x.y.p.C,z.t,x,y,p)C[a/x,b/y,q/p]\frac{\Xi, x \in A, y \in A, p \in x =_A y \vdash C \; \mathrm{metatype} \quad \Xi, z \in A \vdash t \in C[z/x, z/y, \mathrm{refl}_A(z)/p] \quad \Xi \vdash a \in A \quad \Xi \vdash b \in A \quad \Xi \vdash q \in a =_A b}{\Xi \vdash J(x.y.p.C, z.t, x, y, p) \in C[a/x, b/y, q/p]}
Ξ,xA,yA,px= AyCmetatypeΞ,zAt:C[z/x,z/y,refl A(z)/p]Ξa:AΞβ = A(a)J(x.y.p.C,z.t,a,a,refl A(a))= C[a/x,a/y,refl A(a)/p]t[a/z]\frac{\Xi, x \in A, y \in A, p \in x =_A y \vdash C \; \mathrm{metatype} \quad \Xi, z \in A \vdash t:C[z/x, z/y, \mathrm{refl}_A(z)/p] \quad \Xi \vdash a:A}{\Xi \vdash \beta_{=_A}(a) \in J(x.y.p.C, z.t, a, a, \mathrm{refl}_A(a)) =_{C[a/x, a/y, \mathrm{refl}_A(a)/p]} t[a/z]}

Finally, we have the natural numbers metatype, given by the following natural deduction rules:

ΞmetactxΞ𝒩metatypeΞmetactxΞ0 𝒩𝒩Ξn𝒩Ξs 𝒩(n)𝒩\frac{\Xi \; \mathrm{metactx}}{\Xi \vdash \mathcal{N} \; \mathrm{metatype}} \qquad \frac{\Xi \; \mathrm{metactx}}{\Xi \vdash 0_{\mathcal{N}} \in \mathcal{N}} \qquad \frac{\Xi \vdash n \in \mathcal{N}}{\Xi \vdash s_\mathcal{N}(n) \in \mathcal{N}}
Ξ,x𝒩CmetatypeΞc 0 𝒩C[0 𝒩/x]Ξ,x𝒩,cCc s 𝒩C[s 𝒩(x)/x]ΞnΓind 𝒩 C(n,c 0 𝒩,c s 𝒩)C[n/x]\frac{\Xi, x \in \mathcal{N} \vdash C \; \mathrm{metatype} \quad \Xi \vdash c_{0_\mathcal{N}} \in C[0_\mathcal{N}/x] \quad \Xi, x \in \mathcal{N}, c \in C \vdash c_{s_\mathcal{N}} \in C[s_\mathcal{N}(x)/x] \quad \Xi \vdash n \in \mathbb{N}}{\Gamma \vdash \mathrm{ind}_\mathcal{N}^C(n, c_{0_\mathcal{N}}, c_{s_\mathcal{N}}) \in C[n/x]}
Ξ,x𝒩CmetatypeΞc 0 𝒩C[0 𝒩/x]Ξ,x𝒩,cCc s 𝒩C[s 𝒩(x)/x]Ξβ 𝒩 0 𝒩ind 𝒩 C(0 𝒩,c 0 𝒩,c s 𝒩)= C[0 𝒩/x]c 0 𝒩\frac{\Xi, x \in \mathcal{N} \vdash C \; \mathrm{metatype} \quad \Xi \vdash c_{0_\mathcal{N}} \in C[0_\mathcal{N}/x] \quad \Xi, x \in \mathcal{N}, c \in C \vdash c_{s_\mathcal{N}} \in C[s_\mathcal{N}(x)/x]}{\Xi \vdash \beta_\mathcal{N}^{0_\mathcal{N}} \in \mathrm{ind}_\mathcal{N}^C(0_\mathcal{N}, c_{0_\mathcal{N}}, c_{s_\mathcal{N}}) =_{C[0_\mathcal{N}/x]} c_{0_\mathcal{N}}}
Ξ,x𝒩CmetatypeΞc 0 𝒩C[0 𝒩/x]Ξ,x𝒩,cCc s 𝒩C[s 𝒩(x)/x]Γβ 𝒩 s 𝒩(n)ind 𝒩 C(s 𝒩(n),c 0 𝒩,c s 𝒩)= C[s 𝒩(n)/x]c s 𝒩(n,ind 𝒩 C(n,c 0 𝒩,c s 𝒩))\frac{\Xi, x \in \mathcal{N} \vdash C \; \mathrm{metatype} \quad \Xi \vdash c_{0_\mathcal{N}} \in C[0_\mathcal{N}/x] \quad \Xi, x \in \mathcal{N}, c \in C \vdash c_{s_\mathcal{N}} \in C[s_\mathcal{N}(x)/x]}{\Gamma \vdash \beta_\mathcal{N}^{s_\mathcal{N}(n)} \in \mathrm{ind}_\mathcal{N}^C(s_\mathcal{N}(n), c_{0_\mathcal{N}}, c_{s_\mathcal{N}}) =_{C[s_\mathcal{N}(n)/x]} c_{s_\mathcal{N}}(n, \mathrm{ind}_\mathcal{N}^C(n, c_{0_\mathcal{N}}, c_{s_\mathcal{N}}))}

Now, we introduce the second layer, which consists of a type theory with only one judgment, the typing judgment a:Aa:A, which says that aa is a term of the type AA. Instead of type judgments, we introduce a special kind of type called a Russell universe or universe à la Russell, whose terms are the types themselves. Russell universes are formalized with the following rules:

Ξi𝒩ΞU i:U s 𝒩(i)Ξi𝒩ΞA:U iΞLift i(A):U s 𝒩(i)\frac{\Xi \vdash i \in \mathcal{N}}{\Xi \vdash U_i:U_{s_\mathcal{N}(i)}} \quad \frac{\Xi \vdash i \in \mathcal{N} \quad \Xi \vdash A:U_i}{\Xi \vdash \mathrm{Lift}_i(A):U_{s_\mathcal{N}(i)}}

Contexts are defined as a metacontext with a list of typing judgments, with the metacontext always preceding the list of typing judgments:

ΞmetactxΞ|()ctxΞ|ΓA:U iΞ|(Γ,a:A)ctx\frac{\Xi \; \mathrm{metactx}}{\Xi \vert () \; \mathrm{ctx}} \qquad \frac{\Xi \vert \Gamma \vdash A:U_i}{\Xi \vert (\Gamma, a:A) \; \mathrm{ctx}}

The general rules for Russell universes then follows:

Ξ|Γi𝒩Ξ|ΓU i:U s 𝒩(i)Ξ|Γi𝒩Ξ|ΓA:U iΞ|ΓLift i(A):U s 𝒩(i)\frac{\Xi \vert \Gamma \vdash i \in \mathcal{N}}{\Xi \vert \Gamma \vdash U_i:U_{s_\mathcal{N}(i)}} \quad \frac{\Xi \vert \Gamma \vdash i \in \mathcal{N} \quad \Xi \vert \Gamma \vdash A:U_i}{\Xi \vert \Gamma \vdash \mathrm{Lift}_i(A):U_{s_\mathcal{N}(i)}}

With a separate type judgment

If the type theory has a separate type judgment AtypeA \; \mathrm{type}, the rules for Russell universes become simpler, as one doesn’t have to assume infinitely many Russell universes and a second level to house the natural numbers type used to index the universes. Instead, we merely have

ΓctxΓUtypeΓA:UΓAtype\frac{\Gamma \; \mathrm{ctx}}{\Gamma \vdash U \; \mathrm{type}} \qquad \frac{\Gamma \vdash A:U}{\Gamma \vdash A \; \mathrm{type}}

Furthermore, the separate type judgment amounts to collapsing the two levels in the theory above into one level: Instead of defining the identity type and the type of natural numbers as external to the type theory, we instead define it as normal types internal to the type theory. Then the rules for the infinite tower of Russell universes are as follows:

Γi:ΓU(i):U(s(i))Γi:ΓA:U(i)ΓAtypeΓi:ΓA:U(i)ΓLift(i)(A):U(s(i))\frac{\Gamma \vdash i:\mathbb{N}}{\Gamma \vdash U(i):U(s(i))} \qquad \frac{\Gamma \vdash i:\mathbb{N} \quad \Gamma \vdash A:U(i)}{\Gamma \vdash A \; \mathrm{type}} \qquad \frac{\Gamma \vdash i:\mathbb{N} \quad \Gamma \vdash A:U(i)}{\Gamma \vdash \mathrm{Lift}(i)(A):U(s(i))}

See also

References

The notion is due to:

For more see the references at type universe.

Last revised on January 21, 2023 at 16:28:19. See the history of this page for a list of all contributions to it.