]> matita.cs.unibo.it Git - helm.git/commitdiff
- advances in the theory of cofrees
authorFerruccio Guidi <ferruccio.guidi@unibo.it>
Fri, 25 Apr 2014 12:12:05 +0000 (12:12 +0000)
committerFerruccio Guidi <ferruccio.guidi@unibo.it>
Fri, 25 Apr 2014 12:12:05 +0000 (12:12 +0000)
- some notational changes
- some refactoring in etc

91 files changed:
matita/matita/contribs/lambdadelta/basic_2/computation/cpxs_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/csx_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbc.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbc_fleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbc_fpbs.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbg.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbg_fleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbg_fpbg.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbg_lift.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbs.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbs_alt.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbs_fleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbu.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbu_fleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fpbu_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fsb_aaa.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fsb_alt.ma
matita/matita/contribs/lambdadelta/basic_2/computation/fsb_csx.ma
matita/matita/contribs/lambdadelta/basic_2/computation/lpxs_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/computation/lsx.ma
matita/matita/contribs/lambdadelta/basic_2/computation/lsx_alt.ma
matita/matita/contribs/lambdadelta/basic_2/computation/lsx_lpx.ma
matita/matita/contribs/lambdadelta/basic_2/dynamic/snv_cpcs.ma
matita/matita/contribs/lambdadelta/basic_2/dynamic/snv_da_lpr.ma
matita/matita/contribs/lambdadelta/basic_2/dynamic/snv_lpr.ma
matita/matita/contribs/lambdadelta/basic_2/dynamic/snv_lsstas.ma
matita/matita/contribs/lambdadelta/basic_2/dynamic/snv_lsstas_lpr.ma
matita/matita/contribs/lambdadelta/basic_2/etc/cpx_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpxs_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpy.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lpx_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lsuby.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lazyeqalt_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ext.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_fqus.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/llor.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn_alt2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llor.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpx_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpxs_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lazyeqalt_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ext.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_fqus.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lpx_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_3.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_4.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazybtpredproper_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazybtpredstarproper_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyeq_4.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyeq_7.ma
matita/matita/contribs/lambdadelta/basic_2/reduction/cpr_llpx_sn.ma
matita/matita/contribs/lambdadelta/basic_2/reduction/cpx_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/reduction/cpx_llpx_sn.ma
matita/matita/contribs/lambdadelta/basic_2/reduction/fpb.ma
matita/matita/contribs/lambdadelta/basic_2/reduction/lpx_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_alt.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_ldrop.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_leq.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_lpx_sn.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_tc.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/static/aaa_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/static/ssta_llpx_sn.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/cofrees.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/cpys_lift.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/fleq.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/fleq_fleq.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq_alt.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq_fqus.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq_ldrop.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq_leq.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/lleq_lleq.ma
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_alt1.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_ldrop.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_leq.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_lpx_sn.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_tc.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/web/basic_2_src.tbl

index ce575a47b6d7c1b7504f348191b8a0c61ed58c47..2bcff48e41f9cdfc594fdd1694cecc0df551ba8d 100644 (file)
@@ -20,20 +20,20 @@ include "basic_2/computation/cpxs.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 lemma lleq_cpxs_trans: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡*[h, g] T2 →
-                       â\88\80L1. L1 â\8b\95[T1, 0] L2 → ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2.
+                       â\88\80L1. L1 â\89¡[T1, 0] L2 → ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2.
 #h #g #G #L2 #T1 #T2 #H @(cpxs_ind_dx … H) -T1
 /4 width=6 by cpx_lleq_conf_dx, lleq_cpx_trans, cpxs_strap2/
 qed-.
 
 lemma cpxs_lleq_conf: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡*[h, g] T2 →
-                      â\88\80L1. L2 â\8b\95[T1, 0] L1 → ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2.
+                      â\88\80L1. L2 â\89¡[T1, 0] L1 → ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2.
 /3 width=3 by lleq_cpxs_trans, lleq_sym/ qed-.
 
 lemma cpxs_lleq_conf_dx: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡*[h, g] T2 →
-                         â\88\80L1. L1 â\8b\95[T1, 0] L2 â\86\92 L1 â\8b\95[T2, 0] L2.
+                         â\88\80L1. L1 â\89¡[T1, 0] L2 â\86\92 L1 â\89¡[T2, 0] L2.
 #h #g #G #L2 #T1 #T2 #H @(cpxs_ind … H) -T2 /3 width=6 by cpx_lleq_conf_dx/
 qed-.
 
 lemma cpxs_lleq_conf_sn: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 →
-                         â\88\80L2. L1 â\8b\95[T1, 0] L2 â\86\92 L1 â\8b\95[T2, 0] L2.
+                         â\88\80L2. L1 â\89¡[T1, 0] L2 â\86\92 L1 â\89¡[T2, 0] L2.
 /4 width=6 by cpxs_lleq_conf_dx, lleq_sym/ qed-.
index d56acd9df2bf21a29b132e4d94e1d6f6fa5b27f4..765861e3bf61dac1d41a1d53918d34908b7d9e85 100644 (file)
@@ -20,11 +20,11 @@ include "basic_2/computation/csx.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 lemma csx_lleq_conf: ∀h,g,G,L1,T. ⦃G, L1⦄ ⊢ ⬊*[h, g] T →
-                     â\88\80L2. L1 â\8b\95[T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
+                     â\88\80L2. L1 â\89¡[T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
 #h #g #G #L1 #T #H @(csx_ind … H) -T
 /4 width=6 by csx_intro, cpx_lleq_conf_dx, lleq_cpx_trans/
 qed-.
 
 lemma csx_lleq_trans: ∀h,g,G,L1,L2,T.
-                      L1 â\8b\95[T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T → ⦃G, L1⦄ ⊢ ⬊*[h, g] T.
+                      L1 â\89¡[T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T → ⦃G, L1⦄ ⊢ ⬊*[h, g] T.
 /3 width=3 by csx_lleq_conf, lleq_sym/ qed-.
index bf9baaa90c50ddd87d86f801a0eeb3278807fb87..82ea6ec0f5c0c1bc9b77b6b331888ca2ba6fd8f1 100644 (file)
@@ -20,7 +20,7 @@ include "basic_2/computation/fpbu.ma".
 
 definition fpbc: ∀h. sd h → tri_relation genv lenv term ≝
                  λh,g,G1,L1,T1,G2,L2,T2.
-                 â\88\83â\88\83G,L,T. â¦\83G1, L1, T1â¦\84 â\89»[h, g] â¦\83G, L, Tâ¦\84 & â¦\83G, L, Tâ¦\84 â\8b\95[0] ⦃G2, L2, T2⦄.
+                 â\88\83â\88\83G,L,T. â¦\83G1, L1, T1â¦\84 â\89»[h, g] â¦\83G, L, Tâ¦\84 & â¦\83G, L, Tâ¦\84 â\89¡[0] ⦃G2, L2, T2⦄.
 
 interpretation
    "single-step 'big tree' proper parallel reduction (closure)"
@@ -29,5 +29,5 @@ interpretation
 (* Baic properties **********************************************************)
 
 lemma fpbu_fpbc: ∀h,g,G1,G2,L1,L2,T1,T2.
-                 â¦\83G1, L1, T1â¦\84 â\89»[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                 â¦\83G1, L1, T1â¦\84 â\89»[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄.
 /2 width=5 by ex2_3_intro/ qed.
index 9056ca4c77074a20ff258fd295b8098e94ea1d1b..cf2ee2ffc8a9d3d26c20dac63e2e6214c26a297b 100644 (file)
@@ -20,14 +20,14 @@ include "basic_2/computation/fpbc.ma".
 
 (* Properties on lazy equivalence on closures *******************************)
 
-lemma fpbc_fleq_trans: â\88\80h,g,G1,G,G2,L1,L,L2,T1,T,T2. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G, L, T⦄ →
-                       â¦\83G, L, Tâ¦\84 â\8b\95[0] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fpbc_fleq_trans: â\88\80h,g,G1,G,G2,L1,L,L2,T1,T,T2. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G, L, T⦄ →
+                       â¦\83G, L, Tâ¦\84 â\89¡[0] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 *
 /3 width=9 by fleq_trans, ex2_3_intro/
 qed-.
 
-lemma fleq_fpbc_trans: â\88\80h,g,G1,G,G2,L1,L,L2,T1,T,T2. â¦\83G1, L1, T1â¦\84 â\8b\95[0] ⦃G, L, T⦄ →
-                       â¦\83G, L, Tâ¦\84 â\89»â\8b\95[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fleq_fpbc_trans: â\88\80h,g,G1,G,G2,L1,L,L2,T1,T,T2. â¦\83G1, L1, T1â¦\84 â\89¡[0] ⦃G, L, T⦄ →
+                       â¦\83G, L, Tâ¦\84 â\89»â\89¡[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 #H1 *
 #G0 #L0 #T0 #H0 #H02 elim (fleq_fpbu_trans … H1 … H0) -G -L -T
 /3 width=9 by fleq_trans, ex2_3_intro/
index 7d81c812d5214e0c0742461d0ab728b03dd7a83d..2c45646ede54ee7648a284497d945c4e7c043f33 100644 (file)
@@ -20,7 +20,7 @@ include "basic_2/computation/fpbc.ma".
 
 (* Forward lemmas on "big tree" parallel computation for closures ***********)
 
-lemma fpbc_fwd_fpbs: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ →
+lemma fpbc_fwd_fpbs: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ →
                      ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 *
 /3 width=5 by fpbu_fwd_fpbs, fpbs_trans, fleq_fpbs/
index 0755ebf79960759c76b8d4312e356c9b17d042ef..5d7ce1cb342f0b56d17fe9f783c248ef4fce6c10 100644 (file)
@@ -25,38 +25,38 @@ interpretation "general 'big tree' proper parallel computation (closure)"
 
 (* Basic properties *********************************************************)
 
-lemma fpbc_fpbg: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ →
-                 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fpbc_fpbg: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ →
+                 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 /2 width=1 by tri_inj/ qed.
 
 lemma fpbg_strap1: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
-                   â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ →
-                   â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                   â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ →
+                   â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 /2 width=5 by tri_step/ qed.
 
 lemma fpbg_strap2: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
-                   â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ →
-                   â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                   â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ →
+                   â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 /2 width=5 by tri_TC_strap/ qed.
 
 (* Note: this is used in the closure proof *)
-lemma fqup_fpbg: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\8a\90+ â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fqup_fpbg: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 â\8a\90+ â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 /4 width=1 by fpbc_fpbg, fpbu_fpbc, fpbu_fqup/ qed.
 
 (* Basic eliminators ********************************************************)
 
 lemma fpbg_ind: ∀h,g,G1,L1,T1. ∀R:relation3 ….
-                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
-                (â\88\80G,G2,L,L2,T,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
-                â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2.
+                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                (â\88\80G,G2,L,L2,T,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
+                â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2.
 #h #g #G1 #L1 #T1 #R #IH1 #IH2 #G2 #L2 #T2 #H
 @(tri_TC_ind … IH1 IH2 G2 L2 T2 H)
 qed-.
 
 lemma fpbg_ind_dx: ∀h,g,G2,L2,T2. ∀R:relation3 ….
-                   (â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1) →
-                   (â\88\80G1,G,L1,L,T1,T. â¦\83G1, L1, T1â¦\84 â\89»â\8b\95[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
-                   â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1.
+                   (â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1) →
+                   (â\88\80G1,G,L1,L,T1,T. â¦\83G1, L1, T1â¦\84 â\89»â\89¡[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
+                   â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1.
 #h #g #G2 #L2 #T2 #R #IH1 #IH2 #G1 #L1 #T1 #H
 @(tri_TC_ind_dx … IH1 IH2 G1 L1 T1 H)
 qed-.
index bb79f4aab341b387f99820c66e1db82329cda230..293e666d528866c8a6f83a05c3b3b3c8dc8dad93 100644 (file)
@@ -19,16 +19,16 @@ include "basic_2/computation/fpbg.ma".
 
 (* Properties on lazy equivalence for closures ******************************)
 
-lemma fpbg_fleq_trans: â\88\80h,g,G1,G,L1,L,T1,T. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G, L, T⦄ →
-                       â\88\80G2,L2,T2. â¦\83G, L, Tâ¦\84 â\8b\95[0] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fpbg_fleq_trans: â\88\80h,g,G1,G,L1,L,T1,T. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G, L, T⦄ →
+                       â\88\80G2,L2,T2. â¦\83G, L, Tâ¦\84 â\89¡[0] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #L1 #L #T1 #T #H @(fpbg_ind … H) -G -L -T
 [ /3 width=5 by fpbc_fpbg, fpbc_fleq_trans/
 | /4 width=9 by fpbg_strap1, fpbc_fleq_trans/
 ]
 qed-.
 
-lemma fleq_fpbg_trans: â\88\80h,g,G,G2,L,L2,T,T2. â¦\83G, L, Tâ¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ →
-                       â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 â\8b\95[0] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+lemma fleq_fpbg_trans: â\88\80h,g,G,G2,L,L2,T,T2. â¦\83G, L, Tâ¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ →
+                       â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 â\89¡[0] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G #G2 #L #L2 #T #T2 #H @(fpbg_ind_dx … H) -G -L -T
 [ /3 width=5 by fpbc_fpbg, fleq_fpbc_trans/
 | /4 width=9 by fpbg_strap2, fleq_fpbc_trans/
@@ -36,8 +36,8 @@ lemma fleq_fpbg_trans: ∀h,g,G,G2,L,L2,T,T2. ⦃G, L, T⦄ >⋕[h, g] ⦃G2, L2
 qed-.
 
 lemma fpbs_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                 â¦\83G1, L1, T1â¦\84 â\8b\95[0] ⦃G2, L2, T2⦄ ∨
-                 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                 â¦\83G1, L1, T1â¦\84 â\89¡[0] ⦃G2, L2, T2⦄ ∨
+                 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbs_ind … H) -G2 -L2 -T2
 [ /2 width=1 by or_introl/
 | #G #G2 #L #L2 #T #T2 #_ #H2 * #H1 elim (fpb_fpbu … H2) -H2 #H2
@@ -52,27 +52,27 @@ qed-.
 (* Advanced properties ******************************************************)
 
 lemma fpbg_fpb_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
-                      â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                      â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                      â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                      â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 #H1 #H2 elim (fpb_fpbu … H2) -H2
 /3 width=5 by fpbg_fleq_trans, fpbg_strap1, fpbu_fpbc/
 qed-.
 
 
 lemma fpb_fpbg_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
-                      â¦\83G1, L1, T1â¦\84 â\89½[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ →
-                      â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                      â¦\83G1, L1, T1â¦\84 â\89½[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G, L, Tâ¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ →
+                      â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 #H1 elim (fpb_fpbu … H1) -H1
 /3 width=5 by fleq_fpbg_trans, fpbg_strap2, fpbu_fpbc/
 qed-.
 
 lemma fpbs_fpbg_trans: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L, T⦄ →
-                       â\88\80G2,L2,T2. â¦\83G, L, Tâ¦\84 >â\8b\95[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                       â\88\80G2,L2,T2. â¦\83G, L, Tâ¦\84 >â\89¡[h, g] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G #L1 #L #T1 #T #H @(fpbs_ind … H) -G -L -T /3 width=5 by fpb_fpbg_trans/
 qed-.
 
 (* Note: this is used in the closure proof *)
 lemma fpbg_fpbs_trans: ∀h,g,G,G2,L,L2,T,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                       â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄.
+                       â\88\80G1,L1,T1. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄.
 #h #g #G #G2 #L #L2 #T #T2 #H @(fpbs_ind_dx … H) -G -L -T /3 width=5 by fpbg_fpb_trans/
 qed-.
index f423aaecdb067eca8b949de699e6e9208f986f88..1f52880ad8cd8e447a3a14e8d6a721e343bad486 100644 (file)
@@ -19,7 +19,7 @@ include "basic_2/computation/fpbg_fleq.ma".
 
 (* Advanced inversion lemmas ************************************************)
 
-lemma fpbg_inv_fpbu_sn: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ →
+lemma fpbg_inv_fpbu_sn: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ →
                         ∃∃G,L,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ & ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbg_ind_dx … H) -G1 -L1 -T1
 [ #G1 #L1 #T1 * /3 width=5 by fleq_fpbs, ex2_3_intro/
@@ -31,7 +31,7 @@ qed-.
 
 (* Advanced forward lemmas **************************************************)
 
-lemma fpbg_fwd_fpbs: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ →
+lemma fpbg_fwd_fpbs: â\88\80h,g,G1,G2,L1,L2,T1,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ →
                      ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbg_ind … H) -G2 -L2 -T2
 [2: #G #G2 #L #L2 #T #T2 #_ #H2 #IH1 @(fpbs_trans … IH1) -IH1 ] (**) (* full auto fails *)
index 4dd9afb7384ba582fb2736688991378c67dc4512..c67134ee39dc3b46c9d37e30f7112ca1b49434c3 100644 (file)
@@ -20,9 +20,9 @@ include "basic_2/computation/fpbg.ma".
 (* Advanced properties ******************************************************)
 
 lemma lsstas_fpbg: ∀h,g,G,L,T1,T2,l2. ⦃G, L⦄ ⊢ T1 •*[h, g, l2] T2 → (T1 = T2 → ⊥) →
-                   â\88\80l1. l2 â\89¤ l1 â\86\92 â¦\83G, Lâ¦\84 â\8a¢ T1 â\96ª[h, g] l1 â\86\92 â¦\83G, L, T1â¦\84 >â\8b\95[h, g] ⦃G, L, T2⦄.
+                   â\88\80l1. l2 â\89¤ l1 â\86\92 â¦\83G, Lâ¦\84 â\8a¢ T1 â\96ª[h, g] l1 â\86\92 â¦\83G, L, T1â¦\84 >â\89¡[h, g] ⦃G, L, T2⦄.
 /5 width=5 by fpbc_fpbg, fpbu_fpbc, lsstas_fpbu/ qed.
 
 lemma ssta_fpbg: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l+1 →
-                 â¦\83G, Lâ¦\84 â\8a¢ T1 â\80¢[h, g] T2 â\86\92 â¦\83G, L, T1â¦\84 >â\8b\95[h, g] ⦃G, L, T2⦄.
+                 â¦\83G, Lâ¦\84 â\8a¢ T1 â\80¢[h, g] T2 â\86\92 â¦\83G, L, T1â¦\84 >â\89¡[h, g] ⦃G, L, T2⦄.
 /4 width=2 by fpbc_fpbg, fpbu_fpbc, ssta_fpbu/ qed.
index d1ce32de155d8dafba3fb604c1508e8900bdf167..c9f0875e45a999847498d10817ab8a53ef378af1 100644 (file)
@@ -77,7 +77,7 @@ lemma lpxs_fpbs: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 → ⦃G, L1, T
 /3 width=5 by fpb_lpx, fpbs_strap1/
 qed.
 
-lemma lleq_fpbs: â\88\80h,g,G,L1,L2,T. L1 â\8b\95[T, 0] L2 → ⦃G, L1, T⦄ ≥[h, g] ⦃G, L2, T⦄.
+lemma lleq_fpbs: â\88\80h,g,G,L1,L2,T. L1 â\89¡[T, 0] L2 → ⦃G, L1, T⦄ ≥[h, g] ⦃G, L2, T⦄.
 /3 width=1 by fpb_fpbs, fpb_lleq/ qed.
 
 lemma cprs_fpbs: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡* T2 → ⦃G, L, T1⦄ ≥[h, g] ⦃G, L, T2⦄.
@@ -109,7 +109,7 @@ lemma fpbs_lpxs_trans: ∀h,g,G1,G,L1,L,L2,T1,T. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G
 qed-.
 
 lemma fpbs_lleq_trans: ∀h,g,G1,G,L1,L,L2,T1,T. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L, T⦄ →
-                       L â\8b\95[T, 0] L2 → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L2, T⦄.
+                       L â\89¡[T, 0] L2 → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L2, T⦄.
 /3 width=5 by fpbs_strap1, fpb_lleq/ qed-.
 
 lemma fqus_fpbs_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
@@ -131,7 +131,7 @@ lemma lpxs_fpbs_trans: ∀h,g,G1,G2,L1,L,L2,T1,T2. ⦃G1, L, T1⦄ ≥[h, g] ⦃
 qed-.
 
 lemma lleq_fpbs_trans: ∀h,g,G1,G2,L1,L,L2,T1,T2. ⦃G1, L, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                       L1 â\8b\95[T1, 0] L → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
+                       L1 â\89¡[T1, 0] L → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 /3 width=5 by fpbs_strap2, fpb_lleq/ qed-.
 
 lemma cpxs_fqus_fpbs: ∀h,g,G1,G2,L1,L2,T1,T,T2. ⦃G1, L1⦄ ⊢ T1 ➡*[h, g] T →
index a446b57fa26038bcb5e37026f664bdf3cfc79be8..047fd164a8fbe2642399b930d5b8a5a8a81b171e 100644 (file)
@@ -26,7 +26,7 @@ definition fpbsa: ∀h. sd h → tri_relation genv lenv term ≝
                   λh,g,G1,L1,T1,G2,L2,T2.
                   ∃∃L0,L,T. ⦃G1, L1⦄ ⊢ T1 ➡*[h, g] T &
                          ⦃G1, L1, T⦄ ⊐* ⦃G2, L0, T2⦄ &
-                         â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L & L â\8b\95[T2, 0] L2.
+                         â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L & L â\89¡[T2, 0] L2.
 
 interpretation "'big tree' parallel computation (closure) alternative"
    'BTPRedStarAlt h g G1 L1 T1 G2 L2 T2 = (fpbsa h g G1 L1 T1 G2 L2 T2).
@@ -71,7 +71,7 @@ qed-.
 
 lemma fpbs_intro_alt: ∀h,g,G1,G2,L1,L0,L,L2,T1,T,T2.
                       ⦃G1, L1⦄ ⊢ T1 ➡*[h, g] T → ⦃G1, L1, T⦄ ⊐* ⦃G2, L0, T2⦄ →
-                      â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L â\86\92 L â\8b\95[T2, 0] L2 →  ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ .
+                      â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L â\86\92 L â\89¡[T2, 0] L2 →  ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ .
 /3 width=7 by fpbsa_inv_fpbs, ex4_3_intro/ qed.
 
 (* Advanced inversion lemmas *************************************************)
@@ -79,5 +79,5 @@ lemma fpbs_intro_alt: ∀h,g,G1,G2,L1,L0,L,L2,T1,T,T2.
 lemma fpbs_inv_alt: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
                     ∃∃L0,L,T. ⦃G1, L1⦄ ⊢ T1 ➡*[h, g] T &
                               ⦃G1, L1, T⦄ ⊐* ⦃G2, L0, T2⦄ &
-                              â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L & L â\8b\95[T2, 0] L2.
+                              â¦\83G2, L0â¦\84 â\8a¢ â\9e¡*[h, g] L & L â\89¡[T2, 0] L2.
 /2 width=1 by  fpbs_fpbsa/ qed-.
index eb0bc4d2b6361063a8c333a35020dcf2eb88cc10..9f0c8d41522f6c7fde6ff5cac3864eb3e6e805d6 100644 (file)
@@ -20,6 +20,6 @@ include "basic_2/computation/fpbs.ma".
 (* Properties on lazy equivalence on closures *******************************)
 
 lemma fleq_fpbs: ∀h,g,G1,G2,L1,L2,T1,T2.
-                 â¦\83G1, L1, T1â¦\84 â\8b\95[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
+                 â¦\83G1, L1, T1â¦\84 â\89¡[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 * /2 width=1 by lleq_fpbs/
 qed.
index f78b302774e264bcd8b7ff461b7a0637ddc8e200..1525567aa4e3904178c69441a3be0ce077df6815 100644 (file)
@@ -20,7 +20,7 @@ include "basic_2/computation/fpbs.ma".
 inductive fpbu (h) (g) (G1) (L1) (T1): relation3 genv lenv term ≝
 | fpbu_fqup: ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ → fpbu h g G1 L1 T1 G2 L2 T2
 | fpbu_cpxs: ∀T2. ⦃G1, L1⦄ ⊢ T1 ➡*[h, g] T2 → (T1 = T2 → ⊥) → fpbu h g G1 L1 T1 G1 L1 T2
-| fpbu_lpxs: â\88\80L2. â¦\83G1, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\8b\95[T1, 0] L2 → ⊥) → fpbu h g G1 L1 T1 G1 L2 T1
+| fpbu_lpxs: â\88\80L2. â¦\83G1, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\89¡[T1, 0] L2 → ⊥) → fpbu h g G1 L1 T1 G1 L2 T1
 .
 
 interpretation
@@ -33,7 +33,7 @@ lemma cprs_fpbu: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡* T2 → (T1 = T2 → 
                  ⦃G, L, T1⦄ ≻[h, g] ⦃G, L, T2⦄.
 /3 width=1 by fpbu_cpxs, cprs_cpxs/ qed.
 
-lemma lprs_fpbu: â\88\80h,g,G,L1,L2,T. â¦\83G, L1â¦\84 â\8a¢ â\9e¡* L2 â\86\92 (L1 â\8b\95[T, 0] L2 → ⊥) →
+lemma lprs_fpbu: â\88\80h,g,G,L1,L2,T. â¦\83G, L1â¦\84 â\8a¢ â\9e¡* L2 â\86\92 (L1 â\89¡[T, 0] L2 → ⊥) →
                  ⦃G, L1, T⦄ ≻[h, g] ⦃G, L2, T⦄.
 /3 width=1 by fpbu_lpxs, lprs_lpxs/ qed.
 
index 566b8387280c37e6aa067a5dfe8b726a86278724..c4e1813a996279a849ce1a8b3f986c728b32d798 100644 (file)
@@ -20,16 +20,16 @@ include "basic_2/computation/fpbu_lleq.ma".
 
 (* Properties on lazy equivalence for closures ******************************)
 
-lemma fleq_fpbu_trans: â\88\80h,g,F1,F2,K1,K2,T1,T2. â¦\83F1, K1, T1â¦\84 â\8b\95[0] ⦃F2, K2, T2⦄ →
+lemma fleq_fpbu_trans: â\88\80h,g,F1,F2,K1,K2,T1,T2. â¦\83F1, K1, T1â¦\84 â\89¡[0] ⦃F2, K2, T2⦄ →
                        ∀G2,L2,U2. ⦃F2, K2, T2⦄ ≻[h, g] ⦃G2, L2, U2⦄ →
-                       â\88\83â\88\83G1,L1,U1. â¦\83F1, K1, T1â¦\84 â\89»[h, g] â¦\83G1, L1, U1â¦\84 & â¦\83G1, L1, U1â¦\84 â\8b\95[0] ⦃G2, L2, U2⦄.
+                       â\88\83â\88\83G1,L1,U1. â¦\83F1, K1, T1â¦\84 â\89»[h, g] â¦\83G1, L1, U1â¦\84 & â¦\83G1, L1, U1â¦\84 â\89¡[0] ⦃G2, L2, U2⦄.
 #h #g #F1 #F2 #K1 #K2 #T1 #T2 * -F2 -K2 -T2
 #K2 #HK12 #G2 #L2 #U2 #H12 elim (lleq_fpbu_trans … HK12 … H12) -K2
 /3 width=5 by fleq_intro, ex2_3_intro/
 qed-.
 
 lemma fpb_fpbu: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                â¦\83G1, L1, T1â¦\84 â\8b\95[0] ⦃G2, L2, T2⦄ ∨
+                â¦\83G1, L1, T1â¦\84 â\89¡[0] ⦃G2, L2, T2⦄ ∨
                 ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2
 [ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H
@@ -45,7 +45,7 @@ lemma fpb_fpbu: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2,
 qed-.
 
 lemma fpbs_fpbu_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                    â¦\83G1, L1, T1â¦\84 â\8b\95[0] ⦃G2, L2, T2⦄ ∨
+                    â¦\83G1, L1, T1â¦\84 â\89¡[0] ⦃G2, L2, T2⦄ ∨
                     ∃∃G,L,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ & ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄.
 (* ALTERNATIVE PROOF
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbs_ind_dx … H) -G1 -L1 -T1
index 40791dd8451468c05871eab079e41bbe7226c10e..e39e9d79ec782ad1e8bbfd3ab57b24949721ae6c 100644 (file)
@@ -22,9 +22,9 @@ include "basic_2/computation/fpbu.ma".
 
 (* Properties on lazy equivalence for local environments ********************)
 
-lemma lleq_fpbu_trans: â\88\80h,g,F,K1,K2,T. K1 â\8b\95[T, 0] K2 →
+lemma lleq_fpbu_trans: â\88\80h,g,F,K1,K2,T. K1 â\89¡[T, 0] K2 →
                        ∀G,L2,U. ⦃F, K2, T⦄ ≻[h, g] ⦃G, L2, U⦄ →
-                       â\88\83â\88\83L1. â¦\83F, K1, Tâ¦\84 â\89»[h, g] â¦\83G, L1, Uâ¦\84 & L1 â\8b\95[U, 0] L2.
+                       â\88\83â\88\83L1. â¦\83F, K1, Tâ¦\84 â\89»[h, g] â¦\83G, L1, Uâ¦\84 & L1 â\89¡[U, 0] L2.
 #h #g #F #K1 #K2 #T #HT #G #L2 #U * -G -L2 -U
 [ #G #L2 #U #H2 elim (lleq_fqup_trans … H2 … HT) -K2
   /3 width=3 by fpbu_fqup, ex2_intro/
index 1074ef74d3dad0a0254d3dd7391afcc60b91d9d8..e8f4d2015856aaf0769918a7587bcf6a43f7ed8a 100644 (file)
@@ -52,7 +52,7 @@ lemma aaa_ind_fpbu: ∀h,g. ∀R:relation3 genv lenv term.
 
 fact aaa_ind_fpbg_aux: ∀h,g. ∀R:relation3 genv lenv term.
                        (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
-                                     (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                                     (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
                                      R G1 L1 T1
                        ) →
                        ∀G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ∀A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
@@ -64,7 +64,7 @@ qed-.
 
 lemma aaa_ind_fpbg: ∀h,g. ∀R:relation3 genv lenv term.
                     (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
-                                  (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                                  (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
                                   R G1 L1 T1
                     ) →
                     ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
index 992775d70aac4e893ed96f0cf3243a1946212a96..12df3c22c28b17f6f443a6181a40994c7b710920 100644 (file)
@@ -21,7 +21,7 @@ include "basic_2/computation/fsb.ma".
 (* Note: alternative definition of fsb *)
 inductive fsba (h) (g): relation3 genv lenv term ≝
 | fsba_intro: ∀G1,L1,T1. (
-                 â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → fsba h g G2 L2 T2
+                 â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → fsba h g G2 L2 T2
               ) → fsba h g G1 L1 T1.
 
 interpretation
@@ -32,7 +32,7 @@ interpretation
 
 lemma fsba_ind_alt: ∀h,g. ∀R: relation3 …. (
                        ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥⦥[h,g] T1 → (
-                          â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2
+                          â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2
                        ) → R G1 L1 T1
                     ) →
                     ∀G,L,T. ⦃G, L⦄ ⊢ ⦥⦥[h, g] T → R G L T.
@@ -74,7 +74,7 @@ lemma fsb_fpbs_trans: ∀h,g,G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥[h, g] T1 →
 
 lemma fsb_ind_fpbg: ∀h,g. ∀R:relation3 genv lenv term.
                     (∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥[h, g] T1 →
-                                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
                                 R G1 L1 T1
                     ) →
                     ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥[h, g] T1 → R G1 L1 T1.
index e094ff57fc78a2462734f5e9bcdf1a4d0e7de6ea..41ba54fd303b194f2e7a472737dce4ae56443ffc 100644 (file)
@@ -60,7 +60,7 @@ lemma csx_ind_fpbu: ∀h,g. ∀R:relation3 genv lenv term.
 
 lemma csx_ind_fpbg: ∀h,g. ∀R:relation3 genv lenv term.
                     (∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⬊*[h, g] T1 →
-                                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\8b\95[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                                (â\88\80G2,L2,T2. â¦\83G1, L1, T1â¦\84 >â\89¡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
                                 R G1 L1 T1
                     ) →
                     ∀G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → R G L T.
index 8f48afe864a053eb82b207be15bf28fe77e5e5f7..4263c55cd78aefe29a725e44de525de6de27ca2a 100644 (file)
@@ -22,8 +22,8 @@ include "basic_2/computation/lpxs_cpxs.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 lemma lleq_lpxs_trans: ∀h,g,G,L2,K2. ⦃G, L2⦄ ⊢ ➡*[h, g] K2 →
-                       â\88\80L1,T,d. L1 â\8b\95[T, d] L2 →
-                       â\88\83â\88\83K1. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] K1 & K1 â\8b\95[T, d] K2.
+                       â\88\80L1,T,d. L1 â\89¡[T, d] L2 →
+                       â\88\83â\88\83K1. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] K1 & K1 â\89¡[T, d] K2.
 #h #g #G #L2 #K2 #H @(lpxs_ind … H) -K2 /2 width=3 by ex2_intro/
 #K #K2 #_ #HK2 #IH #L1 #T #d #HT elim (IH … HT) -L2
 #L #HL1 #HT elim (lleq_lpx_trans … HK2 … HT) -K
@@ -31,8 +31,8 @@ lemma lleq_lpxs_trans: ∀h,g,G,L2,K2. ⦃G, L2⦄ ⊢ ➡*[h, g] K2 →
 qed-.
 
 lemma lpxs_lleq_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90 â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90 â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
 [ #I #G1 #L1 #V1 #X #H1 #H2 elim (lpxs_inv_pair2 … H1) -H1
   #K0 #V0 #H1KL1 #_ #H destruct
@@ -60,8 +60,8 @@ lemma lpxs_lleq_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2,
 qed-.
 
 lemma lpxs_lleq_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90⸮ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90⸮ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #H1KL1 #H2KL1
 elim (fquq_inv_gen … H) -H
 [ #H elim (lpxs_lleq_fqu_trans … H … H1KL1 H2KL1) -L1
@@ -71,8 +71,8 @@ elim (fquq_inv_gen … H) -H
 qed-.
 
 lemma lpxs_lleq_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
-                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90+ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90+ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
 [ #G2 #L2 #T2 #H #K1 #H1KL1 #H2KL1 elim (lpxs_lleq_fqu_trans … H … H1KL1 H2KL1) -L1
   /3 width=4 by fqu_fqup, ex3_intro/
@@ -83,8 +83,8 @@ lemma lpxs_lleq_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G
 qed-.
 
 lemma lpxs_lleq_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
-                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90* â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                            â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡*[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                            â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90* â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡*[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #H1KL1 #H2KL1
 elim (fqus_inv_gen … H) -H
 [ #H elim (lpxs_lleq_fqup_trans … H … H1KL1 H2KL1) -L1
@@ -96,7 +96,7 @@ qed-.
 fact leq_lpxs_trans_lleq_aux: ∀h,g,G,L1,L0,d,e. L1 ≃[d, e] L0 → e = ∞ →
                               ∀L2. ⦃G, L0⦄ ⊢ ➡*[h, g] L2 →
                               ∃∃L. L ≃[d, e] L2 & ⦃G, L1⦄ ⊢ ➡*[h, g] L &
-                                   (â\88\80T. L0 â\8b\95[T, d] L2 â\86\94 L1 â\8b\95[T, d] L).
+                                   (â\88\80T. L0 â\89¡[T, d] L2 â\86\94 L1 â\89¡[T, d] L).
 #h #g #G #L1 #L0 #d #e #H elim H -L1 -L0 -d -e
 [ #d #e #_ #L2 #H >(lpxs_inv_atom1 … H) -H
   /3 width=5 by ex3_intro, conj/
@@ -120,5 +120,5 @@ qed-.
 lemma leq_lpxs_trans_lleq: ∀h,g,G,L1,L0,d. L1 ≃[d, ∞] L0 →
                            ∀L2. ⦃G, L0⦄ ⊢ ➡*[h, g] L2 →
                            ∃∃L. L ≃[d, ∞] L2 & ⦃G, L1⦄ ⊢ ➡*[h, g] L &
-                                (â\88\80T. L0 â\8b\95[T, d] L2 â\86\94 L1 â\8b\95[T, d] L).
+                                (â\88\80T. L0 â\89¡[T, d] L2 â\86\94 L1 â\89¡[T, d] L).
 /2 width=1 by leq_lpxs_trans_lleq_aux/ qed-.
index 435650bd1577b568851819f9f9fc4c564fcd0ec0..0f47fe0567f69a3b5725c48bbc6e25fa3ad80500 100644 (file)
@@ -29,7 +29,7 @@ interpretation
 
 lemma lsx_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
                (∀L1. G ⊢ ⬊*[h, g, T, d] L1 →
-                     (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → R L2) →
+                     (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → R L2) →
                      R L1
                ) →
                ∀L. G ⊢ ⬊*[h, g, T, d] L → R L.
@@ -40,7 +40,7 @@ qed-.
 (* Basic properties *********************************************************)
 
 lemma lsx_intro: ∀h,g,G,L1,T,d.
-                 (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → G ⊢ ⬊*[h, g, T, d] L2) →
+                 (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → G ⊢ ⬊*[h, g, T, d] L2) →
                  G ⊢ ⬊*[h, g, T, d] L1.
 /5 width=1 by lleq_sym, SN_intro/ qed.
 
index cd7c83be9831e84679703de212810aedc767ab3b..50b41adb254437e5994e177b015d4bc43e30f2a4 100644 (file)
@@ -31,7 +31,7 @@ interpretation
 
 lemma lsxa_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
                 (∀L1. G ⊢ ⬊⬊*[h, g, T, d] L1 →
-                      (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → R L2) →
+                      (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → R L2) →
                       R L1
                 ) →
                 ∀L. G ⊢ ⬊⬊*[h, g, T, d] L → R L.
@@ -42,17 +42,17 @@ qed-.
 (* Basic properties *********************************************************)
 
 lemma lsxa_intro: ∀h,g,G,L1,T,d.
-                  (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
+                  (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
                   G ⊢ ⬊⬊*[h, g, T, d] L1.
 /5 width=1 by lleq_sym, SN_intro/ qed.
 
 fact lsxa_intro_aux: ∀h,g,G,L1,T,d.
-                     (â\88\80L,L2. â¦\83G, Lâ¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 L1 â\8b\95[T, d] L â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
+                     (â\88\80L,L2. â¦\83G, Lâ¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 L1 â\89¡[T, d] L â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
                      G ⊢ ⬊⬊*[h, g, T, d] L1.
 /4 width=3 by lsxa_intro/ qed-.
 
 lemma lsxa_lleq_trans: ∀h,g,T,G,L1,d. G ⊢ ⬊⬊*[h, g, T, d] L1 →
-                       â\88\80L2. L1 â\8b\95[T, d] L2 → G ⊢ ⬊⬊*[h, g, T, d] L2.
+                       â\88\80L2. L1 â\89¡[T, d] L2 → G ⊢ ⬊⬊*[h, g, T, d] L2.
 #h #g #T #G #L1 #d #H @(lsxa_ind … H) -L1
 #L1 #_ #IHL1 #L2 #HL12 @lsxa_intro
 #K2 #HLK2 #HnLK2 elim (lleq_lpxs_trans … HLK2 … HL12) -HLK2
@@ -66,7 +66,7 @@ elim (lleq_dec T L1 L2 d) /3 width=4 by lsxa_lleq_trans/
 qed-.
 
 lemma lsxa_intro_lpx: ∀h,g,G,L1,T,d.
-                      (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
+                      (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → G ⊢ ⬊⬊*[h, g, T, d] L2) →
                       G ⊢ ⬊⬊*[h, g, T, d] L1.
 #h #g #G #L1 #T #d #IH @lsxa_intro_aux
 #L #L2 #H @(lpxs_ind_dx … H) -L
@@ -95,7 +95,7 @@ qed-.
 (* Advanced properties ******************************************************)
 
 lemma lsx_intro_alt: ∀h,g,G,L1,T,d.
-                     (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → G ⊢ ⬊*[h, g, T, d] L2) →
+                     (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → G ⊢ ⬊*[h, g, T, d] L2) →
                      G ⊢ ⬊*[h, g, T, d] L1.
 /6 width=1 by lsxa_inv_lsx, lsx_lsxa, lsxa_intro/ qed.
 
@@ -107,7 +107,7 @@ lemma lsx_lpxs_trans: ∀h,g,G,L1,T,d. G ⊢ ⬊*[h, g, T, d] L1 →
 
 lemma lsx_ind_alt: ∀h,g,G,T,d. ∀R:predicate lenv.
                    (∀L1. G ⊢ ⬊*[h, g, T, d] L1 →
-                         (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\8b\95[T, d] L2 → ⊥) → R L2) →
+                         (â\88\80L2. â¦\83G, L1â¦\84 â\8a¢ â\9e¡*[h, g] L2 â\86\92 (L1 â\89¡[T, d] L2 → ⊥) → R L2) →
                          R L1
                    ) →
                    ∀L. G ⊢ ⬊*[h, g, T, d] L → R L.
index 37f4edfaf3a8b0996e50f148dcf900a7dfafb908..d191024b9a8b35cc4da0118ae619f21cad4c8f20 100644 (file)
@@ -21,7 +21,7 @@ include "basic_2/computation/lsx.ma".
 (* Advanced properties ******************************************************)
 
 lemma lsx_lleq_trans: ∀h,g,T,G,L1,d. G ⊢ ⬊*[h, g, T, d] L1 →
-                      â\88\80L2. L1 â\8b\95[T, d] L2 → G ⊢ ⬊*[h, g, T, d] L2.
+                      â\88\80L2. L1 â\89¡[T, d] L2 → G ⊢ ⬊*[h, g, T, d] L2.
 #h #g #T #G #L1 #d #H @(lsx_ind … H) -L1
 #L1 #_ #IHL1 #L2 #HL12 @lsx_intro
 #K2 #HLK2 #HnLK2 elim (lleq_lpx_trans … HLK2 … HL12) -HLK2
index 797f73147272055091c3a1c7aaf6d1326add106e..56ed1c2c5d734f8154f1622be5beaf4f6e710ed1 100644 (file)
@@ -47,17 +47,17 @@ definition IH_snv_lsstas: ∀h:sh. sd h → relation3 genv lenv term ≝
 (* Properties for the preservation results **********************************)
 
 fact snv_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                        ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
 #h #g #G0 #L0 #T0 #IH #G #L1 #T1 #HLT0 #HT1 #T2 #H
 @(cprs_ind … H) -T2 /4 width=6 by fpbg_fpbs_trans, cprs_fpbs/
 qed-.
 
 fact da_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                      â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                      â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                       ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l →
                       ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ▪[h, g] l.
 #h #g #G0 #L0 #T0 #IH2 #IH1 #G #L1 #T1 #HLT0 #HT1 #l #Hl #T2 #H
@@ -65,10 +65,10 @@ fact da_cprs_lpr_aux: ∀h,g,G0,L0,T0.
 qed-.
 
 fact da_cpcs_aux: ∀h,g,G0,L0,T0.
-                  (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                  (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                  â\88\80G,L,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
-                  â\88\80T2. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L, T2⦄ → ⦃G, L⦄ ⊢ T2 ¡[h, g] →
+                  (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                  (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                  â\88\80G,L,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
+                  â\88\80T2. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L, T2⦄ → ⦃G, L⦄ ⊢ T2 ¡[h, g] →
                   ∀l1. ⦃G, L⦄ ⊢ T1 ▪[h, g] l1 → ∀l2. ⦃G, L⦄ ⊢ T2 ▪[h, g] l2 →
                   ⦃G, L⦄ ⊢ T1 ⬌* T2 → l1 = l2.
 #h #g #G0 #L0 #T0 #IH2 #IH1 #G #L #T1 #HLT01 #HT1 #T2 #HLT02 #HT2 #l1 #Hl1 #l2 #Hl2 #H
@@ -76,8 +76,8 @@ elim (cpcs_inv_cprs … H) -H /4 width=18 by da_cprs_lpr_aux, da_mono/
 qed-.
 
 fact ssta_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                        ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l+1 →
                        ∀U1. ⦃G, L1⦄ ⊢ T1 •[h, g] U1 →
                        ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
@@ -88,10 +88,10 @@ elim (IH … H01 … 1 … Hl U1 … HT12 … HL12)
 qed-.
 
 fact lsstas_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                          â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                          â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                           ∀l1,l2. l2 ≤ l1 → ⦃G, L1⦄ ⊢ T1 ▪[h, g] l1 →
                           ∀U1. ⦃G, L1⦄ ⊢ T1 •*[h, g, l2] U1 →
                           ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
@@ -109,12 +109,12 @@ elim (IH1 … Hl21 … HTU … HTT2 … HL12) -IH1 -HTU -HTT2
 qed-.
 
 fact lsstas_cpcs_lpr_aux: ∀h,g,G0,L0,T0.
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                          â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                          (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                          â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                           ∀l,l1. l ≤ l1 → ⦃G, L1⦄ ⊢ T1 ▪[h, g] l1 → ∀U1. ⦃G, L1⦄ ⊢ T1 •*[h, g, l] U1 →
-                          â\88\80T2. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T2⦄ → ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
+                          â\88\80T2. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T2⦄ → ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
                           ∀l2. l ≤ l2 → ⦃G, L1⦄ ⊢ T2 ▪[h, g] l2 → ∀U2. ⦃G, L1⦄ ⊢ T2 •*[h, g, l] U2 →
                           ⦃G, L1⦄ ⊢ T1 ⬌* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ U1 ⬌* U2.
 #h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G #L1 #T1 #H01 #HT1 #l #l1 #Hl1 #HTl1 #U1 #HTU1 #T2 #H02 #HT2 #l2 #Hl2 #HTl2 #U2 #HTU2 #H #L2 #HL12
@@ -125,18 +125,18 @@ lapply (lsstas_mono … H1 … H2) -h -T -l #H destruct /2 width=3 by cpcs_canc_
 qed-.
 
 fact snv_ssta_aux: ∀h,g,G0,L0,T0.
-                   (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
-                   â\88\80G,L,T. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L, T⦄ → ⦃G, L⦄ ⊢ T ¡[h, g] →
+                   (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                   â\88\80G,L,T. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L, T⦄ → ⦃G, L⦄ ⊢ T ¡[h, g] →
                    ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 →
                    ∀U. ⦃G, L⦄ ⊢ T •[h, g] U → ⦃G, L⦄ ⊢ U ¡[h, g].
 /3 width=8 by lsstas_inv_SO, ssta_lsstas/ qed-.
 
 fact lsstas_cpds_aux: ∀h,g,G0,L0,T0.
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                      â\88\80G,L,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                      â\88\80G,L,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
                       ∀l1,l2. l2 ≤ l1 → ⦃G, L⦄ ⊢ T1 ▪[h, g] l1 →
                       ∀U1. ⦃G, L⦄ ⊢ T1 •*[h, g, l2] U1 → ∀T2. ⦃G, L⦄ ⊢ T1 •*➡*[h, g] T2 →
                       ∃∃U2,l. l ≤ l2 & ⦃G, L⦄ ⊢ T2 •*[h, g, l] U2 & ⦃G, L⦄ ⊢ U1 •*⬌*[h, g] U2.
@@ -155,9 +155,9 @@ elim (le_or_ge l2 l) #Hl2
 qed-.
 
 fact cpds_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                       (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                       â\88\80G,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
                        ∀U1. ⦃G, L1⦄ ⊢ T1 •*➡*[h, g] U1 →
                        ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
                        ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*➡*[h, g] U2 & ⦃G, L2⦄ ⊢ U1 ➡* U2.
index 5adc067d53bfd8fac7657f893df38232f47c01c7..dd56de7a26c0cbd445c34ca837c77b3cb2835ce1 100644 (file)
@@ -22,9 +22,9 @@ include "basic_2/dynamic/snv_cpcs.ma".
 (* Properties on degree assignment for terms ********************************)
 
 fact da_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
                      ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_da_cpr_lpr h g G1 L1 T1.
 #h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
 [ #k #_ #_ #_ #_ #l #H2 #X3 #H3 #L2 #_ -IH3 -IH2 -IH1
index 367312794cbe2f2911b35476b14a58a443083508..f73c20a5e088b2d18021055fe0cd393492187188 100644 (file)
@@ -21,10 +21,10 @@ include "basic_2/dynamic/lsubsv_snv.ma".
 (* Properties on context-free parallel reduction for local environments *****)
 
 fact snv_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                      (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
                       ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_snv_cpr_lpr h g G1 L1 T1.
 #h #g #G0 #L0 #T0 #IH4 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
 [ #k #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #_ destruct -IH4 -IH3 -IH2 -IH1 -H1
index 739caf494243bbfb50c41a4293dd65e66afe4288..a0ef9e99ea3bcf6959a307f428ce83f29d0ef933 100644 (file)
@@ -20,10 +20,10 @@ include "basic_2/dynamic/snv_cpcs.ma".
 (* Properties on nat-iterated stratified static type assignment for terms ***)
 
 fact snv_lsstas_aux: ∀h,g,G0,L0,T0.
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
-                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                     (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
                      ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_snv_lsstas h g G1 L1 T1.
 #h #g #G0 #L0 #T0 #IH4 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
 [ #k #HG0 #HL0 #HT0 #_ #l1 #l2 #Hl21 #Hl1 #X #H2 destruct -IH4 -IH3 -IH2 -IH1
index 9213b4d578d49181ccf8d71c782b7776b20260f3..1ee5ba08ec4cf80bfefd4f3e092a91f8d8b63484 100644 (file)
@@ -22,10 +22,10 @@ include "basic_2/dynamic/lsubsv_lsstas.ma".
 (* Properties on sn parallel reduction for local environments ***************)
 
 fact lsstas_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
-                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
-                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\8b\95[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
+                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_lsstas h g G1 L1 T1) →
+                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpr_lpr h g G1 L1 T1) →
+                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                         (â\88\80G1,L1,T1. â¦\83G0, L0, T0â¦\84 >â\89¡[h, g] ⦃G1, L1, T1⦄ → IH_lsstas_cpr_lpr h g G1 L1 T1) →
                          ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_lsstas_cpr_lpr h g G1 L1 T1.
 #h #g #G0 #L0 #T0 #IH4 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
 [ #k #_ #_ #_ #_ #l1 #l2 #_ #_ #X2 #H2 #X3 #H3 #L2 #_ -IH4 -IH3 -IH2 -IH1
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpx_cpys.etc
deleted file mode 100644 (file)
index 46abd54..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/cpys_alt.ma".
-include "basic_2/reduction/cpx.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
-
-(* Properties on context-sensitive extended multiple substitution for terms *)
-
-lemma cpys_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L #T1 #T2 #d #e #H @(cpys_ind_alt … H) -G -L -T1 -T2 -d -e
-/2 width=7 by cpx_delta, cpx_bind, cpx_flat/
-qed.
-
-lemma cpy_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-/3 width=3 by cpy_cpys, cpys_cpx/ qed.
-
-lemma cpx_cpy_trans: ∀h,g,G,L,T1,T. ⦃G, L⦄ ⊢ T1 ➡[h, g] T →
-                     ∀T2,d,e. ⦃G, L⦄ ⊢ T ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L #T1 #T #H elim H -G -L -T1 -T
-[ #I #G #L #X #d #e #H elim (cpy_inv_atom1 … H) //
-  * /2 width=3 by cpy_cpx/
-| #G #L #k #l #Hkl #X #d #e #H >(cpy_inv_sort1 … H) -X /2 width=2 by cpx_sort/
-| #I #G #L #K #V1 #V #W #i #HLK #_ #HVW #IHV1 #X #d #e #H
-  lapply (ldrop_fwd_drop2 … HLK) #H0
-  lapply (cpy_weak … H 0 (∞) ? ?) -H // #H
-  elim (cpy_inv_lift1_be … H … H0 … HVW) -H -H0 -HVW
-  /3 width=7 by cpx_delta/
-| #a #I #G #L #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #X #d #e #H elim (cpy_inv_bind1 … H) -H
-  #V2 #T2 #HV2 #HT2 #H destruct
-  /5 width=7 by cpx_bind, lsuby_cpy_trans, lsuby_succ/
-| #I #G #L #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #X #d #e #H elim (cpy_inv_flat1 … H) -H
-  #V2 #T2 #HV2 #HT2 #H destruct /3 width=3 by cpx_flat/
-| #G #L #V1 #U1 #U #T #_ #HTU #IHU1 #T2 #d #e #HT2
-  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
-  elim (lift_total T2 0 1) #U2 #HTU2
-  lapply (cpy_lift_be … HT2 (L.ⓓV1) … (Ⓕ) … HTU … HTU2 ? ?) -T
-  /3 width=3 by cpx_zeta, ldrop_drop/
-| /3 width=3 by cpx_tau/
-| /3 width=3 by cpx_ti/
-| #a #G #L #V1 #V #W1 #W #T1 #T #_ #_ #_ #IHV1 #IHW1 #IHT1 #X #d #e #HX
-  elim (cpy_inv_bind1 … HX) -HX #Y #T2 #HY #HT2 #H destruct
-  elim (cpy_inv_flat1 … HY) -HY #W2 #V2 #HW2 #HV2 #H destruct
-  /5 width=7 by cpx_beta, lsuby_cpy_trans, lsuby_succ/
-| #a #G #L #V1 #V #U #W1 #W #T1 #T #_ #HVU #_ #_ #IHV1 #IHW1 #IHT1 #X #d #e #HX
-  elim (cpy_inv_bind1 … HX) -HX #W2 #Y #HW2 #HY #H destruct
-  elim (cpy_inv_flat1 … HY) -HY #U2 #T2 #HU2 #HT2 #H destruct
-  lapply (cpy_weak … HU2 0 (∞) ? ?) -HU2 // #HU2
-  elim (cpy_inv_lift1_be … HU2 L … HVU) -U
-  /5 width=7 by cpx_theta, lsuby_cpy_trans, lsuby_succ, ldrop_drop/
-]
-qed-.
-
-lemma cpx_cpys_trans: ∀h,g,G,L,T1,T. ⦃G, L⦄ ⊢ T1 ➡[h, g] T →
-                      ∀T2,d,e. ⦃G, L⦄ ⊢ T ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L #T1 #T #HT1 #T2 #d #e #H @(cpys_ind … H) -T2
-/2 width=5 by cpx_cpy_trans/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys.etc
new file mode 100644 (file)
index 0000000..3b38ee6
--- /dev/null
@@ -0,0 +1,42 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/cpys_alt.ma".
+include "basic_2/reduction/cpx.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
+
+(* Properties on local environment refinement for extended substitution *****)
+
+lemma lsuby_cpx_trans: ∀h,g,G. lsub_trans … (cpx h g G) (lsuby 0 (∞)).
+#h #g #G #L1 #T1 #T2 #H elim H -G -L1 -T1 -T2
+[ //
+| /2 width=2 by cpx_sort/
+| #I #G #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (lsuby_ldrop_trans_be … HL12 … HLK1) // -HL12 -HLK1 /3 width=7 by cpx_delta/
+|4,9: /4 width=1 by cpx_bind, cpx_beta, lsuby_pair_O_Y/
+|5,7,8: /3 width=1 by cpx_flat, cpx_tau, cpx_ti/
+|6,10: /4 width=3 by cpx_zeta, cpx_theta, lsuby_pair_O_Y/
+]
+qed-.
+
+(* Properties on context-sensitive extended multiple substitution for terms *)
+
+lemma cpys_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L #T1 #T2 #d #e #H @(cpys_ind_alt … H) -G -L -T1 -T2 -d -e
+/2 width=7 by cpx_delta, cpx_bind, cpx_flat/
+qed.
+
+lemma cpy_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+/3 width=3 by cpy_cpys, cpys_cpx/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpx_cpys2.etc
new file mode 100644 (file)
index 0000000..46abd54
--- /dev/null
@@ -0,0 +1,70 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/cpys_alt.ma".
+include "basic_2/reduction/cpx.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
+
+(* Properties on context-sensitive extended multiple substitution for terms *)
+
+lemma cpys_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L #T1 #T2 #d #e #H @(cpys_ind_alt … H) -G -L -T1 -T2 -d -e
+/2 width=7 by cpx_delta, cpx_bind, cpx_flat/
+qed.
+
+lemma cpy_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+/3 width=3 by cpy_cpys, cpys_cpx/ qed.
+
+lemma cpx_cpy_trans: ∀h,g,G,L,T1,T. ⦃G, L⦄ ⊢ T1 ➡[h, g] T →
+                     ∀T2,d,e. ⦃G, L⦄ ⊢ T ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L #T1 #T #H elim H -G -L -T1 -T
+[ #I #G #L #X #d #e #H elim (cpy_inv_atom1 … H) //
+  * /2 width=3 by cpy_cpx/
+| #G #L #k #l #Hkl #X #d #e #H >(cpy_inv_sort1 … H) -X /2 width=2 by cpx_sort/
+| #I #G #L #K #V1 #V #W #i #HLK #_ #HVW #IHV1 #X #d #e #H
+  lapply (ldrop_fwd_drop2 … HLK) #H0
+  lapply (cpy_weak … H 0 (∞) ? ?) -H // #H
+  elim (cpy_inv_lift1_be … H … H0 … HVW) -H -H0 -HVW
+  /3 width=7 by cpx_delta/
+| #a #I #G #L #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #X #d #e #H elim (cpy_inv_bind1 … H) -H
+  #V2 #T2 #HV2 #HT2 #H destruct
+  /5 width=7 by cpx_bind, lsuby_cpy_trans, lsuby_succ/
+| #I #G #L #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #X #d #e #H elim (cpy_inv_flat1 … H) -H
+  #V2 #T2 #HV2 #HT2 #H destruct /3 width=3 by cpx_flat/
+| #G #L #V1 #U1 #U #T #_ #HTU #IHU1 #T2 #d #e #HT2
+  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
+  elim (lift_total T2 0 1) #U2 #HTU2
+  lapply (cpy_lift_be … HT2 (L.ⓓV1) … (Ⓕ) … HTU … HTU2 ? ?) -T
+  /3 width=3 by cpx_zeta, ldrop_drop/
+| /3 width=3 by cpx_tau/
+| /3 width=3 by cpx_ti/
+| #a #G #L #V1 #V #W1 #W #T1 #T #_ #_ #_ #IHV1 #IHW1 #IHT1 #X #d #e #HX
+  elim (cpy_inv_bind1 … HX) -HX #Y #T2 #HY #HT2 #H destruct
+  elim (cpy_inv_flat1 … HY) -HY #W2 #V2 #HW2 #HV2 #H destruct
+  /5 width=7 by cpx_beta, lsuby_cpy_trans, lsuby_succ/
+| #a #G #L #V1 #V #U #W1 #W #T1 #T #_ #HVU #_ #_ #IHV1 #IHW1 #IHT1 #X #d #e #HX
+  elim (cpy_inv_bind1 … HX) -HX #W2 #Y #HW2 #HY #H destruct
+  elim (cpy_inv_flat1 … HY) -HY #U2 #T2 #HU2 #HT2 #H destruct
+  lapply (cpy_weak … HU2 0 (∞) ? ?) -HU2 // #HU2
+  elim (cpy_inv_lift1_be … HU2 L … HVU) -U
+  /5 width=7 by cpx_theta, lsuby_cpy_trans, lsuby_succ, ldrop_drop/
+]
+qed-.
+
+lemma cpx_cpys_trans: ∀h,g,G,L,T1,T. ⦃G, L⦄ ⊢ T1 ➡[h, g] T →
+                      ∀T2,d,e. ⦃G, L⦄ ⊢ T ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L #T1 #T #HT1 #T2 #d #e #H @(cpys_ind … H) -T2
+/2 width=5 by cpx_cpy_trans/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpxs_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpxs_cpys.etc
new file mode 100644 (file)
index 0000000..8810305
--- /dev/null
@@ -0,0 +1,24 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/reduction/cpx_cpys.ma".
+include "basic_2/computation/cpxs.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL COMPUTATION ON TERMS *****************)
+
+(* Properties on local environment refinement for extended substitution *****)
+
+lemma lsuby_cpxs_trans: ∀h,g,G. lsub_trans … (cpxs h g G) (lsuby 0 (∞)).
+/3 width=5 by lsuby_cpx_trans, LTC_lsub_trans/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpy.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpy.etc
new file mode 100644 (file)
index 0000000..e941c96
--- /dev/null
@@ -0,0 +1,27 @@
+include "basic_2/grammar/cl_shift.ma".
+include "basic_2/relocation/ldrop_append.ma".
+
+lemma cpy_append: ∀G,d,e. l_appendable_sn … (cpy d e G).
+#G #d #e #K #T1 #T2 #H elim H -G -K -T1 -T2 -d -e
+/2 width=1 by cpy_atom, cpy_bind, cpy_flat/
+#I #G #K #K0 #V #W #i #d #e #Hdi #Hide #HK0 #HVW #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpy_subst I … (L@@K0) … HVW) // (**) (* /4/ does not work *)
+@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/
+qed-.
+
+lemma cpy_fwd_shift1: ∀G,L1,L,T1,T,d,e. ⦃G, L⦄ ⊢ L1 @@ T1 ▶[d, e] T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#G #L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #d #e #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X #d #e
+  >shift_append_assoc normalize #H
+  elim (cpy_inv_bind1 … H) -H
+  #V0 #T0 #_ #HT10 #H destruct
+  elim (IH … HT10) -IH -HT10 #L2 #T2 #HL12 #H destruct
+  >append_length >HL12 -HL12
+  @(ex2_2_intro … (⋆.ⓑ{I}V0@@L2) T2) [ >append_length ] (**) (* explicit constructor *)
+  /2 width=3 by trans_eq/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/cpys.etc
new file mode 100644 (file)
index 0000000..22f74d0
--- /dev/null
@@ -0,0 +1,14 @@
+lemma cpys_append: ∀G,d,e. l_appendable_sn … (cpys d e G).
+#G #d #e #K #T1 #T2 #H @(cpys_ind … H) -T2
+/3 width=3 by cpys_strap1, cpy_append/
+qed-.
+
+lemma cpys_fwd_shift1: ∀G,L,L1,T1,T,d,e. ⦃G, L⦄ ⊢ L1 @@ T1 ▶*[d, e] T →
+                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#G #L #L1 #T1 #T #d #e #H @(cpys_ind … H) -T
+[ /2 width=4 by ex2_2_intro/
+| #T #X #_ #HX * #L0 #T0 #HL10 #H destruct
+  elim (cpy_fwd_shift1 … HX) -HX #L2 #T2 #HL02 #H destruct
+  /2 width=4 by ex2_2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lpx_cpys.etc
new file mode 100644 (file)
index 0000000..d3c490a
--- /dev/null
@@ -0,0 +1,69 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/relocation/cpy_lift.ma".
+include "basic_2/substitution/cpys.ma".
+include "basic_2/reduction/lpx_ldrop.ma".
+
+(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
+
+(* Properties on context-sensitive extended substitution for terms **********)
+
+lemma cpx_cpy_trans_lpx: ∀h,g,G,L1,T1,T. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T →
+                         ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
+                         ∀T2,d,e. ⦃G, L2⦄ ⊢ T ▶[d, e] T2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L1 #T1 #T #H elim H -G -L1 -T1 -T
+[ #J #G #L1 #L2 #HL12 #T2 #d #e #H elim (cpy_inv_atom1 … H) -H //
+  * #I #K2 #V2 #i #_ #_ #HLK2 #HVT2 #H destruct
+  elim (lpx_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
+  elim (lpx_inv_pair2 … H) -H #K1 #V1 #_ #HV12 #H destruct
+  /2 width=7 by cpx_delta/
+| #G #L1 #k #l #Hkl #L2 #_ #X #d #e #H >(cpy_inv_sort1 … H) -X /2 width=2 by cpx_sort/
+| #I #G #L1 #K1 #V1 #V #T #i #HLK1 #_ #HVT #IHV1 #L2 #HL12 #T2 #d #e #HT2
+  elim (lpx_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+  elim (lpx_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
+  lapply (ldrop_fwd_drop2 … HLK2) -V0 #HLK2
+  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
+  elim (cpy_inv_lift1_be … HT2 … HLK2 … HVT) -HT2 -HLK2 -HVT
+  /3 width=7 by cpx_delta/
+| #a #I #G #L1 #V1 #V #T1 #T #HV1 #_ #IHV1 #IHT1 #L2 #HL12 #X #d #e #H elim (cpy_inv_bind1 … H) -H
+  #V2 #T2 #HV2 #HT2 #H destruct /4 width=5 by lpx_pair, cpx_bind/
+| #I #G #L1 #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #L2 #HL12 #X #d #e #H elim (cpy_inv_flat1 … H) -H
+  #V2 #T2 #HV2 #HT2 #H destruct /3 width=5 by cpx_flat/
+| #G #L1 #V1 #U1 #U #T #_ #HTU #IHU1 #L2 #HL12 #T2 #d #e #HT2
+  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
+  elim (lift_total T2 0 1) #U2 #HTU2
+  lapply (cpy_lift_be … HT2 (L2.ⓓV1) … (Ⓕ) … HTU … HTU2 ? ?) -T
+  /4 width=5 by cpx_zeta, lpx_pair, ldrop_drop/
+| /3 width=5 by cpx_tau/
+| /3 width=5 by cpx_ti/
+| #a #G #L1 #V1 #V #W1 #W #T1 #T #HV1 #HW1 #_ #IHV1 #IHW1 #IHT1 #L2 #HL12 #X #d #e #HX
+  elim (cpy_inv_bind1 … HX) -HX #Y #T2 #HY #HT2 #H destruct
+  elim (cpy_inv_flat1 … HY) -HY #W2 #V2 #HW2 #HV2 #H destruct
+  /5 width=11 by lpx_pair, cpx_beta, lsuby_cpy_trans, lsuby_succ/
+| #a #G #L1 #V1 #V #U #W1 #W #T1 #T #_ #HVU #HW1 #_ #IHV1 #IHW1 #IHT1 #L2 #HL12 #X #d #e #HX
+  elim (cpy_inv_bind1 … HX) -HX #W2 #Y #HW2 #HY #H destruct
+  elim (cpy_inv_flat1 … HY) -HY #U2 #T2 #HU2 #HT2 #H destruct
+  lapply (cpy_weak … HU2 0 (∞) ? ?) -HU2 // #HU2
+  elim (cpy_inv_lift1_be … HU2 L2 … HVU) -U
+  /4 width=7 by lpx_pair, cpx_theta, ldrop_drop/
+]
+qed-.
+
+lemma cpx_cpys_trans_lpx: ∀h,g,G,L1,T1,T. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T →
+                          ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
+                          ∀T2,d,e. ⦃G, L2⦄ ⊢ T ▶*[d, e] T2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
+#h #g #G #L1 #T1 #T #HT1 #L2 #HL12 #T2 #d #e #H @(cpys_ind … H) -T2
+/2 width=7 by cpx_cpy_trans_lpx/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpy/lsuby.etc
new file mode 100644 (file)
index 0000000..657ad6b
--- /dev/null
@@ -0,0 +1,15 @@
+(*
+lemma lsuby_weak: ∀L1,L2,d1,e1. L1 ⊑×[d1, e1] L2 →
+                  ∀d2,e2. d1 ≤ d2 → e2 ≤ e1 → L1 ⊑×[d2, e2] L2.
+#L1 #L2 #d1 #e1 #H elim H -L1 -L2 -d1 -e1 //
+[ #I1 #I2 #L1 #L2 #V1 #V2 #HL12 #_ #d2 #e2 #_ #He21
+  >(yle_inv_O2 … He21) -He21
+  /4 width=3 by lsuby_fwd_length, lsuby_O1, monotonic_le_plus_l/
+| #I1 #I2 #L1 #L2 #V #e #HL12 #IHL12 #d2 #e2 #_ #He21
+  elim (ynat_cases e2) /4 width=3 by lsuby_fwd_length, lsuby_O1, monotonic_le_plus_l/
+  * #e0 #H destruct lapply (yle_inv_succ … He21) -He21 #He21
+  elim (ynat_cases d2) /3 width=1 by lsuby_pair/
+  * #d0 #H destruct @lsuby_succ @IHL12 //
+  [   destruct
+  
+*)  
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lazyeqalt_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lazyeqalt_4.etc
new file mode 100644 (file)
index 0000000..b89d784
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
+
+notation "hvbox( L1 ⋕ ⋕ break [ term 46 T , break term 46 d ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LazyEqAlt $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq.etc
new file mode 100644 (file)
index 0000000..72a5346
--- /dev/null
@@ -0,0 +1,160 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/notation/relations/lazyeq_4.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+definition lleq: relation4 ynat term lenv lenv ≝
+                 λd,T,L1,L2. |L1| = |L2| ∧
+                             (∀U. ⦃⋆, L1⦄ ⊢ T ▶*[d, ∞] U ↔ ⦃⋆, L2⦄ ⊢ T ▶*[d, ∞] U).
+
+interpretation
+   "lazy equivalence (local environment)"
+   'LazyEq T d L1 L2 = (lleq d T L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lleq_refl: ∀d,T. reflexive … (lleq d T).
+/3 width=1 by conj/ qed.
+
+lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
+#d #T #L1 #L2 * /3 width=1 by iff_sym, conj/
+qed-.
+
+lemma lleq_sort: ∀L1,L2,d,k. |L1| = |L2| → L1 ⋕[⋆k, d] L2.
+#L1 #L2 #d #k #HL12 @conj // -HL12
+#U @conj #H >(cpys_inv_sort1 … H) -H //
+qed.
+
+lemma lleq_gref: ∀L1,L2,d,p. |L1| = |L2| → L1 ⋕[§p, d] L2.
+#L1 #L2 #d #k #HL12 @conj // -HL12
+#U @conj #H >(cpys_inv_gref1 … H) -H //
+qed.
+
+lemma lleq_bind: ∀a,I,L1,L2,V,T,d.
+                 L1 ⋕[V, d] L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V →
+                 L1 ⋕[ⓑ{a,I}V.T, d] L2.
+#a #I #L1 #L2 #V #T #d * #HL12 #IHV * #_ #IHT @conj // -HL12
+#X @conj #H elim (cpys_inv_bind1 … H) -H
+#W #U #HVW #HTU #H destruct
+elim (IHV W) -IHV elim (IHT U) -IHT /3 width=1 by cpys_bind/
+qed.
+
+lemma lleq_flat: ∀I,L1,L2,V,T,d.
+                 L1 ⋕[V, d] L2 → L1 ⋕[T, d] L2 → L1 ⋕[ⓕ{I}V.T, d] L2.
+#I #L1 #L2 #V #T #d * #HL12 #IHV * #_ #IHT @conj // -HL12
+#X @conj #H elim (cpys_inv_flat1 … H) -H
+#W #U #HVW #HTU #H destruct
+elim (IHV W) -IHV elim (IHT U) -IHT
+/3 width=1 by cpys_flat/
+qed.
+
+lemma lleq_be: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 → ∀T,d,e. ⇧[d, e] T ≡ U →
+               d ≤ dt → dt ≤ d + e → L1 ⋕[U, d] L2.
+#L1 #L2 #U #dt * #HL12 #IH #T #d #e #HTU #Hddt #Hdtde @conj // -HL12
+#U0 elim (IH U0) -IH #H12 #H21 @conj
+#HU0 elim (cpys_fwd_up … HU0 … HTU) // -HU0 /4 width=5 by cpys_weak/
+qed-.
+
+lemma lsuby_lleq_trans: ∀L2,L,T,d. L2 ⋕[T, d] L →
+                        ∀L1. L1 ⊑×[d, ∞] L2 → |L1| = |L2| → L1 ⋕[T, d] L.
+#L2 #L #T #d * #HL2 #IH #L1 #HL12 #H @conj // -HL2
+#U elim (IH U) -IH #Hdx #Hsn @conj #HTU
+[ @Hdx -Hdx -Hsn @(lsuby_cpys_trans … HTU) -HTU
+  /2 width=1 by lsuby_sym/ (**) (* full auto does not work *)
+| -H -Hdx /3 width=3 by lsuby_cpys_trans/
+]
+qed-.
+
+lemma lleq_lsuby_trans: ∀L,L1,T,d. L ⋕[T, d] L1 →
+                        ∀L2. L1 ⊑×[d, ∞] L2 → |L1| = |L2| → L ⋕[T, d] L2.
+/5 width=4 by lsuby_lleq_trans, lleq_sym, lsuby_sym/ qed-.
+
+lemma lleq_lsuby_repl: ∀L1,L2,T,d. L1 ⋕[T, d] L2 →
+                       ∀K1. K1 ⊑×[d, ∞] L1 → |K1| = |L1| →
+                       ∀K2. L2 ⊑×[d, ∞] K2 → |L2| = |K2| →
+                       K1 ⋕[T, d] K2.
+/3 width=4 by lleq_lsuby_trans, lsuby_lleq_trans/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lleq_fwd_length: ∀L1,L2,T,d. L1 ⋕[T, d] L2 → |L1| = |L2|.
+#L1 #L2 #T #d * //
+qed-.
+
+lemma lleq_fwd_ldrop_sn: ∀L1,L2,T,d. L1 ⋕[d, T] L2 → ∀K1,i. ⇩[i] L1 ≡ K1 →
+                         ∃K2. ⇩[i] L2 ≡ K2.
+#L1 #L2 #T #d #H #K1 #i #HLK1 lapply (lleq_fwd_length … H) -H
+#HL12 lapply (ldrop_fwd_length_le2 … HLK1) -HLK1 /2 width=1 by ldrop_O1_le/
+qed-.
+
+lemma lleq_fwd_ldrop_dx: ∀L1,L2,T,d. L1 ⋕[d, T] L2 → ∀K2,i. ⇩[i] L2 ≡ K2 →
+                         ∃K1. ⇩[i] L1 ≡ K1.
+/3 width=6 by lleq_fwd_ldrop_sn, lleq_sym/ qed-.
+
+lemma lleq_fwd_bind_sn: ∀a,I,L1,L2,V,T,d.
+                        L1 ⋕[ⓑ{a,I}V.T, d] L2 → L1 ⋕[V, d] L2.
+#a #I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
+#U elim (H (ⓑ{a,I}U.T)) -H
+#H1 #H2 @conj
+#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
+/2 width=1 by cpys_bind/ -H
+#H elim (cpys_inv_bind1 … H) -H
+#X #Y #H1 #H2 #H destruct //
+qed-.
+
+lemma lleq_fwd_bind_dx: ∀a,I,L1,L2,V,T,d.
+                        L1 ⋕[ⓑ{a,I}V.T, d] L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V.
+#a #I #L1 #L2 #V #T #d * #HL12 #H @conj [ normalize // ] -HL12
+#U elim (H (ⓑ{a,I}V.U)) -H
+#H1 #H2 @conj
+#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
+/2 width=1 by cpys_bind/ -H
+#H elim (cpys_inv_bind1 … H) -H
+#X #Y #H1 #H2 #H destruct //
+qed-.
+
+lemma lleq_fwd_flat_sn: ∀I,L1,L2,V,T,d.
+                        L1 ⋕[ⓕ{I}V.T, d] L2 → L1 ⋕[V, d] L2.
+#I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
+#U elim (H (ⓕ{I}U.T)) -H
+#H1 #H2 @conj
+#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
+/2 width=1 by cpys_flat/ -H
+#H elim (cpys_inv_flat1 … H) -H
+#X #Y #H1 #H2 #H destruct //
+qed-.
+
+lemma lleq_fwd_flat_dx: ∀I,L1,L2,V,T,d.
+                        L1 ⋕[ⓕ{I}V.T, d] L2 → L1 ⋕[T, d] L2.
+#I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
+#U elim (H (ⓕ{I}V.U)) -H
+#H1 #H2 @conj
+#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
+/2 width=1 by cpys_flat/ -H
+#H elim (cpys_inv_flat1 … H) -H
+#X #Y #H1 #H2 #H destruct //
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lleq_inv_bind: ∀a,I,L1,L2,V,T,d. L1 ⋕[ⓑ{a,I}V.T, d] L2 →
+                     L1 ⋕[V, d] L2 ∧ L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V.
+/3 width=4 by lleq_fwd_bind_sn, lleq_fwd_bind_dx, conj/ qed-.
+
+lemma lleq_inv_flat: ∀I,L1,L2,V,T,d. L1 ⋕[ⓕ{I}V.T, d] L2 →
+                     L1 ⋕[V, d] L2 ∧ L1 ⋕[T, d] L2.
+/3 width=3 by lleq_fwd_flat_sn, lleq_fwd_flat_dx, conj/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_alt.etc
new file mode 100644 (file)
index 0000000..a8fb526
--- /dev/null
@@ -0,0 +1,85 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/notation/relations/lazyeqalt_4.ma".
+include "basic_2/substitution/lleq_lleq.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+(* Note: alternative definition of lleq *)
+inductive lleqa: relation4 ynat term lenv lenv ≝
+| lleqa_sort: ∀L1,L2,d,k. |L1| = |L2| → lleqa d (⋆k) L1 L2
+| lleqa_skip: ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → lleqa d (#i) L1 L2
+| lleqa_lref: ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
+              ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
+              lleqa (yinj 0) V K1 K2 → lleqa d (#i) L1 L2
+| lleqa_free: ∀L1,L2,d,i. |L1| = |L2| → |L1| ≤ i → |L2| ≤ i → lleqa d (#i) L1 L2
+| lleqa_gref: ∀L1,L2,d,p. |L1| = |L2| → lleqa d (§p) L1 L2
+| lleqa_bind: ∀a,I,L1,L2,V,T,d.
+              lleqa d V L1 L2 → lleqa (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
+              lleqa d (ⓑ{a,I}V.T) L1 L2
+| lleqa_flat: ∀I,L1,L2,V,T,d.
+              lleqa d V L1 L2 → lleqa d T L1 L2 → lleqa d (ⓕ{I}V.T) L1 L2
+.
+
+interpretation
+   "lazy equivalence (local environment) alternative"
+   'LazyEqAlt T d L1 L2 = (lleqa d T L1 L2).
+
+(* Main inversion lemmas ****************************************************)
+
+theorem lleqa_inv_lleq: ∀L1,L2,T,d. L1 ⋕⋕[T, d] L2 → L1 ⋕[T, d] L2.
+#L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+/2 width=8 by lleq_flat, lleq_bind, lleq_gref, lleq_free, lleq_lref, lleq_skip, lleq_sort/
+qed-.
+
+(* Main properties **********************************************************)
+
+theorem lleq_lleqa: ∀L1,T,L2,d. L1 ⋕[T, d] L2 → L1 ⋕⋕[T, d] L2.
+#L1 #T @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * * /3 width=3 by lleqa_gref, lleqa_sort, lleq_fwd_length/
+[ #i #Hn #L2 #d #H elim (lleq_fwd_lref … H) [ * || * ]
+  /4 width=9 by lleqa_free, lleqa_lref, lleqa_skip, lleq_fwd_length, ldrop_fwd_rfw/
+| #a #I #V #T #Hn #L2 #d #H elim (lleq_inv_bind … H) -H /3 width=1 by lleqa_bind/
+| #I #V #T #Hn #L2 #d #H elim (lleq_inv_flat … H) -H /3 width=1 by lleqa_flat/
+]
+qed.
+
+(* Advanced eliminators *****************************************************)
+
+lemma lleq_ind_alt: ∀R:relation4 ynat term lenv lenv. (
+                       ∀L1,L2,d,k. |L1| = |L2| → R d (⋆k) L1 L2
+                    ) → (
+                       ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → R d (#i) L1 L2
+                    ) → (
+                       ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
+                       ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
+                       K1 ⋕[V, yinj O] K2 → R (yinj O) V K1 K2 → R d (#i) L1 L2
+                    ) → (
+                       ∀L1,L2,d,i. |L1| = |L2| → |L1| ≤ i → |L2| ≤ i → R d (#i) L1 L2
+                    ) → (
+                       ∀L1,L2,d,p. |L1| = |L2| → R d (§p) L1 L2
+                    ) → (
+                       ∀a,I,L1,L2,V,T,d.
+                       L1 ⋕[V, d]L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V →
+                       R d V L1 L2 → R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → R d (ⓑ{a,I}V.T) L1 L2
+                    ) → (
+                       ∀I,L1,L2,V,T,d.
+                       L1 ⋕[V, d]L2 → L1 ⋕[T, d] L2 →
+                       R d V L1 L2 → R d T L1 L2 → R d (ⓕ{I}V.T) L1 L2
+                    ) →
+                    ∀d,T,L1,L2. L1 ⋕[T, d] L2 → R d T L1 L2.
+#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #d #T #L1 #L2 #H elim (lleq_lleqa … H) -H
+/3 width=9 by lleqa_inv_lleq/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ext.etc
new file mode 100644 (file)
index 0000000..d6bb03f
--- /dev/null
@@ -0,0 +1,91 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/lleq_alt.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+fact lleq_inv_S_aux: ∀L1,L2,T,d0. L1 ⋕[T, d0] L2 → ∀d. d0 = d + 1 →
+                     ∀K1,K2,I,V. ⇩[d] L1 ≡ K1.ⓑ{I}V → ⇩[d] L2 ≡ K2.ⓑ{I}V →
+                     K1 ⋕[V, 0] K2 → L1 ⋕[T, d] L2.
+#L1 #L2 #T #d0 #H @(lleq_ind_alt … H) -L1 -L2 -T -d0
+/2 width=1 by lleq_gref, lleq_free, lleq_sort/
+[ #L1 #L2 #d0 #i #HL12 #Hid #d #H #K1 #K2 #I #V #HLK1 #HLK2 #HV destruct
+  elim (yle_split_eq i d) /2 width=1 by lleq_skip, ylt_fwd_succ2/ -HL12 -Hid
+  #H destruct /2 width=8 by lleq_lref/
+| #I1 #I2 #L1 #L2 #K11 #K22 #V #d0 #i #Hd0i #HLK11 #HLK22 #HV #_ #d #H #K1 #K2 #J #W #_ #_ #_ destruct
+  /3 width=8 by lleq_lref, yle_pred_sn/
+| #a #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W #HLK1 #HLK2 destruct
+  /4 width=7 by lleq_bind, ldrop_drop/
+| #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W #HLK1 #HLK2 destruct
+  /3 width=7 by lleq_flat/
+]
+qed-.
+
+lemma lleq_inv_S: ∀T,L1,L2,d. L1 ⋕[T, d+1] L2 →
+                  ∀K1,K2,I,V. ⇩[d] L1 ≡ K1.ⓑ{I}V → ⇩[d] L2 ≡ K2.ⓑ{I}V →
+                  K1 ⋕[V, 0] K2 → L1 ⋕[T, d] L2.
+/2 width=7 by lleq_inv_S_aux/ qed-.
+
+lemma lleq_inv_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[ⓑ{a,I}V.T, 0] L2 →
+                       L1 ⋕[V, 0] L2 ∧ L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V.
+#a #I #L1 #L2 #V #T #H elim (lleq_inv_bind … H) -H
+/3 width=7 by ldrop_pair, conj, lleq_inv_S/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lleq_fwd_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[ⓑ{a,I}V.T, 0] L2 →
+                       L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V.
+#a #I #L1 #L2 #V #T #H elim (lleq_inv_bind_O … H) -H //
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lleq_ge: ∀L1,L2,T,d1. L1 ⋕[T, d1] L2 → ∀d2. d1 ≤ d2 → L1 ⋕[T, d2] L2.
+#L1 #L2 #T #d1 #H @(lleq_ind_alt … H) -L1 -L2 -T -d1
+/4 width=1 by lleq_sort, lleq_free, lleq_gref, lleq_bind, lleq_flat, yle_succ/
+[ /3 width=3 by lleq_skip, ylt_yle_trans/
+| #I1 #I2 #L1 #L2 #K1 #K2 #V #d1 #i #Hi #HLK1 #HLK2 #HV #IHV #d2 #Hd12 elim (ylt_split i d2)
+  [ lapply (lleq_fwd_length … HV) #HK12 #Hid2
+    lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
+    normalize in ⊢ (%→%→?); -I1 -I2 -V -d1 /2 width=1 by lleq_skip/ 
+  | /3 width=8 by lleq_lref, yle_trans/
+  ]
+]
+qed-.
+
+lemma lleq_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[V, 0] L2 → L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V →
+                   L1 ⋕[ⓑ{a,I}V.T, 0] L2.
+/3 width=3 by lleq_ge, lleq_bind/ qed.
+
+lemma lleq_bind_repl_SO: ∀I1,I2,L1,L2,V1,V2,T. L1.ⓑ{I1}V1 ⋕[T, 0] L2.ⓑ{I2}V2 →
+                         ∀J1,J2,W1,W2. L1.ⓑ{J1}W1 ⋕[T, 1] L2.ⓑ{J2}W2.
+#I1 #I2 #L1 #L2 #V1 #V2 #T #HT #J1 #J2 #W1 #W2 lapply (lleq_ge … HT 1 ?) // -HT
+#HT @(lleq_lsuby_repl … HT) /2 width=1 by lsuby_succ/ (**) (* full auto fails *)
+qed-.
+
+lemma lleq_bind_repl_O: ∀I,L1,L2,V,T. L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V →
+                        ∀J,W. L1 ⋕[W, 0] L2 → L1.ⓑ{J}W ⋕[T, 0] L2.ⓑ{J}W.
+/3 width=7 by lleq_bind_repl_SO, lleq_inv_S/ qed-.
+
+(* Inversion lemmas on negated lazy quivalence for local environments *******)
+
+lemma nlleq_inv_bind_O: ∀a,I,L1,L2,V,T. (L1 ⋕[ⓑ{a,I}V.T, 0] L2 → ⊥) →
+                        (L1 ⋕[V, 0] L2 → ⊥) ∨ (L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V → ⊥).
+#a #I #L1 #L2 #V #T #H elim (lleq_dec V L1 L2 0)
+/4 width=1 by lleq_bind_O, or_intror, or_introl/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_fqus.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_fqus.etc
new file mode 100644 (file)
index 0000000..18744a5
--- /dev/null
@@ -0,0 +1,75 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/fqus_alt.ma".
+include "basic_2/substitution/lleq_ext.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+(* Properties on supclosure and derivatives *********************************)
+
+lemma lleq_fqu_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃ ⦃G2, K2, U⦄ →
+                      ∀L1. L1 ⋕[T, 0] L2 →
+                      ∃∃K1. ⦃G1, L1, T⦄ ⊃ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
+#G1 #G2 #L2 #K2 #T #U #H elim H -G1 -G2 -L2 -K2 -T -U
+[ #I #G #L2 #V #L1 #H elim (lleq_inv_lref_ge_dx … H … I L2 V) -H //
+  #I1 #K1 #H1 #H2 lapply (ldrop_inv_O2 … H1) -H1
+  #H destruct /2 width=3 by fqu_lref_O, ex2_intro/
+| * [ #a ] #I #G #L2 #V #T #L1 #H
+  [ elim (lleq_inv_bind … H)
+  | elim (lleq_inv_flat … H)
+  ] -H
+  /2 width=3 by fqu_pair_sn, ex2_intro/
+| #a #I #G #L2 #V #T #L1 #H elim (lleq_inv_bind_O … H) -H
+  #H3 #H4 /2 width=3 by fqu_bind_dx, ex2_intro/
+| #I #G #L2 #V #T #L1 #H elim (lleq_inv_flat … H) -H
+  /2 width=3 by fqu_flat_dx, ex2_intro/
+| #G #L2 #K2 #T #U #e #HLK2 #HTU #L1 #HL12
+  elim (ldrop_O1_le (e+1) L1)
+  [ /3 width=12 by fqu_drop, lleq_inv_lift_le, ex2_intro/
+  | lapply (ldrop_fwd_length_le2 … HLK2) -K2
+    lapply (lleq_fwd_length … HL12) -T -U //
+  ]
+]
+qed-.
+
+lemma lleq_fquq_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃⸮ ⦃G2, K2, U⦄ →
+                       ∀L1. L1 ⋕[T, 0] L2 →
+                       ∃∃K1. ⦃G1, L1, T⦄ ⊃⸮ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
+#G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fquq_inv_gen … H) -H
+[ #H elim (lleq_fqu_trans … H … HL12) -L2 /3 width=3 by fqu_fquq, ex2_intro/
+| * #HG #HL #HT destruct /2 width=3 by ex2_intro/
+]
+qed-.
+
+lemma lleq_fqup_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃+ ⦃G2, K2, U⦄ →
+                       ∀L1. L1 ⋕[T, 0] L2 →
+                       ∃∃K1. ⦃G1, L1, T⦄ ⊃+ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
+#G1 #G2 #L2 #K2 #T #U #H @(fqup_ind … H) -G2 -K2 -U
+[ #G2 #K2 #U #HTU #L1 #HL12 elim (lleq_fqu_trans … HTU … HL12) -L2
+  /3 width=3 by fqu_fqup, ex2_intro/
+| #G #G2 #K #K2 #U #U2 #_ #HU2 #IHTU #L1 #HL12 elim (IHTU … HL12) -L2
+  #K1 #HTU #HK1 elim (lleq_fqu_trans … HU2 … HK1) -K
+  /3 width=5 by fqup_strap1, ex2_intro/
+]
+qed-.
+
+lemma lleq_fqus_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃* ⦃G2, K2, U⦄ →
+                       ∀L1. L1 ⋕[T, 0] L2 →
+                       ∃∃K1. ⦃G1, L1, T⦄ ⊃* ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
+#G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fqus_inv_gen … H) -H
+[ #H elim (lleq_fqup_trans … H … HL12) -L2 /3 width=3 by fqup_fqus, ex2_intro/
+| * #HG #HL #HT destruct /2 width=3 by ex2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ldrop.etc
new file mode 100644 (file)
index 0000000..9cb597c
--- /dev/null
@@ -0,0 +1,123 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/cpys_lift.ma".
+include "basic_2/substitution/lleq.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+(* Advanced properties ******************************************************)
+
+lemma lleq_skip: ∀L1,L2,d,i. yinj i < d → |L1| = |L2| → L1 ⋕[#i, d] L2.
+#L1 #L2 #d #i #Hid #HL12 @conj // -HL12
+#U @conj #H elim (cpys_inv_lref1 … H) -H // *
+#I #Z #Y #X #H elim (ylt_yle_false … Hid … H)
+qed.
+
+lemma lleq_lref: ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
+                 ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
+                 K1 ⋕[V, 0] K2 → L1 ⋕[#i, d] L2.
+#I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 * #HK12 #IH @conj [ -IH | -HK12 ]
+[ lapply (ldrop_fwd_length … HLK1) -HLK1 #H1
+  lapply (ldrop_fwd_length … HLK2) -HLK2 #H2
+  >H1 >H2 -H1 -H2 normalize //
+| #U @conj #H elim (cpys_inv_lref1 … H) -H // *
+  >yminus_Y_inj #I #K #X #W #_ #_ #H #HVW #HWU
+  [ letin HLK ≝ HLK1 | letin HLK ≝ HLK2 ]
+  lapply (ldrop_mono … H … HLK) -H #H destruct elim (IH W)
+  /3 width=7 by cpys_subst_Y2/
+]
+qed.
+
+lemma lleq_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → L1 ⋕[#i, d] L2.
+#L1 #L2 #d #i #HL1 #HL2 #HL12 @conj // -HL12
+#U @conj #H elim (cpys_inv_lref1 … H) -H // *
+#I #Z #Y #X #_ #_ #H lapply (ldrop_fwd_length_lt2 … H) -H
+#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
+qed.
+
+(* Properties on relocation *************************************************)
+
+lemma lleq_lift_le: ∀K1,K2,T,dt. K1 ⋕[T, dt] K2 →
+                    ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                    ∀U. ⇧[d, e] T ≡ U → dt ≤ d → L1 ⋕[U, dt] L2.
+#K1 #K2 #T #dt * #HK12 #IHT #L1 #L2 #d #e #HLK1 #HLK2 #U #HTU #Hdtd
+lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
+#H2 #H1 @conj // -HK12 -H1 -H2 #U0 @conj #HU0
+[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 ]
+elim (cpys_inv_lift1_be … HU0 … HLKA … HTU) // -HU0 >yminus_Y_inj #T0 #HT0 #HTU0
+elim (IHT T0) [ #H #_ | #_ #H ] -IHT /3 width=12 by cpys_lift_be/
+qed-.
+
+lemma lleq_lift_ge: ∀K1,K2,T,dt. K1 ⋕[T, dt] K2 →
+                    ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                    ∀U. ⇧[d, e] T ≡ U → d ≤ dt → L1 ⋕[U, dt+e] L2.
+#K1 #K2 #T #dt * #HK12 #IHT #L1 #L2 #d #e #HLK1 #HLK2 #U #HTU #Hddt
+lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
+#H2 #H1 @conj // -HK12 -H1 -H2 #U0 @conj #HU0
+[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 ]
+elim (cpys_inv_lift1_ge … HU0 … HLKA … HTU) /2 width=1 by monotonic_yle_plus_dx/ -HU0 >yplus_minus_inj #T0 #HT0 #HTU0
+elim (IHT T0) [ #H #_ | #_ #H ] -IHT /3 width=10 by cpys_lift_ge/
+qed-.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma lleq_inv_lift_le: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
+                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                        ∀T. ⇧[d, e] T ≡ U → dt ≤ d → K1 ⋕[T, dt] K2.
+#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hdtd
+lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
+#H2 #H1 @conj // -HL12 -H1 -H2
+#T0 elim (lift_total T0 d e)
+#U0 #HTU0 elim (IH U0) -IH
+#H12 #H21 @conj #HT0
+[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
+lapply (cpys_lift_be … HT0 … HLKA … HTU … HTU0) // -HT0
+>yplus_Y1 #HU0 elim (cpys_inv_lift1_be … (H0 HU0) … HLKB … HTU) // -L1 -L2 -U -Hdtd
+#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
+qed-.
+
+lemma lleq_inv_lift_ge: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
+                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                        ∀T. ⇧[d, e] T ≡ U → yinj d + e ≤ dt → K1 ⋕[T, dt-e] K2.
+#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hdedt
+lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
+#H2 #H1 @conj // -HL12 -H1 -H2
+elim (yle_inv_plus_inj2 … Hdedt) #Hddt #Hedt
+#T0 elim (lift_total T0 d e)
+#U0 #HTU0 elim (IH U0) -IH
+#H12 #H21 @conj #HT0
+[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
+lapply (cpys_lift_ge … HT0 … HLKA … HTU … HTU0) // -HT0 -Hddt
+>ymax_pre_sn // #HU0 elim (cpys_inv_lift1_ge … (H0 HU0) … HLKB … HTU) // -L1 -L2 -U -Hdedt -Hedt
+#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
+qed-.
+
+lemma lleq_inv_lift_be: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
+                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                        ∀T. ⇧[d, e] T ≡ U → d ≤ dt → dt ≤ yinj d + e → K1 ⋕[T, d] K2.
+#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hddt #Hdtde
+lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
+#H2 #H1 @conj // -HL12 -H1 -H2
+#T0 elim (lift_total T0 d e)
+#U0 #HTU0 elim (IH U0) -IH
+#H12 #H21 @conj #HT0
+[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
+lapply (cpys_lift_ge … HT0 … HLKA … HTU … HTU0) // -HT0
+#HU0 lapply (cpys_weak … HU0 dt (∞) ? ?) // -HU0
+#HU0 lapply (H0 HU0)
+#HU0 lapply (cpys_weak … HU0 d (∞) ? ?) // -HU0
+#HU0 elim (cpys_inv_lift1_ge_up … HU0 … HLKB … HTU) // -L1 -L2 -U -Hddt -Hdtde
+#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_lleq.etc
new file mode 100644 (file)
index 0000000..2a8873d
--- /dev/null
@@ -0,0 +1,175 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/cpys_cpys.ma".
+include "basic_2/substitution/lleq_ldrop.ma".
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lleq_fwd_lref: ∀L1,L2. ∀d:ynat. ∀i:nat. L1 ⋕[#i, d] L2 →
+                     ∨∨ |L1| ≤ i ∧ |L2| ≤ i
+                      | yinj i < d
+                      | ∃∃I1,I2,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V &
+                                         ⇩[i] L2 ≡ K2.ⓑ{I2}V &
+                                         K1 ⋕[V, yinj 0] K2 & d ≤ yinj i.
+#L1 #L2 #d #i * #HL12 #IH elim (lt_or_ge i (|L1|)) /3 width=3 by or3_intro0, conj/
+elim (ylt_split i d) /2 width=1 by or3_intro1/ #Hdi #Hi
+elim (ldrop_O1_lt … Hi) #I1 #K1 #V1 #HLK1
+elim (ldrop_O1_lt L2 i) // -Hi #I2 #K2 #V2 #HLK2
+lapply (ldrop_fwd_length_minus2 … HLK2) #H
+lapply (ldrop_fwd_length_minus2 … HLK1) >HL12 <H -HL12 -H
+#H lapply (injective_plus_l … H) -H #HK12
+elim (lift_total V1 0 (i+1)) #W1 #HVW1
+elim (lift_total V2 0 (i+1)) #W2 #HVW2
+elim (IH W1) elim (IH W2) #_ #H2 #H1 #_
+elim (cpys_inv_lref1_ldrop … (H1 ?) … HLK2 … HVW1) -H1
+[ elim (cpys_inv_lref1_ldrop … (H2 ?) … HLK1 … HVW2) -H2 ]
+/3 width=7 by cpys_subst, yle_inj/ -W1 -W2 #H12 #_ #_ #H21 #_ #_
+lapply (cpys_antisym_eq … H12 … H21) -H12 -H21 #H destruct
+@or3_intro2 @(ex4_5_intro … HLK1 HLK2) // @conj // -HK12
+#V elim (lift_total V 0 (i+1))
+#W #HVW elim (IH W) -IH #H12 #H21 @conj #H
+[ elim (cpys_inv_lref1_ldrop … (H12 ?) … HLK2 … HVW) -H12 -H21
+| elim (cpys_inv_lref1_ldrop … (H21 ?) … HLK1 … HVW) -H21 -H12
+] [1,3: >yminus_Y_inj ] /3 width=7 by cpys_subst_Y2, yle_inj/
+qed-.
+
+lemma lleq_fwd_lref_dx: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 →
+                        ∀I2,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I2}V →
+                        i < d ∨
+                        ∃∃I1,K1. ⇩[i] L1 ≡ K1.ⓑ{I1}V & K1 ⋕[V, 0] K2 & d ≤ i.
+#L1 #L2 #d #i #H #I2 #K2 #V #HLK2 elim (lleq_fwd_lref … H) -H [ * || * ]
+[ #_ #H elim (lt_refl_false i)
+  lapply (ldrop_fwd_length_lt2 … HLK2) -HLK2
+  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
+| /2 width=1 by or_introl/
+| #I1 #I2 #K11 #K22 #V0 #HLK11 #HLK22 #HV0 #Hdi lapply (ldrop_mono … HLK22 … HLK2) -L2
+  #H destruct /3 width=5 by ex3_2_intro, or_intror/
+]
+qed-.
+
+lemma lleq_fwd_lref_sn: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 →
+                        ∀I1,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V →
+                        i < d ∨
+                        ∃∃I2,K2. ⇩[i] L2 ≡ K2.ⓑ{I2}V & K1 ⋕[V, 0] K2 & d ≤ i.
+#L1 #L2 #d #i #HL12 #I1 #K1 #V #HLK1 elim (lleq_fwd_lref_dx L2 … d … HLK1) -HLK1
+[2: * ] /4 width=6 by lleq_sym, ex3_2_intro, or_introl, or_intror/
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma lleq_inv_lref_ge_dx: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
+                           ∀I2,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I2}V →
+                           ∃∃I1,K1. ⇩[i] L1 ≡ K1.ⓑ{I1}V & K1 ⋕[V, 0] K2.
+#L1 #L2 #d #i #H #Hdi #I2 #K2 #V #HLK2 elim (lleq_fwd_lref_dx … H … HLK2) -L2
+[ #H elim (ylt_yle_false … H Hdi)
+| * /2 width=4 by ex2_2_intro/
+]
+qed-.
+
+lemma lleq_inv_lref_ge_sn: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
+                           ∀I1,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V →
+                           ∃∃I2,K2. ⇩[i] L2 ≡ K2.ⓑ{I2}V & K1 ⋕[V, 0] K2.
+#L1 #L2 #d #i #HL12 #Hdi #I1 #K1 #V #HLK1 elim (lleq_inv_lref_ge_dx L2 … Hdi … HLK1) -Hdi -HLK1
+/3 width=4 by lleq_sym, ex2_2_intro/
+qed-.
+
+lemma lleq_inv_lref_ge_gen: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
+                            ∀I1,I2,K1,K2,V1,V2.
+                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                            V1 = V2 ∧ K1 ⋕[V2, 0] K2.
+#L1 #L2 #d #i #HL12 #Hdi #I1 #I2 #K1 #K2 #V1 #V2 #HLK1 #HLK2
+elim (lleq_inv_lref_ge_sn … HL12 … HLK1) // -L1 -d
+#J #Y #HY lapply (ldrop_mono … HY … HLK2) -L2 -i #H destruct /2 width=1 by conj/
+qed-.
+
+lemma lleq_inv_lref_ge: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
+                        ∀I,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}V →
+                        K1 ⋕[V, 0] K2.
+#L1 #L2 #d #i #HL12 #Hdi #I #K1 #K2 #V #HLK1 #HLK2
+elim (lleq_inv_lref_ge_gen … HL12 … HLK1 HLK2) //
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lleq_dec: ∀T,L1,L2,d. Decidable (L1 ⋕[T, d] L2).
+#T #L1 @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * *
+[ #k #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, lleq_sort/
+| #i #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|))
+  [ #HL12 #d elim (ylt_split i d) /3 width=1 by lleq_skip, or_introl/
+    #Hdi elim (lt_or_ge i (|L1|)) #HiL1
+    elim (lt_or_ge i (|L2|)) #HiL2 /3 width=1 by or_introl, lleq_free/
+    elim (ldrop_O1_lt … HiL2) #I2 #K2 #V2 #HLK2
+    elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
+    elim (eq_term_dec V2 V1)
+    [ #H3 elim (IH K1 V1 … K2 0) destruct
+      /3 width=8 by lleq_lref, ldrop_fwd_rfw, or_introl/
+    ]
+    -IH #H3 @or_intror
+    #H elim (lleq_fwd_lref … H) -H [1,3,4,6: * ]
+    [1,3: /3 width=4 by lt_to_le_to_lt, lt_refl_false/
+    |5,6: /2 width=4 by ylt_yle_false/
+    ]
+    #Z1 #Z2 #Y1 #Y2 #X #HLY1 #HLY2 #HX #_
+    lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1
+    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2
+    #H2 #H1 destruct /2 width=1 by/
+  ]
+| #p #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, lleq_gref/
+| #a #I #V #T #Hn #L2 #d destruct
+  elim (IH L1 V … L2 d) /2 width=1 by/
+  elim (IH (L1.ⓑ{I}V) T … (L2.ⓑ{I}V) (d+1)) -IH /3 width=1 by or_introl, lleq_bind/
+  #H1 #H2 @or_intror
+  #H elim (lleq_inv_bind … H) -H /2 width=1 by/
+| #I #V #T #Hn #L2 #d destruct
+  elim (IH L1 V … L2 d) /2 width=1 by/
+  elim (IH L1 T … L2 d) -IH /3 width=1 by or_introl, lleq_flat/
+  #H1 #H2 @or_intror
+  #H elim (lleq_inv_flat … H) -H /2 width=1 by/
+]
+-n /4 width=3 by lleq_fwd_length, or_intror/
+qed-.
+
+(* Main properties **********************************************************)
+
+theorem lleq_trans: ∀d,T. Transitive … (lleq d T).
+#d #T #L1 #L * #HL1 #IH1 #L2 * #HL2 #IH2 /3 width=3 by conj, iff_trans/
+qed-.
+
+theorem lleq_canc_sn: ∀L,L1,L2,T,d. L ⋕[d, T] L1→ L ⋕[d, T] L2 → L1 ⋕[d, T] L2.
+/3 width=3 by lleq_trans, lleq_sym/ qed-.
+
+theorem lleq_canc_dx: ∀L1,L2,L,T,d. L1 ⋕[d, T] L → L2 ⋕[d, T] L → L1 ⋕[d, T] L2.
+/3 width=3 by lleq_trans, lleq_sym/ qed-.
+
+(* Inversion lemmas on negated lazy quivalence for local environments *******)
+
+lemma nlleq_inv_bind: ∀a,I,L1,L2,V,T,d. (L1 ⋕[ⓑ{a,I}V.T, d] L2 → ⊥) →
+                      (L1 ⋕[V, d] L2 → ⊥) ∨ (L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V → ⊥).
+#a #I #L1 #L2 #V #T #d #H elim (lleq_dec V L1 L2 d)
+/4 width=1 by lleq_bind, or_intror, or_introl/
+qed-.
+
+lemma nlleq_inv_flat: ∀I,L1,L2,V,T,d. (L1 ⋕[ⓕ{I}V.T, d] L2 → ⊥) →
+                      (L1 ⋕[V, d] L2 → ⊥) ∨ (L1 ⋕[T, d] L2 → ⊥).
+#I #L1 #L2 #V #T #d #H elim (lleq_dec V L1 L2 d)
+/4 width=1 by lleq_flat, or_intror, or_introl/
+qed-.
+
+(* Note: lleq_nlleq_trans: ∀d,T,L1,L. L1⋕[T, d] L →
+                           ∀L2. (L ⋕[T, d] L2 → ⊥) → (L1 ⋕[T, d] L2 → ⊥).
+/3 width=3 by lleq_canc_sn/ qed-.
+works with /4 width=8/ so lleq_canc_sn is more convenient
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llor.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llor.etc
new file mode 100644 (file)
index 0000000..6a750a0
--- /dev/null
@@ -0,0 +1,115 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "ground_2/xoa/xoa2.ma".
+include "basic_2/notation/relations/lazyor_4.ma".
+include "basic_2/relocation/lpx_sn_alt.ma".
+include "basic_2/substitution/cofrees.ma".
+
+(* POINTWISE UNION FOR LOCAL ENVIRONMENTS ***********************************)
+
+inductive clor (T) (L2) (I) (K1) (V1): predicate term ≝
+| clor_sn: |K1| < |L2| → |L2|-|K1|-1 ~ϵ 𝐅*⦃K1, T⦄ → clor T L2 I K1 V1 V1
+| clor_dx: ∀K2,V2. |K1| < |L2| → (|L2|-|K1|-1 ~ϵ 𝐅*⦃K1, T⦄ → ⊥) →
+           ⇩[|L2|-|K1|-1] L2 ≡ K2.ⓑ{I}V2 → clor T L2 I K1 V1 V2
+.
+
+definition llor: relation4 term lenv lenv lenv ≝
+                 λT,L2. lpx_sn (clor T L2).
+
+interpretation
+   "lazy union (local environment)"
+   'LazyOr L1 T L2 L = (llor T L2 L1 L).
+
+(* Basic properties *********************************************************)
+
+lemma llor_pair_sn: ∀I,L1,L2,L,V,T. L1 ⩖[T] L2 ≡ L →
+                    |L1| < |L2| → |L2|-|L1|-1 ~ϵ 𝐅*⦃L1, T⦄ →
+                    L1.ⓑ{I}V ⩖[T] L2 ≡ L.ⓑ{I}V.
+/3 width=2 by clor_sn, lpx_sn_pair/ qed.
+
+lemma llor_pair_dx: ∀I,L1,L2,L,K2,V1,V2,T. L1 ⩖[T] L2 ≡ L →
+                    |L1| < |L2| → (|L2|-|L1|-1 ~ϵ 𝐅*⦃L1, T⦄ → ⊥) →
+                    ⇩[|L2|-|L1|-1] L2 ≡ K2.ⓑ{I}V2 →
+                    L1.ⓑ{I}V1 ⩖[T] L2 ≡ L.ⓑ{I}V2.
+/4 width=3 by clor_dx, lpx_sn_pair/ qed.
+(*
+lemma llor_total: ∀T,L2,L1. |L1| ≤ |L2| → ∃L. L1 ⩖[T] L2 ≡ L.
+#T #L2 #L1 elim L1 -L1 /2 width=2 by ex_intro/
+#L1 #I1 #V1 #IHL1 normalize
+#H elim IHL1 -IHL1 /2 width=3 by transitive_le/
+#L #HT elim (cofrees_dec L1 T (|L2|-|L1|-1))
+[ /3 width=2 by llor_pair_sn, ex_intro/
+| elim (ldrop_O1_lt L2 (|L2|-|L1|-1))
+  /5 width=4 by llor_pair_dx, monotonic_lt_minus_l, ex_intro/
+| 
+]
+qed-.
+*)
+(* Alternative definition ***************************************************)
+
+(* Note: uses minus_minus_comm, minus_plus_m_m, commutative_plus, plus_minus *)
+lemma plus_minus_minus_be: ∀x,y,z:nat. y ≤ z → z ≤ x → (x - z) + (z - y) = x - y.
+#x #z #y #Hzy #Hyx >plus_minus // >commutative_plus >plus_minus //
+qed-.
+
+fact plus_minus_minus_be_aux: ∀i,x,y,z:nat. y ≤ z → z ≤ x → i = z - y → x - z + i = x - y.
+/2 width=1 by plus_minus_minus_be/ qed-.
+
+lemma llor_intro_alt: ∀T,L2,L1,L. |L1| ≤ |L2| → |L1| = |L| →
+                      (∀I1,I,K1,K,V1,V,i. ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L ≡ K.ⓑ{I}V →
+                         (|L2|-|L1|+i ~ϵ 𝐅*⦃K1, T⦄ → I1 = I ∧ V1 = V) ∧
+                         (∀I2,K2,V2. (|L2|-|L1|+i ~ϵ 𝐅*⦃K1, T⦄  → ⊥) →
+                                     ⇩[|L2|-|L1|+i] L2 ≡ K2.ⓑ{I2}V2 →
+                                     ∧∧ I1 = I & I2 = I & V2 = V 
+                         )
+                      ) → L1 ⩖[T] L2 ≡ L.
+#T #L2 #L1 #L #HL12 #HL1 #IH @lpx_sn_intro_alt // -HL1
+#I1 #I #K1 #K #V1 #V #i #HLK1 #HLK
+lapply (ldrop_fwd_length_minus4 … HLK1)
+lapply (ldrop_fwd_length_le4 … HLK1)
+normalize #HKL1 #H1i lapply (plus_minus_minus_be_aux … HL12 H1i) // #H2i
+lapply (transitive_le … HKL1 HL12) -HKL1 -HL12 #HKL1
+elim (IH … HLK1 HLK) -IH -HLK1 -HLK #IH1 #IH2
+elim (cofrees_dec K1 T (|L2|-|L1|+i))
+[ -IH2 #HT elim (IH1 … HT) -IH1
+  /3 width=2 by clor_sn, conj/
+| -IH1 #H elim (ldrop_O1_lt L2 (|L2|-|L1|+i)) /2 width=1 by monotonic_lt_minus_l/
+  #I2 #K2 #V2 #HLK2 elim (IH2 … HLK2) -IH2
+  /5 width=3 by clor_dx, ex_intro, and3_intro/
+]
+qed.
+
+lemma llor_inv_alt: ∀T,L2,L1,L. L1 ⩖[T] L2 ≡ L → |L1| ≤ |L2| →
+                    |L1| = |L| ∧
+                    (∀I1,I,K1,K,V1,V,i.
+                       ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L ≡ K.ⓑ{I}V →
+                       (∃∃U. ⇧[|L2|-|L1|+i, 1] U ≡ T &
+                             I1 = I & V1 = V & K1 ⩖[T] L2 ≡ K
+                       ) ∨
+                       (∃∃I2,K2,V2. (∀U. ⇧[|L2|-|L1|+i, 1] U ≡ T → ⊥) &
+                                    ⇩[|L2|-|L1|+i] L2 ≡ K2.ⓑ{I2}V2 &
+                                    I1 = I & V2 = V & K1 ⩖[T] L2 ≡ K
+                       )
+                    ).
+#T #L2 #L1 #L #H #HL12 elim (lpx_sn_inv_alt … H) -H
+#HL1 #IH @conj // -HL1
+#I1 #I #K1 #K #V1 #V #i #HLK1 #HLK
+lapply (ldrop_fwd_length_minus4 … HLK1)
+lapply (ldrop_fwd_length_le4 … HLK1)
+normalize #HKL1 #H1i lapply (plus_minus_minus_be_aux … HL12 H1i) //
+lapply (transitive_le … HKL1 HL12) -HKL1 -HL12
+elim (IH … HLK1 HLK) -IH #H *
+/4 width=5 by ex5_3_intro, ex4_intro, or_intror, or_introl/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn_alt2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn_alt2.etc
new file mode 100644 (file)
index 0000000..bdbc32e
--- /dev/null
@@ -0,0 +1,45 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/cofrees_lift.ma".
+include "basic_2/substitution/llpx_sn_alt1.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* alternative definition of llpx_sn (not recursive) *)
+definition llpx_sn_alt2: relation4 bind2 lenv term term → relation4 ynat term lenv lenv ≝
+                         λR,d,T,L1,L2. |L1| = |L2| ∧
+                         (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (L1 ⊢ i ~ϵ 𝐅*[d]⦃T⦄ → ⊥) →
+                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                            I1 = I2 ∧ R I1 K1 V1 V2
+                         ).
+
+(* Main properties **********************************************************)
+
+lemma cpy_inv_nlift2_be: ∀G,L,U1,U2,d. ⦃G, L⦄ ⊢ U1 ▶[d, ∞] U2 → ∀i. d ≤ yinj i →
+                         ∀K,s. ⇩[s, i, 1] L ≡ K →
+                         (∀T2. ⇧[i, 1] T2 ≡ U2 → ⊥) → (∀T1. ⇧[i, 1] T1 ≡ U1 → ⊥).
+#G #L #U1 #U2 #d #HU12 #i #Hdi #K #s #HLK #HnU2 #T1 #HTU1
+elim (cpy_inv_lift1_be … HU12 … HLK … HTU1) /2 width=2 by/
+qed-.
+
+theorem llpx_sn_llpx_sn_alt2: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → llpx_sn_alt2 R d T L1 L2.
+#R #L1 #L2 #U1 #d #H elim (llpx_sn_inv_alt1 … H) -H
+#HL12 #IH @conj // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnU1 #HLK1 #HLK2 elim (frees_inv_gen … HnU1) -HnU1
+#U2 #H generalize in match IH; -IH @(cpys_ind_dx … H) -U1
+[ #IH #HnU2 elim (IH … HnU2 … HLK1 HLK2) -L1 -L2 -U2 /2 width=1 by conj/
+| #U1 #U0 #HU10 #_ #IHU02 #IH #HnU2 @IHU02 /2 width=2 by/ -I1 -I2 -K1 -K2 -V1 -V2 -U2 -i
+  #I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnU0 #HLK1 #HLK2 @(IH … HLK1 HLK2) -IH // -R -I2 -L2 -K2 -V2
+  @(cpy_inv_nlift2_be … HU10) /2 width=3 by/   
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llor.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llor.etc
deleted file mode 100644 (file)
index a2f332a..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "ground_2/xoa/xoa2.ma".
-include "basic_2/notation/relations/lazyor_4.ma".
-include "basic_2/relocation/lpx_sn_alt.ma".
-
-(* POINTWISE UNION FOR LOCAL ENVIRONMENTS ***********************************)
-
-inductive clor (T) (L2) (K1) (V1): predicate term ≝
-| clor_sn: ∀U. |K1| < |L2| → ⇧[|L2|-|K1|-1, 1] U ≡ T → clor T L2 K1 V1 V1
-| clor_dx: ∀I,K2,V2. |K1| < |L2| → (∀U. ⇧[|L2|-|K1|-1, 1] U ≡ T → ⊥) →
-           ⇩[|L2|-|K1|-1] L2 ≡ K2.ⓑ{I}V2 → clor T L2 K1 V1 V2
-.
-
-definition llor: relation4 term lenv lenv lenv ≝
-                 λT,L2. lpx_sn (clor T L2).
-
-interpretation
-   "lazy union (local environment)"
-   'LazyOr L1 T L2 L = (llor T L2 L1 L).
-
-(* Basic properties *********************************************************)
-
-lemma llor_pair_sn: ∀I,L1,L2,L,V,T,U. L1 ⩖[T] L2 ≡ L →
-                    |L1| < |L2| → ⇧[|L2|-|L1|-1, 1] U ≡ T →
-                    L1.ⓑ{I}V ⩖[T] L2 ≡ L.ⓑ{I}V.
-/3 width=2 by clor_sn, lpx_sn_pair/ qed.
-
-lemma llor_pair_dx: ∀I,J,L1,L2,L,K2,V1,V2,T. L1 ⩖[T] L2 ≡ L →
-                    |L1| < |L2| → (∀U. ⇧[|L2|-|L1|-1, 1] U ≡ T → ⊥) →
-                    ⇩[|L2|-|L1|-1] L2 ≡ K2.ⓑ{J}V2 →
-                    L1.ⓑ{I}V1 ⩖[T] L2 ≡ L.ⓑ{I}V2.
-/4 width=3 by clor_dx, lpx_sn_pair/ qed.
-
-lemma llor_total: ∀T,L2,L1. |L1| ≤ |L2| → ∃L. L1 ⩖[T] L2 ≡ L.
-#T #L2 #L1 elim L1 -L1 /2 width=2 by ex_intro/
-#L1 #I1 #V1 #IHL1 normalize
-#H elim IHL1 -IHL1 /2 width=3 by transitive_le/
-#L #HT elim (is_lift_dec T (|L2|-|L1|-1) 1)
-[ * /3 width=2 by llor_pair_sn, ex_intro/
-| elim (ldrop_O1_lt L2 (|L2|-|L1|-1))
-  /5 width=4 by llor_pair_dx, monotonic_lt_minus_l, ex_intro/
-]
-qed-.
-
-(* Alternative definition ***************************************************)
-
-(* Note: uses minus_minus_comm, minus_plus_m_m, commutative_plus, plus_minus *)
-lemma plus_minus_minus_be: ∀x,y,z. y ≤ z → z ≤ x → (x - z) + (z - y) = x - y.
-#x #z #y #Hzy #Hyx >plus_minus // >commutative_plus >plus_minus //
-qed-.
-
-fact plus_minus_minus_be_aux: ∀i,x,y,z. y ≤ z → z ≤ x → i = z - y → x - z + i = x - y.
-/2 width=1 by plus_minus_minus_be/ qed-.
-
-lemma llor_intro_alt: ∀T,L2,L1,L. |L1| ≤ |L2| → |L1| = |L| →
-                      (∀I1,I,K1,K,V1,V,i. ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L ≡ K.ⓑ{I}V →
-                         (∀U. ⇧[|L2|-|L1|+i, 1] U ≡ T →
-                              ∧∧ I1 = I & V1 = V & K1 ⩖[T] L2 ≡ K
-                         ) ∧
-                         (∀I2,K2,V2. (∀U. ⇧[|L2|-|L1|+i, 1] U ≡ T → ⊥) →
-                                     ⇩[|L2|-|L1|+i] L2 ≡ K2.ⓑ{I2}V2 →
-                                     ∧∧ I1 = I & V2 = V & K1 ⩖[T] L2 ≡ K
-                         )
-                      ) → L1 ⩖[T] L2 ≡ L.
-#T #L2 #L1 #L #HL12 #HL1 #IH @lpx_sn_intro_alt // -HL1
-#I1 #I #K1 #K #V1 #V #i #HLK1 #HLK
-lapply (ldrop_fwd_length_minus4 … HLK1)
-lapply (ldrop_fwd_length_le4 … HLK1)
-normalize #HKL1 #H1i lapply (plus_minus_minus_be_aux … HL12 H1i) // #H2i
-lapply (transitive_le … HKL1 HL12) -HKL1 -HL12 #HKL1
-elim (IH … HLK1 HLK) -IH -HLK1 -HLK #IH1 #IH2
-elim (is_lift_dec T (|L2|-|L1|+i) 1)
-[ -IH2 * #U #HUT elim (IH1 … HUT) -IH1
-  /3 width=2 by clor_sn, and3_intro/
-| -IH1 #H elim (ldrop_O1_lt L2 (|L2|-|L1|+i)) /2 width=1 by monotonic_lt_minus_l/
-  #I2 #K2 #V2 #HLK2 elim (IH2 … HLK2) -IH2
-  /5 width=3 by clor_dx, ex_intro, and3_intro/
-]
-qed.
-
-lemma llor_ind_alt: ∀T,L2. ∀S:relation lenv. (
-                       ∀L1,L. |L1| = |L| → (
-                          ∀I1,I,K1,K,V1,V,i.
-                          ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L ≡ K.ⓑ{I}V →
-                          (∃∃U. ⇧[|L2|-|L1|+i, 1] U ≡ T &
-                                I1 = I & V1 = V & K1 ⩖[T] L2 ≡ K & S K1 K
-                          ) ∨
-                          (∃∃I2,K2,V2. (∀U. ⇧[|L2|-|L1|+i, 1] U ≡ T → ⊥) &
-                                       ⇩[|L2|-|L1|+i] L2 ≡ K2.ⓑ{I2}V2 &
-                                       I1 = I & V2 = V & K1 ⩖[T] L2 ≡ K & S K1 K
-                          )
-                       ) → |L1| ≤ |L2| → S L1 L
-                    ) →
-                    ∀L1,L. L1 ⩖[T] L2 ≡ L → |L1| ≤ |L2| → S L1 L.
-#T #L2 #S #IH1 #L1 #L #H @(lpx_sn_ind_alt … H) -L1 -L
-#L1 #L #HL1 #IH2 #HL12 @IH1 // -IH1 -HL1
-#I1 #I #K1 #K #V1 #V #i #HLK1 #HLK
-lapply (ldrop_fwd_length_minus4 … HLK1)
-lapply (ldrop_fwd_length_le4 … HLK1)
-normalize #HKL1 #H1i lapply (plus_minus_minus_be_aux … HL12 H1i) //
-lapply (transitive_le … HKL1 HL12) -HKL1 -HL12
-elim (IH2 … HLK1 HLK) -IH2 #H *
-/5 width=5 by lt_to_le, ex6_3_intro, ex5_intro, or_intror, or_introl/
-qed-.
-
-lemma llor_inv_alt: ∀T,L2,L1,L. L1 ⩖[T] L2 ≡ L → |L1| ≤ |L2| →
-                    |L1| = |L| ∧
-                    (∀I1,I,K1,K,V1,V,i.
-                       ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L ≡ K.ⓑ{I}V →
-                       (∃∃U. ⇧[|L2|-|L1|+i, 1] U ≡ T &
-                             I1 = I & V1 = V & K1 ⩖[T] L2 ≡ K
-                       ) ∨
-                       (∃∃I2,K2,V2. (∀U. ⇧[|L2|-|L1|+i, 1] U ≡ T → ⊥) &
-                                    ⇩[|L2|-|L1|+i] L2 ≡ K2.ⓑ{I2}V2 &
-                                    I1 = I & V2 = V & K1 ⩖[T] L2 ≡ K
-                       )
-                    ).
-#T #L2 #L1 #L #H #HL12 elim (lpx_sn_inv_alt … H) -H
-#HL1 #IH @conj // -HL1
-#I1 #I #K1 #K #V1 #V #i #HLK1 #HLK
-lapply (ldrop_fwd_length_minus4 … HLK1)
-lapply (ldrop_fwd_length_le4 … HLK1)
-normalize #HKL1 #H1i lapply (plus_minus_minus_be_aux … HL12 H1i) //
-lapply (transitive_le … HKL1 HL12) -HKL1 -HL12
-elim (IH … HLK1 HLK) -IH #H *
-/4 width=5 by ex5_3_intro, ex4_intro, or_intror, or_introl/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpx_cpys.etc
deleted file mode 100644 (file)
index 3b38ee6..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/cpys_alt.ma".
-include "basic_2/reduction/cpx.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
-
-(* Properties on local environment refinement for extended substitution *****)
-
-lemma lsuby_cpx_trans: ∀h,g,G. lsub_trans … (cpx h g G) (lsuby 0 (∞)).
-#h #g #G #L1 #T1 #T2 #H elim H -G -L1 -T1 -T2
-[ //
-| /2 width=2 by cpx_sort/
-| #I #G #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (lsuby_ldrop_trans_be … HL12 … HLK1) // -HL12 -HLK1 /3 width=7 by cpx_delta/
-|4,9: /4 width=1 by cpx_bind, cpx_beta, lsuby_pair_O_Y/
-|5,7,8: /3 width=1 by cpx_flat, cpx_tau, cpx_ti/
-|6,10: /4 width=3 by cpx_zeta, cpx_theta, lsuby_pair_O_Y/
-]
-qed-.
-
-(* Properties on context-sensitive extended multiple substitution for terms *)
-
-lemma cpys_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L #T1 #T2 #d #e #H @(cpys_ind_alt … H) -G -L -T1 -T2 -d -e
-/2 width=7 by cpx_delta, cpx_bind, cpx_flat/
-qed.
-
-lemma cpy_cpx: ∀h,g,G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶[d, e] T2 → ⦃G, L⦄ ⊢ T1 ➡[h, g] T2.
-/3 width=3 by cpy_cpys, cpys_cpx/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpxs_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/cpxs_cpys.etc
deleted file mode 100644 (file)
index 8810305..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/reduction/cpx_cpys.ma".
-include "basic_2/computation/cpxs.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL COMPUTATION ON TERMS *****************)
-
-(* Properties on local environment refinement for extended substitution *****)
-
-lemma lsuby_cpxs_trans: ∀h,g,G. lsub_trans … (cpxs h g G) (lsuby 0 (∞)).
-/3 width=5 by lsuby_cpx_trans, LTC_lsub_trans/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lazyeqalt_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lazyeqalt_4.etc
deleted file mode 100644 (file)
index b89d784..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
-
-notation "hvbox( L1 ⋕ ⋕ break [ term 46 T , break term 46 d ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LazyEqAlt $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq.etc
deleted file mode 100644 (file)
index 72a5346..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/notation/relations/lazyeq_4.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-definition lleq: relation4 ynat term lenv lenv ≝
-                 λd,T,L1,L2. |L1| = |L2| ∧
-                             (∀U. ⦃⋆, L1⦄ ⊢ T ▶*[d, ∞] U ↔ ⦃⋆, L2⦄ ⊢ T ▶*[d, ∞] U).
-
-interpretation
-   "lazy equivalence (local environment)"
-   'LazyEq T d L1 L2 = (lleq d T L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lleq_refl: ∀d,T. reflexive … (lleq d T).
-/3 width=1 by conj/ qed.
-
-lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
-#d #T #L1 #L2 * /3 width=1 by iff_sym, conj/
-qed-.
-
-lemma lleq_sort: ∀L1,L2,d,k. |L1| = |L2| → L1 ⋕[⋆k, d] L2.
-#L1 #L2 #d #k #HL12 @conj // -HL12
-#U @conj #H >(cpys_inv_sort1 … H) -H //
-qed.
-
-lemma lleq_gref: ∀L1,L2,d,p. |L1| = |L2| → L1 ⋕[§p, d] L2.
-#L1 #L2 #d #k #HL12 @conj // -HL12
-#U @conj #H >(cpys_inv_gref1 … H) -H //
-qed.
-
-lemma lleq_bind: ∀a,I,L1,L2,V,T,d.
-                 L1 ⋕[V, d] L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V →
-                 L1 ⋕[ⓑ{a,I}V.T, d] L2.
-#a #I #L1 #L2 #V #T #d * #HL12 #IHV * #_ #IHT @conj // -HL12
-#X @conj #H elim (cpys_inv_bind1 … H) -H
-#W #U #HVW #HTU #H destruct
-elim (IHV W) -IHV elim (IHT U) -IHT /3 width=1 by cpys_bind/
-qed.
-
-lemma lleq_flat: ∀I,L1,L2,V,T,d.
-                 L1 ⋕[V, d] L2 → L1 ⋕[T, d] L2 → L1 ⋕[ⓕ{I}V.T, d] L2.
-#I #L1 #L2 #V #T #d * #HL12 #IHV * #_ #IHT @conj // -HL12
-#X @conj #H elim (cpys_inv_flat1 … H) -H
-#W #U #HVW #HTU #H destruct
-elim (IHV W) -IHV elim (IHT U) -IHT
-/3 width=1 by cpys_flat/
-qed.
-
-lemma lleq_be: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 → ∀T,d,e. ⇧[d, e] T ≡ U →
-               d ≤ dt → dt ≤ d + e → L1 ⋕[U, d] L2.
-#L1 #L2 #U #dt * #HL12 #IH #T #d #e #HTU #Hddt #Hdtde @conj // -HL12
-#U0 elim (IH U0) -IH #H12 #H21 @conj
-#HU0 elim (cpys_fwd_up … HU0 … HTU) // -HU0 /4 width=5 by cpys_weak/
-qed-.
-
-lemma lsuby_lleq_trans: ∀L2,L,T,d. L2 ⋕[T, d] L →
-                        ∀L1. L1 ⊑×[d, ∞] L2 → |L1| = |L2| → L1 ⋕[T, d] L.
-#L2 #L #T #d * #HL2 #IH #L1 #HL12 #H @conj // -HL2
-#U elim (IH U) -IH #Hdx #Hsn @conj #HTU
-[ @Hdx -Hdx -Hsn @(lsuby_cpys_trans … HTU) -HTU
-  /2 width=1 by lsuby_sym/ (**) (* full auto does not work *)
-| -H -Hdx /3 width=3 by lsuby_cpys_trans/
-]
-qed-.
-
-lemma lleq_lsuby_trans: ∀L,L1,T,d. L ⋕[T, d] L1 →
-                        ∀L2. L1 ⊑×[d, ∞] L2 → |L1| = |L2| → L ⋕[T, d] L2.
-/5 width=4 by lsuby_lleq_trans, lleq_sym, lsuby_sym/ qed-.
-
-lemma lleq_lsuby_repl: ∀L1,L2,T,d. L1 ⋕[T, d] L2 →
-                       ∀K1. K1 ⊑×[d, ∞] L1 → |K1| = |L1| →
-                       ∀K2. L2 ⊑×[d, ∞] K2 → |L2| = |K2| →
-                       K1 ⋕[T, d] K2.
-/3 width=4 by lleq_lsuby_trans, lsuby_lleq_trans/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lleq_fwd_length: ∀L1,L2,T,d. L1 ⋕[T, d] L2 → |L1| = |L2|.
-#L1 #L2 #T #d * //
-qed-.
-
-lemma lleq_fwd_ldrop_sn: ∀L1,L2,T,d. L1 ⋕[d, T] L2 → ∀K1,i. ⇩[i] L1 ≡ K1 →
-                         ∃K2. ⇩[i] L2 ≡ K2.
-#L1 #L2 #T #d #H #K1 #i #HLK1 lapply (lleq_fwd_length … H) -H
-#HL12 lapply (ldrop_fwd_length_le2 … HLK1) -HLK1 /2 width=1 by ldrop_O1_le/
-qed-.
-
-lemma lleq_fwd_ldrop_dx: ∀L1,L2,T,d. L1 ⋕[d, T] L2 → ∀K2,i. ⇩[i] L2 ≡ K2 →
-                         ∃K1. ⇩[i] L1 ≡ K1.
-/3 width=6 by lleq_fwd_ldrop_sn, lleq_sym/ qed-.
-
-lemma lleq_fwd_bind_sn: ∀a,I,L1,L2,V,T,d.
-                        L1 ⋕[ⓑ{a,I}V.T, d] L2 → L1 ⋕[V, d] L2.
-#a #I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
-#U elim (H (ⓑ{a,I}U.T)) -H
-#H1 #H2 @conj
-#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
-/2 width=1 by cpys_bind/ -H
-#H elim (cpys_inv_bind1 … H) -H
-#X #Y #H1 #H2 #H destruct //
-qed-.
-
-lemma lleq_fwd_bind_dx: ∀a,I,L1,L2,V,T,d.
-                        L1 ⋕[ⓑ{a,I}V.T, d] L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V.
-#a #I #L1 #L2 #V #T #d * #HL12 #H @conj [ normalize // ] -HL12
-#U elim (H (ⓑ{a,I}V.U)) -H
-#H1 #H2 @conj
-#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
-/2 width=1 by cpys_bind/ -H
-#H elim (cpys_inv_bind1 … H) -H
-#X #Y #H1 #H2 #H destruct //
-qed-.
-
-lemma lleq_fwd_flat_sn: ∀I,L1,L2,V,T,d.
-                        L1 ⋕[ⓕ{I}V.T, d] L2 → L1 ⋕[V, d] L2.
-#I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
-#U elim (H (ⓕ{I}U.T)) -H
-#H1 #H2 @conj
-#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
-/2 width=1 by cpys_flat/ -H
-#H elim (cpys_inv_flat1 … H) -H
-#X #Y #H1 #H2 #H destruct //
-qed-.
-
-lemma lleq_fwd_flat_dx: ∀I,L1,L2,V,T,d.
-                        L1 ⋕[ⓕ{I}V.T, d] L2 → L1 ⋕[T, d] L2.
-#I #L1 #L2 #V #T #d * #HL12 #H @conj // -HL12
-#U elim (H (ⓕ{I}V.U)) -H
-#H1 #H2 @conj
-#H [ lapply (H1 ?) | lapply (H2 ?) ] -H1 -H2
-/2 width=1 by cpys_flat/ -H
-#H elim (cpys_inv_flat1 … H) -H
-#X #Y #H1 #H2 #H destruct //
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lleq_inv_bind: ∀a,I,L1,L2,V,T,d. L1 ⋕[ⓑ{a,I}V.T, d] L2 →
-                     L1 ⋕[V, d] L2 ∧ L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V.
-/3 width=4 by lleq_fwd_bind_sn, lleq_fwd_bind_dx, conj/ qed-.
-
-lemma lleq_inv_flat: ∀I,L1,L2,V,T,d. L1 ⋕[ⓕ{I}V.T, d] L2 →
-                     L1 ⋕[V, d] L2 ∧ L1 ⋕[T, d] L2.
-/3 width=3 by lleq_fwd_flat_sn, lleq_fwd_flat_dx, conj/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_alt.etc
deleted file mode 100644 (file)
index a8fb526..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/notation/relations/lazyeqalt_4.ma".
-include "basic_2/substitution/lleq_lleq.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-(* Note: alternative definition of lleq *)
-inductive lleqa: relation4 ynat term lenv lenv ≝
-| lleqa_sort: ∀L1,L2,d,k. |L1| = |L2| → lleqa d (⋆k) L1 L2
-| lleqa_skip: ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → lleqa d (#i) L1 L2
-| lleqa_lref: ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
-              ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
-              lleqa (yinj 0) V K1 K2 → lleqa d (#i) L1 L2
-| lleqa_free: ∀L1,L2,d,i. |L1| = |L2| → |L1| ≤ i → |L2| ≤ i → lleqa d (#i) L1 L2
-| lleqa_gref: ∀L1,L2,d,p. |L1| = |L2| → lleqa d (§p) L1 L2
-| lleqa_bind: ∀a,I,L1,L2,V,T,d.
-              lleqa d V L1 L2 → lleqa (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
-              lleqa d (ⓑ{a,I}V.T) L1 L2
-| lleqa_flat: ∀I,L1,L2,V,T,d.
-              lleqa d V L1 L2 → lleqa d T L1 L2 → lleqa d (ⓕ{I}V.T) L1 L2
-.
-
-interpretation
-   "lazy equivalence (local environment) alternative"
-   'LazyEqAlt T d L1 L2 = (lleqa d T L1 L2).
-
-(* Main inversion lemmas ****************************************************)
-
-theorem lleqa_inv_lleq: ∀L1,L2,T,d. L1 ⋕⋕[T, d] L2 → L1 ⋕[T, d] L2.
-#L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-/2 width=8 by lleq_flat, lleq_bind, lleq_gref, lleq_free, lleq_lref, lleq_skip, lleq_sort/
-qed-.
-
-(* Main properties **********************************************************)
-
-theorem lleq_lleqa: ∀L1,T,L2,d. L1 ⋕[T, d] L2 → L1 ⋕⋕[T, d] L2.
-#L1 #T @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * * /3 width=3 by lleqa_gref, lleqa_sort, lleq_fwd_length/
-[ #i #Hn #L2 #d #H elim (lleq_fwd_lref … H) [ * || * ]
-  /4 width=9 by lleqa_free, lleqa_lref, lleqa_skip, lleq_fwd_length, ldrop_fwd_rfw/
-| #a #I #V #T #Hn #L2 #d #H elim (lleq_inv_bind … H) -H /3 width=1 by lleqa_bind/
-| #I #V #T #Hn #L2 #d #H elim (lleq_inv_flat … H) -H /3 width=1 by lleqa_flat/
-]
-qed.
-
-(* Advanced eliminators *****************************************************)
-
-lemma lleq_ind_alt: ∀R:relation4 ynat term lenv lenv. (
-                       ∀L1,L2,d,k. |L1| = |L2| → R d (⋆k) L1 L2
-                    ) → (
-                       ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → R d (#i) L1 L2
-                    ) → (
-                       ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
-                       ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
-                       K1 ⋕[V, yinj O] K2 → R (yinj O) V K1 K2 → R d (#i) L1 L2
-                    ) → (
-                       ∀L1,L2,d,i. |L1| = |L2| → |L1| ≤ i → |L2| ≤ i → R d (#i) L1 L2
-                    ) → (
-                       ∀L1,L2,d,p. |L1| = |L2| → R d (§p) L1 L2
-                    ) → (
-                       ∀a,I,L1,L2,V,T,d.
-                       L1 ⋕[V, d]L2 → L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V →
-                       R d V L1 L2 → R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → R d (ⓑ{a,I}V.T) L1 L2
-                    ) → (
-                       ∀I,L1,L2,V,T,d.
-                       L1 ⋕[V, d]L2 → L1 ⋕[T, d] L2 →
-                       R d V L1 L2 → R d T L1 L2 → R d (ⓕ{I}V.T) L1 L2
-                    ) →
-                    ∀d,T,L1,L2. L1 ⋕[T, d] L2 → R d T L1 L2.
-#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #d #T #L1 #L2 #H elim (lleq_lleqa … H) -H
-/3 width=9 by lleqa_inv_lleq/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ext.etc
deleted file mode 100644 (file)
index d6bb03f..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/lleq_alt.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-fact lleq_inv_S_aux: ∀L1,L2,T,d0. L1 ⋕[T, d0] L2 → ∀d. d0 = d + 1 →
-                     ∀K1,K2,I,V. ⇩[d] L1 ≡ K1.ⓑ{I}V → ⇩[d] L2 ≡ K2.ⓑ{I}V →
-                     K1 ⋕[V, 0] K2 → L1 ⋕[T, d] L2.
-#L1 #L2 #T #d0 #H @(lleq_ind_alt … H) -L1 -L2 -T -d0
-/2 width=1 by lleq_gref, lleq_free, lleq_sort/
-[ #L1 #L2 #d0 #i #HL12 #Hid #d #H #K1 #K2 #I #V #HLK1 #HLK2 #HV destruct
-  elim (yle_split_eq i d) /2 width=1 by lleq_skip, ylt_fwd_succ2/ -HL12 -Hid
-  #H destruct /2 width=8 by lleq_lref/
-| #I1 #I2 #L1 #L2 #K11 #K22 #V #d0 #i #Hd0i #HLK11 #HLK22 #HV #_ #d #H #K1 #K2 #J #W #_ #_ #_ destruct
-  /3 width=8 by lleq_lref, yle_pred_sn/
-| #a #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W #HLK1 #HLK2 destruct
-  /4 width=7 by lleq_bind, ldrop_drop/
-| #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W #HLK1 #HLK2 destruct
-  /3 width=7 by lleq_flat/
-]
-qed-.
-
-lemma lleq_inv_S: ∀T,L1,L2,d. L1 ⋕[T, d+1] L2 →
-                  ∀K1,K2,I,V. ⇩[d] L1 ≡ K1.ⓑ{I}V → ⇩[d] L2 ≡ K2.ⓑ{I}V →
-                  K1 ⋕[V, 0] K2 → L1 ⋕[T, d] L2.
-/2 width=7 by lleq_inv_S_aux/ qed-.
-
-lemma lleq_inv_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[ⓑ{a,I}V.T, 0] L2 →
-                       L1 ⋕[V, 0] L2 ∧ L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V.
-#a #I #L1 #L2 #V #T #H elim (lleq_inv_bind … H) -H
-/3 width=7 by ldrop_pair, conj, lleq_inv_S/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lleq_fwd_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[ⓑ{a,I}V.T, 0] L2 →
-                       L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V.
-#a #I #L1 #L2 #V #T #H elim (lleq_inv_bind_O … H) -H //
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lleq_ge: ∀L1,L2,T,d1. L1 ⋕[T, d1] L2 → ∀d2. d1 ≤ d2 → L1 ⋕[T, d2] L2.
-#L1 #L2 #T #d1 #H @(lleq_ind_alt … H) -L1 -L2 -T -d1
-/4 width=1 by lleq_sort, lleq_free, lleq_gref, lleq_bind, lleq_flat, yle_succ/
-[ /3 width=3 by lleq_skip, ylt_yle_trans/
-| #I1 #I2 #L1 #L2 #K1 #K2 #V #d1 #i #Hi #HLK1 #HLK2 #HV #IHV #d2 #Hd12 elim (ylt_split i d2)
-  [ lapply (lleq_fwd_length … HV) #HK12 #Hid2
-    lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
-    normalize in ⊢ (%→%→?); -I1 -I2 -V -d1 /2 width=1 by lleq_skip/ 
-  | /3 width=8 by lleq_lref, yle_trans/
-  ]
-]
-qed-.
-
-lemma lleq_bind_O: ∀a,I,L1,L2,V,T. L1 ⋕[V, 0] L2 → L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V →
-                   L1 ⋕[ⓑ{a,I}V.T, 0] L2.
-/3 width=3 by lleq_ge, lleq_bind/ qed.
-
-lemma lleq_bind_repl_SO: ∀I1,I2,L1,L2,V1,V2,T. L1.ⓑ{I1}V1 ⋕[T, 0] L2.ⓑ{I2}V2 →
-                         ∀J1,J2,W1,W2. L1.ⓑ{J1}W1 ⋕[T, 1] L2.ⓑ{J2}W2.
-#I1 #I2 #L1 #L2 #V1 #V2 #T #HT #J1 #J2 #W1 #W2 lapply (lleq_ge … HT 1 ?) // -HT
-#HT @(lleq_lsuby_repl … HT) /2 width=1 by lsuby_succ/ (**) (* full auto fails *)
-qed-.
-
-lemma lleq_bind_repl_O: ∀I,L1,L2,V,T. L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V →
-                        ∀J,W. L1 ⋕[W, 0] L2 → L1.ⓑ{J}W ⋕[T, 0] L2.ⓑ{J}W.
-/3 width=7 by lleq_bind_repl_SO, lleq_inv_S/ qed-.
-
-(* Inversion lemmas on negated lazy quivalence for local environments *******)
-
-lemma nlleq_inv_bind_O: ∀a,I,L1,L2,V,T. (L1 ⋕[ⓑ{a,I}V.T, 0] L2 → ⊥) →
-                        (L1 ⋕[V, 0] L2 → ⊥) ∨ (L1.ⓑ{I}V ⋕[T, 0] L2.ⓑ{I}V → ⊥).
-#a #I #L1 #L2 #V #T #H elim (lleq_dec V L1 L2 0)
-/4 width=1 by lleq_bind_O, or_intror, or_introl/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_fqus.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_fqus.etc
deleted file mode 100644 (file)
index 18744a5..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/fqus_alt.ma".
-include "basic_2/substitution/lleq_ext.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-(* Properties on supclosure and derivatives *********************************)
-
-lemma lleq_fqu_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃ ⦃G2, K2, U⦄ →
-                      ∀L1. L1 ⋕[T, 0] L2 →
-                      ∃∃K1. ⦃G1, L1, T⦄ ⊃ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
-#G1 #G2 #L2 #K2 #T #U #H elim H -G1 -G2 -L2 -K2 -T -U
-[ #I #G #L2 #V #L1 #H elim (lleq_inv_lref_ge_dx … H … I L2 V) -H //
-  #I1 #K1 #H1 #H2 lapply (ldrop_inv_O2 … H1) -H1
-  #H destruct /2 width=3 by fqu_lref_O, ex2_intro/
-| * [ #a ] #I #G #L2 #V #T #L1 #H
-  [ elim (lleq_inv_bind … H)
-  | elim (lleq_inv_flat … H)
-  ] -H
-  /2 width=3 by fqu_pair_sn, ex2_intro/
-| #a #I #G #L2 #V #T #L1 #H elim (lleq_inv_bind_O … H) -H
-  #H3 #H4 /2 width=3 by fqu_bind_dx, ex2_intro/
-| #I #G #L2 #V #T #L1 #H elim (lleq_inv_flat … H) -H
-  /2 width=3 by fqu_flat_dx, ex2_intro/
-| #G #L2 #K2 #T #U #e #HLK2 #HTU #L1 #HL12
-  elim (ldrop_O1_le (e+1) L1)
-  [ /3 width=12 by fqu_drop, lleq_inv_lift_le, ex2_intro/
-  | lapply (ldrop_fwd_length_le2 … HLK2) -K2
-    lapply (lleq_fwd_length … HL12) -T -U //
-  ]
-]
-qed-.
-
-lemma lleq_fquq_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃⸮ ⦃G2, K2, U⦄ →
-                       ∀L1. L1 ⋕[T, 0] L2 →
-                       ∃∃K1. ⦃G1, L1, T⦄ ⊃⸮ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
-#G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fquq_inv_gen … H) -H
-[ #H elim (lleq_fqu_trans … H … HL12) -L2 /3 width=3 by fqu_fquq, ex2_intro/
-| * #HG #HL #HT destruct /2 width=3 by ex2_intro/
-]
-qed-.
-
-lemma lleq_fqup_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃+ ⦃G2, K2, U⦄ →
-                       ∀L1. L1 ⋕[T, 0] L2 →
-                       ∃∃K1. ⦃G1, L1, T⦄ ⊃+ ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
-#G1 #G2 #L2 #K2 #T #U #H @(fqup_ind … H) -G2 -K2 -U
-[ #G2 #K2 #U #HTU #L1 #HL12 elim (lleq_fqu_trans … HTU … HL12) -L2
-  /3 width=3 by fqu_fqup, ex2_intro/
-| #G #G2 #K #K2 #U #U2 #_ #HU2 #IHTU #L1 #HL12 elim (IHTU … HL12) -L2
-  #K1 #HTU #HK1 elim (lleq_fqu_trans … HU2 … HK1) -K
-  /3 width=5 by fqup_strap1, ex2_intro/
-]
-qed-.
-
-lemma lleq_fqus_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊃* ⦃G2, K2, U⦄ →
-                       ∀L1. L1 ⋕[T, 0] L2 →
-                       ∃∃K1. ⦃G1, L1, T⦄ ⊃* ⦃G2, K1, U⦄ & K1 ⋕[U, 0] K2.
-#G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fqus_inv_gen … H) -H
-[ #H elim (lleq_fqup_trans … H … HL12) -L2 /3 width=3 by fqup_fqus, ex2_intro/
-| * #HG #HL #HT destruct /2 width=3 by ex2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_ldrop.etc
deleted file mode 100644 (file)
index 9cb597c..0000000
+++ /dev/null
@@ -1,123 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/cpys_lift.ma".
-include "basic_2/substitution/lleq.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-(* Advanced properties ******************************************************)
-
-lemma lleq_skip: ∀L1,L2,d,i. yinj i < d → |L1| = |L2| → L1 ⋕[#i, d] L2.
-#L1 #L2 #d #i #Hid #HL12 @conj // -HL12
-#U @conj #H elim (cpys_inv_lref1 … H) -H // *
-#I #Z #Y #X #H elim (ylt_yle_false … Hid … H)
-qed.
-
-lemma lleq_lref: ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
-                 ⇩[i] L1 ≡ K1.ⓑ{I1}V → ⇩[i] L2 ≡ K2.ⓑ{I2}V →
-                 K1 ⋕[V, 0] K2 → L1 ⋕[#i, d] L2.
-#I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 * #HK12 #IH @conj [ -IH | -HK12 ]
-[ lapply (ldrop_fwd_length … HLK1) -HLK1 #H1
-  lapply (ldrop_fwd_length … HLK2) -HLK2 #H2
-  >H1 >H2 -H1 -H2 normalize //
-| #U @conj #H elim (cpys_inv_lref1 … H) -H // *
-  >yminus_Y_inj #I #K #X #W #_ #_ #H #HVW #HWU
-  [ letin HLK ≝ HLK1 | letin HLK ≝ HLK2 ]
-  lapply (ldrop_mono … H … HLK) -H #H destruct elim (IH W)
-  /3 width=7 by cpys_subst_Y2/
-]
-qed.
-
-lemma lleq_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → L1 ⋕[#i, d] L2.
-#L1 #L2 #d #i #HL1 #HL2 #HL12 @conj // -HL12
-#U @conj #H elim (cpys_inv_lref1 … H) -H // *
-#I #Z #Y #X #_ #_ #H lapply (ldrop_fwd_length_lt2 … H) -H
-#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
-qed.
-
-(* Properties on relocation *************************************************)
-
-lemma lleq_lift_le: ∀K1,K2,T,dt. K1 ⋕[T, dt] K2 →
-                    ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                    ∀U. ⇧[d, e] T ≡ U → dt ≤ d → L1 ⋕[U, dt] L2.
-#K1 #K2 #T #dt * #HK12 #IHT #L1 #L2 #d #e #HLK1 #HLK2 #U #HTU #Hdtd
-lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
-#H2 #H1 @conj // -HK12 -H1 -H2 #U0 @conj #HU0
-[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 ]
-elim (cpys_inv_lift1_be … HU0 … HLKA … HTU) // -HU0 >yminus_Y_inj #T0 #HT0 #HTU0
-elim (IHT T0) [ #H #_ | #_ #H ] -IHT /3 width=12 by cpys_lift_be/
-qed-.
-
-lemma lleq_lift_ge: ∀K1,K2,T,dt. K1 ⋕[T, dt] K2 →
-                    ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                    ∀U. ⇧[d, e] T ≡ U → d ≤ dt → L1 ⋕[U, dt+e] L2.
-#K1 #K2 #T #dt * #HK12 #IHT #L1 #L2 #d #e #HLK1 #HLK2 #U #HTU #Hddt
-lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
-#H2 #H1 @conj // -HK12 -H1 -H2 #U0 @conj #HU0
-[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 ]
-elim (cpys_inv_lift1_ge … HU0 … HLKA … HTU) /2 width=1 by monotonic_yle_plus_dx/ -HU0 >yplus_minus_inj #T0 #HT0 #HTU0
-elim (IHT T0) [ #H #_ | #_ #H ] -IHT /3 width=10 by cpys_lift_ge/
-qed-.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma lleq_inv_lift_le: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
-                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        ∀T. ⇧[d, e] T ≡ U → dt ≤ d → K1 ⋕[T, dt] K2.
-#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hdtd
-lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
-#H2 #H1 @conj // -HL12 -H1 -H2
-#T0 elim (lift_total T0 d e)
-#U0 #HTU0 elim (IH U0) -IH
-#H12 #H21 @conj #HT0
-[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
-lapply (cpys_lift_be … HT0 … HLKA … HTU … HTU0) // -HT0
->yplus_Y1 #HU0 elim (cpys_inv_lift1_be … (H0 HU0) … HLKB … HTU) // -L1 -L2 -U -Hdtd
-#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
-qed-.
-
-lemma lleq_inv_lift_ge: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
-                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        ∀T. ⇧[d, e] T ≡ U → yinj d + e ≤ dt → K1 ⋕[T, dt-e] K2.
-#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hdedt
-lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
-#H2 #H1 @conj // -HL12 -H1 -H2
-elim (yle_inv_plus_inj2 … Hdedt) #Hddt #Hedt
-#T0 elim (lift_total T0 d e)
-#U0 #HTU0 elim (IH U0) -IH
-#H12 #H21 @conj #HT0
-[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
-lapply (cpys_lift_ge … HT0 … HLKA … HTU … HTU0) // -HT0 -Hddt
->ymax_pre_sn // #HU0 elim (cpys_inv_lift1_ge … (H0 HU0) … HLKB … HTU) // -L1 -L2 -U -Hdedt -Hedt
-#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
-qed-.
-
-lemma lleq_inv_lift_be: ∀L1,L2,U,dt. L1 ⋕[U, dt] L2 →
-                        ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        ∀T. ⇧[d, e] T ≡ U → d ≤ dt → dt ≤ yinj d + e → K1 ⋕[T, d] K2.
-#L1 #L2 #U #dt * #HL12 #IH #K1 #K2 #d #e #HLK1 #HLK2 #T #HTU #Hddt #Hdtde
-lapply (ldrop_fwd_length_minus2 … HLK1) lapply (ldrop_fwd_length_minus2 … HLK2)
-#H2 #H1 @conj // -HL12 -H1 -H2
-#T0 elim (lift_total T0 d e)
-#U0 #HTU0 elim (IH U0) -IH
-#H12 #H21 @conj #HT0
-[ letin HLKA ≝ HLK1 letin HLKB ≝ HLK2 letin H0 ≝ H12 | letin HLKA ≝ HLK2 letin HLKB ≝ HLK1 letin H0 ≝ H21 ]
-lapply (cpys_lift_ge … HT0 … HLKA … HTU … HTU0) // -HT0
-#HU0 lapply (cpys_weak … HU0 dt (∞) ? ?) // -HU0
-#HU0 lapply (H0 HU0)
-#HU0 lapply (cpys_weak … HU0 d (∞) ? ?) // -HU0
-#HU0 elim (cpys_inv_lift1_ge_up … HU0 … HLKB … HTU) // -L1 -L2 -U -Hddt -Hdtde
-#X #HT0 #HX lapply (lift_inj … HX … HTU0) -U0 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lleq_lleq.etc
deleted file mode 100644 (file)
index 2a8873d..0000000
+++ /dev/null
@@ -1,175 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/substitution/cpys_cpys.ma".
-include "basic_2/substitution/lleq_ldrop.ma".
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lleq_fwd_lref: ∀L1,L2. ∀d:ynat. ∀i:nat. L1 ⋕[#i, d] L2 →
-                     ∨∨ |L1| ≤ i ∧ |L2| ≤ i
-                      | yinj i < d
-                      | ∃∃I1,I2,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V &
-                                         ⇩[i] L2 ≡ K2.ⓑ{I2}V &
-                                         K1 ⋕[V, yinj 0] K2 & d ≤ yinj i.
-#L1 #L2 #d #i * #HL12 #IH elim (lt_or_ge i (|L1|)) /3 width=3 by or3_intro0, conj/
-elim (ylt_split i d) /2 width=1 by or3_intro1/ #Hdi #Hi
-elim (ldrop_O1_lt … Hi) #I1 #K1 #V1 #HLK1
-elim (ldrop_O1_lt L2 i) // -Hi #I2 #K2 #V2 #HLK2
-lapply (ldrop_fwd_length_minus2 … HLK2) #H
-lapply (ldrop_fwd_length_minus2 … HLK1) >HL12 <H -HL12 -H
-#H lapply (injective_plus_l … H) -H #HK12
-elim (lift_total V1 0 (i+1)) #W1 #HVW1
-elim (lift_total V2 0 (i+1)) #W2 #HVW2
-elim (IH W1) elim (IH W2) #_ #H2 #H1 #_
-elim (cpys_inv_lref1_ldrop … (H1 ?) … HLK2 … HVW1) -H1
-[ elim (cpys_inv_lref1_ldrop … (H2 ?) … HLK1 … HVW2) -H2 ]
-/3 width=7 by cpys_subst, yle_inj/ -W1 -W2 #H12 #_ #_ #H21 #_ #_
-lapply (cpys_antisym_eq … H12 … H21) -H12 -H21 #H destruct
-@or3_intro2 @(ex4_5_intro … HLK1 HLK2) // @conj // -HK12
-#V elim (lift_total V 0 (i+1))
-#W #HVW elim (IH W) -IH #H12 #H21 @conj #H
-[ elim (cpys_inv_lref1_ldrop … (H12 ?) … HLK2 … HVW) -H12 -H21
-| elim (cpys_inv_lref1_ldrop … (H21 ?) … HLK1 … HVW) -H21 -H12
-] [1,3: >yminus_Y_inj ] /3 width=7 by cpys_subst_Y2, yle_inj/
-qed-.
-
-lemma lleq_fwd_lref_dx: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 →
-                        ∀I2,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I2}V →
-                        i < d ∨
-                        ∃∃I1,K1. ⇩[i] L1 ≡ K1.ⓑ{I1}V & K1 ⋕[V, 0] K2 & d ≤ i.
-#L1 #L2 #d #i #H #I2 #K2 #V #HLK2 elim (lleq_fwd_lref … H) -H [ * || * ]
-[ #_ #H elim (lt_refl_false i)
-  lapply (ldrop_fwd_length_lt2 … HLK2) -HLK2
-  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
-| /2 width=1 by or_introl/
-| #I1 #I2 #K11 #K22 #V0 #HLK11 #HLK22 #HV0 #Hdi lapply (ldrop_mono … HLK22 … HLK2) -L2
-  #H destruct /3 width=5 by ex3_2_intro, or_intror/
-]
-qed-.
-
-lemma lleq_fwd_lref_sn: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 →
-                        ∀I1,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V →
-                        i < d ∨
-                        ∃∃I2,K2. ⇩[i] L2 ≡ K2.ⓑ{I2}V & K1 ⋕[V, 0] K2 & d ≤ i.
-#L1 #L2 #d #i #HL12 #I1 #K1 #V #HLK1 elim (lleq_fwd_lref_dx L2 … d … HLK1) -HLK1
-[2: * ] /4 width=6 by lleq_sym, ex3_2_intro, or_introl, or_intror/
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma lleq_inv_lref_ge_dx: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
-                           ∀I2,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I2}V →
-                           ∃∃I1,K1. ⇩[i] L1 ≡ K1.ⓑ{I1}V & K1 ⋕[V, 0] K2.
-#L1 #L2 #d #i #H #Hdi #I2 #K2 #V #HLK2 elim (lleq_fwd_lref_dx … H … HLK2) -L2
-[ #H elim (ylt_yle_false … H Hdi)
-| * /2 width=4 by ex2_2_intro/
-]
-qed-.
-
-lemma lleq_inv_lref_ge_sn: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
-                           ∀I1,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I1}V →
-                           ∃∃I2,K2. ⇩[i] L2 ≡ K2.ⓑ{I2}V & K1 ⋕[V, 0] K2.
-#L1 #L2 #d #i #HL12 #Hdi #I1 #K1 #V #HLK1 elim (lleq_inv_lref_ge_dx L2 … Hdi … HLK1) -Hdi -HLK1
-/3 width=4 by lleq_sym, ex2_2_intro/
-qed-.
-
-lemma lleq_inv_lref_ge_gen: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
-                            ∀I1,I2,K1,K2,V1,V2.
-                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                            V1 = V2 ∧ K1 ⋕[V2, 0] K2.
-#L1 #L2 #d #i #HL12 #Hdi #I1 #I2 #K1 #K2 #V1 #V2 #HLK1 #HLK2
-elim (lleq_inv_lref_ge_sn … HL12 … HLK1) // -L1 -d
-#J #Y #HY lapply (ldrop_mono … HY … HLK2) -L2 -i #H destruct /2 width=1 by conj/
-qed-.
-
-lemma lleq_inv_lref_ge: ∀L1,L2,d,i. L1 ⋕[#i, d] L2 → d ≤ i →
-                        ∀I,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}V →
-                        K1 ⋕[V, 0] K2.
-#L1 #L2 #d #i #HL12 #Hdi #I #K1 #K2 #V #HLK1 #HLK2
-elim (lleq_inv_lref_ge_gen … HL12 … HLK1 HLK2) //
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lleq_dec: ∀T,L1,L2,d. Decidable (L1 ⋕[T, d] L2).
-#T #L1 @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * *
-[ #k #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, lleq_sort/
-| #i #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|))
-  [ #HL12 #d elim (ylt_split i d) /3 width=1 by lleq_skip, or_introl/
-    #Hdi elim (lt_or_ge i (|L1|)) #HiL1
-    elim (lt_or_ge i (|L2|)) #HiL2 /3 width=1 by or_introl, lleq_free/
-    elim (ldrop_O1_lt … HiL2) #I2 #K2 #V2 #HLK2
-    elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
-    elim (eq_term_dec V2 V1)
-    [ #H3 elim (IH K1 V1 … K2 0) destruct
-      /3 width=8 by lleq_lref, ldrop_fwd_rfw, or_introl/
-    ]
-    -IH #H3 @or_intror
-    #H elim (lleq_fwd_lref … H) -H [1,3,4,6: * ]
-    [1,3: /3 width=4 by lt_to_le_to_lt, lt_refl_false/
-    |5,6: /2 width=4 by ylt_yle_false/
-    ]
-    #Z1 #Z2 #Y1 #Y2 #X #HLY1 #HLY2 #HX #_
-    lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1
-    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2
-    #H2 #H1 destruct /2 width=1 by/
-  ]
-| #p #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, lleq_gref/
-| #a #I #V #T #Hn #L2 #d destruct
-  elim (IH L1 V … L2 d) /2 width=1 by/
-  elim (IH (L1.ⓑ{I}V) T … (L2.ⓑ{I}V) (d+1)) -IH /3 width=1 by or_introl, lleq_bind/
-  #H1 #H2 @or_intror
-  #H elim (lleq_inv_bind … H) -H /2 width=1 by/
-| #I #V #T #Hn #L2 #d destruct
-  elim (IH L1 V … L2 d) /2 width=1 by/
-  elim (IH L1 T … L2 d) -IH /3 width=1 by or_introl, lleq_flat/
-  #H1 #H2 @or_intror
-  #H elim (lleq_inv_flat … H) -H /2 width=1 by/
-]
--n /4 width=3 by lleq_fwd_length, or_intror/
-qed-.
-
-(* Main properties **********************************************************)
-
-theorem lleq_trans: ∀d,T. Transitive … (lleq d T).
-#d #T #L1 #L * #HL1 #IH1 #L2 * #HL2 #IH2 /3 width=3 by conj, iff_trans/
-qed-.
-
-theorem lleq_canc_sn: ∀L,L1,L2,T,d. L ⋕[d, T] L1→ L ⋕[d, T] L2 → L1 ⋕[d, T] L2.
-/3 width=3 by lleq_trans, lleq_sym/ qed-.
-
-theorem lleq_canc_dx: ∀L1,L2,L,T,d. L1 ⋕[d, T] L → L2 ⋕[d, T] L → L1 ⋕[d, T] L2.
-/3 width=3 by lleq_trans, lleq_sym/ qed-.
-
-(* Inversion lemmas on negated lazy quivalence for local environments *******)
-
-lemma nlleq_inv_bind: ∀a,I,L1,L2,V,T,d. (L1 ⋕[ⓑ{a,I}V.T, d] L2 → ⊥) →
-                      (L1 ⋕[V, d] L2 → ⊥) ∨ (L1.ⓑ{I}V ⋕[T, ⫯d] L2.ⓑ{I}V → ⊥).
-#a #I #L1 #L2 #V #T #d #H elim (lleq_dec V L1 L2 d)
-/4 width=1 by lleq_bind, or_intror, or_introl/
-qed-.
-
-lemma nlleq_inv_flat: ∀I,L1,L2,V,T,d. (L1 ⋕[ⓕ{I}V.T, d] L2 → ⊥) →
-                      (L1 ⋕[V, d] L2 → ⊥) ∨ (L1 ⋕[T, d] L2 → ⊥).
-#I #L1 #L2 #V #T #d #H elim (lleq_dec V L1 L2 d)
-/4 width=1 by lleq_flat, or_intror, or_introl/
-qed-.
-
-(* Note: lleq_nlleq_trans: ∀d,T,L1,L. L1⋕[T, d] L →
-                           ∀L2. (L ⋕[T, d] L2 → ⊥) → (L1 ⋕[T, d] L2 → ⊥).
-/3 width=3 by lleq_canc_sn/ qed-.
-works with /4 width=8/ so lleq_canc_sn is more convenient
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsuby/lpx_cpys.etc
deleted file mode 100644 (file)
index d3c490a..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/cpy_lift.ma".
-include "basic_2/substitution/cpys.ma".
-include "basic_2/reduction/lpx_ldrop.ma".
-
-(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
-
-(* Properties on context-sensitive extended substitution for terms **********)
-
-lemma cpx_cpy_trans_lpx: ∀h,g,G,L1,T1,T. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T →
-                         ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
-                         ∀T2,d,e. ⦃G, L2⦄ ⊢ T ▶[d, e] T2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L1 #T1 #T #H elim H -G -L1 -T1 -T
-[ #J #G #L1 #L2 #HL12 #T2 #d #e #H elim (cpy_inv_atom1 … H) -H //
-  * #I #K2 #V2 #i #_ #_ #HLK2 #HVT2 #H destruct
-  elim (lpx_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
-  elim (lpx_inv_pair2 … H) -H #K1 #V1 #_ #HV12 #H destruct
-  /2 width=7 by cpx_delta/
-| #G #L1 #k #l #Hkl #L2 #_ #X #d #e #H >(cpy_inv_sort1 … H) -X /2 width=2 by cpx_sort/
-| #I #G #L1 #K1 #V1 #V #T #i #HLK1 #_ #HVT #IHV1 #L2 #HL12 #T2 #d #e #HT2
-  elim (lpx_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-  elim (lpx_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
-  lapply (ldrop_fwd_drop2 … HLK2) -V0 #HLK2
-  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
-  elim (cpy_inv_lift1_be … HT2 … HLK2 … HVT) -HT2 -HLK2 -HVT
-  /3 width=7 by cpx_delta/
-| #a #I #G #L1 #V1 #V #T1 #T #HV1 #_ #IHV1 #IHT1 #L2 #HL12 #X #d #e #H elim (cpy_inv_bind1 … H) -H
-  #V2 #T2 #HV2 #HT2 #H destruct /4 width=5 by lpx_pair, cpx_bind/
-| #I #G #L1 #V1 #V #T1 #T #_ #_ #IHV1 #IHT1 #L2 #HL12 #X #d #e #H elim (cpy_inv_flat1 … H) -H
-  #V2 #T2 #HV2 #HT2 #H destruct /3 width=5 by cpx_flat/
-| #G #L1 #V1 #U1 #U #T #_ #HTU #IHU1 #L2 #HL12 #T2 #d #e #HT2
-  lapply (cpy_weak … HT2 0 (∞) ? ?) -HT2 // #HT2
-  elim (lift_total T2 0 1) #U2 #HTU2
-  lapply (cpy_lift_be … HT2 (L2.ⓓV1) … (Ⓕ) … HTU … HTU2 ? ?) -T
-  /4 width=5 by cpx_zeta, lpx_pair, ldrop_drop/
-| /3 width=5 by cpx_tau/
-| /3 width=5 by cpx_ti/
-| #a #G #L1 #V1 #V #W1 #W #T1 #T #HV1 #HW1 #_ #IHV1 #IHW1 #IHT1 #L2 #HL12 #X #d #e #HX
-  elim (cpy_inv_bind1 … HX) -HX #Y #T2 #HY #HT2 #H destruct
-  elim (cpy_inv_flat1 … HY) -HY #W2 #V2 #HW2 #HV2 #H destruct
-  /5 width=11 by lpx_pair, cpx_beta, lsuby_cpy_trans, lsuby_succ/
-| #a #G #L1 #V1 #V #U #W1 #W #T1 #T #_ #HVU #HW1 #_ #IHV1 #IHW1 #IHT1 #L2 #HL12 #X #d #e #HX
-  elim (cpy_inv_bind1 … HX) -HX #W2 #Y #HW2 #HY #H destruct
-  elim (cpy_inv_flat1 … HY) -HY #U2 #T2 #HU2 #HT2 #H destruct
-  lapply (cpy_weak … HU2 0 (∞) ? ?) -HU2 // #HU2
-  elim (cpy_inv_lift1_be … HU2 L2 … HVU) -U
-  /4 width=7 by lpx_pair, cpx_theta, ldrop_drop/
-]
-qed-.
-
-lemma cpx_cpys_trans_lpx: ∀h,g,G,L1,T1,T. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T →
-                          ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
-                          ∀T2,d,e. ⦃G, L2⦄ ⊢ T ▶*[d, e] T2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
-#h #g #G #L1 #T1 #T #HT1 #L2 #HL12 #T2 #d #e #H @(cpys_ind … H) -T2
-/2 width=7 by cpx_cpy_trans_lpx/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_3.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_3.ma
deleted file mode 100644 (file)
index 86fc1f1..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
-
-notation "hvbox( d ~ ϵ break 𝐅 * ⦃ term 46 L, break term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'CoFreeStar $d $L $T }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_4.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/cofreestar_4.ma
new file mode 100644 (file)
index 0000000..e73167c
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
+
+notation "hvbox( L ⊢ break term 46 i ~ ϵ 𝐅 * [ break term 46 d ] ⦃ break term 46 T ⦄ )"
+   non associative with precedence 45
+   for @{ 'CoFreeStar $L $i $d $T }.
index a821838f770cd8597801b2986378d9e24da9e618..6abdbeb59a6f696a846d8f0a367c7bc4c85e197c 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 â\89»â\8b\95 break [ term 46 h, break term 46 g ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 â\89»â\89¡ break [ term 46 h, break term 46 g ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'LazyBTPRedProper $h $g $G1 $L1 $T1 $G2 $L2 $T2 }.
index 91a275ab8fec5aeab4a7b7f90a9d61c6c8711984..e56e02e465937c586f60cfe92a3e9f409ebdd4dc 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 >â\8b\95 break [ term 46 h, break term 46 g ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 >â\89¡ break [ term 46 h, break term 46 g ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'LazyBTPRedStarProper $h $g $G1 $L1 $T1 $G2 $L2 $T2 }.
index 955d59e0dd43468c0e699501a4be48a1ee6b516c..0d9afe1caebe7834fea604cb428fdf369c2c5c93 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( L1 â\8b\95 break [ term 46 T , break term 46 d ] break term 46 L2 )"
+notation "hvbox( L1 â\89¡ break [ term 46 T , break term 46 d ] break term 46 L2 )"
    non associative with precedence 45
    for @{ 'LazyEq $T $d $L1 $L2 }.
index 3c6f5e75eea8f8f632cbbff9bc09e3db97a501f0..4bfa2c7544283489b6ccad42e334e9b04c72b110 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 â\8b\95 break [ term 46 d ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( â¦\83 term 46 G1, break term 46 L1, break term 46 T1 â¦\84 â\89¡ break [ term 46 d ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'LazyEq $d $G1 $L1 $T1 $G2 $L2 $T2 }.
index 786779565d53e08dd72edabed9a1485ac98241fd..4db8587981ad613c06bad4f9096025a5f6242a72 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_ldrop.ma".
+include "basic_2/substitution/llpx_sn_ldrop.ma".
 include "basic_2/reduction/cpr.ma".
 
 (* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
index c36dd0fb411c95a81402b9fb5717a3dcdb53511b..507aaef29241b6463ce331c7c4b3b90e2c45b354 100644 (file)
@@ -20,7 +20,7 @@ include "basic_2/reduction/cpx_llpx_sn.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 lemma lleq_cpx_trans: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡[h, g] T2 →
-                      â\88\80L1. L1 â\8b\95[T1, 0] L2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
+                      â\88\80L1. L1 â\89¡[T1, 0] L2 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
 #h #g #G #L2 #T1 #T2 #H elim H -G -L2 -T1 -T2 /2 width=2 by cpx_st/
 [ #I #G #L2 #K2 #V1 #V2 #W2 #i #HLK2 #_ #HVW2 #IHV12 #L1 #H elim (lleq_fwd_lref_dx … H … HLK2) -L2
   [ #H elim (ylt_yle_false … H) //
@@ -44,12 +44,12 @@ lemma lleq_cpx_trans: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡[h, g] T2 →
 qed-.
 
 lemma cpx_lleq_conf: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡[h, g] T2 →
-                     â\88\80L1. L2 â\8b\95[T1, 0] L1 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
+                     â\88\80L1. L2 â\89¡[T1, 0] L1 → ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2.
 /3 width=3 by lleq_cpx_trans, lleq_sym/ qed-.
 
 lemma cpx_lleq_conf_sn: ∀h,g,G. s_r_confluent1 … (cpx h g G) (lleq 0).
 /3 width=6 by cpx_llpx_sn_conf, lift_mono, ex2_intro/ qed-.
 
 lemma cpx_lleq_conf_dx: ∀h,g,G,L2,T1,T2. ⦃G, L2⦄ ⊢ T1 ➡[h, g] T2 →
-                        â\88\80L1. L1 â\8b\95[T1, 0] L2 â\86\92 L1 â\8b\95[T2, 0] L2.
+                        â\88\80L1. L1 â\89¡[T1, 0] L2 â\86\92 L1 â\89¡[T2, 0] L2.
 /4 width=6 by cpx_lleq_conf_sn, lleq_sym/ qed-.
index 46a83164afcdc9c4ff90b7e7e2ecc73290f99646..41810649416a878f3ed38bb903f0a2fef4f5aea3 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_ldrop.ma".
+include "basic_2/substitution/llpx_sn_ldrop.ma".
 include "basic_2/reduction/cpx.ma".
 
 (* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
index 40e03d59b29b0f5e44d9c8d225b5656ddf911f5a..71d7a0cb9deb223a6be51fe3182755bcb6abbc8d 100644 (file)
@@ -23,7 +23,7 @@ inductive fpb (h) (g) (G1) (L1) (T1): relation3 genv lenv term ≝
 | fpb_fquq: ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ → fpb h g G1 L1 T1 G2 L2 T2
 | fpb_cpx : ∀T2. ⦃G1, L1⦄ ⊢ T1 ➡[h, g] T2 → fpb h g G1 L1 T1 G1 L1 T2
 | fpb_lpx : ∀L2. ⦃G1, L1⦄ ⊢ ➡[h, g] L2 → fpb h g G1 L1 T1 G1 L2 T1
-| fpb_lleq: â\88\80L2. L1 â\8b\95[T1, 0] L2 → fpb h g G1 L1 T1 G1 L2 T1
+| fpb_lleq: â\88\80L2. L1 â\89¡[T1, 0] L2 → fpb h g G1 L1 T1 G1 L2 T1
 .
 
 interpretation
index 182aaae8ac0cc90cae50402660d144b0ea1ed698..3ff9a954fa7bab33c46173352008393dc3658a24 100644 (file)
@@ -22,12 +22,12 @@ include "basic_2/reduction/lpx_ldrop.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 axiom lleq_lpx_trans: ∀h,g,G,L2,K2. ⦃G, L2⦄ ⊢ ➡[h, g] K2 →
-                      â\88\80L1,T,d. L1 â\8b\95[T, d] L2 →
-                      â\88\83â\88\83K1. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] K1 & K1 â\8b\95[T, d] K2.
+                      â\88\80L1,T,d. L1 â\89¡[T, d] L2 →
+                      â\88\83â\88\83K1. â¦\83G, L1â¦\84 â\8a¢ â\9e¡[h, g] K1 & K1 â\89¡[T, d] K2.
 
 lemma lpx_lleq_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                          â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                          â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90 â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                          â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                          â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90 â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
 [ #I #G1 #L1 #V1 #X #H1 #H2 elim (lpx_inv_pair2 … H1) -H1
   #K0 #V0 #H1KL1 #_ #H destruct
@@ -55,8 +55,8 @@ lemma lpx_lleq_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2,
 qed-.
 
 lemma lpx_lleq_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90⸮ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90⸮ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #H1KL1 #H2KL1
 elim (fquq_inv_gen … H) -H
 [ #H elim (lpx_lleq_fqu_trans … H … H1KL1 H2KL1) -L1
@@ -66,8 +66,8 @@ elim (fquq_inv_gen … H) -H
 qed-.
 
 lemma lpx_lleq_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
-                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90+ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90+ â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
 [ #G2 #L2 #T2 #H #K1 #H1KL1 #H2KL1 elim (lpx_lleq_fqu_trans … H … H1KL1 H2KL1) -L1
   /3 width=4 by fqu_fqup, ex3_intro/
@@ -78,8 +78,8 @@ lemma lpx_lleq_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2
 qed-.
 
 lemma lpx_lleq_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
-                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\8b\95[T1, 0] L1 →
-                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90* â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\8b\95[T2, 0] L2.
+                           â\88\80K1. â¦\83G1, K1â¦\84 â\8a¢ â\9e¡[h, g] L1 â\86\92 K1 â\89¡[T1, 0] L1 →
+                           â\88\83â\88\83K2. â¦\83G1, K1, T1â¦\84 â\8a\90* â¦\83G2, K2, T2â¦\84 & â¦\83G2, K2â¦\84 â\8a¢ â\9e¡[h, g] L2 & K2 â\89¡[T2, 0] L2.
 #h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #H1KL1 #H2KL1
 elim (fqus_inv_gen … H) -H
 [ #H elim (lpx_lleq_fqup_trans … H … H1KL1 H2KL1) -L1
@@ -91,7 +91,7 @@ qed-.
 fact leq_lpx_trans_lleq_aux: ∀h,g,G,L1,L0,d,e. L1 ≃[d, e] L0 → e = ∞ →
                              ∀L2. ⦃G, L0⦄ ⊢ ➡[h, g] L2 →
                              ∃∃L. L ≃[d, e] L2 & ⦃G, L1⦄ ⊢ ➡[h, g] L &
-                                  (â\88\80T. L0 â\8b\95[T, d] L2 â\86\94 L1 â\8b\95[T, d] L).
+                                  (â\88\80T. L0 â\89¡[T, d] L2 â\86\94 L1 â\89¡[T, d] L).
 #h #g #G #L1 #L0 #d #e #H elim H -L1 -L0 -d -e
 [ #d #e #_ #L2 #H >(lpx_inv_atom1 … H) -H
   /3 width=5 by ex3_intro, conj/
@@ -115,5 +115,5 @@ qed-.
 lemma leq_lpx_trans_lleq: ∀h,g,G,L1,L0,d. L1 ≃[d, ∞] L0 →
                           ∀L2. ⦃G, L0⦄ ⊢ ➡[h, g] L2 →
                           ∃∃L. L ≃[d, ∞] L2 & ⦃G, L1⦄ ⊢ ➡[h, g] L &
-                               (â\88\80T. L0 â\8b\95[T, d] L2 â\86\94 L1 â\8b\95[T, d] L).
+                               (â\88\80T. L0 â\89¡[T, d] L2 â\86\94 L1 â\89¡[T, d] L).
 /2 width=1 by leq_lpx_trans_lleq_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn.ma
deleted file mode 100644 (file)
index 918b426..0000000
+++ /dev/null
@@ -1,209 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "ground_2/ynat/ynat_plus.ma".
-include "basic_2/relocation/ldrop.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-inductive llpx_sn (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
-| llpx_sn_sort: ∀L1,L2,d,k. |L1| = |L2| → llpx_sn R d (⋆k) L1 L2
-| llpx_sn_skip: ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn R d (#i) L1 L2
-| llpx_sn_lref: ∀I,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
-                ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                llpx_sn R (yinj 0) V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d (#i) L1 L2
-| llpx_sn_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → llpx_sn R d (#i) L1 L2
-| llpx_sn_gref: ∀L1,L2,d,p. |L1| = |L2| → llpx_sn R d (§p) L1 L2
-| llpx_sn_bind: ∀a,I,L1,L2,V,T,d.
-                llpx_sn R d V L1 L2 → llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
-                llpx_sn R d (ⓑ{a,I}V.T) L1 L2
-| llpx_sn_flat: ∀I,L1,L2,V,T,d.
-                llpx_sn R d V L1 L2 → llpx_sn R d T L1 L2 → llpx_sn R d (ⓕ{I}V.T) L1 L2
-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact llpx_sn_inv_bind_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 →
-                           ∀a,I,V,T. X = ⓑ{a,I}V.T →
-                           llpx_sn R d V L1 L2 ∧ llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #L1 #L2 #X #d * -L1 -L2 -X -d
-[ #L1 #L2 #d #k #_ #b #J #W #U #H destruct
-| #L1 #L2 #d #i #_ #_ #b #J #W #U #H destruct
-| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #_ #_ #_ #_ #b #J #W #U #H destruct
-| #L1 #L2 #d #i #_ #_ #_ #b #J #W #U #H destruct
-| #L1 #L2 #d #p #_ #b #J #W #U #H destruct
-| #a #I #L1 #L2 #V #T #d #HV #HT #b #J #W #U #H destruct /2 width=1 by conj/
-| #I #L1 #L2 #V #T #d #_ #_ #b #J #W #U #H destruct
-]
-qed-.
-
-lemma llpx_sn_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
-                        llpx_sn R d V L1 L2 ∧ llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-/2 width=4 by llpx_sn_inv_bind_aux/ qed-.
-
-fact llpx_sn_inv_flat_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 →
-                           ∀I,V,T. X = ⓕ{I}V.T →
-                           llpx_sn R d V L1 L2 ∧ llpx_sn R d T L1 L2.
-#R #L1 #L2 #X #d * -L1 -L2 -X -d
-[ #L1 #L2 #d #k #_ #J #W #U #H destruct
-| #L1 #L2 #d #i #_ #_ #J #W #U #H destruct
-| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #_ #_ #_ #_ #J #W #U #H destruct
-| #L1 #L2 #d #i #_ #_ #_ #J #W #U #H destruct
-| #L1 #L2 #d #p #_ #J #W #U #H destruct
-| #a #I #L1 #L2 #V #T #d #_ #_ #J #W #U #H destruct
-| #I #L1 #L2 #V #T #d #HV #HT #J #W #U #H destruct /2 width=1 by conj/
-]
-qed-.
-
-lemma llpx_sn_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
-                        llpx_sn R d V L1 L2 ∧ llpx_sn R d T L1 L2.
-/2 width=4 by llpx_sn_inv_flat_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma llpx_sn_fwd_length: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d //
-#I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #HLK1 #HLK2 #_ #_ #HK12
-lapply (ldrop_fwd_length … HLK1) -HLK1
-lapply (ldrop_fwd_length … HLK2) -HLK2
-normalize //
-qed-.
-
-lemma llpx_sn_fwd_ldrop_sn: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
-                            ∀K1,i. ⇩[i] L1 ≡ K1 → ∃K2. ⇩[i] L2 ≡ K2.
-#R #L1 #L2 #T #d #H #K1 #i #HLK1 lapply (llpx_sn_fwd_length … H) -H
-#HL12 lapply (ldrop_fwd_length_le2 … HLK1) -HLK1 /2 width=1 by ldrop_O1_le/
-qed-.
-
-lemma llpx_sn_fwd_ldrop_dx: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
-                            ∀K2,i. ⇩[i] L2 ≡ K2 → ∃K1. ⇩[i] L1 ≡ K1.
-#R #L1 #L2 #T #d #H #K2 #i #HLK2 lapply (llpx_sn_fwd_length … H) -H
-#HL12 lapply (ldrop_fwd_length_le2 … HLK2) -HLK2 /2 width=1 by ldrop_O1_le/
-qed-.
-
-fact llpx_sn_fwd_lref_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 → ∀i. X = #i →
-                           ∨∨ |L1| ≤ i ∧ |L2| ≤ i
-                            | yinj i < d
-                            | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                               ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                               llpx_sn R (yinj 0) V1 K1 K2 &
-                                               R I K1 V1 V2 & d ≤ yinj i.
-#R #L1 #L2 #X #d * -L1 -L2 -X -d
-[ #L1 #L2 #d #k #_ #j #H destruct
-| #L1 #L2 #d #i #_ #Hid #j #H destruct /2 width=1 by or3_intro1/
-| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 #j #H destruct
-  /3 width=9 by or3_intro2, ex5_5_intro/
-| #L1 #L2 #d #i #HL1 #HL2 #_ #j #H destruct /3 width=1 by or3_intro0, conj/
-| #L1 #L2 #d #p #_ #j #H destruct
-| #a #I #L1 #L2 #V #T #d #_ #_ #j #H destruct
-| #I #L1 #L2 #V #T #d #_ #_ #j #H destruct
-]
-qed-.
-
-lemma llpx_sn_fwd_lref: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
-                        ∨∨ |L1| ≤ i ∧ |L2| ≤ i
-                         | yinj i < d
-                         | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                            ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                            llpx_sn R (yinj 0) V1 K1 K2 &
-                                            R I K1 V1 V2 & d ≤ yinj i.
-/2 width=3 by llpx_sn_fwd_lref_aux/ qed-.
-
-lemma llpx_sn_fwd_bind_sn: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
-                           llpx_sn R d V L1 L2.
-#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_bind … H) -H //
-qed-.
-
-lemma llpx_sn_fwd_bind_dx: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
-                           llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_bind … H) -H //
-qed-.
-
-lemma llpx_sn_fwd_flat_sn: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
-                           llpx_sn R d V L1 L2.
-#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_flat … H) -H //
-qed-.
-
-lemma llpx_sn_fwd_flat_dx: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
-                           llpx_sn R d T L1 L2.
-#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_flat … H) -H //
-qed-.
-
-lemma llpx_sn_fwd_pair_sn: ∀R,I,L1,L2,V,T,d. llpx_sn R d (②{I}V.T) L1 L2 →
-                           llpx_sn R d V L1 L2.
-#R * /2 width=4 by llpx_sn_fwd_flat_sn, llpx_sn_fwd_bind_sn/
-qed-.
-
-(* Basic_properties *********************************************************)
-
-lemma llpx_sn_refl: ∀R. (∀I,L. reflexive … (R I L)) → ∀T,L,d. llpx_sn R d T L L.
-#R #HR #T #L @(f2_ind … rfw … L T) -L -T
-#n #IH #L * * /3 width=1 by llpx_sn_sort, llpx_sn_gref, llpx_sn_bind, llpx_sn_flat/
-#i #Hn elim (lt_or_ge i (|L|)) /2 width=1 by llpx_sn_free/
-#HiL #d elim (ylt_split i d) /2 width=1 by llpx_sn_skip/
-elim (ldrop_O1_lt … HiL) -HiL destruct /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
-qed-.
-
-lemma llpx_sn_Y: ∀R,T,L1,L2. |L1| = |L2| → llpx_sn R (∞) T L1 L2.
-#R #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * * /3 width=1 by llpx_sn_sort, llpx_sn_skip, llpx_sn_gref, llpx_sn_flat/
-#a #I #V1 #T1 #Hn #L2 #HL12
-@llpx_sn_bind /2 width=1/ (**) (* explicit constructor *)
-@IH -IH // normalize /2 width=1 by eq_f2/
-qed-.
-
-lemma llpx_sn_ge_up: ∀R,L1,L2,U,dt. llpx_sn R dt U L1 L2 → ∀T,d,e. ⇧[d, e] T ≡ U →
-                     dt ≤ d + e → llpx_sn R d U L1 L2.
-#R #L1 #L2 #U #dt #H elim H -L1 -L2 -U -dt
-[ #L1 #L2 #dt #k #HL12 #X #d #e #H #_ >(lift_inv_sort2 … H) -H /2 width=1 by llpx_sn_sort/
-| #L1 #L2 #dt #i #HL12 #Hidt #X #d #e #H #Hdtde
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=1 by llpx_sn_skip, ylt_inj/ -HL12
-  elim (ylt_yle_false … Hidt) -Hidt
-  @(yle_trans … Hdtde) /2 width=1 by yle_inj/ (**) (* full auto too slow 11s *)
-| #I #L1 #L2 #K1 #K2 #W1 #W2 #dt #i #Hdti #HLK1 #HLK2 #HW1 #HW12 #_ #X #d #e #H #_
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ lapply (llpx_sn_fwd_length … HW1) -HW1 #HK12
-    lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
-    normalize in ⊢ (%→%→?); -I -W1 -W2 -dt /3 width=1 by llpx_sn_skip, ylt_inj/
-  | /4 width=9 by llpx_sn_lref, yle_inj, le_plus_b/
-  ]
-| /2 width=1 by llpx_sn_free/
-| #L1 #L2 #dt #p #HL12 #X #d #e #H #_ >(lift_inv_gref2 … H) -H /2 width=1 by llpx_sn_gref/
-| #a #I #L1 #L2 #W #U #dt #_ #_ #IHV #IHT #X #d #e #H #Hdtde destruct
-  elim (lift_inv_bind2 … H) -H #V #T #HVW >commutative_plus #HTU #H destruct 
-  @(llpx_sn_bind) /2 width=4 by/ (**) (* full auto fails *)
-  @(IHT … HTU) /2 width=1 by yle_succ/
-| #I #L1 #L2 #W #U #dt #_ #_ #IHV #IHT #X #d #e #H #Hdtde destruct
-  elim (lift_inv_flat2 … H) -H #HVW #HTU #H destruct
-  /3 width=4 by llpx_sn_flat/
-]
-qed-.
-
-(**) (* the minor premise comes first *)
-lemma llpx_sn_ge: ∀R,L1,L2,T,d1,d2. d1 ≤ d2 →
-                  llpx_sn R d1 T L1 L2 → llpx_sn R d2 T L1 L2.
-#R #L1 #L2 #T #d1 #d2 * -d1 -d2 (**) (* destructed yle *)
-/3 width=6 by llpx_sn_ge_up, llpx_sn_Y, llpx_sn_fwd_length, yle_inj/
-qed-.
-
-lemma llpx_sn_bind_O: ∀R,a,I,L1,L2,V,T. llpx_sn R 0 V L1 L2 →
-                      llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
-                      llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2.
-/3 width=3 by llpx_sn_ge, llpx_sn_bind/ qed-.
-
-lemma llpx_sn_co: ∀R1,R2. (∀I,L,T1,T2. R1 I L T1 T2 → R2 I L T1 T2) →
-                  ∀L1,L2,T,d. llpx_sn R1 d T L1 L2 → llpx_sn R2 d T L1 L2.
-#R1 #R2 #HR12 #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-/3 width=9 by llpx_sn_sort, llpx_sn_skip, llpx_sn_lref, llpx_sn_free, llpx_sn_gref, llpx_sn_bind, llpx_sn_flat/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_alt.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_alt.ma
deleted file mode 100644 (file)
index d0b9b20..0000000
+++ /dev/null
@@ -1,250 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/lift_neg.ma".
-include "basic_2/relocation/ldrop_ldrop.ma".
-include "basic_2/relocation/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* alternative definition of llpx_sn *)
-inductive llpx_sn_alt (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
-| llpx_sn_alt_intro: ∀L1,L2,T,d.
-                     (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                        ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 → I1 = I2 ∧ R I1 K1 V1 V2
-                     ) →
-                     (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                        ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 → llpx_sn_alt R 0 V1 K1 K2
-                     ) → |L1| = |L2| → llpx_sn_alt R d T L1 L2
-.
-
-(* Compact definition of llpx_sn_alt ****************************************)
-
-lemma llpx_sn_alt_intro_alt: ∀R,L1,L2,T,d. |L1| = |L2| →
-                             (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                                ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                                ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt R 0 V1 K1 K2
-                             ) → llpx_sn_alt R d T L1 L2.
-#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt_intro // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by conj/
-qed.
-
-lemma llpx_sn_alt_ind_alt: ∀R. ∀S:relation4 ynat term lenv lenv.
-                           (∀L1,L2,T,d. |L1| = |L2| → (
-                              ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                              ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                              ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt R 0 V1 K1 K2 & S 0 V1 K1 K2
-                           ) → S d T L1 L2) →
-                           ∀L1,L2,T,d. llpx_sn_alt R d T L1 L2 → S d T L1 L2.
-#R #S #IH #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-#L1 #L2 #T #d #H1 #H2 #HL12 #IH2 @IH -IH // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (H1 … HnT HLK1 HLK2) -H1 /4 width=8 by and4_intro/
-qed-.
-
-lemma llpx_sn_alt_inv_alt: ∀R,L1,L2,T,d. llpx_sn_alt R d T L1 L2 →
-                           |L1| = |L2| ∧
-                           ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt R 0 V1 K1 K2.
-#R #L1 #L2 #T #d #H @(llpx_sn_alt_ind_alt … H) -L1 -L2 -T -d
-#L1 #L2 #T #d #HL12 #IH @conj // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by and3_intro/
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma llpx_sn_alt_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn_alt R d (ⓕ{I}V.T) L1 L2 →
-                            llpx_sn_alt R d V L1 L2 ∧ llpx_sn_alt R d T L1 L2.
-#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_inv_alt … H) -H
-#HL12 #IH @conj @llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2
-elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2 //
-/3 width=8 by nlift_flat_sn, nlift_flat_dx, and3_intro/
-qed-.
-
-lemma llpx_sn_alt_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn_alt R d (ⓑ{a,I}V.T) L1 L2 →
-                            llpx_sn_alt R d V L1 L2 ∧ llpx_sn_alt R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_inv_alt … H) -H
-#HL12 #IH @conj @llpx_sn_alt_intro_alt [1,3: normalize // ] -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2
-[ elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2
-  /3 width=9 by nlift_bind_sn, and3_intro/
-| lapply (yle_inv_succ1 … Hdi) -Hdi * #Hdi #Hi
-  lapply (ldrop_inv_drop1_lt … HLK1 ?) -HLK1 /2 width=1 by ylt_O/ #HLK1
-  lapply (ldrop_inv_drop1_lt … HLK2 ?) -HLK2 /2 width=1 by ylt_O/ #HLK2
-  elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2 /2 width=1 by and3_intro/
-  @nlift_bind_dx <plus_minus_m_m /2 width=2 by ylt_O/
-]
-qed-.
-
-(* Basic forward lemmas ******************************************************)
-
-lemma llpx_sn_alt_fwd_length: ∀R,L1,L2,T,d. llpx_sn_alt R d T L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #T #d #H elim (llpx_sn_alt_inv_alt … H) -H //
-qed-.
-
-lemma llpx_sn_alt_fwd_lref: ∀R,L1,L2,d,i. llpx_sn_alt R d (#i) L1 L2 →
-                            ∨∨ |L1| ≤ i ∧ |L2| ≤ i
-                             | yinj i < d
-                             | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                                ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                                llpx_sn_alt R (yinj 0) V1 K1 K2 &
-                                                R I K1 V1 V2 & d ≤ yinj i.
-#R #L1 #L2 #d #i #H elim (llpx_sn_alt_inv_alt … H) -H
-#HL12 #IH elim (lt_or_ge i (|L1|)) /3 width=1 by or3_intro0, conj/
-elim (ylt_split i d) /3 width=1 by or3_intro1/
-#Hdi #HL1 elim (ldrop_O1_lt … HL1)
-#I1 #K1 #V1 #HLK1 elim (ldrop_O1_lt L2 i) //
-#I2 #K2 #V2 #HLK2 elim (IH … HLK1 HLK2) -IH
-/3 width=9 by nlift_lref_be_SO, or3_intro2, ex5_5_intro/
-qed-.
-
-(* Basic properties **********************************************************)
-
-lemma llpx_sn_alt_sort: ∀R,L1,L2,d,k. |L1| = |L2| → llpx_sn_alt R d (⋆k) L1 L2.
-#R #L1 #L2 #d #k #HL12 @llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (⋆k)) //
-qed.
-
-lemma llpx_sn_alt_gref: ∀R,L1,L2,d,p. |L1| = |L2| → llpx_sn_alt R d (§p) L1 L2.
-#R #L1 #L2 #d #p #HL12 @llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (§p)) //
-qed.
-
-lemma llpx_sn_alt_skip: ∀R,L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn_alt R d (#i) L1 L2.
-#R #L1 #L2 #d #i #HL12 #Hid @llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #j #Hdj #H elim (H (#i)) -H
-/4 width=3 by lift_lref_lt, ylt_yle_trans, ylt_inv_inj/
-qed.
-
-lemma llpx_sn_alt_free: ∀R,L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| →
-                        llpx_sn_alt R d (#i) L1 L2.
-#R #L1 #L2 #d #i #HL1 #_ #HL12 @llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #j #_ #H #HLK1 elim (H (#(i-1))) -H
-lapply (ldrop_fwd_length_lt2 … HLK1) -HLK1
-/3 width=3 by lift_lref_ge_minus, lt_to_le_to_lt/
-qed.
-
-lemma llpx_sn_alt_lref: ∀R,I,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
-                        ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                        llpx_sn_alt R 0 V1 K1 K2 → R I K1 V1 V2 →
-                        llpx_sn_alt R d (#i) L1 L2.
-#R #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 @llpx_sn_alt_intro_alt
-[ lapply (llpx_sn_alt_fwd_length … HK12) -HK12 #HK12
-  @(ldrop_fwd_length_eq2 … HLK1 HLK2) normalize //
-| #Z1 #Z2 #Y1 #Y2 #X1 #X2 #j #Hdj #H #HLY1 #HLY2
-  elim (lt_or_eq_or_gt i j) #Hij destruct
-  [ elim (H (#i)) -H /2 width=1 by lift_lref_lt/
-  | lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1 #H destruct
-    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2 #H destruct /2 width=1 by and3_intro/
-  | elim (H (#(i-1))) -H /2 width=1 by lift_lref_ge_minus/
-  ]
-]
-qed.
-
-lemma llpx_sn_alt_flat: ∀R,I,L1,L2,V,T,d.
-                        llpx_sn_alt R d V L1 L2 → llpx_sn_alt R d T L1 L2 →
-                        llpx_sn_alt R d (ⓕ{I}V.T) L1 L2.
-#R #I #L1 #L2 #V #T #d #HV #HT
-elim (llpx_sn_alt_inv_alt … HV) -HV #HL12 #IHV
-elim (llpx_sn_alt_inv_alt … HT) -HT #_ #IHT
-@llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnVT #HLK1 #HLK2
-elim (nlift_inv_flat … HnVT) -HnVT #H
-[ elim (IHV … HLK1 … HLK2) -IHV /2 width=2 by and3_intro/
-| elim (IHT … HLK1 … HLK2) -IHT /3 width=2 by and3_intro/
-]
-qed.
-
-lemma llpx_sn_alt_bind: ∀R,a,I,L1,L2,V,T,d.
-                        llpx_sn_alt R d V L1 L2 →
-                        llpx_sn_alt R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
-                        llpx_sn_alt R d (ⓑ{a,I}V.T) L1 L2.
-#R #a #I #L1 #L2 #V #T #d #HV #HT
-elim (llpx_sn_alt_inv_alt … HV) -HV #HL12 #IHV
-elim (llpx_sn_alt_inv_alt … HT) -HT #_ #IHT
-@llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnVT #HLK1 #HLK2
-elim (nlift_inv_bind … HnVT) -HnVT #H
-[ elim (IHV … HLK1 … HLK2) -IHV /2 width=2 by and3_intro/
-| elim IHT -IHT /2 width=12 by ldrop_drop, yle_succ, and3_intro/
-]
-qed.
-
-(* Main properties **********************************************************)
-
-theorem llpx_sn_lpx_sn_alt: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → llpx_sn_alt R d T L1 L2.
-#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-/2 width=9 by llpx_sn_alt_sort, llpx_sn_alt_gref, llpx_sn_alt_skip, llpx_sn_alt_free, llpx_sn_alt_lref, llpx_sn_alt_flat, llpx_sn_alt_bind/
-qed.
-
-(* Main inversion lemmas ****************************************************)
-
-theorem llpx_sn_alt_inv_lpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt R d T L1 L2 → llpx_sn R d T L1 L2.
-#R #T #L1 @(f2_ind … rfw … L1 T) -L1 -T #n #IH #L1 * *
-[1,3: /3 width=4 by llpx_sn_alt_fwd_length, llpx_sn_gref, llpx_sn_sort/
-| #i #Hn #L2 #d #H lapply (llpx_sn_alt_fwd_length … H)
-  #HL12 elim (llpx_sn_alt_fwd_lref … H) -H
-  [ * /2 width=1 by llpx_sn_free/
-  | /2 width=1 by llpx_sn_skip/
-  | * /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
-  ]
-| #a #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt_inv_bind … H) -H
-  /3 width=1 by llpx_sn_bind/
-| #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-]
-qed-.
-
-(* Alternative definition of llpx_sn ****************************************)
-
-lemma llpx_sn_intro_alt: ∀R,L1,L2,T,d. |L1| = |L2| →
-                         (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                            ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2
-                         ) → llpx_sn R d T L1 L2.
-#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt_inv_lpx_sn
-@llpx_sn_alt_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_lpx_sn_alt, and3_intro/
-qed.
-
-lemma llpx_sn_ind_alt: ∀R. ∀S:relation4 ynat term lenv lenv.
-                       (∀L1,L2,T,d. |L1| = |L2| → (
-                          ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                          ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                          ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2 & S 0 V1 K1 K2
-                       ) → S d T L1 L2) →
-                       ∀L1,L2,T,d. llpx_sn R d T L1 L2 → S d T L1 L2.
-#R #S #IH1 #L1 #L2 #T #d #H lapply (llpx_sn_lpx_sn_alt … H) -H
-#H @(llpx_sn_alt_ind_alt … H) -L1 -L2 -T -d
-#L1 #L2 #T #d #HL12 #IH2 @IH1 -IH1 // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (IH2 … HnT HLK1 HLK2) -IH2 -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_alt_inv_lpx_sn, and4_intro/
-qed-.
-
-lemma llpx_sn_inv_alt: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
-                       |L1| = |L2| ∧
-                       ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
-                       ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                       ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2.
-#R #L1 #L2 #T #d #H lapply (llpx_sn_lpx_sn_alt … H) -H
-#H elim (llpx_sn_alt_inv_alt … H) -H
-#HL12 #IH @conj //
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
-elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_alt_inv_lpx_sn, and3_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_ldrop.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_ldrop.ma
deleted file mode 100644 (file)
index 313ddd4..0000000
+++ /dev/null
@@ -1,431 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/ldrop_ldrop.ma".
-include "basic_2/relocation/llpx_sn_leq.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* Advanced forward lemmas **************************************************)
-
-lemma llpx_sn_fwd_lref_dx: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
-                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                           i < d ∨
-                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 & llpx_sn R 0 V1 K1 K2 &
-                                    R I K1 V1 V2 & d ≤ i.
-#R #L1 #L2 #d #i #H #I #K2 #V2 #HLK2 elim (llpx_sn_fwd_lref … H) -H [ * || * ]
-[ #_ #H elim (lt_refl_false i)
-  lapply (ldrop_fwd_length_lt2 … HLK2) -HLK2
-  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
-| /2 width=1 by or_introl/
-| #I #K11 #K22 #V11 #V22 #HLK11 #HLK22 #HK12 #HV12 #Hdi
-  lapply (ldrop_mono … HLK22 … HLK2) -L2 #H destruct
-  /3 width=5 by ex4_2_intro, or_intror/
-]
-qed-.
-
-lemma llpx_sn_fwd_lref_sn: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
-                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                           i < d ∨
-                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 & llpx_sn R 0 V1 K1 K2 &
-                                    R I K1 V1 V2 & d ≤ i.
-#R #L1 #L2 #d #i #H #I #K1 #V1 #HLK1 elim (llpx_sn_fwd_lref … H) -H [ * || * ]
-[ #H #_ elim (lt_refl_false i)
-  lapply (ldrop_fwd_length_lt2 … HLK1) -HLK1
-  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
-| /2 width=1 by or_introl/
-| #I #K11 #K22 #V11 #V22 #HLK11 #HLK22 #HK12 #HV12 #Hdi
-  lapply (ldrop_mono … HLK11 … HLK1) -L1 #H destruct
-  /3 width=5 by ex4_2_intro, or_intror/
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma llpx_sn_inv_lref_ge_dx: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
-                              ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                              ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                       llpx_sn R 0 V1 K1 K2 & R I K1 V1 V2.
-#R #L1 #L2 #d #i #H #Hdi #I #K2 #V2 #HLK2 elim (llpx_sn_fwd_lref_dx … H … HLK2) -L2
-[ #H elim (ylt_yle_false … H Hdi)
-| * /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma llpx_sn_inv_lref_ge_sn: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
-                              ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                              ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                       llpx_sn R 0 V1 K1 K2 & R I K1 V1 V2.
-#R #L1 #L2 #d #i #H #Hdi #I #K1 #V1 #HLK1 elim (llpx_sn_fwd_lref_sn … H … HLK1) -L1
-[ #H elim (ylt_yle_false … H Hdi)
-| * /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma llpx_sn_inv_lref_ge_bi: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
-                              ∀I1,I2,K1,K2,V1,V2.
-                              ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                              ∧∧ I1 = I2 & llpx_sn R 0 V1 K1 K2 & R I1 K1 V1 V2.
-#R #L1 #L2 #d #i #HL12 #Hdi #I1 #I2 #K1 #K2 #V1 #V2 #HLK1 #HLK2
-elim (llpx_sn_inv_lref_ge_sn … HL12 … HLK1) // -L1 -d
-#J #Y #HY lapply (ldrop_mono … HY … HLK2) -L2 -i #H destruct /2 width=1 by and3_intro/
-qed-.
-
-fact llpx_sn_inv_S_aux: ∀R,L1,L2,T,d0. llpx_sn R d0 T L1 L2 → ∀d. d0 = d + 1 →
-                        ∀K1,K2,I,V1,V2. ⇩[d] L1 ≡ K1.ⓑ{I}V1 → ⇩[d] L2 ≡ K2.ⓑ{I}V2 →
-                        llpx_sn R 0 V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d T L1 L2.
-#R #L1 #L2 #T #d0 #H elim H -L1 -L2 -T -d0
-/2 width=1 by llpx_sn_gref, llpx_sn_free, llpx_sn_sort/
-[ #L1 #L2 #d0 #i #HL12 #Hid #d #H #K1 #K2 #I #V1 #V2 #HLK1 #HLK2 #HK12 #HV12 destruct
-  elim (yle_split_eq i d) /2 width=1 by llpx_sn_skip, ylt_fwd_succ2/ -HL12 -Hid
-  #H destruct /2 width=9 by llpx_sn_lref/
-| #I #L1 #L2 #K11 #K22 #V1 #V2 #d0 #i #Hd0i #HLK11 #HLK22 #HK12 #HV12 #_ #d #H #K1 #K2 #J #W1 #W2 #_ #_ #_ #_ destruct
-  /3 width=9 by llpx_sn_lref, yle_pred_sn/
-| #a #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W1 #W2 #HLK1 #HLK2 #HK12 #HW12 destruct
-  /4 width=9 by llpx_sn_bind, ldrop_drop/
-| #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W1 #W2 #HLK1 #HLK2 #HK12 #HW12 destruct
-  /3 width=9 by llpx_sn_flat/
-]
-qed-.
-
-lemma llpx_sn_inv_S: ∀R,L1,L2,T,d. llpx_sn R (d + 1) T L1 L2 →
-                     ∀K1,K2,I,V1,V2. ⇩[d] L1 ≡ K1.ⓑ{I}V1 → ⇩[d] L2 ≡ K2.ⓑ{I}V2 →
-                     llpx_sn R 0 V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d T L1 L2.
-/2 width=9 by llpx_sn_inv_S_aux/ qed-.
-
-lemma llpx_sn_inv_bind_O: ∀R. (∀I,L. reflexive … (R I L)) →
-                          ∀a,I,L1,L2,V,T. llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 →
-                          llpx_sn R 0 V L1 L2 ∧ llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_inv_bind … H) -H
-/3 width=9 by ldrop_pair, conj, llpx_sn_inv_S/
-qed-.
-
-(* More advanced forward lemmas *********************************************)
-
-lemma llpx_sn_fwd_bind_O_dx: ∀R. (∀I,L. reflexive … (R I L)) →
-                             ∀a,I,L1,L2,V,T. llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 →
-                             llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_inv_bind_O … H) -H //
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma llpx_sn_bind_repl_O: ∀R,I,L1,L2,V1,V2,T. llpx_sn R 0 T (L1.ⓑ{I}V1) (L2.ⓑ{I}V2) →
-                           ∀J,W1,W2. llpx_sn R 0 W1 L1 L2 → R J L1 W1 W2 → llpx_sn R 0 T (L1.ⓑ{J}W1) (L2.ⓑ{J}W2).
-/3 width=9 by llpx_sn_bind_repl_SO, llpx_sn_inv_S/ qed-.
-
-lemma llpx_sn_dec: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
-                   ∀T,L1,L2,d. Decidable (llpx_sn R d T L1 L2).
-#R #HR #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * *
-[ #k #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, llpx_sn_sort/
-| #i #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|))
-  [ #HL12 #d elim (ylt_split i d) /3 width=1 by llpx_sn_skip, or_introl/
-    #Hdi elim (lt_or_ge i (|L1|)) #HiL1
-    elim (lt_or_ge i (|L2|)) #HiL2 /3 width=1 by or_introl, llpx_sn_free/
-    elim (ldrop_O1_lt … HiL2) #I2 #K2 #V2 #HLK2
-    elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
-    elim (eq_bind2_dec I2 I1)
-    [ #H2 elim (HR I1 K1 V1 V2) -HR
-      [ #H3 elim (IH K1 V1 … K2 0) destruct
-        /3 width=9 by llpx_sn_lref, ldrop_fwd_rfw, or_introl/
-      ]
-    ]
-    -IH #H3 @or_intror
-    #H elim (llpx_sn_fwd_lref … H) -H [1,3,4,6,7,9: * ]
-    [1,3,5: /3 width=4 by lt_to_le_to_lt, lt_refl_false/
-    |7,8,9: /2 width=4 by ylt_yle_false/
-    ]
-    #Z #Y1 #Y2 #X1 #X2 #HLY1 #HLY2 #HY12 #HX12
-    lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1
-    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2
-    #H #H0 destruct /2 width=1 by/
-  ]
-| #p #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, llpx_sn_gref/
-| #a #I #V #T #Hn #L2 #d destruct
-  elim (IH L1 V … L2 d) /2 width=1 by/
-  elim (IH (L1.ⓑ{I}V) T … (L2.ⓑ{I}V) (⫯d)) -IH /3 width=1 by or_introl, llpx_sn_bind/
-  #H1 #H2 @or_intror
-  #H elim (llpx_sn_inv_bind … H) -H /2 width=1 by/
-| #I #V #T #Hn #L2 #d destruct
-  elim (IH L1 V … L2 d) /2 width=1 by/
-  elim (IH L1 T … L2 d) -IH /3 width=1 by or_introl, llpx_sn_flat/
-  #H1 #H2 @or_intror
-  #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
-]
--n /4 width=4 by llpx_sn_fwd_length, or_intror/
-qed-.
-
-(* Properties on relocation *************************************************)
-
-lemma llpx_sn_lift_le: ∀R. (∀I. l_liftable (R I)) →
-                       ∀K1,K2,T,d0. llpx_sn R d0 T K1 K2 →
-                       ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                       ∀U. ⇧[d, e] T ≡ U → d0 ≤ d → llpx_sn R d0 U L1 L2.
-#R #HR #K1 #K2 #T #d0 #H elim H -K1 -K2 -T -d0
-[ #K1 #K2 #d0 #k #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort1 … H) -X
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
-  /2 width=1 by llpx_sn_sort/
-| #K1 #K2 #d0 #i #HK12 #Hid0 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
-  * #Hdi #H destruct
-  [ lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
-    /2 width=1 by llpx_sn_skip/
-  | elim (ylt_yle_false … Hid0) -L1 -L2 -K1 -K2 -e -Hid0
-    /3 width=3 by yle_trans, yle_inj/
-  ]
-| #I #K1 #K2 #K11 #K22 #V1 #V2 #d0 #i #Hid0 #HK11 #HK22 #HK12 #HV12 #IHK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
-  * #Hdi #H destruct [ -HK12 | -IHK12 ]
-  [ elim (ldrop_trans_lt … HLK1 … HK11) // -K1
-    elim (ldrop_trans_lt … HLK2 … HK22) // -Hdi -K2
-    /3 width=18 by llpx_sn_lref/
-  | lapply (ldrop_trans_ge_comm … HLK1 … HK11 ?) // -K1
-    lapply (ldrop_trans_ge_comm … HLK2 … HK22 ?) // -Hdi -Hd0 -K2
-    /3 width=9 by llpx_sn_lref, yle_plus_dx1_trans/
-  ]
-| #K1 #K2 #d0 #i #HK1 #HK2 #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
-  * #Hid #H destruct
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -HK12
-  [ /3 width=7 by llpx_sn_free, ldrop_fwd_be/
-  | lapply (ldrop_fwd_length … HLK1) -HLK1 #HLK1
-    lapply (ldrop_fwd_length … HLK2) -HLK2 #HLK2
-    @llpx_sn_free [ >HLK1 | >HLK2 ] -Hid -HLK1 -HLK2 /2 width=1 by monotonic_le_plus_r/ (**) (* explicit constructor *)
-  ]
-| #K1 #K2 #d0 #p #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref1 … H) -X
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d -e
-  /2 width=1 by llpx_sn_gref/
-| #a #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind1 … H) -H
-  #W #U #HVW #HTU #H destruct /4 width=6 by llpx_sn_bind, ldrop_skip, yle_succ/
-| #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat1 … H) -H
-  #W #U #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
-]
-qed-.
-
-lemma llpx_sn_lift_ge: ∀R,K1,K2,T,d0. llpx_sn R d0 T K1 K2 →
-                       ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                       ∀U. ⇧[d, e] T ≡ U → d ≤ d0 → llpx_sn R (d0+e) U L1 L2.
-#R #K1 #K2 #T #d0 #H elim H -K1 -K2 -T -d0
-[ #K1 #K2 #d0 #k #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort1 … H) -X
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
-  /2 width=1 by llpx_sn_sort/
-| #K1 #K2 #d0 #i #HK12 #Hid0 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ elim (lift_inv_lref1 … H) -H
-  * #_ #H destruct
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2
-  [ /3 width=3 by llpx_sn_skip, ylt_plus_dx2_trans/
-  | /3 width=3 by llpx_sn_skip, monotonic_ylt_plus_dx/
-  ]
-| #I #K1 #K2 #K11 #K22 #V1 #V2 #d0 #i #Hid0 #HK11 #HK22 #HK12 #HV12 #_ #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
-  * #Hid #H destruct
-  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K1 -K2 -K11 -K22 -V1 -V2 -e -Hid0
-    /3 width=3 by ylt_yle_trans, ylt_inj/
-  | lapply (ldrop_trans_ge_comm … HLK1 … HK11 ?) // -K1
-    lapply (ldrop_trans_ge_comm … HLK2 … HK22 ?) // -Hid -Hd0 -K2
-    /3 width=9 by llpx_sn_lref, monotonic_yle_plus_dx/
-  ]
-| #K1 #K2 #d0 #i #HK1 #HK2 #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
-  * #Hid #H destruct
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -HK12
-  [ /3 width=7 by llpx_sn_free, ldrop_fwd_be/
-  | lapply (ldrop_fwd_length … HLK1) -HLK1 #HLK1
-    lapply (ldrop_fwd_length … HLK2) -HLK2 #HLK2
-    @llpx_sn_free [ >HLK1 | >HLK2 ] -Hid -HLK1 -HLK2 /2 width=1 by monotonic_le_plus_r/ (**) (* explicit constructor *)
-  ]
-| #K1 #K2 #d0 #p #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref1 … H) -X
-  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
-  /2 width=1 by llpx_sn_gref/
-| #a #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind1 … H) -H
-  #W #U #HVW #HTU #H destruct /4 width=5 by llpx_sn_bind, ldrop_skip, yle_succ/
-| #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat1 … H) -H
-  #W #U #HVW #HTU #H destruct /3 width=5 by llpx_sn_flat/
-]
-qed-.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma llpx_sn_inv_lift_le: ∀R. (∀I. l_deliftable_sn (R I)) →
-                           ∀L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
-                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                           ∀T. ⇧[d, e] T ≡ U → d0 ≤ d → llpx_sn R d0 T K1 K2.
-#R #HR #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
-[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d -e
-  /2 width=1 by llpx_sn_sort/
-| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ elim (lift_inv_lref2 … H) -H
-  * #_ #H destruct
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
-  [ /2 width=1 by llpx_sn_skip/
-  | /3 width=3 by llpx_sn_skip, yle_ylt_trans/
-  ]
-| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #IHK12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref2 … H) -H
-  * #Hid #H destruct [ -HK12 | -IHK12 ]
-  [ elim (ldrop_conf_lt … HLK1 … HLK11) // -L1 #L1 #V1 #HKL1 #HKL11 #HVW1
-    elim (ldrop_conf_lt … HLK2 … HLK22) // -Hid -L2 #L2 #V2 #HKL2 #HKL22 #HVW2
-    elim (HR … HW12 … HKL11 … HVW1) -HR #V0 #HV0 #HV12
-    lapply (lift_inj … HV0 … HVW2) -HV0 -HVW2 #H destruct
-    /3 width=10 by llpx_sn_lref/
-  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
-    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hid0
-    elim (le_inv_plus_l … Hid) -Hid /4 width=9 by llpx_sn_lref, yle_trans, yle_inj/ (**) (* slow *)
-  ]
-| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref2 … H) -H
-  * #_ #H destruct
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
-  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
-    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
-    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
-  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
-    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
-    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
-  ]
-| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d -e
-  /2 width=1 by llpx_sn_gref/
-| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind2 … H) -H
-  #V #T #HVW #HTU #H destruct /4 width=6 by llpx_sn_bind, ldrop_skip, yle_succ/
-| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat2 … H) -H
-  #V #T #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
-]
-qed-.
-
-lemma llpx_sn_inv_lift_be: ∀R,L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
-                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                           ∀T. ⇧[d, e] T ≡ U → d ≤ d0 → d0 ≤ yinj d + e → llpx_sn R d T K1 K2.
-#R #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
-[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ #_ >(lift_inv_sort2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d0 -e
-  /2 width=1 by llpx_sn_sort/
-| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
-  * #Hid #H destruct
-  [ lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
-    -Hid0 /3 width=1 by llpx_sn_skip, ylt_inj/
-  | elim (ylt_yle_false … Hid0) -L1 -L2 -Hd0 -Hid0
-    /3 width=3 by yle_trans, yle_inj/ (**) (* slow *)
-  ]
-| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #_ #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
-  * #Hid #H destruct
-  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K11 -K22 -W1 -W2 -Hd0e -Hid0
-    /3 width=3 by ylt_yle_trans, ylt_inj/
-  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
-    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hid0 -Hd0 -Hd0e
-    elim (le_inv_plus_l … Hid) -Hid /3 width=9 by llpx_sn_lref, yle_inj/
-  ]
-| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
-  * #_ #H destruct
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
-  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
-    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
-    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
-  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
-    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
-    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
-  ]
-| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ #_ >(lift_inv_gref2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d0 -e
-  /2 width=1 by llpx_sn_gref/
-| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_bind2 … H) -H
-  >commutative_plus #V #T #HVW #HTU #H destruct
-  @llpx_sn_bind [ /2 width=5 by/ ] -IHW (**) (* explicit constructor *)
-  @(IHU … HTU) -IHU -HTU /2 width=1 by ldrop_skip, yle_succ/
-| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_flat2 … H) -H
-  #V #T #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
-]
-qed-.
-
-lemma llpx_sn_inv_lift_ge: ∀R,L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
-                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                           ∀T. ⇧[d, e] T ≡ U → yinj d + e ≤ d0 → llpx_sn R (d0-e) T K1 K2.
-#R #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
-[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d
-  /2 width=1 by llpx_sn_sort/
-| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
-  * #Hid #H destruct [ -Hid0 | -Hded0 ]
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
-  [ /4 width=3 by llpx_sn_skip, yle_plus_to_minus_inj2, ylt_yle_trans, ylt_inj/
-  | elim (le_inv_plus_l … Hid) -Hid #_
-    /4 width=1 by llpx_sn_skip, monotonic_ylt_minus_dx, yle_inj/
-  ]
-| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #_ #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
-  * #Hid #H destruct
-  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K11 -K22 -W1 -W2 -Hid0
-    /3 width=3 by yle_fwd_plus_sn1, ylt_yle_trans, ylt_inj/
-  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
-    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hded0 -Hid
-    /3 width=9 by llpx_sn_lref, monotonic_yle_minus_dx/
-  ]
-| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
-  * #_ #H destruct
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
-  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
-    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
-    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
-  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
-    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
-    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
-  ]
-| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref2 … H) -X
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d
-  /2 width=1 by llpx_sn_gref/
-| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_bind2 … H) -H
-  #V #T #HVW #HTU #H destruct
-  @llpx_sn_bind [ /2 width=5 by/ ] -IHW (**) (* explicit constructor *)
-  <yminus_succ1_inj /2 width=2 by yle_fwd_plus_sn2/
-  @(IHU … HTU) -IHU -HTU /2 width=1 by ldrop_skip, yle_succ/
-| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_flat2 … H) -H
-  #V #T #HVW #HTU #H destruct /3 width=5 by llpx_sn_flat/
-]
-qed-.
-
-(* Advanced inversion lemmas on relocation **********************************)
-
-lemma llpx_sn_inv_lift_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
-                          ∀K1,K2,e. ⇩[e] L1 ≡ K1 → ⇩[e] L2 ≡ K2 →
-                          ∀T. ⇧[0, e] T ≡ U → llpx_sn R 0 T K1 K2.
-/2 width=11 by llpx_sn_inv_lift_be/ qed-.
-
-lemma llpx_sn_ldrop_conf_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
-                            ∀K1,e. ⇩[e] L1 ≡ K1 → ∀T. ⇧[0, e] T ≡ U →
-                            ∃∃K2. ⇩[e] L2 ≡ K2 & llpx_sn R 0 T K1 K2.
-#R #L1 #L2 #U #HU #K1 #e #HLK1 #T #HTU elim (llpx_sn_fwd_ldrop_sn … HU … HLK1)
-/3 width=10 by llpx_sn_inv_lift_O, ex2_intro/
-qed-.
-
-lemma llpx_sn_ldrop_trans_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
-                             ∀K2,e. ⇩[e] L2 ≡ K2 → ∀T. ⇧[0, e] T ≡ U →
-                             ∃∃K1. ⇩[e] L1 ≡ K1 & llpx_sn R 0 T K1 K2.
-#R #L1 #L2 #U #HU #K2 #e #HLK2 #T #HTU elim (llpx_sn_fwd_ldrop_dx … HU … HLK2)
-/3 width=10 by llpx_sn_inv_lift_O, ex2_intro/
-qed-.
-
-(* Inversion lemmas on negated lazy pointwise extension *********************)
-
-lemma nllpx_sn_inv_bind: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
-                         ∀a,I,L1,L2,V,T,d. (llpx_sn R d (ⓑ{a,I}V.T) L1 L2 → ⊥) →
-                         (llpx_sn R d V L1 L2 → ⊥) ∨ (llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → ⊥).
-#R #HR #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_dec … HR V L1 L2 d)
-/4 width=1 by llpx_sn_bind, or_intror, or_introl/
-qed-.
-
-lemma nllpx_sn_inv_flat: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
-                         ∀I,L1,L2,V,T,d. (llpx_sn R d (ⓕ{I}V.T) L1 L2 → ⊥) →
-                         (llpx_sn R d V L1 L2 → ⊥) ∨ (llpx_sn R d T L1 L2 → ⊥).
-#R #HR #I #L1 #L2 #V #T #d #H elim (llpx_sn_dec … HR V L1 L2 d)
-/4 width=1 by llpx_sn_flat, or_intror, or_introl/
-qed-.
-
-lemma nllpx_sn_inv_bind_O: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
-                           ∀a,I,L1,L2,V,T. (llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 → ⊥) →
-                           (llpx_sn R 0 V L1 L2 → ⊥) ∨ (llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → ⊥).
-#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_dec … HR V L1 L2 0)
-/4 width=1 by llpx_sn_bind_O, or_intror, or_introl/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_leq.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_leq.ma
deleted file mode 100644 (file)
index f347027..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/ldrop_leq.ma".
-include "basic_2/relocation/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* Properties on equivalence for local environments *************************)
-
-lemma leq_llpx_sn_trans: ∀R,L2,L,T,d. llpx_sn R d T L2 L →
-                         ∀L1. L1 ≃[d, ∞] L2 → llpx_sn R d T L1 L.
-#R #L2 #L #T #d #H elim H -L2 -L -T -d
-/4 width=5 by llpx_sn_flat, llpx_sn_gref, llpx_sn_skip, llpx_sn_sort, leq_fwd_length, trans_eq/  
-[ #I #L2 #L #K2 #K #V2 #V #d #i #Hdi #HLK2 #HLK #HK2 #HV2 #_ #L1 #HL12
-  elim (leq_ldrop_trans_be … HL12 … HLK2) -L2 // >yminus_Y_inj #K1 #HK12 #HLK1
-  lapply (leq_inv_O_Y … HK12) -HK12 #H destruct /2 width=9 by llpx_sn_lref/
-| /4 width=5 by llpx_sn_free, leq_fwd_length, le_repl_sn_trans_aux, trans_eq/
-| /4 width=1 by llpx_sn_bind, leq_succ/
-]
-qed-.
-
-lemma llpx_sn_leq_trans: ∀R,L,L1,T,d. llpx_sn R d T L L1 →
-                         ∀L2. L1 ≃[d, ∞] L2 → llpx_sn R d T L L2.
-#R #L #L1 #T #d #H elim H -L -L1 -T -d
-/4 width=5 by llpx_sn_flat, llpx_sn_gref, llpx_sn_skip, llpx_sn_sort, leq_fwd_length, trans_eq/  
-[ #I #L #L1 #K #K1 #V #V1 #d #i #Hdi #HLK #HLK1 #HK1 #HV1 #_ #L2 #HL12
-  elim (leq_ldrop_conf_be … HL12 … HLK1) -L1 // >yminus_Y_inj #K2 #HK12 #HLK2
-  lapply (leq_inv_O_Y … HK12) -HK12 #H destruct /2 width=9 by llpx_sn_lref/
-| /4 width=5 by llpx_sn_free, leq_fwd_length, le_repl_sn_conf_aux, trans_eq/
-| /4 width=1 by llpx_sn_bind, leq_succ/
-]
-qed-.
-
-lemma llpx_sn_leq_repl: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → ∀K1. K1 ≃[d, ∞] L1 → 
-                        ∀K2. L2 ≃[d, ∞] K2 → llpx_sn R d T K1 K2.
-/3 width=4 by llpx_sn_leq_trans, leq_llpx_sn_trans/ qed-.
-
-lemma llpx_sn_bind_repl_SO: ∀R,I1,I2,L1,L2,V1,V2,T. llpx_sn R 0 T (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2) →
-                            ∀J1,J2,W1,W2. llpx_sn R 1 T (L1.ⓑ{J1}W1) (L2.ⓑ{J2}W2).
-#R #I1 #I2 #L1 #L2 #V1 #V2 #T #HT #J1 #J2 #W1 #W2 lapply (llpx_sn_ge R … 1 … HT) -HT
-/3 width=7 by llpx_sn_leq_repl, leq_succ/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_lpx_sn.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_lpx_sn.ma
deleted file mode 100644 (file)
index 6462115..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/lpx_sn_ldrop.ma".
-include "basic_2/relocation/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* Properties on pointwise extensions ***************************************)
-
-lemma lpx_sn_llpx_sn: ∀R. (∀I,L. reflexive … (R I L)) →
-                      ∀T,L1,L2,d. lpx_sn R L1 L2 → llpx_sn R d T L1 L2.
-#R #HR #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * *
-[ -HR -IH /4 width=2 by lpx_sn_fwd_length, llpx_sn_sort/
-| -HR #i elim (lt_or_ge i (|L1|))
-  [2: -IH /4 width=4 by lpx_sn_fwd_length, llpx_sn_free, le_repl_sn_conf_aux/ ]
-  #Hi #Hn #L2 #d elim (ylt_split i d) 
-  [ -n /3 width=2 by llpx_sn_skip, lpx_sn_fwd_length/ ]
-  #Hdi #HL12 elim (ldrop_O1_lt L1 i) //
-  #I #K1 #V1 #HLK1 elim (lpx_sn_ldrop_conf … HL12 … HLK1) -HL12
-  /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
-| -HR -IH /4 width=2 by lpx_sn_fwd_length, llpx_sn_gref/
-| /4 width=1 by llpx_sn_bind, lpx_sn_pair/
-| -HR /3 width=1 by llpx_sn_flat/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_tc.ma b/matita/matita/contribs/lambdadelta/basic_2/relocation/llpx_sn_tc.ma
deleted file mode 100644 (file)
index 866f8fd..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||M||                                                             *)
-(*      ||A||       A project by Andrea Asperti                           *)
-(*      ||T||                                                             *)
-(*      ||I||       Developers:                                           *)
-(*      ||T||         The HELM team.                                      *)
-(*      ||A||         http://helm.cs.unibo.it                             *)
-(*      \   /                                                             *)
-(*       \ /        This file is distributed under the terms of the       *)
-(*        v         GNU General Public License Version 2                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-include "basic_2/relocation/llpx_sn_ldrop.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* Properties about transitive closure **************************************)
-
-lemma llpx_sn_TC_pair_dx: ∀R. (∀I,L. reflexive … (R I L)) →
-                          ∀I,L,V1,V2,T. LTC … (R I) L V1 V2 →
-                          LTC … (llpx_sn R 0) T (L.ⓑ{I}V1) (L.ⓑ{I}V2).
-#R #HR #I #L #V1 #V2 #T #H @(TC_star_ind … V2 H) -V2
-/4 width=9 by llpx_sn_bind_repl_O, llpx_sn_refl, step, inj/
-qed.
index 1edda42ad8aa58369c58eb532c13654e2005e057..7650113a1a9c9ab3e45bd5da9ea8f9459e594f23 100644 (file)
@@ -20,7 +20,7 @@ include "basic_2/static/aaa.ma".
 (* Properties on lazy equivalence for local environments ********************)
 
 lemma lleq_aaa_trans: ∀G,L2,T,A. ⦃G, L2⦄ ⊢ T ⁝ A →
-                      â\88\80L1. L1 â\8b\95[T, 0] L2 → ⦃G, L1⦄ ⊢ T ⁝ A.
+                      â\88\80L1. L1 â\89¡[T, 0] L2 → ⦃G, L1⦄ ⊢ T ⁝ A.
 #G #L2 #T #A #H elim H -G -L2 -T -A /2 width=1 by aaa_sort/
 [ #I #G #L2 #K2 #V2 #A #i #HLK2 #_ #IHV2 #L1 #H elim (lleq_fwd_lref_dx … H … HLK2) -L2
   [ #H elim (ylt_yle_false … H) //
@@ -38,5 +38,5 @@ lemma lleq_aaa_trans: ∀G,L2,T,A. ⦃G, L2⦄ ⊢ T ⁝ A →
 qed-.
 
 lemma aaa_lleq_conf: ∀G,L2,T,A. ⦃G, L2⦄ ⊢ T ⁝ A →
-                     â\88\80L1. L2 â\8b\95[T, 0] L1 → ⦃G, L1⦄ ⊢ T ⁝ A.
+                     â\88\80L1. L2 â\89¡[T, 0] L1 → ⦃G, L1⦄ ⊢ T ⁝ A.
 /3 width=3 by lleq_aaa_trans, lleq_sym/ qed-.
index 8d2ed4dc4a0ec9bb8b4001bd0ae745d817a0f2c5..3b1db6a9a45aaff08cd0e55a5de4a0a47817d766 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_ldrop.ma".
+include "basic_2/substitution/llpx_sn_ldrop.ma".
 include "basic_2/static/ssta.ma".
 
 (* STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ******************************)
index daab997690fa8d805597605bebc6d23b07603a56..0b311d0d25f2d5d4c013df1ab0907632b0bcf167 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/notation/relations/cofreestar_3.ma".
+include "basic_2/notation/relations/cofreestar_4.ma".
+include "basic_2/relocation/lift_neg.ma".
 include "basic_2/substitution/cpys.ma".
 
 (* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
 
-definition cofrees: relation3 nat lenv term ≝
-                    λd,L,U1. ∀U2. ⦃⋆, L⦄ ⊢ U1 ▶*[d, ∞] U2 → ∃T2. ⇧[d, 1] T2 ≡ U2.
+definition cofrees: relation4 ynat nat lenv term ≝
+                    λd,i,L,U1. ∀U2. ⦃⋆, L⦄ ⊢ U1 ▶*[d, ∞] U2 → ∃T2. ⇧[i, 1] T2 ≡ U2.
 
 interpretation
    "context-sensitive exclusion from free variables (term)"
-   'CoFreeStar d L T = (cofrees d L T).
+   'CoFreeStar L i d T = (cofrees d i L T).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma cofrees_inv_gen: ∀L,U,U0,d,i. ⦃⋆, L⦄ ⊢ U ▶*[d, ∞] U0 → (∀T. ⇧[i, 1] T ≡ U0 → ⊥) →
+                       L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥.
+#L #U #U0 #d #i #HU0 #HnU0 #HU elim (HU … HU0) -L -U -d /2 width=2 by/
+qed-.
+
+lemma cofrees_inv_lref_eq: ∀L,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃#i⦄ → ⊥.
+#L #d #i #H elim (H (#i)) -H //
+#X #H elim (lift_inv_lref2_be … H) -H //
+qed-. 
 
 (* Basic forward lemmas *****************************************************)
 
-lemma cofrees_fwd_lift: ∀L,U,d. d ~ϵ 𝐅*⦃L, U⦄ → ∃T. ⇧[d, 1] T ≡ U.
+lemma cofrees_fwd_lift: ∀L,U,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ∃T. ⇧[i, 1] T ≡ U.
 /2 width=1 by/ qed-.
 
-lemma nlift_frees: ∀L,U,d. (∀T. ⇧[d, 1] T ≡ U → ⊥) → (d ~ϵ 𝐅*⦃L, U⦄ → ⊥).
-#L #U #d #HnTU #H elim (cofrees_fwd_lift … H) -H /2 width=2 by/
+lemma cofrees_fwd_nlift: ∀L,U,d,i. (∀T. ⇧[i, 1] T ≡ U → ⊥) → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥).
+#L #U #d #i #HnTU #H elim (cofrees_fwd_lift … H) -H /2 width=2 by/
+qed-.
+
+(* Basic Properties *********************************************************)
+
+lemma cofrees_sort: ∀L,d,i,k. L ⊢ i ~ϵ 𝐅*[d]⦃⋆k⦄.
+#L #d #i #k #X #H >(cpys_inv_sort1 … H) -X /2 width=2 by ex_intro/
+qed.
+
+lemma cofrees_gref: ∀L,d,i,p. L ⊢ i ~ϵ 𝐅*[d]⦃§p⦄.
+#L #d #i #p #X #H >(cpys_inv_gref1 … H) -X /2 width=2 by ex_intro/
+qed.
+
+lemma cofrees_bind: ∀L,V,d,i. L ⊢ i ~ϵ 𝐅*[d] ⦃V⦄ →
+                    ∀I,T. L.ⓑ{I}V ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃T⦄ →
+                    ∀a. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}V.T⦄.
+#L #W1 #d #i #HW1 #I #U1 #HU1 #a #X #H elim (cpys_inv_bind1 … H) -H
+#W2 #U2 #HW12 #HU12 #H destruct
+elim (HW1 … HW12) elim (HU1 … HU12) -W1 -U1 /3 width=2 by lift_bind, ex_intro/
+qed.
+
+lemma cofrees_flat: ∀L,V,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃V⦄ → ∀T. L ⊢ i ~ϵ 𝐅*[d]⦃T⦄ →
+                    ∀I. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}V.T⦄.
+#L #W1 #d #i #HW1 #U1 #HU1 #I #X #H elim (cpys_inv_flat1 … H) -H
+#W2 #U2 #HW12 #HU12 #H destruct
+elim (HW1 … HW12) elim (HU1 … HU12) -W1 -U1 /3 width=2 by lift_flat, ex_intro/
+qed.
+
+axiom cofrees_dec: ∀L,T,d,i. Decidable (L ⊢ i ~ϵ 𝐅*[d]⦃T⦄).
+
+(* Negated inversion lemmas *************************************************)
+
+lemma frees_inv_bind: ∀a,I,L,V,T,d,i. (L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}V.T⦄ → ⊥) →
+                      (L ⊢ i ~ϵ 𝐅*[d]⦃V⦄ → ⊥) ∨ (L.ⓑ{I}V ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃T⦄ → ⊥).
+#a #I #L #W #U #d #i #H elim (cofrees_dec L W d i)
+/4 width=9 by cofrees_bind, or_intror, or_introl/
+qed-.
+
+lemma frees_inv_flat: ∀I,L,V,T,d,i. (L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}V.T⦄ → ⊥) →
+                      (L ⊢ i ~ϵ 𝐅*[d]⦃V⦄ → ⊥) ∨ (L ⊢ i ~ϵ 𝐅*[d]⦃T⦄ → ⊥).
+#I #L #W #U #d #H elim (cofrees_dec L W d)
+/4 width=8 by cofrees_flat, or_intror, or_introl/
 qed-.
index b6d9e45a1080b515395b3ddbe3bfacdb96ecc65e..f4803a17ddf8ec84cc052665f744055f62a6c085 100644 (file)
@@ -77,6 +77,14 @@ lemma cpys_inv_lref1: ∀G,L,T2,i,d,e. ⦃G, L⦄ ⊢ #i ▶*[d, e] T2 →
 * #I #K #V1 #V2 #j #Hdj #Hjde #HLK #HV12 #HVT2 #H destruct /3 width=7 by ex5_4_intro, or_intror/
 qed-.
 
+lemma cpys_inv_lref1_Y2: ∀G,L,T2,i,d. ⦃G, L⦄ ⊢ #i ▶*[d, ∞] T2 →
+                         T2 = #i ∨
+                         ∃∃I,K,V1,V2. d ≤ i & ⇩[i] L ≡ K.ⓑ{I}V1 &
+                                      ⦃G, K⦄ ⊢ V1 ▶*[0, ∞] V2 & ⇧[O, i+1] V2 ≡ T2.
+#G #L #T2 #i #d #H elim (cpys_inv_lref1 … H) -H /2 width=1 by or_introl/
+* >yminus_Y_inj /3 width=7 by or_intror, ex4_4_intro/
+qed-.
+
 lemma cpys_inv_lref1_ldrop: ∀G,L,T2,i,d,e. ⦃G, L⦄ ⊢ #i ▶*[d, e] T2 →
                             ∀I,K,V1. ⇩[i] L ≡ K.ⓑ{I}V1 →
                             ∀V2. ⇧[O, i+1] V2 ≡ T2 →
index bb55c859fb7aa3239d8d2f3123c9ef1aca4bc5d1..3c90f5a9ffc91869a5776ce9a7bfa72a8b9ebf95 100644 (file)
@@ -19,7 +19,7 @@ include "basic_2/substitution/lleq.ma".
 (* LAZY EQUIVALENCE FOR CLOSURES ********************************************)
 
 inductive fleq (d) (G) (L1) (T): relation3 genv lenv term ≝
-| fleq_intro: â\88\80L2. L1 â\8b\95[T, d] L2 → fleq d G L1 T G L2 T
+| fleq_intro: â\88\80L2. L1 â\89¡[T, d] L2 → fleq d G L1 T G L2 T
 .
 
 interpretation
@@ -37,7 +37,7 @@ qed-.
 
 (* Basic inversion lemmas ***************************************************)
 
-lemma fleq_inv_gen: â\88\80G1,G2,L1,L2,T1,T2,d. â¦\83G1, L1, T1â¦\84 â\8b\95[d] ⦃G2, L2, T2⦄ →
-                    â\88§â\88§ G1 = G2 & L1 â\8b\95[T1, d] L2 & T1 = T2.
+lemma fleq_inv_gen: â\88\80G1,G2,L1,L2,T1,T2,d. â¦\83G1, L1, T1â¦\84 â\89¡[d] ⦃G2, L2, T2⦄ →
+                    â\88§â\88§ G1 = G2 & L1 â\89¡[T1, d] L2 & T1 = T2.
 #G1 #G2 #L1 #L2 #T1 #T2 #d * -G2 -L2 -T2 /2 width=1 by and3_intro/
 qed-.
index 36885f0e15c8ced48404e0fed64fee78e8bc3e8b..e8d5dac02024eb93c6efa890f913e9d2ec47281f 100644 (file)
@@ -26,9 +26,9 @@ theorem fleq_trans: ∀d. tri_transitive … (fleq d).
 qed-.
 
 theorem fleq_canc_sn: ∀G,G1,G2,L,L1,L2,T,T1,T2,d.
-                      â¦\83G, L, Tâ¦\84 â\8b\95[d] â¦\83G1, L1, T1â¦\84â\86\92 â¦\83G, L, Tâ¦\84 â\8b\95[d] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\8b\95[d] ⦃G2, L2, T2⦄.
+                      â¦\83G, L, Tâ¦\84 â\89¡[d] â¦\83G1, L1, T1â¦\84â\86\92 â¦\83G, L, Tâ¦\84 â\89¡[d] â¦\83G2, L2, T2â¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89¡[d] ⦃G2, L2, T2⦄.
 /3 width=5 by fleq_trans, fleq_sym/ qed-.
 
 theorem fleq_canc_dx: ∀G1,G2,G,L1,L2,L,T1,T2,T,d.
-                      â¦\83G1, L1, T1â¦\84 â\8b\95[d] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G2, L2, T2â¦\84 â\8b\95[d] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\8b\95[d] ⦃G2, L2, T2⦄.
+                      â¦\83G1, L1, T1â¦\84 â\89¡[d] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G2, L2, T2â¦\84 â\89¡[d] â¦\83G, L, Tâ¦\84 â\86\92 â¦\83G1, L1, T1â¦\84 â\89¡[d] ⦃G2, L2, T2⦄.
 /3 width=5 by fleq_trans, fleq_sym/ qed-.
index d8a174b825d23a44f9b642ed2d7ba1689bee29bf..dc138a492c89e1a3c6b4a9efabc3f4ad100a16c0 100644 (file)
@@ -13,7 +13,7 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/lazyeq_4.ma".
-include "basic_2/relocation/llpx_sn.ma".
+include "basic_2/substitution/llpx_sn.ma".
 
 (* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
 
@@ -26,7 +26,7 @@ interpretation
    'LazyEq T d L1 L2 = (lleq d T L1 L2).
 
 definition lleq_transitive: predicate (relation4 bind2 lenv term term) ≝
-           Î»R. â\88\80I,L2,T1,T2. R I L2 T1 T2 â\86\92 â\88\80L1. L1 â\8b\95[T1, 0] L2 → R I L1 T1 T2.
+           Î»R. â\88\80I,L2,T1,T2. R I L2 T1 T2 â\86\92 â\88\80L1. L1 â\89¡[T1, 0] L2 → R I L1 T1 T2.
 
 (* Basic inversion lemmas ***************************************************)
 
@@ -37,103 +37,103 @@ lemma lleq_ind: ∀R:relation4 ynat term lenv lenv. (
                 ) → (
                    ∀I,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
                    ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}V →
-                   K1 â\8b\95[V, yinj O] K2 → R (yinj O) V K1 K2 → R d (#i) L1 L2
+                   K1 â\89¡[V, yinj O] K2 → R (yinj O) V K1 K2 → R d (#i) L1 L2
                 ) → (
                    ∀L1,L2,d,i. |L1| = |L2| → |L1| ≤ i → |L2| ≤ i → R d (#i) L1 L2
                 ) → (
                    ∀L1,L2,d,p. |L1| = |L2| → R d (§p) L1 L2
                 ) → (
                    ∀a,I,L1,L2,V,T,d.
-                   L1 â\8b\95[V, d]L2 â\86\92 L1.â\93\91{I}V â\8b\95[T, ⫯d] L2.ⓑ{I}V →
+                   L1 â\89¡[V, d]L2 â\86\92 L1.â\93\91{I}V â\89¡[T, ⫯d] L2.ⓑ{I}V →
                    R d V L1 L2 → R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → R d (ⓑ{a,I}V.T) L1 L2
                 ) → (
                    ∀I,L1,L2,V,T,d.
-                   L1 â\8b\95[V, d]L2 â\86\92 L1 â\8b\95[T, d] L2 →
+                   L1 â\89¡[V, d]L2 â\86\92 L1 â\89¡[T, d] L2 →
                    R d V L1 L2 → R d T L1 L2 → R d (ⓕ{I}V.T) L1 L2
                 ) →
-                â\88\80d,T,L1,L2. L1 â\8b\95[T, d] L2 → R d T L1 L2.
+                â\88\80d,T,L1,L2. L1 â\89¡[T, d] L2 → R d T L1 L2.
 #R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #d #T #L1 #L2 #H elim H -L1 -L2 -T -d /2 width=8 by/
 qed-.
 
-lemma lleq_inv_bind: â\88\80a,I,L1,L2,V,T,d. L1 â\8b\95[ⓑ{a,I}V.T, d] L2 →
-                     L1 â\8b\95[V, d] L2 â\88§ L1.â\93\91{I}V â\8b\95[T, ⫯d] L2.ⓑ{I}V.
+lemma lleq_inv_bind: â\88\80a,I,L1,L2,V,T,d. L1 â\89¡[ⓑ{a,I}V.T, d] L2 →
+                     L1 â\89¡[V, d] L2 â\88§ L1.â\93\91{I}V â\89¡[T, ⫯d] L2.ⓑ{I}V.
 /2 width=2 by llpx_sn_inv_bind/ qed-.
 
-lemma lleq_inv_flat: â\88\80I,L1,L2,V,T,d. L1 â\8b\95[ⓕ{I}V.T, d] L2 →
-                     L1 â\8b\95[V, d] L2 â\88§ L1 â\8b\95[T, d] L2.
+lemma lleq_inv_flat: â\88\80I,L1,L2,V,T,d. L1 â\89¡[ⓕ{I}V.T, d] L2 →
+                     L1 â\89¡[V, d] L2 â\88§ L1 â\89¡[T, d] L2.
 /2 width=2 by llpx_sn_inv_flat/ qed-.
 
 (* Basic forward lemmas *****************************************************)
 
-lemma lleq_fwd_length: â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 → |L1| = |L2|.
+lemma lleq_fwd_length: â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 → |L1| = |L2|.
 /2 width=4 by llpx_sn_fwd_length/ qed-.
 
-lemma lleq_fwd_lref: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 →
+lemma lleq_fwd_lref: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 →
                      ∨∨ |L1| ≤ i ∧ |L2| ≤ i
                       | yinj i < d
                       | ∃∃I,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I}V &
                                      ⇩[i] L2 ≡ K2.ⓑ{I}V &
-                                      K1 â\8b\95[V, yinj 0] K2 & d ≤ yinj i.
+                                      K1 â\89¡[V, yinj 0] K2 & d ≤ yinj i.
 #L1 #L2 #d #i #H elim (llpx_sn_fwd_lref … H) /2 width=1/
 * /3 width=7 by or3_intro2, ex4_4_intro/
 qed-.
 
-lemma lleq_fwd_ldrop_sn: â\88\80L1,L2,T,d. L1 â\8b\95[d, T] L2 → ∀K1,i. ⇩[i] L1 ≡ K1 →
+lemma lleq_fwd_ldrop_sn: â\88\80L1,L2,T,d. L1 â\89¡[d, T] L2 → ∀K1,i. ⇩[i] L1 ≡ K1 →
                          ∃K2. ⇩[i] L2 ≡ K2.
 /2 width=7 by llpx_sn_fwd_ldrop_sn/ qed-.
 
-lemma lleq_fwd_ldrop_dx: â\88\80L1,L2,T,d. L1 â\8b\95[d, T] L2 → ∀K2,i. ⇩[i] L2 ≡ K2 →
+lemma lleq_fwd_ldrop_dx: â\88\80L1,L2,T,d. L1 â\89¡[d, T] L2 → ∀K2,i. ⇩[i] L2 ≡ K2 →
                          ∃K1. ⇩[i] L1 ≡ K1.
 /2 width=7 by llpx_sn_fwd_ldrop_dx/ qed-.
 
 lemma lleq_fwd_bind_sn: ∀a,I,L1,L2,V,T,d.
-                        L1 â\8b\95\93\91{a,I}V.T, d] L2 â\86\92 L1 â\8b\95[V, d] L2.
+                        L1 â\89¡[â\93\91{a,I}V.T, d] L2 â\86\92 L1 â\89¡[V, d] L2.
 /2 width=4 by llpx_sn_fwd_bind_sn/ qed-.
 
 lemma lleq_fwd_bind_dx: ∀a,I,L1,L2,V,T,d.
-                        L1 â\8b\95\93\91{a,I}V.T, d] L2 â\86\92 L1.â\93\91{I}V â\8b\95[T, ⫯d] L2.ⓑ{I}V.
+                        L1 â\89¡[â\93\91{a,I}V.T, d] L2 â\86\92 L1.â\93\91{I}V â\89¡[T, ⫯d] L2.ⓑ{I}V.
 /2 width=2 by llpx_sn_fwd_bind_dx/ qed-.
 
 lemma lleq_fwd_flat_sn: ∀I,L1,L2,V,T,d.
-                        L1 â\8b\95\93\95{I}V.T, d] L2 â\86\92 L1 â\8b\95[V, d] L2.
+                        L1 â\89¡[â\93\95{I}V.T, d] L2 â\86\92 L1 â\89¡[V, d] L2.
 /2 width=3 by llpx_sn_fwd_flat_sn/ qed-.
 
 lemma lleq_fwd_flat_dx: ∀I,L1,L2,V,T,d.
-                        L1 â\8b\95\93\95{I}V.T, d] L2 â\86\92 L1 â\8b\95[T, d] L2.
+                        L1 â\89¡[â\93\95{I}V.T, d] L2 â\86\92 L1 â\89¡[T, d] L2.
 /2 width=3 by llpx_sn_fwd_flat_dx/ qed-.
 
 (* Basic properties *********************************************************)
 
-lemma lleq_sort: â\88\80L1,L2,d,k. |L1| = |L2| â\86\92 L1 â\8b\95[⋆k, d] L2.
+lemma lleq_sort: â\88\80L1,L2,d,k. |L1| = |L2| â\86\92 L1 â\89¡[⋆k, d] L2.
 /2 width=1 by llpx_sn_sort/ qed.
 
-lemma lleq_skip: â\88\80L1,L2,d,i. yinj i < d â\86\92 |L1| = |L2| â\86\92 L1 â\8b\95[#i, d] L2.
+lemma lleq_skip: â\88\80L1,L2,d,i. yinj i < d â\86\92 |L1| = |L2| â\86\92 L1 â\89¡[#i, d] L2.
 /2 width=1 by llpx_sn_skip/ qed.
 
 lemma lleq_lref: ∀I,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
                  ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}V →
-                 K1 â\8b\95[V, 0] K2 â\86\92 L1 â\8b\95[#i, d] L2.
+                 K1 â\89¡[V, 0] K2 â\86\92 L1 â\89¡[#i, d] L2.
 /2 width=9 by llpx_sn_lref/ qed.
 
-lemma lleq_free: â\88\80L1,L2,d,i. |L1| â\89¤ i â\86\92 |L2| â\89¤ i â\86\92 |L1| = |L2| â\86\92 L1 â\8b\95[#i, d] L2.
+lemma lleq_free: â\88\80L1,L2,d,i. |L1| â\89¤ i â\86\92 |L2| â\89¤ i â\86\92 |L1| = |L2| â\86\92 L1 â\89¡[#i, d] L2.
 /2 width=1 by llpx_sn_free/ qed.
 
-lemma lleq_gref: â\88\80L1,L2,d,p. |L1| = |L2| â\86\92 L1 â\8b\95[§p, d] L2.
+lemma lleq_gref: â\88\80L1,L2,d,p. |L1| = |L2| â\86\92 L1 â\89¡[§p, d] L2.
 /2 width=1 by llpx_sn_gref/ qed.
 
 lemma lleq_bind: ∀a,I,L1,L2,V,T,d.
-                 L1 â\8b\95[V, d] L2 â\86\92 L1.â\93\91{I}V â\8b\95[T, ⫯d] L2.ⓑ{I}V →
-                 L1 â\8b\95[ⓑ{a,I}V.T, d] L2.
+                 L1 â\89¡[V, d] L2 â\86\92 L1.â\93\91{I}V â\89¡[T, ⫯d] L2.ⓑ{I}V →
+                 L1 â\89¡[ⓑ{a,I}V.T, d] L2.
 /2 width=1 by llpx_sn_bind/ qed.
 
 lemma lleq_flat: ∀I,L1,L2,V,T,d.
-                 L1 â\8b\95[V, d] L2 â\86\92 L1 â\8b\95[T, d] L2 â\86\92 L1 â\8b\95[ⓕ{I}V.T, d] L2.
+                 L1 â\89¡[V, d] L2 â\86\92 L1 â\89¡[T, d] L2 â\86\92 L1 â\89¡[ⓕ{I}V.T, d] L2.
 /2 width=1 by llpx_sn_flat/ qed.
 
 lemma lleq_refl: ∀d,T. reflexive … (lleq d T).
 /2 width=1 by llpx_sn_refl/ qed.
 
-lemma lleq_Y: â\88\80L1,L2,T. |L1| = |L2| â\86\92 L1 â\8b\95[T, ∞] L2.
+lemma lleq_Y: â\88\80L1,L2,T. |L1| = |L2| â\86\92 L1 â\89¡[T, ∞] L2.
 /2 width=1 by llpx_sn_Y/ qed.
 
 lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
@@ -141,20 +141,20 @@ lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
 /2 width=7 by lleq_sort, lleq_skip, lleq_lref, lleq_free, lleq_gref, lleq_bind, lleq_flat/
 qed-.
 
-lemma lleq_ge_up: â\88\80L1,L2,U,dt. L1 â\8b\95[U, dt] L2 →
+lemma lleq_ge_up: â\88\80L1,L2,U,dt. L1 â\89¡[U, dt] L2 →
                   ∀T,d,e. ⇧[d, e] T ≡ U →
-                  dt â\89¤ d + e â\86\92 L1 â\8b\95[U, d] L2.
+                  dt â\89¤ d + e â\86\92 L1 â\89¡[U, d] L2.
 /2 width=6 by llpx_sn_ge_up/ qed-.
 
-lemma lleq_ge: â\88\80L1,L2,T,d1. L1 â\8b\95[T, d1] L2 â\86\92 â\88\80d2. d1 â\89¤ d2 â\86\92 L1 â\8b\95[T, d2] L2.
+lemma lleq_ge: â\88\80L1,L2,T,d1. L1 â\89¡[T, d1] L2 â\86\92 â\88\80d2. d1 â\89¤ d2 â\86\92 L1 â\89¡[T, d2] L2.
 /2 width=3 by llpx_sn_ge/ qed-.
 
-lemma lleq_bind_O: â\88\80a,I,L1,L2,V,T. L1 â\8b\95[V, 0] L2 â\86\92 L1.â\93\91{I}V â\8b\95[T, 0] L2.ⓑ{I}V →
-                   L1 â\8b\95[ⓑ{a,I}V.T, 0] L2.
+lemma lleq_bind_O: â\88\80a,I,L1,L2,V,T. L1 â\89¡[V, 0] L2 â\86\92 L1.â\93\91{I}V â\89¡[T, 0] L2.ⓑ{I}V →
+                   L1 â\89¡[ⓑ{a,I}V.T, 0] L2.
 /2 width=1 by llpx_sn_bind_O/ qed-.
 
 (* Advancded properties on lazy pointwise exyensions ************************)
 
 lemma llpx_sn_lrefl: ∀R. (∀I,L. reflexive … (R I L)) →
-                     â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 → llpx_sn R d T L1 L2.
+                     â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 → llpx_sn R d T L1 L2.
 /2 width=3 by llpx_sn_co/ qed-.
index dd97ea6416db712c9192a0c0f8e19c465b905652..a209206afbfd772879bb8f01c9fbe57c8c5f5d34 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_alt.ma".
+include "basic_2/substitution/llpx_sn_alt1.ma".
 include "basic_2/substitution/lleq.ma".
 
 (* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
@@ -22,9 +22,9 @@ include "basic_2/substitution/lleq.ma".
 theorem lleq_intro_alt: ∀L1,L2,T,d. |L1| = |L2| →
                         (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\8b\95[V1, 0] K2
-                        ) â\86\92 L1 â\8b\95[T, d] L2.
-#L1 #L2 #T #d #HL12 #IH @llpx_sn_intro_alt // -HL12
+                           â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\89¡[V1, 0] K2
+                        ) â\86\92 L1 â\89¡[T, d] L2.
+#L1 #L2 #T #d #HL12 #IH @llpx_sn_intro_alt1 // -HL12
 #I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
 elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by and3_intro/
 qed.
@@ -33,21 +33,21 @@ theorem lleq_ind_alt: ∀S:relation4 ynat term lenv lenv.
                       (∀L1,L2,T,d. |L1| = |L2| → (
                          ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
                          ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                         â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\8b\95[V1, 0] K2 & S 0 V1 K1 K2
+                         â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\89¡[V1, 0] K2 & S 0 V1 K1 K2
                       ) → S d T L1 L2) →
-                      â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 → S d T L1 L2.
-#S #IH1 #L1 #L2 #T #d #H @(llpx_sn_ind_alt … H) -L1 -L2 -T -d
+                      â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 → S d T L1 L2.
+#S #IH1 #L1 #L2 #T #d #H @(llpx_sn_ind_alt1 … H) -L1 -L2 -T -d
 #L1 #L2 #T #d #HL12 #IH2 @IH1 -IH1 // -HL12
 #I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
 elim (IH2 … HnT HLK1 HLK2) -IH2 -HnT -HLK1 -HLK2 /2 width=1 by and4_intro/
 qed-.
 
-theorem lleq_inv_alt: â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 →
+theorem lleq_inv_alt: â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 →
                       |L1| = |L2| ∧
                       ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
                       ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                      â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\8b\95[V1, 0] K2.
-#L1 #L2 #T #d #H elim (llpx_sn_inv_alt … H) -H
+                      â\88§â\88§ I1 = I2 & V1 = V2 & K1 â\89¡[V1, 0] K2.
+#L1 #L2 #T #d #H elim (llpx_sn_inv_alt1 … H) -H
 #HL12 #IH @conj //
 #I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
 elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by and3_intro/
index 3a510eb28c9445822d375bcee3479f4355db4b51..ac1329b4530767e88b9a6363e0bf40f095eff7b3 100644 (file)
@@ -20,8 +20,8 @@ include "basic_2/substitution/lleq_ldrop.ma".
 (* Properties on supclosure *************************************************)
 
 lemma lleq_fqu_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐ ⦃G2, K2, U⦄ →
-                      â\88\80L1. L1 â\8b\95[T, 0] L2 →
-                      â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90 â¦\83G2, K1, Uâ¦\84 & K1 â\8b\95[U, 0] K2.
+                      â\88\80L1. L1 â\89¡[T, 0] L2 →
+                      â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90 â¦\83G2, K1, Uâ¦\84 & K1 â\89¡[U, 0] K2.
 #G1 #G2 #L2 #K2 #T #U #H elim H -G1 -G2 -L2 -K2 -T -U
 [ #I #G #L2 #V #L1 #H elim (lleq_inv_lref_ge_dx … H … I L2 V) -H //
   #K1 #H1 #H2 lapply (ldrop_inv_O2 … H1) -H1
@@ -45,8 +45,8 @@ lemma lleq_fqu_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐ ⦃G2, K2, U⦄ 
 qed-.
 
 lemma lleq_fquq_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐⸮ ⦃G2, K2, U⦄ →
-                       â\88\80L1. L1 â\8b\95[T, 0] L2 →
-                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90⸮ â¦\83G2, K1, Uâ¦\84 & K1 â\8b\95[U, 0] K2.
+                       â\88\80L1. L1 â\89¡[T, 0] L2 →
+                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90⸮ â¦\83G2, K1, Uâ¦\84 & K1 â\89¡[U, 0] K2.
 #G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fquq_inv_gen … H) -H
 [ #H elim (lleq_fqu_trans … H … HL12) -L2 /3 width=3 by fqu_fquq, ex2_intro/
 | * #HG #HL #HT destruct /2 width=3 by ex2_intro/
@@ -54,8 +54,8 @@ lemma lleq_fquq_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐⸮ ⦃G2, K2, U
 qed-.
 
 lemma lleq_fqup_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐+ ⦃G2, K2, U⦄ →
-                       â\88\80L1. L1 â\8b\95[T, 0] L2 →
-                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90+ â¦\83G2, K1, Uâ¦\84 & K1 â\8b\95[U, 0] K2.
+                       â\88\80L1. L1 â\89¡[T, 0] L2 →
+                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90+ â¦\83G2, K1, Uâ¦\84 & K1 â\89¡[U, 0] K2.
 #G1 #G2 #L2 #K2 #T #U #H @(fqup_ind … H) -G2 -K2 -U
 [ #G2 #K2 #U #HTU #L1 #HL12 elim (lleq_fqu_trans … HTU … HL12) -L2
   /3 width=3 by fqu_fqup, ex2_intro/
@@ -66,8 +66,8 @@ lemma lleq_fqup_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐+ ⦃G2, K2, U⦄
 qed-.
 
 lemma lleq_fqus_trans: ∀G1,G2,L2,K2,T,U. ⦃G1, L2, T⦄ ⊐* ⦃G2, K2, U⦄ →
-                       â\88\80L1. L1 â\8b\95[T, 0] L2 →
-                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90* â¦\83G2, K1, Uâ¦\84 & K1 â\8b\95[U, 0] K2.
+                       â\88\80L1. L1 â\89¡[T, 0] L2 →
+                       â\88\83â\88\83K1. â¦\83G1, L1, Tâ¦\84 â\8a\90* â¦\83G2, K1, Uâ¦\84 & K1 â\89¡[U, 0] K2.
 #G1 #G2 #L2 #K2 #T #U #H #L1 #HL12 elim(fqus_inv_gen … H) -H
 [ #H elim (lleq_fqup_trans … H … HL12) -L2 /3 width=3 by fqup_fqus, ex2_intro/
 | * #HG #HL #HT destruct /2 width=3 by ex2_intro/
index 27b16110deb53543994b092d2b98052416f5c0fc..cc527074c71c45b99b6ac91cbfc3aebc85f4ffd0 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_ldrop.ma".
+include "basic_2/substitution/llpx_sn_ldrop.ma".
 include "basic_2/substitution/lleq.ma".
 
 (* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
 
 (* Advanced properties ******************************************************)
 
-lemma lleq_bind_repl_O: â\88\80I,L1,L2,V,T. L1.â\93\91{I}V â\8b\95[T, 0] L2.ⓑ{I}V →
-                        â\88\80J,W. L1 â\8b\95[W, 0] L2 â\86\92 L1.â\93\91{J}W â\8b\95[T, 0] L2.ⓑ{J}W.
+lemma lleq_bind_repl_O: â\88\80I,L1,L2,V,T. L1.â\93\91{I}V â\89¡[T, 0] L2.ⓑ{I}V →
+                        â\88\80J,W. L1 â\89¡[W, 0] L2 â\86\92 L1.â\93\91{J}W â\89¡[T, 0] L2.ⓑ{J}W.
 /2 width=7 by llpx_sn_bind_repl_O/ qed-.
 
-lemma lleq_dec: â\88\80T,L1,L2,d. Decidable (L1 â\8b\95[T, d] L2).
+lemma lleq_dec: â\88\80T,L1,L2,d. Decidable (L1 â\89¡[T, d] L2).
 /3 width=1 by llpx_sn_dec, eq_term_dec/ qed-.
 
 lemma lleq_llpx_sn_trans: ∀R. lleq_transitive R →
-                          â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 →
+                          â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 →
                           ∀L. llpx_sn R d T L2 L → llpx_sn R d T L1 L.
 #R #HR #L1 #L2 #T #d #H @(lleq_ind … H) -L1 -L2 -T -d
 [1,2,5: /4 width=6 by llpx_sn_fwd_length, llpx_sn_gref, llpx_sn_skip, llpx_sn_sort, trans_eq/
@@ -42,109 +42,109 @@ lemma lleq_llpx_sn_trans: ∀R. lleq_transitive R →
 qed-.
 
 lemma lleq_llpx_sn_conf: ∀R. lleq_transitive R →
-                         â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 →
+                         â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 →
                          ∀L. llpx_sn R d T L1 L → llpx_sn R d T L2 L.
 /3 width=3 by lleq_llpx_sn_trans, lleq_sym/ qed-.
 
 (* Advanced inversion lemmas ************************************************)
 
-lemma lleq_inv_lref_ge_dx: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 → d ≤ i →
+lemma lleq_inv_lref_ge_dx: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 → d ≤ i →
                            ∀I,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I}V →
-                           â\88\83â\88\83K1. â\87©[i] L1 â\89¡ K1.â\93\91{I}V & K1 â\8b\95[V, 0] K2.
+                           â\88\83â\88\83K1. â\87©[i] L1 â\89¡ K1.â\93\91{I}V & K1 â\89¡[V, 0] K2.
 #L1 #L2 #d #i #H #Hdi #I #K2 #V #HLK2 elim (llpx_sn_inv_lref_ge_dx … H … HLK2) -L2
 /2 width=3 by ex2_intro/
 qed-.
 
-lemma lleq_inv_lref_ge_sn: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 → d ≤ i →
+lemma lleq_inv_lref_ge_sn: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 → d ≤ i →
                            ∀I,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I}V →
-                           â\88\83â\88\83K2. â\87©[i] L2 â\89¡ K2.â\93\91{I}V & K1 â\8b\95[V, 0] K2.
+                           â\88\83â\88\83K2. â\87©[i] L2 â\89¡ K2.â\93\91{I}V & K1 â\89¡[V, 0] K2.
 #L1 #L2 #d #i #H #Hdi #I1 #K1 #V #HLK1 elim (llpx_sn_inv_lref_ge_sn … H … HLK1) -L1
 /2 width=3 by ex2_intro/
 qed-.
 
-lemma lleq_inv_lref_ge_bi: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 → d ≤ i →
+lemma lleq_inv_lref_ge_bi: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 → d ≤ i →
                            ∀I1,I2,K1,K2,V1,V2.
                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           â\88§â\88§ I1 = I2 & K1 â\8b\95[V1, 0] K2 & V1 = V2.
+                           â\88§â\88§ I1 = I2 & K1 â\89¡[V1, 0] K2 & V1 = V2.
 /2 width=8 by llpx_sn_inv_lref_ge_bi/ qed-.
 
-lemma lleq_inv_lref_ge: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 → d ≤ i →
+lemma lleq_inv_lref_ge: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 → d ≤ i →
                         ∀I,K1,K2,V. ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}V →
-                        K1 â\8b\95[V, 0] K2.
+                        K1 â\89¡[V, 0] K2.
 #L1 #L2 #d #i #HL12 #Hdi #I #K1 #K2 #V #HLK1 #HLK2
 elim (lleq_inv_lref_ge_bi … HL12 … HLK1 HLK2) //
 qed-.
 
-lemma lleq_inv_S: â\88\80L1,L2,T,d. L1 â\8b\95[T, d+1] L2 →
+lemma lleq_inv_S: â\88\80L1,L2,T,d. L1 â\89¡[T, d+1] L2 →
                   ∀I,K1,K2,V. ⇩[d] L1 ≡ K1.ⓑ{I}V → ⇩[d] L2 ≡ K2.ⓑ{I}V →
-                  K1 â\8b\95[V, 0] K2 â\86\92 L1 â\8b\95[T, d] L2.
+                  K1 â\89¡[V, 0] K2 â\86\92 L1 â\89¡[T, d] L2.
 /2 width=9 by llpx_sn_inv_S/ qed-.
 
-lemma lleq_inv_bind_O: â\88\80a,I,L1,L2,V,T. L1 â\8b\95[ⓑ{a,I}V.T, 0] L2 →
-                       L1 â\8b\95[V, 0] L2 â\88§ L1.â\93\91{I}V â\8b\95[T, 0] L2.ⓑ{I}V.
+lemma lleq_inv_bind_O: â\88\80a,I,L1,L2,V,T. L1 â\89¡[ⓑ{a,I}V.T, 0] L2 →
+                       L1 â\89¡[V, 0] L2 â\88§ L1.â\93\91{I}V â\89¡[T, 0] L2.ⓑ{I}V.
 /2 width=2 by llpx_sn_inv_bind_O/ qed-.
 
 (* Advanced forward lemmas **************************************************)
 
-lemma lleq_fwd_lref_dx: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 →
+lemma lleq_fwd_lref_dx: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 →
                         ∀I,K2,V. ⇩[i] L2 ≡ K2.ⓑ{I}V →
                         i < d ∨
-                        â\88\83â\88\83K1. â\87©[i] L1 â\89¡ K1.â\93\91{I}V & K1 â\8b\95[V, 0] K2 & d ≤ i.
+                        â\88\83â\88\83K1. â\87©[i] L1 â\89¡ K1.â\93\91{I}V & K1 â\89¡[V, 0] K2 & d ≤ i.
 #L1 #L2 #d #i #H #I #K2 #V #HLK2 elim (llpx_sn_fwd_lref_dx … H … HLK2) -L2
 [ | * ] /3 width=3 by ex3_intro, or_intror, or_introl/
 qed-.
 
-lemma lleq_fwd_lref_sn: â\88\80L1,L2,d,i. L1 â\8b\95[#i, d] L2 →
+lemma lleq_fwd_lref_sn: â\88\80L1,L2,d,i. L1 â\89¡[#i, d] L2 →
                         ∀I,K1,V. ⇩[i] L1 ≡ K1.ⓑ{I}V →
                         i < d ∨
-                        â\88\83â\88\83K2. â\87©[i] L2 â\89¡ K2.â\93\91{I}V & K1 â\8b\95[V, 0] K2 & d ≤ i.
+                        â\88\83â\88\83K2. â\87©[i] L2 â\89¡ K2.â\93\91{I}V & K1 â\89¡[V, 0] K2 & d ≤ i.
 #L1 #L2 #d #i #H #I #K1 #V #HLK1 elim (llpx_sn_fwd_lref_sn … H … HLK1) -L1
 [ | * ] /3 width=3 by ex3_intro, or_intror, or_introl/
 qed-.
 
-lemma lleq_fwd_bind_O_dx: â\88\80a,I,L1,L2,V,T. L1 â\8b\95[ⓑ{a,I}V.T, 0] L2 →
-                          L1.â\93\91{I}V â\8b\95[T, 0] L2.ⓑ{I}V.
+lemma lleq_fwd_bind_O_dx: â\88\80a,I,L1,L2,V,T. L1 â\89¡[ⓑ{a,I}V.T, 0] L2 →
+                          L1.â\93\91{I}V â\89¡[T, 0] L2.ⓑ{I}V.
 /2 width=2 by llpx_sn_fwd_bind_O_dx/ qed-.
 
 (* Properties on relocation *************************************************)
 
-lemma lleq_lift_le: â\88\80K1,K2,T,dt. K1 â\8b\95[T, dt] K2 →
+lemma lleq_lift_le: â\88\80K1,K2,T,dt. K1 â\89¡[T, dt] K2 →
                     ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                    â\88\80U. â\87§[d, e] T â\89¡ U â\86\92 dt â\89¤ d â\86\92 L1 â\8b\95[U, dt] L2.
+                    â\88\80U. â\87§[d, e] T â\89¡ U â\86\92 dt â\89¤ d â\86\92 L1 â\89¡[U, dt] L2.
 /3 width=10 by llpx_sn_lift_le, lift_mono/ qed-.
 
-lemma lleq_lift_ge: â\88\80K1,K2,T,dt. K1 â\8b\95[T, dt] K2 →
+lemma lleq_lift_ge: â\88\80K1,K2,T,dt. K1 â\89¡[T, dt] K2 →
                     ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                    â\88\80U. â\87§[d, e] T â\89¡ U â\86\92 d â\89¤ dt â\86\92 L1 â\8b\95[U, dt+e] L2.
+                    â\88\80U. â\87§[d, e] T â\89¡ U â\86\92 d â\89¤ dt â\86\92 L1 â\89¡[U, dt+e] L2.
 /2 width=9 by llpx_sn_lift_ge/ qed-.
 
 (* Inversion lemmas on relocation *******************************************)
 
-lemma lleq_inv_lift_le: â\88\80L1,L2,U,dt. L1 â\8b\95[U, dt] L2 →
+lemma lleq_inv_lift_le: â\88\80L1,L2,U,dt. L1 â\89¡[U, dt] L2 →
                         ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 dt â\89¤ d â\86\92 K1 â\8b\95[T, dt] K2.
+                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 dt â\89¤ d â\86\92 K1 â\89¡[T, dt] K2.
 /3 width=10 by llpx_sn_inv_lift_le, ex2_intro/ qed-.
 
-lemma lleq_inv_lift_be: â\88\80L1,L2,U,dt. L1 â\8b\95[U, dt] L2 →
+lemma lleq_inv_lift_be: â\88\80L1,L2,U,dt. L1 â\89¡[U, dt] L2 →
                         ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 d â\89¤ dt â\86\92 dt â\89¤ yinj d + e â\86\92 K1 â\8b\95[T, d] K2.
+                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 d â\89¤ dt â\86\92 dt â\89¤ yinj d + e â\86\92 K1 â\89¡[T, d] K2.
 /2 width=11 by llpx_sn_inv_lift_be/ qed-.
 
-lemma lleq_inv_lift_ge: â\88\80L1,L2,U,dt. L1 â\8b\95[U, dt] L2 →
+lemma lleq_inv_lift_ge: â\88\80L1,L2,U,dt. L1 â\89¡[U, dt] L2 →
                         ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
-                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 yinj d + e â\89¤ dt â\86\92 K1 â\8b\95[T, dt-e] K2.
+                        â\88\80T. â\87§[d, e] T â\89¡ U â\86\92 yinj d + e â\89¤ dt â\86\92 K1 â\89¡[T, dt-e] K2.
 /2 width=9 by llpx_sn_inv_lift_ge/ qed-.
 
 (* Inversion lemmas on negated lazy quivalence for local environments *******)
 
-lemma nlleq_inv_bind: â\88\80a,I,L1,L2,V,T,d. (L1 â\8b\95[ⓑ{a,I}V.T, d] L2 → ⊥) →
-                      (L1 â\8b\95[V, d] L2 â\86\92 â\8a¥) â\88¨ (L1.â\93\91{I}V â\8b\95[T, ⫯d] L2.ⓑ{I}V → ⊥).
+lemma nlleq_inv_bind: â\88\80a,I,L1,L2,V,T,d. (L1 â\89¡[ⓑ{a,I}V.T, d] L2 → ⊥) →
+                      (L1 â\89¡[V, d] L2 â\86\92 â\8a¥) â\88¨ (L1.â\93\91{I}V â\89¡[T, ⫯d] L2.ⓑ{I}V → ⊥).
 /3 width=2 by nllpx_sn_inv_bind, eq_term_dec/ qed-.
 
-lemma nlleq_inv_flat: â\88\80I,L1,L2,V,T,d. (L1 â\8b\95[ⓕ{I}V.T, d] L2 → ⊥) →
-                      (L1 â\8b\95[V, d] L2 â\86\92 â\8a¥) â\88¨ (L1 â\8b\95[T, d] L2 → ⊥).
+lemma nlleq_inv_flat: â\88\80I,L1,L2,V,T,d. (L1 â\89¡[ⓕ{I}V.T, d] L2 → ⊥) →
+                      (L1 â\89¡[V, d] L2 â\86\92 â\8a¥) â\88¨ (L1 â\89¡[T, d] L2 → ⊥).
 /3 width=2 by nllpx_sn_inv_flat, eq_term_dec/ qed-.
 
-lemma nlleq_inv_bind_O: â\88\80a,I,L1,L2,V,T. (L1 â\8b\95[ⓑ{a,I}V.T, 0] L2 → ⊥) →
-                        (L1 â\8b\95[V, 0] L2 â\86\92 â\8a¥) â\88¨ (L1.â\93\91{I}V â\8b\95[T, 0] L2.ⓑ{I}V → ⊥).
+lemma nlleq_inv_bind_O: â\88\80a,I,L1,L2,V,T. (L1 â\89¡[ⓑ{a,I}V.T, 0] L2 → ⊥) →
+                        (L1 â\89¡[V, 0] L2 â\86\92 â\8a¥) â\88¨ (L1.â\93\91{I}V â\89¡[T, 0] L2.ⓑ{I}V → ⊥).
 /3 width=2 by nllpx_sn_inv_bind_O, eq_term_dec/ qed-.
index 01bde31ec11a85483440ff7bf90fe8a8bd579d77..bef6eeb7fdc4814dce79689bb57ed14ad24aac2b 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/relocation/llpx_sn_leq.ma".
+include "basic_2/substitution/llpx_sn_leq.ma".
 include "basic_2/substitution/lleq.ma".
 
 (* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
 
 (* Properties on equivalence for local environments *************************)
 
-lemma leq_lleq_trans: â\88\80L2,L,T,d. L2 â\8b\95[T, d] L →
-                      â\88\80L1. L1 â\89\83[d, â\88\9e] L2 â\86\92 L1 â\8b\95[T, d] L.
+lemma leq_lleq_trans: â\88\80L2,L,T,d. L2 â\89¡[T, d] L →
+                      â\88\80L1. L1 â\89\83[d, â\88\9e] L2 â\86\92 L1 â\89¡[T, d] L.
 /2 width=3 by leq_llpx_sn_trans/ qed-.
 
-lemma lleq_leq_trans: â\88\80L,L1,T,d. L â\8b\95[T, d] L1 →
-                      â\88\80L2. L1 â\89\83[d, â\88\9e] L2 â\86\92 L â\8b\95[T, d] L2.
+lemma lleq_leq_trans: â\88\80L,L1,T,d. L â\89¡[T, d] L1 →
+                      â\88\80L2. L1 â\89\83[d, â\88\9e] L2 â\86\92 L â\89¡[T, d] L2.
 /2 width=3 by llpx_sn_leq_trans/ qed-.
 
-lemma lleq_leq_repl: â\88\80L1,L2,T,d. L1 â\8b\95[T, d] L2 → ∀K1. K1 ≃[d, ∞] L1 →
-                     â\88\80K2. L2 â\89\83[d, â\88\9e] K2 â\86\92 K1 â\8b\95[T, d] K2.
+lemma lleq_leq_repl: â\88\80L1,L2,T,d. L1 â\89¡[T, d] L2 → ∀K1. K1 ≃[d, ∞] L1 →
+                     â\88\80K2. L2 â\89\83[d, â\88\9e] K2 â\86\92 K1 â\89¡[T, d] K2.
 /2 width=5 by llpx_sn_leq_repl/ qed-.
 
-lemma lleq_bind_repl_SO: â\88\80I1,I2,L1,L2,V1,V2,T. L1.â\93\91{I1}V1 â\8b\95[T, 0] L2.ⓑ{I2}V2 →
-                         â\88\80J1,J2,W1,W2. L1.â\93\91{J1}W1 â\8b\95[T, 1] L2.ⓑ{J2}W2.
+lemma lleq_bind_repl_SO: â\88\80I1,I2,L1,L2,V1,V2,T. L1.â\93\91{I1}V1 â\89¡[T, 0] L2.ⓑ{I2}V2 →
+                         â\88\80J1,J2,W1,W2. L1.â\93\91{J1}W1 â\89¡[T, 1] L2.ⓑ{J2}W2.
 /2 width=5 by llpx_sn_bind_repl_SO/ qed-.
index a3a276ff367e31236fb25bd784f58d40ab966ea4..abee448a3bc70740bb8cf207e1bc4a47044a828b 100644 (file)
@@ -19,14 +19,14 @@ include "basic_2/substitution/lleq_ldrop.ma".
 theorem lleq_trans: ∀d,T. Transitive … (lleq d T).
 /2 width=3 by lleq_llpx_sn_trans/ qed-.
 
-theorem lleq_canc_sn: â\88\80L,L1,L2,T,d. L â\8b\95[d, T] L1â\86\92 L â\8b\95[d, T] L2 â\86\92 L1 â\8b\95[d, T] L2.
+theorem lleq_canc_sn: â\88\80L,L1,L2,T,d. L â\89¡[d, T] L1â\86\92 L â\89¡[d, T] L2 â\86\92 L1 â\89¡[d, T] L2.
 /3 width=3 by lleq_trans, lleq_sym/ qed-.
 
-theorem lleq_canc_dx: â\88\80L1,L2,L,T,d. L1 â\8b\95[d, T] L â\86\92 L2 â\8b\95[d, T] L â\86\92 L1 â\8b\95[d, T] L2.
+theorem lleq_canc_dx: â\88\80L1,L2,L,T,d. L1 â\89¡[d, T] L â\86\92 L2 â\89¡[d, T] L â\86\92 L1 â\89¡[d, T] L2.
 /3 width=3 by lleq_trans, lleq_sym/ qed-.
 
-(* Note: lleq_nlleq_trans: â\88\80d,T,L1,L. L1â\8b\95[T, d] L →
-                           â\88\80L2. (L â\8b\95[T, d] L2 â\86\92 â\8a¥) â\86\92 (L1 â\8b\95[T, d] L2 → ⊥).
+(* Note: lleq_nlleq_trans: â\88\80d,T,L1,L. L1â\89¡[T, d] L →
+                           â\88\80L2. (L â\89¡[T, d] L2 â\86\92 â\8a¥) â\86\92 (L1 â\89¡[T, d] L2 → ⊥).
 /3 width=3 by lleq_canc_sn/ qed-.
 works with /4 width=8/ so lleq_canc_sn is more convenient
 *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn.ma
new file mode 100644 (file)
index 0000000..918b426
--- /dev/null
@@ -0,0 +1,209 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "ground_2/ynat/ynat_plus.ma".
+include "basic_2/relocation/ldrop.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+inductive llpx_sn (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
+| llpx_sn_sort: ∀L1,L2,d,k. |L1| = |L2| → llpx_sn R d (⋆k) L1 L2
+| llpx_sn_skip: ∀L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn R d (#i) L1 L2
+| llpx_sn_lref: ∀I,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
+                ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                llpx_sn R (yinj 0) V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d (#i) L1 L2
+| llpx_sn_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → llpx_sn R d (#i) L1 L2
+| llpx_sn_gref: ∀L1,L2,d,p. |L1| = |L2| → llpx_sn R d (§p) L1 L2
+| llpx_sn_bind: ∀a,I,L1,L2,V,T,d.
+                llpx_sn R d V L1 L2 → llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
+                llpx_sn R d (ⓑ{a,I}V.T) L1 L2
+| llpx_sn_flat: ∀I,L1,L2,V,T,d.
+                llpx_sn R d V L1 L2 → llpx_sn R d T L1 L2 → llpx_sn R d (ⓕ{I}V.T) L1 L2
+.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact llpx_sn_inv_bind_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 →
+                           ∀a,I,V,T. X = ⓑ{a,I}V.T →
+                           llpx_sn R d V L1 L2 ∧ llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #L1 #L2 #X #d * -L1 -L2 -X -d
+[ #L1 #L2 #d #k #_ #b #J #W #U #H destruct
+| #L1 #L2 #d #i #_ #_ #b #J #W #U #H destruct
+| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #_ #_ #_ #_ #b #J #W #U #H destruct
+| #L1 #L2 #d #i #_ #_ #_ #b #J #W #U #H destruct
+| #L1 #L2 #d #p #_ #b #J #W #U #H destruct
+| #a #I #L1 #L2 #V #T #d #HV #HT #b #J #W #U #H destruct /2 width=1 by conj/
+| #I #L1 #L2 #V #T #d #_ #_ #b #J #W #U #H destruct
+]
+qed-.
+
+lemma llpx_sn_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
+                        llpx_sn R d V L1 L2 ∧ llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+/2 width=4 by llpx_sn_inv_bind_aux/ qed-.
+
+fact llpx_sn_inv_flat_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 →
+                           ∀I,V,T. X = ⓕ{I}V.T →
+                           llpx_sn R d V L1 L2 ∧ llpx_sn R d T L1 L2.
+#R #L1 #L2 #X #d * -L1 -L2 -X -d
+[ #L1 #L2 #d #k #_ #J #W #U #H destruct
+| #L1 #L2 #d #i #_ #_ #J #W #U #H destruct
+| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #_ #_ #_ #_ #J #W #U #H destruct
+| #L1 #L2 #d #i #_ #_ #_ #J #W #U #H destruct
+| #L1 #L2 #d #p #_ #J #W #U #H destruct
+| #a #I #L1 #L2 #V #T #d #_ #_ #J #W #U #H destruct
+| #I #L1 #L2 #V #T #d #HV #HT #J #W #U #H destruct /2 width=1 by conj/
+]
+qed-.
+
+lemma llpx_sn_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
+                        llpx_sn R d V L1 L2 ∧ llpx_sn R d T L1 L2.
+/2 width=4 by llpx_sn_inv_flat_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma llpx_sn_fwd_length: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d //
+#I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #_ #HLK1 #HLK2 #_ #_ #HK12
+lapply (ldrop_fwd_length … HLK1) -HLK1
+lapply (ldrop_fwd_length … HLK2) -HLK2
+normalize //
+qed-.
+
+lemma llpx_sn_fwd_ldrop_sn: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
+                            ∀K1,i. ⇩[i] L1 ≡ K1 → ∃K2. ⇩[i] L2 ≡ K2.
+#R #L1 #L2 #T #d #H #K1 #i #HLK1 lapply (llpx_sn_fwd_length … H) -H
+#HL12 lapply (ldrop_fwd_length_le2 … HLK1) -HLK1 /2 width=1 by ldrop_O1_le/
+qed-.
+
+lemma llpx_sn_fwd_ldrop_dx: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
+                            ∀K2,i. ⇩[i] L2 ≡ K2 → ∃K1. ⇩[i] L1 ≡ K1.
+#R #L1 #L2 #T #d #H #K2 #i #HLK2 lapply (llpx_sn_fwd_length … H) -H
+#HL12 lapply (ldrop_fwd_length_le2 … HLK2) -HLK2 /2 width=1 by ldrop_O1_le/
+qed-.
+
+fact llpx_sn_fwd_lref_aux: ∀R,L1,L2,X,d. llpx_sn R d X L1 L2 → ∀i. X = #i →
+                           ∨∨ |L1| ≤ i ∧ |L2| ≤ i
+                            | yinj i < d
+                            | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                               ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                               llpx_sn R (yinj 0) V1 K1 K2 &
+                                               R I K1 V1 V2 & d ≤ yinj i.
+#R #L1 #L2 #X #d * -L1 -L2 -X -d
+[ #L1 #L2 #d #k #_ #j #H destruct
+| #L1 #L2 #d #i #_ #Hid #j #H destruct /2 width=1 by or3_intro1/
+| #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 #j #H destruct
+  /3 width=9 by or3_intro2, ex5_5_intro/
+| #L1 #L2 #d #i #HL1 #HL2 #_ #j #H destruct /3 width=1 by or3_intro0, conj/
+| #L1 #L2 #d #p #_ #j #H destruct
+| #a #I #L1 #L2 #V #T #d #_ #_ #j #H destruct
+| #I #L1 #L2 #V #T #d #_ #_ #j #H destruct
+]
+qed-.
+
+lemma llpx_sn_fwd_lref: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
+                        ∨∨ |L1| ≤ i ∧ |L2| ≤ i
+                         | yinj i < d
+                         | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                            ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                            llpx_sn R (yinj 0) V1 K1 K2 &
+                                            R I K1 V1 V2 & d ≤ yinj i.
+/2 width=3 by llpx_sn_fwd_lref_aux/ qed-.
+
+lemma llpx_sn_fwd_bind_sn: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
+                           llpx_sn R d V L1 L2.
+#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_bind … H) -H //
+qed-.
+
+lemma llpx_sn_fwd_bind_dx: ∀R,a,I,L1,L2,V,T,d. llpx_sn R d (ⓑ{a,I}V.T) L1 L2 →
+                           llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_bind … H) -H //
+qed-.
+
+lemma llpx_sn_fwd_flat_sn: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
+                           llpx_sn R d V L1 L2.
+#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_flat … H) -H //
+qed-.
+
+lemma llpx_sn_fwd_flat_dx: ∀R,I,L1,L2,V,T,d. llpx_sn R d (ⓕ{I}V.T) L1 L2 →
+                           llpx_sn R d T L1 L2.
+#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_inv_flat … H) -H //
+qed-.
+
+lemma llpx_sn_fwd_pair_sn: ∀R,I,L1,L2,V,T,d. llpx_sn R d (②{I}V.T) L1 L2 →
+                           llpx_sn R d V L1 L2.
+#R * /2 width=4 by llpx_sn_fwd_flat_sn, llpx_sn_fwd_bind_sn/
+qed-.
+
+(* Basic_properties *********************************************************)
+
+lemma llpx_sn_refl: ∀R. (∀I,L. reflexive … (R I L)) → ∀T,L,d. llpx_sn R d T L L.
+#R #HR #T #L @(f2_ind … rfw … L T) -L -T
+#n #IH #L * * /3 width=1 by llpx_sn_sort, llpx_sn_gref, llpx_sn_bind, llpx_sn_flat/
+#i #Hn elim (lt_or_ge i (|L|)) /2 width=1 by llpx_sn_free/
+#HiL #d elim (ylt_split i d) /2 width=1 by llpx_sn_skip/
+elim (ldrop_O1_lt … HiL) -HiL destruct /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
+qed-.
+
+lemma llpx_sn_Y: ∀R,T,L1,L2. |L1| = |L2| → llpx_sn R (∞) T L1 L2.
+#R #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * * /3 width=1 by llpx_sn_sort, llpx_sn_skip, llpx_sn_gref, llpx_sn_flat/
+#a #I #V1 #T1 #Hn #L2 #HL12
+@llpx_sn_bind /2 width=1/ (**) (* explicit constructor *)
+@IH -IH // normalize /2 width=1 by eq_f2/
+qed-.
+
+lemma llpx_sn_ge_up: ∀R,L1,L2,U,dt. llpx_sn R dt U L1 L2 → ∀T,d,e. ⇧[d, e] T ≡ U →
+                     dt ≤ d + e → llpx_sn R d U L1 L2.
+#R #L1 #L2 #U #dt #H elim H -L1 -L2 -U -dt
+[ #L1 #L2 #dt #k #HL12 #X #d #e #H #_ >(lift_inv_sort2 … H) -H /2 width=1 by llpx_sn_sort/
+| #L1 #L2 #dt #i #HL12 #Hidt #X #d #e #H #Hdtde
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=1 by llpx_sn_skip, ylt_inj/ -HL12
+  elim (ylt_yle_false … Hidt) -Hidt
+  @(yle_trans … Hdtde) /2 width=1 by yle_inj/ (**) (* full auto too slow 11s *)
+| #I #L1 #L2 #K1 #K2 #W1 #W2 #dt #i #Hdti #HLK1 #HLK2 #HW1 #HW12 #_ #X #d #e #H #_
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ lapply (llpx_sn_fwd_length … HW1) -HW1 #HK12
+    lapply (ldrop_fwd_length … HLK1) lapply (ldrop_fwd_length … HLK2)
+    normalize in ⊢ (%→%→?); -I -W1 -W2 -dt /3 width=1 by llpx_sn_skip, ylt_inj/
+  | /4 width=9 by llpx_sn_lref, yle_inj, le_plus_b/
+  ]
+| /2 width=1 by llpx_sn_free/
+| #L1 #L2 #dt #p #HL12 #X #d #e #H #_ >(lift_inv_gref2 … H) -H /2 width=1 by llpx_sn_gref/
+| #a #I #L1 #L2 #W #U #dt #_ #_ #IHV #IHT #X #d #e #H #Hdtde destruct
+  elim (lift_inv_bind2 … H) -H #V #T #HVW >commutative_plus #HTU #H destruct 
+  @(llpx_sn_bind) /2 width=4 by/ (**) (* full auto fails *)
+  @(IHT … HTU) /2 width=1 by yle_succ/
+| #I #L1 #L2 #W #U #dt #_ #_ #IHV #IHT #X #d #e #H #Hdtde destruct
+  elim (lift_inv_flat2 … H) -H #HVW #HTU #H destruct
+  /3 width=4 by llpx_sn_flat/
+]
+qed-.
+
+(**) (* the minor premise comes first *)
+lemma llpx_sn_ge: ∀R,L1,L2,T,d1,d2. d1 ≤ d2 →
+                  llpx_sn R d1 T L1 L2 → llpx_sn R d2 T L1 L2.
+#R #L1 #L2 #T #d1 #d2 * -d1 -d2 (**) (* destructed yle *)
+/3 width=6 by llpx_sn_ge_up, llpx_sn_Y, llpx_sn_fwd_length, yle_inj/
+qed-.
+
+lemma llpx_sn_bind_O: ∀R,a,I,L1,L2,V,T. llpx_sn R 0 V L1 L2 →
+                      llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
+                      llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2.
+/3 width=3 by llpx_sn_ge, llpx_sn_bind/ qed-.
+
+lemma llpx_sn_co: ∀R1,R2. (∀I,L,T1,T2. R1 I L T1 T2 → R2 I L T1 T2) →
+                  ∀L1,L2,T,d. llpx_sn R1 d T L1 L2 → llpx_sn R2 d T L1 L2.
+#R1 #R2 #HR12 #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+/3 width=9 by llpx_sn_sort, llpx_sn_skip, llpx_sn_lref, llpx_sn_free, llpx_sn_gref, llpx_sn_bind, llpx_sn_flat/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_alt1.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_alt1.ma
new file mode 100644 (file)
index 0000000..7e071f2
--- /dev/null
@@ -0,0 +1,250 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/relocation/lift_neg.ma".
+include "basic_2/relocation/ldrop_ldrop.ma".
+include "basic_2/substitution/llpx_sn.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* alternative definition of llpx_sn (recursive) *)
+inductive llpx_sn_alt1 (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
+| llpx_sn_alt1_intro: ∀L1,L2,T,d.
+                      (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                         ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 → I1 = I2 ∧ R I1 K1 V1 V2
+                      ) →
+                      (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                         ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 → llpx_sn_alt1 R 0 V1 K1 K2
+                      ) → |L1| = |L2| → llpx_sn_alt1 R d T L1 L2
+.
+
+(* Compact definition of llpx_sn_alt1 ****************************************)
+
+lemma llpx_sn_alt1_intro_alt: ∀R,L1,L2,T,d. |L1| = |L2| →
+                              (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                                 ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                                 ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt1 R 0 V1 K1 K2
+                              ) → llpx_sn_alt1 R d T L1 L2.
+#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt1_intro // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by conj/
+qed.
+
+lemma llpx_sn_alt1_ind_alt: ∀R. ∀S:relation4 ynat term lenv lenv.
+                            (∀L1,L2,T,d. |L1| = |L2| → (
+                               ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                               ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                               ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt1 R 0 V1 K1 K2 & S 0 V1 K1 K2
+                            ) → S d T L1 L2) →
+                            ∀L1,L2,T,d. llpx_sn_alt1 R d T L1 L2 → S d T L1 L2.
+#R #S #IH #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+#L1 #L2 #T #d #H1 #H2 #HL12 #IH2 @IH -IH // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (H1 … HnT HLK1 HLK2) -H1 /4 width=8 by and4_intro/
+qed-.
+
+lemma llpx_sn_alt1_inv_alt: ∀R,L1,L2,T,d. llpx_sn_alt1 R d T L1 L2 →
+                            |L1| = |L2| ∧
+                            ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                            ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                            ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn_alt1 R 0 V1 K1 K2.
+#R #L1 #L2 #T #d #H @(llpx_sn_alt1_ind_alt … H) -L1 -L2 -T -d
+#L1 #L2 #T #d #HL12 #IH @conj // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /2 width=1 by and3_intro/
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma llpx_sn_alt1_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn_alt1 R d (ⓕ{I}V.T) L1 L2 →
+                            llpx_sn_alt1 R d V L1 L2 ∧ llpx_sn_alt1 R d T L1 L2.
+#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt1_inv_alt … H) -H
+#HL12 #IH @conj @llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2
+elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2 //
+/3 width=8 by nlift_flat_sn, nlift_flat_dx, and3_intro/
+qed-.
+
+lemma llpx_sn_alt1_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn_alt1 R d (ⓑ{a,I}V.T) L1 L2 →
+                             llpx_sn_alt1 R d V L1 L2 ∧ llpx_sn_alt1 R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt1_inv_alt … H) -H
+#HL12 #IH @conj @llpx_sn_alt1_intro_alt [1,3: normalize // ] -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2
+[ elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2
+  /3 width=9 by nlift_bind_sn, and3_intro/
+| lapply (yle_inv_succ1 … Hdi) -Hdi * #Hdi #Hi
+  lapply (ldrop_inv_drop1_lt … HLK1 ?) -HLK1 /2 width=1 by ylt_O/ #HLK1
+  lapply (ldrop_inv_drop1_lt … HLK2 ?) -HLK2 /2 width=1 by ylt_O/ #HLK2
+  elim (IH … HLK1 HLK2) -IH -HLK1 -HLK2 /2 width=1 by and3_intro/
+  @nlift_bind_dx <plus_minus_m_m /2 width=2 by ylt_O/
+]
+qed-.
+
+(* Basic forward lemmas ******************************************************)
+
+lemma llpx_sn_alt1_fwd_length: ∀R,L1,L2,T,d. llpx_sn_alt1 R d T L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #T #d #H elim (llpx_sn_alt1_inv_alt … H) -H //
+qed-.
+
+lemma llpx_sn_alt1_fwd_lref: ∀R,L1,L2,d,i. llpx_sn_alt1 R d (#i) L1 L2 →
+                             ∨∨ |L1| ≤ i ∧ |L2| ≤ i
+                              | yinj i < d
+                              | ∃∃I,K1,K2,V1,V2. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                                 ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                                 llpx_sn_alt1 R (yinj 0) V1 K1 K2 &
+                                                 R I K1 V1 V2 & d ≤ yinj i.
+#R #L1 #L2 #d #i #H elim (llpx_sn_alt1_inv_alt … H) -H
+#HL12 #IH elim (lt_or_ge i (|L1|)) /3 width=1 by or3_intro0, conj/
+elim (ylt_split i d) /3 width=1 by or3_intro1/
+#Hdi #HL1 elim (ldrop_O1_lt … HL1)
+#I1 #K1 #V1 #HLK1 elim (ldrop_O1_lt L2 i) //
+#I2 #K2 #V2 #HLK2 elim (IH … HLK1 HLK2) -IH
+/3 width=9 by nlift_lref_be_SO, or3_intro2, ex5_5_intro/
+qed-.
+
+(* Basic properties **********************************************************)
+
+lemma llpx_sn_alt1_sort: ∀R,L1,L2,d,k. |L1| = |L2| → llpx_sn_alt1 R d (⋆k) L1 L2.
+#R #L1 #L2 #d #k #HL12 @llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (⋆k)) //
+qed.
+
+lemma llpx_sn_alt1_gref: ∀R,L1,L2,d,p. |L1| = |L2| → llpx_sn_alt1 R d (§p) L1 L2.
+#R #L1 #L2 #d #p #HL12 @llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (§p)) //
+qed.
+
+lemma llpx_sn_alt1_skip: ∀R,L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn_alt1 R d (#i) L1 L2.
+#R #L1 #L2 #d #i #HL12 #Hid @llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #j #Hdj #H elim (H (#i)) -H
+/4 width=3 by lift_lref_lt, ylt_yle_trans, ylt_inv_inj/
+qed.
+
+lemma llpx_sn_alt1_free: ∀R,L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| →
+                         llpx_sn_alt1 R d (#i) L1 L2.
+#R #L1 #L2 #d #i #HL1 #_ #HL12 @llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #j #_ #H #HLK1 elim (H (#(i-1))) -H
+lapply (ldrop_fwd_length_lt2 … HLK1) -HLK1
+/3 width=3 by lift_lref_ge_minus, lt_to_le_to_lt/
+qed.
+
+lemma llpx_sn_alt1_lref: ∀R,I,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
+                         ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                         llpx_sn_alt1 R 0 V1 K1 K2 → R I K1 V1 V2 →
+                        llpx_sn_alt1 R d (#i) L1 L2.
+#R #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 @llpx_sn_alt1_intro_alt
+[ lapply (llpx_sn_alt1_fwd_length … HK12) -HK12 #HK12
+  @(ldrop_fwd_length_eq2 … HLK1 HLK2) normalize //
+| #Z1 #Z2 #Y1 #Y2 #X1 #X2 #j #Hdj #H #HLY1 #HLY2
+  elim (lt_or_eq_or_gt i j) #Hij destruct
+  [ elim (H (#i)) -H /2 width=1 by lift_lref_lt/
+  | lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1 #H destruct
+    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2 #H destruct /2 width=1 by and3_intro/
+  | elim (H (#(i-1))) -H /2 width=1 by lift_lref_ge_minus/
+  ]
+]
+qed.
+
+lemma llpx_sn_alt1_flat: ∀R,I,L1,L2,V,T,d.
+                         llpx_sn_alt1 R d V L1 L2 → llpx_sn_alt1 R d T L1 L2 →
+                         llpx_sn_alt1 R d (ⓕ{I}V.T) L1 L2.
+#R #I #L1 #L2 #V #T #d #HV #HT
+elim (llpx_sn_alt1_inv_alt … HV) -HV #HL12 #IHV
+elim (llpx_sn_alt1_inv_alt … HT) -HT #_ #IHT
+@llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnVT #HLK1 #HLK2
+elim (nlift_inv_flat … HnVT) -HnVT #H
+[ elim (IHV … HLK1 … HLK2) -IHV /2 width=2 by and3_intro/
+| elim (IHT … HLK1 … HLK2) -IHT /3 width=2 by and3_intro/
+]
+qed.
+
+lemma llpx_sn_alt1_bind: ∀R,a,I,L1,L2,V,T,d.
+                         llpx_sn_alt1 R d V L1 L2 →
+                         llpx_sn_alt1 R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
+                         llpx_sn_alt1 R d (ⓑ{a,I}V.T) L1 L2.
+#R #a #I #L1 #L2 #V #T #d #HV #HT
+elim (llpx_sn_alt1_inv_alt … HV) -HV #HL12 #IHV
+elim (llpx_sn_alt1_inv_alt … HT) -HT #_ #IHT
+@llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnVT #HLK1 #HLK2
+elim (nlift_inv_bind … HnVT) -HnVT #H
+[ elim (IHV … HLK1 … HLK2) -IHV /2 width=2 by and3_intro/
+| elim IHT -IHT /2 width=12 by ldrop_drop, yle_succ, and3_intro/
+]
+qed.
+
+(* Main properties **********************************************************)
+
+theorem llpx_sn_lpx_sn_alt1: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → llpx_sn_alt1 R d T L1 L2.
+#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+/2 width=9 by llpx_sn_alt1_sort, llpx_sn_alt1_gref, llpx_sn_alt1_skip, llpx_sn_alt1_free, llpx_sn_alt1_lref, llpx_sn_alt1_flat, llpx_sn_alt1_bind/
+qed.
+
+(* Main inversion lemmas ****************************************************)
+
+theorem llpx_sn_alt1_inv_lpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt1 R d T L1 L2 → llpx_sn R d T L1 L2.
+#R #T #L1 @(f2_ind … rfw … L1 T) -L1 -T #n #IH #L1 * *
+[1,3: /3 width=4 by llpx_sn_alt1_fwd_length, llpx_sn_gref, llpx_sn_sort/
+| #i #Hn #L2 #d #H lapply (llpx_sn_alt1_fwd_length … H)
+  #HL12 elim (llpx_sn_alt1_fwd_lref … H) -H
+  [ * /2 width=1 by llpx_sn_free/
+  | /2 width=1 by llpx_sn_skip/
+  | * /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
+  ]
+| #a #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt1_inv_bind … H) -H
+  /3 width=1 by llpx_sn_bind/
+| #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt1_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+]
+qed-.
+
+(* Alternative definition of llpx_sn (recursive) ****************************)
+
+lemma llpx_sn_intro_alt1: ∀R,L1,L2,T,d. |L1| = |L2| →
+                          (∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                             ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                             ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2
+                          ) → llpx_sn R d T L1 L2.
+#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt1_inv_lpx_sn
+@llpx_sn_alt1_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_lpx_sn_alt1, and3_intro/
+qed.
+
+lemma llpx_sn_ind_alt1: ∀R. ∀S:relation4 ynat term lenv lenv.
+                        (∀L1,L2,T,d. |L1| = |L2| → (
+                           ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                           ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2 & S 0 V1 K1 K2
+                        ) → S d T L1 L2) →
+                        ∀L1,L2,T,d. llpx_sn R d T L1 L2 → S d T L1 L2.
+#R #S #IH1 #L1 #L2 #T #d #H lapply (llpx_sn_lpx_sn_alt1 … H) -H
+#H @(llpx_sn_alt1_ind_alt … H) -L1 -L2 -T -d
+#L1 #L2 #T #d #HL12 #IH2 @IH1 -IH1 // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (IH2 … HnT HLK1 HLK2) -IH2 -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_alt1_inv_lpx_sn, and4_intro/
+qed-.
+
+lemma llpx_sn_inv_alt1: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 →
+                        |L1| = |L2| ∧
+                        ∀I1,I2,K1,K2,V1,V2,i. d ≤ yinj i → (∀U. ⇧[i, 1] U ≡ T → ⊥) →
+                        ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                        ∧∧ I1 = I2 & R I1 K1 V1 V2 & llpx_sn R 0 V1 K1 K2.
+#R #L1 #L2 #T #d #H lapply (llpx_sn_lpx_sn_alt1 … H) -H
+#H elim (llpx_sn_alt1_inv_alt … H) -H
+#HL12 #IH @conj //
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hid #HnT #HLK1 #HLK2
+elim (IH … HnT HLK1 HLK2) -IH -HnT -HLK1 -HLK2 /3 width=1 by llpx_sn_alt1_inv_lpx_sn, and3_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_ldrop.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_ldrop.ma
new file mode 100644 (file)
index 0000000..04a0f92
--- /dev/null
@@ -0,0 +1,431 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/relocation/ldrop_ldrop.ma".
+include "basic_2/substitution/llpx_sn_leq.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* Advanced forward lemmas **************************************************)
+
+lemma llpx_sn_fwd_lref_dx: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
+                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                           i < d ∨
+                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 & llpx_sn R 0 V1 K1 K2 &
+                                    R I K1 V1 V2 & d ≤ i.
+#R #L1 #L2 #d #i #H #I #K2 #V2 #HLK2 elim (llpx_sn_fwd_lref … H) -H [ * || * ]
+[ #_ #H elim (lt_refl_false i)
+  lapply (ldrop_fwd_length_lt2 … HLK2) -HLK2
+  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
+| /2 width=1 by or_introl/
+| #I #K11 #K22 #V11 #V22 #HLK11 #HLK22 #HK12 #HV12 #Hdi
+  lapply (ldrop_mono … HLK22 … HLK2) -L2 #H destruct
+  /3 width=5 by ex4_2_intro, or_intror/
+]
+qed-.
+
+lemma llpx_sn_fwd_lref_sn: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 →
+                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                           i < d ∨
+                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 & llpx_sn R 0 V1 K1 K2 &
+                                    R I K1 V1 V2 & d ≤ i.
+#R #L1 #L2 #d #i #H #I #K1 #V1 #HLK1 elim (llpx_sn_fwd_lref … H) -H [ * || * ]
+[ #H #_ elim (lt_refl_false i)
+  lapply (ldrop_fwd_length_lt2 … HLK1) -HLK1
+  /2 width=3 by lt_to_le_to_lt/ (**) (* full auto too slow *)
+| /2 width=1 by or_introl/
+| #I #K11 #K22 #V11 #V22 #HLK11 #HLK22 #HK12 #HV12 #Hdi
+  lapply (ldrop_mono … HLK11 … HLK1) -L1 #H destruct
+  /3 width=5 by ex4_2_intro, or_intror/
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma llpx_sn_inv_lref_ge_dx: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
+                              ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                              ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                       llpx_sn R 0 V1 K1 K2 & R I K1 V1 V2.
+#R #L1 #L2 #d #i #H #Hdi #I #K2 #V2 #HLK2 elim (llpx_sn_fwd_lref_dx … H … HLK2) -L2
+[ #H elim (ylt_yle_false … H Hdi)
+| * /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma llpx_sn_inv_lref_ge_sn: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
+                              ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                              ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                       llpx_sn R 0 V1 K1 K2 & R I K1 V1 V2.
+#R #L1 #L2 #d #i #H #Hdi #I #K1 #V1 #HLK1 elim (llpx_sn_fwd_lref_sn … H … HLK1) -L1
+[ #H elim (ylt_yle_false … H Hdi)
+| * /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma llpx_sn_inv_lref_ge_bi: ∀R,L1,L2,d,i. llpx_sn R d (#i) L1 L2 → d ≤ i →
+                              ∀I1,I2,K1,K2,V1,V2.
+                              ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                              ∧∧ I1 = I2 & llpx_sn R 0 V1 K1 K2 & R I1 K1 V1 V2.
+#R #L1 #L2 #d #i #HL12 #Hdi #I1 #I2 #K1 #K2 #V1 #V2 #HLK1 #HLK2
+elim (llpx_sn_inv_lref_ge_sn … HL12 … HLK1) // -L1 -d
+#J #Y #HY lapply (ldrop_mono … HY … HLK2) -L2 -i #H destruct /2 width=1 by and3_intro/
+qed-.
+
+fact llpx_sn_inv_S_aux: ∀R,L1,L2,T,d0. llpx_sn R d0 T L1 L2 → ∀d. d0 = d + 1 →
+                        ∀K1,K2,I,V1,V2. ⇩[d] L1 ≡ K1.ⓑ{I}V1 → ⇩[d] L2 ≡ K2.ⓑ{I}V2 →
+                        llpx_sn R 0 V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d T L1 L2.
+#R #L1 #L2 #T #d0 #H elim H -L1 -L2 -T -d0
+/2 width=1 by llpx_sn_gref, llpx_sn_free, llpx_sn_sort/
+[ #L1 #L2 #d0 #i #HL12 #Hid #d #H #K1 #K2 #I #V1 #V2 #HLK1 #HLK2 #HK12 #HV12 destruct
+  elim (yle_split_eq i d) /2 width=1 by llpx_sn_skip, ylt_fwd_succ2/ -HL12 -Hid
+  #H destruct /2 width=9 by llpx_sn_lref/
+| #I #L1 #L2 #K11 #K22 #V1 #V2 #d0 #i #Hd0i #HLK11 #HLK22 #HK12 #HV12 #_ #d #H #K1 #K2 #J #W1 #W2 #_ #_ #_ #_ destruct
+  /3 width=9 by llpx_sn_lref, yle_pred_sn/
+| #a #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W1 #W2 #HLK1 #HLK2 #HK12 #HW12 destruct
+  /4 width=9 by llpx_sn_bind, ldrop_drop/
+| #I #L1 #L2 #V #T #d0 #_ #_ #IHV #IHT #d #H #K1 #K2 #J #W1 #W2 #HLK1 #HLK2 #HK12 #HW12 destruct
+  /3 width=9 by llpx_sn_flat/
+]
+qed-.
+
+lemma llpx_sn_inv_S: ∀R,L1,L2,T,d. llpx_sn R (d + 1) T L1 L2 →
+                     ∀K1,K2,I,V1,V2. ⇩[d] L1 ≡ K1.ⓑ{I}V1 → ⇩[d] L2 ≡ K2.ⓑ{I}V2 →
+                     llpx_sn R 0 V1 K1 K2 → R I K1 V1 V2 → llpx_sn R d T L1 L2.
+/2 width=9 by llpx_sn_inv_S_aux/ qed-.
+
+lemma llpx_sn_inv_bind_O: ∀R. (∀I,L. reflexive … (R I L)) →
+                          ∀a,I,L1,L2,V,T. llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 →
+                          llpx_sn R 0 V L1 L2 ∧ llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_inv_bind … H) -H
+/3 width=9 by ldrop_pair, conj, llpx_sn_inv_S/
+qed-.
+
+(* More advanced forward lemmas *********************************************)
+
+lemma llpx_sn_fwd_bind_O_dx: ∀R. (∀I,L. reflexive … (R I L)) →
+                             ∀a,I,L1,L2,V,T. llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 →
+                             llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_inv_bind_O … H) -H //
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma llpx_sn_bind_repl_O: ∀R,I,L1,L2,V1,V2,T. llpx_sn R 0 T (L1.ⓑ{I}V1) (L2.ⓑ{I}V2) →
+                           ∀J,W1,W2. llpx_sn R 0 W1 L1 L2 → R J L1 W1 W2 → llpx_sn R 0 T (L1.ⓑ{J}W1) (L2.ⓑ{J}W2).
+/3 width=9 by llpx_sn_bind_repl_SO, llpx_sn_inv_S/ qed-.
+
+lemma llpx_sn_dec: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
+                   ∀T,L1,L2,d. Decidable (llpx_sn R d T L1 L2).
+#R #HR #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * *
+[ #k #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, llpx_sn_sort/
+| #i #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|))
+  [ #HL12 #d elim (ylt_split i d) /3 width=1 by llpx_sn_skip, or_introl/
+    #Hdi elim (lt_or_ge i (|L1|)) #HiL1
+    elim (lt_or_ge i (|L2|)) #HiL2 /3 width=1 by or_introl, llpx_sn_free/
+    elim (ldrop_O1_lt … HiL2) #I2 #K2 #V2 #HLK2
+    elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
+    elim (eq_bind2_dec I2 I1)
+    [ #H2 elim (HR I1 K1 V1 V2) -HR
+      [ #H3 elim (IH K1 V1 … K2 0) destruct
+        /3 width=9 by llpx_sn_lref, ldrop_fwd_rfw, or_introl/
+      ]
+    ]
+    -IH #H3 @or_intror
+    #H elim (llpx_sn_fwd_lref … H) -H [1,3,4,6,7,9: * ]
+    [1,3,5: /3 width=4 by lt_to_le_to_lt, lt_refl_false/
+    |7,8,9: /2 width=4 by ylt_yle_false/
+    ]
+    #Z #Y1 #Y2 #X1 #X2 #HLY1 #HLY2 #HY12 #HX12
+    lapply (ldrop_mono … HLY1 … HLK1) -HLY1 -HLK1
+    lapply (ldrop_mono … HLY2 … HLK2) -HLY2 -HLK2
+    #H #H0 destruct /2 width=1 by/
+  ]
+| #p #Hn #L2 elim (eq_nat_dec (|L1|) (|L2|)) /3 width=1 by or_introl, llpx_sn_gref/
+| #a #I #V #T #Hn #L2 #d destruct
+  elim (IH L1 V … L2 d) /2 width=1 by/
+  elim (IH (L1.ⓑ{I}V) T … (L2.ⓑ{I}V) (⫯d)) -IH /3 width=1 by or_introl, llpx_sn_bind/
+  #H1 #H2 @or_intror
+  #H elim (llpx_sn_inv_bind … H) -H /2 width=1 by/
+| #I #V #T #Hn #L2 #d destruct
+  elim (IH L1 V … L2 d) /2 width=1 by/
+  elim (IH L1 T … L2 d) -IH /3 width=1 by or_introl, llpx_sn_flat/
+  #H1 #H2 @or_intror
+  #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
+]
+-n /4 width=4 by llpx_sn_fwd_length, or_intror/
+qed-.
+
+(* Properties on relocation *************************************************)
+
+lemma llpx_sn_lift_le: ∀R. (∀I. l_liftable (R I)) →
+                       ∀K1,K2,T,d0. llpx_sn R d0 T K1 K2 →
+                       ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                       ∀U. ⇧[d, e] T ≡ U → d0 ≤ d → llpx_sn R d0 U L1 L2.
+#R #HR #K1 #K2 #T #d0 #H elim H -K1 -K2 -T -d0
+[ #K1 #K2 #d0 #k #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort1 … H) -X
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
+  /2 width=1 by llpx_sn_sort/
+| #K1 #K2 #d0 #i #HK12 #Hid0 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
+  * #Hdi #H destruct
+  [ lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
+    /2 width=1 by llpx_sn_skip/
+  | elim (ylt_yle_false … Hid0) -L1 -L2 -K1 -K2 -e -Hid0
+    /3 width=3 by yle_trans, yle_inj/
+  ]
+| #I #K1 #K2 #K11 #K22 #V1 #V2 #d0 #i #Hid0 #HK11 #HK22 #HK12 #HV12 #IHK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
+  * #Hdi #H destruct [ -HK12 | -IHK12 ]
+  [ elim (ldrop_trans_lt … HLK1 … HK11) // -K1
+    elim (ldrop_trans_lt … HLK2 … HK22) // -Hdi -K2
+    /3 width=18 by llpx_sn_lref/
+  | lapply (ldrop_trans_ge_comm … HLK1 … HK11 ?) // -K1
+    lapply (ldrop_trans_ge_comm … HLK2 … HK22 ?) // -Hdi -Hd0 -K2
+    /3 width=9 by llpx_sn_lref, yle_plus_dx1_trans/
+  ]
+| #K1 #K2 #d0 #i #HK1 #HK2 #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
+  * #Hid #H destruct
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -HK12
+  [ /3 width=7 by llpx_sn_free, ldrop_fwd_be/
+  | lapply (ldrop_fwd_length … HLK1) -HLK1 #HLK1
+    lapply (ldrop_fwd_length … HLK2) -HLK2 #HLK2
+    @llpx_sn_free [ >HLK1 | >HLK2 ] -Hid -HLK1 -HLK2 /2 width=1 by monotonic_le_plus_r/ (**) (* explicit constructor *)
+  ]
+| #K1 #K2 #d0 #p #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref1 … H) -X
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d -e
+  /2 width=1 by llpx_sn_gref/
+| #a #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind1 … H) -H
+  #W #U #HVW #HTU #H destruct /4 width=6 by llpx_sn_bind, ldrop_skip, yle_succ/
+| #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat1 … H) -H
+  #W #U #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
+]
+qed-.
+
+lemma llpx_sn_lift_ge: ∀R,K1,K2,T,d0. llpx_sn R d0 T K1 K2 →
+                       ∀L1,L2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                       ∀U. ⇧[d, e] T ≡ U → d ≤ d0 → llpx_sn R (d0+e) U L1 L2.
+#R #K1 #K2 #T #d0 #H elim H -K1 -K2 -T -d0
+[ #K1 #K2 #d0 #k #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort1 … H) -X
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
+  /2 width=1 by llpx_sn_sort/
+| #K1 #K2 #d0 #i #HK12 #Hid0 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ elim (lift_inv_lref1 … H) -H
+  * #_ #H destruct
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2
+  [ /3 width=3 by llpx_sn_skip, ylt_plus_dx2_trans/
+  | /3 width=3 by llpx_sn_skip, monotonic_ylt_plus_dx/
+  ]
+| #I #K1 #K2 #K11 #K22 #V1 #V2 #d0 #i #Hid0 #HK11 #HK22 #HK12 #HV12 #_ #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
+  * #Hid #H destruct
+  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K1 -K2 -K11 -K22 -V1 -V2 -e -Hid0
+    /3 width=3 by ylt_yle_trans, ylt_inj/
+  | lapply (ldrop_trans_ge_comm … HLK1 … HK11 ?) // -K1
+    lapply (ldrop_trans_ge_comm … HLK2 … HK22 ?) // -Hid -Hd0 -K2
+    /3 width=9 by llpx_sn_lref, monotonic_yle_plus_dx/
+  ]
+| #K1 #K2 #d0 #i #HK1 #HK2 #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref1 … H) -H
+  * #Hid #H destruct
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -HK12
+  [ /3 width=7 by llpx_sn_free, ldrop_fwd_be/
+  | lapply (ldrop_fwd_length … HLK1) -HLK1 #HLK1
+    lapply (ldrop_fwd_length … HLK2) -HLK2 #HLK2
+    @llpx_sn_free [ >HLK1 | >HLK2 ] -Hid -HLK1 -HLK2 /2 width=1 by monotonic_le_plus_r/ (**) (* explicit constructor *)
+  ]
+| #K1 #K2 #d0 #p #HK12 #L1 #L2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref1 … H) -X
+  lapply (ldrop_fwd_length_eq2 … HLK1 HLK2 HK12) -K1 -K2 -d
+  /2 width=1 by llpx_sn_gref/
+| #a #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind1 … H) -H
+  #W #U #HVW #HTU #H destruct /4 width=5 by llpx_sn_bind, ldrop_skip, yle_succ/
+| #I #K1 #K2 #V #T #d0 #_ #_ #IHV #IHT #L1 #L2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat1 … H) -H
+  #W #U #HVW #HTU #H destruct /3 width=5 by llpx_sn_flat/
+]
+qed-.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma llpx_sn_inv_lift_le: ∀R. (∀I. l_deliftable_sn (R I)) →
+                           ∀L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
+                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                           ∀T. ⇧[d, e] T ≡ U → d0 ≤ d → llpx_sn R d0 T K1 K2.
+#R #HR #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
+[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d -e
+  /2 width=1 by llpx_sn_sort/
+| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ elim (lift_inv_lref2 … H) -H
+  * #_ #H destruct
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
+  [ /2 width=1 by llpx_sn_skip/
+  | /3 width=3 by llpx_sn_skip, yle_ylt_trans/
+  ]
+| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #IHK12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref2 … H) -H
+  * #Hid #H destruct [ -HK12 | -IHK12 ]
+  [ elim (ldrop_conf_lt … HLK1 … HLK11) // -L1 #L1 #V1 #HKL1 #HKL11 #HVW1
+    elim (ldrop_conf_lt … HLK2 … HLK22) // -Hid -L2 #L2 #V2 #HKL2 #HKL22 #HVW2
+    elim (HR … HW12 … HKL11 … HVW1) -HR #V0 #HV0 #HV12
+    lapply (lift_inj … HV0 … HVW2) -HV0 -HVW2 #H destruct
+    /3 width=10 by llpx_sn_lref/
+  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
+    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hid0
+    elim (le_inv_plus_l … Hid) -Hid /4 width=9 by llpx_sn_lref, yle_trans, yle_inj/ (**) (* slow *)
+  ]
+| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_lref2 … H) -H
+  * #_ #H destruct
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
+  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
+    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
+    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
+  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
+    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
+    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
+  ]
+| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d -e
+  /2 width=1 by llpx_sn_gref/
+| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_bind2 … H) -H
+  #V #T #HVW #HTU #H destruct /4 width=6 by llpx_sn_bind, ldrop_skip, yle_succ/
+| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 elim (lift_inv_flat2 … H) -H
+  #V #T #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
+]
+qed-.
+
+lemma llpx_sn_inv_lift_be: ∀R,L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
+                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                           ∀T. ⇧[d, e] T ≡ U → d ≤ d0 → d0 ≤ yinj d + e → llpx_sn R d T K1 K2.
+#R #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
+[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ #_ >(lift_inv_sort2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d0 -e
+  /2 width=1 by llpx_sn_sort/
+| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
+  * #Hid #H destruct
+  [ lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
+    -Hid0 /3 width=1 by llpx_sn_skip, ylt_inj/
+  | elim (ylt_yle_false … Hid0) -L1 -L2 -Hd0 -Hid0
+    /3 width=3 by yle_trans, yle_inj/ (**) (* slow *)
+  ]
+| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #_ #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
+  * #Hid #H destruct
+  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K11 -K22 -W1 -W2 -Hd0e -Hid0
+    /3 width=3 by ylt_yle_trans, ylt_inj/
+  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
+    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hid0 -Hd0 -Hd0e
+    elim (le_inv_plus_l … Hid) -Hid /3 width=9 by llpx_sn_lref, yle_inj/
+  ]
+| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_lref2 … H) -H
+  * #_ #H destruct
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
+  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
+    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
+    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
+  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
+    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
+    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
+  ]
+| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ #_ >(lift_inv_gref2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d0 -e
+  /2 width=1 by llpx_sn_gref/
+| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_bind2 … H) -H
+  >commutative_plus #V #T #HVW #HTU #H destruct
+  @llpx_sn_bind [ /2 width=5 by/ ] -IHW (**) (* explicit constructor *)
+  @(IHU … HTU) -IHU -HTU /2 width=1 by ldrop_skip, yle_succ/
+| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hd0 #Hd0e elim (lift_inv_flat2 … H) -H
+  #V #T #HVW #HTU #H destruct /3 width=6 by llpx_sn_flat/
+]
+qed-.
+
+lemma llpx_sn_inv_lift_ge: ∀R,L1,L2,U,d0. llpx_sn R d0 U L1 L2 →
+                           ∀K1,K2,d,e. ⇩[Ⓕ, d, e] L1 ≡ K1 → ⇩[Ⓕ, d, e] L2 ≡ K2 →
+                           ∀T. ⇧[d, e] T ≡ U → yinj d + e ≤ d0 → llpx_sn R (d0-e) T K1 K2.
+#R #L1 #L2 #U #d0 #H elim H -L1 -L2 -U -d0
+[ #L1 #L2 #d0 #k #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_sort2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d
+  /2 width=1 by llpx_sn_sort/
+| #L1 #L2 #d0 #i #HL12 #Hid0 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
+  * #Hid #H destruct [ -Hid0 | -Hded0 ]
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2
+  [ /4 width=3 by llpx_sn_skip, yle_plus_to_minus_inj2, ylt_yle_trans, ylt_inj/
+  | elim (le_inv_plus_l … Hid) -Hid #_
+    /4 width=1 by llpx_sn_skip, monotonic_ylt_minus_dx, yle_inj/
+  ]
+| #I #L1 #L2 #K11 #K22 #W1 #W2 #d0 #i #Hid0 #HLK11 #HLK22 #HK12 #HW12 #_ #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
+  * #Hid #H destruct
+  [ elim (ylt_yle_false … Hid0) -I -L1 -L2 -K11 -K22 -W1 -W2 -Hid0
+    /3 width=3 by yle_fwd_plus_sn1, ylt_yle_trans, ylt_inj/
+  | lapply (ldrop_conf_ge … HLK1 … HLK11 ?) // -L1
+    lapply (ldrop_conf_ge … HLK2 … HLK22 ?) // -L2 -Hded0 -Hid
+    /3 width=9 by llpx_sn_lref, monotonic_yle_minus_dx/
+  ]
+| #L1 #L2 #d0 #i #HL1 #HL2 #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_lref2 … H) -H
+  * #_ #H destruct
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12)
+  [ lapply (ldrop_fwd_length_le4 … HLK1) -HLK1
+    lapply (ldrop_fwd_length_le4 … HLK2) -HLK2
+    #HKL2 #HKL1 #HK12 @llpx_sn_free // /2 width=3 by transitive_le/ (**) (* full auto too slow *)
+  | lapply (ldrop_fwd_length … HLK1) -HLK1 #H >H in HL1; -H
+    lapply (ldrop_fwd_length … HLK2) -HLK2 #H >H in HL2; -H
+    /3 width=1 by llpx_sn_free, le_plus_to_minus_r/
+  ]
+| #L1 #L2 #d0 #p #HL12 #K1 #K2 #d #e #HLK1 #HLK2 #X #H #_ >(lift_inv_gref2 … H) -X
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) -L1 -L2 -d
+  /2 width=1 by llpx_sn_gref/
+| #a #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_bind2 … H) -H
+  #V #T #HVW #HTU #H destruct
+  @llpx_sn_bind [ /2 width=5 by/ ] -IHW (**) (* explicit constructor *)
+  <yminus_succ1_inj /2 width=2 by yle_fwd_plus_sn2/
+  @(IHU … HTU) -IHU -HTU /2 width=1 by ldrop_skip, yle_succ/
+| #I #L1 #L2 #W #U #d0 #_ #_ #IHW #IHU #K1 #K2 #d #e #HLK1 #HLK2 #X #H #Hded0 elim (lift_inv_flat2 … H) -H
+  #V #T #HVW #HTU #H destruct /3 width=5 by llpx_sn_flat/
+]
+qed-.
+
+(* Advanced inversion lemmas on relocation **********************************)
+
+lemma llpx_sn_inv_lift_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
+                          ∀K1,K2,e. ⇩[e] L1 ≡ K1 → ⇩[e] L2 ≡ K2 →
+                          ∀T. ⇧[0, e] T ≡ U → llpx_sn R 0 T K1 K2.
+/2 width=11 by llpx_sn_inv_lift_be/ qed-.
+
+lemma llpx_sn_ldrop_conf_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
+                            ∀K1,e. ⇩[e] L1 ≡ K1 → ∀T. ⇧[0, e] T ≡ U →
+                            ∃∃K2. ⇩[e] L2 ≡ K2 & llpx_sn R 0 T K1 K2.
+#R #L1 #L2 #U #HU #K1 #e #HLK1 #T #HTU elim (llpx_sn_fwd_ldrop_sn … HU … HLK1)
+/3 width=10 by llpx_sn_inv_lift_O, ex2_intro/
+qed-.
+
+lemma llpx_sn_ldrop_trans_O: ∀R,L1,L2,U. llpx_sn R 0 U L1 L2 →
+                             ∀K2,e. ⇩[e] L2 ≡ K2 → ∀T. ⇧[0, e] T ≡ U →
+                             ∃∃K1. ⇩[e] L1 ≡ K1 & llpx_sn R 0 T K1 K2.
+#R #L1 #L2 #U #HU #K2 #e #HLK2 #T #HTU elim (llpx_sn_fwd_ldrop_dx … HU … HLK2)
+/3 width=10 by llpx_sn_inv_lift_O, ex2_intro/
+qed-.
+
+(* Inversion lemmas on negated lazy pointwise extension *********************)
+
+lemma nllpx_sn_inv_bind: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
+                         ∀a,I,L1,L2,V,T,d. (llpx_sn R d (ⓑ{a,I}V.T) L1 L2 → ⊥) →
+                         (llpx_sn R d V L1 L2 → ⊥) ∨ (llpx_sn R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → ⊥).
+#R #HR #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_dec … HR V L1 L2 d)
+/4 width=1 by llpx_sn_bind, or_intror, or_introl/
+qed-.
+
+lemma nllpx_sn_inv_flat: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
+                         ∀I,L1,L2,V,T,d. (llpx_sn R d (ⓕ{I}V.T) L1 L2 → ⊥) →
+                         (llpx_sn R d V L1 L2 → ⊥) ∨ (llpx_sn R d T L1 L2 → ⊥).
+#R #HR #I #L1 #L2 #V #T #d #H elim (llpx_sn_dec … HR V L1 L2 d)
+/4 width=1 by llpx_sn_flat, or_intror, or_introl/
+qed-.
+
+lemma nllpx_sn_inv_bind_O: ∀R. (∀I,L,T1,T2. Decidable (R I L T1 T2)) →
+                           ∀a,I,L1,L2,V,T. (llpx_sn R 0 (ⓑ{a,I}V.T) L1 L2 → ⊥) →
+                           (llpx_sn R 0 V L1 L2 → ⊥) ∨ (llpx_sn R 0 T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → ⊥).
+#R #HR #a #I #L1 #L2 #V #T #H elim (llpx_sn_dec … HR V L1 L2 0)
+/4 width=1 by llpx_sn_bind_O, or_intror, or_introl/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_leq.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_leq.ma
new file mode 100644 (file)
index 0000000..6f3d1c5
--- /dev/null
@@ -0,0 +1,54 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/relocation/ldrop_leq.ma".
+include "basic_2/substitution/llpx_sn.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* Properties on equivalence for local environments *************************)
+
+lemma leq_llpx_sn_trans: ∀R,L2,L,T,d. llpx_sn R d T L2 L →
+                         ∀L1. L1 ≃[d, ∞] L2 → llpx_sn R d T L1 L.
+#R #L2 #L #T #d #H elim H -L2 -L -T -d
+/4 width=5 by llpx_sn_flat, llpx_sn_gref, llpx_sn_skip, llpx_sn_sort, leq_fwd_length, trans_eq/  
+[ #I #L2 #L #K2 #K #V2 #V #d #i #Hdi #HLK2 #HLK #HK2 #HV2 #_ #L1 #HL12
+  elim (leq_ldrop_trans_be … HL12 … HLK2) -L2 // >yminus_Y_inj #K1 #HK12 #HLK1
+  lapply (leq_inv_O_Y … HK12) -HK12 #H destruct /2 width=9 by llpx_sn_lref/
+| /4 width=5 by llpx_sn_free, leq_fwd_length, le_repl_sn_trans_aux, trans_eq/
+| /4 width=1 by llpx_sn_bind, leq_succ/
+]
+qed-.
+
+lemma llpx_sn_leq_trans: ∀R,L,L1,T,d. llpx_sn R d T L L1 →
+                         ∀L2. L1 ≃[d, ∞] L2 → llpx_sn R d T L L2.
+#R #L #L1 #T #d #H elim H -L -L1 -T -d
+/4 width=5 by llpx_sn_flat, llpx_sn_gref, llpx_sn_skip, llpx_sn_sort, leq_fwd_length, trans_eq/  
+[ #I #L #L1 #K #K1 #V #V1 #d #i #Hdi #HLK #HLK1 #HK1 #HV1 #_ #L2 #HL12
+  elim (leq_ldrop_conf_be … HL12 … HLK1) -L1 // >yminus_Y_inj #K2 #HK12 #HLK2
+  lapply (leq_inv_O_Y … HK12) -HK12 #H destruct /2 width=9 by llpx_sn_lref/
+| /4 width=5 by llpx_sn_free, leq_fwd_length, le_repl_sn_conf_aux, trans_eq/
+| /4 width=1 by llpx_sn_bind, leq_succ/
+]
+qed-.
+
+lemma llpx_sn_leq_repl: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → ∀K1. K1 ≃[d, ∞] L1 → 
+                        ∀K2. L2 ≃[d, ∞] K2 → llpx_sn R d T K1 K2.
+/3 width=4 by llpx_sn_leq_trans, leq_llpx_sn_trans/ qed-.
+
+lemma llpx_sn_bind_repl_SO: ∀R,I1,I2,L1,L2,V1,V2,T. llpx_sn R 0 T (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2) →
+                            ∀J1,J2,W1,W2. llpx_sn R 1 T (L1.ⓑ{J1}W1) (L2.ⓑ{J2}W2).
+#R #I1 #I2 #L1 #L2 #V1 #V2 #T #HT #J1 #J2 #W1 #W2 lapply (llpx_sn_ge R … 1 … HT) -HT
+/3 width=7 by llpx_sn_leq_repl, leq_succ/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_lpx_sn.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_lpx_sn.ma
new file mode 100644 (file)
index 0000000..7486958
--- /dev/null
@@ -0,0 +1,38 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/relocation/lpx_sn_ldrop.ma".
+include "basic_2/substitution/llpx_sn.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* Properties on pointwise extensions ***************************************)
+
+lemma lpx_sn_llpx_sn: ∀R. (∀I,L. reflexive … (R I L)) →
+                      ∀T,L1,L2,d. lpx_sn R L1 L2 → llpx_sn R d T L1 L2.
+#R #HR #T #L1 @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * *
+[ -HR -IH /4 width=2 by lpx_sn_fwd_length, llpx_sn_sort/
+| -HR #i elim (lt_or_ge i (|L1|))
+  [2: -IH /4 width=4 by lpx_sn_fwd_length, llpx_sn_free, le_repl_sn_conf_aux/ ]
+  #Hi #Hn #L2 #d elim (ylt_split i d) 
+  [ -n /3 width=2 by llpx_sn_skip, lpx_sn_fwd_length/ ]
+  #Hdi #HL12 elim (ldrop_O1_lt L1 i) //
+  #I #K1 #V1 #HLK1 elim (lpx_sn_ldrop_conf … HL12 … HLK1) -HL12
+  /4 width=9 by llpx_sn_lref, ldrop_fwd_rfw/
+| -HR -IH /4 width=2 by lpx_sn_fwd_length, llpx_sn_gref/
+| /4 width=1 by llpx_sn_bind, lpx_sn_pair/
+| -HR /3 width=1 by llpx_sn_flat/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_tc.ma b/matita/matita/contribs/lambdadelta/basic_2/substitution/llpx_sn_tc.ma
new file mode 100644 (file)
index 0000000..d22e090
--- /dev/null
@@ -0,0 +1,26 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "basic_2/substitution/llpx_sn_ldrop.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* Properties about transitive closure **************************************)
+
+lemma llpx_sn_TC_pair_dx: ∀R. (∀I,L. reflexive … (R I L)) →
+                          ∀I,L,V1,V2,T. LTC … (R I) L V1 V2 →
+                          LTC … (llpx_sn R 0) T (L.ⓑ{I}V1) (L.ⓑ{I}V2).
+#R #HR #I #L #V1 #V2 #T #H @(TC_star_ind … V2 H) -V2
+/4 width=9 by llpx_sn_bind_repl_O, llpx_sn_refl, step, inj/
+qed.
index 50b02acb9b83a8de2e6c6ef7fd7d567b9b18266e..9f34f5121c6fa675a5dbea3c50c50863ee0ac025 100644 (file)
@@ -214,11 +214,15 @@ table {
              [ "lleq ( ? ⋕[?,?] ? )" "lleq_alt" + "lleq_leq" + "lleq_ldrop" + "lleq_fqus" + "lleq_lleq" * ]
           }
         ]
+        [ { "context-sensitive exclusion from free variables" * } {
+             [ "cofrees ( ? ⊢ ? ~ϵ 𝐅*[?]⦃?⦄ )" "cofrees_lift" * ]
+          }
+        ]
         [ { "contxt-sensitive extended multiple substitution" * } {
              [ "cpys ( ⦃?,?⦄ ⊢ ? ▶*[?,?] ? )" "cpys_alt ( ⦃?,?⦄ ⊢ ? ▶▶*[?,?] ? )" "cpys_lift" + "cpys_cpys" * ]
           }
         ]
-       [ { "iterated structural successor for closures" * } {
+        [ { "iterated structural successor for closures" * } {
              [ "fqus ( ⦃?,?,?⦄ ⊐* ⦃?,?,?⦄ )" "fqus_alt" + "fqus_fqus" * ]
              [ "fqup ( ⦃?,?,?⦄ ⊐+ ⦃?,?,?⦄ )" "fqup_fqup" * ]
           }