]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/rt_computation/csx_lsubr.ma
milestone in basic_2
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / rt_computation / csx_lsubr.ma
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/rt_transition/cpx_lsubr.ma".
16 include "basic_2/rt_computation/csx_csx.ma".
17
18 (* STRONGLY NORMALIZING TERMS FOR UNBOUND PARALLEL RT-TRANSITION ************)
19
20 (* Advanced properties ******************************************************)
21
22 fact csx_appl_beta_aux: ∀h,p,G,L,U1. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃U1⦄ →
23                         ∀V,W,T1. U1 = ⓓ{p}ⓝW.V.T1 → ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃ⓐV.ⓛ{p}W.T1⦄.
24 #h #p #G #L #X #H @(csx_ind … H) -X
25 #X #HT1 #IHT1 #V #W #T1 #H1 destruct
26 @csx_intro #X #H1 #H2
27 elim (cpx_inv_appl1 … H1) -H1 *
28 [ -HT1 #V0 #Y #HLV0 #H #H0 destruct
29   elim (cpx_inv_abst1 … H) -H #W0 #T0 #HLW0 #HLT0 #H destruct
30   @IHT1 -IHT1 [4: // | skip ]
31   [ lapply (lsubr_cpx_trans … HLT0 (L.ⓓⓝW.V) ?) -HLT0 -H2
32     /3 width=1 by cpx_bind, cpx_flat, lsubr_beta/
33   | #H elim (tdeq_inv_pair … H) -H
34     #_ #H elim (tdeq_inv_pair … H) -H
35     #_ /4 width=1 by tdeq_pair/
36   ]
37 | -IHT1 -H2 #q #V0 #W0 #W2 #T0 #T2 #HLV0 #HLW02 #HLT02 #H1 #H3 destruct
38   lapply (lsubr_cpx_trans … HLT02 (L.ⓓⓝW0.V) ?) -HLT02
39   /4 width=5 by csx_cpx_trans, cpx_bind, cpx_flat, lsubr_beta/
40 | -HT1 -IHT1 -H2 #q #V0 #V1 #W0 #W1 #T0 #T3 #_ #_ #_ #_ #H destruct
41 ]
42 qed-.
43
44 (* Basic_1: was just: sn3_beta *)
45 lemma csx_appl_beta: ∀h,p,G,L,V,W,T. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃ⓓ{p}ⓝW.V.T⦄ → ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃ⓐV.ⓛ{p}W.T⦄.
46 /2 width=3 by csx_appl_beta_aux/ qed.
47
48 (* Advanced forward lemmas **************************************************)
49
50 fact csx_fwd_bind_dx_unit_aux: ∀h,G,L,U. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃U⦄ →
51                                ∀p,I,J,V,T. U = ⓑ{p,I}V.T → ⦃G, L.ⓤ{J}⦄ ⊢ ⬈*[h] 𝐒⦃T⦄.
52 #h #G #L #U #H elim H -H #U0 #_ #IH #p #I #J #V #T #H destruct
53 @csx_intro #T2 #HLT2 #HT2
54 @(IH (ⓑ{p,I}V.T2)) -IH /2 width=4 by cpx_bind_unit/ -HLT2
55 #H elim (tdeq_inv_pair … H) -H /2 width=1 by/
56 qed-.
57
58 lemma csx_fwd_bind_dx_unit: ∀h,p,I,G,L,V,T. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃ⓑ{p,I}V.T⦄ →
59                             ∀J. ⦃G, L.ⓤ{J}⦄ ⊢ ⬈*[h] 𝐒⦃T⦄.
60 /2 width=6 by csx_fwd_bind_dx_unit_aux/ qed-.
61
62 lemma csx_fwd_bind_unit: ∀h,p,I,G,L,V,T. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃ⓑ{p,I}V.T⦄ →
63                          ∀J. ⦃G, L⦄ ⊢ ⬈*[h] 𝐒⦃V⦄ ∧ ⦃G, L.ⓤ{J}⦄ ⊢ ⬈*[h] 𝐒⦃T⦄.
64 /3 width=4 by csx_fwd_pair_sn, csx_fwd_bind_dx_unit, conj/ qed-.