X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fbasic_2%2Fi_dynamic%2Fntas_nta.ma;h=17259cb17e45bb9403c73526ecde7f95be0ba517;hb=ba7b8553850e4a33cf8607b07758392230d9ed40;hp=7374d2df420897f58a96962a2874aa50d864b45c;hpb=c0d38a82464481e3c8fd68e4b00d7b9b448df462;p=helm.git diff --git a/matita/matita/contribs/lambdadelta/basic_2/i_dynamic/ntas_nta.ma b/matita/matita/contribs/lambdadelta/basic_2/i_dynamic/ntas_nta.ma index 7374d2df4..17259cb17 100644 --- a/matita/matita/contribs/lambdadelta/basic_2/i_dynamic/ntas_nta.ma +++ b/matita/matita/contribs/lambdadelta/basic_2/i_dynamic/ntas_nta.ma @@ -12,11 +12,68 @@ (* *) (**************************************************************************) -include "basic_2/dynamic/nta.ma". -include "basic_2/i_dynamic/ntas.ma". +include "basic_2/dynamic/nta_preserve.ma". +include "basic_2/i_dynamic/ntas_preserve.ma". (* ITERATED NATIVE TYPE ASSIGNMENT FOR TERMS ********************************) +(* Properties with native type assignment for terms *************************) + +lemma nta_ntas (h) (a) (G) (L): + ∀T,U. ⦃G,L⦄ ⊢ T :[h,a] U → ⦃G,L⦄ ⊢ T :*[h,a,1] U. +#h #a #G #L #T #U #H +elim (cnv_inv_cast … H) -H /2 width=3 by ntas_intro/ +qed-. + +(* Inversion lemmas with native type assignment for terms *******************) + +lemma ntas_inv_nta (h) (a) (G) (L): + ∀T,U. ⦃G,L⦄ ⊢ T :*[h,a,1] U → ⦃G,L⦄ ⊢ T :[h,a] U. +#h #a #G #L #T #U +* /2 width=3 by cnv_cast/ +qed-. + +(* Note: this follows from ntas_inv_appl_sn *) +lemma nta_inv_appl_sn_ntas (h) (a) (G) (L) (V) (T): + ∀X. ⦃G,L⦄ ⊢ ⓐV.T :[h,a] X → + ∨∨ ∃∃p,W,U,U0. ad a 0 & ⦃G,L⦄ ⊢ V :[h,a] W & ⦃G,L⦄ ⊢ T :*[h,a,0] ⓛ{p}W.U0 & ⦃G,L.ⓛW⦄ ⊢ U0 :[h,a] U & ⦃G,L⦄ ⊢ ⓐV.ⓛ{p}W.U ⬌*[h] X & ⦃G,L⦄ ⊢ X ![h,a] + | ∃∃n,p,W,U,U0. ad a (↑n) & ⦃G,L⦄ ⊢ V :[h,a] W & ⦃G,L⦄ ⊢ T :[h,a] U & ⦃G,L⦄ ⊢ U :*[h,a,n] ⓛ{p}W.U0 & ⦃G,L⦄ ⊢ ⓐV.U ⬌*[h] X & ⦃G,L⦄ ⊢ X ![h,a]. +#h #a #G #L #V #T #X #H +(* +lapply (nta_ntas … H) -H #H +elim (ntas_inv_appl_sn … H) -H * #n #p #W #U #U0 #Hn #Ha #HVW #HTU #HU #HUX #HX +[ elim (eq_or_gt n) #H destruct + [ (plus_minus_m_m_commutative … Hn) in HTU0; #H + elim (cpms_inv_plus … H) -H #U #HTU #HU0 + lapply (cpms_appl_dx … V V … HTU) [ // ] #H + elim (cnv_cpms_conf … HVT … HTX0 … H) -HVT -HTX0 -H