20 One Logic from \(a=a\), and the Classical One as Its Reflection

Everything starts from \(a=a\).

There is one construction and one idempotent, not two definitions.

Identity, adjunction, currying

Q0 (identity). \(\vdash a=a\), with \(\mathrm {refl}\) the only generator. J gives substitution \(a=b,\ P(a)\vdash P(b)\), and following \(\vdash \) is reflexive and transitive (S2, S3).

Q1 (adjunction, found in identity).

\begin{equation} \Gamma (a,b),\ a=b\vdash R(a,b)\iff \Gamma (a,a)\vdash R(a,a), \tag{350}\end{equation}
with unit reflexivity and counit substitution (L8). In general \(F\dashv G\) means \(F(P)\vdash Q\iff P\vdash G(Q)\). Adjoints are unique, and left adjoints preserve joins while right adjoints preserve meets (S3, Yoneda).

Q2 (currying). Filling \((\lambda x.\,t)u=t[u/x]\) (one-point: pin \(x\) by \(x=u\) and hide it) and \(\lambda x.\,fx=f\) (identity decides) are the two round trips of

\begin{equation} \mathrm {Hom}(C\times B,D)\cong \mathrm {Hom}(C,D^B), \qquad C\wedge A\vdash B\iff C\vdash A\Rightarrow B . \tag{351}\end{equation}

Q3 (truth, falsity, negation).

\begin{equation} \top :=(a=a), \qquad \bot :=\{a:\ \neg (a=a)\}\ \text {(no generator)}, \qquad \neg P:=(P\Rightarrow \bot ). \tag{352}\end{equation}

Q4 (binary meets and joins).

\begin{equation} C\vdash A\wedge B\iff C\vdash A\ \text {and}\ C\vdash B, \qquad A\vee B\vdash C\iff A\vdash C\ \text {and}\ B\vdash C , \tag{353}\end{equation}
the right and left adjoints of duplicating a judgment.

Q5 (exponent laws). Each line has the same consequences or antecedents on both sides, so the two sides are equivalent by uniqueness of adjoints (Q1, Q2):

Kinds Judgments
\(D^{A+B}\cong D^A\times D^B\) \((A\vee B)\Rightarrow D\dashv \vdash (A\Rightarrow D)\wedge (B\Rightarrow D)\)
\((D^B)^A\cong D^{A\times B}\) \(A\Rightarrow (B\Rightarrow D)\dashv \vdash (A\wedge B)\Rightarrow D\)
\((B\times C)^A\cong B^A\times C^A\) \(A\Rightarrow (B\wedge C)\dashv \vdash (A\Rightarrow B)\wedge (A\Rightarrow C)\)
\(D^0\cong 1\), \(D^1\cong D\) \(\bot \Rightarrow D\dashv \vdash \top \), \(\top \Rightarrow D\dashv \vdash D\)
\(A\times (B+C)\cong A\times B+A\times C\) \(A\wedge (B\vee C)\dashv \vdash (A\wedge B)\vee (A\wedge C)\)

The last line holds because \(A\wedge -\) is a left adjoint (Q2), so it preserves joins.

Quantifiers, with witnesses produced by identity

Q6 (“for all” is anchored at \(x=x\)). With \(\top _X(x)=(x=x)\), which holds for every \(x\) by \(\mathrm {refl}\),

\begin{equation} \forall x.\,P(x):\Longleftrightarrow \top _X\le P, \qquad Q\le \forall x.\,P\iff \pi ^*Q\le P, \tag{354}\end{equation}
so \(\forall \) is the right adjoint of weakening, with counit \(\forall x.\,P\vdash P(t)\).

Q7 (witnesses come from identity). Every judgment splits into one-point pieces:

