X-Git-Url: http://matita.cs.unibo.it/gitweb/?p=helm.git;a=blobdiff_plain;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fbasic_2%2Frt_computation%2Fcpms_drops.ma;h=894ece04c1f3e937f03201044a5465133b84d33c;hp=f98626953f8dbe51980fc44de7c85f953a53fa79;hb=bd53c4e895203eb049e75434f638f26b5a161a2b;hpb=3b7b8afcb429a60d716d5226a5b6ab0d003228b1 diff --git a/matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpms_drops.ma b/matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpms_drops.ma index f98626953..894ece04c 100644 --- a/matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpms_drops.ma +++ b/matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpms_drops.ma @@ -46,40 +46,40 @@ qed-. (* Advanced properties ******************************************************) -lemma cpms_delta (n) (h) (G): ∀K,V1,V2. ⦃G,K⦄ ⊢ V1 ➡*[n,h] V2 → - ∀W2. ⇧*[1] V2 ≘ W2 → ⦃G,K.ⓓV1⦄ ⊢ #0 ➡*[n,h] W2. +lemma cpms_delta (n) (h) (G): ∀K,V1,V2. ❪G,K❫ ⊢ V1 ➡*[n,h] V2 → + ∀W2. ⇧*[1] V2 ≘ W2 → ❪G,K.ⓓV1❫ ⊢ #0 ➡*[n,h] W2. #n #h #G #K #V1 #V2 #H @(cpms_ind_dx … H) -V2 [ /3 width=3 by cpm_cpms, cpm_delta/ | #n1 #n2 #V #V2 #_ #IH #HV2 #W2 #HVW2 - elim (lifts_total V (𝐔❴1❵)) #W #HVW + elim (lifts_total V (𝐔❨1❩)) #W #HVW /5 width=11 by cpms_step_dx, cpm_lifts_bi, drops_refl, drops_drop/ ] qed. -lemma cpms_ell (n) (h) (G): ∀K,V1,V2. ⦃G,K⦄ ⊢ V1 ➡*[n,h] V2 → - ∀W2. ⇧*[1] V2 ≘ W2 → ⦃G,K.ⓛV1⦄ ⊢ #0 ➡*[↑n,h] W2. +lemma cpms_ell (n) (h) (G): ∀K,V1,V2. ❪G,K❫ ⊢ V1 ➡*[n,h] V2 → + ∀W2. ⇧*[1] V2 ≘ W2 → ❪G,K.ⓛV1❫ ⊢ #0 ➡*[↑n,h] W2. #n #h #G #K #V1 #V2 #H @(cpms_ind_dx … H) -V2 [ /3 width=3 by cpm_cpms, cpm_ell/ | #n1 #n2 #V #V2 #_ #IH #HV2 #W2 #HVW2 - elim (lifts_total V (𝐔❴1❵)) #W #HVW >plus_S1 + elim (lifts_total V (𝐔❨1❩)) #W #HVW >plus_S1 /5 width=11 by cpms_step_dx, cpm_lifts_bi, drops_refl, drops_drop/ ] qed. -lemma cpms_lref (n) (h) (I) (G): ∀K,T,i. ⦃G,K⦄ ⊢ #i ➡*[n,h] T → - ∀U. ⇧*[1] T ≘ U → ⦃G,K.ⓘ{I}⦄ ⊢ #↑i ➡*[n,h] U. +lemma cpms_lref (n) (h) (I) (G): ∀K,T,i. ❪G,K❫ ⊢ #i ➡*[n,h] T → + ∀U. ⇧*[1] T ≘ U → ❪G,K.ⓘ[I]❫ ⊢ #↑i ➡*[n,h] U. #n #h #I #G #K #T #i #H @(cpms_ind_dx … H) -T [ /3 width=3 by cpm_cpms, cpm_lref/ | #n1 #n2 #T #T2 #_ #IH #HT2 #U2 #HTU2 - elim (lifts_total T (𝐔❴1❵)) #U #TU + elim (lifts_total T (𝐔❨1❩)) #U #TU /5 width=11 by cpms_step_dx, cpm_lifts_bi, drops_refl, drops_drop/ ] qed. lemma cpms_cast_sn (n) (h) (G) (L): - ∀U1,U2. ⦃G,L⦄ ⊢ U1 ➡*[n,h] U2 → - ∀T1,T2. ⦃G,L⦄ ⊢ T1 ➡[n,h] T2 → - ⦃G,L⦄ ⊢ ⓝU1.T1 ➡*[n,h] ⓝU2.T2. + ∀U1,U2. ❪G,L❫ ⊢ U1 ➡*[n,h] U2 → + ∀T1,T2. ❪G,L❫ ⊢ T1 ➡[n,h] T2 → + ❪G,L❫ ⊢ ⓝU1.T1 ➡*[n,h] ⓝU2.T2. #n #h #G #L #U1 #U2 #H @(cpms_ind_sn … H) -U1 -n [ /3 width=3 by cpm_cpms, cpm_cast/ | #n1 #n2 #U1 #U #HU1 #_ #IH #T1 #T2 #H @@ -92,26 +92,26 @@ qed. (* Basic_2A1: uses: cprs_delta *) lemma cpms_delta_drops (n) (h) (G): ∀L,K,V,i. ⇩*[i] L ≘ K.ⓓV → - ∀V2. ⦃G,K⦄ ⊢ V ➡*[n,h] V2 → - ∀W2. ⇧*[↑i] V2 ≘ W2 → ⦃G,L⦄ ⊢ #i ➡*[n,h] W2. + ∀V2. ❪G,K❫ ⊢ V ➡*[n,h] V2 → + ∀W2. ⇧*[↑i] V2 ≘ W2 → ❪G,L❫ ⊢ #i ➡*[n,h] W2. #n #h #G #L #K #V #i #HLK #V2 #H @(cpms_ind_dx … H) -V2 [ /3 width=6 by cpm_cpms, cpm_delta_drops/ | #n1 #n2 #V1 #V2 #_ #IH #HV12 #W2 #HVW2 lapply (drops_isuni_fwd_drop2 … HLK) -HLK // #HLK - elim (lifts_total V1 (𝐔❴↑i❵)) #W1 #HVW1 + elim (lifts_total V1 (𝐔❨↑i❩)) #W1 #HVW1 /3 width=11 by cpm_lifts_bi, cpms_step_dx/ ] qed. lemma cpms_ell_drops (n) (h) (G): ∀L,K,W,i. ⇩*[i] L ≘ K.ⓛW → - ∀W2. ⦃G,K⦄ ⊢ W ➡*[n,h] W2 → - ∀V2. ⇧*[↑i] W2 ≘ V2 → ⦃G,L⦄ ⊢ #i ➡*[↑n,h] V2. + ∀W2. ❪G,K❫ ⊢ W ➡*[n,h] W2 → + ∀V2. ⇧*[↑i] W2 ≘ V2 → ❪G,L❫ ⊢ #i ➡*[↑n,h] V2. #n #h #G #L #K #W #i #HLK #W2 #H @(cpms_ind_dx … H) -W2 [ /3 width=6 by cpm_cpms, cpm_ell_drops/ | #n1 #n2 #W1 #W2 #_ #IH #HW12 #V2 #HWV2 lapply (drops_isuni_fwd_drop2 … HLK) -HLK // #HLK - elim (lifts_total W1 (𝐔❴↑i❵)) #V1 #HWV1 >plus_S1 + elim (lifts_total W1 (𝐔❨↑i❩)) #V1 #HWV1 >plus_S1 /3 width=11 by cpm_lifts_bi, cpms_step_dx/ ] qed. @@ -119,11 +119,11 @@ qed. (* Advanced inversion lemmas ************************************************) lemma cpms_inv_lref1_drops (n) (h) (G): - ∀L,T2,i. ⦃G,L⦄ ⊢ #i ➡*[n,h] T2 → + ∀L,T2,i. ❪G,L❫ ⊢ #i ➡*[n,h] T2 → ∨∨ ∧∧ T2 = #i & n = 0 - | ∃∃K,V,V2. ⇩*[i] L ≘ K.ⓓV & ⦃G,K⦄ ⊢ V ➡*[n,h] V2 & + | ∃∃K,V,V2. ⇩*[i] L ≘ K.ⓓV & ❪G,K❫ ⊢ V ➡*[n,h] V2 & ⇧*[↑i] V2 ≘ T2 - | ∃∃m,K,V,V2. ⇩*[i] L ≘ K.ⓛV & ⦃G,K⦄ ⊢ V ➡*[m,h] V2 & + | ∃∃m,K,V,V2. ⇩*[i] L ≘ K.ⓛV & ❪G,K❫ ⊢ V ➡*[m,h] V2 & ⇧*[↑i] V2 ≘ T2 & n = ↑m. #n #h #G #L #T2 #i #H @(cpms_ind_dx … H) -T2 [ /3 width=1 by or3_intro0, conj/ @@ -147,9 +147,9 @@ lemma cpms_inv_lref1_drops (n) (h) (G): qed-. lemma cpms_inv_delta_sn (n) (h) (G) (K) (V): - ∀T2. ⦃G,K.ⓓV⦄ ⊢ #0 ➡*[n,h] T2 → + ∀T2. ❪G,K.ⓓV❫ ⊢ #0 ➡*[n,h] T2 → ∨∨ ∧∧ T2 = #0 & n = 0 - | ∃∃V2. ⦃G,K⦄ ⊢ V ➡*[n,h] V2 & ⇧*[1] V2 ≘ T2. + | ∃∃V2. ❪G,K❫ ⊢ V ➡*[n,h] V2 & ⇧*[1] V2 ≘ T2. #n #h #G #K #V #T2 #H elim (cpms_inv_lref1_drops … H) -H * [ /3 width=1 by or_introl, conj/ @@ -162,9 +162,9 @@ elim (cpms_inv_lref1_drops … H) -H * qed-. lemma cpms_inv_ell_sn (n) (h) (G) (K) (V): - ∀T2. ⦃G,K.ⓛV⦄ ⊢ #0 ➡*[n,h] T2 → + ∀T2. ❪G,K.ⓛV❫ ⊢ #0 ➡*[n,h] T2 → ∨∨ ∧∧ T2 = #0 & n = 0 - | ∃∃m,V2. ⦃G,K⦄ ⊢ V ➡*[m,h] V2 & ⇧*[1] V2 ≘ T2 & n = ↑m. + | ∃∃m,V2. ❪G,K❫ ⊢ V ➡*[m,h] V2 & ⇧*[1] V2 ≘ T2 & n = ↑m. #n #h #G #K #V #T2 #H elim (cpms_inv_lref1_drops … H) -H * [ /3 width=1 by or_introl, conj/ @@ -177,28 +177,28 @@ elim (cpms_inv_lref1_drops … H) -H * qed-. lemma cpms_inv_lref_sn (n) (h) (G) (I) (K): - ∀U2,i. ⦃G,K.ⓘ{I}⦄ ⊢ #↑i ➡*[n,h] U2 → + ∀U2,i. ❪G,K.ⓘ[I]❫ ⊢ #↑i ➡*[n,h] U2 → ∨∨ ∧∧ U2 = #↑i & n = 0 - | ∃∃T2. ⦃G,K⦄ ⊢ #i ➡*[n,h] T2 & ⇧*[1] T2 ≘ U2. + | ∃∃T2. ❪G,K❫ ⊢ #i ➡*[n,h] T2 & ⇧*[1] T2 ≘ U2. #n #h #G #I #K #U2 #i #H elim (cpms_inv_lref1_drops … H) -H * [ /3 width=1 by or_introl, conj/ | #L #V #V2 #H #HV2 #HVU2 lapply (drops_inv_drop1 … H) -H #HLK - elim (lifts_split_trans … HVU2 (𝐔❴↑i❵) (𝐔❴1❵)) -HVU2 + elim (lifts_split_trans … HVU2 (𝐔❨↑i❩) (𝐔❨1❩)) -HVU2 [| // ] #T2 #HVT2 #HTU2 /4 width=6 by cpms_delta_drops, ex2_intro, or_intror/ | #m #L #V #V2 #H #HV2 #HVU2 #H0 destruct lapply (drops_inv_drop1 … H) -H #HLK - elim (lifts_split_trans … HVU2 (𝐔❴↑i❵) (𝐔❴1❵)) -HVU2 + elim (lifts_split_trans … HVU2 (𝐔❨↑i❩) (𝐔❨1❩)) -HVU2 [| // ] #T2 #HVT2 #HTU2 /4 width=6 by cpms_ell_drops, ex2_intro, or_intror/ ] qed-. fact cpms_inv_succ_sn (n) (h) (G) (L): - ∀T1,T2. ⦃G,L⦄ ⊢ T1 ➡*[↑n,h] T2 → - ∃∃T. ⦃G,L⦄ ⊢ T1 ➡*[1,h] T & ⦃G,L⦄ ⊢ T ➡*[n,h] T2. + ∀T1,T2. ❪G,L❫ ⊢ T1 ➡*[↑n,h] T2 → + ∃∃T. ❪G,L❫ ⊢ T1 ➡*[1,h] T & ❪G,L❫ ⊢ T ➡*[n,h] T2. #n #h #G #L #T1 #T2 @(insert_eq_0 … (↑n)) #m #H @(cpms_ind_sn … H) -T1 -m