]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/rt_computation/lpxs_cpxs.ma
update in ground
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / rt_computation / lpxs_cpxs.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_computation/lpxs_lpx.ma".
16
17 (* EXTENDED PARALLEL RT-COMPUTATION FOR FULL LOCAL ENVIRONMENTS *************)
18
19 (* Properties with context-sensitive extended rt-computation for terms ******)
20
21 (* Basic_2A1: was: cpxs_bind2 *)
22 lemma cpxs_bind_alt (G):
23       ∀L,V1,V2. ❪G,L❫ ⊢ V1 ⬈* V2 →
24       ∀I,T1,T2. ❪G,L.ⓑ[I]V2❫ ⊢ T1 ⬈* T2 →
25       ∀p. ❪G,L❫ ⊢ ⓑ[p,I]V1.T1 ⬈* ⓑ[p,I]V2.T2.
26 /4 width=5 by lpxs_cpxs_trans, lpxs_pair, cpxs_bind/ qed.
27
28 (* Inversion lemmas with context-sensitive ext rt-computation for terms *****)
29
30 lemma cpxs_inv_abst1 (G):
31       ∀p,L,V1,T1,U2. ❪G,L❫ ⊢ ⓛ[p]V1.T1 ⬈* U2 →
32       ∃∃V2,T2. ❪G,L❫ ⊢ V1 ⬈* V2 & ❪G,L.ⓛV1❫ ⊢ T1 ⬈* T2 & U2 = ⓛ[p]V2.T2.
33 #G #p #L #V1 #T1 #U2 #H @(cpxs_ind … H) -U2 /2 width=5 by ex3_2_intro/
34 #U0 #U2 #_ #HU02 * #V0 #T0 #HV10 #HT10 #H destruct
35 elim (cpx_inv_abst1 … HU02) -HU02 #V2 #T2 #HV02 #HT02 #H destruct
36 lapply (lpxs_cpx_trans … HT02 (L.ⓛV1) ?)
37 /3 width=5 by lpxs_pair, cpxs_trans, cpxs_strap1, ex3_2_intro/
38 qed-.
39
40 (* Basic_2A1: was: cpxs_inv_abbr1 *)
41 lemma cpxs_inv_abbr1_dx (p) (G) (L):
42       ∀V1,T1,U2. ❪G,L❫ ⊢ ⓓ[p]V1.T1 ⬈* U2 →
43       ∨∨ ∃∃V2,T2. ❪G,L❫ ⊢ V1 ⬈* V2 & ❪G,L.ⓓV1❫ ⊢ T1 ⬈* T2 & U2 = ⓓ[p]V2.T2
44        | ∃∃T2. ❪G,L.ⓓV1❫ ⊢ T1 ⬈* T2 & ⇧[1] U2 ≘ T2 & p = Ⓣ.
45 #p #G #L #V1 #T1 #U2 #H
46 @(cpxs_ind … H) -U2 /3 width=5 by ex3_2_intro, or_introl/
47 #U0 #U2 #_ #HU02 * *
48 [ #V0 #T0 #HV10 #HT10 #H destruct
49   elim (cpx_inv_abbr1 … HU02) -HU02 *
50   [ #V2 #T2 #HV02 #HT02 #H destruct
51     lapply (lpxs_cpx_trans … HT02 (L.ⓓV1) ?)
52     /4 width=5 by lpxs_pair, cpxs_trans, cpxs_strap1, ex3_2_intro, or_introl/
53   | #T2 #HT20 #HTU2 #Hp -V0
54     elim (cpx_lifts_sn … HTU2 (Ⓣ) … (L.ⓓV1) … HT20) -T2 [| /3 width=3 by drops_refl, drops_drop/ ] #U0 #HU20 #HTU0
55     /4 width=3 by cpxs_strap1, ex3_intro, or_intror/
56   ]
57 | #U1 #HTU1 #HU01 #Hp
58   elim (cpx_lifts_sn … HU02 (Ⓣ) … (L.ⓓV1) … HU01) -U0 [| /3 width=3 by drops_refl, drops_drop/ ] #U #HU2 #HU1
59   /4 width=3 by cpxs_strap1, ex3_intro, or_intror/
60 ]
61 qed-.