\begin{equation} P(x)\ \dashv \vdash \ \exists a.\,\bigl (x=a\wedge P(a)\bigr ), \tag{355}\end{equation}
by the one-point rule. A witness is the piece “\(x=a\)”, the diagonal at \(a\). Introducing \(\exists \) is \(\mathrm {refl}\) followed by hiding:
\begin{equation} P(t)\vdash t=t\wedge P(t)\vdash \exists x.\,\bigl (x=t\wedge P(x)\bigr )\vdash \exists x.\,P(x). \tag{356}\end{equation}
Hiding is generated by these pieces, so
\begin{equation} \exists x.\,P\le Q\iff P\le \pi ^*Q , \tag{357}\end{equation}
and \(\exists \) is the left adjoint of weakening. By Q5, with \(x\) not in \(Q\),
\begin{equation} (\exists x.\,P)\Rightarrow Q\dashv \vdash \forall x.\,(P\Rightarrow Q), \qquad \neg \exists x.\,P\dashv \vdash \forall x.\,\neg P, \qquad (\exists x.\,P)\wedge Q\dashv \vdash \exists x.\,(P\wedge Q). \tag{358}\end{equation}

Q8 (families of every size). A family \(\{x_i\}_{i\in I}\) is one judgment \(x(i,a)\) with an extra place \(i\), and

\begin{equation} \bigvee _ix_i=\exists i.\,x(i,-), \qquad \bigwedge _ix_i=\forall i.\,x(i,-), \qquad \bigvee \dashv \Delta \dashv \bigwedge . \tag{359}\end{equation}

Q9 (\(\Omega \) and \(\Omega ^X\)). \(\Omega \) is the kind of judgments without places, up to \(\dashv \vdash \). By Q2, \(\mathrm {Hom}(Y\times X,\Omega )\cong \mathrm {Hom}(Y,\Omega ^X)\). With Q4–Q8, \(\Omega \) and \(\Omega ^X\) are complete Heyting algebras. This is intuitionistic logic.

Classical logic as a reflection

Q10 (double negation is an idempotent closure). Let \(j=\neg \neg \). Then

\begin{equation} P\vdash jP\ \ \text {(unit of }\Rightarrow \text {)}, \qquad jjP\dashv \vdash jP\ \ (\neg \neg \neg =\neg ), \qquad j(P\wedge Q)\dashv \vdash jP\wedge jQ . \tag{360}\end{equation}
So \(j\) is an idempotent above the identity that preserves \(\wedge \). By L25 it splits as a reflection onto its fixed points
\begin{equation} \Omega _{\neg \neg }=\{P:\ \neg \neg P\vdash P\}. \tag{361}\end{equation}

Q11 (the classical connectives). On \(\Omega _{\neg \neg }\):

Hence, in \(\Omega _{\neg \neg }\),

\begin{equation} P\vee _c\neg P=\neg \neg (P\vee \neg P)=\top , \qquad \neg \neg P=P, \qquad \Omega _{\neg \neg }=\{\bot ,\top \}=\{\neg (a=a),\ a=a\}. \tag{363}\end{equation}
Classical logic is intuitionistic logic read through the idempotent \(j\). A classical tautology \(P\) has \(\neg \neg P\) intuitionistically provable: Glivenko in propositional logic, and the negative translation in predicate logic.

Q12 (the two readings).

\(\Omega \) (intuitionistic) \(\Omega _{\neg \neg }\) (classical)
\(\wedge \), \(\Rightarrow \), \(\forall \) Q2, Q4, Q6 same
\(\vee \) Q4 \(\neg \neg (A\vee B)\)
\(\exists \) witnesses from \(x=a\) (Q7) \(\neg \forall \neg \)
\(\neg \neg P\vdash P\) no yes
\(P\vee \neg P\) no yes
\(\Omega \) complete Heyting \(\{\neg (a=a),\ a=a\}\)
Completeness and Tarski

Q13 (completeness of \(\mathbb R\)). For a family of lower cuts of \(\mathbb Q\) bounded by \(u\), \((\sup _ix_i)(q)=\exists i.\,x_i(q)\) is again a lower cut and the least upper bound (Q8).

Q14 (Tarski). For monotone \(F\) on \(\Omega ^X\), \(\mu F=\forall P.\,(F(P)\le P\Rightarrow P)\) is the least fixed point (M4) in both readings.

