]> matita.cs.unibo.it Git - helm.git/blobdiff - matita/matita/contribs/lambdadelta/basic_2/dynamic/lsubsv_snv.ma
update in basic_2 and ground_2
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / dynamic / lsubsv_snv.ma
index 89687537170512bfddf5e2c43d969a4b2161994f..365849c366c86c8d2953b276652d934ed5dfce23 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/computation/dxprs_dxprs.ma".
-include "basic_2/dynamic/lsubsv_ldrop.ma".
-include "basic_2/dynamic/lsubsv_dxprs.ma".
-include "basic_2/dynamic/lsubsv_cpcs.ma".
+include "basic_2/dynamic/lsubsv_scpds.ma".
 
 (* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE VALIDITY **************)
 
 (* Properties concerning stratified native validity *************************)
 
-fact snv_lsubsv_aux: ∀h,g,L0,T0.
-                     (∀L1,T1. h ⊢ ⦃L0, T0⦄ >[g] ⦃L1, T1⦄ → IH_snv_cpr_lpr h g L1 T1) →
-                     (∀L1,T1. h ⊢ ⦃L0, T0⦄ >[g] ⦃L1, T1⦄ → IH_ssta_cpr_lpr h g L1 T1) →
-                     (∀L1,T1. h ⊢ ⦃L0, T0⦄ >[g] ⦃L1, T1⦄ → IH_snv_ssta h g L1 T1) →
-                     (∀L1,T1. h ⊢ ⦃L0, T0⦄ >[g] ⦃L1, T1⦄ → IH_snv_lsubsv h g L1 T1) →
-                     ∀L1,T1. L0 = L1 → T0 = T1 → IH_snv_lsubsv h g L1 T1.
-#h #g #L0 #T0 #IH4 #IH3 #IH2 #IH1 #L2 * * [||||*] //
-[ #i #HL0 #HT0 #H #L1 #HL12 destruct -IH4 -IH3 -IH2
-  elim (snv_inv_lref … H) -H #I2 #K2 #W2 #HLK2 #HW2
-  elim (lsubsv_ldrop_O1_trans … HL12 … HLK2) -HL12 #X #H #HLK1
-  lapply (ldrop_pair2_fwd_fw … HLK2 (#i)) -HLK2 #HLK2
+lemma lsubsv_snv_trans: ∀h,o,G,L2,T. ⦃G, L2⦄ ⊢ T ¡[h, o] →
+                        ∀L1. G ⊢ L1 ⫃¡[h, o] L2 → ⦃G, L1⦄ ⊢ T ¡[h, o].
+#h #o #G #L2 #T #H elim H -G -L2 -T //
+[ #I #G #L2 #K2 #V #i #HLK2 #_ #IHV #L1 #HL12
+  elim (lsubsv_drop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
   elim (lsubsv_inv_pair2 … H) -H * #K1
-  [ #HK12 #H destruct /4 width=8 by snv_lref, fw_ygt/ (**) (* auto too slow without trace *)
-  | #W1 #V1 #V2 #l #HV1 #_ #_ #_ #_ #_ #H #_ destruct /2 width=5/
+  [ #HK12 #H destruct /3 width=5 by snv_lref/
+  | #W #d #HVW #_ #_ #_ #_ #H1 #H2 destruct -IHV
+    /3 width=6 by shnv_inv_snv, snv_lref/
   ]
-| #p #HL0 #HT0 #H #L1 #HL12 destruct -IH4 -IH3 -IH2 -IH1
-  elim (snv_inv_gref … H)
-| #a #I #V #T #HL0 #HT0 #H #L1 #HL12 destruct -IH4 -IH3 -IH2
-  elim (snv_inv_bind … H) -H /4 width=4/
-| #V #T #HL0 #HT0 #H #L1 #HL12 destruct
-  elim (snv_inv_appl … H) -H #a #W #W0 #U #l #HV #HT #HVW #HW0 #HTU
-  lapply (lsubsv_cprs_trans … HL12 … HW0) -HW0 #HW0
-  elim (lsubsv_ssta_trans … HVW … HL12) -HVW #W1 #HVW1 #HW1
-  lapply (cpcs_cprs_strap1 … HW1 … HW0) -W #HW10
-  elim (lsubsv_dxprs_aux … IH4 IH3 IH2 IH1 … HL12 … HTU) -IH4 -IH3 -IH2 -HTU // /2 width=1/ #X #HTU #H
-  elim (cprs_fwd_abst1 … H Abst W0) -H #W #U2 #HW0 #HU2 #H destruct
-  lapply (cpcs_cprs_strap1 … HW10 … HW0) -W0 #H
-  elim (cpcs_inv_cprs … H) -H #W0 #HW10 #HW0
-  lapply (dxprs_cprs_trans … (ⓛ{a}W0.U2) HTU ?) [ /2 width=1/ ] -HTU -HW0
-  /4 width=8 by snv_appl, fw_ygt/ (**) (* auto too slow without trace *)
-| #W #T #HL0 #HT0 #H #L1 #HL12 destruct -IH4 -IH3 -IH2
-  elim (snv_inv_cast … H) -H #U #l #HW #HT #HTU #HUW
-  lapply (lsubsv_cpcs_trans … HL12 … HUW) -HUW #HUW
-  elim (lsubsv_ssta_trans … HTU … HL12) -HTU #U0 #HTU0 #HU0
-  lapply (cpcs_trans … HU0 … HUW) -U /4 width=4 by snv_cast, fw_ygt/ (**) (* auto too slow without trace *)
+| #a #I #G #L2 #V #T #_ #_ #IHV #IHT #L1 #HL12 destruct
+  /4 width=1 by snv_bind, lsubsv_pair/
+| #a #G #L2 #V #W0 #T #U0 #d #_ #_ #HVW0 #HTU0 #IHV #IHT #L1 #HL12
+  elim (lsubsv_scpds_trans … HVW0 … HL12) -HVW0 #V0 #HV0 #HWV0
+  elim (lsubsv_scpds_trans … HTU0 … HL12) -HTU0 #X #HT0 #H
+  elim (cprs_inv_abst1 … H) -H #W #T0 #HW0 #_ #H destruct
+  elim (cprs_conf … HWV0 … HW0) -W0
+  /4 width=10 by snv_appl, scpds_cprs_trans, cprs_bind/
+| #G #L2 #U #T #U0 #_ #_ #HU0 #HTU0 #IHU #IHT #L1 #HL12
+  elim (lsubsv_scpds_trans … HTU0 … HL12) -HTU0 #X0 #HTX0 #H1
+  elim (lsubsv_scpds_trans … HU0 … HL12) -HU0 #X #HUX #H2
+  elim (cprs_conf … H1 … H2) -U0 /3 width=5 by snv_cast, scpds_cprs_trans/
 ]
 qed-.