]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/etc/referred/lfsx.etc
update in delayed_updating
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / etc / referred / lfsx.etc
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 include "basic_2/notation/relations/predtysnstrong_5.ma".
16 include "basic_2/static/lfdeq.ma".
17 include "basic_2/rt_transition/lfpx.ma".
18
19 (* STRONGLY NORMALIZING LOCAL ENV.S FOR UNBOUND PARALLEL RT-TRANSITION ******)
20
21 definition lfsx: ∀h. sd h → relation3 term genv lenv ≝
22                  λh,o,T,G. SN … (lfpx h G T) (lfdeq h o T).
23
24 interpretation
25    "strong normalization for unbound context-sensitive parallel rt-transition on referred entries (local environment)"
26    'PRedTySNStrong h o T G L = (lfsx h o T G L).
27
28 (* Basic eliminators ********************************************************)
29
30 (* Basic_2A1: uses: lsx_ind *)
31 lemma lfsx_ind: ∀h,o,G,T. ∀R:predicate lenv.
32                 (∀L1. G ⊢ ⬈*[h, o, T] 𝐒⦃L1⦄ →
33                       (∀L2. ⦃G, L1⦄ ⊢ ⬈[h, T] L2 → (L1 ≛[h, o, T] L2 → ⊥) → R L2) →
34                       R L1
35                 ) →
36                 ∀L. G ⊢ ⬈*[h, o, T] 𝐒⦃L⦄ → R L.
37 #h #o #G #T #R #H0 #L1 #H elim H -L1
38 /5 width=1 by SN_intro/
39 qed-.
40
41 (* Basic properties *********************************************************)
42
43 (* Basic_2A1: uses: lsx_intro *)
44 lemma lfsx_intro: ∀h,o,G,L1,T.
45                   (∀L2. ⦃G, L1⦄ ⊢ ⬈[h, T] L2 → (L1 ≛[h, o, T] L2 → ⊥) → G ⊢ ⬈*[h, o, T] 𝐒⦃L2⦄) →
46                   G ⊢ ⬈*[h, o, T] 𝐒⦃L1⦄.
47 /5 width=1 by SN_intro/ qed.
48
49 (* Basic_2A1: uses: lsx_sort *)
50 lemma lfsx_sort: ∀h,o,G,L,s. G ⊢ ⬈*[h, o, ⋆s] 𝐒⦃L⦄.
51 #h #o #G #L1 #s @lfsx_intro
52 #L2 #H #Hs elim Hs -Hs elim (lfpx_inv_sort … H) -H *
53 [ #H1 #H2 destruct //
54 | #I1 #I2 #K1 #K2 #HK12 #H1 #H2 destruct
55   /4 width=4 by lfdeq_sort, lfxs_isid, frees_sort, frees_inv_sort/
56 ]
57 qed.
58
59 (* Basic_2A1: uses: lsx_gref *)
60 lemma lfsx_gref: ∀h,o,G,L,p. G ⊢ ⬈*[h, o, §p] 𝐒⦃L⦄.
61 #h #o #G #L1 #s @lfsx_intro
62 #L2 #H #Hs elim Hs -Hs elim (lfpx_inv_gref … H) -H *
63 [ #H1 #H2 destruct //
64 | #I1 #I2 #K1 #K2 #HK12 #H1 #H2 destruct
65   /4 width=4 by lfdeq_gref, lfxs_isid, frees_gref, frees_inv_gref/
66 ]
67 qed.
68
69 lemma lfsx_unit: ∀h,o,I,G,L. G ⊢ ⬈*[h, o, #0] 𝐒⦃L.ⓤ{I}⦄.
70 #h #o #I #G #L1 @lfsx_intro
71 #Y #HY #HnY elim HnY -HnY /2 width=2 by lfxs_unit_sn/
72 qed.
73
74 (* Basic forward lemmas *****************************************************)
75
76 fact lfsx_fwd_pair_aux: ∀h,o,G,L. G ⊢ ⬈*[h, o, #0] 𝐒⦃L⦄ →
77                         ∀I,K,V. L = K.ⓑ{I}V → G ⊢ ⬈*[h, o, V] 𝐒⦃K⦄.
78 #h #o #G #L #H
79 @(lfsx_ind … H) -L #L1 #_ #IH #I #K1 #V #H destruct
80 /5 width=5 by lfpx_pair, lfsx_intro, lfdeq_fwd_zero_pair/
81 qed-.
82
83 lemma lfsx_fwd_pair: ∀h,o,I,G,K,V.
84                      G ⊢ ⬈*[h, o, #0] 𝐒⦃K.ⓑ{I}V⦄ → G ⊢ ⬈*[h, o, V] 𝐒⦃K⦄.
85 /2 width=4 by lfsx_fwd_pair_aux/ qed-.
86
87 (* Basic_2A1: removed theorems 9:
88               lsx_ge_up lsx_ge
89               lsxa_ind lsxa_intro lsxa_lleq_trans lsxa_lpxs_trans lsxa_intro_lpx lsx_lsxa lsxa_inv_lsx
90 *)