Q15 (the floor).

Ingredient Status Source
adjunction derived unit reflexivity, counit substitution (Q1)
currying, \(\Rightarrow \) derived \(\beta \), \(\eta \) (Q2)
\(\top \), \(\bot \), \(\neg \) derived \(a=a\), \(\neg (a=a)\) (Q3)
\(\wedge \), \(\vee \), exponent laws derived Q4, Q5
\(\forall \) derived anchored at \(x=x\) (Q6)
\(\exists \) and its witnesses derived one-point pieces \(x=a\) (Q7)
\(\bigvee \), \(\bigwedge \) of every size; \(\Omega \), \(\Omega ^X\) derived Q8, Q9
classical logic derived reflection along \(j=\neg \neg \) (Q10, Q11)
completeness, Tarski derived Q13, Q14
generated kinds, e.g. \(\mathbb N\) principle “given by generators”, the step to infinity
choice (Zorn) principle non-separable Hahn–Banach, bases, Tychonoff

20.1 Heyting Algebras from the Diagonal

The diagonal of an order has two adjoints, join and meet. A monotone map that preserves joins has a right adjoint. Applied to \(A\wedge -\), this gives implication, which is currying in an order. A Heyting algebra is an order in which \(A\wedge -\) has this adjoint. Every law of intuitionistic logic is a corollary of its unit and counit, and classical logic is the reflection along \(\neg \neg \).

H1 (the diagonal and its adjoints). For an order \(L\), let \(\Delta :L\to L\times L\), \(\Delta x=(x,x)\). Its adjoints, when they exist, are join and meet:

\begin{equation} a\vee b\le x\iff (a,b)\le (x,x), \qquad (x,x)\le (a,b)\iff x\le a\wedge b, \qquad \vee \dashv \Delta \dashv \wedge . \tag{364}\end{equation}
For a family indexed by \(I\), with \(\Delta _I:L\to L^I\),
\begin{equation} \bigvee \dashv \Delta _I\dashv \bigwedge . \tag{365}\end{equation}
Both are unique by Yoneda. The empty family gives \(\bot =\bigvee \varnothing \) and \(\top =\bigwedge \varnothing \).

H2 (joins give meets). If all \(\bigvee \) exist, then

\begin{equation} \bigwedge S=\bigvee \{v:\ v\le s\ \forall s\in S\}, \tag{366}\end{equation}
by the unit and counit of \(\bigvee \) (M2). A complete lattice needs only the left adjoint of \(\Delta _I\).

H3 (adjoint functor theorem for orders). Let \(L,M\) be complete lattices and \(F:L\to M\) monotone. Then \(F\) has a right adjoint if and only if \(F\) preserves all joins, and

\begin{equation} G(b)=\bigvee \{a:\ F(a)\le b\}. \tag{367}\end{equation}
Proof. Left adjoints preserve joins (Q1). Conversely, if \(F\) preserves joins, then \(F(G(b))=\bigvee \{F(a):\ F(a)\le b\}\le b\), which is the counit. Every \(a\) with \(F(a)\le b\) lies below \(G(b)\), which is the unit. \(\square \)

H4 (currying in an order). Apply H3 to \(F=A\wedge -\). If \(A\wedge -\) preserves joins (distributivity),

\begin{equation} A\wedge \bigvee _ic_i=\bigvee _i(A\wedge c_i), \tag{368}\end{equation}
then it has a right adjoint
\begin{equation} A\Rightarrow B=\bigvee \{C:\ C\wedge A\le B\}, \qquad C\wedge A\le B\iff C\le A\Rightarrow B . \tag{369}\end{equation}
This is currying (Q2) in an order: exponentials of a thin category.

H5 (Heyting algebra). A Heyting algebra is a lattice in which every \(A\wedge -\) has a right adjoint. A complete lattice satisfying the distributivity of H4 (a frame) is a complete Heyting algebra by H3.

Example Join Why distributive
judgments \(\Omega ^X\) \(\exists \) over the index (Q8) Frobenius, Q7
open sets of a space union \(U\cap \bigcup _iV_i=\bigcup _i(U\cap V_i)\)
down-sets of an order (Kripke frames) union as for opens

