APPENDIX D
THE NORMALIZATION ALGORITHM
In this appendix, we extend the relation > of Appendix C to a global reducibility relation L which determines the choice and order of application of Rules (R2)-(R17) in cases of syntactic ambiguity. The relation L is defined on three subclasses of Der(A(X)) whose elements represent the arrows of (a) non-Cartesian, non-symmetric, (b) nonCartesian, symmetric, and (c) Cartesian categories, respectively. The adopted priorities may be summarized as follows: (a)
(R8) 5 (R14) 5 (R9) 5 (R2), (R15) I(R14) I(R9) I(R2), (R17) I(R14) I(R9) I(R2).
(b)
(R8) I(R14) I(R9) I(R2) I(R4), (R15) I(R14) I(R9) I(R2) I(R4).
(c) (R5) 5 (R13) 5 (R10) I(R12) 5 (R14) I(R3) I( R l l ) 5 (R2) 5 (R4), (R15) I(R12) I(R14) I(R3) 5 (R11) I(R2) I(R4), where I is transitive, and (Ri)<(Rj) indicates that (Ri) takes precedence over (Rj) whenever there exists a choice in their order of application. An argument by cases shows that the selected priorities are compatible. Specifically, the relation 2 is the smallest monotone partial ordering on Der(A(X)) containing > and satisfying the following further conditions:
(R2-R2) f
I
244
T H E N O R M A L I Z A T I O N AI.GOR1THM
245
(R2-R3)
(D.2.1)
(D.2.2) h TaA+ @ (D.2.3)
(D.2.4)
(R2-R4)
(D.3.1)
(D.3.2)
(D.3.3)
(D.3.4)
246
APPENDIX D
(R2-R5
(R2-R8)
(D.5.1)
(D.5.2) (R2-R9)
(D.6.1)
(D.6.2) (R2-R 1 0)
T H E NORMAL.IZATION AI-GORITHM
247
(R2-Rll)
(D.8.1)
(R2-R 12)
(R2-R 13)
(D. 10)
248
APPENDIX D
(D.12.1)
(D. 12.2) (R2-R 16)
(D.13.1)
(D.13.2)
(R2-R 17)
(D.14.1)
provided that in (D.14.2),I is the only atomic subformula of a.
T H E NORMALIZATION ALGORITHM
249
(D.15.2) where n L 3, A = ( Y I . * an, ai = a ( 1 5 i 5 n ) , and (a)and ( 7 ) denote n - 1 instances of (R3), with ai active before aj in ( 7 ) if i < j.
(D.16.1)
(D.16.2)
(D.16.3) (R3-R5)
(R3-R10)
250
APPENDIX D
(R3-Rll)
(D. 19.1)
(D. 19.2)
(D. 19.3)
(R3-R 12)
25 1
T H E N O R M A L I Z A T I O N ALGORIT HM
(R3-R14)
(D.22.1)
(D.22.2)
(D.22.3)
(R3-Rl5)
(D.23.1)
(D.23.2) (R4-R4) For any permutation r of the integers 1 , . successions (cr) and ( 7 ) of instances of (R4),
r +f @
A+@
. . , n , and
any
(D.24.1)
provided that T = a1 * * an,A = PI * . . p., pi = aa(i)for 1 5 i 5 n, and ( 7 ) is the unique string of interchanges which first moves a,,(~) to PI, then a,(~)to 0 2 , etc. If r is the identity permutation, the right-hand side denotes f.
252
APPENDIX D
If I is the only atomic subformula of a,or if a = T, then
and
where g and k are the unique cut-free derivations obtained by applying the cut elimination algorithm of Appendix C to the derivations
where m is the derivation of -+ (Y described in 8.6.2, 9.6.2, and 10.6.4, and where ((T)involves no instances of (Rl) and (R4), and contains at most instances of (R8) or (R10) whose premisses have empty antecedents, and at most instances of (R14) whose left premisses have empty antecedents.
(R4-RS)
(D.25) (R4-R8)
(D.26.1)
(D.26.2)
T H E NORMALIZATION ALGORITHM
253
(R4-R9)
(D.27.1)
( D. 27.2)
(D.27.3)
(D.27.4)
(R4-RlO)
(R4-Rll)
(D.29.1)
254
APPENDIX D
(D.29.2)
(D.29.3)
(D.29.4)
(R4-R12)
(R4-R13)
(D.31)
T H E NORMALIZATION ALGORITHM
255
(D.32.4)
(D.32.5) (R4R15) (D.33.1)
(D.33.2)
(D.33.3)
256
APPENDlX D
(D.33.4) (R5-R5)
(D.34)
(R5-Rl0)
(D.35.2)
(D.35.3)
(D.35.4)
(D.35.5)
T H E NORMALIZATION ALGORITHM
257
(D.35.9)
258
APPENDIX D
(R5-R 1 1 )
(D.36)
(R5-RI2)
(R5-Rl3)
(D.38.1)
(D.38.2) (R5-RI4)
(D.39)
T H E NORMALIZATION ALGORITHM
259
(D.40.1)
n
(D.40.2)
(R8-R 14)
(R8-R 16)
(R9-R9)
(D.43)
260
APPENDIX D
(R9-R 14)
(R9-R 15)
(D.45.1)
(R9-R 16)
T H E NORMALIZATION ALGORIT HM
26 I
(R9-R 17)
(D.47) (R 10-R 10) c
262
APPENDIX D
(D.51.2)
(R 10-R 14)
(D.52)
(R1I-R11)
(D.53) (R11-R12)
T H E NORMALIZATION ALGORITHM
263
(R11-RI3)
(D.55) (Rll-R14)
(R11-Rl5)
264
APPENDIX D
(D.57.2)
THE NORMALIZATION ALGORITHM
265
266
APPENDIX D
(R14-R 15)
(D.65.3)
(D.65.4)
(D.65.5)
T H E NORMALIZATION ALGORITHM
-2
261
(D.65.7)
(R14-R 16)
(R14-R17)
(D.67) (R15-R 16)
268
APPENDIX D
(R16-R 16)
(R 16-R 17)
(D.70) (R2-R2-R 10)
(R2-R2-R 12)
I'HE N O K M A I I 7 A T I O N A I . ( i O R I T H M
(R2-R3-R 10)
(R2-R3-R 12)
269
270
(R2-R4-R 10)
(R2-R4-R 12)
APPENDIX D
T H E NORMALIZATION ALGORITH M
27 I
(D.76.9)
(D.76.10)
(D.76.I I )
(D.76.12)
(D.76.13)
(D.76.14)
(D.76.15)
(D.76.16)
THE NOKMAI 1 / 4 1 1 0 N
(R3-R3-R 10)
(R3-R3-R 12)
A I CnOKIIHM
273
214
APPENDIX D
(R4-R4-R 12)
n
r S y A a v PA-+ @
(D.80.
(D.81.1)
(D.8 1.2)
T H E NORMALIZATION ALGORITHM
rrAajph+ rra 3 P A A + r a 4 rra+pA+
Tct+PA-f2 If a
= p, and
ra+$A+
if I is the only atomic subformula of a,or if a
275
(D.81.3)
= T, then (D.81.4)
t
(D.82.2)
-
P
(D.82.4)
(R8) If I is the only atomic subformula of a and /? and of the terms of r and A, then r m n +a &(,) r+a A+P, - + a n p (D.83) TA+auP rA+anP
276
APPENDIX D
with r, s, and (a)involving at most instances of (R8), resp. (R14), whose premisses, resp. left premisses, have empty antecedents, as described in Lemma 8.6.2.
(R14) If I is the only atomic subformula of a and p and of the terms of A, and A, then
r,
(D.84) with r, s,(a), and (7) involving at most instances of (R8), resp. (R14), whose premisses, resp. left premisses, have empty antecedents, as described in Lemma 8.6.2.
(R15) If I is the only subformula of a,or if a =T, then
(D.85) where g is the unique cut-free derivation obtained by applying the cut elimination algorithm of Appendix C to the derivation
where h is the derivation of + a described in 8.6.2,9.6.2,and 10.6.4, and where (a)involves no instances of (Rl) and (R4), and contains at most instances of (R8) or (R10) whose premisses have empty antecedents, and at most instances of (R14) whose left premisses have empty antecedents. This completes the description of the global defining conditions of 2 . All additional local requirements ensuring the uniqueness of representation of unique arrows are listed in the main body of the text. The effectiveness of 2 requires that the semantic condition in (D.12.3), (D.12.4), (D.24.2), (D.81.4). and (D.85) is given a syntactic
T H E NORMALIZATION ALGORITHM
277
characterization. Corollaries 4.6.3, 5.6.6, 6.6.6, and Lemmas 9.6.3 and 10.6.2 achieve this purpose. We define a derivation f to be normal if it is cut-free and if f 2 g implies that f = g . We say that f reduces to g if there exists a finite sequence ( f l , . . . f n > of derivations of A(X) such that f = f l , fn = g, and f l 2 f z 2 . . . 2 fn, and say that f reduces immediately to g , written as f % g , if f = g or if f 2 g by virtue of precisely one of the defining conditions of 2 . An argument by cases shows that if f % g and f % h, then there exists a derivation p such that g 8 p and h ~ p and , an induction on n + m extends this result to show that if f % f l % . . . % fn and f % g l % . * * + gm, there exists a derivation q with the property that fn 2 q and gm 2 q. Hence any derivation fEDer(A(X)) reduces to at most one normal derivation g . Since the relation > is contained in 2 , every fEDer(A(X)) which represents an arrow of one of the categories constructed in Chapters 2-12, reduces to a cut-free derivation g , and an induction on the number of violations of Conditions (D.l-85) in g shows that f reduces to a normal, and hence unique normal, derivation h. The relation 2 thus defines an algorithm for normalizing any f E Der(A(X)) belonging to one of the subclasses Der(xA(X)) of Der(A(X)) mentioned at the beginning of this appendix. Let = be the equivalence relation on Der(A(X)) generated by 2 . Then an induction on the length of the proof that f - g shows that for all f, g E Der(A(X)) representing an arrow of one of the categories constructed in Chapters 2-12, there exists a derivation h such that f 2 h and g 2 h. This property is called the Church-Rosser property of 2 . The proofs of the normalization theorems for the various subsystems xA(X) of A(X) in the main body of the text consist of the appropriate verifications that the relation z Xis contained in where = x is the equivalence relation on Der(xA(X)) induced by the interpretation S : Der(xA(X))+ ArFx(X), and where Z x is the reducibility relation on Der(xA(X)) generated by the local refinement of the restriction of 2 to Der(xA(X)). The proofs of the Church-Rosser theorems for the various subsystems xA(X) of A(X) in the body of the text, on the other hand, consist of the appropriate verifications that distinct normal derivations f and g of a sequent r + @represent distinct arrows of Fx(X), i.e., that f = * g iff f - x g , where z Xis the equivalence relation on Der(xA(X)) generated by zx.