X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fbasic_2%2Frt_conversion%2Fcpce_drops.ma;h=985f9f8f4e7cc98d1aa0c857de43e775449a9f8c;hb=89fc31fc5cc01e8860cf67a8e096c24125370d31;hp=49bf1e88567369b3f0ddc29ccca205b3bf020fca;hpb=db020b4218272e2e35641ce3bc3b0a9b3afda899;p=helm.git diff --git a/matita/matita/contribs/lambdadelta/basic_2/rt_conversion/cpce_drops.ma b/matita/matita/contribs/lambdadelta/basic_2/rt_conversion/cpce_drops.ma index 49bf1e885..985f9f8f4 100644 --- a/matita/matita/contribs/lambdadelta/basic_2/rt_conversion/cpce_drops.ma +++ b/matita/matita/contribs/lambdadelta/basic_2/rt_conversion/cpce_drops.ma @@ -13,6 +13,7 @@ (**************************************************************************) include "static_2/relocation/drops.ma". +include "static_2/relocation/lifts_lifts.ma". include "basic_2/rt_conversion/cpce.ma". (* CONTEXT-SENSITIVE PARALLEL ETA-CONVERSION FOR TERMS **********************) @@ -22,8 +23,8 @@ include "basic_2/rt_conversion/cpce.ma". lemma cpce_eta_drops (h) (n) (G) (K): ∀p,W,V1,U. ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V1.U → ∀V2. ⦃G,K⦄ ⊢ V1 ⬌η[h] V2 → - ∀i,L. ⬇*[i] L ≘ K.ⓛW → - ∀W2. ⬆*[↑i] V2 ≘ W2 → ⦃G,L⦄ ⊢ #i ⬌η[h] +ⓛW2.ⓐ#0.#↑i. + ∀i,L. ⇩*[i] L ≘ K.ⓛW → + ∀W2. ⇧*[↑i] V2 ≘ W2 → ⦃G,L⦄ ⊢ #i ⬌η[h] +ⓛW2.ⓐ#0.#↑i. #h #n #G #K #p #W #V1 #U #HWU #V2 #HV12 #i elim i -i [ #L #HLK #W2 #HVW2 >(drops_fwd_isid … HLK) -L [| // ] /2 width=8 by cpce_eta/ @@ -35,7 +36,7 @@ lemma cpce_eta_drops (h) (n) (G) (K): qed. lemma cpce_zero_drops (h) (G): - ∀i,L. (∀n,p,K,W,V,U. ⬇*[i] L ≘ K.ⓛW → ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V.U → ⊥) → + ∀i,L. (∀n,p,K,W,V,U. ⇩*[i] L ≘ K.ⓛW → ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V.U → ⊥) → ⦃G,L⦄ ⊢ #i ⬌η[h] #i. #h #G #i elim i -i [ * [ #_ // ] #L #I #Hi @@ -44,3 +45,46 @@ lemma cpce_zero_drops (h) (G): /5 width=8 by cpce_lref, drops_drop/ ] qed. + +(* Inversion lemmas with uniform slicing for local environments *************) + +lemma cpce_inv_lref_sn_drops (h) (G) (i) (L): + ∀X2. ⦃G,L⦄ ⊢ #i ⬌η[h] X2 → + ∀I,K. ⇩*[i] L ≘ K.ⓘ{I} → + ∨∨ ∧∧ ∀n,p,W,V,U. I = BPair Abst W → ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V.U → ⊥ & #i = X2 + | ∃∃n,p,W,V1,V2,W2,U. ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V1.U & ⦃G,K⦄ ⊢ V1 ⬌η[h] V2 + & ⇧*[↑i] V2 ≘ W2 & I = BPair Abst W & +ⓛW2.ⓐ#0.#(↑i) = X2. +#h #G #i elim i -i +[ #L #X2 #HX2 #I #K #HLK + lapply (drops_fwd_isid … HLK ?) -HLK [ // ] #H destruct + /2 width=1 by cpce_inv_zero_sn/ +| #i #IH #L0 #X0 #HX0 #J #K #H0 + elim (drops_inv_succ … H0) -H0 #I #L #HLK #H destruct + elim (cpce_inv_lref_sn … HX0) -HX0 #X2 #HX2 #HX20 + elim (IH … HX2 … HLK) -IH -I -L * + [ #HJ #H destruct + lapply (lifts_inv_lref1_uni … HX20) -HX20 #H destruct + /4 width=7 by or_introl, conj/ + | #n #p #W #V1 #V2 #W2 #U #HWU #HV12 #HVW2 #H1 #H2 destruct + elim (lifts_inv_bind1 … HX20) -HX20 #X2 #X #HWX2 #HX #H destruct + elim (lifts_inv_flat1 … HX) -HX #X0 #X1 #H0 #H1 #H destruct + lapply (lifts_inv_push_zero_sn … H0) -H0 #H destruct + elim (lifts_inv_push_succ_sn … H1) -H1 #j #Hj #H destruct + lapply (lifts_inv_lref1_uni … Hj) -Hj #H destruct + /4 width=12 by lifts_trans_uni, ex5_7_intro, or_intror/ + ] +] +qed-. + +lemma cpce_inv_zero_sn_drops (h) (G) (i) (L): + ∀X2. ⦃G,L⦄ ⊢ #i ⬌η[h] X2 → + ∀I,K. ⇩*[i] L ≘ K.ⓘ{I} → + (∀n,p,W,V,U. I = BPair Abst W → ⦃G,K⦄ ⊢ W ➡*[n,h] ⓛ{p}V.U → ⊥) → + #i = X2. +#h #G #i #L #X2 #HX2 #I #K #HLK #HI +elim (cpce_inv_lref_sn_drops … HX2 … HLK) -L * +[ #_ #H // +| #n #p #W #V1 #V2 #W2 #U #HWU #_ #_ #H destruct + elim (HI … HWU) -n -p -K -X2 -V1 -V2 -W2 -U -i // +] +qed-.