For open sets, \(U\Rightarrow V=\mathrm {int}\bigl ((X\setminus U)\cup V\bigr )\) and \(\neg U=\mathrm {int}(X\setminus U)\).

H6 (intuitionistic laws as corollaries). Each law follows from the unit and counit of H4, or from adjoints preserving joins and meets:

Law Reason
\(A\wedge (A\Rightarrow B)\le B\) (modus ponens) counit
\(B\le A\Rightarrow (A\wedge B)\) unit
\(A\Rightarrow A=\top \) \(C\wedge A\le A\) for all \(C\)
\(A\wedge (B\vee C)=(A\wedge B)\vee (A\wedge C)\) \(A\wedge -\) is a left adjoint
\(A\Rightarrow (B\wedge C)=(A\Rightarrow B)\wedge (A\Rightarrow C)\) \(A\Rightarrow -\) is a right adjoint
\((A\vee B)\Rightarrow C=(A\Rightarrow C)\wedge (B\Rightarrow C)\) joins map to meets
\(\neg A:=A\Rightarrow \bot \), \(\ A\wedge \neg A=\bot \) counit with \(B=\bot \)
\(A\le \neg \neg A\) unit with \(B=\bot \)
\(\neg \neg \neg A=\neg A\) \(A\le \neg \neg A\) and antitonicity of \(\neg \)

H7 (what is not forced). In the open sets of \(\mathbb R\):

Excluded middle and double negation elimination are not corollaries of H5. This is intuitionistic logic, built from the diagonal.

H8 (classical logic as a corollary). By H6, \(j=\neg \neg \) satisfies

\begin{equation} A\le jA, \qquad jjA=jA, \qquad j(A\wedge B)=jA\wedge jB, \tag{370}\end{equation}
an idempotent closure preserving meets. Its fixed points \(L_{\neg \neg }=\{A:\ \neg \neg A=A\}\) form a Boolean algebra, with
\begin{equation} A\vee _cB=\neg \neg (A\vee B), \qquad A\vee _c\neg A=\top , \qquad \exists _c=\neg \forall \neg . \tag{371}\end{equation}
For open sets, \(L_{\neg \neg }\) consists of the regular open sets, \(U=\mathrm {int}\,\overline U\). For truth values in sets, \(\Omega _{\neg \neg }=\{\bot ,\top \}\). A Boolean algebra is exactly a Heyting algebra with \(\neg \neg =\mathrm {id}\).

H9 (the chain).

Step Result From
H1 \(\vee \dashv \Delta \dashv \wedge \); \(\bigvee \dashv \Delta _I\dashv \bigwedge \) the diagonal
H2 meets from joins unit and counit
H3 join-preserving maps have right adjoints H1, H2
H4 \(A\Rightarrow B=\bigvee \{C:\ C\wedge A\le B\}\) H3 on \(A\wedge -\)
H5 Heyting algebras; opens, \(\Omega ^X\), down-sets H4
H6 intuitionistic laws unit and counit
H7 no excluded middle in general open sets of \(\mathbb R\)
H8 Boolean algebra \(L_{\neg \neg }\); classical logic idempotent \(j=\neg \neg \)

20.2 Intuitionism through Homotopy Type Theory

Homotopy type theory reaches intuitionistic logic from identity alone.

The resulting propositions form a Heyting algebra, classical logic is its \(\neg \neg \)-reflection, and choice implies excluded middle [193].

HT1 (levels from identity). Each level is defined by identity types only:

\begin{equation} \begin {aligned} \mathrm {isContr}(A)&:=\textstyle \sum _{a:A}\prod _{b:A}(a=b),\\ \mathrm {isProp}(A)&:=\textstyle \prod _{a,b:A}(a=b),\\ \mathrm {isSet}(A)&:=\textstyle \prod _{a,b:A}\mathrm {isProp}(a=b), \end {aligned} \tag{372}\end{equation}
and \(A\) has level \(n+1\) when every \(a=b\) has level \(n\). By one-point (Q7), \(\sum _b(a=b)\) is contractible.

HT2 (propositions).

\begin{equation} \mathrm {Prop}:=\textstyle \sum _{A}\mathrm {isProp}(A), \qquad \top =1, \qquad \bot =0 . \tag{373}\end{equation}
In a set, \(a=a\) is contractible, so \(\top \) is the truth of \(a=a\) (Q3). Univalence gives propositional extensionality, \((P\leftrightarrow Q)\simeq (P=Q)\), so propositions are determined by mutual implication.

HT3 (truncation as a reflection). \(\|A\|\) has the generators \(|a|\) for \(a:A\) and \(\prod _{x,y:\|A\|}(x=y)\). Its universal property is

\begin{equation} \bigl (\|A\|\to P\bigr )\simeq \bigl (A\to P\bigr )\quad \text {for }P:\mathrm {Prop}, \tag{374}\end{equation}
so \(\|-\|\) is left adjoint to the inclusion \(\mathrm {Prop}\hookrightarrow \mathrm {Type}\). It is idempotent, \(\|\|A\|\|\simeq \|A\|\), a reflection as in L25.

HT4 (logic).

Logic Type Adjoint
\(P\wedge Q\) \(P\times Q\) right of duplication
\(P\Rightarrow Q\) \(P\to Q\) right of \(P\times -\) (currying)
\(\forall x.\,P\) \(\prod _xP(x)\) right of weakening
\(P\vee Q\) \(\|P+Q\|\) left of duplication, reflected
\(\exists x.\,P\) \(\|\sum _xP(x)\|\) left of weakening, reflected
\(\top \), \(\bot \) \(1\), \(0\) empty meet, empty join
\(x=y\) identity type left along the diagonal

\(\sum _xP(x)\)keeps its witness, and \(\|\sum _xP(x)\|\) forgets which witness. This is the intuitionistic \(\exists \), generated by witnesses (Q7).

HT5 (Heyting). With the operations of HT4, \(\mathrm {Prop}\) is a Heyting algebra. \(P\times -\) preserves truncated joins, so H3–H5 apply, and every law of H6 holds as a function between propositions.

HT6 (excluded middle, two strengths).

HT7 (classical logic as a reflection). \(\neg \neg \) is an idempotent closure on \(\mathrm {Prop}\) (H8). Its fixed points form a Boolean algebra, and

\begin{equation} \mathrm {LEM}_{-1}\iff \neg \neg P\to P\ \ \forall P:\mathrm {Prop}\iff \mathrm {Prop}\simeq \{0,1\}=\{\neg (a=a),\ a=a\}. \tag{375}\end{equation}

HT8 (choice implies classical logic). The axiom of choice for sets implies \(\mathrm {LEM}_{-1}\) (Diaconescu). For a proposition \(P\), quotient \(\{0,1\}\) by \(0\sim 1\iff P\). A choice of representatives decides whether the two classes coincide, and hence decides \(P\). The floor principle “choice” (Q15) therefore brings classical logic with it.

HT9 (the route).

Step Result From
HT1 contractible, propositions, sets, levels identity types
HT2 \(\mathrm {Prop}\), \(\top \), \(\bot \); extensionality HT1; univalence
HT3 truncation, a reflection generators with all paths
HT4 \(\wedge ,\Rightarrow ,\forall ,\vee ,\exists \) adjoints, truncated
HT5 Heyting algebra H3–H5
HT6 \(\mathrm {LEM}_{-1}\) consistent; \(\mathrm {LEM}_\infty \) contradicts univalence exchange \(\sigma \) on \(\{0,1\}\)
HT7 Boolean reflection; \(\mathrm {Prop}\simeq \{0,1\}\) under LEM \(\neg \neg \)
HT8 choice implies LEM Diaconescu

The diagonal route (Section 20.1) builds Heyting algebras as orders. The HoTT route builds them as the propositions among types, with proofs kept until truncation forgets them. The two meet at HT5.