]> matita.cs.unibo.it Git - helm.git/commitdiff
- degree-based equivalene for terms
authorFerruccio Guidi <ferruccio.guidi@unibo.it>
Sun, 22 Jan 2017 19:56:34 +0000 (19:56 +0000)
committerFerruccio Guidi <ferruccio.guidi@unibo.it>
Sun, 22 Jan 2017 19:56:34 +0000 (19:56 +0000)
- improved matitadep allows to find more top files in the reference graph
- refactoring and bug fix

880 files changed:
matita/components/binaries/matitadep/matitadep.ml
matita/matita/contribs/lambdadelta/Makefile
matita/matita/contribs/lambdadelta/alpha_1/grammar/item.ma [deleted file]
matita/matita/contribs/lambdadelta/alpha_1/grammar/term.ma [deleted file]
matita/matita/contribs/lambdadelta/alpha_1/grammar/term_append.ma [deleted file]
matita/matita/contribs/lambdadelta/alpha_1/syntax/item.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/alpha_1/syntax/term.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/alpha_1/syntax/term_append.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/apps_2/functional/rtm.ma
matita/matita/contribs/lambdadelta/basic_2/etc/append/cir_append.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cix_append.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cl_shift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cpy2.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cpys0.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/cpys2.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/crr_append.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/crx_append.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/append/lpys0.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpx_cpzs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_cpye.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpys_cny.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpzs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/lleq_cpye.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpx_cpye.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpxs_cpye.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/pdeltaconvstar_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubsteval_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstevalalt_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstnormal_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofreestar_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpcs/cpcs_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpes.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cnf_cif.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lbotr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_px.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_top.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_lfpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfprs_ltprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr_lbotr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tps.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ltprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tps.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tps.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_dx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sta_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_tpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_tprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_tps.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_lpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lrsubeq_2.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby_lsuby.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubstsnstar_3.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubststar_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/cpx_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/cpx_cpys2.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/cpxs_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/lpx_cpys.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/lsuby.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/csup/csup.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/csup/csup_csup.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/csup/csups_csups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpcs_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpr_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/cprs_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_tpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/delift/tpr_delift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/etc/cpr_conj.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/etc/ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbc_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa_fpa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_fpas.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_vector.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp_cr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajust_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajuststar_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc_fleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbg.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbs_fpbc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/lazybtpredproper_8.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_bteq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/btpredsn_8.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpb.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbs_conj.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn_fpn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns_fpns.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fqu.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpn/lazyeq_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cfpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc_fpc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_cpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_fpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_cprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_fprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lenv_px_bi.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_fpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfprs_fprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsup.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp_frsupp.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups_frsups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/frsup/ssta_frsups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsup.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsup.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsups.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_cr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/coeq_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq_lcoeq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/ldrop_lcoeq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lazyeqalt_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ext.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_fqus.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/lleq_lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lazynegatedeq_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lazynegatedeqalt_4.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_ext.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lpxs_llneq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cpcs_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_cprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsn_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsnstar_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_llpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_cprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_llprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpx_sn_llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/cpxs_llpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpxs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/fpbs_lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsn_7.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsnstar_7.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysn_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysnalt_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_cpxs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_llpxs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_csx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpxs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/llpx_sn_tc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/lpx_conj.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc_lfpc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_fpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpr_llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpx_llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lleq.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_alt_rec.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_lpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_tc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_lpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_tc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/ssta_llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubn/lsubn_lsubn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/aaa_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpcs_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cprs_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/dxprs_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_cpqs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_lpqs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpr_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lprs_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_cpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_etc.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_lsubr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/snv_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/ssta_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/sstas_lpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_nta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_nta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_sta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_thin.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_ldrop.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_snta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_snta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_thin.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_cpcs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_da_lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lpx.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lstas_lpr.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/snv_preserve.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_sta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_alt.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_da.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lstas.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_llpx_sn.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_sta.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictype_5.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictypestaralt_6.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/tshf/chnf.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/tshf/cpr_tshf.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/tshf/tshf.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lsubss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_aaa.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_cprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lift.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lsubss.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_xprs.etc [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cir_append.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cix_append.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cl_shift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpy2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpys0.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpys2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/crr_append.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/crx_append.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpys0.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpx_cpzs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_cpye.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpys_cny.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpzs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lleq_cpye.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpx_cpye.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpxs_cpye.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/pdeltaconvstar_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubsteval_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstevalalt_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstnormal_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofreestar_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpcs/cpcs_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpes.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cnf_cif.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lbotr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_px.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_top.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_lfpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfprs_ltprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr_lbotr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tps.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ltprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tps.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tps.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_dx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sta_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_tpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_tprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_tps.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_lpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lrsubeq_2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby_lsuby.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubstsnstar_3.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubststar_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/cpx_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/cpx_cpys2.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/cpxs_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/lpx_cpys.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/lsuby.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csup.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csup_csup.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csups_csups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpcs_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpr_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cprs_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_tpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/tpr_delift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/cpr_conj.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbc_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa_fpa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_fpas.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_vector.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp_cr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajust_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajuststar_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc_fleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbg.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbs_fpbc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/lazybtpredproper_8.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_bteq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/btpredsn_8.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpb.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbs_conj.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn_fpn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns_fpns.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fqu.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/lazyeq_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cfpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc_fpc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_cpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_fpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_cprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_fprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lenv_px_bi.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_fpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfprs_fprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsup.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp_frsupp.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups_frsups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/ssta_frsups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsup.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsup.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsups.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_cr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/coeq_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq_lcoeq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/ldrop_lcoeq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lazyeqalt_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq_ext.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq_fqus.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lleq_lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lazynegatedeq_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lazynegatedeqalt_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_ext.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lpxs_llneq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cpcs_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_cprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsn_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsnstar_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_llpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_cprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_llprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpx_sn_llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/cpxs_llpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpxs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/fpbs_lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsn_7.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsnstar_7.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysn_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysnalt_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_cpxs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_llpxs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_csx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpxs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/llpx_sn_tc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/lpx_conj.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc_lfpc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_fpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpr_llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpx_llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lleq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_alt_rec.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_lpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_tc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_lpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_tc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/ssta_llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubn/lsubn_lsubn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/aaa_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpcs_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cprs_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/dxprs_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_cpqs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_lpqs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpr_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lprs_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_cpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_etc.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_lsubr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/snv_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/ssta_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/sstas_lpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_nta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_nta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_sta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_thin.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_ldrop.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_snta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_snta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_thin.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_cpcs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_da_lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lpx.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lstas_lpr.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv_preserve.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_sta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_alt.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_da.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lstas.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_llpx_sn.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_sta.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictype_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictypestaralt_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/chnf.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/cpr_tshf.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/tshf.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lsubss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_aaa.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_cprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lift.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lsubss.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_xprs.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq_ceq.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/etc_new/lazyor_5.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/lrsubeq_4.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/psubst_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststar_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststaralt_6.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/grammar/aarity.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/append.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/append_length.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/ceq.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/ceq_ceq.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/cl_restricted_weight.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/cl_weight.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/genv.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/item.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/lenv.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_length.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_weight.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/term.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/term_simple.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/term_vector.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/term_weight.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/tsts.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_tsts.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_vector.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/names.txt
matita/matita/contribs/lambdadelta/basic_2/notation/constructors/dxabbr_2.ma
matita/matita/contribs/lambdadelta/basic_2/notation/constructors/dxabst_2.ma
matita/matita/contribs/lambdadelta/basic_2/notation/constructors/dxbind2_3.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btpred_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btpredalt_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btpredproper_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btpredstar_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btpredstaralt_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btsn_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/btsnalt_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/cosn_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/dpconvstar_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/dpredstar_7.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazybtpredstarproper_8.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyeq_4.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyor_5.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lrsubeq_4.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/lrsubeqv_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/nativevalid_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/nativevalid_6.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/predeval_6.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/predsnstar_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/predstar_6.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubst_6.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststar_6.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststaralt_6.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/notation/relations/sn_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/sn_6.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/snalt_5.ma
matita/matita/contribs/lambdadelta/basic_2/notation/relations/snalt_6.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/drops_length.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/drops_lreq.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/drops_weight.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lexs.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lexs_length.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lifts.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lifts_simple.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lifts_vector.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lifts_weight.ma
matita/matita/contribs/lambdadelta/basic_2/relocation/lreq.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpxs_tsts.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpxs_tsts_vector.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/csx_lpx.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/csx_vector.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/gcp.ma
matita/matita/contribs/lambdadelta/basic_2/rt_computation/gcp_cr.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpg.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpg_simple.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpm.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpm_drops.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpr_drops.ma
matita/matita/contribs/lambdadelta/basic_2/s_transition/fqu.ma
matita/matita/contribs/lambdadelta/basic_2/s_transition/fqu_length.ma
matita/matita/contribs/lambdadelta/basic_2/s_transition/fqu_weight.ma
matita/matita/contribs/lambdadelta/basic_2/static/aaa.ma
matita/matita/contribs/lambdadelta/basic_2/static/frees.ma
matita/matita/contribs/lambdadelta/basic_2/static/lfxs.ma
matita/matita/contribs/lambdadelta/basic_2/static/lsubr.ma
matita/matita/contribs/lambdadelta/basic_2/static/lsubr_length.ma
matita/matita/contribs/lambdadelta/basic_2/static/sd.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/static/sh.ma [deleted file]
matita/matita/contribs/lambdadelta/basic_2/syntax/aarity.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/append.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/append_length.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/cl_restricted_weight.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/cl_weight.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/deq.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/deq_deq.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/genv.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/item.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/item_sd.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/item_sh.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/lenv.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_length.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_weight.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/term.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/term_simple.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/term_vector.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/term_weight.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/tsts.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_tsts.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_vector.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/web/basic_2_src.tbl
matita/matita/contribs/lambdadelta/replace.sh

index 00a2f926857cee62ee1d6062f1a0a01d7a6528bb..054f90f4a64bac89921c71c81ba7c4bb7c3bc43b 100644 (file)
@@ -14,10 +14,12 @@ let rec purge dname vdeps = match vdeps with
    | hd :: tl -> if hd = dname then tl else hd :: purge dname tl 
 
 let add fname =
+   if fname = "" then () else
    if Hashtbl.mem graph fname then () else
    Hashtbl.add graph fname {ddeps = []; rdeps = None}
 
 let add_ddep fname dname =
+   if dname = "" then () else
    let file = Hashtbl.find graph fname in
    Hashtbl.replace graph fname {file with ddeps = dname :: file.ddeps} 
 
@@ -104,7 +106,7 @@ let _ =
       if !show_top then top ();
       if !show_leaf then leaf ()   
    in
-   let help   = "" in
+   let help   = "matitadep [-clt | -d <int> ] < <file>" in
    let help_c = " Print the redundant and looping arcs of the dependences graph" in
    let help_d = "<flags>  Set these debug options" in
    let help_l = " Print the leaf nodes of the dependences graph" in
index 9de41db0c3f3f4fad5cc8c03a7e726c538f3ad24..cd6bcea179351ebe5bdb3b7229d44ece14bc6ad1 100644 (file)
@@ -91,9 +91,12 @@ orig: $(ORIGS)
 
 # dep input ##################################################################
 
-$(DEP_INPUT): $(MAS)
+$(DEP_INPUT): LINE = $(MAS:%=%:include \"\".)
+
+$(DEP_INPUT): $(MAS) Makefile
        @echo "  GREP include"
        $(H)grep "include \"" $^ > $(DEP_INPUT)
+       $(H)echo "$(LINE)" | sed -e 's/\"\. /\"\.\n/g' >> $(DEP_INPUT) 
 
 # dep ########################################################################
 
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/grammar/item.ma b/matita/matita/contribs/lambdadelta/alpha_1/grammar/item.ma
deleted file mode 100644 (file)
index 01a7672..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* THE FORMAL SYSTEM α: MATITA SOURCE FILES
- * Initial invocation : - Patience on me to gain peace and perfection! -
- * Developed since    : 2014 July 25
- *)
-
-include "ground_2/lib/bool.ma".
-include "ground_2/lib/arith.ma".
-
-(* ITEMS ********************************************************************)
-
-(* unary items *)
-inductive item1: Type[0] ≝
-   | Char: nat → item1 (* character: starting at 0 *)
-   | LRef: nat → item1 (* reference by index: starting at 0 *)
-   | GRef: nat → item1 (* reference by position: starting at 0 *)
-   | Decl:       item1 (* global abstraction *)
-.
-
-(* binary items *)
-inductive item2: Type[0] ≝
-   | Abst:        item2 (* local abstraction *)
-   | Abbr: bool → item2 (* local (Ⓣ) or global (Ⓕ) abbreviation *)
-   | Proj: bool → item2 (* local (Ⓣ) or global (Ⓕ) projection *)
-.
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/grammar/term.ma b/matita/matita/contribs/lambdadelta/alpha_1/grammar/term.ma
deleted file mode 100644 (file)
index 9562d4c..0000000
+++ /dev/null
@@ -1,80 +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/constructors/snitem2_3.ma".
-include "basic_2/notation/constructors/star_0.ma".
-include "basic_2/notation/constructors/snabstpos_2.ma".
-include "basic_2/notation/constructors/snabbr_3.ma".
-include "basic_2/notation/constructors/snabbrpos_2.ma".
-include "basic_2/notation/constructors/snabbrneg_2.ma".
-include "alpha_1/notation/constructors/snitem1_2.ma".
-include "alpha_1/notation/constructors/snstar_2.ma".
-include "alpha_1/notation/constructors/snlref_2.ma".
-include "alpha_1/notation/constructors/sngref_2.ma".
-include "alpha_1/notation/constructors/snabstneg_1.ma".
-include "alpha_1/notation/constructors/snproj_3.ma".
-include "alpha_1/notation/constructors/snprojpos_2.ma".
-include "alpha_1/notation/constructors/snprojneg_2.ma".
-include "alpha_1/grammar/item.ma".
-
-(* TERMS ********************************************************************)
-
-(* terms *)
-inductive term: Type[0] ≝
-  | TAtom:         term                (* atomic item construction *)
-  | TUnit: item1 → term → term         (* unary item construction *)
-  | TPair: item2 → term → term → term  (* binary item construction *)
-.
-
-interpretation "top (term)"
-   'Star = TAtom.
-
-interpretation "term construction (unary)"
-   'SnItem1 I T = (TUnit I T).
-
-interpretation "term construction (binary)"
-   'SnItem2 I T1 T2 = (TPair I T1 T2).
-
-interpretation "character (term)"
-   'SnStar k T = (TUnit (Char k) T).
-
-interpretation "local reference (term)"
-   'SnLRef i T = (TUnit (LRef i) T).
-
-interpretation "global reference (term)"
-   'SnGRef p T = (TUnit (GRef p) T).
-
-interpretation "negative abbreviation (term)"
-   'SnAbbrNeg T = (TUnit Decl T).
-
-interpretation "positive abstraction (term)"
-   'SnAbstPos T1 T2 = (TPair Abst T1 T2).
-
-interpretation "abbreviation (term)"
-   'SnAbbr a T1 T2 = (TPair (Abbr a) T1 T2).
-
-interpretation "positive abbreviation (term)"
-   'SnAbbrPos T1 T2 = (TPair (Abbr true) T1 T2).
-
-interpretation "negative abbreviation (term)"
-   'SnAbbrNeg T1 T2 = (TPair (Abbr false) T1 T2).
-
-interpretation "projection (term)"
-   'SnProj a T1 T2 = (TPair (Proj a) T1 T2).
-
-interpretation "positive projection (term)"
-   'SnProjPos T1 T2 = (TPair (Proj true) T1 T2).
-
-interpretation "negative projection (term)"
-   'SnProjNeg T1 T2 = (TPair (Proj false) T1 T2).
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/grammar/term_append.ma b/matita/matita/contribs/lambdadelta/alpha_1/grammar/term_append.ma
deleted file mode 100644 (file)
index 98ce3ba..0000000
+++ /dev/null
@@ -1,25 +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 "alpha_1/grammar/term.ma".
-
-(* TERMS ********************************************************************)
-
-let rec tappend T U on T ≝ match T with
-[ TAtom       ⇒ U
-| TUnit I T   ⇒ ①{I}.(tappend T U)
-| TPair I V T ⇒ ②{I}V.(tappend T U)
-].
-
-interpretation "append (term)" 'Append T U = (tappend T U).
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/syntax/item.ma b/matita/matita/contribs/lambdadelta/alpha_1/syntax/item.ma
new file mode 100644 (file)
index 0000000..01a7672
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* THE FORMAL SYSTEM α: MATITA SOURCE FILES
+ * Initial invocation : - Patience on me to gain peace and perfection! -
+ * Developed since    : 2014 July 25
+ *)
+
+include "ground_2/lib/bool.ma".
+include "ground_2/lib/arith.ma".
+
+(* ITEMS ********************************************************************)
+
+(* unary items *)
+inductive item1: Type[0] ≝
+   | Char: nat → item1 (* character: starting at 0 *)
+   | LRef: nat → item1 (* reference by index: starting at 0 *)
+   | GRef: nat → item1 (* reference by position: starting at 0 *)
+   | Decl:       item1 (* global abstraction *)
+.
+
+(* binary items *)
+inductive item2: Type[0] ≝
+   | Abst:        item2 (* local abstraction *)
+   | Abbr: bool → item2 (* local (Ⓣ) or global (Ⓕ) abbreviation *)
+   | Proj: bool → item2 (* local (Ⓣ) or global (Ⓕ) projection *)
+.
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/syntax/term.ma b/matita/matita/contribs/lambdadelta/alpha_1/syntax/term.ma
new file mode 100644 (file)
index 0000000..674e618
--- /dev/null
@@ -0,0 +1,80 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/constructors/snitem2_3.ma".
+include "basic_2/notation/constructors/star_0.ma".
+include "basic_2/notation/constructors/snabstpos_2.ma".
+include "basic_2/notation/constructors/snabbr_3.ma".
+include "basic_2/notation/constructors/snabbrpos_2.ma".
+include "basic_2/notation/constructors/snabbrneg_2.ma".
+include "alpha_1/notation/constructors/snitem1_2.ma".
+include "alpha_1/notation/constructors/snstar_2.ma".
+include "alpha_1/notation/constructors/snlref_2.ma".
+include "alpha_1/notation/constructors/sngref_2.ma".
+include "alpha_1/notation/constructors/snabstneg_1.ma".
+include "alpha_1/notation/constructors/snproj_3.ma".
+include "alpha_1/notation/constructors/snprojpos_2.ma".
+include "alpha_1/notation/constructors/snprojneg_2.ma".
+include "alpha_1/syntax/item.ma".
+
+(* TERMS ********************************************************************)
+
+(* terms *)
+inductive term: Type[0] ≝
+  | TAtom:         term                (* atomic item construction *)
+  | TUnit: item1 → term → term         (* unary item construction *)
+  | TPair: item2 → term → term → term  (* binary item construction *)
+.
+
+interpretation "top (term)"
+   'Star = TAtom.
+
+interpretation "term construction (unary)"
+   'SnItem1 I T = (TUnit I T).
+
+interpretation "term construction (binary)"
+   'SnItem2 I T1 T2 = (TPair I T1 T2).
+
+interpretation "character (term)"
+   'SnStar k T = (TUnit (Char k) T).
+
+interpretation "local reference (term)"
+   'SnLRef i T = (TUnit (LRef i) T).
+
+interpretation "global reference (term)"
+   'SnGRef p T = (TUnit (GRef p) T).
+
+interpretation "negative abbreviation (term)"
+   'SnAbbrNeg T = (TUnit Decl T).
+
+interpretation "positive abstraction (term)"
+   'SnAbstPos T1 T2 = (TPair Abst T1 T2).
+
+interpretation "abbreviation (term)"
+   'SnAbbr a T1 T2 = (TPair (Abbr a) T1 T2).
+
+interpretation "positive abbreviation (term)"
+   'SnAbbrPos T1 T2 = (TPair (Abbr true) T1 T2).
+
+interpretation "negative abbreviation (term)"
+   'SnAbbrNeg T1 T2 = (TPair (Abbr false) T1 T2).
+
+interpretation "projection (term)"
+   'SnProj a T1 T2 = (TPair (Proj a) T1 T2).
+
+interpretation "positive projection (term)"
+   'SnProjPos T1 T2 = (TPair (Proj true) T1 T2).
+
+interpretation "negative projection (term)"
+   'SnProjNeg T1 T2 = (TPair (Proj false) T1 T2).
diff --git a/matita/matita/contribs/lambdadelta/alpha_1/syntax/term_append.ma b/matita/matita/contribs/lambdadelta/alpha_1/syntax/term_append.ma
new file mode 100644 (file)
index 0000000..4ea795a
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "alpha_1/syntax/term.ma".
+
+(* TERMS ********************************************************************)
+
+let rec tappend T U on T ≝ match T with
+[ TAtom       ⇒ U
+| TUnit I T   ⇒ ①{I}.(tappend T U)
+| TPair I V T ⇒ ②{I}V.(tappend T U)
+].
+
+interpretation "append (term)" 'Append T U = (tappend T U).
index 2e92ea0cca64f3d207b5610cacd8f2bb40a046f2..66b48129042f4055a37eacf3d13b55f248520c9b 100644 (file)
@@ -12,8 +12,8 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_vector.ma".
-include "basic_2/grammar/genv.ma".
+include "basic_2/syntax/term_vector.ma".
+include "basic_2/syntax/genv.ma".
 include "apps_2/functional/notation.ma".
 
 (* REDUCTION AND TYPE MACHINE ***********************************************)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cir_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cir_append.etc
deleted file mode 100644 (file)
index efd097f..0000000
+++ /dev/null
@@ -1,34 +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/crr_append.ma".
-include "basic_2/reduction/cir.ma".
-
-(* IRREDUCIBLE TERMS FOR CONTEXT-SENSITIVE REDUCTION ************************)
-
-(* Advanved properties ******************************************************)
-
-lemma cir_labst_last: ∀G,L,T,W. ⦃G, L⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, ⋆.ⓛW @@ L⦄ ⊢ ➡ 𝐈⦃T⦄.
-/3 width=2 by crr_inv_labst_last/ qed.
-
-lemma cir_tif: ∀G,T,W. ⦃G, ⋆⦄ ⊢ ➡ 𝐈⦃T⦄ → ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐈⦃T⦄.
-/3 width=2 by crr_inv_trr/ qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cir_inv_append_sn: ∀G,L,K,T. ⦃G, K @@ L⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, L⦄ ⊢ ➡ 𝐈⦃T⦄.
-/3 width=1/ qed-.
-
-lemma cir_inv_tir: ∀G,T,W. ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡ 𝐈⦃T⦄.
-/3 width=1/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cix_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cix_append.etc
deleted file mode 100644 (file)
index 7b5522e..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/reduction/crx_append.ma".
-include "basic_2/reduction/cix.ma".
-
-(* IRREDUCIBLE TERMS FOR CONTEXT-SENSITIVE EXTENDED REDUCTION ***************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cix_inv_append_sn: ∀h,g,G,L,K,T. ⦃G, K @@ L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄  → ⦃G, L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄.
-/3 width=1 by crx_append_sn/ qed-.
-
-lemma cix_inv_tix: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡[h, g] 𝐈⦃T⦄.
-/3 width=1 by trx_crx/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cl_shift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cl_shift.etc
deleted file mode 100644 (file)
index 5fdab71..0000000
+++ /dev/null
@@ -1,45 +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/grammar/lenv_append.ma".
-
-(* SHIFT OF A CLOSURE *******************************************************)
-
-let rec shift L T on L ≝ match L with
-[ LAtom       ⇒ T
-| LPair L I V ⇒ shift L (-ⓑ{I} V. T)
-].
-
-interpretation "shift (closure)" 'Append L T = (shift L T).
-
-(* Basic properties *********************************************************)
-
-lemma shift_append_assoc: ∀L,K. ∀T:term. (L @@ K) @@ T = L @@ K @@ T.
-#L #K elim K -K // normalize //
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma shift_inj: ∀L1,L2. ∀T1,T2:term. L1 @@ T1 = L2 @@ T2 → |L1| = |L2| →
-                 L1 = L2 ∧ T1 = T2.
-#L1 elim L1 -L1
-[ * normalize /2 width=1/
-  #L2 #I2 #V2 #T1 #T2 #_ <plus_n_Sm #H destruct
-| #L1 #H1 #V1 #IH * normalize
-  [ #T1 #T2 #_ <plus_n_Sm #H destruct
-  | #L2 #I2 #V2 #T1 #T2 #H1 #H2
-    elim (IH … H1) -IH -H1 /2 width=1/ -H2 #H1 #H2 destruct /2 width=1/
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpr.etc
deleted file mode 100644 (file)
index 71d8023..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-include "basic_2/grammar/cl_shift.ma".
-include "basic_2/relocation/ldrop_append.ma".
-
-lemma cpr_append: ∀G. l_appendable_sn … (cpr G).
-#G #K #T1 #T2 #H elim H -G -K -T1 -T2
-/2 width=3 by cpr_bind, cpr_flat, cpr_zeta, cpr_tau, cpr_beta, cpr_theta/
-#G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
-lapply (ldrop_fwd_length_lt2 … HK0) #H
-@(cpr_delta … (L@@K0) V1 … HVW2) //
-@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
-qed.
-
-lemma cpr_fwd_shift1: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ➡ T →
-                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#G #L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #L #T1 #T #HT1
-  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #L #T1 #X
-  >shift_append_assoc normalize #H
-  elim (cpr_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 ] /2 width=3 by trans_eq/ (**) (* explicit constructor *)
-  | #T #_ #_ #H destruct
-  ]
-]
-qed-.
-
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpx.etc
deleted file mode 100644 (file)
index 5f8bf52..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-lemma cpx_append: ∀h,g,G. l_appendable_sn … (cpx h g G).
-#h #g #G #K #T1 #T2 #H elim H -G -K -T1 -T2
-/2 width=3 by cpx_sort, cpx_bind, cpx_flat, cpx_zeta, cpx_tau, cpx_ti, cpx_beta, cpx_theta/
-#I #G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
-lapply (ldrop_fwd_length_lt2 … HK0) #H
-@(cpx_delta … I … (L@@K0) V1 … HVW2) // 
-@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
-qed.
-
-lemma cpx_fwd_shift1: ∀h,g,G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ➡[h, g] T →
-                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#h #g #G #L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #L #T1 #T #HT1
-  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #L #T1 #X
-  >shift_append_assoc normalize #H
-  elim (cpx_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 ] /2 width=3 by refl, trans_eq/ (**) (* explicit constructor *)
-  | #T #_ #_ #H destruct
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpy2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpy2.etc
deleted file mode 100644 (file)
index e941c96..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-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/append/cpys0.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpys0.etc
deleted file mode 100644 (file)
index fa9bcf6..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-include "basic_2/grammar/cl_shift.ma".
-include "basic_2/relocation/ldrop_append.ma".
-
-lemma cpys_append: ∀G. l_appendable_sn … (cpys G).
-#G #K #T1 #T2 #H elim H -G -K -T1 -T2
-/2 width=3 by cpys_bind, cpys_flat/
-#I #G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
-lapply (ldrop_fwd_length_lt2 … HK0) #H
-@(cpys_delta … I … (L@@K0) V1 … HVW2) // 
-@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
-qed.
-
-lemma cpys_fwd_shift1: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ▶*× T →
-                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#G #L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #L #T1 #T #HT1 @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #L #T1 #X >shift_append_assoc normalize
-  #H elim (cpys_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 ] /2 width=3 by trans_eq/ (**) (* explicit constructor *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpys2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/cpys2.etc
deleted file mode 100644 (file)
index 22f74d0..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-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/append/crr_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/crr_append.etc
deleted file mode 100644 (file)
index dbf794d..0000000
+++ /dev/null
@@ -1,56 +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_append.ma".
-include "basic_2/reduction/crr.ma".
-
-(* REDUCIBLE TERMS FOR CONTEXT-SENSITIVE REDUCTION **************************)
-
-(* Advanved properties ******************************************************)
-
-lemma crr_append_sn: ∀G,L,K,T. ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, K @@ L⦄ ⊢ ➡ 𝐑⦃T⦄.
-#G #L #K0 #T #H elim H -L -T /2 width=1/
-#L #K #V #i #HLK
-lapply (ldrop_fwd_length_lt2 … HLK) #Hi
-lapply (ldrop_O1_append_sn_le … HLK … K0) -HLK /2 width=2/ -Hi /2 width=3/
-qed.
-
-lemma trr_crr: ∀G,L,T. ⦃G, ⋆⦄ ⊢ ➡ 𝐑⦃T⦄ → ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄.
-#G #L #T #H lapply (crr_append_sn … H) //
-qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-fact crr_inv_labst_last_aux: ∀G,L1,T,W. ⦃G, L1⦄ ⊢ ➡ 𝐑⦃T⦄  →
-                             ∀L2. L1 = ⋆.ⓛW @@ L2 → ⦃G, L2⦄ ⊢ ➡ 𝐑⦃T⦄.
-#G #L1 #T #W #H elim H -L1 -T /2 width=1/ /3 width=1/
-[ #L1 #K1 #V1 #i #HLK1 #L2 #H destruct
-  lapply (ldrop_fwd_length_lt2 … HLK1)
-  >append_length >commutative_plus normalize in ⊢ (??% → ?); #H
-  elim (le_to_or_lt_eq i (|L2|)) /2 width=1/ -H #Hi destruct
-  [ elim (ldrop_O1_lt … Hi) #I2 #K2 #V2 #HLK2
-    lapply (ldrop_O1_inv_append1_le … HLK1 … HLK2) -HLK1 /2 width=2/ -Hi
-    normalize #H destruct /2 width=3/
-  | lapply (ldrop_O1_inv_append1_ge … HLK1 ?) -HLK1 // <minus_n_n #H
-    lapply (ldrop_inv_O2 … H) -H #H destruct
-  ]
-| #a #I #L1 #V #T #HI #_ #IHT #L2 #H destruct /3 width=1/
-]
-qed.
-
-lemma crr_inv_labst_last: ∀G,L,T,W. ⦃G, ⋆.ⓛW @@ L⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄.
-/2 width=4/ qed-.
-
-lemma crr_inv_trr: ∀G,T,W. ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡ 𝐑⦃T⦄.
-/2 width=4/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/crx_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/crx_append.etc
deleted file mode 100644 (file)
index 56667b2..0000000
+++ /dev/null
@@ -1,32 +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_append.ma".
-include "basic_2/reduction/crx.ma".
-
-(* REDUCIBLE TERMS FOR CONTEXT-SENSITIVE EXTENDED REDUCTION *****************)
-
-(* Advanved properties ******************************************************)
-
-lemma crx_append_sn: ∀h,g,G,L,K,T. ⦃G, L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄  → ⦃G, K @@ L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄.
-#h #g #G #L #K0 #T #H elim H -L -T
-/2 width=2 by crx_sort, crx_appl_sn, crx_appl_dx, crx_ri2, crx_ib2_sn, crx_ib2_dx, crx_beta, crx_theta/
-#I #L #K #V #i #HLK
-lapply (ldrop_fwd_length_lt2 … HLK) #Hi
-lapply (ldrop_O1_append_sn_le … HLK … K0) -HLK /2 width=4 by crx_delta, lt_to_le/
-qed.
-
-lemma trx_crx: ∀h,g,G,L,T. ⦃G, ⋆⦄ ⊢ ➡[h, g] 𝐑⦃T⦄ → ⦃G, L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄.
-#h #g #G #L #T #H lapply (crx_append_sn … H) //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpr.etc
deleted file mode 100644 (file)
index 5b55011..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-lemma lpr_append: ∀G,K1,K2. ⦃G, K1⦄ ⊢ ➡ K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                  ⦃G, L1 @@ K1⦄ ⊢ ➡ L2 @@ K2.
-/3 width=1 by lpx_sn_append, cpr_append/ qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpr_fwd_append1: ∀G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ➡ L →
-                       ∃∃K2,L2. ⦃G, K1⦄ ⊢ ➡ K2 & L = K2 @@ L2.
-/2 width=2 by lpx_sn_fwd_append1/ qed-.
-
-lemma lpr_fwd_append2: ∀G,L,K2,L2. ⦃G, L⦄ ⊢ ➡ K2 @@ L2 →
-                       ∃∃K1,L1. ⦃G, K1⦄ ⊢ ➡ K2 & L = K1 @@ L1.
-/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx.etc
deleted file mode 100644 (file)
index a1976d5..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-lemma lpx_append: ∀h,g,G,K1,K2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
-                  ⦃G, L1 @@ K1⦄ ⊢ ➡[h, g] L2 @@ K2.
-/3 width=1 by lpx_sn_append, cpx_append/ qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpx_fwd_append1: ∀h,g,G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ➡[h, g] L →
-                       ∃∃K2,L2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & L = K2 @@ L2.
-/2 width=2 by lpx_sn_fwd_append1/ qed-.
-
-lemma lpx_fwd_append2: ∀h,g,G,L,K2,L2. ⦃G, L⦄ ⊢ ➡[h, g] K2 @@ L2 →
-                       ∃∃K1,L1. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & L = K1 @@ L1.
-/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpx_sn.etc
deleted file mode 100644 (file)
index d399e0a..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-lemma lpx_sn_append: ∀R. l_appendable_sn R →
-                     ∀K1,K2. lpx_sn R K1 K2 → ∀L1,L2. lpx_sn R L1 L2 →
-                     lpx_sn R (L1 @@ K1) (L2 @@ K2).
-#R #HR #K1 #K2 #H elim H -K1 -K2 /3 width=1 by lpx_sn_pair/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpx_sn_fwd_append1: ∀R,L1,K1,L. lpx_sn R (K1 @@ L1) L →
-                          ∃∃K2,L2. lpx_sn R K1 K2 &  L = K2 @@ L2.
-#R #L1 elim L1 -L1
-[ #K1 #K2 #HK12
-  @(ex2_2_intro … K2 (⋆)) // (* explicit constructor, /2 width=4/ does not work *)
-| #L1 #I #V1 #IH #K1 #X #H
-  elim (lpx_sn_inv_pair1 … H) -H #L #V2 #H1 #HV12 #H destruct
-  elim (IH … H1) -IH -H1 #K2 #L2 #HK12 #H destruct
-  @(ex2_2_intro … (L2.ⓑ{I}V2) HK12) // (* explicit constructor, /2 width=4/ does not work *)
-]
-qed-.
-
-lemma lpx_sn_fwd_append2: ∀R,L2,K2,L. lpx_sn R L (K2 @@ L2) →
-                          ∃∃K1,L1. lpx_sn R K1 K2 & L = K1 @@ L1.
-#R #L2 elim L2 -L2
-[ #K2 #K1 #HK12
-  @(ex2_2_intro … K1 (⋆)) // (**) (* explicit constructor, /2 width=4/ does not work *)
-| #L2 #I #V2 #IH #K2 #X #H
-  elim (lpx_sn_inv_pair2 … H) -H #L #V1 #H1 #HV12 #H destruct
-  elim (IH … H1) -IH -H1 #K1 #L1 #HK12 #H destruct
-  @(ex2_2_intro … (L1.ⓑ{I}V1) HK12) // (* explicit constructor, /2 width=4/ does not work *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpys0.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/append/lpys0.etc
deleted file mode 100644 (file)
index cb3dfd0..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-lemma lpys_append: ∀G,K1,K2. ⦃G, K1⦄ ⊢ ▶*× K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ▶*× L2 →
-                   ⦃G, L1 @@ K1⦄ ⊢ ▶*× L2 @@ K2.
-/3 width=1 by lpx_sn_append, cpys_append/ qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpys_fwd_append1: ∀G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ▶*× L →
-                        ∃∃K2,L2. ⦃G, K1⦄ ⊢ ▶*× K2 & L = K2 @@ L2.
-/2 width=2 by lpx_sn_fwd_append1/ qed-.
-
-lemma lpys_fwd_append2: ∀G,L,K2,L2. ⦃G, L⦄ ⊢ ▶*× K2 @@ L2 →
-                        ∃∃K1,L1. ⦃G, K1⦄ ⊢ ▶*× K2 & L = K1 @@ L1.
-/2 width=2 by lpx_sn_fwd_append2/ qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma cpys_fwd_shift1_ext: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ▶*× T →
-                           ∃∃L2,T2. ⦃G, L @@ L1⦄ ⊢ ▶*× L @@ L2 & ⦃G, L @@ L1⦄ ⊢ T1 ▶*× T2 &
-                                    T = L2 @@ T2.
-#G #L1 @(lenv_ind_dx … L1) -L1
-[ #L #T1 #T #HT1 @ex3_2_intro
-  [3: // |4,5: // |1,2: skip ] (**) (* auto does not work *)
-| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
-  elim (cpys_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
-  lapply (lpys_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1 by lpys_append, lpys_pair/ #HL12
-  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3 by trans_eq/ | skip ] <append_assoc // (**) (* explicit constructor *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny.etc
deleted file mode 100644 (file)
index 81919dc..0000000
+++ /dev/null
@@ -1,114 +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/psubstnormal_5.ma".
-include "basic_2/relocation/cpy.ma".
-
-(* NORMAL TERMS FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION *****************)
-
-definition cny: ∀d,e. relation3 genv lenv term ≝
-                λd,e,G,L. NF … (cpy d e G L) (eq …).
-
-interpretation
-   "normality for context-sensitive extended substitution (term)"
-   'PSubstNormal G L T d e = (cny d e G L T).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma cny_inv_lref: ∀G,L,d,e,i. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄ →
-                    ∨∨ yinj i < d | d + e ≤ yinj i | |L| ≤ i.
-#G #L #d #e #i #H elim (ylt_split i d) /2 width=1 by or3_intro0/
-#Hdi elim (ylt_split i (d+e)) /2 width=1 by or3_intro1/
-#Hide elim (lt_or_ge i (|L|)) /2 width=1 by or3_intro2/
-#Hi elim (ldrop_O1_lt L i) //
-#I #K #V #HLK elim (lift_total V 0 (i+1))
-#W #HVW lapply (H W ?) -H /2 width=5 by cpy_subst/ -HLK
-#H destruct elim (lift_inv_lref2_be … HVW) -L -d -e //
-qed-.
-
-lemma cny_inv_bind: ∀a,I,G,L,V,T,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓑ{a,I}V.T⦄ →
-                    ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ ∧ ⦃G, L.ⓑ{I}V⦄ ⊢ ▶[⫯d, e] 𝐍⦃T⦄.
-#a #I #G #L #V1 #T1 #d #e #HVT1 @conj
-[ #V2 #HV2 lapply (HVT1 (ⓑ{a,I}V2.T1) ?) -HVT1
-| #T2 #HT2 lapply (HVT1 (ⓑ{a,I}V1.T2) ?) -HVT1
-] 
-/2 width=1 by cpy_bind/ #H destruct //
-qed-.
-
-lemma cny_inv_flat: ∀I,G,L,V,T,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓕ{I}V.T⦄ →
-                    ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ ∧ ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T⦄.
-#I #G #L #V1 #T1 #d #e #HVT1 @conj
-[ #V2 #HV2 lapply (HVT1 (ⓕ{I}V2.T1) ?) -HVT1
-| #T2 #HT2 lapply (HVT1 (ⓕ{I}V1.T2) ?) -HVT1
-] 
-/2 width=1 by cpy_flat/ #H destruct //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lsuby_cny_conf: ∀G,d,e.
-                      ∀L1,T. ⦃G, L1⦄ ⊢ ▶[d, e] 𝐍⦃T⦄ →
-                      ∀L2. L1 ⊑×[d, e] L2 → ⦃G, L2⦄ ⊢ ▶[d, e] 𝐍⦃T⦄.
-#G #d #e #L1 #T1 #HT1 #L2 #HL12 #T2 #HT12
-@HT1 /3 width=3 by lsuby_cpy_trans/
-qed-. 
-
-lemma cny_sort: ∀G,L,d,e,k. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃⋆k⦄.
-#G #L #d #e #k #X #H elim (cpy_inv_sort1 … H) -H //
-qed.
-
-lemma cny_lref_free: ∀G,L,d,e,i. |L| ≤ i → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
-#G #L #d #e #i #Hi #X #H elim (cpy_inv_lref1 … H) -H // *
-#I #K #V #_ #_ #HLK #_ lapply (ldrop_fwd_length_lt2 … HLK) -HLK
-#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
-qed.
-
-lemma cny_lref_atom: ∀G,L,d,e,i. ⇩[i] L ≡ ⋆ → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
-#G #L #d #e #i #HL @cny_lref_free >(ldrop_fwd_length … HL) -HL //
-qed.
-
-lemma cny_lref_top: ∀G,L,d,e,i. d+e ≤ yinj i → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
-#G #L #d #e #i #Hdei #X #H elim (cpy_inv_lref1 … H) -H // *
-#I #K #V #_ #H elim (ylt_yle_false … H) //
-qed.
-
-lemma cny_lref_skip: ∀G,L,d,e,i. yinj i < d → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
-#G #L #d #e #i #Hid #X #H elim (cpy_inv_lref1 … H) -H // *
-#I #K #V #H elim (ylt_yle_false … H) //
-qed.
-
-lemma cny_gref: ∀G,L,d,e,p. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃§p⦄.
-#G #L #d #e #p #X #H elim (cpy_inv_gref1 … H) -H //
-qed.
-
-lemma cny_bind: ∀G,L,V,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ →
-                ∀I,T. ⦃G, L.ⓑ{I}V⦄ ⊢ ▶[⫯d, e] 𝐍⦃T⦄ →
-                ∀a. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓑ{a,I}V.T⦄.
-#G #L #V1 #d #e #HV1 #I #T1 #HT1 #a #X #H
-elim (cpy_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
->(HV1 … HV12) -V2 >(HT1 … HT12) -T2 //
-qed.
-
-lemma cny_flat: ∀G,L,V,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ →
-                ∀T. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T⦄ →
-                ∀I. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓕ{I}V.T⦄.
-#G #L #V1 #d #e #HV1 #T1 #HT1 #I #X #H
-elim (cpy_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
->(HV1 … HV12) -V2 >(HT1 … HT12) -T2 //
-qed.
-
-lemma cny_narrow: ∀G,L,T,d1,e1. ⦃G, L⦄ ⊢ ▶[d1, e1] 𝐍⦃T⦄ →
-                  ∀d2,e2. d1 ≤ d2 → d2 + e2 ≤ d1 + e1 → ⦃G, L⦄ ⊢ ▶[d2, e2] 𝐍⦃T⦄.
-#G #L #T1 #d1 #e1 #HT1 #d2 #e2 #Hd12 #Hde21 #T2 #HT12
-@HT1 /2 width=5 by cpy_weak/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cny_lift.etc
deleted file mode 100644 (file)
index 213fa6a..0000000
+++ /dev/null
@@ -1,118 +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/relocation/cny.ma".
-
-(* NORMAL TERMS FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION *****************)
-
-(* Properties on relocation *************************************************)
-
-lemma cny_lift_le: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
-                   ⇧[d, e] T ≡ U → dt + et ≤ d → ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hdetd #U2 #HU12
-elim (cpy_inv_lift1_le … HU12 … HLK … HTU1) // -L -Hdetd #T2 #HT12
->(HT1 … HT12) -K /2 width=5 by lift_mono/
-qed-.
-
-lemma cny_lift_be: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
-                   ⇧[d, e] T ≡ U → dt ≤ d → yinj d ≤ dt + et → ⦃G, L⦄ ⊢ ▶[dt, et+e] 𝐍⦃U⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hdtd #Hddet #U2 #HU12
-elim (cpy_inv_lift1_be … HU12 … HLK … HTU1) /2 width=1 by monotonic_yle_plus_dx/ -L -Hdtd -Hddet #T2
->yplus_minus_inj #HT12 >(HT1 … HT12) -K /2 width=5 by lift_mono/
-qed-.
-
-lemma cny_lift_ge: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
-                   ⇧[d, e] T ≡ U → d ≤ dt → ⦃G, L⦄ ⊢ ▶[dt+e, et] 𝐍⦃U⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hddt #U2 #HU12
-elim (cpy_inv_lift1_ge … HU12 … HLK … HTU1) /2 width=1 by monotonic_yle_plus_dx/ -L -Hddt #T2
->yplus_minus_inj #HT12 >(HT1 … HT12) -K /2 width=5 by lift_mono/
-qed-.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma cny_inv_lift_le: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
-                       ⇧[d, e] T ≡ U → dt + et ≤ d → ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdetd #T2 #HT12
-elim (lift_total T2 d e) #U2 #HTU2
-lapply (cpy_lift_le … HT12 … HLK … HTU1 … HTU2 ?) // -K -Hdetd #HU12
-lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
-qed-.
-
-lemma cny_inv_lift_be: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
-                       ⇧[d, e] T ≡ U → dt ≤ d → yinj d + e ≤ dt + et → ⦃G, K⦄ ⊢ ▶[dt, et-e] 𝐍⦃T⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdtd #Hdedet #T2 #HT12
-lapply (yle_fwd_plus_ge_inj … Hdedet) // #Heet
-elim (yle_inv_plus_inj2 … Hdedet) -Hdedet #Hddete #Hedet
-elim (lift_total T2 d e) #U2 #HTU2
-lapply (cpy_lift_be … HT12 … HLK … HTU1 … HTU2 ? ?) // [ >yplus_minus_assoc_inj // ] -K -Hdtd -Hddete
->ymax_pre_sn // -Heet #HU12
-lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
-qed-.
-
-lemma cny_inv_lift_ge: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
-                       ⇧[d, e] T ≡ U → yinj d + e ≤ dt → ⦃G, K⦄ ⊢ ▶[dt-e, et] 𝐍⦃T⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdedt #T2 #HT12
-elim (yle_inv_plus_inj2 … Hdedt) -Hdedt #Hddte #Hedt
-elim (lift_total T2 d e) #U2 #HTU2
-lapply (cpy_lift_ge … HT12 … HLK … HTU1 … HTU2 ?) // -K -Hddte
->ymax_pre_sn // -Hedt #HU12
-lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
-qed-.
-
-(* Advanced inversion lemmas on relocation **********************************)
-
-lemma cny_inv_lift_ge_up: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
-                          ⇧[d, e] T ≡ U → d ≤ dt → dt ≤ yinj d + e → yinj d + e ≤ dt + et →
-                          ⦃G, K⦄ ⊢ ▶[d, dt + et - (yinj d + e)] 𝐍⦃T⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hddt #Hdtde #Hdedet
-lapply (cny_narrow … HU1 (d+e) (dt+et-(d+e)) ? ?) -HU1 [ >ymax_pre_sn_comm ] // #HU1
-lapply (cny_inv_lift_ge … HU1 … HLK … HTU1 ?) // -L -U1
->yplus_minus_inj //
-qed-.
-
-lemma cny_inv_lift_subst: ∀G,L,K,V,W,i,d,e. d ≤ yinj i → i < d + e →
-                          ⇩[i+1] L ≡ K → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃W⦄ →
-                          ⇧[O, i+1] V ≡ W → ⦃G, K⦄ ⊢ ▶[O, ⫰(d+e-i)] 𝐍⦃V⦄.
-#G #L #K #V #W #i #d #e #Hdi #Hide #HLK #HW #HVW
-lapply (cny_inv_lift_ge_up … HW … HLK … HVW ? ? ?) //
->yplus_O1 <yplus_inj >yplus_SO2
-[ /2 width=1 by ylt_fwd_le_succ1/
-| /2 width=3 by yle_trans/
-| >yminus_succ2 //
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-(* Note: this should be applicable in a forward manner *)
-lemma cny_lift_ge_up: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[yinj d, dt + et - (yinj d + yinj e)] 𝐍⦃T⦄ →
-                      ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U →
-                      yinj d ≤ dt → dt ≤ yinj d + yinj e → yinj d + yinj e ≤ dt + et →
-                      ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄.
-#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hddt #Hdtde #Hdedet
-lapply (cny_lift_be … HT1 … HLK … HTU1 ? ?) // -K -T1
-#HU1 @(cny_narrow … HU1) -HU1 // (**) (* auto fails *)
-qed-.
-
-lemma cny_lift_subst: ∀G,L,K,V,W,i,d,e. d ≤ yinj i → i < d + e →
-                      ⇩[i+1] L ≡ K → ⦃G, K⦄ ⊢ ▶[O, ⫰(d+e-i)] 𝐍⦃V⦄ →
-                      ⇧[O, i+1] V ≡ W → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃W⦄.
-#G #L #K #V #W #i #d #e #Hdi #Hide #HLK #HV #HVW
-@(cny_lift_ge_up … HLK … HVW) // >yplus_O1 <yplus_inj >yplus_SO2
-[ >yminus_succ2 //
-| /2 width=3 by yle_trans/
-| /2 width=1 by ylt_fwd_le_succ1/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpx_cpzs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpx_cpzs.etc
deleted file mode 100644 (file)
index 6c208d5..0000000
+++ /dev/null
@@ -1,73 +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/delta_equivalence/cpzs.ma".
-include "basic_2/reduction/cpx.ma".
-
-fact destruct_tsort_tsort: ∀k1,k2. ⋆k1 = ⋆k2 → k1 = k2.
-#k1 #k2 #H destruct //
-qed-.
-
-axiom cpzs_inv_subst: ∀I,G,L,K,V1,V2,W2,i.
-                      ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ W2 →
-                      ⦃G, L⦄ ⊢ #i ◆*[O, ∞] W2 → ⦃G, K⦄⊢ V1 ◆*[O, ∞] V2.
-
-axiom cpzs_subst: ∀I,G,L,K,V1,V2,W2,i.
-                  ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ W2 →
-                  ⦃G, K⦄⊢ V1 ◆*[O, ∞] V2 → ⦃G, L⦄ ⊢ #i ◆*[O, ∞] W2.
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
-
-(* Forward lemmas on delta-equivalence for terms ****************************)
-
-lemma cpx_fwd_cpys_cpzs: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 →
-                         ∀d,e. ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2 ↔ ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2.
-#h #g #G #L #T1 #T2 #H elim H -G -L -T1 -T2
-[ /2 width=1 by conj/
-| #G #L #k #l #_ #d #e @conj #H lapply (next_lt h k)
-  [ <(cpzs_inv_sort … H)
-  | lapply (cpys_inv_sort1 … H) -H #H >(destruct_tsort_tsort … H)
-  ] -H #H elim (lt_refl_false … H)
-| #I #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #IHV12 #d #e @conj #H
-(*  
-  [ @(cpys_subst … HLK … HVW2) // >yminus_Y_inj /3 width=7 by cpzs_inv_subst/
-  | elim (cpys_inv_lref1_ldrop … H … HLK … HVW2) -H /3 width=7 by cpzs_subst/
-  ]
-*)
-| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #d #e
-  elim (IHV12 d e) -IHV12 elim (IHT12 (⫯d) e) -IHT12
-  #IHTdx #IHTsn #IHVdx #IHVsn @conj #H
-  [ elim (cpzs_inv_bind … H) -H /3 width=1 by cpys_bind/
-  | elim (cpys_inv_bind1 … H) -H #X1 #X2 #H1 #H2 #H destruct /3 width=1 by cpzs_bind/
-  ]
-| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #d #e
-  elim (IHV12 d e) -IHV12 elim (IHT12 (d) e) -IHT12
-  #IHTdx #IHTsn #IHVdx #IHVsn @conj #H
-  [ elim (cpzs_inv_flat … H) -H /3 width=1 by cpys_flat/
-  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct /3 width=1 by cpzs_flat/
-  ]
-| #G #L #V #U1 #U2 #T2 #_ #HTU2 #_ #d #e @conj #H
-| #G #L #V1 #T1 #T2 #_ #_ #d #e @conj #H
-| #G #L #V1 #V2 #T1 #HV12 #_ #d #e @conj #H
-| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #d #e @conj #H
-  [ elim (cpzs_inv_flat_bind … H)
-  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct
-  ]
-| #a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #d #e @conj #H
-  [ elim (cpzs_inv_flat_bind … H)
-  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct
-  ]
-]
-    
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye.etc
deleted file mode 100644 (file)
index 71e06ea..0000000
+++ /dev/null
@@ -1,89 +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/psubsteval_6.ma".
-include "basic_2/relocation/cny.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
-
-definition cpye: ynat → ynat → relation4 genv lenv term term ≝
-                 λd,e,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 ∧ ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T2⦄.
-
-interpretation "evaluation for context-sensitive extended substitution (term)"
-   'PSubstEval G L T1 T2 d e = (cpye d e G L T1 T2).
-
-(* Basic_properties *********************************************************)
-
-(* Note: this should go in subconversion *)
-lemma leqy_cpye_trans: ∀G,L2,T1,T2,d,e. ⦃G, L2⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ →
-                       ∀L1. L1 ⊑×[d, e] L2 → L2 ⊑×[d, e] L1 → ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
-#G #L2 #T1 #T2 #d #e *
-/4 width=8 by lsuby_cpys_trans, lsuby_cny_conf, conj/
-qed-.
-
-lemma cpye_sort: ∀G,L,d,e,k. ⦃G, L⦄ ⊢ ⋆k ▶*[d, e] 𝐍⦃⋆k⦄.
-/3 width=5 by cny_sort, conj/ qed.
-
-lemma cpye_free: ∀G,L,d,e,i. |L| ≤ i → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
-/3 width=6 by cny_lref_free, conj/ qed.
-
-lemma cpye_top: ∀G,L,d,e,i. d + e ≤ yinj i → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
-/3 width=6 by cny_lref_top, conj/ qed.
-
-lemma cpye_skip: ∀G,L,d,e,i. yinj i < d → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
-/3 width=6 by cny_lref_skip, conj/ qed.
-
-lemma cpye_gref: ∀G,L,d,e,p. ⦃G, L⦄ ⊢ §p ▶*[d, e] 𝐍⦃§p⦄.
-/3 width=5 by cny_gref, conj/ qed.
-
-lemma cpye_bind: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
-                 ∀I,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ →
-                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶*[d, e] 𝐍⦃ⓑ{a,I}V2.T2⦄.
-#G #L #V1 #V2 #d #e * #HV12 #HV2 #I #T1 #T2 *
-/5 width=8 by cpys_bind, cny_bind, lsuby_cny_conf, lsuby_succ, conj/
-qed.
-
-lemma cpye_flat: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
-                 ∀T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ →
-                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ▶*[d, e] 𝐍⦃ⓕ{I}V2.T2⦄.
-#G #L #V1 #V2 #d #e * #HV12 #HV2 #T1 #T2 *
-/3 width=7 by cpys_flat, cny_flat, conj/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma cpye_inv_sort1: ∀G,L,X,d,e,k. ⦃G, L⦄ ⊢ ⋆k ▶*[d, e] 𝐍⦃X⦄ → X = ⋆k.
-#G #L #X #d #e #k * /2 width=5 by cpys_inv_sort1/
-qed-.
-
-lemma cpye_inv_gref1: ∀G,L,X,d,e,p. ⦃G, L⦄ ⊢ §p ▶*[d, e] 𝐍⦃X⦄ → X = §p.
-#G #L #X #d #e #p * /2 width=5 by cpys_inv_gref1/
-qed-.
-
-lemma cpye_inv_bind1: ∀a,I,G,L,V1,T1,X,d,e. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶*[d, e] 𝐍⦃X⦄ →
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ & ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ &
-                               X = ⓑ{a,I}V2.T2.
-#a #I #G #L #V1 #T1 #X #d #e * #H1 #H2 elim (cpys_inv_bind1 … H1) -H1
-#V2 #T2 #HV12 #HT12 #H destruct elim (cny_inv_bind … H2) -H2
-/5 width=8 by lsuby_cny_conf, lsuby_succ, ex3_2_intro, conj/
-qed-.
-
-lemma cpye_inv_flat1: ∀I,G,L,V1,T1,X,d,e. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ▶*[d, e] 𝐍⦃X⦄ →
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ & ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ &
-                               X = ⓕ{I}V2.T2.
-#I #G #L #V1 #T1 #X #d #e * #H1 #H2 elim (cpys_inv_flat1 … H1) -H1
-#V2 #T2 #HV12 #HT12 #H destruct elim (cny_inv_flat … H2) -H2
-/3 width=5 by ex3_2_intro, conj/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_alt.etc
deleted file mode 100644 (file)
index a9dc53c..0000000
+++ /dev/null
@@ -1,89 +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/psubstevalalt_6.ma".
-include "basic_2/substitution/cpye_lift.ma".
-
-(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
-
-(* Note: alternative definition of cpye *)
-inductive cpyea: ynat → ynat → relation4 genv lenv term term ≝
-| cpyea_sort : ∀G,L,d,e,k. cpyea d e G L (⋆k) (⋆k)
-| cpyea_free : ∀G,L,d,e,i. |L| ≤ i → cpyea d e G L (#i) (#i)
-| cpyea_top  : ∀G,L,d,e,i. d + e ≤ yinj i → cpyea d e G L (#i) (#i)
-| cpyea_skip : ∀G,L,d,e,i. yinj i < d → cpyea d e G L (#i) (#i)
-| cpyea_subst: ∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → yinj i < d+e →
-               ⇩[i] L ≡ K.ⓑ{I}V1 → cpyea (yinj 0) (⫰(d+e-yinj i)) G K V1 V2 →
-               ⇧[0, i+1] V2 ≡ W2 → cpyea d e G L (#i) W2
-| cpyea_gref : ∀G,L,d,e,p. cpyea d e G L (§p) (§p)
-| cpyea_bind : ∀a,I,G,L,V1,V2,T1,T2,d,e.
-               cpyea d e G L V1 V2 → cpyea (⫯d) e G (L.ⓑ{I}V1) T1 T2 →
-               cpyea d e G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
-| cpyea_flat : ∀I,G,L,V1,V2,T1,T2,d,e.
-               cpyea d e G L V1 V2 → cpyea d e G L T1 T2 →
-               cpyea d e G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
-.
-
-interpretation
-   "evaluation for context-sensitive extended substitution (term) alternative"
-   'PSubstEvalAlt G L T1 T2 d e = (cpyea d e G L T1 T2).
-
-(* Main properties **********************************************************)
-
-theorem cpye_cpyea: ∀G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → ⦃G, L⦄ ⊢ T1 ▶▶*[d, e] 𝐍⦃T2⦄.
-#G #L #T1 @(fqup_wf_ind_eq … G L T1) -G -L -T1
-#Z #Y #X #IH #G #L * *
-[ #k #_ #_ #_ #T2 #d #e #H -X -Y -Z >(cpye_inv_sort1 … H) -H //
-| #i #HG #HL #HT #T2 #d #e #H destruct
-  elim (cpye_inv_lref1 … H) -H *
-  /4 width=7 by cpyea_subst, cpyea_free, cpyea_top, cpyea_skip, fqup_lref/
-| #p #_ #_ #_ #T2 #d #e #H -X -Y -Z >(cpye_inv_gref1 … H) -H //
-| #a #I #V1 #T1 #HG #HL #HT #T #d #e #H destruct
-  elim (cpye_inv_bind1 … H) -H /3 width=1 by cpyea_bind/
-| #I #V1 #T1 #HG #HL #HT #T #d #e #H destruct
-  elim (cpye_inv_flat1 … H) -H /3 width=1 by cpyea_flat/
-]
-qed.
-
-(* Main inversion properties ************************************************)
-
-theorem cpyea_inv_cpye: ∀G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶▶*[d, e] 𝐍⦃T2⦄ → ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
-#G #L #T1 #T2 #d #e #H elim H -G -L -T1 -T2 -d -e
-/2 width=7 by cpye_subst, cpye_flat, cpye_bind, cpye_skip, cpye_top, cpye_free/
-qed-.
-
-(* Advanced eliminators *****************************************************)
-
-lemma cpye_ind_alt: ∀R:ynat→ynat→relation4 genv lenv term term.
-                    (∀G,L,d,e,k. R d e G L (⋆k) (⋆k)) →
-                    (∀G,L,d,e,i. |L| ≤ i → R d e G L (#i) (#i)) →
-                    (∀G,L,d,e,i. d + e ≤ yinj i → R d e G L (#i) (#i)) →
-                    (∀G,L,d,e,i. yinj i < d → R d e G L (#i) (#i)) →
-                    (∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → yinj i < d + e →
-                     ⇩[i] L ≡ K.ⓑ{I}V1 → ⦃G, K⦄ ⊢ V1 ▶*[yinj O, ⫰(d+e-yinj i)] 𝐍⦃V2⦄ →
-                     ⇧[O, i+1] V2 ≡ W2 → R (yinj O) (⫰(d+e-yinj i)) G K V1 V2 → R d e G L (#i) W2
-                    ) →
-                    (∀G,L,d,e,p. R d e G L (§p) (§p)) →
-                    (∀a,I,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
-                     ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ → R d e G L V1 V2 →
-                     R (⫯d) e G (L.ⓑ{I}V1) T1 T2 → R d e G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
-                    ) →
-                    (∀I,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
-                     ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → R d e G L V1 V2 →
-                     R d e G L T1 T2 → R d e G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
-                    ) →
-                    ∀d,e,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → R d e G L T1 T2.
-#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8 #d #e #G #L #T1 #T2 #H elim (cpye_cpyea … H) -G -L -T1 -T2 -d -e
-/3 width=8 by cpyea_inv_cpye/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_cpye.etc
deleted file mode 100644 (file)
index 42bd19b..0000000
+++ /dev/null
@@ -1,28 +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_cny.ma".
-include "basic_2/substitution/cpys_cpys.ma".
-include "basic_2/substitution/cpye.ma".
-
-(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
-
-(* Advanced properties ******************************************************)
-
-lemma cpye_cpys_conf: ∀G,L,T,T2,d,e. ⦃G, L⦄ ⊢ T ▶*[d, e] 𝐍⦃T2⦄ →
-                      ∀T1. ⦃G, L⦄ ⊢ T ▶*[d, e] T1 → ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2.
-#G #L #T #T2 #d #e * #H2 #HT2 #T1 #H1 elim (cpys_conf_eq … H1 … H2) -T
-#T0 #HT10 #HT20 >(cpys_inv_cny1 … HT2 … HT20) -T2 //
-qed-.
-   
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpye_lift.etc
deleted file mode 100644 (file)
index 3c0abe6..0000000
+++ /dev/null
@@ -1,169 +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/cny_lift.ma".
-include "basic_2/substitution/fqup.ma".
-include "basic_2/substitution/cpys_lift.ma".
-include "basic_2/substitution/cpye.ma".
-
-(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
-
-(* Advanced properties ******************************************************)
-
-lemma cpye_subst: ∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → i < d + e →
-                  ⇩[i] L ≡ K.ⓑ{I}V1 → ⦃G, K⦄ ⊢ V1 ▶*[O, ⫰(d+e-i)] 𝐍⦃V2⦄ →
-                  ⇧[O, i+1] V2 ≡ W2 → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃W2⦄.
-#I #G #L #K #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK *
-/4 width=13 by cpys_subst, cny_lift_subst, ldrop_fwd_drop2, conj/
-qed.
-
-lemma cpye_total: ∀G,L,T1,d,e. ∃T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
-#G #L #T1 @(fqup_wf_ind_eq … G L T1) -G -L -T1
-#Z #Y #X #IH #G #L * *
-[ #k #HG #HL #HT #d #e destruct -IH /2 width=2 by ex_intro/
-| #i #HG #HL #HT #d #e destruct
-  elim (ylt_split i d) /3 width=2 by cpye_skip, ex_intro/
-  elim (ylt_split i (d+e)) /3 width=2 by cpye_top, ex_intro/
-  elim (lt_or_ge i (|L|)) /3 width=2 by cpye_free, ex_intro/
-  #Hi #Hide #Hdi elim (ldrop_O1_lt L i) // -Hi
-  #I #K #V1 #HLK elim (IH G K V1 … 0 (⫰(d+e-i))) -IH /2 width=2 by fqup_lref/
-  #V2 elim (lift_total V2 0 (i+1)) /3 width=8 by ex_intro, cpye_subst/
-| #p #HG #HL #HT #d #e destruct -IH /2 width=2 by ex_intro/
-| #a #I #V1 #T1 #HG #HL #HT #d #e destruct
-  elim (IH G L V1 … d e) // elim (IH G (L.ⓑ{I}V1) T1 … (⫯d) e) //
-  /3 width=2 by cpye_bind, ex_intro/
-| #I #V1 #T1 #HG #HL #HT #d #e destruct
-  elim (IH G L V1 … d e) // elim (IH G L T1 … d e) //
-  /3 width=2 by cpye_flat, ex_intro/
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cpye_inv_lref1: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
-                      ∨∨ |L| ≤ i ∧ T2 = #i
-                       | d + e ≤ yinj i ∧ T2 = #i
-                       | yinj i < d ∧ T2 = #i
-                       | ∃∃I,K,V1,V2. d ≤ yinj i & yinj i < d + e &
-                                      ⇩[i] L ≡ K.ⓑ{I}V1 &
-                                      ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
-                                      ⇧[O, i+1] V2 ≡ T2.
-#G #L #T2 #i #d #e * #H1 #H2 elim (cpys_inv_lref1 … H1) -H1
-[ #H destruct elim (cny_inv_lref … H2) -H2
-  /3 width=1 by or4_intro0, or4_intro1, or4_intro2, conj/
-| * #I #K #V1 #V2 #Hdi #Hide #HLK #HV12 #HVT2
-    @or4_intro3 @(ex5_4_intro … HLK … HVT2) (**) (* explicit constructor *)
-    /4 width=13 by cny_inv_lift_subst, ldrop_fwd_drop2, conj/
-]
-qed-.
-
-lemma cpye_inv_lref1_free: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
-                           (∨∨ |L| ≤ i | d + e ≤ yinj i | yinj i < d) → T2 = #i.
-#G #L #T2 #d #e #i #H * elim (cpye_inv_lref1 … H) -H * //
-#I #K #V1 #V2 #Hdi #Hide #HLK #_ #_ #H
-[ elim (lt_refl_false i) -d
-  @(lt_to_le_to_lt … H) -H /2 width=5 by ldrop_fwd_length_lt2/ (**) (* full auto slow: 19s *)
-]
-elim (ylt_yle_false … H) //
-qed-.
-
-lemma cpye_inv_lref1_lget: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
-                           ∀I,K,V1. ⇩[i] L ≡ K.ⓑ{I}V1 →
-                           ∨∨ d + e ≤ yinj i ∧ T2 = #i
-                            | yinj i < d ∧ T2 = #i
-                            | ∃∃V2. d ≤ yinj i & yinj i < d + e &
-                                    ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
-                                    ⇧[O, i+1] V2 ≡ T2.
-#G #L #T2 #d #e #i #H #I #K #V1 #HLK elim (cpye_inv_lref1 … H) -H *
-[ #H elim (lt_refl_false i) -T2 -d
-  @(lt_to_le_to_lt … H) -H /2 width=5 by ldrop_fwd_length_lt2/
-| /3 width=1 by or3_intro0, conj/
-| /3 width=1 by or3_intro1, conj/
-| #Z #Y #X1 #X2 #Hdi #Hide #HLY #HX12 #HXT2
-  lapply (ldrop_mono … HLY … HLK) -HLY -HLK #H destruct
-  /3 width=3 by or3_intro2, ex4_intro/
-]
-qed-.
-
-lemma cpye_inv_lref1_subst_ex: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
-                               ∀I,K,V1. d ≤ yinj i → yinj i < d + e →
-                               ⇩[i] L ≡ K.ⓑ{I}V1 →
-                               ∃∃V2. ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
-                                     ⇧[O, i+1] V2 ≡ T2.
-#G #L #T2 #d #e #i #H #I #K #V1 #Hdi #Hide #HLK
-elim (cpye_inv_lref1_lget … H … HLK) -H * /2 width=3 by ex2_intro/
-#H elim (ylt_yle_false … H) //
-qed-.
-
-lemma cpye_inv_lref1_subst: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
-                            ∀I,K,V1,V2. d ≤ yinj i → yinj i < d + e →
-                            ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ T2 →
-                            ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄.
-#G #L #T2 #d #e #i #H #I #K #V1 #V2 #Hdi #Hide #HLK #HVT2
-elim (cpye_inv_lref1_subst_ex … H … HLK) -H -HLK //
-#X2 #H0 #HXT2 lapply (lift_inj … HXT2 … HVT2) -HXT2 -HVT2 #H destruct //
-qed-.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma cpye_inv_lift1_le: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
-                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         dt + et ≤ d →
-                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt, et] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
-#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdetd
-elim (cpys_inv_lift1_le … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
-lapply (cny_inv_lift_le … HU2 … HLK … HTU2 ?) -L
-/3 width=3 by ex2_intro, conj/
-qed-.
-
-lemma cpye_inv_lift1_be: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
-                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         dt ≤ d → yinj d + e ≤ dt + et →
-                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt, et - e] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
-#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdtd #Hdedet
-elim (cpys_inv_lift1_be … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
-lapply (cny_inv_lift_be … HU2 … HLK … HTU2 ? ?) -L
-/3 width=3 by ex2_intro, conj/
-qed-.
-
-lemma cpye_inv_lift1_ge: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
-                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         yinj d + e ≤ dt →
-                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt - e, et] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
-#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdedt
-elim (cpys_inv_lift1_ge … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
-lapply (cny_inv_lift_ge … HU2 … HLK … HTU2 ?) -L
-/3 width=3 by ex2_intro, conj/
-qed-.
-
-lemma cpye_inv_lift1_ge_up: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
-                            ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                            d ≤ dt → dt ≤ yinj d + e → yinj d + e ≤ dt + et →
-                            ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[d, dt + et - (yinj d + e)] 𝐍⦃T2⦄ &
-                                 ⇧[d, e] T2 ≡ U2.
-#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
-elim (cpys_inv_lift1_ge_up … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
-lapply (cny_inv_lift_ge_up … HU2 … HLK … HTU2 ? ? ?) -L
-/3 width=3 by ex2_intro, conj/
-qed-.
-
-lemma cpye_inv_lift1_subst: ∀G,L,W1,W2,d,e. ⦃G, L⦄ ⊢ W1 ▶*[d, e] 𝐍⦃W2⦄ →
-                            ∀K,V1,i. ⇩[i+1] L ≡ K → ⇧[O, i+1] V1 ≡ W1 →
-                            d ≤ yinj i → i < d + e →
-                            ∃∃V2.  ⦃G, K⦄ ⊢ V1 ▶*[O, ⫰(d+e-i)] 𝐍⦃V2⦄ & ⇧[O, i+1] V2 ≡ W2.
-#G #L #W1 #W2 #d #e * #HW12 #HW2 #K #V1 #i #HLK #HVW1 #Hdi #Hide
-elim (cpys_inv_lift1_subst … HW12 … HLK … HVW1) -W1 // #V2 #HV12 #HVW2
-lapply (cny_inv_lift_subst … HLK HW2 HVW2) -L
-/3 width=3 by ex2_intro, conj/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpys_cny.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpys_cny.etc
deleted file mode 100644 (file)
index 1499cee..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/cny.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
-
-(* Inversion lemmas on normality for extended substitution ******************)
-
-lemma cpys_inv_cny1: ∀G,L,T1,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T1⦄ →
-                     ∀T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → T1 = T2.
-#G #L #T1 #d #e #HT1 #T2 #H @(cpys_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT1 destruct <(HT1 … HT2) -T //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpzs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/cpzs.etc
deleted file mode 100644 (file)
index 0fada97..0000000
+++ /dev/null
@@ -1,83 +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/pdeltaconvstar_6.ma".
-include "basic_2/substitution/cpye_lift.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED DELTA-EQUIVALENCE FOR TERMS *******************)
-
-definition cpzs: ynat → ynat → relation4 genv lenv term term ≝
-                 λd,e,G,L,T1,T2.
-                 ∃∃T. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T⦄ & ⦃G, L⦄ ⊢ T2 ▶*[d, e] 𝐍⦃T⦄.
-
-interpretation "context-sensitive extended delta-equivalence (term)"
-   'PDeltaConvStar G L T1 d e T2 = (cpzs d e G L T1 T2).
-
-(* Basic properties **********************************************************)
-
-lemma cpye_div: ∀G,L,T1,T,d,e.  ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T⦄ →
-                ∀T2. ⦃G, L⦄ ⊢ T2 ▶*[d, e] 𝐍⦃T⦄ → ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2.
-/2 width=3 by ex2_intro/ qed.
-
-lemma cpzs_refl: ∀G,L,d,e. reflexive … (cpzs d e G L).
-#G #L #d #e #T elim (cpye_total G L T d e) /2 width=3 by cpye_div/
-qed.
-
-lemma cpzs_bind: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 →
-                 ∀I,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ◆*[⫯d, e] T2 →
-                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ◆*[d, e] ⓑ{a,I}V2.T2.
-#G #L #V1 #V2 #d #e * #V #HV1 #HV2 #I #T1 #T2 *
-/5 width=10 by cpye_div, cpye_bind, leqy_cpye_trans, cny_bind, lsuby_succ/
-qed.
-
-lemma cpzs_flat: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 →
-                 ∀T1,T2. ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2 →
-                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ◆*[d, e] ⓕ{I}V2.T2.
-#G #L #V1 #V2 #d #e * #V #HV1 #HV2 #T1 #T2 *
-/3 width=5 by cpye_div, cpye_flat, cny_flat/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma cpzs_inv_sort: ∀G,L,d,e,k1,k2. ⦃G, L⦄ ⊢ ⋆k1 ◆*[d, e] ⋆k2 → k1 = k2.
-#G #L #d #e #k1 #k2 * #X #H1 #H2
-lapply (cpye_inv_sort1 … H1) -H1 #H1
-lapply (cpye_inv_sort1 … H2) -H2 #H2
-destruct //
-qed-.
-
-lemma cpzs_inv_bind: ∀a1,a2,I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓑ{a1,I1}V1.T1 ◆*[d, e] ⓑ{a2,I2}V2.T2 →
-                     ∧∧ a1 = a2 & I1 = I2
-                      & ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 & ⦃G, L.ⓑ{I1}V1⦄ ⊢ T1 ◆*[⫯d, e] T2.
-#a1 #a2 #I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
-elim (cpye_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
-elim (cpye_inv_bind1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
-destruct /5 width=8 by cpye_div, leqy_cpye_trans, lsuby_succ, and4_intro/
-qed-.
-
-lemma cpzs_inv_flat: ∀I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓕ{I1}V1.T1 ◆*[d, e] ⓕ{I2}V2.T2 →
-                     ∧∧ I1 = I2
-                      & ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 & ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2.
-#I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
-elim (cpye_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
-elim (cpye_inv_flat1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
-destruct /3 width=3 by cpye_div, and3_intro/
-qed-.
-
-lemma cpzs_inv_flat_bind: ∀a2,I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓕ{I1}V1.T1 ◆*[d, e] ⓑ{a2,I2}V2.T2 → ⊥.
-#a2 #I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
-elim (cpye_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
-elim (cpye_inv_bind1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
-destruct
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lleq_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lleq_cpye.etc
deleted file mode 100644 (file)
index e6890e6..0000000
+++ /dev/null
@@ -1,49 +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/cpye_lift.ma".
-include "basic_2/substitution/lleq_alt.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-(* Forward lemmas on evaluation for extended substitution *******************)
-
-lemma lleq_fwd_cpye: ∀L1,L2,T,d. L1 ⋕[T, d] L2 → ∀G,T1. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] 𝐍⦃T1⦄ →
-                     ∀T2. ⦃G, L2⦄ ⊢ T ▶*[d, ∞] 𝐍⦃T2⦄ → T1 = T2.
-#L1 #L2 #T #d #H @(lleq_ind_alt … H) -L1 -L2 -T -d
-[ #L1 #L2 #d #k #_ #G #T1 #H1 #T2 #H2
-  >(cpye_inv_sort1 … H1) -H1 >(cpye_inv_sort1 … H2) -H2 //
-| #L1 #L2 #d #i #_ #Hid #G #T1 #H1 #T2 #H2
-  >(cpye_inv_lref1_free … H1) -H1 [ >(cpye_inv_lref1_free … H2) -H2 ]
-  /2 width=1 by or3_intro2/
-| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 #_ #IHV #G #T1 #H1 #T2 #H2
-  elim (cpye_inv_lref1_subst_ex … H1 … HLK1) -H1 -HLK1 //
-  elim (cpye_inv_lref1_subst_ex … H2 … HLK2) -H2 -HLK2 //
-  >yminus_Y_inj #V2 #HV2 #HVT2 #V1 #HV1 #HVT1
-  lapply (IHV … HV1 … HV2) -IHV -HV1 -HV2 #H destruct /2 width=5 by lift_mono/
-| #L1 #L2 #d #i #_ #HL1 #HL2 #G #T1 #H1 #T2 #H2
-  >(cpye_inv_lref1_free … H1) -H1 [ >(cpye_inv_lref1_free … H2) -H2 ]
-  /2 width=1 by or3_intro0/
-| #L1 #L2 #d #p #_ #G #T1 #H1 #T2 #H2
-  >(cpye_inv_gref1 … H1) -H1 >(cpye_inv_gref1 … H2) -H2 //
-| #a #I #L1 #L2 #V #T #d #_ #_ #IHV #IHT #G #X1 #H1 #X2 #H2
-  elim (cpye_inv_bind1 … H1) -H1 #V1 #T1 #HV1 #HT1 #H destruct
-  elim (cpye_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-  /3 width=3 by eq_f2/
-| #I #L1 #L2 #V #T #d #_ #_ #IHV #IHT #G #X1 #H1 #X2 #H2
-  elim (cpye_inv_flat1 … H1) -H1 #V1 #T1 #HV1 #HT1 #H destruct
-  elim (cpye_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-  /3 width=3 by eq_f2/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpx_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpx_cpye.etc
deleted file mode 100644 (file)
index 48816c8..0000000
+++ /dev/null
@@ -1,44 +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/cpye_cpye.ma".
-include "basic_2/reduction/lpx_cpys.ma".
-
-axiom cpx_cpys_conf_lpx: ∀h,g,G,d,e.
-                         ∀L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡[h, g] T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[h, g] L1 →
-                         ∀T2. ⦃G, L0⦄ ⊢ T0 ▶*[d, e] T2 →
-                         ∃∃T. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] T & ⦃G, L0⦄ ⊢ T2 ➡[h, g] T.
-
-(* SN EXTENDED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS *********************)
-
-(* Forward lemmas on evaluation for extended substitution *******************)
-
-lemma cpx_cpys_cpye_fwd_lpx: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                             ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
-                             ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] U1 →
-                             ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
-                             ⦃G, L1⦄ ⊢ U1 ➡[h, g] U2.
-#h #g #G #L1 #T1 #T2 #HT12 #L2 #HL12 #U1 #d #e #HTU1
-elim (cpx_cpys_conf_lpx … HT12 … HL12 … HTU1) -T1
-/3 width=9 by cpx_cpys_trans_lpx, cpye_cpys_conf/
-qed-.
-
-lemma cpx_cpye_fwd_lpx: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                        ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
-                        ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃U1⦄ →
-                        ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
-                        ⦃G, L1⦄ ⊢ U1 ➡[h, g] U2.
-#h #g #G #L1 #T1 #T2 #HT12 #L2 #HL12 #U1 #d #e *
-/2 width=9 by cpx_cpys_cpye_fwd_lpx/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpxs_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/lpxs_cpye.etc
deleted file mode 100644 (file)
index a6f0f86..0000000
+++ /dev/null
@@ -1,36 +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/cpye_lift.ma".
-include "basic_2/reduction/lpx_cpye.ma".
-include "basic_2/computation/cpxs_cpxs.ma".
-include "basic_2/computation/lpxs.ma".
-
-(* SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *******************)
-
-(* Forward lemmas on evaluation for extended substitution *******************)
-
-lemma cpx_cpye_fwd_lpxs: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
-                         ∀T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                         ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃U1⦄ →
-                         ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
-                         ⦃G, L1⦄ ⊢ U1 ➡*[h, g] U2.
-#h #g #G #L1 #L2 #H @(lpxs_ind_dx … H) -L1
-[ /3 width=9 by cpx_cpxs, cpx_cpye_fwd_lpx/
-| #L1 #L #HL1 #_ #IHL2 #T1 #T2 #HT12 #U1 #d #e #HTU1 #U2 #HTU2
-  elim (cpye_total G L T2 d e) #X2 #HTX2
-  lapply (cpx_cpye_fwd_lpx … HT12 … HL1 … HTU1 … HTX2) -T1
-  /4 width=9 by lpx_cpxs_trans, cpxs_strap2/ (**) (* full auto too long: 41s *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/pdeltaconvstar_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/pdeltaconvstar_6.etc
deleted file mode 100644 (file)
index b7de5f5..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ◆ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PDeltaConvStar $G $L $T1 $d $e $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubsteval_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubsteval_6.etc
deleted file mode 100644 (file)
index 360f43d..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( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ▶ * break [ term 46 d , break term 46 e ] break 𝐍 ⦃ term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'PSubstEval $G $L $T1 $T2 $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstevalalt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstevalalt_6.etc
deleted file mode 100644 (file)
index 18cdf60..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( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ▶ ▶ * break [ term 46 d , break term 46 e ] break 𝐍 ⦃ term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'PSubstEvalAlt $G $L $T1 $T2 $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstnormal_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cny/psubstnormal_5.etc
deleted file mode 100644 (file)
index 4a7a78a..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( ⦃ term 46 G, break term 46 L ⦄ ⊢ ▶ break [ term 46 d , break term 46 e ] 𝐍 break ⦃ term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'PSubstNormal $G $L $T $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees.etc
deleted file mode 100644 (file)
index e1b9b06..0000000
+++ /dev/null
@@ -1,130 +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/cofreestar_4.ma".
-include "basic_2/relocation/lift_neg.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
-
-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 L i d T = (cofrees d i L T).
-
-(* Basic forward lemmas *****************************************************)
-
-lemma cofrees_fwd_lift: ∀L,U,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ∃T. ⇧[i, 1] T ≡ U.
-/2 width=1 by/ qed-.
-
-lemma cofrees_fwd_bind_sn: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
-                           L ⊢ i ~ϵ 𝐅*[d]⦃W⦄.
-#a #I #L #W1 #U #i #d #H #W2 #HW12 elim (H (ⓑ{a,I}W2.U)) /2 width=1 by cpys_bind/ -W1
-#X #H elim (lift_inv_bind2 … H) -H /2 width=2 by ex_intro/
-qed-.
-
-lemma cofrees_fwd_bind_dx: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
-                           L.ⓑ{I}W ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃U⦄.
-#a #I #L #W #U1 #i #d #H #U2 #HU12 elim (H (ⓑ{a,I}W.U2)) /2 width=1 by cpys_bind/ -U1
-#X #H elim (lift_inv_bind2 … H) -H /2 width=2 by ex_intro/
-qed-.
-
-lemma cofrees_fwd_flat_sn: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
-                           L ⊢ i ~ϵ 𝐅*[d]⦃W⦄.
-#I #L #W1 #U #i #d #H #W2 #HW12 elim (H (ⓕ{I}W2.U)) /2 width=1 by cpys_flat/ -W1
-#X #H elim (lift_inv_flat2 … H) -H /2 width=2 by ex_intro/
-qed-.
-
-lemma cofrees_fwd_flat_dx: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
-                           L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
-#I #L #W #U1 #i #d #H #U2 #HU12 elim (H (ⓕ{I}W.U2)) /2 width=1 by cpys_flat/ -U1
-#X #H elim (lift_inv_flat2 … H) -H /2 width=2 by ex_intro/
-qed-.
-
-(* 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-. 
-
-lemma cofrees_inv_bind: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
-                        L ⊢ i ~ϵ 𝐅*[d]⦃W⦄ ∧ L.ⓑ{I}W ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃U⦄.
-/3 width=8 by cofrees_fwd_bind_sn, cofrees_fwd_bind_dx, conj/ qed-.
-
-lemma cofrees_inv_flat: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
-                        L ⊢ i ~ϵ 𝐅*[d]⦃W⦄ ∧ L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
-/3 width=7 by cofrees_fwd_flat_sn, cofrees_fwd_flat_dx, conj/ qed-.
-
-(* Basic Properties *********************************************************)
-
-lemma cofrees_lsuby_conf: ∀L1,U,d,i. L1 ⊢ i ~ϵ 𝐅*[d]⦃U⦄ →
-                          ∀L2. L1 ⊆[d, ∞] L2 → L2 ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
-/3 width=3 by lsuby_cpys_trans/ qed-.
-
-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.
-
-lemma cofrees_cpy_trans: ∀L,U1,U2,d. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 →
-                         ∀i. L ⊢ i ~ϵ 𝐅*[d]⦃U1⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄.
-/3 width=3 by cpys_strap2/ qed-.
-
-axiom cofrees_dec: ∀L,T,d,i. Decidable (L ⊢ i ~ϵ 𝐅*[d]⦃T⦄).
-
-(* Basic negated properties *************************************************)
-
-lemma frees_cpy_div: ∀L,U1,U2,d. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 →
-                     ∀i. (L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄ → ⊥) → (L ⊢ i ~ϵ 𝐅*[d]⦃U1⦄ → ⊥).
-/3 width=7 by cofrees_cpy_trans/ qed-.
-
-(* Basic 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-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_alt.etc
deleted file mode 100644 (file)
index 7bb9c9c..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/cpy_nlift.ma".
-include "basic_2/substitution/cofrees_lift.ma".
-
-(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
-
-(* Alternative definition of frees_ge ***************************************)
-
-lemma nlift_frees: ∀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-.
-
-lemma frees_inv_ge: ∀L,U,d,i. d ≤ yinj i → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) →
-                    (∀T. ⇧[i, 1] T ≡ U → ⊥) ∨
-                    ∃∃I,K,W,j. d ≤ yinj j & j < i & ⇩[j]L ≡ K.ⓑ{I}W &
-                               (K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄ → ⊥) & (∀T. ⇧[j, 1] T ≡ U → ⊥).
-#L #U #d #i #Hdi #H @(frees_ind … H) -U /3 width=2 by or_introl/
-#U1 #U2 #HU12 #HU2 *
-[ #HnU2 elim (cpy_fwd_nlift2_ge … HU12 … HnU2) -HU12 -HnU2 /3 width=2 by or_introl/
-  * /5 width=9 by nlift_frees, ex5_4_intro, or_intror/
-| * #I2 #K2 #W2 #j2 #Hdj2 #Hj2i #HLK2 #HnW2 #HnU2 elim (cpy_fwd_nlift2_ge … HU12 … HnU2) -HU12 -HnU2 /4 width=9 by ex5_4_intro, or_intror/
-  * #I1 #K1 #W1 #j1 #Hdj1 #Hj12 #HLK1 #HnW1 #HnU1
-  lapply (ldrop_conf_ge … HLK1 … HLK2 ?) -HLK2 /2 width=1 by lt_to_le/
-  #HK12 lapply (ldrop_inv_drop1_lt … HK12 ?) /2 width=1 by lt_plus_to_minus_r/ -HK12
-  #HK12
-  @or_intror @(ex5_4_intro … HLK1 … HnU1) -HLK1 -HnU1 /2 width=3 by transitive_lt/
-  @(frees_be … HK12 … HnW1) /2 width=1 by arith_k_sn/ -HK12 -HnW1
-  >minus_plus in ⊢ (??(?(?%?)?)??→?); >minus_plus in ⊢ (??(?(??%)?)??→?); >arith_b1 /2 width=1 by/
-]
-qed-.
-
-lemma frees_ind_ge: ∀R:relation4 ynat nat lenv term.
-                    (∀d,i,L,U. d ≤ yinj i → (∀T. ⇧[i, 1] T ≡ U → ⊥) → R d i L U) →
-                    (∀d,i,j,I,L,K,W,U. d ≤ yinj j → j < i → ⇩[j]L ≡ K.ⓑ{I}W → (K ⊢ i-j-1 ~ϵ 𝐅*[0]⦃W⦄ → ⊥) → (∀T. ⇧[j, 1] T ≡ U → ⊥) → R 0 (i-j-1) K W → R d i L U) →
-                    ∀d,i,L,U. d ≤ yinj i → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) → R d i L U.
-#R #IH1 #IH2 #d #i #L #U
-generalize in match d; -d generalize in match i; -i
-@(f2_ind … rfw … L U) -L -U
-#n #IHn #L #U #Hn #i #d #Hdi #H elim (frees_inv_ge … H) -H /3 width=2 by/
--IH1 * #I #K #W #j #Hdj #Hji #HLK #HnW #HnU destruct /4 width=12 by ldrop_fwd_rfw/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofrees_lift.etc
deleted file mode 100644 (file)
index f93f722..0000000
+++ /dev/null
@@ -1,180 +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/cofrees.ma".
-
-(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cofrees_inv_lref_be: ∀L,d,i,j. L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄ → d ≤ yinj j → j < i →
-                           ∀I,K,W. ⇩[j]L ≡ K.ⓑ{I}W → K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄.
-#L #d #i #j #Hj #Hdj #Hji #I #K #W1 #HLK #W2 #HW12 elim (lift_total W2 0 (j+1))
-#X2 #HWX2 elim (Hj X2) /2 width=7 by cpys_subst_Y2/ -I -L -K -W1 -d
-#Z2 #HZX2 elim (lift_div_le … HWX2 (i-j-1) 1 Z2) -HWX2 /2 width=2 by ex_intro/
->minus_plus <plus_minus_m_m //
-qed-.
-
-lemma cofrees_inv_be: ∀L,U,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ∀j. (∀T. ⇧[j, 1] T ≡ U → ⊥) →
-                      ∀I,K,W. ⇩[j]L ≡ K.ⓑ{I}W → d ≤ yinj j → j < i → K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄.
-#L #U @(f2_ind … rfw … L U) -L -U
-#n #IH #L * *
-[ -IH #k #_ #d #i #_ #j #H elim (H (⋆k)) -H //
-| -IH #j #_ #d #i #Hi0 #j0 #H <(nlift_inv_lref_be_SO … H) -j0
-  /2 width=9 by cofrees_inv_lref_be/
-| -IH #p #_ #d #i #_ #j #H elim (H (§p)) -H //
-| #a #J #W #U #Hn #d #i #H1 #j #H2 #I #K #V #HLK #Hdj #Hji destruct
-  elim (cofrees_inv_bind … H1) -H1 #HW #HU
-  elim (nlift_inv_bind … H2) -H2 [ -HU /3 width=9 by/ ]
-  -HW #HnU lapply (IH … HU … HnU I K V ? ? ?)
-  /2 width=1 by ldrop_drop, yle_succ, lt_minus_to_plus/ -a -I -J -L -W -U -d
-  >minus_plus_plus_l //
-| #J #W #U #Hn #d #i #H1 #j #H2 #I #K #V #HLK #Hdj #Hji destruct
-  elim (cofrees_inv_flat … H1) -H1 #HW #HU
-  elim (nlift_inv_flat … H2) -H2 [ /3 width=9 by/ ]
-  #HnU @(IH … HU … HnU … HLK) // (**) (* full auto fails *)
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma cofrees_lref_skip: ∀L,d,i,j. j < i → yinj j < d → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
-#L #d #i #j #Hji #Hjd #X #H elim (cpys_inv_lref1_Y2 … H) -H
-[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
-| * #I #K #W1 #W2 #Hdj elim (ylt_yle_false … Hdj) -i -I -L -K -W1 -W2 -X //
-]
-qed.
-
-lemma cofrees_lref_lt: ∀L,d,i,j. i < j → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
-#L #d #i #j #Hij #X #H elim (cpys_inv_lref1_Y2 … H) -H
-[ #H destruct /3 width=2 by lift_lref_ge_minus, ex_intro/
-| * #I #K #V1 #V2 #_ #_ #_ #H -I -L -K -V1 -d
-  elim (lift_split … H i j) /2 width=2 by lt_to_le, ex_intro/
-]
-qed.
-
-lemma cofrees_lref_gt: ∀I,L,K,W,d,i,j. j < i → ⇩[j] L ≡ K.ⓑ{I}W → 
-                       K ⊢ (i-j-1) ~ϵ 𝐅*[O]⦃W⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
-#I #L #K #W1 #d #i #j #Hji #HLK #HW1 #X #H elim (cpys_inv_lref1_Y2 … H) -H
-[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
-| * #I0 #K0 #W0 #W2 #Hdj #HLK0 #HW12 #HW2 lapply (ldrop_mono … HLK0 … HLK) -L
-  #H destruct elim (HW1 … HW12) -I -K -W1 -d
-  #V2 #HVW2 elim (lift_trans_le … HVW2 … HW2) -W2 //
-  >minus_plus <plus_minus_m_m /2 width=2 by ex_intro/
-]
-qed.
-
-lemma cofrees_lref_free: ∀L,d,i,j. |L| ≤ j → j < i → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
-#L #d #i #j #Hj #Hji #X #H elim (cpys_inv_lref1_Y2 … H) -H
-[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
-| * #I #K #W1 #W2 #_ #HLK lapply (ldrop_fwd_length_lt2 … HLK) -I
-  #H elim (lt_refl_false j) -d -i -K -W1 -W2 -X /2 width=3 by lt_to_le_to_lt/
-]
-qed.
-
-(* Advanced negated inversion lemmas ****************************************)
-
-lemma frees_inv_lref_gt: ∀L,d,i,j. j < i → (L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄ → ⊥) →
-                         ∃∃I,K,W. ⇩[j] L ≡ K.ⓑ{I}W & (K ⊢ (i-j-1) ~ϵ 𝐅*[0]⦃W⦄ → ⊥) & d ≤ yinj j.
-#L #d #i #j #Hji #H elim (ylt_split j d) #Hjd
-[ elim H -H /2 width=6 by cofrees_lref_skip/ 
-| elim (lt_or_ge j (|L|)) #Hj
-  [ elim (ldrop_O1_lt … Hj) -Hj /4 width=10 by cofrees_lref_gt, ex3_3_intro/
-  | elim H -H /2 width=6 by cofrees_lref_free/
-  ]
-]
-qed-.
-
-lemma frees_inv_lref_free: ∀L,d,i,j. (L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄  → ⊥) → |L| ≤ j → j = i.
-#L #d #i #j #H #Hj elim (lt_or_eq_or_gt i j) //
-#Hij elim H -H /2 width=6 by cofrees_lref_lt, cofrees_lref_free/
-qed-.
-
-lemma frees_inv_gen: ∀L,U,d,i. (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) →
-                     ∃∃U0.  ⦃⋆, L⦄ ⊢ U ▶*[d, ∞] U0 & (∀T. ⇧[i, 1] T ≡ U0 → ⊥).
-#L #U @(f2_ind … rfw … L U) -L -U
-#n #IH #L * *
-[ -IH #k #_ #d #i #H elim H -H //
-| #j #Hn #d #i #H elim (lt_or_eq_or_gt i j)
-  [ -n #Hij elim H -H /2 width=5 by cofrees_lref_lt/
-  | -H -n #H destruct /3 width=7 by lift_inv_lref2_be, ex2_intro/
-  | #Hji elim (frees_inv_lref_gt … H) // -H
-    #I #K #W1 #HLK #H #Hdj elim (IH … H) /2 width=3 by ldrop_fwd_rfw/ -H -n
-    #W2 #HW12 #HnW2 elim (lift_total W2 0 (j+1))
-    #U2 #HWU2 @(ex2_intro … U2) /2 width=7 by cpys_subst_Y2/ -I -L -K -W1 -d
-    #T2 #HTU2 elim (lift_div_le … HWU2 (i-j-1) 1 T2) /2 width=2 by/ -W2
-    >minus_plus <plus_minus_m_m //
-  ]
-| -IH #p #_ #d #i #H elim H -H //
-| #a #I #W #U #Hn #d #i #H elim (frees_inv_bind … H) -H
-  #H elim (IH … H) // -H -n
-  /4 width=9 by cpys_bind, nlift_bind_dx, nlift_bind_sn, ex2_intro/
-| #I #W #U #Hn #d #i #H elim (frees_inv_flat … H) -H
-  #H elim (IH … H) // -H -n
-  /4 width=9 by cpys_flat, nlift_flat_dx, nlift_flat_sn, ex2_intro/
-]
-qed-.
-
-lemma frees_ind: ∀L,d,i. ∀R:predicate term.
-                 (∀U1. (∀T1. ⇧[i, 1] T1 ≡ U1 → ⊥) → R U1) → 
-                 (∀U1,U2. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 → (L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄ → ⊥) → R U2 → R U1) →
-                 ∀U. (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) → R U.
-#L #d #i #R #IH1 #IH2 #U1 #H elim (frees_inv_gen … H) -H
-#U2 #H #HnU2 @(cpys_ind_dx … H) -U1 /4 width=8 by cofrees_inv_gen/
-qed-.
-
-(* Advanced negated properties **********************************************)
-
-lemma frees_be: ∀I,L,K,W,j. ⇩[j]L ≡ K.ⓑ{I}W →
-                ∀i. j < i → (K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄ → ⊥) →
-                ∀U. (∀T. ⇧[j, 1] T ≡ U → ⊥) →
-                ∀d. d ≤ yinj j → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥).
-/4 width=11 by cofrees_inv_be/ qed-.
-
-(* Relocation properties ****************************************************)
-
-lemma cofrees_lift_be: ∀d0,e0,i. d0 ≤ i → i ≤ d0 + e0 →
-                       ∀L,K,s. ⇩[s, d0, e0+1] L ≡ K → ∀T,U. ⇧[d0, e0+1] T ≡ U →
-                       ∀d. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
-#d0 #e0 #i #Hd0i #Hide0 #L #K #s #HLK #T1 #U1 #HTU1 #d #U2 #HU12
-elim (yle_split d0 d) #H1
-[ elim (yle_split d (d0+e0+1)) #H2
-  [ letin cpys_inv ≝ cpys_inv_lift1_ge_up
-  | letin cpys_inv ≝ cpys_inv_lift1_ge
-  ]
-| letin cpys_inv ≝ cpys_inv_lift1_be
-]
-elim (cpys_inv … HU12 … HLK … HTU1) // #T2 #_ #HTU2 -s -L -K -U1 -T1 -d
-elim (lift_split … HTU2 i e0) /2 width=2 by ex_intro/
-qed.
-
-lemma cofrees_lift_ge: ∀d0,e0,i. d0 + e0 ≤ i →
-                       ∀L,K,s. ⇩[s, d0, e0] L ≡ K → ∀T,U. ⇧[d0, e0] T ≡ U →
-                       ∀d. K ⊢ i-e0 ~ϵ 𝐅*[d-yinj e0]⦃T⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
-#d0 #e0 #i #Hde0i #L #K #s #HLK #T1 #U1 #HTU1 #d #HT1 #U2 #HU12
-elim (le_inv_plus_l … Hde0i) -Hde0i #Hd0ie0 #He0i
-elim (yle_split d0 d) #H1
-[ elim (yle_split d (d0+e0)) #H2
-  [ elim (cpys_inv_lift1_ge_up … HU12 … HLK … HTU1) // >yplus_inj >yminus_Y_inj #T2 #HT12
-    lapply (cpys_weak … HT12 (d-yinj e0) (∞) ? ?) /2 width=1 by yle_plus2_to_minus_inj2/ -HT12
-  | elim (cpys_inv_lift1_ge … HU12 … HLK … HTU1) // #T2
-  ]
-| elim (cpys_inv_lift1_be … HU12 … HLK … HTU1) // >yminus_Y_inj #T2 #HT12
-  lapply (cpys_weak … HT12 (d-yinj e0) (∞) ? ?) // -HT12
-]
--s -L #HT12 #HTU2
-elim (HT1 … HT12) -T1 #V2 #HVT2
-elim (lift_trans_le … HVT2 … HTU2 ?) // <plus_minus_m_m /2 width=2 by ex_intro/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofreestar_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cofrees/cofreestar_4.etc
deleted file mode 100644 (file)
index e73167c..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( L ⊢ break term 46 i ~ ϵ 𝐅 * [ break term 46 d ] ⦃ break term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'CoFreeStar $L $i $d $T }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpcs/cpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpcs/cpcs_cpcs.etc
deleted file mode 100644 (file)
index 1647052..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-lemma cpcs_beta_dx: ∀a,L,V1,V2,W1,W2,T1,T2.
-                    L ⊢ V1 ⬌* V2 → L ⊢ W1 ⬌* W2 → L.ⓛW2 ⊢ T1 ⬌* T2 →
-                    L ⊢ ⓐV1.ⓛ{a}W1.T1 ⬌* ⓓ{a}ⓝW2.V2.T2.
-#a #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HW12 #HT12
-@(cpcs_cpr_strap1 … (ⓐV2.ⓛ{a}W2.T2)) /2 width=1/ /3 width=1/
-qed.
-
-lemma cpcs_beta_sn: ∀a,L,V1,V2,W1,W2,T1,T2.
-                    L ⊢ V1 ⬌* V2 → L ⊢ W1 ⬌* W2 → L.ⓛW1 ⊢ T1 ⬌* T2 →
-                    L ⊢ ⓐV1.ⓛ{a}W1.T1 ⬌* ⓓ{a}ⓝW2.V2.T2.
-#a #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HW12 #HT12
-lapply (lsubr_cpcs_trans … HT12 (L.ⓓⓝW1.V1) ?) /2 width=1/ #H2T12
-@(cpcs_cpr_strap2 … (ⓓ{a}ⓝW1.V1.T1)) /2 width=1/ -HT12 /3 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpes.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpes.etc
deleted file mode 100644 (file)
index 96574d2..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-(* Advanced properties ******************************************************)
-
-lemma cpds_cpes_dx: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*➡*[h, g, l] T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
-#h #g #G #L #T1 #T2 #l * /3 width=6 by cpcs_cprs_dx, ex4_2_intro/
-qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cpes_inv_abst2: ∀h,g,a,G,L,W1,T1,T,l. ⦃G, L⦄ ⊢ T •*⬌*[h, g, l] ⓛ{a}W1.T1 →
-                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T •*➡*[h, g, l] ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
-#h #g #a #G #L #W1 #T1 #T #l2 * #T0 #l1 #Hl21 #HT #HT0 #H
-elim (cpcs_inv_abst2 … H) -H /3 width=6 by ex4_2_intro, ex2_2_intro/
-qed-.
-
-(****************************************************************************)
-
-lemma sta_cpcs_cpes: ∀h,g,G,L,T1,T,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l+1 → ⦃G, L⦄ ⊢ T1 •[h] T →
-                     ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, 1] T2.
-/3 width=6 by sta_lstas, ex4_2_intro/ qed.
-
-lemma lstas_cpes: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l → ⦃G, L⦄ ⊢ T1 •*[h, l] T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
-/2 width=6 by ex4_2_intro/ qed.
-                 
-lemma cpes_strap1: ∀h,g,G,L,T1,T,T2,l.
-                   ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T → ⦃G, L⦄ ⊢ T ⬌ T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
-#h #g #G #L #T1 #T #T2 #l * /3 width=8 by cpcs_strap1, ex4_2_intro/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_dx.etc
deleted file mode 100644 (file)
index 9319cc4..0000000
+++ /dev/null
@@ -1,78 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/ltpss_dx_ldrop.ma".
-include "basic_2/static/aaa_lift.ma".
-
-(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
-
-(* Properties about dx parallel unfold **************************************)
-
-lemma aaa_ltpss_dx_tpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                              ∀L2,d,e. L1 ▶* [d, e] L2 →
-                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → L2 ⊢ T2 ⁝ A.
-#L1 #T1 #A #H elim H -L1 -T1 -A
-[ #L1 #k #L2 #d #e #_ #T2 #H
-  >(tpss_inv_sort1 … H) -H //
-| #I #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi
-    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
-      /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
-    | elim (lt_or_ge i (d + e)) #Hide
-      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
-        /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
-      | -Hdi
-        lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide
-        /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=7/
-  ]
-| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=4/
-| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=4/
-| #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=4/
-| #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=4/
-]
-qed.
-
-lemma aaa_ltpss_dx_tps_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                             ∀L2,d,e. L1 ▶* [d, e] L2 →
-                             ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → L2 ⊢ T2 ⁝ A.
-/3 width=7/ qed.
-
-lemma aaa_ltpss_dx_conf: ∀L1,T,A. L1 ⊢ T ⁝ A →
-                         ∀L2,d,e. L1 ▶* [d, e] L2 → L2 ⊢ T ⁝ A.
-/2 width=7/ qed.
-
-lemma aaa_tpss_conf: ∀L,T1,A. L ⊢ T1 ⁝ A →
-                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T2 ⁝ A.
-/2 width=7/ qed.
-
-lemma aaa_tps_conf: ∀L,T1,A. L ⊢ T1 ⁝ A →
-                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → L ⊢ T2 ⁝ A.
-/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/aaa_ltpss_sn.etc
deleted file mode 100644 (file)
index 4f2a448..0000000
+++ /dev/null
@@ -1,37 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/static/aaa_ltpss_dx.ma".
-
-(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
-
-(* Properties about sn parallel unfold **************************************)
-
-lemma aaa_ltpss_sn_conf: ∀L1,T,A. L1 ⊢ T ⁝ A →
-                         ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 → L2 ⊢ T ⁝ A.
-#L1 #T #A #HT #L2 #d #e #HL12
-lapply (ltpss_sn_ltpssa … HL12) -HL12 #HL12
-@(TC_Conf3 … (λL,A. L ⊢ T ⁝ A) … HT ? HL12) /2 width=5/
-qed.
-
-lemma aaa_ltpss_sn_tpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                              ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → L2 ⊢ T2 ⁝ A.
-/3 width=5/ qed.
-
-lemma aaa_ltpss_sn_tps_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                             ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                             ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → L2 ⊢ T2 ⁝ A.
-/3 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cnf_cif.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cnf_cif.etc
deleted file mode 100644 (file)
index 5a1ae5a..0000000
+++ /dev/null
@@ -1,106 +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/reducibility/cif.ma".
-include "basic_2/reducibility/cnf_lift.ma".
-
-(* CONTEXT-SENSITIVE NORMAL TERMS *******************************************)
-
-(* Main properties **********************************************************)
-
-lemma tps_cif_eq: ∀L,T1,T2,d,e. L ⊢ T1 ▶[d, e] T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
-[ //
-| #L #K #V #W #i #d #e #_ #_ #HLK #_ #H -d -e
-  elim (cif_inv_delta … HLK ?) //
-| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #H
-  elim (cif_inv_bind … H) -H #HV1 #HT1 * #H destruct
-  lapply (IHV12 … HV1) -IHV12 -HV1 #H destruct /3 width=1/
-| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #H
-  elim (cif_inv_flat … H) -H #HV1 #HT1 #_ #_ /3 width=1/
-]
-qed.
-
-lemma tpss_cif_eq: ∀L,T1,T2,d,e. L ⊢ T1 ▶*[d, e] T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
-#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT1 #HT1
-lapply (IHT1 HT1) -IHT1 #H destruct /2 width=5/
-qed.
-
-lemma tpr_cif_eq: ∀T1,T2. T1 ➡ T2 → ∀L. L ⊢ 𝐈⦃T1⦄ → T1 = T2.
-#T1 #T2 #H elim H -T1 -T2
-[ //
-| * #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #L #H
-  [ elim (cif_inv_appl … H) -H #HV1 #HT1 #_
-    >IHV1 -IHV1 // -HV1 >IHT1 -IHT1 //
-  | elim (cif_inv_ri2 … H) /2 width=1/
-  ]
-| #a #V1 #V2 #W #T1 #T2 #_ #_ #_ #_ #L #H
-  elim (cif_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-| #a * #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV1 #IHT1 #L #H
-  [ lapply (tps_lsubr_trans … HT2 (L.ⓓV2) ?) -HT2 /2 width=1/ #HT2
-    elim (cif_inv_bind … H) -H #HV1 #HT1 * #H destruct
-    lapply (IHV1 … HV1) -IHV1 -HV1 #H destruct
-    lapply (IHT1 … HT1) -IHT1 #H destruct
-    lapply (tps_cif_eq … HT2 ?) -HT2 //
-  | <(tps_inv_refl_SO2 … HT2 ?) -HT2 //
-    elim (cif_inv_ib2 … H) -H /2 width=1/ /3 width=2/
-  ]
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #L #H
-  elim (cif_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-| #V1 #T1 #T #T2 #_ #_ #_ #L #H
-  elim (cif_inv_ri2 … H) /2 width=1/
-| #V1 #T1 #T2 #_ #_ #L #H
-  elim (cif_inv_ri2 … H) /2 width=1/
-]
-qed.
-
-lemma cpr_cif_eq: ∀L,T1,T2. L ⊢ T1 ➡ T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
-#L #T1 #T2 * #T0 #HT10 #HT02 #HT1
-lapply (tpr_cif_eq … HT10 … HT1) -HT10 #H destruct /2 width=5/
-qed.
-
-theorem cif_cnf: ∀L,T. L ⊢ 𝐈⦃T⦄ → L ⊢ 𝐍⦃T⦄.
-/3 width=3/ qed.
-
-(* Note: this property is unusual *)
-lemma cnf_crf_false: ∀L,T. L ⊢ 𝐑⦃T⦄ → L ⊢ 𝐍⦃T⦄ → ⊥.
-#L #T #H elim H -L -T
-[ #L #K #V #i #HLK #H
-  elim (cnf_inv_delta … HLK H)
-| #L #V #T #_ #IHV #H
-  elim (cnf_inv_appl … H) -H /2 width=1/
-| #L #V #T #_ #IHT #H
-  elim (cnf_inv_appl … H) -H /2 width=1/
-| #I #L #V #T * #H1 #H2 destruct
-  [ elim (cnf_inv_zeta … H2)
-  | elim (cnf_inv_tau … H2)
-  ]
-|5,6: #a * [ elim a ] #L #V #T * #H1 #_ #IH #H2 destruct
-  [1,3: elim (cnf_inv_abbr … H2) -H2 /2 width=1/
-  |*: elim (cnf_inv_abst … H2) -H2 /2 width=1/
-  ]
-| #a #L #V #W #T #H
-  elim (cnf_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-| #a #L #V #W #T #H
-  elim (cnf_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-]
-qed.
-
-theorem cnf_cif: ∀L,T. L ⊢ 𝐍⦃T⦄ → L ⊢ 𝐈⦃T⦄.
-/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_dx.etc
deleted file mode 100644 (file)
index 80f418b..0000000
+++ /dev/null
@@ -1,50 +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/computation/cprs_ltpss_dx.ma".
-include "basic_2/equivalence/cpcs_cpcs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
-
-(* Properties concerning dx partial unfold on local environments ************)
-
-lemma cpcs_ltpss_dx_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
-                          ∀T1,T2. L1 ⊢ T1 ⬌* T2 → L2 ⊢ T1 ⬌* T2.
-#L1 #L2 #d #e #HL12 #T1 #T2 #H
-elim (cpcs_inv_cprs … H) -H #T #HT1 #HT2
-elim (cprs_ltpss_dx_conf … HT1 … HL12) -HT1 #U1 #HTU1 #H1
-elim (cprs_ltpss_dx_conf … HT2 … HL12) -L1 #U2 #HTU2 #H2
-elim (tpss_conf_eq … H1 … H2) -T #U #HU1 #HU2
-lapply (cprs_tpss_trans … HTU1 … HU1) -U1
-lapply (cprs_tpss_trans … HTU2 … HU2) -U2 /2 width=3/
-qed-.
-
-lemma cpcs_ltpss_dx_tpss_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
-                               ∀T,T2. L1 ⊢ T ⬌* T2 →
-                               ∀T1. L2 ⊢ T ▶* [d, e] T1 →
-                               L2 ⊢ T1 ⬌* T2.
-#L1 #L2 #d #e #HL12 #T #T2 #HT2 #T1 #HT1
-lapply (cpcs_ltpss_dx_conf … HL12 … HT2) -L1 #HT2
-lapply (cpcs_tpss_conf … HT1 … HT2) -T //
-qed-.
-
-lemma cpcs_ltpss_dx_tpss2_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
-                                ∀T1,T2. L1 ⊢ T1 ⬌* T2 →
-                                ∀T3. L2 ⊢ T1 ▶* [d, e] T3 →
-                                ∀T4. L2 ⊢ T2 ▶* [d, e] T4 →
-                                L2 ⊢ T3 ⬌* T4.
-#L1 #L2 #d #e #HL12 #T1 #T2 #HT12 #T3 #HT13 #T4 #HT24
-lapply (cpcs_ltpss_dx_tpss_conf … HL12 … HT12 … HT13) -L1 -T1 #HT32
-lapply (cpcs_tpss_strap1 … HT32 … HT24) -T2 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpcs_ltpss_sn.etc
deleted file mode 100644 (file)
index 5bf1ed5..0000000
+++ /dev/null
@@ -1,28 +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/equivalence/cpcs_ltpss_dx.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
-
-(* Properties concerning sn partial unfold on local environments ************)
-
-lemma cpcs_ltpss_sn_conf: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                          ∀T1,T2. L1 ⊢ T1 ⬌* T2 → L2 ⊢ T1 ⬌* T2.
-#L1 #L2 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 //
-#L #L2 #_ #HL2 #IHL1 #T1 #U1 #HTU1
-lapply (IHL1 … HTU1) -IHL1 -HTU1 #HTU1
-lapply (cpcs_ltpss_dx_conf … HL2 … HTU1) -HTU1 -HL2 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr.etc
deleted file mode 100644 (file)
index d82299c..0000000
+++ /dev/null
@@ -1,111 +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/unfold/tpss.ma".
-include "basic_2/reducibility/tpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Basic_1: includes: pr2_delta1 *)
-definition cpr: lenv → relation term ≝
-   λL,T1,T2. ∃∃T. T1 ➡ T & L ⊢ T ▶* [0, |L|] T2.
-
-interpretation
-   "context-sensitive parallel reduction (term)"
-   'PRed L T1 T2 = (cpr L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma cpr_intro: ∀L,T1,T,T2,d,e. T1 ➡ T → L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
-/3 width=5/ qed-.
-
-(* Basic_1: was by definition: pr2_free *)
-lemma cpr_tpr: ∀T1,T2. T1 ➡ T2 → ∀L. L ⊢ T1 ➡ T2.
-/2 width=3/ qed.
-
-lemma cpr_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
-/3 width=5/ qed.
-
-lemma cpr_refl: ∀L,T. L ⊢ T ➡ T.
-/2 width=1/ qed.
-
-(* Note: new property *)
-(* Basic_1: was only: pr2_thin_dx *)
-lemma cpr_flat: ∀I,L,V1,V2,T1,T2.
-                L ⊢ V1 ➡ V2 → L ⊢ T1 ➡ T2 → L ⊢ ⓕ{I} V1. T1 ➡ ⓕ{I} V2. T2.
-#I #L #V1 #V2 #T1 #T2 * #V #HV1 #HV2 * /3 width=5/
-qed.
-
-lemma cpr_cast: ∀L,V,T1,T2.
-                L ⊢ T1 ➡ T2 → L ⊢ ⓝV. T1 ➡ T2.
-#L #V #T1 #T2 * /3 width=3/
-qed.
-
-(* Note: it does not hold replacing |L1| with |L2| *)
-(* Basic_1: was only: pr2_change *)
-lemma cpr_lsubr_trans: ∀L1,T1,T2. L1 ⊢ T1 ➡ T2 →
-                       ∀L2. L2 ⊑ [0, |L1|] L1 → L2 ⊢ T1 ➡ T2.
-#L1 #T1 #T2 * #T #HT1 #HT2 #L2 #HL12
-lapply (tpss_lsubr_trans … HT2 … HL12) -HT2 -HL12 /3 width=4/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-(* Basic_1: was: pr2_gen_csort *)
-lemma cpr_inv_atom: ∀T1,T2. ⋆ ⊢ T1 ➡ T2 → T1 ➡ T2.
-#T1 #T2 * #T #HT normalize #HT2
-<(tpss_inv_refl_O2 … HT2) -HT2 //
-qed-.
-
-(* Basic_1: was: pr2_gen_sort *)
-lemma cpr_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ➡ T2 → T2 = ⋆k.
-#L #T2 #k * #X #H
->(tpr_inv_atom1 … H) -H #H
->(tpss_inv_sort1 … H) -H //
-qed-.
-
-(* Basic_1: was: pr2_gen_cast *)
-lemma cpr_inv_cast1: ∀L,V1,T1,U2. L ⊢ ⓝV1. T1 ➡ U2 → (
-                        ∃∃V2,T2. L ⊢ V1 ➡ V2 & L ⊢ T1 ➡ T2 &
-                                 U2 = ⓝV2. T2
-                     ) ∨ L ⊢ T1 ➡ U2.
-#L #V1 #T1 #U2 * #X #H #HU2
-elim (tpr_inv_cast1 … H) -H /3 width=3/
-* #V #T #HV1 #HT1 #H destruct
-elim (tpss_inv_flat1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma cpr_fwd_bind1_minus: ∀I,L,V1,T1,T. L ⊢ -ⓑ{I}V1.T1 ➡ T → ∀b.
-                           ∃∃V2,T2. L ⊢ ⓑ{b,I}V1.T1 ➡ ⓑ{b,I}V2.T2 &
-                                    T = -ⓑ{I}V2.T2.
-#I #L #V1 #T1 #T * #X #H1 #H2 #b
-elim (tpr_fwd_bind1_minus … H1 b) -H1 #V0 #T0 #HT10 #H destruct
-elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct /4 width=5/
-qed-.
-
-lemma cpr_fwd_shift1: ∀L,L1,T1,T. L ⊢ L1 @@ T1 ➡ T →
-                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#L #L1 #T1 #T * #X #H1 #H2
-elim (tpr_fwd_shift1 … H1) -H1 #L0 #T0 #HL10 #H destruct
-elim (tpss_fwd_shift1 … H2) -H2 #L2 #T2 #HL02 #H destruct /2 width=4/
-qed-.
-
-(* Basic_1: removed theorems 6:
-            pr2_head_2 pr2_cflat pr2_gen_cflat clear_pr2_trans
-            pr2_gen_ctail pr2_ctail
-   Basic_1: removed local theorems 3:
-            pr2_free_free pr2_free_delta pr2_delta_delta
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_aaa.etc
deleted file mode 100644 (file)
index 7c12733..0000000
+++ /dev/null
@@ -1,25 +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/static/aaa_ltpss_sn.ma".
-include "basic_2/reducibility/ltpr_aaa.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_cpr_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. L ⊢ T1 ➡ T2 → L ⊢ T2 ⁝ A.
-#L #T1 #A #HT1 #T2 * /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_cpr.etc
deleted file mode 100644 (file)
index d231c84..0000000
+++ /dev/null
@@ -1,63 +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/reducibility/tpr_tpr.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Advanced properties ******************************************************)
-
-lemma cpr_bind_sn: ∀a,I,L,V1,V2,T1,T2. L ⊢ V1 ➡ V2 → T1 ➡ T2 →
-                   L ⊢ ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
-#a #I #L #V1 #V2 #T1 #T2 * #V #HV1 #HV2 #HT12
-@ex2_intro [2: @(tpr_delta … HV1 HT12) | skip ] /2 width=3/ (* /3 width=5/ is too slow *)
-qed.
-
-(* Basic_1: was only: pr2_gen_cbind *)
-lemma cpr_bind_dx: ∀a,I,L,V1,V2,T1,T2. V1 ➡ V2 → L. ⓑ{I} V2 ⊢ T1 ➡ T2 →
-                   L ⊢ ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
-#a #I #L #V1 #V2 #T1 #T2 #HV12 * #T #HT1 normalize #HT2
-elim (tpss_split_up … HT2 1 ? ?) -HT2 // #T0 <minus_n_O #HT0 normalize <minus_plus_m_m #HT02
-lapply (tpss_lsubr_trans … HT0 (⋆. ⓑ{I} V2) ?) -HT0 /2 width=1/ #HT0
-lapply (tpss_inv_SO2 … HT0) -HT0 #HT0
-@ex2_intro [2: @(tpr_delta … HV12 HT1 HT0) | skip | /2 width=1/ ] (**) (* /3 width=5/ is too slow *)
-qed.
-
-(* Basic_1: was only: pr2_head_1 *)
-lemma cpr_pair_sn: ∀I,L,V1,V2,T1,T2. L ⊢ V1 ➡ V2 → T1 ➡ T2 →
-                   L ⊢ ②{I} V1. T1 ➡ ②{I} V2. T2.
-* /2 width=1/ /3 width=1/
-qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma cpr_shift_fwd: ∀L,T1,T2. L ⊢ T1 ➡ T2 → L @@ T1 ➡ L @@ T2.
-#L elim L -L
-[ #T1 #T2 #HT12 @(cpr_inv_atom … HT12)
-| normalize /3 width=1/
-].
-qed-.
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: pr2_confluence *)
-theorem cpr_conf: ∀L,U0,T1,T2. L ⊢ U0 ➡ T1 → L ⊢ U0 ➡ T2 →
-                  ∃∃T. L ⊢ T1 ➡ T & L ⊢ T2 ➡ T.
-#L #U0 #T1 #T2 * #U1 #HU01 #HUT1 * #U2 #HU02 #HUT2
-elim (tpr_conf … HU01 HU02) -U0 #U #HU1 #HU2
-elim (ltpr_tpr_tpss_conf ? L … HU1 … HUT1) -U1 // #U1 #HTU1 #HU1
-elim (ltpr_tpr_tpss_conf ? L … HU2 … HUT2) -U2 // #U2 #HTU2 #HU2
-elim (tpss_conf_eq … HU1 … HU2) -U /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_lift.etc
deleted file mode 100644 (file)
index 0a7afdd..0000000
+++ /dev/null
@@ -1,180 +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/unfold/tpss_lift.ma".
-include "basic_2/reducibility/tpr_lift.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Advanced properties ******************************************************)
-
-lemma cpr_cdelta: ∀L,K,V1,W1,W2,i.
-                  ⇩[0, i] L ≡ K. ⓓV1 → K ⊢ V1 ▶* [0, |L| - i - 1] W1 →
-                  ⇧[0, i + 1] W1 ≡ W2 → L ⊢ #i ➡ W2.
-#L #K #V1 #W1 #W2 #i #HLK #HVW1 #HW12
-lapply (ldrop_fwd_ldrop2_length … HLK) #Hi
-@ex2_intro [2: // | skip | @tpss_subst /width=6/ ] (**) (* /3 width=6/ is too slow *)
-qed.
-
-lemma cpr_abst: ∀L,V1,V2. L ⊢ V1 ➡ V2 → ∀V,T1,T2. L.ⓛV ⊢ T1 ➡ T2 →
-                          ∀a,I. L ⊢ ⓑ{a,I}V1. T1 ➡ ⓑ{a,I}V2. T2.
-#L #V1 #V2 * #V0 #HV10 #HV02 #V #T1 #T2 * #T0 #HT10 #HT02 #a #I
-lapply (tpss_inv_S2 … HT02 L V ?) -HT02 // #HT02
-lapply (tpss_lsubr_trans … HT02 (L.ⓑ{I}V2) ?) -HT02 /2 width=1/ #HT02
-@(ex2_intro … (ⓑ{a,I}V0.T0)) /2 width=1/ (* explicit constructors *)
-qed.
-
-lemma cpr_beta: ∀a,L,V1,V2,W,T1,T2.
-                L ⊢ V1 ➡ V2 → L.ⓛW ⊢ T1 ➡ T2 → L ⊢ ⓐV1.ⓛ{a}W.T1 ➡ ⓓ{a}V2.T2.
-#a #L #V1 #V2 #W #T1 #T2 * #V #HV1 #HV2 * #T #HT1 #HT2
-lapply (tpss_inv_S2 … HT2 L W ?) -HT2 // #HT2
-lapply (tpss_lsubr_trans … HT2 (L.ⓓV2) ?) -HT2 /2 width=1/ #HT2
-@(ex2_intro … (ⓓ{a}V.T)) /2 width=1/ (**) (* explicit constructor, /3/ is too slow *)
-qed.
-
-lemma cpr_beta_dx: ∀a,L,V1,V2,W,T1,T2.
-                   V1 ➡ V2 → L.ⓛW ⊢ T1 ➡ T2 → L ⊢ ⓐV1.ⓛ{a}W.T1 ➡ ⓓ{a}V2.T2.
-/3 width=1/ qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-(* Basic_1: was: pr2_gen_lref *)
-lemma cpr_inv_lref1: ∀L,T2,i. L ⊢ #i ➡ T2 →
-                     T2 = #i ∨
-                     ∃∃K,V1,T1. ⇩[0, i] L ≡ K. ⓓV1 &
-                                K ⊢ V1 ▶* [0, |L| - i - 1] T1 &
-                                ⇧[0, i + 1] T1 ≡ T2 &
-                                i < |L|.
-#L #T2 #i * #X #H
->(tpr_inv_atom1 … H) -H #H
-elim (tpss_inv_lref1 … H) -H /2 width=1/
-* /3 width=6/
-qed-.
-
-(* Basic_1: was pr2_gen_abbr *)
-lemma cpr_inv_abbr1: ∀a,L,V1,T1,U2. L ⊢ ⓓ{a}V1. T1 ➡ U2 →
-                     (∃∃V,V2,T2. V1 ➡ V & L ⊢ V ▶* [O, |L|] V2 &
-                                 L. ⓓV ⊢ T1 ➡ T2 &
-                                 U2 = ⓓ{a}V2. T2
-                      ) ∨
-                      ∃∃T2. L.ⓓV1 ⊢ T1 ➡ T2 & ⇧[0,1] U2 ≡ T2 & a = true.
-#a #L #V1 #T1 #Y * #X #H1 #H2
-elim (tpr_inv_abbr1 … H1) -H1 *
-[ #V #T #T0 #HV1 #HT1 #HT0 #H destruct
-  elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT02 #H destruct
-  lapply (tps_lsubr_trans … HT0 (L. ⓓV) ?) -HT0 /2 width=1/ #HT0
-  lapply (tps_weak_full … HT0) -HT0 #HT0
-  lapply (tpss_lsubr_trans … HT02 (L. ⓓV) ?) -HT02 /2 width=1/ #HT02
-  lapply (tpss_weak_full … HT02) -HT02 #HT02
-  lapply (tpss_strap2 … HT0 HT02) -T0 /4 width=7/
-| #T2 #HT12 #HXT2 #H destruct
-  elim (lift_total Y 0 1) #Z #HYZ
-  lapply (tpss_lift_ge … H2 (L.ⓓV1) … HXT2 … HYZ) -X // /2 width=1/ #H
-  lapply (cpr_intro … HT12 … H) -T2 /3 width=3/
-]
-qed-.
-
-(* Basic_1: was: pr2_gen_abst *)
-lemma cpr_inv_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a}V1. T1 ➡ U2 → ∀I,W.
-                     ∃∃V2,T2. L ⊢ V1 ➡ V2 & L. ⓑ{I} W ⊢ T1 ➡ T2 & U2 = ⓛ{a}V2. T2.
-#a #L #V1 #T1 #Y * #X #H1 #H2 #I #W
-elim (tpr_inv_abst1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
-elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-lapply (tpss_lsubr_trans … HT2 (L. ⓑ{I} W) ?) -HT2 /2 width=1/ /4 width=5/
-qed-.
-
-(* Basic_1: was pr2_gen_appl *)
-lemma cpr_inv_appl1: ∀L,V1,U0,U2. L ⊢ ⓐV1. U0 ➡ U2 →
-                     ∨∨ ∃∃V2,T2.              L ⊢ V1 ➡ V2 & L ⊢ U0 ➡ T2 &
-                                              U2 = ⓐV2. T2
-                      | ∃∃a,V2,W,T1,T2.       L ⊢ V1 ➡ V2 & L. ⓓV2 ⊢ T1 ➡ T2 &
-                                              U0 = ⓛ{a}W. T1 &
-                                              U2 = ⓓ{a}V2. T2
-                      | ∃∃a,V2,V,W1,W2,T1,T2. L ⊢ V1 ➡ V2 & L ⊢ W1 ➡ W2 & L. ⓓW2 ⊢ T1 ➡ T2 &
-                                              ⇧[0,1] V2 ≡ V &
-                                              U0 = ⓓ{a}W1. T1 &
-                                              U2 = ⓓ{a}W2. ⓐV. T2.
-#L #V1 #U0 #Y * #X #H1 #H2
-elim (tpr_inv_appl1 … H1) -H1 *
-[ #V #U #HV1 #HU0 #H destruct
-  elim (tpss_inv_flat1 … H2) -H2 #V2 #U2 #HV2 #HU2 #H destruct /4 width=5/
-| #a #V #W #T0 #T #HV1 #HT0 #H #H1 destruct
-  elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-  lapply (tpss_weak … HT2 0 (|L|+1) ? ?) -HT2 // /4 width=9/
-| #a #V0 #V #W #W0 #T #T0 #HV10 #HW0 #HT0 #HV0 #H #H1 destruct
-  elim (tpss_inv_bind1 … H2) -H2 #W2 #X #HW02 #HX #HY destruct
-  elim (tpss_inv_flat1 … HX) -HX #V2 #T2 #HV2 #HT2 #H destruct
-  elim (tpss_inv_lift1_ge … HV2 … HV0 ?) -V // [3: /2 width=1/ |2: skip ] #V <minus_plus_m_m
-  lapply (tpss_weak … HT2 0 (|L|+1) ? ?) -HT2 // /4 width=13/
-]
-qed-.
-
-(* Note: the main property of simple terms *)
-lemma cpr_inv_appl1_simple: ∀L,V1,T1,U. L ⊢ ⓐV1. T1 ➡ U → 𝐒⦃T1⦄ →
-                            ∃∃V2,T2. L ⊢ V1 ➡ V2 & L ⊢ T1 ➡ T2 &
-                                     U = ⓐV2. T2.
-#L #V1 #T1 #U #H #HT1
-elim (cpr_inv_appl1 … H) -H *
-[ /2 width=5/
-| #a #V2 #W #W1 #W2 #_ #_ #H #_ destruct
-  elim (simple_inv_bind … HT1)
-| #a #V2 #V #W1 #W2 #U1 #U2 #_ #_ #_ #_ #H #_ destruct
-  elim (simple_inv_bind … HT1)
-]
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma cpr_fwd_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a}V1.T1 ➡ U2 → ∀b,I,W.
-                     ∃∃V2,T2. L ⊢ ⓑ{b,I}W.T1 ➡ ⓑ{b,I}W.T2 &
-                              U2 = ⓛ{a}V2.T2.
-#a #L #V1 #T1 #U2 * #U #H #HU2 #b #I #W
-elim (tpr_fwd_abst1 … H b I W) -H #V #T #HT1 #H destruct
-elim (tpss_inv_bind1 … HU2) -HU2 #V2 #T2 #_ #HT2
-lapply (tpss_lsubr_trans … HT2 (L.ⓑ{I}W) ?) -HT2 /2 width=1/ /4 width=5/
-qed-.
-
-(* Relocation properties ****************************************************)
-
-(* Basic_1: was: pr2_lift *)
-lemma cpr_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K →
-                ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
-                K ⊢ T1 ➡ T2 → L ⊢ U1 ➡ U2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 * #T #HT1 #HT2
-elim (lift_total T d e) #U #HTU
-lapply (tpr_lift … HT1 … HTU1 … HTU) -T1 #HU1
-elim (lt_or_ge (|K|) d) #HKd
-[ lapply (tpss_lift_le … HT2 … HLK HTU … HTU2) -T2 -T -HLK [ /2 width=2/ | /3 width=4/ ]
-| lapply (tpss_lift_be … HT2 … HLK HTU … HTU2) -T2 -T -HLK // /3 width=4/
-]
-qed.
-
-(* Basic_1: was: pr2_gen_lift *)
-lemma cpr_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
-                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀U2. L ⊢ U1 ➡ U2 →
-                     ∃∃T2. ⇧[d, e] T2 ≡ U2 & K ⊢ T1 ➡ T2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #U2 * #U #HU1 #HU2
-elim (tpr_inv_lift1 … HU1 … HTU1) -U1 #T #HTU #T1
-elim (lt_or_ge (|L|) d) #HLd
-[ elim (tpss_inv_lift1_le … HU2 … HLK … HTU ?) -U -HLK /2 width=2/
-  /3 width=7 by ex2_intro, cpr_intro/
-| elim (lt_or_ge (|L|) (d + e)) #HLde
-  [ elim (tpss_inv_lift1_be_up … HU2 … HLK … HTU ? ?) -U -HLK // /2 width=2/
-    /3 width=7 by ex2_intro, cpr_intro/
-  | elim (tpss_inv_lift1_be … HU2 … HLK … HTU ? ?) -U -HLK //
-    /3 width=7 by ex2_intro, cpr_intro/
-  ]
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpr.etc
deleted file mode 100644 (file)
index ab10e3f..0000000
+++ /dev/null
@@ -1,46 +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/reducibility/ltpr_tpss.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties concerning parallel unfold on terms ***************************)
-
-(* Note: we could invoke tpss_weak_full instead of ltpr_fwd_length *)
-(* Basic_1: was only: pr2_subst1 *)
-lemma cpr_tpss_ltpr: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. L2 ⊢ T1 ➡ T2 →
-                     ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
-                     ∃∃U2. L2 ⊢ U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
-#L1 #L2 #HL12 #T1 #T2 * #T #HT1 #HT2 #d #e #U1 #HTU1
-elim (ltpr_tpr_tpss_conf … HL12 … HT1 … HTU1) -L1 -HT1 #U #HU1 #HTU
-elim (tpss_conf_eq … HT2 … HTU) -T /3 width=3/
-qed.
-
-lemma cpr_ltpr_conf_eq: ∀L1,T1,T2. L1 ⊢ T1 ➡ T2 → ∀L2. L1 ➡ L2 →
-                        ∃∃T. L2 ⊢ T1 ➡ T & T2 ➡ T.
-#L1 #T1 #T2 * #T #HT1 #HT2 #L2 #HL12
->(ltpr_fwd_length … HL12) in HT2; #HT2
-elim (ltpr_tpr_tpss_conf … HL12 … HT2) -L1 /3 width=3/
-qed.
-
-lemma cpr_ltpr_conf_tpss: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. L1 ⊢ T1 ➡ T2 →
-                          ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
-                          ∃∃U2. L2 ⊢ U1 ➡ U2 & L2 ⊢ T2 ➡ U2.
-#L1 #L2 #HL12 #T1 #T2 #HT12 #d #e #U1 #HTU1
-elim (cpr_ltpr_conf_eq … HT12 … HL12) -HT12 #T #HT1 #HT2
-elim (cpr_tpss_ltpr … HL12 … HT1 … HTU1) -L1 -HT1 #U2 #HU12 #HTU2
-lapply (tpss_weak_full … HTU2) -HTU2 #HTU2 /3 width=5/ (**) (* /4 width=5/ is too slow *)
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_dx.etc
deleted file mode 100644 (file)
index 5d90e68..0000000
+++ /dev/null
@@ -1,28 +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/unfold/ltpss_dx_ltpss_dx.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties concerning dx partial unfold on local environments ************)
-
-lemma ltpss_dx_cpr_conf: ∀L1,T,U1. L1 ⊢ T ➡ U1 →
-                         ∀L2,d,e. L1 ▶* [d, e] L2 →
-                         ∃∃U2. L2 ⊢ T ➡ U2 & L2 ⊢ U1 ▶* [d, e] U2.
-#L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
-lapply (ltpss_dx_fwd_length … HL12) #H >H in HU1; -H #HU1
-elim (ltpss_dx_tpss_conf … HU1 … HL12) -L1 /3 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_ltpss_sn.etc
deleted file mode 100644 (file)
index f946e4c..0000000
+++ /dev/null
@@ -1,35 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties concerning sn partial unfold on local environments ************)
-
-lemma ltpss_sn_cpr_trans: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                          ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
-#L1 #L2 #d #e #HL12 #T1 #T2 *
-lapply (ltpss_sn_weak_full … HL12)
-<(ltpss_sn_fwd_length … HL12) -HL12 /3 width=5/
-qed.
-
-lemma ltpss_sn_cpr_conf: ∀L1,T,U1. L1 ⊢ T ➡ U1 →
-                         ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                         ∃∃U2. L2 ⊢ T ➡ U2 & L1 ⊢ U1 ▶* [d, e] U2.
-#L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
-lapply (ltpss_sn_fwd_length … HL12) #H >H in HU1; -H #HU1
-elim (ltpss_sn_tpss_conf … HU1 … HL12) -HU1 -HL12 /3 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cpr_tpss.etc
deleted file mode 100644 (file)
index d8c7225..0000000
+++ /dev/null
@@ -1,39 +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/reducibility/ltpr_tpss.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties on partial unfold for terms ***********************************)
-
-lemma cpr_tpss_trans: ∀L,T1,T. L ⊢ T1 ➡ T →
-                      ∀T2,d,e. L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
-#L #T1 #T * #T0 #HT10 #HT0 #T2 #d #e #HT2
-lapply (tpss_weak_full … HT2) -HT2 #HT2
-lapply (tpss_trans_eq … HT0 HT2) -T /2 width=3/
-qed.
-
-lemma cpr_tps_trans: ∀L,T1,T. L ⊢ T1 ➡ T →
-                     ∀T2,d,e. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ➡ T2.
-/3 width=5/ qed.
-
-lemma cpr_tpss_conf: ∀L,T0,T1. L ⊢ T0 ➡ T1 →
-                     ∀T2,d,e. L ⊢ T0 ▶* [d, e] T2 →
-                     ∃∃T. L ⊢ T1 ▶* [d, e] T & L ⊢ T2 ➡ T.
-#L #T0 #T1 * #U0 #HTU0 #HU0T1 #T2 #d #e #HT02
-elim (tpr_tpss_conf … HTU0 … HT02) -T0 #T0 #HT20 #HUT0
-elim (tpss_conf_eq … HU0T1 … HUT0) -U0 /3 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpr.etc
deleted file mode 100644 (file)
index 2682a76..0000000
+++ /dev/null
@@ -1,32 +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/reducibility/cpr_ltpr.ma".
-include "basic_2/computation/cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties concerning parallel unfold on terms ***************************)
-
-(* Basic_1: was only: pr3_subst1 *)
-lemma cprs_tpss_ltpr: ∀L1,T1,U1,d,e. L1 ⊢ T1 ▶* [d, e] U1 →
-                      ∀L2. L1 ➡ L2 → ∀T2. L2 ⊢ T1 ➡* T2 →
-                      ∃∃U2. L2 ⊢ U1 ➡* U2 & L2 ⊢ T2 ▶* [d, e] U2.
-#L1 #T1 #U1 #d #e #HTU1 #L2 #HL12 #T2 #HT12 elim HT12 -T2
-[ #T2 #HT12
-  elim (cpr_tpss_ltpr … HL12 … HT12 … HTU1) -L1 -T1 /3 width=3/
-| #T #T2 #_ #HT2 * #U #HU1 #HTU
-  elim (cpr_tpss_ltpr … HT2 … HTU) -L1 -T // /3 width=3/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_dx.etc
deleted file mode 100644 (file)
index 7f86180..0000000
+++ /dev/null
@@ -1,52 +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/reducibility/cpr_ltpss_dx.ma".
-include "basic_2/computation/cprs_tpss.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties concerning dx partial unfold on local environments ************)
-
-lemma cprs_ltpss_dx_conf: ∀L1,T,U1. L1 ⊢ T ➡* U1 →
-                          ∀L2,d,e. L1 ▶* [d, e] L2 →
-                          ∃∃U2. L2 ⊢ T ➡* U2 & L2 ⊢ U1 ▶* [d, e] U2.
-#L1 #T #U1 #H @(cprs_ind … H) -U1 /2 width=3/
-#T1 #U1 #_ #HTU1 #IHT1 #L2 #d #e #HL12
-elim (IHT1 … HL12) -IHT1 #U #HTU #HT1U
-elim (ltpss_dx_cpr_conf … HTU1 … HL12) -L1 #U0 #HT1U0 #HU10
-elim (cpr_tpss_conf … HT1U0 … HT1U) -T1 #U2 #HU02 #HU2
-lapply (tpss_trans_eq … HU10 HU02) -U0 /3 width=3/
-qed-.
-
-lemma cprs_ltpss_dx_tpss_conf: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
-                               ∀L2,d,e. L1 ▶* [d, e] L2 →
-                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                               ∃∃U2. L2 ⊢ T2 ➡* U2 & L2 ⊢ U1 ▶* [d, e] U2.
-#L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
-elim (cprs_ltpss_dx_conf … HTU1 … HL12) -L1 #U #HT1U #HU1
-elim (cprs_tpss_conf … HT1U … HT12) -T1 #T #HUT #HT2
-lapply (tpss_trans_eq … HU1 HUT) -U /2 width=3/
-qed-.
-
-lemma cprs_ltpss_dx_tpss2_conf: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
-                                ∀L2,d,e. L1 ▶* [d, e] L2 →
-                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                                ∀U2. L2 ⊢ U1 ▶* [d, e] U2 →
-                                ∃∃U. L2 ⊢ T2 ➡* U & L2 ⊢ U2 ▶* [d, e] U.
-#L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12 #U2 #HU12
-elim (cprs_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -L1 -T1 #U #HT2U #HU1
-elim (tpss_conf_eq … HU12 … HU1) -U1 #U0 #HU20 #HU0
-lapply (cprs_tpss_trans … HT2U … HU0) -U /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_ltpss_sn.etc
deleted file mode 100644 (file)
index 32009d1..0000000
+++ /dev/null
@@ -1,34 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/computation/cprs_ltpss_dx.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties concerning sn partial unfold on local environments ************)
-
-lemma cprs_ltpss_sn_conf: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                          ∀T,U1. L1 ⊢ T ➡* U1 →
-                          ∃∃U2. L2 ⊢ T ➡* U2 & L1 ⊢ U1 ▶* [d, e] U2.
-#L1 #L2 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 /2 width=3/
-#L #L2 #HL1 #HL2 #IHL1 #T #U1 #HTU1
-lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
-lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
-elim (IHL1 … HTU1) -IHL1 -HTU1 #U #HTU #HU1
-elim (cprs_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #HTU2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/cprs_tpss.etc
deleted file mode 100644 (file)
index 0c575ae..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/reducibility/cpr_tpss.ma".
-include "basic_2/computation/cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties on partial unfold for terms ***********************************)
-
-lemma cprs_tpss_trans: ∀L,T1,T. L ⊢ T1 ➡* T →
-                       ∀T2,d,e. L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡* T2.
-#L #T1 #T #H @(cprs_ind … H) -T /2 width=3/ /3 width=5/
-qed.
-
-lemma cprs_tps_trans: ∀L,T1,T. L ⊢ T1 ➡* T →
-                      ∀T2,d,e. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ➡* T2.
-/3 width=5 by inj, cprs_tpss_trans/ qed. (**) (* auto too slow without trace *)
-
-lemma cprs_tpss_conf: ∀L,T0,T1. L ⊢ T0 ➡* T1 →
-                      ∀T2,d,e. L ⊢ T0 ▶* [d, e] T2 →
-                      ∃∃T. L ⊢ T1 ▶* [d, e] T & L ⊢ T2 ➡* T.
-#L #T0 #T1 #H @(cprs_ind … H) -T1 /2 width=3/
-#T #T1 #_ #HT1 #IHT0 #T2 #d #e #HT02
-elim (IHT0 … HT02) -T0 #T0 #HT0 #HT20
-elim (cpr_tpss_conf … HT1 … HT0) -T /3 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_dx.etc
deleted file mode 100644 (file)
index 8e3260d..0000000
+++ /dev/null
@@ -1,50 +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/unwind/sstas_ltpss_dx.ma".
-include "basic_2/computation/cprs_ltpss_dx.ma".
-include "basic_2/computation/dxprs.ma".
-
-(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
-
-(* Properties about dx parallel unfold **************************************)
-
-lemma dxprs_ltpss_dx_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 →
-                           ∀L2,d,e. L1 ▶* [d, e] L2 →
-                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
-elim (sstas_ltpss_dx_conf … HTU … HL12) -HTU #U0 #HTU0 #HU0
-elim (cprs_ltpss_dx_conf … HU1 … HL12) -L1 #U2 #HU2 #HU12
-elim (cprs_tpss_conf … HU2 … HU0) -U #U #HU2 #HU0
-lapply (tpss_trans_eq … HU12 HU2) -U2 /3 width=3/
-qed-.
-
-lemma dxprs_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*➡*[g] U1 →
-                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*➡*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
-#h #g #L #T1 #U1 * #W1 #HTW1 #HWU1 #T2 #d #e #HT12
-elim (sstas_tpss_conf … HTW1 … HT12) -T1 #W2 #HTW2 #HW12
-elim (cprs_tpss_conf … HWU1 … HW12) -W1 /3 width=3/
-qed-.
-
-lemma dxprs_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*➡*[g] U1 →
-                                ∀L2,d,e. L1 ▶* [d, e] L2 →
-                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*➡*[g] U2 &
-                                      L2 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
-elim (dxprs_ltpss_dx_conf … HTU1 … HL12) -L1 #U #HT1U #HU1
-elim (dxprs_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/dxprs_ltpss_sn.etc
deleted file mode 100644 (file)
index 553e465..0000000
+++ /dev/null
@@ -1,34 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/computation/dxprs_ltpss_dx.ma".
-
-(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
-
-(* Properties about sn parallel unfold **************************************)
-
-lemma dxprs_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                           ∀T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 →
-                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L1 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #L2 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 [ /2 width=3/ ]
-#L #L2 #HL1 #HL2 #IHL1 #T #U1 #HTU1
-lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
-lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
-elim (IHL1 … HTU1) -IHL1 -HTU1 #U #HTU #HU1
-elim (dxprs_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #HTU2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lbotr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lbotr.etc
deleted file mode 100644 (file)
index df6b2c1..0000000
+++ /dev/null
@@ -1,94 +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/lsubr_lbotr.ma".
-include "basic_2/relocation/ldrop_ldrop.ma".
-
-(* DROPPING *****************************************************************)
-
-(* Inversion lemmas about local env. full refinement for substitution *******)
-
-(* Note: ldrop_ldrop not needed *)
-lemma lbotr_inv_ldrop: ∀I,L,K,V,i. ⇩[0, i] L ≡ K. ⓑ{I}V → ∀d,e. ⊒[d, e] L →
-                       d ≤ i → i < d + e → I = Abbr.
-#I #L elim L -L
-[ #K #V #i #H
-  lapply (ldrop_inv_atom1 … H) -H #H destruct
-| #L #J #W #IHL #K #V #i #H
-  elim (ldrop_inv_O1 … H) -H *
-  [ -IHL #H1 #H2 #d #e #HL #Hdi #Hide destruct
-    lapply (le_n_O_to_eq … Hdi) -Hdi #H destruct
-    lapply (HL … (L.ⓓW) ?) -HL /2 width=1/ #H
-    elim (lsubr_inv_abbr2 … H ?) -H // -Hide #K #_ #H destruct //
-  | #Hi #HLK #d @(nat_ind_plus … d) -d
-    [ #e #H #_ #Hide
-      elim (lbotr_inv_bind … H ?) -H [2: /2 width=2/ ] #HL #H destruct
-      @(IHL … HLK … HL) -IHL -HLK -HL // /2 width=1/
-    | #d #_ #e #H #Hdi #Hide
-      lapply (lbotr_inv_skip … H ?) -H // #HL
-      @(IHL … HLK … HL) -IHL -HLK -HL /2 width=1/
-    ]
-  ]
-]
-qed-.
-
-(* Properties about local env. full refinement for substitution *************)
-
-(* Note: ldrop_ldrop not needed *)
-lemma lbotr_ldrop: ∀L,d,e.
-                   (∀I,K,V,i. d ≤ i → i < d + e → ⇩[0, i] L ≡ K. ⓑ{I}V → I = Abbr) →
-                   ⊒[d, e] L.
-#L elim L -L //
-#L #I #V #IHL #d @(nat_ind_plus … d) -d
-[ #e @(nat_ind_plus … e) -e //
-  #e #_ #H0
-  >(H0 I L V 0 ? ? ?) //
-  /5 width=6 by lbotr_abbr, ldrop_ldrop, lt_minus_to_plus_r/ (**) (* auto now too slow without trace *)
-| #d #_ #e #H0
-  /5 width=6 by lbotr_skip, ldrop_ldrop, le_S_S, lt_minus_to_plus_r/ (**) (* auto now too slow without trace *)
-]
-qed.
-
-lemma lbotr_ldrop_trans_le: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ∀dd,ee. ⊒[dd, ee] L1 →
-                            dd + ee ≤ d → ⊒[dd, ee] L2.
-#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hddee
-@lbotr_ldrop #I #K2 #V2 #i #Hddi #Hiddee #HLK2
-lapply (lt_to_le_to_lt … Hiddee Hddee) -Hddee #Hid
-elim (ldrop_trans_le … HL12 … HLK2 ?) -L2 /2 width=2/ #X #HLK1 #H
-elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K1 #V1 #HK12 #HV21 #H destruct
-@(lbotr_inv_ldrop … HLK1 … HL1) -L1 -K1 -V1 //
-qed.
-
-lemma lbotr_ldrop_trans_be_up: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 →
-                               ∀dd,ee. ⊒[dd, ee] L1 →
-                               dd ≤ d + e → d + e ≤ dd + ee →
-                               ⊒[d, dd + ee - d - e] L2.
-#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hdde #Hddee
-@lbotr_ldrop #I #K2 #V2 #i #Hdi #Hiddee #HLK2
-lapply (transitive_le ? ? (i+e)… Hdde ?) -Hdde /2 width=1/ #Hddie
->commutative_plus in Hiddee; >minus_minus_comm <plus_minus_m_m /2 width=1/ -Hddee #Hiddee
-lapply (ldrop_trans_ge … HL12 … HLK2 ?) -L2 // -Hdi  #HL1K2
-@(lbotr_inv_ldrop … HL1K2 … HL1) -L1 >commutative_plus // -Hddie /2 width=1/
-qed.
-
-lemma lbotr_ldrop_trans_ge: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ∀dd,ee. ⊒[dd, ee] L1 →
-                            d + e ≤ dd → ⊒[dd - e, ee] L2.
-#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hddee
-@lbotr_ldrop #I #K2 #V2 #i #Hddi #Hiddee #HLK2
-elim (le_inv_plus_l … Hddee) -Hddee #Hdde #Hedd
->plus_minus in Hiddee; // #Hiddee
-lapply (transitive_le … Hdde Hddi) -Hdde #Hid
-lapply (ldrop_trans_ge … HL12 … HLK2 ?) -L2 // -Hid #HL1K2
-@(lbotr_inv_ldrop … HL1K2 … HL1) -L1 >commutative_plus /2 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ldrop_lpx.etc
deleted file mode 100644 (file)
index d23ed28..0000000
+++ /dev/null
@@ -1,68 +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/grammar/lenv_px.ma".
-include "basic_2/relocation/ldrop.ma".
-
-(* DROPPING *****************************************************************)
-
-(* Properties on pointwise extension ****************************************)
-
-lemma lpx_deliftable_dropable: ∀R. t_deliftable_sn R → dropable_sn (lpx R).
-#R #HR #L1 #K1 #d #e #H elim H -L1 -K1 -d -e
-[ #d #e #X #H >(lpx_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #X #H
-  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct /3 width=5/
-| #L1 #K1 #I #V1 #e #_ #IHLK1 #X #H
-  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
-  elim (IHLK1 … HL12) -L1 /3 width=3/
-| #L1 #K1 #I #V1 #W1 #d #e #_ #HWV1 #IHLK1 #X #H
-  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
-  elim (HR … HV12 … HWV1) -V1
-  elim (IHLK1 … HL12) -L1 /3 width=5/
-]
-qed.
-
-lemma lpx_liftable_dedropable: ∀R. reflexive ? R →
-                               t_liftable R → dedropable_sn (lpx R).
-#R #H1R #H2R #L1 #K1 #d #e #H elim H -L1 -K1 -d -e
-[ #d #e #X #H >(lpx_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #X #H
-  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=5/
-| #L1 #K1 #I #V1 #e #_ #IHLK1 #K2 #HK12
-  elim (IHLK1 … HK12) -K1 /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d #e #_ #HWV1 #IHLK1 #X #H
-  elim (lpx_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
-  elim (lift_total W2 d e) #V2 #HWV2
-  lapply (H2R … HW12 … HWV1 … HWV2) -W1
-  elim (IHLK1 … HK12) -K1 /3 width=5/
-]
-qed.
-
-fact lpx_dropable_aux: ∀R,L2,K2,d,e. ⇩[d, e] L2 ≡ K2 → ∀L1. lpx R L1 L2 →
-                       d = 0 → ∃∃K1. ⇩[0, e] L1 ≡ K1 & lpx R K1 K2.
-#R #L2 #K2 #d #e #H elim H -L2 -K2 -d -e
-[ #d #e #X #H >(lpx_inv_atom2 … H) -H /2 width=3/
-| #K2 #I #V2 #X #H
-  elim (lpx_inv_pair2 … H) -H #K1 #V1 #HK12 #HV12 #H destruct /3 width=5/
-| #L2 #K2 #I #V2 #e #_ #IHLK2 #X #H #_
-  elim (lpx_inv_pair2 … H) -H #L1 #V1 #HL12 #HV12 #H destruct
-  elim (IHLK2 … HL12 ?) -L2 // /3 width=3/
-| #L2 #K2 #I #V2 #W2 #d #e #_ #_ #_ #L1 #_
-  >commutative_plus normalize #H destruct
-]
-qed-.
-
-lemma lpx_dropable: ∀R. dropable_dx (lpx R).
-/2 width=5 by lpx_dropable_aux/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_px.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_px.etc
deleted file mode 100644 (file)
index ea916e1..0000000
+++ /dev/null
@@ -1,166 +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/grammar/lenv_append.ma".
-
-(* POINTWISE EXTENSION OF A CONTEXT-FREE REALTION FOR TERMS *****************)
-
-inductive lpx (R:relation term): relation lenv ≝
-| lpx_stom: lpx R (⋆) (⋆)
-| lpx_pair: ∀I,K1,K2,V1,V2.
-            lpx R K1 K2 → R V1 V2 → lpx R (K1. ⓑ{I} V1) (K2. ⓑ{I} V2)
-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lpx_inv_atom1_aux: ∀R,L1,L2. lpx R L1 L2 → L1 = ⋆ → L2 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_inv_atom1: ∀R,L2. lpx R (⋆) L2 → L2 = ⋆.
-/2 width=4 by lpx_inv_atom1_aux/ qed-.
-
-fact lpx_inv_pair1_aux: ∀R,L1,L2. lpx R L1 L2 → ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
-                        ∃∃K2,V2. lpx R K1 K2 & R V1 V2 & L2 = K2. ⓑ{I} V2.
-#R #L1 #L2 * -L1 -L2
-[ #J #K1 #V1 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5/
-]
-qed-.
-
-lemma lpx_inv_pair1: ∀R,I,K1,V1,L2. lpx R (K1. ⓑ{I} V1) L2 →
-                     ∃∃K2,V2. lpx R K1 K2 & R V1 V2 & L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_inv_pair1_aux/ qed-.
-
-fact lpx_inv_atom2_aux: ∀R,L1,L2. lpx R L1 L2 → L2 = ⋆ → L1 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_inv_atom2: ∀R,L1. lpx R L1 (⋆) → L1 = ⋆.
-/2 width=4 by lpx_inv_atom2_aux/ qed-.
-
-fact lpx_inv_pair2_aux: ∀R,L1,L2. lpx R L1 L2 → ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
-                        ∃∃K1,V1. lpx R K1 K2 & R V1 V2 & L1 = K1. ⓑ{I} V1.
-#R #L1 #L2 * -L1 -L2
-[ #J #K2 #V2 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5/
-]
-qed-.
-
-lemma lpx_inv_pair2: ∀R,I,L1,K2,V2. lpx R L1 (K2. ⓑ{I} V2) →
-                     ∃∃K1,V1. lpx R K1 K2 & R V1 V2 & L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_inv_pair2_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpx_fwd_length: ∀R,L1,L2. lpx R L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H -L1 -L2 normalize //
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma lpx_inv_append1: ∀R,L1,K1,L. lpx R (K1 @@ L1) L →
-                       ∃∃K2,L2. lpx R K1 K2 & lpx R L1 L2 & L = K2 @@ L2.
-#R #L1 elim L1 -L1 normalize
-[ #K1 #K2 #HK12
-  @(ex3_2_intro … K2 (⋆)) // (**) (* explicit constructor, /2 width=5/ does not work *)
-| #L1 #I #V1 #IH #K1 #X #H
-  elim (lpx_inv_pair1 … H) -H #L #V2 #H1 #HV12 #H destruct
-  elim (IH … H1) -IH -H1 #K2 #L2 #HK12 #HL12 #H destruct
-  @(ex3_2_intro … HK12) [2: /2 width=2/ | skip | // ] (* explicit constructor, /3 width=5/ does not work *)
-]
-qed-.
-
-lemma lpx_inv_append2: ∀R,L2,K2,L. lpx R L (K2 @@ L2) →
-                       ∃∃K1,L1. lpx R K1 K2 & lpx R L1 L2 & L = K1 @@ L1.
-#R #L2 elim L2 -L2 normalize
-[ #K2 #K1 #HK12
-  @(ex3_2_intro … K1 (⋆)) // (**) (* explicit constructor, /2 width=5/ does not work *)
-| #L2 #I #V2 #IH #K2 #X #H
-  elim (lpx_inv_pair2 … H) -H #L #V1 #H1 #HV12 #H destruct
-  elim (IH … H1) -IH -H1 #K1 #L1 #HK12 #HL12 #H destruct
-  @(ex3_2_intro … HK12) [2: /2 width=2/ | skip | // ] (* explicit constructor, /3 width=5/ does not work *)
-]
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpx_refl: ∀R. reflexive ? R → reflexive … (lpx R).
-#R #HR #L elim L -L // /2 width=1/
-qed.
-
-lemma lpx_sym: ∀R. symmetric ? R → symmetric … (lpx R).
-#R #HR #L1 #L2 #H elim H -H // /3 width=1/
-qed.
-
-lemma lpx_trans: ∀R. Transitive ? R → Transitive … (lpx R).
-#R #HR #L1 #L #H elim H -L //
-#I #K1 #K #V1 #V #_ #HV1 #IHK1 #X #H
-elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK2 #HV2 #H destruct /3 width=3/
-qed.
-
-lemma lpx_conf: ∀R. confluent ? R → confluent … (lpx R).
-#R #HR #L0 #L1 #H elim H -L1
-[ #X #H >(lpx_inv_atom1 … H) -X /2 width=3/
-| #I #K0 #K1 #V0 #V1 #_ #HV01 #IHK01 #X #H
-  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK02 #HV02 #H destruct
-  elim (IHK01 … HK02) -K0 #K #HK1 #HK2
-  elim (HR … HV01 … HV02) -HR -V0 /3 width=5/
-]
-qed.
-
-lemma lpx_TC_inj: ∀R,L1,L2. lpx R L1 L2 → lpx (TC … R) L1 L2.
-#R #L1 #L2 #H elim H -L1 -L2 // /3 width=1/
-qed.
-
-lemma lpx_TC_step: ∀R,L1,L. lpx (TC … R) L1 L →
-                   ∀L2. lpx R L L2 → lpx (TC … R) L1 L2.
-#R #L1 #L #H elim H -L /2 width=1/
-#I #K1 #K #V1 #V #_ #HV1 #IHK1 #X #H
-elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK2 #HV2 #H destruct /3 width=3/
-qed.
-
-lemma TC_lpx_pair_dx: ∀R. reflexive ? R →
-                      ∀I,K,V1,V2. TC … R V1 V2 →
-                      TC … (lpx R) (K.ⓑ{I}V1) (K.ⓑ{I}V2).
-#R #HR #I #K #V1 #V2 #H elim H -V2
-/4 width=5 by lpx_refl, lpx_pair, inj, step/ (**) (* too slow without trace *)
-qed.
-
-lemma TC_lpx_pair_sn: ∀R. reflexive ? R →
-                      ∀I,V,K1,K2. TC … (lpx R) K1 K2 →
-                      TC … (lpx R) (K1.ⓑ{I}V) (K2.ⓑ{I}V).
-#R #HR #I #V #K1 #K2 #H elim H -K2
-/4 width=5 by lpx_refl, lpx_pair, inj, step/ (**) (* too slow without trace *)
-qed.
-
-lemma lpx_TC: ∀R,L1,L2. TC … (lpx R) L1 L2 → lpx (TC … R) L1 L2.
-#R #L1 #L2 #H elim H -L2 /2 width=1/ /2 width=3/
-qed.
-
-lemma lpx_inv_TC: ∀R. reflexive ? R →
-                  ∀L1,L2. lpx (TC … R) L1 L2 → TC … (lpx R) L1 L2.
-#R #HR #L1 #L2 #H elim H -L1 -L2 /3 width=1/ /3 width=3/
-qed.
-
-lemma lpx_append: ∀R,K1,K2. lpx R K1 K2 → ∀L1,L2. lpx R L1 L2 →
-                  lpx R (L1 @@ K1) (L2 @@ K2).
-#R #K1 #K2 #H elim H -K1 -K2 // /3 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_top.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lenv_top.etc
deleted file mode 100644 (file)
index ab90ceb..0000000
+++ /dev/null
@@ -1,68 +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 "hvbox( T1 𝟙 break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'RTop $T1 $T2 }.
-
-include "basic_2/grammar/lenv_px.ma".
-
-(* POINTWISE EXTENSION OF TOP RELATION FOR TERMS ****************************)
-
-definition ttop: relation term ≝ λT1,T2. True.
-
-definition ltop: relation lenv ≝ lpx ttop.
-
-interpretation
-  "top reduction (environment)"
-  'RTop L1 L2 = (ltop L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma ltop_refl: reflexive … ltop.
-/2 width=1/ qed.
-
-lemma ltop_sym: symmetric … ltop.
-/2 width=1/ qed.
-
-lemma ltop_trans: transitive … ltop.
-/2 width=3/ qed.
-
-lemma ltop_append: ∀K1,K2. K1 𝟙 K2 → ∀L1,L2. L1 𝟙 L2 → L1 @@ K1 𝟙 L2 @@ K2.
-/2 width=1/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma ltop_inv_atom1: ∀L2. ⋆ 𝟙 L2 → L2 = ⋆.
-/2 width=2 by lpx_inv_atom1/ qed-.
-
-lemma ltop_inv_pair1: ∀K1,I,V1,L2. K1. ⓑ{I} V1 𝟙 L2 →
-                      ∃∃K2,V2. K1 𝟙 K2 & L2 = K2. ⓑ{I} V2.
-#K1 #I #V1 #L2 #H
-elim (lpx_inv_pair1 … H) -H /2 width=4/
-qed-.
-
-lemma ltop_inv_atom2: ∀L1. L1 𝟙 ⋆ → L1 = ⋆.
-/2 width=2 by lpx_inv_atom2/ qed-.
-
-lemma ltop_inv_pair2: ∀L1,K2,I,V2. L1 𝟙 K2. ⓑ{I} V2 →
-                      ∃∃K1,V1. K1 𝟙 K2 & L1 = K1. ⓑ{I} V1.
-#L1 #K2 #I #V2 #H
-elim (lpx_inv_pair2 … H) -H /2 width=4/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma ltop_fwd_length: ∀L1,L2. L1 𝟙 L2 → |L1| = |L2|.
-/2 width=2 by lpx_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr.etc
deleted file mode 100644 (file)
index ea9f585..0000000
+++ /dev/null
@@ -1,48 +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 "hvbox( ⦃ term 46 L1 ⦄ ➡ break ⦃ term 46 L2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRed $L1 $L2 }.
-
-include "basic_2/unfold/ltpss_sn.ma".
-include "basic_2/reducibility/ltpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
-
-definition lfpr: relation lenv ≝
-   λL1,L2. ∃∃L. L1 ➡ L & L ⊢ ▶* [0, |L|] L2
-.
-
-interpretation
-  "focalized parallel reduction (environment)"
-  'FocalizedPRed L1 L2 = (lfpr L1 L2).
-
-(* Basic properties *********************************************************)
-
-(* Note: lemma 250 *)
-lemma lfpr_refl: ∀L. ⦃L⦄ ➡ ⦃L⦄.
-/2 width=3/ qed.
-
-lemma ltpss_sn_lfpr: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → ⦃L1⦄ ➡ ⦃L2⦄.
-/3 width=5/ qed.
-
-lemma ltpr_lfpr: ∀L1,L2. L1 ➡ L2 → ⦃L1⦄ ➡ ⦃L2⦄.
-/3 width=3/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lfpr_inv_atom1: ∀L2. ⦃⋆⦄ ➡ ⦃L2⦄ → L2 = ⋆.
-#L2 * #L #HL >(ltpr_inv_atom1 … HL) -HL #HL2 >(ltpss_sn_inv_atom1 … HL2) -HL2 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_aaa.etc
deleted file mode 100644 (file)
index 6f6c49d..0000000
+++ /dev/null
@@ -1,25 +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/static/aaa_ltpss_sn.ma".
-include "basic_2/reducibility/ltpr_aaa.ma".
-include "basic_2/reducibility/lfpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_lfpr_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. ⦃L1⦄ ➡ ⦃L2⦄ → L2 ⊢ T ⁝ A.
-#L1 #T #A #HT #L2 * /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_cpr.etc
deleted file mode 100644 (file)
index 8a01f26..0000000
+++ /dev/null
@@ -1,52 +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/unfold/ltpss_sn_ltpss_sn.ma".
-include "basic_2/reducibility/ltpr_ldrop.ma".
-include "basic_2/reducibility/cpr.ma".
-include "basic_2/reducibility/lfpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
-
-(* Advanced properties ******************************************************)
-
-lemma lfpr_pair_cpr: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ∀V1,V2. L2 ⊢ V1 ➡ V2 →
-                     ∀I. ⦃L1. ⓑ{I} V1⦄ ➡ ⦃L2. ⓑ{I} V2⦄.
-#L1 #L2 * #L #HL1 #HL2 #V1 #V2 *
-<(ltpss_sn_fwd_length … HL2) #V #HV1 #HV2 #I
-lapply (ltpss_sn_tpss_trans_eq … HV2 … HL2) -HV2 #V2
-@(ex2_intro … (L.ⓑ{I}V)) /2 width=1/ (**) (* explicit constructor *)
-qed.
-
-(* Properties on supclosure *************************************************)
-(*
-lamma fsub_cpr_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ➡ U2 →
-                      ∃∃L,U1. ⦃L1⦄ ➡ ⦃L⦄ & L ⊢ T1 ➡ U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
-#L1 #L2 #T1 #T2 #HT12 #U2 * #T #H1 #H2
-elim (fsub_tpr_trans … HT12 … H1) -T2 #L #U #HL1 #HT1U #HUT
-elim (fsup_tpss_trans_full … HUT … H2) -T  -HUT -H2 #L #U #HL1 #HT1U #HUT
-
-
-
-
-
-
- #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
-#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HK2
-elim (lift_total T d e) #U #HTU
-elim (ldrop_ltpr_trans … HLK1 … HK1) -HLK1 -HK1 #L #HL1 #HLK
-lapply (tpr_lift … HT1 … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
-qed-.
-*)
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_lfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfpr_lfpr.etc
deleted file mode 100644 (file)
index 7031e79..0000000
+++ /dev/null
@@ -1,39 +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/reducibility/ltpr_ltpss_sn.ma".
-include "basic_2/reducibility/ltpr_ltpr.ma".
-include "basic_2/reducibility/lfpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
-
-(* Main properties **********************************************************)
-
-theorem lfpr_conf: ∀L0,L1,L2. ⦃L0⦄ ➡ ⦃L1⦄ → ⦃L0⦄ ➡ ⦃L2⦄ →
-                   ∃∃L. ⦃L1⦄ ➡ ⦃L⦄ & ⦃L2⦄ ➡ ⦃L⦄.
-#K0 #L1 #L2 * #K1 #HK01 #HKL1 * #K2 #HK02 #HKL2
-lapply (ltpr_fwd_length … HK01) #H
->(ltpr_fwd_length … HK02) in H; #H
-elim (ltpr_conf … HK01 … HK02) -K0 #K #HK1 #HK2
-lapply (ltpss_sn_fwd_length … HKL1) #H1
-lapply (ltpss_sn_fwd_length … HKL2) #H2
->H1 in HKL1 H; -H1 #HKL1
->H2 in HKL2; -H2 #HKL2 #H
-elim (ltpr_ltpss_sn_conf … HKL1 … HK1) -K1 #K1 #HK1 #HLK1
-elim (ltpr_ltpss_sn_conf … HKL2 … HK2) -K2 #K2 #HK2 #HLK2
-elim (ltpss_sn_conf … HK1 … HK2) -K #K #HK1 #HK2
-lapply (ltpr_fwd_length … HLK1) #H1
-lapply (ltpr_fwd_length … HLK2) #H2
-/3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfprs_ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lfprs_ltprs.etc
deleted file mode 100644 (file)
index 99ae801..0000000
+++ /dev/null
@@ -1,23 +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/computation/ltprs.ma".
-include "basic_2/computation/lfprs.ma".
-
-(* FOCALIZED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *********************)
-
-(* Properties on context-free parallel computation for local environments ***)
-
-lemma ltprs_lfprs: ∀L1,L2. L1 ➡* L2 → ⦃L1⦄ ➡* ⦃L2⦄.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lift.etc
deleted file mode 100644 (file)
index f0d631e..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-definition t_liftable: relation term → Prop ≝
-                       λR. ∀T1,T2. R T1 T2 → ∀U1,d,e. ⇧[d, e] T1 ≡ U1 →
-                       ∀U2. ⇧[d, e] T2 ≡ U2 → R U1 U2.
-
-definition t_deliftable_sn: relation term → Prop ≝
-                            λR. ∀U1,U2. R U1 U2 → ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
-                            ∃∃T2. ⇧[d, e] T2 ≡ U2 & R T1 T2.
-
-lemma t_liftable_TC: ∀R. t_liftable R → t_liftable (TC … R).
-#R #HR #T1 #T2 #H elim H -T2
-[ /3 width=7/
-| #T #T2 #_ #HT2 #IHT1 #U1 #d #e #HTU1 #U2 #HTU2
-  elim (lift_total T d e) /3 width=9/
-]
-qed.
-
-lemma t_deliftable_sn_TC: ∀R. t_deliftable_sn R → t_deliftable_sn (TC … R).
-#R #HR #U1 #U2 #H elim H -U2
-[ #U2 #HU12 #T1 #d #e #HTU1
-  elim (HR … HU12 … HTU1) -U1 /3 width=3/
-| #U #U2 #_ #HU2 #IHU1 #T1 #d #e #HTU1
-  elim (IHU1 … HTU1) -U1 #T #HTU #HT1
-  elim (HR … HU2 … HTU) -U /3 width=5/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr.etc
deleted file mode 100644 (file)
index 8655a5e..0000000
+++ /dev/null
@@ -1,198 +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 "hvbox( L1 break ⊑ [ term 46 d , break term 46 e ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'SubEq $L1 $d $e $L2 }.
-
-include "basic_2/grammar/lenv_length.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
-
-inductive lsubr: nat → nat → relation lenv ≝
-| lsubr_sort: ∀d,e. lsubr d e (⋆) (⋆)
-| lsubr_OO:   ∀L1,L2. lsubr 0 0 L1 L2
-| lsubr_abbr: ∀L1,L2,V,e. lsubr 0 e L1 L2 →
-              lsubr 0 (e + 1) (L1. ⓓV) (L2.ⓓV)
-| lsubr_abst: ∀L1,L2,I,V1,V2,e. lsubr 0 e L1 L2 →
-              lsubr 0 (e + 1) (L1. ⓑ{I}V1) (L2. ⓛV2)
-| lsubr_skip: ∀L1,L2,I1,I2,V1,V2,d,e.
-              lsubr d e L1 L2 → lsubr (d + 1) e (L1. ⓑ{I1} V1) (L2. ⓑ{I2} V2)
-.
-
-interpretation
-  "local environment refinement (substitution)"
-  'SubEq L1 d e L2 = (lsubr d e L1 L2).
-
-definition lsubr_trans: ∀S. (lenv → relation S) → Prop ≝ λS,R.
-                        ∀L2,s1,s2. R L2 s1 s2 →
-                        ∀L1,d,e. L1 ⊑ [d, e] L2 → R L1 s1 s2.
-
-(* Basic properties *********************************************************)
-
-lemma lsubr_bind_eq: ∀L1,L2,e. L1 ⊑ [0, e] L2 → ∀I,V.
-                     L1. ⓑ{I} V ⊑ [0, e + 1] L2.ⓑ{I} V.
-#L1 #L2 #e #HL12 #I #V elim I -I /2 width=1/
-qed.
-
-lemma lsubr_abbr_lt: ∀L1,L2,V,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
-                     L1. ⓓV ⊑ [0, e] L2.ⓓV.
-#L1 #L2 #V #e #HL12 #He >(plus_minus_m_m e 1) // /2 width=1/
-qed.
-
-lemma lsubr_abst_lt: ∀L1,L2,I,V1,V2,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
-                     L1. ⓑ{I}V1 ⊑ [0, e] L2. ⓛV2.
-#L1 #L2 #I #V1 #V2 #e #HL12 #He >(plus_minus_m_m e 1) // /2 width=1/
-qed.
-
-lemma lsubr_skip_lt: ∀L1,L2,d,e. L1 ⊑ [d - 1, e] L2 → 0 < d →
-                     ∀I1,I2,V1,V2. L1. ⓑ{I1} V1 ⊑ [d, e] L2. ⓑ{I2} V2.
-#L1 #L2 #d #e #HL12 #Hd >(plus_minus_m_m d 1) // /2 width=1/
-qed.
-
-lemma lsubr_bind_lt: ∀I,L1,L2,V,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
-                     L1. ⓓV ⊑ [0, e] L2. ⓑ{I}V.
-* /2 width=1/ qed.
-
-lemma lsubr_refl: ∀d,e,L. L ⊑ [d, e] L.
-#d elim d -d
-[ #e elim e -e // #e #IHe #L elim L -L // /2 width=1/
-| #d #IHd #e #L elim L -L // /2 width=1/
-]
-qed.
-
-lemma TC_lsubr_trans: ∀S,R. lsubr_trans S R → lsubr_trans S (λL. (TC … (R L))).
-#S #R #HR #L1 #s1 #s2 #H elim H -s2
-[ /3 width=5/
-| #s #s2 #_ #Hs2 #IHs1 #L2 #d #e #HL12
-  lapply (HR … Hs2 … HL12) -HR -Hs2 -HL12 /3 width=3/
-]
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lsubr_inv_atom1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 → L1 = ⋆ →
-                          L2 = ⋆ ∨ (d = 0 ∧ e = 0).
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ /2 width=1/
-| /3 width=1/
-| #L1 #L2 #W #e #_ #H destruct
-| #L1 #L2 #I #W1 #W2 #e #_ #H destruct
-| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #H destruct
-]
-qed.
-
-lemma lsubr_inv_atom1: ∀L2,d,e. ⋆ ⊑ [d, e] L2 →
-                       L2 = ⋆ ∨ (d = 0 ∧ e = 0).
-/2 width=3/ qed-.
-
-fact lsubr_inv_skip1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
-                          ∀I1,K1,V1. L1 = K1.ⓑ{I1}V1 → 0 < d →
-                          ∃∃I2,K2,V2. K1 ⊑ [d - 1, e] K2 & L2 = K2.ⓑ{I2}V2.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #I1 #K1 #V1 #H destruct
-| #L1 #L2 #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #W #e #_ #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #I #W1 #W2 #e #_ #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #J1 #J2 #W1 #W2 #d #e #HL12 #I1 #K1 #V1 #H #_ destruct /2 width=5/
-]
-qed.
-
-lemma lsubr_inv_skip1: ∀I1,K1,L2,V1,d,e. K1.ⓑ{I1}V1 ⊑ [d, e] L2 → 0 < d →
-                       ∃∃I2,K2,V2. K1 ⊑ [d - 1, e] K2 & L2 = K2.ⓑ{I2}V2.
-/2 width=5/ qed-.
-
-fact lsubr_inv_atom2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 → L2 = ⋆ →
-                          L1 = ⋆ ∨ (d = 0 ∧ e = 0).
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ /2 width=1/
-| /3 width=1/
-| #L1 #L2 #W #e #_ #H destruct
-| #L1 #L2 #I #W1 #W2 #e #_ #H destruct
-| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #H destruct
-]
-qed.
-
-lemma lsubr_inv_atom2: ∀L1,d,e. L1 ⊑ [d, e] ⋆ →
-                       L1 = ⋆ ∨ (d = 0 ∧ e = 0).
-/2 width=3/ qed-.
-
-fact lsubr_inv_abbr2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
-                          ∀K2,V. L2 = K2.ⓓV → d = 0 → 0 < e →
-                          ∃∃K1. K1 ⊑ [0, e - 1] K2 & L1 = K1.ⓓV.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #K1 #V #H destruct
-| #L1 #L2 #K1 #V #_ #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #W #e #HL12 #K1 #V #H #_ #_ destruct /2 width=3/
-| #L1 #L2 #I #W1 #W2 #e #_ #K1 #V #H destruct
-| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #K1 #V #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma lsubr_inv_abbr2: ∀L1,K2,V,e. L1 ⊑ [0, e] K2.ⓓV → 0 < e →
-                       ∃∃K1. K1 ⊑ [0, e - 1] K2 & L1 = K1.ⓓV.
-/2 width=5/ qed-.
-
-fact lsubr_inv_skip2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
-                          ∀I2,K2,V2. L2 = K2.ⓑ{I2}V2 → 0 < d →
-                          ∃∃I1,K1,V1. K1 ⊑ [d - 1, e] K2 & L1 = K1.ⓑ{I1}V1.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #I1 #K1 #V1 #H destruct
-| #L1 #L2 #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #W #e #_ #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #I #W1 #W2 #e #_ #I1 #K1 #V1 #_ #H
-  elim (lt_zero_false … H)
-| #L1 #L2 #J1 #J2 #W1 #W2 #d #e #HL12 #I1 #K1 #V1 #H #_ destruct /2 width=5/
-]
-qed.
-
-lemma lsubr_inv_skip2: ∀I2,L1,K2,V2,d,e. L1 ⊑ [d, e] K2.ⓑ{I2}V2 → 0 < d →
-                       ∃∃I1,K1,V1. K1 ⊑ [d - 1, e] K2 & L1 = K1.ⓑ{I1}V1.
-/2 width=5/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-fact lsubr_fwd_length_full1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
-                                 d = 0 → e = |L1| → |L1| ≤ |L2|.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize
-[ //
-| /2 width=1/
-| /3 width=1/
-| /3 width=1/
-| #L1 #L2 #_ #_ #_ #_ #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma lsubr_fwd_length_full1: ∀L1,L2. L1 ⊑ [0, |L1|] L2 → |L1| ≤ |L2|.
-/2 width=5/ qed-.
-
-fact lsubr_fwd_length_full2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
-                                 d = 0 → e = |L2| → |L2| ≤ |L1|.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize
-[ //
-| /2 width=1/
-| /3 width=1/
-| /3 width=1/
-| #L1 #L2 #_ #_ #_ #_ #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma lsubr_fwd_length_full2: ∀L1,L2. L1 ⊑ [0, |L2|] L2 → |L2| ≤ |L1|.
-/2 width=5/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr_lbotr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/lsubr_lbotr.etc
deleted file mode 100644 (file)
index b95a19b..0000000
+++ /dev/null
@@ -1,77 +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 "hvbox( ⊒ [ term 46 d , break term 46 e ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'SubEqBottom $d $e $L2 }.
-
-include "basic_2/relocation/lsubr.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
-
-(* bottom element of the refinement *)
-definition lbotr: nat → nat → predicate lenv ≝
-   λd,e. NF_sn … (lsubr d e) (lsubr d e …).
-
-interpretation
-   "local environment full refinement (substitution)"
-   'SubEqBottom d e L = (lbotr d e L).
-
-(* Basic properties *********************************************************)
-
-lemma lbotr_atom: ∀d,e. ⊒[d, e] ⋆.
-#d #e #L #H
-elim (lsubr_inv_atom2 … H) -H
-[ #H destruct //
-| * #H1 #H2 destruct //
-]
-qed.
-
-lemma lbotr_OO: ∀L. ⊒[0, 0] L.
-// qed.
-
-lemma lbotr_abbr: ∀L,V,e. ⊒[0, e] L → ⊒[0, e + 1] L.ⓓV.
-#L #V #e #HL #K #H
-elim (lsubr_inv_abbr2 … H ?) -H // <minus_plus_m_m #X #HLX #H destruct
-lapply (HL … HLX) -HL -HLX /2 width=1/
-qed.
-
-lemma lbotr_abbr_O: ∀L,V. ⊒[0,1] L.ⓓV.
-#L #V
-@(lbotr_abbr … 0) //
-qed.
-
-lemma lbotr_skip: ∀I,L,V,d,e. ⊒[d, e] L → ⊒[d + 1, e] L.ⓑ{I}V.
-#I #L #V #d #e #HL #K #H
-elim (lsubr_inv_skip2 … H ?) -H // <minus_plus_m_m #J #X #W #HLX #H destruct
-lapply (HL … HLX) -HL -HLX /2 width=1/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lbotr_inv_bind: ∀I,L,V,e. ⊒[0, e] L.ⓑ{I}V → 0 < e →
-                      ⊒[0, e - 1] L ∧ I = Abbr.
-#I #L #V #e #HL #He
-lapply (HL (L.ⓓV) ?) /2 width=1/ #H
-elim (lsubr_inv_abbr2 … H ?) -H // #K #_ #H destruct
-@conj // #L #HKL
-lapply (HL (L.ⓓV) ?) -HL /2 width=1/ -HKL #H
-elim (lsubr_inv_abbr2 … H ?) -H // -He #X #HLX #H destruct //
-qed-.
-
-lemma lbotr_inv_skip: ∀I,L,V,d,e. ⊒[d, e] L.ⓑ{I}V → 0 < d → ⊒[d - 1, e] L.
-#I #L #V #d #e #HL #Hd #K #HLK
-lapply (HL (K.ⓑ{I}V) ?) -HL /2 width=1/ -HLK #H
-elim (lsubr_inv_skip2 … H ?) -H // -Hd #J #X #W #HKX #H destruct //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr.etc
deleted file mode 100644 (file)
index a910ea7..0000000
+++ /dev/null
@@ -1,67 +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/grammar/lenv_px.ma".
-include "basic_2/reducibility/tpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-definition ltpr: relation lenv ≝ lpx tpr.
-
-interpretation
-  "context-free parallel reduction (environment)"
-  'PRed L1 L2 = (ltpr L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma ltpr_refl: reflexive … ltpr.
-/2 width=1/ qed.
-
-lemma ltpr_append: ∀K1,K2. K1 ➡ K2 → ∀L1,L2:lenv. L1 ➡ L2 → K1 @@ L1 ➡ K2 @@ L2.
-/2 width=1/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-(* Basic_1: was: wcpr0_gen_sort *)
-lemma ltpr_inv_atom1: ∀L2. ⋆ ➡ L2 → L2 = ⋆.
-/2 width=2 by lpx_inv_atom1/ qed-.
-
-(* Basic_1: was: wcpr0_gen_head *)
-lemma ltpr_inv_pair1: ∀K1,I,V1,L2. K1. ⓑ{I} V1 ➡ L2 →
-                      ∃∃K2,V2. K1 ➡ K2 & V1 ➡ V2 & L2 = K2. ⓑ{I} V2.
-/2 width=1 by lpx_inv_pair1/ qed-.
-
-lemma ltpr_inv_atom2: ∀L1. L1 ➡ ⋆ → L1 = ⋆.
-/2 width=2 by lpx_inv_atom2/ qed-.
-
-lemma ltpr_inv_pair2: ∀L1,K2,I,V2. L1 ➡ K2. ⓑ{I} V2 →
-                      ∃∃K1,V1. K1 ➡ K2 & V1 ➡ V2 & L1 = K1. ⓑ{I} V1.
-/2 width=1 by lpx_inv_pair2/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma ltpr_fwd_length: ∀L1,L2. L1 ➡ L2 → |L1| = |L2|.
-/2 width=2 by lpx_fwd_length/ qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma ltpr_inv_append1: ∀K1,L1. ∀L:lenv. K1 @@ L1 ➡ L →
-                        ∃∃K2,L2. K1 ➡ K2 & L1 ➡ L2 & L = K2 @@ L2.
-/2 width=1 by lpx_inv_append1/ qed-.
-
-lemma ltpr_inv_append2: ∀L:lenv. ∀K2,L2. L ➡ K2 @@ L2 →
-                        ∃∃K1,L1. K1 ➡ K2 & L1 ➡ L2 & L = K1 @@ L1.
-/2 width=1 by lpx_inv_append2/ qed-.
-
-(* Basic_1: removed theorems 2: wcpr0_getl wcpr0_getl_back *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_aaa.etc
deleted file mode 100644 (file)
index 5208a64..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/static/aaa_ltpss_dx.ma".
-include "basic_2/static/lsuba_aaa.ma".
-include "basic_2/reducibility/ltpr_ldrop.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_ltpr_tpr_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A → ∀L2. L1 ➡ L2 →
-                         ∀T2. T1 ➡ T2 → L2 ⊢ T2 ⁝ A.
-#L1 #T1 @(f2_ind … fw … L1 T1) -L1 -T1 #n #IH #L1 * *
-[1,2,3:
-  #i #Hn #X #H1 #L2 #HL12 #Y #H2 destruct
-  >(tpr_inv_atom1 … H2) -Y
-|4,5: [ #a ] * #V1 #T1 #Hn #X #H1 #L2 #HL12 #Y #H2 destruct
-]
-[ >(aaa_inv_sort … H1) -X //
-| elim (aaa_inv_lref … H1) #I #K1 #V1 #HLK1 #HA
-  lapply (ldrop_pair2_fwd_fw … HLK1 (#i)) #HKV1
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #Y #H #HLK2
-  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
-  lapply (IH … HKV1 … HA … HK12 … HV12) -L1 -K1 -V1 /2 width=5/
-| elim (aaa_inv_gref … H1)
-| elim (aaa_inv_abbr … H1) -H1 #B #HB #HA
-  elim (tpr_inv_abbr1 … H2) -H2 *
-  [ #V2 #T #T2 #HV12 #HT1 #HT2 #H destruct
-    lapply (tps_lsubr_trans … HT2 (L2.ⓓV2) ?) -HT2 /2 width=1/ #HT2
-    lapply (IH … HB … HL12 … HV12) -HB /width=5/ #HB
-    lapply (IH … HA … (L2.ⓓV2) … HT1) -IH -HA -HT1 /width=5/ -T1 /2 width=1/ -L1 -V1 /3 width=5/
-  | -B #T #HT1 #HXT #H destruct
-    lapply (IH … HA … (L2.ⓓV1) … HT1) /width=5/ -T1 /2 width=1/ -L1 #HA
-    @(aaa_inv_lift … HA … HXT) /2 width=1/
-  ]
-| elim (aaa_inv_abst … H1) -H1 #B #A #HB #HA #H destruct
-  elim (tpr_inv_abst1 … H2) -H2 #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (IH … HB … HL12 … HV12) -HB /width=5/ #HB
-  lapply (IH … HA … (L2.ⓛV2) … HT12) -IH -HA -HT12 /width=5/ -T1 /2 width=1/
-| elim (aaa_inv_appl … H1) -H1 #B #HB #HA
-  elim (tpr_inv_appl1 … H2) -H2 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH … HB … HL12 … HV12) -HB -HV12 /width=5/ #HB
-    lapply (IH … HA … HL12 … HT12) -IH -HA -HL12 -HT12 /width=5/ /2 width=3/
-  | #b #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
-    elim (aaa_inv_abst … HA) -HA #B0 #A0 #HB0 #HA0 #H destruct
-    lapply (IH … HB … HL12 … HV12) -HB -HV12 /width=5/ #HB
-    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
-    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 // /2 width=1/ -T0 -L1 -V1 /4 width=7/
-  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
-    elim (aaa_inv_abbr … HA) -HA #B0 #HW0 #HT0
-    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
-    lapply (IH … HB … HL12 … HV10) -HB -HV10 /width=5/ #HV0
-    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 // /2 width=1/ -V1 -T0 -L1 -W0 #HT2
-    @(aaa_abbr … HW2) -HW2
-    @(aaa_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
-  ]
-| elim (aaa_inv_cast … H1) -H1 #HV1 #HT1
-  elim (tpr_inv_cast1 … H2) -H2
-  [ * #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
-    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
-  | -HV1 #HT1X
-     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
-  ]
-]
-qed.
-
-lemma aaa_ltpr_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. L1 ➡ L2 → L2 ⊢ T ⁝ A.
-/2 width=5/ qed.
-
-lemma aaa_tpr_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. T1 ➡ T2 → L ⊢ T2 ⁝ A.
-/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ldrop.etc
deleted file mode 100644 (file)
index 02404a1..0000000
+++ /dev/null
@@ -1,45 +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/ldrop_lpx.ma".
-include "basic_2/substitution/fsup.ma".
-include "basic_2/reducibility/tpr_lift.ma".
-include "basic_2/reducibility/ltpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properies on local environment slicing ***********************************)
-
-(* Basic_1: was: wcpr0_drop *)
-lemma ltpr_ldrop_conf: dropable_sn ltpr.
-/3 width=3 by lpx_deliftable_dropable, tpr_inv_lift1/ qed.
-
-(* Basic_1: was: wcpr0_drop_back *)
-lemma ldrop_ltpr_trans: dedropable_sn ltpr.
-/2 width=3/ qed.
-
-lemma ltpr_ldrop_trans_O1: dropable_dx ltpr.
-/2 width=3/ qed.
-
-(* Properties on supclosure *************************************************)
-
-lemma fsub_tpr_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. T2 ➡ U2 →
-                      ∃∃L,U1. L1 ➡ L & T1 ➡ U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
-#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HK2
-elim (lift_total T d e) #U #HTU
-elim (ldrop_ltpr_trans … HLK1 … HK1) -HLK1 -HK1 #L #HL1 #HLK
-lapply (tpr_lift … HT1 … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpr.etc
deleted file mode 100644 (file)
index 4a27a6e..0000000
+++ /dev/null
@@ -1,29 +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/reducibility/tpr_tpr.ma".
-include "basic_2/reducibility/ltpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Main properties **********************************************************)
-
-theorem ltpr_conf: ∀L0:lenv. ∀L1. L0 ➡ L1 → ∀L2. L0 ➡ L2 →
-                   ∃∃L. L1 ➡ L & L2 ➡ L.
-#L0 #L1 #H elim H -L0 -L1 /2 width=3/
-#I #K0 #K1 #V0 #V1 #_ #HV01 #IHK01 #L2 #H
-elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK02 #HV02 #H destruct
-elim (IHK01 … HK02) -K0 #K #HK1 #HK2
-elim (tpr_conf … HV01 HV02) -V0 /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_dx.etc
deleted file mode 100644 (file)
index 00730b7..0000000
+++ /dev/null
@@ -1,36 +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/reducibility/ltpr_tpss.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properties concerning dx parallel unfold on local environments ***********)
-
-lemma ltpr_ltpss_dx_conf: ∀L1,K1,d,e. L1 ▶* [d, e] K1 → ∀L2. L1 ➡ L2 →
-                          ∃∃K2. L2 ▶* [d, e] K2 & K1 ➡ K2.
-#L1 #K1 #d #e #H elim H -L1 -K1 -d -e
-[ /2 width=3/
-| #L1 #I #V1 #X #H
-  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct /3 width=5/
-| #L1 #K1 #I #V1 #W1 #e #_ #HVW1 #IHLK1 #X #H
-  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
-  elim (IHLK1 … HL12) -L1 #K2 #HLK2 #HK12
-  elim (ltpr_tpr_tpss_conf … HK12 … HV12 … HVW1) -V1 /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d #e #_ #HVW1 #IHLK1 #X #H
-  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
-  elim (IHLK1 … HL12) -L1 #K2 #HLK2 #HK12
-  elim (ltpr_tpr_tpss_conf … HK12 … HV12 … HVW1) -V1 /3 width=5/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_ltpss_sn.etc
deleted file mode 100644 (file)
index 79ffb7c..0000000
+++ /dev/null
@@ -1,31 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/reducibility/ltpr_ltpss_dx.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properties on sn parallel unfold on local environments *******************)
-
-(* Note: this can also be proved like ltpr_ltpss_dx_conf *)
-lemma ltpr_ltpss_sn_conf: ∀L1,K1,d,e. L1 ⊢ ▶* [d, e] K1 → ∀L2. L1 ➡ L2 →
-                          ∃∃K2. L2 ⊢ ▶* [d, e] K2 & K1 ➡ K2.
-#L1 #K1 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H
-@(ltpssa_ind … H) -K1 /2 width=3/
-#K #K1 #_ #HK1 #IHK #L2 #HL12
-elim (IHK … HL12) -L1 #K2 #HLK2 #HK2
-elim (ltpr_ltpss_dx_conf … HK1 … HK2) -K /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tps.etc
deleted file mode 100644 (file)
index 7f08be6..0000000
+++ /dev/null
@@ -1,57 +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/reducibility/ltpr_ldrop.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properties concerning parallel substitution on terms *********************)
-
-(* Basic_1: was: pr0_subst1_fwd *)
-lemma ltpr_tps_conf: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶ [d, e] T2 → ∀L2. L1 ➡ L2 →
-                     ∃∃T. L2 ⊢ T1 ▶ [d, e] T & T2 ➡ T.
-#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
-[ /2 width=3/
-| #L1 #K1 #V1 #W1 #i #d #e #Hdi #Hide #HLK1 #HVW1 #L2 #HL12
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
-  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct -K1
-  elim (lift_total V2 0 (i+1)) #W2 #HVW2
-  lapply (tpr_lift … HV12 … HVW1 … HVW2) -V1 /3 width=4/
-| #L1 #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L2 #HL12
-  elim (IHV12 … HL12) -IHV12 #V #HV1 #HV2
-  elim (IHT12 (L2.ⓑ{I}V) ?) /2 width=1/ -L1 /3 width=5/
-| #L1 #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L2 #HL12
-  elim (IHV12 … HL12) -IHV12
-  elim (IHT12 … HL12) -L1 /3 width=5/
-]
-qed-.
-
-(* Basic_1: was: pr0_subst1_back *)
-lemma ltpr_tps_trans: ∀L2,T1,T2,d,e. L2 ⊢ T1 ▶ [d, e] T2 → ∀L1. L1 ➡ L2 →
-                      ∃∃T. L1 ⊢ T1 ▶ [d, e] T & T ➡ T2.
-#L2 #T1 #T2 #d #e #H elim H -L2 -T1 -T2 -d -e
-[ /2 width=3/
-| #L2 #K2 #V2 #W2 #i #d #e #Hdi #Hide #HLK2 #HVW2 #L1 #HL12
-  elim (ltpr_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
-  elim (ltpr_inv_pair2 … H) -H #K1 #V1 #HK12 #HV12 #H destruct -K2
-  elim (lift_total V1 0 (i+1)) #W1 #HVW1
-  lapply (tpr_lift … HV12 … HVW1 … HVW2) -V2 /3 width=4/
-| #L2 #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (IHV12 … HL12) -IHV12 #V #HV1 #HV2
-  elim (IHT12 (L1.ⓑ{I}V) ?) /2 width=1/ -L2 /3 width=5/
-| #L2 #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (IHV12 … HL12) -IHV12
-  elim (IHT12 … HL12) -L2 /3 width=5/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpr_tpss.etc
deleted file mode 100644 (file)
index 71586fa..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/unfold/ltpss_dx_ltpss_dx.ma".
-include "basic_2/reducibility/ltpr_tps.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
-
-(* Properties on partial unfold for terms ***********************************)
-
-(* Basic_1: was: pr0_subst1 *)
-lemma ltpr_tpr_tps_conf: ∀T1,T2. T1 ➡ T2 →
-                         ∀L1,d,e,U1. L1 ⊢ T1 ▶ [d, e] U1 →
-                         ∀L2. L1 ➡ L2 →
-                         ∃∃U2. U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
-#T1 #T2 #H elim H -T1 -T2
-[ #I #L1 #d #e #U1 #H #L2 #HL12
-  elim (ltpr_tps_conf … H … HL12) -L1 /3 width=3/
-| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_flat1 … H) -H #W1 #U1 #HVW1 #HTU1 #H destruct
-  elim (IHV12 … HVW1 … HL12) -V1
-  elim (IHT12 … HTU1 … HL12) -T1 -HL12 /3 width=5/
-| #a #V1 #V2 #W #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_flat1 … H) -H #VV1 #Y #HVV1 #HY #HX destruct
-  elim (tps_inv_bind1 … HY) -HY #WW #TT1 #_ #HTT1 #H destruct
-  elim (IHV12 … HVV1 … HL12) -V1 #VV2 #HVV12 #HVV2
-  elim (IHT12 … HTT1 (L2. ⓛWW) ?) -T1 /2 width=1/ -HL12 #TT2 #HTT12 #HTT2
-  lapply (tpss_lsubr_trans … HTT2 (L2. ⓓVV2) ?) -HTT2 /3 width=5/
-| #a #I #V1 #V2 #T1 #T #T2 #HV12 #_ #HT2 #IHV12 #IHT1 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_bind1 … H) -H #W1 #U1 #HVW1 #HTU1 #H destruct
-  elim (IHV12 … HVW1 … HL12) -V1 #W2 #HW12 #HVW2
-  elim (IHT1 … HTU1 (L2. ⓑ{I} W2) ?) -T1 /2 width=1/ -HL12 #U #HU1 #HTU
-  elim (tpss_strip_neq … HTU … HT2 ?) -T /2 width=1/ #U2 #HU2 #HTU2
-  lapply (tps_lsubr_trans … HU2 (L2. ⓑ{I} V2) ?) -HU2 /2 width=1/ #HU2
-  elim (ltpss_dx_tps_conf … HU2 (L2. ⓑ{I} W2) (d + 1) e ?) -HU2 /2 width=1/ #U3 #HU3 #HU23
-  lapply (tps_lsubr_trans … HU3 (⋆. ⓑ{I} W2) ?) -HU3 /2 width=1/ #HU3
-  lapply (tpss_lsubr_trans … HU23 (L2. ⓑ{I} W2) ?) -HU23 /2 width=1/ #HU23
-  lapply (tpss_trans_eq … HTU2 … HU23) -U2 /3 width=5/
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_flat1 … H) -H #VV1 #Y #HVV1 #HY #HX destruct
-  elim (tps_inv_bind1 … HY) -HY #WW1 #TT1 #HWW1 #HTT1 #H destruct
-  elim (IHV12 … HVV1 … HL12) -V1 #VV2 #HVV12 #HVV2
-  elim (IHW12 … HWW1 … HL12) -W1 #WW2 #HWW12 #HWW2
-  elim (IHT12 … HTT1 (L2. ⓓWW2) ?) -T1 /2 width=1/ -HL12 #TT2 #HTT12 #HTT2
-  elim (lift_total VV2 0 1) #VV #H2VV
-  lapply (tpss_lift_ge … HVV2 (L2. ⓓWW2) … HV2 … H2VV) -V2 /2 width=1/ #HVV
-  @ex2_intro [2: @tpr_theta |1: skip |3: @tpss_bind [2: @tpss_flat ] ] /width=11/ (**) (* /4 width=11/ is too slow *)
-| #V #T1 #T #T2 #_ #HT2 #IHT1 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_bind1 … H) -H #W #U1 #_ #HTU1 #H destruct -V
-  elim (IHT1 … HTU1 (L2.ⓓW) ?) -T1 /2 width=1/ -HL12 #U #HU1 #HTU
-  elim (tpss_inv_lift1_ge … HTU L2 … HT2 ?) -T <minus_plus_m_m /3 width=3/
-| #V1 #T1 #T2 #_ #IHT12 #L1 #d #e #X #H #L2 #HL12
-  elim (tps_inv_flat1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct
-  elim (IHT12 … HTT1 … HL12) -T1 -HL12 /3 width=3/
-]
-qed-.
-
-lemma tpr_tps_conf_bind: ∀I,V1,V2,T1,T2,U1. V1 ➡ V2 → T1 ➡ T2 →
-                         ⋆. ⓑ{I} V1 ⊢ T1 ▶ [0, 1] U1 →
-                         ∃∃U2. U1 ➡ U2 & ⋆. ⓑ{I} V2 ⊢ T2 ▶ [0, 1] U2.
-#I #V1 #V2 #T1 #T2 #U1 #HV12 #HT12 #HTU1
-elim (ltpr_tpr_tps_conf … HT12 … HTU1 (⋆. ⓑ{I} V2) ?) -T1 /2 width=1/ -V1 #U2 #HU12 #HTU2
-lapply (tpss_inv_SO2 … HTU2) -HTU2 /2 width=3/
-qed-.
-
-lemma ltpr_tpr_tpss_conf: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. T1 ➡ T2 →
-                          ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
-                          ∃∃U2. U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
-#L1 #L2 #HL12 #T1 #T2 #HT12 #d #e #U1 #HTU1 @(tpss_ind … HTU1) -U1
-[ /2 width=3/
-| -HT12 #U #U1 #_ #HU1 * #T #HUT #HT2
-  elim (ltpr_tpr_tps_conf … HUT … HU1 … HL12) -U -HL12 #U2 #HU12 #HTU2
-  lapply (tpss_trans_eq … HT2 … HTU2) -T /2 width=3/
-]
-qed-.
-
-lemma tpr_tpss_conf: ∀T1,T2. T1 ➡ T2 →
-                     ∀L,U1,d,e. L ⊢ T1 ▶* [d, e] U1 →
-                     ∃∃U2. U1 ➡ U2 & L ⊢ T2 ▶* [d, e] U2.
-/2 width=5 by ltpr_tpr_tpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs.etc
deleted file mode 100644 (file)
index 8e0c32e..0000000
+++ /dev/null
@@ -1,90 +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/reducibility/ltpr.ma".
-include "basic_2/computation/tprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
-
-definition ltprs: relation lenv ≝ TC … ltpr.
-
-interpretation
-  "context-free parallel computation (environment)"
-  'PRedStar L1 L2 = (ltprs L1 L2).
-
-(* Basic eliminators ********************************************************)
-
-lemma ltprs_ind: ∀L1. ∀R:predicate lenv. R L1 →
-                 (∀L,L2. L1 ➡* L → L ➡ L2 → R L → R L2) →
-                 ∀L2. L1 ➡* L2 → R L2.
-#L1 #R #HL1 #IHL1 #L2 #HL12
-@(TC_star_ind … HL1 IHL1 … HL12) //
-qed-.
-
-lemma ltprs_ind_dx: ∀L2. ∀R:predicate lenv. R L2 →
-                    (∀L1,L. L1 ➡ L → L ➡* L2 → R L → R L1) →
-                    ∀L1. L1 ➡* L2 → R L1.
-#L2 #R #HL2 #IHL2 #L1 #HL12
-@(TC_star_ind_dx … HL2 IHL2 … HL12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma ltprs_refl: reflexive … ltprs.
-/2 width=1/ qed.
-
-lemma ltpr_ltprs: ∀L1,L2. L1 ➡ L2 → L1 ➡* L2.
-/2 width=1/ qed.
-
-lemma ltprs_strap1: ∀L1,L,L2. L1 ➡* L → L ➡ L2 → L1 ➡* L2.
-/2 width=3/ qed.
-
-lemma ltprs_strap2: ∀L1,L,L2. L1 ➡ L → L ➡* L2 → L1 ➡* L2.
-/2 width=3/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma ltprs_inv_atom1: ∀L2. ⋆ ➡* L2 → L2 = ⋆.
-#L2 #H @(ltprs_ind … H) -L2 //
-#L #L2 #_ #HL2 #IHL1 destruct
->(ltpr_inv_atom1 … HL2) -L2 //
-qed-.
-
-lemma ltprs_inv_pair1: ∀I,K1,L2,V1. K1. ⓑ{I} V1 ➡* L2 →
-                       ∃∃K2,V2. K1 ➡* K2 & V1 ➡* V2 & L2 = K2. ⓑ{I} V2.
-#I #K1 #L2 #V1 #H @(ltprs_ind … H) -L2 /2 width=5/
-#L #L2 #_ #HL2 * #K #V #HK1 #HV1 #H destruct
-elim (ltpr_inv_pair1 … HL2) -HL2 #K2 #V2 #HK2 #HV2 #H destruct /3 width=5/
-qed-.
-
-lemma ltprs_inv_atom2: ∀L1. L1 ➡* ⋆ → L1 = ⋆.
-#L1 #H @(ltprs_ind_dx … H) -L1 //
-#L1 #L #HL1 #_ #IHL2 destruct
->(ltpr_inv_atom2 … HL1) -L1 //
-qed-.
-
-lemma ltprs_inv_pair2: ∀I,L1,K2,V2. L1 ➡* K2. ⓑ{I} V2 →
-                       ∃∃K1,V1. K1 ➡* K2 & V1 ➡* V2 & L1 = K1. ⓑ{I} V1.
-#I #L1 #K2 #V2 #H @(ltprs_ind_dx … H) -L1 /2 width=5/
-#L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
-elim (ltpr_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct /3 width=5/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma ltprs_fwd_length: ∀L1,L2. L1 ➡* L2 → |L1| = |L2|.
-#L1 #L2 #H @(ltprs_ind … H) -L2 //
-#L #L2 #_ #HL2 #IHL1
->IHL1 -L1 >(ltpr_fwd_length … HL2) -HL2 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_alt.etc
deleted file mode 100644 (file)
index 1d2db2d..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-notation "hvbox( T1 ➡ ➡ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PRedStarAlt $T1 $T2 }.
-
-include "basic_2/computation/ltprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
-
-(* alternative definition of ltprs *)
-definition ltprsa: relation lenv ≝ lpx tprs.
-
-interpretation
-  "context-free parallel computation (environment) alternative"
-  'PRedStarAlt L1 L2 = (ltprsa L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma ltprs_ltprsa: ∀L1,L2. L1 ➡* L2 → L1 ➡➡* L2.
-/2 width=1/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma ltprsa_ltprs: ∀L1,L2. L1 ➡➡* L2 → L1 ➡* L2.
-/2 width=1/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ldrop.etc
deleted file mode 100644 (file)
index a7c3200..0000000
+++ /dev/null
@@ -1,27 +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/reducibility/ltpr_ldrop.ma".
-include "basic_2/computation/ltprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
-
-lemma ltprs_ldrop_conf: dropable_sn ltprs.
-/2 width=3/ qed.
-
-lemma ldrop_ltprs_trans: dedropable_sn ltprs.
-/2 width=3/ qed.
-
-lemma ltprs_ldrop_trans_O1: dropable_dx ltprs.
-/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltprs_ltprs.etc
deleted file mode 100644 (file)
index 7ededf2..0000000
+++ /dev/null
@@ -1,32 +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/reducibility/ltpr_ltpr.ma".
-include "basic_2/computation/ltprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
-
-(* Advanced properties ******************************************************)
-
-lemma ltprs_strip: ∀L1. ∀L:lenv. L ➡* L1 → ∀L2. L ➡ L2 →
-                   ∃∃L0. L1 ➡ L0 & L2 ➡* L0.
-/3 width=3/ qed.
-
-(* Main properties **********************************************************)
-
-theorem ltprs_conf: confluent … ltprs.
-/3 width=3/ qed.
-
-theorem ltprs_trans: Transitive … ltprs.
-/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx.etc
deleted file mode 100644 (file)
index 753c948..0000000
+++ /dev/null
@@ -1,278 +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 "hvbox( T1 break ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStar $T1 $d $e $T2 }.
-
-include "basic_2/unfold/tpss.ma".
-
-(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Basic_1: includes: csubst1_bind *)
-inductive ltpss_dx: nat → nat → relation lenv ≝
-| ltpss_dx_atom : ∀d,e. ltpss_dx d e (⋆) (⋆)
-| ltpss_dx_pair : ∀L,I,V. ltpss_dx 0 0 (L. ⓑ{I} V) (L. ⓑ{I} V)
-| ltpss_dx_tpss2: ∀L1,L2,I,V1,V2,e.
-                  ltpss_dx 0 e L1 L2 → L2 ⊢ V1 ▶* [0, e] V2 →
-                  ltpss_dx 0 (e + 1) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
-| ltpss_dx_tpss1: ∀L1,L2,I,V1,V2,d,e.
-                  ltpss_dx d e L1 L2 → L2 ⊢ V1 ▶* [d, e] V2 →
-                  ltpss_dx (d + 1) e (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
-.
-
-interpretation "parallel unfold (local environment, dx variant)"
-   'PSubstStar L1 d e L2 = (ltpss_dx d e L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact ltpss_dx_inv_refl_O2_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → e = 0 → L1 = L2.
-#d #e #L1 #L2 #H elim H -d -e -L1 -L2 //
-[ #L1 #L2 #I #V1 #V2 #e #_ #_ #_ >commutative_plus normalize #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #HV12 #IHL12 #He destruct
-  >(IHL12 ?) -IHL12 // >(tpss_inv_refl_O2 … HV12) //
-]
-qed.
-
-lemma ltpss_dx_inv_refl_O2: ∀d,L1,L2. L1 ▶* [d, 0] L2 → L1 = L2.
-/2 width=4/ qed-.
-
-fact ltpss_dx_inv_atom1_aux: ∀d,e,L1,L2.
-                             L1 ▶* [d, e] L2 → L1 = ⋆ → L2 = ⋆.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ //
-| #L #I #V #H destruct
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
-]
-qed.
-
-lemma ltpss_dx_inv_atom1: ∀d,e,L2. ⋆ ▶* [d, e] L2 → L2 = ⋆.
-/2 width=5/ qed-.
-
-fact ltpss_dx_inv_tpss21_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → d = 0 → 0 < e →
-                              ∀K1,I,V1. L1 = K1. ⓑ{I} V1 →
-                              ∃∃K2,V2. K1 ▶* [0, e - 1] K2 &
-                                       K2 ⊢ V1 ▶* [0, e - 1] V2 &
-                                       L2 = K2. ⓑ{I} V2.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #_ #K1 #I #V1 #H destruct
-| #L1 #I #V #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K1 #J #W1 #H destruct /2 width=5/
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma ltpss_dx_inv_tpss21: ∀e,K1,I,V1,L2. K1. ⓑ{I} V1 ▶* [0, e] L2 → 0 < e →
-                           ∃∃K2,V2. K1 ▶* [0, e - 1] K2 &
-                                    K2 ⊢ V1 ▶* [0, e - 1] V2 &
-                                    L2 = K2. ⓑ{I} V2.
-/2 width=5/ qed-.
-
-fact ltpss_dx_inv_tpss11_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → 0 < d →
-                              ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
-                              ∃∃K2,V2. K1 ▶* [d - 1, e] K2 &
-                                       K2 ⊢ V1 ▶* [d - 1, e] V2 &
-                                       L2 = K2. ⓑ{I} V2.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #I #K1 #V1 #H destruct
-| #L #I #V #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K1 #W1 #H destruct /2 width=5/
-]
-qed.
-
-lemma ltpss_dx_inv_tpss11: ∀d,e,I,K1,V1,L2. K1. ⓑ{I} V1 ▶* [d, e] L2 → 0 < d →
-                           ∃∃K2,V2. K1 ▶* [d - 1, e] K2 &
-                                    K2 ⊢ V1 ▶* [d - 1, e] V2 &
-                                    L2 = K2. ⓑ{I} V2.
-/2 width=3/ qed-.
-
-fact ltpss_dx_inv_atom2_aux: ∀d,e,L1,L2.
-                             L1 ▶* [d, e] L2 → L2 = ⋆ → L1 = ⋆.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ //
-| #L #I #V #H destruct
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
-]
-qed.
-
-lemma ltpss_dx_inv_atom2: ∀d,e,L1. L1 ▶* [d, e] ⋆ → L1 = ⋆.
-/2 width=5/ qed-.
-
-fact ltpss_dx_inv_tpss22_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → d = 0 → 0 < e →
-                              ∀K2,I,V2. L2 = K2. ⓑ{I} V2 →
-                              ∃∃K1,V1. K1 ▶* [0, e - 1] K2 &
-                                       K2 ⊢ V1 ▶* [0, e - 1] V2 &
-                                       L1 = K1. ⓑ{I} V1.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #_ #K1 #I #V1 #H destruct
-| #L1 #I #V #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K2 #J #W2 #H destruct /2 width=5/
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma ltpss_dx_inv_tpss22: ∀e,L1,K2,I,V2. L1 ▶* [0, e] K2. ⓑ{I} V2 → 0 < e →
-                           ∃∃K1,V1. K1 ▶* [0, e - 1] K2 &
-                                    K2 ⊢ V1 ▶* [0, e - 1] V2 &
-                                    L1 = K1. ⓑ{I} V1.
-/2 width=5/ qed-.
-
-fact ltpss_dx_inv_tpss12_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → 0 < d →
-                              ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
-                              ∃∃K1,V1. K1 ▶* [d - 1, e] K2 &
-                                       K2 ⊢ V1 ▶* [d - 1, e] V2 &
-                                       L1 = K1. ⓑ{I} V1.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #I #K2 #V2 #H destruct
-| #L #I #V #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K2 #W2 #H destruct /2 width=5/
-]
-qed.
-
-lemma ltpss_dx_inv_tpss12: ∀L1,K2,I,V2,d,e. L1 ▶* [d, e] K2. ⓑ{I} V2 → 0 < d →
-                           ∃∃K1,V1. K1 ▶* [d - 1, e] K2 &
-                                    K2 ⊢ V1 ▶* [d - 1, e] V2 &
-                                    L1 = K1. ⓑ{I} V1.
-/2 width=3/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma ltpss_dx_tps2: ∀L1,L2,I,V1,V2,e.
-                     L1 ▶* [0, e] L2 → L2 ⊢ V1 ▶ [0, e] V2 →
-                     L1. ⓑ{I} V1 ▶* [0, e + 1] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_dx_tps1: ∀L1,L2,I,V1,V2,d,e.
-                     L1 ▶* [d, e] L2 → L2 ⊢ V1 ▶ [d, e] V2 →
-                     L1. ⓑ{I} V1 ▶* [d + 1, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_dx_tpss2_lt: ∀L1,L2,I,V1,V2,e.
-                         L1 ▶* [0, e - 1] L2 → L2 ⊢ V1 ▶* [0, e - 1] V2 →
-                         0 < e → L1. ⓑ{I} V1 ▶* [0, e] L2. ⓑ{I} V2.
-#L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #He
->(plus_minus_m_m e 1) /2 width=1/
-qed.
-
-lemma ltpss_dx_tpss1_lt: ∀L1,L2,I,V1,V2,d,e.
-                         L1 ▶* [d - 1, e] L2 → L2 ⊢ V1 ▶* [d - 1, e] V2 →
-                         0 < d → L1. ⓑ{I} V1 ▶* [d, e] L2. ⓑ{I} V2.
-#L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #Hd
->(plus_minus_m_m d 1) /2 width=1/
-qed.
-
-lemma ltpss_dx_tps2_lt: ∀L1,L2,I,V1,V2,e.
-                        L1 ▶* [0, e - 1] L2 → L2 ⊢ V1 ▶ [0, e - 1] V2 →
-                        0 < e → L1. ⓑ{I} V1 ▶* [0, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_dx_tps1_lt: ∀L1,L2,I,V1,V2,d,e.
-                        L1 ▶* [d - 1, e] L2 → L2 ⊢ V1 ▶ [d - 1, e] V2 →
-                        0 < d → L1. ⓑ{I} V1 ▶* [d, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-(* Basic_1: was by definition: csubst1_refl *)
-lemma ltpss_dx_refl: ∀L,d,e. L ▶* [d, e] L.
-#L elim L -L //
-#L #I #V #IHL * /2 width=1/ * /2 width=1/
-qed.
-
-lemma ltpss_dx_weak: ∀L1,L2,d1,e1. L1 ▶* [d1, e1] L2 →
-                     ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 → L1 ▶* [d2, e2] L2.
-#L1 #L2 #d1 #e1 #H elim H -L1 -L2 -d1 -e1 //
-[ #L1 #L2 #I #V1 #V2 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd2 #Hde2
-  lapply (le_n_O_to_eq … Hd2) #H destruct normalize in Hde2;
-  lapply (lt_to_le_to_lt 0 … Hde2) // #He2
-  lapply (le_plus_to_minus_r … Hde2) -Hde2 /3 width=5/
-| #L1 #L2 #I #V1 #V2 #d1 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd21 #Hde12
-  >plus_plus_comm_23 in Hde12; #Hde12
-  elim (le_to_or_lt_eq 0 d2 ?) // #H destruct
-  [ lapply (le_plus_to_minus_r … Hde12) -Hde12 <plus_minus // #Hde12
-    lapply (le_plus_to_minus … Hd21) -Hd21 #Hd21 /3 width=5/
-  | -Hd21 normalize in Hde12;
-    lapply (lt_to_le_to_lt 0 … Hde12) // #He2
-    lapply (le_plus_to_minus_r … Hde12) -Hde12
-    /3 width=5 by ltpss_dx_tpss2_lt, tpss_weak/ (**) (* /3 width=5/ used to work *)
-  ]
-]
-qed.
-
-lemma ltpss_dx_weak_full: ∀L1,L2,d,e. L1 ▶* [d, e] L2 → L1 ▶* [0, |L2|] L2.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
-// /3 width=2/ /3 width=3/
-qed.
-
-fact ltpss_dx_append_le_aux: ∀K1,K2,d,x. K1 ▶* [d, x] K2 → x = |K1| - d →
-                             ∀L1,L2,e. L1 ▶* [0, e] L2 → d ≤ |K1| →
-                             L1 @@ K1 ▶* [d, x + e] L2 @@ K2.
-#K1 #K2 #d #x #H elim H -K1 -K2 -d -x
-[ #d #x #H1 #L1 #L2 #e #HL12 #H2 destruct
-  lapply (le_n_O_to_eq … H2) -H2 #H destruct //
-| #K #I #V <minus_n_O normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #x #_ #HV12 <minus_n_O #IHK12 <minus_n_O #H #L1 #L2 #e #HL12 #_
-  lapply (injective_plus_l … H) -H #H destruct >plus_plus_comm_23
-  /4 width=5 by ltpss_dx_tpss2, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
-| #K1 #K2 #I #V1 #V2 #d #x #_ #HV12 #IHK12 normalize <minus_le_minus_minus_comm // <minus_plus_m_m #H1 #L1 #L2 #e #HL12 #H2 destruct
-  lapply (le_plus_to_le_r … H2) -H2 #Hd
-  /4 width=5 by ltpss_dx_tpss1, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
-]
-qed-.
-
-lemma ltpss_dx_append_le: ∀K1,K2,d. K1 ▶* [d, |K1| - d] K2 →
-                          ∀L1,L2,e. L1 ▶* [0, e] L2 → d ≤ |K1| →
-                          L1 @@ K1 ▶* [d, |K1| - d + e] L2 @@ K2.
-/2 width=1 by ltpss_dx_append_le_aux/ qed.
-
-lemma ltpss_dx_append_zero: ∀K1,K2. K1 ▶* [0, |K1|] K2 →
-                            ∀L1,L2,e. L1 ▶* [0, e] L2 →
-                            L1 @@ K1 ▶* [0, |K1| + e] L2 @@ K2.
-/2 width=1/ qed.
-
-lemma ltpss_dx_append_ge: ∀K1,K2,d,e. K1 ▶* [d, e] K2 →
-                          ∀L1,L2. L1 ▶* [d - |K1|, e] L2 → |K1| ≤ d →
-                          L1 @@ K1 ▶* [d, e] L2 @@ K2.
-#K1 #K2 #d #e #H elim H -K1 -K2 -d -e
-[ #d #e #L1 #L2 <minus_n_O //
-| #K #I #V #L1 #L2 #_ #H
-  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #e #_ #_ #_ #L1 #L2 #_ #H
-  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #d #e #_ #HV12 #IHK12 #L1 #L2
-  normalize <minus_le_minus_minus_comm // <minus_plus_m_m #HL12 #H
-  lapply (le_plus_to_le_r … H) -H /3 width=1/
-]
-qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma ltpss_dx_fwd_length: ∀L1,L2,d,e. L1 ▶* [d, e] L2 → |L1| = |L2|.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
-normalize //
-qed-.
-
-(* Basic_1: removed theorems 28:
-            csubst0_clear_O csubst0_drop_lt csubst0_drop_gt csubst0_drop_eq
-            csubst0_clear_O_back csubst0_clear_S csubst0_clear_trans
-            csubst0_drop_gt_back csubst0_drop_eq_back csubst0_drop_lt_back
-            csubst0_gen_sort csubst0_gen_head csubst0_getl_ge csubst0_getl_lt
-            csubst0_gen_S_bind_2 csubst0_getl_ge_back csubst0_getl_lt_back
-            csubst0_snd_bind csubst0_fst_bind csubst0_both_bind
-            csubst1_head csubst1_flat csubst1_gen_head
-            csubst1_getl_ge csubst1_getl_lt csubst1_getl_ge_back getl_csubst1
-            fsubst0_gen_base
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ldrop.etc
deleted file mode 100644 (file)
index 0b6c504..0000000
+++ /dev/null
@@ -1,230 +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/fsup.ma".
-include "basic_2/unfold/tpss_lift.ma".
-include "basic_2/unfold/ltpss_dx.ma".
-
-(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properies on local environment slicing ***********************************)
-
-lemma ltpss_dx_ldrop_conf_ge: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                              d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
-| //
-| normalize #K0 #K1 #I #V0 #V1 #e1 #_ #_ #IHK01 #L2 #e2 #H #He12
-  elim (le_inv_plus_l … He12) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
-| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
-]
-qed.
-
-lemma ltpss_dx_ldrop_trans_ge: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                               d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
-| //
-| normalize #K1 #K0 #I #V1 #V0 #e1 #_ #_ #IHK10 #L2 #e2 #H #He12
-  elim (le_inv_plus_l … He12) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK10 … HK0L2 ?) -K0 /2 width=1/
-| #K0 #K1 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK10 … HK0L2 ?) -IHK10 -HK0L2 /2 width=1/
-]
-qed.
-
-lemma ltpss_dx_ldrop_conf_be: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
-                              ∃∃L. L2 ▶* [0, d1 + e1 - e2] L & ⇩[0, e2] L1 ≡ L.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
-  lapply (le_n_O_to_eq … He2) -He2 #H destruct
-  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
-| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #_ #He21
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK01 -He21 destruct <minus_n_O /3 width=3/
-  | -HK01 -HV01 <minus_le_minus_minus_comm //
-    elim (IHK01 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
-  ]
-| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2 #He2de1
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  <minus_le_minus_minus_comm //
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  elim (IHK01 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
-]
-qed.
-
-lemma ltpss_dx_ldrop_trans_be: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
-                               ∃∃L. L ▶* [0, d1 + e1 - e2] L2 & ⇩[0, e2] L1 ≡ L.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
-  lapply (le_n_O_to_eq … He2) -He2 #H destruct
-  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
-| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #_ #He21
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK10 -He21 destruct <minus_n_O /3 width=3/
-  | -HK10 -HV10 <minus_le_minus_minus_comm //
-    elim (IHK10 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
-  ]
-| #K1 #K0 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2 #He2de1
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  <minus_le_minus_minus_comm //
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  elim (IHK10 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
-]
-qed.
-
-lemma ltpss_dx_ldrop_conf_le: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                              ∃∃L. L2 ▶* [d1 - e2, e1] L & ⇩[0, e2] L1 ≡ L.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #_ #L2 #e2 #H #He2
-  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
-  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
-| #K0 #K1 #I #V0 #V1 #d1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #He2d1
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK01 -He2d1 destruct <minus_n_O /3 width=3/
-  | -HK01 -HV01 <minus_le_minus_minus_comm //
-    elim (IHK01 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
-  ]
-]
-qed.
-
-lemma ltpss_dx_ldrop_trans_le: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                               ∃∃L. L ▶* [d1 - e2, e1] L2 & ⇩[0, e2] L1 ≡ L.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #_ #L2 #e2 #H #He2
-  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
-  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
-| #K1 #K0 #I #V1 #V0 #d1 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #He2d1
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK10 -He2d1 destruct <minus_n_O /3 width=3/
-  | -HK10 -HV10 <minus_le_minus_minus_comm //
-    elim (IHK10 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
-  ]
-]
-qed.
-
-lemma ldrop_ltpss_dx_trans_le: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 → d1 ≤ d2 →
-                               ∃∃L2. L1 ▶* [d2 + e1, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_
-  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #Hd
-  elim (IHLK1 … HK12 Hd) -K1 -Hd /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #_ #HWV1 #IHLK1 #X #d2 #e2 #H #Hd12
-  elim (le_inv_plus_l … Hd12) -Hd12 #Hd12 #Hd2
-  elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-  elim (IHLK1 … HK12 … Hd12) -IHLK1 -HK12 <le_plus_minus_comm // #L2 #HL12 #HLK2
-  elim (lift_total W2 d1 e1) #V2 #HWV2
-  lapply (tpss_lift_ge … HW12 … HLK2 HWV1 … HWV2) -W1 // -Hd12
-  <le_plus_minus_comm // /4 width=5/
-]
-qed-.
-
-lemma ldrop_ltpss_dx_trans_be: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 →
-                               d2 ≤ d1 → d1 ≤ d2 + e2 →
-                               ∃∃L2. L1 ▶* [d2, e1 + e2] L2 &
-                                     ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_ #_
-  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H #_
-  lapply (le_n_O_to_eq … H) -H #H destruct /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H1 #H2
-  elim (IHLK1 … HK12 H1 H2) -K1 -H2
-  lapply (le_n_O_to_eq … H1) -H1 #H destruct /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #_ #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21 #Hd12
-  elim (eq_or_gt d2) #Hd2 [ -Hd21 elim (eq_or_gt e2) #He2 ] destruct
-  [ lapply (le_n_O_to_eq … Hd12) -Hd12 <plus_n_Sm #H destruct
-  | elim (ltpss_dx_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 // /2 width=1/ >plus_minus_commutative // #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_be … HW12 … HLK2 HWV1 … HWV2) -W1 // /2 width=1/
-    >plus_minus // >commutative_plus /4 width=5/
-  | elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // ] /2 width=1/ #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_be … HW12 … HLK2 HWV1 … HWV2) -W1 [ >plus_minus // ] /2 width=1/
-    >commutative_plus /3 width=5/
-  ]
-]
-qed-.
-
-lemma ldrop_ltpss_dx_trans_ge: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 → d2 + e2 ≤ d1 →
-                               ∃∃L2. L1 ▶* [d2, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_
-  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H
-  elim (plus_le_0 … H) -H #H1 #H2 destruct /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H
-  elim (IHLK1 … HK12 H) -K1
-  elim (plus_le_0 … H) -H #H1 #H2 destruct #L2 #HL12
-  >(ltpss_dx_inv_refl_O2 … HL12) -L1 /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21
-  elim (eq_or_gt d2) #Hd2 [ elim (eq_or_gt e2) #He2 ] destruct
-  [ -IHLK1 -Hd21 <(ltpss_dx_inv_refl_O2 … H) -X /3 width=5/
-  | elim (ltpss_dx_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 /2 width=1/ #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_le … HW12 … HLK2 HWV1 … HWV2) -W1 /2 width=1/ /3 width=5/
-  | elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // /2 width=1/ ] #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_le … HW12 … HLK2 HWV1 … HWV2) -W1 [ >plus_minus // /2 width=1/ ] /3 width=5/
-  ]
-]
-qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma fsup_tps_trans_full: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶[0,|L2|] U2 →
-                           ∃∃L,U1. L1 ▶*[0,|L|] L & L ⊢ T1 ▶[0,|L|] U1 & ⦃L, U1⦄ ⊃ ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
-#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
-elim (lift_total T d e) #U #HTU
-elim (le_or_ge d (|K|)) #Hd
-[ elim (ldrop_ltpss_dx_trans_be … HLK1 … HK1 … Hd) // -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (tps_lift_be … HT1 … HL2K … HTU1 HTU … Hd) // -HT1 -HTU1 #HU1
-| elim (ldrop_ltpss_dx_trans_ge … HLK1 … HK1 Hd) -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (tps_lift_le … HT1 … HL2K … HTU1 HTU Hd) -HT1 -HTU1 #HU1
-]
-lapply (ltpss_dx_weak_full … HL12) -HL12 #HL12
-lapply (tps_weak_full … HU1) -HU1 #HU1
-@(ex3_2_intro … L2 U) // /2 width=7/ (**) (* explicit constructor: auto /3 width=14/ too slow *)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_ltpss_dx.etc
deleted file mode 100644 (file)
index 74b898d..0000000
+++ /dev/null
@@ -1,106 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/ltpss_dx_tpss.ma".
-
-(* DX PARTIAL UNFOLD ON LOCAL ENVIRONMENTS **********************************)
-
-(* Advanced properties ******************************************************)
-
-lemma ltpss_dx_tpss_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                          ∀L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                          ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T &
-                               L1 ⊢ U2 ▶* [d1, e1] T.
-#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 @(tpss_ind … H) -U2 /2 width=3/
-#U #U2 #_ #HU2 * #X2 #HTX2 #HUX2
-elim (ltpss_dx_tps_conf … HU2 … HL01) -L0 #X1 #HUX1 #HU2X1
-elim (tpss_strip_eq … HUX2 … HUX1) -U #X #HX2 #HX1
-lapply (tpss_trans_eq … HU2X1 … HX1) -X1 /3 width=3/
-qed.
-
-lemma ltpss_dx_tpss_trans_down: ∀L0,L1,T2,U2,d1,e1,d2,e2. d2 + e2 ≤ d1 →
-                                L1 ▶* [d1, e1] L0 → L0 ⊢ T2 ▶* [d2, e2] U2 →
-                                ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T & L0 ⊢ T ▶* [d1, e1] U2.
-#L0 #L1 #T2 #U2 #d1 #e1 #d2 #e2 #Hde2d1 #HL10 #H @(tpss_ind … H) -U2
-[ /2 width=3/
-| #U #U2 #_ #HU2 * #T #HT2 #HTU
-  elim (tpss_strap1_down … HTU … HU2 ?) -U // #U #HTU #HU2
-  elim (ltpss_dx_tps_trans … HTU … HL10) -HTU -HL10 #X #HTX #HXU
-  lapply (tpss_trans_eq … HXU HU2) -U /3 width=3/
-]
-qed.
-
-lemma ltpss_dx_tpss_trans_eq: ∀L1,T2,U2,d,e. L1 ⊢ T2 ▶* [d, e] U2 →
-                              ∀L0. L0 ▶* [d, e] L1 → L0 ⊢ T2 ▶* [d, e] U2.
-#L1 #T2 @(f2_ind … fw … L1 T2) -L1 -T2 #n #IH #L1 *
-[ #I #Hn #W2 #d #e #H #L0 #HL01 destruct
-  elim (tpss_inv_atom1 … H) -H // *
-  #K1 #V1 #V2 #i #Hdi #Hide #HLK1 #HV12 #HVW2 #H destruct
-  lapply (ldrop_fwd_lw … HLK1) #H1 normalize in H1;
-  elim (ltpss_dx_ldrop_trans_be … HL01 … HLK1 ? ?) -HL01 -HLK1 // /2 width=2/ #X #H #HLK0
-  elim (ltpss_dx_inv_tpss22 … H ?) -H /2 width=1/ #K0 #V0 #HK01 #HV01 #H destruct
-  lapply (tpss_fwd_tw … HV01) #H2
-  lapply (transitive_le (♯{K1} + ♯{V0}) … H1) -H1 /2 width=1/ -H2 #H
-  lapply (tpss_trans_eq … HV01 HV12) -V1 #HV02
-  lapply (IH … HV02 … HK01) -IH -HV02 -HK01
-  [ normalize /2 width=1/ | /2 width=6/ ]
-| * [ #a ] #I #V2 #T2 #Hn #X #d #e #H #L0 #HL0 destruct
-  [ elim (tpss_inv_bind1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
-    lapply (tpss_lsubr_trans … HTU2 (L1. ⓑ{I} V2) ?) -HTU2 /2 width=1/ #HTU2
-    lapply (IH … HVW2 … HL0) -HVW2 [ /2 width=2/ ] #HVW2
-    lapply (IH … HTU2 (L0. ⓑ{I} V2) ?) -IH -HTU2 // /2 width=2/ -HL0 #HTU2
-    lapply (tpss_lsubr_trans … HTU2 (L0. ⓑ{I} W2) ?) -HTU2 /2 width=1/
-  | elim (tpss_inv_flat1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
-    lapply (IH … HVW2 … HL0) -HVW2 //
-    lapply (IH … HTU2 … HL0) -IH -HTU2 // -HL0 /2 width=1/
-]
-qed.
-
-lemma ltpss_dx_tps_trans_eq: ∀L0,L1,T2,U2,d,e. L0 ▶* [d, e] L1 →
-                             L1 ⊢ T2 ▶ [d, e] U2 → L0 ⊢ T2 ▶* [d, e] U2.
-/3 width=3/ qed.
-
-(* Main properties **********************************************************)
-
-theorem ltpss_dx_conf: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                       ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
-                       ∃∃L. L1 ▶* [d2, e2] L & L2 ▶* [d1, e1] L.
-#L0 @(f_ind … lw … L0) -L0 #n #IH *
-[ #_ #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2 -n
-  >(ltpss_dx_inv_atom1 … H1) -L1
-  >(ltpss_dx_inv_atom1 … H2) -L2 /2 width=3/
-| #K0 #I0 #V0 #Hn #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2 destruct
-  elim (eq_or_gt d1) #Hd1 [ elim (eq_or_gt e1) #He1 ] destruct
-  [ lapply (ltpss_dx_inv_refl_O2 … H1) -H1 #H1
-  | elim (ltpss_dx_inv_tpss21 … H1 … He1) -H1 #K1 #V1 #HK01 #HV01 #H1
-  | elim (ltpss_dx_inv_tpss11 … H1 … Hd1) -H1 #K1 #V1 #HK01 #HV01 #H1
-  ] destruct
-  elim (eq_or_gt d2) #Hd2 [1,3,5: elim (eq_or_gt e2) #He2 ] destruct
-  [1,3,5: lapply (ltpss_dx_inv_refl_O2 … H2) -H2 #H2
-  |2,4,6: elim (ltpss_dx_inv_tpss21 … H2 … He2) -H2 #K2 #V2 #HK02 #HV02 #H2
-  |7,8,9: elim (ltpss_dx_inv_tpss11 … H2 … Hd2) -H2 #K2 #V2 #HK02 #HV02 #H2
-  ] destruct
-  [1: -IH /2 width=3/
-  |2,3,4,7: -IH /3 width=5/
-  |5,6,8,9:
-    elim (IH … HK01 … HK02) // -K0 #K #HK1 #HK2
-    elim (ltpss_dx_tpss_conf … HV01 … HK1) -HV01 #W1 #HW1 #HVW1
-    elim (ltpss_dx_tpss_conf … HV02 … HK2) -HV02 #W2 #HW2 #HVW2
-    elim (tpss_conf_eq … HW1 … HW2) -V0 #V #HW1 #HW2
-    lapply (tpss_trans_eq … HVW1 HW1) -W1
-    lapply (tpss_trans_eq … HVW2 HW2) -W2 /3 width=5/
-  ]
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tps.etc
deleted file mode 100644 (file)
index b103066..0000000
+++ /dev/null
@@ -1,47 +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/unfold/ltpss_dx_ldrop.ma".
-
-(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properties concerning partial substitution on terms **********************)
-
-lemma ltpss_dx_tps_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                            ∀L1,d1,e1. L0 ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
-                            L1 ⊢ T2 ▶ [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ //
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01 #Hde1d2
-  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
-  lapply (ltpss_dx_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /2 width=4/
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01 #Hde1d2
-  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_dx_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
-| /3 width=4/
-]
-qed.
-
-lemma ltpss_dx_tps_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                             ∀L1,d1,e1. L1 ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
-                             L1 ⊢ T2 ▶ [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ //
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10 #Hde1d2
-  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
-  lapply (ltpss_dx_ldrop_trans_ge … HL10 … HLK0 ?) -L0 // /2 width=4/
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10 #Hde1d2
-  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_dx_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
-| /3 width=4/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_dx_tpss.etc
deleted file mode 100644 (file)
index 9c78759..0000000
+++ /dev/null
@@ -1,101 +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/unfold/ltpss_dx_tps.ma".
-
-(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properties concerning partial unfold on terms ****************************)
-
-lemma ltpss_dx_tpss_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                             ∀L1,d1,e1. L0 ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
-                             L1 ⊢ T2 ▶* [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU
-lapply (ltpss_dx_tps_conf_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
-qed.
-
-(* Basic_1: was: subst1_subst1_back *)
-lemma ltpss_dx_tps_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                         ∀L1,d1,e1. L0 ▶* [d1, e1] L1 →
-                         ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
-                              L1 ⊢ U2 ▶* [d1, e1] T.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ /2 width=3/
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01
-  elim (lt_or_ge i2 d1) #Hi2d1
-  [ elim (ltpss_dx_ldrop_conf_le … HL01 … HLK0 ?) -L0 /2 width=2/ #X #H #HLK1
-    elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK1) #H
-    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-    lapply (tpss_lift_ge … HV01 … H HVW0 … HVW1) -V0 -H // >minus_plus <plus_minus_m_m // /3 width=4/
-  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
-    [ elim (ltpss_dx_ldrop_conf_be … HL01 … HLK0 ? ?) -L0 // /2 width=2/ #X #H #HLK1
-      elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK1) #H
-      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-      lapply (tpss_lift_ge … HV01 … H HVW0 … HVW1) -V0 -H // normalize #HW01
-      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /2 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
-    | lapply (ltpss_dx_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /3 width=4/
-    ]
-  ]
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
-  elim (IHVW2 … HL01) -IHVW2 #V #HV2 #HVW2
-  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL01 /3 width=5/
-| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
-  elim (IHVW2 … HL01) -IHVW2
-  elim (IHTU2 … HL01) -IHTU2 -HL01 /3 width=5/
-]
-qed.
-
-lemma ltpss_dx_tpss_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                              ∀L1,d1,e1. L1 ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
-                              L1 ⊢ T2 ▶* [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU
-lapply (ltpss_dx_tps_trans_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
-qed.
-
-(* Basic_1: was: subst1_subst1 *)
-lemma ltpss_dx_tps_trans: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                          ∀L1,d1,e1. L1 ▶* [d1, e1] L0 →
-                          ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
-                               L0 ⊢ T ▶* [d1, e1] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ /2 width=3/
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10
-  elim (lt_or_ge i2 d1) #Hi2d1
-  [ elim (ltpss_dx_ldrop_trans_le … HL10 … HLK0 ?) -HL10 /2 width=2/ #X #H #HLK1
-    elim (ltpss_dx_inv_tpss12 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #H
-    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-    lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // >minus_plus <plus_minus_m_m /2 width=1/ /3 width=4/
-  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
-    [ elim (ltpss_dx_ldrop_trans_be … HL10 … HLK0 ? ?) -HL10 // /2 width=2/ #X #H #HLK1
-      elim (ltpss_dx_inv_tpss22 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #H
-      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-      lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // normalize #HW01
-      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /3 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
-    | lapply (ltpss_dx_ldrop_trans_ge … HL10 … HLK0 ?) -HL10 -HLK0 // /3 width=4/
-    ]
-  ]
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
-  elim (IHVW2 … HL10) -IHVW2 #V #HV2 #HVW2
-  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL10 /3 width=5/
-| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
-  elim (IHVW2 … HL10) -IHVW2
-  elim (IHTU2 … HL10) -IHTU2 -HL10 /3 width=5/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn.etc
deleted file mode 100644 (file)
index 577c150..0000000
+++ /dev/null
@@ -1,259 +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 "hvbox( T1 break ⊢ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStarSn $T1 $d $e $T2 }.
-
-include "basic_2/unfold/tpss.ma".
-
-(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-inductive ltpss_sn: nat → nat → relation lenv ≝
-| ltpss_sn_atom : ∀d,e. ltpss_sn d e (⋆) (⋆)
-| ltpss_sn_pair : ∀L,I,V. ltpss_sn 0 0 (L. ⓑ{I} V) (L. ⓑ{I} V)
-| ltpss_sn_tpss2: ∀L1,L2,I,V1,V2,e.
-                  ltpss_sn 0 e L1 L2 → L1 ⊢ V1 ▶* [0, e] V2 →
-                  ltpss_sn 0 (e + 1) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
-| ltpss_sn_tpss1: ∀L1,L2,I,V1,V2,d,e.
-                  ltpss_sn d e L1 L2 → L1 ⊢ V1 ▶* [d, e] V2 →
-                  ltpss_sn (d + 1) e (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
-.
-
-interpretation "parallel unfold (local environment, sn variant)"
-   'PSubstStarSn L1 d e L2 = (ltpss_sn d e L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact ltpss_sn_inv_refl_O2_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → e = 0 → L1 = L2.
-#d #e #L1 #L2 #H elim H -d -e -L1 -L2 //
-[ #L1 #L2 #I #V1 #V2 #e #_ #_ #_ >commutative_plus normalize #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #HV12 #IHL12 #He destruct
-  >(IHL12 ?) -IHL12 // >(tpss_inv_refl_O2 … HV12) //
-]
-qed.
-
-lemma ltpss_sn_inv_refl_O2: ∀d,L1,L2. L1 ⊢ ▶* [d, 0] L2 → L1 = L2.
-/2 width=4/ qed-.
-
-fact ltpss_sn_inv_atom1_aux: ∀d,e,L1,L2.
-                             L1 ⊢ ▶* [d, e] L2 → L1 = ⋆ → L2 = ⋆.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ //
-| #L #I #V #H destruct
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
-]
-qed.
-
-lemma ltpss_sn_inv_atom1: ∀d,e,L2. ⋆ ⊢ ▶* [d, e] L2 → L2 = ⋆.
-/2 width=5/ qed-.
-
-fact ltpss_sn_inv_tpss21_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → d = 0 → 0 < e →
-                              ∀K1,I,V1. L1 = K1. ⓑ{I} V1 →
-                              ∃∃K2,V2. K1 ⊢ ▶* [0, e - 1] K2 &
-                                       K1 ⊢ V1 ▶* [0, e - 1] V2 &
-                                       L2 = K2. ⓑ{I} V2.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #_ #K1 #I #V1 #H destruct
-| #L1 #I #V #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K1 #J #W1 #H destruct /2 width=5/
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma ltpss_sn_inv_tpss21: ∀e,K1,I,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* [0, e] L2 → 0 < e →
-                           ∃∃K2,V2. K1 ⊢ ▶* [0, e - 1] K2 &
-                                    K1 ⊢ V1 ▶* [0, e - 1] V2 &
-                                    L2 = K2. ⓑ{I} V2.
-/2 width=5/ qed-.
-
-fact ltpss_sn_inv_tpss11_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → 0 < d →
-                              ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
-                              ∃∃K2,V2. K1 ⊢ ▶* [d - 1, e] K2 &
-                                       K1 ⊢ V1 ▶* [d - 1, e] V2 &
-                                       L2 = K2. ⓑ{I} V2.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #I #K1 #V1 #H destruct
-| #L #I #V #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K1 #W1 #H destruct /2 width=5/
-]
-qed.
-
-lemma ltpss_sn_inv_tpss11: ∀d,e,I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* [d, e] L2 → 0 < d →
-                           ∃∃K2,V2. K1 ⊢ ▶* [d - 1, e] K2 &
-                                    K1 ⊢ V1 ▶* [d - 1, e] V2 &
-                                    L2 = K2. ⓑ{I} V2.
-/2 width=3/ qed-.
-
-fact ltpss_sn_inv_atom2_aux: ∀d,e,L1,L2.
-                             L1 ⊢ ▶* [d, e] L2 → L2 = ⋆ → L1 = ⋆.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ //
-| #L #I #V #H destruct
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
-]
-qed.
-
-lemma ltpss_sn_inv_atom2: ∀d,e,L1. L1 ⊢ ▶* [d, e] ⋆ → L1 = ⋆.
-/2 width=5/ qed-.
-
-fact ltpss_sn_inv_tpss22_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → d = 0 → 0 < e →
-                              ∀K2,I,V2. L2 = K2. ⓑ{I} V2 →
-                              ∃∃K1,V1. K1 ⊢ ▶* [0, e - 1] K2 &
-                                       K1 ⊢ V1 ▶* [0, e - 1] V2 &
-                                       L1 = K1. ⓑ{I} V1.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #_ #K1 #I #V1 #H destruct
-| #L1 #I #V #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K2 #J #W2 #H destruct /2 width=5/
-| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
-]
-qed.
-
-lemma ltpss_sn_inv_tpss22: ∀e,L1,K2,I,V2. L1 ⊢ ▶* [0, e] K2. ⓑ{I} V2 → 0 < e →
-                           ∃∃K1,V1. K1 ⊢ ▶* [0, e - 1] K2 &
-                                    K1 ⊢ V1 ▶* [0, e - 1] V2 &
-                                    L1 = K1. ⓑ{I} V1.
-/2 width=5/ qed-.
-
-fact ltpss_sn_inv_tpss12_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → 0 < d →
-                              ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
-                              ∃∃K1,V1. K1 ⊢ ▶* [d - 1, e] K2 &
-                                       K1 ⊢ V1 ▶* [d - 1, e] V2 &
-                                       L1 = K1. ⓑ{I} V1.
-#d #e #L1 #L2 * -d -e -L1 -L2
-[ #d #e #_ #I #K2 #V2 #H destruct
-| #L #I #V #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
-| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K2 #W2 #H destruct /2 width=5/
-]
-qed.
-
-lemma ltpss_sn_inv_tpss12: ∀L1,K2,I,V2,d,e. L1 ⊢ ▶* [d, e] K2. ⓑ{I} V2 → 0 < d →
-                           ∃∃K1,V1. K1 ⊢ ▶* [d - 1, e] K2 &
-                                    K1 ⊢ V1 ▶* [d - 1, e] V2 &
-                                    L1 = K1. ⓑ{I} V1.
-/2 width=3/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma ltpss_sn_tps2: ∀L1,L2,I,V1,V2,e.
-                     L1 ⊢ ▶* [0, e] L2 → L1 ⊢ V1 ▶ [0, e] V2 →
-                     L1. ⓑ{I} V1 ⊢ ▶* [0, e + 1] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_sn_tps1: ∀L1,L2,I,V1,V2,d,e.
-                     L1 ⊢ ▶* [d, e] L2 → L1 ⊢ V1 ▶ [d, e] V2 →
-                     L1. ⓑ{I} V1 ⊢ ▶* [d + 1, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_sn_tpss2_lt: ∀L1,L2,I,V1,V2,e.
-                         L1 ⊢ ▶* [0, e - 1] L2 → L1 ⊢ V1 ▶* [0, e - 1] V2 →
-                         0 < e → L1. ⓑ{I} V1 ⊢ ▶* [0, e] L2. ⓑ{I} V2.
-#L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #He
->(plus_minus_m_m e 1) /2 width=1/
-qed.
-
-lemma ltpss_sn_tpss1_lt: ∀L1,L2,I,V1,V2,d,e.
-                         L1 ⊢ ▶* [d - 1, e] L2 → L1 ⊢ V1 ▶* [d - 1, e] V2 →
-                         0 < d → L1. ⓑ{I} V1 ⊢ ▶* [d, e] L2. ⓑ{I} V2.
-#L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #Hd
->(plus_minus_m_m d 1) /2 width=1/
-qed.
-
-lemma ltpss_sn_tps2_lt: ∀L1,L2,I,V1,V2,e.
-                        L1 ⊢ ▶* [0, e - 1] L2 → L1 ⊢ V1 ▶ [0, e - 1] V2 →
-                        0 < e → L1. ⓑ{I} V1 ⊢ ▶* [0, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_sn_tps1_lt: ∀L1,L2,I,V1,V2,d,e.
-                        L1 ⊢ ▶* [d - 1, e] L2 → L1 ⊢ V1 ▶ [d - 1, e] V2 →
-                        0 < d → L1. ⓑ{I} V1 ⊢ ▶* [d, e] L2. ⓑ{I} V2.
-/3 width=1/ qed.
-
-lemma ltpss_sn_refl: ∀L,d,e. L ⊢ ▶* [d, e] L.
-#L elim L -L //
-#L #I #V #IHL * /2 width=1/ * /2 width=1/
-qed.
-
-lemma ltpss_sn_weak: ∀L1,L2,d1,e1. L1 ⊢ ▶* [d1, e1] L2 →
-                     ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 → L1 ⊢ ▶* [d2, e2] L2.
-#L1 #L2 #d1 #e1 #H elim H -L1 -L2 -d1 -e1 //
-[ #L1 #L2 #I #V1 #V2 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd2 #Hde2
-  lapply (le_n_O_to_eq … Hd2) #H destruct normalize in Hde2;
-  lapply (lt_to_le_to_lt 0 … Hde2) // #He2
-  lapply (le_plus_to_minus_r … Hde2) -Hde2 /3 width=5/
-| #L1 #L2 #I #V1 #V2 #d1 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd21 #Hde12
-  >plus_plus_comm_23 in Hde12; #Hde12
-  elim (le_to_or_lt_eq 0 d2 ?) // #H destruct
-  [ lapply (le_plus_to_minus_r … Hde12) -Hde12 <plus_minus // #Hde12
-    lapply (le_plus_to_minus … Hd21) -Hd21 #Hd21 /3 width=5/
-  | -Hd21 normalize in Hde12;
-    lapply (lt_to_le_to_lt 0 … Hde12) // #He2
-    lapply (le_plus_to_minus_r … Hde12) -Hde12
-    /3 width=5 by ltpss_sn_tpss2_lt, tpss_weak/ (**) (* /3 width=5/ used to work *)
-  ]
-]
-qed.
-
-lemma ltpss_sn_weak_full: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [0, |L1|] L2.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
-// /3 width=2/ /3 width=3/
-qed.
-
-fact ltpss_sn_append_le_aux: ∀K1,K2,d,x. K1 ⊢ ▶* [d, x] K2 → x = |K1| - d →
-                             ∀L1,L2,e. L1 ⊢ ▶* [0, e] L2 → d ≤ |K1| →
-                             L1 @@ K1 ⊢ ▶* [d, x + e] L2 @@ K2.
-#K1 #K2 #d #x #H elim H -K1 -K2 -d -x
-[ #d #x #H1 #L1 #L2 #e #HL12 #H2 destruct
-  lapply (le_n_O_to_eq … H2) -H2 #H destruct //
-| #K #I #V <minus_n_O normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #x #_ #HV12 <minus_n_O #IHK12 <minus_n_O #H #L1 #L2 #e #HL12 #_
-  lapply (injective_plus_l … H) -H #H destruct >plus_plus_comm_23
-  /4 width=5 by ltpss_sn_tpss2, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
-| #K1 #K2 #I #V1 #V2 #d #x #_ #HV12 #IHK12 normalize <minus_le_minus_minus_comm // <minus_plus_m_m #H1 #L1 #L2 #e #HL12 #H2 destruct
-  lapply (le_plus_to_le_r … H2) -H2 #Hd
-  /4 width=5 by ltpss_sn_tpss1, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
-]
-qed-.
-
-lemma ltpss_sn_append_le: ∀K1,K2,d. K1 ⊢ ▶* [d, |K1| - d] K2 →
-                          ∀L1,L2,e. L1 ⊢ ▶* [0, e] L2 → d ≤ |K1| →
-                          L1 @@ K1 ⊢ ▶* [d, |K1| - d + e] L2 @@ K2.
-/2 width=1 by ltpss_sn_append_le_aux/ qed.
-
-lemma ltpss_sn_append_ge: ∀K1,K2,d,e. K1 ⊢ ▶* [d, e] K2 →
-                          ∀L1,L2. L1 ⊢ ▶* [d - |K1|, e] L2 → |K1| ≤ d →
-                          L1 @@ K1 ⊢ ▶* [d, e] L2 @@ K2.
-#K1 #K2 #d #e #H elim H -K1 -K2 -d -e
-[ #d #e #L1 #L2 <minus_n_O //
-| #K #I #V #L1 #L2 #_ #H
-  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #e #_ #_ #_ #L1 #L2 #_ #H
-  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
-| #K1 #K2 #I #V1 #V2 #d #e #_ #HV12 #IHK12 #L1 #L2
-  normalize <minus_le_minus_minus_comm // <minus_plus_m_m #HL12 #H
-  lapply (le_plus_to_le_r … H) -H /3 width=1/
-]
-qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma ltpss_sn_fwd_length: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → |L1| = |L2|.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
-normalize //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_alt.etc
deleted file mode 100644 (file)
index d2cdba0..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-notation "hvbox( T1 break ⊢ ▶ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStarSnAlt $T1 $d $e $T2 }.
-
-include "basic_2/unfold/ltpss_dx_ltpss_dx.ma".
-include "basic_2/unfold/ltpss_sn_ltpss_sn.ma".
-
-(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* alternative definition of ltpss_sn *)
-definition ltpssa: nat → nat → relation lenv ≝
-                   λd,e. TC … (ltpss_dx d e).
-
-interpretation "parallel unfold (local environment, sn variant) alternative"
-   'PSubstStarSnAlt L1 d e L2 = (ltpssa d e L1 L2).
-
-(* Basic eliminators ********************************************************)
-
-lemma ltpssa_ind: ∀d,e,L1. ∀R:predicate lenv. R L1 →
-                  (∀L,L2. L1 ⊢ ▶▶* [d, e] L → L ▶* [d, e] L2 → R L → R L2) →
-                  ∀L2. L1 ⊢ ▶▶* [d, e] L2 → R L2.
-#d #e #L1 #R #HL1 #IHL1 #L2 #HL12 @(TC_star_ind … HL1 IHL1 … HL12) //
-qed-.
-
-lemma ltpssa_ind_dx: ∀d,e,L2. ∀R:predicate lenv. R L2 →
-                     (∀L1,L. L1 ▶* [d, e] L → L ⊢ ▶▶* [d, e] L2 → R L → R L1) →
-                     ∀L1. L1 ⊢ ▶▶* [d, e] L2 → R L1.
-#d #e #L2 #R #HL2 #IHL2 #L1 #HL12 @(TC_star_ind_dx … HL2 IHL2 … HL12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma ltpssa_refl: ∀L,d,e. L ⊢ ▶▶* [d, e] L.
-/2 width=1/ qed.
-
-lemma ltpssa_tpss2: ∀I,L1,V1,V2,e. L1 ⊢ V1 ▶*[0, e] V2 →
-                    ∀L2. L1 ⊢ ▶▶* [0, e] L2 →
-                    L1.ⓑ{I}V1 ⊢ ▶▶* [O, e + 1] L2.ⓑ{I}V2.
-#I #L1 #V1 #V2 #e #HV12 #L2 #H @(ltpssa_ind … H) -L2
-[ /3 width=1/ | /3 width=5/ ]
-qed.
-
-lemma ltpssa_tpss1: ∀I,L1,V1,V2,d,e. L1 ⊢ V1 ▶*[d, e] V2 →
-                    ∀L2. L1 ⊢ ▶▶* [d, e] L2 →
-                    L1.ⓑ{I}V1 ⊢ ▶▶* [d + 1, e] L2.ⓑ{I}V2.
-#I #L1 #V1 #V2 #d #e #HV12 #L2 #H @(ltpssa_ind … H) -L2
-[ /3 width=1/ | /3 width=5/ ]
-qed.
-
-lemma ltpss_sn_ltpssa: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → L1 ⊢ ▶▶* [d, e] L2.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e // /2 width=1/
-qed.
-
-lemma ltpss_sn_dx_trans_eq: ∀L1,L,d,e. L1 ⊢ ▶* [d, e] L →
-                            ∀L2. L ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
-#L1 #L #d #e #H elim H -L1 -L -d -e
-[ #d #e #X #H
-  lapply (ltpss_dx_inv_atom1 … H) -H #H destruct //
-| #L #I #V #X #H
-  lapply (ltpss_dx_inv_refl_O2 … H) -H #H destruct //
-| #L1 #L #I #V1 #V #e #_ #HV1 #IHL1 #X #H
-  elim (ltpss_dx_inv_tpss21 … H ?) -H // <minus_plus_m_m
-  #L2 #V2 #HL2 #HV2 #H destruct
-  lapply (IHL1 … HL2) -L #HL12
-  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL12) -HV2 #HV2
-  lapply (tpss_trans_eq … HV1 HV2) -V /2 width=1/
-| #L1 #L #I #V1 #V #d #e #_ #HV1 #IHL1 #X #H
-  elim (ltpss_dx_inv_tpss11 … H ?) -H // <minus_plus_m_m
-  #L2 #V2 #HL2 #HV2 #H destruct
-  lapply (IHL1 … HL2) -L #HL12
-  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL12) -HV2 #HV2
-  lapply (tpss_trans_eq … HV1 HV2) -V /2 width=1/
-]
-qed.
-
-lemma ltpss_dx_sn_trans_eq: ∀L1,L,d,e. L1 ▶* [d, e] L →
-                            ∀L2. L ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
-/3 width=3/ qed.
-
-lemma ltpssa_strip: ∀L0,L1,d1,e1. L0 ⊢ ▶▶* [d1, e1] L1 →
-                    ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
-                    ∃∃L. L1 ▶* [d2, e2] L & L2 ⊢ ▶▶* [d1, e1] L.
-/3 width=3/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma ltpssa_ltpss_sn: ∀L1,L2,d,e. L1 ⊢ ▶▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
-#L1 #L2 #d #e #H @(ltpssa_ind … H) -L2 // /2 width=3/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma ltpss_sn_strip: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                      ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
-                      ∃∃L. L1 ▶* [d2, e2] L & L2 ⊢ ▶* [d1, e1] L.
-#L0 #L1 #d1 #e1 #H #L2 #d2 #e2 #HL02
-lapply (ltpss_sn_ltpssa … H) -H #HL01
-elim (ltpssa_strip … HL01 … HL02) -L0
-/3 width=3 by ltpssa_ltpss_sn, ex2_intro/
-qed.
-
-(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
-lemma ltpss_sn_tpss_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                          ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                          ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T &
-                               L0 ⊢ U2 ▶* [d1, e1] T.
-#L0 #T2 #U2 #d2 #e2 #HTU2 #L1 #d1 #e1 #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L1 /2 width=3/ -HTU2
-#L #L1 #H #HL1 * #T #HT2 #HU2T
-lapply (ltpssa_ltpss_sn … H) -H #HL0
-lapply (ltpss_sn_dx_trans_eq … HL0 … HL1) -HL0 #HL01
-elim (ltpss_dx_tpss_conf … HT2 … HL1) -HT2 -HL1 #T0 #HT20 #HT0
-lapply (ltpss_sn_tpss_trans_eq … HT0 … HL01) -HT0 -HL01 #HT0
-lapply (tpss_trans_eq … HU2T HT0) -T /2 width=3/
-qed.
-
-(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
-lemma ltpss_sn_tpss_trans_down: ∀L0,L1,T2,U2,d1,e1,d2,e2. d2 + e2 ≤ d1 →
-                                L1 ⊢ ▶* [d1, e1] L0 → L0 ⊢ T2 ▶* [d2, e2] U2 →
-                                ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T & L1 ⊢ T ▶* [d1, e1] U2.
-#L0 #L1 #T2 #U2 #d1 #e1 #d2 #e2 #Hde2d1 #H #HTU2
-lapply (ltpss_sn_ltpssa … H) -H #HL10
-@(ltpssa_ind_dx … HL10) -L1 /2 width=3/ -HTU2
-#L1 #L #HL1 #_ * #T #HT2 #HTU2
-elim (ltpss_dx_tpss_trans_down … HL1 HT2) -HT2 // #T0 #HT20 #HT0 -Hde2d1
-lapply (tpss_trans_eq … HT0 HTU2) -T #HT0U2
-lapply (ltpss_dx_tpss_trans_eq … HT0U2 … HL1) -HT0U2 -HL1 /2 width=3/
-qed.
-
-(* Main properties **********************************************************)
-
-theorem ltpssa_conf: ∀L0,L1,d1,e1. L0 ⊢ ▶▶* [d1, e1] L1 →
-                     ∀L2,d2,e2. L0 ⊢ ▶▶* [d2, e2] L2 →
-                     ∃∃L. L1 ⊢ ▶▶* [d2, e2] L & L2 ⊢ ▶▶* [d1, e1] L.
-/3 width=3/ qed.
-
-(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
-theorem ltpss_sn_conf: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                       ∀L2,d2,e2. L0 ⊢ ▶* [d2, e2] L2 →
-                       ∃∃L. L1 ⊢ ▶* [d2, e2] L & L2 ⊢ ▶* [d1, e1] L.
-#L0 #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2
-lapply (ltpss_sn_ltpssa … H1) -H1 #HL01
-lapply (ltpss_sn_ltpssa … H2) -H2 #HL02
-elim (ltpssa_conf … HL01 … HL02) -L0
-/3 width=3 by ltpssa_ltpss_sn, ex2_intro/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ldrop.etc
deleted file mode 100644 (file)
index 70167df..0000000
+++ /dev/null
@@ -1,231 +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/fsup.ma".
-include "basic_2/unfold/tpss_lift.ma".
-include "basic_2/unfold/ltpss_sn.ma".
-
-(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properies on local environment slicing ***********************************)
-
-lemma ltpss_sn_ldrop_conf_ge: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                              d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
-| //
-| normalize #K0 #K1 #I #V0 #V1 #e1 #_ #_ #IHK01 #L2 #e2 #H #He12
-  elim (le_inv_plus_l … He12) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
-| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
-]
-qed.
-
-lemma ltpss_sn_ldrop_trans_ge: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                               d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
-| //
-| normalize #K1 #K0 #I #V1 #V0 #e1 #_ #_ #IHK10 #L2 #e2 #H #He12
-  elim (le_inv_plus_l … He12) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK10 … HK0L2 ?) -K0 /2 width=1/
-| #K0 #K1 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  lapply (IHK10 … HK0L2 ?) -IHK10 -HK0L2 /2 width=1/
-]
-qed.
-
-lemma ltpss_sn_ldrop_conf_be: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
-                              ∃∃L. L2 ⊢ ▶* [0, d1 + e1 - e2] L & ⇩[0, e2] L1 ≡ L.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
-  lapply (le_n_O_to_eq … He2) -He2 #H destruct
-  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
-| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #_ #He21
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK01 -He21 destruct <minus_n_O /3 width=3/
-  | -HK01 -HV01 <minus_le_minus_minus_comm //
-    elim (IHK01 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
-  ]
-| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2 #He2de1
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  <minus_le_minus_minus_comm //
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  elim (IHK01 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
-]
-qed.
-
-lemma ltpss_sn_ldrop_trans_be: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
-                               ∃∃L. L ⊢ ▶* [0, d1 + e1 - e2] L2 & ⇩[0, e2] L1 ≡ L.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
-  lapply (le_n_O_to_eq … He2) -He2 #H destruct
-  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
-| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #_ #He21
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK10 -He21 destruct <minus_n_O /3 width=3/
-  | -HK10 -HV10 <minus_le_minus_minus_comm //
-    elim (IHK10 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
-  ]
-| #K1 #K0 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2 #He2de1
-  elim (le_inv_plus_l … Hd1e2) #_ #He2
-  <minus_le_minus_minus_comm //
-  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
-  elim (IHK10 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
-]
-qed.
-
-lemma ltpss_sn_ldrop_conf_le: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                              ∃∃L. L2 ⊢ ▶* [d1 - e2, e1] L & ⇩[0, e2] L1 ≡ L.
-#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #_ #L2 #e2 #H #He2
-  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
-  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
-| #K0 #K1 #I #V0 #V1 #d1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #He2d1
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK01 -He2d1 destruct <minus_n_O /3 width=3/
-  | -HK01 -HV01 <minus_le_minus_minus_comm //
-    elim (IHK01 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
-  ]
-]
-qed.
-
-lemma ltpss_sn_ldrop_trans_le: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
-                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                               ∃∃L. L ⊢ ▶* [d1 - e2, e1] L2 & ⇩[0, e2] L1 ≡ L.
-#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
-[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #_ #L2 #e2 #H #He2
-  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
-  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
-| #K1 #K0 #I #V1 #V0 #d1 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #He2d1
-  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
-  [ -IHK10 -He2d1 destruct <minus_n_O /3 width=3/
-  | -HK10 -HV10 <minus_le_minus_minus_comm //
-    elim (IHK10 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
-  ]
-]
-qed.
-
-lemma ldrop_ltpss_sn_trans_le: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 → d1 ≤ d2 →
-                               ∃∃L2. L1 ⊢ ▶* [d2 + e1, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_
-  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
-| /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #Hd
-  elim (IHLK1 … HK12 Hd) -K1 -Hd /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd12
-  elim (le_inv_plus_l … Hd12) -Hd12 #Hd12 #Hd2
-  elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-  elim (IHLK1 … HK12 … Hd12) -IHLK1 -HK12 <le_plus_minus_comm // #L2 #HL12 #HLK2
-  elim (lift_total W2 d1 e1) #V2 #HWV2
-  lapply (tpss_lift_ge … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 // -Hd12
-  <le_plus_minus_comm // /4 width=5/
-]
-qed-.
-
-lemma ldrop_ltpss_sn_trans_be: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 →
-                               d2 ≤ d1 → d1 ≤ d2 + e2 →
-                               ∃∃L2. L1 ⊢ ▶* [d2, e1 + e2] L2 &
-                                     ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_ #_
-  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H #_
-  lapply (le_n_O_to_eq … H) -H #H destruct /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H1 #H2
-  elim (IHLK1 … HK12 H1 H2) -K1 -H2
-  lapply (le_n_O_to_eq … H1) -H1 #H destruct /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21 #Hd12
-  elim (eq_or_gt d2) #Hd2 [ -Hd21 elim (eq_or_gt e2) #He2 ] destruct
-  [ lapply (le_n_O_to_eq … Hd12) -Hd12 <plus_n_Sm #H destruct
-  | elim (ltpss_sn_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 // /2 width=1/ >plus_minus_commutative // #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_be … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 // /2 width=1/
-    >plus_minus // >commutative_plus /4 width=5/
-  | elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // ] /2 width=1/ #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_be … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 [ >plus_minus // ] /2 width=1/
-    >commutative_plus /3 width=5/
-  ]
-]
-qed-.
-
-lemma ldrop_ltpss_sn_trans_ge: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
-                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 → d2 + e2 ≤ d1 →
-                               ∃∃L2. L1 ⊢ ▶* [d2, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
-#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
-[ #d1 #e1 #K2 #d2 #e2 #H #_
-  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
-| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H
-  elim (plus_le_0 … H) -H #H1 #H2 destruct /2 width=3/
-| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H
-  elim (IHLK1 … HK12 H) -K1
-  elim (plus_le_0 … H) -H #H1 #H2 destruct #L2 #HL12
-  >(ltpss_sn_inv_refl_O2 … HL12) -L1 /3 width=5/
-| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21
-  elim (eq_or_gt d2) #Hd2 [ elim (eq_or_gt e2) #He2 ] destruct
-  [ -IHLK1 -Hd21 <(ltpss_sn_inv_refl_O2 … H) -X /3 width=5/
-  | elim (ltpss_sn_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 /2 width=1/ #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_le … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 /2 width=1/ /3 width=5/
-  | elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // /2 width=1/ ] #L2 #HL12 #HLK2
-    elim (lift_total W2 d1 e1) #V2 #HWV2
-    lapply (tpss_lift_le … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 [ >plus_minus // /2 width=1/ ] /3 width=5/
-  ]
-]
-qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma fsup_tpss_trans_full: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶*[0,|L2|] U2 →
-                            ∃∃L,U1. L1 ⊢ ▶*[0,|L1|] L & L ⊢ T1 ▶*[0,|L|] U1 & ⦃L, U1⦄ ⊃ ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
-#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
-elim (lift_total T d e) #U #HTU
-lapply (ltpss_sn_fwd_length … HK1) #H >H in HK1; -H #HK1
-elim (le_or_ge d (|K|)) #Hd
-[ elim (ldrop_ltpss_sn_trans_be … HLK1 … HK1 … Hd) // -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (tpss_lift_be … HT1 … Hd HL2K HTU1 … HTU) // -HT1 -HTU1 #HU1
-| elim (ldrop_ltpss_sn_trans_ge … HLK1 … HK1 Hd) -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (tpss_lift_le … HT1 … Hd HL2K HTU1 … HTU) -HT1 -HTU1 #HU1
-]
-lapply (ltpss_sn_weak_full … HL12) -HL12 #HL12
-lapply (tpss_weak_full … HU1) -HU1 #HU1
-@(ex3_2_intro … L2 U) // /2 width=7/ (**) (* explicit constructor: auto /3 width=14/ too slow *)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_ltpss_sn.etc
deleted file mode 100644 (file)
index 67c287e..0000000
+++ /dev/null
@@ -1,81 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/ltpss_sn_tpss.ma".
-
-(* PARTIAL UNFOLD ON LOCAL ENVIRONMENTS *************************************)
-
-(* Advanced properties ******************************************************)
-
-lemma ltpss_sn_tpss_trans_eq: ∀L1,T2,U2,d,e. L1 ⊢ T2 ▶* [d, e] U2 →
-                              ∀L0. L0 ⊢ ▶* [d, e] L1 → L0 ⊢ T2 ▶* [d, e] U2.
-#L1 #T2 @(f2_ind … fw … L1 T2) -L1 -T2 #n #IH #L1 *
-[ #I #Hn #W2 #d #e #H #L0 #HL01 destruct
-  elim (tpss_inv_atom1 … H) -H // *
-  #K1 #V1 #V2 #i #Hdi #Hide #HLK1 #HV12 #HVW2 #H destruct
-  lapply (ldrop_fwd_lw … HLK1) #H1 normalize in H1;
-  elim (ltpss_sn_ldrop_trans_be … HL01 … HLK1 ? ?) -HL01 -HLK1 // /2 width=2/ #X #H #HLK0
-  elim (ltpss_sn_inv_tpss22 … H ?) -H /2 width=1/ #K0 #V0 #HK01 #HV01 #H destruct
-  lapply (IH … HV12 … HK01) -IH -HV12 -HK01 [ normalize /2 width=1/ ] #HV12
-  lapply (tpss_trans_eq … HV01 HV12) -V1 /2 width=6/
-| * [ #a ] #I #V2 #T2 #Hn #X #d #e #H #L0 #HL0 destruct
-  [ elim (tpss_inv_bind1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
-    lapply (tpss_lsubr_trans … HTU2 (L1. ⓑ{I} V2) ?) -HTU2 /2 width=1/ #HTU2
-    lapply (IH … HVW2 … HL0) -HVW2 [ /2 width=2/ ] #HVW2
-    lapply (IH … HTU2 (L0. ⓑ{I} V2) ?) -IH -HTU2 // /2 width=2/ -HL0 #HTU2
-    lapply (tpss_lsubr_trans … HTU2 (L0. ⓑ{I} W2) ?) -HTU2 /2 width=1/
-  | elim (tpss_inv_flat1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
-    lapply (IH … HVW2 … HL0) -HVW2 //
-    lapply (IH … HTU2 … HL0) -IH -HTU2 // -HL0 /2 width=1/
-]
-qed.
-
-lemma ltpss_sn_tps_trans_eq: ∀L0,L1,T2,U2,d,e. L0 ⊢ ▶* [d, e] L1 →
-                             L1 ⊢ T2 ▶ [d, e] U2 → L0 ⊢ T2 ▶* [d, e] U2.
-/3 width=3/ qed.
-
-(* Main properties **********************************************************)
-
-theorem ltpss_sn_trans_eq: ∀L1,L,d,e. L1 ⊢ ▶* [d, e] L →
-                           ∀L2. L ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
-#L1 #L #d #e #H elim H -L1 -L -d -e //
-[ #L1 #L #I #V1 #V #e #HL1 #HV1 #IHL1 #X #H
-  elim (ltpss_sn_inv_tpss21 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
-  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL1) -HV2 -HL1 #HV2
-  lapply (tpss_trans_eq … HV1 … HV2) -V /3 width=1/
-| #L1 #L #I #V1 #V #d #e #HL1 #HV1 #IHL1 #X #H
-  elim (ltpss_sn_inv_tpss11 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
-  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL1) -HV2 -HL1 #HV2
-  lapply (tpss_trans_eq … HV1 … HV2) -V /3 width=1/
-]
-qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma tps_fwd_shift1: ∀L1,L,T1,T,d,e. L ⊢ L1 @@ T1 ▶ [d, e] T →
-                      ∃∃L2,T2. L @@ L1 ⊢ ▶* [d + |L1|, e] L @@ L2 &
-                               L @@ L2 ⊢ T1 ▶ [d + |L1|, e] T2 &
-                               T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1
-[ #L #T1 #T #d #e #HT1
-  @ex3_2_intro [3: // |5: // |4: normalize /2 width=1/ |1,2: skip ] (**) (* /2 width=4/ does not work *)
-| #I #L1 #V1 #IH #L #T1 #T #d #e >shift_append_assoc #H
-  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
-  <append_assoc >append_length <associative_plus
-  lapply (ltpss_sn_trans_eq (L.ⓑ{I}V1@@L1) … HL12) -HL12 /3 width=1/ #HL12
-  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tps.etc
deleted file mode 100644 (file)
index 1de83c6..0000000
+++ /dev/null
@@ -1,47 +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/unfold/ltpss_sn_ldrop.ma".
-
-(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properties concerning partial substitution on terms **********************)
-
-lemma ltpss_sn_tps_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                            ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
-                            L1 ⊢ T2 ▶ [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ //
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01 #Hde1d2
-  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
-  lapply (ltpss_sn_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /2 width=4/
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01 #Hde1d2
-  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_sn_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
-| /3 width=4/
-]
-qed.
-
-lemma ltpss_sn_tps_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                             ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
-                             L1 ⊢ T2 ▶ [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ //
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10 #Hde1d2
-  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
-  lapply (ltpss_sn_ldrop_trans_ge … HL10 … HLK0 ?) -L0 // /2 width=4/
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10 #Hde1d2
-  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_sn_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
-| /3 width=4/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ltpss_sn_tpss.etc
deleted file mode 100644 (file)
index 007613c..0000000
+++ /dev/null
@@ -1,101 +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/unfold/ltpss_sn_tps.ma".
-
-(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
-
-(* Properties concerning partial unfold on terms ****************************)
-
-lemma ltpss_sn_tpss_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                             ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
-                             L1 ⊢ T2 ▶* [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU
-lapply (ltpss_sn_tps_conf_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
-qed.
-
-lemma ltpss_sn_tps_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                         ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
-                         ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
-                              L0 ⊢ U2 ▶* [d1, e1] T.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ /2 width=3/
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01
-  elim (lt_or_ge i2 d1) #Hi2d1
-  [ elim (ltpss_sn_ldrop_conf_le … HL01 … HLK0 ?) /2 width=2/ #X #H #HLK1
-    elim (ltpss_sn_inv_tpss11 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #HLK0
-    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-    lapply (tpss_lift_ge … HV01 … HLK0 HVW0 … HVW1) -V0 -HLK0 // >minus_plus <plus_minus_m_m // /3 width=4/
-  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
-    [ elim (ltpss_sn_ldrop_conf_be … HL01 … HLK0 ? ?) -HL01 // /2 width=2/ #X #H #HLK1
-      elim (ltpss_sn_inv_tpss21 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #HLK0
-      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-      lapply (tpss_lift_ge … HV01 … HLK0 HVW0 … HVW1) -V0 -HLK0 // normalize #HW01
-      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /2 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
-    | lapply (ltpss_sn_ldrop_conf_ge … HL01 … HLK0 ?) -HL01 -HLK0 // /3 width=4/
-    ]
-  ]
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
-  elim (IHVW2 … HL01) -IHVW2 #V #HV2 #HVW2
-  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL01 #T #HT2 #H
-  lapply (tpss_lsubr_trans … H (L0.ⓑ{I}V) ?) -H /2 width=1/ /3 width=5/
-| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
-  elim (IHVW2 … HL01) -IHVW2
-  elim (IHTU2 … HL01) -IHTU2 -HL01 /3 width=5/
-]
-qed.
-
-lemma ltpss_sn_tpss_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
-                              ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
-                              L1 ⊢ T2 ▶* [d2, e2] U2.
-#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU
-lapply (ltpss_sn_tps_trans_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
-qed.
-
-lemma ltpss_sn_tps_trans: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
-                          ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
-                          ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
-                               L1 ⊢ T ▶* [d1, e1] U2.
-#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
-[ /2 width=3/
-| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10
-  elim (lt_or_ge i2 d1) #Hi2d1
-  [ elim (ltpss_sn_ldrop_trans_le … HL10 … HLK0 ?) -L0 /2 width=2/ #X #H #HLK1
-    elim (ltpss_sn_inv_tpss12 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK1) #H
-    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-    lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // >minus_plus <plus_minus_m_m /2 width=1/ /3 width=4/
-  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
-    [ elim (ltpss_sn_ldrop_trans_be … HL10 … HLK0 ? ?) -L0 // /2 width=2/ #X #H #HLK1
-      elim (ltpss_sn_inv_tpss22 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK1) #H
-      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
-      lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // normalize #HW01
-      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /3 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
-    | lapply (ltpss_sn_ldrop_trans_ge … HL10 … HLK0 ?) -HL10 -HLK0 // /3 width=4/
-    ]
-  ]
-| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
-  elim (IHVW2 … HL10) -IHVW2 #V #HV2 #HVW2
-  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL10 #T #HT2 #H
-  lapply (tpss_lsubr_trans … H (L1.ⓑ{I}W2) ?) -H /2 width=1/ /3 width=5/
-| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
-  elim (IHVW2 … HL10) -IHVW2
-  elim (IHTU2 … HL10) -IHTU2 -HL10 /3 width=5/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_dx.etc
deleted file mode 100644 (file)
index ca55239..0000000
+++ /dev/null
@@ -1,87 +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/computation/dxprs_ltpss_dx.ma".
-include "basic_2/equivalence/cpcs_ltpss_dx.ma".
-include "basic_2/dynamic/snv_lift.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties about dx parallel unfold **************************************)
-
-lemma snv_ltpss_dx_tpss_conf: ∀h,g,L1,T1. ⦃h, L1⦄ ⊢ T1 ¡[g] →
-                              ∀L2,d,e. L1 ▶* [d, e] L2 →
-                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 ¡[g].
-#h #g #L1 #T1 #H elim H -L1 -T1
-[ #L1 #k #L2 #d #e #_ #X #H
-   >(tpss_inv_sort1 … H) -X //
-| #I #L1 #K1 #V1 #i #HLK1 #HV1 #IHV1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi [ | elim (lt_or_ge i (d + e)) #Hide ]
-    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 …) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_dx_inv_tpss11 … H …) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-      lapply (IHV1 … HK12 … HV12) -IHV1 -HK12 -HV12 /2 width=5/
-    | elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 …) -L1 // /2 width=2/ #X #H #HLK2
-      elim (ltpss_dx_inv_tpss21 … H …) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-      lapply (IHV1 … HK12 … HV12) -IHV1 -HK12 -HV12 /2 width=5/
-    | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=5/
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 …) -L1 // /2 width=2/ #X #H1 #H2
-    elim (ltpss_dx_inv_tpss21 … H1 …) -H1 /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … H2 … HLK2) -H2 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
-    lapply (IHV1 … HK12 … HV1W2) -IHV1 -HK12 -HV1W2 /2 width=7/
-  ]
-| #a #I #L1 #V1 #T1 #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (IHV1 … HL12 … HV12) -IHV1 #HV2
-  lapply (IHT1 … HT12) -IHT1 -HT12 /2 width=1/
-| #a #L1 #V1 #W1 #W0 #T1 #U1 #l #_ #_ #HVW1 #HW10 #HTU1 #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (IHV1 … HL12 … HV12) -IHV1 #HV2
-  lapply (IHT1 … HT12) -IHT1 /2 width=1/ #HT2
-  elim (ssta_ltpss_dx_tpss_conf … HVW1 … HL12 … HV12) -V1 #W2 #HVW2 #HW12
-  elim (dxprs_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -T1 #X #HTU2 #H
-  elim (tpss_inv_bind1 … H) -H #W #U2 #HW0 #_ #H -U1 destruct
-  elim (cprs_ltpss_dx_tpss2_conf … HW10 … HL12 … HW12 … HW0) -L1 -W1 -W0 #W0 #HW20 #HW0
-  lapply (dxprs_strap1 … (ⓛ{a}W0.U2) HTU2 ?) -HTU2 /3 width=3/ -HW0 /2 width=8/
-| #L1 #W1 #T1 #U1 #l #_ #_ #HTU1 #HUW1 #IHW1 #IHT1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
-  lapply (IHW1 … HL12 … HW12) -IHW1 #HW2
-  lapply (IHT1 … HL12 … HT12) -IHT1 #HT2
-  elim (ssta_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -T1 #U2 #HTU2 #HU12
-  lapply (cpcs_ltpss_dx_tpss2_conf … HL12 … HUW1 … HU12 … HW12) -L1 -W1 -U1 /2 width=4/
-]
-qed-.
-
-lemma snv_ltpss_dx_conf: ∀h,g,L1,T. ⦃h, L1⦄ ⊢ T ¡[g] →
-                         ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T ¡[g].
-#h #g #L1 #T #HT #L2 #d #e #HL12
-@(snv_ltpss_dx_tpss_conf … HT … HL12) //
-qed-.
-
-lemma snv_tpss_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
-                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
-#h #g #L #T1 #HT1 #T2 #d #e #HT12
-@(snv_ltpss_dx_tpss_conf … HT1 … HT12) //
-qed-.
-
-lemma snv_tps_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
-                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
-#h #g #L #T1 #HT1 #T2 #d #e #HT12
-@(snv_tpss_conf … HT1 T2) /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/snv_ltpss_sn.etc
deleted file mode 100644 (file)
index 3c80702..0000000
+++ /dev/null
@@ -1,28 +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/dynamic/snv_ltpss_dx.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties about sn parallel unfold **************************************)
-
-lemma snv_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                         ∀T. ⦃h, L1⦄ ⊢ T ¡[g] → ⦃h, L2⦄ ⊢ T ¡[g].
-#h #g #L1 #L2 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 //
-#L #L2 #_ #HL2 #IHL1 #T1 #HT1
-lapply (IHL1 … HT1) -IHL1 -HT1 #HT1
-lapply (snv_ltpss_dx_conf … HT1 … HL2) -HT1 -HL2 //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_dx.etc
deleted file mode 100644 (file)
index 72eff78..0000000
+++ /dev/null
@@ -1,125 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/ltpss_dx_tpss.ma".
-include "basic_2/static/ssta_lift.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Properties about dx parallel unfold **************************************)
-
-(* Note: apparently this was missing in basic_1 *)
-lemma ssta_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                               ∀L2,d,e. L1 ▶* [d, e] L2 →
-                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
-                                     L2 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
-[ #L1 #k1 #l1 #Hkl1 #L2 #d #e #_ #T2 #H
-  >(tpss_inv_sort1 … H) -H /3 width=3/
-| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HVW1 ]
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi [ -HVW1 | ]
-    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-      elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
-      lapply (ldrop_fwd_ldrop2 … HLK2) #H
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1
-      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
-    | elim (lt_or_ge i (d + e)) #Hide [ -HVW1 | -Hdi -IHVW1 ]
-      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-        elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
-        lapply (ldrop_fwd_ldrop2 … HLK2) #H
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1 >minus_plus #H
-        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
-      | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
-    elim (IHVW1 … HK12 … HV1W2) -IHVW1 -HK12 -HV1W2 #V2 #HWV2 #HW1V2
-    elim (lift_total V2 0 (i+1)) #U2 #HVU2
-    lapply (ssta_lift … HWV2 … HLK2 … HWT2 … HVU2) -HWV2 -HWT2 #HTU2
-    lapply (tpss_lift_ge … HW1V2 … HLK2 … HWU1 … HVU2) // -HW1V2 -HLK2 -HWU1 -HVU2 >minus_plus #H
-    lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /2 width=3/
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
-    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-      elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
-      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1
-      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
-    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -Hdi ]
-      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-        elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
-        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1 >minus_plus #H
-        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
-      | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
-    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
-  ]
-| #a #I #L1 #V1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
-| #L1 #V1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=5/
-| #L1 #W1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=3/
-]
-qed.
-
-lemma ssta_ltpss_dx_tps_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                              ∀L2,d,e. L1 ▶* [d, e] L2 →
-                              ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                              ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
-                                    L2 ⊢ U1 ▶* [d, e] U2.
-/3 width=5/ qed.
-
-lemma ssta_ltpss_dx_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
-                          ∀L2,d,e. L1 ▶* [d, e] L2 →
-                          ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L2 ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma ssta_tpss_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                      ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma ssta_tps_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                     ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
-                     ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/ssta_ltpss_sn.etc
deleted file mode 100644 (file)
index d554f1f..0000000
+++ /dev/null
@@ -1,53 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/static/ssta_ltpss_dx.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Properties about sn parallel unfold **************************************)
-
-lemma ssta_ltpss_sn_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
-                          ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                          ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T #U1 #l #HTU1 #L2 #d #e #HL12
-lapply (ltpss_sn_ltpssa … HL12) -HL12 #HL12
-@(ltpssa_ind … HL12) -L2 [ /2 width=3/ ] -HTU1
-#L #L2 #HL1 #HL2 * #U #HTU #HU1
-lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
-elim (ssta_ltpss_dx_conf … HTU … HL2) -HTU #U2 #HTU2 #HU2
-lapply (ltpss_dx_tpss_trans_eq … HU2 … HL2) -HU2 -HL2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL1) -HU2 -HL1 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed.
-
-lemma ssta_ltpss_sn_tpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                               ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
-                                     L1 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U1 #l #HTU1 #L2 #d #e #HL12 #T2 #HT12
-elim (ssta_ltpss_sn_conf … HTU1 … HL12) -HTU1 #U #HT1U #HU1
-elim (ssta_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed.
-
-lemma ssta_ltpss_sn_tps_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                              ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                              ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                              ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
-                                    L1 ⊢ U1 ▶* [d, e] U2.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss.etc
deleted file mode 100644 (file)
index e0aa942..0000000
+++ /dev/null
@@ -1,55 +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/static/ssta_ltpss.ma".
-include "basic_2/unwind/sstas.ma".
-
-(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENTON TERMS ***********************)
-
-(* Properties about parallel unfold *****************************************)
-
-lemma sstas_ltpss_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                             ∀L2,d,e. L1 ▶* [d, e] L2 →
-                             ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                             ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
-                                   L2 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U1 #H @(sstas_ind_alt … H) -T1
-[ #T1 #HUT1 #L2 #d #e #HL12 #U2 #HU12
-  elim (ssta_ltpss_tpss_conf … HUT1 … HL12 … HU12) -HUT1 -HL12 /3 width=3/
-| #T0 #U0 #l0 #HTU0 #_ #IHU01 #L2 #d #e #HL12 #T #HT0
-  elim (ssta_ltpss_tpss_conf … HTU0 … HL12 … HT0) -HTU0 -HT0 #U #HTU #HU0
-  elim (IHU01 … HL12 … HU0) -IHU01 -HL12 -U0 /3 width=4/
-]
-qed.
-
-lemma sstas_ltpss_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                            ∀L2,d,e. L1 ▶* [d, e] L2 →
-                            ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/3 width=5/ qed.
-
-lemma sstas_ltpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
-                        ∀L2,d,e. L1 ▶* [d, e] L2 →
-                        ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sstas_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
-                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sstas_tps_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
-                      ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
-                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_dx.etc
deleted file mode 100644 (file)
index 2a8f8e7..0000000
+++ /dev/null
@@ -1,52 +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/static/ssta_ltpss_dx.ma".
-include "basic_2/unwind/sstas.ma".
-
-(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS *********************)
-
-(* Properties about dx parallel unfold **************************************)
-
-lemma sstas_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                                ∀L2,d,e. L1 ▶* [d, e] L2 →
-                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
-                                      L2 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U1 #H @(sstas_ind_dx … H) -T1 /2 width=3/
-#T0 #U0 #l0 #HTU0 #_ #IHU01 #L2 #d #e #HL12 #T #HT0
-elim (ssta_ltpss_dx_tpss_conf … HTU0 … HL12 … HT0) -HTU0 -HT0 #U #HTU #HU0
-elim (IHU01 … HL12 … HU0) -IHU01 -HL12 -U0 /3 width=4/
-qed.
-
-lemma sstas_ltpss_dx_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                               ∀L2,d,e. L1 ▶* [d, e] L2 →
-                               ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/3 width=7 by step, sstas_ltpss_dx_tpss_conf/ qed. (**) (* auto fails without trace *)
-
-lemma sstas_ltpss_dx_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
-                           ∀L2,d,e. L1 ▶* [d, e] L2 →
-                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sstas_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
-                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sstas_tps_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
-                      ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
-                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sstas_ltpss_sn.etc
deleted file mode 100644 (file)
index d066adb..0000000
+++ /dev/null
@@ -1,53 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/unwind/sstas_ltpss_dx.ma".
-
-(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ************************)
-
-(* Properties about sn parallel unfold *****************************************)
-
-lemma sstas_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                           ∀T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
-                           ∃∃U2. L1 ⊢ U1 ▶* [d, e] U2 & ⦃h, L2⦄ ⊢ T •*[g] U2.
-#h #g #L1 #L2 #d #e #H
-lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 /2 width=3/
-#L #L2 #HL1 #HL2 #IHL1 #T #U1 #H1
-lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
-lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
-elim (IHL1 … H1) -IHL1 -H1 #U #HU1 #HTU
-elim (sstas_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #H2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed.
-
-lemma sstas_ltpss_sn_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                                ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
-                                      L1 ⊢ U1 ▶* [d, e] U2.
-#h #g #L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
-elim (sstas_ltpss_sn_conf … HL12 … HTU1) -HTU1 #U #HU1 #HT1U
-elim (sstas_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
-lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
-lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
-qed.
-
-lemma sstas_ltpss_sn_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                               ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
-                               ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
-                                     L1 ⊢ U1 ▶* [d, e] U2.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/sta_ltpss.etc
deleted file mode 100644 (file)
index b0232f5..0000000
+++ /dev/null
@@ -1,122 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/ltpss_tpss.ma".
-include "basic_2/static/sta_lift.ma".
-
-(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties about parallel unfold *****************************************)
-
-lemma sta_ltpss_tpss_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 • U1 →
-                           ∀L2,d,e. L1 ▶* [d, e] L2 →
-                           ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
-                           ∃∃U2. ⦃h, L2⦄ ⊢ T2 • U2 & L2 ⊢ U1 ▶* [d, e] U2.
-#h #L1 #T1 #U #H elim H -L1 -T1 -U
-[ #L1 #k1 #L2 #d #e #_ #T2 #H
-  >(tpss_inv_sort1 … H) -H /2 width=3/
-| #L1 #K1 #V1 #W1 #U1 #i #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HVW1 ]
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi [ -HVW1 | ]
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-      elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
-      lapply (ldrop_fwd_ldrop2 … HLK2) #H
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1
-      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
-    | elim (lt_or_ge i (d + e)) #Hide [ -HVW1 | -Hdi -IHVW1 ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-        elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
-        lapply (ldrop_fwd_ldrop2 … HLK2) #H
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1 >minus_plus #H
-        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
-    elim (IHVW1 … HK12 … HV1W2) -IHVW1 -HK12 -HV1W2 #V2 #HWV2 #HW1V2
-    elim (lift_total V2 0 (i+1)) #U2 #HVU2
-    lapply (sta_lift … HWV2 … HLK2 … HWT2 … HVU2) -HWV2 -HWT2 #HTU2
-    lapply (tpss_lift_ge … HW1V2 … HLK2 … HWU1 … HVU2) // -HW1V2 -HLK2 -HWU1 -HVU2 >minus_plus #H
-    lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /2 width=3/
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-      elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
-      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1
-      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
-    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -Hdi ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-        elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
-        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1 >minus_plus #H
-        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
-  ]
-| #I #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
-| #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=5/
-| #L1 #W1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
-  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=3/
-]
-qed.
-
-lemma sta_ltpss_tps_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 • U1 →
-                          ∀L2,d,e. L1 ▶* [d, e] L2 →
-                          ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
-                          ∃∃U2. ⦃h, L2⦄ ⊢ T2 • U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/3 width=5/ qed.
-
-lemma sta_ltpss_conf: ∀h,L1,T,U1. ⦃h, L1⦄ ⊢ T • U1 →
-                      ∀L2,d,e. L1 ▶* [d, e] L2 →
-                      ∃∃U2. ⦃h, L2⦄ ⊢ T • U2 & L2 ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sta_tpss_conf: ∀h,L,T1,U1. ⦃h, L⦄ ⊢ T1 • U1 →
-                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                     ∃∃U2. ⦃h, L⦄ ⊢ T2 • U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
-
-lemma sta_tps_conf: ∀h,L,T1,U1. ⦃h, L⦄ ⊢ T1 • U1 →
-                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
-                    ∃∃U2. ⦃h, L⦄ ⊢ T2 • U2 & L ⊢ U1 ▶* [d, e] U2.
-/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr.etc
deleted file mode 100644 (file)
index de987d6..0000000
+++ /dev/null
@@ -1,242 +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 "hvbox( T1 ➡ break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PRed $T1 $T2 }.
-
-include "basic_2/substitution/tps.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
-
-(* Basic_1: includes: pr0_delta1 *)
-inductive tpr: relation term ≝
-| tpr_atom : ∀I. tpr (⓪{I}) (⓪{I})
-| tpr_flat : ∀I,V1,V2,T1,T2. tpr V1 V2 → tpr T1 T2 →
-             tpr (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-| tpr_beta : ∀a,V1,V2,W,T1,T2.
-             tpr V1 V2 → tpr T1 T2 → tpr (ⓐV1. ⓛ{a}W. T1) (ⓓ{a}V2. T2)
-| tpr_delta: ∀a,I,V1,V2,T1,T,T2.
-             tpr V1 V2 → tpr T1 T → ⋆. ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 →
-             tpr (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| tpr_theta: ∀a,V,V1,V2,W1,W2,T1,T2.
-             tpr V1 V2 → ⇧[0,1] V2 ≡ V → tpr W1 W2 → tpr T1 T2 →
-             tpr (ⓐV1. ⓓ{a}W1. T1) (ⓓ{a}W2. ⓐV. T2)
-| tpr_zeta : ∀V,T1,T,T2. tpr T1 T → ⇧[0, 1] T2 ≡ T → tpr (+ⓓV. T1) T2
-| tpr_tau  : ∀V,T1,T2. tpr T1 T2 → tpr (ⓝV. T1) T2
-.
-
-interpretation
-   "context-free parallel reduction (term)"
-   'PRed T1 T2 = (tpr T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma tpr_bind: ∀a,I,V1,V2,T1,T2. V1 ➡ V2 → T1 ➡ T2 → ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
-/2 width=3/ qed.
-
-(* Basic_1: was by definition: pr0_refl *)
-lemma tpr_refl: reflexive … tpr.
-#T elim T -T //
-#I elim I -I /2 width=1/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact tpr_inv_atom1_aux: ∀U1,U2. U1 ➡ U2 → ∀I. U1 = ⓪{I} → U2 = ⓪{I}.
-#U1 #U2 * -U1 -U2
-[ //
-| #I #V1 #V2 #T1 #T2 #_ #_ #k #H destruct
-| #a #V1 #V2 #W #T1 #T2 #_ #_ #k #H destruct
-| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #k #H destruct
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #k #H destruct
-| #V #T1 #T #T2 #_ #_ #k #H destruct
-| #V #T1 #T2 #_ #k #H destruct
-]
-qed.
-
-(* Basic_1: was: pr0_gen_sort pr0_gen_lref *)
-lemma tpr_inv_atom1: ∀I,U2. ⓪{I} ➡ U2 → U2 = ⓪{I}.
-/2 width=3/ qed-.
-
-fact tpr_inv_bind1_aux: ∀U1,U2. U1 ➡ U2 → ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
-                        (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
-                                    ⋆.  ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 &
-                                    U2 = ⓑ{a,I} V2. T2
-                        ) ∨
-                        ∃∃T. T1 ➡ T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
-#U1 #U2 * -U1 -U2
-[ #J #a #I #V #T #H destruct
-| #I1 #V1 #V2 #T1 #T2 #_ #_ #a #I #V #T #H destruct
-| #b #V1 #V2 #W #T1 #T2 #_ #_ #a #I #V #T #H destruct
-| #b #I1 #V1 #V2 #T1 #T #T2 #HV12 #HT1 #HT2 #a #I0 #V0 #T0 #H destruct /3 width=7/
-| #b #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #a #I0 #V0 #T0 #H destruct
-| #V #T1 #T #T2 #HT1 #HT2 #a #I0 #V0 #T0 #H destruct /3 width=3/
-| #V #T1 #T2 #_ #a #I0 #V0 #T0 #H destruct
-]
-qed.
-
-lemma tpr_inv_bind1: ∀V1,T1,U2,a,I. ⓑ{a,I} V1. T1 ➡ U2 →
-                     (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
-                                 ⋆.  ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 &
-                                 U2 = ⓑ{a,I} V2. T2
-                     ) ∨
-                     ∃∃T. T1 ➡ T & ⇧[0,1] U2 ≡ T & a = true & I = Abbr.
-/2 width=3/ qed-.
-
-(* Basic_1: was pr0_gen_abbr *)
-lemma tpr_inv_abbr1: ∀a,V1,T1,U2. ⓓ{a}V1. T1 ➡ U2 →
-                     (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
-                                 ⋆.  ⓓV2 ⊢ T ▶ [0, 1] T2 &
-                                 U2 = ⓓ{a}V2. T2
-                      ) ∨
-                      ∃∃T. T1 ➡ T & ⇧[0, 1] U2 ≡ T & a = true.
-#a #V1 #T1 #U2 #H
-elim (tpr_inv_bind1 … H) -H * /3 width=7/
-qed-.
-
-fact tpr_inv_flat1_aux: ∀U1,U2. U1 ➡ U2 → ∀I,V1,U0. U1 = ⓕ{I} V1. U0 →
-                        ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
-                                                 U2 = ⓕ{I} V2. T2
-                         | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
-                                                 U0 = ⓛ{a}W. T1 &
-                                                 U2 = ⓓ{a}V2. T2 & I = Appl
-                         | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
-                                                 ⇧[0,1] V2 ≡ V &
-                                                 U0 = ⓓ{a}W1. T1 &
-                                                 U2 = ⓓ{a}W2. ⓐV. T2 &
-                                                 I = Appl
-                         |                       (U0 ➡ U2 ∧ I = Cast).
-#U1 #U2 * -U1 -U2
-[ #I #J #V #T #H destruct
-| #I #V1 #V2 #T1 #T2 #HV12 #HT12 #J #V #T #H destruct /3 width=5/
-| #a #V1 #V2 #W #T1 #T2 #HV12 #HT12 #J #V #T #H destruct /3 width=9/
-| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #J #V0 #T0 #H destruct
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HV2 #HW12 #HT12 #J #V0 #T0 #H destruct /3 width=13/
-| #V #T1 #T #T2 #_ #_ #J #V0 #T0 #H destruct
-| #V #T1 #T2 #HT12 #J #V0 #T0 #H destruct /3 width=1/
-]
-qed.
-
-lemma tpr_inv_flat1: ∀V1,U0,U2,I. ⓕ{I} V1. U0 ➡ U2 →
-                     ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
-                                              U2 = ⓕ{I} V2. T2
-                      | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
-                                              U0 = ⓛ{a}W. T1 &
-                                              U2 = ⓓ{a}V2. T2 & I = Appl
-                      | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
-                                              ⇧[0,1] V2 ≡ V &
-                                              U0 = ⓓ{a}W1. T1 &
-                                              U2 = ⓓ{a}W2. ⓐV. T2 &
-                                              I = Appl
-                      |                       (U0 ➡ U2 ∧ I = Cast).
-/2 width=3/ qed-.
-
-(* Basic_1: was pr0_gen_appl *)
-lemma tpr_inv_appl1: ∀V1,U0,U2. ⓐV1. U0 ➡ U2 →
-                     ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
-                                              U2 = ⓐV2. T2
-                      | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
-                                              U0 = ⓛ{a}W. T1 &
-                                              U2 = ⓓ{a}V2. T2
-                      | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
-                                              ⇧[0,1] V2 ≡ V &
-                                              U0 = ⓓ{a}W1. T1 &
-                                              U2 = ⓓ{a}W2. ⓐV. T2.
-#V1 #U0 #U2 #H
-elim (tpr_inv_flat1 … H) -H *
-/3 width=5/ /3 width=9/ /3 width=13/
-#_ #H destruct
-qed-.
-
-(* Note: the main property of simple terms *)
-lemma tpr_inv_appl1_simple: ∀V1,T1,U. ⓐV1. T1 ➡ U → 𝐒⦃T1⦄ →
-                            ∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 &
-                                     U = ⓐV2. T2.
-#V1 #T1 #U #H #HT1
-elim (tpr_inv_appl1 … H) -H *
-[ /2 width=5/
-| #a #V2 #W #W1 #W2 #_ #_ #H #_ destruct
-  elim (simple_inv_bind … HT1)
-| #a #V2 #V #W1 #W2 #U1 #U2 #_ #_ #_ #_ #H #_ destruct
-  elim (simple_inv_bind … HT1)
-]
-qed-.
-
-(* Basic_1: was: pr0_gen_cast *)
-lemma tpr_inv_cast1: ∀V1,T1,U2. ⓝV1. T1 ➡ U2 →
-                       (∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 & U2 = ⓝV2. T2)
-                     ∨ T1 ➡ U2.
-#V1 #T1 #U2 #H
-elim (tpr_inv_flat1 … H) -H * /3 width=5/ #a #V2 #W #W1 #W2
-[ #_ #_ #_ #_ #H destruct
-| #T2 #U1 #_ #_ #_ #_ #_ #_ #H destruct
-]
-qed-.
-
-fact tpr_inv_lref2_aux: ∀T1,T2. T1 ➡ T2 → ∀i. T2 = #i →
-                        ∨∨        T1 = #i
-                         | ∃∃V,T. T ➡ #(i+1) & T1 = +ⓓV. T
-                         | ∃∃V,T. T ➡ #i & T1 = ⓝV. T.
-#T1 #T2 * -T1 -T2
-[ #I #i #H destruct /2 width=1/
-| #I #V1 #V2 #T1 #T2 #_ #_ #i #H destruct
-| #a #V1 #V2 #W #T1 #T2 #_ #_ #i #H destruct
-| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #i #H destruct
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #i #H destruct
-| #V #T1 #T #T2 #HT1 #HT2 #i #H destruct
-  lapply (lift_inv_lref1_ge … HT2 ?) -HT2 // #H destruct /3 width=4/
-| #V #T1 #T2 #HT12 #i #H destruct /3 width=4/
-]
-qed.
-
-lemma tpr_inv_lref2: ∀T1,i. T1 ➡ #i →
-                     ∨∨        T1 = #i
-                      | ∃∃V,T. T ➡ #(i+1) & T1 = +ⓓV. T
-                      | ∃∃V,T. T ➡ #i & T1 = ⓝV. T.
-/2 width=3/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma tpr_fwd_bind1_minus: ∀I,V1,T1,T. -ⓑ{I}V1.T1 ➡ T → ∀b.
-                           ∃∃V2,T2. ⓑ{b,I}V1.T1 ➡ ⓑ{b,I}V2.T2 &
-                                    T = -ⓑ{I}V2.T2.
-#I #V1 #T1 #T #H #b elim (tpr_inv_bind1 … H) -H *
-[ #V2 #T0 #T2 #HV12 #HT10 #HT02 #H destruct /3 width=4/
-| #T2 #_ #_ #H destruct
-]
-qed-.
-
-lemma tpr_fwd_shift1: ∀L1,T1,T. L1 @@ T1 ➡ T →
-                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #T1 #T #HT1
-  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #T1 #X
-  >shift_append_assoc normalize #H
-  elim (tpr_inv_bind1 … H) -H *
-  [ #V0 #T0 #X0 #_ #HT10 #H0 #H destruct
-    elim (IH … HT10) -IH -T1 #L #T #HL1 #H destruct
-    elim (tps_fwd_shift1 … H0) -T #L2 #T2 #HL2 #H destruct
-    >append_length >HL1 >HL2 -L1 -L
-    @(ex2_2_intro … (⋆.ⓑ{I}V0@@L2) T2) [ >append_length ] // /2 width=3/ (**) (* explicit constructor *)
-  | #T #_ #_ #H destruct
-  ]
-]
-qed-.
-
-(* Basic_1: removed theorems 3:
-            pr0_subst0_back pr0_subst0_fwd pr0_subst0
-*)
-(* Basic_1: removed local theorems: 1: pr0_delta_tau *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_lift.etc
deleted file mode 100644 (file)
index 8d6b036..0000000
+++ /dev/null
@@ -1,121 +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/tps_lift.ma".
-include "basic_2/reducibility/tpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
-
-(* Relocation properties ****************************************************)
-
-(* Basic_1: was: pr0_lift *)
-lemma tpr_lift: t_liftable tpr.
-#T1 #T2 #H elim H -T1 -T2
-[ * #i #U1 #d #e #HU1 #U2 #HU2
-  lapply (lift_mono … HU1 … HU2) -HU1 #H destruct
-  [ lapply (lift_inv_sort1 … HU2) -HU2 #H destruct //
-  | lapply (lift_inv_lref1 … HU2) * * #Hid #H destruct //
-  | lapply (lift_inv_gref1 … HU2) -HU2 #H destruct //
-  ]
-| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
-  elim (lift_inv_flat1 … HX1) -HX1 #W1 #U1 #HVW1 #HTU1 #HX1 destruct
-  elim (lift_inv_flat1 … HX2) -HX2 #W2 #U2 #HVW2 #HTU2 #HX2 destruct /3 width=4/
-| #a #V1 #V2 #W #T1 #T2 #_ #_ #IHV12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
-  elim (lift_inv_flat1 … HX1) -HX1 #V0 #X #HV10 #HX #HX1 destruct
-  elim (lift_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT10 #HX destruct
-  elim (lift_inv_bind1 … HX2) -HX2 #V3 #T3 #HV23 #HT23 #HX2 destruct /3 width=4/
-| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV12 #IHT1 #X1 #d #e #HX1 #X2 #HX2
-  elim (lift_inv_bind1 … HX1) -HX1 #W1 #U1 #HVW1 #HTU1 #HX1 destruct
-  elim (lift_inv_bind1 … HX2) -HX2 #W2 #U0 #HVW2 #HTU0 #HX2 destruct
-  elim (lift_total T (d + 1) e) #U #HTU
-  @tpr_delta
-  [4: @(tps_lift_le … HT2 … HTU HTU0 ?) /2 width=1/ |1: skip |2: /2 width=4/ |3: /2 width=4/ ] (**) (*/3. is too slow *)
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
-  elim (lift_inv_flat1 … HX1) -HX1 #V0 #X #HV10 #HX #HX1 destruct
-  elim (lift_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT10 #HX destruct
-  elim (lift_inv_bind1 … HX2) -HX2 #W3 #X #HW23 #HX #HX2 destruct
-  elim (lift_inv_flat1 … HX) -HX #V3 #T3 #HV3 #HT23 #HX destruct
-  elim (lift_trans_ge … HV2 … HV3 ?) -V // /3 width=4/
-| #V #T1 #T #T2 #_ #HT2 #IHT1 #X #d #e #H #U2 #HTU2
-  elim (lift_inv_bind1 … H) -H #V3 #T3 #_ #HT13 #H destruct -V
-  elim (lift_conf_O1 … HTU2 … HT2) -T2 /3 width=4/
-| #V #T1 #T2 #_ #IHT12 #X #d #e #HX #T #HT2
-  elim (lift_inv_flat1 … HX) -HX #V0 #T0 #_ #HT0 #HX destruct /3 width=4/
-]
-qed.
-
-(* Basic_1: was: pr0_gen_lift *)
-lemma tpr_inv_lift1: t_deliftable_sn tpr.
-#T1 #T2 #H elim H -T1 -T2
-[ * #i #X #d #e #HX
-  [ lapply (lift_inv_sort2 … HX) -HX #H destruct /2 width=3/
-  | lapply (lift_inv_lref2 … HX) -HX * * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … HX) -HX #H destruct /2 width=3/
-  ]
-| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #X #d #e #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #T0 #HV01 #HT01 #HX destruct
-  elim (IHV12 … HV01) -V1
-  elim (IHT12 … HT01) -T1 /3 width=5/
-| #a #V1 #V2 #W1 #T1 #T2 #_ #_ #IHV12 #IHT12 #X #d #e #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
-  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
-  elim (IHV12 … HV01) -V1
-  elim (IHT12 … HT01) -T1 /3 width=5/
-| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV12 #IHT1 #X #d #e #HX
-  elim (lift_inv_bind2 … HX) -HX #W1 #U1 #HWV1 #HUT1 #HX destruct
-  elim (IHV12 … HWV1) -V1 #W2 #HWV2 #HW12
-  elim (IHT1 … HUT1) -T1 #U #HUT #HU1
-  elim (tps_inv_lift1_le … HT2 … HUT ?) -T // [3: /2 width=5/ |2: skip ] #U2 #HU2 #HUT2
-  @ex2_intro  [2: /2 width=2/ |1: skip |3: /2 width=3/ ] (**) (* /3 width=5/ is slow *)
-| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #X #d #e #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
-  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
-  elim (IHV12 … HV01) -V1 #V3 #HV32 #HV03
-  elim (IHW12 … HW01) -W1 #W3 #HW32 #HW03
-  elim (IHT12 … HT01) -T1 #T3 #HT32 #HT03
-  elim (lift_trans_le … HV32 … HV2 ?) -V2 // #V2 #HV32 #HV2
-  @ex2_intro [2: /3 width=2/ |1: skip |3: /2 width=3/ ] (**) (* /4 width=5/ is slow *)
-| #V #T1 #T #T2 #_ #HT2 #IHT1 #X #d #e #HX
-  elim (lift_inv_bind2 … HX) -HX #V3 #T3 #_ #HT31 #H destruct
-  elim (IHT1 … HT31) -T1 #T1 #HT1 #HT31
-  elim (lift_div_le … HT2 … HT1 ?) -T // /3 width=5/
-| #V #T1 #T2 #_ #IHT12 #X #d #e #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #T0 #_ #HT01 #H destruct
-  elim (IHT12 … HT01) -T1 /3 width=3/
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-(* Basic_1: was pr0_gen_abst *)
-lemma tpr_inv_abst1: ∀a,V1,T1,U2. ⓛ{a}V1. T1 ➡ U2 →
-                     ∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 & U2 = ⓛ{a}V2. T2.
-#a #V1 #T1 #U2 #H elim (tpr_inv_bind1 … H) -H *
-[ #V2 #T #T2 #HV12 #HT1 #HT2
-  lapply (tps_inv_refl_SO2 … HT2 ???) -HT2 // /2 width=5/
-| #T2 #_ #_ #_ #H destruct
-]
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma tpr_fwd_abst1: ∀a,V1,T1,U2. ⓛ{a}V1.T1 ➡ U2 → ∀b,I,W.
-                     ∃∃V2,T2. ⓑ{b,I}W.T1 ➡ ⓑ{b,I}W.T2 &
-                              U2 = ⓛ{a}V2.T2.
-#a #V1 #T1 #U2 #H #b #I #W elim (tpr_inv_bind1 … H) -H *
-[ #V2 #T #T2 #HV12 #HT1 #HT2
-  lapply (tps_inv_refl_SO2 … HT2 ???) -HT2 // /3 width=4/
-| #T2 #_ #_ #_ #H destruct
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_tpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpr_tpr.etc
deleted file mode 100644 (file)
index a733345..0000000
+++ /dev/null
@@ -1,261 +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/reducibility/ltpr_tpss.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
-
-(* Confluence lemmas ********************************************************)
-
-fact tpr_conf_atom_atom: ∀I. ∃∃X. ⓪{I} ➡ X & ⓪{I} ➡ X.
-/2 width=3/ qed.
-
-fact tpr_conf_flat_flat:
-   ∀I,V0,V1,T0,T1,V2,T2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
-   ∃∃T0. ⓕ{I} V1. T1 ➡ T0 & ⓕ{I} V2. T2 ➡ T0.
-#I #V0 #V1 #T0 #T1 #V2 #T2 #IH #HV01 #HV02 #HT01 #HT02
-elim (IH … HV01 … HV02) -HV01 -HV02 // #V #HV1 #HV2
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /3 width=5/
-qed.
-
-fact tpr_conf_flat_beta:
-   ∀a,V0,V1,T1,V2,W0,U0,T2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{U0} + 1) + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 →
-   U0 ➡ T2 → ⓛ{a}W0. U0 ➡ T1 →
-   ∃∃X. ⓐV1. T1 ➡ X & ⓓ{a}V2. T2 ➡ X.
-#a #V0 #V1 #T1 #V2 #W0 #U0 #T2 #IH #HV01 #HV02 #HT02 #H
-elim (tpr_inv_abst1 … H) -H #W1 #U1 #HW01 #HU01 #H destruct
-elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
-elim (IH … HT02 … HU01) -HT02 -HU01 -IH /2 width=1/ /3 width=5/
-qed.
-
-(* Basic-1: was:
-            pr0_cong_upsilon_refl pr0_cong_upsilon_zeta
-            pr0_cong_upsilon_cong pr0_cong_upsilon_delta
-*)
-fact tpr_conf_flat_theta:
-   ∀a,V0,V1,T1,V2,V,W0,W2,U0,U2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{U0} + 1) + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 → ⇧[O,1] V2 ≡ V →
-   W0 ➡ W2 → U0 ➡ U2 →  ⓓ{a}W0. U0 ➡ T1 →
-   ∃∃X. ⓐV1. T1 ➡ X & ⓓ{a}W2. ⓐV. U2 ➡ X.
-#a #V0 #V1 #T1 #V2 #V #W0 #W2 #U0 #U2 #IH #HV01 #HV02 #HV2 #HW02 #HU02 #H
-elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #VV #HVV1 #HVV2
-elim (lift_total VV 0 1) #VVV #HVV
-lapply (tpr_lift … HVV2 … HV2 … HVV) #HVVV
-elim (tpr_inv_abbr1 … H) -H *
-(* case 1: delta *)
-[ -HV2 -HVV2 #WW2 #UU2 #UU #HWW2 #HUU02 #HUU2 #H destruct
-  elim (IH … HW02 … HWW2) -HW02 -HWW2 /2 width=1/ #W #HW02 #HWW2
-  elim (IH … HU02 … HUU02) -HU02 -HUU02 -IH /2 width=1/ #U #HU2 #HUUU2
-  elim (tpr_tps_conf_bind … HWW2 HUUU2 … HUU2) -UU2 #UUU #HUUU2 #HUUU1
-  @ex2_intro
-  [2: @tpr_theta [6: @HVV |7: @HWW2 |8: @HUUU2 |1,2,3,4: skip | // ]
-  |1:skip
-  |3: @tpr_delta [3: @tpr_flat |1: skip ] /2 width=5/
-  ] (**) (* /5 width=14/ is too slow *)
-(* case 3: zeta *)
-| -HV2 -HW02 -HVV2 #U1 #HU01 #HTU1
-  elim (IH … HU01 … HU02) -HU01 -HU02 -IH // -U0 #U #HU1 #HU2
-  elim (tpr_inv_lift1 … HU1 … HTU1) -U1 #UU #HUU #HT1UU #H destruct
-  @(ex2_intro … (ⓐVV.UU)) /2 width=1/ /3 width=5/ (**) (* /4 width=9/ is too slow *)
-]
-qed.
-
-fact tpr_conf_flat_cast:
-   ∀X2,V0,V1,T0,T1. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → T0 ➡ T1 → T0 ➡ X2 →
-   ∃∃X. ⓝV1. T1 ➡ X & X2 ➡ X.
-#X2 #V0 #V1 #T0 #T1 #IH #_ #HT01 #HT02
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /3 width=3/
-qed.
-
-fact tpr_conf_beta_beta:
-   ∀a. ∀W0:term. ∀V0,V1,T0,T1,V2,T2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{T0} + 1) + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
-   ∃∃X. ⓓ{a}V1. T1 ➡X & ⓓ{a}V2. T2 ➡ X.
-#a #W0 #V0 #V1 #T0 #T1 #V2 #T2 #IH #HV01 #HV02 #HT01 #HT02
-elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH /2 width=1/ /3 width=5/
-qed.
-
-(* Basic_1: was: pr0_cong_delta pr0_delta_delta *)
-fact tpr_conf_delta_delta:
-   ∀a,I1,V0,V1,T0,T1,TT1,V2,T2,TT2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
-   ⋆. ⓑ{I1} V1 ⊢ T1 ▶ [O, 1] TT1 →
-   ⋆. ⓑ{I1} V2 ⊢ T2 ▶ [O, 1] TT2 →
-   ∃∃X. ⓑ{a,I1} V1. TT1 ➡ X & ⓑ{a,I1} V2. TT2 ➡ X.
-#a #I1 #V0 #V1 #T0 #T1 #TT1 #V2 #T2 #TT2 #IH #HV01 #HV02 #HT01 #HT02 #HTT1 #HTT2
-elim (IH … HV01 … HV02) -HV01 -HV02 // #V #HV1 #HV2
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH // #T #HT1 #HT2
-elim (tpr_tps_conf_bind … HV1 HT1 … HTT1) -T1 #U1 #TTU1 #HTU1
-elim (tpr_tps_conf_bind … HV2 HT2 … HTT2) -T2 #U2 #TTU2 #HTU2
-elim (tps_conf_eq … HTU1 … HTU2) -T #U #HU1 #HU2
-@ex2_intro [2,3: @tpr_delta |1: skip ] /width=10/ (**) (* /3 width=10/ is too slow *)
-qed.
-
-fact tpr_conf_delta_zeta:
-   ∀X2,V0,V1,T0,T1,TT1,T2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → T0 ➡ T1 → ⋆. ⓓV1 ⊢ T1 ▶ [O,1] TT1 →
-   T0 ➡ T2 → ⇧[O, 1] X2 ≡ T2 →
-   ∃∃X. +ⓓV1. TT1 ➡ X & X2 ➡ X.
-#X2 #V0 #V1 #T0 #T1 #TT1 #T2 #IH #_ #HT01 #HTT1 #HT02 #HXT2
-elim (IH … HT01 … HT02) -IH -HT01 -HT02 // -V0 -T0 #T #HT1 #HT2
-elim (tpr_tps_conf_bind ? ? V1 … HT1 HTT1) -T1 // #TT #HTT1 #HTT
-elim (tpr_inv_lift1 … HT2 … HXT2) -T2 #X #HXT #HX2
-lapply (tps_inv_lift1_eq … HTT … HXT) -HTT #H destruct /3 width=3/
-qed.
-
-(* Basic_1: was: pr0_upsilon_upsilon *)
-fact tpr_conf_theta_theta:
-   ∀a,VV1,V0,V1,W0,W1,T0,T1,V2,VV2,W2,T2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{T0} + 1) + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   V0 ➡ V1 → V0 ➡ V2 → W0 ➡ W1 → W0 ➡ W2 → T0 ➡ T1 → T0 ➡ T2 →
-   ⇧[O, 1] V1 ≡ VV1 → ⇧[O, 1] V2 ≡ VV2 →
-   ∃∃X. ⓓ{a}W1. ⓐVV1. T1 ➡ X & ⓓ{a}W2. ⓐVV2. T2 ➡ X.
-#a #VV1 #V0 #V1 #W0 #W1 #T0 #T1 #V2 #VV2 #W2 #T2 #IH #HV01 #HV02 #HW01 #HW02 #HT01 #HT02 #HVV1 #HVV2
-elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
-elim (IH … HW01 … HW02) -HW01 -HW02 /2 width=1/ #W #HW1 #HW2
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH /2 width=1/ #T #HT1 #HT2
-elim (lift_total V 0 1) #VV #HVV
-lapply (tpr_lift … HV1 … HVV1 … HVV) -V1 #HVV1
-lapply (tpr_lift … HV2 … HVV2 … HVV) -V2 -HVV #HVV2
-@ex2_intro [2,3: @tpr_bind |1:skip ] /2 width=5/ (**) (* /4 width=5/ is too slow *)
-qed.
-
-fact tpr_conf_zeta_zeta:
-   ∀V0:term. ∀X2,TT0,T0,T1,TT2. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{TT0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   TT0 ➡ T0 → ⇧[O, 1] T1 ≡ T0 →
-   TT0 ➡ TT2 → ⇧[O, 1] X2 ≡ TT2 →
-   ∃∃X. T1 ➡ X & X2 ➡ X.
-#V0 #X2 #TT0 #T0 #T1 #TT2 #IH #HTT0 #HT10 #HTT02 #HXTT2
-elim (IH … HTT0 … HTT02) -IH -HTT0 -HTT02 // -V0 -TT0 #T #HT0 #HTT2
-elim (tpr_inv_lift1 … HT0 … HT10) -T0 #T0 #HT0 #HT10
-elim (tpr_inv_lift1 … HTT2 … HXTT2) -TT2 #TT2 #HTT2 #HXTT2
-lapply (lift_inj … HTT2 … HT0) -HTT2 #H destruct /2 width=3/
-qed.
-
-fact tpr_conf_tau_tau:
-   ∀V0,T0:term. ∀X2,T1. (
-      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
-      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
-      ∃∃X. X1 ➡ X & X2 ➡ X
-   ) →
-   T0 ➡ T1 → T0 ➡ X2 →
-   ∃∃X. T1 ➡ X & X2 ➡ X.
-#V0 #T0 #X2 #T1 #IH #HT01 #HT02
-elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /2 width=3/
-qed.
-
-(* Confluence ***************************************************************)
-
-(* Basic_1: was: pr0_confluence *)
-theorem tpr_conf: ∀T0:term. ∀T1,T2. T0 ➡ T1 → T0 ➡ T2 →
-                  ∃∃T. T1 ➡ T & T2 ➡ T.
-#T0 @(f_ind … tw … T0) -T0 #n #IH *
-[ #I #_ #X1 #X2 #H1 #H2 -n
-  >(tpr_inv_atom1 … H1) -X1
-  >(tpr_inv_atom1 … H2) -X2
-(* case 1: atom, atom *)
-  //
-| * [ #a ] #I #V0 #T0 #Hn #X1 #X2 #H1 #H2
-  [ elim (tpr_inv_bind1 … H1) -H1 *
-    [ #V1 #T1 #U1 #HV01 #HT01 #HTU1 #H1
-    | #T1 #HT01 #HXT1 #H11 #H12
-    ]
-    elim (tpr_inv_bind1 … H2) -H2 *
-    [1,3: #V2 #T2 #U2 #HV02 #HT02 #HTU2 #H2
-    |2,4: #T2 #HT02 #HXT2 #H21 #H22
-    ] destruct
-(* case 2: delta, delta *)
-    [ /3 width=11 by tpr_conf_delta_delta/ (**) (* /3 width=11/ is too slow *)
-(* case 3: zeta, delta (repeated) *)
-    | @ex2_commute /3 width=10 by tpr_conf_delta_zeta/
-(* case 4: delta, zeta *)
-    | /3 width=10 by tpr_conf_delta_zeta/ (**) (* /3 width=10/ is too slow *)
-(* case 5: zeta, zeta *)
-    | /3 width=9 by tpr_conf_zeta_zeta/ (**) (* /3 width=9/ is too slow *)
-    ]
-  | elim (tpr_inv_flat1 … H1) -H1 *
-    [ #V1 #T1 #HV01 #HT01 #H1
-    | #b1 #V1 #W1 #U1 #T1 #HV01 #HUT1 #H11 #H12 #H13
-    | #b1 #V1 #Y1 #W1 #Z1 #U1 #T1 #HV01 #HWZ1 #HUT1 #HVY1 #H11 #H12 #H13
-    | #HX1 #H1
-    ]
-    elim (tpr_inv_flat1 … H2) -H2 *
-    [1,5,9,13: #V2 #T2 #HV02 #HT02 #H2
-    |2,6,10,14: #b2 #V2 #W2 #U2 #T2 #HV02 #HUT2 #H21 #H22 #H23
-    |3,7,11,15: #b2 #V2 #Y2 #W2 #Z2 #U2 #T2 #HV02 #HWZ2 #HUT2 #HVY2 #H21 #H22 #H23
-    |4,8,12,16: #HX2 #H2
-    ] destruct
-(* case 6: flat, flat *)
-    [ /3 width=7 by tpr_conf_flat_flat/ (**) (* /3 width=7/ is too slow *)
-(* case 7: beta, flat (repeated) *)
-    | @ex2_commute /3 width=8 by tpr_conf_flat_beta/
-(* case 8: theta, flat (repeated) *)
-    | @ex2_commute /3 width=11 by tpr_conf_flat_theta/
-(* case 9: tau, flat (repeated) *)
-    | @ex2_commute /3 width=6 by tpr_conf_flat_cast/
-(* case 10: flat, beta *)
-    | /3 width=8 by tpr_conf_flat_beta/ (**) (* /3 width=8/ is too slow *)
-(* case 11: beta, beta *)
-    | /3 width=8 by tpr_conf_beta_beta/ (**) (* /3 width=8/ is too slow *)
-(* case 12: flat, theta *)
-    | /3 width=11 by tpr_conf_flat_theta/ (**) (* /3 width=11/ is too slow *)
-(* case 13: theta, theta *)
-    | /3 width=14 by tpr_conf_theta_theta/ (**) (* /3 width=14/ is too slow *)
-(* case 14: flat, tau *)
-    | /3 width=6 by tpr_conf_flat_cast/ (**) (* /3 width=6/ is too slow *)
-(* case 15: tau, tau *)
-    | /3 width=5 by tpr_conf_tau_tau/
-    ]
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs.etc
deleted file mode 100644 (file)
index 492b390..0000000
+++ /dev/null
@@ -1,94 +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 "hvbox( T1 ➡ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PRedStar $T1 $T2 }.
-
-include "basic_2/reducibility/tpr.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
-
-(* Basic_1: includes: pr1_pr0 *)
-definition tprs: relation term ≝ TC … tpr.
-
-interpretation "context-free parallel computation (term)"
-   'PRedStar T1 T2 = (tprs T1 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma tprs_ind: ∀T1. ∀R:predicate term. R T1 →
-                (∀T,T2. T1 ➡* T → T ➡ T2 → R T → R T2) →
-                ∀T2. T1 ➡* T2 → R T2.
-#T1 #R #HT1 #IHT1 #T2 #HT12
-@(TC_star_ind … HT1 IHT1 … HT12) //
-qed-.
-
-lemma tprs_ind_dx: ∀T2. ∀R:predicate term. R T2 →
-                   (∀T1,T. T1 ➡ T → T ➡* T2 → R T → R T1) →
-                   ∀T1. T1 ➡* T2 → R T1.
-#T2 #R #HT2 #IHT2 #T1 #HT12
-@(TC_star_ind_dx … HT2 IHT2 … HT12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma tprs_refl: reflexive … tprs.
-/2 width=1/ qed.
-
-lemma tpr_tprs: ∀T1,T2. T1 ➡ T2 → T2 ➡* T2.
-/2 width=1/ qed.
-
-lemma tprs_strap1: ∀T1,T,T2. T1 ➡* T → T ➡ T2 → T1 ➡* T2.
-/2 width=3/ qed.
-
-lemma tprs_strap2: ∀T1,T,T2. T1 ➡ T → T ➡* T2 → T1 ➡* T2.
-/2 width=3/ qed.
-
-(* Basic_1: was only: pr1_head_1 *)
-lemma tprs_pair_sn: ∀I,T1,T2. T1 ➡ T2 → ∀V1,V2. V1 ➡* V2 →
-                    ②{I} V1. T1 ➡* ②{I} V2. T2.
-* [ #a ] #I #T1 #T2 #HT12 #V1 #V2 #H @(tprs_ind … H) -V2
-[1,3: /3 width=1/
-|2,4: #V #V2 #_ #HV2 #IHV1
-      @(tprs_strap1 … IHV1) -IHV1 /2 width=1/
-]
-qed.
-
-(* Basic_1: was only: pr1_head_2 *)
-lemma tprs_pair_dx: ∀I,V1,V2. V1 ➡ V2 → ∀T1,T2. T1 ➡* T2 →
-                    ②{I} V1. T1 ➡* ②{I} V2. T2.
-* [ #a ] #I #V1 #V2 #HV12 #T1 #T2 #H @(tprs_ind … H) -T2
-[1,3: /3 width=1/
-|2,4: #T #T2 #_ #HT2 #IHT1
-      @(tprs_strap1 … IHT1) -IHT1 /2 width=1/
-]
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma tprs_inv_atom1: ∀U2,k. ⋆k ➡* U2 → U2 = ⋆k.
-#U2 #k #H @(tprs_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU1 destruct
->(tpr_inv_atom1 … HU2) -HU2 //
-qed-.
-
-lemma tprs_inv_cast1: ∀W1,T1,U2. ⓝW1.T1 ➡* U2 → T1 ➡* U2 ∨
-                      ∃∃W2,T2. W1 ➡* W2 & T1 ➡* T2 & U2 = ⓝW2.T2.
-#W1 #T1 #U2 #H @(tprs_ind … H) -U2 /3 width=5/
-#U #U2 #_ #HU2 * /3 width=3/ *
-#W #T #HW1 #HT1 #H destruct
-elim (tpr_inv_cast1 … HU2) -HU2 /3 width=3/ *
-#W2 #T2 #HW2 #HT2 #H destruct /4 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_lift.etc
deleted file mode 100644 (file)
index d0d1734..0000000
+++ /dev/null
@@ -1,43 +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/reducibility/tpr_lift.ma".
-include "basic_2/computation/tprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma tprs_inv_abst1: ∀a,V1,T1,U2. ⓛ{a}V1. T1 ➡* U2 →
-                      ∃∃V2,T2. V1 ➡* V2 & T1 ➡* T2 & U2 = ⓛ{a}V2. T2.
-#a #V1 #T1 #U2 #H @(tprs_ind … H) -U2 /2 width=5/
-#U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
-elim (tpr_inv_abst1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
-qed-.
-
-lemma tprs_inv_abst: ∀a,V1,V2,T1,T2. ⓛ{a}V1. T1 ➡* ⓛ{a}V2. T2 →
-                     V1 ➡* V2 ∧ T1 ➡* T2.
-#a #V1 #V2 #T1 #T2 #H
-elim (tprs_inv_abst1 … H) -H #V #T #HV1 #HT1 #H destruct /2 width=1/
-qed-.
-
-(* Relocation properties ****************************************************)
-
-(* Note: this was missing in basic_1 *)
-lemma tprs_lift: t_liftable tprs.
-/3 width=7/ qed.
-
-(* Note: this was missing in basic_1 *)
-lemma tprs_inv_lift1: t_deliftable_sn tprs.
-/3 width=3 by tpr_inv_lift1, t_deliftable_sn_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_tprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tprs_tprs.etc
deleted file mode 100644 (file)
index 87a4a71..0000000
+++ /dev/null
@@ -1,43 +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/reducibility/tpr_tpr.ma".
-include "basic_2/computation/tprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
-
-(* Advanced properties ******************************************************)
-
-(* Basic_1: was: pr1_strip *)
-lemma tprs_strip: ∀T1,T. T ➡* T1 → ∀T2. T ➡ T2 →
-                  ∃∃T0. T1 ➡ T0 & T2 ➡* T0.
-/3 width=3 by TC_strip1, tpr_conf/ qed.
-
-(* Main propertis ***********************************************************)
-
-(* Basic_1: was: pr1_confluence *)
-theorem tprs_conf: confluent … tprs.
-/3 width=3/ qed.
-
-(* Basic_1: was: pr1_t *)
-theorem tprs_trans: Transitive … tprs.
-/2 width=3/ qed.
-
-(* Basic_1: was: pr1_comp *)
-lemma tprs_pair: ∀I,V1,V2. V1 ➡* V2 → ∀T1,T2. T1 ➡* T2 →
-                 ②{I} V1. T1 ➡* ②{I} V2. T2.
-#I #V1 #V2 #H @(tprs_ind … H) -V2 /2 width=1/
-#V #V2 #_ #HV2 #IHV1 #T1 #T2 #HT12
-@(tprs_trans … (②{I}V.T2)) /2 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps.etc
deleted file mode 100644 (file)
index 7d89243..0000000
+++ /dev/null
@@ -1,288 +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 "hvbox( L ⊢ break term 46 T1 break ▶ [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubst $L $T1 $d $e $T2 }.
-
-include "basic_2/substitution/ldrop_append.ma".
-
-(* PARALLEL SUBSTITUTION ON TERMS *******************************************)
-
-inductive tps: nat → nat → lenv → relation term ≝
-| tps_atom : ∀L,I,d,e. tps d e L (⓪{I}) (⓪{I})
-| tps_subst: ∀L,K,V,W,i,d,e. d ≤ i → i < d + e →
-             ⇩[0, i] L ≡ K. ⓓV → ⇧[0, i + 1] V ≡ W → tps d e L (#i) W
-| tps_bind : ∀L,a,I,V1,V2,T1,T2,d,e.
-             tps d e L V1 V2 → tps (d + 1) e (L. ⓑ{I} V2) T1 T2 →
-             tps d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| tps_flat : ∀L,I,V1,V2,T1,T2,d,e.
-             tps d e L V1 V2 → tps d e L T1 T2 →
-             tps d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-.
-
-interpretation "parallel substritution (term)"
-   'PSubst L T1 d e T2 = (tps d e L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma tps_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶ [d, e] T2 →
-                       ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶ [d, e] T2.
-#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
-[ //
-| #L1 #K1 #V #W #i #d #e #Hdi #Hide #HLK1 #HVW #L2 #HL12
-  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /2 width=4/
-| /4 width=1/
-| /3 width=1/
-]
-qed.
-
-lemma tps_refl: ∀T,L,d,e. L ⊢ T ▶ [d, e] T.
-#T elim T -T //
-#I elim I -I /2 width=1/
-qed.
-
-(* Basic_1: was: subst1_ex *)
-lemma tps_full: ∀K,V,T1,L,d. ⇩[0, d] L ≡ (K. ⓓV) →
-                ∃∃T2,T. L ⊢ T1 ▶ [d, 1] T2 & ⇧[d, 1] T ≡ T2.
-#K #V #T1 elim T1 -T1
-[ * #i #L #d #HLK /2 width=4/
-  elim (lt_or_eq_or_gt i d) #Hid /3 width=4/
-  destruct
-  elim (lift_total V 0 (i+1)) #W #HVW
-  elim (lift_split … HVW i i ? ? ?) // /3 width=4/
-| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
-  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
-  [ elim (IHU1 (L. ⓑ{I} W2) (d+1) ?) -IHU1 /2 width=1/ -HLK /3 width=9/
-  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8/
-  ]
-]
-qed.
-
-lemma tps_weak: ∀L,T1,T2,d1,e1. L ⊢ T1 ▶ [d1, e1] T2 →
-                ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 →
-                L ⊢ T1 ▶ [d2, e2] T2.
-#L #T1 #T2 #d1 #e1 #H elim H -L -T1 -T2 -d1 -e1
-[ //
-| #L #K #V #W #i #d1 #e1 #Hid1 #Hide1 #HLK #HVW #d2 #e2 #Hd12 #Hde12
-  lapply (transitive_le … Hd12 … Hid1) -Hd12 -Hid1 #Hid2
-  lapply (lt_to_le_to_lt … Hide1 … Hde12) -Hide1 /2 width=4/
-| /4 width=3/
-| /4 width=1/
-]
-qed.
-
-lemma tps_weak_top: ∀L,T1,T2,d,e.
-                    L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶ [d, |L| - d] T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
-[ //
-| #L #K #V #W #i #d #e #Hdi #_ #HLK #HVW
-  lapply (ldrop_fwd_ldrop2_length … HLK) #Hi
-  lapply (le_to_lt_to_lt … Hdi Hi) /3 width=4/
-| normalize /2 width=1/
-| /2 width=1/
-]
-qed.
-
-lemma tps_weak_full: ∀L,T1,T2,d,e.
-                     L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶ [0, |L|] T2.
-#L #T1 #T2 #d #e #HT12
-lapply (tps_weak … HT12 0 (d + e) ? ?) -HT12 // #HT12
-lapply (tps_weak_top … HT12) //
-qed.
-
-lemma tps_split_up: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ∀i. d ≤ i → i ≤ d + e →
-                    ∃∃T. L ⊢ T1 ▶ [d, i - d] T & L ⊢ T ▶ [i, d + e - i] T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
-[ /2 width=3/
-| #L #K #V #W #i #d #e #Hdi #Hide #HLK #HVW #j #Hdj #Hjde
-  elim (lt_or_ge i j)
-  [ -Hide -Hjde
-    >(plus_minus_m_m j d) in ⊢ (% → ?); // -Hdj /3 width=4/
-  | -Hdi -Hdj #Hij
-    lapply (plus_minus_m_m … Hjde) -Hjde /3 width=8/
-  ]
-| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
-  elim (IHV12 i ? ?) -IHV12 // #V #HV1 #HV2
-  elim (IHT12 (i + 1) ? ?) -IHT12 /2 width=1/
-  -Hdi -Hide >arith_c1x #T #HT1 #HT2
-  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /3 width=5/
-| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
-  elim (IHV12 i ? ?) -IHV12 // elim (IHT12 i ? ?) -IHT12 //
-  -Hdi -Hide /3 width=5/
-]
-qed.
-
-lemma tps_split_down: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
-                      ∀i. d ≤ i → i ≤ d + e →
-                      ∃∃T. L ⊢ T1 ▶ [i, d + e - i] T &
-                           L ⊢ T ▶ [d, i - d] T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
-[ /2 width=3/
-| #L #K #V #W #i #d #e #Hdi #Hide #HLK #HVW #j #Hdj #Hjde
-  elim (lt_or_ge i j)
-  [ -Hide -Hjde >(plus_minus_m_m j d) in ⊢ (% → ?); // -Hdj /3 width=8/
-  | -Hdi -Hdj
-    >(plus_minus_m_m (d+e) j) in Hide; // -Hjde /3 width=4/
-  ]
-| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
-  elim (IHV12 i ? ?) -IHV12 // #V #HV1 #HV2
-  elim (IHT12 (i + 1) ? ?) -IHT12 /2 width=1/
-  -Hdi -Hide >arith_c1x #T #HT1 #HT2
-  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /3 width=5/
-| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
-  elim (IHV12 i ? ?) -IHV12 // elim (IHT12 i ? ?) -IHT12 //
-  -Hdi -Hide /3 width=5/
-]
-qed.
-
-lemma tps_append: ∀K,T1,T2,d,e. K ⊢ T1 ▶ [d, e] T2 →
-                  ∀L. L @@ K ⊢ T1 ▶ [d, e] T2.
-#K #T1 #T2 #d #e #H elim H -K -T1 -T2 -d -e // /2 width=1/
-#K #K0 #V #W #i #d #e #Hdi #Hide #HK0 #HVW #L
-lapply (ldrop_fwd_ldrop2_length … HK0) #H
-@(tps_subst … (L@@K0) … HVW) // (**) (* /3/ does not work *)
-@(ldrop_O1_append_sn_le … HK0) /2 width=2/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact tps_inv_atom1_aux: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ∀I. T1 = ⓪{I} →
-                        T2 = ⓪{I} ∨
-                        ∃∃K,V,i. d ≤ i & i < d + e &
-                                 ⇩[O, i] L ≡ K. ⓓV &
-                                 ⇧[O, i + 1] V ≡ T2 &
-                                 I = LRef i.
-#L #T1 #T2 #d #e * -L -T1 -T2 -d -e
-[ #L #I #d #e #J #H destruct /2 width=1/
-| #L #K #V #T2 #i #d #e #Hdi #Hide #HLK #HVT2 #I #H destruct /3 width=8/
-| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #J #H destruct
-| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #J #H destruct
-]
-qed.
-
-lemma tps_inv_atom1: ∀L,T2,I,d,e. L ⊢ ⓪{I} ▶ [d, e] T2 →
-                     T2 = ⓪{I} ∨
-                     ∃∃K,V,i. d ≤ i & i < d + e &
-                              ⇩[O, i] L ≡ K. ⓓV &
-                              ⇧[O, i + 1] V ≡ T2 &
-                              I = LRef i.
-/2 width=3/ qed-.
-
-
-(* Basic_1: was: subst1_gen_sort *)
-lemma tps_inv_sort1: ∀L,T2,k,d,e. L ⊢ ⋆k ▶ [d, e] T2 → T2 = ⋆k.
-#L #T2 #k #d #e #H
-elim (tps_inv_atom1 … H) -H //
-* #K #V #i #_ #_ #_ #_ #H destruct
-qed-.
-
-(* Basic_1: was: subst1_gen_lref *)
-lemma tps_inv_lref1: ∀L,T2,i,d,e. L ⊢ #i ▶ [d, e] T2 →
-                     T2 = #i ∨
-                     ∃∃K,V. d ≤ i & i < d + e &
-                            ⇩[O, i] L ≡ K. ⓓV &
-                            ⇧[O, i + 1] V ≡ T2.
-#L #T2 #i #d #e #H
-elim (tps_inv_atom1 … H) -H /2 width=1/
-* #K #V #j #Hdj #Hjde #HLK #HVT2 #H destruct /3 width=4/
-qed-.
-
-lemma tps_inv_gref1: ∀L,T2,p,d,e. L ⊢ §p ▶ [d, e] T2 → T2 = §p.
-#L #T2 #p #d #e #H
-elim (tps_inv_atom1 … H) -H //
-* #K #V #i #_ #_ #_ #_ #H destruct
-qed-.
-
-fact tps_inv_bind1_aux: ∀d,e,L,U1,U2. L ⊢ U1 ▶ [d, e] U2 →
-                        ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
-                        ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 &
-                                 L. ⓑ{I} V2 ⊢ T1 ▶ [d + 1, e] T2 &
-                                 U2 = ⓑ{a,I} V2. T2.
-#d #e #L #U1 #U2 * -d -e -L -U1 -U2
-[ #L #k #d #e #a #I #V1 #T1 #H destruct
-| #L #K #V #W #i #d #e #_ #_ #_ #_ #a #I #V1 #T1 #H destruct
-| #L #b #J #V1 #V2 #T1 #T2 #d #e #HV12 #HT12 #a #I #V #T #H destruct /2 width=5/
-| #L #J #V1 #V2 #T1 #T2 #d #e #_ #_ #a #I #V #T #H destruct
-]
-qed.
-
-lemma tps_inv_bind1: ∀d,e,L,a,I,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶ [d, e] U2 →
-                     ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 &
-                              L. ⓑ{I} V2 ⊢ T1 ▶ [d + 1, e] T2 &
-                              U2 = ⓑ{a,I} V2. T2.
-/2 width=3/ qed-.
-
-fact tps_inv_flat1_aux: ∀d,e,L,U1,U2. L ⊢ U1 ▶ [d, e] U2 →
-                        ∀I,V1,T1. U1 = ⓕ{I} V1. T1 →
-                        ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 & L ⊢ T1 ▶ [d, e] T2 &
-                                 U2 =  ⓕ{I} V2. T2.
-#d #e #L #U1 #U2 * -d -e -L -U1 -U2
-[ #L #k #d #e #I #V1 #T1 #H destruct
-| #L #K #V #W #i #d #e #_ #_ #_ #_ #I #V1 #T1 #H destruct
-| #L #a #J #V1 #V2 #T1 #T2 #d #e #_ #_ #I #V #T #H destruct
-| #L #J #V1 #V2 #T1 #T2 #d #e #HV12 #HT12 #I #V #T #H destruct /2 width=5/
-]
-qed.
-
-lemma tps_inv_flat1: ∀d,e,L,I,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶ [d, e] U2 →
-                     ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 & L ⊢ T1 ▶ [d, e] T2 &
-                              U2 =  ⓕ{I} V2. T2.
-/2 width=3/ qed-.
-
-fact tps_inv_refl_O2_aux: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → e = 0 → T1 = T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
-[ //
-| #L #K #V #W #i #d #e #Hdi #Hide #_ #_ #H destruct
-  lapply (le_to_lt_to_lt … Hdi … Hide) -Hdi -Hide <plus_n_O #Hdd
-  elim (lt_refl_false … Hdd)
-| /3 width=1/
-| /3 width=1/
-]
-qed.
-
-lemma tps_inv_refl_O2: ∀L,T1,T2,d. L ⊢ T1 ▶ [d, 0] T2 → T1 = T2.
-/2 width=6/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma tps_fwd_tw: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ♯{T1} ≤ ♯{T2}.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e normalize
-/3 by monotonic_le_plus_l, le_plus/ (**) (* just /3 width=1/ is too slow *)
-qed-.
-
-lemma tps_fwd_shift1: ∀L1,L,T1,T,d,e. L ⊢ L1 @@ T1 ▶[d, e] T →
-                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#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 (tps_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 ] // /2 width=3/ (**) (* explicit constructor *)
-]
-qed-.
-
-(* Basic_1: removed theorems 25:
-            subst0_gen_sort subst0_gen_lref subst0_gen_head subst0_gen_lift_lt
-            subst0_gen_lift_false subst0_gen_lift_ge subst0_refl subst0_trans
-            subst0_lift_lt subst0_lift_ge subst0_lift_ge_S subst0_lift_ge_s
-            subst0_subst0 subst0_subst0_back subst0_weight_le subst0_weight_lt
-            subst0_confluence_neq subst0_confluence_eq subst0_tlt_head
-            subst0_confluence_lift subst0_tlt
-            subst1_head subst1_gen_head subst1_lift_S subst1_confluence_lift
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_lift.etc
deleted file mode 100644 (file)
index 1d65d8d..0000000
+++ /dev/null
@@ -1,294 +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/ldrop_ldrop.ma".
-include "basic_2/substitution/tps.ma".
-
-(* PARTIAL SUBSTITUTION ON TERMS ********************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-fact tps_inv_S2_aux: ∀L,T1,T2,d,e1. L ⊢ T1 ▶ [d, e1] T2 → ∀e2. e1 = e2 + 1 →
-                     ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶ [d + 1, e2] T2.
-#L #T1 #T2 #d #e1 #H elim H -L -T1 -T2 -d -e1
-[ //
-| #L #K0 #V0 #W #i #d #e1 #Hdi #Hide1 #HLK0 #HV0 #e2 #He12 #K #V #HLK destruct
-  elim (lt_or_ge i (d+1)) #HiSd
-  [ -Hide1 -HV0
-    lapply (le_to_le_to_eq … Hdi ?) /2 width=1/ #H destruct
-    lapply (ldrop_mono … HLK0 … HLK) #H destruct
-  | -V -Hdi /2 width=4/
-  ]
-| /4 width=3/
-| /3 width=3/
-]
-qed.
-
-lemma tps_inv_S2: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e + 1] T2 →
-                  ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶ [d + 1, e] T2.
-/2 width=3/ qed-.
-
-lemma tps_inv_refl_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶ [d, 1] T2 →
-                        ∀K,V. ⇩[0, d] L ≡ K. ⓛV → T1 = T2.
-#L #T1 #T2 #d #HT12 #K #V #HLK
-lapply (tps_inv_S2 … T1 T2 … 0 … HLK) -K // -HT12 #HT12
-lapply (tps_inv_refl_O2 … HT12) -HT12 //
-qed-.
-
-(* Relocation properties ****************************************************)
-
-(* Basic_1: was: subst1_lift_lt *)
-lemma tps_lift_le: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
-                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
-                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                   dt + et ≤ d →
-                   L ⊢ U1 ▶ [dt, et] U2.
-#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
-[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hdetd
-  lapply (lt_to_le_to_lt … Hidet … Hdetd) -Hdetd #Hid
-  lapply (lift_inv_lref1_lt … H … Hid) -H #H destruct
-  elim (lift_trans_ge … HVW … HWU2 ?) -W // <minus_plus #W #HVW #HWU2
-  elim (ldrop_trans_le … HLK … HKV ?) -K /2 width=2/ #X #HLK #H
-  elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K #Y #_ #HVY
-  >(lift_mono … HVY … HVW) -Y -HVW #H destruct /2 width=4/
-| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
-  @tps_bind [ /2 width=6/ | @IHT12 /2 width=6/ ] (**) (* /3 width=6/ is too slow, arith3 needed to avoid crash *)
-| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
-]
-qed.
-
-lemma tps_lift_be: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
-                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
-                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                   dt ≤ d → d ≤ dt + et →
-                   L ⊢ U1 ▶ [dt, et + e] U2.
-#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
-[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_ #_
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hdtd #_
-  elim (lift_inv_lref1 … H) -H * #Hid #H destruct
-  [ -Hdtd
-    lapply (lt_to_le_to_lt … (dt+et+e) Hidet ?) // -Hidet #Hidete
-    elim (lift_trans_ge … HVW … HWU2 ?) -W // <minus_plus #W #HVW #HWU2
-    elim (ldrop_trans_le … HLK … HKV ?) -K /2 width=2/ #X #HLK #H
-    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K #Y #_ #HVY
-    >(lift_mono … HVY … HVW) -V #H destruct /2 width=4/
-  | -Hdti
-    lapply (transitive_le … Hdtd Hid) -Hdtd #Hdti
-    lapply (lift_trans_be … HVW … HWU2 ? ?) -W // /2 width=1/ >plus_plus_comm_23 #HVU2
-    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=4/
-  ]
-| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdtd #Hddet
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
-  @tps_bind [ /2 width=6/ | @IHT12 [3,4: // | skip |5,6: /2 width=1/ | /2 width=1/ ]
-            ] (**) (* /3 width=6/ is too slow, simplification like tps_lift_le is too slow *)
-| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
-]
-qed.
-
-(* Basic_1: was: subst1_lift_ge *)
-lemma tps_lift_ge: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
-                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
-                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                   d ≤ dt →
-                   L ⊢ U1 ▶ [dt + e, et] U2.
-#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
-[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hddt
-  lapply (transitive_le … Hddt … Hdti) -Hddt #Hid
-  lapply (lift_inv_lref1_ge … H … Hid) -H #H destruct
-  lapply (lift_trans_be … HVW … HWU2 ? ?) -W // /2 width=1/ >plus_plus_comm_23 #HVU2
-  lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=4/
-| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hddt
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
-  @tps_bind [ /2 width=5/ | /3 width=5/ ] (**) (* explicit constructor *)
-| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hddt
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=5/
-]
-qed.
-
-(* Basic_1: was: subst1_gen_lift_lt *)
-lemma tps_inv_lift1_le: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                        dt + et ≤ d →
-                        ∃∃T2. K ⊢ T1 ▶ [dt, et] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
-[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
-  ]
-| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdetd
-  lapply (lt_to_le_to_lt … Hidet … Hdetd) -Hdetd #Hid
-  lapply (lift_inv_lref2_lt … H … Hid) -H #H destruct
-  elim (ldrop_conf_lt … HLK … HLKV ?) -L // #L #U #HKL #_ #HUV
-  elim (lift_trans_le … HUV … HVW ?) -V // >minus_plus <plus_minus_m_m // -Hid /3 width=4/
-| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1 ?) -V1 // #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1 ?) -IHU12 -HTU1 [3: /2 width=1/ |4: @ldrop_skip // |2: skip ] -HLK -Hdetd (**) (* /3 width=5/ is too slow *)
-  /3 width=5/
-| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1 ?) -V1 //
-  elim (IHU12 … HLK … HTU1 ?) -U1 -HLK // /3 width=5/
-]
-qed.
-
-lemma tps_inv_lift1_be: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                        dt ≤ d → d + e ≤ dt + et →
-                        ∃∃T2. K ⊢ T1 ▶ [dt, et - e] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
-[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
-  ]
-| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdtd #Hdedet
-  lapply (le_fwd_plus_plus_ge … Hdtd … Hdedet) #Heet
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ -Hdtd -Hidet
-    lapply (lt_to_le_to_lt … (dt + (et - e)) Hid ?) [ <le_plus_minus /2 width=1/ ] -Hdedet #Hidete
-    elim (ldrop_conf_lt … HLK … HLKV ?) -L // #L #U #HKL #_ #HUV
-    elim (lift_trans_le … HUV … HVW ?) -V // >minus_plus <plus_minus_m_m // -Hid /3 width=4/
-  | -Hdti -Hdedet
-    lapply (transitive_le … (i - e) Hdtd ?) /2 width=1/ -Hdtd #Hdtie
-    elim (le_inv_plus_l … Hid) #Hdie #Hei
-    lapply (ldrop_conf_ge … HLK … HLKV ?) -L // #HKV
-    elim (lift_split … HVW d (i - e + 1) ? ? ?) -HVW [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
-    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O #H
-    @ex2_intro [3: @H | skip | @tps_subst [3,5,6: // |1,2: skip | >commutative_plus >plus_minus // /2 width=1/ ] ] (**) (* explicit constructor, uses monotonic_lt_minus_l *)
-  ]
-| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdtd #Hdedet
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1 ? ?) -V1 // #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1 ? ?) -U1 [5: @ldrop_skip // |2: skip |3: >plus_plus_comm_23 >(plus_plus_comm_23 dt) /2 width=1/ |4: /2 width=1/ ] (**) (* 29s without the rewrites *)
-  /3 width=5/
-| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdtd #Hdedet
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1 ? ?) -V1 //
-  elim (IHU12 … HLK … HTU1 ? ?) -U1 -HLK // /3 width=5/
-]
-qed.
-
-(* Basic_1: was: subst1_gen_lift_ge *)
-lemma tps_inv_lift1_ge: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                        d + e ≤ dt →
-                        ∃∃T2. K ⊢ T1 ▶ [dt - e, et] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
-[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
-  ]
-| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdedt
-  lapply (transitive_le … Hdedt … Hdti) #Hdei
-  elim (le_inv_plus_l … Hdedt) -Hdedt #_ #Hedt
-  elim (le_inv_plus_l … Hdei) #Hdie #Hei
-  lapply (lift_inv_lref2_ge … H … Hdei) -H #H destruct
-  lapply (ldrop_conf_ge … HLK … HLKV ?) -L // #HKV
-  elim (lift_split … HVW d (i - e + 1) ? ? ?) -HVW [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hdei -Hdie
-  #V0 #HV10 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O #H
-  @ex2_intro [3: @H | skip | @tps_subst [5,6: // |1,2: skip | /2 width=1/ | >plus_minus // /2 width=1/ ] ] (**) (* explicit constructor, uses monotonic_lt_minus_l *)
-| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (le_inv_plus_l … Hdetd) #_ #Hedt
-  elim (IHV12 … HLK … HWV1 ?) -V1 // #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1 ?) -U1 [4: @ldrop_skip // |2: skip |3: /2 width=1/ ]
-  <plus_minus // /3 width=5/
-| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1 ?) -V1 //
-  elim (IHU12 … HLK … HTU1 ?) -U1 -HLK // /3 width=5/
-]
-qed.
-
-(* Basic_1: was: subst1_gen_lift_eq *)
-lemma tps_inv_lift1_eq: ∀L,U1,U2,d,e.
-                        L ⊢ U1 ▶ [d, e] U2 → ∀T1. ⇧[d, e] T1 ≡ U1 → U1 = U2.
-#L #U1 #U2 #d #e #H elim H -L -U1 -U2 -d -e
-[ //
-| #L #K #V #W #i #d #e #Hdi #Hide #_ #_ #T1 #H
-  elim (lift_inv_lref2 … H) -H * #H
-  [ lapply (le_to_lt_to_lt … Hdi … H) -Hdi -H #H
-    elim (lt_refl_false … H)
-  | lapply (lt_to_le_to_lt … Hide … H) -Hide -H #H
-    elim (lt_refl_false … H)
-  ]
-| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #X #HX
-  elim (lift_inv_bind2 … HX) -HX #V #T #HV1 #HT1 #H destruct
-  >IHV12 // >IHT12 //
-| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #X #HX
-  elim (lift_inv_flat2 … HX) -HX #V #T #HV1 #HT1 #H destruct
-  >IHV12 // >IHT12 //
-]
-qed.
-(*
-      Theorem subst0_gen_lift_rev_ge: (t1,v,u2,i,h,d:?)
-                                      (subst0 i v t1 (lift h d u2)) ->
-                                      (le (plus d h) i) ->
-                                      (EX u1 | (subst0 (minus i h) v u1 u2) &
-                                               t1 = (lift h d u1)
-                                      ).
-
-
-      Theorem subst0_gen_lift_rev_lelt: (t1,v,u2,i,h,d:?)
-                                        (subst0 i v t1 (lift h d u2)) ->
-                                        (le d i) -> (lt i (plus d h)) ->
-                                        (EX u1 | t1 = (lift (minus (plus d h) (S i)) (S i) u1)).
-*)
-lemma tps_inv_lift1_ge_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                           d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
-                           ∃∃T2. K ⊢ T1 ▶ [d, dt + et - (d + e)] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
-elim (tps_split_up … HU12 (d + e) ? ?) -HU12 // -Hdedet #U #HU1 #HU2
-lapply (tps_weak … HU1 d e ? ?) -HU1 // [ >commutative_plus /2 width=1/ ] -Hddt -Hdtde #HU1
-lapply (tps_inv_lift1_eq … HU1 … HTU1) -HU1 #HU1 destruct
-elim (tps_inv_lift1_ge … HU2 … HLK … HTU1 ?) -U -L // <minus_plus_m_m /2 width=3/
-qed.
-
-lemma tps_inv_lift1_be_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                           dt ≤ d → dt + et ≤ d + e →
-                           ∃∃T2. K ⊢ T1 ▶ [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdetde
-lapply (tps_weak … HU12 dt (d + e - dt) ? ?) -HU12 // /2 width=3/ -Hdetde #HU12
-elim (tps_inv_lift1_be … HU12 … HLK … HTU1 ? ?) -U1 -L // /2 width=3/
-qed.
-
-lemma tps_inv_lift1_le_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
-                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                           dt ≤ d → d ≤ dt + et → dt + et ≤ d + e →
-                           ∃∃T2. K ⊢ T1 ▶ [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hdtd #Hddet #Hdetde
-elim (tps_split_up … HU12 d ? ?) -HU12 // #U #HU1 #HU2
-elim (tps_inv_lift1_le … HU1 … HLK … HTU1 ?) -U1 [2: >commutative_plus /2 width=1/ ] -Hdtd #T #HT1 #HTU
-lapply (tps_weak … HU2 d e ? ?) -HU2 // [ >commutative_plus <plus_minus_m_m // ] -Hddet -Hdetde #HU2
-lapply (tps_inv_lift1_eq … HU2 … HTU) -L #H destruct /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tps_tps.etc
deleted file mode 100644 (file)
index 7e146c2..0000000
+++ /dev/null
@@ -1,132 +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/tps_lift.ma".
-
-(* PARALLEL SUBSTITUTION ON TERMS *******************************************)
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: subst1_confluence_eq *)
-theorem tps_conf_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶ [d1, e1] T1 →
-                     ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 →
-                     ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T2 ▶ [d1, e1] T.
-#L #T0 #T1 #d1 #e1 #H elim H -L -T0 -T1 -d1 -e1
-[ /2 width=3/
-| #L #K1 #V1 #T1 #i0 #d1 #e1 #Hd1 #Hde1 #HLK1 #HVT1 #T2 #d2 #e2 #H
-  elim (tps_inv_lref1 … H) -H
-  [ #HX destruct /3 width=6/
-  | -Hd1 -Hde1 * #K2 #V2 #_ #_ #HLK2 #HVT2
-    lapply (ldrop_mono … HLK1 … HLK2) -HLK1 -HLK2 #H destruct
-    >(lift_mono … HVT1 … HVT2) -HVT1 -HVT2 /2 width=3/
-  ]
-| #L #a #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #X #d2 #e2 #HX
-  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V1) ?) -HT02 /2 width=1/ #HT02
-  elim (IHV01 … HV02) -V0 #V #HV1 #HV2
-  elim (IHT01 … HT02) -T0 #T #HT1 #HT2
-  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/
-  lapply (tps_lsubr_trans … HT2 (L. ⓑ{I} V) ?) -HT2 /3 width=5/
-| #L #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #X #d2 #e2 #HX
-  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  elim (IHV01 … HV02) -V0
-  elim (IHT01 … HT02) -T0 /3 width=5/
-]
-qed.
-
-(* Basic_1: was: subst1_confluence_neq *)
-theorem tps_conf_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶ [d1, e1] T1 →
-                      ∀L2,T2,d2,e2. L2 ⊢ T0 ▶ [d2, e2] T2 →
-                      (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
-                      ∃∃T. L2 ⊢ T1 ▶ [d2, e2] T & L1 ⊢ T2 ▶ [d1, e1] T.
-#L1 #T0 #T1 #d1 #e1 #H elim H -L1 -T0 -T1 -d1 -e1
-[ /2 width=3/
-| #L1 #K1 #V1 #T1 #i0 #d1 #e1 #Hd1 #Hde1 #HLK1 #HVT1 #L2 #T2 #d2 #e2 #H1 #H2
-  elim (tps_inv_lref1 … H1) -H1
-  [ #H destruct /3 width=6/
-  | -HLK1 -HVT1 * #K2 #V2 #Hd2 #Hde2 #_ #_ elim H2 -H2 #Hded
-    [ -Hd1 -Hde2
-      lapply (transitive_le … Hded Hd2) -Hded -Hd2 #H
-      lapply (lt_to_le_to_lt … Hde1 H) -Hde1 -H #H
-      elim (lt_refl_false … H)
-    | -Hd2 -Hde1
-      lapply (transitive_le … Hded Hd1) -Hded -Hd1 #H
-      lapply (lt_to_le_to_lt … Hde2 H) -Hde2 -H #H
-      elim (lt_refl_false … H)
-    ]
-  ]
-| #L1 #a #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #L2 #X #d2 #e2 #HX #H
-  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  elim (IHV01 … HV02 H) -V0 #V #HV1 #HV2
-  elim (IHT01 … HT02 ?) -T0
-  [ -H #T #HT1 #HT2
-    lapply (tps_lsubr_trans … HT1 (L2. ⓑ{I} V) ?) -HT1 /2 width=1/
-    lapply (tps_lsubr_trans … HT2 (L1. ⓑ{I} V) ?) -HT2 /2 width=1/ /3 width=5/
-  | -HV1 -HV2 >plus_plus_comm_23 >plus_plus_comm_23 in ⊢ (? ? %); elim H -H #H
-    [ @or_introl | @or_intror ] /2 by monotonic_le_plus_l/ (**) (* /3 / is too slow *)
-  ]
-| #L1 #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #L2 #X #d2 #e2 #HX #H
-  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  elim (IHV01 … HV02 H) -V0
-  elim (IHT01 … HT02 H) -T0 -H /3 width=5/
-]
-qed.
-
-(* Note: the constant 1 comes from tps_subst *)
-(* Basic_1: was: subst1_trans *)
-theorem tps_trans_ge: ∀L,T1,T0,d,e. L ⊢ T1 ▶ [d, e] T0 →
-                      ∀T2. L ⊢ T0 ▶ [d, 1] T2 → 1 ≤ e →
-                      L ⊢ T1 ▶ [d, e] T2.
-#L #T1 #T0 #d #e #H elim H -L -T1 -T0 -d -e
-[ #L #I #d #e #T2 #H #He
-  elim (tps_inv_atom1 … H) -H
-  [ #H destruct //
-  | * #K #V #i #Hd2i #Hide2 #HLK #HVT2 #H destruct
-    lapply (lt_to_le_to_lt … (d + e) Hide2 ?) /2 width=4/
-  ]
-| #L #K #V #V2 #i #d #e #Hdi #Hide #HLK #HVW #T2 #HVT2 #He
-  lapply (tps_weak … HVT2 0 (i +1) ? ?) -HVT2 /2 width=1/ #HVT2
-  <(tps_inv_lift1_eq … HVT2 … HVW) -HVT2 /2 width=4/
-| #L #a #I #V1 #V0 #T1 #T0 #d #e #_ #_ #IHV10 #IHT10 #X #H #He
-  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV02 #HT02 #H destruct
-  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V0) ?) -HT02 /2 width=1/ #HT02
-  lapply (IHT10 … HT02 He) -T0 #HT12
-  lapply (tps_lsubr_trans … HT12 (L. ⓑ{I} V2) ?) -HT12 /2 width=1/ /3 width=1/
-| #L #I #V1 #V0 #T1 #T0 #d #e #_ #_ #IHV10 #IHT10 #X #H #He
-  elim (tps_inv_flat1 … H) -H #V2 #T2 #HV02 #HT02 #H destruct /3 width=1/
-]
-qed.
-
-theorem tps_trans_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶ [d1, e1] T0 →
-                        ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 → d2 + e2 ≤ d1 →
-                        ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T ▶ [d1, e1] T2.
-#L #T1 #T0 #d1 #e1 #H elim H -L -T1 -T0 -d1 -e1
-[ /2 width=3/
-| #L #K #V #W #i1 #d1 #e1 #Hdi1 #Hide1 #HLK #HVW #T2 #d2 #e2 #HWT2 #Hde2d1
-  lapply (transitive_le … Hde2d1 Hdi1) -Hde2d1 #Hde2i1
-  lapply (tps_weak … HWT2 0 (i1 + 1) ? ?) -HWT2 normalize /2 width=1/ -Hde2i1 #HWT2
-  <(tps_inv_lift1_eq … HWT2 … HVW) -HWT2 /3 width=8/
-| #L #a #I #V1 #V0 #T1 #T0 #d1 #e1 #_ #_ #IHV10 #IHT10 #X #d2 #e2 #HX #de2d1
-  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V0) ?) -HT02 /2 width=1/ #HT02
-  elim (IHV10 … HV02 ?) -IHV10 -HV02 // #V
-  elim (IHT10 … HT02 ?) -T0 /2 width=1/ #T #HT1 #HT2
-  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/
-  lapply (tps_lsubr_trans … HT2 (L. ⓑ{I} V2) ?) -HT2 /2 width=1/ /3 width=6/
-| #L #I #V1 #V0 #T1 #T0 #d1 #e1 #_ #_ #IHV10 #IHT10 #X #d2 #e2 #HX #de2d1
-  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
-  elim (IHV10 … HV02 ?) -V0 //
-  elim (IHT10 … HT02 ?) -T0 // /3 width=6/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss.etc
deleted file mode 100644 (file)
index 4337188..0000000
+++ /dev/null
@@ -1,188 +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 "hvbox( L ⊢ break term 46 T1 break ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStar $L $T1 $d $e $T2 }.
-
-include "basic_2/substitution/tps.ma".
-
-(* PARTIAL UNFOLD ON TERMS **************************************************)
-
-definition tpss: nat → nat → lenv → relation term ≝
-                 λd,e,L. TC … (tps d e L).
-
-interpretation "partial unfold (term)"
-   'PSubstStar L T1 d e T2 = (tpss d e L T1 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma tpss_ind: ∀d,e,L,T1. ∀R:predicate term. R T1 →
-                (∀T,T2. L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶ [d, e] T2 → R T → R T2) →
-                ∀T2. L ⊢ T1 ▶* [d, e] T2 → R T2.
-#d #e #L #T1 #R #HT1 #IHT1 #T2 #HT12
-@(TC_star_ind … HT1 IHT1 … HT12) //
-qed-.
-
-lemma tpss_ind_dx: ∀d,e,L,T2. ∀R:predicate term. R T2 →
-                   (∀T1,T. L ⊢ T1 ▶ [d, e] T → L ⊢ T ▶* [d, e] T2 → R T → R T1) →
-                   ∀T1. L ⊢ T1 ▶* [d, e] T2 → R T1.
-#d #e #L #T2 #R #HT2 #IHT2 #T1 #HT12
-@(TC_star_ind_dx … HT2 IHT2 … HT12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma tps_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
-/2 width=1/ qed.
-
-lemma tpss_strap1: ∀L,T1,T,T2,d,e.
-                   L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
-/2 width=3/ qed.
-
-lemma tpss_strap2: ∀L,T1,T,T2,d,e.
-                   L ⊢ T1 ▶ [d, e] T → L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
-/2 width=3/ qed.
-
-lemma tpss_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶* [d, e] T2 →
-                        ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶* [d, e] T2.
-/3 width=3/ qed.
-
-lemma tpss_refl: ∀d,e,L,T. L ⊢ T ▶* [d, e] T.
-/2 width=1/ qed.
-
-lemma tpss_bind: ∀L,V1,V2,d,e. L ⊢ V1 ▶* [d, e] V2 →
-                 ∀a,I,T1,T2. L. ⓑ{I} V2 ⊢ T1 ▶* [d + 1, e] T2 →
-                 L ⊢ ⓑ{a,I} V1. T1 ▶* [d, e] ⓑ{a,I} V2. T2.
-#L #V1 #V2 #d #e #HV12 elim HV12 -V2
-[ #V2 #HV12 #a #I #T1 #T2 #HT12 elim HT12 -T2
-  [ /3 width=5/
-  | #T #T2 #_ #HT2 #IHT @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
-  ]
-| #V #V2 #_ #HV12 #IHV #a #I #T1 #T2 #HT12
-  lapply (tpss_lsubr_trans … HT12 (L. ⓑ{I} V) ?) -HT12 /2 width=1/ #HT12
-  lapply (IHV a … HT12) -IHV -HT12 #HT12 @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
-]
-qed.
-
-lemma tpss_flat: ∀L,I,V1,V2,T1,T2,d,e.
-                 L ⊢ V1 ▶* [d, e] V2 → L ⊢ T1 ▶* [d, e] T2 →
-                 L ⊢ ⓕ{I} V1. T1 ▶* [d, e] ⓕ{I} V2. T2.
-#L #I #V1 #V2 #T1 #T2 #d #e #HV12 elim HV12 -V2
-[ #V2 #HV12 #HT12 elim HT12 -T2
-  [ /3 width=1/
-  | #T #T2 #_ #HT2 #IHT @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
-  ]
-| #V #V2 #_ #HV12 #IHV #HT12
-  lapply (IHV … HT12) -IHV -HT12 #HT12 @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
-]
-qed.
-
-lemma tpss_weak: ∀L,T1,T2,d1,e1. L ⊢ T1 ▶* [d1, e1] T2 →
-                 ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 →
-                 L ⊢ T1 ▶* [d2, e2] T2.
-#L #T1 #T2 #d1 #e1 #H #d1 #d2 #Hd21 #Hde12 @(tpss_ind … H) -T2
-[ //
-| #T #T2 #_ #HT12 #IHT
-  lapply (tps_weak … HT12 … Hd21 Hde12) -HT12 -Hd21 -Hde12 /2 width=3/
-]
-qed.
-
-lemma tpss_weak_top: ∀L,T1,T2,d,e.
-                     L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶* [d, |L| - d] T2.
-#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2
-[ //
-| #T #T2 #_ #HT12 #IHT
-  lapply (tps_weak_top … HT12) -HT12 /2 width=3/
-]
-qed.
-
-lemma tpss_weak_full: ∀L,T1,T2,d,e.
-                      L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶* [0, |L|] T2.
-#L #T1 #T2 #d #e #HT12
-lapply (tpss_weak … HT12 0 (d + e) ? ?) -HT12 // #HT12
-lapply (tpss_weak_top … HT12) //
-qed.
-
-lemma tpss_append: ∀K,T1,T2,d,e. K ⊢ T1 ▶* [d, e] T2 →
-                   ∀L. L @@ K ⊢ T1 ▶* [d, e] T2.
-#K #T1 #T2 #d #e #H @(tpss_ind … H) -T2 // /3 width=3/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-(* Note: this can be derived from tpss_inv_atom1 *)
-lemma tpss_inv_sort1: ∀L,T2,k,d,e. L ⊢ ⋆k ▶* [d, e] T2 → T2 = ⋆k.
-#L #T2 #k #d #e #H @(tpss_ind … H) -T2
-[ //
-| #T #T2 #_ #HT2 #IHT destruct
-  >(tps_inv_sort1 … HT2) -HT2 //
-]
-qed-.
-
-(* Note: this can be derived from tpss_inv_atom1 *)
-lemma tpss_inv_gref1: ∀L,T2,p,d,e. L ⊢ §p ▶* [d, e] T2 → T2 = §p.
-#L #T2 #p #d #e #H @(tpss_ind … H) -T2
-[ //
-| #T #T2 #_ #HT2 #IHT destruct
-  >(tps_inv_gref1 … HT2) -HT2 //
-]
-qed-.
-
-lemma tpss_inv_bind1: ∀d,e,L,a,I,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶* [d, e] U2 →
-                      ∃∃V2,T2. L ⊢ V1 ▶* [d, e] V2 &
-                               L. ⓑ{I} V2 ⊢ T1 ▶* [d + 1, e] T2 &
-                               U2 = ⓑ{a,I} V2. T2.
-#d #e #L #a #I #V1 #T1 #U2 #H @(tpss_ind … H) -U2
-[ /2 width=5/
-| #U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
-  elim (tps_inv_bind1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H
-  lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V2) ?) -HT1 /2 width=1/ /3 width=5/
-]
-qed-.
-
-lemma tpss_inv_flat1: ∀d,e,L,I,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶* [d, e] U2 →
-                      ∃∃V2,T2. L ⊢ V1 ▶* [d, e] V2 & L ⊢ T1 ▶* [d, e] T2 &
-                               U2 =  ⓕ{I} V2. T2.
-#d #e #L #I #V1 #T1 #U2 #H @(tpss_ind … H) -U2
-[ /2 width=5/
-| #U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
-  elim (tps_inv_flat1 … HU2) -HU2 /3 width=5/
-]
-qed-.
-
-lemma tpss_inv_refl_O2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 0] T2 → T1 = T2.
-#L #T1 #T2 #d #H @(tpss_ind … H) -T2
-[ //
-| #T #T2 #_ #HT2 #IHT <(tps_inv_refl_O2 … HT2) -HT2 //
-]
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma tpss_fwd_tw: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ♯{T1} ≤ ♯{T2}.
-#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT1
-lapply (tps_fwd_tw … HT2) -HT2 #HT2
-@(transitive_le … IHT1) //
-qed-.
-
-lemma tpss_fwd_shift1: ∀L,L1,T1,T,d,e. L ⊢ L1 @@ T1 ▶*[d, e] T →
-                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#L #L1 #T1 #T #d #e #H @(tpss_ind … H) -T
-[ /2 width=4/
-| #T #X #_ #H0 * #L0 #T0 #HL10 #H destruct
-  elim (tps_fwd_shift1 … H0) -H0 #L2 #T2 #HL02 #H destruct /2 width=4/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_alt.etc
deleted file mode 100644 (file)
index f7670ea..0000000
+++ /dev/null
@@ -1,105 +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 "hvbox( L ⊢ break term 46 T1 break ▶ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStarAlt $L $T1 $d $e $T2 }.
-
-include "basic_2/unfold/tpss_lift.ma".
-
-(* PARALLEL UNFOLD ON TERMS *************************************************)
-
-(* alternative definition of tpss *)
-inductive tpssa: nat → nat → lenv → relation term ≝
-| tpssa_atom : ∀L,I,d,e. tpssa d e L (⓪{I}) (⓪{I})
-| tpssa_subst: ∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
-               ⇩[0, i] L ≡ K. ⓓV1 → tpssa 0 (d + e - i - 1) K V1 V2 →
-               ⇧[0, i + 1] V2 ≡ W2 → tpssa d e L (#i) W2
-| tpssa_bind : ∀L,a,I,V1,V2,T1,T2,d,e.
-               tpssa d e L V1 V2 → tpssa (d + 1) e (L. ⓑ{I} V2) T1 T2 →
-               tpssa d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| tpssa_flat : ∀L,I,V1,V2,T1,T2,d,e.
-               tpssa d e L V1 V2 → tpssa d e L T1 T2 →
-               tpssa d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-.
-
-interpretation "parallel unfold (term) alternative"
-   'PSubstStarAlt L T1 d e T2 = (tpssa d e L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma tpssa_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶▶* [d, e] T2 →
-                         ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶▶* [d, e] T2.
-#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
-[ //
-| #L1 #K1 #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /3 width=6/
-| /4 width=1/
-| /3 width=1/
-]
-qed.
-
-lemma tpssa_refl: ∀T,L,d,e. L ⊢ T ▶▶* [d, e] T.
-#T elim T -T //
-#I elim I -I /2 width=1/
-qed.
-
-lemma tpssa_tps_trans: ∀L,T1,T,d,e. L ⊢ T1 ▶▶* [d, e] T →
-                       ∀T2. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ▶▶* [d, e] T2.
-#L #T1 #T #d #e #H elim H -L -T1 -T -d -e
-[ #L #I #d #e #X #H
-  elim (tps_inv_atom1 … H) -H // * /2 width=6/
-| #L #K #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK #_ #HVW2 #IHV12 #T2 #H
-  lapply (ldrop_fwd_ldrop2 … HLK) #H0LK
-  lapply (tps_weak … H 0 (d+e) ? ?) -H // #H
-  elim (tps_inv_lift1_be … H … H0LK … HVW2 ? ?) -H -H0LK -HVW2 // /3 width=6/
-| #L #a #I #V1 #V #T1 #T #d #e #_ #_ #IHV1 #IHT1 #X #H
-  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV2 #HT2 #H destruct
-  lapply (tps_lsubr_trans … HT2 (L.ⓑ{I}V) ?) -HT2 /2 width=1/ #HT2
-  lapply (IHV1 … HV2) -IHV1 -HV2 #HV12
-  lapply (IHT1 … HT2) -IHT1 -HT2 #HT12
-  lapply (tpssa_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/
-| #L #I #V1 #V #T1 #T #d #e #_ #_ #IHV1 #IHT1 #X #H
-  elim (tps_inv_flat1 … H) -H #V2 #T2 #HV2 #HT2 #H destruct /3 width=1/
-]
-qed.
-
-lemma tpss_tpssa: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶▶* [d, e] T2.
-#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 // /2 width=3/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma tpssa_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶▶* [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e // /2 width=6/
-qed-.
-
-lemma tpss_ind_alt: ∀R:nat→nat→lenv→relation term.
-                    (∀L,I,d,e. R d e L (⓪{I}) (⓪{I})) →
-                    (∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
-                     ⇩[O, i] L ≡ K.ⓓV1 → K ⊢ V1 ▶* [O, d + e - i - 1] V2 →
-                     ⇧[O, i + 1] V2 ≡ W2 → R O (d+e-i-1) K V1 V2 → R d e L (#i) W2
-                    ) →
-                    (∀L,a,I,V1,V2,T1,T2,d,e. L ⊢ V1 ▶* [d, e] V2 →
-                     L.ⓑ{I}V2 ⊢ T1 ▶* [d + 1, e] T2 → R d e L V1 V2 →
-                     R (d+1) e (L.ⓑ{I}V2) T1 T2 → R d e L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
-                    ) →
-                    (∀L,I,V1,V2,T1,T2,d,e. L ⊢ V1 ▶* [d, e] V2 →
-                     L ⊢ T1 ▶* [d, e] T2 → R d e L V1 V2 →
-                     R d e L T1 T2 → R d e L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
-                    ) →
-                    ∀d,e,L,T1,T2. L ⊢ T1 ▶* [d, e] T2 → R d e L T1 T2.
-#R #H1 #H2 #H3 #H4 #d #e #L #T1 #T2 #H elim (tpss_tpssa … H) -L -T1 -T2 -d -e
-// /3 width=1 by tpssa_tpss/ /3 width=7 by tpssa_tpss/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_lift.etc
deleted file mode 100644 (file)
index a68f86e..0000000
+++ /dev/null
@@ -1,196 +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/tps_lift.ma".
-include "basic_2/unfold/tpss.ma".
-
-(* PARTIAL UNFOLD ON TERMS **************************************************)
-
-(* Advanced properties ******************************************************)
-
-lemma tpss_subst: ∀L,K,V,U1,i,d,e.
-                  d ≤ i → i < d + e →
-                  ⇩[0, i] L ≡ K. ⓓV → K ⊢ V ▶* [0, d + e - i - 1] U1 →
-                  ∀U2. ⇧[0, i + 1] U1 ≡ U2 → L ⊢ #i ▶* [d, e] U2.
-#L #K #V #U1 #i #d #e #Hdi #Hide #HLK #H @(tpss_ind … H) -U1
-[ /3 width=4/
-| #U #U1 #_ #HU1 #IHU #U2 #HU12
-  elim (lift_total U 0 (i+1)) #U0 #HU0
-  lapply (IHU … HU0) -IHU #H
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  lapply (tps_lift_ge … HU1 … HLK HU0 HU12 ?) -HU1 -HLK -HU0 -HU12 // normalize #HU02
-  lapply (tps_weak … HU02 d e ? ?) -HU02 [ >minus_plus >commutative_plus /2 width=1/ | /2 width=1/ | /2 width=3/ ]
-]
-qed.
-
-(* Advanced inverion lemmas *************************************************)
-
-lemma tpss_inv_atom1: ∀L,T2,I,d,e. L ⊢ ⓪{I} ▶* [d, e] T2 →
-                      T2 = ⓪{I} ∨
-                      ∃∃K,V1,V2,i. d ≤ i & i < d + e &
-                                   ⇩[O, i] L ≡ K. ⓓV1 &
-                                   K ⊢ V1 ▶* [0, d + e - i - 1] V2 &
-                                   ⇧[O, i + 1] V2 ≡ T2 &
-                                   I = LRef i.
-#L #T2 #I #d #e #H @(tpss_ind … H) -T2
-[ /2 width=1/
-| #T #T2 #_ #HT2 *
-  [ #H destruct
-    elim (tps_inv_atom1 … HT2) -HT2 [ /2 width=1/ | * /3 width=10/ ]
-  | * #K #V1 #V #i #Hdi #Hide #HLK #HV1 #HVT #HI
-    lapply (ldrop_fwd_ldrop2 … HLK) #H
-    elim (tps_inv_lift1_ge_up … HT2 … H … HVT ? ? ?) normalize -HT2 -H -HVT [2,3,4: /2 width=1/ ] #V2 <minus_plus #HV2 #HVT2
-    @or_intror @(ex6_4_intro … Hdi Hide HLK … HVT2 HI) /2 width=3/ (**) (* /4 width=10/ is too slow *)
-  ]
-]
-qed-.
-
-lemma tpss_inv_lref1: ∀L,T2,i,d,e. L ⊢ #i ▶* [d, e] T2 →
-                      T2 = #i ∨
-                      ∃∃K,V1,V2. d ≤ i & i < d + e &
-                                 ⇩[O, i] L ≡ K. ⓓV1 &
-                                 K ⊢ V1 ▶* [0, d + e - i - 1] V2 &
-                                 ⇧[O, i + 1] V2 ≡ T2.
-#L #T2 #i #d #e #H
-elim (tpss_inv_atom1 … H) -H /2 width=1/
-* #K #V1 #V2 #j #Hdj #Hjde #HLK #HV12 #HVT2 #H destruct /3 width=6/
-qed-.
-
-lemma tpss_inv_S2: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e + 1] T2 →
-                   ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶* [d + 1, e] T2.
-#L #T1 #T2 #d #e #H #K #V #HLK @(tpss_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT
-lapply (tps_inv_S2 … HT2 … HLK) -HT2 -HLK /2 width=3/
-qed-.
-
-lemma tpss_inv_refl_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 1] T2 →
-                         ∀K,V. ⇩[0, d] L ≡ K. ⓛV → T1 = T2.
-#L #T1 #T2 #d #H #K #V #HLK @(tpss_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT <(tps_inv_refl_SO2 … HT2 … HLK) //
-qed-.
-
-(* Relocation properties ****************************************************)
-
-lemma tpss_lift_le: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
-                    ∀L,U1,d,e. dt + et ≤ d → ⇩[d, e] L ≡ K →
-                    ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
-                    L ⊢ U1 ▶* [dt, et] U2.
-#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hdetd #HLK #HTU1 @(tpss_ind … H) -T2
-[ #U2 #H >(lift_mono … HTU1 … H) -H //
-| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
-  elim (lift_total T d e) #U #HTU
-  lapply (IHT … HTU) -IHT #HU1
-  lapply (tps_lift_le … HT2 … HLK HTU HTU2 ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
-]
-qed.
-
-lemma tpss_lift_be: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
-                    ∀L,U1,d,e. dt ≤ d → d ≤ dt + et →
-                    ⇩[d, e] L ≡ K → ⇧[d, e] T1 ≡ U1 →
-                    ∀U2. ⇧[d, e] T2 ≡ U2 → L ⊢ U1 ▶* [dt, et + e] U2.
-#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hdtd #Hddet #HLK #HTU1 @(tpss_ind … H) -T2
-[ #U2 #H >(lift_mono … HTU1 … H) -H //
-| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
-  elim (lift_total T d e) #U #HTU
-  lapply (IHT … HTU) -IHT #HU1
-  lapply (tps_lift_be … HT2 … HLK HTU HTU2 ? ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
-]
-qed.
-
-lemma tpss_lift_ge: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
-                    ∀L,U1,d,e. d ≤ dt → ⇩[d, e] L ≡ K →
-                    ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
-                    L ⊢ U1 ▶* [dt + e, et] U2.
-#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hddt #HLK #HTU1 @(tpss_ind … H) -T2
-[ #U2 #H >(lift_mono … HTU1 … H) -H //
-| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
-  elim (lift_total T d e) #U #HTU
-  lapply (IHT … HTU) -IHT #HU1
-  lapply (tps_lift_ge … HT2 … HLK HTU HTU2 ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_le: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         dt + et ≤ d →
-                         ∃∃T2. K ⊢ T1 ▶* [dt, et] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdetd @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_le … HU2 … HLK … HTU ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_be: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         dt ≤ d → d + e ≤ dt + et →
-                         ∃∃T2. K ⊢ T1 ▶* [dt, et - e] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdedet @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_be … HU2 … HLK … HTU ? ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_ge: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         d + e ≤ dt →
-                         ∃∃T2. K ⊢ T1 ▶* [dt - e, et] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdedt @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_ge … HU2 … HLK … HTU ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_eq: ∀L,U1,U2,d,e.
-                         L ⊢ U1 ▶* [d, e] U2 → ∀T1. ⇧[d, e] T1 ≡ U1 → U1 = U2.
-#L #U1 #U2 #d #e #H #T1 #HTU1 @(tpss_ind … H) -U2 //
-#U #U2 #_ #HU2 #IHU destruct
-<(tps_inv_lift1_eq … HU2 … HTU1) -HU2 -HTU1 //
-qed.
-
-lemma tpss_inv_lift1_ge_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                            d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
-                            ∃∃T2. K ⊢ T1 ▶* [d, dt + et - (d + e)] T2 &
-                                 ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_ge_up … HU2 … HLK … HTU ? ? ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_be_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                            dt ≤ d → dt + et ≤ d + e →
-                            ∃∃T2. K ⊢ T1 ▶* [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdetde @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_be_up … HU2 … HLK … HTU ? ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
-
-lemma tpss_inv_lift1_le_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                            dt ≤ d → d ≤ dt + et → dt + et ≤ d + e →
-                            ∃∃T2. K ⊢ T1 ▶* [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hddet #Hdetde @(tpss_ind … H) -U2
-[ /2 width=3/
-| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
-  elim (tps_inv_lift1_le_up … HU2 … HLK … HTU ? ? ?) -HU2 -HLK -HTU // /3 width=3/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpr/tpss_tpss.etc
deleted file mode 100644 (file)
index d124bb3..0000000
+++ /dev/null
@@ -1,96 +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/tps_tps.ma".
-include "basic_2/unfold/tpss_lift.ma".
-
-(* PARTIAL UNFOLD ON TERMS **************************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma tpss_inv_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 1] T2 → L ⊢ T1 ▶ [d, 1] T2.
-#L #T1 #T2 #d #H @(tpss_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT1
-lapply (tps_trans_ge … IHT1 … HT2 ?) //
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma tpss_strip_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶* [d1, e1] T1 →
-                     ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 →
-                     ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T2 ▶* [d1, e1] T.
-/3 width=3/ qed.
-
-lemma tpss_strip_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶* [d1, e1] T1 →
-                      ∀L2,T2,d2,e2. L2 ⊢ T0 ▶ [d2, e2] T2 →
-                      (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
-                      ∃∃T. L2 ⊢ T1 ▶ [d2, e2] T & L1 ⊢ T2 ▶* [d1, e1] T.
-/3 width=3/ qed.
-
-lemma tpss_strap1_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶* [d1, e1] T0 →
-                        ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 → d2 + e2 ≤ d1 →
-                        ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T ▶* [d1, e1] T2.
-/3 width=3/ qed.
-
-lemma tpss_strap2_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶ [d1, e1] T0 →
-                        ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 → d2 + e2 ≤ d1 →
-                        ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T ▶ [d1, e1] T2.
-/3 width=3/ qed.
-
-lemma tpss_split_up: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
-                     ∀i. d ≤ i → i ≤ d + e →
-                     ∃∃T. L ⊢ T1 ▶* [d, i - d] T & L ⊢ T ▶* [i, d + e - i] T2.
-#L #T1 #T2 #d #e #H #i #Hdi #Hide @(tpss_ind … H) -T2
-[ /2 width=3/
-| #T #T2 #_ #HT12 * #T3 #HT13 #HT3
-  elim (tps_split_up … HT12 … Hdi Hide) -HT12 -Hide #T0 #HT0 #HT02
-  elim (tpss_strap1_down … HT3 … HT0 ?) -T [2: >commutative_plus /2 width=1/ ]
-  /3 width=7 by ex2_intro, step/ (**) (* just /3 width=7/ is too slow *)
-]
-qed.
-
-lemma tpss_inv_lift1_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
-                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
-                         d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
-                         ∃∃T2. K ⊢ T1 ▶* [d, dt + et - (d + e)] T2 &
-                               ⇧[d, e] T2 ≡ U2.
-#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
-elim (tpss_split_up … HU12 (d + e) ? ?) -HU12 // -Hdedet #U #HU1 #HU2
-lapply (tpss_weak … HU1 d e ? ?) -HU1 // [ >commutative_plus /2 width=1/ ] -Hddt -Hdtde #HU1
-lapply (tpss_inv_lift1_eq … HU1 … HTU1) -HU1 #HU1 destruct
-elim (tpss_inv_lift1_ge … HU2 … HLK … HTU1 ?) -HU2 -HLK -HTU1 // <minus_plus_m_m /2 width=3/
-qed.
-
-(* Main properties **********************************************************)
-
-theorem tpss_conf_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶* [d1, e1] T1 →
-                      ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 →
-                      ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T2 ▶* [d1, e1] T.
-/3 width=3/ qed.
-
-theorem tpss_conf_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶* [d1, e1] T1 →
-                       ∀L2,T2,d2,e2. L2 ⊢ T0 ▶* [d2, e2] T2 →
-                       (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
-                       ∃∃T. L2 ⊢ T1 ▶* [d2, e2] T & L1 ⊢ T2 ▶* [d1, e1] T.
-/3 width=3/ qed.
-
-theorem tpss_trans_eq: ∀L,T1,T,T2,d,e.
-                       L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶* [d, e] T2 →
-                       L ⊢ T1 ▶* [d, e] T2.
-/2 width=3/ qed.
-
-theorem tpss_trans_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶* [d1, e1] T0 →
-                         ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 → d2 + e2 ≤ d1 →
-                         ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T ▶* [d1, e1] T2.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys.etc
deleted file mode 100644 (file)
index b3b5bc6..0000000
+++ /dev/null
@@ -1,177 +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/psubststar_4.ma".
-include "basic_2/grammar/genv.ma".
-include "basic_2/substitution/lsuby.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
-
-(* avtivate genv *)
-inductive cpys: relation4 genv lenv term term ≝
-| cpys_atom : ∀I,G,L. cpys G L (⓪{I}) (⓪{I})
-| cpys_delta: ∀I,G,L,K,V,V2,W2,i.
-              ⇩[i] L ≡ K.ⓑ{I}V → cpys G K V V2 →
-              ⇧[0, i + 1] V2 ≡ W2 → cpys G L (#i) W2
-| cpys_bind : ∀a,I,G,L,V1,V2,T1,T2.
-              cpys G L V1 V2 → cpys G (L.ⓑ{I}V1) T1 T2 →
-              cpys G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
-| cpys_flat : ∀I,G,L,V1,V2,T1,T2.
-              cpys G L V1 V2 → cpys G L T1 T2 →
-              cpys G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
-.
-
-interpretation
-   "context-sensitive extended multiple substitution (term)"
-   'PSubstStar G L T1 T2 = (cpys G L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma lsuby_cpys_trans: ∀G. lsub_trans … (cpys G) lsuby.
-#G #L1 #T1 #T2 #H elim H -G -L1 -T1 -T2
-[ //
-| #I #G #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (lsuby_ldrop_trans … HL12 … HLK1) -HL12 -HLK1 *
-  /3 width=7 by cpys_delta/
-| /4 width=1 by lsuby_pair, cpys_bind/
-| /3 width=1 by cpys_flat/
-]
-qed-.
-
-(* Note: this is "∀L. reflexive … (cpys L)" *)
-lemma cpys_refl: ∀G,T,L. ⦃G, L⦄ ⊢ T ▶* T.
-#G #T elim T -T // * /2 width=1 by cpys_bind, cpys_flat/
-qed.
-
-lemma cpys_pair_sn: ∀I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ▶* V2 →
-                    ∀T. ⦃G, L⦄ ⊢ ②{I}V1.T ▶* ②{I}V2.T.
-* /2 width=1 by cpys_bind, cpys_flat/
-qed.
-
-lemma cpys_bind_ext: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ▶* V2 →
-                     ∀J,T1,T2. ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 →
-                     ∀a,I. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* ⓑ{a,I}V2.T2.
-/4 width=4 by lsuby_cpys_trans, cpys_bind, lsuby_pair/ qed.
-
-lemma cpys_delift: ∀I,G,K,V,T1,L,d. ⇩[d] L ≡ (K.ⓑ{I}V) →
-                   ∃∃T2,T.  ⦃G, L⦄ ⊢ T1 ▶* T2 & ⇧[d, 1] T ≡ T2.
-#I #G #K #V #T1 elim T1 -T1
-[ * /2 width=4 by cpys_atom, lift_sort, lift_gref, ex2_2_intro/
-  #i #L #d elim (lt_or_eq_or_gt i d) #Hid [1,3: /3 width=4 by cpys_atom, lift_lref_ge_minus, lift_lref_lt, ex2_2_intro/ ]
-  destruct
-  elim (lift_total V 0 (i+1)) #W #HVW
-  elim (lift_split … HVW i i) /3 width=7 by cpys_delta, ex2_2_intro/
-| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
-  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
-  [ elim (IHU1 (L. ⓑ{I}W1) (d+1)) -IHU1 /3 width=9 by cpys_bind, ldrop_drop, lift_bind, ex2_2_intro/
-  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8 by cpys_flat, lift_flat, ex2_2_intro/
-  ]
-]
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact cpys_inv_atom1_aux: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶* T2 → ∀J. T1 = ⓪{J} →
-                         T2 = ⓪{J} ∨
-                         ∃∃I,K,V,V2,i. ⇩[i] L ≡ K.ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
-                                       ⇧[O, i + 1] V2 ≡ T2 & J = LRef i.
-#G #L #T1 #T2 * -L -T1 -T2
-[ #I #G #L #J #H destruct /2 width=1 by or_introl/
-| #I #G #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #J #H destruct /3 width=9 by ex4_5_intro, or_intror/
-| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-]
-qed-.
-
-lemma cpys_inv_atom1: ∀J,G,L,T2. ⦃G, L⦄ ⊢ ⓪{J} ▶* T2 →
-                      T2 = ⓪{J} ∨
-                      ∃∃I,K,V,V2,i. ⇩[i] L ≡ K.ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
-                                    ⇧[O, i + 1] V2 ≡ T2 & J = LRef i.
-/2 width=3 by cpys_inv_atom1_aux/ qed-.
-
-lemma cpys_inv_sort1: ∀G,L,T2,k. ⦃G, L⦄ ⊢ ⋆k ▶* T2 → T2 = ⋆k.
-#G #L #T2 #k #H elim (cpys_inv_atom1 … H) -H // *
-#I #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-lemma cpys_inv_lref1: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ▶* T2 →
-                      T2 = #i ∨
-                      ∃∃I,K,V,V2. ⇩[i] L ≡ K. ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
-                                  ⇧[O, i + 1] V2 ≡ T2.
-#G #L #T2 #i #H elim (cpys_inv_atom1 … H) -H /2 width=1 by or_introl/ *
-#I #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=7 by ex3_4_intro, or_intror/
-qed-.
-
-lemma cpys_inv_lref1_ge: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ▶* T2 → |L| ≤ i → T2 = #i.
-#G #L #T2 #i #H elim (cpys_inv_lref1 … H) -H // *
-#I #K #V1 #V2 #HLK #_ #_ #HL -V2 lapply (ldrop_fwd_length_lt2 … HLK) -K -I -V1
-#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
-qed-.
-
-lemma cpys_inv_gref1: ∀G,L,T2,p.  ⦃G, L⦄ ⊢ §p ▶* T2 → T2 = §p.
-#G #L #T2 #p #H elim (cpys_inv_atom1 … H) -H // *
-#I #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-fact cpys_inv_bind1_aux: ∀G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ▶* U2 →
-                         ∀a,J,V1,T1. U1 = ⓑ{a,J}V1.T1 →
-                         ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 &
-                                  U2 = ⓑ{a,J}V2.T2.
-#G #L #U1 #U2 * -L -U1 -U2
-[ #I #G #L #b #J #W #U1 #H destruct
-| #I #G #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W #U1 #H destruct
-| #a #I #G #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W #U1 #H destruct /2 width=5 by ex3_2_intro/
-| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W #U1 #H destruct
-]
-qed-.
-
-lemma cpys_inv_bind1: ∀a,I,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* U2 →
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶* T2 &
-                               U2 = ⓑ{a,I}V2.T2.
-/2 width=3 by cpys_inv_bind1_aux/ qed-.
-
-lemma cpys_inv_bind1_ext: ∀a,I,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* U2 → ∀J.
-                          ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 &
-                                   U2 = ⓑ{a,I}V2.T2.
-#a #I #G #L #V1 #T1 #U2 #H #J elim (cpys_inv_bind1 … H) -H
-#V2 #T2 #HV12 #HT12 #H destruct
-/4 width=5 by lsuby_cpys_trans, lsuby_pair, ex3_2_intro/
-qed-.
-
-fact cpys_inv_flat1_aux: ∀G,L,U,U2. ⦃G, L⦄ ⊢ U ▶* U2 →
-                         ∀J,V1,U1. U = ⓕ{J}V1.U1 →
-                         ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L⦄ ⊢ U1 ▶* T2 &
-                                  U2 = ⓕ{J}V2.T2.
-#G #L #U #U2 * -L -U -U2
-[ #I #G #L #J #W #U1 #H destruct
-| #I #G #L #K #V #V2 #W2 #i #_ #_ #_ #J #W #U1 #H destruct
-| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #W #U1 #H destruct
-| #I #G #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W #U1 #H destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-(* Note: lemma 1250 *)
-lemma cpys_inv_flat1: ∀I,G,L,V1,U1,U2. ⦃G, L⦄ ⊢ ⓕ{I}V1.U1 ▶* U2 →
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L⦄ ⊢ U1 ▶* T2 &
-                               U2 = ⓕ{I}V2.T2.
-/2 width=3 by cpys_inv_flat1_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma cpys_fwd_bind1: ∀a,I,G,L,V1,T1,T. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* T → ∀b,J.
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ ⓑ{b,J}V1.T1 ▶* ⓑ{b,J}V2.T2 &
-                               T = ⓑ{a,I}V2.T2.
-#a #I #G #L #V1 #T1 #T #H #b #J elim (cpys_inv_bind1_ext … H J) -H
-#V2 #T2 #HV12 #HT12 #H destruct /3 width=4 by cpys_bind, ex2_2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_cpys.etc
deleted file mode 100644 (file)
index 7f423f6..0000000
+++ /dev/null
@@ -1,72 +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_lpx_sn.ma".
-include "basic_2/substitution/fqup.ma".
-include "basic_2/substitution/lpys_ldrop.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
-
-(* Main properties **********************************************************)
-
-theorem cpys_antisym: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶* T2 → ⦃G, L⦄ ⊢ T2 ▶* T1 → T1 = T2.
-#G #L #T1 #T2 #H elim H -G -L -T1 -T2 //
-[ #I #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #_ #HW2 lapply (ldrop_fwd_drop2 … HLK) -I -V1
-  #HLK elim (cpys_inv_lift1 … HW2 … HLK … HVW2) -L -HVW2
-  #X #H #_ elim (lift_inv_lref2_be … H) -G -K -V2 -W2 -X //
-| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #H elim (cpys_inv_bind1 … H) -H
-  #V #T #HV2 #HT2 #H destruct
-  lapply (IHV12 HV2) #H destruct -IHV12 -HV2 /3 width=1 by eq_f2/
-| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #H elim (cpys_inv_flat1 … H) -H
-  #V #T #HV2 #HT2 #H destruct /3 width=1 by eq_f2/
-]
-qed-.
-
-theorem cpys_trans_lpys: ∀G. lpx_sn_transitive (cpys G) (cpys G).
-#G0 #L0 #T0 @(fqup_wf_ind_eq … G0 L0 T0) -G0 -L0 -T0 #G0 #L0 #T0 #IH #G1 #L1 * [|*]
-[ #I #HG #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
-  elim (cpys_inv_atom1 … H1) -H1
-  [ #H destruct
-    elim (cpys_inv_atom1 … HT2) -HT2
-    [ #H destruct //
-    | * #I2 #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
-      elim (lpys_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
-      elim (lpys_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
-      lapply (fqup_lref … G1 … HLK1) /3 width=10 by cpys_delta/
-    ]
-  | * #I1 #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
-    elim (lpys_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-    elim (lpys_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
-    elim (cpys_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
-    lapply (fqup_lref … G1 … HLK1) /3 width=10 by cpys_delta/
-  ]
-| #a #I #V1 #T1 #HG #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpys_inv_bind1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
-  elim (cpys_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-  /4 width=5 by cpys_bind, lpys_pair/
-| #I #V1 #T1 #HG #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpys_inv_flat1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
-  elim (cpys_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
-  /3 width=5 by cpys_flat/
-]
-qed-.
-
-theorem cpys_trans: ∀G,L. Transitive … (cpys G L).
-/2 width=5 by cpys_trans_lpys/ qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lpys_cpys_trans: ∀G. lsub_trans … (cpys G) (lpys G).
-/2 width=5 by cpys_trans_lpys/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/cpys_lift.etc
deleted file mode 100644 (file)
index f435a86..0000000
+++ /dev/null
@@ -1,176 +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/substitution/fqus_alt.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
-
-(* Relocation properties ****************************************************)
-
-lemma cpys_lift: ∀G. l_liftable (cpys G).
-#G #K #T1 #T2 #H elim H -G -K -T1 -T2
-[ #I #G #K #L #s #d #e #_ #U1 #H1 #U2 #H2
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #I #G #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #s #d #e #HLK #U1 #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
-    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2 by lt_to_le/ #X #HLK #H
-    elim (ldrop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K #Y #HKV #HVY #H destruct /3 width=10 by cpys_delta/
-  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 /2 width=1 by le_S/ >plus_plus_comm_23 #HVU2
-    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K /3 width=7 by cpys_delta, ldrop_inv_gen/
-  ]
-| #a #I #G #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #s #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=6 by cpys_bind, ldrop_skip/
-| #I #G #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #s #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6 by cpys_flat/
-]
-qed.
-
-lemma cpys_inv_lift1: ∀G. l_deliftable_sn (cpys G).
-#G #L #U1 #U2 #H elim H -G -L -U1 -U2
-[ * #G #L #i #K #s #d #e #_ #T1 #H
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3 by cpys_atom, lift_sort, ex2_intro/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3 by cpys_atom, lift_lref_ge_minus, lift_lref_lt, ex2_intro/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3 by cpys_atom, lift_gref, ex2_intro/
-  ]
-| #I #G #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #s #d #e #HLK #T1 #H
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
-    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
-    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m /3 width=9 by cpys_delta, ex2_intro/
-  | elim (le_inv_plus_l … Hid) #Hdie #Hei
-    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
-    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 /3 width=1 by le_S, le_S_S/ -Hid -Hdie
-    #V1 #HV1 >plus_minus // <minus_minus /2 width=1 by le_S/ <minus_n_n <plus_n_O /3 width=9 by cpys_delta, ex2_intro/
-  ]
-| #a #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=6 by cpys_bind, ldrop_skip, lift_bind, ex2_intro/
-| #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -V1
-  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5 by cpys_flat, lift_flat, ex2_intro/
-]
-qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma fqu_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                      ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
-                      ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2 
-/3 width=3 by fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, cpys_pair_sn, cpys_bind, cpys_flat, ex2_intro/
-[ #I #G #L #V2 #U2 #HVU2
-  elim (lift_total U2 0 1)
-  /4 width=7 by fqu_drop, cpys_delta, ldrop_pair, ldrop_drop, ex2_intro/
-| #G #L #K #T1 #U1 #e #HLK1 #HTU1 #T2 #HTU2
-  elim (lift_total T2 0 (e+1))
-  /3 width=11 by cpys_lift, fqu_drop, ex2_intro/
-]
-qed-.
-
-lemma fquq_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
-                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐⸮ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (fqu_cpys_trans … HT12 … HTU2) /3 width=3 by fqu_fquq, ex2_intro/
-| * #H1 #H2 #H3 destruct /2 width=3 by ex2_intro/
-]
-qed-.
-
-lemma fqup_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
-                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
-                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐+ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
-[ #G2 #L2 #T2 #H12 #U2 #HTU2 elim (fqu_cpys_trans … H12 … HTU2) -T2
-  /3 width=3 by fqu_fqup, ex2_intro/
-| #G #G2 #L #L2 #T #T2 #_ #HT2 #IHT1 #U2 #HTU2
-  elim (fqu_cpys_trans … HT2 … HTU2) -T2 #T2 #HT2 #HTU2
-  elim (IHT1 … HT2) -T /3 width=7 by fqup_strap1, ex2_intro/
-]
-qed-.
-
-lemma fqus_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
-                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
-                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐* ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fqus_inv_gen … H) -H
-[ #HT12 elim (fqup_cpys_trans … HT12 … HTU2) /3 width=3 by fqup_fqus, ex2_intro/
-| * #H1 #H2 #H3 destruct /2 width=3 by ex2_intro/
-]
-qed-.
-
-lemma fqu_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                          ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
-                          ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-[ #I #G #L #V1 #V2 #HV12 #_ elim (lift_total V2 0 1)
-  #U2 #HVU2 @(ex3_intro … U2)
-  [1,3: /3 width=7 by fqu_drop, cpys_delta, ldrop_pair, ldrop_drop/
-  | #H destruct /2 width=7 by lift_inv_lref2_be/
-  ]
-| #I #G #L #V1 #T #V2 #HV12 #H @(ex3_intro … (②{I}V2.T))
-  [1,3: /2 width=4 by fqu_pair_sn, cpys_pair_sn/
-  | #H0 destruct /2 width=1 by/
-  ]
-| #a #I #G #L #V #T1 #T2 #HT12 #H @(ex3_intro … (ⓑ{a,I}V.T2))
-  [1,3: /2 width=4 by fqu_bind_dx, cpys_bind/
-  | #H0 destruct /2 width=1 by/
-  ]
-| #I #G #L #V #T1 #T2 #HT12 #H @(ex3_intro … (ⓕ{I}V.T2))
-  [1,3: /2 width=4 by fqu_flat_dx, cpys_flat/
-  | #H0 destruct /2 width=1 by/
-  ]
-| #G #L #K #T1 #U1 #e #HLK #HTU1 #T2 #HT12 #H elim (lift_total T2 0 (e+1))
-  #U2 #HTU2 @(ex3_intro … U2)
-  [1,3: /2 width=10 by cpys_lift, fqu_drop/
-  | #H0 destruct /3 width=5 by lift_inj/
-]
-qed-.
-
-lemma fquq_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
-                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐⸮ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H12 #U2 #HTU2 #H elim (fquq_inv_gen … H12) -H12
-[ #H12 elim (fqu_cpys_trans_neq … H12 … HTU2 H) -T2
-  /3 width=4 by fqu_fquq, ex3_intro/
-| * #HG #HL #HT destruct /3 width=4 by ex3_intro/
-]
-qed-.
-
-lemma fqup_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
-                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
-                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐+ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind_dx … H) -G1 -L1 -T1
-[ #G1 #L1 #T1 #H12 #U2 #HTU2 #H elim (fqu_cpys_trans_neq … H12 … HTU2 H) -T2
-  /3 width=4 by fqu_fqup, ex3_intro/
-| #G #G1 #L #L1 #T #T1 #H1 #_ #IH12 #U2 #HTU2 #H elim (IH12 … HTU2 H) -T2
-  #U1 #HTU1 #H #H12 elim (fqu_cpys_trans_neq … H1 … HTU1 H) -T1
-  /3 width=8 by fqup_strap2, ex3_intro/
-]
-qed-.
-
-lemma fqus_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
-                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
-                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐* ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H12 #U2 #HTU2 #H elim (fqus_inv_gen … H12) -H12
-[ #H12 elim (fqup_cpys_trans_neq … H12 … HTU2 H) -T2
-  /3 width=4 by fqup_fqus, ex3_intro/
-| * #HG #HL #HT destruct /3 width=4 by ex3_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys.etc
deleted file mode 100644 (file)
index 0a9563a..0000000
+++ /dev/null
@@ -1,61 +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/psubstsnstar_3.ma".
-include "basic_2/relocation/lpx_sn.ma".
-include "basic_2/substitution/cpys.ma".
-
-(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
-
-definition lpys: relation3 genv lenv lenv ≝ λG. lpx_sn (cpys G).
-
-interpretation
-   "extended multiple substitution (local environment, sn variant)"
-   'PSubstSnStar G L1 L2 = (lpys G L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lpys_inv_atom1: ∀G,L2. ⦃G, ⋆⦄ ⊢ ▶* L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-lemma lpys_inv_pair1: ∀I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ▶* L2 →
-                      ∃∃K2,V2. ⦃G, K1⦄ ⊢ ▶* K2 & ⦃G, K1⦄ ⊢ V1 ▶* V2 &
-                               L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-lemma lpys_inv_atom2: ∀G,L1. ⦃G, L1⦄ ⊢ ▶* ⋆ → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-lemma lpys_inv_pair2: ∀I,G,L1,K2,V2. ⦃G, L1⦄ ⊢ ▶* K2.ⓑ{I}V2 →
-                      ∃∃K1,V1. ⦃G, K1⦄ ⊢ ▶* K2 & ⦃G, K1⦄ ⊢ V1 ▶* V2 &
-                               L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-lemma lpys_inv_pair: ∀I1,I2,G,L1,L2,V1,V2. ⦃G, L1.ⓑ{I1}V1⦄ ⊢ ▶* L2.ⓑ{I2}V2 →
-                     ∧∧ ⦃G, L1⦄ ⊢ ▶* L2 & ⦃G, L1⦄ ⊢ V1 ▶* V2 & I1 = I2.
-/2 width=1 by lpx_sn_inv_pair/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpys_refl: ∀G,L. ⦃G, L⦄ ⊢ ▶* L.
-/2 width=1 by lpx_sn_refl/ qed.
-
-lemma lpys_pair: ∀I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ▶* K2 → ⦃G, K1⦄ ⊢ V1 ▶* V2 →
-                 ⦃G, K1.ⓑ{I}V1⦄ ⊢ ▶* K2.ⓑ{I}V2.
-/2 width=1 by lpx_sn_pair/ qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpys_fwd_length: ∀G,L1,L2. ⦃G, L1⦄ ⊢ ▶* L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_ldrop.etc
deleted file mode 100644 (file)
index db5037c..0000000
+++ /dev/null
@@ -1,78 +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/substitution/cpys_lift.ma".
-include "basic_2/substitution/lpys.ma".
-
-(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
-
-(* Properies on local environment slicing ***********************************)
-
-lemma lpys_ldrop_conf: ∀G. dropable_sn (lpys G).
-/3 width=6 by lpx_sn_deliftable_dropable, cpys_inv_lift1/ qed-.
-
-lemma ldrop_lpys_trans: ∀G. dedropable_sn (lpys G).
-/3 width=10 by lpx_sn_liftable_dedropable, cpys_lift/ qed-.
-
-lemma lpys_ldrop_trans_O1: ∀G. dropable_dx (lpys G).
-/2 width=3 by lpx_sn_dropable/ qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma fqu_lpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                      ∀K2. ⦃G2, L2⦄ ⊢ ▶* K2 →
-                      ∃∃K1,T. ⦃G1, L1⦄ ⊢ ▶* K1 & ⦃G1, L1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐ ⦃G2, K2, T2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-/3 width=5 by fqu_lref_O, fqu_pair_sn, fqu_flat_dx, lpys_pair, ex3_2_intro/
-[ #a #I #G2 #L2 #V2 #T2 #X #H elim (lpys_inv_pair1 … H) -H
-  #K2 #W2 #HLK2 #HVW2 #H destruct
-  /3 width=5 by fqu_fquq, cpys_pair_sn, fqu_bind_dx, ex3_2_intro/
-| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #K2 #HK12
-  elim (ldrop_lpys_trans … HLK1 … HK12) -HK12
-  /3 width=7 by fqu_drop, ex3_2_intro/
-]
-qed-.
-
-lemma fquq_lpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                       ∀K2. ⦃G2, L2⦄ ⊢ ▶* K2 →
-                       ∃∃K1,T. ⦃G1, L1⦄ ⊢ ▶* K1 & ⦃G1, L1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐⸮ ⦃G2, K2, T2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #K2 #HLK2 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (fqu_lpys_trans … HT12 … HLK2) /3 width=5 by fqu_fquq, ex3_2_intro/
-| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma lpys_fqu_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
-                      ∀K1. ⦃G1, K1⦄ ⊢ ▶* L1 →
-                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ▶* L2.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-/3 width=7 by fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, lpys_pair, ex3_2_intro/
-[ #I #G1 #L1 #V1 #X #H elim (lpys_inv_pair2 … H) -H
-  #K1 #W1 #HKL1 #HWV1 #H destruct elim (lift_total V1 0 1)
-  /4 width=7 by cpys_delta, fqu_drop, ldrop_drop, ex3_2_intro/
-| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #L0 #HL01
-  elim (lpys_ldrop_trans_O1 … HL01 … HLK1) -L1
-  /3 width=5 by fqu_drop, ex3_2_intro/
-]
-qed-.
-
-lemma lpys_fquq_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
-                       ∀K1. ⦃G1, K1⦄ ⊢ ▶* L1 →
-                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ▶* L2.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #HKL1 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (lpys_fqu_trans … HT12 … HKL1) /3 width=5 by fqu_fquq, ex3_2_intro/
-| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_lpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lpys_lpys.etc
deleted file mode 100644 (file)
index f5524bf..0000000
+++ /dev/null
@@ -1,23 +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".
-
-(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
-
-(* Main properties **********************************************************)
-
-theorem lpys_trans: ∀G. Transitive … (lpys G).
-/3 width=5 by lpx_sn_trans, cpys_trans_lpys/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lrsubeq_2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lrsubeq_2.etc
deleted file mode 100644 (file)
index da28322..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 ⊆ break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LRSubEq $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby.etc
deleted file mode 100644 (file)
index c06429d..0000000
+++ /dev/null
@@ -1,95 +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/lrsubeq_2.ma".
-include "basic_2/relocation/ldrop.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR EXTENDED SUBSTITUTION *******************)
-
-inductive lsuby: relation lenv ≝
-| lsuby_atom: ∀L. lsuby L (⋆)
-| lsuby_pair: ∀I1,I2,L1,L2,V. lsuby L1 L2 → lsuby (L1.ⓑ{I1}V) (L2.ⓑ{I2}V)
-.
-
-interpretation
-  "local environment refinement (extended substitution)"
-  'LRSubEq L1 L2 = (lsuby L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lsuby_refl: ∀L. L ⊆ L.
-#L elim L -L /2 width=1 by lsuby_pair/
-qed.
-
-lemma lsuby_sym: ∀L1,L2. L1 ⊆ L2 → |L1| = |L2| → L2 ⊆ L1.
-#L1 #L2 #H elim H -L1 -L2
-[ #L1 #H >(length_inv_zero_dx … H) -L1 //
-| #I1 #I2 #L1 #L2 #V #_ #IHL12 #H lapply (injective_plus_l … H) -H
-  /3 width=1 by lsuby_pair/
-]
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lsuby_inv_atom1_aux: ∀L1,L2. L1 ⊆ L2 → L1 = ⋆ → L2 = ⋆.
-#L1 #L2 * -L1 -L2 //
-#I1 #I2 #L1 #L2 #V #_ #H destruct
-qed-.
-
-lemma lsuby_inv_atom1: ∀L2. ⋆ ⊆ L2 → L2 = ⋆.
-/2 width=3 by lsuby_inv_atom1_aux/ qed-.
-
-fact lsuby_inv_pair1_aux: ∀L1,L2. L1 ⊆ L2 → ∀J1,K1,W. L1 = K1.ⓑ{J1}W →
-                          L2 = ⋆ ∨ ∃∃I2,K2. K1 ⊆ K2 & L2 = K2.ⓑ{I2}W.
-#L1 #L2 * -L1 -L2
-[ #L #J1 #K1 #W #H destruct /2 width=1 by or_introl/
-| #I1 #I2 #L1 #L2 #V #HL12 #J1 #K1 #W #H destruct /3 width=4 by ex2_2_intro, or_intror/
-]
-qed-.
-
-lemma lsuby_inv_pair1: ∀I1,K1,L2,W. K1.ⓑ{I1}W ⊆ L2 →
-                       L2 = ⋆ ∨ ∃∃I2,K2. K1 ⊆ K2 & L2 = K2.ⓑ{I2}W.
-/2 width=4 by lsuby_inv_pair1_aux/ qed-.
-
-fact lsuby_inv_pair2_aux: ∀L1,L2. L1 ⊆ L2 → ∀J2,K2,W. L2 = K2.ⓑ{J2}W →
-                          ∃∃I1,K1. K1 ⊆ K2 & L1 = K1.ⓑ{I1}W.
-#L1 #L2 * -L1 -L2
-[ #L #J2 #K2 #W #H destruct
-| #I1 #I2 #L1 #L2 #V #HL12 #J2 #K2 #W #H destruct /2 width=4 by ex2_2_intro/
-]
-qed-.
-
-lemma lsuby_inv_pair2: ∀I2,L1,K2,W. L1 ⊆ K2.ⓑ{I2}W  →
-                       ∃∃I1,K1. K1 ⊆ K2 & L1 = K1.ⓑ{I1}W.
-/2 width=4 by lsuby_inv_pair2_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lsuby_fwd_length: ∀L1,L2. L1 ⊆ L2 → |L2| ≤ |L1|.
-#L1 #L2 #H elim H -L1 -L2 /2 width=1 by monotonic_le_plus_l/
-qed-.
-
-lemma lsuby_ldrop_trans: ∀L1,L2. L1 ⊆ L2 →
-                         ∀I2,K2,W,s,i. ⇩[s, 0, i] L2 ≡ K2.ⓑ{I2}W →
-                         ∃∃I1,K1. K1 ⊆ K2 & ⇩[s, 0, i] L1 ≡ K1.ⓑ{I1}W.
-#L1 #L2 #H elim H -L1 -L2
-[ #L #J2 #K2 #W #s #i #H
-  elim (ldrop_inv_atom1 … H) -H #H destruct
-| #I1 #I2 #L1 #L2 #V #HL12 #IHL12 #J2 #K2 #W #s #i #H
-  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct [ -IHL12 | -HL12 ]
-  [ /3 width=4 by ldrop_pair, ex2_2_intro/
-  | elim (IHL12 … HLK2) -IHL12 -HLK2 * /3 width=4 by ldrop_drop_lt, ex2_2_intro/
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby_lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/lsuby_lsuby.etc
deleted file mode 100644 (file)
index 254d629..0000000
+++ /dev/null
@@ -1,27 +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/lsuby.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR EXTENDED SUBSTITUTION *******************)
-
-(* Main properties **********************************************************)
-
-theorem lsuby_trans: Transitive … lsuby.
-#L1 #L #H elim H -L1 -L
-[ #L1 #X #H lapply (lsuby_inv_atom1 … H) -H //
-| #I1 #I #L1 #L #V #_ #IHL1 #X #H elim (lsuby_inv_pair1 … H) -H // *
-  #I2 #L2 #HL2 #H destruct /3 width=1 by lsuby_pair/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubstsnstar_3.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubstsnstar_3.etc
deleted file mode 100644 (file)
index 0d6dffe..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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ▶ * break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'PSubstSnStar $G $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubststar_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys0/psubststar_4.etc
deleted file mode 100644 (file)
index 0e76c6f..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStar $G $L $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/cpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/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/cpys2/cpx_cpys2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/cpx_cpys2.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/cpys2/cpxs_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/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/cpys2/lpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/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/etc/cpys2/lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/cpys2/lsuby.etc
deleted file mode 100644 (file)
index 657ad6b..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-(*
-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/csup/csup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/csup/csup.etc
deleted file mode 100644 (file)
index 0a980f6..0000000
+++ /dev/null
@@ -1,88 +0,0 @@
-(* Basic forward lemmas *****************************************************)
-
-lemma csup_fwd_ldrop: ∀L1,L2,T1,T2. ⦃L1, T1⦄ > ⦃L2, T2⦄ →
-                      ∃i. ⇩[0, i] L1 ≡ L2 ∨ ⇩[0, i] L2 ≡ L1.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /3 width=2/ /4 width=2/
-#I #L1 #K1 #V1 #i #HLK1
-lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 /3 width=2/
-qed-. 
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lift_csup_trans_eq: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
-                          ∀L,U2. ⦃L, U1⦄ > ⦃L, U2⦄ → 
-                          ∃T2. ⇧[d, e] T2 ≡ U2.
-#T1 #U1 #d #e * -T1 -U1 -d -e
-[5: #a #I #V1 #W1 #T1 #U1 #d #e #HVW1 #_ #L #X #H
-    elim (csup_inv_bind1 … H) -H *
-    [ #_ #H destruct /2 width=2/
-    | #H elim (discr_lpair_x_xy … H)
-    ]
-|6: #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HUT1 #L #X #H
-    elim (csup_inv_flat1 … H) -H #_ * #H destruct /2 width=2/
-]
-#i #d #e [2,3: #_ ] #L #X #H
-elim (csup_inv_atom1 … H) -H #I #j #HL #H destruct
-lapply (ldrop_pair2_fwd_cw … HL X) -HL #H
-elim (lt_refl_false … H)
-qed-.
-(*
-lemma lift_csup_trans_gt: ∀L1,L2,U1,U2. ⦃L1, U1⦄ > ⦃L2, U2⦄ →
-                          ⇩[0, 1] L2 ≡ L1 → ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
-                          ∃T2. ⇧[d + 1, e] T2 ≡ U2.
-#L1 #L2 #U1 #U2 * -L1 -L2 -U1 -U2
-[ #I #L1 #K1 #V #i #HLK1 #HKL1
-  lapply (ldrop_fwd_lw … HLK1) -HLK1 #HLK1
-  lapply (ldrop_fwd_lw … HKL1) -HKL1 #HKL1
-  lapply (transitive_le … HLK1 HKL1) -L1 normalize #H
-  
-  
-| #a
-| #a
-]
-#I #L1 #W1 #U1 #HL1
-  
-
-
- #X #d #e #H
-  lapply (ldrop_inv_refl … HL1) -HL1
-| #a #I #L1 #W1 #U1 #j #HL1 #X #d #e #H
-  lapply (ldrop_inv_ldrop1 … HL1)
-
-  elim (lift_inv_bind2 … H) -H #W2 #U2 #HW21 #HU21 #H destruct 
-   
-
- /3 width=2/ /4 width=2/
-
-*)
-
-
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma csup_inv_lref2_be: ∀L,U,i. ⦃L, U⦄ > ⦃L, #i⦄ →
-                         ∀T,d,e. ⇧[d, e] T ≡ U → d ≤ i → i < d + e → ⊥.
-#L #U #i #H #T #d #e #HTU #Hdi #Hide
-elim (lift_csup_trans_eq … HTU … H) -H -T #T #H
-elim (lift_inv_lref2_be … H ? ?) //
-qed-.
-
-
-fact csup_inv_all4_refl_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ > ⦃L2, T2⦄ → L1 = L2 →
-                             ∨∨ ∃∃a,I,U. T1 = ⓑ{a,I}T2.U
-                              | ∃∃I,W. T1 = ⓕ{I}W.T2
-                              | ∃∃I,U. T1 = ⓕ{I}T2.U.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /3 width=3/ /3 width=4/
-[ #I #L #K #V #i #HLK #H destruct
-  lapply (ldrop_pair2_fwd_cw … HLK V) -HLK #H
-  elim (lt_refl_false … H)
-| #a #I #L #V #T #H
-  elim (discr_lpair_x_xy … H)
-]
-qed-.
-
-lemma csup_inv_all4_refl: ∀L,T1,T2. ⦃L, T1⦄ > ⦃L, T2⦄ →
-                          ∨∨ ∃∃a,I,U. T1 = ⓑ{a,I}T2.U
-                           | ∃∃I,W. T1 = ⓕ{I}W.T2
-                           | ∃∃I,U. T1 = ⓕ{I}T2.U.
-/2 width=4 by csup_inv_all4_refl_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/csup/csup_csup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/csup/csup_csup.etc
deleted file mode 100644 (file)
index 661d896..0000000
+++ /dev/null
@@ -1,33 +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/ldrop_ldrop.ma".
-include "basic_2/substitution/csup.ma".
-
-(* SUPCLOSURE ***************************************************************)
-
-(* Main forward lemmas ******************************************************)
-
-theorem csup_trans_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ > ⦃L0, T2⦄ →
-                             ∀T3. ⦃L0, T2⦄ > ⦃L, T3⦄ →
-                             L = L0 ∨ ⦃L, T1⦄ > ⦃L, T3⦄.
-#L #L0 #T1 #T2 * -L -L0 -T1 -T2 /2 width=1/
-[ #I #L0 #K0 #V0 #i #HLK0 #T3 #H
-  lapply (ldrop_pair2_fwd_cw … HLK0 T3) -HLK0 #H1
-  lapply (csup_fwd_cw … H) -H #H2
-  lapply (transitive_lt … H1 H2) -H1 -H2 #H
-  elim (lt_refl_false … H)
-| #a #I #L0 #V2 #T2 #T3 #HT23
-  elim (csup_inv_ldrop … HT23 I V2 0 ?) -HT23 // #H1 #H2 destruct /2 width=1/
-  qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/csup/csups_csups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/csup/csups_csups.etc
deleted file mode 100644 (file)
index 9978429..0000000
+++ /dev/null
@@ -1,57 +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/csup_csup.ma".
-include "basic_2/unfold/csups.ma".
-
-(* STAR-ITERATED SUPCLOSURE *************************************************)
-
-(* Advanced forward lemmas **************************************************)
-
-(*
-lemma csupp_strap2_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ > ⦃L0, T2⦄ →
-                             ∀T3. ⦃L0, T2⦄ >+ ⦃L, T3⦄ →
-                             L = L0 ∨ ⦃L, T1⦄ >+ ⦃L, T3⦄.
-#L #L0 #T1 #T2 * -L -L0 -T1 -T2 /2 width=1/
-[ #I #L0 #K0 #V0 #i #HLK0 #T3 #H
-  lapply (ldrop_pair2_fwd_cw … HLK0 T3) -HLK0 #H1
-  lapply (csupp_fwd_cw … H) -H #H2
-  lapply (transitive_lt … H1 H2) -H1 -H2 #H
-  elim (lt_refl_false … H)
-| #a #I #L0 #V2 #T2 #T3 #HT23
-  /3 width=5/
-
-  elim (csup_inv_ldrop … HT23 I V2 0 ?) -HT23 // #H1 #H2 destruct /2 width=1/
-  qed-.
-
-
-
-
-
-
-
-
-lemma csups_strap1_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ >* ⦃L0, T2⦄ →
-                             ∀T3. ⦃L0, T2⦄ > ⦃L, T3⦄ → L = L0.
-#L #L0 #T1 #T2 #H @(csups_ind_dx … H) -L -T1 //
-#L1 #L #T1 #T #HL1 #_ #IHL0 #T3 #HL0
-lapply (csup_trans_fwd_refl … HL10) … HL0) -T2
-*) 
-lemma lift_csups_trans_aux: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
-                            ∀L1,L2,U2. ⦃L1, U1⦄ >* ⦃L2, U2⦄ → L1 = L2 →
-                            ∃T2. ⇧[d, e] T2 ≡ U2.
-#T1 #U1 #d #e #HTU1 #L1 #L2 #U2 #H @(csups_ind … H) -L2 -U2 /2 width=2/ -T1
-#L #L2 #U #U2 #HL1 #HL2 #IHL1 #H destruct
-
-* -T1 -U1 -d -e
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpcs_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpcs_delift.etc
deleted file mode 100644 (file)
index 7012ec1..0000000
+++ /dev/null
@@ -1,37 +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/unfold/delift_lift.ma".
-include "basic_2/unfold/delift_delift.ma".
-include "basic_2/computation/cprs_delift.ma".
-include "basic_2/equivalence/cpcs_cpcs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
-
-(* Properties on inverse basic term relocation ******************************)
-
-lemma cpcs_zeta_delift_comm: ∀L,V,T1,T2. L.ⓓV ⊢ ▼*[O, 1] T1 ≡ T2 →
-                             L ⊢ T2 ⬌* +ⓓV.T1.
-/3 width=1/ qed.
-
-(* Basic_1: was only: pc3_gen_cabbr *)
-lemma thin_cpcs_delift_mono: ∀L,U1,U2. L ⊢ U1 ⬌* U2 →
-                             ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
-                             ∀T2. L ⊢ ▼*[d, e] U2 ≡ T2 → K ⊢ T1 ⬌* T2.
-#L #U1 #U2 #H #K #d #e #HLK #T1 #HTU1 #T2 #HTU2
-elim (cpcs_inv_cprs … H) -H #U #HU1 #HU2
-elim (thin_cprs_delift_conf … HU1 … HLK … HTU1) -U1 #T #HT1 #HUT
-elim (thin_cprs_delift_conf … HU2 … HLK … HTU2) -U2 -HLK #X #HT2 #H
-lapply (delift_mono … H … HUT) -L #H destruct /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpr_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cpr_delift.etc
deleted file mode 100644 (file)
index 04eb4ae..0000000
+++ /dev/null
@@ -1,37 +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/unfold/thin_delift.ma".
-include "basic_2/reducibility/tpr_delift.ma".
-include "basic_2/reducibility/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
-
-(* Properties on inverse basic term relocation ******************************)
-
-(* Basic_1: was only: pr2_gen_cabbr *)
-lemma thin_cpr_delift_conf: ∀L,U1,U2. L ⊢ U1 ➡ U2 →
-                            ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
-                            ∃∃T2. K ⊢ T1 ➡ T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
-#L #U1 #U2 * #U #HU1 #HU2 #K #d #e #HLK #T1 #HTU1
-elim (tpr_delift_conf … HU1 … HTU1) -U1 #T #HT1 #HUT
-elim (le_or_ge (|L|) d) #Hd
-[ elim (thin_delift_tpss_conf_le … HU2 … HUT … HLK ?)
-| elim (le_or_ge (|L|) (d+e)) #Hde
-  [ elim (thin_delift_tpss_conf_le_up … HU2 … HUT … HLK ? ? ?)
-  | elim (thin_delift_tpss_conf_be … HU2 … HUT … HLK ? ?)
-  ]
-] -U -HLK // -Hd [2,3: -Hde] #T2 #HT2
-lapply (cpr_intro … HT1 HT2) -T /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cprs_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/cprs_delift.etc
deleted file mode 100644 (file)
index 6b78926..0000000
+++ /dev/null
@@ -1,37 +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/reducibility/cpr_delift.ma".
-include "basic_2/reducibility/cpr_cpr.ma".
-include "basic_2/computation/cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties on inverse basic term relocation ******************************)
-
-(* Note: this should be stated with tprs *)
-lemma cprs_zeta_delift: ∀L,V,T1,T2. L.ⓓV ⊢ ▼*[O, 1] T1 ≡ T2 → L ⊢ +ⓓV.T1 ➡* T2.
-#L #V #T1 #T2 * #T #HT1 #HT2
-@(cprs_strap2 … (+ⓓV.T)) [ /3 width=3/ | @inj /3 width=3/ ] (**) (* explicit constructor, /5 width=3/ is too slow *)
-qed.
-
-(* Basic_1: was only: pr3_gen_cabbr *)
-lemma thin_cprs_delift_conf: ∀L,U1,U2. L ⊢ U1 ➡* U2 →
-                             ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
-                             ∃∃T2. K ⊢ T1 ➡* T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
-#L #U1 #U2 #H @(cprs_ind … H) -U2 /2 width=3/
-#U #U2 #_ #HU2 #IHU1 #K #d #e #HLK #T1 #HTU1
-elim (IHU1 … HLK … HTU1) -U1 #T #HT1 #HUT
-elim (thin_cpr_delift_conf … HU2 … HLK … HUT) -U -HLK /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift.etc
deleted file mode 100644 (file)
index eda8396..0000000
+++ /dev/null
@@ -1,112 +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 "hvbox( L ⊢ break ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'TSubst $L $T1 $d $e $T2 }.
-
-include "basic_2/unfold/tpss.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-definition delift: nat → nat → lenv → relation term ≝
-                   λd,e,L,T1,T2. ∃∃T. L ⊢ T1 ▶* [d, e] T & ⇧[d, e] T2 ≡ T.
-
-interpretation "inverse basic relocation (term)"
-   'TSubst L T1 d e T2 = (delift d e L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma lift_delift: ∀T1,T2,d,e. ⇧[d, e] T1 ≡ T2 →
-                   ∀L. L ⊢ ▼*[d, e] T2 ≡ T1.
-/2 width=3/ qed.
-
-lemma delift_refl_O2: ∀L,T,d. L ⊢ ▼*[d, 0] T ≡ T.
-/2 width=3/ qed.
-
-lemma delift_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ ▼*[d, e] T1 ≡ T2 →
-                          ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ ▼*[d, e] T1 ≡ T2.
-#L1 #T1 #T2 #d #e * /3 width=3/
-qed.
-
-lemma delift_sort: ∀L,d,e,k. L ⊢ ▼*[d, e] ⋆k ≡ ⋆k.
-/2 width=3/ qed.
-
-lemma delift_lref_lt: ∀L,d,e,i. i < d → L ⊢ ▼*[d, e] #i ≡ #i.
-/3 width=3/ qed.
-
-lemma delift_lref_ge: ∀L,d,e,i. d + e ≤ i → L ⊢ ▼*[d, e] #i ≡ #(i - e).
-/3 width=3/ qed.
-
-lemma delift_gref: ∀L,d,e,p. L ⊢ ▼*[d, e] §p ≡ §p.
-/2 width=3/ qed.
-
-lemma delift_bind: ∀a,I,L,V1,V2,T1,T2,d,e.
-                   L ⊢ ▼*[d, e] V1 ≡ V2 → L. ⓑ{I} V2 ⊢ ▼*[d+1, e] T1 ≡ T2 →
-                   L ⊢ ▼*[d, e] ⓑ{a,I} V1. T1 ≡ ⓑ{a,I} V2. T2.
-#a #I #L #V1 #V2 #T1 #T2 #d #e * #V #HV1 #HV2 * #T #HT1 #HT2
-lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/ /3 width=5/
-qed.
-
-lemma delift_flat: ∀I,L,V1,V2,T1,T2,d,e.
-                   L ⊢ ▼*[d, e] V1 ≡ V2 → L ⊢ ▼*[d, e] T1 ≡ T2 →
-                   L ⊢ ▼*[d, e] ⓕ{I} V1. T1 ≡ ⓕ{I} V2. T2.
-#I #L #V1 #V2 #T1 #T2 #d #e * #V #HV1 #HV2 * /3 width=5/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma delift_inv_sort1: ∀L,U2,d,e,k. L ⊢ ▼*[d, e] ⋆k ≡ U2 → U2 = ⋆k.
-#L #U2 #d #e #k * #U #HU
->(tpss_inv_sort1 … HU) -HU #HU2
->(lift_inv_sort2 … HU2) -HU2 //
-qed-.
-
-lemma delift_inv_gref1: ∀L,U2,d,e,p. L ⊢ ▼*[d, e] §p ≡ U2 → U2 = §p.
-#L #U #d #e #p * #U #HU
->(tpss_inv_gref1 … HU) -HU #HU2
->(lift_inv_gref2 … HU2) -HU2 //
-qed-.
-
-lemma delift_inv_bind1: ∀a,I,L,V1,T1,U2,d,e. L ⊢ ▼*[d, e] ⓑ{a,I} V1. T1 ≡ U2 →
-                        ∃∃V2,T2. L ⊢ ▼*[d, e] V1 ≡ V2 &
-                                 L. ⓑ{I} V2 ⊢ ▼*[d+1, e] T1 ≡ T2 &
-                                 U2 = ⓑ{a,I} V2. T2.
-#a #I #L #V1 #T1 #U2 #d #e * #U #HU #HU2
-elim (tpss_inv_bind1 … HU) -HU #V #T #HV1 #HT1 #X destruct
-elim (lift_inv_bind2 … HU2) -HU2 #V2 #T2 #HV2 #HT2
-lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V2) ?) -HT1 /2 width=1/ /3 width=5/
-qed-.
-
-lemma delift_inv_flat1: ∀I,L,V1,T1,U2,d,e. L ⊢ ▼*[d, e] ⓕ{I} V1. T1 ≡ U2 →
-                        ∃∃V2,T2. L ⊢ ▼*[d, e] V1 ≡ V2 &
-                                 L ⊢ ▼*[d, e] T1 ≡ T2 &
-                                 U2 = ⓕ{I} V2. T2.
-#I #L #V1 #T1 #U2 #d #e * #U #HU #HU2
-elim (tpss_inv_flat1 … HU) -HU #V #T #HV1 #HT1 #X destruct
-elim (lift_inv_flat2 … HU2) -HU2 /3 width=5/
-qed-.
-
-lemma delift_inv_refl_O2: ∀L,T1,T2,d. L ⊢ ▼*[d, 0] T1 ≡ T2 → T1 = T2.
-#L #T1 #T2 #d * #T #HT1
->(tpss_inv_refl_O2 … HT1) -HT1 #HT2
->(lift_inv_refl_O2 … HT2) -HT2 //
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma delift_fwd_tw: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 → ♯{T1} ≤ ♯{T2}.
-#L #T1 #T2 #d #e * #T #HT1 #HT2
->(lift_fwd_tw … HT2) -T2 /2 width=4 by tpss_fwd_tw/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_alt.etc
deleted file mode 100644 (file)
index e229110..0000000
+++ /dev/null
@@ -1,104 +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 "hvbox( L ⊢ break ▼ ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'TSubstAlt $L $T1 $d $e $T2 }.
-
-include "basic_2/unfold/delift_lift.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-(* alternative definition of inverse basic term relocation *)
-inductive delifta: nat → nat → lenv → relation term ≝
-| delifta_sort   : ∀L,d,e,k. delifta d e L (⋆k) (⋆k)
-| delifta_lref_lt: ∀L,d,e,i. i < d → delifta d e L (#i) (#i)
-| delifta_lref_be: ∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
-                   ⇩[0, i] L ≡ K. ⓓV1 → delifta 0 (d + e - i - 1) K V1 V2 →
-                   ⇧[0, d] V2 ≡ W2 → delifta d e L (#i) W2
-| delifta_lref_ge: ∀L,d,e,i. d + e ≤ i → delifta d e L (#i) (#(i - e))
-| delifta_gref   : ∀L,d,e,p. delifta d e L (§p) (§p)
-| delifta_bind   : ∀L,a,I,V1,V2,T1,T2,d,e.
-                   delifta d e L V1 V2 → delifta (d + 1) e (L. ⓑ{I} V2) T1 T2 →
-                   delifta d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| delifta_flat   : ∀L,I,V1,V2,T1,T2,d,e.
-                   delifta d e L V1 V2 → delifta d e L T1 T2 →
-                   delifta d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-.
-
-interpretation "inverse basic relocation (term) alternative"
-   'TSubstAlt L T1 d e T2 = (delifta d e L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma delifta_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ ▼▼*[d, e] T1 ≡ T2 →
-                           ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ ▼▼*[d, e] T1 ≡ T2.
-#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e // /2 width=1/
-[ #L1 #K1 #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /3 width=6/
-| /4 width=1/
-| /3 width=1/
-]
-qed.
-
-lemma delift_delifta: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 → L ⊢ ▼▼*[d, e] T1 ≡ T2.
-#L #T1 @(f2_ind … fw … L T1) -L -T1 #n #IH #L *
-[ * #i #Hn #T2 #d #e #H destruct
-  [ >(delift_inv_sort1 … H) -H //
-  | elim (delift_inv_lref1 … H) -H * /2 width=1/
-    #K #V1 #V2 #Hdi #Hide #HLK #HV12 #HVT2
-    lapply (ldrop_pair2_fwd_fw … HLK) #H
-    lapply (IH … HV12) // -H /2 width=6/
-  | >(delift_inv_gref1 … H) -H //
-  ]
-| * [ #a ] #I #V1 #T1 #Hn #X #d #e #H
-  [ elim (delift_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (delift_lsubr_trans … HT12 (L.ⓑ{I}V1) ?) -HT12 /2 width=1/ #HT12
-    lapply (IH … HV12) -HV12 // #HV12
-    lapply (IH … HT12) -IH -HT12 /2 width=1/ #HT12
-    lapply (delifta_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/
-  | elim (delift_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH … HV12) -HV12 //
-    lapply (IH … HT12) -IH -HT12 // /2 width=1/
-  ]
-]
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma delifta_delift: ∀L,T1,T2,d,e. L ⊢ ▼▼*[d, e] T1 ≡ T2 → L ⊢ ▼*[d, e] T1 ≡ T2.
-#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e // /2 width=1/ /2 width=6/
-qed-.
-
-lemma delift_ind_alt: ∀R:ℕ→ℕ→lenv→relation term.
-                      (∀L,d,e,k. R d e L (⋆k) (⋆k)) →
-                      (∀L,d,e,i. i < d → R d e L (#i) (#i)) →
-                      (∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
-                       ⇩[O, i] L ≡ K.ⓓV1 → K ⊢ ▼*[O, d + e - i - 1] V1 ≡ V2 →
-                       ⇧[O, d] V2 ≡ W2 → R O (d+e-i-1) K V1 V2 → R d e L (#i) W2
-                      ) →
-                      (∀L,d,e,i. d + e ≤ i → R d e L (#i) (#(i - e))) →
-                      (∀L,d,e,p. R d e L (§p) (§p)) →
-                      (∀L,a,I,V1,V2,T1,T2,d,e. L ⊢ ▼*[d, e] V1 ≡ V2 →
-                       L.ⓑ{I}V2 ⊢ ▼*[d + 1, e] T1 ≡ T2 → R d e L V1 V2 →
-                       R (d+1) e (L.ⓑ{I}V2) T1 T2 → R d e L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
-                      ) →
-                      (∀L,I,V1,V2,T1,T2,d,e. L ⊢ ▼*[d, e] V1 ≡ V2 →
-                       L⊢ ▼*[d, e] T1 ≡ T2 → R d e L V1 V2 →
-                       R d e L T1 T2 → R d e L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
-                      ) →
-                      ∀d,e,L,T1,T2. L ⊢ ▼*[d, e] T1 ≡ T2 → R d e L T1 T2.
-#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #d #e #L #T1 #T2 #H elim (delift_delifta … H) -L -T1 -T2 -d -e
-// /2 width=1 by delifta_delift/ /3 width=1 by delifta_delift/ /3 width=7 by delifta_delift/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_delift.etc
deleted file mode 100644 (file)
index a5c5635..0000000
+++ /dev/null
@@ -1,29 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/delift.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-(* Main properties **********************************************************)
-
-theorem delift_mono: ∀L,T,T1,T2,d,e.
-                     L ⊢ ▼*[d, e] T ≡ T1 → L ⊢ ▼*[d, e] T ≡ T2 → T1 = T2.
-#L #T #T1 #T2 #d #e * #U1 #H1TU1 #H2TU1 * #U2 #H1TU2 #H2TU2
-elim (tpss_conf_eq … H1TU1 … H1TU2) -T #U #HU1 #HU2
-lapply (tpss_inv_lift1_eq … HU1 … H2TU1) -HU1 #H destruct
-lapply (tpss_inv_lift1_eq … HU2 … H2TU2) -HU2 #H destruct
-lapply (lift_inj … H2TU1 … H2TU2) //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_lift.etc
deleted file mode 100644 (file)
index 8abaeb9..0000000
+++ /dev/null
@@ -1,164 +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/ldrop_lbotr.ma".
-include "basic_2/unfold/tpss_lift.ma".
-include "basic_2/unfold/delift.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-(* Advanced properties ******************************************************)
-
-lemma delift_lref_be: ∀L,K,V1,V2,U2,i,d,e. d ≤ i → i < d + e →
-                      ⇩[0, i] L ≡ K. ⓓV1 → K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 →
-                      ⇧[0, d] V2 ≡ U2 → L ⊢ ▼*[d, e] #i ≡ U2.
-#L #K #V1 #V2 #U2 #i #d #e #Hdi #Hide #HLK * #V #HV1 #HV2 #HVU2
-elim (lift_total V 0 (i+1)) #U #HVU
-lapply (lift_trans_be … HV2 … HVU ? ?) -HV2 // >minus_plus <plus_minus_m_m /2 width=1/ #HV2U
-lapply (lift_conf_be … HVU2 … HV2U ?) //
->commutative_plus in ⊢ (??%??→?); <minus_plus_m_m /3 width=6/
-qed.
-
-lemma lbotr_delift: ∀L,T1,d,e. d + e ≤ |L| → ⊒[d, e] L →
-                    ∃T2. L ⊢ ▼*[d, e] T1 ≡ T2.
-#L #T1 @(f2_ind … fw … L T1) -L -T1
-#n #IH #L * * /2 width=2/
-[ #i #H #d #e #Hde #HL destruct
-  elim (lt_or_ge i d) #Hdi [ /3 width=2/ ]
-  elim (lt_or_ge i (d+e)) #Hide [2: /3 width=2/ ]
-  lapply (lt_to_le_to_lt … Hide Hde) #Hi
-  elim (ldrop_O1_lt … Hi) -Hi #I #K #V1 #HLK
-  lapply (lbotr_inv_ldrop … HLK … HL ? ?) // #H destruct
-  lapply (ldrop_pair2_fwd_fw … HLK (#i)) #HKL
-  lapply (ldrop_fwd_ldrop2 … HLK) #HLK0
-  lapply (ldrop_fwd_O1_length … HLK0) #H
-  lapply (lbotr_ldrop_trans_be_up … HLK0 … HL ? ?) -HLK0 -HL
-  [1,2: /2 width=1/ | <minus_n_O <minus_plus ] #HK
-  elim (IH … HKL … HK) -IH -HKL -HK
-  [2: >H -H /2 width=1/ ] -Hde -H #V2 #V12 (**) (* H erased two times *)
-  elim (lift_total V2 0 d) /3 width=7/
-| #a #I #V1 #T1 #H #d #e #Hde #HL destruct
-  elim (IH … V1 … Hde HL) // #V2 #HV12
-  elim (IH (L.ⓑ{I}V1) T1 … (d+1) e ??) -IH // [2,3: /2 width=1/ ] -Hde -HL #T2 #HT12
-  lapply (delift_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/ /3 width=4/
-| #I #V1 #T1 #H #d #e #Hde #HL destruct
-  elim (IH … V1 … Hde HL) // #V2 #HV12
-  elim (IH … T1 … Hde HL) -IH -Hde -HL // /3 width=2/
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma delift_inv_lref1_lt: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 → i < d → U2 = #i.
-#L #U2 #i #d #e * #U #HU #HU2 #Hid
-elim (tpss_inv_lref1 … HU) -HU
-[ #H destruct >(lift_inv_lref2_lt … HU2) //
-| * #K #V1 #V2 #Hdi
-  lapply (lt_to_le_to_lt … Hid Hdi) -Hid -Hdi #Hi
-  elim (lt_refl_false … Hi)
-]
-qed-.
-
-lemma delift_inv_lref1_be: ∀L,U2,d,e,i. L ⊢ ▼*[d, e] #i ≡ U2 →
-                           d ≤ i → i < d + e →
-                           ∃∃K,V1,V2. ⇩[0, i] L ≡ K. ⓓV1 &
-                                      K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 &
-                                      ⇧[0, d] V2 ≡ U2.
-#L #U2 #d #e #i * #U #HU #HU2 #Hdi #Hide
-elim (tpss_inv_lref1 … HU) -HU
-[ #H destruct elim (lift_inv_lref2_be … HU2 ? ?) //
-| * #K #V1 #V #_ #_ #HLK #HV1 #HVU
-  elim (lift_div_be … HVU … HU2 ? ?) -U // /2 width=1/ /3 width=6/
-]
-qed-.
-
-lemma delift_inv_lref1_ge: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 →
-                           d + e ≤ i → U2 = #(i - e).
-#L #U2 #i #d #e * #U #HU #HU2 #Hdei
-elim (tpss_inv_lref1 … HU) -HU
-[ #H destruct >(lift_inv_lref2_ge … HU2) //
-| * #K #V1 #V2 #_ #Hide
-  lapply (lt_to_le_to_lt … Hide Hdei) -Hide -Hdei #Hi
-  elim (lt_refl_false … Hi)
-]
-qed-.
-
-lemma delift_inv_lref1: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 →
-                        ∨∨ (i < d ∧ U2 = #i)
-                        |  (∃∃K,V1,V2. d ≤ i & i < d + e &
-                                       ⇩[0, i] L ≡ K. ⓓV1 &
-                                       K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 &
-                                       ⇧[0, d] V2 ≡ U2
-                           )
-                        |  (d + e ≤ i ∧ U2 = #(i - e)).
-#L #U2 #i #d #e #H
-elim (lt_or_ge i d) #Hdi
-[ elim (delift_inv_lref1_lt … H Hdi) -H /3 width=1/
-| elim (lt_or_ge i (d+e)) #Hide
-  [ elim (delift_inv_lref1_be … H Hdi Hide) -H /3 width=6/
-  | elim (delift_inv_lref1_ge … H Hide) -H /3 width=1/
-  ]
-]
-qed-.
-
-(* Properties on basic term relocation **************************************)
-
-lemma delift_lift_le: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
-                      ∀L,U1,d,e. dt + et ≤ d → ⇩[d, e] L ≡ K →
-                      ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d - et, e] T2 ≡ U2 →
-                      L ⊢ ▼*[dt, et] U1 ≡ U2.
-#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hdetd #HLK #HTU1 #U2 #HTU2
-elim (lift_total T d e) #U #HTU
-lapply (tpss_lift_le … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
-elim (lift_trans_ge … HT2 … HTU ?) -T // -Hdetd #T #HT2 #HTU
->(lift_mono … HTU2 … HT2) -T2 /2 width=3/
-qed.
-
-lemma delift_lift_be: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
-                      ∀L,U1,d,e. dt ≤ d → d ≤ dt + et →
-                      ⇩[d, e] L ≡ K → ⇧[d, e] T1 ≡ U1 →
-                      L ⊢ ▼*[dt, et + e] U1 ≡ T2.
-#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hdtd #Hddet #HLK #HTU1
-elim (lift_total T d e) #U #HTU
-lapply (tpss_lift_be … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
-lapply (lift_trans_be … HT2 … HTU ? ?) -T // -Hdtd -Hddet /2 width=3/
-qed.
-
-lemma delift_lift_ge: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
-                      ∀L,U1,d,e. d ≤ dt → ⇩[d, e] L ≡ K →
-                      ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
-                      L ⊢ ▼*[dt + e, et] U1 ≡ U2.
-#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hddt #HLK #HTU1 #U2 #HTU2
-elim (lift_total T d e) #U #HTU
-lapply (tpss_lift_ge … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
-elim (lift_trans_le … HT2 … HTU ?) -T // -Hddt #T #HT2 #HTU
->(lift_mono … HTU2 … HT2) -T2 /2 width=3/
-qed.
-
-lemma delift_inv_lift1_eq: ∀L,U1,T2,d,e. L ⊢ ▼*[d, e] U1 ≡ T2 →
-                           ∀K. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 → T1 = T2.
-#L #U1 #T2 #d #e * #U2 #HU12 #HTU2 #K #HLK #T1 #HTU1
-lapply (tpss_inv_lift1_eq … HU12 … HTU1) -L -K #H destruct
-lapply (lift_inj … HTU1 … HTU2) -U2 //
-qed-.
-
-lemma delift_lift_div_be: ∀L,T1,T,d,e,i. L ⊢ ▼*[i, d + e - i] T1 ≡ T →
-                          ∀T2. ⇧[d, i - d] T2 ≡ T → d ≤ i → i ≤ d + e →
-                          L ⊢ ▼*[d, e] T1 ≡ T2.
-#L #T1 #T #d #e #i * #T0 #HT10 #HT0 #T2 #HT2 #Hdi #Hide
-lapply (tpss_weak … HT10 d e ? ?) -HT10 // [ >commutative_plus /2 width=1/ ] #HT10
-lapply (lift_trans_be … HT2 … HT0 ? ?) -T //
->commutative_plus >commutative_plus in ⊢ (? ? (? % ?) ? ? → ?);
-<minus_le_minus_minus_comm // <plus_minus_m_m [ /2 width=3/ | /2 width=1/ ]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_ltpss.etc
deleted file mode 100644 (file)
index 2954223..0000000
+++ /dev/null
@@ -1,33 +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/unfold/ltpss_sn_alt.ma".
-include "basic_2/unfold/delift.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-(* Properties on sn partial unfold on local environments ********************)
-
-lemma delift_ltpss_sn_conf_eq: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 →
-                               ∀K. L ⊢ ▶* [d, e] K → K ⊢ ▼*[d, e] T1 ≡ T2.
-#L #T1 #T2 #d #e * #T #HT1 #HT2 #K #HLK
-elim (ltpss_sn_tpss_conf … HT1 … HLK) -HT1 -HLK #T0 #HT10 #HT0
-lapply (tpss_inv_lift1_eq … HT0 … HT2) -HT0 #H destruct /2 width=3/
-qed.
-
-lemma ltpss_sn_delift_trans_eq: ∀L,K,d,e. L ⊢ ▶* [d, e] K →
-                                ∀T1,T2. K ⊢ ▼*[d, e] T1 ≡ T2 → L ⊢ ▼*[d, e] T1 ≡ T2.
-#L #K #d #e #HLK #T1 #T2 * #T #HT1 #HT2
-lapply (ltpss_sn_tpss_trans_eq … HT1 … HLK) -K /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/delift_tpss.etc
deleted file mode 100644 (file)
index 662ae56..0000000
+++ /dev/null
@@ -1,92 +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/unfold/tpss_tpss.ma".
-include "basic_2/unfold/delift.ma".
-
-(* INVERSE BASIC TERM RELOCATION  *******************************************)
-
-(* Properties on partial unfold on terms ************************************)
-
-lemma delift_tpss_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                           ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                           ∀K. ⇩[dd, ee] L ≡ K → d + e ≤ dd →
-                           ∃∃T2. K ⊢ T1 ▶* [d, e] T2 & L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1
-elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
-elim (tpss_inv_lift1_le … HXU1 … HLK … HTX1 ?) -X1 -HLK // -H1 /3 width=5/
-qed.
-
-lemma delift_tps_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                          ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                          ∀K. ⇩[dd, ee] L ≡ K → d + e ≤ dd →
-                          ∃∃T2. K ⊢ T1 ▶* [d, e] T2 & L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=3/ qed.
-
-lemma delift_tpss_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                              ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                              ∀K. ⇩[dd, ee] L ≡ K →
-                              d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
-                              ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
-                                    L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1 #H2 #H3
-elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
-elim (tpss_inv_lift1_le_up … HXU1 … HLK … HTX1 ? ? ?) -X1 -HLK // -H1 -H2 -H3 /3 width=5/
-qed.
-
-lemma delift_tps_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                             ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                             ∀K. ⇩[dd, ee] L ≡ K →
-                             d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
-                             ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
-                                   L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=6/ qed.
-
-lemma delift_tpss_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                           ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                           ∀K. ⇩[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
-                           ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
-                                 L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1 #H2
-elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
-elim (tpss_inv_lift1_be … HXU1 … HLK … HTX1 ? ?) -X1 -HLK // -H1 -H2 /3 width=5/
-qed.
-
-lemma delift_tps_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                          ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                          ∀K. ⇩[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
-                          ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
-                                L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=3/ qed.
-
-lemma delift_tpss_conf_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                           ∀T. L ⊢ ▼*[d, e] U1 ≡ T → L ⊢ ▼*[d, e] U2 ≡ T.
-#L #U1 #U2 #d #e #HU12 #T * #X1 #HUX1 #HTX1
-elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
-lapply (tpss_inv_lift1_eq … HXU1 … HTX1) -HXU1 #H destruct /2 width=3/
-qed.
-
-lemma delift_tps_conf_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                          ∀T. L ⊢ ▼*[d, e] U1 ≡ T → L ⊢ ▼*[d, e] U2 ≡ T.
-/3 width=3/ qed.
-
-lemma tpss_delift_trans_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                            ∀T. L ⊢ ▼*[d, e] U2 ≡ T → L ⊢ ▼*[d, e] U1 ≡ T.
-#L #U1 #U2 #d #e #HU12 #T * #X1 #HUX1 #HTX1
-lapply (tpss_trans_eq … HU12 … HUX1) -U2 /2 width=3/
-qed.
-
-lemma tps_delift_trans_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                           ∀T. L ⊢ ▼*[d, e] U2 ≡ T → L ⊢ ▼*[d, e] U1 ≡ T.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin.etc
deleted file mode 100644 (file)
index f92cd54..0000000
+++ /dev/null
@@ -1,41 +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 "hvbox( ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'TSubst $T1 $d $e $T2 }.
-
-include "basic_2/unfold/ltpss_sn.ma".
-
-(* BASIC LOCAL ENVIRONMENT THINNING *****************************************)
-
-definition thin: nat → nat → relation lenv ≝
-                 λd,e,L1,L2. ∃∃L. L1 ⊢ ▶* [d, e] L & ⇩[d, e] L ≡ L2.
-
-interpretation "basic thinning (local environment)"
-   'TSubst L1 d e L2 = (thin d e L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma ldrop_thin: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ▼*[d, e] L1 ≡ L2.
-/2 width=3/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma thin_inv_thin1: ∀I,K1,V1,L2,e. ▼*[0, e] K1.ⓑ{I} V1 ≡ L2 → 0 < e →
-                      ▼*[0, e - 1] K1 ≡ L2.
-#I #K1 #V1 #L2 #e * #X #HK1 #HL2 #e
-elim (ltpss_sn_inv_tpss21 … HK1 ?) -HK1 // #K #V #HK1 #_ #H destruct
-lapply (ldrop_inv_ldrop1 … HL2 ?) -HL2 // /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_delift.etc
deleted file mode 100644 (file)
index b5ffc5e..0000000
+++ /dev/null
@@ -1,102 +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/unfold/delift_tpss.ma".
-include "basic_2/unfold/delift_ltpss.ma".
-include "basic_2/unfold/thin.ma".
-
-(* BASIC DELIFT ON LOCAL ENVIRONMENTS ***************************************)
-
-(* Inversion lemmas on inverse basic term relocation ************************)
-
-lemma thin_inv_delift1: ∀I,K1,V1,L2,d,e. ▼*[d, e] K1. ⓑ{I} V1 ≡ L2 → 0 < d →
-                        ∃∃K2,V2. ▼*[d - 1, e] K1 ≡ K2 &
-                                 K1 ⊢ ▼*[d - 1, e] V1 ≡ V2 &
-                                 L2 = K2. ⓑ{I} V2.
-#I #K1 #V1 #L2 #d #e * #X #HK1 #HL2 #e
-elim (ltpss_sn_inv_tpss11 … HK1 ?) -HK1 // #K #V #HK1 #HV1 #H destruct
-elim (ldrop_inv_skip1 … HL2 ?) -HL2 // #K2 #V2 #HK2 #HV2 #H destruct /3 width=5/
-qed-.
-
-(* Properties on inverse basic term relocation ******************************)
-
-lemma thin_delift: ∀L1,L2,d,e. ▼*[d, e] L1 ≡ L2 → ∀V1,V2. L1 ⊢ ▼*[d, e] V1 ≡ V2 →
-                   ∀I. ▼*[d + 1, e] L1.ⓑ{I}V1 ≡ L2.ⓑ{I}V2.
-#L1 #L2 #d #e * #L #HL1 #HL2 #V1 #V2 * #V #HV1 #HV2 #I
-elim (ltpss_sn_tpss_conf … HV1 … HL1) -HV1 #V0 #HV10 #HV0
-lapply (tpss_inv_lift1_eq … HV0 … HV2) -HV0 #H destruct
-lapply (ltpss_sn_tpss_trans_eq … HV10 … HL1) -HV10 /3 width=5/
-qed.
-
-lemma thin_delift_tpss_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                                ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                                ∀K. ▼*[dd, ee] L ≡ K → d + e ≤ dd →
-                                ∃∃T2. K ⊢ T1 ▶* [d, e] T2 &
-                                      L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdedd
-lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
-elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
-elim (delift_tpss_conf_le … HU1 … HUT1 … HYK ?) -HU1 -HUT1 -HYK // -Hdedd #T #HT1 #HUT
-lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
-lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
-qed.
-
-lemma thin_delift_tps_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                               ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                               ∀K. ▼*[dd, ee] L ≡ K → d + e ≤ dd →
-                               ∃∃T2. K ⊢ T1 ▶* [d, e] T2 &
-                                     L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=3/ qed.
-
-lemma thin_delift_tpss_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                                   ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                                   ∀K. ▼*[dd, ee] L ≡ K →
-                                   d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
-                                   ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
-                                         L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdd #Hdde #Hddee
-lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
-elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
-elim (delift_tpss_conf_le_up … HU1 … HUT1 … HYK ? ? ?) -HU1 -HUT1 -HYK // -Hdd -Hdde -Hddee #T #HT1 #HUT
-lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
-lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
-qed.
-
-lemma thin_delift_tps_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                                  ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                                  ∀K. ▼*[dd, ee] L ≡ K →
-                                  d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
-                                  ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
-                                        L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=6 by thin_delift_tpss_conf_le_up, tpss_strap2/ qed. (**) (* too slow without trace *)
-
-lemma thin_delift_tpss_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
-                                ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                                ∀K. ▼*[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
-                                ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
-                                      L ⊢ ▼*[dd, ee] U2 ≡ T2.
-#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdd #Hddee
-lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
-elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
-elim (delift_tpss_conf_be … HU1 … HUT1 … HYK ? ?) -HU1 -HUT1 -HYK // -Hdd -Hddee #T #HT1 #HUT
-lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
-lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
-qed.
-
-lemma thin_delift_tps_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
-                               ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
-                               ∀K. ▼*[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
-                               ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
-                                     L ⊢ ▼*[dd, ee] U2 ≡ T2.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/thin_ldrop.etc
deleted file mode 100644 (file)
index f26c26f..0000000
+++ /dev/null
@@ -1,58 +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/unfold/ltpss_sn_ldrop.ma".
-include "basic_2/unfold/thin.ma".
-
-(* BASIC LOCAL ENVIRONMENT THINNING *****************************************)
-
-(* Properties on local environment slicing **********************************)
-
-lemma thin_ldrop_conf_ge: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
-                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                          d1 + e1 ≤ e2 → ⇩[0, e2 - e1] L1 ≡ L2.
-#L0 #L1 #d1 #e1 * /3 width=8 by ltpss_sn_ldrop_conf_ge, ldrop_conf_ge/
-qed.
-
-lemma thin_ldrop_conf_be: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
-                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
-                          ∃∃L. ▼*[0, d1 + e1 - e2] L2 ≡ L & ⇩[0, d1] L1 ≡ L.
-#L0 #L1 #d1 #e1 * #L #HL0 #HL1 #L2 #e2 #HL02 #Hd1e2 #He2de1
-elim (ltpss_sn_ldrop_conf_be … HL0 … HL02 ? ?) -L0 // #L0 #HL20 #HL0
-elim (ldrop_conf_be … HL1 … HL0 ? ?) -L // -Hd1e2 -He2de1 /3 width=3/
-qed.
-
-lemma thin_ldrop_conf_le: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
-                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                          ∃∃L. ▼*[d1 - e2, e1] L2 ≡ L & ⇩[0, e2] L1 ≡ L.
-#L0 #L1 #d1 #e1 * #L #HL0 #HL1 #L2 #e2 #HL02 #He2d1
-elim (ltpss_sn_ldrop_conf_le … HL0 … HL02 ?) -L0 // #L0 #HL20 #HL0
-elim (ldrop_conf_le … HL1 … HL0 ?) -L // -He2d1 /3 width=3/
-qed.
-
-lemma thin_ldrop_trans_ge: ∀L1,L0,d1,e1. ▼*[d1, e1] L1 ≡ L0 →
-                           ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
-                           d1 ≤ e2 → ⇩[0, e1 + e2] L1 ≡ L2.
-#L1 #L0 #d1 #e1 * #L #HL1 #HL0 #L2 #e2 #HL02 #Hd1e2
-lapply (ldrop_trans_ge … HL0 … HL02 ?) -L0 // #HL2
-lapply (ltpss_sn_ldrop_trans_ge … HL1 … HL2 ?) -L // /2 width=1/
-qed.
-
-lemma thin_ldrop_trans_le: ∀L1,L0,d1,e1. ▼*[d1, e1] L1 ≡ L0 →
-                           ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
-                           ∃∃L. ▼*[d1 - e2, e1] L ≡ L2 & ⇩[0, e2] L1 ≡ L.
-#L1 #L0 #d1 #e1 * #L #HL1 #HL0 #L2 #e2 #HL02 #He2d1
-elim (ldrop_trans_le … HL0 … HL02 He2d1) -L0 #L0 #HL0 #HL02
-elim (ltpss_sn_ldrop_trans_le … HL1 … HL0 He2d1) -L -He2d1 /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/delift/tpr_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/delift/tpr_delift.etc
deleted file mode 100644 (file)
index 3fff8f2..0000000
+++ /dev/null
@@ -1,27 +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/unfold/delift.ma".
-include "basic_2/reducibility/ltpr_tpss.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
-
-(* Properties on inverse basic term relocation ******************************)
-
-lemma tpr_delift_conf: ∀U1,U2. U1 ➡ U2 → ∀L,T1,d,e. L ⊢ ▼*[d, e] U1 ≡ T1 →
-                       ∃∃T2. T1 ➡ T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
-#U1 #U2 #HU12 #L #T1 #d #e * #W1 #HUW1 #HTW1
-elim (tpr_tpss_conf … HU12 … HUW1) -U1 #U1 #HWU1 #HU21
-elim (tpr_inv_lift1 … HWU1 … HTW1) -W1 /3 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/etc/cpr_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/etc/cpr_conj.etc
deleted file mode 100644 (file)
index 6ffdb54..0000000
+++ /dev/null
@@ -1,88 +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/lpr_ldrop.ma".
-
-include "basic_2/unfold/fsups.ma".
-include "basic_2/reducibility/lpr_ldrop.ma".
-
-lamma pippo: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀V1,i. ⇧[i, 1] V1 ≡ T1 → T2 = #i → ⊥.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2
-[ #I #L1 #V #W1 #j #H1 #H2
-  elim (lift_inv_lref2 … H1) -H1 * #H1 #H3
-
- HVT2 : ()
- HV2 : (K2⊢V➡V2)
-
-
-thaorem cpr_trans_lpr: ∀L1,T1,T. L1 ⊢ T1 ➡ T → ∀L2. L1 ⊢ ➡ L2 →
-                       ∀T2. L2 ⊢ T ➡ T2 →
-                       (⦃L2, T2⦄ ⊃* ⦃L1, T1⦄ → ⊥) ∨ T1 = T.
-#L1 #T1 @(fsupp_wf_ind … L1 T1) -L1 -T1 #n #IH #L1 * [|*]
-[ #I #Hn #T #H1 #L2 #HL12 #T2 #HT2 destruct -IH
-  elim (cpr_inv_atom1 … H1) -H1
-  [ #H destruct
-    elim (cpr_inv_atom1 … HT2) -HT2
-    [ #H destruct //
-    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct //
-    ]
-  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
-    lapply (ldrop_pair2_fwd_fw … HLK1 (#i)) #HKV1
-    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
-    elim (lpr_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 #HLK2
-    elim (cpr_inv_lift1 … HT2 … HLK2 … HVT) -HT2 -HLK2 -HVT #V2 #HVT2 #HV2
-    @or_introl #H
-
-
-
-
-
-
-    elim (lift_inv_lref2 … HVT2) -HVT2 * #H #_
-    [ elim (lt_zero_false … H)
-    | >commutative_plus in H; >plus_plus_comm_23 #H
-      elim (le_plus_xySz_x_false … H)
-    ]
-  ]
-| #a #I #V1 #T1 #Hn #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpr_inv_bind1 … H1) -H1 *
-  [ #V #T #HV1 #HT1 #H destruct
-    elim (cpr_inv_bind1 … H2) -H2 *
-    [ #V2 #T2 #HV2 #HT2 #H destruct
-      elim (IH … HV1 … HV2) // #HV12 destruct
-      [ @or_introl #H destruct /2 width=1/
-      | elim (IH … HT1 … HT2) // /2 width=1/ -L1 -L2 #HT12 destruct
-        @or_introl #H destruct /2 width=1/
-      ]
-    | #T2 #HT2 #HXT2 #H1 #H2 destruct
-      elim (IH … HT1 … HT2) // /2 width=1/ -L1 -L2 #HT12 destruct
-      |        elim (term_eq_dec V1 V) #HV1 destruct
-
-    ]
-  | #Y1 #HTY1 #HXY1 #H11 #H12 destruct
-    elim (lift_total (+ⓓV1.T1) 0 1) #Y2 #HXY2
-    lapply (cpr_lift … H2 (L2.ⓓV1) … HXY1 … HXY2) /2 width=1/ -X1 /4 width=5/
-  ]
-| #I #V1 #T1 #Hn #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpr_inv_flat1 … H1) -H1 *
-  [ #V #T #HV1 #HT1 #H destruct
-    elim (cpr_inv_flat1 … H2) -H2 *
-    [ #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
-    | #HX2 #H destruct /3 width=5/
-    ]
-  | #HX1 #H destruct /3 width=5/
-]
-qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/etc/ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/etc/ldrop.etc
deleted file mode 100644 (file)
index e4caef0..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-lemma ldrop_bor1: ∀L1,L2,s1,s2,d,e. ⇩[s1, d, e] L1 ≡ L2 → ⇩[s1 ∨ s2, d, e] L1 ≡ L2.
-#L1 #L2 * /2 width=1 by ldrop_gen/
-qed.
-
-lemma ldrop_bor2: ∀L1,L2,s1,s2,d,e. ⇩[s2, d, e] L1 ≡ L2 → ⇩[s1 ∨ s2, d, e] L1 ≡ L2.
-#L1 #L2 #s1 #s2 >commutative_orb /2 width=1 by ldrop_bor1/
-qed.
-
-(* Basic_1: was: drop_conf_rev *)
-axiom ldrop_div: ∀e1,L1,L. ⇩[0, e1] L1 ≡ L → ∀e2,L2. ⇩[0, e2] L2 ≡ L →
-                 ∃∃L0. ⇩[0, e1] L0 ≡ L2 & ⇩[e1, e2] L0 ≡ L1.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbc_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbc_lift.etc
deleted file mode 100644 (file)
index 2862901..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-include "basic_2/reduction/lpx_ldrop.ma".
-
-lemma lpx_fpbc_trans: ∀h,g,G1,G2,K1,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ →
-                      ⦃G1, K1⦄ ⊢ ➡[h, g] L1 →
-                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ≻[h, g] ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g] L2.
-#h #g #G1 #G2 #K1 #L1 #L2 #T1 #T2 * -G2 -L2 -T2
-[ #G2 #L2 #T2 #H12 #HKL1 elim (lpx_fqu_trans … H12 … HKL1) -L1
-  /3 width=5 by fpbc_fqu, ex3_2_intro/
-| #T2 #HT12 #H #HKL1  
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fleq/fpbs.etc
deleted file mode 100644 (file)
index 017421f..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-lemma fpbs_fpbu_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                    ⦃G1, L1, T1⦄ ≡[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
-[ /2 width=1 by or_introl/
-| #G1 #G #L1 #L #T1 #T #H1 #_ * [ #H2 | * #G0 #L0 #T0 #H0 #H02 ]
-  elim (fpb_fpbu … H1) -H1 #H1
-  [ /3 width=1 by  
-*)
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim(fpbs_inv_alt … H) -H
-#L0 #L #T #HT1 #HT2 #HL0 #HL2 elim (eq_term_dec T1 T) #H destruct
-[ -HT1 elim (fqus_inv_gen … HT2) -HT2
-  [ #H elim (fqup_inv_step_sn … H) -H
-    /4 width=11 by fpbs_intro_alt, fpbu_fqu, ex2_3_intro, or_intror/
-  | * #HG #HL #HT destruct elim (lleq_dec T2 L0 L 0) #H
-    [ /4 width=3 by fleq_intro, lleq_trans, or_introl/
-    | elim (lpxs_nlleq_inv_step_sn … HL0 H) -HL0 -H
-      /5 width=7 by lpxs_lleq_fpbs, fpbu_lpx, lleq_trans, ex2_3_intro, or_intror/
-    ]
-  ]
-| elim (cpxs_neq_inv_step_sn … HT1 H) -HT1 -H
-  /5 width=11 by fpbs_intro_alt, fpbu_cpx, ex2_3_intro, or_intror/
-]
-qed-.
-
-(* alternative proof that needs decidability of bteq to go in fpbs.ma 
- * or lpx_fpbc_trans to go in fpbs_lift.ma (possibly)  
-*)
-
-axiom lpx_bteq_trans: ∀h,g,G1,G2,L1,L,L2,T1,T2. ⦃G1, L1⦄ ⊢➡ [h, g] L →
-                      ⦃G1, L, T1⦄ ⋕[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⋕[h, g] ⦃G2, L2, T2⦄.
-
-lemma fpbs_fwd_fpb_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                       ⦃G1, L1, T1⦄ ⋕[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 @(fpbs_ind_dx … H) -G1 -L1 -T1 [ /2 width=1 by or_introl/ ] (**) (* auto fails without brackets *)
-#G1 #G #L1 #L #T1 #T *
-[ #G0 #L0 #T0 #H #H02 #IH1 elim (fquq_inv_gen … H) -H
-  [ -IH1 /4 width=5 by fpbc_fqu, ex2_3_intro, or_intror/
-  | -H02 * #HG #HL #HT destruct /2 width=1 by/
-  ]
-| #T0 #HT10 #H02 #IH02 elim (eq_term_dec T1 T0) #H destruct
-  [ -H02 /2 width=1 by/
-  | -IH02 /5 width=5 by fpbc_cpx, ex2_3_intro, or_intror/
-  ]
-| #L0 #HL10 #_ * [ /3 width=3 by or_introl, lpx_bteq_trans/ ]
-  * #G3 #L3 #T3 #H13 #H32
-
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa.etc
deleted file mode 100644 (file)
index 8f72937..0000000
+++ /dev/null
@@ -1,36 +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/rajust_5.ma".
-include "basic_2/substitution/drop.ma".
-
-(* AJUSTMENT ****************************************************************)
-
-inductive fpa (s:bool): bi_relation lenv term ≝
-| fpa_fwd: ∀L,K,T,U,d,e. ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U → fpa s K T L U
-| fpa_bwd: ∀L,K,T,U,d,e. ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U → fpa s L U K T
-.
-
-interpretation
-   "ajustment (restricted closure)"
-   'RAjust L1 T1 s L2 T2 = (fpa s L1 T1 L2 T2).
-
-(* Basic properties *********************************************************)
-
-lemma fpa_refl: ∀s. bi_reflexive … (fpa s).
-/2 width=4 by fpa_fwd/ qed.
-
-lemma fpa_sym: ∀s. bi_symmetric … (fpa s).
-#s #L1 #L2 #T1 #T2 * /2 width=4 by fpa_fwd, fpa_bwd/
-qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa_fpa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpa_fpa.etc
deleted file mode 100644 (file)
index c62b8bf..0000000
+++ /dev/null
@@ -1,22 +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/fpa.ma".
-
-(* AJUSTMENT ****************************************************************)
-
-(* Main properties **********************************************************)
-
-theorem fpa_conf: ∀s. bi_confluent … (fpa s).
-/3 width=4 by fpa_sym, ex2_2_intro/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas.etc
deleted file mode 100644 (file)
index 6817d8c..0000000
+++ /dev/null
@@ -1,59 +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/rajuststar_5.ma".
-include "basic_2/substitution/fpa.ma".
-
-(* MULTIPLE AJUSTMENT *******************************************************)
-
-definition fpas: bool → bi_relation lenv term ≝ λs. bi_TC … (fpa s).
-
-interpretation
-   "multiple ajustment (restricted closure)"
-   'RAjustStar L1 T1 s L2 T2 = (fpas s L1 T1 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma fpas_ind: ∀L1,T1,s. ∀R:relation2 …. R L1 T1 →
-                (∀L,L2,T,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳[s] ⦃L2, T2⦄ → R L T → R L2 T2) →
-                ∀L2,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ → R L2 T2.
-#L1 #T1 #s #R #IH1 #IH2 #L2 #T2 #H
-@(bi_TC_star_ind … IH1 IH2 L2 T2 H) //
-qed-.
-
-lemma fpas_ind_dx: ∀L2,T2,s. ∀R:relation2 …. R L2 T2 →
-                   (∀L1,L,T1,T. ⦃L1, T1⦄ ⇳[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ → R L T → R L1 T1) →
-                   ∀L1,T1. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ → R L1 T1.
-#L2 #T2 #s #R #IH1 #IH2 #L1 #T1 #H
-@(bi_TC_star_ind_dx … IH1 IH2 L1 T1 H) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma fpas_refl: ∀s. bi_reflexive … (fpas s).
-/2 width=1 by bi_inj/ qed.
-
-lemma fpas_sym: ∀s. bi_symmetric … (fpas s).
-/3 width=1 by fpa_sym, bi_TC_symmetric/ qed-.
-
-lemma fpa_fpas: ∀L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L2, T2⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
-/2 width=1 by bi_inj/ qed.
-
-lemma fpas_strap1: ∀L1,L,L2,T1,T,T2,s. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳[s] ⦃L2, T2⦄ →
-                   ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
-/2 width=4 by bi_step/ qed-.
-
-lemma fpas_strap2: ∀L1,L,L2,T1,T,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ →
-                   ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
-/2 width=4 by bi_TC_strap/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_fpas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_fpas.etc
deleted file mode 100644 (file)
index 28d648e..0000000
+++ /dev/null
@@ -1,40 +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/fpa_fpa.ma".
-include "basic_2/multiple/fpas.ma".
-
-(* MULTIPLE AJUSTMENT *******************************************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fpas_strip: ∀L0,L1,L2,T0,T1,T2,s. ⦃L0, T0⦄ ⇳[s] ⦃L1, T1⦄ → ⦃L0, T0⦄ ⇳*[s] ⦃L2, T2⦄ →
-                  ∃∃L,T. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ & ⦃L2, T2⦄ ⇳[s] ⦃L, T⦄.
-/3 width=4 by fpa_conf, bi_TC_strip/ qed-.
-
-(* Main properties **********************************************************)
-
-theorem fpas_conf: ∀s. bi_confluent … (fpas s).
-/3 width=4 by fpa_conf, bi_TC_confluent/ qed-.
-
-theorem fpas_trans: ∀s. bi_transitive … (fpas s).
-/2 width=4 by bi_TC_transitive/ qed-.
-
-theorem fpas_canc_sn: ∀L,L1,L2,T,T1,T2,s.
-                      ⦃L, T⦄ ⇳*[s] ⦃L1, T1⦄→ ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
-/3 width=4 by fpas_trans, fpas_sym/ qed-.
-
-theorem fpas_canc_dx: ∀L1,L2,L,T1,T2,T,s.
-                      ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L2, T2⦄ ⇳*[s] ⦃L, T⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
-/3 width=4 by fpas_trans, fpas_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_vector.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/fpas_vector.etc
deleted file mode 100644 (file)
index 65e8190..0000000
+++ /dev/null
@@ -1,56 +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/grammar/term_vector.ma".
-include "basic_2/multiple/fpas.ma".
-
-(* MULTIPLE VECTOR AJUSTMENT ************************************************)
-
-inductive fpasv (s:bool): bi_relation lenv (list term) ≝
-| fpasv_nil : ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄  → fpasv s L1 (◊) L2 (◊)
-| fpasv_cons: ∀L1,L2,T1s,T2s,T1,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄  →
-              fpasv s L1 T1s L2 T2s →
-              fpasv s L1 (T1 @ T1s) L2 (T2 @ T2s)
-.
-
-interpretation
-   "multiple vector ajustment (restricted closure)"
-   'RAjustStar L1 T1s s L2 T2s = (fpasv s L1 T1s L2 T2s).
-
-(* Basic inversion lemmas ***************************************************)
-
-
-
-(* Basic_1: was just: lifts1_flat (left to right) *)
-lemma fpas_inv_applv1: ∀L1,L2,V1s,T1,X,s. ⦃L1, Ⓐ V1s.T1⦄ ⇳*[s] ⦃L2, X⦄ →
-                       ∃∃V2s,T2. ⦃L1, V1s⦄ ⇳*[s] ⦃L2, V2s⦄ & ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ &
-                                 X = Ⓐ V2s.T2.
-#L1 #L2 #V1s elim V1s -V1s
-[ #T1 #X #s #H
-  @(ex3_2_intro … (◊) X) /2 width=3 by fpasv_nil/ (**) (* explicit constructor *)
-| #V1 #V1s #IHV1s #T1 #X #s #H
-  elim (lifts_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
-  elim (IHV1s … HY) -IHV1s -HY #V2s #T2 #HV12s #HT12 #H destruct
-  @(ex3_2_intro) [4: // |3: /2 width=2 by liftsv_cons/ |1,2: skip | // ] (**) (* explicit constructor *)
-]
-qed-.
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was just: lifts1_flat (right to left) *)
-lemma lifts_applv: ∀V1s,V2s,des. ⇧*[des] V1s ≡ V2s →
-                   ∀T1,T2. ⇧*[des] T1 ≡ T2 →
-                   ⇧*[des] Ⓐ V1s. T1 ≡ Ⓐ V2s. T2.
-#V1s #V2s #des #H elim H -V1s -V2s /3 width=1 by lifts_flat/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp.etc
deleted file mode 100644 (file)
index b9b2db8..0000000
+++ /dev/null
@@ -1,48 +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/grammar/genv.ma".
-include "basic_2/multiple/fpas.ma".
-
-(* GENERIC COMPUTATION PROPERTIES *******************************************)
-
-definition candidate: Type[0] ≝ relation3 genv lenv term.
-
-definition CP0 ≝ λRR:relation4 genv lenv term term. λRS:relation term.
-                 ∀G,L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L2, T2⦄ →
-                 NF … (RR G L1) RS T1 → NF … (RR G L2) RS T2.
-
-definition CP0s ≝ λRR:relation4 genv lenv term term. λRS:relation term.
-                  ∀G,L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ →
-                  NF … (RR G L1) RS T1 → NF … (RR G L2) RS T2.
-
-definition CP1 ≝ λRR:relation4 genv lenv term term. λRS:relation term.
-                 ∀G,L. ∃k. NF … (RR G L) RS (⋆k).
-
-definition CP2 ≝ λRP:candidate.
-                 ∀G,L,T,k. RP G L (ⓐ⋆k.T) → RP G L T.
-
-(* requirements for generic computation properties *)
-record gcp (RR:relation4 genv lenv term term) (RS:relation term) (RP:candidate) : Prop ≝
-{ cp0: CP0 RR RS;
-  cp1: CP1 RR RS;
-  cp2: CP2 RP
-}.
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was just: nf2_lift1 *)
-lemma gcp_fpas: ∀RR,RS. CP0 RR RS → CP0s RR RS.
-#RR #RS #HRR #G #L1 #L2 #T1 #T2 #s #H @(fpas_ind … H) -L2 -T2 /3 width=5 by/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp_cr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/gcp_cr.etc
deleted file mode 100644 (file)
index 7649098..0000000
+++ /dev/null
@@ -1,185 +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/ineint_5.ma".
-include "basic_2/grammar/aarity.ma".
-include "basic_2/substitution/lift_vector.ma".
-include "basic_2/computation/gcp.ma".
-
-(* GENERIC COMPUTATION PROPERTIES *******************************************)
-
-definition S0 ≝ λC:candidate. ∀G,L1,L2,T1,T2. ⦃L1, T1⦄ ⇳[Ⓕ] ⦃L2, T2⦄ →
-                C G L1 T1 → C G L2 T2.
-
-definition S0s ≝ λC:candidate. ∀G,L1,L2,T1,T2. ⦃L1, T1⦄ ⇳*[Ⓕ] ⦃L2, T2⦄ →
-                 C G L1 T1 → C G L2 T2.
-
-(* Note: this is Girard's CR1 *)
-definition S1 ≝ λRP,C:candidate.
-                ∀G,L,T. C G L T → RP G L T.
-
-(* Note: this is Tait's iii, or Girard's CR4 *)
-definition S2 ≝ λRR:relation4 genv lenv term term. λRS:relation term. λRP,C:candidate.
-                ∀G,L,Vs. all … (RP G L) Vs →
-                ∀T. 𝐒⦃T⦄ → NF … (RR G L) RS T → C G L (ⒶVs.T).
-
-(* Note: this generalizes Tait's ii *)
-definition S3 ≝ λC:candidate.
-                ∀a,G,L,Vs,V,T,W.
-                C G L (ⒶVs.ⓓ{a}ⓝW.V.T) → C G L (ⒶVs.ⓐV.ⓛ{a}W.T).
-
-definition S4 ≝ λRP,C:candidate.
-                ∀G,L,Vs. all … (RP G L) Vs → ∀k. C G L (ⒶVs.⋆k).
-
-definition S5 ≝ λC:candidate. ∀I,G,L,K,Vs,V1,V2,i.
-                C G L (ⒶVs.V2) → ⇧[0, i+1] V1 ≡ V2 →
-                ⇩[i] L ≡ K.ⓑ{I}V1 → C G L (ⒶVs.#i).
-
-definition S6 ≝ λRP,C:candidate.
-                ∀G,L,V1s,V2s. ⇧[0, 1] V1s ≡ V2s →
-                ∀a,V,T. C G (L.ⓓV) (ⒶV2s.T) → RP G L V → C G L (ⒶV1s.ⓓ{a}V.T).
-
-definition S7 ≝ λC:candidate.
-                ∀G,L,Vs,T,W. C G L (ⒶVs.T) → C G L (ⒶVs.W) → C G L (ⒶVs.ⓝW.T).
-
-(* requirements for the generic reducibility candidate *)
-record gcr (RR:relation4 genv lenv term term) (RS:relation term) (RP,C:candidate) : Prop ≝
-{ s0: S0 C;
-  s1: S1 RP C;
-  s2: S2 RR RS RP C;
-  s3: S3 C;
-  s4: S4 RP C;
-  s5: S5 C;
-  s6: S6 RP C;
-  s7: S7 C
-}.
-
-(* the functional construction for candidates *)
-definition cfun: candidate → candidate → candidate ≝
-                 λC1,C2,G,K,T. ∀L,V,U. ⦃K, T⦄ ⇳*[Ⓕ] ⦃L, U⦄ →
-                 C1 G L V → C2 G L (ⓐV.U).
-
-(* the reducibility candidate associated to an atomic arity *)
-let rec acr (RP:candidate) (A:aarity) on A: candidate ≝
-match A with
-[ AAtom     ⇒ RP
-| APair B A ⇒ cfun (acr RP B) (acr RP A)
-].
-
-interpretation
-   "candidate of reducibility of an atomic arity (abstract)"
-   'InEInt RP G L T A = (acr RP A G L T).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was just: sc3_lift1 *)
-lemma gcr_fpas: ∀C. S0 C → S0s C.
-#C #HC #G #L1 #L2 #T1 #T2 #H @(fpas_ind … H) -L2 -T2 /3 width=5 by/
-qed.
-(*
-lemma rp_lifts: ∀RR,RS,RP. gcr RR RS RP RP →
-                ∀des,G,L0,L,V,V0. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] V ≡ V0 →
-                RP G L V → RP G L0 V0.
-#RR #RS #RP #HRP #des #G #L0 #L #V #V0 #HL0 #HV0 #HV
-@gcr_lifts /width=7 by/
-@(s0 … HRP)
-qed.
-
-(* Basic_1: was only: sns3_lifts1 *)
-lemma rp_liftsv_all: ∀RR,RS,RP. gcr RR RS RP RP →
-                     ∀des,G,L0,L,Vs,V0s. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] Vs ≡ V0s →
-                     all … (RP G L) Vs → all … (RP G L0) V0s.
-#RR #RS #RP #HRP #des #G #L0 #L #Vs #V0s #HL0 #H elim H -Vs -V0s normalize //
-#T1s #T2s #T1 #T2 #HT12 #_ #IHT2s * /3 width=7 by rp_lifts, conj/
-qed.
-*)
-(* Basic_1: was:
-   sc3_sn3 sc3_abst sc3_appl sc3_abbr sc3_bind sc3_cast sc3_lift
-*)
-lemma acr_gcr: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-               ∀A. gcr RR RS RP (acr RP A).
-#RR #RS #RP #H1RP #H2RP #A elim A -A //
-#B #A #IHB #IHA @mk_gcr
-[ /3 width=4 by fpas_strap2/
-| #G #L #T #H
-  elim (cp1 … H1RP G L) #k #HK
-  lapply (H L (⋆k) T ? ?) -H //
-  [ @(s2 … IHB … (◊)) //
-  | #H @(cp2 … H1RP … k) @(s1 … IHA) //
-  ]
-| #G #L #Vs #HVs #T #H1T #H2T #L0 #V0 #X #H #HB
-  elim (lifts_inv_applv1 … H) -H #V0s #T0 #HV0s #HT0 #H destruct
-  lapply (s1 … IHB … HB) #HV0
-  @(s2 … IHA … (V0 @ V0s))
-  /3 width=14 by rp_liftsv_all, gcp_lifts, cp0, lifts_simple_dx, conj/
-| #a #G #L #Vs #U #T #W #HA #L0 #V0 #X #des #HL0 #H #HB
-  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
-  elim (lifts_inv_flat1 … HY) -HY #U0 #X #HU0 #HX #H destruct
-  elim (lifts_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT0 #H destruct
-  @(s3 … IHA … (V0 @ V0s)) /5 width=6 by lifts_applv, lifts_flat, lifts_bind/
-| #G #L #Vs #HVs #k #L0 #V0 #X #des #HL0 #H #HB
-  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
-  >(lifts_inv_sort1 … HY) -Y
-  lapply (s1 … IHB … HB) #HV0
-  @(s4 … IHA … (V0 @ V0s)) /3 width=7 by rp_liftsv_all, conj/
-| #I #G #L #K #Vs #V1 #V2 #i #HA #HV12 #HLK #L0 #V0 #X #des #HL0 #H #HB
-  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
-  elim (lifts_inv_lref1 … HY) -HY #i0 #Hi0 #H destruct
-  elim (drops_drop_trans … HL0 … HLK) #X #des0 #i1 #HL02 #H #Hi1 #Hdes0
-  >(at_mono … Hi1 … Hi0) in HL02; -i1 #HL02
-  elim (drops_inv_skip2 … Hdes0 … H) -H -des0 #L2 #W1 #des0 #Hdes0 #HLK #HVW1 #H destruct
-  elim (lift_total W1 0 (i0 + 1)) #W2 #HW12
-  elim (lifts_lift_trans  … Hdes0 … HVW1 … HW12) // -Hdes0 -Hi0 #V3 #HV13 #HVW2
-  >(lift_mono … HV13 … HV12) in HVW2; -V3 #HVW2
-  @(s5 … IHA … (V0 @ V0s) … HW12 HL02) /3 width=5 by lifts_applv/
-| #G #L #V1s #V2s #HV12s #a #V #T #HA #HV #L0 #V10 #X #des #HL0 #H #HB
-  elim (lifts_inv_applv1 … H) -H #V10s #Y #HV10s #HY #H destruct
-  elim (lifts_inv_bind1 … HY) -HY #V0 #T0 #HV0 #HT0 #H destruct
-  elim (lift_total V10 0 1) #V20 #HV120
-  elim (liftv_total 0 1 V10s) #V20s #HV120s
-  @(s6 … IHA … (V10 @ V10s) (V20 @ V20s)) /3 width=7 by rp_lifts, liftv_cons/
-  @(HA … (des + 1)) /2 width=2 by drops_skip/
-  [ @lifts_applv //
-    elim (liftsv_liftv_trans_le … HV10s … HV120s) -V10s #V10s #HV10s #HV120s
-    >(liftv_mono … HV12s … HV10s) -V1s //
-  | @(s0 … IHB … HB … HV120) /2 width=2 by drop_drop/
-  ]
-| #G #L #Vs #T #W #HA #HW #L0 #V0 #X #des #HL0 #H #HB
-  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
-  elim (lifts_inv_flat1 … HY) -HY #W0 #T0 #HW0 #HT0 #H destruct
-  @(s7 … IHA … (V0 @ V0s)) /3 width=5 by lifts_applv/
-]
-qed.
-
-lemma acr_abst: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-                ∀a,G,L,W,T,A,B. ⦃G, L, W⦄ ϵ[RP] 〚B〛 → (
-                   ∀L0,V0,W0,T0,des. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] W ≡ W0 → ⇧*[des + 1] T ≡ T0 →
-                                   ⦃G, L0, V0⦄ ϵ[RP] 〚B〛 → ⦃G, L0, W0⦄ ϵ[RP] 〚B〛 → ⦃G, L0.ⓓⓝW0.V0, T0⦄ ϵ[RP] 〚A〛
-                ) →
-                ⦃G, L, ⓛ{a}W.T⦄ ϵ[RP] 〚②B.A〛.
-#RR #RS #RP #H1RP #H2RP #a #G #L #W #T #A #B #HW #HA #L0 #V0 #X #des #HL0 #H #HB
-lapply (acr_gcr … H1RP H2RP A) #HCA
-lapply (acr_gcr … H1RP H2RP B) #HCB
-elim (lifts_inv_bind1 … H) -H #W0 #T0 #HW0 #HT0 #H destruct
-lapply (gcr_lifts … HL0 … HW0 HW) -HW [ @(s0 … HCB) ] #HW0
-@(s3 … HCA … (◊))
-@(s6 … HCA … (◊) (◊)) //
-[ @(HA … HL0) //
-| lapply (s1 … HCB) -HCB #HCB
-  @(s7 … H2RP … (◊)) /2 width=1 by/
-]
-qed.
-
-(* Basic_1: removed theorems 2: sc3_arity_gen sc3_repl *)
-(* Basic_1: removed local theorems 1: sc3_sn3_abst *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajust_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajust_5.etc
deleted file mode 100644 (file)
index ef0fbc4..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( ⦃ term 46 L1, break term 46 T1 ⦄ ⇳ [ break term 46 s ] break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'RAjust $L1 $T1 $s $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajuststar_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpa/rajuststar_5.etc
deleted file mode 100644 (file)
index 7cf9191..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( ⦃ term 46 L1, break term 46 T1 ⦄ ⇳ * [ break term 46 s ] break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'RAjustStar $L1 $T1 $s $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc.etc
deleted file mode 100644 (file)
index 9c803f0..0000000
+++ /dev/null
@@ -1,33 +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/lazybtpredproper_8.ma".
-include "basic_2/multiple/fleq.ma".
-include "basic_2/reduction/fpbu.ma".
-
-(* "QRST" PROPER PARALLEL REDUCTION FOR CLOSURES ****************************)
-
-definition fpbc: ∀h. sd h → tri_relation genv lenv term ≝
-                 λh,g,G1,L1,T1,G2,L2,T2.
-                 ∃∃G,L,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ & ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄.
-
-interpretation
-   "'qrst' proper parallel reduction (closure)"
-   'LazyBTPRedProper h g G1 L1 T1 G2 L2 T2 = (fpbc h g G1 L1 T1 G2 L2 T2).
-
-(* Baic properties **********************************************************)
-
-lemma fpbu_fpbc: ∀h,g,G1,G2,L1,L2,T1,T2.
-                 ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄.
-/2 width=5 by ex2_3_intro/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc_fleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbc_fleq.etc
deleted file mode 100644 (file)
index aa5cd7f..0000000
+++ /dev/null
@@ -1,34 +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/multiple/fleq_fleq.ma".
-include "basic_2/reduction/fpbu_fleq.ma".
-include "basic_2/reduction/fpbc.ma".
-
-(* "QRST" PROPER PARALLEL REDUCTION FOR CLOSURES ****************************)
-
-(* Properties on lazy equivalence on closures *******************************)
-
-lemma fpbc_fleq_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ →
-                       ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[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: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ≡[0] ⦃G, L, T⦄ →
-                       ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[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/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg.etc
deleted file mode 100644 (file)
index 574c35e..0000000
+++ /dev/null
@@ -1,61 +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/lazybtpredstarproper_8.ma".
-include "basic_2/reduction/fpbc.ma".
-
-(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
-
-definition fpbg: ∀h. sd h → tri_relation genv lenv term ≝
-                 λh,g. tri_TC … (fpbc h g).
-
-interpretation "'qrst' proper parallel computation (closure)"
-   'LazyBTPRedStarProper h g G1 L1 T1 G2 L2 T2 = (fpbg h g G1 L1 T1 G2 L2 T2).
-
-(* Basic properties *********************************************************)
-
-lemma fpbc_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ →
-                 ⦃G1, L1, T1⦄ >≡[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.
-                   ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ →
-                   ⦃G1, L1, T1⦄ >≡[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.
-                   ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
-                   ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
-/2 width=5 by tri_TC_strap/ qed.
-
-lemma fpbu_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h,g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
-/3 width=1 by fpbu_fpbc, fpbc_fpbg/ qed.
-
-(* Basic eliminators ********************************************************)
-
-lemma fpbg_ind: ∀h,g,G1,L1,T1. ∀R:relation3 ….
-                (∀G2,L2,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
-                (∀G,G2,L,L2,T,T2. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
-                ∀G2,L2,T2. ⦃G1, L1, T1⦄ >≡[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 ….
-                   (∀G1,L1,T1. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1) →
-                   (∀G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
-                   ∀G1,L1,T1. ⦃G1, L1, T1⦄ >≡[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-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fleq.etc
deleted file mode 100644 (file)
index 754811e..0000000
+++ /dev/null
@@ -1,36 +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/fpbc_fleq.ma".
-include "basic_2/computation/fpbg.ma".
-
-(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
-
-(* Properties on lazy equivalence for closures ******************************)
-
-lemma fpbg_fleq_trans: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ →
-                       ∀G2,L2,T2. ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[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: ∀h,g,G,G2,L,L2,T,T2. ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
-                       ∀G1,L1,T1. ⦃G1, L1, T1⦄ ≡[0] ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ >≡[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/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbg.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbg.etc
deleted file mode 100644 (file)
index 57dd5eb..0000000
+++ /dev/null
@@ -1,53 +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/computation/fpbs_fpbu.ma".
-include "basic_2/computation/fpbs_fpbc.ma".
-include "basic_2/computation/fpbs_fpbs.ma".
-include "basic_2/computation/fpbg_fpbs.ma".
-
-(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpbg_inv_fpbu_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ >≡[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/
-| #G1 #G #L1 #L #T1 #T *
-  #G0 #L0 #T0 #H10 #H0 #_ *
-  /5 width=9 by fpbu_fpbs, fpbs_trans, fleq_fpbs, ex2_3_intro/
-]
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma fpbg_fwd_fpbs: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ >≡[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 *)
-/2 width=1 by fpbc_fpbs/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma fpbs_fpbu_trans: ∀h,g,F1,F2,K1,K2,T1,T2. ⦃F1, K1, T1⦄ ≥[h, g] ⦃F2, K2, T2⦄ →
-                       ∀G2,L2,U2. ⦃F2, K2, T2⦄ ≻[h, g] ⦃G2, L2, U2⦄ →
-                       ∃∃G1,L1,U1. ⦃F1, K1, T1⦄ ≻[h, g] ⦃G1, L1, U1⦄ & ⦃G1, L1, U1⦄ ≥[h, g] ⦃G2, L2, U2⦄.
-/5 width=5 by fpbg_inv_fpbu_sn, fpbs_fpbg_trans, fpbc_fpbg, fpbu_fpbc/ qed-.
-
-(* Man properties ***********************************************************)
-
-theorem fpbg_trans: ∀h,g. tri_transitive … (fpbg h g).
-/2 width=5 by tri_TC_transitive/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_fpbs.etc
deleted file mode 100644 (file)
index 4b86622..0000000
+++ /dev/null
@@ -1,88 +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/computation/lpxs_lleq.ma".
-include "basic_2/computation/fpbs_lift.ma".
-include "basic_2/computation/fpbg_fleq.ma".
-
-(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
-
-(* Properties on "qrst" parallel reduction on closures **********************)
-
-lemma fpbg_fpb_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
-                      ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                      ⦃G1, L1, T1⦄ >≡[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.
-                      ⦃G1, L1, T1⦄ ≽[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
-                      ⦃G1, L1, T1⦄ >≡[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-.
-
-(* Properties on "qrst" parallel compuutation on closures *******************)
-
-lemma fpbs_fpbg_trans: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L, T⦄ →
-                       ∀G2,L2,T2. ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[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⦄ →
-                       ∀G1,L1,T1. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ >≡[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-.
-
-lemma fpbu_fpbs_fpbg: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ → 
-                      ∀G2,L2,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
-/3 width=5 by fpbg_fpbs_trans, fpbu_fpbg/ qed.
-
-(* Note: this is used in the closure proof *)
-lemma fqup_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim (fqup_inv_step_sn … H) -H
-/3 width=5 by fqus_fpbs, fpbu_fqu, fpbu_fpbs_fpbg/
-qed.
-
-lemma cpxs_fpbg: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡*[h, g] T2 →
-                 (T1 = T2 → ⊥) → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
-#h #g #G #L #T1 #T2 #H #H0 elim (cpxs_neq_inv_step_sn … H … H0) -H -H0
-/4 width=5 by cpxs_fpbs, fpbu_cpx, fpbu_fpbs_fpbg/
-qed.
-
-lemma lstas_fpbg: ∀h,g,G,L,T1,T2,l2. ⦃G, L⦄ ⊢ T1 •*[h, l2] T2 → (T1 = T2 → ⊥) →
-                  ∀l1. l2 ≤ l1 → ⦃G, L⦄ ⊢ T1 ▪[h, g] l1 → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
-/3 width=5 by lstas_cpxs, cpxs_fpbg/ qed.
-
-lemma lpxs_fpbg: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
-                 (L1 ≡[T, 0] L2 → ⊥) → ⦃G, L1, T⦄ >≡[h, g] ⦃G, L2, T⦄.
-#h #g #G #L1 #L2 #T #H #H0 elim (lpxs_nlleq_inv_step_sn … H … H0) -H -H0
-/4 width=5 by fpbu_fpbs_fpbg, fpbu_lpx, lpxs_lleq_fpbs/
-qed.
-
-lemma fpbs_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                 ⦃G1, L1, T1⦄ ≡[0] ⦃G2, L2, T2⦄ ∨
-                 ⦃G1, L1, T1⦄ >≡[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
-  [ /3 width=5 by fleq_trans, or_introl/
-  | /5 width=5 by fpbc_fpbg, fleq_fpbc_trans, fpbu_fpbc, or_intror/
-  | /3 width=5 by fpbg_fleq_trans, or_intror/
-  | /4 width=5 by fpbg_strap1, fpbu_fpbc, or_intror/
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbg_lift.etc
deleted file mode 100644 (file)
index 58ecd12..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/fpbu_lift.ma".
-include "basic_2/computation/fpbg.ma".
-
-(* "QRST" PARALLEL COMPUTATION FOR CLOSURES *********************************)
-
-(* Advanced properties ******************************************************)
-
-lemma sta_fpbg: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l+1 →
-                ⦃G, L⦄ ⊢ T1 •*[h, 1] T2 → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
-/4 width=2 by fpbu_fpbg, sta_fpbu/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbs_fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/fpbs_fpbc.etc
deleted file mode 100644 (file)
index a88d519..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/reduction/fpbc.ma".
-include "basic_2/computation/fpbs_fleq.ma".
-
-(* "QRST" PARALLEL COMPUTATION FOR CLOSURES *********************************)
-
-(* Properties on "qrst" proper parallel reduction for closures **************)
-
-lemma fpbc_fpbs: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻≡[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_fpb, fpbs_strap2, fleq_fpbs/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/lazybtpredproper_8.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpbc/lazybtpredproper_8.etc
deleted file mode 100644 (file)
index 6abdbeb..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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≻≡ 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 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq.etc
deleted file mode 100644 (file)
index c909e2e..0000000
+++ /dev/null
@@ -1,46 +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/bteq_6.ma".
-include "basic_2/grammar/lenv_length.ma".
-include "basic_2/grammar/genv.ma".
-
-(* EQUIVALENT "BIG TREE" NORMAL FORMS ***************************************)
-
-definition bteq: tri_relation genv lenv term ≝
-                 λG1,L1,T1,G2,L2,T2.
-                 ∧∧ G1 = G2 & |L1| = |L2| & T1 = T2.
-
-interpretation
-   "equivalent 'big tree' normal forms (closure)"
-   'BTEq G1 L1 T1 G2 L2 T2 = (bteq G1 L1 T1 G2 L2 T2).
-
-(* Basic_properties *********************************************************)
-
-lemma bteq_refl: tri_reflexive … bteq.
-/2 width=1 by and3_intro/ qed.
-
-lemma bteq_sym: tri_symmetric … bteq.
-#G1 #G2 #L1 #L2 #T1 #T2 * //
-qed-.
-
-lemma bteq_dec: ∀G1,G2,L1,L2,T1,T2. Decidable (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄).
-#G1 #G2 #L1 #L2 #T1 #T2 elim (genv_eq_dec G1 G2)
-#H1G [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
-elim (eq_nat_dec (|L1|) (|L2|))
-#H1L [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
-elim (term_eq_dec T1 T2)
-#H1T [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
-/3 width=1 by and3_intro, or_introl/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_6.etc
deleted file mode 100644 (file)
index 5ee962f..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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⋕ break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'BTEq $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_bteq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/bteq_bteq.etc
deleted file mode 100644 (file)
index 7870b26..0000000
+++ /dev/null
@@ -1,31 +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/grammar/bteq.ma".
-
-(* EQUIVALENT "BIG TREE" NORMAL FORMS ***************************************)
-
-(* Main properties **********************************************************)
-
-theorem bteq_trans: tri_transitive … bteq.
-#G1 #G #L1 #L #T1 #T * //
-qed-.
-
-theorem bteq_canc_sn: ∀G,G1,G2,L,L1,L2,T,T1,T2. ⦃G, L, T⦄ ⋕ ⦃G1, L1, T1⦄ →
-                      ⦃G, L, T⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
-/3 width=5 by bteq_trans, bteq_sym/ qed-.
-
-theorem bteq_canc_dx: ∀G1,G2,G,L1,L2,L,T1,T2,T. ⦃G1, L1, T1⦄ ⋕ ⦃G, L, T⦄ →
-                      ⦃G2, L2, T2⦄ ⋕ ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
-/3 width=5 by bteq_trans, bteq_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/btpredsn_8.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/btpredsn_8.etc
deleted file mode 100644 (file)
index 0350d14..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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⊢ ⋕ ➡ 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 @{ 'BTPRedSn $h $g $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpb.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpb.etc
deleted file mode 100644 (file)
index e669834..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-include "basic_2/reduction/fpn.ma".
-
-(* Basic forward lemmas *****************************************************)
-
-lemma fpb_bteq_fwd_fpn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                        ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=1 by and3_intro/
-[ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H
-  [ #H1 #H2 elim (fqu_fwd_bteq … H1 H2)
-  | * #HG #HL #HT #_ destruct //
-  ]
-| #T2 #HT12 * //
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbc.etc
deleted file mode 100644 (file)
index 1ed366c..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-lemma fpb_fpbc_or_fpn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                       ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ ∨
-                       ⦃G1, L1, T1⦄ ⊢ ➡[h,g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2
-/3 width=1 by and3_intro, or_intror/
-[ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H [| * ]
-  /3 width=1 by fpbc_fqu, and3_intro, or_introl, or_intror/
-| #T2 #HT12 elim (eq_term_dec T1 T2) #H destruct
-  /4 width=1 by and3_intro, or_introl, or_intror, fpbc_cpx/
-]
-qed-.
-
-lemma fpb_fpbc: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) →
-                ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #H0 elim (fpb_fpbc_or_fpn … H) -H //
-#H elim H0 -H0 /2 width=3 by fpn_fwd_bteq/
-qed.
-
-lemma fpbc_fwd_bteq: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ →
-                     ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=8 by fqu_fwd_bteq/
-#T2 #_ #HT12 * /2 width=1 by/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbs_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpbs_conj.etc
deleted file mode 100644 (file)
index 8d0f137..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-(*
-inclade "basic_2/computation/fpns.ma".
-inclade "basic_2/computation/fpbs.ma".
-inclade "basic_2/reduction/fpbc.ma".
-
-lemma fpn_dec: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-               Decidable (⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄).
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim (fpb_fpbc_or_fpn … H) -H /2 width=1 by or_introl/
-#H12 @or_intror
-#H @(fpbc_fwd_bteq … H12) -H12 @(fpn_fwd_bteq … H)
-qed-.
-*)
-(*
-lemma fpns_dec: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                Decidable (⦃G1, L1, T1⦄ ⊢ ➡*[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 #H #H2 *
-#H1 elim (fpn_dec … H2) -H2 #H2 /3 width=5 by fpns_strap1, or_introl/
-[ @or_intror #H12
-| @or_intror #H12 @H1 -H1
-*)
-(*
-inclade "basic_2/grammar/bteq_bteq.ma".
-inclade "basic_2/computation/fpns.ma".
-
-(* Advanced forward lemmas **************************************************)
-
-lemma fpbs_bteq_fwd_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                          ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbs_ind … H) -G2 -L2 -T2 //
-#G #G2 #L #L2 #T #T2 #H1 #H2 #IH1 #H12 elim (bteq_dec G1 G L1 L T1 T)
-[ -H1 /4 width=10 by fpns_strap1, fpb_bteq_fwd_fpn, bteq_canc_sn/
-| -IH1 #H
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn.etc
deleted file mode 100644 (file)
index 406e6eb..0000000
+++ /dev/null
@@ -1,39 +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/btpredsn_8.ma".
-include "basic_2/relocation/lleq.ma".
-include "basic_2/reduction/lpx.ma".
-
-(* REDUCTION FOR "BIG TREE" NORMAL FORMS ************************************)
-
-inductive fpn (h) (g) (G) (L1) (T): relation3 genv lenv term ≝
-| fpn_intro: ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → L1 ⋕[T] L2 → fpn h g G L1 T G L2 T
-.
-
-interpretation
-   "reduction for 'big tree' normal forms (closure)"
-   'BTPRedSn h g G1 L1 T1 G2 L2 T2 = (fpn h g G1 L1 T1 G2 L2 T2).
-
-(* Basic_properties *********************************************************)
-
-lemma fpn_refl: ∀h,g. tri_reflexive … (fpn h g).
-/2 width=1 by fpn_intro/ qed.
-
-(* Basic inversion lemmas ***************************************************) 
-
-lemma fpn_inv_gen: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ →
-                   ∧∧ G1 = G2 & ⦃G1, L1⦄ ⊢ ➡[h, g] L2 & L1 ⋕[T1] L2 & T1 = T2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=1 by and4_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn_fpn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpn_fpn.etc
deleted file mode 100644 (file)
index adda4b5..0000000
+++ /dev/null
@@ -1,52 +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/lpx_lpx.ma".
-include "basic_2/reduction/fpn.ma".
-
-(* REDUCTION FOR "BIG TREE" NORMAL FORMS ************************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fpn_fqu_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
-                     ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
-                     ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
-#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
-#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqu_trans … H12 … HKL1 HV1) -L1
-/3 width=5 by fpn_intro, ex2_3_intro/
-qed-.
-
-lemma fpn_fquq_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
-                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
-                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃⸮ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
-#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
-#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fquq_trans … H12 … HKL1 HV1) -L1
-/3 width=5 by fpn_intro, ex2_3_intro/
-qed-.
-
-lemma fpn_fqup_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
-                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
-                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃+ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
-#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
-#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqup_trans … H12 … HKL1 HV1) -L1
-/3 width=5 by fpn_intro, ex2_3_intro/
-qed-.
-
-lemma fpn_fqus_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
-                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
-                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃* ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
-#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
-#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqus_trans … H12 … HKL1 HV1) -L1
-/3 width=5 by fpn_intro, ex2_3_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns.etc
deleted file mode 100644 (file)
index 0a208fe..0000000
+++ /dev/null
@@ -1,58 +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/btpredsnstar_8.ma".
-include "basic_2/reduction/fpn.ma".
-
-(* COMPUTATION FOR "BIG TREE" NORMAL FORMS **********************************)
-
-definition fpns: ∀h. sd h → tri_relation genv lenv term ≝
-                 λh,g. tri_TC … (fpn h g).
-
-interpretation
-   "computation for 'big tree' normal forms (closure)"
-   'BTPRedSnStar h g G1 L1 T1 G2 L2 T2 = (fpns h g G1 L1 T1 G2 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma fpns_ind: ∀h,g,G1,L1,T1. ∀R:relation3 …. R G1 L1 T1 →
-                (∀G,G2,L,L2,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
-                ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2.
-#h #g #G1 #L1 #T1 #R #IH1 #IH2 #G2 #L2 #T2 #H
-lapply (tri_TC_star_ind … IH1 IH2 G2 L2 T2 H) //
-qed-.
-
-lemma fpns_ind_dx: ∀h,g,G2,L2,T2. ∀R:relation3 …. R G2 L2 T2 →
-                   (∀G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
-                   ∀G1,L1,T1. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1.
-#h #g #G2 #L2 #T2 #R #IH1 #IH2 #G1 #L1 #T1 #H
-@(tri_TC_star_ind_dx … IH1 IH2 G1 L1 T1 H) //
-qed-.
-
-(* Basic_properties *********************************************************)
-
-lemma fpns_refl: ∀h,g. tri_reflexive … (fpns h g).
-/2 width=1 by tri_inj/ qed.
-
-lemma fpn_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ →
-                ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
-/2 width=1 by tri_inj/ qed.
-
-lemma fpns_strap1: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G, L, T⦄ →
-                   ⦃G, L, T⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
-/2 width=5 by tri_step/ qed-.
-
-lemma fpns_strap2: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G, L, T⦄ →
-                   ⦃G, L, T⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
-/2 width=5 by tri_TC_strap/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns_fpns.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fpns_fpns.etc
deleted file mode 100644 (file)
index 5aaea6a..0000000
+++ /dev/null
@@ -1,74 +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/lleq_lleq.ma".
-include "basic_2/computation/lpxs.ma".
-include "basic_2/computation/fpns.ma".
-
-(* COMPUTATION FOR "BIG TREE" NORMAL FORMS **********************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpns_inv_gen: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ →
-                    ∧∧ G1 = G2 & ⦃G1, L1⦄ ⊢ ➡*[h, g] L2 & L1 ⋕[T1] L2 & T1 = T2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpns_ind … H) -G2 -L2 -T2 /2 width=1 by and4_intro/
-#G #G2 #L #L2 #T #T2 #_ #H2 * #HG #HL1 #HT1 #HT destruct
-elim (fpn_inv_gen … H2) -H2 #HG #HL2 #HT #HT2 destruct
-/3 width=3 by lpxs_strap1, lleq_trans, and4_intro/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lpxs_lleq_fpns: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 → L1 ⋕[T] L2 →
-                      ⦃G, L1, T⦄ ⊢ ⋕➡*[h, g] ⦃G, L2, T⦄.
-#h #g #G #L1 #L2 #T #H @(lpxs_ind … H) -L2 //
-#L #L2 #HL1 #HL2 #IHL1 #HL12 elim (lleq_dec T L1 L) #HT
-[ -HL1 @fpns_strap1 [4: @IHL1 // |1,2,3: skip ]
-  /3 width=3 by fpn_intro, lleq_canc_sn/
-| -IHL1
-
-(* Main properties **********************************************************)
-
-theorem fpns_trans: tri_transitive … fqus.
-/2 width=5 by tri_TC_transitive/ qed-.
-
-
-(*
-lemma fpns_refl: ∀h,g. tri_reflexive … (fpns h g).
-/2 width=1 by and3_intro/ qed.
-
-lemma fpn_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄ →
-                ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * /3 width=1 by lpx_lpxs, and3_intro/
-qed.
-
-lemma fpns_strap1: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G, L, T⦄ →
-                   ⦃G, L, T⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 * #H1G #H1L #G1T *
-/3 width=3 by lpxs_strap1, and3_intro/
-qed-.
-
-lemma fpns_strap2: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G, L, T⦄ →
-                   ⦃G, L, T⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
-#h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 * #H1G #H1L #G1T *
-/3 width=3 by lpxs_strap2, and3_intro/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma fpns_fwd_bteq: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄ →
-                     ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 * /3 width=4 by lpxs_fwd_length, and3_intro/
-qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fqu.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fqu.etc
deleted file mode 100644 (file)
index 1e4defb..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-include "basic_2/grammar/bteq.ma".
-
-lemma fqu_fwd_bteq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
-                    ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-[ #I #G #L #V * #_ #H elim (plus_xSy_x_false … H)
-| #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_x … H)
-| #a #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_y … H)
-| #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_y … H)
-| #G #L #K #T #U #e #HLK #_ * #_ #H
-  lapply (ldrop_fwd_length_lt4 … HLK ?) // >H -L #H
-  elim (lt_refl_false … H)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb.etc
deleted file mode 100644 (file)
index 3cd6861..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-(* Basic eliminators ********************************************************)
-
-theorem fsb_ind_alt: ∀h,g. ∀R: relation3 …. (
-                        ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥[h,g] T1 → (
-                           ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                           (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → R G2 L2 T2
-                        ) → R G1 L1 T1
-                     ) →
-                     ∀G,L,T. ⦃G, L⦄ ⊢ ⦥[h, g] T → R G L T.
-#h #g #R #IH #G #L #T #H elim H -G -L -T
-/5 width=1 by fpb_fpbc, fsb_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/fsb_alt.etc
deleted file mode 100644 (file)
index 8c69a00..0000000
+++ /dev/null
@@ -1,105 +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/btsnalt_5.ma".
-include "basic_2/computation/fpbs_fpbs.ma".
-include "basic_2/computation/fsb.ma".
-
-(* "BIG TREE" STRONGLY NORMALIZING TERMS ************************************)
-
-(* Note: alternative definition of fsb *)
-inductive fsba (h) (g): relation3 genv lenv term ≝
-| fsba_intro: ∀G1,L1,T1. (
-                 ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                 (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → fsba h g G2 L2 T2
-              ) → fsba h g G1 L1 T1.
-
-interpretation
-   "'big tree' strong normalization (closure) alternative"
-   'BTSNAlt h g G L T = (fsba h g G L T).
-
-(* Basic eliminators ********************************************************)
-
-theorem fsba_ind_alt: ∀h,g. ∀R: relation3 …. (
-                         ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥⦥[h,g] T1 → (
-                            ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                            (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → R G2 L2 T2
-                         ) → R G1 L1 T1
-                      ) →
-                      ∀G,L,T. ⦃G, L⦄ ⊢ ⦥⦥[h, g] T → R G L T.
-#h #g #R #IH #G #L #T #H elim H -G -L -T
-/5 width=1 by fsba_intro/
-qed-.
-
-(* Basic_properties *********************************************************)
-
-fact fsba_intro_aux: ∀h,g,G1,L1,T1. (
-                        ∀G,G2,L,L2,T,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
-                        ⦃G1, L1, T1⦄ ⋕ ⦃G, L, T⦄ →
-                        (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → fsba h g G2 L2 T2
-                     ) → fsba h g G1 L1 T1.
-/4 width=5 by fsba_intro/ qed-.
-
-lemma fsba_fpbs_trans: ∀h,g,G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥⦥[h, g] T1 →
-                       ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ → ⦃G2, L2⦄ ⊢ ⦥⦥[h, g] T2.
-#h #g #G1 #L1 #T1 #H @(fsba_ind_alt … H) -G1 -L1 -T1
-#G1 #L1 #T1 #H0 #IH0 #G #L #T #H1 @fsba_intro
-#G2 #L2 #T2 #H2 #_ lapply (fpbs_trans … H1 … H2) -G -L -T
-#H12 elim (bteq_dec G1 G2 L1 L2 T1 T2) /3 width=6 by fpb_fpbs/
--IH0 #H212 
-
- -H0 -H #H @(IH0 … H) -IH0 -H // @(fpbs_trans … H1 … H2)    
-
-lemma fsba_intro_fpb: ∀h,g,G1,L1,T1. (
-                         ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
-                         (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → ⦃G2, L2⦄ ⊢ ⦥⦥[h, g] T2
-                      ) → ⦃G1, L1⦄ ⊢ ⦥⦥[h, g] T1.
-#h #g #G1 #L1 #T1 #IH1 @fsba_intro_aux
-#G #G2 #L #L2 #T #T2 #H @(fpbs_ind_dx … H) -G -L -T
-[ #H1 #H2 -IH1 elim H2 -H2 //
-| #G0 #G #L0 #L #T0 #T #H10 #H12 #IH2 #H210 #H212 elim (bteq_dec G1 G L1 L T1 T) 
-  [ -IH1 -H210 -H10 -H12 /3 width=1 by/
-  | -IH2 -H212 #H21 lapply (IH1 … H21) -IH1 -H21
-    [
-    | -H10 -H210 #H 
-(*
-(* Main inversion lemmas ****************************************************)
-
-theorem fsba_inv_fsb: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⦥⦥[h, g] T → ⦃G, L⦄ ⊢ ⦥[h, g] T.
-#h #g #G #L #T #H elim H -G -L -T
-/5 width=12 by fsb_intro, fpb_fpbs, fpbc_fwd_fpb, fpbc_fwd_gen/
-qed-.
-
-(* Main properties **********************************************************)
-
-theorem fsb_fsba: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⦥[h, g] T → ⦃G, L⦄ ⊢ ⦥⦥[h, g] T.
-#h #g #G #L #T #H @(fsb_ind_alt … H) -G -L -T
-/4 width=1 by fsba_intro_fpb/
-qed.
-(*
-| fsba_intro: ∀G1,L1,T1. (
-                ∀G2,L2,T2.  ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → fsb h g G2 L2 T2
-              ) → fsb h g G1 L1 T1
-.
-
-
-
-(****************************************************************************)
-
-include "basic_2/substitution/fqup.ma".
-
-lemma fsb_csx: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ⦃G, L⦄ ⊢ ⦥[h, g] T.
-#h #g #G #L #T #H @(csx_ind … H) -T
-*)*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/lazyeq_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpn/lazyeq_6.etc
deleted file mode 100644 (file)
index 105a473..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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⋕ break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'LazyEq $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr.etc
deleted file mode 100644 (file)
index f58a52c..0000000
+++ /dev/null
@@ -1,59 +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 "hvbox( L ⊢ break ⦃ term 46 L1, break term 46 T1 ⦄ ➡ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRed $L $L1 $T1 $L2 $T2 }.
-
-include "basic_2/reducibility/cpr.ma".
-include "basic_2/reducibility/fpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
-
-definition cfpr: lenv → bi_relation lenv term ≝
-                 λL,L1,T1,L2,T2. |L1| = |L2| ∧ L ⊢ L1 @@ T1 ➡ L2 @@ T2.
-
-interpretation
-   "context-sensitive parallel reduction (closure)"
-   'FocalizedPRed L L1 T1 L2 T2 = (cfpr L L1 T1 L2 T2).
-
-(* Basic properties *********************************************************)
-
-lemma cfpr_refl: ∀L. bi_reflexive … (cfpr L).
-/2 width=1/ qed.
-
-lemma fpr_cfpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⋆ ⊢ ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 * /3 width=1/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma cfpr_inv_atom1: ∀L,L2,T1,T2. L ⊢ ⦃⋆, T1⦄ ➡ ⦃L2, T2⦄ → L ⊢ T1 ➡ T2 ∧ L2 = ⋆.
-#L #L2 #T1 #T2 * #H >(length_inv_zero_sn … H) /2 width=1/
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpr_inv_pair1_sn: ∀I,K1,L2,V1,T1,T2. ⦃⋆.ⓑ{I}V1@@K1, T1⦄ ➡ ⦃L2, T2⦄ →
-                        ∃∃K2,V2. V1 ➡ V2 &
-                                 ⋆.ⓑ{I}V2 ⊢ ⦃K1, T1⦄ ➡ ⦃K2, T2⦄  &
-                                 L2 = ⋆.ⓑ{I}V2@@K2.
-#I1 #K1 #L2 #V1 #T1 #T2 * >append_length #H
-elim (length_inv_pos_sn_append … H) -H #I2 #K2 #V2 #HK12 #H destruct
->shift_append_assoc >shift_append_assoc normalize in ⊢ (%→?); #H
-elim (tpr_inv_bind1 … H) -H *
-[ #V0 #T #T0 #HV10 #HT1 #HT0 #H destruct /5 width=5/
-| #T0 #_ #_ #H destruct
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_aaa.etc
deleted file mode 100644 (file)
index 72802e4..0000000
+++ /dev/null
@@ -1,27 +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/reducibility/cpr_aaa.ma".
-include "basic_2/reducibility/cfpr_cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_fpr_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                    ∀L2,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → L2 ⊢ T2 ⁝ A.
-#L1 #T1 #A #HT1 #L2 #T2 #H
-elim (fpr_inv_all … H) -H
-/4 width=5 by aaa_cpr_conf, aaa_ltpr_conf, aaa_ltpss_sn_conf/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cfpr.etc
deleted file mode 100644 (file)
index f442be2..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/reducibility/cpr_cpr.ma".
-include "basic_2/reducibility/cfpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
-
-(* Main properties **********************************************************)
-
-theorem cfpr_conf: ∀L. bi_confluent … (cfpr L).
-#L #L0 #L1 #T0 #T1 * #HL01 #HT01 #L2 #T2 * >HL01 #HL12 #HT02
-elim (cpr_conf … HT01 HT02) -L0 -T0 #X #H1 #H2
-elim (cpr_fwd_shift1 … H1) #L0 #T0 #HL10 #H destruct /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_cpr.etc
deleted file mode 100644 (file)
index a1e20a0..0000000
+++ /dev/null
@@ -1,64 +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/reducibility/cpr_tpss.ma".
-include "basic_2/reducibility/cpr_cpr.ma".
-include "basic_2/reducibility/cfpr_ltpss.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fpr_all: ∀L1,L. L1 ➡ L → ∀L2,T1,T2. L ⊢ T1 ➡ T2 →
-               L ⊢ ▶* [0, |L|] L2 → ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
-#L1 #L #H elim H -L1 -L
-[ #L2 #T1 #T2 #HT12 #HL2
-  lapply (ltpss_sn_inv_atom1 … HL2) -HL2 #H destruct
-  lapply (cpr_inv_atom … HT12) -HT12 /2 width=1/
-| #I #L1 #L #V1 #V #_ #HV1 #IH #X #T1 #T2 #HT12 #H
-  elim (ltpss_sn_inv_tpss21 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
-  lapply (cpr_bind_dx false … HV1 HT12) -HV1 -HT12 #HT12
-  lapply (cpr_tpss_trans … HT12 (-ⓑ{I}V2.T2) 0 (|L|) ?) -HT12 /2 width=1/ -HV2 /3 width=1/
-]
-qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cfpr_inv_all: ∀L1,L2,L0,T1,T2. L0 ⊢ ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ →
-                    ∃∃L. L0 @@ L1 ➡ L0 @@ L & L0 @@ L ⊢ T1 ➡ T2 &
-                         L0 @@ L ⊢ ▶* [0, |L0| + |L|] L0 @@ L2.
-#L1 @(lenv_ind_dx … L1) -L1
-[ #L2 #L0 #T1 #T2 #H
-  elim (cfpr_inv_atom1 … H) -H #HT12 #H destruct /3 width=4/
-| #I #L1 #V1 #IH #X #L0 #T1 #T2 #H
-  elim (cfpr_inv_pair1 … H) -H #L2 #V #V2 #HV1 #HV2 #HT12 #H destruct
-  elim (IH … HT12) -IH -HT12 #L #HL1 #HT12 #HL2
-  elim (ltpr_inv_append1 … HL1) -HL1 #X #Y #HX #HY #H
-  lapply (ltpr_fwd_length … HX) -HX #HX
-  elim (append_inj_dx … H ?) -H // -HX #_ #H destruct -X
-  lapply (ltpss_sn_fwd_length … HL2) >append_length >append_length #H
-  lapply (injective_plus_r … H) -H #H
-  @(ex3_intro … (⋆.ⓑ{I}V@@Y)) <append_assoc // -HT12
-  <append_assoc [ /3 width=1/ ] -HV1 -HY
-  >append_length <associative_plus
-  @(ltpss_sn_dx_trans_eq … HL2) -HL2 >H -H >commutative_plus /3 width=1/
-]
-qed-.
-
-lemma fpr_inv_all: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ →
-                   ∃∃L. L1 ➡ L & L ⊢ T1 ➡ T2 & L ⊢ ▶* [0, |L|] L2.
-#L1 #L2 #T1 #T2 #H
-lapply (fpr_cfpr … H) -H #H
-elim (cfpr_inv_all … H) -H /2 width=4/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/cfpr_ltpss.etc
deleted file mode 100644 (file)
index 66e102e..0000000
+++ /dev/null
@@ -1,39 +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/reducibility/cpr_lift.ma".
-include "basic_2/reducibility/cpr_ltpss_sn.ma".
-include "basic_2/reducibility/cfpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cfpr_inv_pair1: ∀I,L,K1,L2,V1,T1,T2. L ⊢ ⦃⋆.ⓑ{I}V1@@K1, T1⦄ ➡ ⦃L2, T2⦄ →
-                      ∃∃K2,V,V2. V1 ➡ V & L ⊢ V ▶* [0, |L|] V2 &
-                                 L.ⓑ{I}V ⊢ ⦃K1, T1⦄ ➡ ⦃K2, T2⦄  &
-                                 L2 = ⋆.ⓑ{I}V2@@K2.
-* #L #K1 #L2 #V1 #T1 #T2 * >append_length #H
-elim (length_inv_pos_sn_append … H) -H #I2 #K2 #V2 #HK12 #H destruct
->shift_append_assoc >shift_append_assoc normalize in ⊢ (??%%→?); #H
-[ elim (cpr_inv_abbr1 … H) -H *
-  [ #V #V0 #T0 #HV1 #HV0 #HT10 #H destruct /3 width=7/
-  | #T0 #_ #_ #H destruct
-  ]
-| elim (cpr_inv_abst1 … H Abst V2) -H
-  #V #T * #V0 #HV10 #HV0 #HT1 #H destruct
-  lapply (ltpss_sn_cpr_trans (L.ⓛV0) … 0 (|L|+1) … HT1) -HT1 /2 width=1/ #HT12
-  /3 width=7/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc.etc
deleted file mode 100644 (file)
index ee36247..0000000
+++ /dev/null
@@ -1,48 +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 "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConv $L1 $T1 $L2 $T2 }.
-
-notation "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ ⬌ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConvAlt $L1 $T1 $L2 $T2 }.
-
-include "basic_2/reducibility/fpr.ma".
-
-(* CONTEXT-FREE PARALLEL CONVERSION ON CLOSURES *****************************)
-
-definition fpc: bi_relation lenv term ≝
-   λL1,T1,L2,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ ∨ ⦃L2, T2⦄ ➡ ⦃L1, T1⦄.
-
-interpretation
-   "context-free parallel conversion (closure)"
-   'FocalizedPConv L1 T1 L2 T2 = (fpc L1 T1 L2 T2).
-
-(* Basic properties *********************************************************)
-
-lemma fpc_refl: bi_reflexive … fpc.
-/2 width=1/ qed.
-
-lemma fpc_sym: bi_symmetric … fpc.
-#L1 #L2 #T1 #T2 * /2 width=1/
-qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma fpc_fwd_fpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌ ⦃L2, T2⦄ →
-                   ∃∃L,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ & ⦃L2, T2⦄ ➡ ⦃L, T⦄.
-#L1 #L2 #T1 #T2 * /2 width=4/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc_fpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpc_fpc.etc
deleted file mode 100644 (file)
index 22fc16f..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/conversion/fpc.ma".
-
-(* CONTEXT-FREE PARALLEL CONVERSION ON CLOSURES *****************************)
-
-(* Main properties **********************************************************)
-
-theorem fpc_conf: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ⬌ ⦃L1, T1⦄ →
-                  ∀L2,T2. ⦃L0, T0⦄ ⬌ ⦃L2, T2⦄ →
-                  ∃∃L,T. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ & ⦃L2, T2⦄ ⬌ ⦃L, T⦄.
-/3 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs.etc
deleted file mode 100644 (file)
index 68c946c..0000000
+++ /dev/null
@@ -1,84 +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 "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConvStar $L1 $T1 $L2 $T2 }.
-
-notation "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ ⬌ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConvStarAlt $L1 $T1 $L2 $T2 }.
-
-include "basic_2/conversion/fpc.ma".
-
-(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
-
-definition fpcs: bi_relation lenv term ≝ bi_TC … fpc.
-
-interpretation "context-free parallel equivalence (closure)"
-   'FocalizedPConvStar L1 T1 L2 T2 = (fpcs L1 T1 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma fpcs_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
-                (∀L,L2,T,T2. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L, T⦄ ⬌ ⦃L2, T2⦄ → R L T → R L2 T2) →
-                ∀L2,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → R L2 T2.
-/3 width=7 by bi_TC_star_ind/ qed-.
-
-lemma fpcs_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
-                   (∀L1,L,T1,T. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → R L T → R L1 T1) →
-                   ∀L1,T1. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → R L1 T1.
-/3 width=7 by bi_TC_star_ind_dx/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma fpcs_refl: bi_reflexive … fpcs.
-/2 width=1/ qed.
-
-lemma fpcs_sym: bi_symmetric … fpcs.
-/3 width=1/ qed.
-
-lemma fpc_fpcs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/2 width=1/ qed.
-
-lemma fpcs_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L, T⦄ ⬌ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma fpcs_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma fpcs_fpr_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=1/ qed.
-
-lemma fpcs_fpr_sn: ∀L1,L2,T1,T2. ⦃L2, T2⦄ ➡ ⦃L1, T1⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=1/ qed.
-
-lemma fpcs_fpr_strap1: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ →
-                       ∀L2,T2. ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4/ qed.
-
-lemma fpcs_fpr_strap2: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ →
-                       ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4/ qed.
-
-lemma fpcs_fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ →
-                    ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4/ qed.
-
-lemma fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4/ qed-.
-
-lemma fpcs_fpr_conf: ∀L1,L,T1,T. ⦃L, T⦄ ➡ ⦃L1, T1⦄ →
-                     ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_aaa.etc
deleted file mode 100644 (file)
index 9f4327b..0000000
+++ /dev/null
@@ -1,30 +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/computation/fprs_aaa.ma".
-include "basic_2/equivalence/fpcs_fpcs.ma".
-
-(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
-
-(* Main properties about atomic arity assignment on terms *******************)
-
-theorem aaa_fpcs_mono: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ →
-                       ∀A1. L1 ⊢ T1 ⁝ A1 → ∀A2. L2 ⊢ T2 ⁝ A2 →
-                       A1 = A2.
-#L1 #L2 #T1 #T2 #H12 #A1 #HT1 #A2 #HT2
-elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
-lapply (aaa_fprs_conf … HT1 … H1) -L1 -T1 #HT1
-lapply (aaa_fprs_conf … HT2 … H2) -L2 -T2 #HT2
-lapply (aaa_mono … HT1 … HT2) -L -T //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_cpcs.etc
deleted file mode 100644 (file)
index b1288f7..0000000
+++ /dev/null
@@ -1,86 +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/computation/fprs_cprs.ma".
-include "basic_2/equivalence/cpcs_cpcs.ma".
-include "basic_2/equivalence/fpcs_fpcs.ma".
-
-(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fpcs_flat_dx_tpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
-                        ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ⬌* ⦃L2, ⓕ{I}V2.T2⦄.
-#L1 #L2 #T1 #T2 #HT12
-elim (fpcs_inv_fprs … HT12) -HT12
-/3 width=6 by fprs_flat_dx_tpr, fprs_div/ (**) (* auto too slow without trace *)
-qed.
-
-lemma fpcs_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄ →
-                  ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄.
-#I #L1 #L2 #V1 #V2 #T1 #T2 #H12
-elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
-elim (fprs_bind2_minus … H1) -H1 #W1 #U1 #HTU1 #H destruct
-elim (fprs_bind2_minus … H2) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
-qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpcs_inv_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄ →
-                      ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄.
-#I #L1 #L2 #V1 #V2 #T1 #T2 #H12
-elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
-elim (fprs_inv_pair1 … H1) -H1 #K1 #U1 #_ #HTU1 #H destruct
-elim (fprs_inv_pair1 … H2) -H2 #K2 #U2 #_ #HTU2 #H destruct /2 width=4/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma fpcs_fwd_bind_minus: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄ →
-                           ∀b. ⦃L1, ⓑ{b,I}V1.T1⦄ ⬌* ⦃L2, ⓑ{b,I}V2.T2⦄.
-#I #L1 #L2 #V1 #V2 #T1 #T2 #H12 #b
-elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
-elim (fprs_fwd_bind2_minus … H1 b) -H1 #W1 #U1 #HTU1 #H destruct
-elim (fprs_fwd_bind2_minus … H2 b) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
-qed-.
-
-lemma fpcs_fwd_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄ →
-                      ∀b. ⦃L1, ⓑ{b,I}V1.T1⦄ ⬌* ⦃L2, ⓑ{b,I}V2.T2⦄.
-/3 width=1 by fpcs_inv_shift, fpcs_fwd_bind_minus/ qed-.
-
-lemma fpcs_fwd_abst24: ∀a,L1,L2,V1,V2,T1,T2. ⦃L1, ⓛ{a}V1.T1⦄ ⬌* ⦃L2, ⓛ{a}V2.T2⦄ →
-                       ∀b,I,W. ⦃L1, ⓑ{b,I}W.T1⦄ ⬌* ⦃L2, ⓑ{b,I}W.T2⦄.
-#a #L1 #L2 #V1 #V2 #T1 #T2 #H12 #b #I #W
-elim (fpcs_inv_fprs … H12) -H12 #L #U #H1 #H2
-elim (fprs_fwd_abst2 … H1 b I W) -H1 #W1 #U1 #HTU1 #H destruct
-elim (fprs_fwd_abst2 … H2 b I W) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
-qed-.
-
-lemma fpcs_fwd_abst13: ∀L1,L2,V1,V2,T1,T2. ⦃L1.ⓛV1, T1⦄ ⬌* ⦃L2.ⓛV2, T2⦄ →
-                       ∀I,W. ⦃L1.ⓑ{I}W, T1⦄ ⬌* ⦃L2.ⓑ{I}W, T2⦄.
-/4 width=4 by fpcs_fwd_shift, fpcs_fwd_abst24, fpcs_shift/ qed-.
-
-(* Properties on context-sensitive parallel equivalence for terms ***********)
-
-lemma cpcs_fpcs: ∀L,T1,T2. L ⊢ T1 ⬌* T2 → ⦃L, T1⦄ ⬌* ⦃L, T2⦄.
-#L #T1 #T2 #H
-elim (cpcs_inv_cprs … H) -H /3 width=4 by fprs_div, cprs_fprs/ (**) (* too slow without trace *)
-qed.
-
-(* Inversion lemmas on context-sensitive parallel equivalence for terms *****)
-
-lemma fpcs_inv_cpcs: ∀L,T1,T2. ⦃L, T1⦄ ⬌* ⦃L, T2⦄ → L ⊢ T1 ⬌* T2.
-#L #T1 #T2 #H
-elim (fpcs_inv_fprs … H) -H /3 width=4 by cprs_div, fprs_fwd_cprs/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fpcs.etc
deleted file mode 100644 (file)
index 270e8dc..0000000
+++ /dev/null
@@ -1,66 +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/computation/fprs_fprs.ma".
-include "basic_2/conversion/fpc_fpc.ma".
-include "basic_2/equivalence/fpcs_fprs.ma".
-
-(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpcs_inv_fprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ →
-                     ∃∃L,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ & ⦃L2, T2⦄ ➡* ⦃L, T⦄.
-#L1 #L2 #T1 #T2 #H @(fpcs_ind … H) -L2 -T2
-[ /3 width=4/
-| #L #L2 #T #T2 #_ #HT2 * #L0 #T0 #HT10 elim HT2 -HT2 #HT2 #HT0
-  [ elim (fprs_strip … HT2 … HT0) -L -T #L #T #HT2 #HT0
-    lapply (fprs_strap1 … HT10 … HT0) -L0 -T0 /2 width=4/
-  | lapply (fprs_strap2 … HT2 … HT0) -L -T /2 width=4/
-  ]
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma fpr_fprs_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
-elim (fprs_strip … HT2 … HT1) /2 width=4 by fpr_fprs_div/
-qed-.
-
-lemma fprs_fpr_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L2, T2⦄ ⬌* ⦃L1, T1⦄.
-#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
-elim (fprs_strip … HT2 … HT1) /2 width=4 by fprs_fpr_div/
-qed-.
-
-lemma fprs_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
-elim (fprs_conf … HT1 … HT2) /2 width=4/
-qed-.
-
-lemma fpcs_strip: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ⬌ ⦃L1, T1⦄ →
-                  ∀L2,T2. ⦃L0, T0⦄ ⬌* ⦃L2, T2⦄ →
-                  ∃∃L,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ & ⦃L2, T2⦄ ⬌ ⦃L, T⦄.
-/3 width=4/ qed.
-
-(* Main properties **********************************************************)
-
-theorem fpcs_trans: bi_transitive … fpcs.
-/2 width=4/ qed.
-
-theorem fpcs_canc_sn: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ⬌* ⦃L1, T1⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4 by fpcs_trans, fpcs_sym/ qed. (**) (* /3 width=3/ is too slow *)
-
-theorem fpcs_canc_dx: ∀L1,L2,L,T1,T2,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L2, T2⦄ ⬌* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4 by fpcs_trans, fpcs_sym/ qed. (**) (* /3 width=3/ is too slow *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpcs_fprs.etc
deleted file mode 100644 (file)
index 43239ea..0000000
+++ /dev/null
@@ -1,55 +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/computation/fprs.ma".
-include "basic_2/equivalence/fpcs.ma".
-
-(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
-
-(* Properties on context-free parallel computation for closures *************)
-
-(* Note: was lemma 1000 *)
-lemma fpcs_fprs_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 /width=1/ /3 width=4/
-qed.
-
-lemma fpcs_fprs_sn: ∀L1,L2,T1,T2. ⦃L2, T2⦄ ➡* ⦃L1, T1⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 #H @(fprs_ind_dx … H) -L2 -T2 /width=1/ /3 width=4/
-qed.
-
-lemma fpcs_fprs_strap1: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ∀L2,T2. ⦃L, T⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L #T1 #T #HT1 #L2 #T2 #H @(fprs_ind … H) -L2 -T2 /width=1/ /2 width=4/
-qed.
-
-lemma fpcs_fprs_strap2: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L #T1 #T #H #L2 #T2 #HT2 @(fprs_ind_dx … H) -L1 -T1 /width=1/ /2 width=4/
-qed.
-
-lemma fpcs_fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L #T1 #T #HT1 #L2 #T2 #H @(fprs_ind_dx … H) -L2 -T2 /width=1/ /2 width=4/
-qed.
-
-lemma fpcs_fprs_conf: ∀L1,L,T1,T. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L #T1 #T #H #T2 #HT2 @(fprs_ind … H) -L1 -T1 /width=1/ /3 width=4 by fpcs_fpr_conf/ (**) (* /2 width=4/ does not work *)
-qed.
-
-lemma fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-#L1 #L #T1 #T #HT1 #T2 #L2 #H @(fprs_ind_dx … H) -L2 -T2 /2 width=1/ /2 width=4/
-qed.
-
-lemma fprs_fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=7 by bi_step, fprs_div/ qed-.
-
-lemma fpr_fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
-/3 width=4 by bi_step, fprs_div/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr.etc
deleted file mode 100644 (file)
index 3bb168f..0000000
+++ /dev/null
@@ -1,68 +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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ➡ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRed $L1 $T1 $L2 $T2 }.
-
-include "basic_2/reducibility/tpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
-
-definition fpr: bi_relation lenv term ≝
-                λL1,T1,L2,T2. |L1| = |L2| ∧ L1 @@ T1 ➡ L2 @@ T2.
-
-interpretation
-   "context-free parallel reduction (closure)"
-   'FocalizedPRed L1 T1 L2 T2 = (fpr L1 T1 L2 T2).
-
-(* Basic properties *********************************************************)
-
-lemma fpr_refl: bi_reflexive … fpr.
-/2 width=1/ qed.
-
-lemma fpr_shift: ∀I1,I2,L1,L2,V1,V2,T1,T2.
-                 ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
-                 ⦃L1.ⓑ{I1}V1, T1⦄ ➡ ⦃L2.ⓑ{I2}V2, T2⦄.
-#I1 #I2 #L1 #L2 #V1 #V2 #T1 #T2 * #HL12 #HT12
-@conj // normalize // (**) (* explicit constructor *)
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma fpr_inv_atom1: ∀L2,T1,T2. ⦃⋆, T1⦄ ➡ ⦃L2, T2⦄ → T1 ➡ T2 ∧ L2 = ⋆.
-#L2 #T1 #T2 * #H
-lapply (length_inv_zero_sn … H) -H #H destruct /2 width=1/
-qed-.
-
-lemma fpr_inv_atom3: ∀L1,T1,T2. ⦃L1,T1⦄ ➡ ⦃⋆,T2⦄ → T1 ➡ T2 ∧ L1 = ⋆.
-#L1 #T1 #T2 * #H
-lapply (length_inv_zero_dx … H) -H #H destruct /2 width=1/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma fpr_fwd_pair1: ∀I1,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I1}V1, T1⦄ ➡ ⦃L2, T2⦄ →
-                     ∃∃I2,K2,V2. ⦃K1, -ⓑ{I1}V1.T1⦄ ➡ ⦃K2, -ⓑ{I2}V2.T2⦄  &
-                                 L2 = K2.ⓑ{I2}V2.
-#I1 #K1 #L2 #V1 #T1 #T2 * #H
-elim (length_inv_pos_sn … H) -H #I2 #K2 #V2 #HK12 #H destruct /3 width=5/
-qed-.
-
-lemma fpr_fwd_pair3: ∀I2,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡ ⦃K2.ⓑ{I2}V2, T2⦄ →
-                     ∃∃I1,K1,V1. ⦃K1, -ⓑ{I1}V1.T1⦄ ➡ ⦃K2, -ⓑ{I2}V2.T2⦄  &
-                                 L1 = K1.ⓑ{I1}V1.
-#I2 #L1 #K2 #V2 #T1 #T2 * #H
-elim (length_inv_pos_dx … H) -H #I1 #K1 #V1 #HK12 #H destruct /3 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_cpr.etc
deleted file mode 100644 (file)
index baa630f..0000000
+++ /dev/null
@@ -1,125 +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/reducibility/cfpr_cpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
-
-(* Properties on context-sensitive parallel reduction for terms *************)
-
-lemma ltpr_tpr_fpr: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. T1 ➡ T2 → ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
-/3 width=4/ qed.
-
-lemma cpr_fpr: ∀L,T1,T2. L ⊢ T1 ➡ T2 → ⦃L, T1⦄ ➡ ⦃L, T2⦄.
-/2 width=4/ qed.
-
-lemma fpr_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ➡ ⦃K2, T2⦄ →
-                ∀d,e,L1. ⇩[d, e] L1 ≡ K1 →
-                ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                ∃∃L2. ⦃L1, U1⦄ ➡ ⦃L2, U2⦄ & ⇩[d, e] L2 ≡ K2.
-#K1 #K2 #T1 #T2 #HT12 #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
-elim (fpr_inv_all … HT12) -HT12 #K #HK1 #HT12 #HK2
-elim (ldrop_ltpr_trans … HLK1 … HK1) -K1 #L #HL1 #HLK
-lapply (cpr_lift … HLK … HTU1 … HTU2 HT12) -T1 -T2 #HU12
-elim (le_or_ge (|K|) d) #Hd
-[ elim (ldrop_ltpss_sn_trans_ge … HLK … HK2 …)
-| elim (ldrop_ltpss_sn_trans_be … HLK … HK2 …)
-] // -Hd #L2 #HL2 #HLK2
-lapply (ltpss_sn_weak_full … HL2) -K /3 width=4/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma fpr_flat_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
-                   ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ➡ ⦃L2, ⓕ{I}V2.T2⦄.
-#L1 #L2 #T1 #T2 #HT12
-elim (fpr_inv_all … HT12) -HT12 /4 width=4/
-qed.
-
-lemma fpr_bind_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ → ∀T1,T2. T1 ➡ T2 →
-                   ∀a,I. ⦃L1, ⓑ{a,I}V1.T1⦄ ➡ ⦃L2, ⓑ{a,I}V2.T2⦄.
-#L1 #L2 #V1 #V2 #H #T1 #T2 #HT12 #a #I
-elim (fpr_inv_all … H) /3 width=4/
-qed.
-
-lemma fpr_bind2_minus: ∀I,L1,L2,V1,T1,U2. ⦃L1, -ⓑ{I}V1.T1⦄ ➡ ⦃L2, U2⦄ →
-                       ∃∃V2,T2. ⦃L1.ⓑ{I}V1, T1⦄ ➡ ⦃L2.ⓑ{I}V2, T2⦄ &
-                                U2 = -ⓑ{I}V2.T2.
-#I1 #L1 #L2 #V1 #T1 #U2 #H
-elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
-elim (cpr_fwd_bind1_minus … H false) -H /4 width=4/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma fpr_fwd_bind2_minus: ∀I,L1,L,V1,T1,T. ⦃L1, -ⓑ{I}V1.T1⦄ ➡ ⦃L, T⦄ → ∀b.
-                           ∃∃V2,T2. ⦃L1, ⓑ{b,I}V1.T1⦄ ➡ ⦃L, ⓑ{b,I}V2.T2⦄ &
-                                    T = -ⓑ{I}V2.T2.
-#I #L1 #L #V1 #T1 #T #H1 #b
-elim (fpr_inv_all … H1) -H1 #L0 #HL10 #HT1 #HL0
-elim (cpr_fwd_bind1_minus … HT1 b) -HT1 /3 width=4/
-qed-.
-
-lemma fpr_fwd_shift_bind_minus: ∀I1,I2,L1,L2,V1,V2,T1,T2.
-                                ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
-                                ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ ∧ I1 = I2.
-* #I2 #L1 #L2 #V1 #V2 #T1 #T2 #H
-elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
-[ elim (cpr_inv_abbr1 … H) -H *
-  [ #V #V0 #T #HV1 #HV0 #_ #H destruct /4 width=4/
-  | #T #_ #_ #H destruct
-  ]
-| elim (cpr_inv_abst1 … H Abst V2) -H
-  #V #T #HV1 #_ #H destruct /3 width=4/
-]
-qed-.
-
-lemma fpr_fwd_abst2: ∀a,L1,L2,V1,T1,U2. ⦃L1, ⓛ{a}V1.T1⦄ ➡ ⦃L2, U2⦄ → ∀b,I,W.
-                     ∃∃V2,T2. ⦃L1, ⓑ{b,I}W.T1⦄ ➡ ⦃L2, ⓑ{b,I}W.T2⦄ &
-                              U2 = ⓛ{a}V2.T2.
-#a #L1 #L2 #V1 #T1 #U2 #H
-elim (fpr_inv_all … H) #L #HL1 #H #HL2 #b #I #W
-elim (cpr_fwd_abst1 … H b I W) -H /3 width=4/
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fpr_inv_pair1: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡ ⦃L2, T2⦄ →
-                     ∃∃K2,V2. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
-                              ⦃K1, -ⓑ{I}V1.T1⦄ ➡ ⦃K2, -ⓑ{I}V2.T2⦄ &
-                              L2 = K2.ⓑ{I}V2.
-#I1 #K1 #X #V1 #T1 #T2 #H
-elim (fpr_fwd_pair1 … H) -H #I2 #K2 #V2 #HT12 #H destruct
-elim (fpr_fwd_shift_bind_minus … HT12) #HV12 #H destruct /2 width=5/
-qed-.
-
-lemma fpr_inv_pair3: ∀I,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡ ⦃K2.ⓑ{I}V2, T2⦄ →
-                     ∃∃K1,V1. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
-                              ⦃K1, -ⓑ{I}V1.T1⦄ ➡ ⦃K2, -ⓑ{I}V2.T2⦄ &
-                              L1 = K1.ⓑ{I}V1.
-#I2 #X #K2 #V2 #T1 #T2 #H
-elim (fpr_fwd_pair3 … H) -H #I1 #K1 #V1 #HT12 #H destruct
-elim (fpr_fwd_shift_bind_minus … HT12) #HV12 #H destruct /2 width=5/
-qed-.
-
-(* More advanced forward lemmas *********************************************)
-
-lemma fpr_fwd_pair1_full: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡ ⦃L2, T2⦄ →
-                          ∀b. ∃∃K2,V2. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
-                                       ⦃K1, ⓑ{b,I}V1.T1⦄ ➡ ⦃K2, ⓑ{b,I}V2.T2⦄ &
-                                       L2 = K2.ⓑ{I}V2.
-#I #K1 #L2 #V1 #T1 #T2 #H #b
-elim (fpr_inv_pair1 … H) -H #K2 #V2 #HV12 #HT12 #H destruct
-elim (fpr_fwd_bind2_minus … HT12 b) -HT12 #W1 #U1 #HTU1 #H destruct /2 width=5/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fpr_fpr.etc
deleted file mode 100644 (file)
index 3f7ac2c..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/reducibility/tpr_tpr.ma".
-include "basic_2/reducibility/fpr.ma".
-
-(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
-
-(* Main properties **********************************************************)
-
-theorem fpr_conf: bi_confluent … fpr.
-#L0 #L1 #T0 #T1 * #HL01 #HT01 #L2 #T2 * >HL01 #HL12 #HT02
-elim (tpr_conf … HT01 HT02) -L0 -T0 #X #H1 #H2
-elim (tpr_fwd_shift1 … H1) #L #T #HL1 #H destruct /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs.etc
deleted file mode 100644 (file)
index f42bdf7..0000000
+++ /dev/null
@@ -1,58 +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 "hvbox( ⦃ term 46 L1 , term 46 T1 ⦄ ➡ * break ⦃ term 46 L2 , term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRedStar $L1 $T1 $L2 $T2 }.
-
-notation "hvbox( ⦃ term 46 L1 , term 46 T1 ⦄ ➡ ➡ * break ⦃ term 46 L2 , term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRedStarAlt $L1 $T1 $L2 $T2 }.
-
-include "basic_2/reducibility/fpr.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
-
-definition fprs: bi_relation lenv term ≝ bi_TC … fpr.
-
-interpretation "context-free parallel computation (closure)"
-   'FocalizedPRedStar L1 T1 L2 T2 = (fprs L1 T1 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma fprs_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
-                (∀L,L2,T,T2. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → R L T → R L2 T2) →
-                ∀L2,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → R L2 T2.
-/3 width=7 by bi_TC_star_ind/ qed-.
-
-lemma fprs_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
-                   (∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ → R L T → R L1 T1) →
-                   ∀L1,T1. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → R L1 T1.
-/3 width=7 by bi_TC_star_ind_dx/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma fpr_fprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
-/2 width=1/ qed.
-
-lemma fprs_refl: bi_reflexive … fprs.
-/2 width=1/ qed.
-
-lemma fprs_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ →
-                   ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma fprs_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ →
-                   ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
-/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_aaa.etc
deleted file mode 100644 (file)
index b76637f..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/reducibility/cfpr_aaa.ma".
-include "basic_2/computation/fprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_fprs_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
-                     ∀L2,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → L2 ⊢ T2 ⁝ A.
-#L1 #T1 #A #HT1 #L2 #T2 #HLT12
-@(bi_TC_Conf3 … HT1 ?? HLT12) /2 width=4/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_cprs.etc
deleted file mode 100644 (file)
index 9d4d954..0000000
+++ /dev/null
@@ -1,138 +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/reducibility/fpr_cpr.ma".
-include "basic_2/computation/cprs_lfprs.ma".
-include "basic_2/computation/lfprs_ltprs.ma".
-include "basic_2/computation/lfprs_fprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fprs_flat_dx_tpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
-                        ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ➡* ⦃L2, ⓕ{I}V2.T2⦄.
-#L1 #L2 #T1 #T2 #HT12 @(fprs_ind … HT12) -L2 -T2 /3 width=1/
-#L #L2 #T #T2 #_ #HT2 #IHT2 #V1 #V2 #HV12 #I
-lapply (IHT2 … HV12 I) -IHT2 -HV12 /3 width=6/
-qed.
-
-lemma fprs_bind2_minus: ∀I,L1,L2,V1,T1,U2. ⦃L1, -ⓑ{I}V1.T1⦄ ➡* ⦃L2, U2⦄ →
-                        ∃∃V2,T2. ⦃L1.ⓑ{I}V1, T1⦄ ➡* ⦃L2.ⓑ{I}V2, T2⦄ &
-                                 U2 = -ⓑ{I}V2.T2.
-#I #L1 #L2 #V1 #T1 #U2 #H @(fprs_ind … H) -L2 -U2 /2 width=4/
-#L #L2 #U #U2 #_ #HU2 * #V #T #HT1 #H destruct
-elim (fpr_bind2_minus … HU2) -HU2 /3 width=4/
-qed-.
-
-lemma fprs_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ➡* ⦃K2, T2⦄ →
-                 ∀d,e,L1. ⇩[d, e] L1 ≡ K1 →
-                 ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                 ∃∃L2. ⦃L1, U1⦄ ➡* ⦃L2, U2⦄ & ⇩[d, e] L2 ≡ K2.
-#K1 #K2 #T1 #T2 #HT12 @(fprs_ind … HT12) -K2 -T2
-[ #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
-  >(lift_mono … HTU2 … HTU1) -U2 /2 width=3/
-| #K #K2 #T #T2 #_ #HT2 #IHT1 #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
-  elim (lift_total T d e) #U #HTU
-  elim (IHT1 … HLK1 … HTU1 HTU) -K1 -T1 #L #HU1 #HKL
-  elim (fpr_lift … HT2 … HKL … HTU HTU2) -K -T -T2 /3 width=4/
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma fprs_inv_pair1: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡* ⦃L2, T2⦄ →
-                      ∃∃K2,V2. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
-                               ⦃K1, -ⓑ{I}V1.T1⦄ ➡* ⦃K2, -ⓑ{I}V2.T2⦄  &
-                               L2 = K2.ⓑ{I}V2.
-#I #K1 #L2 #V1 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 /2 width=5/
-#L #L2 #T #T2 #_ #HT2 * #K #V #HV1 #HT1 #H destruct
-elim (fpr_inv_pair1 … HT2) -HT2 #K2 #V2 #HV2 #HT2 #H destruct /3 width=5/
-qed-.
-
-lemma fprs_inv_pair3: ∀I,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡* ⦃K2.ⓑ{I}V2, T2⦄ →
-                      ∃∃K1,V1. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
-                               ⦃K1, -ⓑ{I}V1.T1⦄ ➡* ⦃K2, -ⓑ{I}V2.T2⦄  &
-                               L1 = K1.ⓑ{I}V1.
-#I2 #L1 #K2 #V2 #T1 #T2 #H @(fprs_ind_dx … H) -L1 -T1 /2 width=5/
-#L1 #L #T1 #T #HT1 #_ * #K #V #HV2 #HT2 #H destruct
-elim (fpr_inv_pair3 … HT1) -HT1 #K1 #V1 #HV1 #HT1 #H destruct /3 width=5/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma fprs_fwd_bind2_minus: ∀I,L1,L,V1,T1,T. ⦃L1, -ⓑ{I}V1.T1⦄ ➡* ⦃L, T⦄ → ∀b.
-                            ∃∃V2,T2. ⦃L1, ⓑ{b,I}V1.T1⦄ ➡* ⦃L, ⓑ{b,I}V2.T2⦄ &
-                                     T = -ⓑ{I}V2.T2.
-#I #L1 #L #V1 #T1 #T #H1 #b @(fprs_ind … H1) -L -T /2 width=4/
-#L0 #L #T0 #T #_ #H0 * #W1 #U1 #HTU1 #H destruct
-elim (fpr_fwd_bind2_minus … H0 b) -H0 /3 width=4/
-qed-.
-
-lemma fprs_fwd_pair1_full: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡* ⦃L2, T2⦄ →
-                           ∀b. ∃∃K2,V2. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
-                                        ⦃K1, ⓑ{b,I}V1.T1⦄ ➡* ⦃K2, ⓑ{b,I}V2.T2⦄ &
-                                        L2 = K2.ⓑ{I}V2.
-#I #K1 #L2 #V1 #T1 #T2 #H #b
-elim (fprs_inv_pair1 … H) -H #K2 #V2 #HV12 #HT12 #H destruct
-elim (fprs_fwd_bind2_minus … HT12 b) -HT12 #W1 #U1 #HTU1 #H destruct /2 width=5/
-qed-.
-
-lemma fprs_fwd_abst2: ∀a,L1,L2,V1,T1,U2. ⦃L1, ⓛ{a}V1.T1⦄ ➡* ⦃L2, U2⦄ → ∀b,I,W.
-                      ∃∃V2,T2. ⦃L1, ⓑ{b,I}W.T1⦄ ➡* ⦃L2, ⓑ{b,I}W.T2⦄ &
-                               U2 = ⓛ{a}V2.T2.
-#a #L1 #L2 #V1 #T1 #U2 #H #b #I #W @(fprs_ind … H) -L2 -U2 /2 width=4/
-#L #L2 #U #U2 #_ #H2 * #V #T #HT1 #H destruct
-elim (fpr_fwd_abst2 … H2 b I W) -H2 /3 width=4/
-qed-.
-
-(* Properties on context-sensitive parallel computation for terms ***********)
-
-lemma cprs_fprs: ∀L,T1,T2. L ⊢ T1 ➡* T2 → ⦃L, T1⦄ ➡* ⦃L, T2⦄.
-#L #T1 #T2 #H @(cprs_ind … H) -T2 // /3 width=4/
-qed.
-
-(* Forward lemmas on context-sensitive parallel computation for terms *******)
-
-lemma fprs_fwd_cprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → L1 ⊢ T1 ➡* T2.
-#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 //
-#L #L2 #T #T2 #H1 #H2 #IH1
-elim (fpr_inv_all … H2) -H2 #L0 #HL0 #HT2 #_ -L2
-lapply (lfprs_cpr_trans L1 … HT2) -HT2 /3 width=3/
-qed-.
-(*
-(* Advanced properties ******************************************************)
-
-lamma fpr_bind_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ → ∀T1,T2. T1 ➡ T2 →
-                   ∀a,I. ⦃L1, ⓑ{a,I}V1.T1⦄ ➡ ⦃L2, ⓑ{a,I}V2.T2⦄.
-#L1 #L2 #V1 #V2 #H #T1 #T2 #HT12 #a #I
-elim (fpr_inv_all … H) /3 width=4/
-qed.
-
-(* Advanced forward lemmas **************************************************)
-
-lamma fpr_fwd_shift_bind_minus: ∀I1,I2,L1,L2,V1,V2,T1,T2.
-                                ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
-                                ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ ∧ I1 = I2.
-* #I2 #L1 #L2 #V1 #V2 #T1 #T2 #H
-elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
-[ elim (cpr_inv_abbr1 … H) -H *
-  [ #V #V0 #T #HV1 #HV0 #_ #H destruct /4 width=4/
-  | #T #_ #_ #H destruct
-  ]
-| elim (cpr_inv_abst1 … H Abst V2) -H
-  #V #T #HV1 #_ #H destruct /3 width=4/
-]
-qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/fprs_fprs.etc
deleted file mode 100644 (file)
index e0c1b30..0000000
+++ /dev/null
@@ -1,34 +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/reducibility/fpr_fpr.ma".
-include "basic_2/computation/fprs.ma".
-
-(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
-
-(* Advanced properties ******************************************************)
-
-lemma fprs_strip: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ➡ ⦃L1, T1⦄ →
-                  ∀L2,T2. ⦃L0, T0⦄ ➡* ⦃L2, T2⦄ →
-                  ∃∃L,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ & ⦃L2, T2⦄ ➡ ⦃L, T⦄.
-#H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8
-/2 width=4/ qed.
-
-(* Main propertis ***********************************************************)
-
-theorem fprs_conf: bi_confluent … fprs.
-/2 width=4/ qed.
-
-theorem fprs_trans: bi_transitive … fprs.
-/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lenv_px_bi.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lenv_px_bi.etc
deleted file mode 100644 (file)
index 931d075..0000000
+++ /dev/null
@@ -1,88 +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/grammar/lenv_length.ma".
-
-(* POINTWISE EXTENSION OF A FOCALIZED REALTION FOR TERMS ********************)
-
-inductive lpx_bi (R:bi_relation lenv term): relation lenv ≝
-| lpx_bi_stom: lpx_bi R (⋆) (⋆)
-| lpx_bi_pair: ∀I,K1,K2,V1,V2.
-               lpx_bi R K1 K2 → R K1 V1 K2 V2 →
-               lpx_bi R (K1. ⓑ{I} V1) (K2. ⓑ{I} V2)
-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lpx_bi_inv_atom1_aux: ∀R,L1,L2. lpx_bi R L1 L2 → L1 = ⋆ → L2 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_bi_inv_atom1: ∀R,L2. lpx_bi R (⋆) L2 → L2 = ⋆.
-/2 width=4 by lpx_bi_inv_atom1_aux/ qed-.
-
-fact lpx_bi_inv_pair1_aux: ∀R,L1,L2. lpx_bi R L1 L2 →
-                           ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
-                           ∃∃K2,V2. lpx_bi R K1 K2 &
-                                    R K1 V1 K2 V2 & L2 = K2. ⓑ{I} V2.
-#R #L1 #L2 * -L1 -L2
-[ #J #K1 #V1 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5/
-]
-qed-.
-
-lemma lpx_bi_inv_pair1: ∀R,I,K1,V1,L2. lpx_bi R (K1. ⓑ{I} V1) L2 →
-                        ∃∃K2,V2. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
-                                 L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_bi_inv_pair1_aux/ qed-.
-
-fact lpx_bi_inv_atom2_aux: ∀R,L1,L2. lpx_bi R L1 L2 → L2 = ⋆ → L1 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_bi_inv_atom2: ∀R,L1. lpx_bi R L1 (⋆) → L1 = ⋆.
-/2 width=4 by lpx_bi_inv_atom2_aux/ qed-.
-
-fact lpx_bi_inv_pair2_aux: ∀R,L1,L2. lpx_bi R L1 L2 →
-                           ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
-                           ∃∃K1,V1. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
-                                    L1 = K1. ⓑ{I} V1.
-#R #L1 #L2 * -L1 -L2
-[ #J #K2 #V2 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5/
-]
-qed-.
-
-lemma lpx_bi_inv_pair2: ∀R,I,L1,K2,V2. lpx_bi R L1 (K2. ⓑ{I} V2) →
-                        ∃∃K1,V1. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
-                                 L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_bi_inv_pair2_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpx_bi_fwd_length: ∀R,L1,L2. lpx_bi R L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H -L1 -L2 normalize //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpx_bi_refl: ∀R. bi_reflexive ? ? R → reflexive … (lpx_bi R).
-#R #HR #L elim L -L // /2 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_alt.etc
deleted file mode 100644 (file)
index 95ec60b..0000000
+++ /dev/null
@@ -1,87 +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 "hvbox( L1 ⊢ ➡ ➡ break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'PRedSnAlt $L1 $L2 }.
-
-notation "hvbox( ⦃ term 46 L1 ⦄ ➡ ➡ break ⦃ term 46 L2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPRedAlt $L1 $L2 }.
-
-include "basic_2/grammar/lenv_px_bi.ma".
-include "basic_2/reducibility/fpr_cpr.ma".
-include "basic_2/reducibility/lfpr_fpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
-
-(* alternative definition *)
-definition lfpra: relation lenv ≝ lpx_bi fpr.
-
-interpretation
-  "focalized parallel reduction (environment) alternative"
-  'FocalizedPRedAlt L1 L2 = (lfpra L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lfpra_refl: reflexive … lfpra.
-/2 width=1/ qed.
-
-lemma fpr_lfpra: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1⦄ ➡➡ ⦃L2⦄.
-#L1 elim L1 -L1
-[ #L2 #T1 #T2 #H
-  elim (fpr_inv_atom1 … H) -H #_ #H destruct //
-| #L1 #I #V1 #IH #L2 #T1 #T2 #H
-  elim (fpr_inv_pair1 … H) -H #L #V #HV1 #HL1 #H destruct /3 width=3/
-]
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lfpra_inv_atom1: ∀L2. ⦃⋆⦄ ➡➡ ⦃L2⦄ → L2 = ⋆.
-/2 width=2 by lpx_bi_inv_atom1/ qed-.
-
-lemma lfpra_inv_pair1: ∀K1,I,V1,L2. ⦃K1. ⓑ{I} V1⦄ ➡➡ ⦃L2⦄ →
-                       ∃∃K2,V2. ⦃K1⦄ ➡➡ ⦃K2⦄ & ⦃K1, V1⦄ ➡ ⦃K2, V2⦄ &
-                                L2 = K2. ⓑ{I} V2.
-/2 width=1 by lpx_bi_inv_pair1/ qed-.
-
-lemma lfpra_inv_atom2: ∀L1. ⦃L1⦄ ➡➡ ⦃⋆⦄ → L1 = ⋆.
-/2 width=2 by lpx_bi_inv_atom2/ qed-.
-
-lemma lfpra_inv_pair2: ∀L1,K2,I,V2. ⦃L1⦄ ➡➡ ⦃K2. ⓑ{I} V2⦄ →
-                       ∃∃K1,V1. ⦃K1⦄ ➡➡ ⦃K2⦄ & ⦃K1, V1⦄ ➡ ⦃K2, V2⦄ &
-                                L1 = K1. ⓑ{I} V1.
-/2 width=1 by lpx_bi_inv_pair2/ qed-.
-
-lemma lfpra_inv_fpr: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → ∀T.⦃L1, T⦄ ➡ ⦃L2, T⦄.
-#L1 #L2 * -L1 -L2 // /3 width=1/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lfpra_fwd_length: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → |L1| = |L2|.
-/2 width=2 by lpx_bi_fwd_length/ qed-.
-
-(* Main properties **********************************************************)
-
-theorem lfpr_lfpra: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ➡➡ ⦃L2⦄.
-#L1 #L2 #H
-lapply (lfpr_inv_fpr … H (⋆0)) -H /2 width=3/
-qed.
-
-theorem lfpra_lfpr: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → ⦃L1⦄ ➡ ⦃L2⦄.
-#L1 #L2 #H
-lapply (lfpra_inv_fpr … H (⋆0)) -H /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfpr_fpr.etc
deleted file mode 100644 (file)
index f798d56..0000000
+++ /dev/null
@@ -1,31 +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/reducibility/lfpr.ma".
-include "basic_2/reducibility/cfpr_cpr.ma".
-
-(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
-
-(* Properties on context-free parallel reduction for closures ***************)
-
-lemma fpr_lfpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1⦄ ➡ ⦃L2⦄.
-#L1 #L2 #T1 #T2 #H
-elim (fpr_inv_all … H) -H /2 width=3/
-qed.
-
-(* Inversion lemmas on context-free parallel reduction for closures *********)
-
-lemma lfpr_inv_fpr: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ∀T. ⦃L1, T⦄ ➡ ⦃L2, T⦄.
-#L1 #L2 * /2 width=4/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfprs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fpr/lfprs_fprs.etc
deleted file mode 100644 (file)
index a5c42ba..0000000
+++ /dev/null
@@ -1,41 +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/reducibility/lfpr_fpr.ma".
-include "basic_2/computation/fprs_fprs.ma".
-include "basic_2/computation/lfprs.ma".
-
-(* FOCALIZED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *********************)
-
-(* Inversion lemmas on context-free parallel reduction for closures *********)
-
-lemma lfprs_inv_fprs: ∀L1,L2. ⦃L1⦄ ➡* ⦃L2⦄ → ∀T. ⦃L1, T⦄ ➡* ⦃L2, T⦄.
-#L1 #L2 #H @(lfprs_ind … H) -L2 //
-#L #L2 #_ #HL2 #IHL1 #T
-lapply (lfpr_inv_fpr … HL2 T) -HL2 /3 width=4/
-qed-.
-
-(* Properties on context-free parallel computation for closures *************)
-
-lemma fprs_lfprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1⦄ ➡* ⦃L2⦄.
-#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 // /3 width=5/
-qed.
-
-lemma lfprs_fprs_trans: ∀L1,L,L2,T1,T2. ⦃L1⦄ ➡* ⦃L⦄ → ⦃L, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
-#L1 #L #L2 #T1 #T2 #HL1 #HL2
-lapply (lfprs_inv_fprs … HL1 T1) -HL1 /2 width=4/
-qed.
-(*
-lamma lfprs_cprs_conf: ∀L1,L,L2,T1,T2. ⦃L1⦄ ➡* ⦃L2⦄ → L1 ⊢ T1 ➡* T2 → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsup.etc
deleted file mode 100644 (file)
index 077fd74..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-notation "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'RestSupTerm $L1 $T1 $L2 $T2 }.
-
-include "basic_2/grammar/cl_weight.ma".
-include "basic_2/substitution/lift.ma".
-
-(* RESTRICTED SUPCLOSURE ****************************************************)
-
-inductive frsup: bi_relation lenv term ≝
-| frsup_bind_sn: ∀a,I,L,V,T. frsup L (ⓑ{a,I}V.T) L V
-| frsup_bind_dx: ∀a,I,L,V,T. frsup L (ⓑ{a,I}V.T) (L.ⓑ{I}V) T
-| frsup_flat_sn: ∀I,L,V,T.   frsup L (ⓕ{I}V.T) L V
-| frsup_flat_dx: ∀I,L,V,T.   frsup L (ⓕ{I}V.T) L T
-.
-
-interpretation
-   "restricted structural predecessor (closure)"
-   'RestSupTerm L1 T1 L2 T2 = (frsup L1 T1 L2 T2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact frsup_inv_atom1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
-                          ∀J. T1 = ⓪{J} → ⊥.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #a #I #L #V #T #J #H destruct
-| #a #I #L #V #T #J #H destruct
-| #I #L #V #T #J #H destruct
-| #I #L #V #T #J #H destruct
-]
-qed-.
-
-lemma frsup_inv_atom1: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⧁ ⦃L2, T2⦄ → ⊥.
-/2 width=7 by frsup_inv_atom1_aux/ qed-.
-
-fact frsup_inv_bind1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
-                          ∀b,J,W,U. T1 = ⓑ{b,J}W.U →
-                          (L2 = L1 ∧ T2 = W) ∨
-                          (L2 = L1.ⓑ{J}W ∧ T2 = U).
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
-| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
-| #I #L #V #T #b #J #W #U #H destruct
-| #I #L #V #T #b #J #W #U #H destruct
-]
-qed-.
-
-lemma frsup_inv_bind1: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⧁ ⦃L2, T2⦄ →
-                       (L2 = L1 ∧ T2 = W) ∨
-                       (L2 = L1.ⓑ{J}W ∧ T2 = U).
-/2 width=4 by frsup_inv_bind1_aux/ qed-.
-
-fact frsup_inv_flat1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
-                          ∀J,W,U. T1 = ⓕ{J}W.U →
-                          L2 = L1 ∧ (T2 = W ∨ T2 = U).
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #a #I #L #V #T #J #W #U #H destruct
-| #a #I #L #V #T #J #W #U #H destruct
-| #I #L #V #T #J #W #U #H destruct /3 width=1/
-| #I #L #V #T #J #W #U #H destruct /3 width=1/
-]
-qed-.
-
-lemma frsup_inv_flat1: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⧁ ⦃L2, T2⦄ →
-                       L2 = L1 ∧ (T2 = W ∨ T2 = U).
-/2 width=4 by frsup_inv_flat1_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma frsup_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{L2, T2} < ♯{L1, T1}.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/
-qed-.
-
-lemma frsup_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/
-qed-.
-
-lemma frsup_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{T2} < ♯{T1}.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/ /2 width=1 by le_minus_to_plus/
-qed-.
-
-lemma frsup_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #a
-| #a #I #L #V #_ @(ex_intro … (⋆.ⓑ{I}V)) //
-]
-#I #L #V #T @(ex_intro … (⋆)) //
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lift_frsup_trans: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
-                        ∀L,K,U2. ⦃L, U1⦄ ⧁ ⦃L @@ K, U2⦄ →
-                        ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
-#T1 #U1 #d #e * -T1 -U1 -d -e
-[5: #a #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HTU1 #L #K #X #H
-    elim (frsup_inv_bind1 … H) -H *
-    [ -HTU1 #H1 #H2 destruct
-      >(append_inv_refl_dx … H1) -L -K normalize /2 width=2/
-    | -HVW1 #H1 #H2 destruct
-      >(append_inv_pair_dx … H1) -L -K normalize /2 width=2/
-    ]
-|6: #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HUT1 #L #K #X #H
-    elim (frsup_inv_flat1 … H) -H #H1 * #H2 destruct
-    >(append_inv_refl_dx … H1) -L -K normalize /2 width=2/
-]
-#i #d #e [2,3: #_ ] #L #K #X #H
-elim (frsup_inv_atom1 … H)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp.etc
deleted file mode 100644 (file)
index 9f7a8dc..0000000
+++ /dev/null
@@ -1,110 +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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ + break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'RestSupTermPlus $L1 $T1 $L2 $T2 }.
-
-include "basic_2/substitution/frsup.ma".
-
-(* PLUS-ITERATED RESTRICTED SUPCLOSURE **************************************)
-
-definition frsupp: bi_relation lenv term ≝ bi_TC … frsup.
-
-interpretation "plus-iterated restricted structural predecessor (closure)"
-   'RestSupTermPlus L1 T1 L2 T2 = (frsupp L1 T1 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma frsupp_ind: ∀L1,T1. ∀R:relation2 lenv term.
-                  (∀L2,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → R L2 T2) →
-                  (∀L,T,L2,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ → R L T → R L2 T2) →
-                  ∀L2,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → R L2 T2.
-#L1 #T1 #R #IH1 #IH2 #L2 #T2 #H
-@(bi_TC_ind … IH1 IH2 ? ? H)
-qed-.
-
-lemma frsupp_ind_dx: ∀L2,T2. ∀R:relation2 lenv term.
-                     (∀L1,T1. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → R L1 T1) →
-                     (∀L1,L,T1,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ → R L T → R L1 T1) →
-                     ∀L1,T1. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → R L1 T1.
-#L2 #T2 #R #IH1 #IH2 #L1 #T1 #H
-@(bi_TC_ind_dx … IH1 IH2 ? ? H)
-qed-.
-
-(* Baic inversion lemmas ****************************************************)
-
-lemma frsupp_inv_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ ∨
-                     ∃∃L,T. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ & ⦃L, T⦄ ⧁ ⦃L2, T2⦄.
-/2 width=1 by bi_TC_decomp_r/ qed-.
-
-lemma frsupp_inv_sn: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ ∨
-                     ∃∃L,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ & ⦃L, T⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=1 by bi_TC_decomp_l/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma frsup_frsupp: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=1/ qed.
-
-lemma frsupp_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ →
-                     ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma frsupp_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ →
-                     ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma frsupp_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{L2, T2} < ♯{L1, T1}.
-#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
-/3 width=3 by frsup_fwd_fw, transitive_lt/
-qed-.
-
-lemma frsupp_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
-#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
-/2 width=3 by frsup_fwd_lw/ (**) (* /3 width=5 by frsup_fwd_lw, transitive_le/ is too slow *)
-#L #T #L2 #T2 #_ #HL2 #HL1
-lapply (frsup_fwd_lw … HL2) -HL2 /2 width=3 by transitive_le/
-qed-.
-
-lemma frsupp_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{T2} < ♯{T1}.
-#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
-/3 width=3 by frsup_fwd_tw, transitive_lt/
-qed-.
-
-lemma frsupp_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
-#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2 /2 width=3 by frsup_fwd_append/
-#L #T #L2 #T2 #_ #HL2 * #K1 #H destruct
-elim (frsup_fwd_append … HL2) -HL2 #K2 #H destruct /2 width=2/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lift_frsupp_trans: ∀L,U1,K,U2. ⦃L, U1⦄ ⧁+ ⦃L @@ K, U2⦄ →
-                         ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
-                         ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
-#L #U1 @(f2_ind … fw … L U1) -L -U1 #n #IH
-#L #U1 #Hn #K #U2 #H #T1 #d #e #HTU1 destruct
-elim (frsupp_inv_sn … H) -H /2 width=5 by lift_frsup_trans/ *
-#L0 #U0 #HL0 #HL
-elim (frsup_fwd_append … HL0) #K0 #H destruct
-elim (frsupp_fwd_append … HL) #L0 >append_assoc #H
-elim (append_inj_dx … H ?) -H // #_ #H destruct
-<append_assoc in HL; #HL
-elim (lift_frsup_trans … HTU1 … HL0) -T1 #T #HTU
-lapply (frsup_fwd_fw … HL0) -HL0 #HL0
-elim (IH … HL … HTU) -IH -HL -T // -L -U1 -U0 /2 width=2/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp_frsupp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsupp_frsupp.etc
deleted file mode 100644 (file)
index 92efe26..0000000
+++ /dev/null
@@ -1,22 +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/unfold/frsupp.ma".
-
-(* PLUS-ITERATED RESTRICTED SUPCLOSURE **************************************)
-
-(* Main propertis ***********************************************************)
-
-theorem frsupp_trans: bi_transitive … frsupp.
-/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups.etc
deleted file mode 100644 (file)
index 6e70e76..0000000
+++ /dev/null
@@ -1,137 +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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'RestSupTermStar $L1 $T1 $L2 $T2 }.
-
-include "basic_2/unfold/frsupp.ma".
-
-(* STAR-ITERATED RESTRICTED SUPCLOSURE **************************************)
-
-definition frsups: bi_relation lenv term ≝ bi_star … frsup.
-
-interpretation "star-iterated restricted structural predecessor (closure)"
-   'RestSupTermStar L1 T1 L2 T2 = (frsups L1 T1 L2 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma frsups_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
-                  (∀L,L2,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ → R L T → R L2 T2) →
-                  ∀L2,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → R L2 T2.
-#L1 #T1 #R #IH1 #IH2 #L2 #T2 #H
-@(bi_star_ind … IH1 IH2 ? ? H)
-qed-.
-
-lemma frsups_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
-                     (∀L1,L,T1,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁* ⦃L2, T2⦄ → R L T → R L1 T1) →
-                     ∀L1,T1. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → R L1 T1.
-#L2 #T2 #R #IH1 #IH2 #L1 #T1 #H
-@(bi_star_ind_dx … IH1 IH2 ? ? H)
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma frsups_refl: bi_reflexive … frsups.
-/2 width=1/ qed.
-
-lemma frsupp_frsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
-/2 width=1/ qed.
-
-lemma frsup_frsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
-/2 width=1/ qed.
-
-lemma frsups_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ →
-                     ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma frsups_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁* ⦃L2, T2⦄ →
-                     ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma frsups_frsupp_frsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ →
-                            ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-lemma frsupp_frsups_frsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ →
-                            ⦃L, T⦄ ⧁* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-/2 width=4/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma frsups_inv_all: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ →
-                      (L1 = L2 ∧ T1 = T2) ∨ ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
-#L1 #L2 #T1 #T2 * /2 width=1/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma frsups_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{L2, T2} ≤ ♯{L1, T1}.
-#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
-/3 width=1 by frsupp_fwd_fw, lt_to_le/
-qed-.
-
-lemma frsups_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
-#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
-/2 width=3 by frsupp_fwd_lw/
-qed-.
-
-lemma frsups_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{T2} ≤ ♯{T1}.
-#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
-/3 width=3 by frsupp_fwd_tw, lt_to_le/
-qed-.
-
-lemma frsups_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
-#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H
-[ * #H1 #H2 destruct
-  @(ex_intro … (⋆)) //
-| /2 width=3 by frsupp_fwd_append/
-qed-.
-
-(* Advanced forward lemmas ***************************************************)
-
-lemma lift_frsups_trans: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
-                         ∀L,K,U2. ⦃L, U1⦄ ⧁* ⦃L @@ K, U2⦄ →
-                         ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
-#T1 #U1 #d #e #HTU1 #L #K #U2 #H elim (frsups_inv_all … H) -H
-[ * #H1 #H2 destruct
-  >(append_inv_refl_dx … (sym_eq … H1)) -H1 normalize /2 width=2/
-| /2 width=5 by lift_frsupp_trans/
-]
-qed-.
-
-(* Advanced inversion lemmas for frsupp **************************************)
-
-lemma frsupp_inv_atom1_frsups: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⧁+ ⦃L2, T2⦄ → ⊥.
-#J #L1 #L2 #T2 #H @(frsupp_ind … H) -L2 -T2 //
-#L2 #T2 #H elim (frsup_inv_atom1 … H)
-qed-.
-
-lemma frsupp_inv_bind1_frsups: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⧁+ ⦃L2, T2⦄ →
-                               ⦃L1, W⦄ ⧁* ⦃L2, T2⦄ ∨ ⦃L1.ⓑ{J}W, U⦄ ⧁* ⦃L2, T2⦄.
-#b #J #L1 #L2 #W #U #T2 #H @(frsupp_ind … H) -L2 -T2
-[ #L2 #T2 #H
-  elim (frsup_inv_bind1 … H) -H * #H1 #H2 destruct /2 width=1/
-| #L #T #L2 #T2 #_ #HT2 * /3 width=4/
-]
-qed-.
-
-lemma frsupp_inv_flat1_frsups: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⧁+ ⦃L2, T2⦄ →
-                               ⦃L1, W⦄ ⧁* ⦃L2, T2⦄ ∨ ⦃L1, U⦄ ⧁* ⦃L2, T2⦄.
-#J #L1 #L2 #W #U #T2 #H @(frsupp_ind … H) -L2 -T2
-[ #L2 #T2 #H
-  elim (frsup_inv_flat1 … H) -H #H1 * #H2 destruct /2 width=1/
-| #L #T #L2 #T2 #_ #HT2 * /3 width=4/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups_frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/frsups_frsups.etc
deleted file mode 100644 (file)
index e7b7de2..0000000
+++ /dev/null
@@ -1,22 +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/unfold/frsups.ma".
-
-(* STAR-ITERATED RESTRICTED SUPCLOSURE **************************************)
-
-(* Main propertis ***********************************************************)
-
-theorem frsups_trans: bi_transitive … frsups.
-/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/ssta_frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/frsup/ssta_frsups.etc
deleted file mode 100644 (file)
index 9eb1fbd..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/unfold/frsups.ma".
-include "basic_2/static/ssta.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma ssta_inv_frsupp: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → ⦃L, U⦄ ⧁+ ⦃L, T⦄ → ⊥.
-#h #g #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #l #_ #H
-  elim (frsupp_inv_atom1_frsups … H)
-| #L #K #V #W #U #i #l #_ #_ #HWU #_ #H
-  elim (lift_frsupp_trans … (⋆) … H … HWU) -U #X #H
-  elim (lift_inv_lref2_be … H ? ?) -H //
-| #L #K #W #V #U #i #l #_ #_ #HWU #_ #H
-  elim (lift_frsupp_trans … (⋆) … H … HWU) -U #X #H
-  elim (lift_inv_lref2_be … H ? ?) -H //
-| #a #I #L #V #T #U #l #_ #IHTU #H
-  elim (frsupp_inv_bind1_frsups … H) -H #H [2: /4 width=4/ ] -IHTU
-  lapply (frsups_fwd_fw … H) -H normalize
-  <associative_plus <associative_plus #H
-  elim (le_plus_xySz_x_false … H)
-| #L #V #T #U #l #_ #IHTU #H
-  elim (frsupp_inv_flat1_frsups … H) -H #H [2: /4 width=4/ ] -IHTU
-  lapply (frsups_fwd_fw … H) -H normalize
-  <associative_plus <associative_plus #H
-  elim (le_plus_xySz_x_false … H)
-| /3 width=4/
-]
-qed-.
-
-fact ssta_inv_refl_aux: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → T = U → ⊥.
-#h #g #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #l #_ #H
-  lapply (next_lt h k) destruct -H -e0 (**) (* destruct: these premises are not erased *)
-  <e1 -e1 #H elim (lt_refl_false … H)
-| #L #K #V #W #U #i #l #_ #_ #HWU #_ #H destruct
-  elim (lift_inv_lref2_be … HWU ? ?) -HWU //
-| #L #K #W #V #U #i #l #_ #_ #HWU #_ #H destruct
-  elim (lift_inv_lref2_be … HWU ? ?) -HWU //
-| #a #I #L #V #T #U #l #_ #IHTU #H destruct /2 width=1/
-| #L #V #T #U #l #_ #IHTU #H destruct /2 width=1/
-| #L #W #T #U #l #HTU #_ #H destruct
-  elim (ssta_inv_frsupp … HTU ?) -HTU /2 width=1/
-]
-qed-.
-
-lemma ssta_inv_refl: ∀h,g,T,L,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, T⦄ → ⊥.
-/2 width=8 by ssta_inv_refl_aux/ qed-.
-
-lemma ssta_inv_frsups: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → ⦃L, U⦄ ⧁* ⦃L, T⦄ → ⊥.
-#h #g #L #T #U #L #HTU #H elim (frsups_inv_all … H) -H
-[ * #_ #H destruct /2 width=6 by ssta_inv_refl/
-| /2 width=8 by ssta_inv_frsupp/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsup.etc
deleted file mode 100644 (file)
index b3970be..0000000
+++ /dev/null
@@ -1,73 +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/ldrop.ma".
-
-(* SUPCLOSURE ***************************************************************)
-
-(* Basic inversion lemmas ***************************************************)
-
-fact fsup_inv_atom1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀J. T1 = ⓪{J} →
-                         (∃∃I,K,V. L1 = K.ⓑ{I}V & J = LRef 0 & L2 = K & T2 = V) ∨
-                         ∃∃I,K,V,i. ⦃K, #i⦄ ⊃ ⦃L2, T2⦄ & L1 = K.ⓑ{I}V & J = LRef (i+1).
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #I #L #V #J #H destruct /3 width=6/
-| #I #L #K #V #T #i #HLK #J #H destruct /3 width=7/
-| #a #I #L #V #T #J #H destruct
-| #a #I #L #V #T #J #H destruct
-| #I #L #V #T #J #H destruct
-| #I #L #V #T #J #H destruct
-]
-qed-.
-
-lemma fsup_inv_atom1: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⊃ ⦃L2, T2⦄ →
-                      (∃∃I,K,V. L1 = K.ⓑ{I}V & J = LRef 0 & L2 = K & T2 = V) ∨
-                      ∃∃I,K,V,i. ⦃K, #i⦄ ⊃ ⦃L2, T2⦄ & L1 = K.ⓑ{I}V & J = LRef (i+1).
-/2 width=3 by fsup_inv_atom1_aux/ qed-.
-
-fact fsup_inv_bind1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
-                         ∀b,J,W,U. T1 = ⓑ{b,J}W.U →
-                         (L2 = L1 ∧ T2 = W) ∨
-                         (L2 = L1.ⓑ{J}W ∧ T2 = U).
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #I #L #V #b #J #W #U #H destruct
-| #I #L #K #V #T #i #_ #b #J #W #U #H destruct
-| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
-| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
-| #I #L #V #T #b #J #W #U #H destruct
-| #I #L #V #T #b #J #W #U #H destruct
-]
-qed-.
-
-lemma fsup_inv_bind1: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⊃ ⦃L2, T2⦄ →
-                      (L2 = L1 ∧ T2 = W) ∨
-                      (L2 = L1.ⓑ{J}W ∧ T2 = U).
-/2 width=4 by fsup_inv_bind1_aux/ qed-.
-
-fact fsup_inv_flat1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
-                         ∀J,W,U. T1 = ⓕ{J}W.U →
-                         L2 = L1 ∧ (T2 = W ∨ T2 = U).
-#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
-[ #I #L #K #J #W #U #H destruct
-| #I #L #K #V #T #i #_ #J #W #U #H destruct
-| #a #I #L #V #T #J #W #U #H destruct
-| #a #I #L #V #T #J #W #U #H destruct
-| #I #L #V #T #J #W #U #H destruct /3 width=1/
-| #I #L #V #T #J #W #U #H destruct /3 width=1/
-]
-qed-.
-
-lemma fsup_inv_flat1: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⊃ ⦃L2, T2⦄ →
-                      L2 = L1 ∧ (T2 = W ∨ T2 = U).
-/2 width=4 by fsup_inv_flat1_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/fsups.etc
deleted file mode 100644 (file)
index 36abe12..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-(* Advanced inversion lemmas on plus-iterated supclosure ********************)
-
-lamma fsupp_inv_bind1_fsups: ∀b,J,G1,G2,L1,L2,W,U,T2. ⦃G1, L1, ⓑ{b,J}W.U⦄ ⊃+ ⦃G2, L2, T2⦄ →
-                             ⦃G1, L1, W⦄ ⊃* ⦃G2, L2, T2⦄ ∨ ⦃L1.ⓑ{J}W, U⦄ ⊃* ⦃G2, L2, T2⦄.
-#b #J #G1 #G2 #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -G2 -L2 -T2
-[ #G2 #L2 #T2 #H
-  elim (fsup_inv_bind1 … H) -H * #H1 #H2 #H3 destruct /2 width=1/
-| #G #G2 #L #L2 #T #T2 #_ #HT2 * /3 width=4/
-]
-qad-.
-
-lamma fsupp_inv_flat1_fsups: ∀J,G1,G2,L1,L2,W,U,T2. ⦃G1, L1, ⓕ{J}W.U⦄ ⊃+ ⦃G2, L2, T2⦄ →
-                             ⦃G1, L1, W⦄ ⊃* ⦃G2, L2, T2⦄ ∨ ⦃G1, L1, U⦄ ⊃* ⦃G2, L2, T2⦄.
-#J #G1 #G2 #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -G2 -L2 -T2
-[ #G2 #L2 #T2 #H
-  elim (fsup_inv_flat1 … H) -H #H1 * #H2 destruct /2 width=1/
-| #G #G2 #L #L2 #T #T2 #_ #HT2 * /3 width=4/
-]
-qad-.
-
-lamma fsupp_fsups: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄.
-/2 width=1 by tri_inj/ qed.
-
-lamma fsups_lref: ∀I,G,K,V,i,L. ⇩[0, i] L ≡ K.ⓑ{I}V → ⦃G, L, #i⦄ ⊃* ⦃G, K, V⦄.
-/3 width=5 by _/ qed.
-
-lamma fsups_lref_S_lt: ∀I,G1,G2,L,K,V,T,i.
-                       0 < i → ⦃G1, L, #(i-1)⦄ ⊃* ⦃G2, K, T⦄ → ⦃G1, L.ⓑ{I}V, #i⦄ ⊃+ ⦃G2, K, T⦄.
-/3 width=7 by _/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsup.etc
deleted file mode 100644 (file)
index 75ea3e5..0000000
+++ /dev/null
@@ -1,62 +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/fsup.ma".
-include "basic_2/substitution/ldrop_ldrop.ma".
-
-(* LOCAL ENVIRONMENT SLICING ************************************************)
-
-(* Inversion lemmas on supclosure *******************************************)
-
-lemma fsup_inv_atom1_ldrop: ∀K,V,L,I. ⦃L, ⓪{I}⦄ ⊃ ⦃K, V⦄ →
-                            ∃∃J,i. ⇩[0, i] L ≡ K.ⓑ{J}V & I = LRef i.
-#K #V #L @(f_ind … length … L) -L #n #IH #L #Hn #I #H
-elim (fsup_inv_atom1 … H) -H *
-[ #J #L0 #V0 #H1 #H2 #H3 #H4 destruct /2 width=4/
-| #J #L0 #V0 #i #HLK #H1 #H2 destruct
-  elim (IH … HLK) -IH -HLK [2: normalize // ] #I #j #HLK #H destruct /3 width=4/
-]
-qed-.
-
-(* Advanced eliminators on supclosure ***************************************)
-
-lemma fsup_ind_ldrop: ∀R:bi_relation lenv term.
-                      (∀I,L,K,V,i. ⇩[0, i] L ≡ K.ⓑ{I}V → R L (#i) K V) →
-                      (∀a,I,L,V,T. R L (ⓑ{a,I}V.T) L V) →
-                      (∀a,I,L,V,T. R L (ⓑ{a,I}V.T) (L.ⓑ{I}V) T) →
-                      (∀I,L,V,T. R L (ⓕ{I}V.T) L V) →
-                      (∀I,L,V,T. R L (ⓕ{I}V.T) L T) →
-                      ∀L1,T1,L2,T2. ⦃L1,T1⦄⊃⦃L2,T2⦄ → R L1 T1 L2 T2.
-#R #H1 #H2 #H3 #H4 #H5 #L1 #T1 #L2 #T2 #H elim H -L1 -T1 -L2 -T2 //
-[ /3 width=2/
-| #I #L #K #V #T #i #H #H1LK
-  elim (fsup_inv_atom1_ldrop … H) -H #J #j #H2LK #H destruct /3 width=2/
-]
-qed-.
-
-(* Advanced inversion lemmas on supclosure **********************************)
-
-lemma fsup_inv_ldrop: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
-                      ∀J,W,j. ⇩[0, j] L1 ≡ L2.ⓑ{J}W → T1 = #j ∧ T2 = W.
-#L1 #L2 #T1 #T2 #H @(fsup_ind_ldrop … H) -L1 -L2 -T1 -T2
-[ #I #L #K #V #i #HLKV #J #W #j #HLKW
-  elim (ldrop_conf_div … HLKV … HLKW) -L /2 width=1/
-| #a
-| #a
-]
-#I #L #V #T #J #W #j #H
-lapply (ldrop_pair2_fwd_fw … H W) -H #H
-[2: lapply (transitive_lt (♯{L,W}) … H) /2 width=1/ -H #H ]
-elim (lt_refl_false … H)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/fsup/ldrop_fsups.etc
deleted file mode 100644 (file)
index dc4d7e9..0000000
+++ /dev/null
@@ -1,30 +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/grammar/fsups.ma".
-include "basic_2/substitution/ldrop_fsup.ma".
-
-(* LOCAL ENVIRONMENT SLICING ************************************************)
-
-(* Inversion lemmas on plus-iterated supclosure  ****************************)
-
-lemma fsupp_inv_atom1_fsups: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⊃+ ⦃L2, T2⦄ →
-                             ∃∃I,K,V,i. ⇩[0, i] L1 ≡ K.ⓑ{I}V &
-                             ⦃K, V⦄ ⊃* ⦃L2, T2⦄ & J = LRef i.
-#J #L1 #L2 #T2 #H @(fsupp_ind … H) -L2 -T2
-[ #L2 #T2 #H
-  elim (fsup_inv_atom1_ldrop … H) -H * #i #HL12 #H destruct /2 width=7/
-| #L #T #L2 #T2 #_ #HT2 * #I #K #V #i #HLK #HVT #H destruct /3 width=8/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_aaa.etc
deleted file mode 100644 (file)
index 0ad8732..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/multiple/lifts_lifts.ma".
-include "basic_2/multiple/drops_drops.ma".
-include "basic_2/static/aaa_lifts.ma".
-include "basic_2/static/aaa_aaa.ma".
-include "basic_2/computation/lsubc_drops.ma".
-
-(* GENERIC COMPUTATION PROPERTIES *******************************************)
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: sc3_arity_csubc *)
-theorem acr_aaa_csubc: ∀RR,RS,RP.
-                       gcp RR RS RP → gcr RR RS RP RP →
-                       ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
-                       ∀L2. G ⊢ L2 ⫃[RP] L1 → ⦃G, L2, T⦄ ϵ[RP] 〚A〛.
-#RR #RS #RP #H1RP #H2RP #G #L1 #T #A #H elim H -G -L1 -T -A
-[ #G #L1 #k #L2 #HL21
-  lapply (acr_gcr … H1RP H2RP (⓪)) #HAtom
-  lapply (s4 … HAtom G L2 (◊)) /2 width=1 by/
-| #I #G #L1 #K1 #V1 #B #i #HLK1 #HKV1B #IHB #L2 #HL21
-  lapply (acr_gcr … H1RP H2RP B) #HB
-  elim (lsubc_drop_O1_trans … HL21 … HLK1) -L1 #X #HLK2 #H
-  elim (lsubc_inv_pair2 … H) -H *
-  [ #K2 #HK21 #H destruct -HKV1B
-    lapply (drop_fwd_drop2 … HLK2) #H
-    elim (lift_total V1 0 (i +1)) #V #HV1
-    lapply (s5 … HB ? G ? ? (◊) … HV1 HLK2) /3 width=7 by s0/
-  | #K2 #V2 #A2 #HVA2 #H1V1A2 #H2V1A2 #_ #H1 #H2 destruct -IHB
-    lapply (aaa_mono … H2V1A2 … HKV1B) #H destruct -H2V1A2 -HKV1B
-    lapply (drop_fwd_drop2 … HLK2) #H
-    elim (lift_total V1 0 (i +1)) #V3 #HV13
-    elim (lift_total V2 0 (i +1)) #V #HV2
-    lapply (s5 … HB ? G ? ? (◊) … (ⓝV3.V) … HLK2) /2 width=1 by lift_flat/ -HLK2 
-    lapply (s7 … HB G L2 (◊)) /3 width=7 by s0/
-  ]
-| #a #G #L1 #V #T #B #A #_ #_ #IHB #IHA #L2 #HL21
-  lapply (acr_gcr … H1RP H2RP A) #HA
-  lapply (acr_gcr … H1RP H2RP B) #HB
-  lapply (s1 … HB) -HB #HB
-  lapply (s6 … HA G L2 (◊) (◊)) /4 width=1 by lsubc_pair/
-| #a #G #L1 #W #T #B #A #HLWB #_ #IHB #IHA #L2 #HL21
-  @(acr_abst  … H1RP H2RP) [ /2 width=5 by/ ]
-  #L3 #V3 #W3 #T3 #des3 #HL32 #HW03 #HT03 #H1B #H2B
-  @(gcr_lifts … L2.ⓓⓝW.V3,T … HL32)
-  elim (drops_lsubc_trans … H1RP H2RP … HL32 … HL21) -L2 #L2 #HL32 #HL21
-  lapply (aaa_lifts … L2 W3 … des3 … HLWB) -HLWB /2 width=4 by drops_trans, lifts_trans/ #HLW2B
-  @(s0 
-  
-  @(IHA (L2. ⓛW3) … (des3 + 1)) -IHA
-  /3 width=5 by lsubc_beta, drops_trans, drops_skip, lifts_trans/
-| #G #L #V #T #B #A #_ #_ #IHB #IHA #L0 #des #HL0 #X #H #L2 #HL20
-  elim (lifts_inv_flat1 … H) -H #V0 #T0 #HV0 #HT0 #H destruct
-  /3 width=10 by drops_nil, lifts_nil/
-| #G #L #V #T #A #_ #_ #IH1A #IH2A #L0 #des #HL0 #X #H #L2 #HL20
-  elim (lifts_inv_flat1 … H) -H #V0 #T0 #HV0 #HT0 #H destruct
-  lapply (acr_gcr … H1RP H2RP A) #HA
-  lapply (s7 … HA G L2 (◊)) /3 width=5 by/
-]
-qed.
-
-(* Basic_1: was: sc3_arity *)
-lemma acr_aaa: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-               ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦃G, L, T⦄ ϵ[RP] 〚A〛.
-/2 width=8 by drops_nil, lifts_nil, acr_aaa_csubc_lifts/ qed.
-
-lemma gcr_aaa: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-               ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → RP G L T.
-#RR #RS #RP #H1RP #H2RP #G #L #T #A #HT
-lapply (acr_gcr … H1RP H2RP A) #HA
-@(s1 … HA) /2 width=4 by acr_aaa/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_cr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/gcp/gcp_cr.etc
deleted file mode 100644 (file)
index d8d3bbc..0000000
+++ /dev/null
@@ -1,177 +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/ineint_5.ma".
-include "basic_2/grammar/aarity.ma".
-include "basic_2/multiple/mr2_mr2.ma".
-include "basic_2/multiple/lifts_lift_vector.ma".
-include "basic_2/multiple/drops_drop.ma".
-include "basic_2/computation/gcp.ma".
-
-(* GENERIC COMPUTATION PROPERTIES *******************************************)
-
-definition S0 ≝ λC:candidate. ∀G,L2,L1,T1,d,e.
-                C G L1 T1 → ∀T2. ⇩[Ⓕ, d, e] L2 ≡ L1 → ⇧[d, e] T1 ≡ T2 → C G L2 T2.
-
-definition S0s ≝ λC:candidate.
-                 ∀G,L1,L2,des. ⇩*[Ⓕ, des] L2 ≡ L1 →
-                 ∀T1,T2. ⇧*[des] T1 ≡ T2 → C G L1 T1 → C G L2 T2.
-
-(* Note: this is Girard's CR1 *)
-definition S1 ≝ λRP,C:candidate.
-                ∀G,L,T. C G L T → RP G L T.
-
-(* Note: this is Tait's iii, or Girard's CR4 *)
-definition S2 ≝ λRR:relation4 genv lenv term term. λRS:relation term. λRP,C:candidate.
-                ∀G,L,Vs. all … (RP G L) Vs →
-                ∀T. 𝐒⦃T⦄ → NF … (RR G L) RS T → C G L (ⒶVs.T).
-
-(* Note: this generalizes Tait's ii *)
-definition S3 ≝ λC:candidate.
-                ∀a,G,L,Vs,V,T,W.
-                C G L (ⒶVs.ⓓ{a}ⓝW.V.T) → C G L (ⒶVs.ⓐV.ⓛ{a}W.T).
-
-definition S4 ≝ λRP,C:candidate.
-                ∀G,L,Vs. all … (RP G L) Vs → ∀k. C G L (ⒶVs.⋆k).
-
-definition S5 ≝ λC:candidate. ∀I,G,L,K,Vs,V1,V2,i.
-                ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[0, i+1] V1 ≡ V2 →
-                C G L (ⒶVs.V2) → C G L (ⒶVs.#i).
-
-definition S6 ≝ λRP,C:candidate.
-                ∀G,L,V1s,V2s. ⇧[0, 1] V1s ≡ V2s →
-                ∀a,V,T. C G (L.ⓓV) (ⒶV2s.T) → RP G L V → C G L (ⒶV1s.ⓓ{a}V.T).
-
-definition S7 ≝ λC:candidate.
-                ∀G,L,Vs,T,W. C G L (ⒶVs.T) → C G L (ⒶVs.W) → C G L (ⒶVs.ⓝW.T).
-
-(* requirements for the generic reducibility candidate *)
-record gcr (RR:relation4 genv lenv term term) (RS:relation term) (RP,C:candidate) : Prop ≝
-{ (* s0: S0 C; *)
-  s1: S1 RP C;
-  s2: S2 RR RS RP C;
-  s3: S3 C;
-  s4: S4 RP C;
-  s5: S5 C;
-  s6: S6 RP C;
-  s7: S7 C
-}.
-
-(* the functional construction for candidates *)
-definition cfun: candidate → candidate → candidate ≝
-                 λC1,C2,G,K,T. ∀V. C1 G K V → C2 G K (ⓐV.T).
-
-(* the reducibility candidate associated to an atomic arity *)
-let rec acr (RP:candidate) (A:aarity) on A: candidate ≝
-match A with
-[ AAtom     ⇒ RP
-| APair B A ⇒ cfun (acr RP B) (acr RP A)
-].
-
-interpretation
-   "candidate of reducibility of an atomic arity (abstract)"
-   'InEInt RP G L T A = (acr RP A G L T).
-
-(* Basic properties *********************************************************)
-(*
-(* Basic_1: was: sc3_lift1 *)
-lemma gcr_lifts: ∀C. S0 C → S0s C.
-#C #HC #G #L1 #L2 #des #H elim H -L1 -L2 -des
-[ #L #T1 #T2 #H #HT1 <(lifts_inv_nil … H) -H //
-| #L1 #L #L2 #des #d #e #_ #HL2 #IHL #T2 #T1 #H #HLT2
-  elim (lifts_inv_cons … H) -H /3 width=10 by/
-]
-qed.
-*)
-axiom rp_lift: ∀RP. S0 RP.
-
-
-axiom rp_lifts: ∀RR,RS,RP. gcr RR RS RP RP →
-                ∀des,G,L0,L,V,V0. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] V ≡ V0 →
-                RP G L V → RP G L0 V0.
-(*
-#RR #RS #RP #HRP #des #G #L0 #L #V #V0 #HL0 #HV0 #HV
-@gcr_lifts /width=7 by/
-@(s0 … HRP)
-qed.
-*)
-(* Basic_1: was only: sns3_lifts1 *)
-axiom rp_liftsv_all: ∀RR,RS,RP. gcr RR RS RP RP →
-                     ∀des,G,L0,L,Vs,V0s. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] Vs ≡ V0s →
-                     all … (RP G L) Vs → all … (RP G L0) V0s.
-(*
-#RR #RS #RP #HRP #des #G #L0 #L #Vs #V0s #HL0 #H elim H -Vs -V0s normalize //
-#T1s #T2s #T1 #T2 #HT12 #_ #IHT2s * /3 width=7 by rp_lifts, conj/
-qed.
-*)
-
-lemma gcr_lift: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-                ∀A. S0 (acr RP A).
-#RR #RS #RP #H1RP #H2RP #A elim A -A /2 width=7 by rp_lift/
-#B #A #IHB #IHA #G #L2 #L1 #T1 #d #e #IH #T2 #HL21 #HT12 #V #HB
-@(IHA … HL21) [3: @(lift_flat … HT12) |1: skip |  
-
-(* Basic_1: was:
-   sc3_sn3 sc3_abst sc3_appl sc3_abbr sc3_bind sc3_cast sc3_lift
-*)
-lemma acr_gcr: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-               ∀A. gcr RR RS RP (acr RP A).
-#RR #RS #RP #H1RP #H2RP #A elim A -A //
-#B #A #IHB #IHA @mk_gcr
-[ #G #L #T #H
-  elim (cp1 … H1RP G L) #k #HK
-  lapply (H (⋆k) ?) -H
-  [ lapply (s2 … IHB G L (◊) … HK) //
-  | #H @(cp2 … H1RP … k) @(s1 … IHA) //
-  ]
-| #G #L #Vs #HVs #T #H1T #H2T #V #HB
-  lapply (s1 … IHB … HB) #HV
-  @(s2 … IHA … (V @ Vs))
-  /3 width=14 by rp_liftsv_all, gcp_lifts, cp0, lifts_simple_dx, conj/
-| #a #G #L #Vs #U #T #W #HA #V #HB
-  @(s3 … IHA … (V @ Vs)) /2 width=1 by/
-| #G #L #Vs #HVs #k #V #HB
-  lapply (s1 … IHB … HB) #HV
-  @(s4 … IHA … (V @ Vs)) /3 width=7 by rp_liftsv_all, conj/
-| #I #G #L #K #Vs #V1 #V2 #i #HLK #HV12 #HA #V #HB
-  @(s5 … IHA … (V @ Vs) … HLK HV12) /2 width=1 by/
-| #G #L #V1s #V2s #HV12s #a #W #T #HA #HW #V1 #HB
-  elim (lift_total V1 0 1) #V2 #HV12
-  @(s6 … IHA … (V1 @ V1s) (V2 @ V2s)) /2 width=1 by liftv_cons/
-  @HA @(gcr_lift … H1RP H2RP … HB … HV12) /2 width=2 by drop_drop/
-| #G #L #Vs #T #W #HA #HW #V #HB
-  @(s7 … IHA … (V @ Vs)) /2 width=1 by/
-]
-qed.
-
-lemma acr_abst: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
-                ∀a,G,L,W,T,B,A. ⦃G, L, W⦄ ϵ[RP] 〚B〛 → (
-                   ∀V. ⦃G, L, V⦄ ϵ[RP] 〚B〛 → ⦃G, L.ⓓⓝW.V, T⦄ ϵ[RP] 〚A〛
-                ) →
-                ⦃G, L, ⓛ{a}W.T⦄ ϵ[RP] 〚②B.A〛.
-#RR #RS #RP #H1RP #H2RP #a #G #L #W #T #B #A #HW #HA #L0 #V0 #X #des #HL0 #H #HB
-lapply (acr_gcr … H1RP H2RP A) #HCA
-lapply (acr_gcr … H1RP H2RP B) #HCB
-elim (lifts_inv_bind1 … H) -H #W0 #T0 #HW0 #HT0 #H destruct
-lapply (gcr_lifts … HL0 … HW0 HW) -HW [ @(s0 … HCB) ] #HW0
-lapply (s3 … HCA … a G L0 (◊)) #H @H -H
-lapply (s6 … HCA G L0 (◊) (◊) ?) // #H @H -H
-[ @(HA … HL0) //
-| lapply (s1 … HCB) -HCB #HCB
-  lapply (s7 … H2RP G L0 (◊)) /3 width=1 by/
-]
-qed.
-
-(* Basic_1: removed theorems 2: sc3_arity_gen sc3_repl *)
-(* Basic_1: removed local theorems 1: sc3_sn3_abst *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas.etc
deleted file mode 100644 (file)
index 8cfaa34..0000000
+++ /dev/null
@@ -1,57 +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 "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : : * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'NativeTypeStarAlt $h $L $T1 $T2 }.
-
-include "basic_2/dynamic/nta.ma".
-
-(* HIGHER ORDER NATIVE TYPE ASSIGNMENT ON TERMS *****************************)
-
-definition ntas: sh → lenv → relation term ≝
-                 λh,L. star … (nta h L).
-
-interpretation "higher order native type assignment (term)"
-   'NativeTypeStar h L T U = (ntas h L T U).
-
-(* Basic eliminators ********************************************************)
-(*
-lemma cprs_ind: ∀L,T1. ∀R:predicate term. R T1 →
-                (∀T,T2. L ⊢ T1 ➡* T → L ⊢ T ➡ T2 → R T → R T2) →
-                ∀T2. L ⊢ T1 ➡* T2 → R T2.
-#L #T1 #R #HT1 #IHT1 #T2 #HT12
-@(TC_star_ind … HT1 IHT1 … HT12) //
-qed-.
-*)
-axiom ntas_ind_dx: ∀h,L,T2. ∀R:predicate term. R T2 →
-                   (∀T1,T. ⦃h, L⦄ ⊢ T1 : T → ⦃h, L⦄ ⊢ T :* T2 → R T → R T1) →
-                   ∀T1. ⦃h, L⦄ ⊢ T1 :* T2 → R T1.
-(*
-#h #L #T2 #R #HT2 #IHT2 #T1 #HT12
-@(star_ind_dx … HT2 IHT2 … HT12) //
-qed-.
-*)
-(* Basic properties *********************************************************)
-
-lemma ntas_refl: ∀h,L,T. ⦃h, L⦄ ⊢ T :* T.
-// qed.
-
-lemma ntas_strap1: ∀h,L,T1,T,T2.
-                   ⦃h, L⦄ ⊢ T1 :* T → ⦃h, L⦄  ⊢ T : T2 → ⦃h, L⦄  ⊢ T1 :* T2.
-/2 width=3/ qed.
-
-lemma ntas_strap2: ∀h,L,T1,T,T2.
-                   ⦃h, L⦄  ⊢ T1 : T → ⦃h, L⦄ ⊢ T :* T2 → ⦃h, L⦄ ⊢ T1 :* T2.
-/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/hod/ntas_lift.etc
deleted file mode 100644 (file)
index 1adced7..0000000
+++ /dev/null
@@ -1,71 +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/dynamic/nta_lift.ma".
-include "basic_2/hod/ntas.ma".
-
-(* HIGHER ORDER NATIVE TYPE ASSIGNMENT ON TERMS *****************************)
-
-(* Advanced properties on native type assignment for terms ******************)
-
-lemma nta_pure_ntas: ∀h,L,U,W,Y. ⦃h, L⦄ ⊢ U :* ⓛW.Y → ∀T. ⦃h, L⦄ ⊢ T : U →
-                     ∀V. ⦃h, L⦄ ⊢ V : W →  ⦃h, L⦄ ⊢ ⓐV.T : ⓐV.U.
-#h #L #U #W #Y #H @(ntas_ind_dx … H) -U /2 width=1/ /3 width=2/
-qed.
-
-axiom pippo: ∀h,L,T,W,Y. ⦃h, L⦄ ⊢ T :* ⓛW.Y → ∀U. ⦃h, L⦄ ⊢ T : U →
-             ∃Z. ⦃h, L⦄ ⊢ U :* ⓛW.Z.
-(* REQUIRES SUBJECT CONVERSION
-#h #L #T #W #Y #H @(ntas_ind_dx … H) -T
-[ #U #HYU
-  elim (nta_fwd_correct … HYU) #U0 #HU0 
-  elim (nta_inv_bind1 … HYU) #W0 #Y0 #HW0 #HY0 #HY0U
-*)
-
-(* Advanced inversion lemmas on native type assignment for terms ************)
-
-fact nta_inv_pure1_aux: ∀h,L,Z,U. ⦃h, L⦄ ⊢ Z : U → ∀X,Y. Z = ⓐY.X →
-                        ∃∃W,V,T. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V &
-                                 L ⊢ ⓐY.V ⬌* U & ⦃h, L⦄ ⊢ V :* ⓛW.T.
-#h #L #Z #U #H elim H -L -Z -U
-[ #L #k #X #Y #H destruct
-| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W #Z #U #HVW #HZU #_ #_ #X #Y #H destruct /2 width=7/
-| #L #V #W #Z #U #HZU #_ #_ #IHUW #X #Y #H destruct
-  elim (IHUW U Y ?) -IHUW // /3 width=9/
-| #L #Z #U #_ #_ #X #Y #H destruct
-| #L #Z #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
-  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #W #V #T #HYW #HXV #HU1 #HVT
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=7/
-]
-qed.
-
-(* Basic_1: was only: ty3_gen_appl *)
-lemma nta_inv_pure1: ∀h,L,Y,X,U. ⦃h, L⦄ ⊢ ⓐY.X : U →
-                     ∃∃W,V,T. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V &
-                              L ⊢ ⓐY.V ⬌* U & ⦃h, L⦄ ⊢ V :* ⓛW.T.
-/2 width=3/ qed-.
-
-axiom nta_inv_appl1: ∀h,L,Z,Y,X,U. ⦃h, L⦄ ⊢ ⓐZ.ⓛY.X : U →
-                     ∃∃W. ⦃h, L⦄ ⊢ Z : Y & ⦃h, L⦄ ⊢ ⓛY.X : ⓛY.W &
-                     L ⊢ ⓐZ.ⓛY.W ⬌* U.
-(* REQUIRES SUBJECT REDUCTION
-#h #L #Z #Y #X #U #H
-elim (nta_inv_pure1 … H) -H #W #V #T #HZW #HXV #HVU #HVT
-elim (nta_inv_bind1 … HXV) -HXV #Y0 #X0 #HY0 #HX0 #HX0V
-lapply (cpcs_trans … (ⓐZ.ⓛY.X0) … HVU) -HVU /2 width=1/ -HX0V #HX0U
-@(ex3_1_intro … HX0U) /2 width=2/
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/coeq_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/coeq_4.etc
deleted file mode 100644 (file)
index 8abd1ee..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 d , break term 46 e ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'CoEq $d $e $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq.etc
deleted file mode 100644 (file)
index 5338c2a..0000000
+++ /dev/null
@@ -1,165 +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_lt.ma".
-include "basic_2/notation/relations/coeq_4.ma".
-include "basic_2/grammar/lenv_length.ma".
-
-(* COEQUIVALENCE FOR LOCAL ENVIRONMENTS *************************************)
-
-inductive lcoeq: relation4 ynat ynat lenv lenv ≝
-| lcoeq_atom: ∀d,e. lcoeq d e (⋆) (⋆)
-| lcoeq_zero: ∀I,L1,L2,V.
-              lcoeq 0 0 L1 L2 → lcoeq 0 0 (L1.ⓑ{I}V) (L2.ⓑ{I}V)
-| lcoeq_pair: ∀I1,I2,L1,L2,V1,V2,e. lcoeq 0 e L1 L2 →
-              lcoeq 0 (⫯e) (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2)
-| lcoeq_succ: ∀I,L1,L2,V,d,e.
-              lcoeq d e L1 L2 → lcoeq (⫯d) e (L1.ⓑ{I}V) (L2.ⓑ{I}V)
-.
-
-interpretation
-  "coequivalence (local environment)"
-  'CoEq d e L1 L2 = (lcoeq d e L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lcoeq_pair_lt: ∀I1,I2,L1,L2,V1,V2,e. L1 ≅[0, ⫰e] L2 → 0 < e →
-                     L1.ⓑ{I1}V1 ≅[0, e] L2.ⓑ{I2}V2.
-#I1 #I2 #L1 #L2 #V1 #V2 #e #HL12 #He <(ylt_inv_O1 … He) /2 width=1 by lcoeq_pair/
-qed.
-
-lemma lcoeq_succ_lt: ∀I,L1,L2,V,d,e. L1 ≅[⫰d, e] L2 → 0 < d →
-                     L1.ⓑ{I}V ≅[d, e] L2. ⓑ{I}V.
-#I #L1 #L2 #V #d #e #HL12 #Hd <(ylt_inv_O1 … Hd) /2 width=1 by lcoeq_succ/
-qed.
-
-lemma lcoeq_pair_O_Y: ∀L1,L2. L1 ≅[0, ∞] L2 →
-                      ∀I1,I2,V1,V2. L1.ⓑ{I1}V1 ≅[0,∞] L2.ⓑ{I2}V2.
-#L1 #L2 #HL12 #I1 #I2 #V1 #V2 lapply (lcoeq_pair I1 I2 … V1 V2 … HL12) -HL12 //
-qed.
-
-lemma lcoeq_refl: ∀L,d,e. L ≅[d, e] L.
-#L elim L -L //
-#L #I #V #IHL #d elim (ynat_cases … d) [| * #x ]
-#Hd destruct /2 width=1 by lcoeq_succ/
-#e elim (ynat_cases … e) [| * #x ]
-#He destruct /2 width=1 by lcoeq_zero, lcoeq_pair/
-qed.
-
-lemma lcoeq_O_Y: ∀L1,L2. |L1| = |L2| → L1 ≅[0, ∞] L2.
-#L1 elim L1 -L1 [| #L1 #I1 #V1 #IHL1 ]
-* [2,4: #L2 #I2 #V1 ] normalize /3 width=2 by lcoeq_pair_O_Y/
-<plus_n_Sm #H destruct
-qed.
-
-lemma lcoeq_sym: ∀d,e. symmetric … (lcoeq d e).
-#d #e #L1 #L2 #H elim H -L1 -L2
-/2 width=1 by lcoeq_zero, lcoeq_pair, lcoeq_succ/
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lcoeq_inv_atom1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 → L1 = ⋆ → L2 = ⋆.
-#L1 #L2 #d #e * -L1 -L2 -d -e //
-[ #I #L1 #L2 #V #_ #H destruct
-| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #H destruct
-| #I #L1 #L2 #V #d #e #_ #H destruct
-]
-qed-.
-
-lemma lcoeq_inv_atom1: ∀L2,d,e. ⋆ ≅[d, e] L2 → L2 = ⋆.
-/2 width=5 by lcoeq_inv_atom1_aux/ qed-.
-
-fact lcoeq_inv_zero1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
-                          ∀J,K1,W. L1 = K1.ⓑ{J}W → d = 0 → e = 0 →
-                          ∃∃K2. K1 ≅[0, 0] K2 & L2 = K2.ⓑ{J}W.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #J #K1 #W #H destruct
-| #I #L1 #L2 #V #HL12 #J #K1 #W #H destruct /2 width=3 by ex2_intro/
-| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #J #K1 #W #_ #_ #H elim (ysucc_inv_O_dx … H)
-| #I #L1 #L2 #V #d #e #_ #J #K1 #W #_ #H elim (ysucc_inv_O_dx … H)
-]
-qed-.
-
-lemma lcoeq_inv_zero1: ∀I,K1,L2,V. K1.ⓑ{I}V ≅[0, 0] L2 →
-                       ∃∃K2. K1 ≅[0, 0] K2 & L2 = K2.ⓑ{I}V.
-/2 width=7 by lcoeq_inv_zero1_aux/ qed-.
-
-fact lcoeq_inv_pair1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
-                          ∀J1,K1,W1. L1 = K1.ⓑ{J1}W1 → d = 0 → 0 < e →
-                          ∃∃J2,K2,W2. K1 ≅[0, ⫰e] K2 & L2 = K2.ⓑ{J2}W2.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #J1 #K1 #W1 #H destruct
-| #I #L1 #L2 #V #_ #J1 #K1 #W1 #_ #_ #H elim (ylt_yle_false … H) //
-| #I1 #I2 #L1 #L2 #V1 #V2 #e #HL12 #J1 #K1 #W1 #H #_ #_ destruct
-  /2 width=5 by ex2_3_intro/
-| #I #L1 #L2 #V #d #e #_ #J1 #K1 #W1 #_ #H elim (ysucc_inv_O_dx … H)
-]
-qed-.
-
-lemma lcoeq_inv_pair1: ∀I1,K1,L2,V1,e. K1.ⓑ{I1}V1 ≅[0, e] L2 → 0 < e →
-                       ∃∃I2,K2,V2. K1 ≅[0, ⫰e] K2 & L2 = K2.ⓑ{I2}V2.
-/2 width=7 by lcoeq_inv_pair1_aux/ qed-.
-
-fact lcoeq_inv_succ1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
-                          ∀J,K1,W. L1 = K1.ⓑ{J}W → 0 < d →
-                          ∃∃K2. K1 ≅[⫰d, e] K2 & L2 = K2.ⓑ{J}W.
-#L1 #L2 #d #e * -L1 -L2 -d -e
-[ #d #e #J #K1 #W #H destruct
-| #I #L1 #L2 #V #_ #J #K1 #W #_ #H elim (ylt_yle_false … H) //
-| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #J #K1 #W #_ #H elim (ylt_yle_false … H) //
-| #I #L1 #L2 #V #d #e #HL12 #J #K1 #W #H destruct /2 width=3 by ex2_intro/
-]
-qed-.
-
-lemma lcoeq_inv_succ1: ∀I,K1,L2,V,d,e. K1.ⓑ{I}V ≅[d, e] L2 → 0 < d →
-                       ∃∃K2. K1 ≅[⫰d, e] K2 & L2 = K2.ⓑ{I}V.
-/2 width=3 by lcoeq_inv_succ1_aux/ qed-.
-
-lemma lcoeq_inv_atom2: ∀L1,d,e. L1 ≅[d, e] ⋆ → L1 = ⋆.
-/3 width=3 by lcoeq_inv_atom1, lcoeq_sym/ qed-.
-
-lemma lcoeq_inv_zero2: ∀I,K2,L1,V. L1 ≅[0, 0] K2.ⓑ{I}V →
-                       ∃∃K1. K1 ≅[0, 0] K2 & L1 = K1.ⓑ{I}V.
-#I #K2 #L1 #V #H elim (lcoeq_inv_zero1 … (lcoeq_sym … H)) -H
-/3 width=3 by lcoeq_sym, ex2_intro/
-qed-.
-
-lemma lcoeq_inv_pair2: ∀I2,K2,L1,V2,e. L1 ≅[0, e] K2.ⓑ{I2}V2 → 0 < e →
-                       ∃∃I1,K1,V1. K1 ≅[0, ⫰e] K2 & L1 = K1.ⓑ{I1}V1.
-#I2 #K2 #L1 #V2 #e #H #He elim (lcoeq_inv_pair1 … (lcoeq_sym … H)) -H
-/3 width=5 by lcoeq_sym, ex2_3_intro/
-qed-.
-
-lemma lcoeq_inv_succ2: ∀I,K2,L1,V,d,e. L1 ≅[d, e] K2.ⓑ{I}V → 0 < d →
-                       ∃∃K1. K1 ≅[⫰d, e] K2 & L1 = K1.ⓑ{I}V.
-#I #K2 #L1 #V #d #e #H #Hd elim (lcoeq_inv_succ1 … (lcoeq_sym … H)) -H
-/3 width=3 by lcoeq_sym, ex2_intro/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lcoeq_fwd_length: ∀L1,L2,d,e. L1 ≅[d, e] L2 → |L2| ≤ |L1|.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize /2 width=1 by le_S_S/
-qed-.
-
-(* Advanced inversionn lemmas ***********************************************)
-
-fact lcoeq_inv_O2_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 → e = 0 → L1 = L2.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e /3 width=1 by eq_f3/
-#I1 #I2 #L1 #L2 #V1 #V2 #e #_ #_ #H elim (ysucc_inv_O_dx … H)
-qed-.
-
-lemma lcoeq_inv_O2: ∀L1,L2,d. L1 ≅[d, 0] L2 → L1 = L2.
-/2 width=4 by lcoeq_inv_O2_aux/ qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq_lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/lcoeq_lcoeq.etc
deleted file mode 100644 (file)
index 2977753..0000000
+++ /dev/null
@@ -1,29 +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/grammar/lcoeq.ma".
-
-(* COEQUIVALENCE FOR LOCAL ENVIRONMENTS *************************************)
-
-(* Main properties **********************************************************)
-
-theorem lcoeq_trans: ∀d,e. Transitive … (lcoeq d e).
-#d #e #L1 #L2 #H elim H -L1 -L2 -d -e //
-[ #I #L1 #L #V #HL1 #_ #X #H >(lcoeq_inv_O2 … HL1) -HL1 //
-| #I1 #I #L1 #L #V1 #V #e #_ #IHL1 #X #H elim (lcoeq_inv_pair1 … H) -H //
-  #I2 #L2 #V2 #HL2 #H destruct /3 width=1 by lcoeq_pair/
-| #I #L1 #L #V #d #e #_ #IHL1 #X #H elim (lcoeq_inv_succ1 … H) -H //
-  #L2 #HL2 #H destruct /3 width=1 by lcoeq_succ/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/ldrop_lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcoeq/ldrop_lcoeq.etc
deleted file mode 100644 (file)
index 4891949..0000000
+++ /dev/null
@@ -1,51 +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_minus.ma".
-include "basic_2/grammar/lcoeq.ma".
-include "basic_2/relocation/ldrop.ma".
-
-(* BASIC SLICING FOR LOCAL ENVIRONMENTS *************************************)
-
-(* Properties on coequivalence **********************************************)
-
-lemma lcoeq_ldrop_trans_lt: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
-                            ∀I,K2,W,s,i. ⇩[s, 0, i] L2 ≡ K2.ⓑ{I}W → i < d →
-                            ∃∃K1. K1 ≅[⫰(d-i), e] K2 & ⇩[s, 0, i] L1 ≡ K1.ⓑ{I}W.
-#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
-[ #d #e #J #K2 #W #s #i #H
-  elim (ldrop_inv_atom1 … H) -H #H destruct
-| #I #L1 #L2 #V #_ #_ #J #K2 #W #s #i #_ #H
-  elim (ylt_yle_false … H) //
-| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #_ #J #K2 #W #s #i #_ #H
-  elim (ylt_yle_false … H) //
-| #I #L1 #L2 #V #d #e #HL12 #IHL12 #J #K2 #W #s #i #H
-  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK1 [ -IHL12 | -HL12 ]
-  [ #_ destruct >ypred_succ
-    /2 width=3 by ldrop_pair, ex2_intro/
-  | lapply (ylt_inv_O1 i ?) /2 width=1 by ylt_inj/
-    #H <H -H #H lapply (ylt_inv_succ … H) -H
-    #Hie elim (IHL12 … HLK1) -IHL12 -HLK1 // -Hie
-    >yminus_succ <yminus_inj /3 width=3 by ldrop_drop_lt, ex2_intro/
-  ]
-]
-qed-.
-
-lemma lcoeq_ldrop_conf_lt: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
-                           ∀I,K1,W,s,i. ⇩[s, 0, i] L1 ≡ K1.ⓑ{I}W → i < d →
-                           ∃∃K2. K1 ≅[⫰(d-i), e] K2 & ⇩[s, 0, i] L2 ≡ K2.ⓑ{I}W.
-#L1 #L2 #d #e #HL12 #I #K1 #W #s #i #HLK1 #Hid
-elim (lcoeq_ldrop_trans_lt … (lcoeq_sym … HL12) … HLK1) // -L1 -Hid
-/3 width=3 by lcoeq_sym, ex2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs.etc
deleted file mode 100644 (file)
index d815739..0000000
+++ /dev/null
@@ -1,48 +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 "hvbox( L1 ⊢ ⬌* break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'CPConvStar $L1 $L2 }.
-
-include "basic_2/grammar/lenv_px_sn.ma".
-include "basic_2/equivalence/cpcs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *************)
-
-definition lcpcs: relation lenv ≝ lpx_sn … cpcs.
-
-interpretation "context-sensitive parallel equivalence (local environment)"
-   'CPConvStar L1 L2 = (lcpcs L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lcpcs_inv_atom1: ∀L2. ⋆ ⊢ ⬌* L2 → L2 = ⋆.
-/2 width=2 by lpx_sn_inv_atom1/ qed-.
-
-lemma lcpcs_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ⬌* L2 →
-                       ∃∃K2,V2. K1 ⊢ ⬌* K2 & K1 ⊢ V1 ⬌* V2 & L2 = K2. ⓑ{I} V2.
-/2 width=1 by lpx_sn_inv_pair1/ qed-.
-
-lemma lcpcs_inv_atom2: ∀L1. L1 ⊢ ⬌* ⋆ → L1 = ⋆.
-/2 width=2 by lpx_sn_inv_atom2/ qed-.
-
-lemma lcpcs_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ⬌* K2. ⓑ{I} V2 →
-                       ∃∃K1,V1. K1 ⊢ ⬌* K2 & K1 ⊢ V1 ⬌* V2 & L1 = K1. ⓑ{I} V1.
-/2 width=1 by lpx_sn_inv_pair2/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lcpcs_fwd_length: ∀L1,L2. L1 ⊢ ⬌* L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lcpcs/lcpcs_ltpr.etc
deleted file mode 100644 (file)
index ecc6be8..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/reducibility/ltpr.ma".
-include "basic_2/equivalence/lcpcs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *************)
-
-(* Properties on context-free parallel reduction for local environments *****)
-
-lemma ltpr_lcpcs: ∀L1,L2. L1 ➡ L2 → L1 ⊢ ⬌* L2.
-#L1 #L2 #H elim H -L1 -L2 // /4 width=1/
-qed.
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
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/lleq_alt/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/lleq_alt/lleq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/lleq_alt/lleq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/lleq_alt/lleq_fqus.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/lleq_alt/lleq_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/lleq_alt/lleq_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lleq_alt/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/llneq/lazynegatedeq_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lazynegatedeq_4.etc
deleted file mode 100644 (file)
index 6b0cb85..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 @{ 'LazyNegatedEq $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lazynegatedeqalt_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lazynegatedeqalt_4.etc
deleted file mode 100644 (file)
index b150f63..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 @{ 'LazyNegatedEqAlt $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq.etc
deleted file mode 100644 (file)
index d41a4e8..0000000
+++ /dev/null
@@ -1,25 +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/lazynegatedeq_4.ma".
-include "basic_2/substitution/lleq.ma".
-
-(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
-
-definition llneq: relation4 ynat term lenv lenv ≝
-                  λd,T,L1,L2. |L1| = |L2| ∧ (L1 ⋕[T, d] L2 → ⊥).
-
-interpretation
-   "negated lazy equivalence (local environment)"
-   'LazyNegatedEq T d L1 L2 = (llneq d T L1 L2).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_alt.etc
deleted file mode 100644 (file)
index 00eb2c3..0000000
+++ /dev/null
@@ -1,68 +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/lazynegatedeqalt_4.ma".
-include "basic_2/substitution/lleq_lleq.ma".
-include "basic_2/substitution/llneq.ma".
-
-(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
-
-(* alternative definition of llneq *)
-inductive llneqa: relation4 ynat term lenv lenv ≝
-| llneqa_neq:     ∀I1,I2,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
-                  ⇩[i]L1 ≡ K1.ⓑ{I1}V1 → ⇩[i]L2 ≡ K2.ⓑ{I2}V2 →
-                  |K1| = |K2| → (V1 = V2 → ⊥) → llneqa d (#i) L1 L2
-| llneqa_eq :     ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
-                  ⇩[i]L1 ≡ K1.ⓑ{I1}V → ⇩[i]L2 ≡ K2.ⓑ{I2}V →
-                  llneqa 0 (V) K1 K2 → llneqa d (#i) L1 L2
-| llneqa_bind_sn: ∀a,I,L1,L2,V,T,d.
-                  llneqa d V L1 L2 → llneqa d (ⓑ{a,I}V.T) L1 L2
-| llneqa_bind_dx: ∀a,I,L1,L2,V,T,d.
-                  llneqa (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → llneqa d (ⓑ{a,I}V.T) L1 L2
-| llneqa_flat_sn: ∀I,L1,L2,V,T,d.
-                  llneqa d V L1 L2 → llneqa d (ⓕ{I}V.T) L1 L2
-| llneqa_flat_dx: ∀I,L1,L2,V,T,d.
-                  llneqa d T L1 L2 → llneqa d (ⓕ{I}V.T) L1 L2
-.
-
-interpretation
-   "negated lazy equivalence (local environment) alternative"
-   'LazyNegatedEqAlt T d L1 L2 = (llneqa d T L1 L2).
-
-(* Main properties **********************************************************)
-
-theorem llneq_llneqa: ∀T,L1,L2,d. L1 ⧣[T, d] L2 → L1 ⧣⧣[T, d] L2.
-#T #L1 @(f2_ind … rfw … L1 T) -L1 -T
-#n #IH #L1 * *
-[ #k #Hn #L2 #d * #HL12 #H elim H /2 width=1 by lleq_sort/
-| #i #Hn #L2 #d * #HL12 #H elim (ylt_split i d) #Hdi
-  [ elim H /2 width=1 by lleq_skip/ ]
-  elim (lt_or_ge i (|L1|)) #HiL1
-  [2: elim H /3 width=3 by lleq_free, le_repl_sn_aux/ ]
-  elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
-  elim (ldrop_O1_lt L2 i) /2 width=1 by/ #I2 #K2 #V2 #HLK2
-  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) normalize
-  elim (eq_term_dec V1 V2) #HnV12 destruct
-  [2: #H @(llneqa_neq … HLK1 … HLK2) /2 width=1 by/ ] (**) (* explicit constructor *)
-  elim (lleq_dec V2 K1 K2 0) #HnV2 [ elim H /2 width=8 by lleq_lref/ ]
-  #H @(llneqa_eq … HLK1 … HLK2) /4 width=2 by ldrop_fwd_rfw, conj/ (**) (* explicit constructor *)
-| #p #Hn #L2 #d * #HL12 #H elim H /2 width=1 by lleq_gref/
-| #a #I #V #T #Hn #L2 #d * #HL12 #H destruct elim (nlleq_inv_bind … H) -H
-  [ /5 width=1 by llneqa_bind_sn, conj/
-  | #H @llneqa_bind_dx @IH // @conj normalize /2 width=1 by/
-  ]
-| #I #V #T #Hn #L2 #d * #HL12 #H destruct elim (nlleq_inv_flat … H) -H
-  /5 width=1 by llneqa_flat_dx, llneqa_flat_sn, conj/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/llneq_ext.etc
deleted file mode 100644 (file)
index 235d869..0000000
+++ /dev/null
@@ -1,33 +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/llneq_alt.ma".
-
-(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma llneq_inv_atom1: ∀L1,L2,T,d. L1 ⧣⧣[T, d] L2 → |L1| ≤ d → ⊥.
-#L1 #L2 #T #d #H elim H -L1 -L2 -T -d /2 width=1 by/
-[ #I1 #I2 #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #_ #_ #_
-  >(ldrop_fwd_length … HLK1) -HLK1 normalize
-  #H lapply (yle_trans … H … Hdi) -d
-  /3 width=4 by yle_inv_inj, le_plus_xySz_x_false/
-| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #_ #_ #_
-  >(ldrop_fwd_length … HLK1) -HLK1 normalize
-  #H lapply (yle_trans … H … Hdi) -d
-  /3 width=4 by yle_inv_inj, le_plus_xySz_x_false/
-| #a #I #L1 <yplus_inj /4 width=1 by yle_succ/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lpxs_llneq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llneq/lpxs_llneq.etc
deleted file mode 100644 (file)
index 556d59b..0000000
+++ /dev/null
@@ -1,67 +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/llneq_alt.ma".
-include "basic_2/computation/lpxs_ldrop.ma".
-include "basic_2/computation/lpxs_cpxs.ma".
-
-(* SN EXTENDED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ******************)
-
-(* Forward lemmas on negated lazy equivalence for local environments ********)
-
-lemma lpxs_llneq_fwd_cpxs: ∀h,g,G,L1,L2,T,d. L1 ⧣⧣[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
-                           ∃∃T1,T2. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] T1 & ⦃G, L2⦄ ⊢ T ▶*[d, ∞] T2 &
-                                    ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 & (T1 = T2 → ⊥).
-#h #g #G #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-[ #I1 #I2 #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #_ #HnV12 #HL12
-  elim (lpxs_ldrop_conf … HLK1 … HL12) -HL12 #Y #H #HY
-  elim (lpxs_inv_pair1 … H) -H #Z #X #_ #HV12 #H destruct
-  lapply (ldrop_mono … HY … HLK2) -HY #H destruct
-  lapply (ldrop_fwd_drop2 … HLK1) #H2LK1
-  elim (lift_total V1 0 (i+1)) #T1 #HVT1
-  elim (lift_total V2 0 (i+1)) #T2 #HVT2
-  @(ex4_2_intro … T1 T2) /3 width=10 by cpxs_lift, cpys_subst, lift_inj/ (**) (* explicit constructor *)
-| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 #_ #IHK12 #HL12
-  elim (lpxs_ldrop_conf … HLK1 … HL12) -HL12 #Y #H #HY
-  elim (lpxs_inv_pair1 … H) -H #Z #X #HK12 #_ #H destruct
-  lapply (ldrop_mono … HY … HLK2) -HY #H destruct
-  elim (IHK12 HK12) -IHK12 -HK12 #V1 #V2 #HV1 #HV2 #HV12 #HnV12
-  lapply (ldrop_fwd_drop2 … HLK1) #H2LK1
-  elim (lift_total V1 0 (i+1)) #T1 #HVT1
-  elim (lift_total V2 0 (i+1)) #T2 #HVT2
-  @(ex4_2_intro … T1 T2) /3 width=10 by cpxs_lift, cpys_subst_Y2, lift_inj/ (**) (* explicit constructor *)
-| #a #I #L1 #L2 #V #T #d #_ #IHV #HL12 elim (IHV HL12) -IHV -HL12
-  #V1 #V2 #HV1 #HV2 #HV12 #HnV12
-  @(ex4_2_intro … (ⓑ{a,I}V1.T) (ⓑ{a,I}V2.T)) /2 width=1 by cpys_bind, cpxs_pair_sn/
-  #H destruct /2 width=1 by/
-| #a #I #L1 #L2 #V #T #d #_ #IHT #HL12 elim (IHT ?) /2 width=1 by lpxs_pair_refl/ -IHT -HL12
-  #T1 #T2 #HT1 #HT2 #HT12 #HnT12
-  @(ex4_2_intro … (ⓑ{a,I}V.T1) (ⓑ{a,I}V.T2)) /2 width=1 by cpys_bind, cpxs_bind_dx/
-  #H destruct /2 width=1 by/
-| #I #L1 #L2 #V #T #d #_ #IHV #HL12 elim (IHV HL12) -IHV -HL12
-  #V1 #V2 #HV1 #HV2 #HV12 #HnV12
-  @(ex4_2_intro … (ⓕ{I}V1.T) (ⓕ{I}V2.T)) /2 width=1 by cpys_flat, cpxs_pair_sn/
-  #H destruct /2 width=1 by/
-| #I #L1 #L2 #V #T #d #_ #IHT #HL12 elim (IHT HL12) -IHT -HL12
-  #T1 #T2 #HT1 #HT2 #HT12 #HnT12
-  @(ex4_2_intro … (ⓕ{I}V.T1) (ⓕ{I}V.T2)) /2 width=1 by cpys_flat, cpxs_flat_dx/
-  #H destruct /2 width=1 by/
-]
-qed-.
-
-lemma lpxs_nlleq_fwd_cpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
-                           (L1 ⋕[T, d] L2 → ⊥) →
-                           ∃∃T1,T2. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] T1 & ⦃G, L2⦄ ⊢ T ▶*[d, ∞] T2 &
-                                    ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 & (T1 = T2 → ⊥).
-/5 width=4 by lpxs_llneq_fwd_cpxs, lpxs_fwd_length, llneq_llneqa, conj/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cpcs_cpcs.etc
deleted file mode 100644 (file)
index d31f9ca..0000000
+++ /dev/null
@@ -1,205 +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/computation/llprs_cprs.ma".
-include "basic_2/conversion/cpc_cpc.ma".
-include "basic_2/equivalence/cpcs_cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma cpcs_inv_cprs: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
-                     ∃∃T. ⦃G, L⦄ ⊢ T1 ➡* T & ⦃G, L⦄ ⊢ T2 ➡* T.
-#G #L #T1 #T2 #H @(cpcs_ind … H) -T2
-[ /3 width=3 by ex2_intro/
-| #T #T2 #_ #HT2 * #T0 #HT10 elim HT2 -HT2 #HT2 #HT0
-  [ elim (cprs_strip … HT0 … HT2) -T /3 width=3 by cprs_strap1, ex2_intro/
-  | /3 width=5 by cprs_strap2, ex2_intro/
-  ]
-]
-qed-.
-
-(* Basic_1: was: pc3_gen_sort *)
-lemma cpcs_inv_sort: ∀G,L,k1,k2. ⦃G, L⦄ ⊢ ⋆k1 ⬌* ⋆k2 → k1 = k2.
-#G #L #k1 #k2 #H elim (cpcs_inv_cprs … H) -H
-#T #H1 >(cprs_inv_sort1 … H1) -T #H2
-lapply (cprs_inv_sort1 … H2) -L #H destruct //
-qed-.
-
-lemma cpcs_inv_abst1: ∀a,G,L,W1,T1,T. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ⬌* T →
-                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T ➡* ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
-#a #G #L #W1 #T1 #T #H
-elim (cpcs_inv_cprs … H) -H #X #H1 #H2
-elim (cprs_inv_abst1 … H1) -H1 #W2 #T2 #HW12 #HT12 #H destruct
-/3 width=6 by cprs_bind, ex2_2_intro/
-qed-.
-
-lemma cpcs_inv_abst2: ∀a,G,L,W1,T1,T. ⦃G, L⦄ ⊢ T ⬌* ⓛ{a}W1.T1 →
-                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T ➡* ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
-/3 width=1 by cpcs_inv_abst1, cpcs_sym/ qed-.
-
-(* Basic_1: was: pc3_gen_sort_abst *)
-lemma cpcs_inv_sort_abst: ∀a,G,L,W,T,k. ⦃G, L⦄ ⊢ ⋆k ⬌* ⓛ{a}W.T → ⊥.
-#a #G #L #W #T #k #H
-elim (cpcs_inv_cprs … H) -H #X #H1
->(cprs_inv_sort1 … H1) -X #H2
-elim (cprs_inv_abst1 … H2) -H2 #W0 #T0 #_ #_ #H destruct
-qed-.
-
-(* Basic_1: was: pc3_gen_lift *)
-lemma cpcs_inv_lift: ∀G,L,K,s,d,e. ⇩[s, d, e] L ≡ K →
-                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
-                     ⦃G, L⦄ ⊢ U1 ⬌* U2 → ⦃G, K⦄ ⊢ T1 ⬌* T2.
-#G #L #K #s #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #HU12
-elim (cpcs_inv_cprs … HU12) -HU12 #U #HU1 #HU2
-elim (cprs_inv_lift1 … HU1 … HLK … HTU1) -U1 #T #HTU #HT1
-elim (cprs_inv_lift1 … HU2 … HLK … HTU2) -L -U2 #X #HXU
->(lift_inj … HXU … HTU) -X -U -d -e /2 width=3 by cprs_div/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma llpr_cpcs_trans: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡[T2, 0] L2 →
-                       ⦃G, L2⦄ ⊢ T1 ⬌* T2 → ⦃G, L1⦄ ⊢ T1 ⬌* T2.
-#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
-/4 width=5 by cprs_div, cprs_llpr_trans/
-qed-.
-
-lemma llprs_cpcs_trans: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡*[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡*[T2, 0] L2 →
-                        ⦃G, L2⦄ ⊢ T1 ⬌* T2 → ⦃G, L1⦄ ⊢ T1 ⬌* T2.
-#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
-/4 width=5 by cprs_div, llprs_cprs_trans/
-qed-.
-
-lemma cpr_cprs_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡ T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
-#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_strip … HT1 … HT2) -HT1 -HT2
-/2 width=3 by cpr_cprs_div/
-qed-.
-
-lemma cprs_cpr_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡ T2 → ⦃G, L⦄ ⊢ T2 ⬌* T1.
-#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_strip … HT1 … HT2) -HT1 -HT2
-/2 width=3 by cprs_cpr_div/
-qed-.
-
-lemma cprs_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
-#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_conf … HT1 … HT2) -HT1 -HT2
-/2 width=3 by cprs_div/
-qed-.
-
-(* Basic_1: was: pc3_wcpr0_t *)
-(* Basic_1: note: pc3_wcpr0_t should be renamed *)
-lemma llpr_cprs_conf: ∀G,L1,L2,T1. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 →
-                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
-#G #L1 #L2 #T1 #HL12 #T2 #HT12 elim (cprs_llpr_conf_dx … HT12 … HL12) -L1
-/2 width=3 by cprs_div/
-qed-.
-
-(* Basic_1: was only: pc3_pr0_pr2_t *)
-(* Basic_1: note: pc3_pr0_pr2_t should be renamed *)
-lemma llpr_cpr_conf: ∀G,L1,L2,T1. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 →
-                     ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
-/3 width=5 by llpr_cprs_conf, cpr_cprs/ qed-.
-
-(* Basic_1: was only: pc3_thin_dx *)
-lemma cpcs_flat: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 → ∀T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
-                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ⬌* ⓕ{I}V2.T2.
-#G #L #V1 #V2 #HV12 #T1 #T2 #HT12
-elim (cpcs_inv_cprs … HV12) -HV12
-elim (cpcs_inv_cprs … HT12) -HT12
-/3 width=5 by cprs_flat, cprs_div/
-qed.
-
-lemma cpcs_flat_dx_cpr_rev: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V2 ➡ V1 → ∀T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
-                            ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ⬌* ⓕ{I}V2.T2.
-/3 width=1 by cpr_cpcs_sn, cpcs_flat/ qed.
-
-lemma cpcs_bind_dx: ∀a,I,G,L,V,T1,T2. ⦃G, L.ⓑ{I}V⦄ ⊢ T1 ⬌* T2 →
-                    ⦃G, L⦄ ⊢ ⓑ{a,I}V.T1 ⬌* ⓑ{a,I}V.T2.
-#a #I #G #L #V #T1 #T2 #HT12 elim (cpcs_inv_cprs … HT12) -HT12
-/3 width=5 by cprs_div, cprs_bind/
-qed.
-
-lemma cpcs_bind_sn: ∀a,I,G,L,V1,V2,T. ⦃G, L⦄ ⊢ V1 ⬌* V2 → ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T ⬌* ⓑ{a,I}V2. T.
-#a #I #G #L #V1 #V2 #T #HV12 elim (cpcs_inv_cprs … HV12) -HV12
-/3 width=5 by cprs_div, cprs_bind/
-qed.
-
-lemma lsubr_cpcs_trans: ∀G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ⬌* T2 →
-                        ∀L2. L2 ⊑ L1 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
-#G #L1 #T1 #T2 #HT12 elim (cpcs_inv_cprs … HT12) -HT12
-/3 width=5 by cprs_div, lsubr_cprs_trans/
-qed-.
-
-(* Basic_1: was: pc3_lift *)
-lemma cpcs_lift: ∀G,L,K,s,d,e. ⇩[s, d, e] L ≡ K →
-                 ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
-                 ⦃G, K⦄ ⊢ T1 ⬌* T2 → ⦃G, L⦄ ⊢ U1 ⬌* U2.
-#G #L #K #s #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #HT12
-elim (cpcs_inv_cprs … HT12) -HT12 #T #HT1 #HT2
-elim (lift_total T d e) /3 width=12 by cprs_div, cprs_lift/
-qed.
-
-lemma cpcs_strip: ∀G,L,T1,T. ⦃G, L⦄ ⊢ T ⬌* T1 → ∀T2. ⦃G, L⦄ ⊢ T ⬌ T2 →
-                  ∃∃T0. ⦃G, L⦄ ⊢ T1 ⬌ T0 & ⦃G, L⦄ ⊢ T2 ⬌* T0.
-#G #L #T1 #T @TC_strip1 /2 width=3 by cpc_conf/ qed-.
-
-(* More inversion lemmas ****************************************************)
-
-axiom cpcs_inv_abst_sn: ∀a1,a2,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a1}W1.T1 ⬌* ⓛ{a2}W2.T2 →
-                        ∧∧ ⦃G, L⦄ ⊢ W1 ⬌* W2 & ⦃G, L.ⓛW1⦄ ⊢ T1 ⬌* T2 & a1 = a2.
-(*
-#a1 #a2 #G #L #W1 #W2 #T1 #T2 #H
-elim (cpcs_inv_cprs … H) -H #T #H1 #H2
-elim (cprs_inv_abst1 … H1) -H1 #W0 #T0 #HW10 #HT10 #H destruct
-elim (cprs_inv_abst1 … H2) -H2 #W #T #HW2 #HT2 #H destruct
-lapply (llprs_cprs_conf … (L.ⓛW) … HT2) /2 width=1 by llprs_pair/ -HT2 #HT2
-lapply (llprs_cpcs_trans … (L.ⓛW1) … HT2) /2 width=1 by llprs_pair/ -HT2 #HT2
-/4 width=3 by and3_intro, cprs_div, cpcs_cprs_div, cpcs_sym/
-qed-.
-*)
-lemma cpcs_inv_abst_dx: ∀a1,a2,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a1}W1.T1 ⬌* ⓛ{a2}W2.T2 →
-                        ∧∧ ⦃G, L⦄ ⊢ W1 ⬌* W2 & ⦃G, L.ⓛW2⦄ ⊢ T1 ⬌* T2 & a1 = a2.
-#a1 #a2 #G #L #W1 #W2 #T1 #T2 #HT12 lapply (cpcs_sym … HT12) -HT12
-#HT12 elim (cpcs_inv_abst_sn … HT12) -HT12 /3 width=1 by cpcs_sym, and3_intro/
-qed-.
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was pc3_t *)
-theorem cpcs_trans: ∀G,L,T1,T. ⦃G, L⦄ ⊢ T1 ⬌* T → ∀T2. ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
-#G #L #T1 #T #HT1 #T2 @(trans_TC … HT1) qed-.
-
-theorem cpcs_canc_sn: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ⬌* T1 → ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
-/3 width=3 by cpcs_trans, cpcs_sym/ qed-.
-
-theorem cpcs_canc_dx: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T → ⦃G, L⦄ ⊢ T2 ⬌* T → ⦃G, L⦄ ⊢ T1 ⬌* T2.
-/3 width=3 by cpcs_trans, cpcs_sym/ qed-.
-
-lemma cpcs_bind1: ∀a,I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 →
-                  ∀T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ⬌* T2 →
-                  ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T1 ⬌* ⓑ{a,I}V2. T2.
-/3 width=3 by cpcs_trans, cpcs_bind_sn, cpcs_bind_dx/ qed.
-
-lemma cpcs_bind2: ∀a,I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 →
-                  ∀T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ⬌* T2 →
-                  ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T1 ⬌* ⓑ{a,I}V2. T2.
-/3 width=3 by cpcs_trans, cpcs_bind_sn, cpcs_bind_dx/ qed.
-
-(* Basic_1: was: pc3_wcpr0 *)
-lemma llpr_cpcs_conf: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡[T2, 0] L2 →
-                      ⦃G, L1⦄ ⊢ T1 ⬌* T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
-#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
-/3 width=5 by cpcs_canc_dx, llpr_cprs_conf/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_cprs.etc
deleted file mode 100644 (file)
index a85488c..0000000
+++ /dev/null
@@ -1,166 +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/llpr_llpr.ma".
-include "basic_2/computation/cprs_lift.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: pr3_t *)
-(* Basic_1: includes: pr1_t *)
-theorem cprs_trans: ∀G,L. Transitive … (cprs G L).
-normalize /2 width=3 by trans_TC/ qed-. 
-
-(* Basic_1: was: pr3_confluence *)
-(* Basic_1: includes: pr1_confluence *)
-theorem cprs_conf: ∀G,L. confluent2 … (cprs G L) (cprs G L).
-normalize /3 width=3 by cpr_conf, TC_confluent2/ qed-.
-
-theorem cprs_bind: ∀a,I,G,L,V1,V2,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
-                   ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
-#a #I #G #L #V1 #V2 #T1 #T2 #HT12 #H @(cprs_ind … H) -V2
-/3 width=5 by cprs_trans, cprs_bind_dx/
-qed.
-
-(* Basic_1: was: pr3_flat *)
-theorem cprs_flat: ∀I,G,L,V1,V2,T1,T2. ⦃G, L⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
-                   ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ➡* ⓕ{I}V2.T2.
-#I #G #L #V1 #V2 #T1 #T2 #HT12 #H @(cprs_ind … H) -V2
-/3 width=3 by cprs_flat_dx, cprs_strap1, cpr_pair_sn/
-qed.
-
-theorem cprs_beta_rc: ∀a,G,L,V1,V2,W1,W2,T1,T2.
-                      ⦃G, L⦄ ⊢ V1 ➡ V2 → ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ W1 ➡* W2 →
-                      ⦃G, L⦄ ⊢ ⓐV1.ⓛ{a}W1.T1 ➡* ⓓ{a}ⓝW2.V2.T2.
-#a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HT12 #H @(cprs_ind … H) -W2 /2 width=1 by cprs_beta_dx/
-#W #W2 #_ #HW2 #IHW1 (**) (* fulla uto too slow 14s *)
-@(cprs_trans … IHW1) -IHW1 /3 width=1 by cprs_flat_dx, cprs_bind/
-qed.
-
-theorem cprs_beta: ∀a,G,L,V1,V2,W1,W2,T1,T2.
-                   ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
-                   ⦃G, L⦄ ⊢ ⓐV1.ⓛ{a}W1.T1 ➡* ⓓ{a}ⓝW2.V2.T2.
-#a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #HT12 #HW12 #H @(cprs_ind … H) -V2 /2 width=1 by cprs_beta_rc/
-#V #V2 #_ #HV2 #IHV1
-@(cprs_trans … IHV1) -IHV1 /3 width=1 by cprs_flat_sn, cprs_bind/
-qed.
-
-theorem cprs_theta_rc: ∀a,G,L,V1,V,V2,W1,W2,T1,T2.
-                       ⦃G, L⦄ ⊢ V1 ➡ V → ⇧[0, 1] V ≡ V2 → ⦃G, L.ⓓW1⦄ ⊢ T1 ➡* T2 →
-                       ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L⦄ ⊢ ⓐV1.ⓓ{a}W1.T1 ➡* ⓓ{a}W2.ⓐV2.T2.
-#a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #HV1 #HV2 #HT12 #H elim H -W2
-/3 width=5 by cprs_trans, cprs_theta_dx, cprs_bind_dx/
-qed.
-
-theorem cprs_theta: ∀a,G,L,V1,V,V2,W1,W2,T1,T2.
-                    ⇧[0, 1] V ≡ V2 → ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L.ⓓW1⦄ ⊢ T1 ➡* T2 →
-                    ⦃G, L⦄ ⊢ V1 ➡* V → ⦃G, L⦄ ⊢ ⓐV1.ⓓ{a}W1.T1 ➡* ⓓ{a}W2.ⓐV2.T2.
-#a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #HV2 #HW12 #HT12 #H @(TC_ind_dx … V1 H) -V1
-/3 width=3 by cprs_trans, cprs_theta_rc, cprs_flat_dx/
-qed.
-
-(* Advanced inversion lemmas ************************************************)
-
-(* Basic_1: was pr3_gen_appl *)
-lemma cprs_inv_appl1: ∀G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓐV1.T1 ➡* U2 →
-                      ∨∨ ∃∃V2,T2.       ⦃G, L⦄ ⊢ V1 ➡* V2 & ⦃G, L⦄ ⊢ T1 ➡* T2 &
-                                        U2 = ⓐV2. T2
-                       | ∃∃a,W,T.       ⦃G, L⦄ ⊢ T1 ➡* ⓛ{a}W.T &
-                                        ⦃G, L⦄ ⊢ ⓓ{a}ⓝW.V1.T ➡* U2
-                       | ∃∃a,V0,V2,V,T. ⦃G, L⦄ ⊢ V1 ➡* V0 & ⇧[0,1] V0 ≡ V2 &
-                                        ⦃G, L⦄ ⊢ T1 ➡* ⓓ{a}V.T &
-                                        ⦃G, L⦄ ⊢ ⓓ{a}V.ⓐV2.T ➡* U2.
-#G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /3 width=5 by or3_intro0, ex3_2_intro/
-#U #U2 #_ #HU2 * *
-[ #V0 #T0 #HV10 #HT10 #H destruct
-  elim (cpr_inv_appl1 … HU2) -HU2 *
-  [ #V2 #T2 #HV02 #HT02 #H destruct /4 width=5 by cprs_strap1, or3_intro0, ex3_2_intro/
-  | #a #V2 #W #W2 #T #T2 #HV02 #HW2 #HT2 #H1 #H2 destruct
-    lapply (cprs_strap1 … HV10 … HV02) -V0 #HV12
-    lapply (lsubr_cpr_trans … HT2 (L.ⓓⓝW.V1) ?) -HT2
-    /5 width=5 by cprs_flat_dx, cpr_cprs, cprs_bind, lsubr_abst, ex2_3_intro, or3_intro1/
-  | #a #V #V2 #W0 #W2 #T #T2 #HV0 #HV2 #HW02 #HT2 #H1 #H2 destruct
-    @or3_intro2 @(ex4_5_intro … HV2 HT10) /3 width=3 by cprs_flat_sn, cprs_strap1, cpr_cprs, cprs_bind/ (**) (* full auto is too slow 11s *)
-  ]
-| /4 width=9 by cprs_strap1, or3_intro1, ex2_3_intro/
-| /4 width=11 by cprs_strap1, or3_intro2, ex4_5_intro/
-]
-qed-.
-
-(* Properties concerning sn parallel reduction on local environments ********)
-
-(* Basic_1: was just: pr3_pr2_pr2_t *)
-(* Basic_1: includes: pr3_pr0_pr2_t *)
-lemma llpr_cpr_trans: ∀G. s_r_transitive … (cpr G) (llpr G 0).
-#G #L2 #T1 #T2 #HT12 elim HT12 -G -L2 -T1 -T2
-[ /2 width=3 by/
-| #G #L2 #K2 #V0 #V2 #W2 #i #HLK2 #_ #HVW2 #IHV02 #L1 #HL12
-  elim (llpr_inv_lref_ge_dx … HL12 … HLK2) -L2
-  /5 width=7 by cprs_delta, cprs_strap2, llpr_cpr_conf/
-| #a #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (llpr_inv_bind_O … HL12) -HL12 /4 width=1 by cprs_bind/
-| #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (llpr_inv_flat … HL12) -HL12 /3 width=1 by cprs_flat/
-| #G #L2 #V2 #T1 #T #T2 #_ #HT2 #IHT1 #L1 #HL12
-  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_zeta/
-| #G #L2 #V2 #T1 #T2 #HT12 #IHT12 #L1 #HL12
-  elim (llpr_inv_flat … HL12) /3 width=1 by cprs_tau/
-| #a #G #L2 #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #L1 #HL12
-  elim (llpr_inv_flat … HL12) -HL12 #HV1 #HL12
-  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_beta/
-| #a #G #L2 #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #L1 #HL12
-  elim (llpr_inv_flat … HL12) -HL12 #HV1 #HL12
-  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_theta/
-]
-qed-.
-
-lemma cpr_bind2: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡ V2 → ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡ T2 →
-                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
-/4 width=9 by llpr_cpr_trans, cprs_bind_dx, llpr_bind_repl_O/ qed.
-
-(* Advanced properties ******************************************************)
-
-(* Basic_1: was only: pr3_pr2_pr3_t pr3_wcpr0_t *)
-lemma cprs_llpr_trans: ∀G. s_rs_transitive … (cpr G) (llpr G 0).
-/3 width=6 by llpr_cpr_trans, llpr_cpr_conf, s_r_trans_LTC1/ qed-.
-
-(* Basic_1: was: pr3_strip *)
-(* Basic_1: includes: pr1_strip *)
-lemma cprs_strip: ∀G,L. confluent2 … (cprs G L) (cpr G L).
-normalize /4 width=3 by cpr_conf, TC_strip1/ qed-.
-
-lemma cprs_llpr_conf_dx: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
-                         ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
-#G #L0 #T0 #T1 #H @(cprs_ind_dx … T0 H) -T0 /2 width=3 by ex2_intro/
-#T0 #T #HT0 #_ #IHT1 #L1 #HL01
-elim (IHT1 … L1) /2 by llpr_cpr_conf/ -IHT1 #T2 #HT12 #HT2
-elim (llpr_cpr_conf_dx … HT0 … HL01) -L0 #T3 #HT03 #HT3
-elim (cprs_strip … HT2 … HT3) -T
-/4 width=5 by cprs_strap2, cprs_strap1, ex2_intro/
-qed-.
-
-lemma cprs_llpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 →
-                         ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
-                         ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
-#G #L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cprs_llpr_conf_dx … HT01 … HL01)
-/4 width=5 by cprs_llpr_trans, cprs_llpr_conf, ex2_intro/
-qed-.
-
-lemma cprs_bind2_dx: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡ V2 →
-                     ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡* T2 →
-                     ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
-/4 width=9 by cprs_llpr_trans, cprs_bind_dx, llpr_bind_repl_O/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/cprs_lift.etc
deleted file mode 100644 (file)
index 27f0bb6..0000000
+++ /dev/null
@@ -1,63 +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/llpr_ldrop.ma".
-include "basic_2/computation/cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Advanced properties ******************************************************)
-
-(* Note: apparently this was missing in basic_1 *)
-lemma cprs_delta: ∀G,L,K,V,V2,i.
-                  ⇩[i] L ≡ K.ⓓV → ⦃G, K⦄ ⊢ V ➡* V2 →
-                  ∀W2. ⇧[0, i + 1] V2 ≡ W2 → ⦃G, L⦄ ⊢ #i ➡* W2.
-#G #L #K #V #V2 #i #HLK #H elim H -V2 [ /3 width=6 by cpr_cprs, cpr_delta/ ]
-#V1 #V2 #_ #HV12 #IHV1 #W2 #HVW2
-lapply (ldrop_fwd_drop2 … HLK) -HLK #HLK
-elim (lift_total V1 0 (i+1)) /4 width=12 by cpr_lift, cprs_strap1/
-qed.
-
-lemma cprs_llpr_conf: ∀G. s_r_confluent1 … (cprs G) (llpr G 0).
-/3 width=5 by llpr_cpr_conf, s_r_conf1_LTC1/ qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-(* Basic_1: was: pr3_gen_lref *)
-lemma cprs_inv_lref1: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ➡* T2 →
-                      T2 = #i ∨
-                      ∃∃K,V1,T1. ⇩[i] L ≡ K.ⓓV1 & ⦃G, K⦄ ⊢ V1 ➡* T1 &
-                                 ⇧[0, i + 1] T1 ≡ T2.
-#G #L #T2 #i #H @(cprs_ind … H) -T2 /2 width=1 by or_introl/
-#T #T2 #_ #HT2 *
-[ #H destruct
-  elim (cpr_inv_lref1 … HT2) -HT2 /2 width=1 by or_introl/
-  * /4 width=6 by cpr_cprs, ex3_3_intro, or_intror/
-| * #K #V1 #T1 #HLK #HVT1 #HT1
-  lapply (ldrop_fwd_drop2 … HLK) #H0LK
-  elim (cpr_inv_lift1 … HT2 … H0LK … HT1) -H0LK -T
- /4 width=6 by cprs_strap1, ex3_3_intro, or_intror/
-]
-qed-.
-
-(* Relocation properties ****************************************************)
-
-(* Basic_1: was: pr3_lift *)
-lemma cprs_lift: ∀G. l_liftable (cprs G).
-/3 width=10 by l_liftable_LTC, cpr_lift/ qed.
-
-(* Basic_1: was: pr3_gen_lift *)
-lemma cprs_inv_lift1: ∀G. l_deliftable_sn (cprs G).
-/3 width=6 by l_deliftable_sn_LTC, cpr_inv_lift1/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsn_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsn_5.etc
deleted file mode 100644 (file)
index 01ce586..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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡ break [ term 46 T , break term 46 d ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LazyPRedSn $G $L1 $L2 $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsnstar_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/lazypredsnstar_5.etc
deleted file mode 100644 (file)
index 824933f..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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡* break [ term 46 T , break term 46 d ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LazyPRedSnStar $G $L1 $L2 $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr.etc
deleted file mode 100644 (file)
index e4c1a01..0000000
+++ /dev/null
@@ -1,51 +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/lazypredsn_5.ma".
-include "basic_2/relocation/llpx_sn.ma".
-include "basic_2/reduction/cpr.ma".
-
-(* LAZY SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ************************)
-
-definition llpr: genv → relation4 ynat term lenv lenv ≝ λG. llpx_sn (cpr G).
-
-interpretation "lazy parallel reduction (local environment, sn variant)"
-   'LazyPRedSn G L1 L2 T d = (llpr G d T L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma llpr_inv_flat: ∀I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[ⓕ{I}V.T, d] L2 →
-                     ⦃G, L1⦄ ⊢ ➡[V, d] L2 ∧ ⦃G, L1⦄ ⊢ ➡[T, d] L2.
-/2 width=2 by llpx_sn_inv_flat/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma llpr_fwd_length: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L2 → |L1| = |L2|.
-/2 width=4 by llpx_sn_fwd_length/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma llpr_lref: ∀I,G,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
-                 ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                 ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 → ⦃G, K1⦄ ⊢ V1 ➡ V2 → ⦃G, L1⦄ ⊢ ➡[#i, d] L2.
-/2 width=9 by llpx_sn_lref/ qed.
-
-(* Note: lemma 250 *)
-lemma llpr_refl: ∀G,T,d. reflexive … (llpr G d T).
-/2 width=1 by llpx_sn_refl/ qed.
-
-(* Basic_1: removed theorems 5: wcpr0_gen_sort wcpr0_gen_head
-                                wcpr0_getl wcpr0_getl_back
-                                pr0_subst1_back
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_ldrop.etc
deleted file mode 100644 (file)
index 74f7cc6..0000000
+++ /dev/null
@@ -1,97 +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/fquq_alt.ma".
-include "basic_2/static/ssta_llpx_sn.ma".
-include "basic_2/reduction/cpr_lift.ma".
-include "basic_2/reduction/cpr_llpx_sn.ma".
-include "basic_2/reduction/llpr.ma".
-
-(* LAZY SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma llpr_inv_lref_ge_dx: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
-                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                    ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
-/2 width=5 by llpx_sn_inv_lref_ge_dx/ qed-.
-
-lemma llpr_inv_lref_ge_sn: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
-                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                    ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
-/2 width=5 by llpx_sn_inv_lref_ge_sn/ qed-.
-
-lemma llpr_inv_lref_ge_bi: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
-                           ∀I1,I2,K1,K2,V1,V2.
-                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           ∧∧ I1 = I2 & ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
-/2 width=8 by llpx_sn_inv_lref_ge_bi/ qed-.
-
-lemma llpr_inv_bind_O: ∀a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡ [ⓑ{a,I}V.T, 0] L2 →
-                       ⦃G, L1⦄ ⊢ ➡[V, 0] L2 ∧ ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[T, 0] L2.ⓑ{I}V.
-/2 width=2 by llpx_sn_inv_bind_O/ qed-.
-
-lemma llpr_bind_repl_O: ∀I,G,L1,L2,V1,V2,T. ⦃G, L1.ⓑ{I}V1⦄ ⊢ ➡[T, 0] L2.ⓑ{I}V2 →
-                        ∀J,W1,W2. ⦃G, L1⦄ ⊢ ➡[W1, 0] L2 → ⦃G, L1⦄ ⊢ W1 ➡ W2 → ⦃G, L1.ⓑ{J}W1⦄ ⊢ ➡[T, 0] L2.ⓑ{J}W2.
-/2 width=4 by llpx_sn_bind_repl_O/ qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma llpr_ssta_conf: ∀h,g,G. s_r_confluent1 … (ssta h g G) (llpr G 0).
-/3 width=10 by ssta_llpx_sn_conf, cpr_lift/ qed-.
-
-lemma llpr_cpr_conf: ∀G. s_r_confluent1 … (cpr G) (llpr G 0).
-/3 width=10 by cpr_llpx_sn_conf, cpr_inv_lift1, cpr_lift/ qed-.
-
-(* Properties on context-sensitive parallel reduction for terms *************)
-
-lemma fqu_cpr_trans_dx: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
-                        ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
-                        ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-/3 width=10 by llpr_lref, cpr_pair_sn, cpr_atom, cpr_bind, cpr_flat, fqu_lref_O, fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, ldrop_pair, ex3_2_intro/
-#G #L #K #U #T #e #HLK #HUT #U2 #HU2
-elim (lift_total U2 0 (e+1)) #T2 #HUT2
-lapply (cpr_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9 by fqu_drop, ex3_2_intro/
-qed-.
-
-lemma fquq_cpr_trans_dx: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
-                         ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
-                         ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃⸮ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (fqu_cpr_trans_dx … HT12 … HTU2) /3 width=5 by fqu_fquq, ex3_2_intro/
-| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma fqu_cpr_trans_sn: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
-                        ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
-                        ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L1⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-/3 width=10 by llpr_lref, cpr_pair_sn, cpr_bind, cpr_flat, fqu_lref_O, fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, ldrop_pair, ex3_2_intro/
-#G #L #K #U #T #e #HLK #HUT #U2 #HU2
-elim (lift_total U2 0 (e+1)) #T2 #HUT2
-lapply (cpr_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9 by fqu_drop, ex3_2_intro/
-qed-.
-
-lemma fquq_cpr_trans_sn: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
-                         ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
-                         ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L1⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃⸮ ⦃G2, L2, U2⦄.
-#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (fqu_cpr_trans_sn … HT12 … HTU2) /3 width=5 by fqu_fquq, ex3_2_intro/
-| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_llpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpr_llpr.etc
deleted file mode 100644 (file)
index 4e5b9e2..0000000
+++ /dev/null
@@ -1,375 +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_llpx_sn.ma".
-include "basic_2/substitution/fqup.ma".
-include "basic_2/reduction/llpr_ldrop.ma".
-
-(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
-
-(* Main properties on context-sensitive parallel reduction for terms ********)
-
-fact cpr_conf_llpr_atom_atom:
-   ∀I,G,L1,L2. ∃∃T. ⦃G, L1⦄ ⊢ ⓪{I} ➡ T & ⦃G, L2⦄ ⊢ ⓪{I} ➡ T.
-/2 width=3 by cpr_atom, ex2_intro/ qed-.
-
-fact cpr_conf_llpr_atom_delta:
-   ∀G,L0,i. (
-      ∀L,T. ⦃G, L0, #i⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀K0,V0. ⇩[i] L0 ≡ K0.ⓓV0 →
-   ∀V2. ⦃G, K0⦄ ⊢ V0 ➡ V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[#i, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[#i, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ #i ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
-#G #L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_lref_ge_sn … HL01 … HLK0) -HL01 // #K1 #V1 #HLK1 #HK01 #HV01
-elim (llpr_inv_lref_ge_sn … HL02 … HLK0) -HL02 // #K2 #W2 #HLK2 #HK02 #_
-lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
-lapply (fqup_lref … G … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1))
-/3 width=12 by cpr_lift, cpr_delta, ex2_intro/
-qed-.
-
-(* Basic_1: includes: pr0_delta_delta pr2_delta_delta *)
-fact cpr_conf_llpr_delta_delta:
-   ∀G,L0,i. (
-      ∀L,T. ⦃G, L0, #i⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀K0,V0. ⇩[i] L0 ≡ K0.ⓓV0 →
-   ∀V1. ⦃G, K0⦄ ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
-   ∀KX,VX. ⇩[i] L0 ≡ KX.ⓓVX →
-   ∀V2. ⦃G, KX⦄ ⊢ VX ➡ V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[#i, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[#i, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
-#G #L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
-#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-lapply (ldrop_mono … H … HLK0) -H #H destruct
-elim (llpr_inv_lref_ge_sn … HL01 … HLK0) -HL01 // #K1 #W1 #HLK1 #HK01 #_
-lapply (ldrop_fwd_drop2 … HLK1) -W1 #HLK1
-elim (llpr_inv_lref_ge_sn … HL02 … HLK0) -HL02 // #K2 #W2 #HLK2 #HK02 #_
-lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
-lapply (fqup_lref … G … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) /3 width=12 by cpr_lift, ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_bind_bind:
-   ∀a,I,G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, ⓑ{a,I}V0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0.ⓑ{I}V0⦄ ⊢ T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀T2. ⦃G, L0.ⓑ{I}V0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓑ{a,I}V0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓑ{a,I}V0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓑ{a,I}V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓑ{a,I}V2.T2 ➡ T.
-#a #I #G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
-elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) //
-elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH
-/3 width=5 by llpr_bind_repl_O, cpr_bind, ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_bind_zeta:
-   ∀G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, +ⓓV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T1 →
-   ∀T2. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ +ⓓV1.T1 ➡ T & ⦃G, L2⦄ ⊢ X2 ➡ T.
-#G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
-elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
-elim (IH … HT01 … HT02 (L1.ⓓV1) … (L2.ⓓV1)) -IH -HT01 -HT02 /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -T0 #T #HT1 #HT2
-elim (cpr_inv_lift1 … HT2 L2 … HXT2) -T2 /3 width=3 by cpr_zeta, ldrop_drop, ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_zeta_zeta:
-   ∀G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, +ⓓV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀T1. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
-   ∀T2. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ X1 ➡ T & ⦃G, L2⦄ ⊢ X2 ➡ T.
-#G #L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
-#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
-elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
-elim (IH … HT01 … HT02 (L1.ⓓV0) … (L2.ⓓV0)) -IH -HT01 -HT02 /2 width=4 by llpr_bind_repl_O/ -L0 -T0 #T #HT1 #HT2
-elim (cpr_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=2 by ldrop_drop/ #T1 #HT1 #HXT1
-elim (cpr_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=2 by ldrop_drop/ #T2 #HT2 #HXT2
-lapply (lift_inj … HT2 … HT1) -T #H destruct /2 width=3 by ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_flat_flat:
-   ∀I,G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, ⓕ{I}V0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓕ{I}V0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓕ{I}V0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓕ{I}V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓕ{I}V2.T2 ➡ T.
-#I #G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #H1V0 #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #H2V0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) //
-elim (IH … HT01 … HT02 … H1T0 … H2T0) /3 width=5 by cpr_flat, ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_flat_tau:
-   ∀G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, ⓝV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓝV1.T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
-#G #L0 #V0 #T0 #IH #V1 #T1 #HT01
-#T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #_ #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #_ #H2T0
-elim (IH … HT01 … HT02 … H1T0 … H2T0) // -L0 -V0 -T0 /3 width=3 by cpr_tau, ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_tau_tau:
-   ∀G,L0,V0,T0. (
-      ∀L,T. ⦃G, L0, ⓝV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
-#G #L0 #V0 #T0 #IH #T1 #HT01
-#T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #_ #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #_ #H2T0
-elim (IH … HT01 … HT02 … H1T0 … H2T0) // -L0 -V0 -T0 /2 width=3 by ex2_intro/
-qed-.
-
-fact cpr_conf_llpr_flat_beta:
-   ∀a,G,L0,V0,W0,T0. (
-      ∀L,T. ⦃G, L0, ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ ⓛ{a}W0.T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓐV1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}ⓝW2.V2.T2 ➡ T.
-#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #X #H
-#V2 #HV02 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (cpr_inv_abst1 … H) -H #W1 #T1 #HW01 #HT01 #H destruct
-elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
-elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
-elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
-elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/ #W #HW1 #HW2
-elim (IH … HT01 … HT02 (L1.ⓛW1) … (L2.ⓛW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
-lapply (lsubr_cpr_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /2 width=1 by lsubr_abst/ (**) (* full auto not tried *)
-/4 width=5 by cpr_bind, cpr_flat, cpr_beta, ex2_intro/
-qed-.
-
-(* Basic-1: includes:
-            pr0_cong_upsilon_refl pr0_cong_upsilon_zeta
-            pr0_cong_upsilon_cong pr0_cong_upsilon_delta
-*)
-fact cpr_conf_llpr_flat_theta:
-   ∀a,G,L0,V0,W0,T0. (
-      ∀L,T. ⦃G, L0, ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ ⓓ{a}W0.T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀U2. ⇧[O, 1] V2 ≡ U2 →
-   ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓐV1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}W2.ⓐU2.T2 ➡ T.
-#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #X #H
-#V2 #HV02 #U2 #HVU2 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
-elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
-elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
-elim (lift_total V 0 1) #U #HVU
-lapply (cpr_lift … HV2 (L2.ⓓW2) … HVU2 … HVU) -HVU2 /2 width=2 by ldrop_drop/ #HU2
-elim (cpr_inv_abbr1 … H) -H *
-[ #W1 #T1 #HW01 #HT01 #H destruct
-  elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/
-  elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0
-  /4 width=7 by cpr_bind, cpr_flat, cpr_theta, ex2_intro/
-| #T1 #HT01 #HXT1 #H destruct
-  elim (IH … HT01 … HT02 (L1.ⓓW2) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
-  elim (cpr_inv_lift1 … HT1 L1 … HXT1) -HXT1
-  /4 width=9 by cpr_flat, cpr_zeta, ldrop_drop, lift_flat, ex2_intro/
-]
-qed-.
-
-fact cpr_conf_llpr_beta_beta:
-   ∀a,G,L0,V0,W0,T0. (
-      ∀L,T. ⦃G, L0, ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀W1. ⦃G, L0⦄ ⊢ W0 ➡ W1 → ∀T1. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓓ{a}ⓝW1.V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}ⓝW2.V2.T2 ➡ T.
-#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #W1 #HW01 #T1 #HT01
-#V2 #HV02 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
-elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
-elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
-elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1/ #W #HW1 #HW2
-elim (IH … HT01 … HT02 (L1.ⓛW1) … (L2.ⓛW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
-lapply (lsubr_cpr_trans … HT1 (L1.ⓓⓝW1.V1) ?) -HT1 /2 width=1 by lsubr_abst/
-lapply (lsubr_cpr_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /2 width=1 by lsubr_abst/
-/4 width=5 by cpr_bind, cpr_flat, ex2_intro/ (**) (* full auto not tried *)
-qed-.
-
-(* Basic_1: includes: pr0_upsilon_upsilon *)
-fact cpr_conf_llpr_theta_theta:
-   ∀a,G,L0,V0,W0,T0. (
-      ∀L,T. ⦃G, L0, ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
-      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
-      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
-      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
-   ) →
-   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀U1. ⇧[O, 1] V1 ≡ U1 →
-   ∀W1. ⦃G, L0⦄ ⊢ W0 ➡ W1 → ∀T1. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T1 →
-   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀U2. ⇧[O, 1] V2 ≡ U2 →
-   ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T2 →
-   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L2 →
-   ∃∃T. ⦃G, L1⦄ ⊢ ⓓ{a}W1.ⓐU1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}W2.ⓐU2.T2 ➡ T.
-#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #U1 #HVU1 #W1 #HW01 #T1 #HT01
-#V2 #HV02 #U2 #HVU2 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
-elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
-elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
-elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
-elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
-elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/
-elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0
-elim (lift_total V 0 1) #U #HVU
-lapply (cpr_lift … HV1 (L1.ⓓW1) … HVU1 … HVU) -HVU1 /2 width=2 by ldrop_drop/
-lapply (cpr_lift … HV2 (L2.ⓓW2) … HVU2 … HVU) -HVU2 /2 width=2 by ldrop_drop/
-/4 width=7 by cpr_bind, cpr_flat, ex2_intro/ (**) (* full auto not tried *)
-qed-.
-
-theorem cpr_conf_llpr: ∀G. llpx_sn_confluent2 (cpr G) (cpr G).
-#G #L0 #T0 @(fqup_wf_ind_eq … G L0 T0) -G -L0 -T0 #G #L #T #IH #G0 #L0 * [| * ]
-[ #I0 #HG #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpr_inv_atom1 … H1) -H1
-  elim (cpr_inv_atom1 … H2) -H2
-  [ #H2 #H1 destruct
-    /2 width=1 by cpr_conf_llpr_atom_atom/
-  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
-    /3 width=10 by cpr_conf_llpr_atom_delta/
-  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
-    /4 width=10 by ex2_commute, cpr_conf_llpr_atom_delta/
-  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
-    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
-    /3 width=17 by cpr_conf_llpr_delta_delta/
-  ]
-| #a #I #V0 #T0 #HG #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpr_inv_bind1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #T1 #HT01 #HXT1 #H11 #H12
-  ]
-  elim (cpr_inv_bind1 … H2) -H2 *
-  [1,3: #V2 #T2 #HV02 #HT02 #H2
-  |2,4: #T2 #HT02 #HXT2 #H21 #H22
-  ] destruct
-  [ /3 width=10 by cpr_conf_llpr_bind_bind/
-  | /4 width=11 by ex2_commute, cpr_conf_llpr_bind_zeta/
-  | /3 width=11 by cpr_conf_llpr_bind_zeta/
-  | /3 width=12 by cpr_conf_llpr_zeta_zeta/
-  ]
-| #I #V0 #T0 #HG #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpr_inv_flat1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #HX1 #H1
-  | #a1 #V1 #Y1 #W1 #Z1 #T1 #HV01 #HYW1 #HZT1 #H11 #H12 #H13
-  | #a1 #V1 #U1 #Y1 #W1 #Z1 #T1 #HV01 #HVU1 #HYW1 #HZT1 #H11 #H12 #H13
-  ]
-  elim (cpr_inv_flat1 … H2) -H2 *
-  [1,5,9,13: #V2 #T2 #HV02 #HT02 #H2
-  |2,6,10,14: #HX2 #H2
-  |3,7,11,15: #a2 #V2 #Y2 #W2 #Z2 #T2 #HV02 #HYW2 #HZT2 #H21 #H22 #H23
-  |4,8,12,16: #a2 #V2 #U2 #Y2 #W2 #Z2 #T2 #HV02 #HVU2 #HYW2 #HZT2 #H21 #H22 #H23
-  ] destruct
-  [ /3 width=10 by cpr_conf_llpr_flat_flat/
-  | /4 width=8 by ex2_commute, cpr_conf_llpr_flat_tau/
-  | /4 width=12 by ex2_commute, cpr_conf_llpr_flat_beta/
-  | /4 width=14 by ex2_commute, cpr_conf_llpr_flat_theta/
-  | /3 width=8 by cpr_conf_llpr_flat_tau/
-  | /3 width=8 by cpr_conf_llpr_tau_tau/
-  | /3 width=12 by cpr_conf_llpr_flat_beta/
-  | /3 width=13 by cpr_conf_llpr_beta_beta/
-  | /3 width=14 by cpr_conf_llpr_flat_theta/
-  | /3 width=17 by cpr_conf_llpr_theta_theta/
-  ]
-]
-qed-.
-
-(* Basic_1: includes: pr0_confluence pr2_confluence *)
-theorem cpr_conf: ∀G,L. confluent … (cpr G L).
-/2 width=6 by cpr_conf_llpr/ qed-.
-
-(* Properties on context-sensitive parallel reduction for terms *************)
-
-lemma llpr_cpr_conf_dx: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
-                        ∃∃T. ⦃G, L1⦄ ⊢ T0 ➡ T & ⦃G, L1⦄ ⊢ T1 ➡ T.
-#G #L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpr_conf_llpr … HT01 T0 … HL01 … HL01) /2 width=3 by ex2_intro/
-qed-.
-
-lemma llpr_cpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
-                        ∃∃T. ⦃G, L1⦄ ⊢ T0 ➡ T & ⦃G, L0⦄ ⊢ T1 ➡ T.
-#G #L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpr_conf_llpr … HT01 T0 … L0 … HL01) /2 width=3 by ex2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs.etc
deleted file mode 100644 (file)
index d3c2a6f..0000000
+++ /dev/null
@@ -1,61 +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/lazypredsnstar_5.ma".
-include "basic_2/reduction/llpr.ma".
-
-(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
-
-definition llprs: genv → relation4 ynat term lenv lenv ≝
-                  λG,d. LTC … (llpr G d).
-
-interpretation "lazy parallel computation (local environment, sn variant)"
-   'LazyPRedSnStar G L1 L2 T d = (llprs G d T L1 L2).
-
-(* Basic eliminators ********************************************************)
-
-lemma llprs_ind: ∀G,L1,T,d. ∀R:predicate lenv. R L1 →
-                 (∀L,L2. ⦃G, L1⦄ ⊢ ➡*[T, d] L → ⦃G, L⦄ ⊢ ➡[T, d] L2 → R L → R L2) →
-                 ∀L2. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → R L2.
-#G #L1 #T #d #R #HL1 #IHL1 #L2 #HL12
-@(TC_star_ind … HL1 IHL1 … HL12) //
-qed-.
-
-lemma llprs_ind_dx: ∀G,L2,T,d. ∀R:predicate lenv. R L2 →
-                    (∀L1,L. ⦃G, L1⦄ ⊢ ➡[T, d] L → ⦃G, L⦄ ⊢ ➡*[T, d] L2 → R L → R L1) →
-                    ∀L1. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → R L1.
-#G #L2 #T #d #R #HL2 #IHL2 #L1 #HL12
-@(TC_star_ind_dx … HL2 IHL2 … HL12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpr_llprs: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
-/2 width=1 by inj/ qed.
-
-lemma llprs_refl: ∀G,L,T,d. ⦃G, L⦄ ⊢ ➡*[T, d] L.
-/2 width=1 by lpr_llprs/ qed.
-
-lemma llprs_strap1: ∀G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[T, d] L → ⦃G, L⦄ ⊢ ➡[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
-normalize /2 width=3 by step/ qed-.
-
-lemma llprs_strap2: ∀G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L → ⦃G, L⦄ ⊢ ➡*[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
-normalize /2 width=3 by TC_strap/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma llprs_fwd_length: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → |L1| = |L2|.
-#G #L1 #L2 #T #d #H @(llprs_ind … H) -L2
-/3 width=6 by llpr_fwd_length, trans_eq/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_cprs.etc
deleted file mode 100644 (file)
index b9bf0f9..0000000
+++ /dev/null
@@ -1,122 +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_tc.ma".
-include "basic_2/computation/cprs_cprs.ma".
-include "basic_2/computation/llprs.ma".
-
-(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
-
-(* Advanced properties ******************************************************)
-
-lemma llprs_pair_dx: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡* V2 →
-                     ∀I,T. ⦃G, L.ⓑ{I}V1⦄ ⊢ ➡*[T, 0] L.ⓑ{I}V2.
-/2 width=1 by llpx_sn_TC_pair_dx/ qed.
-
-(* Properties on context-sensitive parallel computation for terms ***********)
-
-lemma llprs_cpr_trans: ∀G. s_r_transitive … (cpr G) (llprs G 0).
-/3 width=5 by cprs_llpr_trans, s_r_trans_LTC2/ qed-.
-
-(* Basic_1: was just: pr3_pr3_pr3_t *)
-lemma llprs_cprs_trans: ∀G. s_rs_transitive … (cpr G) (llprs G 0).
-#G @s_r_to_s_rs_trans @s_r_trans_LTC2
-/3 width=5 by cprs_llpr_trans, s_rs_trans_TC1/ (**) (* full auto too slow *)
-qed-.
-
-(* Note: this is an instance of a general theorem *)
-lemma llprs_cprs_conf_dx: ∀G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡* U2 →
-                          ∀L0. ⦃G2, L0⦄ ⊢ ➡*[T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[U2, O] L2.
-#G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llprs_ind_dx … H) -L0 //
-#L0 #L #HL0 #HL2 #IHL2 @(llprs_strap2 … IHL2) -IHL2
-lapply (llprs_cprs_trans … HTU2 … HL2) -L2 #HTU2
-/3 width=3 by cprs_llpr_trans, cprs_llpr_conf/
-qed-.
-
-(* Note: this is an instance of a general theorem *)
-lemma llprs_cpr_conf_dx: ∀G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
-                         ∀L0. ⦃G2, L0⦄ ⊢ ➡*[T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[U2, O] L2.
-#G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llprs_ind_dx … H) -L0 //
-#L0 #L #HL0 #HL2 #IHL2 @(llprs_strap2 … IHL2) -IHL2
-lapply (llprs_cpr_trans … HTU2 … HL2) -L2 #HTU2
-/3 width=3 by cprs_llpr_trans, cprs_llpr_conf/
-qed-.
-
-lemma llprs_cprs_conf_sn: ∀G,L0,L1,T0. ⦃G, L0⦄ ⊢ ➡*[T0, 0] L1 →
-                          ∀T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 →
-                          ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
-#G #L0 #L1 #T0 #H @(llprs_ind_dx … H) -L0 /2 width=3 by ex2_intro/
-#L0 #L #HL0 #HL1 #IHL1 #T1 #HT01 elim (cprs_llpr_conf_sn … HT01 … HL0)
-#T2 #HT12 #HT02 elim (IHL1 … HT02) -IHL1 -HT02
-lapply (cprs_trans … HT01 … HT12) #HT02
-lapply (cprs_llpr_conf … HT02 … HL0) -HT02 -HL0
-/4 width=5 by cprs_llpr_trans, cprs_trans, ex2_intro/
-qed-.
-
-lemma llprs_cpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 →
-                         ∀L1. ⦃G, L0⦄ ⊢ ➡*[T0, 0] L1 →
-                         ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
-/3 width=3 by llprs_cprs_conf_sn, cpr_cprs/ qed-.
-
-lemma cprs_bind2: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡* V2 →
-                  ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡* T2 →
-                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
-/4 width=3 by llprs_cprs_trans, llprs_pair_dx, cprs_bind/ qed-.
-
-(* Inversion lemmas on context-sensitive parallel computation for terms *****)
-
-(* Basic_1: was: pr3_gen_abst *)
-lemma cprs_inv_abst1: ∀a,G,L,W1,T1,U2. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* U2 →
-                      ∃∃W2,T2. ⦃G, L⦄ ⊢ W1 ➡* W2 & ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 &
-                               U2 = ⓛ{a}W2.T2.
-#a #G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /2 width=5 by ex3_2_intro/
-#U0 #U2 #_ #HU02 * #V0 #T0 #HV10 #HT10 #H destruct
-elim (cpr_inv_abst1 … HU02) -HU02 #V2 #T2 #HV02 #HT02 #H destruct
-lapply (llprs_cpr_trans … HT02 (L.ⓛV1) ?)
-/3 width=5 by llprs_pair_dx, cprs_trans, cprs_strap1, ex3_2_intro/
-qed-.
-
-lemma cprs_inv_abst: ∀a,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2 →
-                     ⦃G, L⦄ ⊢ W1 ➡* W2 ∧ ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2.
-#a #G #L #W1 #W2 #T1 #T2 #H
-elim (cprs_inv_abst1 … H) -H #W #T #HW1 #HT1 #H destruct /2 width=1 by conj/
-qed-.
-
-(* Basic_1: was pr3_gen_abbr *)
-lemma cprs_inv_abbr1: ∀a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓓ{a}V1.T1 ➡* U2 → (
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡* V2 & ⦃G, L.ⓓV1⦄ ⊢ T1 ➡* T2 &
-                               U2 = ⓓ{a}V2.T2
-                      ) ∨
-                      ∃∃T2. ⦃G, L.ⓓV1⦄ ⊢ T1 ➡* T2 & ⇧[0, 1] U2 ≡ T2 & a = true.
-#a #G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /3 width=5 by ex3_2_intro, or_introl/
-#U0 #U2 #_ #HU02 * *
-[ #V0 #T0 #HV10 #HT10 #H destruct
-  elim (cpr_inv_abbr1 … HU02) -HU02 *
-  [ #V2 #T2 #HV02 #HT02 #H destruct
-    lapply (llprs_cpr_trans … HT02 (L.ⓓV1) ?)
-    /4 width=5 by llprs_pair_dx, cprs_trans, cprs_strap1, ex3_2_intro, or_introl/
-  | #T2 #HT02 #HUT2
-    lapply (llprs_cpr_trans … HT02 (L.ⓓV1) ?) -HT02
-    /4 width=3 by llprs_pair_dx, cprs_trans, ex3_intro, or_intror/
-  ]
-| #U1 #HTU1 #HU01
-  elim (lift_total U2 0 1) #U #HU2
-  lapply (cpr_lift … HU02 (L.ⓓV1) … HU01 … HU2) -U0
-  /4 width=3 by cprs_strap1, ldrop_drop, ex3_intro, or_intror/
-]
-qed-.
-
-(* Note: we loose lprs_cprs_conf_dx and derivatives:
-         lprs_cpr_conf_dx lprs_cprs_conf
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_llprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llprs_llprs.etc
deleted file mode 100644 (file)
index 4f97672..0000000
+++ /dev/null
@@ -1,22 +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/computation/llprs.ma".
-
-(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
-
-(* Main properties **********************************************************)
-
-theorem llprs_trans: ∀G,T,d. Transitive … (llprs G d T).
-normalize /2 width=3 by trans_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpx_sn_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpr/llpx_sn_llpx_sn.etc
deleted file mode 100644 (file)
index 0df9690..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/relocation/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-definition llpx_sn_confluent2: relation (lenv→relation term) ≝ λR1,R2.
-                               ∀L0,T0,T1. R1 L0 T0 T1 → ∀T2. R2 L0 T0 T2 →
-                               ∀L1. llpx_sn R1 0 T0 L0 L1 → ∀L2. llpx_sn R2 0 T0 L0 L2 →
-                               ∃∃T. R2 L1 T1 T & R1 L2 T2 T.
-
-(* Note: we miss llpx_sn_conf and derivatives: lpr_conf lprs_conf *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/cpxs_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/cpxs_llpx.etc
deleted file mode 100644 (file)
index bec908e..0000000
+++ /dev/null
@@ -1,53 +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/llpx_ldrop.ma".
-include "basic_2/computation/cpxs_cpxs.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL COMPUTATION ON TERMS *****************)
-
-(* Properties on lazy sn reduction on local environments ********************)
-
-lemma cpxs_llpx_conf: ∀h,g,G. s_r_confluent1 … (cpxs h g G) (llpx h g G 0).
-/3 width=5 by llpx_cpx_conf, s_r_conf1_LTC1/ qed-.
-
-lemma llpx_cpx_trans: ∀h,g,G. s_r_transitive … (cpx h g G) (llpx h g G 0).
-#h #g #G #L2 #T1 #T2 #HT12 elim HT12 -G -L2 -T1 -T2
-[ /2 width=3 by/
-| /3 width=2 by cpx_cpxs, cpx_sort/
-| #I #G #L2 #K2 #V0 #V2 #W2 #i #HLK2 #_ #HVW2 #IHV02 #L1 #HL12
-  elim (llpx_inv_lref_ge_dx … HL12 … HLK2) -L2
-  /5 width=8 by cpxs_delta, cpxs_strap2, llpx_cpx_conf/
-| #a #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (llpx_inv_bind_O … HL12) -HL12 /4 width=1 by cpxs_bind/
-| #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
-  elim (llpx_inv_flat … HL12) -HL12 /3 width=1 by cpxs_flat/
-| #G #L2 #V2 #T1 #T #T2 #_ #HT2 #IHT1 #L1 #HL12
-  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_zeta/
-| #G #L2 #V2 #T1 #T2 #HT12 #IHT12 #L1 #HL12
-  elim (llpx_inv_flat … HL12) /3 width=1 by cpxs_tau/
-| #G #L2 #V1 #V2 #T2 #HV12 #IHV12 #L1 #HL12
-  elim (llpx_inv_flat … HL12) /3 width=1 by cpxs_ti/
-| #a #G #L2 #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #L1 #HL12
-  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HL12
-  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_beta/
-| #a #G #L2 #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #L1 #HL12
-  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HL12
-  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_theta/
-]
-qed-.
-
-lemma llpx_cpxs_trans: ∀h,g,G. s_rs_transitive … (cpx h g G) (llpx h g G 0).
-#h #g #G @s_r_trans_LTC1 /2 width=3 by llpx_cpx_trans, llpx_cpx_conf/ (**) (* full auto fails here but works in cprs_cprs *)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpx.etc
deleted file mode 100644 (file)
index c14492f..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/computation/cpxs_llpx.ma".
-include "basic_2/computation/csx_alt.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED STRONGLY NORMALIZING TERMS ********************)
-
-(* Properties on lazy sn extended reduction for local environments **********)
-
-lemma csx_llpx_conf: ∀h,g,G,L1,T. ⦃G, L1⦄ ⊢ ⬊*[h, g] T →
-                     ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
-#h #g #G #L1 #T #H @(csx_ind_alt … H) -T
-/5 width=3 by csx_intro_cpxs, llpx_cpxs_trans, cpxs_llpx_conf/ (* 2 cpxs_llpx_trans *)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/csx_llpxs.etc
deleted file mode 100644 (file)
index aad3e8b..0000000
+++ /dev/null
@@ -1,25 +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/computation/csx_llpx.ma".
-include "basic_2/computation/llpxs.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED STRONGLY NORMALIZING TERMS ********************)
-
-(* Properties on lazy sn extended computation for local environments ********)
-
-lemma csx_llpxs_conf: ∀h,g,G,L1,T. ⦃G, L1⦄ ⊢ ⬊*[h, g] T →
-                      ∀L2.  ⦃G, L1⦄ ⊢ ➡*[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
-#h #g #G #L1 #T #HT #L2 #H @(llpxs_ind … H) -L2 /3 by llpxs_strap1, csx_llpx_conf/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/fpbs_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/fpbs_lpr.etc
deleted file mode 100644 (file)
index 34b60ad..0000000
+++ /dev/null
@@ -1,36 +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_lift.ma".
-include "basic_2/reduction/llpx_lpr.ma".
-include "basic_2/computation/fpbs.ma".
-
-(* "BIG TREE" PARALLEL COMPUTATION FOR CLOSURES *****************************)
-
-(* Properties on sn parallel reduction for local environments ***************)
-
-(* Note: this is used in the closure proof *)
-(* Note: original proof: /4 width=5 by fpbs_strap1, lpr_fpb, cpr_fpb/ *)
-(* Note: this should be moved *)
-lemma cpr_lpr_fpbs: ∀h,g,G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L1⦄ ⊢ ➡ L2 →
-                    ⦃G, L1, T1⦄ ≥[h, g] ⦃G, L2, T2⦄.
-/5 width=5 by fpbs_strap1, cpr_fpb, fpb_llpx, lpr_llpx/ qed.
-
-(* Note: this is used in the closure proof *)
-(* Note: this should be moved *)
-lemma cpr_lpr_ssta_fpbs: ∀h,g,G,L1,L2,T1,T2,U2,l2.
-                         ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L1⦄ ⊢ ➡ L2 →
-                         ⦃G, L2⦄ ⊢ T2 ▪[h, g] l2+1 → ⦃G, L2⦄ ⊢ T2 •[h, g] U2 →
-                         ⦃G, L1, T1⦄ ≥[h, g] ⦃G, L2, U2⦄.
-/4 width=5 by fpbs_strap1, cpr_lpr_fpbs, ssta_cpx, fpb_cpx/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsn_7.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsn_7.etc
deleted file mode 100644 (file)
index 2350f5e..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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡ break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LazyPRedSn $G $L1 $L2 $h $g $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsnstar_7.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazypredsnstar_7.etc
deleted file mode 100644 (file)
index f8209e2..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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡* break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LazyPRedSnStar $G $L1 $L2 $h $g $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysn_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysn_6.etc
deleted file mode 100644 (file)
index 0c52a6e..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( G ⊢ ⋕ ⬊ * break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L )"
-   non associative with precedence 45
-   for @{ 'LazySN $h $g $T $d $G $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysnalt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/lazysnalt_6.etc
deleted file mode 100644 (file)
index 0976a31..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( G ⊢ ⋕ ⬊ ⬊ * break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L )"
-   non associative with precedence 45
-   for @{ 'LazySNAlt $h $g $T $d $G $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx.etc
deleted file mode 100644 (file)
index 3276008..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/notation/relations/lazypredsn_7.ma".
-include "basic_2/relocation/llpx_sn.ma".
-include "basic_2/reduction/cpx.ma".
-
-(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
-
-definition llpx: ∀h. sd h → genv → relation4 ynat term lenv lenv ≝
-                 λh,g,G. llpx_sn (cpx h g  G).
-
-interpretation "lazy extended parallel reduction (local environment, sn variant)"
-   'LazyPRedSn G L1 L2 h g T d = (llpx h g G d T L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma llpx_inv_flat: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
-                     ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2 ∧ ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
-/2 width=2 by llpx_sn_inv_flat/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma llpx_fwd_length: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → |L1| = |L2|.
-/2 width=4 by llpx_sn_fwd_length/ qed-.
-
-lemma llpx_fwd_flat_dx: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
-                     ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
-/2 width=3 by llpx_sn_fwd_flat_dx/ qed-.
-
-lemma llpx_fwd_pair_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ②{I}V.T, d] L2 →
-                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
-/2 width=3 by llpx_sn_fwd_pair_sn/ qed-.
-
-(* Note: this might be removed *)
-lemma llpx_fwd_bind_sn: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, d] L2 →
-                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
-/2 width=4 by llpx_sn_fwd_bind_sn/ qed-.
-
-(* Note: this might be removed *)
-lemma llpx_fwd_bind_dx: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, d] L2 →
-                        ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, ⫯d] L2.ⓑ{I}V.
-/2 width=2 by llpx_sn_fwd_bind_dx/ qed-.
-
-(* Note: this might be removed *)
-lemma llpx_fwd_flat_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
-                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
-/2 width=3 by llpx_sn_fwd_flat_sn/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma llpx_lref: ∀h,g,I,G,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
-                 ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                 ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 → ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 → ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2.
-/2 width=9 by llpx_sn_lref/ qed.
-
-lemma llpx_refl: ∀h,g,G,T,d. reflexive … (llpx h g G d T).
-/2 width=1 by llpx_sn_refl/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_aaa.etc
deleted file mode 100644 (file)
index 99eef8d..0000000
+++ /dev/null
@@ -1,82 +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/static/aaa_lift.ma".
-include "basic_2/static/lsuba_aaa.ma".
-include "basic_2/reduction/llpx_ldrop.ma".
-
-(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-(* Note: lemma 500 *)
-lemma aaa_cpx_llpx_conf: ∀h,g,G,L1,T1,A. ⦃G, L1⦄ ⊢ T1 ⁝ A →
-                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                         ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T1, 0] L2 → ⦃G, L2⦄ ⊢ T2 ⁝ A.
-#h #g #G #L1 #T1 #A #H elim H -G -L1 -T1 -A
-[ #g #L1 #k #X #H elim (cpx_inv_sort1 … H) -H // * //
-| #I #G #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #X #H #L2 #HL12
-  elim (cpx_inv_lref1 … H) -H
-  [ #H destruct
-    elim (llpx_inv_lref_ge_sn … HL12 … HLK1) -L1 /3 width=6 by aaa_lref/
-  | * #J #Y #Z #V2 #H #HV12 #HV2
-    lapply (ldrop_mono … H … HLK1) -H #H destruct
-    elim (llpx_inv_lref_ge_sn … HL12 … HLK1) -L1 /3 width=8 by aaa_lift, ldrop_fwd_drop2/
-  ]
-| #a #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (llpx_inv_bind_O … HL12) -HL12 #HV1 #HT1
-  elim (cpx_inv_abbr1 … H) -H *
-  [ #V2 #T2 #HV12 #HT12 #H destruct /4 width=4 by llpx_bind_repl_O, aaa_abbr/
-  | #T2 #HT12 #HT2 #H destruct -IHV1 /3 width=8 by aaa_inv_lift, ldrop_drop/
-  ]
-| #a #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (llpx_inv_bind_O … HL12) -HL12 #HV1 #HT1
-  elim (cpx_inv_abst1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  /4 width=4 by llpx_bind_repl_O, aaa_abst/
-| #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HT1
-  elim (cpx_inv_appl1 … H) -H *
-  [ #V2 #T2 #HV12 #HT12 #H destruct /3 width=3 by aaa_appl/
-  | #b #V2 #W1 #W2 #U1 #U2 #HV12 #HW12 #HU12 #H1 #H2 destruct
-    lapply (IHV1 … HV12 … HV1) -IHV1 -HV12 #HV2
-    lapply (IHT1 (ⓛ{b}W2.U2) … HT1) -IHT1 /2 width=1 by cpx_bind/ -L1 #H
-    elim (aaa_inv_abst … H) -H #B0 #A0 #HW1 #HU2 #H destruct
-    /5 width=6 by lsuba_aaa_trans, lsuba_abbr, aaa_abbr, aaa_cast/
-  | #b #V #V2 #W1 #W2 #U1 #U2 #HV1 #HV2 #HW12 #HU12 #H1 #H2 destruct
-    lapply (aaa_lift G L2 … B … (L2.ⓓW2) … HV2) -HV2 /2 width=2 by ldrop_drop/ #HV2
-    lapply (IHT1 (ⓓ{b}W2.U2) … HT1) -IHT1 /2 width=1 by cpx_bind/ -L1 #H
-    elim (aaa_inv_abbr … H) -H /3 width=3 by aaa_abbr, aaa_appl/
-  ]
-| #G #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HT1
-  elim (cpx_inv_cast1 … H) -H
-  [ * #V2 #T2 #HV12 #HT12 #H destruct /3 width=1 by aaa_cast/
-  | -IHV1 /2 width=1 by/
-  | -IHT1 /2 width=1 by/
-  ]
-]
-qed-.
-
-lemma aaa_cpx_conf: ∀h,g,G,L,T1,A. ⦃G, L⦄ ⊢ T1 ⁝ A → ∀T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 → ⦃G, L⦄ ⊢ T2 ⁝ A.
-/2 width=7 by aaa_cpx_llpx_conf/ qed-.
-
-lemma aaa_llpx_conf: ∀h,g,G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
-/2 width=7 by aaa_cpx_llpx_conf/ qed-.
-
-lemma aaa_cpr_conf: ∀G,L,T1,A. ⦃G, L⦄ ⊢ T1 ⁝ A → ∀T2. ⦃G, L⦄ ⊢ T1 ➡ T2 → ⦃G, L⦄ ⊢ T2 ⁝ A.
-/3 width=5 by aaa_cpx_conf, cpr_cpx/ qed-.
-(*
-lamma aaa_llpr_conf: ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A → ∀L2. ⦃G, L1⦄ ⊢ ➡[T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
-/3 width=5 by aaa_llpx_conf, llpr_llpx/ qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_ldrop.etc
deleted file mode 100644 (file)
index 3e4bcab..0000000
+++ /dev/null
@@ -1,90 +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_llpx_sn.ma".
-include "basic_2/reduction/cpx_lift.ma".
-include "basic_2/reduction/llpx.ma".
-
-(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma llpx_inv_lref_ge_dx: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
-                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
-                                    ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
-/2 width=5 by llpx_sn_inv_lref_ge_dx/ qed-.
-
-lemma llpx_inv_lref_ge_sn: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
-                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                    ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
-/2 width=5 by llpx_sn_inv_lref_ge_sn/ qed-.
-
-lemma llpx_inv_lref_ge_bi: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
-                           ∀I1,I2,K1,K2,V1,V2.
-                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           ∧∧ I1 = I2 & ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
-/2 width=8 by llpx_sn_inv_lref_ge_bi/ qed-.
-
-lemma llpx_inv_bind_O: ∀h,g,a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡ [h, g, ⓑ{a,I}V.T, 0] L2 →
-                       ⦃G, L1⦄ ⊢ ➡[h, g, V, 0] L2 ∧ ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V.
-/2 width=2 by llpx_sn_inv_bind_O/ qed-.
-
-lemma llpx_bind_repl_O: ∀h,g,I,G,L1,L2,V1,V2,T. ⦃G, L1.ⓑ{I}V1⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V2 →
-                        ∀J,W1,W2. ⦃G, L1⦄ ⊢ ➡[h, g, W1, 0] L2 → ⦃G, L1⦄ ⊢ W1 ➡[h, g] W2 → ⦃G, L1.ⓑ{J}W1⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{J}W2.
-/2 width=4 by llpx_sn_bind_repl_O/ qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma llpx_fwd_bind_O_dx: ∀h,g,a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, 0] L2 →
-                          ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V.
-/2 width=3 by llpx_sn_fwd_bind_O_dx/ qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma llpx_cpx_conf: ∀h,g,G. s_r_confluent1 … (cpx h g G) (llpx h g G 0).
-/3 width=10 by cpx_llpx_sn_conf, cpx_inv_lift1, cpx_lift/ qed-.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma llpx_ldrop_trans_O: ∀h,g,G,L1,L2,U. ⦃G, L1⦄ ⊢ ➡[h, g, U, 0] L2 →
-                          ∀K2,e. ⇩[e] L2 ≡ K2 → ∀T. ⇧[0, e] T ≡ U →
-                          ∃∃K1. ⇩[e] L1 ≡ K1 & ⦃G, K1⦄ ⊢ ➡[h, g, T, 0] K2.
-/2 width=5 by llpx_sn_ldrop_trans_O/ qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma llpx_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
-                      ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
-                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ⊃ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
-/3 width=7 by llpx_fwd_bind_O_dx, llpx_fwd_pair_sn,llpx_fwd_flat_dx, ex3_2_intro/
-[ #I #G1 #L1 #V1 #K1 #H elim (llpx_inv_lref_ge_dx … H) -H [5,6: // |2,3,4: skip ]
-  #Y1 #W1 #HKL1 #HW1 #HWV1 elim (lift_total V1 0 1)
-  /4 width=7 by llpx_cpx_conf, cpx_delta, fqu_drop, ldrop_fwd_drop2, ex3_2_intro/
-| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #L0 #HU1
-  elim (llpx_ldrop_trans_O … HU1 … HLK1) -L1
-  /3 width=5 by fqu_drop, ex3_2_intro/
-]
-qed-.
-
-lemma llpx_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
-                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
-                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ⊃⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #HKL1 elim (fquq_inv_gen … H) -H
-[ #HT12 elim (llpx_fqu_trans … HT12 … HKL1) /3 width=5 by fqu_fquq, ex3_2_intro/
-| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lleq.etc
deleted file mode 100644 (file)
index e936cc5..0000000
+++ /dev/null
@@ -1,31 +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_lleq.ma".
-include "basic_2/reduction/llpx.ma".
-
-(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
-
-(* Properties on lazy equivalence for local environments ********************)
-
-lemma llpx_lrefl: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
-/2 width=1 by llpx_sn_lrefl/ qed-.
-
-lemma lleq_llpx_trans: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 →
-                       ∀L.⦃G, L2⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L.
-/3 width=3 by lleq_cpx_trans, lleq_llpx_sn_trans/ qed-.
-
-lemma lleq_llpx_conf: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 →
-                      ∀L.⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L2⦄ ⊢ ➡[h, g, T, d] L.
-/3 width=3 by lleq_cpx_trans, lleq_llpx_sn_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpx_lpr.etc
deleted file mode 100644 (file)
index 6ceb64b..0000000
+++ /dev/null
@@ -1,25 +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_lpx_sn.ma".
-include "basic_2/reduction/lpr.ma".
-include "basic_2/reduction/llpx.ma".
-
-(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
-
-(* Properties on sn parallel reduction **************************************)
-
-(* Note: this should be moved *)
-lemma lpr_llpx: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
-/3 width=4 by cpr_cpx, lpx_sn_llpx_sn, llpx_sn_co/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs.etc
deleted file mode 100644 (file)
index 750d0b5..0000000
+++ /dev/null
@@ -1,89 +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/lazypredsnstar_7.ma".
-include "basic_2/reduction/llpx.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
-
-definition llpxs: ∀h. sd h → genv → relation4 ynat term lenv lenv ≝
-                  λh,g,G,d. LTC … (llpx h g G d).
-
-interpretation "lazy extended parallel computation (local environment, sn variant)"
-   'LazyPRedSnStar G L1 L2 h g T d = (llpxs h g G d T L1 L2).
-
-(* Basic eliminators ********************************************************)
-
-lemma llpxs_ind: ∀h,g,G,L1,T,d. ∀R:predicate lenv. R L1 →
-                 (∀L,L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡[h, g, T, d] L2 → R L → R L2) →
-                 ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → R L2.
-#h #g #G #L1 #T #d #R #HL1 #IHL1 #L2 #HL12
-@(TC_star_ind … HL1 IHL1 … HL12) //
-qed-.
-
-lemma llpxs_ind_dx: ∀h,g,G,L2,T,d. ∀R:predicate lenv. R L2 →
-                    (∀L1,L. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → R L → R L1) →
-                    ∀L1. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → R L1.
-#h #g #G #L2 #T #d #R #HL2 #IHL2 #L1 #HL12
-@(TC_star_ind_dx … HL2 IHL2 … HL12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma llpx_llpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-normalize /2 width=1 by inj/ qed.
-
-lemma llpxs_refl: ∀h,g,G,L,T,d. ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L.
-/2 width=1 by llpx_llpxs/ qed.
-
-lemma llpxs_strap1: ∀h,g,G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-normalize /2 width=3 by step/ qed.
-
-lemma llpxs_strap2: ∀h,g,G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-normalize /2 width=3 by TC_strap/ qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma llpxs_fwd_length: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → |L1| = |L2|.
-#h #g #G #L1 #L2 #T #d #H @(llpxs_ind … H) -L2
-/3 width=8 by llpx_fwd_length, trans_eq/
-qed-.
-
-(* Note: this might be moved *)
-lemma llpxs_fwd_bind_sn: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
-                         ⦃G, L1⦄ ⊢ ➡*[h, g, V, d] L2.
-#h #g #a #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
-/3 width=6 by llpx_fwd_bind_sn, llpxs_strap1/
-qed-.
-
-(* Note: this might be moved *)
-lemma llpxs_fwd_bind_dx: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
-                         ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡*[h, g, T, ⫯d] L2.ⓑ{I}V.
-#h #g #a #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
-/3 width=6 by llpx_fwd_bind_dx, llpxs_strap1/
-qed-.
-
-(* Note: this might be moved *)
-lemma llpxs_fwd_flat_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
-                         ⦃G, L1⦄ ⊢ ➡*[h, g, V, d] L2.
-#h #g #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
-/3 width=6 by llpx_fwd_flat_sn, llpxs_strap1/
-qed-.
-
-(* Note: this might be moved *)
-lemma llpxs_fwd_flat_dx: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
-                         ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-#h #g #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
-/3 width=6 by llpx_fwd_flat_dx, llpxs_strap1/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_aaa.etc
deleted file mode 100644 (file)
index ededb03..0000000
+++ /dev/null
@@ -1,31 +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/llpx_aaa.ma".
-include "basic_2/computation/llpxs.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
-
-(* Properties about atomic arity assignment on terms ************************)
-
-lemma aaa_llpxs_conf: ∀h,g,G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
-                      ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
-#h #g #G #L1 #T #A #HT #L2 #HL12
-@(TC_Conf3 … (λL,A. ⦃G, L⦄ ⊢ T ⁝ A) … HT ? HL12) /2 width=5 by aaa_llpx_conf/
-qed-.
-(*
-lamma aaa_llprs_conf: ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
-                      ∀L2. ⦃G, L1⦄ ⊢ ➡*[T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
-/3 width=5 by aaa_llpxs_conf, llprs_llpxs/ qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_cpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_cpxs.etc
deleted file mode 100644 (file)
index 35472d7..0000000
+++ /dev/null
@@ -1,172 +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_tc.ma".
-include "basic_2/computation/cpxs_llpx.ma".
-include "basic_2/computation/llpxs.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
-
-(* Advanced properties ******************************************************)
-
-lemma llpxs_pair_dx: ∀h,g,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 →
-                     ∀I,T. ⦃G, L.ⓑ{I}V1⦄ ⊢ ➡*[h, g, T, 0] L.ⓑ{I}V2.
-/2 width=1 by llpx_sn_TC_pair_dx/ qed.
-
-(* Properties on context-sensitive extended parallel computation for terms **)
-
-lemma llpxs_cpx_trans: ∀h,g,G. s_r_transitive … (cpx h g G) (llpxs h g G 0).
-/3 width=5 by s_r_trans_LTC2, llpx_cpxs_trans/ qed-.
-
-lemma llpxs_cpxs_trans: ∀h,g,G. s_rs_transitive … (cpx h g G) (llpxs h g G 0).
-#h #g #G @s_r_to_s_rs_trans @s_r_trans_LTC2
-/3 width=5 by llpx_cpxs_trans, s_rs_trans_TC1/ (**) (* full auto too slow *)
-qed-.
-
-(* Note: this is an instance of a general theorem *)
-lemma llpxs_cpxs_conf_dx: ∀h,g,G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡*[h, g] U2 →
-                          ∀L0. ⦃G2, L0⦄ ⊢ ➡*[h, g, T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[h, g, U2, O] L2.
-#h #g #G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llpxs_ind_dx … H) -L0 //
-#L0 #L #HL0 #HL2 #IHL2 @(llpxs_strap2 … IHL2) -IHL2
-lapply (llpxs_cpxs_trans … HTU2 … HL2) -L2 #HTU2
-/3 width=3 by llpx_cpxs_trans, cpxs_llpx_conf/
-qed-.
-
-(* Note: this is an instance of a general theorem *)
-lemma llpxs_cpx_conf_dx: ∀h,g,G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡[h, g] U2 →
-                         ∀L0. ⦃G2, L0⦄ ⊢ ➡*[h, g, T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[h, g, U2, O] L2.
-#h #g #G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llpxs_ind_dx … H) -L0 //
-#L0 #L #HL0 #HL2 #IHL2 @(llpxs_strap2 … IHL2) -IHL2
-lapply (llpxs_cpx_trans … HTU2 … HL2) -L2 #HTU2
-/3 width=3 by llpx_cpxs_trans, cpxs_llpx_conf/
-qed-.
-
-lemma cpxs_bind2: ∀h,g,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 →
-                  ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡*[h, g] T2 →
-                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡*[h, g] ⓑ{a,I}V2.T2.
-/4 width=5 by llpxs_cpxs_trans, llpxs_pair_dx, cpxs_bind/ qed.
-
-(* Advanced forward lemmas **************************************************)
-
-(* Note: this might be moved *)
-lemma llpxs_fwd_lref_ge_sn: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡*[h, g, #i, d] L2 → d ≤ i →
-                            ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                            ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
-                                     ⦃G, K1⦄ ⊢ ➡*[h, g, V2, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡*[h, g] V2.
-#h #g #G #L1 #L2 #d #i #H #Hdi #I #K1 #V1 #HLK1 @(llpxs_ind … H) -L2 /2 width=5 by ex3_2_intro/ -HLK1
-#L #L2 #_ #HL2 * #K #V #HLK #HK1 #HV1 elim (llpx_inv_lref_ge_sn … HL2 … HLK) // -HL2 -HLK -Hdi
-#K2 #V2 #HLK2 #HK2 #HV2
-@(ex3_2_intro … HLK2) -HLK2
-[ /3 width=5 by llpxs_cpx_conf_dx, llpxs_strap1, llpx_cpx_conf/
-| /3 width=5 by llpxs_cpx_trans, cpxs_trans/
-]
-qed-.
-
-(* Inversion lemmas on context-sensitive ext parallel computation for terms *)
-
-lemma cpxs_inv_abst1: ∀h,g,a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓛ{a}V1.T1 ➡*[h, g] U2 →
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 & ⦃G, L.ⓛV1⦄ ⊢ T1 ➡*[h, g] T2 &
-                               U2 = ⓛ{a}V2.T2.
-#h #g #a #G #L #V1 #T1 #U2 #H @(cpxs_ind … H) -U2 /2 width=5 by ex3_2_intro/
-#U0 #U2 #_ #HU02 * #V0 #T0 #HV10 #HT10 #H destruct
-elim (cpx_inv_abst1 … HU02) -HU02 #V2 #T2 #HV02 #HT02 #H destruct
-lapply (llpxs_cpx_trans … HT02 (L.ⓛV1) ?)
-/3 width=5 by llpxs_pair_dx, cpxs_trans, cpxs_strap1, ex3_2_intro/
-qed-.
-
-lemma cpxs_inv_abbr1: ∀h,g,a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓓ{a}V1.T1 ➡*[h, g] U2 → (
-                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 & ⦃G, L.ⓓV1⦄ ⊢ T1 ➡*[h, g] T2 &
-                               U2 = ⓓ{a}V2.T2
-                      ) ∨
-                      ∃∃T2. ⦃G, L.ⓓV1⦄ ⊢ T1 ➡*[h, g] T2 & ⇧[0, 1] U2 ≡ T2 & a = true.
-#h #g #a #G #L #V1 #T1 #U2 #H @(cpxs_ind … H) -U2 /3 width=5 by ex3_2_intro, or_introl/
-#U0 #U2 #_ #HU02 * *
-[ #V0 #T0 #HV10 #HT10 #H destruct
-  elim (cpx_inv_abbr1 … HU02) -HU02 *
-  [ #V2 #T2 #HV02 #HT02 #H destruct
-    lapply (llpxs_cpx_trans … HT02 (L.ⓓV1) ?)
-    /4 width=5 by llpxs_pair_dx, cpxs_trans, cpxs_strap1, ex3_2_intro, or_introl/
-  | #T2 #HT02 #HUT2
-    lapply (llpxs_cpx_trans … HT02 (L.ⓓV1) ?) -HT02
-    /4 width=3 by llpxs_pair_dx, cpxs_trans, ex3_intro, or_intror/
-  ]
-| #U1 #HTU1 #HU01
-  elim (lift_total U2 0 1) #U #HU2
-  /6 width=12 by cpxs_strap1, cpx_lift, ldrop_drop, ex3_intro, or_intror/
-]
-qed-.
-
-(* Properties on supclosure *************************************************)
-
-lemma llpx_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
-                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
-                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃+ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
-[ #G2 #L2 #T2 #H12 #K1 #HKL1 elim (llpx_fqu_trans … H12 … HKL1) -L1
-  /3 width=5 by cpx_cpxs, fqu_fqup, ex3_2_intro/
-| #G #G2 #L #L2 #T #T2 #_ #H2 #IH1 #K1 #HLK1 elim (IH1 … HLK1) -L1
-  #L0 #T0 #HT10 #HT0 #HL0 elim (llpx_fqu_trans … H2 … HL0) -L
-  #L #T3 #HT3 #HT32 #HL2 elim (fqup_cpx_trans … HT0 … HT3) -T
-  /3 width=7 by cpxs_strap1, fqup_strap1, ex3_2_intro/
-]
-qed-.
-
-lemma llpx_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
-                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
-                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃* ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqus_ind … H) -G2 -L2 -T2 /2 width=5 by ex3_2_intro/
-#G #G2 #L #L2 #T #T2 #_ #H2 #IH1 #K1 #HLK1 elim (IH1 … HLK1) -L1
-#L0 #T0 #HT10 #HT0 #HL0 elim (llpx_fquq_trans … H2 … HL0) -L
-#L #T3 #HT3 #HT32 #HL2 elim (fqus_cpx_trans … HT0 … HT3) -T
-/3 width=7 by cpxs_strap1, fqus_strap1, ex3_2_intro/
-qed-.
-
-lemma llpxs_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
-                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
-                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
-[ /2 width=5 by ex3_2_intro/
-| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
-  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
-  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
-  elim (llpx_fquq_trans … HT2 … HK1) -K
-  /3 width=7 by llpxs_strap2, cpxs_strap1, ex3_2_intro/
-]
-qed-.
-
-lemma llpxs_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
-                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
-                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃+ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
-[ /2 width=5 by ex3_2_intro/
-| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
-  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
-  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
-  elim (llpx_fqup_trans … HT2 … HK1) -K
-  /3 width=7 by llpxs_strap2, cpxs_trans, ex3_2_intro/
-]
-qed-.
-
-lemma llpxs_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
-                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
-                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃* ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
-#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
-[ /2 width=5 by ex3_2_intro/
-| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
-  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
-  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
-  elim (llpx_fqus_trans … HT2 … HK1) -K
-  /3 width=7 by llpxs_strap2, cpxs_trans, ex3_2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lleq.etc
deleted file mode 100644 (file)
index a38ba39..0000000
+++ /dev/null
@@ -1,66 +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_leq.ma".
-include "basic_2/reduction/llpx_lleq.ma".
-include "basic_2/computation/cpxs_lleq.ma".
-include "basic_2/computation/llpxs_cpxs.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS *************)
-
-(* Properties on lazy equivalence for local environments ********************)
-
-lemma llpxs_lrefl: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-/3 width=1 by llpx_lrefl, llpx_llpxs/ qed-.
-
-lemma lleq_llpxs_trans: ∀h,g,G,L2,L,T,d. ⦃G, L2⦄ ⊢ ➡*[h, g, T, d] L →
-                        ∀L1. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L.
-#h #g #G #L2 #L #T #d #H @(llpxs_ind … H) -L
-/3 width=3 by llpxs_strap1, llpxs_lrefl/
-qed-.
-
-lemma lleq_llpxs_conf: ∀h,g,G,L1,L,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L →
-                       ∀L2. L1 ⋕[T, d] L2 → ⦃G, L2⦄ ⊢ ➡*[h, g, T, d] L.
-/3 width=3 by lleq_llpxs_trans, lleq_sym/ qed-.
-(*
-foct 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 &
-                                   (∀T. L0 ⋕[T, d] L2 ↔ L1 ⋕[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/
-| #I1 #I0 #L1 #L0 #V1 #V0 #_ #_ #He destruct
-| #I #L1 #L0 #V1 #e #HL10 #IHL10 #He #Y #H
-  elim (lpxs_inv_pair1 … H) -H #L2 #V2 #HL02 #HV02 #H destruct
-  lapply (ysucc_inv_Y_dx … He) -He #He
-  elim (IHL10 … HL02) // -IHL10 -HL02 #L #HL2 #HL1 #IH
-  @(ex3_intro … (L.ⓑ{I}V2)) /3 width=3 by lpxs_pair, leq_cpxs_trans, leq_pair/
-  #T elim (IH T) #HL0dx #HL0sn
-  @conj #H @(lleq_leq_repl … H) -H /3 width=1 by leq_sym, leq_pair_O_Y/
-| #I1 #I0 #L1 #L0 #V1 #V0 #d #e #HL10 #IHL10 #He #Y #H
-  elim (lpxs_inv_pair1 … H) -H #L2 #V2 #HL02 #HV02 #H destruct
-  elim (IHL10 … HL02) // -IHL10 -HL02 #L #HL2 #HL1 #IH
-  @(ex3_intro … (L.ⓑ{I1}V1)) /3 width=1 by lpxs_pair, leq_succ/
-  #T elim (IH T) #HL0dx #HL0sn
-  @conj #H @(lleq_leq_repl … H) -H /3 width=1 by leq_sym, leq_succ/
-]
-qed-.
-
-lamma 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 &
-                                (∀T. L0 ⋕[T, d] L2 ↔ L1 ⋕[T, d] L).
-/2 width=1 by leq_lpxs_trans_lleq_aux/ qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_llpxs.etc
deleted file mode 100644 (file)
index d316c52..0000000
+++ /dev/null
@@ -1,22 +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/computation/llpxs.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
-
-(* Main properties **********************************************************)
-
-theorem llpxs_trans: ∀h,g,G,T,d. Transitive … (llpxs h g G d T).
-normalize /2 width=3 by trans_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llpxs_lprs.etc
deleted file mode 100644 (file)
index 32d7bbc..0000000
+++ /dev/null
@@ -1,25 +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/llpx_lpr.ma".
-include "basic_2/computation/lprs.ma".
-include "basic_2/computation/llpxs.ma".
-
-(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
-
-(* Properties on sn parallel computation ************************************)
-
-(* Note: this should be moved *)
-lemma lprs_llpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡* L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
-normalize /3 width=3 by lpr_llpx, monotonic_TC/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx.etc
deleted file mode 100644 (file)
index 286d064..0000000
+++ /dev/null
@@ -1,57 +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/lazysn_6.ma".
-include "basic_2/substitution/lleq.ma".
-include "basic_2/reduction/llpx.ma".
-
-(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
-
-definition llsx: ∀h. sd h → relation4 ynat term genv lenv ≝
-                 λh,g,d,T,G. SN … (llpx h g G d T) (lleq d T).
-
-interpretation
-   "lazy extended strong normalization (local environment)"
-   'LazySN h g d T G L = (llsx h g T d G L).
-
-(* Basic eliminators ********************************************************)
-
-lemma llsx_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
-                (∀L1. G ⊢ ⋕⬊*[h, g, T, d] L1 →
-                      (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
-                      R L1
-                ) →
-                ∀L. G ⊢ ⋕⬊*[h, g, T, d] L → R L.
-#h #g #G #T #d #R #H0 #L1 #H elim H -L1
-/5 width=1 by lleq_sym, SN_intro/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma llsx_intro: ∀h,g,G,L1,T,d.
-                  (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊*[h, g, T, d] L2) →
-                  G ⊢ ⋕⬊*[h, g, T, d] L1.
-/5 width=1 by lleq_sym, SN_intro/ qed.
-
-lemma llsx_sort: ∀h,g,G,L,d,k. G ⊢ ⋕⬊*[h, g, ⋆k, d] L.
-#h #g #G #L1 #d #k @llsx_intro
-#L2 #HL12 #H elim H -H
-/3 width=6 by llpx_fwd_length, lleq_sort/
-qed.
-
-lemma llsx_gref: ∀h,g,G,L,d,p. G ⊢ ⋕⬊*[h, g, §p, d] L.
-#h #g #G #L1 #d #p @llsx_intro
-#L2 #HL12 #H elim H -H
-/3 width=6 by llpx_fwd_length, lleq_gref/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_alt.etc
deleted file mode 100644 (file)
index 0d23439..0000000
+++ /dev/null
@@ -1,107 +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/lazysnalt_6.ma".
-include "basic_2/substitution/lleq_lleq.ma".
-include "basic_2/computation/llpxs_lleq.ma".
-include "basic_2/computation/llsx.ma".
-
-(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
-
-(* alternative definition of llsx *)
-definition llsxa: ∀h. sd h → relation4 ynat term genv lenv ≝
-                  λh,g,d,T,G. SN … (llpxs h g G d T) (lleq d T).
-
-interpretation
-   "lazy extended strong normalization (local environment) alternative"
-   'LazySNAlt h g d T G L = (llsxa h g T d G L).
-
-(* Basic eliminators ********************************************************)
-
-lemma llsxa_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
-                 (∀L1. G ⊢ ⋕⬊⬊*[h, g, T, d] L1 →
-                       (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
-                       R L1
-                 ) →
-                 ∀L. G ⊢ ⋕⬊⬊*[h, g, T, d] L → R L.
-#h #g #G #T #d #R #H0 #L1 #H elim H -L1
-/5 width=1 by lleq_sym, SN_intro/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma llsxa_intro: ∀h,g,G,L1,T,d.
-                   (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[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 llsxa_intro_aux: ∀h,g,G,L1,T,d.
-                      (∀L,L2. ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → L1 ⋕[T, d] L → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊⬊*[h, g, T, d] L2) →
-                      G ⊢ ⋕⬊⬊*[h, g, T, d] L1.
-/4 width=3 by llsxa_intro/ qed-.
-
-lemma llsxa_llpxs_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊⬊*[h, g, T, d] L1 →
-                         ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → G ⊢ ⋕⬊⬊*[h, g, T, d] L2.
-#h #g #G #L1 #T #d #H @(llsxa_ind … H) -L1 #L1 #HL1 #IHL1 #L2 #HL12 @llsxa_intro
-elim (lleq_dec T L1 L2 d) /4 width=4 by lleq_llpxs_trans, lleq_canc_sn/
-qed-.
-
-lemma llsxa_intro_llpx: ∀h,g,G,L1,T,d.
-                        (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊⬊*[h, g, T, d] L2) →
-                        G ⊢ ⋕⬊⬊*[h, g, T, d] L1.
-#h #g #G #L1 #T #d #IH @llsxa_intro_aux
-#L #L2 #H @(llpxs_ind_dx … H) -L
-[ #H destruct #H elim H //
-| #L0 #L elim (lleq_dec T L1 L d)
-  /4 width=3 by llsxa_llpxs_trans, lleq_llpx_trans/
-]
-qed.
-
-(* Main properties **********************************************************)
-
-theorem llsx_llsxa: ∀h,g,G,L,T,d. G ⊢ ⋕⬊*[h, g, T, d] L → G ⊢ ⋕⬊⬊*[h, g, T, d] L.
-#h #g #G #L #T #d #H @(llsx_ind … H) -L
-/4 width=1 by llsxa_intro_llpx/
-qed.
-
-(* Main inversion lemmas ****************************************************)
-
-theorem llsxa_inv_llsx: ∀h,g,G,L,T,d. G ⊢ ⋕⬊⬊*[h, g, T, d] L → G ⊢ ⋕⬊*[h, g, T, d] L.
-#h #g #G #L #T #d #H @(llsxa_ind … H) -L
-/4 width=1 by llsx_intro, llpx_llpxs/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma llsx_intro_alt: ∀h,g,G,L1,T,d.
-                      (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊*[h, g, T, d] L2) →
-                      G ⊢ ⋕⬊*[h, g, T, d] L1.
-/6 width=1 by llsxa_inv_llsx, llsx_llsxa, llsxa_intro/ qed.
-
-lemma llsx_llpxs_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊*[h, g, T, d] L1 →
-                        ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → G ⊢ ⋕⬊*[h, g, T, d] L2.
-/4 width=3 by llsxa_inv_llsx, llsx_llsxa, llsxa_llpxs_trans/
-qed-.
-
-(* Advanced eliminators *****************************************************)
-
-lemma llsx_ind_alt: ∀h,g,G,T,d. ∀R:predicate lenv.
-                    (∀L1. G ⊢ ⋕⬊*[h, g, T, d] L1 →
-                          (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
-                          R L1
-                    ) →
-                    ∀L. G ⊢ ⋕⬊*[h, g, T, d] L → R L.
-#h #g #G #T #d #R #IH #L #H @(llsxa_ind h g G T d … L)
-/4 width=1 by llsxa_inv_llsx, llsx_llsxa/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_csx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_csx.etc
deleted file mode 100644 (file)
index 9c28473..0000000
+++ /dev/null
@@ -1,96 +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/computation/csx_lift.ma".
-include "basic_2/computation/csx_llpxs.ma".
-include "basic_2/computation/llsx_ldrop.ma".
-include "basic_2/computation/llsx_llpx.ma".
-include "basic_2/computation/llsx_llpxs.ma".
-(*
-axiom cpx_llpx_trans: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                      ∀L2. ⦃G, L1⦄⊢ ➡[h, g, T2, O] L2 → 
-                      ∃∃L. ⦃G, L1⦄⊢ ➡[h, g, T1, O] L & L ⋕[T2, 0] L2.
-(*
-fact llsx_cpx_trans_aux: ∀h,g,G,L0,T1,T2. ⦃G, L0⦄ ⊢ T1 ➡[h, g] T2 →
-                         ∀L1,d. G ⊢ ⋕⬊*[h, g, T1, d] L1 → d = 0 → 
-                         L0 ⋕[T1, d] L1 → ∀L2. L1 ⋕[T2, d] L2 →
-                         G ⊢ ⋕⬊*[h, g, T2, d] L2.
-#h #g #G #L0 #T1 #T2 #HT12 #L1 #d #H @(llsx_ind … H) -L1
-#L1 #_ #IHL1 #Hd #He011 #L2 #He122 @llsx_intro
-#L3 #Hx223 #Hn223 destruct
-lapply (lleq_cpx_conf_sn … HT12 … He011) #He021
-lapply (lleq_cpx_conf … HT12 … He011) -HT12 #HT12
-lapply (lleq_llpx_trans … He122 … Hx223) -Hx223 #Hx123
-elim (cpx_llpx_trans … HT12 … Hx123) -Hx123 #L4 #Hx114 #He423
-(* lapply (lleq_cpx_conf … Hx114 … He011) #He120 *)
-@(IHL1 … Hx114) // -IHL1
-[ #HL13 @HnL2 -HnL2  
-*)
-
-fact llsx_cpx_trans_aux: ∀h,g,G,L1,T1,d. G ⊢ ⋕⬊*[h, g, T1, d] L1 → d = 0 →
-                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
-                         ∀L2. L1 ⋕[T1, d] L2 → G ⊢ ⋕⬊*[h, g, T2, 0] L2.
-#h #g #G #L1 #T1 #d #H @(llsx_ind … H) -L1
-#L1 #_ #IHL1 #Hd #T2 #HT12 #L2 #He112 @llsx_intro
-#L3 #Hx223 #Hn223 destruct
-lapply (lleq_cpx_conf_sn … HT12 … He112) #He122
-lapply (lleq_cpx_conf … HT12 … He112) -HT12 #HT12
-elim (cpx_llpx_trans … HT12 … Hx223) #L4 #Hx214 #He423
-@(IHL1 … L4) //
-*)
-axiom llsx_cpx_trans_O: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 →
-                        G ⊢ ⋕⬊*[h, g, T1, 0] L → G ⊢ ⋕⬊*[h, g, T2, 0] L.
-
-(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
-
-(* Advanced properties ******************************************************)
-
-lemma llsx_lref_be_lpxs: ∀h,g,I,G,K1,V,i,d. d ≤ yinj i → ⦃G, K1⦄ ⊢ ⬊*[h, g] V →
-                         ∀K2. G ⊢ ⋕⬊*[h, g, V, 0] K2 → ⦃G, K1⦄ ⊢ ➡*[h, g, V, 0] K2 →
-                         ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V → G ⊢ ⋕⬊*[h, g, #i, d] L2.
-#h #g #I #G #K1 #V #i #d #Hdi #H @(csx_ind_alt … H) -V
-#V0 #_ #IHV0 #K2 #H @(llsx_ind … H) -K2
-#K0 #HK0 #IHK0 #HK10 #L0 #HLK0 @llsx_intro
-#L2 #HL02 #HnL02 elim (llpx_inv_lref_ge_sn … HL02 … HLK0) // -HL02
-#K2 #V2 #HLK2 #HK02 #HV02 elim (eq_term_dec V0 V2)
-#HnV02 destruct [ -IHV0 -HV02 -HK0 | -IHK0 -HnL02 -HLK0 ]
-[ /4 width=7 by llpxs_strap1, lleq_lref/
-| lapply (llpx_cpx_conf … HV02 … HK02) -HK02 #HK02
-  @(IHV0 … HnV02 … HLK2) -IHV0 -HnV02 -HLK2
-  /3 width=3 by llsx_cpx_trans_O, llpxs_cpx_conf_dx, llsx_llpx_trans, llpxs_cpx_trans, llpxs_strap1/
-]
-qed.
-
-lemma llsx_lref_be: ∀h,g,I,G,K,V,i,d. d ≤ yinj i → ⦃G, K⦄ ⊢ ⬊*[h, g] V →
-                    G ⊢ ⋕⬊*[h, g, V, 0] K →
-                    ∀L. ⇩[i] L ≡ K.ⓑ{I}V → G ⊢ ⋕⬊*[h, g, #i, d] L.
-/2 width=8 by llsx_lref_be_lpxs/ qed.
-
-(* Main properties **********************************************************)
-
-theorem csx_llsx: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ∀d. G ⊢ ⋕⬊*[h, g, T, d] L.
-#h #g #G #L #T @(fqup_wf_ind_eq … G L T) -G -L -T
-#Z #Y #X #IH #G #L * * //
-[ #i #HG #HL #HT #H #d destruct
-  elim (lt_or_ge i (|L|)) /2 width=1 by llsx_lref_free/
-  elim (ylt_split i d) /2 width=1 by llsx_lref_skip/
-  #Hdi #Hi elim (ldrop_O1_lt … Hi) -Hi
-  #I #K #V #HLK lapply (csx_inv_lref_bind … HLK … H) -H
-  /4 width=6 by llsx_lref_be, fqup_lref/
-| #a #I #V #T #HG #HL #HT #H #d destruct
-  elim (csx_fwd_bind … H) -H /3 width=1 by llsx_bind/
-| #I #V #T #HG #HL #HT #H #d destruct
-  elim (csx_fwd_flat … H) -H /3 width=1 by llsx_flat/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_ldrop.etc
deleted file mode 100644 (file)
index 2d16e32..0000000
+++ /dev/null
@@ -1,32 +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_ldrop.ma".
-include "basic_2/computation/llsx.ma".
-
-(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
-
-(* Advanced properties ******************************************************)
-
-lemma llsx_lref_free: ∀h,g,G,L,d,i. |L| ≤ i → G ⊢ ⋕⬊*[h, g, #i, d] L.
-#h #g #G #L1 #d #i #HL1 @llsx_intro
-#L2 #HL12 #H elim H -H
-/4 width=8 by llpx_fwd_length, lleq_free, le_repl_sn_conf_aux/
-qed.
-
-lemma llsx_lref_skip: ∀h,g,G,L,d,i. yinj i < d → G ⊢ ⋕⬊*[h, g, #i, d] L.
-#h #g #G #L1 #d #i #HL1 @llsx_intro
-#L2 #HL12 #H elim H -H
-/3 width=6 by llpx_fwd_length, lleq_skip/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpx.etc
deleted file mode 100644 (file)
index 9392afb..0000000
+++ /dev/null
@@ -1,27 +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_lleq.ma".
-include "basic_2/reduction/llpx_lleq.ma".
-include "basic_2/computation/llsx.ma".
-
-(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
-
-(* Advanced properties ******************************************************)
-
-lemma llsx_llpx_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊*[h, g, T, d] L1 →
-                       ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → G ⊢ ⋕⬊*[h, g, T, d] L2.
-#h #g #G #L1 #T #d #H @(llsx_ind … H) -L1 #L1 #HL1 #IHL1 #L2 #HL12 @llsx_intro
-elim (lleq_dec T L1 L2 d) /4 width=4 by lleq_llpx_trans, lleq_canc_sn/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx/llsx_llpxs.etc
deleted file mode 100644 (file)
index af37a37..0000000
+++ /dev/null
@@ -1,66 +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/computation/llpxs_llpxs.ma".
-include "basic_2/computation/llsx_alt.ma".
-
-(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
-
-(* Advanced properties ******************************************************)
-
-fact llsx_bind_llpxs_aux: ∀h,g,a,I,G,L1,V,d. G ⊢ ⋕⬊*[h, g, V, d] L1 →
-                          ∀Y,T. G ⊢ ⋕⬊*[h, g, T, ⫯d] Y →
-                          ∀L2. Y = L2.ⓑ{I}V → ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
-                          G ⊢ ⋕⬊*[h, g, ⓑ{a,I}V.T, d] L2.
-#h #g #a #I #G #L1 #V #d #H @(llsx_ind_alt … H) -L1
-#L1 #HL1 #IHL1 #Y #T #H @(llsx_ind_alt … H) -Y
-#Y #HY #IHY #L2 #H #HL12 destruct @llsx_intro_alt
-#L0 #HL20 lapply (llpxs_fwd_bind_dx … HL20)
-lapply (llpxs_trans … HL12 … HL20)
-#HL10 #HT #H elim (nlleq_inv_bind … H) -H [ -HL1 -IHY | -HY -IHL1 ]
-[ #HnV elim (lleq_dec V L1 L2 d)
-  [  -HL20 #HV @(IHL1 … L0)
-     /3 width=4 by llsx_llpxs_trans, llpxs_fwd_bind_sn, lleq_canc_sn/ (**) (* full auto too slow *)
-  | -HnV -HL10
-     /3 width=4 by llsx_llpxs_trans, llpxs_fwd_bind_sn/
-  ]
-| /3 width=4 by/
-]
-qed-.
-
-lemma llsx_bind: ∀h,g,a,I,G,L,V,d. G ⊢ ⋕⬊*[h, g, V, d] L →
-                 ∀T. G ⊢ ⋕⬊*[h, g, T, ⫯d] L.ⓑ{I}V →
-                 G ⊢ ⋕⬊*[h, g, ⓑ{a,I}V.T, d] L.
-/2 width=3 by llsx_bind_llpxs_aux/ qed.
-
-lemma llsx_flat_llpxs: ∀h,g,I,G,L1,V,d. G ⊢ ⋕⬊*[h, g, V, d] L1 →
-                       ∀L2,T. G ⊢ ⋕⬊*[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
-                       G ⊢ ⋕⬊*[h, g, ⓕ{I}V.T, d] L2.
-#h #g #I #G #L1 #V #d #H @(llsx_ind_alt … H) -L1
-#L1 #HL1 #IHL1 #L2 #T #H @(llsx_ind_alt … H) -L2
-#L2 #HL2 #IHL2 #HL12 @llsx_intro_alt
-#L0 #HL20 lapply (llpxs_fwd_flat_dx … HL20)
-lapply (llpxs_trans … HL12 … HL20)
-#HL10 #HT #H elim (nlleq_inv_flat … H) -H [ -HL1 -IHL2 | -HL2 -IHL1 ]
-[ #HnV elim (lleq_dec V L1 L2 d)
-  [ #HV @(IHL1 … L0) /3 width=3 by llsx_llpxs_trans, llpxs_fwd_flat_sn, lleq_canc_sn/ (**) (* full auto too slow: 47s *)
-  | -HnV -HL10 /3 width=4 by llsx_llpxs_trans, llpxs_fwd_flat_sn/
-  ]
-| /3 width=1 by/
-]
-qed-.
-
-lemma llsx_flat: ∀h,g,I,G,L,V,d. G ⊢ ⋕⬊*[h, g, V, d] L →
-                 ∀T. G ⊢ ⋕⬊*[h, g, T, d] L → G ⊢ ⋕⬊*[h, g, ⓕ{I}V.T, d] L.
-/2 width=3 by llsx_flat_llpxs/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/llpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/llpx_sn_tc.etc
deleted file mode 100644 (file)
index 682b48c..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/relocation/ldrop_leq.ma".
-include "basic_2/relocation/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-definition TC_llpx_sn_confluent1: relation (relation3 lenv term term) ≝ λS,R.
-                                  ∀Ls,T1,T2. S Ls T1 T2 →
-                                  ∀Ld. TC … (llpx_sn R 0 T1) Ls Ld → TC … (llpx_sn R 0 T2) Ls Ld.
-
-lemma TC_llpx_sn_s_confluent: ∀S,R. (llpx_sn_confluent1 S R) → TC_llpx_sn_confluent1 S R.
-#S #R #HSR #Ls #T1 #T2 #HT12 #Ld #H
-generalize in match HT12; -HT12
-@(TC_ind_dx … Ls H) -Ls
-[ /3 width=3 by inj/
-| #Ls #L #HLs #_ #IHLd #HT12
-  @(TC_strap … L) /2 width=3 by/ @IHLd -IHLd
-
-lemma TC_llpx_sn_lref_refl: ∀R. (∀L.reflexive … (R L)) →
-                            ∀I,L1,K1,K2,V,d,i. d ≤ yinj i → ⇩[i] L1 ≡ K1.ⓑ{I}V →
-                            TC lenv (llpx_sn R 0 V) K1 K2 →
-                            ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V → TC … (llpx_sn R d (#i)) L1 L2.
-#R #HR #I #L1 #K1 #K2 #V #d #i #Hdi #HLK1 #H @(TC_star_ind … K2 H) -K2
-[ /2 width=1 by llpx_sn_refl/
-| /4 width=9 by llpx_sn_refl, llpx_sn_lref, inj/
-| #K #K2 #_ #HV #IHK1 #L2 #HLK2 lapply (ldrop_fwd_length … HLK2)
-  #H elim (ldrop_O1_ex (K.ⓑ{I}V) i L2) [2: normalize in H ⊢ %; >(llpx_sn_fwd_length … HV) ]
-  /4 width=11 by llpx_sn_lref, step/
-]
-qed-.
-
-lemma TC_llpx_sn_lref: ∀R. (∀L.reflexive … (R L)) → (llpx_sn_confluent1 R R) →
-                       ∀I,K1,V1,V2,d,i. d ≤ yinj i → LTC … R K1 V1 V2 →
-                       ∀K2. TC lenv (llpx_sn R 0 V1) K1 K2 → ∀L1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                       ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 → TC … (llpx_sn R d (#i)) L1 L2.
-#R #H1R #H2R #I #K1 #V1 #V2 #d #i #Hdi #H @(TC_star_ind_dx … V1 H) -V1
-[ /2 width=1 by llpx_sn_refl/
-| /2 width=7 by TC_llpx_sn_lref_refl/
-| #V1 #V #HV1 #_ #IHV2 #K2 #HK12 #L1 #HLK1 #L2 #HLK2
-  lapply (ldrop_fwd_length … HLK1)
-  #H elim (ldrop_O1_ex (K1.ⓑ{I}V) i L1) [2: normalize in H ⊢ %; // ] -H
-  #L #_ #HLK @(TC_strap … L)
-  [ @(llpx_sn_lref … HLK1 … HLK) /2 width=1 by llpx_sn_refl/
-  | @(IHV2 … HLK … HLK2)
-    -HLK1 -HLK2 -HLK -IHV2 -Hdi @(TC_llpx_sn_s_confluent R R … HK12) //
-  ]
-]
-
-
-lemma llpx_sn_LTC_TC_llpx_sn: ∀R. (∀L. reflexive … (R L)) →
-                              ∀L1,L2,T,d. llpx_sn (LTC … R) d T L1 L2 →
-                              TC … (llpx_sn R d T) L1 L2.
-#R #HR #L1 #L2 #T #d #H elim H -L1 -L2
-/3 width=3 by llpx_sn_gref, llpx_sn_free, llpx_sn_skip, llpx_sn_sort, inj/
-[ #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #_ #HV12 #IHV1   
-
-(* Properties on transitive_closure *****************************************)
-
-lemma TC_lpx_sn_pair: ∀R. (∀L. reflexive … (R L)) →
-                      ∀I,L1,L2. TC … (lpx_sn R) L1 L2 →
-                      ∀V1,V2. LTC … R L1 V1 V2 →
-                      TC … (lpx_sn R) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2).
-#R #HR #I #L1 #L2 #HL12 #V1 #V2 #H @(TC_star_ind_dx … V1 H) -V1 //
-[ /2 width=1 by TC_lpx_sn_pair_refl/
-| /4 width=3 by TC_strap, lpx_sn_pair, lpx_sn_refl/
-]
-qed-.
-
-lemma lpx_sn_LTC_TC_lpx_sn: ∀R. (∀L. reflexive … (R L)) →
-                            ∀L1,L2. lpx_sn (LTC … R) L1 L2 →
-                            TC … (lpx_sn R) L1 L2.
-#R #HR #L1 #L2 #H elim H -L1 -L2
-/2 width=1 by TC_lpx_sn_pair, lpx_sn_atom, inj/
-qed-.
-
-(* Inversion lemmas on transitive closure ***********************************)
-
-lemma TC_lpx_sn_inv_atom2: ∀R,L1. TC … (lpx_sn R) L1 (⋆) → L1 = ⋆.
-#R #L1 #H @(TC_ind_dx … L1 H) -L1
-[ /2 width=2 by lpx_sn_inv_atom2/
-| #L1 #L #HL1 #_ #IHL2 destruct /2 width=2 by lpx_sn_inv_atom2/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_pair2: ∀R. s_rs_trans … R (lpx_sn R) →
-                           ∀I,L1,K2,V2. TC  … (lpx_sn R) L1 (K2.ⓑ{I}V2) →
-                           ∃∃K1,V1. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L1 = K1. ⓑ{I} V1.
-#R #HR #I #L1 #K2 #V2 #H @(TC_ind_dx … L1 H) -L1
-[ #L1 #H elim (lpx_sn_inv_pair2 … H) -H /3 width=5 by inj, ex3_2_intro/
-| #L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
-  elim (lpx_sn_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct
-  lapply (HR … HV2 … HK1) -HR -HV2 /3 width=5 by TC_strap, ex3_2_intro/
-]
-qed-.
-
-lemma TC_lpx_sn_ind: ∀R. s_rs_trans … R (lpx_sn R) →
-                     ∀S:relation lenv.
-                     S (⋆) (⋆) → (
-                        ∀I,K1,K2,V1,V2.
-                        TC … (lpx_sn R) K1 K2 → LTC … R K1 V1 V2 →
-                        S K1 K2 → S (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
-                     ) →
-                     ∀L2,L1. TC … (lpx_sn R) L1 L2 → S L1 L2.
-#R #HR #S #IH1 #IH2 #L2 elim L2 -L2
-[ #X #H >(TC_lpx_sn_inv_atom2 … H) -X //
-| #L2 #I #V2 #IHL2 #X #H
-  elim (TC_lpx_sn_inv_pair2 … H) // -H -HR
-  #L1 #V1 #HL12 #HV12 #H destruct /3 width=1 by/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_atom1: ∀R,L2. TC … (lpx_sn R) (⋆) L2 → L2 = ⋆.
-#R #L2 #H elim H -L2
-[ /2 width=2 by lpx_sn_inv_atom1/
-| #L #L2 #_ #HL2 #IHL1 destruct /2 width=2 by lpx_sn_inv_atom1/
-]
-qed-.
-
-fact TC_lpx_sn_inv_pair1_aux: ∀R. s_rs_trans … R (lpx_sn R) →
-                              ∀L1,L2. TC … (lpx_sn R) L1 L2 →
-                              ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
-                              ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L2 = K2. ⓑ{I} V2.
-#R #HR #L1 #L2 #H @(TC_lpx_sn_ind … H) // -HR -L1 -L2
-[ #J #K #W #H destruct
-| #I #L1 #L2 #V1 #V2 #HL12 #HV12 #_ #J #K #W #H destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_pair1: ∀R. s_rs_trans … R (lpx_sn R) →
-                           ∀I,K1,L2,V1. TC … (lpx_sn R) (K1.ⓑ{I}V1) L2 →
-                           ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L2 = K2. ⓑ{I} V2.
-/2 width=3 by TC_lpx_sn_inv_pair1_aux/ qed-.
-
-lemma TC_lpx_sn_inv_lpx_sn_LTC: ∀R. s_rs_trans … R (lpx_sn R) →
-                                ∀L1,L2. TC … (lpx_sn R) L1 L2 →
-                                lpx_sn (LTC … R) L1 L2.
-/3 width=4 by TC_lpx_sn_ind, lpx_sn_pair/ qed-.
-
-(* Forward lemmas on transitive closure *************************************)
-
-lemma TC_lpx_sn_fwd_length: ∀R,L1,L2. TC … (lpx_sn R) L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H -L2
-[ #L2 #HL12 >(lpx_sn_fwd_length … HL12) -HL12 //
-| #L #L2 #_ #HL2 #IHL1
-  >IHL1 -L1 >(lpx_sn_fwd_length … HL2) -HL2 //
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/lpx_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/llpx_sn/lpx_conj.etc
deleted file mode 100644 (file)
index 5950f1b..0000000
+++ /dev/null
@@ -1,120 +0,0 @@
-include "basic_2/relocation/lleq_alt.ma".
-include "basic_2/reduction/cpx_lleq.ma".
-include "basic_2/reduction/lpx_lleq.ma".
-
-lemma not_ex_to_all_not: ∀A:Type[0]. ∀R:predicate A.
-                         ((∃a. R a)→⊥) → (∀a. R a → ⊥).
-/3 width=2 by ex_intro/ qed-.
-
-lemma lt_repl_sn_trans_tw: ∀L1,L2,T1,T2. ♯{L1, T1} < ♯{L2, T2} →
-                           ∀U1. ♯{U1} = ♯{T1} → ♯{L1, U1} < ♯{L2, T2}.
-normalize in ⊢ (?→?→?→?→?%%→?→?→?%%); //
-qed-.
-
-axiom cpx_fwd_lift1: ∀h,g,G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ➡[h, g] U2 →
-                     ∀T1,d,e. ⇧[d, e] T1 ≡ U1 → ∃T2. ⇧[d, e] T2 ≡ U2.
-(*
-#h #g #G #L #U1 #U2 #H elim H -G -L -U1 -U2
-[ * #i #G #L #T1 #d #e #H
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=2 by ex_intro/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=2 by lift_lref_ge_minus, lift_lref_lt, ex_intro/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=2 by ex_intro/
-  ]
-| #G #L #k #l #Hkl #T1 #d #e #H
-  lapply (lift_inv_sort2 … H) -H #H destruct /3 width=3 by ex_intro/
-| #I #G #L #K #V1 #V2 #W2 #i #HLK #HV12 #HVW2 #IHV2 #T1 #d #e #H
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
-    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
-    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m /3 width=9 by cpx_delta, ex2_intro/
-  | elim (le_inv_plus_l … Hid) #Hdie #Hei
-    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
-    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 /3 width=1 by le_S, le_S_S/ -Hid -Hdie
-    #V1 #HV1 >plus_minus // <minus_minus /2 width=1 by le_S/ <minus_n_n <plus_n_O /3 width=9 by cpx_delta, ex2_intro/
-  ]
-| #a #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=6 by cpx_bind, ldrop_skip, lift_bind, ex2_intro/
-| #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -V1
-  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5 by cpx_flat, lift_flat, ex2_intro/
-| #G #L #V #U1 #U #U2 #_ #HU2 #IHU1 #K #s #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHU1 (K.ⓓW1) s … HTU1) /2 width=1/ -L -U1 #T #HTU #HT1
-  elim (lift_div_le … HU2 … HTU) -U /3 width=5 by cpx_zeta, ex2_intro/
-| #G #L #V #U1 #U2 #_ #IHU12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHU12 … HLK … HTU1) -L -U1 /3 width=3 by cpx_tau, ex2_intro/
-| #G #L #V1 #V2 #U1 #_ #IHV12 #K #s #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -L -V1 /3 width=3 by cpx_ti, ex2_intro/
-| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #K #s #d #e #HLK #X #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
-  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
-  elim (IHV12 … HLK … HV01) -V1 #V3 #HV32 #HV03
-  elim (IHT12 (K.ⓛW0) s … HT01) -T1 /2 width=1 by ldrop_skip/ #T3 #HT32 #HT03
-  elim (IHW12 … HLK … HW01) -W1
-  /4 width=7 by cpx_beta, lift_bind, lift_flat, ex2_intro/
-| #a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #K #s #d #e #HLK #X #HX
-  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
-  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
-  elim (IHV1 … HLK … HV01) -V1 #V3 #HV3 #HV03
-  elim (IHT12 (K.ⓓW0) s … HT01) -T1 /2 width=1 by ldrop_skip/ #T3 #HT32 #HT03
-  elim (IHW12 … HLK … HW01) -W1 #W3 #HW32 #HW03
-  elim (lift_trans_le … HV3 … HV2) -V
-  /4 width=9 by cpx_theta, lift_bind, lift_flat, ex2_intro/
-]
-qed-.
-*)
-lemma cpx_fwd_nlift2: ∀h,g,G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ➡[h, g] U2 → ∀d,e.
-                      (∀T2. ⇧[d, e] T2 ≡ U2 → ⊥) → (∀T1. ⇧[d, e] T1 ≡ U1 → ⊥).
-#h #g #G #L #U1 #U2 #HU12 #d #e #HnU2 #T1 #HTU1
-elim (cpx_fwd_lift1 … HU12 … HTU1) -L -U1 /2 width=2 by/
-qed-.
-
-fact lleq_lpx_cpx_trans_aux: ∀h,g,G,T1,L1s,L1d,d. L1s ⋕[T1, d] L1d →
-                             ∀Y,L2d. ⦃G, Y⦄ ⊢ ➡[h, g] L2d → Y = L1d → d = 0 →
-                             ∀T2. ⦃G, L1d⦄ ⊢ T1 ➡[h, g] T2 →
-                             ∃∃L2s. ⦃G, L1s⦄ ⊢ ➡[h, g] L2s & L2s ⋕[T2, d] L2d.
-#h #g #G #T1 #L1s @(f2_ind … rfw … L1s T1) -L1s -T1 #n #IH
-#Ys #U1 #Hn #Yd #d #HU1 elim (lleq_fwd_alt … HU1) #H #IHU1
-#Y #L2d * -Y -L2d
-[ -IH -IHU1 -HU1 #HY #Hd #U2 #HU12 destruct
-  >(length_inv_zero_dx … H) -Ys /2 width=3 by ex2_intro/
-| #Id #L1d #L2d #W1d #W2d #HL12d #HW12d #HY #Hd #U2 #HU12 destruct
-  elim (length_inv_pos_dx … H) -H #Is #L1s #W1s #_ #H destruct
-  elim (is_lift_dec U1 0 1) [ -IHU1 -HW12d | -HU1 ]
-  [ * #T1 #HTU1 lapply (lift_fwd_tw … HTU1) #H
-    lapply (lleq_inv_lift_le … HU1 L1s L1d … HTU1 ?) -HU1 /2 width=1 by ldrop_drop/
-    #HT1 elim (cpx_inv_lift1 … HU12 L1d … HTU1) -HU12 -HTU1 /2 width=4 by ldrop_drop/
-    #T2 #HTU2 #HT12 elim (IH … HT1 … HL12d … HT12) /2 width=3 by lt_repl_sn_trans_tw/ -IH -HT1 -HT12 -H
-    #L2s #HL12s #HT2 @(ex2_intro … (L2s.ⓑ{Is}W1s))
-    /3 width=10 by lleq_lift_le, lpx_pair, ldrop_drop/ (**) (* full auto too slow *)
-  | #HnU1 lapply (not_ex_to_all_not … HnU1) -HnU1 #HnU1
-    elim (IHU1 … HnU1) [2,3,4: // |5,6,7,8,9,10: skip ] -HnU1 #H1 #H2 #HW1s destruct
-    elim (IH … HW1s … HL12d … HW12d) // #L2s #HL12s #HW2d
-    @(ex2_intro … (L2s.ⓑ{Id}W2d)) /3 width=3 by lleq_cpx_trans, lpx_pair/
-    lapply (lleq_fwd_length … HW2d) #HL2sd -HW12d -HW1s
-    @lleq_intro_alt [ normalize // ] -HL2sd
-    #I2s #I2d #K2s #K2d #V2s #V2d #i @(nat_ind_plus … i) -i
-    [ #_ #_ #HLK2s #HLK2d -IH -IHU1 -HU12 -HL12s -HL12d
-      lapply (ldrop_inv_O2 … HLK2s) -HLK2s #H destruct
-      lapply (ldrop_inv_O2 … HLK2d) -HLK2d #H destruct /2 width=1 by and3_intro/
-    | #i #_ #_ #HnU2 #HLK2s #HLK2d
-      lapply (cpx_fwd_nlift2 … HU12 … HnU2) -HU12 -HnU2 #HnU1
-      lapply (ldrop_inv_drop1 … HLK2s) -HLK2s #HLK2s
-      lapply (ldrop_inv_drop1 … HLK2d) -HLK2d #HLK2d
-      elim (lpx_ldrop_trans_O1 … HL12s … HLK2s) -L2s #Y #HLK1s #H
-      elim (lpx_inv_pair2 … H) -H #K1s #V1s #HK12s #HV12s #H destruct
-      elim (lpx_ldrop_trans_O1 … HL12d … HLK2d) -L2d #Y #HLK1d #H
-      elim (lpx_inv_pair2 … H) -H #K1d #V1d #HK12d #HV12d #H destruct
-      elim (IHU1 … HnU1) [2,3,4: /2 width=2 by ldrop_drop/ | 5,6,7,8,9,10: skip ] -IHU1 -HnU1 -HLK1d
-      #H1 #H2 #HV1d destruct
-      lapply (ldrop_fwd_rfw … HLK1s) -HLK1s #H
-      elim (IH … HV1d … HK12d … HV12d) // -IH -HV1d -HK12d -HV12d
-      [ #Y #H1Y #H2Y   
-       
-      
-
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc.etc
deleted file mode 100644 (file)
index b80b290..0000000
+++ /dev/null
@@ -1,41 +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 "hvbox( ⦃ term 46 L1 ⦄ ⬌ ⬌ break ⦃ term 46 L2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConvAlt $L1 $L2 }.
-
-include "basic_2/reducibility/lfpr.ma".
-
-(* FOCALIZED PARALLEL CONVERSION ON LOCAL ENVIRONMENTS **********************)
-
-definition lfpc: relation lenv ≝
-   λL1,L2. ⦃L1⦄ ➡ ⦃L2⦄ ∨ ⦃L2⦄ ➡ ⦃L1⦄.
-
-interpretation
-   "focalized parallel conversion (local environment)"
-   'FocalizedPConv L1 L2 = (lfpc L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lfpc_refl: ∀L. ⦃L⦄ ⬌ ⦃L⦄.
-/2 width=1/ qed.
-
-lemma lfpc_sym: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ⦃L2⦄ ⬌ ⦃L1⦄.
-#L1 #L2 * /2 width=1/
-qed.
-
-lemma lfpc_lfpr: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ∃∃L. ⦃L1⦄ ➡ ⦃L⦄ & ⦃L2⦄ ➡ ⦃L⦄.
-#L1 #L2 * /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc_lfpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpc_lfpc.etc
deleted file mode 100644 (file)
index 69e444a..0000000
+++ /dev/null
@@ -1,23 +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/conversion/lfpc.ma".
-
-(* FOCALIZED PARALLEL CONVERSION ON LOCAL ENVIRONMENTS **********************)
-
-(* Main properties **********************************************************)
-
-theorem lfpc_conf: ∀L0,L1,L2. ⦃L0⦄ ⬌ ⦃L1⦄ → ⦃L0⦄ ⬌ ⦃L2⦄ →
-                   ∃∃L. ⦃L1⦄ ⬌ ⦃L⦄ & ⦃L2⦄ ⬌ ⦃L⦄.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs.etc
deleted file mode 100644 (file)
index 3674637..0000000
+++ /dev/null
@@ -1,76 +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 "hvbox( ⦃ term 46 L1 ⦄ ⬌ ⬌ * break ⦃ term 46 L2 ⦄ )"
-   non associative with precedence 45
-   for @{ 'FocalizedPConvStarAlt $L1 $L2 }.
-
-include "basic_2/conversion/lfpc.ma".
-
-(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
-
-definition lfpcs: relation lenv ≝ TC … lfpc.
-
-interpretation "focalized parallel equivalence (local environment)"
-   'FocalizedPConvStar L1 L2 = (lfpcs L1 L2).
-
-(* Basic eliminators ********************************************************)
-
-lemma lfpcs_ind: ∀L1. ∀R:predicate lenv. R L1 →
-                 (∀L,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L⦄ ⬌ ⦃L2⦄ → R L → R L2) →
-                 ∀L2. ⦃L1⦄ ⬌* ⦃L2⦄ → R L2.
-#L1 #R #HL1 #IHL1 #L2 #HL12 @(TC_star_ind … HL1 IHL1 … HL12) //
-qed-.
-
-lemma lfpcs_ind_dx: ∀L2. ∀R:predicate lenv. R L2 →
-                    (∀L1,L. ⦃L1⦄ ⬌ ⦃L⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → R L → R L1) →
-                    ∀L1. ⦃L1⦄ ⬌* ⦃L2⦄ → R L1.
-#L2 #R #HL2 #IHL2 #L1 #HL12
-@(TC_star_ind_dx … HL2 IHL2 … HL12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lfpcs_refl: reflexive … lfpcs.
-/2 width=1/ qed.
-
-lemma lfpcs_sym: symmetric … lfpcs.
-/3 width=1/ qed.
-
-lemma lfpc_lfpcs: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/2 width=1/ qed.
-
-lemma lfpcs_strap1: ∀L1,L,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L⦄ ⬌ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/2 width=3/ qed.
-
-lemma lfpcs_strap2: ∀L1,L,L2. ⦃L1⦄ ⬌ ⦃L⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/2 width=3/ qed.
-
-lemma lfpcs_lfpr_dx: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=1/ qed.
-
-lemma lfpcs_lfpr_sn: ∀L1,L2. ⦃L2⦄ ➡ ⦃L1⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=1/ qed.
-
-lemma lfpcs_lfpr_strap1: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3/ qed.
-
-lemma lfpcs_lfpr_strap2: ∀L1,L. ⦃L1⦄ ➡ ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3/ qed.
-
-lemma lfpcs_lfpr_div: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡ ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3/ qed.
-
-lemma lfpcs_lfpr_conf: ∀L1,L. ⦃L⦄ ➡ ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_aaa.etc
deleted file mode 100644 (file)
index b7cea0b..0000000
+++ /dev/null
@@ -1,30 +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/computation/lfprs_aaa.ma".
-include "basic_2/equivalence/lfpcs_lfpcs.ma".
-
-(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
-
-(* Main properties about atomic arity assignment on terms *******************)
-
-theorem aaa_lfpcs_mono: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
-                        ∀T,A1. L1 ⊢ T ⁝ A1 → ∀A2. L2 ⊢ T ⁝ A2 →
-                        A1 = A2.
-#L1 #L2 #HL12 #T #A1 #HT1 #A2 #HT2
-elim (lfpcs_inv_lfprs … HL12) -HL12 #L #HL1 #HL2
-lapply (aaa_lfprs_conf … HT1 … HL1) -L1 #HT1
-lapply (aaa_lfprs_conf … HT2 … HL2) -L2 #HT2
-lapply (aaa_mono … HT1 … HT2) -L -T //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_fpcs.etc
deleted file mode 100644 (file)
index 8f36888..0000000
+++ /dev/null
@@ -1,52 +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/computation/fprs_cprs.ma".
-include "basic_2/computation/lfprs_fprs.ma".
-include "basic_2/equivalence/fpcs_fpcs.ma".
-include "basic_2/equivalence/lfpcs_lfpcs.ma".
-
-(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
-
-(* Inversion lemmas on context-free parallel equivalence for closures *******)
-
-lemma lfpcs_inv_fpcs: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ → ∀T. ⦃L1, T⦄ ⬌* ⦃L2, T⦄.
-#L1 #L2 #HL12 #T
-elim (lfpcs_inv_lfprs … HL12) -HL12 #L #HL1 #HL2
-lapply (lfprs_inv_fprs … HL1 T) -HL1
-lapply (lfprs_inv_fprs … HL2 T) -HL2 /2 width=4/
-qed-.
-
-(* Properties on context-free parallel equivalence for closures *************)
-
-lemma fpcs_lfpcs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L2 #T1 #T2 #HT12
-elim (fpcs_inv_fprs … HT12) -HT12 /3 width=5 by fprs_lfprs, lfprs_div/ (**) (* auto too slow without trace *)
-qed.
-
-lemma fpcs_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ⬌* ⦃K2, T2⦄ →
-                 ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
-                 ∀d,e. ⇩[d, e] L1 ≡ K1 → ⇩[d, e] L2 ≡ K2 →
-                 ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
-                 ⦃L1, U1⦄ ⬌* ⦃L2, U2⦄.
-#K1 #K2 #T1 #T2 #HT12 #L1 #L2 #HL12 #d #e #HLK1 #HLK2 #U1 #U2 #HTU1 #HTU2
-elim (fpcs_inv_fprs … HT12) -HT12 #K #T #HT1 #HT2
-elim (lift_total T d e) #U #HTU
-elim (fprs_lift … HT1 … HLK1 … HTU1 HTU) -K1 -T1 #K1 #HU1 #_
-elim (fprs_lift … HT2 … HLK2 … HTU2 HTU) -K2 -T2 -T #K2 #HU2 #_ -K -d -e
-lapply (lfpcs_lfprs_conf K1 … HL12) -HL12 /2 width=3/ #H
-lapply (lfpcs_lfprs_strap1 … H K2 ?) -H /2 width=3/ #HK12
-lapply (lfpcs_inv_fpcs … HK12 U) -HK12 #HU
-/3 width=4 by fpcs_fprs_strap2, fpcs_fprs_div/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfpcs.etc
deleted file mode 100644 (file)
index 1e95217..0000000
+++ /dev/null
@@ -1,50 +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/computation/lfprs_lfprs.ma".
-include "basic_2/conversion/lfpc_lfpc.ma".
-include "basic_2/equivalence/lfpcs_lfprs.ma".
-
-(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma lfpcs_inv_lfprs: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
-                       ∃∃L. ⦃L1⦄ ➡* ⦃L⦄ & ⦃L2⦄ ➡* ⦃L⦄.
-#L1 #L2 #H @(lfpcs_ind … H) -L2
-[ /3 width=3/
-| #L #L2 #_ #HL2 * #L0 #HL10 elim HL2 -HL2 #HL2 #HL0
-  [ elim (lfprs_strip … HL0 … HL2) -L #L #HL0 #HL2
-    lapply (lfprs_strap1 … HL10 … HL0) -L0 /2 width=3/
-  | lapply (lfprs_strap2 … HL2 … HL0) -L /2 width=3/
-  ]
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lfpcs_strip: ∀L,L1. ⦃L⦄ ⬌* ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌ ⦃L2⦄ →
-                   ∃∃L0. ⦃L1⦄ ⬌ ⦃L0⦄ & ⦃L2⦄ ⬌* ⦃L0⦄.
-/3 width=3/ qed.
-
-(* Main properties **********************************************************)
-
-theorem lfpcs_trans: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/2 width=3/ qed.
-
-theorem lfpcs_canc_sn: ∀L,L1,L2. ⦃L⦄ ⬌* ⦃L1⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3 by lfpcs_trans, lfpcs_sym/ qed.
-
-theorem lfpcs_canc_dx: ∀L,L1,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L2⦄ ⬌* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-/3 width=3 by lfpcs_trans, lfpcs_sym/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpc/lfpcs_lfprs.etc
deleted file mode 100644 (file)
index baf2caf..0000000
+++ /dev/null
@@ -1,48 +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/computation/lfprs.ma".
-include "basic_2/equivalence/lfpcs.ma".
-
-(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
-
-(* Properties on focalized computation for local environments ***************)
-
-lemma lfpcs_lfprs_dx: ∀L1,L2. ⦃L1⦄ ➡* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L2 #H @(lfprs_ind … H) -L2 /width=1/ /3 width=3/
-qed.
-
-lemma lfpcs_lfprs_sn: ∀L1,L2. ⦃L2⦄ ➡* ⦃L1⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L2 #H @(lfprs_ind_dx … H) -L2 /width=1/ /3 width=3/
-qed.
-
-lemma lfpcs_lfprs_strap1: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ➡* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L #HL1 #L2 #H @(lfprs_ind … H) -L2 /width=1/ /2 width=3/
-qed.
-
-lemma lfpcs_lfprs_strap2: ∀L1,L. ⦃L1⦄ ➡* ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L #H #L2 #HL2 @(lfprs_ind_dx … H) -L1 /width=1/ /2 width=3/
-qed.
-
-lemma lfpcs_lfprs_div: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L #HL1 #L2 #H @(lfprs_ind_dx … H) -L2 /width=1/ /2 width=3/
-qed.
-
-lemma lfpcs_lfprs_conf: ∀L1,L. ⦃L⦄ ➡* ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L #H #L2 #HL2 @(lfprs_ind … H) -L1 /width=1/ /2 width=3/
-qed.
-
-lemma lfprs_div: ∀L1,L. ⦃L1⦄ ➡* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
-#L1 #L #HL1 #L2 #H @(lfprs_ind_dx … H) -L2 /2 width=1/ /2 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpr_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpr_llpx_sn.etc
deleted file mode 100644 (file)
index 4db8587..0000000
+++ /dev/null
@@ -1,49 +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/llpx_sn_ldrop.ma".
-include "basic_2/reduction/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
-
-(* Properties on lazy sn pointwise extensions *******************************)
-
-lemma cpr_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
-                            (∀I.l_liftable (R I)) →
-                            (∀I.l_deliftable_sn (R I)) →
-                        ∀G. s_r_confluent1 … (cpr G) (llpx_sn R 0).
-#R #H1R #H2R #H3R #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
-[ //
-| #G #Ls #Ks #V1s #V2s #W2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
-| #a #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
-| #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-| #G #Ls #V #T1 #T2 #T #_ #HT2 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /3 width=10 by llpx_sn_inv_lift_le, ldrop_drop/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
-| #a #G #Ls #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_flat, llpx_sn_bind/
-| #a #G #Ls #V1 #V2 #V #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H //
-  #HW1 #HT1 @llpx_sn_bind_O /2 width=1 by/ @llpx_sn_flat (**) (* full auto too slow *)
-  [ /3 width=10 by llpx_sn_lift_le, ldrop_drop/
-  | /3 width=4 by llpx_sn_bind_repl_O/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpx_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/cpx_llpx_sn.etc
deleted file mode 100644 (file)
index 4181064..0000000
+++ /dev/null
@@ -1,52 +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/llpx_sn_ldrop.ma".
-include "basic_2/reduction/cpx.ma".
-
-(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
-
-(* Properties on lazy sn pointwise extensions *******************************)
-
-(* Note: lemma 1000 *)
-lemma cpx_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
-                            (∀I.l_liftable (R I)) →
-                            (∀I.l_deliftable_sn (R I)) →
-                        ∀h,g,G. s_r_confluent1 … (cpx h g G) (llpx_sn R 0).
-#R #H1R #H2R #H3R #h #g #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
-[ //
-| /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
-| #I #G #Ls #Ks #V1s #V2s #W2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
-| #a #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
-| #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-| #G #Ls #V #T1 #T2 #T #_ #HT2 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /3 width=10 by llpx_sn_inv_lift_le, ldrop_drop/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
-| #G #Ls #V1 #V2 #T #_ #IHV12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
-| #a #G #Ls #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_flat, llpx_sn_bind/
-| #a #G #Ls #V1 #V2 #V #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H //
-  #HW1 #HT1 @llpx_sn_bind_O /2 width=1 by/ @llpx_sn_flat (**) (* full auto too slow *)
-  [ /3 width=10 by llpx_sn_lift_le, ldrop_drop/
-  | /3 width=4 by llpx_sn_bind_repl_O/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lleq.etc
deleted file mode 100644 (file)
index dc138a4..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/llpx_sn.ma".
-
-(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
-
-definition ceq: relation4 bind2 lenv term term ≝ λI,L,T1,T2. T1 = T2.
-
-definition lleq: relation4 ynat term lenv lenv ≝ llpx_sn ceq.
-
-interpretation
-   "lazy equivalence (local environment)"
-   'LazyEq T d L1 L2 = (lleq d T L1 L2).
-
-definition lleq_transitive: predicate (relation4 bind2 lenv term term) ≝
-           λR. ∀I,L2,T1,T2. R I L2 T1 T2 → ∀L1. L1 ≡[T1, 0] L2 → R I L1 T1 T2.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lleq_ind: ∀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
-                ) → (
-                   ∀I,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
-                   ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}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 H -L1 -L2 -T -d /2 width=8 by/
-qed-.
-
-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.
-/2 width=2 by llpx_sn_inv_bind/ 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.
-/2 width=2 by llpx_sn_inv_flat/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lleq_fwd_length: ∀L1,L2,T,d. L1 ≡[T, d] L2 → |L1| = |L2|.
-/2 width=4 by llpx_sn_fwd_length/ qed-.
-
-lemma lleq_fwd_lref: ∀L1,L2,d,i. L1 ≡[#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 ≡[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: ∀L1,L2,T,d. L1 ≡[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: ∀L1,L2,T,d. L1 ≡[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 ≡[ⓑ{a,I}V.T, d] L2 → L1 ≡[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 ≡[ⓑ{a,I}V.T, d] L2 → L1.ⓑ{I}V ≡[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 ≡[ⓕ{I}V.T, d] L2 → L1 ≡[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 ≡[ⓕ{I}V.T, d] L2 → L1 ≡[T, d] L2.
-/2 width=3 by llpx_sn_fwd_flat_dx/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lleq_sort: ∀L1,L2,d,k. |L1| = |L2| → L1 ≡[⋆k, d] L2.
-/2 width=1 by llpx_sn_sort/ qed.
-
-lemma lleq_skip: ∀L1,L2,d,i. yinj i < d → |L1| = |L2| → L1 ≡[#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 ≡[V, 0] K2 → L1 ≡[#i, d] L2.
-/2 width=9 by llpx_sn_lref/ qed.
-
-lemma lleq_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → L1 ≡[#i, d] L2.
-/2 width=1 by llpx_sn_free/ qed.
-
-lemma lleq_gref: ∀L1,L2,d,p. |L1| = |L2| → L1 ≡[§p, d] L2.
-/2 width=1 by llpx_sn_gref/ 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.
-/2 width=1 by llpx_sn_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.
-/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: ∀L1,L2,T. |L1| = |L2| → L1 ≡[T, ∞] L2.
-/2 width=1 by llpx_sn_Y/ qed.
-
-lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
-#d #T #L1 #L2 #H @(lleq_ind … H) -d -T -L1 -L2
-/2 width=7 by lleq_sort, lleq_skip, lleq_lref, lleq_free, lleq_gref, lleq_bind, lleq_flat/
-qed-.
-
-lemma lleq_ge_up: ∀L1,L2,U,dt. L1 ≡[U, dt] L2 →
-                  ∀T,d,e. ⇧[d, e] T ≡ U →
-                  dt ≤ d + e → L1 ≡[U, d] L2.
-/2 width=6 by llpx_sn_ge_up/ qed-.
-
-lemma lleq_ge: ∀L1,L2,T,d1. L1 ≡[T, d1] L2 → ∀d2. d1 ≤ d2 → L1 ≡[T, d2] L2.
-/2 width=3 by llpx_sn_ge/ 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.
-/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)) →
-                     ∀L1,L2,T,d. L1 ≡[T, d] L2 → llpx_sn R d T L1 L2.
-/2 width=3 by llpx_sn_co/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn.etc
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/etc/lpx_sn/llpx_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_alt.etc
deleted file mode 100644 (file)
index 0916edb..0000000
+++ /dev/null
@@ -1,62 +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/cofrees_alt.ma".
-include "basic_2/substitution/llpx_sn_alt_rec.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* alternative definition of llpx_sn (not recursive) *)
-definition llpx_sn_alt: 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 **********************************************************)
-
-theorem llpx_sn_llpx_sn_alt: ∀R,T,L1,L2,d. llpx_sn R d T L1 L2 → llpx_sn_alt R d T L1 L2.
-#R #U #L1 @(f2_ind … rfw … L1 U) -L1 -U
-#n #IHn #L1 #U #Hn #L2 #d #H elim (llpx_sn_inv_alt_r … H) -H
-#HL12 #IHU @conj //
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2 elim (frees_inv_ge … H) -H //
-[ -n #HnU elim (IHU … HnU HLK1 HLK2) -IHU -HnU -HLK1 -HLK2 /2 width=1 by conj/
-| * #J1 #K10 #W10 #j #Hdj #Hji #HLK10 #HnW10 #HnU destruct
-  lapply (ldrop_fwd_drop2 … HLK10) #H
-  lapply (ldrop_conf_ge … H … HLK1 ?) -H /2 width=1 by lt_to_le/ <minus_plus #HK10
-  elim (ldrop_O1_lt (Ⓕ) L2 j) [2: <HL12 /2 width=5 by ldrop_fwd_length_lt2/ ] #J2 #K20 #W20 #HLK20
-  lapply (ldrop_fwd_drop2 … HLK20) #H
-  lapply (ldrop_conf_ge … H … HLK2 ?) -H /2 width=1 by lt_to_le/ <minus_plus #HK20
-  elim (IHn K10 W10 … K20 0) -IHn -HL12 /3 width=6 by ldrop_fwd_rfw/
-  elim (IHU … HnU HLK10 HLK20) -IHU -HnU -HLK10 -HLK20 //
-]
-qed.
-
-theorem llpx_sn_alt_inv_llpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt R d T L1 L2 → llpx_sn R d T L1 L2.
-#R #U #L1 @(f2_ind … rfw … L1 U) -L1 -U
-#n #IHn #L1 #U #Hn #L2 #d * #HL12 #IHU @llpx_sn_intro_alt_r //
-#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnU #HLK1 #HLK2 destruct
-elim (IHU … HLK1 HLK2) /3 width=6 by nlift_frees/
-#H #HV12 @and3_intro // @IHn -IHn /3 width=6 by ldrop_fwd_rfw/
-lapply (ldrop_fwd_drop2 … HLK1) #H1
-lapply (ldrop_fwd_drop2 … HLK2) -HLK2 #H2
-@conj [ @(ldrop_fwd_length_eq1 … H1 H2) // ] -HL12
-#Z1 #Z2 #Y1 #Y2 #X1 #X2 #j #_
->(minus_plus_m_m j (i+1)) in ⊢ (%→?); >commutative_plus <minus_plus
-#HnV1 #HKY1 #HKY2 (**) (* full auto too slow *)
-lapply (ldrop_trans_ge … H1 … HKY1 ?) -H1 -HKY1 // #HLY1
-lapply (ldrop_trans_ge … H2 … HKY2 ?) -H2 -HKY2 // #HLY2
-/4 width=14 by frees_be, yle_plus_dx2_trans, yle_succ_dx/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_alt_rec.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_alt_rec.etc
deleted file mode 100644 (file)
index 2671af0..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/substitution/llpx_sn.ma".
-
-(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
-
-(* alternative definition of llpx_sn (recursive) *)
-inductive llpx_sn_alt_r (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
-| llpx_sn_alt_r_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 R 0 V1 K1 K2
-                       ) → |L1| = |L2| → llpx_sn_alt_r R d T L1 L2
-.
-
-(* Compact definition of llpx_sn_alt_r **************************************)
-
-lemma llpx_sn_alt_r_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 R 0 V1 K1 K2
-                               ) → llpx_sn_alt_r R d T L1 L2.
-#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt_r_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_r_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 R 0 V1 K1 K2 & S 0 V1 K1 K2
-                             ) → S d T L1 L2) →
-                             ∀L1,L2,T,d. llpx_sn_alt_r 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_r_inv_alt: ∀R,L1,L2,T,d. llpx_sn_alt_r 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 R 0 V1 K1 K2.
-#R #L1 #L2 #T #d #H @(llpx_sn_alt_r_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_r_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn_alt_r R d (ⓕ{I}V.T) L1 L2 →
-                              llpx_sn_alt_r R d V L1 L2 ∧ llpx_sn_alt_r R d T L1 L2.
-#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H
-#HL12 #IH @conj @llpx_sn_alt_r_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_r_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn_alt_r R d (ⓑ{a,I}V.T) L1 L2 →
-                              llpx_sn_alt_r R d V L1 L2 ∧ llpx_sn_alt_r R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
-#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H
-#HL12 #IH @conj @llpx_sn_alt_r_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_r_fwd_length: ∀R,L1,L2,T,d. llpx_sn_alt_r R d T L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H //
-qed-.
-
-lemma llpx_sn_alt_r_fwd_lref: ∀R,L1,L2,d,i. llpx_sn_alt_r 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 R (yinj 0) V1 K1 K2 &
-                                                  R I K1 V1 V2 & d ≤ yinj i.
-#R #L1 #L2 #d #i #H elim (llpx_sn_alt_r_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_r_sort: ∀R,L1,L2,d,k. |L1| = |L2| → llpx_sn_alt_r R d (⋆k) L1 L2.
-#R #L1 #L2 #d #k #HL12 @llpx_sn_alt_r_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (⋆k)) //
-qed.
-
-lemma llpx_sn_alt_r_gref: ∀R,L1,L2,d,p. |L1| = |L2| → llpx_sn_alt_r R d (§p) L1 L2.
-#R #L1 #L2 #d #p #HL12 @llpx_sn_alt_r_intro_alt // -HL12
-#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (§p)) //
-qed.
-
-lemma llpx_sn_alt_r_skip: ∀R,L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn_alt_r R d (#i) L1 L2.
-#R #L1 #L2 #d #i #HL12 #Hid @llpx_sn_alt_r_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_r_free: ∀R,L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| →
-                          llpx_sn_alt_r R d (#i) L1 L2.
-#R #L1 #L2 #d #i #HL1 #_ #HL12 @llpx_sn_alt_r_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_r_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 R 0 V1 K1 K2 → R I K1 V1 V2 →
-                          llpx_sn_alt_r R d (#i) L1 L2.
-#R #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 @llpx_sn_alt_r_intro_alt
-[ lapply (llpx_sn_alt_r_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_r_flat: ∀R,I,L1,L2,V,T,d.
-                          llpx_sn_alt_r R d V L1 L2 → llpx_sn_alt_r R d T L1 L2 →
-                          llpx_sn_alt_r R d (ⓕ{I}V.T) L1 L2.
-#R #I #L1 #L2 #V #T #d #HV #HT
-elim (llpx_sn_alt_r_inv_alt … HV) -HV #HL12 #IHV
-elim (llpx_sn_alt_r_inv_alt … HT) -HT #_ #IHT
-@llpx_sn_alt_r_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_r_bind: ∀R,a,I,L1,L2,V,T,d.
-                          llpx_sn_alt_r R d V L1 L2 →
-                          llpx_sn_alt_r R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
-                          llpx_sn_alt_r R d (ⓑ{a,I}V.T) L1 L2.
-#R #a #I #L1 #L2 #V #T #d #HV #HT
-elim (llpx_sn_alt_r_inv_alt … HV) -HV #HL12 #IHV
-elim (llpx_sn_alt_r_inv_alt … HT) -HT #_ #IHT
-@llpx_sn_alt_r_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: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → llpx_sn_alt_r R d T L1 L2.
-#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
-/2 width=9 by llpx_sn_alt_r_sort, llpx_sn_alt_r_gref, llpx_sn_alt_r_skip, llpx_sn_alt_r_free, llpx_sn_alt_r_lref, llpx_sn_alt_r_flat, llpx_sn_alt_r_bind/
-qed.
-
-(* Main inversion lemmas ****************************************************)
-
-theorem llpx_sn_alt_r_inv_lpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt_r 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_r_fwd_length, llpx_sn_gref, llpx_sn_sort/
-| #i #Hn #L2 #d #H lapply (llpx_sn_alt_r_fwd_length … H)
-  #HL12 elim (llpx_sn_alt_r_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_r_inv_bind … H) -H
-  /3 width=1 by llpx_sn_bind/
-| #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt_r_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-]
-qed-.
-
-(* Alternative definition of llpx_sn (recursive) ****************************)
-
-lemma llpx_sn_intro_alt_r: ∀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_r_inv_lpx_sn
-@llpx_sn_alt_r_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_r, and3_intro/
-qed.
-
-lemma llpx_sn_ind_alt_r: ∀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_r … H) -H
-#H @(llpx_sn_alt_r_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_r_inv_lpx_sn, and4_intro/
-qed-.
-
-lemma llpx_sn_inv_alt_r: ∀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_r … H) -H
-#H elim (llpx_sn_alt_r_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_r_inv_lpx_sn, and3_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_ldrop.etc
deleted file mode 100644 (file)
index 509a836..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/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/etc/lpx_sn/llpx_sn_lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_lpx_sn.etc
deleted file mode 100644 (file)
index 21a88ca..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/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/etc/lpx_sn/llpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/llpx_sn_tc.etc
deleted file mode 100644 (file)
index d22e090..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/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.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpr.etc
deleted file mode 100644 (file)
index fd05f63..0000000
+++ /dev/null
@@ -1,61 +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/predsn_3.ma".
-include "basic_2/relocation/lpx_sn.ma".
-include "basic_2/reduction/cpr.ma".
-
-(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
-
-definition lpr: relation3 genv lenv lenv ≝ λG. lpx_sn (λ_.cpr G).
-
-interpretation "parallel reduction (local environment, sn variant)"
-   'PRedSn G L1 L2 = (lpr G L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-(* Basic_1: includes: wcpr0_gen_sort *)
-lemma lpr_inv_atom1: ∀G,L2. ⦃G, ⋆⦄ ⊢ ➡ L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-(* Basic_1: includes: wcpr0_gen_head *)
-lemma lpr_inv_pair1: ∀I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡ L2 →
-                     ∃∃K2,V2. ⦃G, K1⦄ ⊢ ➡ K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2 & L2 = K2.ⓑ{I}V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-lemma lpr_inv_atom2: ∀G,L1. ⦃G, L1⦄ ⊢ ➡ ⋆ → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-lemma lpr_inv_pair2: ∀I,G,L1,K2,V2. ⦃G, L1⦄ ⊢ ➡ K2.ⓑ{I}V2 →
-                     ∃∃K1,V1. ⦃G, K1⦄ ⊢ ➡ K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2 & L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-(* Basic properties *********************************************************)
-
-(* Note: lemma 250 *)
-lemma lpr_refl: ∀G,L. ⦃G, L⦄ ⊢ ➡ L.
-/2 width=1 by lpx_sn_refl/ qed.
-
-lemma lpr_pair: ∀I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ➡ K2 → ⦃G, K1⦄ ⊢ V1 ➡ V2 →
-                ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡ K2.ⓑ{I}V2.
-/2 width=1 by lpx_sn_pair/ qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpr_fwd_length: ∀G,L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
-
-(* Basic_1: removed theorems 3: wcpr0_getl wcpr0_getl_back
-                                pr0_subst1_back
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx.etc
deleted file mode 100644 (file)
index 2482329..0000000
+++ /dev/null
@@ -1,65 +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/predsn_5.ma".
-include "basic_2/reduction/lpr.ma".
-include "basic_2/reduction/cpx.ma".
-
-(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
-
-definition lpx: ∀h. sd h → relation3 genv lenv lenv ≝
-                λh,g,G. lpx_sn (λ_.cpx h g G).
-
-interpretation "extended parallel reduction (local environment, sn variant)"
-   'PRedSn h g G L1 L2 = (lpx h g G L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lpx_inv_atom1: ∀h,g,G,L2. ⦃G, ⋆⦄ ⊢ ➡[h, g] L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-lemma lpx_inv_pair1: ∀h,g,I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡[h, g] L2 →
-                     ∃∃K2,V2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 &
-                              L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-lemma lpx_inv_atom2: ∀h,g,G,L1.  ⦃G, L1⦄ ⊢ ➡[h, g] ⋆ → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-lemma lpx_inv_pair2: ∀h,g,I,G,L1,K2,V2.  ⦃G, L1⦄ ⊢ ➡[h, g] K2.ⓑ{I}V2 →
-                     ∃∃K1,V1. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 &
-                             L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-lemma lpx_inv_pair: ∀h,g,I1,I2,G,L1,L2,V1,V2.  ⦃G, L1.ⓑ{I1}V1⦄ ⊢ ➡[h, g] L2.ⓑ{I2}V2 →
-                    ∧∧ ⦃G, L1⦄ ⊢ ➡[h, g] L2 & ⦃G, L1⦄ ⊢ V1 ➡[h, g] V2 & I1 = I2.
-/2 width=1 by lpx_sn_inv_pair/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpx_refl: ∀h,g,G,L.  ⦃G, L⦄ ⊢ ➡[h, g] L.
-/2 width=1 by lpx_sn_refl/ qed.
-
-lemma lpx_pair: ∀h,g,I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 → ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 →
-                ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡[h, g] K2.ⓑ{I}V2.
-/2 width=1 by lpx_sn_pair/ qed.
-
-lemma lpr_lpx: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L1⦄ ⊢ ➡[h, g] L2.
-#h #g #G #L1 #L2 #H elim H -L1 -L2 /3 width=1 by lpx_pair, cpr_cpx/
-qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpx_fwd_length: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn.etc
deleted file mode 100644 (file)
index eb640da..0000000
+++ /dev/null
@@ -1,89 +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/grammar/lenv_length.ma".
-
-(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
-
-inductive lpx_sn (R:relation4 bind2 lenv term term): relation lenv ≝
-| lpx_sn_atom: lpx_sn R (⋆) (⋆)
-| lpx_sn_pair: ∀I,K1,K2,V1,V2.
-               lpx_sn R K1 K2 → R I K1 V1 V2 →
-               lpx_sn R (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
-.
-
-(* Basic properties *********************************************************)
-
-lemma lpx_sn_refl: ∀R. (∀I,L. reflexive ? (R I L)) → reflexive … (lpx_sn R).
-#R #HR #L elim L -L /2 width=1 by lpx_sn_atom, lpx_sn_pair/
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lpx_sn_inv_atom1_aux: ∀R,L1,L2. lpx_sn R L1 L2 → L1 = ⋆ → L2 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_sn_inv_atom1: ∀R,L2. lpx_sn R (⋆) L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-fact lpx_sn_inv_pair1_aux: ∀R,L1,L2. lpx_sn R L1 L2 → ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
-                           ∃∃K2,V2. lpx_sn R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
-#R #L1 #L2 * -L1 -L2
-[ #J #K1 #V1 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma lpx_sn_inv_pair1: ∀R,I,K1,V1,L2. lpx_sn R (K1.ⓑ{I}V1) L2 →
-                        ∃∃K2,V2. lpx_sn R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-fact lpx_sn_inv_atom2_aux: ∀R,L1,L2. lpx_sn R L1 L2 → L2 = ⋆ → L1 = ⋆.
-#R #L1 #L2 * -L1 -L2
-[ //
-| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
-]
-qed-.
-
-lemma lpx_sn_inv_atom2: ∀R,L1. lpx_sn R L1 (⋆) → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-fact lpx_sn_inv_pair2_aux: ∀R,L1,L2. lpx_sn R L1 L2 → ∀I,K2,V2. L2 = K2.ⓑ{I}V2 →
-                           ∃∃K1,V1. lpx_sn R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
-#R #L1 #L2 * -L1 -L2
-[ #J #K2 #V2 #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma lpx_sn_inv_pair2: ∀R,I,L1,K2,V2. lpx_sn R L1 (K2.ⓑ{I}V2) →
-                        ∃∃K1,V1. lpx_sn R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-lemma lpx_sn_inv_pair: ∀R,I1,I2,L1,L2,V1,V2.
-                       lpx_sn R (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2) →
-                       ∧∧ lpx_sn R L1 L2 & R I1 L1 V1 V2 & I1 = I2.
-#R #I1 #I2 #L1 #L2 #V1 #V2 #H elim (lpx_sn_inv_pair1 … H) -H
-#L0 #V0 #HL10 #HV10 #H destruct /2 width=1 by and3_intro/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpx_sn_fwd_length: ∀R,L1,L2. lpx_sn R L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H -L1 -L2 normalize //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_alt.etc
deleted file mode 100644 (file)
index 8a0aa39..0000000
+++ /dev/null
@@ -1,125 +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.ma".
-include "basic_2/relocation/lpx_sn.ma".
-
-(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
-
-(* alternative definition of lpx_sn *)
-definition lpx_sn_alt: relation4 bind2 lenv term term → relation lenv ≝
-                       λR,L1,L2. |L1| = |L2| ∧
-                       (∀I1,I2,K1,K2,V1,V2,i.
-                          ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                          I1 = I2 ∧ R I1 K1 V1 V2
-                       ).
-
-(* Basic forward lemmas ******************************************************)
-
-lemma lpx_sn_alt_fwd_length: ∀R,L1,L2. lpx_sn_alt R L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H //
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lpx_sn_alt_inv_atom1: ∀R,L2. lpx_sn_alt R (⋆) L2 → L2 = ⋆.
-#R #L2 #H lapply (lpx_sn_alt_fwd_length … H) -H
-normalize /2 width=1 by length_inv_zero_sn/
-qed-.
-
-lemma lpx_sn_alt_inv_pair1: ∀R,I,L2,K1,V1. lpx_sn_alt R (K1.ⓑ{I}V1) L2 →
-                            ∃∃K2,V2. lpx_sn_alt R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
-#R #I1 #L2 #K1 #V1 #H elim H -H
-#H #IH elim (length_inv_pos_sn … H) -H
-#I2 #K2 #V2 #HK12 #H destruct
-elim (IH I1 I2 K1 K2 V1 V2 0) //
-#H #HV12 destruct @(ex3_2_intro … K2 V2) // -HV12
-@conj // -HK12
-#J1 #J2 #L1 #L2 #W1 #W2 #i #HKL1 #HKL2 elim (IH J1 J2 L1 L2 W1 W2 (i+1)) -IH
-/2 width=1 by ldrop_drop, conj/
-qed-.
-
-lemma lpx_sn_alt_inv_atom2: ∀R,L1. lpx_sn_alt R L1 (⋆) → L1 = ⋆.
-#R #L1 #H lapply (lpx_sn_alt_fwd_length … H) -H
-normalize /2 width=1 by length_inv_zero_dx/
-qed-.
-
-lemma lpx_sn_alt_inv_pair2: ∀R,I,L1,K2,V2. lpx_sn_alt R L1 (K2.ⓑ{I}V2) →
-                            ∃∃K1,V1. lpx_sn_alt R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
-#R #I2 #L1 #K2 #V2 #H elim H -H
-#H #IH elim (length_inv_pos_dx … H) -H
-#I1 #K1 #V1 #HK12 #H destruct
-elim (IH I1 I2 K1 K2 V1 V2 0) //
-#H #HV12 destruct @(ex3_2_intro … K1 V1) // -HV12
-@conj // -HK12
-#J1 #J2 #L1 #L2 #W1 #W2 #i #HKL1 #HKL2 elim (IH J1 J2 L1 L2 W1 W2 (i+1)) -IH
-/2 width=1 by ldrop_drop, conj/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpx_sn_alt_atom: ∀R. lpx_sn_alt R (⋆) (⋆).
-#R @conj //
-#I1 #I2 #K1 #K2 #V1 #V2 #i #HLK1 elim (ldrop_inv_atom1 … HLK1) -HLK1
-#H destruct
-qed.
-
-lemma lpx_sn_alt_pair: ∀R,I,L1,L2,V1,V2.
-                       lpx_sn_alt R L1 L2 → R I L1 V1 V2 →
-                       lpx_sn_alt R (L1.ⓑ{I}V1) (L2.ⓑ{I}V2).
-#R #I #L1 #L2 #V1 #V2 #H #HV12 elim H -H
-#HL12 #IH @conj normalize //
-#I1 #I2 #K1 #K2 #W1 #W2 #i @(nat_ind_plus … i) -i
-[ #HLK1 #HLK2
-  lapply (ldrop_inv_O2 … HLK1) -HLK1 #H destruct
-  lapply (ldrop_inv_O2 … HLK2) -HLK2 #H destruct
-  /2 width=1 by conj/
-| -HL12 -HV12 /3 width=6 by ldrop_inv_drop1/
-]
-qed.
-
-(* Main properties **********************************************************)
-
-theorem lpx_sn_lpx_sn_alt: ∀R,L1,L2. lpx_sn R L1 L2 → lpx_sn_alt R L1 L2.
-#R #L1 #L2 #H elim H -L1 -L2
-/2 width=1 by lpx_sn_alt_atom, lpx_sn_alt_pair/
-qed.
-
-(* Main inversion lemmas ****************************************************)
-
-theorem lpx_sn_alt_inv_lpx_sn: ∀R,L1,L2. lpx_sn_alt R L1 L2 → lpx_sn R L1 L2.
-#R #L1 elim L1 -L1
-[ #L2 #H lapply (lpx_sn_alt_inv_atom1 … H) -H //
-| #L1 #I #V1 #IH #X #H elim (lpx_sn_alt_inv_pair1 … H) -H
-  #L2 #V2 #HL12 #HV12 #H destruct /3 width=1 by lpx_sn_pair/
-]
-qed-.
-
-(* alternative definition of lpx_sn *****************************************)
-
-lemma lpx_sn_intro_alt: ∀R,L1,L2. |L1| = |L2| →
-                        (∀I1,I2,K1,K2,V1,V2,i.
-                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                           I1 = I2 ∧ R I1 K1 V1 V2
-                        ) → lpx_sn R L1 L2.
-/4 width=4 by lpx_sn_alt_inv_lpx_sn, conj/ qed.
-
-lemma lpx_sn_inv_alt: ∀R,L1,L2. lpx_sn R L1 L2 →
-                      |L1| = |L2| ∧
-                      ∀I1,I2,K1,K2,V1,V2,i.
-                      ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
-                      I1 = I2 ∧ R I1 K1 V1 V2.
-#R #L1 #L2 #H lapply (lpx_sn_lpx_sn_alt … H) -H
-#H elim H -H /3 width=4 by conj/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_ldrop.etc
deleted file mode 100644 (file)
index 2b44e20..0000000
+++ /dev/null
@@ -1,104 +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/lpx_sn.ma".
-
-(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
-
-(* Properies on dropping ****************************************************)
-
-lemma lpx_sn_ldrop_conf: ∀R,L1,L2. lpx_sn R L1 L2 →
-                         ∀I,K1,V1,i. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
-                         ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 & lpx_sn R K1 K2 & R I K1 V1 V2.
-#R #L1 #L2 #H elim H -L1 -L2
-[ #I0 #K0 #V0 #i #H elim (ldrop_inv_atom1 … H) -H #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #IHK12 #I0 #K0 #V0 #i #H elim (ldrop_inv_O1_pair1 … H) * -H
-  [ -IHK12 #H1 #H2 destruct /3 width=5 by ldrop_pair, ex3_2_intro/
-  | -HK12 -HV12 #Hi #HK10 elim (IHK12 … HK10) -IHK12 -HK10
-    /3 width=5 by ldrop_drop_lt, ex3_2_intro/
-  ]
-]
-qed-.
-
-lemma lpx_sn_ldrop_trans: ∀R,L1,L2. lpx_sn R L1 L2 →
-                          ∀I,K2,V2,i. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
-                          ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 & lpx_sn R K1 K2 & R I K1 V1 V2.
-#R #L1 #L2 #H elim H -L1 -L2
-[ #I0 #K0 #V0 #i #H elim (ldrop_inv_atom1 … H) -H #H destruct
-| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #IHK12 #I0 #K0 #V0 #i #H elim (ldrop_inv_O1_pair1 … H) * -H
-  [ -IHK12 #H1 #H2 destruct /3 width=5 by ldrop_pair, ex3_2_intro/
-  | -HK12 -HV12 #Hi #HK10 elim (IHK12 … HK10) -IHK12 -HK10
-    /3 width=5 by ldrop_drop_lt, ex3_2_intro/
-  ]
-]
-qed-.
-
-lemma lpx_sn_deliftable_dropable: ∀R. (∀I. l_deliftable_sn (R I)) → dropable_sn (lpx_sn R).
-#R #HR #L1 #K1 #s #d #e #H elim H -L1 -K1 -d -e
-[ #d #e #He #X #H >(lpx_sn_inv_atom1 … H) -H
-  /4 width=3 by ldrop_atom, lpx_sn_atom, ex2_intro/
-| #I #K1 #V1 #X #H elim (lpx_sn_inv_pair1 … H) -H
-  #L2 #V2 #HL12 #HV12 #H destruct
-  /3 width=5 by ldrop_pair, lpx_sn_pair, ex2_intro/
-| #I #L1 #K1 #V1 #e #_ #IHLK1 #X #H elim (lpx_sn_inv_pair1 … H) -H
-  #L2 #V2 #HL12 #HV12 #H destruct
-  elim (IHLK1 … HL12) -L1 /3 width=3 by ldrop_drop, ex2_intro/
-| #I #L1 #K1 #V1 #W1 #d #e #HLK1 #HWV1 #IHLK1 #X #H
-  elim (lpx_sn_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
-  elim (HR … HV12 … HLK1 … HWV1) -V1
-  elim (IHLK1 … HL12) -L1 /3 width=5 by ldrop_skip, lpx_sn_pair, ex2_intro/
-]
-qed-.
-
-lemma lpx_sn_liftable_dedropable: ∀R. (∀I,L. reflexive ? (R I L)) →
-                                  (∀I. l_liftable (R I)) → dedropable_sn (lpx_sn R).
-#R #H1R #H2R #L1 #K1 #s #d #e #H elim H -L1 -K1 -d -e
-[ #d #e #He #X #H >(lpx_sn_inv_atom1 … H) -H
-  /4 width=4 by ldrop_atom, lpx_sn_atom, ex3_intro/
-| #I #K1 #V1 #X #H elim (lpx_sn_inv_pair1 … H) -H
-  #K2 #V2 #HK12 #HV12 #H destruct
-  lapply (lpx_sn_fwd_length … HK12)
-  #H @(ex3_intro … (K2.ⓑ{I}V2)) (**) (* explicit constructor *)
-  /3 width=1 by lpx_sn_pair, monotonic_le_plus_l/
-  @leq_O2 normalize //
-| #I #L1 #K1 #V1 #e #_ #IHLK1 #K2 #HK12 elim (IHLK1 … HK12) -K1
-  /3 width=5 by ldrop_drop, leq_pair, lpx_sn_pair, ex3_intro/
-| #I #L1 #K1 #V1 #W1 #d #e #HLK1 #HWV1 #IHLK1 #X #H
-  elim (lpx_sn_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
-  elim (lift_total W2 d e) #V2 #HWV2
-  lapply (H2R … HW12 … HLK1 … HWV1 … HWV2) -W1
-  elim (IHLK1 … HK12) -K1
-  /3 width=6 by ldrop_skip, leq_succ, lpx_sn_pair, ex3_intro/
-]
-qed-.
-
-fact lpx_sn_dropable_aux: ∀R,L2,K2,s,d,e. ⇩[s, d, e] L2 ≡ K2 → ∀L1. lpx_sn R L1 L2 →
-                          d = 0 → ∃∃K1. ⇩[s, 0, e] L1 ≡ K1 & lpx_sn R K1 K2.
-#R #L2 #K2 #s #d #e #H elim H -L2 -K2 -d -e
-[ #d #e #He #X #H >(lpx_sn_inv_atom2 … H) -H 
-  /4 width=3 by ldrop_atom, lpx_sn_atom, ex2_intro/
-| #I #K2 #V2 #X #H elim (lpx_sn_inv_pair2 … H) -H
-  #K1 #V1 #HK12 #HV12 #H destruct
-  /3 width=5 by ldrop_pair, lpx_sn_pair, ex2_intro/
-| #I #L2 #K2 #V2 #e #_ #IHLK2 #X #H #_ elim (lpx_sn_inv_pair2 … H) -H
-  #L1 #V1 #HL12 #HV12 #H destruct
-  elim (IHLK2 … HL12) -L2 /3 width=3 by ldrop_drop, ex2_intro/
-| #I #L2 #K2 #V2 #W2 #d #e #_ #_ #_ #L1 #_
-  <plus_n_Sm #H destruct
-]
-qed-.
-
-lemma lpx_sn_dropable: ∀R. dropable_dx (lpx_sn R).
-/2 width=5 by lpx_sn_dropable_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_lpx_sn.etc
deleted file mode 100644 (file)
index bd72cf6..0000000
+++ /dev/null
@@ -1,48 +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.ma".
-
-(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
-
-definition lpx_sn_confluent: relation (relation3 lenv term term) ≝ λR1,R2.
-                             ∀L0,T0,T1. R1 L0 T0 T1 → ∀T2. R2 L0 T0 T2 →
-                             ∀L1. lpx_sn (λ_.R1) L0 L1 → ∀L2. lpx_sn (λ_.R2) L0 L2 →
-                             ∃∃T. R2 L1 T1 T & R1 L2 T2 T.
-
-definition lpx_sn_transitive: relation (relation3 lenv term term) ≝ λR1,R2.
-                              ∀L1,T1,T. R1 L1 T1 T → ∀L2. lpx_sn (λ_.R1) L1 L2 →
-                              ∀T2. R2 L2 T T2 → R1 L1 T1 T2.
-
-(* Main properties **********************************************************)
-
-theorem lpx_sn_trans: ∀R. lpx_sn_transitive R R → Transitive … (lpx_sn (λ_.R)).
-#R #HR #L1 #L #H elim H -L1 -L //
-#I #L1 #L #V1 #V #HL1 #HV1 #IHL1 #X #H
-elim (lpx_sn_inv_pair1 … H) -H #L2 #V2 #HL2 #HV2 #H destruct /3 width=5 by lpx_sn_pair/
-qed-.
-
-theorem lpx_sn_conf: ∀R1,R2. lpx_sn_confluent R1 R2 →
-                     confluent2 … (lpx_sn (λ_.R1)) (lpx_sn (λ_.R2)).
-#R1 #R2 #HR12 #L0 @(f_ind … length … L0) -L0 #n #IH *
-[ #_ #X1 #H1 #X2 #H2 -n
-  >(lpx_sn_inv_atom1 … H1) -X1
-  >(lpx_sn_inv_atom1 … H2) -X2 /2 width=3 by lpx_sn_atom, ex2_intro/
-| #L0 #I #V0 #Hn #X1 #H1 #X2 #H2 destruct
-  elim (lpx_sn_inv_pair1 … H1) -H1 #L1 #V1 #HL01 #HV01 #H destruct
-  elim (lpx_sn_inv_pair1 … H2) -H2 #L2 #V2 #HL02 #HV02 #H destruct
-  elim (IH … HL01 … HL02) -IH normalize // #L #HL1 #HL2
-  elim (HR12 … HV01 … HV02 … HL01 … HL02) -L0 -V0 /3 width=5 by lpx_sn_pair, ex2_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/lpx_sn_tc.etc
deleted file mode 100644 (file)
index 2a3a87c..0000000
+++ /dev/null
@@ -1,119 +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.ma".
-
-(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
-
-(* Properties on transitive_closure *****************************************)
-
-lemma TC_lpx_sn_pair_refl: ∀R. (∀I,L. reflexive … (R I L)) →
-                           ∀L1,L2. TC … (lpx_sn R) L1 L2 →
-                           ∀I,V. TC … (lpx_sn R) (L1.ⓑ{I}V) (L2. ⓑ{I}V).
-#R #HR #L1 #L2 #H @(TC_star_ind … L2 H) -L2
-[ /2 width=1 by lpx_sn_refl/
-| /3 width=1 by TC_reflexive, lpx_sn_refl/
-| /3 width=5 by lpx_sn_pair, step/
-]
-qed-.
-
-lemma TC_lpx_sn_pair: ∀R. (∀I,L. reflexive … (R I L)) →
-                      ∀I,L1,L2. TC … (lpx_sn R) L1 L2 →
-                      ∀V1,V2. LTC … (R I) L1 V1 V2 →
-                      TC … (lpx_sn R) (L1.ⓑ{I}V1) (L2. ⓑ{I}V2).
-#R #HR #I #L1 #L2 #HL12 #V1 #V2 #H @(TC_star_ind_dx … V1 H) -V1 //
-[ /2 width=1 by TC_lpx_sn_pair_refl/
-| /4 width=3 by TC_strap, lpx_sn_pair, lpx_sn_refl/
-]
-qed-.
-
-lemma lpx_sn_LTC_TC_lpx_sn: ∀R. (∀I,L. reflexive … (R I L)) →
-                            ∀L1,L2. lpx_sn (λI.LTC … (R I)) L1 L2 →
-                            TC … (lpx_sn R) L1 L2.
-#R #HR #L1 #L2 #H elim H -L1 -L2
-/2 width=1 by TC_lpx_sn_pair, lpx_sn_atom, inj/
-qed-.
-
-(* Inversion lemmas on transitive closure ***********************************)
-
-lemma TC_lpx_sn_inv_atom2: ∀R,L1. TC … (lpx_sn R) L1 (⋆) → L1 = ⋆.
-#R #L1 #H @(TC_ind_dx … L1 H) -L1
-[ /2 width=2 by lpx_sn_inv_atom2/
-| #L1 #L #HL1 #_ #IHL2 destruct /2 width=2 by lpx_sn_inv_atom2/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_pair2: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
-                           ∀I,L1,K2,V2. TC  … (lpx_sn R) L1 (K2.ⓑ{I}V2) →
-                           ∃∃K1,V1. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L1 = K1.ⓑ{I}V1.
-#R #HR #I #L1 #K2 #V2 #H @(TC_ind_dx … L1 H) -L1
-[ #L1 #H elim (lpx_sn_inv_pair2 … H) -H /3 width=5 by inj, ex3_2_intro/
-| #L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
-  elim (lpx_sn_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct
-  lapply (HR … HV2 … HK1) -HR -HV2 /3 width=5 by TC_strap, ex3_2_intro/
-]
-qed-.
-
-lemma TC_lpx_sn_ind: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
-                     ∀S:relation lenv.
-                     S (⋆) (⋆) → (
-                        ∀I,K1,K2,V1,V2.
-                        TC … (lpx_sn R) K1 K2 → LTC … (R I) K1 V1 V2 →
-                        S K1 K2 → S (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
-                     ) →
-                     ∀L2,L1. TC … (lpx_sn R) L1 L2 → S L1 L2.
-#R #HR #S #IH1 #IH2 #L2 elim L2 -L2
-[ #X #H >(TC_lpx_sn_inv_atom2 … H) -X //
-| #L2 #I #V2 #IHL2 #X #H
-  elim (TC_lpx_sn_inv_pair2 … H) // -H -HR
-  #L1 #V1 #HL12 #HV12 #H destruct /3 width=1 by/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_atom1: ∀R,L2. TC … (lpx_sn R) (⋆) L2 → L2 = ⋆.
-#R #L2 #H elim H -L2
-[ /2 width=2 by lpx_sn_inv_atom1/
-| #L #L2 #_ #HL2 #IHL1 destruct /2 width=2 by lpx_sn_inv_atom1/
-]
-qed-.
-
-fact TC_lpx_sn_inv_pair1_aux: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
-                              ∀L1,L2. TC … (lpx_sn R) L1 L2 →
-                              ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
-                              ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L2 = K2. ⓑ{I} V2.
-#R #HR #L1 #L2 #H @(TC_lpx_sn_ind … H) // -HR -L1 -L2
-[ #J #K #W #H destruct
-| #I #L1 #L2 #V1 #V2 #HL12 #HV12 #_ #J #K #W #H destruct /2 width=5 by ex3_2_intro/
-]
-qed-.
-
-lemma TC_lpx_sn_inv_pair1: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
-                           ∀I,K1,L2,V1. TC … (lpx_sn R) (K1.ⓑ{I}V1) L2 →
-                           ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L2 = K2. ⓑ{I} V2.
-/2 width=3 by TC_lpx_sn_inv_pair1_aux/ qed-.
-
-lemma TC_lpx_sn_inv_lpx_sn_LTC: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
-                                ∀L1,L2. TC … (lpx_sn R) L1 L2 →
-                                lpx_sn (λI.LTC … (R I)) L1 L2.
-/3 width=4 by TC_lpx_sn_ind, lpx_sn_pair/ qed-.
-
-(* Forward lemmas on transitive closure *************************************)
-
-lemma TC_lpx_sn_fwd_length: ∀R,L1,L2. TC … (lpx_sn R) L1 L2 → |L1| = |L2|.
-#R #L1 #L2 #H elim H -L2
-[ #L2 #HL12 >(lpx_sn_fwd_length … HL12) -HL12 //
-| #L #L2 #_ #HL2 #IHL1
-  >IHL1 -L1 >(lpx_sn_fwd_length … HL2) -HL2 //
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/ssta_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lpx_sn/ssta_llpx_sn.etc
deleted file mode 100644 (file)
index 3b1db6a..0000000
+++ /dev/null
@@ -1,44 +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/llpx_sn_ldrop.ma".
-include "basic_2/static/ssta.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ******************************)
-
-(* Properties on lazy sn pointwise extensions *******************************)
-
-lemma ssta_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
-                             (∀I.l_liftable (R I)) →
-                         ∀h,g,G. s_r_confluent1 … (ssta h g G) (llpx_sn R 0).
-#R #H1R #H2R #h #g #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
-[ /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
-| #G #Ls #Ks #V1s #W2s #V2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
-| #G #Ls #Ks #V1s #W1s #l #i #HLKs #Hl #HVW1s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HVW1s) -HLKs -HLKd -HVW1s /2 width=1 by/ (**) (* full auto too slow *)
-| #a #I #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubn/lsubn_lsubn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubn/lsubn_lsubn.etc
deleted file mode 100644 (file)
index 9ef3dda..0000000
+++ /dev/null
@@ -1,36 +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/dynamic/lsubn_nta.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
-
-(* Main properties **********************************************************)
-
-(* Note: new property *)
-theorem lsubn_trans: ∀h,L1,L. h ⊢ L1 :⊑ L → ∀L2. h ⊢ L :⊑ L2 → h ⊢ L1 :⊑ L2.
-#h #L1 #L #H elim H -L1 -L
-[ #X #H >(lsubn_inv_atom1 … H) -H //
-| #I #L1 #L #V #HL1 #H1W #IHL1 #X #H
-  elim (lsubn_inv_pair1 … H) -H * #L2
-  [ #HL2 #H #H2W destruct /4 width=1/
-  | #W #H1VW #H2VW #HL2 #H1 #H2 destruct /3 width=3/
-  ]
-| #L1 #L #V1 #W1 #H1VW1 #H2VW1 #HL1 #IHL1 #X #H
-  elim (lsubn_inv_pair1 … H) -H * #L2
-  [ #HL2 #H #HW destruct /3 width=1/
-  | #V #_ #_ #_ #_ #H destruct
-  ]
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/aaa_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/aaa_lpss.etc
deleted file mode 100644 (file)
index e930823..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/substitution/lpss_ldrop.ma".
-include "basic_2/static/aaa_lift.ma".
-
-(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
-
-(* Properties about sn parallel substitution ********************************)
-
-(* Note: lemma 500 *)
-lemma aaa_cpss_lpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A → ∀T2. L1 ⊢ T1 ▶* T2 →
-                          ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T2 ⁝ A.
-#L1 #T1 #A #H elim H -L1 -T1 -A
-[ #L1 #k #X #H
-  >(cpss_inv_sort1 … H) -H //
-| #I #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #X #H #L2 #HL12
-  elim (cpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
-  | * #Y #Z #V2 #H #HV12 #HV2
-    lapply (ldrop_mono … H … HLK1) -H #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #Z #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 /3 width=7/
-  ]
-| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=2/
-| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=1/
-| #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=3/
-| #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=1/
-]
-qed-.
-
-lemma aaa_cpss_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. L ⊢ T1 ▶* T2 → L ⊢ T2 ⁝ A.
-/2 width=5 by aaa_cpss_lpss_conf/ qed-.
-
-lemma aaa_lpss_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T ⁝ A.
-/2 width=5 by aaa_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpcs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpcs_lpss.etc
deleted file mode 100644 (file)
index 09d2975..0000000
+++ /dev/null
@@ -1,50 +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/computation/cprs_lpss.ma".
-include "basic_2/equivalence/cpcs_cpcs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
-
-(* Properties on sn parallel substitution for local environments ************)
-
-lemma cpcs_lpss_conf: ∀L1,T1,T2. L1 ⊢ T1 ⬌* T2 →
-                      ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T1 ⬌* T2.
-#L1 #T1 #T2 #H #L2 #HL12
-elim (cpcs_inv_cprs … H) -H #T #HT1 #HT2
-elim (cprs_lpss_conf_dx … HT1 … HL12) -HT1 #U1 #H1 #HTU1
-elim (cprs_lpss_conf_dx … HT2 … HL12) -L1 #U2 #H2 #HTU2
-elim (cpss_conf … H1 … H2) -T #U #HU1 #HU2
-lapply (cprs_cpss_trans … HTU1 … HU1) -U1
-lapply (cprs_cpss_trans … HTU2 … HU2) -U2 /2 width=3/
-qed-.
-
-lemma cpcs_cpss_lpss_conf: ∀L1,T,T2. L1 ⊢ T ⬌* T2 → ∀T1. L1 ⊢ T ▶* T1 →
-                           ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T1 ⬌* T2.
-#L1 #T #T2 #HT2 #T1 #HT1 #L2 #HL12
-lapply (cpcs_lpss_conf … HT2 … HL12) -HT2 #HT2
-elim (lpss_cpss_conf_dx … HT1 … HL12) -L1 #T0 #HT0 #HT10
-lapply (cpcs_cpss_conf … HT0 … HT2) -T #HT02
-lapply (cpcs_cpss_strap2 … HT10 … HT02) -T0 //
-qed-.
-
-lemma cpcs_cpss2_lpss_conf: ∀L1,T1,T2. L1 ⊢ T1 ⬌* T2 →
-                            ∀T3. L1 ⊢ T1 ▶* T3 → ∀T4. L1 ⊢ T2 ▶* T4 →
-                            ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T3 ⬌* T4.
-#L1 #T1 #T2 #HT12 #T3 #HT13 #T4 #HT24 #L2 #HL12
-lapply (cpcs_cpss_lpss_conf … HT12 … HT13 … HL12) -T1 #HT32
-elim (lpss_cpss_conf_dx … HT24 … HL12) -L1 #T #HT2 #HT4
-lapply (cpcs_cpss_strap1 … HT32 … HT2) -T2 #HT3
-lapply (cpcs_cpss_div … HT3 … HT4) -T //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs.etc
deleted file mode 100644 (file)
index 4112036..0000000
+++ /dev/null
@@ -1,227 +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 "hvbox( L ⊢ break term 46 T1 ➤ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PRestStar $L $T1 $T2 }.
-
-include "basic_2/substitution/cpss.ma".
-
-(* CONTEXT-SENSITIVE RESTRICTED PARALLEL COMPUTATION FOR TERMS **************)
-
-inductive cpqs: lenv → relation term ≝
-| cpqs_atom : ∀I,L. cpqs L (⓪{I}) (⓪{I})
-| cpqs_delta: ∀L,K,V,V2,W2,i.
-              ⇩[0, i] L ≡ K. ⓓV → cpqs K V V2 →
-              ⇧[0, i + 1] V2 ≡ W2 → cpqs L (#i) W2
-| cpqs_bind : ∀a,I,L,V1,V2,T1,T2.
-              cpqs L V1 V2 → cpqs (L. ⓑ{I} V1) T1 T2 →
-              cpqs L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| cpqs_flat : ∀I,L,V1,V2,T1,T2.
-              cpqs L V1 V2 → cpqs L T1 T2 →
-              cpqs L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-| cpqs_zeta : ∀L,V,T1,T,T2. cpqs (L.ⓓV) T1 T →
-              ⇧[0, 1] T2 ≡ T → cpqs L (+ⓓV. T1) T2
-| cpqs_tau  : ∀L,V,T1,T2. cpqs L T1 T2 → cpqs L (ⓝV. T1) T2
-.
-
-interpretation "context-sensitive restricted parallel computation (term)"
-   'PRestStar L T1 T2 = (cpqs L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma cpqs_lsubr_trans: lsub_trans … cpqs lsubr.
-#L1 #T1 #T2 #H elim H -L1 -T1 -T2
-[ //
-| #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (lsubr_fwd_ldrop2_abbr … HL12 … HLK1) -HL12 -HLK1 /3 width=6/
-| /4 width=1/
-|4,6: /3 width=1/
-| /4 width=3/
-]
-qed-.
-
-lemma cpss_cpqs: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➤* T2.
-#L #T1 #T2 #H elim H -L -T1 -T2 // /2 width=1/ /2 width=6/
-qed.
-
-lemma cpqs_refl: ∀T,L. L ⊢ T ➤* T.
-/2 width=1/ qed.
-
-lemma cpqs_delift: ∀L,K,V,T1,d. ⇩[0, d] L ≡ (K. ⓓV) →
-                   ∃∃T2,T. L ⊢ T1 ➤* T2 & ⇧[d, 1] T ≡ T2.
-#L #K #V #T1 #d #HLK
-elim (cpss_delift … T1 … HLK) -HLK /3 width=4/
-qed-.
-
-lemma cpqs_append: l_appendable_sn … cpqs.
-#K #T1 #T2 #H elim H -K -T1 -T2 // /2 width=1/ /2 width=3/
-#K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
-lapply (ldrop_fwd_length_lt2 … HK0) #H
-@(cpqs_delta … (L@@K0) V1 … HVW2) //
-@(ldrop_O1_append_sn_le … HK0) /2 width=2/ (**) (* /3/ does not work *)
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact cpqs_inv_atom1_aux: ∀L,T1,T2. L ⊢ T1 ➤* T2 → ∀I. T1 = ⓪{I} →
-                         T2 = ⓪{I} ∨
-                         ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
-                                     K ⊢ V ➤* V2 &
-                                     ⇧[O, i + 1] V2 ≡ T2 &
-                                     I = LRef i.
-#L #T1 #T2 * -L -T1 -T2
-[ #I #L #J #H destruct /2 width=1/
-| #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #J #H destruct /3 width=8/
-| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-| #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-| #L #V #T1 #T #T2 #_ #_ #J #H destruct
-| #L #V #T1 #T2 #_ #J #H destruct
-]
-qed-.
-
-lemma cpqs_inv_atom1: ∀I,L,T2. L ⊢ ⓪{I} ➤* T2 →
-                      T2 = ⓪{I} ∨
-                      ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
-                                  K ⊢ V ➤* V2 &
-                                  ⇧[O, i + 1] V2 ≡ T2 &
-                                  I = LRef i.
-/2 width=3 by cpqs_inv_atom1_aux/ qed-.
-
-lemma cpqs_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ➤* T2 → T2 = ⋆k.
-#L #T2 #k #H
-elim (cpqs_inv_atom1 … H) -H //
-* #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-lemma cpqs_inv_lref1: ∀L,T2,i. L ⊢ #i ➤* T2 →
-                      T2 = #i ∨
-                      ∃∃K,V,V2. ⇩[O, i] L ≡ K. ⓓV &
-                                K ⊢ V ➤* V2 &
-                                ⇧[O, i + 1] V2 ≡ T2.
-#L #T2 #i #H
-elim (cpqs_inv_atom1 … H) -H /2 width=1/
-* #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=6/
-qed-.
-
-lemma cpqs_inv_gref1: ∀L,T2,p. L ⊢ §p ➤* T2 → T2 = §p.
-#L #T2 #p #H
-elim (cpqs_inv_atom1 … H) -H //
-* #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-fact cpqs_inv_bind1_aux: ∀L,U1,U2. L ⊢ U1 ➤* U2 →
-                         ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 → (
-                         ∃∃V2,T2. L ⊢ V1 ➤* V2 &
-                                  L. ⓑ{I} V1 ⊢ T1 ➤* T2 &
-                                  U2 = ⓑ{a,I} V2. T2
-                         ) ∨
-                         ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
-#L #U1 #U2 * -L -U1 -U2
-[ #I #L #b #J #W1 #U1 #H destruct
-| #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W1 #U1 #H destruct
-| #a #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W1 #U1 #H destruct /3 width=5/
-| #I #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W1 #U1 #H destruct
-| #L #V #T1 #T #T2 #HT1 #HT2 #b #J #W1 #U1 #H destruct /3 width=3/
-| #L #V #T1 #T2 #_ #b #J #W1 #U1 #H destruct
-]
-qed-.
-
-lemma cpqs_inv_bind1: ∀a,I,L,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ➤* U2 → (
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
-                               L. ⓑ{I} V1 ⊢ T1 ➤* T2 &
-                               U2 = ⓑ{a,I} V2. T2
-                      ) ∨
-                      ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
-/2 width=3 by cpqs_inv_bind1_aux/ qed-.
-
-lemma cpqs_inv_abbr1: ∀a,L,V1,T1,U2. L ⊢ ⓓ{a} V1. T1 ➤* U2 → (
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
-                               L. ⓓ V1 ⊢ T1 ➤* T2 &
-                               U2 = ⓓ{a} V2. T2
-                      ) ∨
-                      ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true.
-#a #L #V1 #T1 #U2 #H
-elim (cpqs_inv_bind1 … H) -H * /3 width=3/ /3 width=5/
-qed-.
-
-lemma cpqs_inv_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a} V1. T1 ➤* U2 →
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
-                               L. ⓛ V1 ⊢ T1 ➤* T2 &
-                               U2 = ⓛ{a} V2. T2.
-#a #L #V1 #T1 #U2 #H
-elim (cpqs_inv_bind1 … H) -H *
-[ /3 width=5/
-| #T #_ #_ #_ #H destruct
-]
-qed-.
-
-fact cpqs_inv_flat1_aux: ∀L,U1,U2. L ⊢ U1 ➤* U2 →
-                         ∀I,V1,T1. U1 = ⓕ{I} V1. T1 → (
-                         ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
-                                  U2 = ⓕ{I} V2. T2
-                         ) ∨
-                         (L ⊢ T1 ➤* U2 ∧ I = Cast).
-#L #U1 #U2 * -L -U1 -U2
-[ #I #L #J #W1 #U1 #H destruct
-| #L #K #V #V2 #W2 #i #_ #_ #_ #J #W1 #U1 #H destruct
-| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #W1 #U1 #H destruct
-| #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W1 #U1 #H destruct /3 width=5/
-| #L #V #T1 #T #T2 #_ #_ #J #W1 #U1 #H destruct
-| #L #V #T1 #T2 #HT12 #J #W1 #U1 #H destruct /3 width=1/
-]
-qed-.
-
-lemma cpqs_inv_flat1: ∀I,L,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ➤* U2 → (
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
-                               U2 = ⓕ{I} V2. T2
-                      ) ∨
-                      (L ⊢ T1 ➤* U2 ∧ I = Cast).
-/2 width=3 by cpqs_inv_flat1_aux/ qed-.
-
-lemma cpqs_inv_appl1: ∀L,V1,T1,U2. L ⊢ ⓐ V1. T1 ➤* U2 →
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
-                               U2 = ⓐ V2. T2.
-#L #V1 #T1 #U2 #H elim (cpqs_inv_flat1 … H) -H *
-[ /3 width=5/
-| #_ #H destruct
-]
-qed-.
-
-lemma cpqs_inv_cast1: ∀L,V1,T1,U2. L ⊢ ⓝ V1. T1 ➤* U2 → (
-                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
-                               U2 = ⓝ V2. T2
-                      ) ∨
-                      L ⊢ T1 ➤* U2.
-#L #V1 #T1 #U2 #H elim (cpqs_inv_flat1 … H) -H * /2 width=1/ /3 width=5/
-qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma cpqs_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ➤* T →
-                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #L #T1 #T #HT1
-  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #L #T1 #X
-  >shift_append_assoc normalize #H
-  elim (cpqs_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 ] // /2 width=3/ (**) (* explicit constructor *)
-  | #T #_ #_ #H destruct
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpqs_lift.etc
deleted file mode 100644 (file)
index 78529b6..0000000
+++ /dev/null
@@ -1,81 +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/unfold/cpqs.ma".
-
-(* CONTEXT-SENSITIVE RESTRICTED PARALLEL COMPUTATION FOR TERMS **************)
-
-(* Relocation properties ****************************************************)
-
-lemma cpqs_lift: l_liftable cpqs.
-#K #T1 #T2 #H elim H -K -T1 -T2
-[ #I #K #L #d #e #_ #U1 #H1 #U2 #H2
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #d #e #HLK #U1 #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
-    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2/ #X #HLK #H
-    elim (ldrop_inv_skip2 … H) -H /2 width=1/ -Hid #K #Y #HKV #HVY #H destruct /3 width=8/
-  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 // /2 width=1/ >plus_plus_comm_23 #HVU2
-    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=6/
-  ]
-| #a #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=5/
-| #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
-| #K #V #T1 #T #T2 #_ #HT2 #IHT1 #L #d #e #HLK #U1 #H #U2 #HTU2
-  elim (lift_inv_bind1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct
-  elim (lift_conf_O1 … HTU2 … HT2) -T2 /4 width=5/
-| #K #V #T1 #T2 #_ #IHT12 #L #d #e #HLK #U1 #H #U2 #HTU2
-  elim (lift_inv_flat1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct /3 width=5/
-] 
-qed.
-
-lemma cpqs_inv_lift1: l_deliftable_sn cpqs.
-#L #U1 #U2 #H elim H -L -U1 -U2
-[ * #L #i #K #d #e #_ #T1 #H
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
-  ]
-| #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #d #e #HLK #T1 #H
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
-    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
-    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m // -Hid /3 width=8/
-  | elim (le_inv_plus_l … Hid) #Hdie #Hei
-    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
-    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
-    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O /3 width=8/
-  ]
-| #a #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=5/
-| #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -V1
-  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5/
-| #L #V #U1 #U #U2 #_ #HU2 #IHU1 #K #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHU1 (K.ⓓW1) … HTU1) /2 width=1/ -L -U1 #T #HTU #HT1
-  elim (lift_div_le … HU2 … HTU) -U // /3 width=5/
-| #L #V #U1 #U2 #_ #IHU12 #K #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHU12 … HLK … HTU1) -L -U1 /3 width=3/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cprs_lpss.etc
deleted file mode 100644 (file)
index 9887fa7..0000000
+++ /dev/null
@@ -1,92 +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/lpss_lpss.ma".
-include "basic_2/reduction/lpr_lpss.ma".
-include "basic_2/computation/cprs.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
-
-(* Properties on parallel substitution for terms ****************************)
-
-(* Basic_1: was: pr3_subst1 *)
-lemma cprs_cpss_conf: ∀L,T0,T1. L ⊢ T0 ➡* T1 → ∀T2. L ⊢ T0 ▶* T2 →
-                      ∃∃T. L ⊢ T1 ▶* T & L ⊢ T2 ➡* T.
-#L @TC_strip1 /2 width=3 by cpr_cpss_conf/ qed-. (**) (* auto /3 width=3/ fails because a δ-expansion gets in the way *)
-
-(* Properties on sn parallel substitution for local environments ************)
-
-lemma cprs_lpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➡* T1 → ∀L1. L0 ⊢ ▶* L1 →
-                         ∃∃T. L1 ⊢ T1 ▶* T & L1 ⊢ T0 ➡* T.
-#L0 #T0 #T1 #H elim H -T1
-[ #T1 #HT01 #L1 #HL01
-  elim (cpr_lpss_conf_dx … HT01 … HL01) -L0 /3 width=3/
-| #T #T1 #_ #HT1 #IHT0 #L1 #HL01
-  elim (IHT0 … HL01) #T2 #HT2 #HT02
-  elim (cpr_lpss_conf_dx … HT1 … HL01) -L0 #T3 #HT13 #HT3
-  elim (cpr_cpss_conf … HT3 … HT2) -T #T #HT3 #HT2
-  lapply (cpss_trans … HT13 … HT3) -T3
-  lapply (cprs_strap1 … HT02 … HT2) -T2 /2 width=3/
-]
-qed-.
-
-lemma cprs_lpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➡* T1 → ∀L1. L0 ⊢ ▶* L1 →
-                         ∃∃T. L0 ⊢ T1 ▶* T & L1 ⊢ T0 ➡* T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cprs_lpss_conf_dx … HT01 … HL01) -HT01 #T #HT1
-lapply (lpss_cpss_trans … HL01 … HT1) -HT1 /2 width=3/
-qed-.
-
-lemma cprs_cpss_lpss_conf_sn: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
-                              ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
-                              ∃∃U2. L2 ⊢ T2 ➡* U2 & L1 ⊢ U1 ▶* U2.
-#L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
-elim (cprs_cpss_conf … HTU1 … HT12) -T1 #U #HU1 #HT2U
-elim (cprs_lpss_conf_sn … HT2U … HL12) -HT2U -HL12 #U2 #HU2 #HTU2
-lapply (cpss_trans … HU1 … HU2) -U /2 width=3/
-qed-.
-
-lemma cprs_cpss_lpss_conf_dx: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
-                              ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
-                              ∃∃U2. L2 ⊢ T2 ➡* U2 & L2 ⊢ U1 ▶* U2.
-#L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
-elim (cprs_lpss_conf_dx … HTU1 … HL12) -HTU1 #U2 #HU12 #HT1U2
-elim (lpss_cpss_conf_dx … HT12 … HL12) -L1 #T #HT1 #HT2
-elim (cprs_cpss_conf … HT1U2 … HT1) -T1 #U #HU2 #HTU
-lapply (cpss_trans … HU12 … HU2) -U2
-lapply (cpss_cprs_trans … HT2 … HTU) -T /2 width=3/
-qed-.
-
-
-lemma cprs_cpss2_lpss_conf_sn: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 → ∀T2. L1 ⊢ T1 ▶* T2 →
-                               ∀U2. L1 ⊢ U1 ▶* U2 → ∀L2. L1 ⊢ ▶* L2 →
-                               ∃∃U. L2 ⊢ T2 ➡* U & L1 ⊢ U2 ▶* U.
-#L1 #T1 #U1 #HTU1 #T2 #HT12 #U2 #HU12 #L2 #HL12
-elim (cprs_cpss_lpss_conf_sn … HTU1 … HT12 … HL12) -T1 #T1 #HT21 #HUT1
-elim (cpss_conf … HU12 … HUT1) -U1 #U1 #HU21 #HTU1
-elim (lpss_cpss_conf_sn … HTU1 … HL12) -HTU1 -HL12 #U2 #HT1U2 #HU12
-lapply (cpss_trans … HU21 … HU12) -U1
-lapply (cprs_cpss_trans … HT21 … HT1U2) -T1 /2 width=3/
-qed-.
-
-lemma cprs_cpss2_lpss_conf_dx: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 → ∀T2. L1 ⊢ T1 ▶* T2 →
-                               ∀U2. L1 ⊢ U1 ▶* U2 → ∀L2. L1 ⊢ ▶* L2 →
-                               ∃∃U. L2 ⊢ T2 ➡* U & L2 ⊢ U2 ▶* U.
-#L1 #T1 #U1 #HTU1 #T2 #HT12 #U2 #HU12 #L2 #HL12
-elim (cprs_cpss_lpss_conf_dx … HTU1 … HT12 … HL12) -T1 #T1 #HT21 #HUT1
-elim (lpss_cpss_conf_dx … HU12 … HL12) -L1 #U #HU1 #HU2
-elim (cpss_conf … HU1 … HUT1) -U1 #U1 #HU1 #HTU1
-lapply (cpss_trans … HU2 … HU1) -U
-lapply (cprs_cpss_trans … HT21 … HTU1) -T1 /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss.etc
deleted file mode 100644 (file)
index 16b9608..0000000
+++ /dev/null
@@ -1,199 +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 "hvbox( L ⊢ break term 46 T1 ▶* break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStar $L $T1 $T2 }.
-
-include "basic_2/grammar/cl_shift.ma".
-include "basic_2/relocation/ldrop_append.ma".
-include "basic_2/substitution/lsubr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL SUBSTITUTION FOR TERMS ************************)
-
-inductive cpss: lenv → relation term ≝
-| cpss_atom : ∀I,L. cpss L (⓪{I}) (⓪{I})
-| cpss_delta: ∀L,K,V,V2,W2,i.
-              ⇩[0, i] L ≡ K. ⓓV → cpss K V V2 →
-              ⇧[0, i + 1] V2 ≡ W2 → cpss L (#i) W2
-| cpss_bind : ∀a,I,L,V1,V2,T1,T2.
-              cpss L V1 V2 → cpss (L. ⓑ{I} V1) T1 T2 →
-              cpss L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
-| cpss_flat : ∀I,L,V1,V2,T1,T2.
-              cpss L V1 V2 → cpss L T1 T2 →
-              cpss L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
-.
-
-interpretation "context-sensitive parallel substitution (term)"
-   'PSubstStar L T1 T2 = (cpss L T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma cpss_lsubr_trans: lsub_trans … cpss lsubr.
-#L1 #T1 #T2 #H elim H -L1 -T1 -T2
-[ //
-| #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
-  elim (lsubr_fwd_ldrop2_abbr … HL12 … HLK1) -HL12 -HLK1 /3 width=6/
-| /4 width=1/
-| /3 width=1/
-]
-qed-.
-
-(* Basic_1: was by definition: subst1_refl *)
-lemma cpss_refl: ∀T,L. L ⊢ T ▶* T.
-#T elim T -T //
-#I elim I -I /2 width=1/
-qed.
-
-(* Basic_1: was only: subst1_ex *)
-lemma cpss_delift: ∀K,V,T1,L,d. ⇩[0, d] L ≡ (K. ⓓV) →
-                   ∃∃T2,T. L ⊢ T1 ▶* T2 & ⇧[d, 1] T ≡ T2.
-#K #V #T1 elim T1 -T1
-[ * #i #L #d #HLK /2 width=4/
-  elim (lt_or_eq_or_gt i d) #Hid /3 width=4/
-  destruct
-  elim (lift_total V 0 (i+1)) #W #HVW
-  elim (lift_split … HVW i i) // /3 width=6/
-| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
-  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
-  [ elim (IHU1 (L. ⓑ{I} W1) (d+1)) -IHU1 /2 width=1/ -HLK /3 width=9/
-  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8/
-  ]
-]
-qed-.
-
-lemma cpss_append: l_appendable_sn … cpss.
-#K #T1 #T2 #H elim H -K -T1 -T2 // /2 width=1/
-#K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
-lapply (ldrop_fwd_length_lt2 … HK0) #H
-@(cpss_delta … (L@@K0) V1 … HVW2) //
-@(ldrop_O1_append_sn_le … HK0) /2 width=2/ (**) (* /3/ does not work *)
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact cpss_inv_atom1_aux: ∀L,T1,T2. L ⊢ T1 ▶* T2 → ∀I. T1 = ⓪{I} →
-                         T2 = ⓪{I} ∨
-                         ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
-                                     K ⊢ V ▶* V2 &
-                                     ⇧[O, i + 1] V2 ≡ T2 &
-                                     I = LRef i.
-#L #T1 #T2 * -L -T1 -T2
-[ #I #L #J #H destruct /2 width=1/
-| #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #I #H destruct /3 width=8/
-| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-| #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
-]
-qed-.
-
-lemma cpss_inv_atom1: ∀I,L,T2. L ⊢ ⓪{I} ▶* T2 →
-                      T2 = ⓪{I} ∨
-                      ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
-                                  K ⊢ V ▶* V2 &
-                                  ⇧[O, i + 1] V2 ≡ T2 &
-                                  I = LRef i.
-/2 width=3 by cpss_inv_atom1_aux/ qed-.
-
-(* Basic_1: was only: subst1_gen_sort *)
-lemma cpss_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ▶* T2 → T2 = ⋆k.
-#L #T2 #k #H
-elim (cpss_inv_atom1 … H) -H //
-* #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-(* Basic_1: was only: subst1_gen_lref *)
-lemma cpss_inv_lref1: ∀L,T2,i. L ⊢ #i ▶* T2 →
-                      T2 = #i ∨
-                      ∃∃K,V,V2. ⇩[O, i] L ≡ K. ⓓV &
-                                K ⊢ V ▶* V2 &
-                                ⇧[O, i + 1] V2 ≡ T2.
-#L #T2 #i #H
-elim (cpss_inv_atom1 … H) -H /2 width=1/
-* #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=6/
-qed-.
-
-lemma cpss_inv_gref1: ∀L,T2,p. L ⊢ §p ▶* T2 → T2 = §p.
-#L #T2 #p #H
-elim (cpss_inv_atom1 … H) -H //
-* #K #V #V2 #i #_ #_ #_ #H destruct
-qed-.
-
-fact cpss_inv_bind1_aux: ∀L,U1,U2. L ⊢ U1 ▶* U2 →
-                         ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
-                         ∃∃V2,T2. L ⊢ V1 ▶* V2 &
-                                  L. ⓑ{I} V1 ⊢ T1 ▶* T2 &
-                                  U2 = ⓑ{a,I} V2. T2.
-#L #U1 #U2 * -L -U1 -U2
-[ #I #L #b #J #W1 #U1 #H destruct
-| #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W1 #U1 #H destruct
-| #a #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W1 #U1 #H destruct /2 width=5/
-| #I #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W1 #U1 #H destruct
-]
-qed-.
-
-lemma cpss_inv_bind1: ∀a,I,L,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶* U2 →
-                      ∃∃V2,T2. L ⊢ V1 ▶* V2 &
-                               L. ⓑ{I} V1 ⊢ T1 ▶* T2 &
-                               U2 = ⓑ{a,I} V2. T2.
-/2 width=3 by cpss_inv_bind1_aux/ qed-.
-
-fact cpss_inv_flat1_aux: ∀L,U1,U2. L ⊢ U1 ▶* U2 →
-                         ∀I,V1,T1. U1 = ⓕ{I} V1. T1 →
-                         ∃∃V2,T2. L ⊢ V1 ▶* V2 & L ⊢ T1 ▶* T2 &
-                                  U2 =  ⓕ{I} V2. T2.
-#L #U1 #U2 * -L -U1 -U2
-[ #I #L #J #W1 #U1 #H destruct
-| #L #K #V #V2 #W2 #i #_ #_ #_ #J #W1 #U1 #H destruct
-| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #W1 #U1 #H destruct
-| #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W1 #U1 #H destruct /2 width=5/
-]
-qed-.
-
-lemma cpss_inv_flat1: ∀I,L,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶* U2 →
-                      ∃∃V2,T2. L ⊢ V1 ▶* V2 & L ⊢ T1 ▶* T2 &
-                               U2 =  ⓕ{I} V2. T2.
-/2 width=3 by cpss_inv_flat1_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma cpss_fwd_tw: ∀L,T1,T2. L ⊢ T1 ▶* T2 → ♯{T1} ≤ ♯{T2}.
-#L #T1 #T2 #H elim H -L -T1 -T2 normalize
-/3 width=1 by monotonic_le_plus_l, le_plus/ (**) (* auto is too slow without trace *)
-qed-.
-
-lemma cpss_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ▶* T →
-                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1 normalize
-[ #L #T1 #T #HT1
-  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
-| #I #L1 #V1 #IH #L #T1 #X
-  >shift_append_assoc normalize #H
-  elim (cpss_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 ] // /2 width=3/ (**) (* explicit constructor *)
-]
-qed-.
-
-(* Basic_1: removed theorems 27:
-            subst0_gen_sort subst0_gen_lref subst0_gen_head subst0_gen_lift_lt
-            subst0_gen_lift_false subst0_gen_lift_ge subst0_refl subst0_trans
-            subst0_lift_lt subst0_lift_ge subst0_lift_ge_S subst0_lift_ge_s
-            subst0_subst0 subst0_subst0_back subst0_weight_le subst0_weight_lt
-            subst0_confluence_neq subst0_confluence_eq subst0_tlt_head
-            subst0_confluence_lift subst0_tlt
-            subst1_head subst1_gen_head subst1_lift_S subst1_confluence_lift
-            subst1_gen_lift_eq subst1_confluence_neq
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/cpss_lift.etc
deleted file mode 100644 (file)
index 9745b6c..0000000
+++ /dev/null
@@ -1,71 +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/substitution/cpss.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL SUBSTITUTION FOR TERMS ************************)
-
-(* Relocation properties ****************************************************)
-
-(* Basic_1: was only: subst1_lift_lt subst1_lift_ge *)
-lemma cpss_lift: l_liftable cpss.
-#K #T1 #T2 #H elim H -K -T1 -T2
-[ #I #K #L #d #e #_ #U1 #H1 #U2 #H2
-  >(lift_mono … H1 … H2) -H1 -H2 //
-| #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #d #e #HLK #U1 #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
-    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2/ #X #HLK #H
-    elim (ldrop_inv_skip2 … H) -H /2 width=1/ -Hid #K #Y #HKV #HVY #H destruct /3 width=8/
-  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 // /2 width=1/ >plus_plus_comm_23 #HVU2
-    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=6/
-  ]
-| #a #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=5/
-| #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
-  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
-]
-qed.
-
-(* Basic_1: was only: subst1_gen_lift_lt subst1_gen_lift_ge *)
-lemma cpss_inv_lift1: l_deliftable_sn cpss.
-#L #U1 #U2 #H elim H -L -U1 -U2
-[ * #L #i #K #d #e #_ #T1 #H
-  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
-  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
-  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
-  ]
-| #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #d #e #HLK #T1 #H
-  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
-  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
-    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
-    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m // -Hid /3 width=8/
-  | elim (le_inv_plus_l … Hid) #Hdie #Hei
-    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
-    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
-    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O /3 width=8/
-  ]
-| #a #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
-  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
-  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=5/
-| #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
-  elim (IHV12 … HLK … HWV1) -V1
-  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/dxprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/dxprs_lpss.etc
deleted file mode 100644 (file)
index a14c551..0000000
+++ /dev/null
@@ -1,46 +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/unfold/sstas_lpss.ma".
-include "basic_2/computation/cprs_lpss.ma".
-include "basic_2/computation/dxprs.ma".
-
-(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
-
-(* Properties about sn parallel substitution for local environments *********)
-
-lemma dxprs_lpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 → ∀L2. L1 ⊢ ▶* L2 →
-                       ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L1 ⊢ U1 ▶* U2.
-#h #g #L1 #T #U1 * #U #HTU #HU1 #L2 #HL12
-elim (sstas_lpss_conf … HTU … HL12) -HTU #U0 #HTU0 #HU0
-elim (cprs_cpss_conf … HU1 … HU0) -U #U #HU1 #HU0
-elim (cprs_lpss_conf_sn … HU0 … HL12) -HU0 -HL12 #U2 #HU2 #HU02
-lapply (cpss_trans … HU1 … HU2) -U /3 width=3/
-qed-.
-
-lemma dxprs_cpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*➡*[g] U1 → ∀T2. L ⊢ T1 ▶* T2 →
-                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*➡*[g] U2 & L ⊢ U1 ▶* U2.
-#h #g #L #T1 #U1 * #W1 #HTW1 #HWU1 #T2 #HT12
-elim (sstas_cpss_conf … HTW1 … HT12) -T1 #W2 #HTW2 #HW12
-elim (cprs_cpss_conf … HWU1 … HW12) -W1 /3 width=3/
-qed-.
-
-lemma dxprs_cpss_lpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*➡*[g] U1 →
-                            ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
-                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*➡*[g] U2 & L1 ⊢ U1 ▶* U2.
-#h #g #L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
-elim (dxprs_cpss_conf … HTU1 … HT12) -T1 #U2 #HTU2 #HU12
-elim (dxprs_lpss_conf … HTU2 … HL12) -HTU2 -HL12 #U #HT2U #HU2
-lapply (cpss_trans … HU12 … HU2) -U2 /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs.etc
deleted file mode 100644 (file)
index 402af46..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-notation "hvbox( T1 ⊢ ➤ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PRestStarSn $T1 $T2 }.
-
-include "basic_2/substitution/lpss.ma".
-include "basic_2/unfold/cpqs.ma".
-
-(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
-
-definition lpqs: relation lenv ≝ lpx_sn cpqs. 
-
-interpretation "restricted parallel computation (local environment, sn variant)"
-   'PRestStarSn L1 L2 = (lpqs L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lpqs_inv_atom1: ∀L2. ⋆ ⊢ ➤* L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-lemma lpqs_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ➤* L2 →
-                      ∃∃K2,V2. K1 ⊢ ➤* K2 & K1 ⊢ V1 ➤* V2 & L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-lemma lpqs_inv_atom2: ∀L1. L1 ⊢ ➤* ⋆ → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-lemma lpqs_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ➤* K2. ⓑ{I} V2 →
-                      ∃∃K1,V1. K1 ⊢ ➤* K2 & K1 ⊢ V1 ➤* V2 & L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lpqs_refl: ∀L. L ⊢ ➤* L.
-/2 width=1 by lpx_sn_refl/ qed.
-
-lemma lpqs_pair: ∀I,K1,K2,V1,V2. K1 ⊢ ➤* K2 → K1 ⊢ V1 ➤* V2 →
-                 K1.ⓑ{I}V1 ⊢ ➤* K2.ⓑ{I}V2.
-/2 width=1/ qed.
-
-lemma lpqs_append: ∀K1,K2. K1 ⊢ ➤* K2 → ∀L1,L2. L1 ⊢ ➤* L2 →
-                   L1 @@ K1 ⊢ ➤* L2 @@ K2.
-/3 width=1 by lpx_sn_append, cpqs_append/ qed.
-
-lemma lpss_lpqs: ∀L1,L2. L1 ⊢ ▶* L2 → L1 ⊢ ➤* L2.
-#L1 #L2 #H elim H -L1 -L2 // /3 width=1/
-qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpqs_fwd_length: ∀L1,L2. L1 ⊢ ➤* L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpqs_fwd_append1: ∀K1,L1,L. K1 @@ L1 ⊢ ➤* L →
-                        ∃∃K2,L2. K1 ⊢ ➤* K2 & L = K2 @@ L2.
-/2 width=2 by lpx_sn_fwd_append1/ qed-.
-
-lemma lpqs_fwd_append2: ∀L,K2,L2. L ⊢ ➤* K2 @@ L2 →
-                        ∃∃K1,L1. K1 ⊢ ➤* K2 & L = K1 @@ L1.
-/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_cpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_cpqs.etc
deleted file mode 100644 (file)
index 7b8f17b..0000000
+++ /dev/null
@@ -1,71 +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/grammar/lpx_sn_lpx_sn.ma".
-include "basic_2/substitution/fsupp.ma".
-include "basic_2/unfold/lpqs_ldrop.ma".
-
-(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
-
-(* Main properties on context-sensitive rest parallel computation for terms *)
-
-theorem cpqs_trans_lpqs: lpx_sn_transitive cpqs cpqs.
-#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L0 #T0 #IH #L1 * [|*]
-[ #I #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
-  elim (cpqs_inv_atom1 … H1) -H1
-  [ #H destruct
-    elim (cpqs_inv_atom1 … HT2) -HT2
-    [ #H destruct //
-    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
-      elim (lpqs_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
-      elim (lpqs_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
-      lapply (fsupp_lref … HLK1) /3 width=9/
-    ]
-  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
-    elim (lpqs_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-    elim (lpqs_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-    elim (cpqs_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
-    lapply (fsupp_lref … HLK1) /3 width=9/
-  ]
-| #a #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpqs_inv_bind1 … H1) -H1 *
-  [ #V #T #HV1 #HT1 #H destruct
-    elim (cpqs_inv_bind1 … H2) -H2 *
-    [ #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
-    | #T2 #HT2 #HXT2 #H1 #H2 destruct /4 width=5/
-    ]
-  | #Y1 #HTY1 #HXY1 #H11 #H12 destruct
-    elim (lift_total X2 0 1) #Y2 #HXY2
-    lapply (cpqs_lift … H2 (L2.ⓓV1) … HXY1 … HXY2) /2 width=1/ -X1 /4 width=5/
-  ]
-| #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpqs_inv_flat1 … H1) -H1 *
-  [ #V #T #HV1 #HT1 #H destruct
-    elim (cpqs_inv_flat1 … H2) -H2 *
-    [ #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
-    | #HX2 #H destruct /3 width=5/
-    ]
-  | #HX1 #H destruct /3 width=5/
-]
-qed-.
-
-theorem cpqs_trans: ∀L. Transitive … (cpqs L).
-/2 width=5 by cpqs_trans_lpqs/ qed-.
-
-(* Properties on context-sensitive rest. parallel computation for terms *****)
-
-lemma lpqs_cpqs_trans: ∀L1,L2. L1 ⊢ ➤* L2 →
-                       ∀T1,T2. L2 ⊢ T1 ➤* T2 → L1 ⊢ T1 ➤* T2.
-/2 width=5 by cpqs_trans_lpqs/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_ldrop.etc
deleted file mode 100644 (file)
index e121c0c..0000000
+++ /dev/null
@@ -1,47 +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/fsup.ma".
-include "basic_2/relocation/ldrop_lpx_sn.ma".
-include "basic_2/unfold/cpqs_lift.ma".
-include "basic_2/unfold/lpqs.ma".
-
-(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
-
-(* Properies on local environment slicing ***********************************)
-
-lemma lpqs_ldrop_conf: dropable_sn lpqs.
-/3 width=5 by lpx_sn_deliftable_dropable, cpqs_inv_lift1/ qed-.
-
-lemma ldrop_lpqs_trans: dedropable_sn lpqs.
-/3 width=9 by lpx_sn_liftable_dedropable, cpqs_lift/ qed-.
-
-lemma lpqs_ldrop_trans_O1: dropable_dx lpqs.
-/2 width=3 by lpx_sn_dropable/ qed-.
-
-(* Properties on context-sensitive rest. parallel computation for terms *****)
-
-lemma fsup_cpqs_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ➤* U2 →
-                       ∃∃L,U1. L1 ⊢ ➤* L & L ⊢ T1 ➤* U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [2: * ] [1,2,3,4,5: /3 width=5/ ]
-[ #L #K #U #T #d #e #HLK #HUT #He #U2 #HU2
-  elim (lift_total U2 d e) #T2 #HUT2
-  lapply (cpqs_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9/
-| #L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-  elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
-  elim (lift_total T d e) #U #HTU
-  elim (ldrop_lpqs_trans … HLK1 … HK1) -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (cpqs_lift … HT1 … HL2K … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_lpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpqs_lpqs.etc
deleted file mode 100644 (file)
index 13f221e..0000000
+++ /dev/null
@@ -1,267 +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/unfold/lpqs_cpqs.ma".
-
-(* SN RESTRICTED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *****************)
-
-(* Main properties on context-sensitive rest parallel computation for terms *)
-
-fact cpqs_conf_lpqs_atom_atom:
-   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ➤* T & L2 ⊢ ⓪{I} ➤* T.
-/2 width=3/ qed-.
-
-fact cpqs_conf_lpqs_atom_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V2. K0 ⊢ V0 ➤* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ #i ➤* T & L2 ⊢ T2 ➤* T.
-#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-elim (lpqs_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpqs_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
-elim (lpqs_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpqs_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpqs_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
-qed-.
-
-fact cpqs_conf_lpqs_delta_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V1. K0 ⊢ V0 ➤* V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
-   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
-   ∀V2. KX ⊢ VX ➤* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ T1 ➤* T & L2 ⊢ T2 ➤* T.
-#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
-#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-lapply (ldrop_mono … H … HLK0) -H #H destruct
-elim (lpqs_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpqs_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
-elim (lpqs_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpqs_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpqs_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
-lapply (cpqs_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
-qed-.
-
-fact cpqs_conf_lpqs_bind_bind:
-   ∀a,I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ➤* T1 →
-   ∀V2. L0 ⊢ V0 ➤* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ➤* T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ➤* T & L2 ⊢ ⓑ{a,I}V2.T2 ➤* T.
-#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
-qed-.
-
-fact cpqs_conf_lpqs_bind_zeta:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0.ⓓV0 ⊢ T0 ➤* T1 →
-   ∀T2. L0.ⓓV0 ⊢ T0 ➤* T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ +ⓓV1.T1 ➤* T & L2 ⊢ X2 ➤* T.
-#L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 (L1.ⓓV1) … (L2.ⓓV1)) -IH -HT01 -HT02 // /2 width=1/ -L0 -V0 -T0 #T #HT1 #HT2
-elim (cpqs_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=1/ /3 width=3/
-qed-.
-
-fact cpqs_conf_lpqs_zeta_zeta:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀T1. L0.ⓓV0 ⊢ T0 ➤* T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
-   ∀T2. L0.ⓓV0 ⊢ T0 ➤* T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ X1 ➤* T & L2 ⊢ X2 ➤* T.
-#L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
-#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 (L1.ⓓV0) … (L2.ⓓV0)) -IH -HT01 -HT02 // /2 width=1/ -L0 -T0 #T #HT1 #HT2
-elim (cpqs_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=1/ #T1 #HT1 #HXT1
-elim (cpqs_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=1/ #T2 #HT2 #HXT2 
-lapply (lift_inj … HT2 … HT1) -T #H destruct /2 width=3/
-qed-.
-
-fact cpqs_conf_lpqs_flat_flat:
-   ∀I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0 ⊢ T0 ➤* T1 →
-   ∀V2. L0 ⊢ V0 ➤* V2 → ∀T2. L0 ⊢ T0 ➤* T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ➤* T & L2 ⊢ ⓕ{I}V2.T2 ➤* T.
-#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
-qed-.
-
-fact cpqs_conf_lpqs_flat_tau:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀V1,T1. L0 ⊢ T0 ➤* T1 → ∀T2. L0 ⊢ T0 ➤* T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ ⓝV1.T1 ➤* T & L2 ⊢ T2 ➤* T.
-#L0 #V0 #T0 #IH #V1 #T1 #HT01
-#T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /3 width=3/
-qed-.
-
-fact cpqs_conf_lpqs_tau_tau:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
-      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
-      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
-   ) →
-   ∀T1. L0 ⊢ T0 ➤* T1 → ∀T2. L0 ⊢ T0 ➤* T2 →
-   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
-   ∃∃T. L1 ⊢ T1 ➤* T & L2 ⊢ T2 ➤* T.
-#L0 #V0 #T0 #IH #T1 #HT01
-#T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /2 width=3/
-qed-.
-
-theorem cpqs_conf_lpqs: lpx_sn_confluent cpqs cpqs.
-#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
-[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpqs_inv_atom1 … H1) -H1
-  elim (cpqs_inv_atom1 … H2) -H2
-  [ #H2 #H1 destruct
-    /2 width=1 by cpqs_conf_lpqs_atom_atom/
-  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
-    /3 width=10 by cpqs_conf_lpqs_atom_delta/
-  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
-    /4 width=10 by ex2_commute, cpqs_conf_lpqs_atom_delta/
-  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
-    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
-    /3 width=17 by cpqs_conf_lpqs_delta_delta/
-  ]
-| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpqs_inv_bind1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #T1 #HT01 #HXT1 #H11 #H12
-  ]
-  elim (cpqs_inv_bind1 … H2) -H2 *
-  [1,3: #V2 #T2 #HV02 #HT02 #H2
-  |2,4: #T2 #HT02 #HXT2 #H21 #H22
-  ] destruct
-  [ /3 width=10 by cpqs_conf_lpqs_bind_bind/
-  | /4 width=11 by ex2_commute, cpqs_conf_lpqs_bind_zeta/
-  | /3 width=11 by cpqs_conf_lpqs_bind_zeta/
-  | /3 width=12 by cpqs_conf_lpqs_zeta_zeta/
-  ]
-| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpqs_inv_flat1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #HX1 #H1
-  ]
-  elim (cpqs_inv_flat1 … H2) -H2 *
-  [1,3: #V2 #T2 #HV02 #HT02 #H2
-  |2,4: #HX2 #H2
-  ] destruct
-  [ /3 width=10 by cpqs_conf_lpqs_flat_flat/
-  | /4 width=8 by ex2_commute, cpqs_conf_lpqs_flat_tau/
-  | /3 width=8 by cpqs_conf_lpqs_flat_tau/
-  | /3 width=7 by cpqs_conf_lpqs_tau_tau/
-  ]
-]
-qed-.
-
-theorem cpqs_conf: ∀L. confluent … (cpqs L).
-/2 width=6 by cpqs_conf_lpqs/ qed-.
-
-(* Properties on context-sensitive rest. parallel computation for terms *****)
-
-lemma lpqs_cpqs_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➤* T1 → ∀L1. L0 ⊢ ➤* L1 →
-                         ∃∃T. L1 ⊢ T0 ➤* T & L1 ⊢ T1 ➤* T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpqs_conf_lpqs … HT01 T0 … HL01 … HL01) // -L0 /2 width=3/
-qed-.
-
-lemma lpqs_cpqs_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➤* T1 → ∀L1. L0 ⊢ ➤* L1 →
-                         ∃∃T. L1 ⊢ T0 ➤* T & L0 ⊢ T1 ➤* T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpqs_conf_lpqs … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
-qed-.
-
-(* Main properties **********************************************************)
-
-theorem lpqs_conf: confluent … lpqs.
-/3 width=6 by lpx_sn_conf, cpqs_conf_lpqs/
-qed-.
-
-theorem lpqs_trans: Transitive … lpqs.
-/3 width=5 by lpx_sn_trans, cpqs_trans_lpqs/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma cpqs_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ➤* T →
-                       ∃∃L2,T2. L @@ L1 ⊢ ➤* L @@ L2 & L @@ L1 ⊢ T1 ➤* T2 &
-                                T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1
-[ #L #T1 #T #HT1
-  @ex3_2_intro [3: // |4,5: // |1,2: skip ] (**) (* /2 width=4/ does not work *)
-| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
-  elim (cpqs_inv_bind1 … H) -H *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
-    lapply (lpqs_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1/ #HL12
-    @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
-  | #T #_ #_ #H destruct
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpr_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpr_lpss.etc
deleted file mode 100644 (file)
index 9ce690f..0000000
+++ /dev/null
@@ -1,279 +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/grammar/lpx_sn_lpx_sn.ma".
-include "basic_2/substitution/fsupp.ma".
-include "basic_2/substitution/lpss_ldrop.ma".
-include "basic_2/reduction/lpr_ldrop.ma".
-
-(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
-
-(* Properties on context-sensitive parallel substitution for terms **********)
-
-fact cpr_cpss_conf_lpr_lpss_atom_atom:
-   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ▶* T & L2 ⊢ ⓪{I} ➡ T.
-/2 width=3/ qed-.
-
-fact cpr_cpss_conf_lpr_lpss_atom_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V2. K0 ⊢ V0 ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ #i ▶* T & L2 ⊢ T2 ➡ T.
-#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpr_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
-elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpr_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_delta_atom:
-   ∀L0,i. (
-      ∀L,T.⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V1. K0 ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ #i ➡ T.
-#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1 #L1 #HL01 #L2 #HL02
-elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpss_inv_pair1 … H2) -H2 #K2 #V2 #HK02 #HV02 #H destruct
-elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpr_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1 /3 width=9/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_delta_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V1. K0 ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
-   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
-   ∀V2. KX ⊢ VX ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ T2 ➡ T.
-#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
-#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-lapply (ldrop_mono … H … HLK0) -H #H destruct
-elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpr_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
-elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
-lapply (cpr_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_bind_bind:
-   ∀a,I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ➡ T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ▶* T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ▶* T & L2 ⊢ ⓑ{a,I}V2.T2 ➡ T.
-#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_bind_zeta:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀T1. L0.ⓓV0 ⊢ T0 ➡ T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓓV0 ⊢ T0 ▶* T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ X1 ▶* T & L2 ⊢ +ⓓV2.T2 ➡ T.
-#L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 (L1.ⓓV2) … (L2.ⓓV2)) -IH -HT01 -HT02 // /2 width=1/ /3 width=1/ -L0 -V0 -T0 #T #HT1 #HT2
-elim (cpss_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=1/ /3 width=9/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_flat_flat:
-   ∀I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0 ⊢ T0 ➡ T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ T0 ▶* T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ▶* T & L2 ⊢ ⓕ{I}V2.T2 ➡ T.
-#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_flat_tau:
-   ∀L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀T1. L0 ⊢ T0 ➡ T1 → ∀V2,T2. L0 ⊢ T0 ▶* T2 → 
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ ⓝV2.T2 ➡ T.
-#L0 #V0 #T0 #IH #T1 #HT01
-#V2 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /3 width=3/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_flat_beta:
-   ∀a,L0,V0,W0,T0. (
-      ∀L,T. ⦃L0,ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0.ⓛW0 ⊢ T0 ➡ T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ ⓛ{a}W0.T0 ▶* T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓓ{a}V1.T1 ▶* T & L2 ⊢ ⓐV2.T2 ➡ T.
-#a #L0 #V0 #W0 #T0 #IH #V1 #HV01 #T1 #HT01 
-#V2 #HV02 #X #H #L1 #HL01 #L2 #HL02
-elim (cpss_inv_bind1 … H) -H #W2 #T2 #HW02 #HT02 #H destruct
-elim (IH … HV01 … HV02 … HL01 … HL02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
-elim (IH … HT01 … HT02 (L1.ⓛW2) … (L2.ⓛW2)) /2 width=1/ /3 width=1/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
-lapply (cpss_lsubr_trans … HT1 (L1.ⓓV1) ?) -HT1 /2 width=1/ /3 width=5/
-qed-.
-
-fact cpr_cpss_conf_lpr_lpss_flat_theta:
-   ∀a,L0,V0,W0,T0. (
-      ∀L,T. ⦃L0,ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
-   ) →
-   ∀V1. L0 ⊢ V0 ➡ V1 → ∀U1. ⇧[O, 1] V1 ≡ U1 →
-   ∀W1. L0 ⊢ W0 ➡ W1 → ∀T1. L0.ⓓW0 ⊢ T0 ➡ T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ ⓓ{a}W0.T0 ▶* T2 →
-   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓓ{a}W1.ⓐU1.T1 ▶* T & L2 ⊢ ⓐV2.T2 ➡ T.
-#a #L0 #V0 #W0 #T0 #IH #V1 #HV01 #U1 #HVU1 #W1 #HW01 #T1 #HT01
-#V2 #HV02 #X #H #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
-elim (lift_total V 0 1) #U #HVU
-lapply (cpss_lift … HV1 (L1.ⓓW1) … HVU1 … HVU) -HVU1 /2 width=1/ #HU1
-elim (cpss_inv_bind1 … H) -H #W2 #T2 #HW02 #HT02 #H destruct
-elim (IH … HW01 … HW02 … HL01 … HL02) /2 width=1/
-elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=1/ -L0 -V0 -W0 -T0
-/4 width=9 by ex2_intro, cpr_theta, cpss_bind, cpss_flat/ (**) (* auto too slow without trace *)
-qed-.
-
-lemma cpr_cpss_conf_lpr_lpss: lpx_sn_confluent cpr cpss.
-#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
-[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpr_inv_atom1 … H1) -H1
-  elim (cpss_inv_atom1 … H2) -H2
-  [ #H2 #H1 destruct
-    /2 width=1 by cpr_cpss_conf_lpr_lpss_atom_atom/
-  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
-    /3 width=10 by cpr_cpss_conf_lpr_lpss_atom_delta/
-  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
-    /3 width=10 by cpr_cpss_conf_lpr_lpss_delta_atom/
-  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
-    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
-    /3 width=17 by cpr_cpss_conf_lpr_lpss_delta_delta/
-  ]
-| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H2
-  elim (cpr_inv_bind1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #T1 #HT01 #HXT1 #H11 #H12
-  ] destruct
-  [ /3 width=10 by cpr_cpss_conf_lpr_lpss_bind_bind/
-  | /3 width=11 by cpr_cpss_conf_lpr_lpss_bind_zeta/
-  ]
-| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H2
-  elim (cpr_inv_flat1 … H1) -H1 *
-  [ #V1 #T1 #HV01 #HT01 #H1
-  | #HX1 #H1
-  | #a1 #V1 #Y1 #Z1 #T1 #HV01 #HZT1 #H11 #H12 #H13
-  | #a1 #V1 #U1 #Y1 #W1 #Z1 #T1 #HV01 #HVU1 #HYW1 #HZT1 #H11 #H12 #H13
-  ] destruct
-  [ /3 width=10 by cpr_cpss_conf_lpr_lpss_flat_flat/
-  | /3 width=8 by cpr_cpss_conf_lpr_lpss_flat_tau/
-  | /3 width=11 by cpr_cpss_conf_lpr_lpss_flat_beta/
-  | /3 width=14 by cpr_cpss_conf_lpr_lpss_flat_theta/
-  ]
-]
-qed-.
-
-(* Basic_1: includes: pr0_subst1 *)
-(* Basic_1: was: pr2_subst1 *)
-lemma cpr_cpss_conf: ∀L. confluent2 … (cpr L) (cpss L).
-/2 width=6 by cpr_cpss_conf_lpr_lpss/ qed-.
-
-lemma cpr_lpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➡ T1 → ∀L1. L0 ⊢ ▶* L1 →
-                        ∃∃T. L1 ⊢ T1 ▶* T & L1 ⊢ T0 ➡ T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpr_cpss_conf_lpr_lpss … HT01 T0 … L1 … HL01) // /2 width=1/ -L0 /2 width=3/
-qed-.
-
-lemma cpr_lpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➡ T1 → ∀L1. L0 ⊢ ▶* L1 →
-                        ∃∃T. L0 ⊢ T1 ▶* T & L1 ⊢ T0 ➡ T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpr_cpss_conf_lpr_lpss … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
-qed-.
-
-(* Basic_1: includes: pr0_subst1_fwd *)
-lemma lpr_cpss_conf: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ➡ L1 →
-                     ∃∃T. L1 ⊢ T0 ▶* T & L0 ⊢ T1 ➡ T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpr_cpss_conf_lpr_lpss ?? T0 … HT01 … HL01 L0) // -HT01 -HL01 /2 width=3/
-qed-.
-
-(* Properties on sn parallel substitution on local environments *************)
-
-lemma lpr_lpss_conf: confluent2 … lpr lpss.
-/3 width=6 by lpx_sn_conf, cpr_cpss_conf_lpr_lpss/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lprs_lpss.etc
deleted file mode 100644 (file)
index ed9e7d0..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/lpr_lpss.ma".
-include "basic_2/computation/lprs.ma".
-
-(* SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ****************************)
-
-(* Properties on sn parallel substitution on local environments *************)
-
-lemma lprs_lpss_conf: confluent2 … lprs lpss.
-/3 width=3 by TC_strip1, lpr_lpss_conf/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss.etc
deleted file mode 100644 (file)
index 6d57e17..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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-notation "hvbox( T1 ⊢ ▶ * break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStarSn $T1 $T2 }.
-
-include "basic_2/grammar/lpx_sn.ma".
-include "basic_2/substitution/cpss.ma".
-
-(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
-
-(* Basic_1: includes: csubst1_bind *)
-definition lpss: relation lenv ≝ lpx_sn cpss. 
-
-interpretation "parallel substitution (local environment, sn variant)"
-   'PSubstStarSn L1 L2 = (lpss L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lpss_inv_atom1: ∀L2. ⋆ ⊢ ▶* L2 → L2 = ⋆.
-/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
-
-lemma lpss_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* L2 →
-                      ∃∃K2,V2. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L2 = K2. ⓑ{I} V2.
-/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
-
-lemma lpss_inv_atom2: ∀L1. L1 ⊢ ▶* ⋆ → L1 = ⋆.
-/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
-
-lemma lpss_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ▶* K2. ⓑ{I} V2 →
-                       ∃∃K1,V1. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L1 = K1. ⓑ{I} V1.
-/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was by definition: csubst1_refl *)
-lemma lpss_refl: ∀L. L ⊢ ▶* L.
-/2 width=1 by lpx_sn_refl/ qed.
-
-lemma lpss_pair: ∀I,K1,K2,V1,V2. K1 ⊢ ▶* K2 → K1 ⊢ V1 ▶* V2 →
-                 K1.ⓑ{I}V1 ⊢ ▶* K2.ⓑ{I}V2.
-/2 width=1/ qed.
-
-lemma lpss_append: ∀K1,K2. K1 ⊢ ▶* K2 → ∀L1,L2. L1 ⊢ ▶* L2 →
-                    L1 @@ K1 ⊢ ▶* L2 @@ K2.
-/3 width=1 by lpx_sn_append, cpss_append/ qed.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lpss_fwd_length: ∀L1,L2. L1 ⊢ ▶* L2 → |L1| = |L2|.
-/2 width=2 by lpx_sn_fwd_length/ qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lpss_fwd_append1: ∀K1,L1,L. K1 @@ L1 ⊢ ▶* L →
-                        ∃∃K2,L2. K1 ⊢ ▶* K2 & L = K2 @@ L2.
-/2 width=2 by lpx_sn_fwd_append1/ qed-.
-
-lemma lpss_fwd_append2: ∀L,K2,L2. L ⊢ ▶* K2 @@ L2 →
-                        ∃∃K1,L1. K1 ⊢ ▶* K2 & L = K1 @@ L1.
-/2 width=2 by lpx_sn_fwd_append2/ qed-.
-
-(* Basic_1: removed theorems 28:
-            csubst0_clear_O csubst0_drop_lt csubst0_drop_gt csubst0_drop_eq
-            csubst0_clear_O_back csubst0_clear_S csubst0_clear_trans
-            csubst0_drop_gt_back csubst0_drop_eq_back csubst0_drop_lt_back
-            csubst0_gen_sort csubst0_gen_head csubst0_getl_ge csubst0_getl_lt
-            csubst0_gen_S_bind_2 csubst0_getl_ge_back csubst0_getl_lt_back
-            csubst0_snd_bind csubst0_fst_bind csubst0_both_bind
-            csubst1_head csubst1_flat csubst1_gen_head
-            csubst1_getl_ge csubst1_getl_lt csubst1_getl_ge_back getl_csubst1
-            fsubst0_gen_base
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_cpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_cpss.etc
deleted file mode 100644 (file)
index 71ab873..0000000
+++ /dev/null
@@ -1,60 +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/grammar/lpx_sn_lpx_sn.ma".
-include "basic_2/substitution/fsupp.ma".
-include "basic_2/substitution/lpss_ldrop.ma".
-
-(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
-
-(* Main properties on context-sensitive parallel substitution for terms *****)
-
-theorem cpss_trans_lpss: lpx_sn_transitive cpss cpss.
-#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L0 #T0 #IH #L1 * [|*]
-[ #I #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
-  elim (cpss_inv_atom1 … H1) -H1
-  [ #H destruct
-    elim (cpss_inv_atom1 … HT2) -HT2
-    [ #H destruct //
-    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
-      elim (lpss_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
-      elim (lpss_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
-      lapply (fsupp_lref … HLK1) /3 width=9/
-    ]
-  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-    elim (cpss_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
-    lapply (fsupp_lref … HLK1) /3 width=9/
-  ]
-| #a #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpss_inv_bind1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
-  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
-| #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
-  elim (cpss_inv_flat1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
-  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
-]
-qed-.
-
-(* Basic_1: was only: subst1_trans *)
-theorem cpss_trans: ∀L. Transitive … (cpss L).
-/2 width=5 by cpss_trans_lpss/ qed-.
-
-(* Properties on context-sensitive parallel substitution for terms **********)
-
-(* Basic_1: was only: subst1_subst1 *)
-lemma lpss_cpss_trans: ∀L1,L2. L1 ⊢ ▶* L2 →
-                       ∀T1,T2. L2 ⊢ T1 ▶* T2 → L1 ⊢ T1 ▶* T2.
-/2 width=5 by cpss_trans_lpss/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_ldrop.etc
deleted file mode 100644 (file)
index 7a549f1..0000000
+++ /dev/null
@@ -1,47 +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/fsup.ma".
-include "basic_2/relocation/ldrop_lpx_sn.ma".
-include "basic_2/substitution/cpss_lift.ma".
-include "basic_2/substitution/lpss.ma".
-
-(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
-
-(* Properies on local environment slicing ***********************************)
-
-lemma lpss_ldrop_conf: dropable_sn lpss.
-/3 width=5 by lpx_sn_deliftable_dropable, cpss_inv_lift1/ qed-.
-
-lemma ldrop_lpss_trans: dedropable_sn lpss.
-/3 width=9 by lpx_sn_liftable_dedropable, cpss_lift/ qed-.
-
-lemma lpss_ldrop_trans_O1: dropable_dx lpss.
-/2 width=3 by lpx_sn_dropable/ qed-.
-
-(* Properties on context-sensitive parallel substitution for terms **********)
-
-lemma fsup_cpss_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶* U2 →
-                       ∃∃L,U1. L1 ⊢ ▶* L & L ⊢ T1 ▶* U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
-#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [2: * ] [1,2,3,4,5: /3 width=5/ ]
-[ #L #K #U #T #d #e #HLK #HUT #He #U2 #HU2
-  elim (lift_total U2 d e) #T2 #HUT2
-  lapply (cpss_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9/
-| #L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
-  elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
-  elim (lift_total T d e) #U #HTU
-  elim (ldrop_lpss_trans … HLK1 … HK1) -HLK1 -HK1 #L2 #HL12 #HL2K
-  lapply (cpss_lift … HT1 … HL2K … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lpss_lpss.etc
deleted file mode 100644 (file)
index 12bb02b..0000000
+++ /dev/null
@@ -1,180 +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/lpss_cpss.ma".
-
-(* SN PARALLEL SUBSTITUTION ON LOCAL ENVIRONMENTS ***************************)
-
-(* Main properties on context-sensitive parallel substitution for terms *****)
-
-fact cpss_conf_lpss_atom_atom:
-   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ▶* T & L2 ⊢ ⓪{I} ▶* T.
-/2 width=3/ qed-.
-
-fact cpss_conf_lpss_atom_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V2. K0 ⊢ V0 ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ #i ▶* T & L2 ⊢ T2 ▶* T.
-#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-elim (lpss_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpss_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
-elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpss_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
-qed-.
-
-fact cpss_conf_lpss_delta_delta:
-   ∀L0,i. (
-      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
-      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
-   ) →
-   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
-   ∀V1. K0 ⊢ V0 ▶* V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
-   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
-   ∀V2. KX ⊢ VX ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
-   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ T2 ▶* T.
-#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
-#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
-lapply (ldrop_mono … H … HLK0) -H #H destruct
-elim (lpss_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
-elim (lpss_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
-elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
-elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
-lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
-lapply (fsupp_lref … HLK0) -HLK0 #HLK0
-elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
-elim (lift_total V 0 (i+1)) #T #HVT
-lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
-lapply (cpss_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
-qed-.
-
-fact cpss_conf_lpss_bind_bind:
-   ∀a,I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
-   ) →
-   ∀V1. L0 ⊢ V0 ▶* V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ▶* T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ▶* T2 →
-   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ▶* T & L2 ⊢ ⓑ{a,I}V2.T2 ▶* T.
-#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
-qed-.
-
-fact cpss_conf_lpss_flat_flat:
-   ∀I,L0,V0,T0. (
-      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
-      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
-      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
-      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
-   ) →
-   ∀V1. L0 ⊢ V0 ▶* V1 → ∀T1. L0 ⊢ T0 ▶* T1 →
-   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ T0 ▶* T2 →
-   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
-   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ▶* T & L2 ⊢ ⓕ{I}V2.T2 ▶* T.
-#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
-#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
-elim (IH … HV01 … HV02 … HL01 … HL02) //
-elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
-qed-.
-
-theorem cpss_conf_lpss: lpx_sn_confluent cpss cpss.
-#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
-[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpss_inv_atom1 … H1) -H1
-  elim (cpss_inv_atom1 … H2) -H2
-  [ #H2 #H1 destruct
-    /2 width=1 by cpss_conf_lpss_atom_atom/
-  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
-    /3 width=10 by cpss_conf_lpss_atom_delta/
-  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
-    /4 width=10 by ex2_commute, cpss_conf_lpss_atom_delta/
-  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
-    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
-    /3 width=17 by cpss_conf_lpss_delta_delta/
-  ]
-| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpss_inv_bind1 … H1) -H1 #V1 #T1 #HV01 #HT01 #H destruct
-  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct
-  /3 width=10 by cpss_conf_lpss_bind_bind/
-| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
-  elim (cpss_inv_flat1 … H1) -H1 #V1 #T1 #HV01 #HT01 #H destruct
-  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct
-  /3 width=10 by cpss_conf_lpss_flat_flat/
-]
-qed-.
-
-(* Basic_1: was only: subst1_confluence_eq *)
-theorem cpss_conf: ∀L. confluent … (cpss L).
-/2 width=6 by cpss_conf_lpss/ qed-.
-
-(* Properties on context-sensitive parallel substitution for terms **********)
-
-(* Basic_1: was only: subst1_subst1_back *)
-lemma lpss_cpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ▶* L1 →
-                         ∃∃T. L1 ⊢ T0 ▶* T & L1 ⊢ T1 ▶* T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpss_conf_lpss … HT01 T0 … HL01 … HL01) // -L0 /2 width=3/
-qed-.
-
-lemma lpss_cpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ▶* L1 →
-                         ∃∃T. L1 ⊢ T0 ▶* T & L0 ⊢ T1 ▶* T.
-#L0 #T0 #T1 #HT01 #L1 #HL01
-elim (cpss_conf_lpss … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
-qed-.
-
-(* Main properties **********************************************************)
-
-theorem lpss_conf: confluent … lpss.
-/3 width=6 by lpx_sn_conf, cpss_conf_lpss/
-qed-.
-
-theorem lpss_trans: Transitive … lpss.
-/3 width=5 by lpx_sn_trans, cpss_trans_lpss/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma cpss_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ▶* T →
-                       ∃∃L2,T2. L @@ L1 ⊢ ▶* L @@ L2 & L @@ L1 ⊢ T1 ▶* T2 &
-                                T = L2 @@ T2.
-#L1 @(lenv_ind_dx … L1) -L1
-[ #L #T1 #T #HT1
-  @ex3_2_intro [3: // |4,5: // |1,2: skip ] (**) (* /2 width=4/ does not work *)
-| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
-  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
-  lapply (lpss_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1/ #HL12
-  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr.etc
deleted file mode 100644 (file)
index c41ab19..0000000
+++ /dev/null
@@ -1,104 +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 "hvbox( L1 ⓝ ⊑ break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LRSubEqT $L1 $L2 }.
-
-include "basic_2/relocation/ldrop.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
-
-inductive lsubr: relation lenv ≝
-| lsubr_sort: ∀L. lsubr L (⋆)
-| lsubr_abbr: ∀L1,L2,V. lsubr L1 L2 → lsubr (L1. ⓓV) (L2.ⓓV)
-| lsubr_abst: ∀I,L1,L2,V1,V2. lsubr L1 L2 → lsubr (L1. ⓑ{I}V1) (L2. ⓛV2)
-.
-
-interpretation
-  "local environment refinement (substitution)"
-  'CrSubEq L1 L2 = (lsubr L1 L2).
-
-(* Basic properties *********************************************************)
-
-lemma lsubr_bind: ∀I,L1,L2,V. L1 ⊑ L2 → L1. ⓑ{I} V ⊑ L2.ⓑ{I} V.
-* /2 width=1/ qed.
-
-lemma lsubr_abbr: ∀I,L1,L2,V. L1 ⊑ L2 → L1. ⓓV ⊑ L2. ⓑ{I}V.
-* /2 width=1/ qed.
-
-lemma lsubr_refl: ∀L. L ⊑ L.
-#L elim L -L // /2 width=1/
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lsubr_inv_atom1_aux: ∀L1,L2. L1 ⊑ L2 → L1 = ⋆ → L2 = ⋆.
-#L1 #L2 * -L1 -L2 //
-[ #L1 #L2 #V #_ #H destruct
-| #I #L1 #L2 #V1 #V2 #_ #H destruct
-]
-qed-.
-
-lemma lsubr_inv_atom1: ∀L2. ⋆ ⊑ L2 → L2 = ⋆.
-/2 width=3 by lsubr_inv_atom1_aux/ qed-.
-
-fact lsubr_inv_abbr2_aux: ∀L1,L2. L1 ⊑ L2 → ∀K2,W. L2 = K2.ⓓW →
-                          ∃∃K1. K1 ⊑ K2 & L1 = K1.ⓓW.
-#L1 #L2 * -L1 -L2
-[ #L #K2 #W #H destruct
-| #L1 #L2 #V #HL12 #K2 #W #H destruct /2 width=3/
-| #I #L1 #L2 #V1 #V2 #_ #K2 #W #H destruct
-]
-qed-.
-
-lemma lsubr_inv_abbr2: ∀L1,K2,W. L1 ⊑ K2.ⓓW →
-                       ∃∃K1. K1 ⊑ K2 & L1 = K1.ⓓW.
-/2 width=3 by lsubr_inv_abbr2_aux/ qed-.
-
-fact lsubr_inv_abst2_aux: ∀L1,L2. L1 ⊑ L2 → ∀K2,W2. L2 = K2.ⓛW2 →
-                          ∃∃I,K1,W1. K1 ⊑ K2 & L1 = K1.ⓑ{I}W1.
-#L1 #L2 * -L1 -L2
-[ #L #K2 #W2 #H destruct
-| #L1 #L2 #V #_ #K2 #W2 #H destruct
-| #I #L1 #L2 #V1 #V2 #HL12 #K2 #W2 #H destruct /2 width=5/
-]
-qed-.
-
-lemma lsubr_inv_abst2: ∀L1,K2,W2. L1 ⊑ K2.ⓛW2 →
-                       ∃∃I,K1,W1. K1 ⊑ K2 & L1 = K1.ⓑ{I}W1.
-/2 width=4 by lsubr_inv_abst2_aux/ qed-.
-
-(* Basic forward lemmas *****************************************************)
-
-lemma lsubr_fwd_length: ∀L1,L2. L1 ⊑ L2 → |L2| ≤ |L1|.
-#L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-lemma lsubr_fwd_ldrop2_abbr: ∀L1,L2. L1 ⊑ L2 →
-                             ∀K2,W,i. ⇩[0, i] L2 ≡ K2. ⓓW →
-                             ∃∃K1. K1 ⊑ K2 & ⇩[0, i] L1 ≡ K1. ⓓW.
-#L1 #L2 #H elim H -L1 -L2
-[ #L #K2 #W #i #H
-  elim (ldrop_inv_atom1 … H) -H #H destruct
-| #L1 #L2 #V #HL12 #IHL12 #K2 #W #i #H
-  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct [ -IHL12 | -HL12 ]
-  [ /2 width=3/
-  | elim (IHL12 … HLK2) -IHL12 -HLK2 /3 width=3/
-  ]
-| #I #L1 #L2 #V1 #V2 #_ #IHL12 #K2 #W #i #H
-  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct
-  elim (IHL12 … HLK2) -IHL12 -HLK2 /3 width=3/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_etc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_etc.etc
deleted file mode 100644 (file)
index 107109a..0000000
+++ /dev/null
@@ -1,64 +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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-lemma lsubr_fwd_lsubr: ∀L1,L2. L1 ⓝ⊑ L2 → L1 ⊑ L2.
-#L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-lemma cpqs_cpr: ∀L,T1,T2. L ⊢ T1 ➤* T2 → L ⊢ T1 ➡ T2.
-#L #T1 #T2 #H elim H -L -T1 -T2 // /2 width=1/ /2 width=6/
-qed.
-
-lemma cpss_cpr: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➡ T2.
-/3 width=1/ qed.
-
-lemma lpqs_lpr: ∀L1,L2. L1 ⊢ ➤* L2 → L1 ⊢ ➡ L2.
-#L1 #L2 #H elim H -L1 -L2 // /3 width=1/
-qed.
-
-lemma lpss_lpr: ∀L1,L2. L1 ⊢ ▶* L2 → L1 ⊢ ➡ L2.
-/3 width=1/ qed.
-
-lemma cpss_fwd_cir_eq: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ 𝐈⦃T1⦄ → T2 = T1.
-/3 width=3 by cpr_fwd_cir, cpss_cpr/ qed-.
-
-lemma cpss_cprs: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➡* T2.
-/3 width=1/ qed.
-
-lemma cprs_cpss_trans: ∀L,T1,T. L ⊢ T1 ➡* T → ∀T2. L ⊢ T ▶* T2 → L ⊢ T1 ➡* T2.
-/3 width=3/ qed-.
-
-lemma cpss_cprs_trans: ∀L,T1,T. L ⊢ T1 ▶* T → ∀T2. L ⊢ T ➡* T2 → L ⊢ T1 ➡* T2.
-/3 width=3/ qed-.
-
-lemma cpcs_cpss_strap1: ∀L,T1,T. L ⊢ T1 ⬌* T → ∀T2. L ⊢ T ▶* T2 → L ⊢ T1 ⬌* T2.
-#L #T1 #T #HT1 #T2 #HT2
-@(cpcs_cpr_strap1 … HT1) -T1 /2 width=3/
-qed-.
-
-lemma cpcs_cpss_strap2: ∀L,T1,T. L ⊢ T1 ▶* T → ∀T2. L ⊢ T ⬌* T2 → L ⊢ T1 ⬌* T2.
-#L #T1 #T #HT1 #T2 #HT2
-@(cpcs_cpr_strap2 … HT2) -T2 /2 width=3/
-qed-.
-
-lemma cpcs_cpss_conf: ∀L,T,T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ⬌* T2 → L ⊢ T1 ⬌* T2.
-#L #T #T1 #HT1 #T2 #HT2
-@(cpcs_cpr_conf … HT2) -T2 /2 width=3/
-qed-.
-
-lemma cpcs_cpss_div: ∀L,T1,T. L ⊢ T1 ⬌* T → ∀T2. L ⊢ T2 ▶* T → L ⊢ T1 ⬌* T2.
-#L #T1 #T #HT1 #T2 #HT2
-@(cpcs_cpr_div … HT1) -T1 /2 width=3/
-qed-.
-
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/lsubr_lsubr.etc
deleted file mode 100644 (file)
index 98f3227..0000000
+++ /dev/null
@@ -1,66 +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/lsubr.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
-
-(* Auxiliary inversion lemmas ***********************************************)
-
-fact lsubr_inv_abbr1_aux: ∀L1,L2. L1 ⊑ L2 → ∀K1,W. L1 = K1.ⓓW →
-                          ∨∨ L2 = ⋆
-                           | ∃∃K2. K1 ⊑ K2 & L2 = K2.ⓓW
-                           | ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
-#L1 #L2 * -L1 -L2
-[ #L #K1 #W #H destruct /2 width=1/
-| #L1 #L2 #V #HL12 #K1 #W #H destruct /3 width=3/
-| #I #L1 #L2 #V1 #V2 #HL12 #K1 #W #H destruct /3 width=4/
-]
-qed-.
-
-lemma lsubr_inv_abbr1: ∀K1,L2,W. K1.ⓓW ⊑ L2 →
-                       ∨∨ L2 = ⋆
-                        | ∃∃K2. K1 ⊑ K2 & L2 = K2.ⓓW
-                        | ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
-/2 width=3 by lsubr_inv_abbr1_aux/ qed-.
-
-fact lsubr_inv_abst1_aux: ∀L1,L2. L1 ⊑ L2 → ∀K1,W1. L1 = K1.ⓛW1 →
-                          L2 = ⋆ ∨
-                          ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
-#L1 #L2 * -L1 -L2
-[ #L #K1 #W1 #H destruct /2 width=1/
-| #L1 #L2 #V #_ #K1 #W1 #H destruct
-| #I #L1 #L2 #V1 #V2 #HL12 #K1 #W1 #H destruct /3 width=4/
-]
-qed-.
-
-lemma lsubr_inv_abst1: ∀K1,L2,W1. K1.ⓛW1 ⊑ L2 →
-                       L2 = ⋆ ∨
-                       ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
-/2 width=4 by lsubr_inv_abst1_aux/ qed-.
-
-(* Main properties **********************************************************)
-
-theorem lsubr_trans: Transitive … lsubr.
-#L1 #L #H elim H -L1 -L
-[ #L1 #X #H
-  lapply (lsubr_inv_atom1 … H) -H //
-| #L1 #L #V #_ #IHL1 #X #H
-  elim (lsubr_inv_abbr1 … H) -H // *
-  #L2 [2: #V2 ] #HL2 #H destruct /3 width=1/
-| #I #L1 #L #V1 #V #_ #IHL1 #X #H
-  elim (lsubr_inv_abst1 … H) -H // *
-  #L2 #V2 #HL2 #H destruct /3 width=1/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/snv_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/snv_lpss.etc
deleted file mode 100644 (file)
index 91d34b1..0000000
+++ /dev/null
@@ -1,73 +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/computation/dxprs_lpss.ma".
-include "basic_2/equivalence/cpcs_lpss.ma".
-include "basic_2/dynamic/snv_lift.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties about sn parallel substitution for local environments *********)
-
-lemma snv_cpss_lpss_conf: ∀h,g,L1,T1. ⦃h, L1⦄ ⊢ T1 ¡[g] → ∀T2. L1 ⊢ T1 ▶* T2 →
-                          ∀L2. L1 ⊢ ▶* L2 → ⦃h, L2⦄ ⊢ T2 ¡[g].
-#h #g #L1 #T1 #H elim H -L1 -T1
-[ #L1 #k #X #H #L2 #_
-   >(cpss_inv_sort1 … H) -X //
-| #I #L1 #K1 #V1 #i #HLK1 #_ #IHV1 #W2 #H #L2 #HL12
-  elim (cpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
-    lapply (IHV1 … HV12 … HK12) -IHV1 -HV12 -HK12 /2 width=5/
-  | * #K0 #V0 #V2 #HLK0 #HV12 #HVW2
-    lapply (ldrop_mono … HLK0 … HLK1) -HLK0 #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -V #HLK2
-    lapply (IHV1 … HV12 … HK12) -IHV1 -HV12 -HK12 /2 width=7/
-  ]
-| #a #I #L1 #V1 #T1 #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (IHV1 … HV12 … HL12) -IHV1 #HV2
-  lapply (IHT1 … HT12 (L2.ⓑ{I}V2) ?) -IHT1 -HT12 /2 width=1/
-| #a #L1 #V1 #W1 #W0 #T1 #U1 #l #_ #_ #HVW1 #HW10 #HTU1 #IHV1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (IHV1 … HV12 … HL12) -IHV1 #HV2
-  lapply (IHT1 … HT12 … HL12) -IHT1 #HT2
-  elim (ssta_cpss_lpss_conf … HVW1 … HV12 … HL12) -V1 #W2 #HVW2 #HW12
-  elim (dxprs_cpss_lpss_conf … HTU1 … HT12 … HL12) -T1 #X #HTU2 #H
-  elim (cpss_inv_bind1 … H) -H #W #U2 #HW0 #_ #H -U1 destruct
-  elim (cprs_cpss2_lpss_conf_dx … HW10 … HW12 … HW0 … HL12) -L1 -W1 -W0 #W0 #HW20 #HW0
-  lapply (dxprs_strap1 … (ⓛ{a}W0.U2) HTU2 ?) -HTU2 /3 width=3/ -HW0 /2 width=8/
-| #L1 #W1 #T1 #U1 #l #_ #_ #HTU1 #HUW1 #IHW1 #IHT1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
-  lapply (IHW1 … HW12 … HL12) -IHW1 #HW2
-  lapply (IHT1 … HT12 … HL12) -IHT1 #HT2
-  elim (ssta_cpss_lpss_conf … HTU1 … HT12 … HL12) -T1 #U2 #HTU2 #HU12
-  lapply (cpcs_cpss2_lpss_conf … HUW1 … HU12 … HW12 … HL12) -L1 -W1 -U1 /2 width=4/
-]
-qed-.
-
-lemma snv_lpss_conf: ∀h,g,L1,T. ⦃h, L1⦄ ⊢ T ¡[g] →
-                     ∀L2. L1 ⊢ ▶* L2 → ⦃h, L2⦄ ⊢ T ¡[g].
-#h #g #L1 #T #HT #L2 #HL12
-@(snv_cpss_lpss_conf … HT … HL12) //
-qed-.
-
-lemma snv_cpss_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
-                     ∀T2. L ⊢ T1 ▶* T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
-#h #g #L #T1 #HT1 #T2 #HT12
-@(snv_cpss_lpss_conf … HT1 … HT12) //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/ssta_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/ssta_lpss.etc
deleted file mode 100644 (file)
index 7471b23..0000000
+++ /dev/null
@@ -1,81 +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/lpss_ldrop.ma".
-include "basic_2/static/ssta_lift.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Properties about sn parallel substitution ********************************)
-
-(* Note: apparently this was missing in basic_1 *)
-lemma ssta_cpss_lpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                           ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
-                           ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* U2.
-#h #g #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
-[ #L1 #k1 #l1 #Hkl1 #X #H
-  >(cpss_inv_sort1 … H) -H /3 width=3/
-| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #_ #HWU1 #IHVW1 #X #H #L2 #HL12
-  elim (cpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
-    elim (IHVW1 … HV12 … HK12) -IHVW1 -HV12 -HK12 #W2 #HVW2 #HW12
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 /3 width=6/
-  | * #Y #Z #V2 #H #HV12 #HV2
-    lapply (ldrop_mono … H … HLK1) -H #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #Z #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 #HLK2
-    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
-    elim (IHVW1 … HV12 … HK12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (ssta_lift … HVW2 … HLK2 … HV2 … HWU2) -HVW2 -HLK2 -HV2
-    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 -HWU2 /3 width=3/
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #_ #HWU1 #IHWV1 #X #H #L2 #HL12
-  elim (cpss_inv_lref1 … H) -H [ | -IHWV1 -HWU1 -HL12 ]
-  [ #H destruct
-    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-    elim (lpss_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
-    elim (IHWV1 … HW12 … HK12) -IHWV1 -HK12 #V2 #HWV2 #_
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 /3 width=6/ 
-  | * #K2 #V2 #W2 #HLK2 #_ #_
-    lapply (ldrop_mono … HLK2 … HLK1) -HLK1 -HLK2 #H destruct
-  ]
-| #a #I #L1 #V1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
-  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12 (L2.ⓑ{I}V2)) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
-| #L1 #V1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  elim (IHTU1 … HT12 … HL12) -IHTU1 -HT12 -HL12 /3 width=5/
-| #L1 #W1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
-  elim (cpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
-  elim (IHTU1 … HT12 … HL12) -IHTU1 -HT12 -HL12 /3 width=3/
-]
-qed-.
-
-lemma ssta_cpss_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
-                      ∀T2. L ⊢ T1 ▶* T2 →
-                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* U2.
-/2 width=3 by ssta_cpss_lpss_conf/ qed-.
-
-lemma ssta_lpss_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
-                      ∀L2. L1 ⊢ ▶* L2 →
-                      ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* U2.
-/2 width=3 by ssta_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/sstas_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/lsubr/sstas_lpss.etc
deleted file mode 100644 (file)
index 3ecbc22..0000000
+++ /dev/null
@@ -1,39 +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/static/ssta_lpss.ma".
-include "basic_2/unfold/sstas.ma".
-
-(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS *********************)
-
-(* Properties about sn parallel substitution for local environments *********)
-
-lemma sstas_cpss_lpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
-                            ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
-                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L1 ⊢ U1 ▶* U2.
-#h #g #L1 #T1 #U1 #H @(sstas_ind_dx … H) -T1 /2 width=3/
-#T0 #U0 #l0 #HTU0 #_ #IHU01 #T #HT0 #L2 #HL12
-elim (ssta_cpss_lpss_conf … HTU0 … HT0 … HL12) -HTU0 -HT0 #U #HTU #HU0
-elim (IHU01 … HU0 … HL12) -IHU01 -U0 -HL12 /3 width=4/
-qed-.
-
-lemma sstas_cpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
-                       ∀T2. L ⊢ T1 ▶* T2 →
-                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* U2.
-/2 width=3 by sstas_cpss_lpss_conf/ qed-.
-
-lemma sstas_lpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
-                       ∀L2. L1 ⊢ ▶* L2 →
-                       ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L1 ⊢ U1 ▶* U2.
-/2 width=3 by sstas_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn.etc
deleted file mode 100644 (file)
index c4359c3..0000000
+++ /dev/null
@@ -1,118 +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 "hvbox( h ⊢ break term 46 L1 : ⊑ break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'CrSubEqN $h $L1 $L2 }.
-
-notation "hvbox( h ⊢ break term 46 L1 : : ⊑ break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'CrSubEqNAlt $h $L1 $L2 }.
-
-include "basic_2/dynamic/nta.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
-
-(* Note: may not be transitive *)
-inductive lsubn (h:sh): relation lenv ≝
-| lsubn_atom: lsubn h (⋆) (⋆)
-| lsubn_pair: ∀I,L1,L2,W. lsubn h L1 L2 → lsubn h (L1. ⓑ{I} W) (L2. ⓑ{I} W)
-| lsubn_abbr: ∀L1,L2,V,W. ⦃h, L1⦄ ⊢ V : W → ⦃h, L2⦄ ⊢ V : W →
-              lsubn h L1 L2 → lsubn h (L1. ⓓV) (L2. ⓛW)
-.
-
-interpretation
-  "local environment refinement (native type assigment)"
-  'CrSubEqN h L1 L2 = (lsubn h L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lsubn_inv_atom1_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 = ⋆ → L2 = ⋆.
-#h #L1 #L2 * -L1 -L2
-[ //
-| #I #L1 #L2 #V #_ #H destruct
-| #L1 #L2 #V #W #_ #_ #_ #H destruct
-]
-qed.
-
-lemma lsubn_inv_atom1: ∀h,L2. h ⊢ ⋆ :⊑ L2 → L2 = ⋆.
-/2 width=4/ qed-.
-
-fact lsubn_inv_pair1_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀I,K1,V. L1 = K1. ⓑ{I} V →
-                          (∃∃K2. h ⊢ K1 :⊑ K2 & L2 = K2. ⓑ{I} V) ∨
-                          ∃∃K2,W. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
-                                  h ⊢ K1 :⊑ K2 & L2 = K2. ⓛW & I = Abbr.
-#h #L1 #L2 * -L1 -L2
-[ #I #K1 #V #H destruct
-| #J #L1 #L2 #V #HL12 #I #K1 #W #H destruct /3 width=3/
-| #L1 #L2 #V #W #H1VW #H2VW #HL12 #I #K1 #V1 #H destruct /3 width=7/
-]
-qed.
-
-lemma lsubn_inv_pair1: ∀h,I,K1,L2,V. h ⊢ K1. ⓑ{I} V :⊑ L2 →
-                       (∃∃K2. h ⊢ K1 :⊑ K2 & L2 = K2. ⓑ{I} V) ∨
-                       ∃∃K2,W. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
-                               h ⊢ K1 :⊑ K2 & L2 = K2. ⓛW & I = Abbr.
-/2 width=3/ qed-.
-
-fact lsubn_inv_atom2_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L2 = ⋆ → L1 = ⋆.
-#h #L1 #L2 * -L1 -L2
-[ //
-| #I #L1 #L2 #V #_ #H destruct
-| #L1 #L2 #V #W #_ #_ #_ #H destruct
-]
-qed.
-
-lemma lsubc_inv_atom2: ∀h,L1. h ⊢ L1 :⊑ ⋆ → L1 = ⋆.
-/2 width=4/ qed-.
-
-fact lsubn_inv_pair2_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀I,K2,W. L2 = K2. ⓑ{I} W →
-                          (∃∃K1. h ⊢ K1 :⊑ K2 & L1 = K1. ⓑ{I} W) ∨
-                          ∃∃K1,V. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
-                                  h ⊢ K1 :⊑ K2 & L1 = K1. ⓓV & I = Abst.
-#h #L1 #L2 * -L1 -L2
-[ #I #K2 #W #H destruct
-| #J #L1 #L2 #V #HL12 #I #K2 #W #H destruct /3 width=3/
-| #L1 #L2 #V #W #H1VW #H2VW #HL12 #I #K2 #W2 #H destruct /3 width=7/
-]
-qed.
-
-(* Basic_1: was: csubt_gen_bind *)
-lemma lsubn_inv_pair2: ∀h,I,L1,K2,W. h ⊢ L1 :⊑ K2. ⓑ{I} W →
-                       (∃∃K1. h ⊢ K1 :⊑ K2 & L1 = K1. ⓑ{I} W) ∨
-                       ∃∃K1,V. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
-                               h ⊢ K1 :⊑ K2 & L1 = K1. ⓓV & I = Abst.
-/2 width=3/ qed-.
-
-(* Basic_forward lemmas *****************************************************)
-
-lemma lsubn_fwd_lsubs1: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 ≼[0, |L1|] L2.
-#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-lemma lsubn_fwd_lsubs2: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 ≼[0, |L2|] L2.
-#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: csubt_refl *)
-lemma lsubn_refl: ∀h,L. h ⊢ L :⊑ L.
-#h #L elim L -L // /2 width=1/
-qed.
-
-(* Basic_1: removed theorems 6:
-            csubt_gen_flat csubt_drop_flat csubt_clear_conf
-            csubt_getl_abbr csubt_getl_abst csubt_ty3_ld
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_cpcs.etc
deleted file mode 100644 (file)
index 5f610bc..0000000
+++ /dev/null
@@ -1,34 +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/equivalence/cpcs_cpcs.ma".
-include "basic_2/dynamic/lsubn.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
-
-(* Properties on context-sensitive parallel equivalence for terms ***********)
-
-(* Basic_1: was: csubt_pr2 *)
-lemma cpr_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
-                       ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
-/3 width=4 by lsubn_fwd_lsubs2, cpr_lsubs_trans/ qed.
-
-lemma cprs_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
-                        ∀T1,T2. L2 ⊢ T1 ➡* T2 → L1 ⊢ T1 ➡* T2.
-/3 width=4 by lsubn_fwd_lsubs2, cprs_lsubs_trans/ qed.
-
-(* Basic_1: was: csubt_pc3 *)
-lemma cpcs_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
-                        ∀T1,T2. L2 ⊢ T1 ⬌* T2 → L1 ⊢ T1 ⬌* T2.
-/3 width=4 by lsubn_fwd_lsubs2, cpcs_lsubs_trans/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_ldrop.etc
deleted file mode 100644 (file)
index a16fff6..0000000
+++ /dev/null
@@ -1,64 +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/dynamic/lsubn.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
-
-(* Properties concerning basic local environment slicing ********************)
-
-(* Note: the constant 0 cannot be generalized *)
-lemma lsubn_ldrop_O1_conf: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀K1,e. ⇩[0, e] L1 ≡ K1 →
-                           ∃∃K2. h ⊢ K1 :⊑ K2 & ⇩[0, e] L2 ≡ K2.
-#h #L1 #L2 #H elim H -L1 -L2
-[ /2 width=3/
-| #I #L1 #L2 #V #_ #IHL12 #K1 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK1
-  [ destruct
-    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK1) -L1 /3 width=3/
-  ]
-| #L1 #L2 #V #W #H1VW #H2VW #_ #IHL12 #K1 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK1
-  [ destruct
-    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK1) -L1 /3 width=3/
-  ]
-]
-qed.
-
-(* Note: the constant 0 cannot be generalized *)
-(* Basic_1: was only: csubt_drop_abbr csubt_drop_abst *)
-lemma lsubn_ldrop_O1_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀K2,e. ⇩[0, e] L2 ≡ K2 →
-                            ∃∃K1. h ⊢ K1 :⊑ K2 & ⇩[0, e] L1 ≡ K1.
-#h #L1 #L2 #H elim H -L1 -L2
-[ /2 width=3/
-| #I #L1 #L2 #V #_ #IHL12 #K2 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK2
-  [ destruct
-    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK2) -L2 /3 width=3/
-  ]
-| #L1 #L2 #V #W #H1VW #H2VW #_ #IHL12 #K2 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK2
-  [ destruct
-    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK2) -L2 /3 width=3/
-  ]
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/lsubn_nta.etc
deleted file mode 100644 (file)
index 5832b00..0000000
+++ /dev/null
@@ -1,47 +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/dynamic/nta_nta.ma".
-include "basic_2/dynamic/lsubn_ldrop.ma".
-include "basic_2/dynamic/lsubn_cpcs.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
-
-(* Properties concerning atomic arity assignment ****************************)
-
-(* Note: the corresponding confluence property does not hold *)
-(* Basic_1: was: csubt_ty3 *)
-lemma lsubn_nta_trans: ∀h,L2,T,U. ⦃h, L2⦄ ⊢ T : U → ∀L1. h ⊢ L1 :⊑ L2 →
-                       ⦃h, L1⦄ ⊢ T : U.
-#h #L2 #T #U #H elim H -L2 -T -U
-[ //
-| #L2 #K2 #V2 #W2 #U2 #i #HLK2 #_ #WU2 #IHVW2 #L1 #HL12
-  elim (lsubn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
-  elim (lsubn_inv_pair2 … H) -H * #K1
-  [ #HK12 #H destruct /3 width=6/
-  | #V1 #_ #_ #_ #_ #H destruct
-  ]
-| #L2 #K2 #W2 #V2 #U2 #i #HLK2 #_ #HWU2 #IHWV2 #L1 #HL12
-  elim (lsubn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
-  elim (lsubn_inv_pair2 … H) -H * #K1 [ | -IHWV2 ]
-  [ #HK12 #H destruct /3 width=6/
-  | #V1 #H1V1W2 #_ #_ #H #_ destruct /2 width=6/
-  ]
-| /4 width=2/
-| /3 width=1/
-| /3 width=2/
-| /3 width=1/
-| /4 width=6/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta.etc
deleted file mode 100644 (file)
index fa4a8ed..0000000
+++ /dev/null
@@ -1,53 +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/static/sh.ma".
-include "basic_2/equivalence/cpcs.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-inductive nta (h:sh): lenv → relation term ≝
-| nta_sort: ∀L,k. nta h L (⋆k) (⋆(next h k))
-| nta_ldef: ∀L,K,V,W,U,i. ⇩[0, i] L ≡ K. ⓓV → nta h K V W →
-            ⇧[0, i + 1] W ≡ U → nta h L (#i) U
-| nta_ldec: ∀L,K,W,V,U,i. ⇩[0, i] L ≡ K. ⓛW → nta h K W V →
-            ⇧[0, i + 1] W ≡ U → nta h L (#i) U
-| nta_bind: ∀I,L,V,W,T,U. nta h L V W → nta h (L. ⓑ{I} V) T U →
-            nta h L (ⓑ{I}V.T) (ⓑ{I}V.U)
-| nta_appl: ∀L,V,W,T,U. nta h L V W → nta h L (ⓛW.T) (ⓛW.U) →
-            nta h L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
-| nta_pure: ∀L,V,W,T,U. nta h L T U → nta h L (ⓐV.U) W →
-            nta h L (ⓐV.T) (ⓐV.U)
-| nta_cast: ∀L,T,U. nta h L T U → nta h L (ⓝU. T) U
-| nta_conv: ∀L,T,U1,U2,V2. nta h L T U1 → L ⊢ U1 ⬌* U2 → nta h L U2 V2 →
-            nta h L T U2
-.
-
-interpretation "native type assignment (term)"
-   'NativeType h L T U = (nta h L T U).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: ty3_cast *)
-lemma nta_cast_old: ∀h,L,W,T,U.
-                    ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ U : W → ⦃h, L⦄ ⊢ ⓝU.T : ⓝW.U.
-/4 width=3/ qed.
-
-(* Basic_1: was: ty3_typecheck *)
-lemma nta_typecheck: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃T0. ⦃h, L⦄ ⊢ ⓝU.T : T0.
-/3 width=2/ qed.
-
-(* Basic_1: removed theorems 4:
-            ty3_getl_subst0 ty3_fsubst0 ty3_csubst0 ty3_subst0
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_aaa.etc
deleted file mode 100644 (file)
index 9628569..0000000
+++ /dev/null
@@ -1,49 +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/computation/csn_aaa.ma".
-include "basic_2/equivalence/lcpcs_aaa.ma".
-include "basic_2/dynamic/nta.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Forward lemmas on atomic arity assignment for terms **********************)
-
-lemma nta_fwd_aaa: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃∃A. L ⊢ T ⁝ A & L ⊢ U ⁝ A.
-#h #L #T #U #H elim H -L -T -U
-[ /2 width=3/
-| #L #K #V #W #U #i #HLK #_ #HWU * #B #HV #HW
-  lapply (ldrop_fwd_ldrop2 … HLK) /3 width=9/
-| #L #K #W #V #U #i #HLK #_ #HWU * #B #HW #_ -V
-  lapply (ldrop_fwd_ldrop2 … HLK) /3 width=9/
-| * #L #V #W #T #U #_ #_ * #B #HV #HW * #A #HT #HU
-  [ /3 width=3/ | /3 width=5/ ]
-| #L #V #W #T #U #_ #_ * #B #HV #HW * #X #H1 #H2
-  elim (aaa_inv_abst … H1) -H1 #B1 #A1 #HW1 #HT #H destruct
-  elim (aaa_inv_abst … H2) -H2 #B2 #A #_ #HU #H destruct
-  lapply (aaa_mono … HW1 … HW) -HW1 #H destruct /4 width=5/
-| #L #V #W #T #U #_ #_ * #X #HT #HUX * #A #H #_ -W
-  elim (aaa_inv_appl … H) -H #B #HV #HUA
-  lapply (aaa_mono … HUA … HUX) -HUX #H destruct /3 width=5/
-| #L #T #U #_ * #A #HT #HU /3 width=3/
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ * #X #HT #HU1 * #A #HU2 #_
-  lapply (aaa_cpcs_mono … HU12 … HU1 … HU2) -U1 #H destruct /2 width=3/
-]
-qed-.
-
-(* Note: this is the stong normalization property *)
-(* Basic_1: was only: ty3_sn3 *)
-theorem nta_fwd_csn: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → L ⊢ ⬇* T ∧ L ⊢ ⬇* U.
-#h #L #T #U #H elim (nta_fwd_aaa … H) -H /3 width=2/
-qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_alt.etc
deleted file mode 100644 (file)
index 8cbd595..0000000
+++ /dev/null
@@ -1,190 +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/equivalence/cpcs_cpcs.ma".
-include "basic_2/dynamic/nta.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* alternative definition of nta *)
-inductive ntaa (h:sh): lenv → relation term ≝
-| ntaa_sort: ∀L,k. ntaa h L (⋆k) (⋆(next h k))
-| ntaa_ldef: ∀L,K,V,W,U,i. ⇩[0, i] L ≡ K. ⓓV → ntaa h K V W →
-             ⇧[0, i + 1] W ≡ U → ntaa h L (#i) U
-| ntaa_ldec: ∀L,K,W,V,U,i. ⇩[0, i] L ≡ K. ⓛW → ntaa h K W V →
-             ⇧[0, i + 1] W ≡ U → ntaa h L (#i) U
-| ntaa_bind: ∀I,L,V,W,T,U. ntaa h L V W → ntaa h (L. ⓑ{I} V) T U →
-             ntaa h L (ⓑ{I}V.T) (ⓑ{I}V.U)
-| ntaa_appl: ∀L,V,W,T,U. ntaa h L V W → ntaa h L (ⓛW.T) (ⓛW.U) →
-             ntaa h L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
-| ntaa_pure: ∀L,V,W,T,U. ntaa h L T U → ntaa h L (ⓐV.U) W →
-             ntaa h L (ⓐV.T) (ⓐV.U)
-| ntaa_cast: ∀L,T,U,W. ntaa h L T U → ntaa h L U W → ntaa h L (ⓝU. T) U
-| ntaa_conv: ∀L,T,U1,U2,V2. ntaa h L T U1 → L ⊢ U1 ⬌* U2 → ntaa h L U2 V2 →
-             ntaa h L T U2
-.
-
-interpretation "native type assignment (term) alternative"
-   'NativeTypeAlt h L T U = (ntaa h L T U).
-
-(* Advanced inversion lemmas ************************************************)
-
-fact ntaa_inv_bind1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ∀J,X,Y. T = ⓑ{J}Y.X →
-                         ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y :: Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :: Z2 &
-                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
-#h #L #T #U #H elim H -L -T -U
-[ #L #k #J #X #Y #H destruct
-| #L #K #V #W #U #i #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #K #W #V #U #i #_ #_ #_ #_ #J #X #Y #H destruct
-| #I #L #V #W #T #U #HVW #HTU #_ #_ #J #X #Y #H destruct /2 width=3/
-| #L #V #W #T #U #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #T #U #W #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #J #X #Y #H destruct
-  elim (IHTU1 ????) -IHTU1 [5: // |2,3,4: skip ] #Z1 #Z2 #HZ1 #HZ2 #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
-]
-qed.
-
-lemma ntaa_inv_bind1: ∀h,J,L,Y,X,U. ⦃h, L⦄ ⊢ ⓑ{J}Y.X :: U →
-                      ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y :: Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :: Z2 &
-                               L ⊢ ⓑ{J}Y.Z2 ⬌* U.
-/2 width=3/ qed-.                            
-
-lemma ntaa_nta: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ⦃h, L⦄ ⊢ T : U.
-#h #L #T #U #H elim H -L -T -U
-// /2 width=1/ /2 width=2/ /2 width=3/ /2 width=6/
-qed-.
-
-(* Properties on relocation *************************************************)
-
-lemma ntaa_lift: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 :: U1 → ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
-                 ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 → ⦃h, L2⦄ ⊢ T2 :: U2.
-#h #L1 #T1 #U1 #H elim H -L1 -T1 -U1
-[ #L1 #k #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  >(lift_inv_sort1 … H1) -X1
-  >(lift_inv_sort1 … H2) -X2 //
-| #L1 #K1 #V1 #W1 #W #i #HLK1 #_ #HW1 #IHVW1 #L2 #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // #W2 #HW12 #HWU2
-    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
-    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
-    /3 width=8/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
-    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
-  ]
-| #L1 #K1 #W1 #V1 #W #i #HLK1 #_ #HW1 #IHWV1 #L2 #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // <minus_plus #W #HW1 #HWU2
-    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
-    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
-    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
-    elim (lift_total V1 (d-i-1) e) /3 width=8/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
-    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct
-  elim (lift_total W1 d e) /4 width=6/
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #V2 #X #HV12 #H1 #H destruct
-  elim (lift_inv_bind1 … H1) -H1 #W2 #T2 #HW12 #HT12 #H destruct
-  elim (lift_inv_flat1 … H2) -H2 #Y2 #X #HY #H2 #H destruct
-  elim (lift_inv_bind1 … H2) -H2 #X2 #U2 #HX #HU12 #H destruct
-  lapply (lift_mono … HY … HV12) -HY #H destruct
-  lapply (lift_mono … HX … HW12) -HX #H destruct /4 width=6/
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct
-  elim (lift_total W1 d e) /4 width=6/
-| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X #H #U2 #HU12
-  elim (lift_inv_flat1 … H) -H #X2 #T2 #HUX2 #HT12 #H destruct
-  lapply (lift_mono … HUX2 … HU12) -HUX2 #H destruct
-  elim (lift_total W1 d e) /3 width=6/
-| #L1 #T1 #U11 #U12 #V12 #_ #HU112 #_ #IHTU11 #IHUV12 #L2 #d #e #HL21 #U1 #HTU1 #U2 #HU12
-  elim (lift_total U11 d e) #U #HU11
-  elim (lift_total V12 d e) #V22 #HV122
-  lapply (cpcs_lift … HL21 … HU11 … HU12 HU112) -HU112 /3 width=6/
-]
-qed.
-
-(* Advanced forvard lemmas **************************************************)
-
-lemma ntaa_fwd_correct: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ∃T0. ⦃h, L⦄ ⊢ U :: T0.
-#h #L #T #U #H elim H -L -T -U
-[ /2 width=2/
-| #L #K #V #W #W0 #i #HLK #_ #HW0 * #V0 #HWV0
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  elim (lift_total V0 0 (i+1)) /3 width=10/
-| #L #K #W #V #V0 #i #HLK #HWV #HWV0 #_
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  elim (lift_total V 0 (i+1)) /3 width=10/
-| #I #L #V #W #T #U #HVW #_ #_ * /3 width=2/
-| #L #V #W #T #U #HVW #_ #_ * #X #H
-  elim (ntaa_inv_bind1 … H) -H /4 width=2/
-| #L #V #W #T #U #_ #HUW * #T0 #HUT0 /3 width=2/
-| /2 width=2/
-| /2 width=2/
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma nta_ntaa: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ T :: U.
-#h #L #T #U #H elim H -L -T -U
-// /2 width=1/ /2 width=2/ /2 width=3/ /2 width=6/
-#L #T #U #_ #HTU
-elim (ntaa_fwd_correct … HTU) /2 width=2/
-qed.
-
-(* Advanced eliminators *****************************************************)
-
-lemma nta_ind_alt: ∀h. ∀R:lenv→relation term.
-   (∀L,k. R L ⋆k ⋆(next h k)) →
-   (∀L,K,V,W,U,i.
-      ⇩[O, i] L ≡ K.ⓓV → ⦃h, K⦄ ⊢ V : W → ⇧[O, i + 1] W ≡ U →
-      R K V W → R L (#i) U 
-   ) →
-   (∀L,K,W,V,U,i.
-      ⇩[O, i] L ≡ K.ⓛW → ⦃h, K⦄ ⊢ W : V → ⇧[O, i + 1] W ≡ U →
-      R K W V → R L (#i) U
-   ) →
-   (∀I,L,V,W,T,U.
-      ⦃h, L⦄ ⊢ V : W → ⦃h, L.ⓑ{I}V⦄ ⊢ T : U →
-      R L V W → R (L.ⓑ{I}V) T U → R L (ⓑ{I}V.T) (ⓑ{I}V.U)
-   ) →
-   (∀L,V,W,T,U.
-      ⦃h, L⦄ ⊢ V : W → ⦃h, L⦄ ⊢ (ⓛW.T):(ⓛW.U) →
-      R L V W →R L (ⓛW.T) (ⓛW.U) →R L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
-   ) →
-   (∀L,V,W,T,U.
-      ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ (ⓐV.U) : W →
-      R L T U → R L (ⓐV.U) W → R L (ⓐV.T) (ⓐV.U)
-   ) →
-   (∀L,T,U,W.
-      ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ U : W →
-      R L T U → R L U W → R L (ⓝU.T) U
-   ) →
-   (∀L,T,U1,U2,V2.
-      ⦃h, L⦄ ⊢ T : U1 → L ⊢ U1 ⬌* U2 → ⦃h, L⦄ ⊢ U2 : V2 →
-      R L T U1 →R L U2 V2 →R L T U2
-   ) →
-   ∀L,T,U. ⦃h, L⦄ ⊢ T : U → R L T U.
-#h #R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8 #L #T #U #H elim (nta_ntaa … H) -L -T -U
-// /3 width=1 by ntaa_nta/ /3 width=3 by ntaa_nta/ /3 width=4 by ntaa_nta/
-/3 width=7 by ntaa_nta/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_lift.etc
deleted file mode 100644 (file)
index 57e06a1..0000000
+++ /dev/null
@@ -1,144 +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/dynamic/nta_alt.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-fact nta_inv_sort1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀k0. T = ⋆k0 →
-                        L ⊢ ⋆(next h k0) ⬌* U.
-#h #L #T #U #H elim H -L -T -U
-[ #L #k #k0 #H destruct //
-| #L #K #V #W #U #i #_ #_ #_ #_ #k0 #H destruct
-| #L #K #W #V #U #i #_ #_ #_ #_ #k0 #H destruct
-| #I #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
-| #L #T #U #_ #_ #k0 #H destruct
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #k0 #H destruct
-  lapply (IHTU1 ??) -IHTU1 [ // | skip ] #Hk0
-  lapply (cpcs_trans … Hk0 … HU12) -U1 //
-]
-qed.
-
-(* Basic_1: was: ty3_gen_sort *)
-lemma nta_inv_sort1: ∀h,L,U,k. ⦃h, L⦄ ⊢ ⋆k : U → L ⊢ ⋆(next h k) ⬌* U.
-/2 width=3/ qed-.
-
-fact nta_inv_lref1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀j. T = #j →
-                        (∃∃K,V,W,U0. ⇩[0, j] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V : W &
-                                     ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                        ) ∨
-                        (∃∃K,W,V,U0. ⇩[0, j] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W : V &
-                                     ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                        ).
-#h #L #T #U #H elim H -L -T -U
-[ #L #k #j #H destruct
-| #L #K #V #W #U #i #HLK #HVW #HWU #_ #j #H destruct /3 width=8/
-| #L #K #W #V #U #i #HLK #HWV #HWU #_ #j #H destruct /3 width=8/
-| #I #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
-| #L #T #U #_ #_ #j #H destruct
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #j #H destruct
-  elim (IHTU1 ??) -IHTU1 [4: // |2: skip ] * #K #V #W #U0 #HLK #HVW #HWU0 #HU01
-  lapply (cpcs_trans … HU01 … HU12) -U1 /3 width=8/
-]
-qed.
-
-(* Basic_1: was ty3_gen_lref *)
-lemma nta_inv_lref1: ∀h,L,U,i. ⦃h, L⦄ ⊢ #i : U →
-                     (∃∃K,V,W,U0. ⇩[0, i] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V : W &
-                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                     ) ∨
-                     (∃∃K,W,V,U0. ⇩[0, i] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W : V &
-                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                     ).
-/2 width=3/ qed-.
-
-(* Basic_1: was: ty3_gen_bind *)
-lemma nta_inv_bind1: ∀h,I,L,Y,X,U. ⦃h, L⦄ ⊢ ⓑ{I}Y.X : U →
-                     ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y : Z1 & ⦃h, L.ⓑ{I}Y⦄ ⊢ X : Z2 &
-                              L ⊢ ⓑ{I}Y.Z2 ⬌* U.
-#h #I #L #Y #X #U #H
-elim (ntaa_inv_bind1 … (nta_ntaa … H)) -H /3 width=3 by ntaa_nta, ex3_2_intro/
-qed-.
-
-fact nta_inv_cast1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. T = ⓝY.X →
-                     ⦃h, L⦄ ⊢ X : Y ∧ L ⊢ Y ⬌* U.
-#h #L #T #U #H elim H -L -T -U
-[ #L #k #X #Y #H destruct
-| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
-| #L #T #U #HTU #_ #X #Y #H destruct /2 width=1/
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
-  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #HXY #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=1/
-]
-qed.
-
-(* Basic_1: was: ty3_gen_cast *)
-lemma nta_inv_cast1: ∀h,L,X,Y,U. ⦃h, L⦄ ⊢ ⓝY.X : U →  ⦃h, L⦄ ⊢ X : Y ∧ L ⊢ Y ⬌* U.
-/2 width=3/ qed-.
-
-(* Advanced forvard lemmas **************************************************)
-
-fact nta_fwd_pure1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. T = ⓐY.X →
-                        ∃∃V,W. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V & L ⊢ ⓐY.V ⬌* U.
-#h #L #T #U #H elim H -L -T -U
-[ #L #k #X #Y #H destruct
-| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
-| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W #T #U #HVW #HTU #_ #_ #X #Y #H destruct /2 width=3/
-| #L #V #W #T #U #HTU #_ #_ #IHUW #X #Y #H destruct
-  elim (IHUW U Y ?) -IHUW // /2 width=3/
-| #L #T #U #_ #_ #X #Y #H destruct
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
-  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #V #W #HYW #HXV #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
-]
-qed.
-
-lemma nta_fwd_pure1: ∀h,L,X,Y,U. ⦃h, L⦄ ⊢ ⓐY.X : U →
-                     ∃∃V,W. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V & L ⊢ ⓐY.V ⬌* U.
-/2 width=3/ qed-.
-
-(* Basic_1: was: ty3_correct *)
-lemma nta_fwd_correct: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃T0. ⦃h, L⦄ ⊢ U : T0.
-#h #L #T #U #H
-elim (ntaa_fwd_correct … (nta_ntaa … H)) -H /3 width=2 by ntaa_nta, ex_intro/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-(* Basic_1: was: ty3_appl *)
-lemma nta_appl_old: ∀h,L,V,W,T,U. ⦃h, L⦄ ⊢ V : W → ⦃h, L⦄ ⊢ T : ⓛW.U →
-                    ⦃h, L⦄ ⊢ ⓐV.T : ⓐV.ⓛW.U.
-#h #L #V #W #T #U #HVW #HTU
-elim (nta_fwd_correct … HTU) #X #H
-elim (nta_inv_bind1 … H) -H /4 width=2/
-qed.
-
-(* Properties on relocation *************************************************)
-
-(* Basic_1: was: ty3_lift *)
-lemma nta_lift: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 → ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
-                ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 → ⦃h, L2⦄ ⊢ T2 : U2.
-/4 width=9 by ntaa_nta, nta_ntaa, ntaa_lift/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpr.etc
deleted file mode 100644 (file)
index c461e9f..0000000
+++ /dev/null
@@ -1,235 +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/equivalence/cpcs_delift.ma".
-include "basic_2/dynamic/nta.ma".
-(*
-lemma pippo: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. L ⊢ T ➡* ⓛX.Y →
-             ∃Z. L ⊢ U ➡* ⓛX.Z.
-#h #L #T #U #H elim H -L -T -U
-[
-|
-|
-|
-| #L #V #W #T #U #_ #_ #IHVW #IHTU #X #Y #H  
-| #L #V #W #T #U #_ #HUW #IHTU #IHUW #X #Y #HTY
-  elim (cprs_inv_appl_abst … HTY) -HTY #W1 #T1 #W2 #T2 #HT1 #HT12 #HYT2
-  elim (IHTU … HT1) -IHTU -HT1 #U1 #HU1 
-  
-  
-   *
-  [ #V0 #T0 #_ #_ #H destruct
-  | #V0 #W0 #T0 #HV0 #HT0 #HTY
-    elim (IHTU … HT0) -IHTU -HT0 #Z #HUZ
-    elim (cprs_inv_abbr1 … HTY) -HTY *
-    [ #V1 #T1 #_ #_ #H destruct #X0  
-
-*)
-
-(*
-
-include "basic_2/computation/cprs_lcprs.ma".
-
-
-
-
-include "basic_2/dynamic/nta_ltpss.ma".
-include "basic_2/dynamic/nta_thin.ma".
-include "basic_2/dynamic/lsubn_nta.ma".
-
-include "basic_2/hod/ntas_lift.ma".
-
-  
-  elim (nta_inv_pure1 … HUW) -HUW #V0 #U0 #U1 #HV0 #HU0 #HU0W #HU01
-  @(ex2_2_intro … HYW)
-  [2: 
-
-
-axiom pippo_aux: ∀h,L,Z,U. ⦃h, L⦄ ⊢ Z : U → ∀Y,X. Z = ⓐY.X →
-                 ∀W,T. L ⊢ X ➡* ⓛW.T → ⦃h, L⦄ ⊢ Y : W.
-#h #L #Z #U #H elim H -L -Z -U
-[
-|
-|
-|
-|
-| #L #V #W #T #U #HTU #_ #_ #IHUW #Y #X #H #W0 #T0 #HX destruct 
-  lapply (IHUW Y U ? ?) -IHUW -W // #T 
-  @(ex2_2_intro … HYW)
-  [2: 
-
-axiom pippo: ∀h,L,V,X,U. ⦃h, L⦄ ⊢ ⓐV.X : U →
-             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ V : W.
-#h #L #V #X #Y #H 
-
-*)
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties on context-free parallel reduction for local environments ******)
-(*
-axiom nta_ltpr_cprs_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
-                          ∀T2. L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 : U.
-#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
-[ #L1 #k #L2 #_ #T2 #H
-  >(cprs_inv_sort1 … H) -H //
-|
-|
-|
-|
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #HL12 #T2 #H
-  elim (cprs_inv_appl1 … H) -H *
-  [ #V2 #T0 #HV12 #HT10 #H destruct
-    elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=2/ ] #U
-    @(nta_conv … (ⓐV2.U1)) (* /2 width=1/*) [ /4 width=2/] (**) (* explicit constructor, /5 width=5/ is too slow *)
-  | #V2 #W2 #T0 #HV12 #HT10 #HT02
-    lapply (IHTU1 … HL12 (ⓛW2.T0) ?) -IHTU1 /2 width=1/ -HT10 #H
-    elim (nta_inv_bind1 … H) -H #W #U0 #HW2 #HTU0 #HU01
-    elim (cpcs_inv_abst1 … HU01) -HU01 #W #U #HU1 #HU0
-    lapply (IHUW1 … HL12 (ⓐV2.ⓛW.U) ?) -IHUW1 -HL12 /2 width=1/ -HV12 #H
-    
-    
-    
-    elim (nta_fwd_pure1 … H) -H #W0 #U2 #HVU2 #H #HW01
-    elim (nta_inv_bind1 … H) -H #W3 #U3 #HW3 #HU3 #H
-    elim (cpcs_inv_abst1 … H) -H #W4 #U4  
-*)      
-(*
-axiom nta_ltpr_tpr_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
-                         ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
-#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
-[ #L1 #k #L2 #_ #T2 #H
-  >(tpr_inv_atom1 … H) -H //
-| #L1 #K1 #V1 #W #U #i #HLK1 #_ #HWU #IHV1 #L2 #HL12 #T2 #H
-  >(tpr_inv_atom1 … H) -T2
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
-  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
-| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #HL12 #T2 #H
-  >(tpr_inv_atom1 … H) -T2
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
-  elim (ltpr_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
-  lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-  elim (lift_total V1 0 (i+1)) #W #HW
-  lapply (nta_lift h … HLK … HWU1 … HW) /2 width=1/ -HLK -HW
-  elim (lift_total W2 0 (i+1)) #U2 #HWU2
-  lapply (tpr_lift … HW12 … HWU1 … HWU2) -HWU1 #HU12
-  @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /3 width=6/ is too slow *)
-| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H
-  elim (tpr_inv_bind1 … H) -H *
-  [ #V2 #T0 #T2 #HV12 #HT10 #HT02 #H destruct
-    lapply (IHVW1 … HL12 … HV12) #HV2W1
-    lapply (IHVW1 L2 … V1 ?) // -IHVW1 #HWV1
-    lapply (IHTU1 (L2.ⓑ{I}V2) … HT10) -HT10 /2 width=1/ #HT0U1
-    lapply (IHTU1 (L2.ⓑ{I}V1) ? T1 ?) -IHTU1 // /2 width=1/ -HL12 #H
-    lapply (tps_lsubs_trans … HT02 (L2.ⓑ{I}V2) ?) -HT02 /2 width=1/ #HT02
-    lapply (nta_tps_conf … HT0U1 … HT02) -T0 #HT2U1
-    elim (nta_fwd_correct … H) -H #U2 #HU12
-    @(nta_conv … (ⓑ{I}V2.U1)) /2 width=2/ /3 width=1/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-  | #T #HT1 #HTX #H destruct
-    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HVW1
-    elim (lift_total X 0 1) #Y #HXY
-    lapply (tpr_lift … HTX … HT1 … HXY) -T #H
-    lapply (IHTU1 (L2.ⓓV1) … H) -T1 /2 width=1/ -L1 #H
-    elim (nta_fwd_correct … H) #T1 #HUT1
-    elim (nta_thin_conf … H L2 0 (0+1) ? ?) -H /2 width=1/ /3 width=1/ #T #U #HTU #H
-    normalize in ⊢ (??%??? → ?); #HU1
-    lapply (delift_inv_lift1_eq … H L2 … HXY) -Y /2 width=1/ #H destruct
-    @(nta_conv … U) // /2 width=2/
-  ]
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H
-  elim (tpr_inv_appl1 … H) -H *
-  [ #V2 #Y #HV12 #HY #H destruct
-    elim (tpr_inv_abst1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
-    lapply (IHTU1 L2 ? (ⓛW1.T1) ?) // #H
-    elim (nta_fwd_correct … H) -H #X #H
-    elim (nta_inv_bind1 … H) -H #W #U #HW #HU #_
-    @(nta_conv … (ⓐV2.ⓛW1.U1)) /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
-    lapply (IHVW1 … HL12 … HV12) #HVW2
-    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HV1W2
-    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 -HL12 /2 width=1/ -HT02 #H1
-    elim (nta_fwd_correct … H1) #T #H2
-    elim (nta_inv_bind1 … H1) -H1 #W #U2 #HW2 #HTU2 #H
-    elim (cpcs_inv_abst … H Abst W2) -H #_ #HU21
-    elim (nta_inv_bind1 … H2) -H2 #W0 #U0 #_ #H #_ -T -W0
-    lapply (lsubn_nta_trans … HTU2 (L2.ⓓV2) ?) -HTU2 /2 width=1/ #HTU2
-    @(nta_conv … (ⓓV2.U2)) /2 width=2/ /3 width=2/ (**) (* explicit constructor, /4 width=5/ is too slow *)
-  | #V0 #V2 #W0 #W2 #T0 #T2 #_ #_ #_ #_ #H destruct
-  ]
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #HL12 #X #H
-  elim (tpr_inv_appl1 … H) -H *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=2/ ] #U
-    @(nta_conv … (ⓐV2.U1)) /2 width=1/ /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
-    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 /2 width=1/ -T0 #H
-    elim (nta_inv_bind1 … H) -H #W #U2 #HW2 #HTU2 #HU21
-    lapply (IHUW1 … HL12 (ⓐV2.U1) ?) -IHUW1 -HL12 /2 width=1/ #H
-    elim (nta_inv_pure1 … H) -H #V0 #U0 #U #HV20 #HU10 #HU0W1 #HU0
-    @(nta_conv … (ⓓV2.U2))
-    [2: @nta_bind //
-        @(lsubn_nta_trans … HTU2) @lsubn_abbr //
-(*
-    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HB
-    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
-    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 /width=5/ -T0 /2 width=1/ -L1 -V1 /4 width=7/
-*)
-*)
-(*
-axiom pippo: ⦃h, L⦄ ⊢ ⓐV.X : Y →
-             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ ⓐV : W.
-
-*)
-(* SEGMENT 2
-| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
-  lapply (cpr_tpss … HU12) /4 width=4/
-| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
-  @(nta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
-]
-qed.
-*)
-
-(* SEGMENT 3
-fact nta_ltpr_tpr_conf_aux: ∀h,L,T,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → L = L1 → T = T1 →
-                            ∀L2. L1 ➡ L2 → ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
-  
-  
-  | #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
-    elim (nta_inv_abbr … HT1) -HT1 #B0 #HW0 #HT0
-    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
-    lapply (IH … HV1 … HL12 … HV10) -HV1 -HV10 /width=5/ #HV0
-    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 /width=5/ -V1 -T0 /2 width=1/ -L1 -W0 #HT2
-    @(nta_abbr … HW2) -HW2
-    @(nta_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
-  ]
-| #L1 #V1 #T1 #A #HV1 #HT1 #H1 #H2 #L2 #HL12 #X #H destruct
-  elim (tpr_inv_cast1 … H) -H
-  [ * #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
-    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
-  | -HV1 #HT1X
-     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
-  ]
-]
-qed.
-
-/2 width=9/ qed.
-
-axiom nta_ltpr_conf: ∀L1,T,A. L1 ⊢ T : A → ∀L2. L1 ➡ L2 → L2 ⊢ T : A.
-/2 width=5/ qed.
-
-axiom nta_tpr_conf: ∀L,T1,A. L ⊢ T1 : A → ∀T2. T1 ➡ T2 → L ⊢ T2 : A.
-/2 width=5/ qed.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_ltpss.etc
deleted file mode 100644 (file)
index 828fd82..0000000
+++ /dev/null
@@ -1,121 +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/equivalence/cpcs_ltpss.ma".
-include "basic_2/dynamic/nta_nta.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties about parallel unfold *****************************************)
-
-lemma nta_ltpss_tpss_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U →
-                           ∀L2,d,e. L1 ▶* [d, e] L2 →
-                           ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 : U.
-#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
-[ #L1 #k #L2 #d #e #_ #T2 #H
-  >(tpss_inv_sort1 … H) -H //
-| #L1 #K1 #V1 #W #U #i #HLK1 #_ #HWU #IHV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
-      /3 width=7/
-    | elim (lt_or_ge i (d + e)) #Hide [ | -Hdi ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
-        /3 width=7/
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=7/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=9/
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
-  [ #H destruct
-    elim (lift_total V1 0 (i+1)) #W #HW
-    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #W2 #HK12 #HW12 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-      lapply (nta_lift h … HLK … HWU1 … HW) /2 width=4/ -HW
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
-      lapply (cpr_tpss … HU12) -HU12 #HU12
-      @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -HW -Hdi ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #W2 #HK12 #HW12 #H destruct
-        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-        lapply (nta_lift h … HLK … HWU1 … HW) /2 width=4/ -HW
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
-        lapply (cpr_tpss … HU12) -HU12 #HU12
-        @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HV
-  lapply (IHTU1 (L2.ⓑ{I}V1) (d+1) e ? T1 ?) // /2 width=1/ #H
-  elim (nta_fwd_correct … H) -H #U2 #HU12
-  @(nta_conv … (ⓑ{I}V2.U1)) /3 width=2/ /3 width=4/ /4 width=4/ (**) (* explicit constructor, /5 width=6/ is too slow *)
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
-  elim (tpss_inv_bind1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HV
-  lapply (IHTU1 L2 d e ? (ⓛW1.T1) ?) // #H
-  elim (nta_fwd_correct … H) -H #X #H
-  elim (nta_inv_bind1 … H) -H #W #U #HW #HU #_
-  @(nta_conv … (ⓐV2.ⓛW1.U1)) /3 width=2/ /3 width=4/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HV
-  elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=4/ ] #U #HU
-  @(nta_conv … (ⓐV2.U1)) // /3 width=1/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
-  lapply (cpr_tpss … HU12) /4 width=4/
-| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
-  @(nta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
-]
-qed.
-
-lemma nta_ltpss_tps_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U →
-                          ∀L2,d,e. L1 ▶* [d, e] L2 →
-                          ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → ⦃h, L2⦄ ⊢ T2 : U.
-/3 width=7/ qed.
-
-lemma nta_ltpss_conf: ∀h,L1,T,U. ⦃h, L1⦄ ⊢ T : U →
-                      ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T : U.
-/2 width=7/ qed.
-
-lemma nta_tpss_conf: ∀h,L,T1,U. ⦃h, L⦄ ⊢ T1 : U →
-                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 : U.
-/2 width=7/ qed.
-
-lemma nta_tps_conf: ∀h,L,T1,U. ⦃h, L⦄ ⊢ T1 : U →
-                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 : U.
-/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_nta.etc
deleted file mode 100644 (file)
index 05eb6c5..0000000
+++ /dev/null
@@ -1,59 +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/dynamic/nta_lift.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: ty3_unique *)
-theorem nta_mono: ∀h,L,T,U1. ⦃h, L⦄ ⊢ T : U1 → ∀U2. ⦃h, L⦄ ⊢ T : U2 →
-                  L ⊢ U1 ⬌* U2.
-#h #L #T #U1 #H elim H -L -T -U1
-[ #L #k #X #H
-  lapply (nta_inv_sort1 … H) -H //
-| #L #K #V #W11 #W12 #i #HLK #_ #HW112 #IHVW11 #X #H
-  elim (nta_inv_lref1 … H) -H * #K0 #V0 #W21 #W22 #HLK0 #HVW21 #HW212 #HX
-  lapply (ldrop_mono … HLK0 … HLK) -HLK0 #H destruct
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  @(cpcs_trans … HX) -X /3 width=9 by cpcs_lift/ (**) (* to slow without trace *)
-| #L #K #W #V1 #V #i #HLK #_ #HWV #_ #X #H
-  elim (nta_inv_lref1 … H) -H * #K0 #W0 #V2 #V0 #HLK0 #_ #HWV0 #HX
-  lapply (ldrop_mono … HLK0 … HLK) -HLK0 -HLK #H destruct
-  lapply (lift_mono … HWV0 … HWV) -HWV0 -HWV #H destruct //
-| #I #L #V #W1 #T #U1 #_ #_ #_ #IHTU1 #X #H
-  elim (nta_inv_bind1 … H) -H #W2 #U2 #_ #HTU2 #H
-  @(cpcs_trans … H) -X /3 width=1/
-| #L #V #W1 #T #U1 #_ #_ #_ #IHTU1 #X #H
-  elim (nta_fwd_pure1 … H) -H #U2 #W2 #_ #HTU2 #H
-  @(cpcs_trans … H) -X /3 width=1/
-| #L #V #W1 #T #U1 #_ #_ #IHTU1 #_ #X #H
-  elim (nta_fwd_pure1 … H) -H #U2 #W2 #_ #HTU2 #H
-  @(cpcs_trans … H) -X /3 width=1/
-| #L #T #U1 #_ #_ #X #H
-  elim (nta_inv_cast1 … H) -H //
-| #L #T #U11 #U12 #V12 #_ #HU112 #_ #IHTU11 #_ #U2 #HTU2
-  @(cpcs_canc_sn … HU112) -U12 /2 width=1/
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma nta_cast_alt: ∀h,L,T,W,U. ⦃h, L⦄ ⊢ T : W → ⦃h, L⦄ ⊢ T : U →
-             ⦃h, L⦄ ⊢ ⓝW.T : U.
-#h #L #T #W #U #HTW #HTU
-lapply (nta_mono … HTW … HTU) #HWU
-elim (nta_fwd_correct … HTU) -HTU /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_sta.etc
deleted file mode 100644 (file)
index 6268b98..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/static/sta.ma".
-include "basic_2/equivalence/cpcs_cpcs.ma".
-include "basic_2/dynamic/nta.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties on static type assignment *************************************)
-
-lemma nta_fwd_sta: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U →
-                   ∃∃U0. ⦃h, L⦄ ⊢ T • U0 & L ⊢ U0 ⬌* U.
-#h #L #T #U #H elim H -L -T -U
-[ /2 width=3/
-| #L #K #V #W1 #V1 #i #HLK #_ #HWV1 * #W0 #HVW0 #HW01
-  elim (lift_total W0 0 (i+1)) #V0 #HWV0
-  lapply (ldrop_fwd_ldrop2 … HLK) #HLK0
-  lapply (cpcs_lift … HLK0 … HWV0 … HWV1 HW01) -HLK0 -HWV1 -HW01 /3 width=6/
-| #L #K #W #V1 #W1 #i #HLK #HWV1 #HW1 * /3 width=6/
-| #I #L #V #W #T #U #_ #_ * #W0 #_ #_ * /3 width=3/
-| #L #V #W #T #U #_ #_ * #W0 #_ #HW0 * #X #H #HX
-  elim (sta_inv_bind1 … H) -H #U0 #HTU0 #H destruct
-  @(ex2_1_intro … (ⓐV.ⓛW.U0)) /2 width=1/ /3 width=1/
-| #L #V #W #T #U #_ #_ * #U0 #HTU0 #HU0 #_ -W
-  @(ex2_1_intro … (ⓐV.U0)) /2 width=1/
-| #L #T #U #HTU * #U0 #HTU0 #HU0 /3 width=3/
-| #L #T #U1 #U2 #V2 #_ #HU12 #_ * #U0 #HTU0 #HU01 #_
-  lapply (cpcs_trans … HU01 … HU12) -U1 /2 width=3/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/nta/nta_thin.etc
deleted file mode 100644 (file)
index f927f84..0000000
+++ /dev/null
@@ -1,116 +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/unfold/thin_ldrop.ma".
-include "basic_2/equivalence/cpcs_delift.ma".
-include "basic_2/dynamic/nta_lift.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties on basic local environment thinning ***************************)
-
-(* Note: this is known as the substitution lemma *)
-(* Basic_1: was only: ty3_gen_cabbr *)
-lemma nta_thin_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 →
-                     ∀L2,d,e. ≽ [d, e] L1 → L1 ▼*[d, e] ≡ L2 →
-                     ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 : U2 &
-                              L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
-#h #L1 #T1 #U1 #H elim H -L1 -T1 -U1
-[ /2 width=5/
-| #L1 #K1 #V1 #W1 #U1 #i #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL1 #HL12
-  elim (lt_or_ge i d) #Hdi [ -HVW1 ]
-  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
-    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
-    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
-    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-    elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #X2 #W2 #HVW2 #H #HW12
-    lapply (delift_mono … H … HV12) -H -HV12 #H destruct
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (ldrop_fwd_ldrop2 … HLK1) -V1 #HLK1
-    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
-    >minus_plus <plus_minus_m_m // /3 width=6/
-  | elim (lt_or_ge i (d+e)) #Hide [ -HVW1 | -Hdi -IHVW1 -HL1 ]
-    [ lapply (sfr_ldrop_trans_be_up … HLK1 … HL1 ? ?) -HL1 // /2 width=2/ <minus_n_O #H
-      elim (sfr_inv_bind … H ?) -H /2 width=1/ #HK1 #_
-      elim (thin_ldrop_conf_be … HL12 … HLK1 ? ?) -HL12 /2 width=2/ #K2 #H #HLK2
-      lapply (thin_inv_thin1 … H ?) -H /2 width=1/ #HK12
-      elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #V2 #W2 #HVW2 #HV12 #HW12
-      elim (lift_total V2 0 d) #T2 #HVT2
-      elim (lift_total W2 0 d) #U2 #HWU2
-      elim (lift_total W2 0 (i+1)) #U #HW2U
-      lapply (nta_lift … HVW2 … HLK2 … HVT2 … HWU2) -HVW2 -HLK2 #HTU2
-      lapply (ldrop_fwd_ldrop2 … HLK1) #HLK0
-      lapply (delift_lift_ge … HW12 … HLK0 HWU1 … HW2U) -HW12 -HLK0 -HWU1 // >minus_plus #HU1
-      lapply (lift_conf_be … HWU2 … HW2U ?) -W2 /2 width=1/ #HU2
-      lapply (delift_lift_div_be … HU1 … HU2 ? ?) -U // /2 width=1/ /3 width=8/
-    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
-      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
-      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
-      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
-      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
-    ]
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL1 #HL12
-  elim (lt_or_ge i d) #Hdi [ -HWV1 | -IHWV1 ]
-  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
-    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
-    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
-    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHWV1 … HK1 HK12) -IHWV1 -HK1 -HK12 #X2 #V2 #HWV2 #H #_
-    lapply (delift_mono … H … HW12) -H #H destruct
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
-    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
-    >minus_plus <plus_minus_m_m // /3 width=6/
-  | elim (lt_or_ge i (d+e)) #Hide [ -HWV1 -HWU1 -HL12 | -Hdi -HL1 ]
-    [ lapply (sfr_inv_ldrop … HLK1 … HL1 ? ?) -HLK1 -HL1 // -Hdi -Hide #H destruct 
-    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
-      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
-      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
-      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
-      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
-    ]
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
-  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #_
-  elim (IHTU1 (L2.ⓑ{I}V2) (d+1) e ? ?) -IHTU1 /2 width=1/ -HL1 -HL12 #T2 #U2 #HTU2 #HT12 #HU12
-  lapply (delift_lsubs_trans … HT12 (L1.ⓑ{I}V2) ?) -HT12 /2 width=1/
-  lapply (delift_lsubs_trans … HU12 (L1.ⓑ{I}V2) ?) -HU12 /2 width=1/ /3 width=7/
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
-  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #HW12
-  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 #X2 #Y2 #HXY2 #HX2 #HY2
-  elim (delift_inv_bind1 … HX2) -HX2 #Z21 #T2 #HZ21 #HT12 #H destruct
-  elim (delift_inv_bind1 … HY2) -HY2 #Z22 #U2 #HZ22 #HU12 #H destruct
-  lapply (delift_mono … HZ21 … HW12) -HZ21 #H destruct
-  lapply (delift_mono … HZ22 … HW12) -HZ22 #H destruct
-  @(ex3_2_intro … (ⓐV2.ⓛW2.T2) (ⓐV2.ⓛW2.U2)) /3 width=1/ (**) (* explict constructor, /4 depth=?/ is too slow *)
-| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
-  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
-  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #X2 #W2 #HXW2 #H #HW12
-  elim (delift_inv_flat1 … H) -H #V2 #Y2 #HV12 #HY2 #H destruct
-  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=7/
-| #L1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL1 #HL12
-  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 /3 width=5/
-| #L1 #T1 #U11 #U12 #V1 #_ #HU112 #_ #IHT1 #IHU12 #L2 #d #e #HL1 #HL12
-  elim (IHT1 … HL1 HL12) -IHT1 #T2 #U21 #HT2 #HT12 #HU121
-  elim (IHU12 … HL1 HL12) -IHU12 -HL1 #U22 #V2 #HU22 #HU122 #_
-  lapply (thin_cpcs_delift_mono … HU112 … HL12 … HU121 … HU122) -HU112 -HL12 -HU121 /3 width=5/
-]
-qed.
-
-lemma nta_ldrop_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 →
-                      ∀L2,d,e. ≽ [d, e] L1 → ⇩[d, e] L1 ≡ L2 →
-                      ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 : U2 &
-                               L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
-/3 width=1/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn.etc
deleted file mode 100644 (file)
index f6b5450..0000000
+++ /dev/null
@@ -1,110 +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 "hvbox( h ⊢ break term 46 L1 : ⊑ [ ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'StratifiedCrSubEqN $h $L1 $L2 }.
-
-include "basic_2/dynamic/snta.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
-
-(* Note: may not be transitive *)
-inductive lsubsn (h:sh): relation lenv ≝
-| lsubsn_atom: lsubsn h (⋆) (⋆)
-| lsubsn_pair: ∀I,L1,L2,W. lsubsn h L1 L2 →
-               lsubsn h (L1. ⓑ{I} W) (L2. ⓑ{I} W)
-| lsubsn_abbr: ∀L1,L2,V,W,l. ⦃h, L1⦄ ⊢ V :[l+1] W → ⦃h, L2⦄ ⊢ V :[l+1] W →
-               lsubsn h L1 L2 → lsubsn h (L1. ⓓV) (L2. ⓛW)
-.
-
-interpretation
-  "local environment refinement (stratified native type assigment)"
-  'StratifiedCrSubEqN h L1 L2 = (lsubsn h L1 L2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact lsubsn_inv_atom1_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 = ⋆ → L2 = ⋆.
-#h #L1 #L2 * -L1 -L2
-[ //
-| #I #L1 #L2 #V #_ #H destruct
-| #L1 #L2 #V #W #l #_ #_ #_ #H destruct
-]
-qed.
-
-lemma lsubsn_inv_atom1: ∀h,L2. h ⊢ ⋆ :⊑[] L2 → L2 = ⋆.
-/2 width=5/ qed-.
-
-fact lsubsn_inv_pair1_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                           ∀I,K1,V. L1 = K1. ⓑ{I} V →
-                           (∃∃K2. h ⊢ K1 :⊑[] K2 & L2 = K2. ⓑ{I} V) ∨
-                           ∃∃K2,W,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
-                                     h ⊢ K1 :⊑[] K2 & L2 = K2. ⓛW & I = Abbr.
-#h #L1 #L2 * -L1 -L2
-[ #I #K1 #V #H destruct
-| #J #L1 #L2 #V #HL12 #I #K1 #W #H destruct /3 width=3/
-| #L1 #L2 #V #W #l #H1VW #H2VW #HL12 #I #K1 #V1 #H destruct /3 width=7/
-]
-qed.
-
-lemma lsubsn_inv_pair1: ∀h,I,K1,L2,V. h ⊢ K1. ⓑ{I} V :⊑[] L2 →
-                        (∃∃K2. h ⊢ K1 :⊑[] K2 & L2 = K2. ⓑ{I} V) ∨
-                        ∃∃K2,W,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
-                                  h ⊢ K1 :⊑[] K2 & L2 = K2. ⓛW & I = Abbr.
-/2 width=3/ qed-.
-
-fact lsubsn_inv_atom2_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L2 = ⋆ → L1 = ⋆.
-#h #L1 #L2 * -L1 -L2
-[ //
-| #I #L1 #L2 #V #_ #H destruct
-| #L1 #L2 #V #W #l #_ #_ #_ #H destruct
-]
-qed.
-
-lemma lsubsn_inv_atom2: ∀h,L1. h ⊢ L1 :⊑[] ⋆ → L1 = ⋆.
-/2 width=5/ qed-.
-
-fact lsubsn_inv_pair2_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                           ∀I,K2,W. L2 = K2. ⓑ{I} W →
-                           (∃∃K1. h ⊢ K1 :⊑[] K2 & L1 = K1. ⓑ{I} W) ∨
-                           ∃∃K1,V,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
-                                     h ⊢ K1 :⊑[] K2 & L1 = K1. ⓓV & I = Abst.
-#h #L1 #L2 * -L1 -L2
-[ #I #K2 #W #H destruct
-| #J #L1 #L2 #V #HL12 #I #K2 #W #H destruct /3 width=3/
-| #L1 #L2 #V #W #l #H1VW #H2VW #HL12 #I #K2 #W2 #H destruct /3 width=7/
-]
-qed.
-
-lemma lsubsn_inv_pair2: ∀h,I,L1,K2,W. h ⊢ L1 :⊑[] K2. ⓑ{I} W →
-                        (∃∃K1. h ⊢ K1 :⊑[] K2 & L1 = K1. ⓑ{I} W) ∨
-                        ∃∃K1,V,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
-                                  h ⊢ K1 :⊑[] K2 & L1 = K1. ⓓV & I = Abst.
-/2 width=3/ qed-.
-
-(* Basic_forward lemmas *****************************************************)
-
-lemma lsubsn_fwd_lsubs1: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 ≼[0, |L1|] L2.
-#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-lemma lsubsn_fwd_lsubs2: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 ≼[0, |L2|] L2.
-#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lsubsn_refl: ∀h,L. h ⊢ L :⊑[] L.
-#h #L elim L -L // /2 width=1/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_cpcs.etc
deleted file mode 100644 (file)
index 38f7e17..0000000
+++ /dev/null
@@ -1,32 +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/equivalence/cpcs_cpcs.ma".
-include "basic_2/dynamic/lsubsn.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
-
-(* Properties on context-sensitive parallel equivalence for terms ***********)
-
-lemma cpr_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                        ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
-/3 width=5 by lsubsn_fwd_lsubs2, cpr_lsubs_trans/ qed-.
-
-lemma cprs_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                         ∀T1,T2. L2 ⊢ T1 ➡* T2 → L1 ⊢ T1 ➡* T2.
-/3 width=5 by lsubsn_fwd_lsubs2, cprs_lsubs_trans/ qed-.
-
-lemma cpcs_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                         ∀T1,T2. L2 ⊢ T1 ⬌* T2 → L1 ⊢ T1 ⬌* T2.
-/3 width=5 by lsubsn_fwd_lsubs2, cpcs_lsubs_trans/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_ldrop.etc
deleted file mode 100644 (file)
index 0928837..0000000
+++ /dev/null
@@ -1,65 +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/dynamic/lsubsn.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
-
-(* Properties concerning basic local environment slicing ********************)
-
-(* Note: the constant 0 cannot be generalized *)
-lemma lsubsn_ldrop_O1_conf: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                            ∀K1,e. ⇩[0, e] L1 ≡ K1 →
-                            ∃∃K2. h ⊢ K1 :⊑[] K2 & ⇩[0, e] L2 ≡ K2.
-#h #L1 #L2 #H elim H -L1 -L2
-[ /2 width=3/
-| #I #L1 #L2 #V #_ #IHL12 #K1 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK1
-  [ destruct
-    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK1) -L1 /3 width=3/
-  ]
-| #L1 #L2 #V #W #l #H1VW #H2VW #_ #IHL12 #K1 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK1
-  [ destruct
-    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK1) -L1 /3 width=3/
-  ]
-]
-qed.
-
-(* Note: the constant 0 cannot be generalized *)
-lemma lsubsn_ldrop_O1_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
-                             ∀K2,e. ⇩[0, e] L2 ≡ K2 →
-                             ∃∃K1. h ⊢ K1 :⊑[] K2 & ⇩[0, e] L1 ≡ K1.
-#h #L1 #L2 #H elim H -L1 -L2
-[ /2 width=3/
-| #I #L1 #L2 #V #_ #IHL12 #K2 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK2
-  [ destruct
-    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK2) -L2 /3 width=3/
-  ]
-| #L1 #L2 #V #W #l #H1VW #H2VW #_ #IHL12 #K2 #e #H
-  elim (ldrop_inv_O1 … H) -H * #He #HLK2
-  [ destruct
-    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
-    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
-  | elim (IHL12 … HLK2) -L2 /3 width=3/
-  ]
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/lsubsn_snta.etc
deleted file mode 100644 (file)
index c621530..0000000
+++ /dev/null
@@ -1,49 +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/dynamic/snta_snta.ma".
-include "basic_2/dynamic/lsubsn_ldrop.ma".
-include "basic_2/dynamic/lsubsn_cpcs.ma".
-
-(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
-
-(* Properties concerning stratified native type assignment ******************)
-
-(* Note: the corresponding confluence property does not hold *)
-lemma lsubsn_snta_trans: ∀h,L2,T,U,l. ⦃h, L2⦄ ⊢ T :[l] U →
-                         ∀L1. h ⊢ L1 :⊑[] L2 → ⦃h, L1⦄ ⊢ T :[l] U.
-#h #L2 #T #U #l #H elim H -L2 -T -U -l
-[ //
-| #L2 #K2 #V2 #W2 #U2 #i #l #HLK2 #_ #WU2 #IHVW2 #L1 #HL12
-  elim (lsubsn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
-  elim (lsubsn_inv_pair2 … H) -H * #K1
-  [ #HK12 #H destruct /3 width=6/
-  | #V1 #l0 #_ #_ #_ #_ #H destruct
-  ]
-| #L2 #K2 #W2 #V2 #U2 #i #l #HLK2 #HWV2 #HWU2 #IHWV2 #L1 #HL12
-  elim (lsubsn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
-  elim (lsubsn_inv_pair2 … H) -H * #K1 [ -HWV2 | -IHWV2 ]
-  [ #HK12 #H destruct /3 width=6/
-  | #V1 #l0 #H1 #H2 #_ #H #_ destruct
-    elim (snta_fwd_correct … H2) -H2 #V #H
-    elim (snta_mono … HWV2 … H) -HWV2 -H /2 width=6/
-  ]
-| /4 width=3/
-| /3 width=2/
-| /3 width=2/
-| /3 width=1/
-| #L2 #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #IHUV2 #L1 #HL12
-  lapply (cpcs_lsubsn_trans … HL12 … HU12) -HU12 /3 width=3/
-]
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta.etc
deleted file mode 100644 (file)
index 71ed421..0000000
+++ /dev/null
@@ -1,48 +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 "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : * break [ l ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'NativeTypeStar $h $l $L $T1 $T2 }.
-
-notation "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : break [ l ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'StratifiedNativeType $h $l $L $T1 $T2 }.
-
-include "basic_2/static/sh.ma".
-include "basic_2/equivalence/cpcs.ma".
-
-(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
-
-inductive snta (h:sh): nat → lenv → relation term ≝
-| snta_sort: ∀L,k. snta h 0 L (⋆k) (⋆(next h k))
-| snta_ldef: ∀L,K,V,W,U,i,l. ⇩[0, i] L ≡ K. ⓓV → snta h l K V W →
-             ⇧[0, i + 1] W ≡ U → snta h l L (#i) U
-| snta_ldec: ∀L,K,W,V,U,i,l. ⇩[0, i] L ≡ K. ⓛW → snta h l K W V →
-             ⇧[0, i + 1] W ≡ U → snta h (l+1) L (#i) U
-| snta_bind: ∀I,L,V,W,T,U,l1,l2. snta h l1 L V W → snta h l2 (L. ⓑ{I} V) T U →
-             snta h l2 L (ⓑ{I}V.T) (ⓑ{I}V.U)
-| snta_appl: ∀L,V,W1,W2,T,U,l1,l2. snta h (l1+1) L V W2 →
-             snta h l2 L (ⓛW1.T) (ⓛW2.U) →
-             snta h l2 L (ⓐV.ⓛW1.T) (ⓐV.ⓛW2.U)
-| snta_pure: ∀L,V,T,U,W,l. snta h (l+1) L T U → snta h l L (ⓐV.U) W →
-             snta h (l+1) L (ⓐV.T) (ⓐV.U)
-| snta_cast: ∀L,T,U,W,l1,l2. snta h l2 L T U → snta h l1 L U W →
-             snta h l2 L (ⓝU.T) U
-| snta_conv: ∀L,T,U1,U2,V2,l. snta h l L T U1 → L ⊢ U1 ⬌* U2 →
-             snta h (l-1) L U2 V2 → snta h l L T U2
-.
-
-interpretation "stratified native type assignment (term)"
-   'StratifiedNativeType h l L T U = (snta h l L T U).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_lift.etc
deleted file mode 100644 (file)
index 424bfe8..0000000
+++ /dev/null
@@ -1,238 +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/equivalence/cpcs_cpcs.ma".
-include "basic_2/dynamic/snta.ma".
-
-(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-fact snta_inv_sort1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀k0. T = ⋆k0 →
-                         l = 0 ∧ L ⊢ ⋆(next h k0) ⬌* U.
-#h #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #k0 #H destruct /2 width=1/
-| #L #K #V #W #U #i #l #_ #_ #_ #_ #k0 #H destruct
-| #L #K #W #V #U #i #l #_ #_ #_ #_ #k0 #H destruct
-| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
-| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
-| #L #V #T #U #W #l #_ #_ #_ #_ #k0 #H destruct
-| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
-| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #k0 #H destruct
-  elim (IHTU1 ??) -IHTU1 [3: // |2: skip ] #H #Hk0
-  lapply (cpcs_trans … Hk0 … HU12) -U1 /2 width=1/
-]
-qed.
-
-lemma snta_inv_sort1: ∀h,L,U,k,l. ⦃h, L⦄ ⊢ ⋆k :[l] U →
-                      l = 0 ∧ L ⊢ ⋆(next h k) ⬌* U.
-/2 width=4/ qed-.
-
-fact snta_inv_lref1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀j. T = #j →
-                         (∃∃K,V,W,U0. ⇩[0, j] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V :[l] W &
-                                      ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                         ) ∨
-                         (∃∃K,W,V,U0. ⇩[0, j] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W :[l-1] V &
-                                      ⇧[0, j + 1] W ≡ U0 & l > 0 & L ⊢ U0 ⬌* U
-                         ).
-#h #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #j #H destruct
-| #L #K #V #W #U #i #l #HLK #HVW #HWU #_ #j #H destruct /3 width=8/
-| #L #K #W #V #U #i #l #HLK #HWV #HWU #_ #j #H destruct /3 width=8/
-| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #j #H destruct
-| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #j #H destruct
-| #L #V #T #U #W #l #_ #_ #_ #_ #j #H destruct
-| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #j #H destruct
-| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #j #H destruct
-  elim (IHTU1 ??) -IHTU1 [4: // |2: skip ] * #K #V #W #U0 #HLK #HVW #HWU0 [2: #H ] #HU01
-  lapply (cpcs_trans … HU01 … HU12) -U1 /3 width=8/
-]
-qed.
-
-lemma snta_inv_lref1: ∀h,L,U,i,l. ⦃h, L⦄ ⊢ #i :[l] U →
-                     (∃∃K,V,W,U0. ⇩[0, i] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V :[l] W &
-                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
-                     ) ∨
-                     (∃∃K,W,V,U0. ⇩[0, i] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W :[l-1] V &
-                                  ⇧[0, i + 1] W ≡ U0 & l > 0 & L ⊢ U0 ⬌* U
-                     ).
-/2 width=3/ qed-.
-
-fact snta_inv_bind1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀J,X,Y. T = ⓑ{J}Y.X →
-                         ∃∃Z1,Z2,l0. ⦃h, L⦄ ⊢ Y :[l0] Z1 &
-                                  ⦃h, L.ⓑ{J}Y⦄ ⊢ X :[l] Z2 &
-                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
-#h #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #J #X #Y #H destruct
-| #L #K #V #W #U #i #l #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #K #W #V #U #i #l #_ #_ #_ #_ #J #X #Y #H destruct
-| #I #L #V #W #T #U #l1 #l2 #HVW #HTU #_ #_ #J #X #Y #H destruct /2 width=3/
-| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #V #T #U #W #l #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #J #X #Y #H destruct
-| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #J #X #Y #H destruct
-  elim (IHTU1 ????) -IHTU1 [5: // |2,3,4: skip ] #Z1 #Z2 #l0 #HZ1 #HZ2 #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
-]
-qed.
-
-lemma snta_inv_bind1: ∀h,J,L,Y,X,U,l. ⦃h, L⦄ ⊢ ⓑ{J}Y.X :[l] U →
-                      ∃∃Z1,Z2,l0. ⦃h, L⦄ ⊢ Y :[l0] Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :[l] Z2 &
-                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
-/2 width=3/ qed-.
-
-fact snta_inv_cast1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀X,Y. T = ⓝY.X →
-                      ⦃h, L⦄ ⊢ X :[l] Y ∧ L ⊢ Y ⬌* U.
-#h #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #X #Y #H destruct
-| #L #K #V #W #U #i #l #_ #_ #_ #_ #X #Y #H destruct
-| #L #K #W #V #U #i #l #_ #_ #_ #_ #X #Y #H destruct
-| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #T #U #W #l #_ #_ #_ #_ #X #Y #H destruct
-| #L #T #U #W #l1 #l2 #HTU #_ #_ #_ #X #Y #H destruct /2 width=1/
-| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
-  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #HXY #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=1/
-]
-qed.
-
-lemma snta_inv_cast1: ∀h,L,X,Y,U,l. ⦃h, L⦄ ⊢ ⓝY.X :[l] U →
-                      ⦃h, L⦄ ⊢ X :[l] Y ∧ L ⊢ Y ⬌* U.
-/2 width=3/ qed-.
-
-(* Properties on relocation *************************************************)
-
-lemma snta_lift: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
-                 ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
-                 ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 →
-                 ⦃h, L2⦄ ⊢ T2 :[l] U2.
-#h #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
-[ #L1 #k #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  >(lift_inv_sort1 … H1) -X1
-  >(lift_inv_sort1 … H2) -X2 //
-| #L1 #K1 #V1 #W1 #W #i #l #HLK1 #_ #HW1 #IHVW1 #L2 #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // #W2 #HW12 #HWU2
-    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
-    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
-    /3 width=8/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
-    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
-  ]
-| #L1 #K1 #W1 #V1 #W #i #l #HLK1 #_ #HW1 #IHWV1 #L2 #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // <minus_plus #W #HW1 #HWU2
-    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
-    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
-    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
-    elim (lift_total V1 (d-i-1) e) /3 width=8/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
-    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct
-  elim (lift_total W1 d e) /4 width=6/
-| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #V2 #X #HV12 #H1 #H destruct
-  elim (lift_inv_bind1 … H1) -H1 #W21 #T2 #HW121 #HT12 #H destruct
-  elim (lift_inv_flat1 … H2) -H2 #Y2 #X #HY #H2 #H destruct
-  elim (lift_inv_bind1 … H2) -H2 #W22 #U2 #HW122 #HU12 #H destruct
-  lapply (lift_mono … HY … HV12) -HY #H destruct /4 width=6/
-| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct
-  elim (lift_total W1 d e) #W2 #HW12 /4 width=6/
-| #L1 #T1 #U1 #W1 #l1 #l2 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X #H #U2 #HU12
-  elim (lift_inv_flat1 … H) -H #X2 #T2 #HUX2 #HT12 #H destruct
-  lapply (lift_mono … HUX2 … HU12) -HUX2 #H destruct
-  elim (lift_total W1 d e) /3 width=6/
-| #L1 #T1 #U11 #U12 #V12 #l #_ #HU112 #_ #IHTU11 #IHUV12 #L2 #d #e #HL21 #U1 #HTU1 #U2 #HU12
-  elim (lift_total U11 d e) #U #HU11
-  elim (lift_total V12 d e) #V22 #HV122
-  lapply (cpcs_lift … HL21 … HU11 … HU12 HU112) -HU112 /3 width=6/
-]
-qed.
-
-(* Advanced forvard lemmas **************************************************)
-
-fact snta_fwd_pure1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀X,Y. T = ⓐY.X →
-                         ∃∃V,W,l0. ⦃h, L⦄ ⊢ Y :[l0+1] W & ⦃h, L⦄ ⊢ X :[l] V &
-                                   L ⊢ ⓐY.V ⬌* U.
-#h #L #T #U #l #H elim H -L -T -U -l
-[ #L #k #X #Y #H destruct
-| #L #K #V #W #U #i #l #_ #_ #_ #_ #X #Y #H destruct
-| #L #K #W #V #U #i #l #_ #_ #_ #_ #X #Y #H destruct
-| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
-| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #_ #_ #X #Y #H destruct /2 width=3/
-| #L #V #T #U #W #l #HTU #_ #_ #IHU #X #Y #H destruct
-  elim (IHU U Y ?) -IHU // /3 width=3/
-| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
-| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
-  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #V #W #l0 #HYW #HXV #HU1
-  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
-]
-qed.
-
-lemma snta_fwd_pure1: ∀h,L,X,Y,U,l. ⦃h, L⦄ ⊢ ⓐY.X :[l] U →
-                      ∃∃V,W,l0. ⦃h, L⦄ ⊢ Y :[l0+1] W & ⦃h, L⦄ ⊢ X :[l] V &
-                                L ⊢ ⓐY.V ⬌* U.
-/2 width=3/ qed-.
-
-lemma snta_fwd_correct: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U →
-                        ∃T0. ⦃h, L⦄ ⊢ U :[l-1] T0.
-#h #L #T #U #l #H elim H -L -T -U -l
-[ /2 width=2/
-| #L #K #V #W #W0 #i #l #HLK #_ #HW0 * #V0 #HWV0
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  elim (lift_total V0 0 (i+1)) /3 width=10/
-| #L #K #W #V #V0 #i #l #HLK #HWV #HWV0 #_
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  elim (lift_total V 0 (i+1)) /3 width=10/
-| #I #L #V #W #T #U #l1 #l2 #HVW #_ #_ * /3 width=3/
-| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #_ #_ * #X #H
-  elim (snta_inv_bind1 … H) -H /4 width=5/   
-| /3 width=2/
-| /2 width=2/
-| /2 width=2/
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma snta_cast_short: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ⦃h, L⦄ ⊢ ⓝU.T :[l] U.
-#h #L #T #U #l #HTU
-elim (snta_fwd_correct … HTU) /2 width=3/
-qed.
-
-lemma snta_typecheck: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U →
-                      ∃T0. ⦃h, L⦄ ⊢ ⓝU.T :[l] T0.
-/3 width=2/ qed.
-
-lemma snta_cast_old: ∀h,L,W,T,U,l.
-                    ⦃h, L⦄ ⊢ T :[l] U → ⦃h, L⦄ ⊢ U :[l-1] W → ⦃h, L⦄ ⊢ ⓝU.T :[l] ⓝW.U.
-#h #L #W #T #U #l #HTU #HUW
-@(snta_conv … U) /2 width=2/ /3 width=1/ (**) (* /4 width=3/ is a bit slow *)
-qed.
-
-lemma snta_appl_old: ∀h,L,V,W,T,U,l1,l2.
-                     ⦃h, L⦄ ⊢ V :[l1+1] W → ⦃h, L⦄ ⊢ T :[l2+1] ⓛW.U →
-                     ⦃h, L⦄ ⊢ ⓐV.T :[l2+1] ⓐV.ⓛW.U.
-#h #L #V #W #T #U #l1 #l2 #HVW #HTU
-elim (snta_fwd_correct … HTU) #X #H
-elim (snta_inv_bind1 … H) -H /4 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpr.etc
deleted file mode 100644 (file)
index 77b62e4..0000000
+++ /dev/null
@@ -1,278 +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/dynamic/snta_ltpss.ma".
-include "basic_2/dynamic/snta_thin.ma".
-include "basic_2/dynamic/lsubsn_snta.ma".
-
-(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
-(*
-lemma snta_fwd_abst: ∀h,L,W1,W2,T,U,l2. ⦃h, L⦄ ⊢ ⓛW1.T :[l2] ⓛW2.U →
-                     ∃∃V1,V2,l1. ⦃h, L⦄ ⊢ W1 :[l1] V1 & ⦃h, L⦄ ⊢ W2 :[l1] V2 &
-                                 L ⊢ W1 ⬌* W2.
-#h #L #W1 #W2 #T #U #l2 #HTU
-elim (snta_fwd_correct … HTU) #X #H
-elim (snta_inv_bind1 … H) -H #W #T0 #l #HW2 #_ #_ -X
-elim (snta_inv_bind1 … HTU) -HTU #V1 #U0 #l0 #HWV1 #_ #H
-elim (cpcs_inv_abst … H Abst W1) -H
-#HW12 #_ -U0
-@(ex3_3_intro … HWV1 … HW12)
-[3: @(snta_conv … HTU0 HU0) 
-
- /3 width=3/
-
-*)
-(*
-#h #L #V #T #U #l2 #HTU
-elim (snta_fwd_correct … HTU) #X #H
-elim (snta_inv_bind1 … H) -H #W #T0 #l1 #HVW #HUT0 #_ -X
-elim (snta_inv_bind1 … HTU) -HTU #W0 #U0 #l0 #_ #HTU0 #H -l0
-elim (cpcs_inv_abst … H Abst V) -H /3 width=3/
-qed-.
-*)
-(*
-lemma snta_fwd_appl1_sound_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
-                                        l < l0 → ⦃h, L1⦄ ⊢ T1 :[l] U →
-                                        L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
-                                       ) →
-                                ∀L,T,U,l2. ⦃h, L⦄ ⊢ T :[l2] U →
-                                ∀Z,Y,X1. T = ⓐZ.ⓛY.X1 → l0 = l2 →
-                                ∃l1. ⦃h, L⦄ ⊢ Z :[l1+1] Y.
-#h #l0 #IH #L #T #U #l2 #H elim H -L -T -U -l2
-[
-|
-|
-|
-| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #_ #_ #Z #Y #X1 #H1 #H2 destruct -IH
-  elim (snta_fwd_abst … HTU) -X1 -U -l2 #Y0 #W0 #l0 #HY0 #H1 #HYW2
-  elim (snta_fwd_correct … HVW2) #W #H2
-  elim (snta_mono … H1 … H2) -H1 -H2 #H #_ destruct -W0 -W /4 width=6/
-| #L #V #T #U #W #l #HTU #HUW #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
-  elim (snta_inv_abst_sn … HTU) -HTU #Y0 #l0 #HY0 #HX12
-|
-| #L #T #U1 #U2 #V2 #l #HTU1 #HU12 #HUV2 #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-lemma snta_inv_appl_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
-                                 l < l0 + 1 → ⦃h, L1⦄ ⊢ T1 :[l] U →
-                                 L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
-                                ) →
-                         ∀L,T,U,l2. ⦃h, L⦄ ⊢ T :[l2] U →
-                         ∀Z,Y,X1,X2. T = ⓐZ.ⓛY.X1 → U = ⓐZ.ⓛY.X2 → l0 = l2 →
-                         ∃∃l1. ⦃h, L⦄ ⊢ Z :[l1+1] Y & ⦃h, L.ⓛY⦄ ⊢ X1 :[l2] X2.
-#h #l0 #IH #L #T #U #l2 * -L -T -U -l2
-[
-|
-|
-|
-| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #Z #Y #X1 #X2 #H1 #H2 #H3 destruct -IH
-  elim (snta_inv_abst … HTU) -HTU /2 width=2/
-| #L #V #T #U #W #l #HTU #HUW #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
-  elim (snta_inv_abst … HTU) -HTU #Y0 #l0 #HY0 #HX12
-|
-| #L #T #U1 #U2 #V2 #l #HTU1 #HU12 #HUV2 #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
-  
-   /2 width=2/
-
-
-axiom pippo: ∀h,l0. (∀L1,L2,T1,T2,U,l.
-                l < l0 + 1 → ⦃h, L1⦄ ⊢ T1 :[l] U →
-                L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
-             ) →
-             ∀L,T1,U1,l. ⦃h, L⦄ ⊢ T1 :[l] U1 →
-             ∀V2,W2,T2. L ⊢ T1 ➡* ⓐV2.ⓛW2.T2 → l0 = l →
-             ∃l0. ⦃h, L2⦄ ⊢ V2 :[l0+1] W2.
-(*
-#h #l #IH #L1 #T1 #U1 #l1 * -L1 -T1 -U1 -l1
-[
-|
-|
-|
-| #L1 #V1 #W1 #T1 #U1 #l1 #HVW1 #HTU1 #Y1 #X1 #H1 #L2 #Y2 #HL12 #HY12 #Z2 #X2 #HX12 #H2 destruct
-  elim (IH ??? Y2 … HVW1 HL12 ?) -HVW1 // [2: /3 width=1/ ] -HY12 #l21 #HY2W1 #H1l21 #H2l21
-  elim (IH … HTU1 HL12 HX12) -IH -HTU1 -HL12 -HX12 // #l22 #H #_ #H2l22
-  elim (snta_inv_bind1 … H) -H #Z #X #HZ2 #_ #H
-  elim (cpcs_inv_abst … H Abst W1) -H #H #_
-  lapply (transitive_le … (l21+l22) … H1l21 ?) -H1l21 // #Hl21
-  @(ex3_1_intro … Hl21) [2: /3 width=1/ ]
-  @(snta_conv … W1) /2 width=2/ (**) (* explicit constructors *)
-| #L1 #V1 #T1 #U1 #W1 #l1 #HTU1 #HUW1 #Y1 #X1 #H1 #L2 #Y2 #HL12 #HY12 #Z2 #X2 #HX12 #H2 destruct
-
-*)
-(* Properties on context-free parallel reduction for local environments *****)
-*)
-fact snta_ltpr_tpr_conf_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
-                                l < l0 → ⦃h, L1⦄ ⊢ T1 :[l] U →
-                                L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
-                             ) →
-                             ∀L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U → ∀L2. L1 ➡ L2 →
-                             ∀T2. T1 ➡ T2 → l0 = l → ⦃h, L2⦄ ⊢ T2 :[l] U.
-#h #l0 #IH #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
-[ #L1 #k1 #L2 #_ #T2 #H #_ -l0
-  >(tpr_inv_atom1 … H) -H //
-| #L1 #K1 #V1 #W #U #i1 #l #HLK1 #_ #HWU #IHV1 #L2 #HL12 #T2 #H #Hl -IH
-  >(tpr_inv_atom1 … H) -T2
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
-  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
-| #L1 #K1 #W1 #V1 #U1 #i1 #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #HL12 #T2 #H #Hl -IH
-(*  
-  >(tpr_inv_atom1 … H) -T2
-  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
-  elim (ltpr_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
-  lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-  elim (lift_total V1 0 (i+1)) #W #HW
-  lapply (snta_lift h … HLK … HWU1 … HW) /2 width=1/ -HLK -HW
-  elim (lift_total W2 0 (i+1)) #U2 #HWU2
-  lapply (tpr_lift … HW12 … HWU1 … HWU2) -HWU1 #HU12
-  @(snta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /3 width=6/ is too slow *)
-*)
-| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H #Hl -IH
-(*  
-  elim (tpr_inv_bind1 … H) -H *
-  [ #V2 #T #T2 #HV12 #HT1 #HT2 #H destruct
-    lapply (IHVW1 … HL12 … HV12) #HV2W1
-    lapply (IHVW1 L2 … V1 ?) // -IHVW1 #HWV1
-    lapply (IHTU1 (L2.ⓑ{I}V2) … HT1) -HT1 /2 width=1/ #HTU1
-    lapply (IHTU1 (L2.ⓑ{I}V1) ? T1 ?) -IHTU1 // /2 width=1/ -HL12 #H
-    lapply (tps_lsubs_trans … HT2 (L2.ⓑ{I}V2) ?) -HT2 /2 width=1/ #HT2
-    lapply (snta_tps_conf … HTU1 … HT2) -T #HT2U1
-    elim (snta_fwd_correct … H) -H #U2 #HU12
-    @(snta_conv … (ⓑ{I}V2.U1)) /2 width=2/ /3 width=1/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-  | #T #HT1 #HTX #H destruct
-    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HVW1
-    lapply (IHTU1 (L2.ⓓV1) … HT1) -T1 /2 width=1/ -L1 #H
-    elim (snta_fwd_correct … H) #T1 #HUT1
-    elim (snta_ldrop_conf … H L2 0 1 ? ?) -H // /2 width=1/ #T0 #U0 #HTU0 #H #HU10
-    lapply (delift_inv_lift1_eq … H L2 … HTX) -H -HTX /2 width=1/ #H destruct
-    @(snta_conv … HTU0) /2 width=2/
-  ]
-*)
-| #L1 #V1 #W11 #W2 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H #Hl -IH
-(*
-  elim (tpr_inv_appl1 … H) -H *
-  [ #V2 #Y #HV12 #HY #H destruct
-    elim (tpr_inv_abst1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
-    lapply (IHTU1 L2 ? (ⓛW1.T1) ?) // #H
-    elim (snta_fwd_correct … H) -H #X #H
-    elim (snta_inv_bind1 … H) -H #W #U #HW #HU #_
-    @(snta_conv … (ⓐV2.ⓛW1.U1)) /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
-    lapply (IHVW1 … HL12 … HV12) #HVW2
-    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HV1W2
-    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 -HL12 /2 width=1/ -HT02 #H1
-    elim (snta_fwd_correct … H1) #T #H2
-    elim (snta_inv_bind1 … H1) -H1 #W #U2 #HW2 #HTU2 #H
-    elim (cpcs_inv_abst … H Abst W2) -H #_ #HU21
-    elim (snta_inv_bind1 … H2) -H2 #W0 #U0 #_ #H #_ -T -W0
-    lapply (lsubsn_snta_trans … HTU2 (L2.ⓓV2) ?) -HTU2 /2 width=1/ #HTU2
-    @(snta_conv … (ⓓV2.U2)) /2 width=2/ /3 width=2/ (**) (* explicit constructor, /4 width=5/ is too slow *)
-  | #V0 #V2 #W0 #W2 #T0 #T2 #_ #_ #_ #_ #H destruct
-  ]
-*)
-| #L1 #V1 #T1 #U1 #W1 #l #_ #HUW1 #IHTU1 #_ #L2 #HL12 #X #H #Hl
-  elim (tpr_inv_appl1 … H) -H *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (cpr_tpr … HV12 L2) #HV
-    elim (snta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) (l+1) ?) [2: /3 width=6/ ] #U
-    @(snta_conv … (ⓐV2.U1)) /2 width=1/ -HV12 /4 width=8 by snta_pure, cprs_flat_dx/ (**) (* explicit constructor, /4 width=8/ is too slow without trace *)
-  | #V2 #W0 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
-    lapply (IHTU1 … HL12 (ⓛW0.T2) ? ?) -IHTU1 // /2 width=1/ -T0 #H1
-    lapply (IH … (ⓐV2.U1) … HUW1 HL12 ?) // /3 width=1/ #H2
-    lapply (snta_pure … H1 H2) -H2 #H
-    elim (snta_inv_bind1 … H1) -H1 #V0 #U2 #l1 #HWV0 #HTU2 #HU21
-    @(snta_conv … (ⓓV2.U2)) (**) (* explicit constructor *)
-    [2:
-(*
-        @snta_bind /3 width=2/ /3 width=6/ (**) (* /4 width=6/ is a bit slow *)
-*)
-    |3: @(cpcs_cpr_conf … (ⓐV1.ⓛW0.U2)) /2 width=1/
-    |4: /2 width=5/
-    | skip
-    ]
-(*
-    elim (snta_fwd_pure1 … H) -H #T1 #W2 #HVW2 #HUT1 #HTW1
-
-    elim (cpcs_inv_abst1 … HU21) #W3 #U3 #HU13 #H
-    elim (cprs_inv_abst … H Abst W0) -H #HW03 #_
-    elim (pippo … IH … HUW1 ? V2 W3 U3 HL12 ? ?) -IH -HUW1 -HL12 // /3 width=1/ -HU13 #l2 #HV2W3
-    lapply (snta_conv h L2 V2 W3 W0 V0 (l1+1) ? ? ?) /2 width=1/ -HV2W3 -HW03 -HWV0 #HV2W0    
-*)    
-(* SEGMENT 1.5
-    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HB
-    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
-    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 /width=5/ -T0 /2 width=1/ -L1 -V1 /4 width=7/
-    
-axiom pippo: ⦃h, L⦄ ⊢ ⓐV.X : Y →
-             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ ⓐV : W.
-
-*)
-(* SEGMENT 2
-| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
-  lapply (cpr_tpss … HU12) /4 width=4/
-| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
-  @(snta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
-]
-qed.
-*)
-
-(* SEGMENT 3
-fact snta_ltpr_tpr_conf_aux: ∀h,L,T,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → L = L1 → T = T1 →
-                            ∀L2. L1 ➡ L2 → ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
-  
-  
-  | #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
-    elim (snta_inv_abbr … HT1) -HT1 #B0 #HW0 #HT0
-    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
-    lapply (IH … HV1 … HL12 … HV10) -HV1 -HV10 /width=5/ #HV0
-    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 /width=5/ -V1 -T0 /2 width=1/ -L1 -W0 #HT2
-    @(snta_abbr … HW2) -HW2
-    @(snta_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
-  ]
-| #L1 #V1 #T1 #A #HV1 #HT1 #H1 #H2 #L2 #HL12 #X #H destruct
-  elim (tpr_inv_cast1 … H) -H
-  [ * #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
-    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
-  | -HV1 #HT1X
-     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
-  ]
-]
-qed.
-
-lemma snta_ltpr_tpr_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
-                         ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
-
-/2 width=9/ qed.
-
-axiom snta_ltpr_conf: ∀L1,T,A. L1 ⊢ T : A → ∀L2. L1 ➡ L2 → L2 ⊢ T : A.
-/2 width=5/ qed.
-
-axiom snta_tpr_conf: ∀L,T1,A. L ⊢ T1 : A → ∀T2. T1 ➡ T2 → L ⊢ T2 : A.
-/2 width=5/ qed.
-*)
-*)*)
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_ltpss.etc
deleted file mode 100644 (file)
index 0e5f393..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/equivalence/cpcs_ltpss.ma".
-include "basic_2/dynamic/snta_snta.ma".
-
-(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Properties about parallel unfold *****************************************)
-
-lemma snta_ltpss_tpss_conf: ∀h,L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U →
-                            ∀L2,d,e. L1 ▶* [d, e] L2 →
-                            ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 :[l] U.
-#h #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
-[ #L1 #k #L2 #d #e #_ #T2 #H
-  >(tpss_inv_sort1 … H) -H //
-| #L1 #K1 #V1 #W #U #i #l #HLK1 #_ #HWU #IHV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H
-  [ #H destruct
-    elim (lt_or_ge i d) #Hdi
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
-      /3 width=7/
-    | elim (lt_or_ge i (d + e)) #Hide [ | -Hdi ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
-        /3 width=7/
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=7/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
-    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
-    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=9/
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
-  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
-  [ #H destruct
-    elim (lift_total V1 0 (i+1)) #W #HW
-    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
-    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
-      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #W2 #HK12 #HW12 #H destruct
-      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-      lapply (snta_lift h … HLK … HWU1 … HW) [ /2 width=4/ | skip ] -HW #H
-      elim (lift_total W2 0 (i+1)) #U2 #HWU2
-      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
-      lapply (cpr_tpss … HU12) -HU12 #HU12
-      @(snta_conv … U2) // /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -HW -Hdi ]
-      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
-        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #W2 #HK12 #HW12 #H destruct
-        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
-        lapply (snta_lift h … HLK … HWU1 … HW) [ /2 width=4/ | skip ] -HW #H
-        elim (lift_total W2 0 (i+1)) #U2 #HWU2
-        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
-        lapply (cpr_tpss … HU12) -HU12 #HU12
-        @(snta_conv … U2) // /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
-      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=6/
-      ]
-    ]
-  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
-    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
-    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
-    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HV
-  lapply (IHTU1 (L2.ⓑ{I}V1) (d+1) e ? T1 ?) // /2 width=1/ #H
-  elim (snta_fwd_correct … H) -H #U2 #HU12
-  @(snta_conv … (ⓑ{I}V2.U1)) /3 width=2/ /3 width=4/ /4 width=4/ (**) (* explicit constructor, /5 width=6/ is too slow *)
-| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
-  elim (tpss_inv_bind1 … HY) -HY #W21 #T2 #HW121 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HVV12
-  lapply (IHTU1 L2 d e ? (ⓛW21.T2) ?) -IHTU1 // /2 width=1/ -HW121 -HT12 #H0
-  elim (snta_fwd_correct … H0) #X #H
-  elim (snta_inv_bind1 … H) -H #W #U #l0 #HW #HU #_
-  @(snta_conv … (ⓐV2.ⓛW12.U1)) /3 width=2/ /3 width=4/ /3 width=5/ (**) (* explicit constructor, /4 width=5/ is too slow *)
-| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
-  lapply (cpr_tpss … HV12) #HV
-  elim (snta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) (l+1) ?) [2: /3 width=4/ ] #U
-  @(snta_conv … (ⓐV2.U1)) /3 width=1/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
-| #L1 #T1 #U1 #W1 #l1 #l2 #HTU1 #HUW1 #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
-  elim (snta_fwd_correct … HTU1) -HTU1 #U #H
-  elim (snta_mono … HUW1 … H) -HUW1 -H #H #_ -U destruct
-  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
-  lapply (cpr_tpss … HU12) #HU /4 width=4/
-| #L1 #T1 #U11 #U12 #U #l #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
-  @(snta_conv … U11) /2 width=5/ (**) (* explicit constructor, /3 width=7/ is too slow *)
-]
-qed.
-
-lemma snta_ltpss_tps_conf: ∀h,L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U →
-                           ∀L2,d,e. L1 ▶* [d, e] L2 →
-                           ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → ⦃h, L2⦄ ⊢ T2 :[l] U.
-/3 width=7/ qed.
-
-lemma snta_ltpss_conf: ∀h,L1,T,U,l. ⦃h, L1⦄ ⊢ T :[l] U →
-                       ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T :[l] U.
-/2 width=7/ qed.
-
-lemma snta_tpss_conf: ∀h,L,T1,U,l. ⦃h, L⦄ ⊢ T1 :[l] U →
-                      ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 :[l] U.
-/2 width=7/ qed.
-
-lemma snta_tps_conf: ∀h,L,T1,U,l. ⦃h, L⦄ ⊢ T1 :[l] U →
-                     ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 :[l] U.
-/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_snta.etc
deleted file mode 100644 (file)
index db71e11..0000000
+++ /dev/null
@@ -1,65 +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/dynamic/snta_lift.ma".
-
-(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Main properties **********************************************************)
-
-theorem snta_mono: ∀h,L,T,U1,l1. ⦃h, L⦄ ⊢ T :[l1] U1 →
-                   ∀U2,l2. ⦃h, L⦄ ⊢ T :[l2] U2 → l1 = l2 ∧ L ⊢ U1 ⬌* U2.
-#h #L #T #U1 #l1 #H elim H -L -T -U1 -l1
-[ #L #k #X #l2 #H
-  lapply (snta_inv_sort1 … H) -H * /2 width=1/
-| #L #K #V #W11 #W12 #i #l1 #HLK #_ #HW112 #IHVW11 #X #l2 #H
-  elim (snta_inv_lref1 … H) -H * #K0 #V0 #W21 #W22 #HLK0 #HVW21 #HW212 #HX
-  lapply (ldrop_mono … HLK0 … HLK) -HLK0 #H destruct
-  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
-  elim (IHVW11 … HVW21) -IHVW11 -HVW21 #Hl12 #HW121
-  lapply (cpcs_lift … HLK … HW112 … HW212 ?) // -K -W11 -W21 /3 width=3/
-| #L #K #W #V1 #V #i #l1 #HLK #_ #HWV #IHWV1 #X #l2 #H
-  elim (snta_inv_lref1 … H) -H * #K0 #W0 #V2 #V0 #HLK0 #HW0V2 #HWV0 [2: #HL2 ] #HX
-  lapply (ldrop_mono … HLK0 … HLK) -HLK0 -HLK #H destruct
-  lapply (lift_mono … HWV0 … HWV) -HWV0 -HWV #H destruct
-  elim (IHWV1 … HW0V2) -IHWV1 -HW0V2 /3 width=1/
-| #I #L #V #W1 #T #U1 #l10 #l1 #_ #_ #_ #IHTU1 #X #l2 #H
-  elim (snta_inv_bind1 … H) -H #W2 #U2 #l20 #_ #HTU2 #H
-  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
-  lapply (cpcs_trans … (ⓑ{I}V.U1) … H) -H /2 width=1/
-| #L #V #W #W1 #T #U1 #l10 #l1 #_ #_ #_ #IHTU1 #X #l2 #H
-  elim (snta_fwd_pure1 … H) -H #U2 #W2 #l20 #_ #HTU2 #H
-  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
-  lapply (cpcs_trans … (ⓐV.ⓛW1.U1) … H) -H /2 width=1/
-| #L #V #T #U1 #W1 #l1 #_ #_ #IHTU1 #_ #X #l2 #H
-  elim (snta_fwd_pure1 … H) -H #U2 #W2 #l20 #_ #HTU2 #H
-  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
-  lapply (cpcs_trans … (ⓐV.U1) … H) -H /2 width=1/
-| #L #T #U1 #W1 #l10 #l1 #_ #_ #IHTU1 #_ #X #l2 #H
-  elim (snta_inv_cast1 … H) -H #HTU1
-  elim (IHTU1 … HTU1) -IHTU1 -HTU1 /2 width=1/
-| #L #T #U11 #U12 #V12 #l1 #_ #HU112 #_ #IHTU11 #_ #U2 #l2 #HTU2
-  elim (IHTU11 … HTU2) -IHTU11 -HTU2 #Hl12 #H
-  lapply (cpcs_canc_sn … HU112 … H) -U11 /2 width=1/
-]
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma snta_cast_alt: ∀h,L,T,W,U,l. ⦃h, L⦄ ⊢ T :[l] W → ⦃h, L⦄ ⊢ T :[l] U →
-             ⦃h, L⦄ ⊢ ⓝW.T :[l] U.
-#h #L #T #W #U #l #HTW #HTU
-elim (snta_mono … HTW … HTU) #_ #HWU
-elim (snta_fwd_correct … HTU) -HTU /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snta/snta_thin.etc
deleted file mode 100644 (file)
index ceb5375..0000000
+++ /dev/null
@@ -1,116 +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/unfold/thin_ldrop.ma".
-include "basic_2/equivalence/cpcs_delift.ma".
-include "basic_2/dynamic/snta_lift.ma".
-
-(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
-
-(* Properties on basic local environment thinning ***************************)
-
-(* Note: this is known as the substitution lemma *)
-lemma snta_thin_conf: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
-                      ∀L2,d,e. ≽ [d, e] L1 → L1 ▼*[d, e] ≡ L2 →
-                      ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 :[l] U2 &
-                               L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
-#h #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
-[ /2 width=5/
-| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL1 #HL12
-  elim (lt_or_ge i d) #Hdi [ -HVW1 ]
-  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
-    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
-    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
-    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
-    elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #X2 #W2 #HVW2 #H #HW12
-    lapply (delift_mono … H … HV12) -H -HV12 #H destruct
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (ldrop_fwd_ldrop2 … HLK1) -V1 #HLK1
-    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
-    >minus_plus <plus_minus_m_m // /3 width=6/
-  | elim (lt_or_ge i (d+e)) #Hide [ -HVW1 | -Hdi -IHVW1 -HL1 ]
-    [ lapply (sfr_ldrop_trans_be_up … HLK1 … HL1 ? ?) -HL1 // /2 width=2/ <minus_n_O #H
-      elim (sfr_inv_bind … H ?) -H /2 width=1/ #HK1 #_
-      elim (thin_ldrop_conf_be … HL12 … HLK1 ? ?) -HL12 /2 width=2/ #K2 #H #HLK2
-      lapply (thin_inv_thin1 … H ?) -H /2 width=1/ #HK12
-      elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #V2 #W2 #HVW2 #HV12 #HW12
-      elim (lift_total V2 0 d) #T2 #HVT2
-      elim (lift_total W2 0 d) #U2 #HWU2
-      elim (lift_total W2 0 (i+1)) #U #HW2U
-      lapply (snta_lift … HVW2 … HLK2 … HVT2 … HWU2) -HVW2 -HLK2 #HTU2
-      lapply (ldrop_fwd_ldrop2 … HLK1) #HLK0
-      lapply (delift_lift_ge … HW12 … HLK0 HWU1 … HW2U) -HW12 -HLK0 -HWU1 // >minus_plus #HU1
-      lapply (lift_conf_be … HWU2 … HW2U ?) -W2 /2 width=1/ #HU2
-      lapply (delift_lift_div_be … HU1 … HU2 ? ?) -U // /2 width=1/ /3 width=8/
-    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
-      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
-      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
-      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
-      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
-    ]
-  ]
-| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL1 #HL12
-  elim (lt_or_ge i d) #Hdi [ -HWV1 | -IHWV1 ]
-  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
-    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
-    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
-    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
-    elim (IHWV1 … HK1 HK12) -IHWV1 -HK1 -HK12 #X2 #V2 #HWV2 #H #_
-    lapply (delift_mono … H … HW12) -H #H destruct
-    elim (lift_total W2 0 (i+1)) #U2 #HWU2
-    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
-    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
-    >minus_plus <plus_minus_m_m // /3 width=6/
-  | elim (lt_or_ge i (d+e)) #Hide [ -HWV1 -HWU1 -HL12 | -Hdi -HL1 ]
-    [ lapply (sfr_inv_ldrop … HLK1 … HL1 ? ?) -HLK1 -HL1 // -Hdi -Hide #H destruct 
-    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
-      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
-      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
-      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
-      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
-    ]
-  ]
-| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
-  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #_
-  elim (IHTU1 (L2.ⓑ{I}V2) (d+1) e ? ?) -IHTU1 /2 width=1/ -HL1 -HL12 #T2 #U2 #HTU2 #HT12 #HU12
-  lapply (delift_lsubs_trans … HT12 (L1.ⓑ{I}V2) ?) -HT12 /2 width=1/
-  lapply (delift_lsubs_trans … HU12 (L1.ⓑ{I}V2) ?) -HU12 /2 width=1/ /3 width=7/
-| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
-  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W22 #HVW2 #HV12 #HW122
-  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 #X2 #Y2 #HXY2 #HX2 #HY2
-  elim (delift_inv_bind1 … HX2) -HX2 #W21 #T2 #W121 #HT12 #H destruct
-  elim (delift_inv_bind1 … HY2) -HY2 #X #U2 #HX #HU12 #H destruct
-  lapply (delift_mono … HX … HW122) -HX #H destruct
-  @(ex3_2_intro … (ⓐV2.ⓛW21.T2) (ⓐV2.ⓛW22.U2)) [ /2 width=2/ | 2,3: /3 width=1/ ] (**) (* explict constructor, /4 depth=?/ is too slow *)
-| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
-  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
-  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #X2 #W2 #HXW2 #H #HW12
-  elim (delift_inv_flat1 … H) -H #V2 #Y2 #HV12 #HY2 #H destruct
-  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=7/
-| #L1 #T1 #U1 #W1 #l1 #l2 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
-  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
-  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #Y2 #W2 #HUW2 #HY2 #HW12
-  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=5/
-| #L1 #T1 #U11 #U12 #V1 #l #_ #HU112 #_ #IHT1 #IHU12 #L2 #d #e #HL1 #HL12
-  elim (IHT1 … HL1 HL12) -IHT1 #T2 #U21 #HT2 #HT12 #HU121
-  elim (IHU12 … HL1 HL12) -IHU12 -HL1 #U22 #V2 #HU22 #HU122 #_
-  lapply (thin_cpcs_delift_mono … HU112 … HL12 … HU121 … HU122) -HU112 -HL12 -HU121 /3 width=5/
-]
-qed.
-
-lemma snta_ldrop_conf: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
-                       ∀L2,d,e. ≽ [d, e] L1 → ⇩[d, e] L1 ≡ L2 →
-                       ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 :[l] U2 &
-                                L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
-/3 width=1/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_cpcs.etc
deleted file mode 100644 (file)
index 9e68edf..0000000
+++ /dev/null
@@ -1,182 +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/unfold/lstas_lstas.ma".
-include "basic_2/computation/fpbs_lift.ma".
-include "basic_2/computation/fpbg_fleq.ma".
-include "basic_2/equivalence/cpes_cpds.ma".
-include "basic_2/dynamic/snv.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Inductive premises for the preservation results **************************)
-
-definition IH_snv_cpx_lpx: ∀h:sh. sd h → relation3 genv lenv term ≝
-                           λh,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                           ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
-
-definition IH_da_cpr_lpr: ∀h:sh. sd h → relation3 genv lenv term ≝
-                          λ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.
-
-definition IH_lstas_cpr_lpr: ∀h:sh. sd h → relation3 genv lenv term ≝
-                             λ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, l2] U1 →
-                             ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                             ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*[h, l2] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
-
-(* Properties for the preservation results **********************************)
-
-fact snv_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
-/3 width=6 by lpr_lpx, cpr_cpx/ qed-.
-
-fact snv_sta_aux: ∀h,g,G0,L0,T0.
-                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                  ∀G,L,T. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L⦄ ⊢ T ¡[h, g] →
-                  ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 →
-                  ∀U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ U ¡[h, g].
-/3 width=6 by sta_cpx/ qed-.
-
-fact snv_cpxs_lpx_aux: ∀h,g,G0,L0,T0.
-                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                       ∀T2. ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
-#h #g #G0 #L0 #T0 #IH #G #L1 #T1 #HLT0 #HT1 #T2 #H
-@(cpxs_ind … H) -T2 /4 width=6 by fpbg_fpbs_trans, cpxs_fpbs/
-qed-.
-
-fact snv_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                       ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
-/3 width=10 by snv_cpxs_lpx_aux, cprs_cpxs, lpr_lpx/ qed-.
-
-fact snv_lstas_aux: ∀h,g,G0,L0,T0.
-                    (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                    ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 → ⦃G, L1⦄ ⊢ U1 ¡[h, g].
-/3 width=12 by snv_cpxs_lpx_aux, lstas_cpxs/ qed-.
-
-fact da_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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
-@(cprs_ind … H) -T2 /4 width=10 by snv_cprs_lpr_aux, fpbg_fpbs_trans, cprs_fpbs/
-qed-.
-
-fact da_cpcs_aux: ∀h,g,G0,L0,T0.
-                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                  ∀G,L,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
-                  ∀T2. ⦃G0, L0, T0⦄ >≡[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
-elim (cpcs_inv_cprs … H) -H /4 width=18 by da_cprs_lpr_aux, da_mono/
-qed-.
-
-fact sta_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                      ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l+1 →
-                      ∀U1. ⦃G, L1⦄ ⊢ T1 •[h] U1 →
-                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                      ∃∃U2. ⦃G, L2⦄ ⊢ T2 •[h] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
-#h #g #G0 #L0 #T0 #IH #G #L1 #T1 #H01 #HT1 #l #Hl #U1 #HTU1 #T2 #HT12 #L2 #HL12
-elim (IH … H01 … 1 … Hl U1 … HT12 … HL12) -H01 -Hl -HT12 -HL12
-/3 width=3 by lstas_inv_SO, sta_lstas, ex2_intro/
-qed-.
-
-fact lstas_cprs_lpr_aux: ∀h,g,G0,L0,T0.
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                         ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 →
-                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                         ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*[h, l2] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
-#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G #L1 #T1 #H01 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 #H
-@(cprs_ind … H) -T2 [ /2 width=10 by/ ]
-#T #T2 #HT1T #HTT2 #IHT1 #L2 #HL12
-elim (IHT1 L1) // -IHT1 #U #HTU #HU1
-elim (IH1 … Hl21 … HTU … HTT2 … HL12) -IH1 -HTU -HTT2
-[2: /3 width=12 by da_cprs_lpr_aux/
-|3: /3 width=10 by snv_cprs_lpr_aux/
-|4: /3 width=5 by fpbg_fpbs_trans, cprs_fpbs/
-] -G0 -L0 -T0 -T1 -T -l1
-/4 width=5 by lpr_cpcs_conf, cpcs_trans, ex2_intro/
-qed-.
-
-fact lstas_cpcs_lpr_aux: ∀h,g,G0,L0,T0.
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                         ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l] U1 →
-                         ∀T2. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T2⦄ → ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
-                         ∀l2. l ≤ l2 → ⦃G, L1⦄ ⊢ T2 ▪[h, g] l2 → ∀U2. ⦃G, L1⦄ ⊢ T2 •*[h, 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
-elim (cpcs_inv_cprs … H) -H #T #H1 #H2
-elim (lstas_cprs_lpr_aux … H01 HT1 … Hl1 HTl1 … HTU1 … H1 … HL12) -T1 /2 width=1 by/ #W1 #H1 #HUW1
-elim (lstas_cprs_lpr_aux … H02 HT2 … Hl2 HTl2 … HTU2 … H2 … HL12) -T2 /2 width=1 by/ #W2 #H2 #HUW2 -L0 -T0
-lapply (lstas_mono … H1 … H2) -h -T -l #H destruct /2 width=3 by cpcs_canc_dx/
-qed-.
-
-fact lstas_cpds_aux: ∀h,g,G0,L0,T0.
-                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                     ∀G,L,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 → ∀T2. ⦃G, L⦄ ⊢ T1 •*➡*[h, g] T2 →
-                     ∃∃U2,l. l ≤ l2 & ⦃G, L⦄ ⊢ T2 •*[h, l] U2 & ⦃G, L⦄ ⊢ U1 •*⬌*[h, g] U2.
-#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G #L #T1 #H01 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 * #T #l0 #l #Hl0 #H #HT1T #HTT2
-lapply (da_mono … H … Hl1) -H #H destruct
-lapply (lstas_da_conf … HTU1 … Hl1) #Hl12
-elim (le_or_ge l2 l) #Hl2
-[ lapply (lstas_conf_le … HTU1 … HT1T) -HT1T
-  /5 width=11 by cpds_cpes_dx, monotonic_le_minus_l, ex3_2_intro, ex4_3_intro/
-| lapply (lstas_da_conf … HT1T … Hl1) #Hl1l
-  lapply (lstas_conf_le … HT1T … HTU1) -HTU1 // #HTU1
-  elim (lstas_cprs_lpr_aux … IH3 IH2 IH1 … Hl1l … HTU1 … HTT2 L) -IH2 -IH1 -Hl1l -HTU1 -HTT2
-  /3 width=12 by snv_lstas_aux, cpcs_cpes, fpbg_fpbs_trans, lstas_fpbs, monotonic_le_minus_l, ex3_2_intro/
-]
-qed-.
-
-fact cpds_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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.
-#h #g #G0 #L0 #T0 #IH2 #IH1 #G #L1 #T1 #H01 #HT1 #U1 * #W1 #l1 #l2 #Hl21 #Hl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
-elim (IH1 … H01 … HTW1 … HT12 … HL12) -IH1 // #W2 #HTW2 #HW12
-lapply (IH2 … H01 … Hl1 … HT12 … HL12) -L0 -T0 // -T1
-lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
-lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
-elim (cpcs_inv_cprs … H) -H /3 width=7 by ex4_3_intro, ex2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_da_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_da_lpr.etc
deleted file mode 100644 (file)
index 119a402..0000000
+++ /dev/null
@@ -1,93 +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/static/lsubd_da.ma".
-include "basic_2/computation/cpds_cpds.ma".
-include "basic_2/dynamic/snv_aaa.ma".
-include "basic_2/dynamic/snv_cpcs.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties on degree assignment for terms ********************************)
-
-fact da_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[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 #IH2 #IH1 #G1 #L1 * * [|||| * ]
-[ #k #_ #_ #_ #_ #l #H2 #X3 #H3 #L2 #_ -IH2 -IH1
-  lapply (da_inv_sort … H2) -H2
-  lapply (cpr_inv_sort1 … H3) -H3 #H destruct /2 width=1 by da_sort/
-| #i #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
-  elim (snv_inv_lref … H1) -H1 #I0 #K0 #X0 #H #HX0
-  elim (da_inv_lref … H2) -H2 * #K1 [ #V1 | #W1 #l1 ] #HLK1 [ #HV1 | #HW1 #H ] destruct
-  lapply (ldrop_mono … H … HLK1) -H #H destruct
-  elim (cpr_inv_lref1 … H3) -H3
-  [1,3: #H destruct
-    lapply (fqup_lref … G1 … HLK1)
-    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
-    elim (lpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
-    /4 width=10 by da_ldef, da_ldec, fqup_fpbg/
-  |2,4: * #K0 #V0 #W0 #H #HVW0 #HW0
-    lapply (ldrop_mono … H … HLK1) -H #H destruct
-    lapply (fqup_lref … G1 … HLK1)
-    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
-    elim (lpr_inv_pair1 … H) -H #K2 #V2 #HK12 #_ #H destruct
-    lapply (ldrop_fwd_drop2 … HLK2) -V2
-    /4 width=8 by da_lift, fqup_fpbg/
-  ]
-| #p #_ #_ #HT0 #H1 destruct -IH2 -IH1
-  elim (snv_inv_gref … H1)
-| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
-  elim (snv_inv_bind … H1) -H1 #_ #HT1
-  lapply (da_inv_bind … H2) -H2
-  elim (cpr_inv_bind1 … H3) -H3 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    /4 width=9 by da_bind, fqup_fpbg, lpr_pair/
-  | #T2 #HT12 #HT2 #H1 #H2 destruct
-    /4 width=11 by da_inv_lift, fqup_fpbg, lpr_pair, ldrop_drop/
-  ]
-| #V1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct
-  elim (snv_inv_appl … H1) -H1 #b0 #W1 #W0 #T0 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HT10
-  lapply (da_inv_flat … H2) -H2 #Hl
-  elim (cpr_inv_appl1 … H3) -H3 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct -IH2 /4 width=7 by da_flat, fqup_fpbg/
-  | #b #V2 #W #W2 #U1 #U2 #HV12 #HW2 #HU12 #H1 #H2 destruct
-    elim (snv_inv_bind … HT1) -HT1 #HW #HU1
-    lapply (da_inv_bind … Hl) -Hl #Hl
-    elim (cpds_inv_abst1 … HT10) -HT10 #W3 #U3 #HW3 #_ #H destruct -U3
-    lapply (cprs_div … HW3 … HW10) -W3 #HWW1
-    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #H
-    elim (snv_fwd_da … HW) #l1 #Hl1
-    lapply (snv_lstas_aux … IH2 … HV1 … 1 … Hl0 W1 ?) /2 width=2 by fqup_fpbg, sta_lstas/ #HW1
-    lapply (da_cpcs_aux … IH2 IH1 … Hl1 … H … HWW1) -H
-    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
-    lapply (IH1 … HV1 … Hl0 … HV12 … HL12) -HV1 -Hl0 -HV12 [ /2 by fqup_fpbg/ ] #Hl0
-    lapply (IH1 … Hl1 … HW2 … HL12) -Hl1 // /2 width=1 by fqup_fpbg/ -HW
-    lapply (IH1 … HU1 … Hl … HU12 (L2.ⓛW2) ?) -IH1 -HU1 -Hl -HU12 [1,2: /2 by fqup_fpbg, lpr_pair/ ] -HL12 -HW2
-    /4 width=6 by da_bind, lsubd_da_trans, lsubd_abbr/
-  | #b #V #V2 #W #W2 #U1 #U2 #HV1 #HV2 #HW2 #HU12 #H1 #H2 destruct -IH2 -V -W0 -T0 -l0 -HV1 -HVW1
-    elim (snv_inv_bind … HT1) -HT1 #_
-    lapply (da_inv_bind … Hl) -Hl
-    /5 width=9 by da_bind, da_flat, fqup_fpbg, lpr_pair/
-  ]
-| #W1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
-  elim (snv_inv_cast … H1) -H1 #U1 #l0 #HW1 #HT1 #Hl0 #HTU1 #HUW1
-  lapply (da_inv_flat … H2) -H2 #Hl
-  elim (cpr_inv_cast1 … H3) -H3
-  [ * #W2 #T2 #HW12 #HT12 #H destruct /4 width=7 by da_flat, fqup_fpbg/
-  | /3 width=7 by fqup_fpbg/
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lpx.etc
deleted file mode 100644 (file)
index 0839b45..0000000
+++ /dev/null
@@ -1,135 +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/dynamic/snv_lift.ma".
-include "basic_2/dynamic/snv_cpcs.ma".
-include "basic_2/dynamic/lsubsv_snv.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties on context-free parallel reduction for local environments *****)
-
-fact snv_cpx_lpx_aux: ∀h,g,G0,L0,T0.
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                      ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_snv_cpx_lpx h g G1 L1 T1.
-#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
-[ #k #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #_ destruct -IH3 -IH2 -IH1 -H1
-  elim (cpx_inv_sort1 … H2) -H2 // * //
-| #i #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2
-  elim (snv_inv_lref … H1) -H1 #I #K1 #V1 #HLK1 #HV1
-  elim (lpx_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
-  lapply (fqup_lref … G1 … HLK1) #HKL
-  elim (cpx_inv_lref1 … H2) -H2
-  [ #H destruct -HLK1 /4 width=10 by fqup_fpbg, snv_lref/
-  | * #I0 #K0 #V0 #W0 #H #HVW0 #W0 -HV12
-    lapply (ldrop_mono … H … HLK1) -HLK1 -H #H destruct
-    lapply (ldrop_fwd_drop2 … HLK2) -HLK2 /4 width=8 by fqup_fpbg, snv_lift/
-  ]
-| #p #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2 -IH1
-  elim (snv_inv_gref … H1)
-| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2
-  elim (snv_inv_bind … H1) -H1 #HV1 #HT1
-  elim (cpx_inv_bind1 … H2) -H2 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct /4 width=8 by fqup_fpbg, snv_bind, lpx_pair/
-  | #T2 #HT12 #HXT2 #H1 #H2 destruct -HV1
-    /4 width=10 by fqup_fpbg, snv_inv_lift, lpx_pair, ldrop_drop/
-  ]
-| #V1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct
-  elim (snv_inv_appl … H1) -H1 #a #W10 #W1 #U1 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HTU1
-  elim (cpx_inv_appl1 … H2) -H2 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    lapply (IH1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2
-    lapply (IH1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ #HT2
-(*    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #H2l0
-    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HVW1 … HV12 … HL12) -Hl0 -HVW1 -HV12 /2 width=1 by fqup_fpbg/ -HV1 #W2 #HVW2 #HW12
-    elim (cpds_cpr_lpr_aux … IH2 IH3 … HTU1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -HT12 -HTU1 #X #HTU2 #H
-    elim (cprs_inv_abst1 … H) -H #W20 #U2 #HW120 #_ #H destruct
-    lapply (lpr_cprs_conf … HL12 … HW10) -L1 #HW10
-    lapply (cpcs_cprs_strap1 … HW10 … HW120) -W1 #HW120
-    lapply (cpcs_canc_sn … HW12 HW120) -W10 #HW20
-    elim (cpcs_inv_cprs … HW20) -HW20 #W0 #HW20 #HW200
-    lapply (cpds_cprs_trans … (ⓛ{a}W0.U2) HTU2 ?)
-    /2 width=7 by snv_appl, cprs_bind/ *)
-  | #b #V2 #W20 #W2 #T20 #T2 #HV12 #HW202 #HT202 #H1 #H2 destruct
-    elim (snv_inv_bind … HT1) -HT1 #HW20 #HT20
-    elim (cpds_inv_abst1 … HTU1) -HTU1 #W30 #T30 #HW230 #_ #H destruct -T30
-    lapply (cprs_div … HW10 … HW230) -W30 #HW120
-    lapply (snv_sta_aux … IH1 … Hl0 … HVW1) /2 width=1 by fqup_fpbg/ #HW10
-    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #HlW10
-    elim (snv_fwd_da … HW20) #l #Hl
-    lapply (da_cpcs_aux … IH1 IH2 … HlW10 … Hl … HW120) // -HlW10
-    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
-(*    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HlV2
-    lapply (IH2 … Hl … HW202 … HL12) /2 width=1 by fqup_fpbg/ #HlW2
-    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HVW1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #W3 #HV2W3 #HW103
-    lapply (da_sta_conf … HV2W3 … HlV2) <minus_plus_m_m #HlW3
-    lapply (cpcs_cpr_strap1 … HW120 … HW202) -HW120 #HW102
-    lapply (lpr_cpcs_conf … HL12 … HW102) -HW102 #HW102
-    lapply (cpcs_canc_sn … HW103 … HW102) -W10 #HW32
-    lapply (IH1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ -HV1 #HV2
-    lapply (IH1 … HW202 … HL12) /2 width=1 by fqup_fpbg/ -HW20 #HW2
-    lapply (IH1 … HT20 … HT202 … (L2.ⓛW2) ?) /2 width=1 by fqup_fpbg, lpr_pair/ -HT20 #HT2
-    lapply (snv_sta_aux … IH4 … HlV2 … HV2W3)
-    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/ #HW3
-    lapply (lsubsv_snv_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /3 width=3 by snv_bind, snv_cast/
-    @(lsubsv_abbr … l) /3 width=7 by fqup_fpbg/ #W #W0 #l0 #Hl0 #HV2W #HW20
-    lapply (lstas_sta_conf_pos … HV2W3 … HV2W) -HV2W #HW3W
-    @(lstas_cpcs_lpr_aux … IH1 IH2 IH3 … HlW3 … HW3W … HlW2 … HW20 … HW32) //
-    [ /3 width=9 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_sta_fpbs/
-    | /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/
-    ] *)
-  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HV02 #HW02 #HT02 #H1 #H2 destruct
-    elim (snv_inv_bind … HT1) -HT1 #HW0 #HT0
-    elim (cpds_inv_abbr_abst … HTU1) -HTU1 #X #HTU0 #HX #H destruct
-    elim (lift_inv_bind1 … HX) -HX #W3 #U3 #HW13 #_ #H destruct
-(*    lapply (lpr_cpr_conf … HL12 … HW10) -HW10 #HW10 
-    elim (cpds_cpr_lpr_aux … IH2 IH3 … HTU0 … HT02 (L2.ⓓW2)) /2 width=1 by fqup_fpbg, lpr_pair/ -HTU0 #X #HTU2 #H
-    elim (cprs_inv_abst1 … H) -H #W #U2 #HW1 #_ #H destruct -U3
-    elim (sta_cpr_lpr_aux … IH3 … HVW1 … HV10 … HL12) /2 width=2 by fqup_fpbg/ -IH3 -HVW1 #X #H1 #H2
-    lapply (cpcs_canc_sn … H2 HW10) -W10 #H2
-    elim (lift_total X 0 1) #W20 #H3
-    lapply (sta_lift … H1 (L2.ⓓW2) … HV02 … H3) /2 width=2 by ldrop_drop/ -H1 #HVW20
-    lapply (cpcs_lift … (L2.ⓓW2) … H3 … HW13 H2) /2 width=2 by ldrop_drop/ -HW13 -H3 -H2 #HW320
-    lapply (cpcs_cprs_strap1 … HW320 … HW1) -W3 #HW20
-    elim (cpcs_inv_cprs … HW20) -HW20 #W3 #HW203 #HW3
-    lapply (cpds_cprs_trans … (ⓛ{a}W3.U2) HTU2 ?) /2 width=1 by cprs_bind/ -HW3 -HTU2 #HTU2
-    lapply (IH2 … Hl0 … HV10 … HL12) /2 width=1 by fqup_fpbg/ -IH2 -Hl0 #Hl0
-    lapply (da_lift … Hl0 (L2.ⓓW2) … HV02) /2 width=2 by ldrop_drop/ -Hl0 #Hl0
-    lapply (IH1 … HW02 … HL12) /2 width=1 by fqup_fpbg/ -HW0 #HW2
-    lapply (IH1 … HV10 … HL12) /2 width=1 by fqup_fpbg/ -HV1 -HV10 #HV0
-    lapply (IH1 … HT02 (L2.ⓓW2) ?) /2 width=1 by fqup_fpbg, lpr_pair/ -L1 #HT2
-    lapply (snv_lift … HV0 (L2.ⓓW2) … HV02) /3 width=7 by snv_bind, snv_appl, ldrop_drop/ *)
-  ]
-| #W1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct
-  elim (snv_inv_cast … H1) -H1 #U1 #l0 #HW1 #HT1 #Hl0 #HTU1 #HUW1
-  elim (cpx_inv_cast1 … H2) -H2
-  [ * #W2 #T2 #HW12 #HT12 #H destruct
-(*    lapply (cpcs_cprs_strap1 … HUW1 W2 ?) /2 width=1 by cpr_cprs/ -HUW1 #H1
-*)    lapply (IH1 … HW12 … HL12) /2 width=1 by fqup_fpbg/ -HW1 -HW12 #HW2
-    lapply (IH1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -IH1 #HT2
-(*    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HTU1 … HT12 … HL12) /2 width=2 by fqup_fpbg/ -IH3 -HTU1 #U2 #HTU2 #HU12
-    lapply (IH2 … Hl0 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -IH2 -HT1 -HT12 -Hl0 #Hl0
-    /4 width=7 by snv_cast, lpr_cpcs_conf, cpcs_canc_sn/ *)
-  | #H -IH3 -IH2 -HW1 -HTU1 -HUW1
-    lapply (IH1 … H … HL12) -IH1 -H -HL12 /2 width=1 by fqup_fpbg/
-  | #H -IH3 -IH2 -HTU1 -HUW1
-    lapply (IH1 … H … HL12) -IH1 -H -HL12 /2 width=1 by fqup_fpbg/
-  ]
-]
-[4: @snv_cast //
-qed-.
-snv_lstas, snv_cpr_lpr
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lstas_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snv/snv_lstas_lpr.etc
deleted file mode 100644 (file)
index 3e1ed02..0000000
+++ /dev/null
@@ -1,150 +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/computation/cpds_cpds.ma".
-include "basic_2/dynamic/snv_aaa.ma".
-include "basic_2/dynamic/snv_cpcs.ma".
-include "basic_2/dynamic/lsubsv_lstas.ma".
-
-(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
-
-(* Properties on sn parallel reduction for local environments ***************)
-
-fact lstas_cpr_lpr_aux: ∀h,g,G0,L0,T0.
-                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
-                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
-                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
-                        ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_lstas_cpr_lpr h g G1 L1 T1.
-#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
-[ #k #_ #_ #_ #_ #l1 #l2 #_ #_ #X2 #H2 #X3 #H3 #L2 #_ -IH3 -IH2 -IH1
-  >(lstas_inv_sort1 … H2) -X2
-  >(cpr_inv_sort1 … H3) -X3 /2 width=3 by ex2_intro/
-| #i #HG0 #HL0 #HT0 #H1 #l1 #l2 @(nat_ind_plus … l2) -l2 [ #_ | #l2 #_ #Hl21 ] #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3
-  [ lapply (lstas_inv_O … H2) -H2 #H destruct -IH1 -H1 -l1 /4 width=5 by lpr_cpcs_conf, cpr_cpcs_dx, ex2_intro/ ]
-  elim (snv_inv_lref … H1) -H1 #I0 #K0 #X0 #HK0 #HX0
-  elim (da_inv_lref … Hl1) -Hl1 * #K1 [ #V1 | #W1 #l0 ] #HLK1 [ #HVl1 | #HWl1 #H destruct ]
-  lapply (ldrop_mono … HK0 … HLK1) -HK0 #H destruct
-  elim (lstas_inv_lref1 … H2) -H2 * #K0 #V0 #W0 [2,4: #X0 ] #HK0 [1,2: #_ -X0 ] #HVW0 #HX2
-  lapply (ldrop_mono … HK0 … HLK1) -HK0 #H destruct
-  [ lapply (le_plus_to_le_r … Hl21) -Hl21 #Hl21 ]
-  lapply (fqup_lref … G1 … HLK1) #HKV1
-  elim (lpr_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
-  elim (lpr_inv_pair1 … H) -H #K2 [ #W2 | #V2 ] #HK12 [ #HW12 | #HV12 ] #H destruct
-  lapply (ldrop_fwd_drop2 … HLK2) #H2
-  elim (cpr_inv_lref1 … H3) -H3
-  [1,3: #H destruct -HLK1
-  |2,4: * #K0 #V0 #X0 #H #HVX0 #HX0
-        lapply (ldrop_mono … H … HLK1) -H -HLK1 #H destruct
-  ]
-  [ lapply (IH2 … HWl1 … HW12 … HK12) /2 width=1 by fqup_fpbg/ -IH2 #H
-    elim (da_inv_sta … H) -H
-    elim (IH1 … HWl1 … HVW0 … HW12 … HK12) -IH1 -HVW0 /2 width=1 by fqup_fpbg/ #V2 #HWV2 #HV2
-    elim (lift_total V2 0 (i+1))
-    /3 width=12 by cpcs_lift, lstas_ldec, ex2_intro/
-  | elim (IH1 … HVl1 … HVW0 … HV12 … HK12) -IH1 -HVl1 -HVW0 -HV12 -HK12 -IH2 /2 width=1 by fqup_fpbg/ #W2 #HVW2 #HW02
-    elim (lift_total W2 0 (i+1))
-    /4 width=12 by cpcs_lift, lstas_ldef, ex2_intro/
-  | elim (IH1 … HVl1 … HVW0 … HVX0 … HK12) -IH1 -HVl1 -HVW0 -HVX0 -HK12 -IH2 -V2 /2 width=1 by fqup_fpbg/ -l1 #W2 #HXW2 #HW02
-    elim (lift_total W2 0 (i+1))
-    /3 width=12 by cpcs_lift, lstas_lift, ex2_intro/
-  ]
-| #p #_ #_ #HT0 #H1 destruct -IH3 -IH2 -IH1
-  elim (snv_inv_gref … H1)
-| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 #Hl21 #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3 -IH2
-  elim (snv_inv_bind … H1) -H1 #_ #HT1
-  lapply (da_inv_bind … Hl1) -Hl1 #Hl1
-  elim (lstas_inv_bind1 … H2) -H2 #U1 #HTU1 #H destruct
-  elim (cpr_inv_bind1 … H3) -H3 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct
-    elim (IH1 … Hl1 … HTU1 … HT12 (L2.ⓑ{I}V2)) -IH1 -Hl1 -HTU1 -HT12 /2 width=1 by fqup_fpbg, lpr_pair/ -T1
-    /4 width=5 by cpcs_bind2, lpr_cpr_conf, lstas_bind, ex2_intro/
-  | #T3 #HT13 #HXT3 #H1 #H2 destruct
-    elim (IH1 … Hl1 … HTU1 … HT13 (L2.ⓓV1)) -IH1 -Hl1 -HTU1 -HT13 /2 width=1 by fqup_fpbg, lpr_pair/ -T1 -HL12 #U3 #HTU3 #HU13
-    elim (lstas_inv_lift1 … HTU3 L2 … HXT3) -T3
-    /5 width=8 by cpcs_cpr_strap1, cpcs_bind1, cpr_zeta, ldrop_drop, ex2_intro/
-  ]
-| #V1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 #Hl21 #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct
-  elim (snv_inv_appl … H1) -H1 #a #W1 #W10 #U10 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HTU10
-  lapply (da_inv_flat … Hl1) -Hl1 #Hl1
-  elim (lstas_inv_appl1 … H2) -H2 #U1 #HTU1 #H destruct
-  elim (cpr_inv_appl1 … H3) -H3 *
-  [ #V2 #T2 #HV12 #HT12 #H destruct -a -l0 -W1 -W10 -U10 -HV1 -IH3 -IH2
-    elim (IH1 … Hl1 … HTU1 … HT12 … HL12) -IH1 -Hl1 -HTU1
-    /4 width=5 by fqup_fpbg, cpcs_flat, lpr_cpr_conf, lstas_appl, ex2_intro/
-  | #b #V2 #W2 #W3 #T2 #T3 #HV12 #HW23 #HT23 #H1 #H2 destruct
-    elim (snv_inv_bind … HT1) -HT1 #HW2 #HT2
-    lapply (da_inv_bind … Hl1) -Hl1 #Hl1
-    elim (lstas_inv_bind1 … HTU1) -HTU1 #U2 #HTU2 #H destruct
-    elim (cpds_inv_abst1 … HTU10) -HTU10 #W0 #U0 #HW20 #_ #H destruct
-    lapply (cprs_div … HW10 … HW20) -W0 #HW12
-    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #H
-    elim (snv_fwd_da … HW2) #l #Hl
-    lapply (snv_lstas_aux … IH3 … HV1 … 1 … Hl0 W1 ?) /2 width=1 by fqup_fpbg, sta_lstas/ #HW1
-    lapply (da_cpcs_aux … IH3 IH2 … H … Hl … HW12) // -H
-    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
-    lapply (snv_cpr_lpr_aux … IH3 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2
-    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2l
-    elim (IH1 … 1 … Hl0 … W1 … HV12 … HL12) /2 width=1 by fqup_fpbg, sta_lstas/ -HVW1 #W4 #H #HW14
-    lapply (lstas_inv_SO … H) #HV2W4
-    lapply (da_sta_conf … HV2W4 … HV2l) <minus_plus_m_m #HW4l
-    lapply (snv_lstas_aux … IH3 … HV2 … HV2l … H) -H /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/ #HW4
-    lapply (snv_cpr_lpr_aux … IH3 … HW23 … HL12) /2 width=1 by fqup_fpbg/ #HW3
-    lapply (IH2 … Hl … HW23 … HL12) /2 width=1 by fqup_fpbg/ #HW3l
-    elim (IH1 … Hl1 … HTU2 … HT23 (L2.ⓛW3)) -HTU2 /2 width=1 by fqup_fpbg, lpr_pair/ #U3 #HTU3 #HU23
-    lapply (cpcs_cpr_strap1 … HW12 … HW23) #H
-    lapply (lpr_cpcs_conf … HL12 … H) -H #H
-    lapply (cpcs_canc_sn … HW14 H) -H #HW43
-    elim (lsubsv_lstas_trans … g … HTU3 … Hl21 … (L2.ⓓⓝW3.V2)) -HTU3
-    [ #U4 #HT3U4 #HU43 -HW12 -HW3 -HW3l -W4 -IH3 -IH2
-      @(ex2_intro … (ⓓ{b}ⓝW3.V2.U4)) /2 width=1 by lstas_bind/ -HT3U4
-      @(cpcs_canc_dx … (ⓓ{b}ⓝW3.V2.U3)) /2 width=1 by cpcs_bind_dx/ -HU43
-      @(cpcs_cpr_strap1 … (ⓐV2.ⓛ{b}W3.U3)) /2 width=1 by cpr_beta/
-      /4 width=3 by cpcs_flat, cpcs_bind2, lpr_cpr_conf/
-    | -U3
-      @(lsubsv_abbr … l) /3 width=7 by fqup_fpbg/
-      #W #W0 #l0 #Hl0 #HV2W #HW30
-      lapply (lstas_sta_conf_pos … HV2W4 … HV2W) -HV2W #HW4W
-      @(lstas_cpcs_lpr_aux … IH3 IH2 IH1 … Hl0 … HW4W … Hl0 … HW30 … HW43) //
-      [ /3 width=9 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_sta_fpbs/
-      | /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/
-      ]
-    | -IH3 -IH1 /3 width=9 by fqup_fpbg, lpr_pair/
-    ]
-  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HV02 #HW02 #HT02 #H1 #H2 destruct -a -l0 -W1 -W10 -HV1 -IH3 -IH2
-    elim (snv_inv_bind … HT1) -HT1 #_ #HT0
-    lapply (da_inv_bind … Hl1) -Hl1 #Hl1
-    elim (lstas_inv_bind1 … HTU1) -HTU1 #U0 #HTU0 #H destruct
-    elim (IH1 … Hl1 … HTU0 … HT02 (L2.ⓓW2)) -IH1 -Hl1 -HTU0 /2 width=1 by fqup_fpbg, lpr_pair/ -T0 #U2 #HTU2 #HU02
-    lapply (lpr_cpr_conf … HL12 … HV10) -HV10 #HV10
-    lapply (lpr_cpr_conf … HL12 … HW02) -L1 #HW02
-    lapply (cpcs_bind2 b … HW02 … HU02) -HW02 -HU02 #HU02
-    lapply (cpcs_flat … HV10 … HU02 Appl) -HV10 -HU02 #HU02
-    lapply (cpcs_cpr_strap1 … HU02 (ⓓ{b}W2.ⓐV2.U2) ?)
-    /4 width=3 by lstas_appl, lstas_bind, cpr_theta, ex2_intro/
-  ]
-| #W1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 @(nat_ind_plus … l2) -l2 [ #_ | #l2 #_ #Hl21 ] #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3 -IH2
-  [ lapply (lstas_inv_O … H2) -H2 #H destruct -IH1 -H1 -l1 /4 width=5 by lpr_cpcs_conf, cpr_cpcs_dx, ex2_intro/ ]
-  elim (snv_inv_cast … H1) -H1 #U1 #l #_ #HT1 #_ #_ #_ -U1 -l
-  lapply (da_inv_flat … Hl1) -Hl1 #Hl1
-  lapply (lstas_inv_cast1 … H2) -H2 #HTU1
-  elim (cpr_inv_cast1 … H3) -H3
-  [ * #U2 #T2 #_ #HT12 #H destruct
-    elim (IH1 … Hl1 … HTU1 … HT12 … HL12) -IH1 -Hl1 -HTU1 -HL12
-    /3 width=3 by fqup_fpbg, lstas_cast, ex2_intro/
-  | #HT1X3
-    elim (IH1 … Hl1 … HTU1 … HT1X3 … HL12) -IH1 -Hl1 -HTU1 -HL12
-    /2 width=3 by fqup_fpbg, ex2_intro/
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/snv_preserve.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/snv_preserve.etc
deleted file mode 100644 (file)
index 8da0347..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-lemma da_cpcs: ∀h,g,G,L,T1. ⦃G, L⦄ ⊢ T1 ¡[h, g] →
-               ∀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 #G #L #T1 #HT1 #T2 #HT2 #l1 #Hl1 #l2 #Hl2 #H
-elim (cpcs_inv_cprs … H) -H /3 width=12 by da_cprs_lpr, da_mono/
-qed-.
-
-lemma sta_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                   ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l+1 →
-                   ∀U1. ⦃G, L1⦄ ⊢ T1 •[h] U1 →
-                   ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                   ∃∃U2. ⦃G, L2⦄ ⊢ T2 •[h] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
-#h #g #G #L1 #T1 #HT1 #l #Hl #U1 #HTU1 #T2 #HT12 #L2 #HL12
-elim (lstas_cpr_lpr  … 1 … Hl U1 … HT12 … HL12) -Hl -HT12 -HL12
-/3 width=3 by lstas_inv_SO, sta_lstas, ex2_intro/
-qed-.
-
-lemma snv_sta: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ T ¡[h, g] →
-               ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 →
-               ∀U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ U ¡[h, g].
-/3 width=7 by lstas_inv_SO, sta_lstas, snv_lstas/ qed-.
-
-lemma lstas_cpds: ∀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, l2] U1 → ∀T2. ⦃G, L⦄ ⊢ T1 •*➡*[h, g] T2 →
-                  ∃∃U2,l. l ≤ l2 & ⦃G, L⦄ ⊢ T2 •*[h, l] U2 & ⦃G, L⦄ ⊢ U1 •*⬌*[h, g] U2.
-#h #g #G #L #T1 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 * #T #l0 #l #Hl0 #H #HT1T #HTT2
-lapply (da_mono … H … Hl1) -H #H destruct
-lapply (lstas_da_conf … HTU1 … Hl1) #Hl12
-elim (le_or_ge l2 l) #Hl2
-[ lapply (lstas_conf_le … HTU1 … HT1T) -HT1T //
-  /5 width=11 by cpds_cpes_dx, monotonic_le_minus_l, ex3_2_intro, ex4_3_intro/
-| lapply (lstas_da_conf … HT1T … Hl1) #Hl1l
-  lapply (lstas_conf_le … HT1T … HTU1) -HTU1 // #HTU1
-  elim (lstas_cprs_lpr … Hl1l … HTU1 … HTT2 L) -Hl1l -HTU1 -HTT2
-  /3 width=7 by snv_lstas, cpcs_cpes, monotonic_le_minus_l, ex3_2_intro/
-]
-qed-.
-
-lemma cpds_cpr_lpr: ∀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.
-#h #g #G #L1 #T1 #HT1 #U1 * #W1 #l1 #l2 #Hl21 #Hl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
-elim (lstas_cpr_lpr … Hl1 … HTW1 … HT12 … HL12) // #W2 #HTW2 #HW12
-lapply (da_cpr_lpr … Hl1 … HT12 … HL12) // -T1
-lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
-lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
-elim (cpcs_inv_cprs … H) -H /3 width=7 by ex4_3_intro, ex2_intro/
-qed-.
-
-(* Note: missing da_scpds_lpr, da_scpes *)
-
-lemma scpds_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                     ∀U1,l. ⦃G, L1⦄ ⊢ T1 •*➡*[h, g, l] U1 →
-                     ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                     ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*➡*[h, g, l] U2 & ⦃G, L2⦄ ⊢ U1 ➡* U2.
-#h #g #G #L1 #T1 #HT1 #U1 #l2 * #W1 #l1 #Hl21 #HTl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
-elim (lstas_cpr_lpr … HTl1 … HTW1 … HT12 … HL12) // #W2 #HTW2 #HW12
-lapply (da_cpr_lpr … HTl1 … HT12 … HL12) // -T1
-lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
-lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
-elim (cpcs_inv_cprs … H) -H /3 width=6 by ex4_2_intro, ex2_intro/
-qed-.
-
-lemma scpes_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
-                     ∀T2. ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
-                     ∀l1,l2. ⦃G, L1⦄ ⊢ T1 •*⬌*[h, g, l1, l2] T2 →
-                     ∀U1. ⦃G, L1⦄ ⊢ T1 ➡ U1 → ∀U2. ⦃G, L1⦄ ⊢ T2 ➡ U2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
-                     ⦃G, L2⦄ ⊢ U1 •*⬌*[h, g, l1, l2] U2.
-#h #g #G #L1 #T1 #HT1 #T2 #HT2 #l1 #l2 * #T0 #HT10 #HT20 #U1 #HTU1 #U2 #HTU2 #L2 #HL12
-elim (scpds_cpr_lpr … HT10 … HTU1 … HL12) -HT10 -HTU1 // #X1 #HUX1 #H1
-elim (scpds_cpr_lpr … HT20 … HTU2 … HL12) -HT20 -HTU2 // #X2 #HUX2 #H2
-elim (cprs_conf … H1 … H2) -T0 /3 width=5 by scpds_div, scpds_cprs_trans/
-qed-.
-
-(* Note: missing lstas_scpds, scpes_le *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_aaa.etc
deleted file mode 100644 (file)
index dccb10f..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/static/da_sta.ma".
-include "basic_2/static/sta_aaa.ma".
-
-(* DEGREE ASSIGNMENT FOR TERMS **********************************************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-lemma aaa_da: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ∃l. ⦃G, L⦄ ⊢ T ▪[h, g] l.
-#h #g #G #L #T #A #H elim (aaa_sta h … H) -A /2 width=2 by sta_da/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/da_sta.etc
deleted file mode 100644 (file)
index 4f45a81..0000000
+++ /dev/null
@@ -1,86 +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/static/sta.ma".
-include "basic_2/static/da_da.ma".
-
-(* Properties on static type assignment for terms ***************************)
-
-lemma da_sta_conf: ∀h,g,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
-                   ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l → ⦃G, L⦄ ⊢ U ▪[h, g] l-1.
-#h #g #G #L #T #U #H elim H -G -L -T -U
-[ #G #L #k #l #H
-  lapply (da_inv_sort … H) -H /3 width=1 by da_sort, deg_next/
-| #G #L #K #V #U #W #i #HLK #_ #HWU #IHVW #l #H
-  elim (da_inv_lref … H) -H * #K0 #V0 [| #l0] #HLK0 #HV0
-  lapply (drop_mono … HLK0 … HLK) -HLK0 #H destruct
-  lapply (drop_fwd_drop2 … HLK) -HLK /3 width=8 by da_lift/
-| #G #L #K #W #V #U #i #HLK #_ #HWU #IHWV #l #H
-  elim (da_inv_lref … H) -H * #K0 #V0 [| #l0] #HLK0 #HV0 [| #H0 ]
-  lapply (drop_mono … HLK0 … HLK) -HLK0 #H destruct
-  lapply (drop_fwd_drop2 … HLK) -HLK /3 width=8 by da_lift/
-| #a #I #G #L #V #T #U #_ #IHTU #l #H
-  lapply (da_inv_bind … H) -H /3 width=1 by da_bind/
-| #G #L #V #T #U #_ #IHTU #l #H
-  lapply (da_inv_flat … H) -H /3 width=1 by da_flat/
-| #G #L #W #T #U #_ #IHTU #l #H
-  lapply (da_inv_flat … H) -H /2 width=1 by/
-]
-qed-.
-
-lemma sta_da: ∀h,g,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
-              ∃l. ⦃G, L⦄ ⊢ T ▪[h, g] l.
-#h #g #G #L #T #U #H elim H -G -L -T -U
-[ #G #L #k elim (deg_total h g k) /3 width=2 by da_sort, ex_intro/
-| #G #L #K #V #W #W0 #i #HLK #_ #_ * /3 width=5 by da_ldef, ex_intro/
-| #G #L #K #W #V #W0 #i #HLK #_ #_ * /3 width=5 by da_ldec, ex_intro/
-| #a #I #G #L #V #T #U #_ * /3 width=2 by da_bind, ex_intro/
-| #G #L #V #T #U #_ * /3 width=2 by da_flat, ex_intro/
-| #G #L #W #T #U #_ * /3 width=2 by da_flat, ex_intro/
-]
-qed-.
-
-lemma sta_da_ge: ∀h,G,L,T,U,l0. ⦃G, L⦄ ⊢ T •[h] U →
-                 ∃∃g,l. ⦃G, L⦄ ⊢ T ▪[h, g] l & l0 ≤ l.
-#h #G #L #T #U #l0 #H elim H -G -L -T -U
-[ /3 width=4 by da_sort, ex2_2_intro/
-| #G #L #K #V #W #W0 #i #HLK #_ #_ * /3 width=5 by da_ldef, ex2_2_intro/
-| #G #L #K #W #V #W0 #i #HLK #_ #_ * /4 width=5 by da_ldec, lt_to_le, le_S_S, ex2_2_intro/
-| #a #I #G #L #V #T #U #_ * /3 width=4 by da_bind, ex2_2_intro/
-| #G #L #V #T #U #_ * /3 width=4 by da_flat, ex2_2_intro/
-| #G #L #W #T #U #_ * /3 width=4 by da_flat, ex2_2_intro/
-]
-qed-.
-
-(* Inversion lrmmas on static type assignment for terms *********************)
-
-lemma da_inv_sta: ∀h,g,G,L,T,l. ⦃G, L⦄ ⊢ T ▪[h, g] l →
-                  ∃U. ⦃G, L⦄ ⊢ T •[h] U.
-#h #g #G #L #T #l #H elim H -G -L -T -l
-[ /2 width=2/
-| #G #L #K #V #i #l #HLK #_ * #W #HVW
-  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldef, ex_intro/
-| #G #L #K #W #i #l #HLK #_ * #V #HWV
-  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldec, ex_intro/
-| #a #I #G #L #V #T #l #_ * /3 width=2 by sta_bind, ex_intro/
-| * #G #L #V #T #l #_ * /3 width=2 by sta_appl, sta_cast, ex_intro/
-]
-qed-.
-
-lemma sta_inv_refl_pos: ∀h,g,G,L,T,l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 → ⦃G, L⦄ ⊢ T •[h] T → ⊥.
-#h #g #G #L #T #l #H1T #HTT
-lapply (da_sta_conf … HTT … H1T) -HTT <minus_plus_m_m #H2T
-lapply (da_mono … H2T … H1T) -h -G -L -T #H
-elim (plus_xySz_x_false 0 l 0) //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas.etc
deleted file mode 100644 (file)
index feed03e..0000000
+++ /dev/null
@@ -1,133 +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/statictypestar_6.ma".
-include "basic_2/static/sta.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-definition lstas: ∀h. genv → lenv → nat → relation term ≝
-                  λh,G,L. lstar … (sta h G L).
-
-interpretation "nat-iterated static type assignment (term)"
-   'StaticTypeStar h G L l T U = (lstas h G L l T U).
-
-(* Basic eliminators ********************************************************)
-
-lemma lstas_ind_sn: ∀h,G,L,U2. ∀R:relation2 nat term.
-                    R 0 U2 → (
-                       ∀l,T,U1. ⦃G, L⦄ ⊢ T •[h] U1 → ⦃G, L⦄ ⊢ U1 •* [h, l] U2 →
-                       R l U1 → R (l+1) T
-                    ) →
-                    ∀l,T. ⦃G, L⦄ ⊢ T •*[h, l] U2 → R l T.
-/3 width=5 by lstar_ind_l/ qed-.
-
-lemma lstas_ind_dx: ∀h,G,L,T. ∀R:relation2 nat term.
-                    R 0 T → (
-                       ∀l,U1,U2. ⦃G, L⦄ ⊢ T •* [h, l] U1 →  ⦃G, L⦄ ⊢ U1 •[h] U2 →
-                       R l U1 → R (l+1) U2
-                    ) →
-                    ∀l,U. ⦃G, L⦄ ⊢ T •*[h, l] U → R l U.
-/3 width=5 by lstar_ind_r/ qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma lstas_inv_O: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •*[h, 0] U → T = U.
-/2 width=4 by lstar_inv_O/ qed-.
-
-lemma lstas_inv_SO: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •*[h, 1] U → ⦃G, L⦄ ⊢ T •[h] U.
-/2 width=1 by lstar_inv_step/ qed-.
-
-lemma lstas_inv_step_sn: ∀h,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
-                         ∃∃T. ⦃G, L⦄ ⊢ T1 •[h] T & ⦃G, L⦄ ⊢ T •*[h, l] T2.
-/2 width=3 by lstar_inv_S/ qed-.
-
-lemma lstas_inv_step_dx: ∀h,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
-                         ∃∃T. ⦃G, L⦄ ⊢ T1 •*[h, l] T & ⦃G, L⦄ ⊢ T •[h] T2.
-/2 width=3 by lstar_inv_S_dx/ qed-.
-
-lemma lstas_inv_sort1: ∀h,G,L,X,k,l. ⦃G, L⦄ ⊢ ⋆k •*[h, l] X → X = ⋆((next h)^l k).
-#h #G #L #X #k #l #H @(lstas_ind_dx … H) -X -l //
-#l #X #X0 #_ #H #IHX destruct
-lapply (sta_inv_sort1 … H) -H #H destruct
->iter_SO //
-qed-.
-
-lemma lstas_inv_gref1: ∀h,G,L,X,p,l. ⦃G, L⦄ ⊢ §p •*[h, l+1] X → ⊥.
-#h #G #L #X #p #l #H elim (lstas_inv_step_sn … H) -H
-#U #H #HUX elim (sta_inv_gref1 … H)
-qed-.
-
-lemma lstas_inv_bind1: ∀h,a,I,G,L,V,T,X,l. ⦃G, L⦄ ⊢ ⓑ{a,I}V.T •*[h, l] X →
-                       ∃∃U. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U & X = ⓑ{a,I}V.U.
-#h #a #I #G #L #V #T #X #l #H @(lstas_ind_dx … H) -X -l /2 width=3 by ex2_intro/
-#l #X #X0 #_ #HX0 * #U #HTU #H destruct
-elim (sta_inv_bind1 … HX0) -HX0 #U0 #HU0 #H destruct /3 width=3 by lstar_dx, ex2_intro/
-qed-.
-
-lemma lstas_inv_appl1: ∀h,G,L,V,T,X,l. ⦃G, L⦄ ⊢ ⓐV.T •*[h, l] X →
-                       ∃∃U. ⦃G, L⦄ ⊢ T •*[h, l] U & X = ⓐV.U.
-#h #G #L #V #T #X #l #H @(lstas_ind_dx … H) -X -l /2 width=3 by ex2_intro/
-#l #X #X0 #_ #HX0 * #U #HTU #H destruct
-elim (sta_inv_appl1 … HX0) -HX0 #U0 #HU0 #H destruct /3 width=3 by lstar_dx, ex2_intro/
-qed-.
-
-lemma lstas_inv_cast1: ∀h,G,L,W,T,U,l. ⦃G, L⦄ ⊢ ⓝW.T •*[h, l+1] U → ⦃G, L⦄ ⊢ T •*[h, l+1] U.
-#h #G #L #W #T #X #l #H elim (lstas_inv_step_sn … H) -H
-#U #H #HUX lapply (sta_inv_cast1 … H) -H /2 width=3 by lstar_S/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma lstas_refl: ∀h,G,L. reflexive … (lstas h G L 0).
-// qed.
-
-lemma sta_lstas: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ T •*[h, 1] U.
-/2 width=1 by lstar_step/ qed.
-
-lemma lstas_step_sn: ∀h,G,L,T1,U1,U2,l. ⦃G, L⦄ ⊢ T1 •[h] U1 → ⦃G, L⦄ ⊢ U1 •*[h, l] U2 →
-                     ⦃G, L⦄ ⊢ T1 •*[h, l+1] U2.
-/2 width=3 by lstar_S/ qed.
-
-lemma lstas_step_dx: ∀h,G,L,T1,T2,U2,l. ⦃G, L⦄ ⊢ T1 •*[h, l] T2 → ⦃G, L⦄ ⊢ T2 •[h] U2 →
-                     ⦃G, L⦄ ⊢ T1 •*[h, l+1] U2.
-/2 width=3 by lstar_dx/ qed.
-
-lemma lstas_split: ∀h,G,L. inv_ltransitive … (lstas h G L).
-/2 width=1 by lstar_inv_ltransitive/ qed-.
-
-lemma lstas_sort: ∀h,G,L,l,k. ⦃G, L⦄ ⊢ ⋆k •*[h, l] ⋆((next h)^l k).
-#h #G #L #l @(nat_ind_plus … l) -l //
-#l #IHl #k >iter_SO /2 width=3 by sta_sort, lstas_step_dx/
-qed.
-
-lemma lstas_bind: ∀h,I,G,L,V,T,U,l. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U →
-                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V.T •*[h, l] ⓑ{a,I}V.U.
-#h #I #G #L #V #T #U #l #H @(lstas_ind_dx … H) -U -l /3 width=3 by sta_bind, lstar_O, lstas_step_dx/
-qed.
-
-lemma lstas_appl: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U →
-                  ∀V.⦃G, L⦄ ⊢ ⓐV.T •*[h, l] ⓐV.U.
-#h #G #L #T #U #l #H @(lstas_ind_dx … H) -U -l /3 width=3 by sta_appl, lstar_O, lstas_step_dx/
-qed.
-
-lemma lstas_cast: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l+1] U →
-                  ∀W. ⦃G, L⦄ ⊢ ⓝW.T •*[h, l+1] U.
-#h #G #L #T #U #l #H elim (lstas_inv_step_sn … H) -H /3 width=3 by sta_cast, lstas_step_sn/
-qed.
-
-(* Basic_1: removed theorems 7:
-            sty1_abbr sty1_appl sty1_bind sty1_cast2
-            sty1_correct sty1_lift sty1_trans
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_aaa.etc
deleted file mode 100644 (file)
index 7497f44..0000000
+++ /dev/null
@@ -1,23 +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/static/sta_aaa.ma".
-include "basic_2/unfold/lstas.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-lemma lstas_aaa_conf: ∀h,G,L,l. Conf3 … (aaa G L) (lstas h G L l).
-/3 width=6 by sta_aaa_conf, lstar_Conf3/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_alt.etc
deleted file mode 100644 (file)
index 0ad7b9b..0000000
+++ /dev/null
@@ -1,102 +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/statictypestaralt_6.ma".
-include "basic_2/unfold/lstas_lift.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-(* alternative definition of lstas *)
-inductive lstasa (h): genv → relation4 lenv nat term term ≝
-| lstasa_O   : ∀G,L,T. lstasa h G L 0 T T
-| lstasa_sort: ∀G,L,l,k. lstasa h G L l (⋆k) (⋆((next h)^l k))
-| lstasa_ldef: ∀G,L,K,V,W,U,i,l. ⇩[i] L ≡ K.ⓓV → lstasa h G K (l+1) V W →
-               ⇧[0, i+1] W ≡ U → lstasa h G L (l+1) (#i) U
-| lstasa_ldec: ∀G,L,K,W,V,V0,U,i,l. ⇩[i] L ≡ K.ⓛW → ⦃G, K⦄ ⊢ W •[h] V0 →
-               lstasa h G K l W V → ⇧[0, i+1] V ≡ U → lstasa h G L (l+1) (#i) U
-| lstasa_bind: ∀a,I,G,L,V,T,U,l. lstasa h G (L.ⓑ{I}V) l T U →
-               lstasa h G L l (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
-| lstasa_appl: ∀G,L,V,T,U,l. lstasa h G L l T U → lstasa h G L l (ⓐV.T) (ⓐV.U)
-| lstasa_cast: ∀G,L,W,T,U,l. lstasa h G L (l+1) T U → lstasa h G L (l+1) (ⓝW.T) U
-.
-
-interpretation "nat-iterated static type assignment (term) alternative"
-   'StaticTypeStarAlt h G L l T U = (lstasa h G L l T U).
-
-(* Base properties **********************************************************)
-
-lemma sta_lstasa: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ T ••*[h, 1] U.
-#h #G #L #T #U #H elim H -G -L -T -U
-/2 width=8 by lstasa_O, lstasa_sort, lstasa_ldef, lstasa_ldec, lstasa_bind, lstasa_appl, lstasa_cast/
-qed.
-
-lemma lstasa_step_dx: ∀h,G,L,T1,T,l. ⦃G, L⦄ ⊢ T1 ••*[h, l] T →
-                      ∀T2. ⦃G, L⦄ ⊢ T •[h] T2 → ⦃G, L⦄ ⊢ T1 ••*[h, l+1] T2.
-#h #G #L #T1 #T #l #H elim H -G -L -T1 -T -l
-[ /2 width=1 by sta_lstasa/
-| #G #L #l #k #X #H >(sta_inv_sort1 … H) -X >commutative_plus //
-| #G #L #K #V #W #U #i #l #HLK #_ #HWU #IHVW #U2 #HU2
-  lapply (drop_fwd_drop2 … HLK) #H
-  elim (sta_inv_lift1 … HU2 … H … HWU) -H -U /3 width=6 by lstasa_ldef/
-| #G #L #K #W #V #V0 #U #i #l #HLK #HWl0 #_ #HVU #IHWV #U2 #HU2
-  lapply (drop_fwd_drop2 … HLK) #H
-  elim (sta_inv_lift1 … HU2 … H … HVU) -H -U /3 width=8 by lstasa_ldec/
-| #a #I #G #L #V #T1 #U1 #l #_ #IHTU1 #X #H
-  elim (sta_inv_bind1 … H) -H #U #HU1 #H destruct /3 width=1 by lstasa_bind/
-| #G #L #V #T1 #U1 #l #_ #IHTU1 #X #H
-  elim (sta_inv_appl1 … H) -H #U #HU1 #H destruct /3 width=1 by lstasa_appl/
-| /3 width=1 by lstasa_cast/
-]
-qed.
-
-(* Main properties **********************************************************)
-
-theorem lstas_lstasa: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U → ⦃G, L⦄ ⊢ T ••*[h, l] U.
-#h #G #L #T #U #l #H @(lstas_ind_dx … H) -U -l /2 width=3 by lstasa_step_dx, lstasa_O/
-qed.
-
-(* Main inversion lemmas ****************************************************)
-
-theorem lstasa_inv_lstas: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T ••*[h, l] U → ⦃G, L⦄ ⊢ T •*[h, l] U.
-#h #G #L #T #U #l #H elim H -G -L -T -U -l
-/2 width=8 by lstas_inv_SO, lstas_ldec, lstas_ldef, lstas_cast, lstas_appl, lstas_bind/
-qed-.
-
-(* Advanced eliminators *****************************************************)
-
-lemma lstas_ind_alt: ∀h. ∀R:genv→relation4 lenv nat term term.
-                     (∀G,L,T. R G L O T T) →
-                     (∀G,L,l,k. R G L l (⋆k) (⋆((next h)^l k))) → (
-                        ∀G,L,K,V,W,U,i,l.
-                        ⇩[i] L ≡ K.ⓓV → ⦃G, K⦄ ⊢ V •*[h, l+1] W → ⇧[O, i+1] W ≡ U →
-                        R G K (l+1) V W → R G L (l+1) (#i) U
-                     ) → (
-                        ∀G,L,K,W,V,V0,U,i,l.
-                        ⇩[i] L ≡ K.ⓛW → ⦃G, K⦄ ⊢ W •[h] V0 →
-                        ⦃G, K⦄ ⊢ W •*[h, l]V → ⇧[O, i+1] V ≡ U →
-                        R G K l W V → R G L (l+1) (#i) U
-                     ) → (
-                        ∀a,I,G,L,V,T,U,l. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U →
-                        R G (L.ⓑ{I}V) l T U → R G L l (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
-                     ) → (
-                        ∀G,L,V,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U →
-                        R G L l T U → R G L l (ⓐV.T) (ⓐV.U)
-                     ) → (
-                        ∀G,L,W,T,U,l. ⦃G, L⦄⊢ T •*[h, l+1] U →
-                        R G L (l+1) T U → R G L (l+1) (ⓝW.T) U
-                     ) →
-                     ∀G,L,l,T,U. ⦃G, L⦄ ⊢ T •*[h, l] U → R G L l T U.
-#h #R #IH1 #IH2 #IH3 #IH4 #IH5 #IH6 #IH7 #G #L #l #T #U #H
-elim (lstas_lstasa … H) /3 width=10 by lstasa_inv_lstas/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_da.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_da.etc
deleted file mode 100644 (file)
index 8b11d1d..0000000
+++ /dev/null
@@ -1,40 +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/unfold/lstas.ma".
-include "basic_2/static/da_sta.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-(* Properties on degree assignment for terms ********************************)
-
-lemma lstas_da_conf: ∀h,g,G,L,T,U,l1. ⦃G, L⦄ ⊢ T •*[h, l1] U →
-                     ∀l2. ⦃G, L⦄ ⊢ T ▪[h, g] l2 → ⦃G, L⦄ ⊢ U ▪[h, g] l2-l1.
-#h #g #G #L #T #U #l1 #H @(lstas_ind_dx … H) -U -l1 //
-#l1 #U #U0 #_ #HU0 #IHTU #l2 #HT
-<minus_plus /3 width=3 by da_sta_conf/
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma lstas_inv_refl_pos: ∀h,G,L,T,l. ⦃G, L⦄ ⊢ T •*[h, l+1] T → ⊥.
-#h #G #L #T #l #H elim (lstas_inv_step_sn … H)
-#U #HTU #_ elim (sta_da_ge … (l+1) HTU) -U
-#g #l0 #HT #Hl0 lapply (lstas_da_conf … H … HT) -H
-#H0T lapply (da_mono … HT … H0T) -h -G -L -T
-#H elim (discr_x_minus_xy … H) -H
-[ #H destruct /2 width=3 by le_plus_xSy_O_false/
-| -Hl0 <plus_n_Sm #H destruct 
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lift.etc
deleted file mode 100644 (file)
index 947c162..0000000
+++ /dev/null
@@ -1,81 +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/static/sta_lift.ma".
-include "basic_2/unfold/lstas.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-(* Properties on relocation *************************************************)
-
-lemma lstas_lift: ∀h,G,l. l_liftable (llstar … (sta h G) l).
-/3 width=10 by l_liftable_llstar, sta_lift/ qed.
-
-(* Inversion lemmas on relocation *******************************************)
-
-lemma lstas_inv_lift1: ∀h,G,l. l_deliftable_sn (llstar … (sta h G) l).
-/3 width=6 by l_deliftable_sn_llstar, sta_inv_lift1/ qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma lstas_inv_lref1: ∀h,G,L,U,i,l. ⦃G, L⦄ ⊢ #i •*[h, l+1] U →
-                       (∃∃K,V,W. ⇩[i] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •*[h, l+1] W &
-                                 ⇧[0, i+1] W ≡ U
-                       ) ∨
-                       (∃∃K,W,V,V0. ⇩[i] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V0 &
-                                    ⦃G, K⦄ ⊢ W •*[h, l] V & ⇧[0, i+1] V ≡ U
-                        ).
-#h #G #L #U #i #l #H elim (lstas_inv_step_sn … H) -H
-#X #H #HXU elim (sta_inv_lref1 … H) -H
-* #K #V #W #HLK #HVW #HWX
-lapply (drop_fwd_drop2 … HLK) #H0LK
-elim (lstas_inv_lift1 … HXU … H0LK … HWX) -H0LK -X
-/4 width=8 by lstas_step_sn, ex4_4_intro, ex3_3_intro, or_introl, or_intror/
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-lemma lstas_fwd_correct: ∀h,G,L,T1,U1. ⦃G, L⦄ ⊢ T1 •[h] U1 →
-                         ∀T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l] T2 →
-                         ∃U2. ⦃G, L⦄ ⊢ T2 •[h] U2.
-#h #G #L #T1 #U1 #HTU1 #T2 #l #H @(lstas_ind_dx … H) -l -T2 /2 width=3 by ex_intro/ -HTU1
-#l #T #T2 #_ #HT2 #_ -T1 -U1 -l
-elim (sta_fwd_correct … HT2) -T /2 width=2 by ex_intro/
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lstas_total: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
-                   ∀l. ∃U0. ⦃G, L⦄ ⊢ T •*[h, l] U0.
-#h #G #L #T #U #HTU #l @(nat_ind_plus … l) -l /2 width=2 by ex_intro/
-#l * #U0 #HTU0 elim (lstas_fwd_correct … HTU … HTU0) -U
-/3 width=4 by lstas_step_dx, ex_intro/
-qed-.
-
-lemma lstas_ldef: ∀h,G,L,K,V,i. ⇩[i] L ≡ K.ⓓV →
-                  ∀W,l. ⦃G, K⦄ ⊢ V •*[h, l+1] W →
-                  ∀U. ⇧[0, i+1] W ≡ U → ⦃G, L⦄ ⊢ #i •*[h, l+1] U.
-#h #G #L #K #V #i #HLK #W #l #HVW #U #HWU
-lapply (drop_fwd_drop2 … HLK)
-elim (lstas_inv_step_sn … HVW) -HVW #W0
-elim (lift_total W0 0 (i+1)) /3 width=12 by lstas_step_sn, sta_ldef, lstas_lift/
-qed.
-
-lemma lstas_ldec: ∀h,G,L,K,W,i. ⇩[i] L ≡ K.ⓛW → ∀V0. ⦃G, K⦄ ⊢ W •[h] V0 →
-                  ∀V,l. ⦃G, K⦄ ⊢ W •*[h, l] V →
-                  ∀U. ⇧[0, i+1] V ≡ U → ⦃G, L⦄ ⊢ #i •*[h, l+1] U.
-#h #G #L #K #W #i #HLK #V0 #HWV0 #V #l #HWV #U #HVU
-lapply (drop_fwd_drop2 … HLK) #H
-elim (lift_total W 0 (i+1)) /3 width=12 by lstas_step_sn, sta_ldec, lstas_lift/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lstas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/lstas_lstas.etc
deleted file mode 100644 (file)
index 58614e3..0000000
+++ /dev/null
@@ -1,51 +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/static/sta_sta.ma".
-include "basic_2/unfold/lstas_lift.ma".
-
-(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
-
-(* Main properties **********************************************************)
-
-theorem lstas_trans: ∀h,G,L. ltransitive … (lstas h G L).
-/2 width=3 by lstar_ltransitive/ qed-.
-
-theorem lstas_mono: ∀h,G,L,l. singlevalued … (lstas h G L l).
-/3 width=7 by sta_mono, lstar_singlevalued/ qed-.
-
-theorem lstas_conf_le: ∀h,G,L,T,U1,l1. ⦃G, L⦄ ⊢ T •*[h, l1] U1 →
-                       ∀U2,l2. l1 ≤ l2 → ⦃G, L⦄ ⊢ T •*[h, l2] U2 →
-                       ⦃G, L⦄ ⊢ U1 •*[h, l2-l1] U2.
-#h #G #L #T #U1 #l1 #HTU1 #U2 #l2 #Hl12
->(plus_minus_m_m … Hl12) in ⊢ (%→?); -Hl12 >commutative_plus #H
-elim (lstas_split … H) -H #U #HTU
->(lstas_mono … HTU … HTU1) -T //
-qed-.
-
-(* Advanced properties ******************************************************)
-
-lemma lstas_sta_conf_pos: ∀h,G,L,T,U1. ⦃G, L⦄ ⊢ T •[h] U1 →
-                          ∀U2,l. ⦃G, L⦄ ⊢ T •*[h, l+1] U2 → ⦃G, L⦄ ⊢ U1 •*[h, l] U2.
-#h #G #L #T #U1 #HTU1 #U2 #l #HTU2
-lapply (lstas_conf_le … T U1 1 … HTU2) -HTU2 /2 width=1 by sta_lstas/
-qed-.
-
-lemma lstas_strip_pos: ∀h,G,L,T1,U1. ⦃G, L⦄ ⊢ T1 •[h] U1 →
-                       ∀T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
-                       ∃∃U2. ⦃G, L⦄ ⊢ T2 •[h] U2 & ⦃G, L⦄ ⊢ U1 •*[h, l+1] U2.
-#h #G #L #T1 #U1 #HTU1 #T2 #l #HT12
-elim (lstas_fwd_correct … HTU1 … HT12)
-lapply (lstas_sta_conf_pos … HTU1 … HT12) -T1 /3 width=5 by lstas_step_dx, ex2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta.etc
deleted file mode 100644 (file)
index fc6bf6a..0000000
+++ /dev/null
@@ -1,143 +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/statictype_5.ma".
-include "basic_2/grammar/genv.ma".
-include "basic_2/substitution/drop.ma".
-include "basic_2/static/sh.ma".
-
-(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* activate genv *)
-inductive sta (h:sh): relation4 genv lenv term term ≝
-| sta_sort: ∀G,L,k. sta h G L (⋆k) (⋆(next h k))
-| sta_ldef: ∀G,L,K,V,W,U,i. ⇩[i] L ≡ K.ⓓV → sta h G K V W →
-            ⇧[0, i + 1] W ≡ U → sta h G L (#i) U
-| sta_ldec: ∀G,L,K,W,V,U,i. ⇩[i] L ≡ K.ⓛW → sta h G K W V →
-            ⇧[0, i + 1] W ≡ U → sta h G L (#i) U
-| sta_bind: ∀a,I,G,L,V,T,U. sta h G (L.ⓑ{I}V) T U →
-            sta h G L (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
-| sta_appl: ∀G,L,V,T,U. sta h G L T U → sta h G L (ⓐV.T) (ⓐV.U)
-| sta_cast: ∀G,L,W,T,U. sta h G L T U → sta h G L (ⓝW.T) U
-.
-
-interpretation "static type assignment (term)"
-   'StaticType h G L T U = (sta h G L T U).
-
-(* Basic inversion lemmas ************************************************)
-
-fact sta_inv_sort1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀k0. T = ⋆k0 →
-                        U = ⋆(next h k0).
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #k0 #H destruct //
-| #G #L #K #V #W #U #i #_ #_ #_ #k0 #H destruct
-| #G #L #K #W #V #U #i #_ #_ #_ #k0 #H destruct
-| #a #I #G #L #V #T #U #_ #k0 #H destruct
-| #G #L #V #T #U #_ #k0 #H destruct
-| #G #L #W #T #U #_ #k0 #H destruct
-qed-.
-
-(* Basic_1: was: sty0_gen_sort *)
-lemma sta_inv_sort1: ∀h,G,L,U,k. ⦃G, L⦄ ⊢ ⋆k •[h] U → U = ⋆(next h k).
-/2 width=5 by sta_inv_sort1_aux/ qed-.
-
-fact sta_inv_lref1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀j. T = #j →
-                        (∃∃K,V,W. ⇩[j] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •[h] W &
-                                  ⇧[0, j+1] W ≡ U
-                        ) ∨
-                        (∃∃K,W,V. ⇩[j] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V &
-                                  ⇧[0, j+1] W ≡ U
-                        ).
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #j #H destruct
-| #G #L #K #V #W #U #i #HLK #HVW #HWU #j #H destruct /3 width=6 by or_introl, ex3_3_intro/
-| #G #L #K #W #V #U #i #HLK #HWV #HWU #j #H destruct /3 width=6 by or_intror, ex3_3_intro/
-| #a #I #G #L #V #T #U #_ #j #H destruct
-| #G #L #V #T #U #_ #j #H destruct
-| #G #L #W #T #U #_ #j #H destruct
-]
-qed-.
-
-(* Basic_1: was sty0_gen_lref *)
-lemma sta_inv_lref1: ∀h,G,L,U,i. ⦃G, L⦄ ⊢ #i •[h] U →
-                     (∃∃K,V,W. ⇩[i] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •[h] W &
-                               ⇧[0, i+1] W ≡ U
-                     ) ∨
-                     (∃∃K,W,V. ⇩[i] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V &
-                               ⇧[0, i+1] W ≡ U
-                     ).
-/2 width=3 by sta_inv_lref1_aux/ qed-.
-
-fact sta_inv_gref1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀p0. T = §p0 → ⊥.
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #p0 #H destruct
-| #G #L #K #V #W #U #i #_ #_ #_ #p0 #H destruct
-| #G #L #K #W #V #U #i #_ #_ #_ #p0 #H destruct
-| #a #I #G #L #V #T #U #_ #p0 #H destruct
-| #G #L #V #T #U #_ #p0 #H destruct
-| #G #L #W #T #U #_ #p0 #H destruct
-qed-.
-
-lemma sta_inv_gref1: ∀h,G,L,U,p. ⦃G, L⦄ ⊢ §p •[h] U → ⊥.
-/2 width=8 by sta_inv_gref1_aux/ qed-.
-
-fact sta_inv_bind1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀b,J,X,Y. T = ⓑ{b,J}Y.X →
-                        ∃∃Z. ⦃G, L.ⓑ{J}Y⦄ ⊢ X •[h] Z & U = ⓑ{b,J}Y.Z.
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #b #J #X #Y #H destruct
-| #G #L #K #V #W #U #i #_ #_ #_ #b #J #X #Y #H destruct
-| #G #L #K #W #V #U #i #_ #_ #_ #b #J #X #Y #H destruct
-| #a #I #G #L #V #T #U #HTU #b #J #X #Y #H destruct /2 width=3 by ex2_intro/
-| #G #L #V #T #U #_ #b #J #X #Y #H destruct
-| #G #L #W #T #U #_ #b #J #X #Y #H destruct
-]
-qed-.
-
-(* Basic_1: was: sty0_gen_bind *)
-lemma sta_inv_bind1: ∀h,b,J,G,L,Y,X,U. ⦃G, L⦄ ⊢ ⓑ{b,J}Y.X •[h] U →
-                     ∃∃Z. ⦃G, L.ⓑ{J}Y⦄ ⊢ X •[h] Z & U = ⓑ{b,J}Y.Z.
-/2 width=3 by sta_inv_bind1_aux/ qed-.
-
-fact sta_inv_appl1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀X,Y. T = ⓐY.X →
-                        ∃∃Z. ⦃G, L⦄ ⊢ X •[h] Z & U = ⓐY.Z.
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #X #Y #H destruct
-| #G #L #K #V #W #U #i #_ #_ #_ #X #Y #H destruct
-| #G #L #K #W #V #U #i #_ #_ #_ #X #Y #H destruct
-| #a #I #G #L #V #T #U #_ #X #Y #H destruct
-| #G #L #V #T #U #HTU #X #Y #H destruct /2 width=3 by ex2_intro/
-| #G #L #W #T #U #_ #X #Y #H destruct
-]
-qed-.
-
-(* Basic_1: was: sty0_gen_appl *)
-lemma sta_inv_appl1: ∀h,G,L,Y,X,U. ⦃G, L⦄ ⊢ ⓐY.X •[h] U →
-                     ∃∃Z. ⦃G, L⦄ ⊢ X •[h] Z & U = ⓐY.Z.
-/2 width=3 by sta_inv_appl1_aux/ qed-.
-
-fact sta_inv_cast1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀X,Y. T = ⓝY.X →
-                     ⦃G, L⦄ ⊢ X •[h] U.
-#h #G #L #T #U * -G -L -T -U
-[ #G #L #k #X #Y #H destruct
-| #G #L #K #V #W #U #i #_ #_ #_ #X #Y #H destruct
-| #G #L #K #W #V #U #i #_ #_ #_ #X #Y #H destruct
-| #a #I #G #L #V #T #U #_ #X #Y #H destruct
-| #G #L #V #T #U #_ #X #Y #H destruct
-| #G #L #W #T #U #HTU #X #Y #H destruct //
-]
-qed-.
-
-(* Basic_1: was: sty0_gen_cast *)
-lemma sta_inv_cast1: ∀h,G,L,X,Y,U. ⦃G, L⦄ ⊢ ⓝY.X •[h] U → ⦃G, L⦄ ⊢ X •[h] U.
-/2 width=4 by sta_inv_cast1_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_aaa.etc
deleted file mode 100644 (file)
index affd2ed..0000000
+++ /dev/null
@@ -1,52 +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/static/sta.ma".
-include "basic_2/static/aaa_lift.ma".
-
-(* STATIC TYPE ASSIGNMENT FOR TERMS *****************************************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-lemma aaa_sta: ∀h,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ∃U. ⦃G, L⦄ ⊢ T •[h] U.
-#h #G #L #T #A #H elim H -G -L -T -A
-[ /2 width=2 by sta_sort, ex_intro/
-| * #G #L #K [ #V | #W ] #B #i #HLK #_ * [ #W | #V ] #HVW
-  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldef, sta_ldec, ex_intro/
-| #a #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_bind, ex_intro/
-| #a #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_bind, ex_intro/
-| #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_appl, ex_intro/
-| #G #L #W #T #A #_ #_ #_ * /3 width=2 by sta_cast, ex_intro/
-]
-qed-.
-
-lemma sta_aaa_conf: ∀h,G,L. Conf3 … (aaa G L) (sta h G L).
-#h #G #L #T #A #H elim H -G -L -T -A
-[ #G #L #k #U #H
-  lapply (sta_inv_sort1 … H) -H #H destruct //
-| #I #G #L #K #V #B #i #HLK #HV #IHV #U #H
-  elim (sta_inv_lref1 … H) -H * #K0 #V0 #W0 #HLK0 #HVW0 #HU
-  lapply (drop_mono … HLK0 … HLK) -HLK0 #H0 destruct
-  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
-  @(aaa_lift … HLK … HU) -HU -L /2 width=2 by/
-| #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
-  elim (sta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2 by aaa_abbr/
-| #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
-  elim (sta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2 by aaa_abst/
-| #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
-  elim (sta_inv_appl1 … H) -H #U #HTU #H destruct /3 width=3 by aaa_appl/
-| #G #L #V #T #A #_ #_ #IHV #IHT #X #H
-  lapply (sta_inv_cast1 … H) -H /2 width=2 by/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_lift.etc
deleted file mode 100644 (file)
index 4d34287..0000000
+++ /dev/null
@@ -1,113 +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/drop_drop.ma".
-include "basic_2/static/sta.ma".
-
-(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Properties on relocation *************************************************)
-
-(* Basic_1: was: sty0_lift *)
-lemma sta_lift: ∀h,G. l_liftable (sta h G).
-#h #G #L1 #T1 #U1 #H elim H -G -L1 -T1 -U1
-[ #G #L1 #k #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
-  >(lift_inv_sort1 … H1) -X1
-  >(lift_inv_sort1 … H2) -X2 //
-| #G #L1 #K1 #V1 #W1 #W #i #HLK1 #_ #HW1 #IHVW1 #L2 #s #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2) -W // #W2 #HW12 #HWU2
-    elim (drop_trans_le … HL21 … HLK1) -L1 /2 width=2 by lt_to_le/ #X #HLK2 #H
-    elim (drop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
-    /3 width=9 by sta_ldef/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W /2 width=1 by le_S/ #HW1U2
-    lapply (drop_trans_ge … HL21 … HLK1 ?) -L1 /3 width=9 by sta_ldef, drop_inv_gen/
-  ]
-| #G #L1 #K1 #W1 #V1 #W #i #HLK1 #_ #HW1 #IHWV1 #L2 #s #d #e #HL21 #X #H #U2 #HWU2
-  elim (lift_inv_lref1 … H) * #Hid #H destruct
-  [ elim (lift_trans_ge … HW1 … HWU2) -W // <minus_plus #W #HW1 #HWU2
-    elim (drop_trans_le … HL21 … HLK1) -L1 /2 width=2 by lt_to_le/ #X #HLK2 #H
-    elim (drop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
-    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
-    elim (lift_total V1 (d-i-1) e) /3 width=9 by sta_ldec/
-  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W /2 width=1 by le_S/ #HW1U2
-    lapply (drop_trans_ge … HL21 … HLK1 ?) -L1 /3 width=9 by sta_ldec, drop_inv_gen/
-  ]
-| #a #I #G #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct /4 width=6 by sta_bind, drop_skip/
-| #G #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
-  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
-  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
-  lapply (lift_mono … H1 … HV12) -H1 #H destruct /4 width=6 by sta_appl/
-| #G #L1 #W1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X #H #U2 #HU12
-  elim (lift_inv_flat1 … H) -H #W2 #T2 #_ #HT12 #H destruct /3 width=6 by sta_cast/
-]
-qed.
-
-(* Note: apparently this was missing in basic_1 *)
-lemma sta_inv_lift1: ∀h,G. l_deliftable_sn (sta h G).
-#h #G #L2 #T2 #U2 #H elim H -G -L2 -T2 -U2
-[ #G #L2 #k #L1 #s #d #e #_ #X #H
-  >(lift_inv_sort2 … H) -X /2 width=3 by sta_sort, lift_sort, ex2_intro/
-| #G #L2 #K2 #V2 #W2 #W #i #HLK2 #HVW2 #HW2 #IHVW2 #L1 #s #d #e #HL21 #X #H
-  elim (lift_inv_lref2 … H) * #Hid #H destruct [ -HVW2 | -IHVW2 ]
-  [ elim (drop_conf_lt … HL21 … HLK2) -L2 // #K1 #V1 #HLK1 #HK21 #HV12
-    elim (IHVW2 … HK21 … HV12) -K2 -V2 #W1 #HW12 #HVW1
-    elim (lift_trans_le … HW12 … HW2) -W2 // >minus_plus <plus_minus_m_m /3 width=8 by sta_ldef, ex2_intro/
-  | lapply (drop_conf_ge … HL21 … HLK2 ?) -L2 // #HL1K2
-    elim (le_inv_plus_l … Hid) -Hid #Hdie #ei
-    elim (lift_split … HW2 d (i-e+1)) -HW2 /2 width=1 by le_S_S, le_S/
-    #W0 #HW20 <le_plus_minus_comm // >minus_minus_m_m /3 width=8 by sta_ldef, le_S, ex2_intro/
-  ]
-| #G #L2 #K2 #W2 #V2 #W #i #HLK2 #HWV2 #HW2 #IHWV2 #L1 #s #d #e #HL21 #X #H
-  elim (lift_inv_lref2 … H) * #Hid #H destruct [ -HWV2 | -IHWV2 ]
-  [ elim (drop_conf_lt … HL21 … HLK2) -L2 // #K1 #W1 #HLK1 #HK21 #HW12
-    elim (IHWV2 … HK21 … HW12) -K2 #V1 #_ #HWV1
-    elim (lift_trans_le … HW12 … HW2) -W2 // >minus_plus <plus_minus_m_m /3 width=8 by sta_ldec, ex2_intro/
-  | lapply (drop_conf_ge … HL21 … HLK2 ?) -L2 // #HL1K2
-    elim (le_inv_plus_l … Hid) -Hid #Hdie #ei
-    elim (lift_split … HW2 d (i-e+1)) -HW2 /2 width=1 by le_S_S, le_S/
-    #W0 #HW20 <le_plus_minus_comm // >minus_minus_m_m /3 width=8 by sta_ldec, le_S, ex2_intro/
-  ]
-| #a #I #G #L2 #V2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
-  elim (lift_inv_bind2 … H) -H #V1 #T1 #HV12 #HT12 #H destruct
-  elim (IHTU2 (L1.ⓑ{I}V1) … HT12) -IHTU2 -HT12 /3 width=5 by sta_bind, drop_skip, lift_bind, ex2_intro/
-| #G #L2 #V2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
-  elim (lift_inv_flat2 … H) -H #V1 #T1 #HV12 #HT12 #H destruct
-  elim (IHTU2 … HL21 … HT12) -L2 -HT12 /3 width=5 by sta_appl, lift_flat, ex2_intro/
-| #G #L2 #W2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
-  elim (lift_inv_flat2 … H) -H #W1 #T1 #_ #HT12 #H destruct
-  elim (IHTU2 … HL21 … HT12) -L2 -HT12 /3 width=3 by sta_cast, ex2_intro/
-]
-qed-.
-
-(* Advanced forward lemmas **************************************************)
-
-(* Basic_1: was: sty0_correct *)
-lemma sta_fwd_correct: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∃T0. ⦃G, L⦄ ⊢ U •[h] T0.
-#h #G #L #T #U #H elim H -G -L -T -U
-[ /2 width=2/
-| #G #L #K #V #W #W0 #i #HLK #_ #HW0 * #V0 #HWV0
-  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
-  elim (lift_total V0 0 (i+1)) /3 width=11 by ex_intro, sta_lift/
-| #G #L #K #W #V #V0 #i #HLK #HWV #HWV0 #_
-  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
-  elim (lift_total V 0 (i+1)) /3 width=11 by ex_intro, sta_lift/
-| #a #I #G #L #V #T #U #_ * /3 width=2 by sta_bind, ex_intro/
-| #G #L #V #T #U #_ * #T0 #HUT0 /3 width=2 by sta_appl, ex_intro/
-| #G #L #W #T #U #_ * /2 width=2 by ex_intro/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_llpx_sn.etc
deleted file mode 100644 (file)
index 3adf28f..0000000
+++ /dev/null
@@ -1,43 +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/multiple/llpx_sn_drop.ma".
-include "basic_2/static/sta.ma".
-
-(* STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ******************************)
-
-(* Properties on lazy sn pointwise extensions *******************************)
-
-lemma sta_llpx_sn_conf: ∀R. (∀L. reflexive … (R L)) → l_liftable R →
-                        ∀h,G. s_r_confluent1 … (sta h G) (llpx_sn R 0).
-#R #H1R #H2R #h #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
-[ /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
-| #G #Ls #Ks #V1s #W2s #V2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (drop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (drop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
-| #G #Ls #Ks #V1s #W1s #V2s #i #HLKs #_ #HV12s #IHVW1s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
-  #Kd #V1d #HLKd #HV1s #HV1sd
-  lapply (drop_fwd_drop2 … HLKs) -HLKs #HLKs
-  lapply (drop_fwd_drop2 … HLKd) -HLKd #HLKd
-  @(llpx_sn_lift_le … HLKs HLKd … HV12s) -HLKs -HLKd -HV12s /2 width=1 by/ (**) (* full auto too slow *)
-| #a #I #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
-  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
-  /3 width=1 by llpx_sn_flat/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/sta_sta.etc
deleted file mode 100644 (file)
index 6d54d56..0000000
+++ /dev/null
@@ -1,43 +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/drop_drop.ma".
-include "basic_2/static/sta.ma".
-
-(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
-
-(* Main properties **********************************************************)
-
-(* Note: apparently this was missing in basic_1 *)
-theorem sta_mono: ∀h,G,L. singlevalued … (sta h G L).
-#h #G #L #T #U1 #H elim H -G -L -T -U1
-[ #G #L #k #X #H >(sta_inv_sort1 … H) -X //
-| #G #L #K #V #W #U1 #i #HLK #_ #HWU1 #IHVW #U2 #H
-  elim (sta_inv_lref1 … H) -H * #K0 #V0 #W0 #HLK0 #HVW0 #HW0U2
-  lapply (drop_mono … HLK0 … HLK) -HLK -HLK0 #H destruct
-  lapply (IHVW … HVW0) -IHVW -HVW0 #H destruct
-  >(lift_mono … HWU1 … HW0U2) -W0 -U1 //
-| #G #L #K #W #V #U1 #i #HLK #_ #HWU1 #IHWV #U2 #H
-  elim (sta_inv_lref1 … H) -H * #K0 #W0 #V0 #HLK0 #HWV0 #HV0U2
-  lapply (drop_mono … HLK0 … HLK) -HLK -HLK0 #H destruct
-  lapply (IHWV … HWV0) -IHWV -HWV0 #H destruct
-  >(lift_mono … HWU1 … HV0U2) -W -U1 //
-| #a #I #G #L #V #T #U1 #_ #IHTU1 #X #H
-  elim (sta_inv_bind1 … H) -H #U2 #HTU2 #H destruct /3 width=1 by eq_f/
-| #G #L #V #T #U1 #_ #IHTU1 #X #H
-  elim (sta_inv_appl1 … H) -H #U2 #HTU2 #H destruct /3 width=1 by eq_f/
-| #G #L #W #T #U1 #_ #IHTU1 #U2 #H
-  lapply (sta_inv_cast1 … H) -H /2 width=1 by/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictype_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictype_5.etc
deleted file mode 100644 (file)
index 9249be4..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • break [ term 46 h ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'StaticType $h $G $L $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictypestaralt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/sta/statictypestaralt_6.etc
deleted file mode 100644 (file)
index a6e46be..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • • * break [ term 46 h , break term 46 l ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'StaticTypeStarAlt $h $G $L $l $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/chnf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/chnf.etc
deleted file mode 100644 (file)
index f6106d3..0000000
+++ /dev/null
@@ -1,40 +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 "hvbox( L ⊢ break 𝐇𝐍 ⦃ term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'HdNormal $L $T }.
-
-include "basic_2/reduction/cpr_tshf.ma".
-
-(* CONTEXT-SENSITIVE WEAK HEAD NORMAL TERMS *********************************)
-
-definition chnf: lenv → predicate term ≝ λL. NF … (cpr L) tshf.
-
-interpretation
-   "context-sensitive head normality (term)"
-   'HdNormal L T = (chnf L T).
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma chnf_inv_tshf: ∀L,T. L ⊢ 𝐇𝐍⦃T⦄ → T ≈ T.
-normalize /2 width=1/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma tshf_thnf: ∀T. T ≈ T → ⋆ ⊢ 𝐇𝐍⦃T⦄.
-#T #HT #T2 #H elim (cpr_fwd_tshf1 … H) -H //
-#H elim H //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/cpr_tshf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/cpr_tshf.etc
deleted file mode 100644 (file)
index 0fc5e1d..0000000
+++ /dev/null
@@ -1,46 +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/grammar/tshf.ma".
-include "basic_2/reduction/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
-
-(* Forward lemmas on same head forms for terms ******************************)
-
-lemma cpr_fwd_tshf1: ∀L,T1,T2. L ⊢ T1 ➡ T2 → T1 ≈ T1 →
-                     T2 ≈ T1 ∨ (L = ⋆ → ⊥).
-#L #T1 #T2 #H elim H -L -T1 -T2
-[ /2 width=1/
-| #L #K #V1 #V2 #W2 #i #HLK #_ #_ #_ #_
-  @or_intror #H destruct
-  lapply (ldrop_inv_atom1 … HLK) -HLK #H destruct
-| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #_ #_ #H
-  elim (tshf_inv_bind1 … H) -H #W2 #U2 #H1 * #H2 destruct /2 width=1/
-| #I #L #V1 #V2 #T1 #T2 #_ #_ #_ #IHT12 #H
-  elim (tshf_inv_flat1 … H) -H #W2 #U2 #HT1U2 #HT1 #_ #H1 #H2 destruct
-  lapply (IHT12 HT1U2) -IHT12 -HT1U2 * #HUT2 /3 width=1/
-  lapply (simple_tshf_repl_sn … HUT2 HT1) /3 width=1/
-| #L #V #T #T1 #T2 #_ #_ #_ #H
-  elim (tshf_inv_bind1 … H) -H #W2 #U2 #H1 * #H2 destruct
-| #L #V #T1 #T2 #_ #_ #H
-  elim (tshf_inv_flat1 … H) -H #W2 #U2 #_ #_ #_ #H destruct
-| #a #L #V1 #V2 #W #T1 #T2 #_ #_ #_ #_ #H
-  elim (tshf_inv_flat1 … H) -H #W2 #U2 #_ #H
-  elim (simple_inv_bind … H)
-| #a #L #V2 #V1 #V #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #H
-  elim (tshf_inv_flat1 … H) -H #U1 #U2 #_ #H
-  elim (simple_inv_bind … H)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/tshf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/tshf/tshf.etc
deleted file mode 100644 (file)
index 583c3f4..0000000
+++ /dev/null
@@ -1,98 +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 "hvbox( L ⊢ break term 46 T1 ≈ break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'Hom $L $T1 $T2 }.
-
-notation "hvbox( L ⊢ break 𝐇𝐑 ⦃ term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'HdReducible $L $T }.
-
-notation "hvbox( L ⊢ break 𝐇𝐈 ⦃ term 46 T ⦄ )"
-   non associative with precedence 45
-   for @{ 'NotHdReducible $L $T }.
-
-include "basic_2/grammar/term_simple.ma".
-
-(* SAME HEAD TERM FORMS *****************************************************)
-
-inductive tshf: relation term ≝
-   | tshf_atom: ∀I. tshf (⓪{I}) (⓪{I})
-   | tshf_abbr: ∀V1,V2,T1,T2. tshf (-ⓓV1. T1) (-ⓓV2. T2)
-   | tshf_abst: ∀a,V1,V2,T1,T2. tshf (ⓛ{a}V1. T1) (ⓛ{a}V2. T2)
-   | tshf_appl: ∀V1,V2,T1,T2. tshf T1 T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄ →
-                tshf (ⓐV1. T1) (ⓐV2. T2)
-.
-
-interpretation "same head form (term)" 'napart T1 T2 = (tshf T1 T2).
-
-(* Basic properties *********************************************************)
-
-lemma tshf_sym: ∀T1,T2. T1 ≈ T2 → T2 ≈ T1.
-#T1 #T2 #H elim H -T1 -T2 /2 width=1/
-qed.
-
-lemma tshf_refl2: ∀T1,T2. T1 ≈ T2 → T2 ≈ T2.
-#T1 #T2 #H elim H -T1 -T2 // /2 width=1/
-qed.
-
-lemma tshf_refl1: ∀T1,T2. T1 ≈ T2 → T1 ≈ T1.
-/3 width=2/ qed.
-
-lemma simple_tshf_repl_dx: ∀T1,T2. T1 ≈ T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄.
-#T1 #T2 #H elim H -T1 -T2 //
-[ #V1 #V2 #T1 #T2 #H
-  elim (simple_inv_bind … H)
-| #a #V1 #V2 #T1 #T2 #H
-  elim (simple_inv_bind … H)
-]
-qed. (**) (* remove from index *)
-
-lemma simple_tshf_repl_sn: ∀T1,T2. T1 ≈ T2 → 𝐒⦃T2⦄ → 𝐒⦃T1⦄.
-/3 width=3/ qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact tshf_inv_bind1_aux: ∀T1,T2. T1 ≈ T2 → ∀a,I,W1,U1. T1 = ⓑ{a,I}W1.U1 →
-                         ∃∃W2,U2. T2 = ⓑ{a,I}W2. U2 &
-                                  (Bind2 a I = Bind2 false Abbr ∨ I = Abst).
-#T1 #T2 * -T1 -T2
-[ #J #a #I #W1 #U1 #H destruct
-| #V1 #V2 #T1 #T2 #a #I #W1 #U1 #H destruct /3 width=3/
-| #b #V1 #V2 #T1 #T2 #a #I #W1 #U1 #H destruct /3 width=3/
-| #V1 #V2 #T1 #T2 #_ #_ #_ #a #I #W1 #U1 #H destruct
-]
-qed.
-
-lemma tshf_inv_bind1: ∀a,I,W1,U1,T2. ⓑ{a,I}W1.U1 ≈ T2 →
-                      ∃∃W2,U2. T2 = ⓑ{a,I}W2. U2 &
-                               (Bind2 a I = Bind2 false Abbr ∨ I = Abst).
-/2 width=5/ qed-.
-
-fact tshf_inv_flat1_aux: ∀T1,T2. T1 ≈ T2 → ∀I,W1,U1. T1 = ⓕ{I}W1.U1 →
-                         ∃∃W2,U2. U1 ≈ U2 & 𝐒⦃U1⦄ & 𝐒⦃U2⦄ &
-                                  I = Appl & T2 = ⓐW2. U2.
-#T1 #T2 * -T1 -T2
-[ #J #I #W1 #U1 #H destruct
-| #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct
-| #a #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct
-| #V1 #V2 #T1 #T2 #HT12 #HT1 #HT2 #I #W1 #U1 #H destruct /2 width=5/
-]
-qed.
-
-lemma tshf_inv_flat1: ∀I,W1,U1,T2. ⓕ{I}W1.U1 ≈ T2 →
-                      ∃∃W2,U2. U1 ≈ U2 & 𝐒⦃U1⦄ & 𝐒⦃U2⦄ &
-                               I = Appl & T2 = ⓐW2. U2.
-/2 width=4/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_aaa.etc
deleted file mode 100644 (file)
index 98fe013..0000000
+++ /dev/null
@@ -1,25 +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/static/ssta_aaa.ma".
-include "basic_2/reducibility/cpr_aaa.ma".
-include "basic_2/reducibility/xpr.ma".
-
-(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-lemma xpr_aaa: ∀h,g,L,T,A. L ⊢ T ⁝ A → ∀U. ⦃h, L⦄ ⊢ T •➡[g] U → L ⊢ U ⁝ A.
-#h #g #L #T #A #HT #U * /2 width=3/ /2 width=6/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lift.etc
deleted file mode 100644 (file)
index 8f5deca..0000000
+++ /dev/null
@@ -1,48 +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/static/ssta_lift.ma".
-include "basic_2/reducibility/cpr_lift.ma".
-include "basic_2/reducibility/xpr.ma".
-
-(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma xpr_inv_abst1: ∀h,g,a,L,V1,T1,U2. ⦃h, L⦄ ⊢ ⓛ{a}V1.T1 •➡[g] U2 →
-                     ∃∃V2,T2. L ⊢ V1 ➡ V2 & ⦃h, L. ⓛV1⦄ ⊢ T1 •➡[g] T2 &
-                              U2 = ⓛ{a}V2. T2.
-#h #g #a #L #V1 #T1 #U2 *
-[ #H elim (cpr_inv_abst1 … H Abst V1) /3 width=5/
-| #l #H elim (ssta_inv_bind1 … H) /3 width=5/
-]
-qed-.
-
-(* Relocation properties ****************************************************)
-
-lemma xpr_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K →
-                ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
-                ∀h,g. ⦃h, K⦄ ⊢ T1 •➡[g] T2 → ⦃h, L⦄ ⊢ U1 •➡[g] U2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #h #g *
-/3 width=9/ /3 width=10/
-qed.
-
-lemma xpr_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
-                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀h,g,U2. ⦃h, L⦄ ⊢ U1 •➡[g] U2 →
-                     ∃∃T2. ⇧[d, e] T2 ≡ U2 & ⦃h, K⦄ ⊢ T1 •➡[g] T2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #U2 * [ #HU12 | #l #HU12 ]
-[ elim (cpr_inv_lift1 … HLK … HTU1 … HU12) -L -U1 /3 width=3/
-| elim (ssta_inv_lift1 … HU12 … HLK … HTU1) -L -U1 /3 width=4/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lsubss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xpr_lsubss.etc
deleted file mode 100644 (file)
index bc66cd2..0000000
+++ /dev/null
@@ -1,28 +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/static/lsubss_ssta.ma".
-include "basic_2/reducibility/xpr.ma".
-
-(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
-
-(* Properties on lenv ref for stratified type assignment ********************)
-
-lemma lsubss_xpr_trans: ∀h,g,L1,L2. h ⊢ L1 •⊑[g] L2 →
-                        ∀T1,T2. ⦃h, L2⦄ ⊢ T1 •➡[g] T2 → ⦃h, L1⦄ ⊢ T1 •➡[g] T2.
-#h #g #L1 #L2 #HL12 #T1 #T2 * [ | #l ] #HT12
-[ lapply (lsubss_fwd_lsubs2 … HL12) -HL12 /3 width=3/
-| /3 width=4/
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs.etc
deleted file mode 100644 (file)
index bffc4e7..0000000
+++ /dev/null
@@ -1,72 +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 "hvbox( ⦃ term 46 h , break term 46 L ⦄ ⊢ break term 46 T1 • ➡ * break [ term 46 g ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'XPRedStar $h $g $L $T1 $T2 }.
-
-notation "hvbox( ⦃ term 46 h , break term 46 L ⦄ ⊢ • ⬊ * break [ term 46 g ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'XSN $h $g $L $T }.
-
-include "basic_2/static/lsubss.ma".
-include "basic_2/reducibility/xpr.ma".
-(*
-include "basic_2/reducibility/cnf.ma".
-*)
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-definition xprs: ∀h. sd h → lenv → relation term ≝
-                 λh,g,L. TC … (xpr h g L).
-
-interpretation "extended parallel computation (term)"
-   'XPRedStar h g L T1 T2 = (xprs h g L T1 T2).
-
-(* Basic eliminators ********************************************************)
-
-lemma xprs_ind: ∀h,g,L,T1. ∀R:predicate term. R T1 →
-                (∀T,T2. ⦃h, L⦄ ⊢ T1 •➡*[g] T → ⦃h, L⦄ ⊢ T •➡[g] T2 → R T → R T2) →
-                ∀T2. ⦃h, L⦄ ⊢ T1 •➡*[g] T2 → R T2.
-#h #g #L #T1 #R #HT1 #IHT1 #T2 #HT12
-@(TC_star_ind … HT1 IHT1 … HT12) //
-qed-.
-
-lemma xprs_ind_dx: ∀h,g,L,T2. ∀R:predicate term. R T2 →
-                   (∀T1,T. ⦃h, L⦄ ⊢ T1 •➡[g] T → ⦃h, L⦄ ⊢ T •➡*[g] T2 → R T → R T1) →
-                   ∀T1. ⦃h, L⦄ ⊢ T1 •➡*[g] T2 → R T1.
-#h #g #L #T2 #R #HT2 #IHT2 #T1 #HT12
-@(TC_star_ind_dx … HT2 IHT2 … HT12) //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma xprs_refl: ∀h,g,L. reflexive … (xprs h g L).
-/2 width=1/ qed.
-
-lemma xprs_strap1: ∀h,g,L,T1,T,T2.
-                   ⦃h, L⦄ ⊢ T1 •➡*[g] T → ⦃h, L⦄ ⊢ T •➡[g] T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
-/2 width=3/ qed.
-
-lemma xprs_strap2: ∀h,g,L,T1,T,T2.
-                   ⦃h, L⦄ ⊢ T1 •➡[g] T → ⦃h, L⦄ ⊢ T •➡*[g] T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
-/2 width=3/ qed.
-
-(* Basic inversion lemmas ***************************************************)
-(*
-axiom xprs_inv_cnf1: ∀L,T,U. L ⊢ T ➡* U → L ⊢ 𝐍⦃T⦄ → T = U.
-#L #T #U #H @(xprs_ind_dx … H) -T //
-#T0 #T #H1T0 #_ #IHT #H2T0
-lapply (H2T0 … H1T0) -H1T0 #H destruct /2 width=1/
-qed-.
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_aaa.etc
deleted file mode 100644 (file)
index 5beb8fe..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/reducibility/xpr_aaa.ma".
-include "basic_2/computation/xprs.ma".
-
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-(* Properties on atomic arity assignment for terms **************************)
-
-lemma xprs_aaa: ∀h,g,L,T,A. L ⊢ T ⁝ A → ∀U. ⦃h, L⦄ ⊢ T •➡*[g] U → L ⊢ U ⁝ A.
-#h #g #L #T #A #HT #U #H @(xprs_ind … H) -U // /2 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_cprs.etc
deleted file mode 100644 (file)
index 13a4f88..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/computation/cprs.ma".
-include "basic_2/computation/xprs.ma".
-
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-(* properties on context sensitive parallel computation for terms ***********)
-
-lemma cprs_xprs: ∀h,g,L,T1,T2. L ⊢ T1 ➡* T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
-#h #g #L #T1 #T2 #H @(cprs_ind … H) -T2 // /3 width=3/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lift.etc
deleted file mode 100644 (file)
index cb151a1..0000000
+++ /dev/null
@@ -1,50 +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/reducibility/xpr_lift.ma".
-include "basic_2/computation/cprs.ma".
-include "basic_2/computation/xprs.ma".
-
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-(* Advanced forward lemmas **************************************************)
-
-lemma xprs_fwd_abst1: ∀h,g,a,L,V1,T1,U2. ⦃h, L⦄ ⊢ ⓛ{a}V1. T1 •➡*[g] U2 →
-                      ∃∃V2,T2. L ⊢ V1 ➡* V2 & U2 = ⓛ{a}V2. T2.
-#h #g #a #L #V1 #T1 #U2 #H @(xprs_ind … H) -U2 /2 width=4/
-#U #U2 #_ #HU2 * #V #T #HV1 #H destruct
-elim (xpr_inv_abst1 … HU2) -HU2 #V2 #T2 #HV2 #_ #H destruct /3 width=4/
-qed-.
-
-(* Relocation properties ****************************************************)
-
-lemma xprs_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K → ∀T1,U1. ⇧[d, e] T1 ≡ U1 →
-                 ∀h,g,T2. ⦃h, K⦄ ⊢ T1 •➡*[g] T2 → ∀U2. ⇧[d, e] T2 ≡ U2 →
-                 ⦃h, L⦄ ⊢ U1 •➡*[g] U2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #T2 #HT12 @(xprs_ind … HT12) -T2
-[ -HLK #T2 #HT12
-   <(lift_mono … HTU1 … HT12) -T1 //
-| -HTU1 #T #T2 #_ #HT2 #IHT2 #U2 #HTU2
-  elim (lift_total T d e) #U #HTU
-  lapply (xpr_lift … HLK … HTU … HTU2 … HT2) -T2 -HLK /3 width=3/
-]
-qed.
-
-lemma xprs_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
-                      ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀h,g,U2. ⦃h, L⦄ ⊢ U1 •➡*[g] U2 →
-                      ∃∃T2. ⇧[d, e] T2 ≡ U2 & ⦃h, K⦄ ⊢ T1 •➡*[g] T2.
-#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #U2 #HU12 @(xprs_ind … HU12) -U2 /2 width=3/
--HTU1 #U #U2 #_ #HU2 * #T #HTU #HT1
-elim (xpr_inv_lift1 … HLK … HTU … HU2) -U -HLK /3 width=5/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lsubss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_lsubss.etc
deleted file mode 100644 (file)
index c883c14..0000000
+++ /dev/null
@@ -1,27 +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/reducibility/xpr_lsubss.ma".
-include "basic_2/computation/xprs.ma".
-
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-(* Properties on lenv ref for stratified type assignment ********************)
-
-lemma lsubss_xprs_trans: ∀h,g,L1,L2. h ⊢ L1 •⊑[g] L2 →
-                         ∀T1,T2. ⦃h, L2⦄ ⊢ T1 •➡*[g] T2 → ⦃h, L1⦄ ⊢ T1 •➡*[g] T2.
-#h #g #L1 #L2 #HL12 #T1 #T2 #H @(xprs_ind … H) -T2 //
-#T #T2 #_ #HT2 #IHT1
-lapply (lsubss_xpr_trans … HL12 … HT2) -L2 /2 width=3/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_xprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc/xpr/xprs_xprs.etc
deleted file mode 100644 (file)
index 9593f05..0000000
+++ /dev/null
@@ -1,20 +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/computation/xprs.ma".
-
-(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
-
-theorem xprs_trans: ∀h,g,L. transitive … (xprs h g L).
-/2 width=3/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cir_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cir_append.etc
new file mode 100644 (file)
index 0000000..efd097f
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/crr_append.ma".
+include "basic_2/reduction/cir.ma".
+
+(* IRREDUCIBLE TERMS FOR CONTEXT-SENSITIVE REDUCTION ************************)
+
+(* Advanved properties ******************************************************)
+
+lemma cir_labst_last: ∀G,L,T,W. ⦃G, L⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, ⋆.ⓛW @@ L⦄ ⊢ ➡ 𝐈⦃T⦄.
+/3 width=2 by crr_inv_labst_last/ qed.
+
+lemma cir_tif: ∀G,T,W. ⦃G, ⋆⦄ ⊢ ➡ 𝐈⦃T⦄ → ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐈⦃T⦄.
+/3 width=2 by crr_inv_trr/ qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cir_inv_append_sn: ∀G,L,K,T. ⦃G, K @@ L⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, L⦄ ⊢ ➡ 𝐈⦃T⦄.
+/3 width=1/ qed-.
+
+lemma cir_inv_tir: ∀G,T,W. ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐈⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡ 𝐈⦃T⦄.
+/3 width=1/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cix_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cix_append.etc
new file mode 100644 (file)
index 0000000..7b5522e
--- /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/reduction/crx_append.ma".
+include "basic_2/reduction/cix.ma".
+
+(* IRREDUCIBLE TERMS FOR CONTEXT-SENSITIVE EXTENDED REDUCTION ***************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cix_inv_append_sn: ∀h,g,G,L,K,T. ⦃G, K @@ L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄  → ⦃G, L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄.
+/3 width=1 by crx_append_sn/ qed-.
+
+lemma cix_inv_tix: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ➡[h, g] 𝐈⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡[h, g] 𝐈⦃T⦄.
+/3 width=1 by trx_crx/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cl_shift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cl_shift.etc
new file mode 100644 (file)
index 0000000..5fdab71
--- /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/grammar/lenv_append.ma".
+
+(* SHIFT OF A CLOSURE *******************************************************)
+
+let rec shift L T on L ≝ match L with
+[ LAtom       ⇒ T
+| LPair L I V ⇒ shift L (-ⓑ{I} V. T)
+].
+
+interpretation "shift (closure)" 'Append L T = (shift L T).
+
+(* Basic properties *********************************************************)
+
+lemma shift_append_assoc: ∀L,K. ∀T:term. (L @@ K) @@ T = L @@ K @@ T.
+#L #K elim K -K // normalize //
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma shift_inj: ∀L1,L2. ∀T1,T2:term. L1 @@ T1 = L2 @@ T2 → |L1| = |L2| →
+                 L1 = L2 ∧ T1 = T2.
+#L1 elim L1 -L1
+[ * normalize /2 width=1/
+  #L2 #I2 #V2 #T1 #T2 #_ <plus_n_Sm #H destruct
+| #L1 #H1 #V1 #IH * normalize
+  [ #T1 #T2 #_ <plus_n_Sm #H destruct
+  | #L2 #I2 #V2 #T1 #T2 #H1 #H2
+    elim (IH … H1) -IH -H1 /2 width=1/ -H2 #H1 #H2 destruct /2 width=1/
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpr.etc
new file mode 100644 (file)
index 0000000..71d8023
--- /dev/null
@@ -0,0 +1,29 @@
+include "basic_2/grammar/cl_shift.ma".
+include "basic_2/relocation/ldrop_append.ma".
+
+lemma cpr_append: ∀G. l_appendable_sn … (cpr G).
+#G #K #T1 #T2 #H elim H -G -K -T1 -T2
+/2 width=3 by cpr_bind, cpr_flat, cpr_zeta, cpr_tau, cpr_beta, cpr_theta/
+#G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpr_delta … (L@@K0) V1 … HVW2) //
+@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
+qed.
+
+lemma cpr_fwd_shift1: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ➡ T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#G #L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X
+  >shift_append_assoc normalize #H
+  elim (cpr_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 ] /2 width=3 by trans_eq/ (**) (* explicit constructor *)
+  | #T #_ #_ #H destruct
+  ]
+]
+qed-.
+
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpx.etc
new file mode 100644 (file)
index 0000000..5f8bf52
--- /dev/null
@@ -0,0 +1,25 @@
+lemma cpx_append: ∀h,g,G. l_appendable_sn … (cpx h g G).
+#h #g #G #K #T1 #T2 #H elim H -G -K -T1 -T2
+/2 width=3 by cpx_sort, cpx_bind, cpx_flat, cpx_zeta, cpx_tau, cpx_ti, cpx_beta, cpx_theta/
+#I #G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpx_delta … I … (L@@K0) V1 … HVW2) // 
+@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
+qed.
+
+lemma cpx_fwd_shift1: ∀h,g,G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ➡[h, g] T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#h #g #G #L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X
+  >shift_append_assoc normalize #H
+  elim (cpx_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 ] /2 width=3 by refl, trans_eq/ (**) (* explicit constructor *)
+  | #T #_ #_ #H destruct
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpy2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpy2.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_2A1/append/cpys0.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpys0.etc
new file mode 100644 (file)
index 0000000..fa9bcf6
--- /dev/null
@@ -0,0 +1,24 @@
+include "basic_2/grammar/cl_shift.ma".
+include "basic_2/relocation/ldrop_append.ma".
+
+lemma cpys_append: ∀G. l_appendable_sn … (cpys G).
+#G #K #T1 #T2 #H elim H -G -K -T1 -T2
+/2 width=3 by cpys_bind, cpys_flat/
+#I #G #K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpys_delta … I … (L@@K0) V1 … HVW2) // 
+@(ldrop_O1_append_sn_le … HK0) /2 width=2 by lt_to_le/ (**) (* /3/ does not work *)
+qed.
+
+lemma cpys_fwd_shift1: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ▶*× T →
+                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#G #L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #HT1 @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X >shift_append_assoc normalize
+  #H elim (cpys_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 ] /2 width=3 by trans_eq/ (**) (* explicit constructor *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpys2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/cpys2.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_2A1/append/crr_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/crr_append.etc
new file mode 100644 (file)
index 0000000..dbf794d
--- /dev/null
@@ -0,0 +1,56 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_append.ma".
+include "basic_2/reduction/crr.ma".
+
+(* REDUCIBLE TERMS FOR CONTEXT-SENSITIVE REDUCTION **************************)
+
+(* Advanved properties ******************************************************)
+
+lemma crr_append_sn: ∀G,L,K,T. ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, K @@ L⦄ ⊢ ➡ 𝐑⦃T⦄.
+#G #L #K0 #T #H elim H -L -T /2 width=1/
+#L #K #V #i #HLK
+lapply (ldrop_fwd_length_lt2 … HLK) #Hi
+lapply (ldrop_O1_append_sn_le … HLK … K0) -HLK /2 width=2/ -Hi /2 width=3/
+qed.
+
+lemma trr_crr: ∀G,L,T. ⦃G, ⋆⦄ ⊢ ➡ 𝐑⦃T⦄ → ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄.
+#G #L #T #H lapply (crr_append_sn … H) //
+qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+fact crr_inv_labst_last_aux: ∀G,L1,T,W. ⦃G, L1⦄ ⊢ ➡ 𝐑⦃T⦄  →
+                             ∀L2. L1 = ⋆.ⓛW @@ L2 → ⦃G, L2⦄ ⊢ ➡ 𝐑⦃T⦄.
+#G #L1 #T #W #H elim H -L1 -T /2 width=1/ /3 width=1/
+[ #L1 #K1 #V1 #i #HLK1 #L2 #H destruct
+  lapply (ldrop_fwd_length_lt2 … HLK1)
+  >append_length >commutative_plus normalize in ⊢ (??% → ?); #H
+  elim (le_to_or_lt_eq i (|L2|)) /2 width=1/ -H #Hi destruct
+  [ elim (ldrop_O1_lt … Hi) #I2 #K2 #V2 #HLK2
+    lapply (ldrop_O1_inv_append1_le … HLK1 … HLK2) -HLK1 /2 width=2/ -Hi
+    normalize #H destruct /2 width=3/
+  | lapply (ldrop_O1_inv_append1_ge … HLK1 ?) -HLK1 // <minus_n_n #H
+    lapply (ldrop_inv_O2 … H) -H #H destruct
+  ]
+| #a #I #L1 #V #T #HI #_ #IHT #L2 #H destruct /3 width=1/
+]
+qed.
+
+lemma crr_inv_labst_last: ∀G,L,T,W. ⦃G, ⋆.ⓛW @@ L⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, L⦄ ⊢ ➡ 𝐑⦃T⦄.
+/2 width=4/ qed-.
+
+lemma crr_inv_trr: ∀G,T,W. ⦃G, ⋆.ⓛW⦄ ⊢ ➡ 𝐑⦃T⦄  → ⦃G, ⋆⦄ ⊢ ➡ 𝐑⦃T⦄.
+/2 width=4/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/crx_append.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/crx_append.etc
new file mode 100644 (file)
index 0000000..56667b2
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_append.ma".
+include "basic_2/reduction/crx.ma".
+
+(* REDUCIBLE TERMS FOR CONTEXT-SENSITIVE EXTENDED REDUCTION *****************)
+
+(* Advanved properties ******************************************************)
+
+lemma crx_append_sn: ∀h,g,G,L,K,T. ⦃G, L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄  → ⦃G, K @@ L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄.
+#h #g #G #L #K0 #T #H elim H -L -T
+/2 width=2 by crx_sort, crx_appl_sn, crx_appl_dx, crx_ri2, crx_ib2_sn, crx_ib2_dx, crx_beta, crx_theta/
+#I #L #K #V #i #HLK
+lapply (ldrop_fwd_length_lt2 … HLK) #Hi
+lapply (ldrop_O1_append_sn_le … HLK … K0) -HLK /2 width=4 by crx_delta, lt_to_le/
+qed.
+
+lemma trx_crx: ∀h,g,G,L,T. ⦃G, ⋆⦄ ⊢ ➡[h, g] 𝐑⦃T⦄ → ⦃G, L⦄ ⊢ ➡[h, g] 𝐑⦃T⦄.
+#h #g #G #L #T #H lapply (crx_append_sn … H) //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpr.etc
new file mode 100644 (file)
index 0000000..5b55011
--- /dev/null
@@ -0,0 +1,13 @@
+lemma lpr_append: ∀G,K1,K2. ⦃G, K1⦄ ⊢ ➡ K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                  ⦃G, L1 @@ K1⦄ ⊢ ➡ L2 @@ K2.
+/3 width=1 by lpx_sn_append, cpr_append/ qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpr_fwd_append1: ∀G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ➡ L →
+                       ∃∃K2,L2. ⦃G, K1⦄ ⊢ ➡ K2 & L = K2 @@ L2.
+/2 width=2 by lpx_sn_fwd_append1/ qed-.
+
+lemma lpr_fwd_append2: ∀G,L,K2,L2. ⦃G, L⦄ ⊢ ➡ K2 @@ L2 →
+                       ∃∃K1,L1. ⦃G, K1⦄ ⊢ ➡ K2 & L = K1 @@ L1.
+/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx.etc
new file mode 100644 (file)
index 0000000..a1976d5
--- /dev/null
@@ -0,0 +1,13 @@
+lemma lpx_append: ∀h,g,G,K1,K2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
+                  ⦃G, L1 @@ K1⦄ ⊢ ➡[h, g] L2 @@ K2.
+/3 width=1 by lpx_sn_append, cpx_append/ qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpx_fwd_append1: ∀h,g,G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ➡[h, g] L →
+                       ∃∃K2,L2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & L = K2 @@ L2.
+/2 width=2 by lpx_sn_fwd_append1/ qed-.
+
+lemma lpx_fwd_append2: ∀h,g,G,L,K2,L2. ⦃G, L⦄ ⊢ ➡[h, g] K2 @@ L2 →
+                       ∃∃K1,L1. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & L = K1 @@ L1.
+/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpx_sn.etc
new file mode 100644 (file)
index 0000000..d399e0a
--- /dev/null
@@ -0,0 +1,31 @@
+lemma lpx_sn_append: ∀R. l_appendable_sn R →
+                     ∀K1,K2. lpx_sn R K1 K2 → ∀L1,L2. lpx_sn R L1 L2 →
+                     lpx_sn R (L1 @@ K1) (L2 @@ K2).
+#R #HR #K1 #K2 #H elim H -K1 -K2 /3 width=1 by lpx_sn_pair/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpx_sn_fwd_append1: ∀R,L1,K1,L. lpx_sn R (K1 @@ L1) L →
+                          ∃∃K2,L2. lpx_sn R K1 K2 &  L = K2 @@ L2.
+#R #L1 elim L1 -L1
+[ #K1 #K2 #HK12
+  @(ex2_2_intro … K2 (⋆)) // (* explicit constructor, /2 width=4/ does not work *)
+| #L1 #I #V1 #IH #K1 #X #H
+  elim (lpx_sn_inv_pair1 … H) -H #L #V2 #H1 #HV12 #H destruct
+  elim (IH … H1) -IH -H1 #K2 #L2 #HK12 #H destruct
+  @(ex2_2_intro … (L2.ⓑ{I}V2) HK12) // (* explicit constructor, /2 width=4/ does not work *)
+]
+qed-.
+
+lemma lpx_sn_fwd_append2: ∀R,L2,K2,L. lpx_sn R L (K2 @@ L2) →
+                          ∃∃K1,L1. lpx_sn R K1 K2 & L = K1 @@ L1.
+#R #L2 elim L2 -L2
+[ #K2 #K1 #HK12
+  @(ex2_2_intro … K1 (⋆)) // (**) (* explicit constructor, /2 width=4/ does not work *)
+| #L2 #I #V2 #IH #K2 #X #H
+  elim (lpx_sn_inv_pair2 … H) -H #L #V1 #H1 #HV12 #H destruct
+  elim (IH … H1) -IH -H1 #K1 #L1 #HK12 #H destruct
+  @(ex2_2_intro … (L1.ⓑ{I}V1) HK12) // (* explicit constructor, /2 width=4/ does not work *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpys0.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/append/lpys0.etc
new file mode 100644 (file)
index 0000000..cb3dfd0
--- /dev/null
@@ -0,0 +1,29 @@
+lemma lpys_append: ∀G,K1,K2. ⦃G, K1⦄ ⊢ ▶*× K2 → ∀L1,L2. ⦃G, L1⦄ ⊢ ▶*× L2 →
+                   ⦃G, L1 @@ K1⦄ ⊢ ▶*× L2 @@ K2.
+/3 width=1 by lpx_sn_append, cpys_append/ qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpys_fwd_append1: ∀G,K1,L1,L. ⦃G, K1 @@ L1⦄ ⊢ ▶*× L →
+                        ∃∃K2,L2. ⦃G, K1⦄ ⊢ ▶*× K2 & L = K2 @@ L2.
+/2 width=2 by lpx_sn_fwd_append1/ qed-.
+
+lemma lpys_fwd_append2: ∀G,L,K2,L2. ⦃G, L⦄ ⊢ ▶*× K2 @@ L2 →
+                        ∃∃K1,L1. ⦃G, K1⦄ ⊢ ▶*× K2 & L = K1 @@ L1.
+/2 width=2 by lpx_sn_fwd_append2/ qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma cpys_fwd_shift1_ext: ∀G,L1,L,T1,T. ⦃G, L⦄ ⊢ L1 @@ T1 ▶*× T →
+                           ∃∃L2,T2. ⦃G, L @@ L1⦄ ⊢ ▶*× L @@ L2 & ⦃G, L @@ L1⦄ ⊢ T1 ▶*× T2 &
+                                    T = L2 @@ T2.
+#G #L1 @(lenv_ind_dx … L1) -L1
+[ #L #T1 #T #HT1 @ex3_2_intro
+  [3: // |4,5: // |1,2: skip ] (**) (* auto does not work *)
+| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
+  elim (cpys_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
+  lapply (lpys_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1 by lpys_append, lpys_pair/ #HL12
+  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3 by trans_eq/ | skip ] <append_assoc // (**) (* explicit constructor *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny.etc
new file mode 100644 (file)
index 0000000..81919dc
--- /dev/null
@@ -0,0 +1,114 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/psubstnormal_5.ma".
+include "basic_2/relocation/cpy.ma".
+
+(* NORMAL TERMS FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION *****************)
+
+definition cny: ∀d,e. relation3 genv lenv term ≝
+                λd,e,G,L. NF … (cpy d e G L) (eq …).
+
+interpretation
+   "normality for context-sensitive extended substitution (term)"
+   'PSubstNormal G L T d e = (cny d e G L T).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma cny_inv_lref: ∀G,L,d,e,i. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄ →
+                    ∨∨ yinj i < d | d + e ≤ yinj i | |L| ≤ i.
+#G #L #d #e #i #H elim (ylt_split i d) /2 width=1 by or3_intro0/
+#Hdi elim (ylt_split i (d+e)) /2 width=1 by or3_intro1/
+#Hide elim (lt_or_ge i (|L|)) /2 width=1 by or3_intro2/
+#Hi elim (ldrop_O1_lt L i) //
+#I #K #V #HLK elim (lift_total V 0 (i+1))
+#W #HVW lapply (H W ?) -H /2 width=5 by cpy_subst/ -HLK
+#H destruct elim (lift_inv_lref2_be … HVW) -L -d -e //
+qed-.
+
+lemma cny_inv_bind: ∀a,I,G,L,V,T,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓑ{a,I}V.T⦄ →
+                    ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ ∧ ⦃G, L.ⓑ{I}V⦄ ⊢ ▶[⫯d, e] 𝐍⦃T⦄.
+#a #I #G #L #V1 #T1 #d #e #HVT1 @conj
+[ #V2 #HV2 lapply (HVT1 (ⓑ{a,I}V2.T1) ?) -HVT1
+| #T2 #HT2 lapply (HVT1 (ⓑ{a,I}V1.T2) ?) -HVT1
+] 
+/2 width=1 by cpy_bind/ #H destruct //
+qed-.
+
+lemma cny_inv_flat: ∀I,G,L,V,T,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓕ{I}V.T⦄ →
+                    ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ ∧ ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T⦄.
+#I #G #L #V1 #T1 #d #e #HVT1 @conj
+[ #V2 #HV2 lapply (HVT1 (ⓕ{I}V2.T1) ?) -HVT1
+| #T2 #HT2 lapply (HVT1 (ⓕ{I}V1.T2) ?) -HVT1
+] 
+/2 width=1 by cpy_flat/ #H destruct //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lsuby_cny_conf: ∀G,d,e.
+                      ∀L1,T. ⦃G, L1⦄ ⊢ ▶[d, e] 𝐍⦃T⦄ →
+                      ∀L2. L1 ⊑×[d, e] L2 → ⦃G, L2⦄ ⊢ ▶[d, e] 𝐍⦃T⦄.
+#G #d #e #L1 #T1 #HT1 #L2 #HL12 #T2 #HT12
+@HT1 /3 width=3 by lsuby_cpy_trans/
+qed-. 
+
+lemma cny_sort: ∀G,L,d,e,k. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃⋆k⦄.
+#G #L #d #e #k #X #H elim (cpy_inv_sort1 … H) -H //
+qed.
+
+lemma cny_lref_free: ∀G,L,d,e,i. |L| ≤ i → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
+#G #L #d #e #i #Hi #X #H elim (cpy_inv_lref1 … H) -H // *
+#I #K #V #_ #_ #HLK #_ lapply (ldrop_fwd_length_lt2 … HLK) -HLK
+#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
+qed.
+
+lemma cny_lref_atom: ∀G,L,d,e,i. ⇩[i] L ≡ ⋆ → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
+#G #L #d #e #i #HL @cny_lref_free >(ldrop_fwd_length … HL) -HL //
+qed.
+
+lemma cny_lref_top: ∀G,L,d,e,i. d+e ≤ yinj i → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
+#G #L #d #e #i #Hdei #X #H elim (cpy_inv_lref1 … H) -H // *
+#I #K #V #_ #H elim (ylt_yle_false … H) //
+qed.
+
+lemma cny_lref_skip: ∀G,L,d,e,i. yinj i < d → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃#i⦄.
+#G #L #d #e #i #Hid #X #H elim (cpy_inv_lref1 … H) -H // *
+#I #K #V #H elim (ylt_yle_false … H) //
+qed.
+
+lemma cny_gref: ∀G,L,d,e,p. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃§p⦄.
+#G #L #d #e #p #X #H elim (cpy_inv_gref1 … H) -H //
+qed.
+
+lemma cny_bind: ∀G,L,V,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ →
+                ∀I,T. ⦃G, L.ⓑ{I}V⦄ ⊢ ▶[⫯d, e] 𝐍⦃T⦄ →
+                ∀a. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓑ{a,I}V.T⦄.
+#G #L #V1 #d #e #HV1 #I #T1 #HT1 #a #X #H
+elim (cpy_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+>(HV1 … HV12) -V2 >(HT1 … HT12) -T2 //
+qed.
+
+lemma cny_flat: ∀G,L,V,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃V⦄ →
+                ∀T. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T⦄ →
+                ∀I. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃ⓕ{I}V.T⦄.
+#G #L #V1 #d #e #HV1 #T1 #HT1 #I #X #H
+elim (cpy_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+>(HV1 … HV12) -V2 >(HT1 … HT12) -T2 //
+qed.
+
+lemma cny_narrow: ∀G,L,T,d1,e1. ⦃G, L⦄ ⊢ ▶[d1, e1] 𝐍⦃T⦄ →
+                  ∀d2,e2. d1 ≤ d2 → d2 + e2 ≤ d1 + e1 → ⦃G, L⦄ ⊢ ▶[d2, e2] 𝐍⦃T⦄.
+#G #L #T1 #d1 #e1 #HT1 #d2 #e2 #Hd12 #Hde21 #T2 #HT12
+@HT1 /2 width=5 by cpy_weak/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cny_lift.etc
new file mode 100644 (file)
index 0000000..213fa6a
--- /dev/null
@@ -0,0 +1,118 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/relocation/cny.ma".
+
+(* NORMAL TERMS FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION *****************)
+
+(* Properties on relocation *************************************************)
+
+lemma cny_lift_le: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
+                   ⇧[d, e] T ≡ U → dt + et ≤ d → ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hdetd #U2 #HU12
+elim (cpy_inv_lift1_le … HU12 … HLK … HTU1) // -L -Hdetd #T2 #HT12
+>(HT1 … HT12) -K /2 width=5 by lift_mono/
+qed-.
+
+lemma cny_lift_be: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
+                   ⇧[d, e] T ≡ U → dt ≤ d → yinj d ≤ dt + et → ⦃G, L⦄ ⊢ ▶[dt, et+e] 𝐍⦃U⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hdtd #Hddet #U2 #HU12
+elim (cpy_inv_lift1_be … HU12 … HLK … HTU1) /2 width=1 by monotonic_yle_plus_dx/ -L -Hdtd -Hddet #T2
+>yplus_minus_inj #HT12 >(HT1 … HT12) -K /2 width=5 by lift_mono/
+qed-.
+
+lemma cny_lift_ge: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄ → ⇩[s, d, e] L ≡ K →
+                   ⇧[d, e] T ≡ U → d ≤ dt → ⦃G, L⦄ ⊢ ▶[dt+e, et] 𝐍⦃U⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hddt #U2 #HU12
+elim (cpy_inv_lift1_ge … HU12 … HLK … HTU1) /2 width=1 by monotonic_yle_plus_dx/ -L -Hddt #T2
+>yplus_minus_inj #HT12 >(HT1 … HT12) -K /2 width=5 by lift_mono/
+qed-.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma cny_inv_lift_le: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
+                       ⇧[d, e] T ≡ U → dt + et ≤ d → ⦃G, K⦄ ⊢ ▶[dt, et] 𝐍⦃T⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdetd #T2 #HT12
+elim (lift_total T2 d e) #U2 #HTU2
+lapply (cpy_lift_le … HT12 … HLK … HTU1 … HTU2 ?) // -K -Hdetd #HU12
+lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
+qed-.
+
+lemma cny_inv_lift_be: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
+                       ⇧[d, e] T ≡ U → dt ≤ d → yinj d + e ≤ dt + et → ⦃G, K⦄ ⊢ ▶[dt, et-e] 𝐍⦃T⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdtd #Hdedet #T2 #HT12
+lapply (yle_fwd_plus_ge_inj … Hdedet) // #Heet
+elim (yle_inv_plus_inj2 … Hdedet) -Hdedet #Hddete #Hedet
+elim (lift_total T2 d e) #U2 #HTU2
+lapply (cpy_lift_be … HT12 … HLK … HTU1 … HTU2 ? ?) // [ >yplus_minus_assoc_inj // ] -K -Hdtd -Hddete
+>ymax_pre_sn // -Heet #HU12
+lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
+qed-.
+
+lemma cny_inv_lift_ge: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
+                       ⇧[d, e] T ≡ U → yinj d + e ≤ dt → ⦃G, K⦄ ⊢ ▶[dt-e, et] 𝐍⦃T⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hdedt #T2 #HT12
+elim (yle_inv_plus_inj2 … Hdedt) -Hdedt #Hddte #Hedt
+elim (lift_total T2 d e) #U2 #HTU2
+lapply (cpy_lift_ge … HT12 … HLK … HTU1 … HTU2 ?) // -K -Hddte
+>ymax_pre_sn // -Hedt #HU12
+lapply (HU1 … HU12) -L /2 width=5 by lift_inj/
+qed-.
+
+(* Advanced inversion lemmas on relocation **********************************)
+
+lemma cny_inv_lift_ge_up: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄ → ⇩[s, d, e] L ≡ K →
+                          ⇧[d, e] T ≡ U → d ≤ dt → dt ≤ yinj d + e → yinj d + e ≤ dt + et →
+                          ⦃G, K⦄ ⊢ ▶[d, dt + et - (yinj d + e)] 𝐍⦃T⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HU1 #HLK #HTU1 #Hddt #Hdtde #Hdedet
+lapply (cny_narrow … HU1 (d+e) (dt+et-(d+e)) ? ?) -HU1 [ >ymax_pre_sn_comm ] // #HU1
+lapply (cny_inv_lift_ge … HU1 … HLK … HTU1 ?) // -L -U1
+>yplus_minus_inj //
+qed-.
+
+lemma cny_inv_lift_subst: ∀G,L,K,V,W,i,d,e. d ≤ yinj i → i < d + e →
+                          ⇩[i+1] L ≡ K → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃W⦄ →
+                          ⇧[O, i+1] V ≡ W → ⦃G, K⦄ ⊢ ▶[O, ⫰(d+e-i)] 𝐍⦃V⦄.
+#G #L #K #V #W #i #d #e #Hdi #Hide #HLK #HW #HVW
+lapply (cny_inv_lift_ge_up … HW … HLK … HVW ? ? ?) //
+>yplus_O1 <yplus_inj >yplus_SO2
+[ /2 width=1 by ylt_fwd_le_succ1/
+| /2 width=3 by yle_trans/
+| >yminus_succ2 //
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+(* Note: this should be applicable in a forward manner *)
+lemma cny_lift_ge_up: ∀G,L,K,T,U,s,d,dt,e,et. ⦃G, K⦄ ⊢ ▶[yinj d, dt + et - (yinj d + yinj e)] 𝐍⦃T⦄ →
+                      ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U →
+                      yinj d ≤ dt → dt ≤ yinj d + yinj e → yinj d + yinj e ≤ dt + et →
+                      ⦃G, L⦄ ⊢ ▶[dt, et] 𝐍⦃U⦄.
+#G #L #K #T1 #U1 #s #d #dt #e #et #HT1 #HLK #HTU1 #Hddt #Hdtde #Hdedet
+lapply (cny_lift_be … HT1 … HLK … HTU1 ? ?) // -K -T1
+#HU1 @(cny_narrow … HU1) -HU1 // (**) (* auto fails *)
+qed-.
+
+lemma cny_lift_subst: ∀G,L,K,V,W,i,d,e. d ≤ yinj i → i < d + e →
+                      ⇩[i+1] L ≡ K → ⦃G, K⦄ ⊢ ▶[O, ⫰(d+e-i)] 𝐍⦃V⦄ →
+                      ⇧[O, i+1] V ≡ W → ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃W⦄.
+#G #L #K #V #W #i #d #e #Hdi #Hide #HLK #HV #HVW
+@(cny_lift_ge_up … HLK … HVW) // >yplus_O1 <yplus_inj >yplus_SO2
+[ >yminus_succ2 //
+| /2 width=3 by yle_trans/
+| /2 width=1 by ylt_fwd_le_succ1/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpx_cpzs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpx_cpzs.etc
new file mode 100644 (file)
index 0000000..6c208d5
--- /dev/null
@@ -0,0 +1,73 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/delta_equivalence/cpzs.ma".
+include "basic_2/reduction/cpx.ma".
+
+fact destruct_tsort_tsort: ∀k1,k2. ⋆k1 = ⋆k2 → k1 = k2.
+#k1 #k2 #H destruct //
+qed-.
+
+axiom cpzs_inv_subst: ∀I,G,L,K,V1,V2,W2,i.
+                      ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ W2 →
+                      ⦃G, L⦄ ⊢ #i ◆*[O, ∞] W2 → ⦃G, K⦄⊢ V1 ◆*[O, ∞] V2.
+
+axiom cpzs_subst: ∀I,G,L,K,V1,V2,W2,i.
+                  ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ W2 →
+                  ⦃G, K⦄⊢ V1 ◆*[O, ∞] V2 → ⦃G, L⦄ ⊢ #i ◆*[O, ∞] W2.
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
+
+(* Forward lemmas on delta-equivalence for terms ****************************)
+
+lemma cpx_fwd_cpys_cpzs: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 →
+                         ∀d,e. ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2 ↔ ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2.
+#h #g #G #L #T1 #T2 #H elim H -G -L -T1 -T2
+[ /2 width=1 by conj/
+| #G #L #k #l #_ #d #e @conj #H lapply (next_lt h k)
+  [ <(cpzs_inv_sort … H)
+  | lapply (cpys_inv_sort1 … H) -H #H >(destruct_tsort_tsort … H)
+  ] -H #H elim (lt_refl_false … H)
+| #I #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #IHV12 #d #e @conj #H
+(*  
+  [ @(cpys_subst … HLK … HVW2) // >yminus_Y_inj /3 width=7 by cpzs_inv_subst/
+  | elim (cpys_inv_lref1_ldrop … H … HLK … HVW2) -H /3 width=7 by cpzs_subst/
+  ]
+*)
+| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #d #e
+  elim (IHV12 d e) -IHV12 elim (IHT12 (⫯d) e) -IHT12
+  #IHTdx #IHTsn #IHVdx #IHVsn @conj #H
+  [ elim (cpzs_inv_bind … H) -H /3 width=1 by cpys_bind/
+  | elim (cpys_inv_bind1 … H) -H #X1 #X2 #H1 #H2 #H destruct /3 width=1 by cpzs_bind/
+  ]
+| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #d #e
+  elim (IHV12 d e) -IHV12 elim (IHT12 (d) e) -IHT12
+  #IHTdx #IHTsn #IHVdx #IHVsn @conj #H
+  [ elim (cpzs_inv_flat … H) -H /3 width=1 by cpys_flat/
+  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct /3 width=1 by cpzs_flat/
+  ]
+| #G #L #V #U1 #U2 #T2 #_ #HTU2 #_ #d #e @conj #H
+| #G #L #V1 #T1 #T2 #_ #_ #d #e @conj #H
+| #G #L #V1 #V2 #T1 #HV12 #_ #d #e @conj #H
+| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #d #e @conj #H
+  [ elim (cpzs_inv_flat_bind … H)
+  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct
+  ]
+| #a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #d #e @conj #H
+  [ elim (cpzs_inv_flat_bind … H)
+  | elim (cpys_inv_flat1 … H) -H #X1 #X2 #H1 #H2 #H destruct
+  ]
+]
+    
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye.etc
new file mode 100644 (file)
index 0000000..71e06ea
--- /dev/null
@@ -0,0 +1,89 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/psubsteval_6.ma".
+include "basic_2/relocation/cny.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
+
+definition cpye: ynat → ynat → relation4 genv lenv term term ≝
+                 λd,e,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 ∧ ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T2⦄.
+
+interpretation "evaluation for context-sensitive extended substitution (term)"
+   'PSubstEval G L T1 T2 d e = (cpye d e G L T1 T2).
+
+(* Basic_properties *********************************************************)
+
+(* Note: this should go in subconversion *)
+lemma leqy_cpye_trans: ∀G,L2,T1,T2,d,e. ⦃G, L2⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ →
+                       ∀L1. L1 ⊑×[d, e] L2 → L2 ⊑×[d, e] L1 → ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
+#G #L2 #T1 #T2 #d #e *
+/4 width=8 by lsuby_cpys_trans, lsuby_cny_conf, conj/
+qed-.
+
+lemma cpye_sort: ∀G,L,d,e,k. ⦃G, L⦄ ⊢ ⋆k ▶*[d, e] 𝐍⦃⋆k⦄.
+/3 width=5 by cny_sort, conj/ qed.
+
+lemma cpye_free: ∀G,L,d,e,i. |L| ≤ i → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
+/3 width=6 by cny_lref_free, conj/ qed.
+
+lemma cpye_top: ∀G,L,d,e,i. d + e ≤ yinj i → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
+/3 width=6 by cny_lref_top, conj/ qed.
+
+lemma cpye_skip: ∀G,L,d,e,i. yinj i < d → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃#i⦄.
+/3 width=6 by cny_lref_skip, conj/ qed.
+
+lemma cpye_gref: ∀G,L,d,e,p. ⦃G, L⦄ ⊢ §p ▶*[d, e] 𝐍⦃§p⦄.
+/3 width=5 by cny_gref, conj/ qed.
+
+lemma cpye_bind: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
+                 ∀I,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ →
+                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶*[d, e] 𝐍⦃ⓑ{a,I}V2.T2⦄.
+#G #L #V1 #V2 #d #e * #HV12 #HV2 #I #T1 #T2 *
+/5 width=8 by cpys_bind, cny_bind, lsuby_cny_conf, lsuby_succ, conj/
+qed.
+
+lemma cpye_flat: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
+                 ∀T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ →
+                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ▶*[d, e] 𝐍⦃ⓕ{I}V2.T2⦄.
+#G #L #V1 #V2 #d #e * #HV12 #HV2 #T1 #T2 *
+/3 width=7 by cpys_flat, cny_flat, conj/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma cpye_inv_sort1: ∀G,L,X,d,e,k. ⦃G, L⦄ ⊢ ⋆k ▶*[d, e] 𝐍⦃X⦄ → X = ⋆k.
+#G #L #X #d #e #k * /2 width=5 by cpys_inv_sort1/
+qed-.
+
+lemma cpye_inv_gref1: ∀G,L,X,d,e,p. ⦃G, L⦄ ⊢ §p ▶*[d, e] 𝐍⦃X⦄ → X = §p.
+#G #L #X #d #e #p * /2 width=5 by cpys_inv_gref1/
+qed-.
+
+lemma cpye_inv_bind1: ∀a,I,G,L,V1,T1,X,d,e. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶*[d, e] 𝐍⦃X⦄ →
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ & ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ &
+                               X = ⓑ{a,I}V2.T2.
+#a #I #G #L #V1 #T1 #X #d #e * #H1 #H2 elim (cpys_inv_bind1 … H1) -H1
+#V2 #T2 #HV12 #HT12 #H destruct elim (cny_inv_bind … H2) -H2
+/5 width=8 by lsuby_cny_conf, lsuby_succ, ex3_2_intro, conj/
+qed-.
+
+lemma cpye_inv_flat1: ∀I,G,L,V1,T1,X,d,e. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ▶*[d, e] 𝐍⦃X⦄ →
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ & ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ &
+                               X = ⓕ{I}V2.T2.
+#I #G #L #V1 #T1 #X #d #e * #H1 #H2 elim (cpys_inv_flat1 … H1) -H1
+#V2 #T2 #HV12 #HT12 #H destruct elim (cny_inv_flat … H2) -H2
+/3 width=5 by ex3_2_intro, conj/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_alt.etc
new file mode 100644 (file)
index 0000000..a9dc53c
--- /dev/null
@@ -0,0 +1,89 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/psubstevalalt_6.ma".
+include "basic_2/substitution/cpye_lift.ma".
+
+(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
+
+(* Note: alternative definition of cpye *)
+inductive cpyea: ynat → ynat → relation4 genv lenv term term ≝
+| cpyea_sort : ∀G,L,d,e,k. cpyea d e G L (⋆k) (⋆k)
+| cpyea_free : ∀G,L,d,e,i. |L| ≤ i → cpyea d e G L (#i) (#i)
+| cpyea_top  : ∀G,L,d,e,i. d + e ≤ yinj i → cpyea d e G L (#i) (#i)
+| cpyea_skip : ∀G,L,d,e,i. yinj i < d → cpyea d e G L (#i) (#i)
+| cpyea_subst: ∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → yinj i < d+e →
+               ⇩[i] L ≡ K.ⓑ{I}V1 → cpyea (yinj 0) (⫰(d+e-yinj i)) G K V1 V2 →
+               ⇧[0, i+1] V2 ≡ W2 → cpyea d e G L (#i) W2
+| cpyea_gref : ∀G,L,d,e,p. cpyea d e G L (§p) (§p)
+| cpyea_bind : ∀a,I,G,L,V1,V2,T1,T2,d,e.
+               cpyea d e G L V1 V2 → cpyea (⫯d) e G (L.ⓑ{I}V1) T1 T2 →
+               cpyea d e G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
+| cpyea_flat : ∀I,G,L,V1,V2,T1,T2,d,e.
+               cpyea d e G L V1 V2 → cpyea d e G L T1 T2 →
+               cpyea d e G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
+.
+
+interpretation
+   "evaluation for context-sensitive extended substitution (term) alternative"
+   'PSubstEvalAlt G L T1 T2 d e = (cpyea d e G L T1 T2).
+
+(* Main properties **********************************************************)
+
+theorem cpye_cpyea: ∀G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → ⦃G, L⦄ ⊢ T1 ▶▶*[d, e] 𝐍⦃T2⦄.
+#G #L #T1 @(fqup_wf_ind_eq … G L T1) -G -L -T1
+#Z #Y #X #IH #G #L * *
+[ #k #_ #_ #_ #T2 #d #e #H -X -Y -Z >(cpye_inv_sort1 … H) -H //
+| #i #HG #HL #HT #T2 #d #e #H destruct
+  elim (cpye_inv_lref1 … H) -H *
+  /4 width=7 by cpyea_subst, cpyea_free, cpyea_top, cpyea_skip, fqup_lref/
+| #p #_ #_ #_ #T2 #d #e #H -X -Y -Z >(cpye_inv_gref1 … H) -H //
+| #a #I #V1 #T1 #HG #HL #HT #T #d #e #H destruct
+  elim (cpye_inv_bind1 … H) -H /3 width=1 by cpyea_bind/
+| #I #V1 #T1 #HG #HL #HT #T #d #e #H destruct
+  elim (cpye_inv_flat1 … H) -H /3 width=1 by cpyea_flat/
+]
+qed.
+
+(* Main inversion properties ************************************************)
+
+theorem cpyea_inv_cpye: ∀G,L,T1,T2,d,e. ⦃G, L⦄ ⊢ T1 ▶▶*[d, e] 𝐍⦃T2⦄ → ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
+#G #L #T1 #T2 #d #e #H elim H -G -L -T1 -T2 -d -e
+/2 width=7 by cpye_subst, cpye_flat, cpye_bind, cpye_skip, cpye_top, cpye_free/
+qed-.
+
+(* Advanced eliminators *****************************************************)
+
+lemma cpye_ind_alt: ∀R:ynat→ynat→relation4 genv lenv term term.
+                    (∀G,L,d,e,k. R d e G L (⋆k) (⋆k)) →
+                    (∀G,L,d,e,i. |L| ≤ i → R d e G L (#i) (#i)) →
+                    (∀G,L,d,e,i. d + e ≤ yinj i → R d e G L (#i) (#i)) →
+                    (∀G,L,d,e,i. yinj i < d → R d e G L (#i) (#i)) →
+                    (∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → yinj i < d + e →
+                     ⇩[i] L ≡ K.ⓑ{I}V1 → ⦃G, K⦄ ⊢ V1 ▶*[yinj O, ⫰(d+e-yinj i)] 𝐍⦃V2⦄ →
+                     ⇧[O, i+1] V2 ≡ W2 → R (yinj O) (⫰(d+e-yinj i)) G K V1 V2 → R d e G L (#i) W2
+                    ) →
+                    (∀G,L,d,e,p. R d e G L (§p) (§p)) →
+                    (∀a,I,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
+                     ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶*[⫯d, e] 𝐍⦃T2⦄ → R d e G L V1 V2 →
+                     R (⫯d) e G (L.ⓑ{I}V1) T1 T2 → R d e G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
+                    ) →
+                    (∀I,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ V1 ▶*[d, e] 𝐍⦃V2⦄ →
+                     ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → R d e G L V1 V2 →
+                     R d e G L T1 T2 → R d e G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
+                    ) →
+                    ∀d,e,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄ → R d e G L T1 T2.
+#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8 #d #e #G #L #T1 #T2 #H elim (cpye_cpyea … H) -G -L -T1 -T2 -d -e
+/3 width=8 by cpyea_inv_cpye/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_cpye.etc
new file mode 100644 (file)
index 0000000..42bd19b
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_cny.ma".
+include "basic_2/substitution/cpys_cpys.ma".
+include "basic_2/substitution/cpye.ma".
+
+(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
+
+(* Advanced properties ******************************************************)
+
+lemma cpye_cpys_conf: ∀G,L,T,T2,d,e. ⦃G, L⦄ ⊢ T ▶*[d, e] 𝐍⦃T2⦄ →
+                      ∀T1. ⦃G, L⦄ ⊢ T ▶*[d, e] T1 → ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2.
+#G #L #T #T2 #d #e * #H2 #HT2 #T1 #H1 elim (cpys_conf_eq … H1 … H2) -T
+#T0 #HT10 #HT20 >(cpys_inv_cny1 … HT2 … HT20) -T2 //
+qed-.
+   
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpye_lift.etc
new file mode 100644 (file)
index 0000000..3c0abe6
--- /dev/null
@@ -0,0 +1,169 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cny_lift.ma".
+include "basic_2/substitution/fqup.ma".
+include "basic_2/substitution/cpys_lift.ma".
+include "basic_2/substitution/cpye.ma".
+
+(* EVALUATION FOR CONTEXT-SENSITIVE EXTENDED SUBSTITUTION ON TERMS **********)
+
+(* Advanced properties ******************************************************)
+
+lemma cpye_subst: ∀I,G,L,K,V1,V2,W2,i,d,e. d ≤ yinj i → i < d + e →
+                  ⇩[i] L ≡ K.ⓑ{I}V1 → ⦃G, K⦄ ⊢ V1 ▶*[O, ⫰(d+e-i)] 𝐍⦃V2⦄ →
+                  ⇧[O, i+1] V2 ≡ W2 → ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃W2⦄.
+#I #G #L #K #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK *
+/4 width=13 by cpys_subst, cny_lift_subst, ldrop_fwd_drop2, conj/
+qed.
+
+lemma cpye_total: ∀G,L,T1,d,e. ∃T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T2⦄.
+#G #L #T1 @(fqup_wf_ind_eq … G L T1) -G -L -T1
+#Z #Y #X #IH #G #L * *
+[ #k #HG #HL #HT #d #e destruct -IH /2 width=2 by ex_intro/
+| #i #HG #HL #HT #d #e destruct
+  elim (ylt_split i d) /3 width=2 by cpye_skip, ex_intro/
+  elim (ylt_split i (d+e)) /3 width=2 by cpye_top, ex_intro/
+  elim (lt_or_ge i (|L|)) /3 width=2 by cpye_free, ex_intro/
+  #Hi #Hide #Hdi elim (ldrop_O1_lt L i) // -Hi
+  #I #K #V1 #HLK elim (IH G K V1 … 0 (⫰(d+e-i))) -IH /2 width=2 by fqup_lref/
+  #V2 elim (lift_total V2 0 (i+1)) /3 width=8 by ex_intro, cpye_subst/
+| #p #HG #HL #HT #d #e destruct -IH /2 width=2 by ex_intro/
+| #a #I #V1 #T1 #HG #HL #HT #d #e destruct
+  elim (IH G L V1 … d e) // elim (IH G (L.ⓑ{I}V1) T1 … (⫯d) e) //
+  /3 width=2 by cpye_bind, ex_intro/
+| #I #V1 #T1 #HG #HL #HT #d #e destruct
+  elim (IH G L V1 … d e) // elim (IH G L T1 … d e) //
+  /3 width=2 by cpye_flat, ex_intro/
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cpye_inv_lref1: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
+                      ∨∨ |L| ≤ i ∧ T2 = #i
+                       | d + e ≤ yinj i ∧ T2 = #i
+                       | yinj i < d ∧ T2 = #i
+                       | ∃∃I,K,V1,V2. d ≤ yinj i & yinj i < d + e &
+                                      ⇩[i] L ≡ K.ⓑ{I}V1 &
+                                      ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
+                                      ⇧[O, i+1] V2 ≡ T2.
+#G #L #T2 #i #d #e * #H1 #H2 elim (cpys_inv_lref1 … H1) -H1
+[ #H destruct elim (cny_inv_lref … H2) -H2
+  /3 width=1 by or4_intro0, or4_intro1, or4_intro2, conj/
+| * #I #K #V1 #V2 #Hdi #Hide #HLK #HV12 #HVT2
+    @or4_intro3 @(ex5_4_intro … HLK … HVT2) (**) (* explicit constructor *)
+    /4 width=13 by cny_inv_lift_subst, ldrop_fwd_drop2, conj/
+]
+qed-.
+
+lemma cpye_inv_lref1_free: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
+                           (∨∨ |L| ≤ i | d + e ≤ yinj i | yinj i < d) → T2 = #i.
+#G #L #T2 #d #e #i #H * elim (cpye_inv_lref1 … H) -H * //
+#I #K #V1 #V2 #Hdi #Hide #HLK #_ #_ #H
+[ elim (lt_refl_false i) -d
+  @(lt_to_le_to_lt … H) -H /2 width=5 by ldrop_fwd_length_lt2/ (**) (* full auto slow: 19s *)
+]
+elim (ylt_yle_false … H) //
+qed-.
+
+lemma cpye_inv_lref1_lget: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
+                           ∀I,K,V1. ⇩[i] L ≡ K.ⓑ{I}V1 →
+                           ∨∨ d + e ≤ yinj i ∧ T2 = #i
+                            | yinj i < d ∧ T2 = #i
+                            | ∃∃V2. d ≤ yinj i & yinj i < d + e &
+                                    ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
+                                    ⇧[O, i+1] V2 ≡ T2.
+#G #L #T2 #d #e #i #H #I #K #V1 #HLK elim (cpye_inv_lref1 … H) -H *
+[ #H elim (lt_refl_false i) -T2 -d
+  @(lt_to_le_to_lt … H) -H /2 width=5 by ldrop_fwd_length_lt2/
+| /3 width=1 by or3_intro0, conj/
+| /3 width=1 by or3_intro1, conj/
+| #Z #Y #X1 #X2 #Hdi #Hide #HLY #HX12 #HXT2
+  lapply (ldrop_mono … HLY … HLK) -HLY -HLK #H destruct
+  /3 width=3 by or3_intro2, ex4_intro/
+]
+qed-.
+
+lemma cpye_inv_lref1_subst_ex: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
+                               ∀I,K,V1. d ≤ yinj i → yinj i < d + e →
+                               ⇩[i] L ≡ K.ⓑ{I}V1 →
+                               ∃∃V2. ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄ &
+                                     ⇧[O, i+1] V2 ≡ T2.
+#G #L #T2 #d #e #i #H #I #K #V1 #Hdi #Hide #HLK
+elim (cpye_inv_lref1_lget … H … HLK) -H * /2 width=3 by ex2_intro/
+#H elim (ylt_yle_false … H) //
+qed-.
+
+lemma cpye_inv_lref1_subst: ∀G,L,T2,d,e,i. ⦃G, L⦄ ⊢ #i ▶*[d, e] 𝐍⦃T2⦄ →
+                            ∀I,K,V1,V2. d ≤ yinj i → yinj i < d + e →
+                            ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[O, i+1] V2 ≡ T2 →
+                            ⦃G, K⦄ ⊢ V1 ▶*[yinj 0, ⫰(d+e-yinj i)]  𝐍⦃V2⦄.
+#G #L #T2 #d #e #i #H #I #K #V1 #V2 #Hdi #Hide #HLK #HVT2
+elim (cpye_inv_lref1_subst_ex … H … HLK) -H -HLK //
+#X2 #H0 #HXT2 lapply (lift_inj … HXT2 … HVT2) -HXT2 -HVT2 #H destruct //
+qed-.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma cpye_inv_lift1_le: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
+                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         dt + et ≤ d →
+                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt, et] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
+#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdetd
+elim (cpys_inv_lift1_le … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
+lapply (cny_inv_lift_le … HU2 … HLK … HTU2 ?) -L
+/3 width=3 by ex2_intro, conj/
+qed-.
+
+lemma cpye_inv_lift1_be: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
+                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         dt ≤ d → yinj d + e ≤ dt + et →
+                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt, et - e] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
+#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdtd #Hdedet
+elim (cpys_inv_lift1_be … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
+lapply (cny_inv_lift_be … HU2 … HLK … HTU2 ? ?) -L
+/3 width=3 by ex2_intro, conj/
+qed-.
+
+lemma cpye_inv_lift1_ge: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
+                         ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         yinj d + e ≤ dt →
+                         ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[dt - e, et] 𝐍⦃T2⦄ & ⇧[d, e] T2 ≡ U2.
+#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hdedt
+elim (cpys_inv_lift1_ge … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
+lapply (cny_inv_lift_ge … HU2 … HLK … HTU2 ?) -L
+/3 width=3 by ex2_intro, conj/
+qed-.
+
+lemma cpye_inv_lift1_ge_up: ∀G,L,U1,U2,dt,et. ⦃G, L⦄ ⊢ U1 ▶*[dt, et] 𝐍⦃U2⦄ →
+                            ∀K,s,d,e. ⇩[s, d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                            d ≤ dt → dt ≤ yinj d + e → yinj d + e ≤ dt + et →
+                            ∃∃T2. ⦃G, K⦄ ⊢ T1 ▶*[d, dt + et - (yinj d + e)] 𝐍⦃T2⦄ &
+                                 ⇧[d, e] T2 ≡ U2.
+#G #L #U1 #U2 #dt #et * #HU12 #HU2 #K #s #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
+elim (cpys_inv_lift1_ge_up … HU12 … HLK … HTU1) -U1 // #T2 #HT12 #HTU2
+lapply (cny_inv_lift_ge_up … HU2 … HLK … HTU2 ? ? ?) -L
+/3 width=3 by ex2_intro, conj/
+qed-.
+
+lemma cpye_inv_lift1_subst: ∀G,L,W1,W2,d,e. ⦃G, L⦄ ⊢ W1 ▶*[d, e] 𝐍⦃W2⦄ →
+                            ∀K,V1,i. ⇩[i+1] L ≡ K → ⇧[O, i+1] V1 ≡ W1 →
+                            d ≤ yinj i → i < d + e →
+                            ∃∃V2.  ⦃G, K⦄ ⊢ V1 ▶*[O, ⫰(d+e-i)] 𝐍⦃V2⦄ & ⇧[O, i+1] V2 ≡ W2.
+#G #L #W1 #W2 #d #e * #HW12 #HW2 #K #V1 #i #HLK #HVW1 #Hdi #Hide
+elim (cpys_inv_lift1_subst … HW12 … HLK … HVW1) -W1 // #V2 #HV12 #HVW2
+lapply (cny_inv_lift_subst … HLK HW2 HVW2) -L
+/3 width=3 by ex2_intro, conj/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpys_cny.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpys_cny.etc
new file mode 100644 (file)
index 0000000..1499cee
--- /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/relocation/cny.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
+
+(* Inversion lemmas on normality for extended substitution ******************)
+
+lemma cpys_inv_cny1: ∀G,L,T1,d,e. ⦃G, L⦄ ⊢ ▶[d, e] 𝐍⦃T1⦄ →
+                     ∀T2. ⦃G, L⦄ ⊢ T1 ▶*[d, e] T2 → T1 = T2.
+#G #L #T1 #d #e #HT1 #T2 #H @(cpys_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT1 destruct <(HT1 … HT2) -T //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpzs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/cpzs.etc
new file mode 100644 (file)
index 0000000..0fada97
--- /dev/null
@@ -0,0 +1,83 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/pdeltaconvstar_6.ma".
+include "basic_2/substitution/cpye_lift.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED DELTA-EQUIVALENCE FOR TERMS *******************)
+
+definition cpzs: ynat → ynat → relation4 genv lenv term term ≝
+                 λd,e,G,L,T1,T2.
+                 ∃∃T. ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T⦄ & ⦃G, L⦄ ⊢ T2 ▶*[d, e] 𝐍⦃T⦄.
+
+interpretation "context-sensitive extended delta-equivalence (term)"
+   'PDeltaConvStar G L T1 d e T2 = (cpzs d e G L T1 T2).
+
+(* Basic properties **********************************************************)
+
+lemma cpye_div: ∀G,L,T1,T,d,e.  ⦃G, L⦄ ⊢ T1 ▶*[d, e] 𝐍⦃T⦄ →
+                ∀T2. ⦃G, L⦄ ⊢ T2 ▶*[d, e] 𝐍⦃T⦄ → ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2.
+/2 width=3 by ex2_intro/ qed.
+
+lemma cpzs_refl: ∀G,L,d,e. reflexive … (cpzs d e G L).
+#G #L #d #e #T elim (cpye_total G L T d e) /2 width=3 by cpye_div/
+qed.
+
+lemma cpzs_bind: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 →
+                 ∀I,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ◆*[⫯d, e] T2 →
+                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ◆*[d, e] ⓑ{a,I}V2.T2.
+#G #L #V1 #V2 #d #e * #V #HV1 #HV2 #I #T1 #T2 *
+/5 width=10 by cpye_div, cpye_bind, leqy_cpye_trans, cny_bind, lsuby_succ/
+qed.
+
+lemma cpzs_flat: ∀G,L,V1,V2,d,e. ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 →
+                 ∀T1,T2. ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2 →
+                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ◆*[d, e] ⓕ{I}V2.T2.
+#G #L #V1 #V2 #d #e * #V #HV1 #HV2 #T1 #T2 *
+/3 width=5 by cpye_div, cpye_flat, cny_flat/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma cpzs_inv_sort: ∀G,L,d,e,k1,k2. ⦃G, L⦄ ⊢ ⋆k1 ◆*[d, e] ⋆k2 → k1 = k2.
+#G #L #d #e #k1 #k2 * #X #H1 #H2
+lapply (cpye_inv_sort1 … H1) -H1 #H1
+lapply (cpye_inv_sort1 … H2) -H2 #H2
+destruct //
+qed-.
+
+lemma cpzs_inv_bind: ∀a1,a2,I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓑ{a1,I1}V1.T1 ◆*[d, e] ⓑ{a2,I2}V2.T2 →
+                     ∧∧ a1 = a2 & I1 = I2
+                      & ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 & ⦃G, L.ⓑ{I1}V1⦄ ⊢ T1 ◆*[⫯d, e] T2.
+#a1 #a2 #I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
+elim (cpye_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
+elim (cpye_inv_bind1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
+destruct /5 width=8 by cpye_div, leqy_cpye_trans, lsuby_succ, and4_intro/
+qed-.
+
+lemma cpzs_inv_flat: ∀I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓕ{I1}V1.T1 ◆*[d, e] ⓕ{I2}V2.T2 →
+                     ∧∧ I1 = I2
+                      & ⦃G, L⦄ ⊢ V1 ◆*[d, e] V2 & ⦃G, L⦄ ⊢ T1 ◆*[d, e] T2.
+#I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
+elim (cpye_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
+elim (cpye_inv_flat1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
+destruct /3 width=3 by cpye_div, and3_intro/
+qed-.
+
+lemma cpzs_inv_flat_bind: ∀a2,I1,I2,G,L,V1,V2,T1,T2,d,e. ⦃G, L⦄ ⊢ ⓕ{I1}V1.T1 ◆*[d, e] ⓑ{a2,I2}V2.T2 → ⊥.
+#a2 #I1 #I2 #G #L #V1 #V2 #T1 #T2 #d #e * #X #H1 #H2
+elim (cpye_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H1
+elim (cpye_inv_bind1 … H2) -H2 #W2 #U2 #HW12 #HU12 #H2
+destruct
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lleq_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lleq_cpye.etc
new file mode 100644 (file)
index 0000000..e6890e6
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cpye_lift.ma".
+include "basic_2/substitution/lleq_alt.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+(* Forward lemmas on evaluation for extended substitution *******************)
+
+lemma lleq_fwd_cpye: ∀L1,L2,T,d. L1 ⋕[T, d] L2 → ∀G,T1. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] 𝐍⦃T1⦄ →
+                     ∀T2. ⦃G, L2⦄ ⊢ T ▶*[d, ∞] 𝐍⦃T2⦄ → T1 = T2.
+#L1 #L2 #T #d #H @(lleq_ind_alt … H) -L1 -L2 -T -d
+[ #L1 #L2 #d #k #_ #G #T1 #H1 #T2 #H2
+  >(cpye_inv_sort1 … H1) -H1 >(cpye_inv_sort1 … H2) -H2 //
+| #L1 #L2 #d #i #_ #Hid #G #T1 #H1 #T2 #H2
+  >(cpye_inv_lref1_free … H1) -H1 [ >(cpye_inv_lref1_free … H2) -H2 ]
+  /2 width=1 by or3_intro2/
+| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 #_ #IHV #G #T1 #H1 #T2 #H2
+  elim (cpye_inv_lref1_subst_ex … H1 … HLK1) -H1 -HLK1 //
+  elim (cpye_inv_lref1_subst_ex … H2 … HLK2) -H2 -HLK2 //
+  >yminus_Y_inj #V2 #HV2 #HVT2 #V1 #HV1 #HVT1
+  lapply (IHV … HV1 … HV2) -IHV -HV1 -HV2 #H destruct /2 width=5 by lift_mono/
+| #L1 #L2 #d #i #_ #HL1 #HL2 #G #T1 #H1 #T2 #H2
+  >(cpye_inv_lref1_free … H1) -H1 [ >(cpye_inv_lref1_free … H2) -H2 ]
+  /2 width=1 by or3_intro0/
+| #L1 #L2 #d #p #_ #G #T1 #H1 #T2 #H2
+  >(cpye_inv_gref1 … H1) -H1 >(cpye_inv_gref1 … H2) -H2 //
+| #a #I #L1 #L2 #V #T #d #_ #_ #IHV #IHT #G #X1 #H1 #X2 #H2
+  elim (cpye_inv_bind1 … H1) -H1 #V1 #T1 #HV1 #HT1 #H destruct
+  elim (cpye_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+  /3 width=3 by eq_f2/
+| #I #L1 #L2 #V #T #d #_ #_ #IHV #IHT #G #X1 #H1 #X2 #H2
+  elim (cpye_inv_flat1 … H1) -H1 #V1 #T1 #HV1 #HT1 #H destruct
+  elim (cpye_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+  /3 width=3 by eq_f2/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpx_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpx_cpye.etc
new file mode 100644 (file)
index 0000000..48816c8
--- /dev/null
@@ -0,0 +1,44 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cpye_cpye.ma".
+include "basic_2/reduction/lpx_cpys.ma".
+
+axiom cpx_cpys_conf_lpx: ∀h,g,G,d,e.
+                         ∀L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡[h, g] T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[h, g] L1 →
+                         ∀T2. ⦃G, L0⦄ ⊢ T0 ▶*[d, e] T2 →
+                         ∃∃T. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] T & ⦃G, L0⦄ ⊢ T2 ➡[h, g] T.
+
+(* SN EXTENDED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS *********************)
+
+(* Forward lemmas on evaluation for extended substitution *******************)
+
+lemma cpx_cpys_cpye_fwd_lpx: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                             ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
+                             ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] U1 →
+                             ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
+                             ⦃G, L1⦄ ⊢ U1 ➡[h, g] U2.
+#h #g #G #L1 #T1 #T2 #HT12 #L2 #HL12 #U1 #d #e #HTU1
+elim (cpx_cpys_conf_lpx … HT12 … HL12 … HTU1) -T1
+/3 width=9 by cpx_cpys_trans_lpx, cpye_cpys_conf/
+qed-.
+
+lemma cpx_cpye_fwd_lpx: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                        ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 →
+                        ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃U1⦄ →
+                        ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
+                        ⦃G, L1⦄ ⊢ U1 ➡[h, g] U2.
+#h #g #G #L1 #T1 #T2 #HT12 #L2 #HL12 #U1 #d #e *
+/2 width=9 by cpx_cpys_cpye_fwd_lpx/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpxs_cpye.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/lpxs_cpye.etc
new file mode 100644 (file)
index 0000000..a6f0f86
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cpye_lift.ma".
+include "basic_2/reduction/lpx_cpye.ma".
+include "basic_2/computation/cpxs_cpxs.ma".
+include "basic_2/computation/lpxs.ma".
+
+(* SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *******************)
+
+(* Forward lemmas on evaluation for extended substitution *******************)
+
+lemma cpx_cpye_fwd_lpxs: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
+                         ∀T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                         ∀U1,d,e. ⦃G, L1⦄ ⊢ T1 ▶*[d, e] 𝐍⦃U1⦄ →
+                         ∀U2. ⦃G, L2⦄ ⊢ T2 ▶*[d, e] 𝐍⦃U2⦄ →
+                         ⦃G, L1⦄ ⊢ U1 ➡*[h, g] U2.
+#h #g #G #L1 #L2 #H @(lpxs_ind_dx … H) -L1
+[ /3 width=9 by cpx_cpxs, cpx_cpye_fwd_lpx/
+| #L1 #L #HL1 #_ #IHL2 #T1 #T2 #HT12 #U1 #d #e #HTU1 #U2 #HTU2
+  elim (cpye_total G L T2 d e) #X2 #HTX2
+  lapply (cpx_cpye_fwd_lpx … HT12 … HL1 … HTU1 … HTX2) -T1
+  /4 width=9 by lpx_cpxs_trans, cpxs_strap2/ (**) (* full auto too long: 41s *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/pdeltaconvstar_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/pdeltaconvstar_6.etc
new file mode 100644 (file)
index 0000000..b7de5f5
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ◆ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PDeltaConvStar $G $L $T1 $d $e $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubsteval_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubsteval_6.etc
new file mode 100644 (file)
index 0000000..360f43d
--- /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( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ▶ * break [ term 46 d , break term 46 e ] break 𝐍 ⦃ term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'PSubstEval $G $L $T1 $T2 $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstevalalt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstevalalt_6.etc
new file mode 100644 (file)
index 0000000..18cdf60
--- /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( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ▶ ▶ * break [ term 46 d , break term 46 e ] break 𝐍 ⦃ term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'PSubstEvalAlt $G $L $T1 $T2 $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstnormal_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cny/psubstnormal_5.etc
new file mode 100644 (file)
index 0000000..4a7a78a
--- /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( ⦃ term 46 G, break term 46 L ⦄ ⊢ ▶ break [ term 46 d , break term 46 e ] 𝐍 break ⦃ term 46 T ⦄ )"
+   non associative with precedence 45
+   for @{ 'PSubstNormal $G $L $T $d $e }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees.etc
new file mode 100644 (file)
index 0000000..e1b9b06
--- /dev/null
@@ -0,0 +1,130 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cofreestar_4.ma".
+include "basic_2/relocation/lift_neg.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
+
+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 L i d T = (cofrees d i L T).
+
+(* Basic forward lemmas *****************************************************)
+
+lemma cofrees_fwd_lift: ∀L,U,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ∃T. ⇧[i, 1] T ≡ U.
+/2 width=1 by/ qed-.
+
+lemma cofrees_fwd_bind_sn: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
+                           L ⊢ i ~ϵ 𝐅*[d]⦃W⦄.
+#a #I #L #W1 #U #i #d #H #W2 #HW12 elim (H (ⓑ{a,I}W2.U)) /2 width=1 by cpys_bind/ -W1
+#X #H elim (lift_inv_bind2 … H) -H /2 width=2 by ex_intro/
+qed-.
+
+lemma cofrees_fwd_bind_dx: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
+                           L.ⓑ{I}W ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃U⦄.
+#a #I #L #W #U1 #i #d #H #U2 #HU12 elim (H (ⓑ{a,I}W.U2)) /2 width=1 by cpys_bind/ -U1
+#X #H elim (lift_inv_bind2 … H) -H /2 width=2 by ex_intro/
+qed-.
+
+lemma cofrees_fwd_flat_sn: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
+                           L ⊢ i ~ϵ 𝐅*[d]⦃W⦄.
+#I #L #W1 #U #i #d #H #W2 #HW12 elim (H (ⓕ{I}W2.U)) /2 width=1 by cpys_flat/ -W1
+#X #H elim (lift_inv_flat2 … H) -H /2 width=2 by ex_intro/
+qed-.
+
+lemma cofrees_fwd_flat_dx: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
+                           L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
+#I #L #W #U1 #i #d #H #U2 #HU12 elim (H (ⓕ{I}W.U2)) /2 width=1 by cpys_flat/ -U1
+#X #H elim (lift_inv_flat2 … H) -H /2 width=2 by ex_intro/
+qed-.
+
+(* 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-. 
+
+lemma cofrees_inv_bind: ∀a,I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓑ{a,I}W.U⦄ →
+                        L ⊢ i ~ϵ 𝐅*[d]⦃W⦄ ∧ L.ⓑ{I}W ⊢ i+1 ~ϵ 𝐅*[⫯d]⦃U⦄.
+/3 width=8 by cofrees_fwd_bind_sn, cofrees_fwd_bind_dx, conj/ qed-.
+
+lemma cofrees_inv_flat: ∀I,L,W,U,i,d. L ⊢ i ~ϵ 𝐅*[d]⦃ⓕ{I}W.U⦄ →
+                        L ⊢ i ~ϵ 𝐅*[d]⦃W⦄ ∧ L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
+/3 width=7 by cofrees_fwd_flat_sn, cofrees_fwd_flat_dx, conj/ qed-.
+
+(* Basic Properties *********************************************************)
+
+lemma cofrees_lsuby_conf: ∀L1,U,d,i. L1 ⊢ i ~ϵ 𝐅*[d]⦃U⦄ →
+                          ∀L2. L1 ⊆[d, ∞] L2 → L2 ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
+/3 width=3 by lsuby_cpys_trans/ qed-.
+
+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.
+
+lemma cofrees_cpy_trans: ∀L,U1,U2,d. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 →
+                         ∀i. L ⊢ i ~ϵ 𝐅*[d]⦃U1⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄.
+/3 width=3 by cpys_strap2/ qed-.
+
+axiom cofrees_dec: ∀L,T,d,i. Decidable (L ⊢ i ~ϵ 𝐅*[d]⦃T⦄).
+
+(* Basic negated properties *************************************************)
+
+lemma frees_cpy_div: ∀L,U1,U2,d. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 →
+                     ∀i. (L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄ → ⊥) → (L ⊢ i ~ϵ 𝐅*[d]⦃U1⦄ → ⊥).
+/3 width=7 by cofrees_cpy_trans/ qed-.
+
+(* Basic 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-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_alt.etc
new file mode 100644 (file)
index 0000000..7bb9c9c
--- /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/cpy_nlift.ma".
+include "basic_2/substitution/cofrees_lift.ma".
+
+(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
+
+(* Alternative definition of frees_ge ***************************************)
+
+lemma nlift_frees: ∀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-.
+
+lemma frees_inv_ge: ∀L,U,d,i. d ≤ yinj i → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) →
+                    (∀T. ⇧[i, 1] T ≡ U → ⊥) ∨
+                    ∃∃I,K,W,j. d ≤ yinj j & j < i & ⇩[j]L ≡ K.ⓑ{I}W &
+                               (K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄ → ⊥) & (∀T. ⇧[j, 1] T ≡ U → ⊥).
+#L #U #d #i #Hdi #H @(frees_ind … H) -U /3 width=2 by or_introl/
+#U1 #U2 #HU12 #HU2 *
+[ #HnU2 elim (cpy_fwd_nlift2_ge … HU12 … HnU2) -HU12 -HnU2 /3 width=2 by or_introl/
+  * /5 width=9 by nlift_frees, ex5_4_intro, or_intror/
+| * #I2 #K2 #W2 #j2 #Hdj2 #Hj2i #HLK2 #HnW2 #HnU2 elim (cpy_fwd_nlift2_ge … HU12 … HnU2) -HU12 -HnU2 /4 width=9 by ex5_4_intro, or_intror/
+  * #I1 #K1 #W1 #j1 #Hdj1 #Hj12 #HLK1 #HnW1 #HnU1
+  lapply (ldrop_conf_ge … HLK1 … HLK2 ?) -HLK2 /2 width=1 by lt_to_le/
+  #HK12 lapply (ldrop_inv_drop1_lt … HK12 ?) /2 width=1 by lt_plus_to_minus_r/ -HK12
+  #HK12
+  @or_intror @(ex5_4_intro … HLK1 … HnU1) -HLK1 -HnU1 /2 width=3 by transitive_lt/
+  @(frees_be … HK12 … HnW1) /2 width=1 by arith_k_sn/ -HK12 -HnW1
+  >minus_plus in ⊢ (??(?(?%?)?)??→?); >minus_plus in ⊢ (??(?(??%)?)??→?); >arith_b1 /2 width=1 by/
+]
+qed-.
+
+lemma frees_ind_ge: ∀R:relation4 ynat nat lenv term.
+                    (∀d,i,L,U. d ≤ yinj i → (∀T. ⇧[i, 1] T ≡ U → ⊥) → R d i L U) →
+                    (∀d,i,j,I,L,K,W,U. d ≤ yinj j → j < i → ⇩[j]L ≡ K.ⓑ{I}W → (K ⊢ i-j-1 ~ϵ 𝐅*[0]⦃W⦄ → ⊥) → (∀T. ⇧[j, 1] T ≡ U → ⊥) → R 0 (i-j-1) K W → R d i L U) →
+                    ∀d,i,L,U. d ≤ yinj i → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) → R d i L U.
+#R #IH1 #IH2 #d #i #L #U
+generalize in match d; -d generalize in match i; -i
+@(f2_ind … rfw … L U) -L -U
+#n #IHn #L #U #Hn #i #d #Hdi #H elim (frees_inv_ge … H) -H /3 width=2 by/
+-IH1 * #I #K #W #j #Hdj #Hji #HLK #HnW #HnU destruct /4 width=12 by ldrop_fwd_rfw/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofrees_lift.etc
new file mode 100644 (file)
index 0000000..f93f722
--- /dev/null
@@ -0,0 +1,180 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cofrees.ma".
+
+(* CONTEXT-SENSITIVE EXCLUSION FROM FREE VARIABLES **************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cofrees_inv_lref_be: ∀L,d,i,j. L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄ → d ≤ yinj j → j < i →
+                           ∀I,K,W. ⇩[j]L ≡ K.ⓑ{I}W → K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄.
+#L #d #i #j #Hj #Hdj #Hji #I #K #W1 #HLK #W2 #HW12 elim (lift_total W2 0 (j+1))
+#X2 #HWX2 elim (Hj X2) /2 width=7 by cpys_subst_Y2/ -I -L -K -W1 -d
+#Z2 #HZX2 elim (lift_div_le … HWX2 (i-j-1) 1 Z2) -HWX2 /2 width=2 by ex_intro/
+>minus_plus <plus_minus_m_m //
+qed-.
+
+lemma cofrees_inv_be: ∀L,U,d,i. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ∀j. (∀T. ⇧[j, 1] T ≡ U → ⊥) →
+                      ∀I,K,W. ⇩[j]L ≡ K.ⓑ{I}W → d ≤ yinj j → j < i → K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄.
+#L #U @(f2_ind … rfw … L U) -L -U
+#n #IH #L * *
+[ -IH #k #_ #d #i #_ #j #H elim (H (⋆k)) -H //
+| -IH #j #_ #d #i #Hi0 #j0 #H <(nlift_inv_lref_be_SO … H) -j0
+  /2 width=9 by cofrees_inv_lref_be/
+| -IH #p #_ #d #i #_ #j #H elim (H (§p)) -H //
+| #a #J #W #U #Hn #d #i #H1 #j #H2 #I #K #V #HLK #Hdj #Hji destruct
+  elim (cofrees_inv_bind … H1) -H1 #HW #HU
+  elim (nlift_inv_bind … H2) -H2 [ -HU /3 width=9 by/ ]
+  -HW #HnU lapply (IH … HU … HnU I K V ? ? ?)
+  /2 width=1 by ldrop_drop, yle_succ, lt_minus_to_plus/ -a -I -J -L -W -U -d
+  >minus_plus_plus_l //
+| #J #W #U #Hn #d #i #H1 #j #H2 #I #K #V #HLK #Hdj #Hji destruct
+  elim (cofrees_inv_flat … H1) -H1 #HW #HU
+  elim (nlift_inv_flat … H2) -H2 [ /3 width=9 by/ ]
+  #HnU @(IH … HU … HnU … HLK) // (**) (* full auto fails *)
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma cofrees_lref_skip: ∀L,d,i,j. j < i → yinj j < d → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
+#L #d #i #j #Hji #Hjd #X #H elim (cpys_inv_lref1_Y2 … H) -H
+[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
+| * #I #K #W1 #W2 #Hdj elim (ylt_yle_false … Hdj) -i -I -L -K -W1 -W2 -X //
+]
+qed.
+
+lemma cofrees_lref_lt: ∀L,d,i,j. i < j → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
+#L #d #i #j #Hij #X #H elim (cpys_inv_lref1_Y2 … H) -H
+[ #H destruct /3 width=2 by lift_lref_ge_minus, ex_intro/
+| * #I #K #V1 #V2 #_ #_ #_ #H -I -L -K -V1 -d
+  elim (lift_split … H i j) /2 width=2 by lt_to_le, ex_intro/
+]
+qed.
+
+lemma cofrees_lref_gt: ∀I,L,K,W,d,i,j. j < i → ⇩[j] L ≡ K.ⓑ{I}W → 
+                       K ⊢ (i-j-1) ~ϵ 𝐅*[O]⦃W⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
+#I #L #K #W1 #d #i #j #Hji #HLK #HW1 #X #H elim (cpys_inv_lref1_Y2 … H) -H
+[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
+| * #I0 #K0 #W0 #W2 #Hdj #HLK0 #HW12 #HW2 lapply (ldrop_mono … HLK0 … HLK) -L
+  #H destruct elim (HW1 … HW12) -I -K -W1 -d
+  #V2 #HVW2 elim (lift_trans_le … HVW2 … HW2) -W2 //
+  >minus_plus <plus_minus_m_m /2 width=2 by ex_intro/
+]
+qed.
+
+lemma cofrees_lref_free: ∀L,d,i,j. |L| ≤ j → j < i → L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄.
+#L #d #i #j #Hj #Hji #X #H elim (cpys_inv_lref1_Y2 … H) -H
+[ #H destruct /3 width=2 by lift_lref_lt, ex_intro/
+| * #I #K #W1 #W2 #_ #HLK lapply (ldrop_fwd_length_lt2 … HLK) -I
+  #H elim (lt_refl_false j) -d -i -K -W1 -W2 -X /2 width=3 by lt_to_le_to_lt/
+]
+qed.
+
+(* Advanced negated inversion lemmas ****************************************)
+
+lemma frees_inv_lref_gt: ∀L,d,i,j. j < i → (L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄ → ⊥) →
+                         ∃∃I,K,W. ⇩[j] L ≡ K.ⓑ{I}W & (K ⊢ (i-j-1) ~ϵ 𝐅*[0]⦃W⦄ → ⊥) & d ≤ yinj j.
+#L #d #i #j #Hji #H elim (ylt_split j d) #Hjd
+[ elim H -H /2 width=6 by cofrees_lref_skip/ 
+| elim (lt_or_ge j (|L|)) #Hj
+  [ elim (ldrop_O1_lt … Hj) -Hj /4 width=10 by cofrees_lref_gt, ex3_3_intro/
+  | elim H -H /2 width=6 by cofrees_lref_free/
+  ]
+]
+qed-.
+
+lemma frees_inv_lref_free: ∀L,d,i,j. (L ⊢ i ~ϵ 𝐅*[d]⦃#j⦄  → ⊥) → |L| ≤ j → j = i.
+#L #d #i #j #H #Hj elim (lt_or_eq_or_gt i j) //
+#Hij elim H -H /2 width=6 by cofrees_lref_lt, cofrees_lref_free/
+qed-.
+
+lemma frees_inv_gen: ∀L,U,d,i. (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) →
+                     ∃∃U0.  ⦃⋆, L⦄ ⊢ U ▶*[d, ∞] U0 & (∀T. ⇧[i, 1] T ≡ U0 → ⊥).
+#L #U @(f2_ind … rfw … L U) -L -U
+#n #IH #L * *
+[ -IH #k #_ #d #i #H elim H -H //
+| #j #Hn #d #i #H elim (lt_or_eq_or_gt i j)
+  [ -n #Hij elim H -H /2 width=5 by cofrees_lref_lt/
+  | -H -n #H destruct /3 width=7 by lift_inv_lref2_be, ex2_intro/
+  | #Hji elim (frees_inv_lref_gt … H) // -H
+    #I #K #W1 #HLK #H #Hdj elim (IH … H) /2 width=3 by ldrop_fwd_rfw/ -H -n
+    #W2 #HW12 #HnW2 elim (lift_total W2 0 (j+1))
+    #U2 #HWU2 @(ex2_intro … U2) /2 width=7 by cpys_subst_Y2/ -I -L -K -W1 -d
+    #T2 #HTU2 elim (lift_div_le … HWU2 (i-j-1) 1 T2) /2 width=2 by/ -W2
+    >minus_plus <plus_minus_m_m //
+  ]
+| -IH #p #_ #d #i #H elim H -H //
+| #a #I #W #U #Hn #d #i #H elim (frees_inv_bind … H) -H
+  #H elim (IH … H) // -H -n
+  /4 width=9 by cpys_bind, nlift_bind_dx, nlift_bind_sn, ex2_intro/
+| #I #W #U #Hn #d #i #H elim (frees_inv_flat … H) -H
+  #H elim (IH … H) // -H -n
+  /4 width=9 by cpys_flat, nlift_flat_dx, nlift_flat_sn, ex2_intro/
+]
+qed-.
+
+lemma frees_ind: ∀L,d,i. ∀R:predicate term.
+                 (∀U1. (∀T1. ⇧[i, 1] T1 ≡ U1 → ⊥) → R U1) → 
+                 (∀U1,U2. ⦃⋆, L⦄ ⊢ U1 ▶[d, ∞] U2 → (L ⊢ i ~ϵ 𝐅*[d]⦃U2⦄ → ⊥) → R U2 → R U1) →
+                 ∀U. (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥) → R U.
+#L #d #i #R #IH1 #IH2 #U1 #H elim (frees_inv_gen … H) -H
+#U2 #H #HnU2 @(cpys_ind_dx … H) -U1 /4 width=8 by cofrees_inv_gen/
+qed-.
+
+(* Advanced negated properties **********************************************)
+
+lemma frees_be: ∀I,L,K,W,j. ⇩[j]L ≡ K.ⓑ{I}W →
+                ∀i. j < i → (K ⊢ i-j-1 ~ϵ 𝐅*[yinj 0]⦃W⦄ → ⊥) →
+                ∀U. (∀T. ⇧[j, 1] T ≡ U → ⊥) →
+                ∀d. d ≤ yinj j → (L ⊢ i ~ϵ 𝐅*[d]⦃U⦄ → ⊥).
+/4 width=11 by cofrees_inv_be/ qed-.
+
+(* Relocation properties ****************************************************)
+
+lemma cofrees_lift_be: ∀d0,e0,i. d0 ≤ i → i ≤ d0 + e0 →
+                       ∀L,K,s. ⇩[s, d0, e0+1] L ≡ K → ∀T,U. ⇧[d0, e0+1] T ≡ U →
+                       ∀d. L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
+#d0 #e0 #i #Hd0i #Hide0 #L #K #s #HLK #T1 #U1 #HTU1 #d #U2 #HU12
+elim (yle_split d0 d) #H1
+[ elim (yle_split d (d0+e0+1)) #H2
+  [ letin cpys_inv ≝ cpys_inv_lift1_ge_up
+  | letin cpys_inv ≝ cpys_inv_lift1_ge
+  ]
+| letin cpys_inv ≝ cpys_inv_lift1_be
+]
+elim (cpys_inv … HU12 … HLK … HTU1) // #T2 #_ #HTU2 -s -L -K -U1 -T1 -d
+elim (lift_split … HTU2 i e0) /2 width=2 by ex_intro/
+qed.
+
+lemma cofrees_lift_ge: ∀d0,e0,i. d0 + e0 ≤ i →
+                       ∀L,K,s. ⇩[s, d0, e0] L ≡ K → ∀T,U. ⇧[d0, e0] T ≡ U →
+                       ∀d. K ⊢ i-e0 ~ϵ 𝐅*[d-yinj e0]⦃T⦄ → L ⊢ i ~ϵ 𝐅*[d]⦃U⦄.
+#d0 #e0 #i #Hde0i #L #K #s #HLK #T1 #U1 #HTU1 #d #HT1 #U2 #HU12
+elim (le_inv_plus_l … Hde0i) -Hde0i #Hd0ie0 #He0i
+elim (yle_split d0 d) #H1
+[ elim (yle_split d (d0+e0)) #H2
+  [ elim (cpys_inv_lift1_ge_up … HU12 … HLK … HTU1) // >yplus_inj >yminus_Y_inj #T2 #HT12
+    lapply (cpys_weak … HT12 (d-yinj e0) (∞) ? ?) /2 width=1 by yle_plus2_to_minus_inj2/ -HT12
+  | elim (cpys_inv_lift1_ge … HU12 … HLK … HTU1) // #T2
+  ]
+| elim (cpys_inv_lift1_be … HU12 … HLK … HTU1) // >yminus_Y_inj #T2 #HT12
+  lapply (cpys_weak … HT12 (d-yinj e0) (∞) ? ?) // -HT12
+]
+-s -L #HT12 #HTU2
+elim (HT1 … HT12) -T1 #V2 #HVT2
+elim (lift_trans_le … HVT2 … HTU2 ?) // <plus_minus_m_m /2 width=2 by ex_intro/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofreestar_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cofrees/cofreestar_4.etc
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 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpcs/cpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpcs/cpcs_cpcs.etc
new file mode 100644 (file)
index 0000000..1647052
--- /dev/null
@@ -0,0 +1,14 @@
+lemma cpcs_beta_dx: ∀a,L,V1,V2,W1,W2,T1,T2.
+                    L ⊢ V1 ⬌* V2 → L ⊢ W1 ⬌* W2 → L.ⓛW2 ⊢ T1 ⬌* T2 →
+                    L ⊢ ⓐV1.ⓛ{a}W1.T1 ⬌* ⓓ{a}ⓝW2.V2.T2.
+#a #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HW12 #HT12
+@(cpcs_cpr_strap1 … (ⓐV2.ⓛ{a}W2.T2)) /2 width=1/ /3 width=1/
+qed.
+
+lemma cpcs_beta_sn: ∀a,L,V1,V2,W1,W2,T1,T2.
+                    L ⊢ V1 ⬌* V2 → L ⊢ W1 ⬌* W2 → L.ⓛW1 ⊢ T1 ⬌* T2 →
+                    L ⊢ ⓐV1.ⓛ{a}W1.T1 ⬌* ⓓ{a}ⓝW2.V2.T2.
+#a #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HW12 #HT12
+lapply (lsubr_cpcs_trans … HT12 (L.ⓓⓝW1.V1) ?) /2 width=1/ #H2T12
+@(cpcs_cpr_strap2 … (ⓓ{a}ⓝW1.V1.T1)) /2 width=1/ -HT12 /3 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpes.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpes.etc
new file mode 100644 (file)
index 0000000..96574d2
--- /dev/null
@@ -0,0 +1,27 @@
+(* Advanced properties ******************************************************)
+
+lemma cpds_cpes_dx: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*➡*[h, g, l] T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
+#h #g #G #L #T1 #T2 #l * /3 width=6 by cpcs_cprs_dx, ex4_2_intro/
+qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cpes_inv_abst2: ∀h,g,a,G,L,W1,T1,T,l. ⦃G, L⦄ ⊢ T •*⬌*[h, g, l] ⓛ{a}W1.T1 →
+                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T •*➡*[h, g, l] ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
+#h #g #a #G #L #W1 #T1 #T #l2 * #T0 #l1 #Hl21 #HT #HT0 #H
+elim (cpcs_inv_abst2 … H) -H /3 width=6 by ex4_2_intro, ex2_2_intro/
+qed-.
+
+(****************************************************************************)
+
+lemma sta_cpcs_cpes: ∀h,g,G,L,T1,T,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l+1 → ⦃G, L⦄ ⊢ T1 •[h] T →
+                     ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, 1] T2.
+/3 width=6 by sta_lstas, ex4_2_intro/ qed.
+
+lemma lstas_cpes: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l → ⦃G, L⦄ ⊢ T1 •*[h, l] T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
+/2 width=6 by ex4_2_intro/ qed.
+                 
+lemma cpes_strap1: ∀h,g,G,L,T1,T,T2,l.
+                   ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T → ⦃G, L⦄ ⊢ T ⬌ T2 → ⦃G, L⦄ ⊢ T1 •*⬌*[h, g, l] T2.
+#h #g #G #L #T1 #T #T2 #l * /3 width=8 by cpcs_strap1, ex4_2_intro/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..9319cc4
--- /dev/null
@@ -0,0 +1,78 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/ltpss_dx_ldrop.ma".
+include "basic_2/static/aaa_lift.ma".
+
+(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
+
+(* Properties about dx parallel unfold **************************************)
+
+lemma aaa_ltpss_dx_tpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                              ∀L2,d,e. L1 ▶* [d, e] L2 →
+                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → L2 ⊢ T2 ⁝ A.
+#L1 #T1 #A #H elim H -L1 -T1 -A
+[ #L1 #k #L2 #d #e #_ #T2 #H
+  >(tpss_inv_sort1 … H) -H //
+| #I #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi
+    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
+      /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
+    | elim (lt_or_ge i (d + e)) #Hide
+      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
+        /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
+      | -Hdi
+        lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide
+        /3 width=8 by aaa_lref/ (**) (* too slow without trace *)
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=7/
+  ]
+| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=4/
+| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=4/
+| #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=4/
+| #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=4/
+]
+qed.
+
+lemma aaa_ltpss_dx_tps_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                             ∀L2,d,e. L1 ▶* [d, e] L2 →
+                             ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → L2 ⊢ T2 ⁝ A.
+/3 width=7/ qed.
+
+lemma aaa_ltpss_dx_conf: ∀L1,T,A. L1 ⊢ T ⁝ A →
+                         ∀L2,d,e. L1 ▶* [d, e] L2 → L2 ⊢ T ⁝ A.
+/2 width=7/ qed.
+
+lemma aaa_tpss_conf: ∀L,T1,A. L ⊢ T1 ⁝ A →
+                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T2 ⁝ A.
+/2 width=7/ qed.
+
+lemma aaa_tps_conf: ∀L,T1,A. L ⊢ T1 ⁝ A →
+                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → L ⊢ T2 ⁝ A.
+/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/aaa_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..4f2a448
--- /dev/null
@@ -0,0 +1,37 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/static/aaa_ltpss_dx.ma".
+
+(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
+
+(* Properties about sn parallel unfold **************************************)
+
+lemma aaa_ltpss_sn_conf: ∀L1,T,A. L1 ⊢ T ⁝ A →
+                         ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 → L2 ⊢ T ⁝ A.
+#L1 #T #A #HT #L2 #d #e #HL12
+lapply (ltpss_sn_ltpssa … HL12) -HL12 #HL12
+@(TC_Conf3 … (λL,A. L ⊢ T ⁝ A) … HT ? HL12) /2 width=5/
+qed.
+
+lemma aaa_ltpss_sn_tpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                              ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → L2 ⊢ T2 ⁝ A.
+/3 width=5/ qed.
+
+lemma aaa_ltpss_sn_tps_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                             ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                             ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → L2 ⊢ T2 ⁝ A.
+/3 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cnf_cif.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cnf_cif.etc
new file mode 100644 (file)
index 0000000..5a1ae5a
--- /dev/null
@@ -0,0 +1,106 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cif.ma".
+include "basic_2/reducibility/cnf_lift.ma".
+
+(* CONTEXT-SENSITIVE NORMAL TERMS *******************************************)
+
+(* Main properties **********************************************************)
+
+lemma tps_cif_eq: ∀L,T1,T2,d,e. L ⊢ T1 ▶[d, e] T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
+[ //
+| #L #K #V #W #i #d #e #_ #_ #HLK #_ #H -d -e
+  elim (cif_inv_delta … HLK ?) //
+| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #H
+  elim (cif_inv_bind … H) -H #HV1 #HT1 * #H destruct
+  lapply (IHV12 … HV1) -IHV12 -HV1 #H destruct /3 width=1/
+| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #H
+  elim (cif_inv_flat … H) -H #HV1 #HT1 #_ #_ /3 width=1/
+]
+qed.
+
+lemma tpss_cif_eq: ∀L,T1,T2,d,e. L ⊢ T1 ▶*[d, e] T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
+#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT1 #HT1
+lapply (IHT1 HT1) -IHT1 #H destruct /2 width=5/
+qed.
+
+lemma tpr_cif_eq: ∀T1,T2. T1 ➡ T2 → ∀L. L ⊢ 𝐈⦃T1⦄ → T1 = T2.
+#T1 #T2 #H elim H -T1 -T2
+[ //
+| * #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #L #H
+  [ elim (cif_inv_appl … H) -H #HV1 #HT1 #_
+    >IHV1 -IHV1 // -HV1 >IHT1 -IHT1 //
+  | elim (cif_inv_ri2 … H) /2 width=1/
+  ]
+| #a #V1 #V2 #W #T1 #T2 #_ #_ #_ #_ #L #H
+  elim (cif_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+| #a * #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV1 #IHT1 #L #H
+  [ lapply (tps_lsubr_trans … HT2 (L.ⓓV2) ?) -HT2 /2 width=1/ #HT2
+    elim (cif_inv_bind … H) -H #HV1 #HT1 * #H destruct
+    lapply (IHV1 … HV1) -IHV1 -HV1 #H destruct
+    lapply (IHT1 … HT1) -IHT1 #H destruct
+    lapply (tps_cif_eq … HT2 ?) -HT2 //
+  | <(tps_inv_refl_SO2 … HT2 ?) -HT2 //
+    elim (cif_inv_ib2 … H) -H /2 width=1/ /3 width=2/
+  ]
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #L #H
+  elim (cif_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+| #V1 #T1 #T #T2 #_ #_ #_ #L #H
+  elim (cif_inv_ri2 … H) /2 width=1/
+| #V1 #T1 #T2 #_ #_ #L #H
+  elim (cif_inv_ri2 … H) /2 width=1/
+]
+qed.
+
+lemma cpr_cif_eq: ∀L,T1,T2. L ⊢ T1 ➡ T2 → L ⊢ 𝐈⦃T1⦄ → T1 = T2.
+#L #T1 #T2 * #T0 #HT10 #HT02 #HT1
+lapply (tpr_cif_eq … HT10 … HT1) -HT10 #H destruct /2 width=5/
+qed.
+
+theorem cif_cnf: ∀L,T. L ⊢ 𝐈⦃T⦄ → L ⊢ 𝐍⦃T⦄.
+/3 width=3/ qed.
+
+(* Note: this property is unusual *)
+lemma cnf_crf_false: ∀L,T. L ⊢ 𝐑⦃T⦄ → L ⊢ 𝐍⦃T⦄ → ⊥.
+#L #T #H elim H -L -T
+[ #L #K #V #i #HLK #H
+  elim (cnf_inv_delta … HLK H)
+| #L #V #T #_ #IHV #H
+  elim (cnf_inv_appl … H) -H /2 width=1/
+| #L #V #T #_ #IHT #H
+  elim (cnf_inv_appl … H) -H /2 width=1/
+| #I #L #V #T * #H1 #H2 destruct
+  [ elim (cnf_inv_zeta … H2)
+  | elim (cnf_inv_tau … H2)
+  ]
+|5,6: #a * [ elim a ] #L #V #T * #H1 #_ #IH #H2 destruct
+  [1,3: elim (cnf_inv_abbr … H2) -H2 /2 width=1/
+  |*: elim (cnf_inv_abst … H2) -H2 /2 width=1/
+  ]
+| #a #L #V #W #T #H
+  elim (cnf_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+| #a #L #V #W #T #H
+  elim (cnf_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+]
+qed.
+
+theorem cnf_cif: ∀L,T. L ⊢ 𝐍⦃T⦄ → L ⊢ 𝐈⦃T⦄.
+/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..80f418b
--- /dev/null
@@ -0,0 +1,50 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/cprs_ltpss_dx.ma".
+include "basic_2/equivalence/cpcs_cpcs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
+
+(* Properties concerning dx partial unfold on local environments ************)
+
+lemma cpcs_ltpss_dx_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
+                          ∀T1,T2. L1 ⊢ T1 ⬌* T2 → L2 ⊢ T1 ⬌* T2.
+#L1 #L2 #d #e #HL12 #T1 #T2 #H
+elim (cpcs_inv_cprs … H) -H #T #HT1 #HT2
+elim (cprs_ltpss_dx_conf … HT1 … HL12) -HT1 #U1 #HTU1 #H1
+elim (cprs_ltpss_dx_conf … HT2 … HL12) -L1 #U2 #HTU2 #H2
+elim (tpss_conf_eq … H1 … H2) -T #U #HU1 #HU2
+lapply (cprs_tpss_trans … HTU1 … HU1) -U1
+lapply (cprs_tpss_trans … HTU2 … HU2) -U2 /2 width=3/
+qed-.
+
+lemma cpcs_ltpss_dx_tpss_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
+                               ∀T,T2. L1 ⊢ T ⬌* T2 →
+                               ∀T1. L2 ⊢ T ▶* [d, e] T1 →
+                               L2 ⊢ T1 ⬌* T2.
+#L1 #L2 #d #e #HL12 #T #T2 #HT2 #T1 #HT1
+lapply (cpcs_ltpss_dx_conf … HL12 … HT2) -L1 #HT2
+lapply (cpcs_tpss_conf … HT1 … HT2) -T //
+qed-.
+
+lemma cpcs_ltpss_dx_tpss2_conf: ∀L1,L2,d,e. L1 ▶* [d, e] L2 →
+                                ∀T1,T2. L1 ⊢ T1 ⬌* T2 →
+                                ∀T3. L2 ⊢ T1 ▶* [d, e] T3 →
+                                ∀T4. L2 ⊢ T2 ▶* [d, e] T4 →
+                                L2 ⊢ T3 ⬌* T4.
+#L1 #L2 #d #e #HL12 #T1 #T2 #HT12 #T3 #HT13 #T4 #HT24
+lapply (cpcs_ltpss_dx_tpss_conf … HL12 … HT12 … HT13) -L1 -T1 #HT32
+lapply (cpcs_tpss_strap1 … HT32 … HT24) -T2 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpcs_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..5bf1ed5
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_ltpss_dx.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
+
+(* Properties concerning sn partial unfold on local environments ************)
+
+lemma cpcs_ltpss_sn_conf: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                          ∀T1,T2. L1 ⊢ T1 ⬌* T2 → L2 ⊢ T1 ⬌* T2.
+#L1 #L2 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 //
+#L #L2 #_ #HL2 #IHL1 #T1 #U1 #HTU1
+lapply (IHL1 … HTU1) -IHL1 -HTU1 #HTU1
+lapply (cpcs_ltpss_dx_conf … HL2 … HTU1) -HTU1 -HL2 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr.etc
new file mode 100644 (file)
index 0000000..d82299c
--- /dev/null
@@ -0,0 +1,111 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss.ma".
+include "basic_2/reducibility/tpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Basic_1: includes: pr2_delta1 *)
+definition cpr: lenv → relation term ≝
+   λL,T1,T2. ∃∃T. T1 ➡ T & L ⊢ T ▶* [0, |L|] T2.
+
+interpretation
+   "context-sensitive parallel reduction (term)"
+   'PRed L T1 T2 = (cpr L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma cpr_intro: ∀L,T1,T,T2,d,e. T1 ➡ T → L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
+/3 width=5/ qed-.
+
+(* Basic_1: was by definition: pr2_free *)
+lemma cpr_tpr: ∀T1,T2. T1 ➡ T2 → ∀L. L ⊢ T1 ➡ T2.
+/2 width=3/ qed.
+
+lemma cpr_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
+/3 width=5/ qed.
+
+lemma cpr_refl: ∀L,T. L ⊢ T ➡ T.
+/2 width=1/ qed.
+
+(* Note: new property *)
+(* Basic_1: was only: pr2_thin_dx *)
+lemma cpr_flat: ∀I,L,V1,V2,T1,T2.
+                L ⊢ V1 ➡ V2 → L ⊢ T1 ➡ T2 → L ⊢ ⓕ{I} V1. T1 ➡ ⓕ{I} V2. T2.
+#I #L #V1 #V2 #T1 #T2 * #V #HV1 #HV2 * /3 width=5/
+qed.
+
+lemma cpr_cast: ∀L,V,T1,T2.
+                L ⊢ T1 ➡ T2 → L ⊢ ⓝV. T1 ➡ T2.
+#L #V #T1 #T2 * /3 width=3/
+qed.
+
+(* Note: it does not hold replacing |L1| with |L2| *)
+(* Basic_1: was only: pr2_change *)
+lemma cpr_lsubr_trans: ∀L1,T1,T2. L1 ⊢ T1 ➡ T2 →
+                       ∀L2. L2 ⊑ [0, |L1|] L1 → L2 ⊢ T1 ➡ T2.
+#L1 #T1 #T2 * #T #HT1 #HT2 #L2 #HL12
+lapply (tpss_lsubr_trans … HT2 … HL12) -HT2 -HL12 /3 width=4/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+(* Basic_1: was: pr2_gen_csort *)
+lemma cpr_inv_atom: ∀T1,T2. ⋆ ⊢ T1 ➡ T2 → T1 ➡ T2.
+#T1 #T2 * #T #HT normalize #HT2
+<(tpss_inv_refl_O2 … HT2) -HT2 //
+qed-.
+
+(* Basic_1: was: pr2_gen_sort *)
+lemma cpr_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ➡ T2 → T2 = ⋆k.
+#L #T2 #k * #X #H
+>(tpr_inv_atom1 … H) -H #H
+>(tpss_inv_sort1 … H) -H //
+qed-.
+
+(* Basic_1: was: pr2_gen_cast *)
+lemma cpr_inv_cast1: ∀L,V1,T1,U2. L ⊢ ⓝV1. T1 ➡ U2 → (
+                        ∃∃V2,T2. L ⊢ V1 ➡ V2 & L ⊢ T1 ➡ T2 &
+                                 U2 = ⓝV2. T2
+                     ) ∨ L ⊢ T1 ➡ U2.
+#L #V1 #T1 #U2 * #X #H #HU2
+elim (tpr_inv_cast1 … H) -H /3 width=3/
+* #V #T #HV1 #HT1 #H destruct
+elim (tpss_inv_flat1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma cpr_fwd_bind1_minus: ∀I,L,V1,T1,T. L ⊢ -ⓑ{I}V1.T1 ➡ T → ∀b.
+                           ∃∃V2,T2. L ⊢ ⓑ{b,I}V1.T1 ➡ ⓑ{b,I}V2.T2 &
+                                    T = -ⓑ{I}V2.T2.
+#I #L #V1 #T1 #T * #X #H1 #H2 #b
+elim (tpr_fwd_bind1_minus … H1 b) -H1 #V0 #T0 #HT10 #H destruct
+elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct /4 width=5/
+qed-.
+
+lemma cpr_fwd_shift1: ∀L,L1,T1,T. L ⊢ L1 @@ T1 ➡ T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#L #L1 #T1 #T * #X #H1 #H2
+elim (tpr_fwd_shift1 … H1) -H1 #L0 #T0 #HL10 #H destruct
+elim (tpss_fwd_shift1 … H2) -H2 #L2 #T2 #HL02 #H destruct /2 width=4/
+qed-.
+
+(* Basic_1: removed theorems 6:
+            pr2_head_2 pr2_cflat pr2_gen_cflat clear_pr2_trans
+            pr2_gen_ctail pr2_ctail
+   Basic_1: removed local theorems 3:
+            pr2_free_free pr2_free_delta pr2_delta_delta
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_aaa.etc
new file mode 100644 (file)
index 0000000..7c12733
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/aaa_ltpss_sn.ma".
+include "basic_2/reducibility/ltpr_aaa.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_cpr_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. L ⊢ T1 ➡ T2 → L ⊢ T2 ⁝ A.
+#L #T1 #A #HT1 #T2 * /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_cpr.etc
new file mode 100644 (file)
index 0000000..d231c84
--- /dev/null
@@ -0,0 +1,63 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/tpr_tpr.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Advanced properties ******************************************************)
+
+lemma cpr_bind_sn: ∀a,I,L,V1,V2,T1,T2. L ⊢ V1 ➡ V2 → T1 ➡ T2 →
+                   L ⊢ ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
+#a #I #L #V1 #V2 #T1 #T2 * #V #HV1 #HV2 #HT12
+@ex2_intro [2: @(tpr_delta … HV1 HT12) | skip ] /2 width=3/ (* /3 width=5/ is too slow *)
+qed.
+
+(* Basic_1: was only: pr2_gen_cbind *)
+lemma cpr_bind_dx: ∀a,I,L,V1,V2,T1,T2. V1 ➡ V2 → L. ⓑ{I} V2 ⊢ T1 ➡ T2 →
+                   L ⊢ ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
+#a #I #L #V1 #V2 #T1 #T2 #HV12 * #T #HT1 normalize #HT2
+elim (tpss_split_up … HT2 1 ? ?) -HT2 // #T0 <minus_n_O #HT0 normalize <minus_plus_m_m #HT02
+lapply (tpss_lsubr_trans … HT0 (⋆. ⓑ{I} V2) ?) -HT0 /2 width=1/ #HT0
+lapply (tpss_inv_SO2 … HT0) -HT0 #HT0
+@ex2_intro [2: @(tpr_delta … HV12 HT1 HT0) | skip | /2 width=1/ ] (**) (* /3 width=5/ is too slow *)
+qed.
+
+(* Basic_1: was only: pr2_head_1 *)
+lemma cpr_pair_sn: ∀I,L,V1,V2,T1,T2. L ⊢ V1 ➡ V2 → T1 ➡ T2 →
+                   L ⊢ ②{I} V1. T1 ➡ ②{I} V2. T2.
+* /2 width=1/ /3 width=1/
+qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma cpr_shift_fwd: ∀L,T1,T2. L ⊢ T1 ➡ T2 → L @@ T1 ➡ L @@ T2.
+#L elim L -L
+[ #T1 #T2 #HT12 @(cpr_inv_atom … HT12)
+| normalize /3 width=1/
+].
+qed-.
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: pr2_confluence *)
+theorem cpr_conf: ∀L,U0,T1,T2. L ⊢ U0 ➡ T1 → L ⊢ U0 ➡ T2 →
+                  ∃∃T. L ⊢ T1 ➡ T & L ⊢ T2 ➡ T.
+#L #U0 #T1 #T2 * #U1 #HU01 #HUT1 * #U2 #HU02 #HUT2
+elim (tpr_conf … HU01 HU02) -U0 #U #HU1 #HU2
+elim (ltpr_tpr_tpss_conf ? L … HU1 … HUT1) -U1 // #U1 #HTU1 #HU1
+elim (ltpr_tpr_tpss_conf ? L … HU2 … HUT2) -U2 // #U2 #HTU2 #HU2
+elim (tpss_conf_eq … HU1 … HU2) -U /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_lift.etc
new file mode 100644 (file)
index 0000000..0a7afdd
--- /dev/null
@@ -0,0 +1,180 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_lift.ma".
+include "basic_2/reducibility/tpr_lift.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Advanced properties ******************************************************)
+
+lemma cpr_cdelta: ∀L,K,V1,W1,W2,i.
+                  ⇩[0, i] L ≡ K. ⓓV1 → K ⊢ V1 ▶* [0, |L| - i - 1] W1 →
+                  ⇧[0, i + 1] W1 ≡ W2 → L ⊢ #i ➡ W2.
+#L #K #V1 #W1 #W2 #i #HLK #HVW1 #HW12
+lapply (ldrop_fwd_ldrop2_length … HLK) #Hi
+@ex2_intro [2: // | skip | @tpss_subst /width=6/ ] (**) (* /3 width=6/ is too slow *)
+qed.
+
+lemma cpr_abst: ∀L,V1,V2. L ⊢ V1 ➡ V2 → ∀V,T1,T2. L.ⓛV ⊢ T1 ➡ T2 →
+                          ∀a,I. L ⊢ ⓑ{a,I}V1. T1 ➡ ⓑ{a,I}V2. T2.
+#L #V1 #V2 * #V0 #HV10 #HV02 #V #T1 #T2 * #T0 #HT10 #HT02 #a #I
+lapply (tpss_inv_S2 … HT02 L V ?) -HT02 // #HT02
+lapply (tpss_lsubr_trans … HT02 (L.ⓑ{I}V2) ?) -HT02 /2 width=1/ #HT02
+@(ex2_intro … (ⓑ{a,I}V0.T0)) /2 width=1/ (* explicit constructors *)
+qed.
+
+lemma cpr_beta: ∀a,L,V1,V2,W,T1,T2.
+                L ⊢ V1 ➡ V2 → L.ⓛW ⊢ T1 ➡ T2 → L ⊢ ⓐV1.ⓛ{a}W.T1 ➡ ⓓ{a}V2.T2.
+#a #L #V1 #V2 #W #T1 #T2 * #V #HV1 #HV2 * #T #HT1 #HT2
+lapply (tpss_inv_S2 … HT2 L W ?) -HT2 // #HT2
+lapply (tpss_lsubr_trans … HT2 (L.ⓓV2) ?) -HT2 /2 width=1/ #HT2
+@(ex2_intro … (ⓓ{a}V.T)) /2 width=1/ (**) (* explicit constructor, /3/ is too slow *)
+qed.
+
+lemma cpr_beta_dx: ∀a,L,V1,V2,W,T1,T2.
+                   V1 ➡ V2 → L.ⓛW ⊢ T1 ➡ T2 → L ⊢ ⓐV1.ⓛ{a}W.T1 ➡ ⓓ{a}V2.T2.
+/3 width=1/ qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+(* Basic_1: was: pr2_gen_lref *)
+lemma cpr_inv_lref1: ∀L,T2,i. L ⊢ #i ➡ T2 →
+                     T2 = #i ∨
+                     ∃∃K,V1,T1. ⇩[0, i] L ≡ K. ⓓV1 &
+                                K ⊢ V1 ▶* [0, |L| - i - 1] T1 &
+                                ⇧[0, i + 1] T1 ≡ T2 &
+                                i < |L|.
+#L #T2 #i * #X #H
+>(tpr_inv_atom1 … H) -H #H
+elim (tpss_inv_lref1 … H) -H /2 width=1/
+* /3 width=6/
+qed-.
+
+(* Basic_1: was pr2_gen_abbr *)
+lemma cpr_inv_abbr1: ∀a,L,V1,T1,U2. L ⊢ ⓓ{a}V1. T1 ➡ U2 →
+                     (∃∃V,V2,T2. V1 ➡ V & L ⊢ V ▶* [O, |L|] V2 &
+                                 L. ⓓV ⊢ T1 ➡ T2 &
+                                 U2 = ⓓ{a}V2. T2
+                      ) ∨
+                      ∃∃T2. L.ⓓV1 ⊢ T1 ➡ T2 & ⇧[0,1] U2 ≡ T2 & a = true.
+#a #L #V1 #T1 #Y * #X #H1 #H2
+elim (tpr_inv_abbr1 … H1) -H1 *
+[ #V #T #T0 #HV1 #HT1 #HT0 #H destruct
+  elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT02 #H destruct
+  lapply (tps_lsubr_trans … HT0 (L. ⓓV) ?) -HT0 /2 width=1/ #HT0
+  lapply (tps_weak_full … HT0) -HT0 #HT0
+  lapply (tpss_lsubr_trans … HT02 (L. ⓓV) ?) -HT02 /2 width=1/ #HT02
+  lapply (tpss_weak_full … HT02) -HT02 #HT02
+  lapply (tpss_strap2 … HT0 HT02) -T0 /4 width=7/
+| #T2 #HT12 #HXT2 #H destruct
+  elim (lift_total Y 0 1) #Z #HYZ
+  lapply (tpss_lift_ge … H2 (L.ⓓV1) … HXT2 … HYZ) -X // /2 width=1/ #H
+  lapply (cpr_intro … HT12 … H) -T2 /3 width=3/
+]
+qed-.
+
+(* Basic_1: was: pr2_gen_abst *)
+lemma cpr_inv_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a}V1. T1 ➡ U2 → ∀I,W.
+                     ∃∃V2,T2. L ⊢ V1 ➡ V2 & L. ⓑ{I} W ⊢ T1 ➡ T2 & U2 = ⓛ{a}V2. T2.
+#a #L #V1 #T1 #Y * #X #H1 #H2 #I #W
+elim (tpr_inv_abst1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
+elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+lapply (tpss_lsubr_trans … HT2 (L. ⓑ{I} W) ?) -HT2 /2 width=1/ /4 width=5/
+qed-.
+
+(* Basic_1: was pr2_gen_appl *)
+lemma cpr_inv_appl1: ∀L,V1,U0,U2. L ⊢ ⓐV1. U0 ➡ U2 →
+                     ∨∨ ∃∃V2,T2.              L ⊢ V1 ➡ V2 & L ⊢ U0 ➡ T2 &
+                                              U2 = ⓐV2. T2
+                      | ∃∃a,V2,W,T1,T2.       L ⊢ V1 ➡ V2 & L. ⓓV2 ⊢ T1 ➡ T2 &
+                                              U0 = ⓛ{a}W. T1 &
+                                              U2 = ⓓ{a}V2. T2
+                      | ∃∃a,V2,V,W1,W2,T1,T2. L ⊢ V1 ➡ V2 & L ⊢ W1 ➡ W2 & L. ⓓW2 ⊢ T1 ➡ T2 &
+                                              ⇧[0,1] V2 ≡ V &
+                                              U0 = ⓓ{a}W1. T1 &
+                                              U2 = ⓓ{a}W2. ⓐV. T2.
+#L #V1 #U0 #Y * #X #H1 #H2
+elim (tpr_inv_appl1 … H1) -H1 *
+[ #V #U #HV1 #HU0 #H destruct
+  elim (tpss_inv_flat1 … H2) -H2 #V2 #U2 #HV2 #HU2 #H destruct /4 width=5/
+| #a #V #W #T0 #T #HV1 #HT0 #H #H1 destruct
+  elim (tpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+  lapply (tpss_weak … HT2 0 (|L|+1) ? ?) -HT2 // /4 width=9/
+| #a #V0 #V #W #W0 #T #T0 #HV10 #HW0 #HT0 #HV0 #H #H1 destruct
+  elim (tpss_inv_bind1 … H2) -H2 #W2 #X #HW02 #HX #HY destruct
+  elim (tpss_inv_flat1 … HX) -HX #V2 #T2 #HV2 #HT2 #H destruct
+  elim (tpss_inv_lift1_ge … HV2 … HV0 ?) -V // [3: /2 width=1/ |2: skip ] #V <minus_plus_m_m
+  lapply (tpss_weak … HT2 0 (|L|+1) ? ?) -HT2 // /4 width=13/
+]
+qed-.
+
+(* Note: the main property of simple terms *)
+lemma cpr_inv_appl1_simple: ∀L,V1,T1,U. L ⊢ ⓐV1. T1 ➡ U → 𝐒⦃T1⦄ →
+                            ∃∃V2,T2. L ⊢ V1 ➡ V2 & L ⊢ T1 ➡ T2 &
+                                     U = ⓐV2. T2.
+#L #V1 #T1 #U #H #HT1
+elim (cpr_inv_appl1 … H) -H *
+[ /2 width=5/
+| #a #V2 #W #W1 #W2 #_ #_ #H #_ destruct
+  elim (simple_inv_bind … HT1)
+| #a #V2 #V #W1 #W2 #U1 #U2 #_ #_ #_ #_ #H #_ destruct
+  elim (simple_inv_bind … HT1)
+]
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma cpr_fwd_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a}V1.T1 ➡ U2 → ∀b,I,W.
+                     ∃∃V2,T2. L ⊢ ⓑ{b,I}W.T1 ➡ ⓑ{b,I}W.T2 &
+                              U2 = ⓛ{a}V2.T2.
+#a #L #V1 #T1 #U2 * #U #H #HU2 #b #I #W
+elim (tpr_fwd_abst1 … H b I W) -H #V #T #HT1 #H destruct
+elim (tpss_inv_bind1 … HU2) -HU2 #V2 #T2 #_ #HT2
+lapply (tpss_lsubr_trans … HT2 (L.ⓑ{I}W) ?) -HT2 /2 width=1/ /4 width=5/
+qed-.
+
+(* Relocation properties ****************************************************)
+
+(* Basic_1: was: pr2_lift *)
+lemma cpr_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K →
+                ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
+                K ⊢ T1 ➡ T2 → L ⊢ U1 ➡ U2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 * #T #HT1 #HT2
+elim (lift_total T d e) #U #HTU
+lapply (tpr_lift … HT1 … HTU1 … HTU) -T1 #HU1
+elim (lt_or_ge (|K|) d) #HKd
+[ lapply (tpss_lift_le … HT2 … HLK HTU … HTU2) -T2 -T -HLK [ /2 width=2/ | /3 width=4/ ]
+| lapply (tpss_lift_be … HT2 … HLK HTU … HTU2) -T2 -T -HLK // /3 width=4/
+]
+qed.
+
+(* Basic_1: was: pr2_gen_lift *)
+lemma cpr_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
+                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀U2. L ⊢ U1 ➡ U2 →
+                     ∃∃T2. ⇧[d, e] T2 ≡ U2 & K ⊢ T1 ➡ T2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #U2 * #U #HU1 #HU2
+elim (tpr_inv_lift1 … HU1 … HTU1) -U1 #T #HTU #T1
+elim (lt_or_ge (|L|) d) #HLd
+[ elim (tpss_inv_lift1_le … HU2 … HLK … HTU ?) -U -HLK /2 width=2/
+  /3 width=7 by ex2_intro, cpr_intro/
+| elim (lt_or_ge (|L|) (d + e)) #HLde
+  [ elim (tpss_inv_lift1_be_up … HU2 … HLK … HTU ? ?) -U -HLK // /2 width=2/
+    /3 width=7 by ex2_intro, cpr_intro/
+  | elim (tpss_inv_lift1_be … HU2 … HLK … HTU ? ?) -U -HLK //
+    /3 width=7 by ex2_intro, cpr_intro/
+  ]
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpr.etc
new file mode 100644 (file)
index 0000000..ab10e3f
--- /dev/null
@@ -0,0 +1,46 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_tpss.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties concerning parallel unfold on terms ***************************)
+
+(* Note: we could invoke tpss_weak_full instead of ltpr_fwd_length *)
+(* Basic_1: was only: pr2_subst1 *)
+lemma cpr_tpss_ltpr: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. L2 ⊢ T1 ➡ T2 →
+                     ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
+                     ∃∃U2. L2 ⊢ U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
+#L1 #L2 #HL12 #T1 #T2 * #T #HT1 #HT2 #d #e #U1 #HTU1
+elim (ltpr_tpr_tpss_conf … HL12 … HT1 … HTU1) -L1 -HT1 #U #HU1 #HTU
+elim (tpss_conf_eq … HT2 … HTU) -T /3 width=3/
+qed.
+
+lemma cpr_ltpr_conf_eq: ∀L1,T1,T2. L1 ⊢ T1 ➡ T2 → ∀L2. L1 ➡ L2 →
+                        ∃∃T. L2 ⊢ T1 ➡ T & T2 ➡ T.
+#L1 #T1 #T2 * #T #HT1 #HT2 #L2 #HL12
+>(ltpr_fwd_length … HL12) in HT2; #HT2
+elim (ltpr_tpr_tpss_conf … HL12 … HT2) -L1 /3 width=3/
+qed.
+
+lemma cpr_ltpr_conf_tpss: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. L1 ⊢ T1 ➡ T2 →
+                          ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
+                          ∃∃U2. L2 ⊢ U1 ➡ U2 & L2 ⊢ T2 ➡ U2.
+#L1 #L2 #HL12 #T1 #T2 #HT12 #d #e #U1 #HTU1
+elim (cpr_ltpr_conf_eq … HT12 … HL12) -HT12 #T #HT1 #HT2
+elim (cpr_tpss_ltpr … HL12 … HT1 … HTU1) -L1 -HT1 #U2 #HU12 #HTU2
+lapply (tpss_weak_full … HTU2) -HTU2 #HTU2 /3 width=5/ (**) (* /4 width=5/ is too slow *)
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..5d90e68
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_dx_ltpss_dx.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties concerning dx partial unfold on local environments ************)
+
+lemma ltpss_dx_cpr_conf: ∀L1,T,U1. L1 ⊢ T ➡ U1 →
+                         ∀L2,d,e. L1 ▶* [d, e] L2 →
+                         ∃∃U2. L2 ⊢ T ➡ U2 & L2 ⊢ U1 ▶* [d, e] U2.
+#L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
+lapply (ltpss_dx_fwd_length … HL12) #H >H in HU1; -H #HU1
+elim (ltpss_dx_tpss_conf … HU1 … HL12) -L1 /3 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..f946e4c
--- /dev/null
@@ -0,0 +1,35 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties concerning sn partial unfold on local environments ************)
+
+lemma ltpss_sn_cpr_trans: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                          ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
+#L1 #L2 #d #e #HL12 #T1 #T2 *
+lapply (ltpss_sn_weak_full … HL12)
+<(ltpss_sn_fwd_length … HL12) -HL12 /3 width=5/
+qed.
+
+lemma ltpss_sn_cpr_conf: ∀L1,T,U1. L1 ⊢ T ➡ U1 →
+                         ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                         ∃∃U2. L2 ⊢ T ➡ U2 & L1 ⊢ U1 ▶* [d, e] U2.
+#L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
+lapply (ltpss_sn_fwd_length … HL12) #H >H in HU1; -H #HU1
+elim (ltpss_sn_tpss_conf … HU1 … HL12) -HU1 -HL12 /3 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cpr_tpss.etc
new file mode 100644 (file)
index 0000000..d8c7225
--- /dev/null
@@ -0,0 +1,39 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_tpss.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties on partial unfold for terms ***********************************)
+
+lemma cpr_tpss_trans: ∀L,T1,T. L ⊢ T1 ➡ T →
+                      ∀T2,d,e. L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡ T2.
+#L #T1 #T * #T0 #HT10 #HT0 #T2 #d #e #HT2
+lapply (tpss_weak_full … HT2) -HT2 #HT2
+lapply (tpss_trans_eq … HT0 HT2) -T /2 width=3/
+qed.
+
+lemma cpr_tps_trans: ∀L,T1,T. L ⊢ T1 ➡ T →
+                     ∀T2,d,e. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ➡ T2.
+/3 width=5/ qed.
+
+lemma cpr_tpss_conf: ∀L,T0,T1. L ⊢ T0 ➡ T1 →
+                     ∀T2,d,e. L ⊢ T0 ▶* [d, e] T2 →
+                     ∃∃T. L ⊢ T1 ▶* [d, e] T & L ⊢ T2 ➡ T.
+#L #T0 #T1 * #U0 #HTU0 #HU0T1 #T2 #d #e #HT02
+elim (tpr_tpss_conf … HTU0 … HT02) -T0 #T0 #HT20 #HUT0
+elim (tpss_conf_eq … HU0T1 … HUT0) -U0 /3 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpr.etc
new file mode 100644 (file)
index 0000000..2682a76
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_ltpr.ma".
+include "basic_2/computation/cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties concerning parallel unfold on terms ***************************)
+
+(* Basic_1: was only: pr3_subst1 *)
+lemma cprs_tpss_ltpr: ∀L1,T1,U1,d,e. L1 ⊢ T1 ▶* [d, e] U1 →
+                      ∀L2. L1 ➡ L2 → ∀T2. L2 ⊢ T1 ➡* T2 →
+                      ∃∃U2. L2 ⊢ U1 ➡* U2 & L2 ⊢ T2 ▶* [d, e] U2.
+#L1 #T1 #U1 #d #e #HTU1 #L2 #HL12 #T2 #HT12 elim HT12 -T2
+[ #T2 #HT12
+  elim (cpr_tpss_ltpr … HL12 … HT12 … HTU1) -L1 -T1 /3 width=3/
+| #T #T2 #_ #HT2 * #U #HU1 #HTU
+  elim (cpr_tpss_ltpr … HT2 … HTU) -L1 -T // /3 width=3/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..7f86180
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_ltpss_dx.ma".
+include "basic_2/computation/cprs_tpss.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties concerning dx partial unfold on local environments ************)
+
+lemma cprs_ltpss_dx_conf: ∀L1,T,U1. L1 ⊢ T ➡* U1 →
+                          ∀L2,d,e. L1 ▶* [d, e] L2 →
+                          ∃∃U2. L2 ⊢ T ➡* U2 & L2 ⊢ U1 ▶* [d, e] U2.
+#L1 #T #U1 #H @(cprs_ind … H) -U1 /2 width=3/
+#T1 #U1 #_ #HTU1 #IHT1 #L2 #d #e #HL12
+elim (IHT1 … HL12) -IHT1 #U #HTU #HT1U
+elim (ltpss_dx_cpr_conf … HTU1 … HL12) -L1 #U0 #HT1U0 #HU10
+elim (cpr_tpss_conf … HT1U0 … HT1U) -T1 #U2 #HU02 #HU2
+lapply (tpss_trans_eq … HU10 HU02) -U0 /3 width=3/
+qed-.
+
+lemma cprs_ltpss_dx_tpss_conf: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
+                               ∀L2,d,e. L1 ▶* [d, e] L2 →
+                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                               ∃∃U2. L2 ⊢ T2 ➡* U2 & L2 ⊢ U1 ▶* [d, e] U2.
+#L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
+elim (cprs_ltpss_dx_conf … HTU1 … HL12) -L1 #U #HT1U #HU1
+elim (cprs_tpss_conf … HT1U … HT12) -T1 #T #HUT #HT2
+lapply (tpss_trans_eq … HU1 HUT) -U /2 width=3/
+qed-.
+
+lemma cprs_ltpss_dx_tpss2_conf: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
+                                ∀L2,d,e. L1 ▶* [d, e] L2 →
+                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                                ∀U2. L2 ⊢ U1 ▶* [d, e] U2 →
+                                ∃∃U. L2 ⊢ T2 ➡* U & L2 ⊢ U2 ▶* [d, e] U.
+#L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12 #U2 #HU12
+elim (cprs_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -L1 -T1 #U #HT2U #HU1
+elim (tpss_conf_eq … HU12 … HU1) -U1 #U0 #HU20 #HU0
+lapply (cprs_tpss_trans … HT2U … HU0) -U /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..32009d1
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/computation/cprs_ltpss_dx.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties concerning sn partial unfold on local environments ************)
+
+lemma cprs_ltpss_sn_conf: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                          ∀T,U1. L1 ⊢ T ➡* U1 →
+                          ∃∃U2. L2 ⊢ T ➡* U2 & L1 ⊢ U1 ▶* [d, e] U2.
+#L1 #L2 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 /2 width=3/
+#L #L2 #HL1 #HL2 #IHL1 #T #U1 #HTU1
+lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
+lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
+elim (IHL1 … HTU1) -IHL1 -HTU1 #U #HTU #HU1
+elim (cprs_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #HTU2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/cprs_tpss.etc
new file mode 100644 (file)
index 0000000..0c575ae
--- /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/reducibility/cpr_tpss.ma".
+include "basic_2/computation/cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties on partial unfold for terms ***********************************)
+
+lemma cprs_tpss_trans: ∀L,T1,T. L ⊢ T1 ➡* T →
+                       ∀T2,d,e. L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ➡* T2.
+#L #T1 #T #H @(cprs_ind … H) -T /2 width=3/ /3 width=5/
+qed.
+
+lemma cprs_tps_trans: ∀L,T1,T. L ⊢ T1 ➡* T →
+                      ∀T2,d,e. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ➡* T2.
+/3 width=5 by inj, cprs_tpss_trans/ qed. (**) (* auto too slow without trace *)
+
+lemma cprs_tpss_conf: ∀L,T0,T1. L ⊢ T0 ➡* T1 →
+                      ∀T2,d,e. L ⊢ T0 ▶* [d, e] T2 →
+                      ∃∃T. L ⊢ T1 ▶* [d, e] T & L ⊢ T2 ➡* T.
+#L #T0 #T1 #H @(cprs_ind … H) -T1 /2 width=3/
+#T #T1 #_ #HT1 #IHT0 #T2 #d #e #HT02
+elim (IHT0 … HT02) -T0 #T0 #HT0 #HT20
+elim (cpr_tpss_conf … HT1 … HT0) -T /3 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..8e3260d
--- /dev/null
@@ -0,0 +1,50 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unwind/sstas_ltpss_dx.ma".
+include "basic_2/computation/cprs_ltpss_dx.ma".
+include "basic_2/computation/dxprs.ma".
+
+(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
+
+(* Properties about dx parallel unfold **************************************)
+
+lemma dxprs_ltpss_dx_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 →
+                           ∀L2,d,e. L1 ▶* [d, e] L2 →
+                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T #U1 * #U #HTU #HU1 #L2 #d #e #HL12
+elim (sstas_ltpss_dx_conf … HTU … HL12) -HTU #U0 #HTU0 #HU0
+elim (cprs_ltpss_dx_conf … HU1 … HL12) -L1 #U2 #HU2 #HU12
+elim (cprs_tpss_conf … HU2 … HU0) -U #U #HU2 #HU0
+lapply (tpss_trans_eq … HU12 HU2) -U2 /3 width=3/
+qed-.
+
+lemma dxprs_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*➡*[g] U1 →
+                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*➡*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
+#h #g #L #T1 #U1 * #W1 #HTW1 #HWU1 #T2 #d #e #HT12
+elim (sstas_tpss_conf … HTW1 … HT12) -T1 #W2 #HTW2 #HW12
+elim (cprs_tpss_conf … HWU1 … HW12) -W1 /3 width=3/
+qed-.
+
+lemma dxprs_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*➡*[g] U1 →
+                                ∀L2,d,e. L1 ▶* [d, e] L2 →
+                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*➡*[g] U2 &
+                                      L2 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
+elim (dxprs_ltpss_dx_conf … HTU1 … HL12) -L1 #U #HT1U #HU1
+elim (dxprs_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/dxprs_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..553e465
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/computation/dxprs_ltpss_dx.ma".
+
+(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
+
+(* Properties about sn parallel unfold **************************************)
+
+lemma dxprs_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                           ∀T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 →
+                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L1 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #L2 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 [ /2 width=3/ ]
+#L #L2 #HL1 #HL2 #IHL1 #T #U1 #HTU1
+lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
+lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
+elim (IHL1 … HTU1) -IHL1 -HTU1 #U #HTU #HU1
+elim (dxprs_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #HTU2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lbotr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lbotr.etc
new file mode 100644 (file)
index 0000000..df6b2c1
--- /dev/null
@@ -0,0 +1,94 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lsubr_lbotr.ma".
+include "basic_2/relocation/ldrop_ldrop.ma".
+
+(* DROPPING *****************************************************************)
+
+(* Inversion lemmas about local env. full refinement for substitution *******)
+
+(* Note: ldrop_ldrop not needed *)
+lemma lbotr_inv_ldrop: ∀I,L,K,V,i. ⇩[0, i] L ≡ K. ⓑ{I}V → ∀d,e. ⊒[d, e] L →
+                       d ≤ i → i < d + e → I = Abbr.
+#I #L elim L -L
+[ #K #V #i #H
+  lapply (ldrop_inv_atom1 … H) -H #H destruct
+| #L #J #W #IHL #K #V #i #H
+  elim (ldrop_inv_O1 … H) -H *
+  [ -IHL #H1 #H2 #d #e #HL #Hdi #Hide destruct
+    lapply (le_n_O_to_eq … Hdi) -Hdi #H destruct
+    lapply (HL … (L.ⓓW) ?) -HL /2 width=1/ #H
+    elim (lsubr_inv_abbr2 … H ?) -H // -Hide #K #_ #H destruct //
+  | #Hi #HLK #d @(nat_ind_plus … d) -d
+    [ #e #H #_ #Hide
+      elim (lbotr_inv_bind … H ?) -H [2: /2 width=2/ ] #HL #H destruct
+      @(IHL … HLK … HL) -IHL -HLK -HL // /2 width=1/
+    | #d #_ #e #H #Hdi #Hide
+      lapply (lbotr_inv_skip … H ?) -H // #HL
+      @(IHL … HLK … HL) -IHL -HLK -HL /2 width=1/
+    ]
+  ]
+]
+qed-.
+
+(* Properties about local env. full refinement for substitution *************)
+
+(* Note: ldrop_ldrop not needed *)
+lemma lbotr_ldrop: ∀L,d,e.
+                   (∀I,K,V,i. d ≤ i → i < d + e → ⇩[0, i] L ≡ K. ⓑ{I}V → I = Abbr) →
+                   ⊒[d, e] L.
+#L elim L -L //
+#L #I #V #IHL #d @(nat_ind_plus … d) -d
+[ #e @(nat_ind_plus … e) -e //
+  #e #_ #H0
+  >(H0 I L V 0 ? ? ?) //
+  /5 width=6 by lbotr_abbr, ldrop_ldrop, lt_minus_to_plus_r/ (**) (* auto now too slow without trace *)
+| #d #_ #e #H0
+  /5 width=6 by lbotr_skip, ldrop_ldrop, le_S_S, lt_minus_to_plus_r/ (**) (* auto now too slow without trace *)
+]
+qed.
+
+lemma lbotr_ldrop_trans_le: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ∀dd,ee. ⊒[dd, ee] L1 →
+                            dd + ee ≤ d → ⊒[dd, ee] L2.
+#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hddee
+@lbotr_ldrop #I #K2 #V2 #i #Hddi #Hiddee #HLK2
+lapply (lt_to_le_to_lt … Hiddee Hddee) -Hddee #Hid
+elim (ldrop_trans_le … HL12 … HLK2 ?) -L2 /2 width=2/ #X #HLK1 #H
+elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K1 #V1 #HK12 #HV21 #H destruct
+@(lbotr_inv_ldrop … HLK1 … HL1) -L1 -K1 -V1 //
+qed.
+
+lemma lbotr_ldrop_trans_be_up: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 →
+                               ∀dd,ee. ⊒[dd, ee] L1 →
+                               dd ≤ d + e → d + e ≤ dd + ee →
+                               ⊒[d, dd + ee - d - e] L2.
+#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hdde #Hddee
+@lbotr_ldrop #I #K2 #V2 #i #Hdi #Hiddee #HLK2
+lapply (transitive_le ? ? (i+e)… Hdde ?) -Hdde /2 width=1/ #Hddie
+>commutative_plus in Hiddee; >minus_minus_comm <plus_minus_m_m /2 width=1/ -Hddee #Hiddee
+lapply (ldrop_trans_ge … HL12 … HLK2 ?) -L2 // -Hdi  #HL1K2
+@(lbotr_inv_ldrop … HL1K2 … HL1) -L1 >commutative_plus // -Hddie /2 width=1/
+qed.
+
+lemma lbotr_ldrop_trans_ge: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ∀dd,ee. ⊒[dd, ee] L1 →
+                            d + e ≤ dd → ⊒[dd - e, ee] L2.
+#L1 #L2 #d #e #HL12 #dd #ee #HL1 #Hddee
+@lbotr_ldrop #I #K2 #V2 #i #Hddi #Hiddee #HLK2
+elim (le_inv_plus_l … Hddee) -Hddee #Hdde #Hedd
+>plus_minus in Hiddee; // #Hiddee
+lapply (transitive_le … Hdde Hddi) -Hdde #Hid
+lapply (ldrop_trans_ge … HL12 … HLK2 ?) -L2 // -Hid #HL1K2
+@(lbotr_inv_ldrop … HL1K2 … HL1) -L1 >commutative_plus /2 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ldrop_lpx.etc
new file mode 100644 (file)
index 0000000..d23ed28
--- /dev/null
@@ -0,0 +1,68 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lenv_px.ma".
+include "basic_2/relocation/ldrop.ma".
+
+(* DROPPING *****************************************************************)
+
+(* Properties on pointwise extension ****************************************)
+
+lemma lpx_deliftable_dropable: ∀R. t_deliftable_sn R → dropable_sn (lpx R).
+#R #HR #L1 #K1 #d #e #H elim H -L1 -K1 -d -e
+[ #d #e #X #H >(lpx_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #X #H
+  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct /3 width=5/
+| #L1 #K1 #I #V1 #e #_ #IHLK1 #X #H
+  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
+  elim (IHLK1 … HL12) -L1 /3 width=3/
+| #L1 #K1 #I #V1 #W1 #d #e #_ #HWV1 #IHLK1 #X #H
+  elim (lpx_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
+  elim (HR … HV12 … HWV1) -V1
+  elim (IHLK1 … HL12) -L1 /3 width=5/
+]
+qed.
+
+lemma lpx_liftable_dedropable: ∀R. reflexive ? R →
+                               t_liftable R → dedropable_sn (lpx R).
+#R #H1R #H2R #L1 #K1 #d #e #H elim H -L1 -K1 -d -e
+[ #d #e #X #H >(lpx_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #X #H
+  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=5/
+| #L1 #K1 #I #V1 #e #_ #IHLK1 #K2 #HK12
+  elim (IHLK1 … HK12) -K1 /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d #e #_ #HWV1 #IHLK1 #X #H
+  elim (lpx_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
+  elim (lift_total W2 d e) #V2 #HWV2
+  lapply (H2R … HW12 … HWV1 … HWV2) -W1
+  elim (IHLK1 … HK12) -K1 /3 width=5/
+]
+qed.
+
+fact lpx_dropable_aux: ∀R,L2,K2,d,e. ⇩[d, e] L2 ≡ K2 → ∀L1. lpx R L1 L2 →
+                       d = 0 → ∃∃K1. ⇩[0, e] L1 ≡ K1 & lpx R K1 K2.
+#R #L2 #K2 #d #e #H elim H -L2 -K2 -d -e
+[ #d #e #X #H >(lpx_inv_atom2 … H) -H /2 width=3/
+| #K2 #I #V2 #X #H
+  elim (lpx_inv_pair2 … H) -H #K1 #V1 #HK12 #HV12 #H destruct /3 width=5/
+| #L2 #K2 #I #V2 #e #_ #IHLK2 #X #H #_
+  elim (lpx_inv_pair2 … H) -H #L1 #V1 #HL12 #HV12 #H destruct
+  elim (IHLK2 … HL12 ?) -L2 // /3 width=3/
+| #L2 #K2 #I #V2 #W2 #d #e #_ #_ #_ #L1 #_
+  >commutative_plus normalize #H destruct
+]
+qed-.
+
+lemma lpx_dropable: ∀R. dropable_dx (lpx R).
+/2 width=5 by lpx_dropable_aux/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_px.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_px.etc
new file mode 100644 (file)
index 0000000..ea916e1
--- /dev/null
@@ -0,0 +1,166 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lenv_append.ma".
+
+(* POINTWISE EXTENSION OF A CONTEXT-FREE REALTION FOR TERMS *****************)
+
+inductive lpx (R:relation term): relation lenv ≝
+| lpx_stom: lpx R (⋆) (⋆)
+| lpx_pair: ∀I,K1,K2,V1,V2.
+            lpx R K1 K2 → R V1 V2 → lpx R (K1. ⓑ{I} V1) (K2. ⓑ{I} V2)
+.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lpx_inv_atom1_aux: ∀R,L1,L2. lpx R L1 L2 → L1 = ⋆ → L2 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_inv_atom1: ∀R,L2. lpx R (⋆) L2 → L2 = ⋆.
+/2 width=4 by lpx_inv_atom1_aux/ qed-.
+
+fact lpx_inv_pair1_aux: ∀R,L1,L2. lpx R L1 L2 → ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
+                        ∃∃K2,V2. lpx R K1 K2 & R V1 V2 & L2 = K2. ⓑ{I} V2.
+#R #L1 #L2 * -L1 -L2
+[ #J #K1 #V1 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5/
+]
+qed-.
+
+lemma lpx_inv_pair1: ∀R,I,K1,V1,L2. lpx R (K1. ⓑ{I} V1) L2 →
+                     ∃∃K2,V2. lpx R K1 K2 & R V1 V2 & L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_inv_pair1_aux/ qed-.
+
+fact lpx_inv_atom2_aux: ∀R,L1,L2. lpx R L1 L2 → L2 = ⋆ → L1 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_inv_atom2: ∀R,L1. lpx R L1 (⋆) → L1 = ⋆.
+/2 width=4 by lpx_inv_atom2_aux/ qed-.
+
+fact lpx_inv_pair2_aux: ∀R,L1,L2. lpx R L1 L2 → ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
+                        ∃∃K1,V1. lpx R K1 K2 & R V1 V2 & L1 = K1. ⓑ{I} V1.
+#R #L1 #L2 * -L1 -L2
+[ #J #K2 #V2 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5/
+]
+qed-.
+
+lemma lpx_inv_pair2: ∀R,I,L1,K2,V2. lpx R L1 (K2. ⓑ{I} V2) →
+                     ∃∃K1,V1. lpx R K1 K2 & R V1 V2 & L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_inv_pair2_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpx_fwd_length: ∀R,L1,L2. lpx R L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H -L1 -L2 normalize //
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma lpx_inv_append1: ∀R,L1,K1,L. lpx R (K1 @@ L1) L →
+                       ∃∃K2,L2. lpx R K1 K2 & lpx R L1 L2 & L = K2 @@ L2.
+#R #L1 elim L1 -L1 normalize
+[ #K1 #K2 #HK12
+  @(ex3_2_intro … K2 (⋆)) // (**) (* explicit constructor, /2 width=5/ does not work *)
+| #L1 #I #V1 #IH #K1 #X #H
+  elim (lpx_inv_pair1 … H) -H #L #V2 #H1 #HV12 #H destruct
+  elim (IH … H1) -IH -H1 #K2 #L2 #HK12 #HL12 #H destruct
+  @(ex3_2_intro … HK12) [2: /2 width=2/ | skip | // ] (* explicit constructor, /3 width=5/ does not work *)
+]
+qed-.
+
+lemma lpx_inv_append2: ∀R,L2,K2,L. lpx R L (K2 @@ L2) →
+                       ∃∃K1,L1. lpx R K1 K2 & lpx R L1 L2 & L = K1 @@ L1.
+#R #L2 elim L2 -L2 normalize
+[ #K2 #K1 #HK12
+  @(ex3_2_intro … K1 (⋆)) // (**) (* explicit constructor, /2 width=5/ does not work *)
+| #L2 #I #V2 #IH #K2 #X #H
+  elim (lpx_inv_pair2 … H) -H #L #V1 #H1 #HV12 #H destruct
+  elim (IH … H1) -IH -H1 #K1 #L1 #HK12 #HL12 #H destruct
+  @(ex3_2_intro … HK12) [2: /2 width=2/ | skip | // ] (* explicit constructor, /3 width=5/ does not work *)
+]
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpx_refl: ∀R. reflexive ? R → reflexive … (lpx R).
+#R #HR #L elim L -L // /2 width=1/
+qed.
+
+lemma lpx_sym: ∀R. symmetric ? R → symmetric … (lpx R).
+#R #HR #L1 #L2 #H elim H -H // /3 width=1/
+qed.
+
+lemma lpx_trans: ∀R. Transitive ? R → Transitive … (lpx R).
+#R #HR #L1 #L #H elim H -L //
+#I #K1 #K #V1 #V #_ #HV1 #IHK1 #X #H
+elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK2 #HV2 #H destruct /3 width=3/
+qed.
+
+lemma lpx_conf: ∀R. confluent ? R → confluent … (lpx R).
+#R #HR #L0 #L1 #H elim H -L1
+[ #X #H >(lpx_inv_atom1 … H) -X /2 width=3/
+| #I #K0 #K1 #V0 #V1 #_ #HV01 #IHK01 #X #H
+  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK02 #HV02 #H destruct
+  elim (IHK01 … HK02) -K0 #K #HK1 #HK2
+  elim (HR … HV01 … HV02) -HR -V0 /3 width=5/
+]
+qed.
+
+lemma lpx_TC_inj: ∀R,L1,L2. lpx R L1 L2 → lpx (TC … R) L1 L2.
+#R #L1 #L2 #H elim H -L1 -L2 // /3 width=1/
+qed.
+
+lemma lpx_TC_step: ∀R,L1,L. lpx (TC … R) L1 L →
+                   ∀L2. lpx R L L2 → lpx (TC … R) L1 L2.
+#R #L1 #L #H elim H -L /2 width=1/
+#I #K1 #K #V1 #V #_ #HV1 #IHK1 #X #H
+elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK2 #HV2 #H destruct /3 width=3/
+qed.
+
+lemma TC_lpx_pair_dx: ∀R. reflexive ? R →
+                      ∀I,K,V1,V2. TC … R V1 V2 →
+                      TC … (lpx R) (K.ⓑ{I}V1) (K.ⓑ{I}V2).
+#R #HR #I #K #V1 #V2 #H elim H -V2
+/4 width=5 by lpx_refl, lpx_pair, inj, step/ (**) (* too slow without trace *)
+qed.
+
+lemma TC_lpx_pair_sn: ∀R. reflexive ? R →
+                      ∀I,V,K1,K2. TC … (lpx R) K1 K2 →
+                      TC … (lpx R) (K1.ⓑ{I}V) (K2.ⓑ{I}V).
+#R #HR #I #V #K1 #K2 #H elim H -K2
+/4 width=5 by lpx_refl, lpx_pair, inj, step/ (**) (* too slow without trace *)
+qed.
+
+lemma lpx_TC: ∀R,L1,L2. TC … (lpx R) L1 L2 → lpx (TC … R) L1 L2.
+#R #L1 #L2 #H elim H -L2 /2 width=1/ /2 width=3/
+qed.
+
+lemma lpx_inv_TC: ∀R. reflexive ? R →
+                  ∀L1,L2. lpx (TC … R) L1 L2 → TC … (lpx R) L1 L2.
+#R #HR #L1 #L2 #H elim H -L1 -L2 /3 width=1/ /3 width=3/
+qed.
+
+lemma lpx_append: ∀R,K1,K2. lpx R K1 K2 → ∀L1,L2. lpx R L1 L2 →
+                  lpx R (L1 @@ K1) (L2 @@ K2).
+#R #K1 #K2 #H elim H -K1 -K2 // /3 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_top.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lenv_top.etc
new file mode 100644 (file)
index 0000000..ab90ceb
--- /dev/null
@@ -0,0 +1,68 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( T1 𝟙 break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'RTop $T1 $T2 }.
+
+include "basic_2/grammar/lenv_px.ma".
+
+(* POINTWISE EXTENSION OF TOP RELATION FOR TERMS ****************************)
+
+definition ttop: relation term ≝ λT1,T2. True.
+
+definition ltop: relation lenv ≝ lpx ttop.
+
+interpretation
+  "top reduction (environment)"
+  'RTop L1 L2 = (ltop L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma ltop_refl: reflexive … ltop.
+/2 width=1/ qed.
+
+lemma ltop_sym: symmetric … ltop.
+/2 width=1/ qed.
+
+lemma ltop_trans: transitive … ltop.
+/2 width=3/ qed.
+
+lemma ltop_append: ∀K1,K2. K1 𝟙 K2 → ∀L1,L2. L1 𝟙 L2 → L1 @@ K1 𝟙 L2 @@ K2.
+/2 width=1/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma ltop_inv_atom1: ∀L2. ⋆ 𝟙 L2 → L2 = ⋆.
+/2 width=2 by lpx_inv_atom1/ qed-.
+
+lemma ltop_inv_pair1: ∀K1,I,V1,L2. K1. ⓑ{I} V1 𝟙 L2 →
+                      ∃∃K2,V2. K1 𝟙 K2 & L2 = K2. ⓑ{I} V2.
+#K1 #I #V1 #L2 #H
+elim (lpx_inv_pair1 … H) -H /2 width=4/
+qed-.
+
+lemma ltop_inv_atom2: ∀L1. L1 𝟙 ⋆ → L1 = ⋆.
+/2 width=2 by lpx_inv_atom2/ qed-.
+
+lemma ltop_inv_pair2: ∀L1,K2,I,V2. L1 𝟙 K2. ⓑ{I} V2 →
+                      ∃∃K1,V1. K1 𝟙 K2 & L1 = K1. ⓑ{I} V1.
+#L1 #K2 #I #V2 #H
+elim (lpx_inv_pair2 … H) -H /2 width=4/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma ltop_fwd_length: ∀L1,L2. L1 𝟙 L2 → |L1| = |L2|.
+/2 width=2 by lpx_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr.etc
new file mode 100644 (file)
index 0000000..ea9f585
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 ⦄ ➡ break ⦃ term 46 L2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRed $L1 $L2 }.
+
+include "basic_2/unfold/ltpss_sn.ma".
+include "basic_2/reducibility/ltpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
+
+definition lfpr: relation lenv ≝
+   λL1,L2. ∃∃L. L1 ➡ L & L ⊢ ▶* [0, |L|] L2
+.
+
+interpretation
+  "focalized parallel reduction (environment)"
+  'FocalizedPRed L1 L2 = (lfpr L1 L2).
+
+(* Basic properties *********************************************************)
+
+(* Note: lemma 250 *)
+lemma lfpr_refl: ∀L. ⦃L⦄ ➡ ⦃L⦄.
+/2 width=3/ qed.
+
+lemma ltpss_sn_lfpr: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → ⦃L1⦄ ➡ ⦃L2⦄.
+/3 width=5/ qed.
+
+lemma ltpr_lfpr: ∀L1,L2. L1 ➡ L2 → ⦃L1⦄ ➡ ⦃L2⦄.
+/3 width=3/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lfpr_inv_atom1: ∀L2. ⦃⋆⦄ ➡ ⦃L2⦄ → L2 = ⋆.
+#L2 * #L #HL >(ltpr_inv_atom1 … HL) -HL #HL2 >(ltpss_sn_inv_atom1 … HL2) -HL2 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_aaa.etc
new file mode 100644 (file)
index 0000000..6f6c49d
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/aaa_ltpss_sn.ma".
+include "basic_2/reducibility/ltpr_aaa.ma".
+include "basic_2/reducibility/lfpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_lfpr_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. ⦃L1⦄ ➡ ⦃L2⦄ → L2 ⊢ T ⁝ A.
+#L1 #T #A #HT #L2 * /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_cpr.etc
new file mode 100644 (file)
index 0000000..8a01f26
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_ltpss_sn.ma".
+include "basic_2/reducibility/ltpr_ldrop.ma".
+include "basic_2/reducibility/cpr.ma".
+include "basic_2/reducibility/lfpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
+
+(* Advanced properties ******************************************************)
+
+lemma lfpr_pair_cpr: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ∀V1,V2. L2 ⊢ V1 ➡ V2 →
+                     ∀I. ⦃L1. ⓑ{I} V1⦄ ➡ ⦃L2. ⓑ{I} V2⦄.
+#L1 #L2 * #L #HL1 #HL2 #V1 #V2 *
+<(ltpss_sn_fwd_length … HL2) #V #HV1 #HV2 #I
+lapply (ltpss_sn_tpss_trans_eq … HV2 … HL2) -HV2 #V2
+@(ex2_intro … (L.ⓑ{I}V)) /2 width=1/ (**) (* explicit constructor *)
+qed.
+
+(* Properties on supclosure *************************************************)
+(*
+lamma fsub_cpr_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ➡ U2 →
+                      ∃∃L,U1. ⦃L1⦄ ➡ ⦃L⦄ & L ⊢ T1 ➡ U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
+#L1 #L2 #T1 #T2 #HT12 #U2 * #T #H1 #H2
+elim (fsub_tpr_trans … HT12 … H1) -T2 #L #U #HL1 #HT1U #HUT
+elim (fsup_tpss_trans_full … HUT … H2) -T  -HUT -H2 #L #U #HL1 #HT1U #HUT
+
+
+
+
+
+
+ #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
+#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HK2
+elim (lift_total T d e) #U #HTU
+elim (ldrop_ltpr_trans … HLK1 … HK1) -HLK1 -HK1 #L #HL1 #HLK
+lapply (tpr_lift … HT1 … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
+qed-.
+*)
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_lfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfpr_lfpr.etc
new file mode 100644 (file)
index 0000000..7031e79
--- /dev/null
@@ -0,0 +1,39 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_ltpss_sn.ma".
+include "basic_2/reducibility/ltpr_ltpr.ma".
+include "basic_2/reducibility/lfpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
+
+(* Main properties **********************************************************)
+
+theorem lfpr_conf: ∀L0,L1,L2. ⦃L0⦄ ➡ ⦃L1⦄ → ⦃L0⦄ ➡ ⦃L2⦄ →
+                   ∃∃L. ⦃L1⦄ ➡ ⦃L⦄ & ⦃L2⦄ ➡ ⦃L⦄.
+#K0 #L1 #L2 * #K1 #HK01 #HKL1 * #K2 #HK02 #HKL2
+lapply (ltpr_fwd_length … HK01) #H
+>(ltpr_fwd_length … HK02) in H; #H
+elim (ltpr_conf … HK01 … HK02) -K0 #K #HK1 #HK2
+lapply (ltpss_sn_fwd_length … HKL1) #H1
+lapply (ltpss_sn_fwd_length … HKL2) #H2
+>H1 in HKL1 H; -H1 #HKL1
+>H2 in HKL2; -H2 #HKL2 #H
+elim (ltpr_ltpss_sn_conf … HKL1 … HK1) -K1 #K1 #HK1 #HLK1
+elim (ltpr_ltpss_sn_conf … HKL2 … HK2) -K2 #K2 #HK2 #HLK2
+elim (ltpss_sn_conf … HK1 … HK2) -K #K #HK1 #HK2
+lapply (ltpr_fwd_length … HLK1) #H1
+lapply (ltpr_fwd_length … HLK2) #H2
+/3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfprs_ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lfprs_ltprs.etc
new file mode 100644 (file)
index 0000000..99ae801
--- /dev/null
@@ -0,0 +1,23 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/ltprs.ma".
+include "basic_2/computation/lfprs.ma".
+
+(* FOCALIZED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *********************)
+
+(* Properties on context-free parallel computation for local environments ***)
+
+lemma ltprs_lfprs: ∀L1,L2. L1 ➡* L2 → ⦃L1⦄ ➡* ⦃L2⦄.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lift.etc
new file mode 100644 (file)
index 0000000..f0d631e
--- /dev/null
@@ -0,0 +1,25 @@
+definition t_liftable: relation term → Prop ≝
+                       λR. ∀T1,T2. R T1 T2 → ∀U1,d,e. ⇧[d, e] T1 ≡ U1 →
+                       ∀U2. ⇧[d, e] T2 ≡ U2 → R U1 U2.
+
+definition t_deliftable_sn: relation term → Prop ≝
+                            λR. ∀U1,U2. R U1 U2 → ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
+                            ∃∃T2. ⇧[d, e] T2 ≡ U2 & R T1 T2.
+
+lemma t_liftable_TC: ∀R. t_liftable R → t_liftable (TC … R).
+#R #HR #T1 #T2 #H elim H -T2
+[ /3 width=7/
+| #T #T2 #_ #HT2 #IHT1 #U1 #d #e #HTU1 #U2 #HTU2
+  elim (lift_total T d e) /3 width=9/
+]
+qed.
+
+lemma t_deliftable_sn_TC: ∀R. t_deliftable_sn R → t_deliftable_sn (TC … R).
+#R #HR #U1 #U2 #H elim H -U2
+[ #U2 #HU12 #T1 #d #e #HTU1
+  elim (HR … HU12 … HTU1) -U1 /3 width=3/
+| #U #U2 #_ #HU2 #IHU1 #T1 #d #e #HTU1
+  elim (IHU1 … HTU1) -U1 #T #HTU #HT1
+  elim (HR … HU2 … HTU) -U /3 width=5/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr.etc
new file mode 100644 (file)
index 0000000..8655a5e
--- /dev/null
@@ -0,0 +1,198 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L1 break ⊑ [ term 46 d , break term 46 e ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'SubEq $L1 $d $e $L2 }.
+
+include "basic_2/grammar/lenv_length.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
+
+inductive lsubr: nat → nat → relation lenv ≝
+| lsubr_sort: ∀d,e. lsubr d e (⋆) (⋆)
+| lsubr_OO:   ∀L1,L2. lsubr 0 0 L1 L2
+| lsubr_abbr: ∀L1,L2,V,e. lsubr 0 e L1 L2 →
+              lsubr 0 (e + 1) (L1. ⓓV) (L2.ⓓV)
+| lsubr_abst: ∀L1,L2,I,V1,V2,e. lsubr 0 e L1 L2 →
+              lsubr 0 (e + 1) (L1. ⓑ{I}V1) (L2. ⓛV2)
+| lsubr_skip: ∀L1,L2,I1,I2,V1,V2,d,e.
+              lsubr d e L1 L2 → lsubr (d + 1) e (L1. ⓑ{I1} V1) (L2. ⓑ{I2} V2)
+.
+
+interpretation
+  "local environment refinement (substitution)"
+  'SubEq L1 d e L2 = (lsubr d e L1 L2).
+
+definition lsubr_trans: ∀S. (lenv → relation S) → Prop ≝ λS,R.
+                        ∀L2,s1,s2. R L2 s1 s2 →
+                        ∀L1,d,e. L1 ⊑ [d, e] L2 → R L1 s1 s2.
+
+(* Basic properties *********************************************************)
+
+lemma lsubr_bind_eq: ∀L1,L2,e. L1 ⊑ [0, e] L2 → ∀I,V.
+                     L1. ⓑ{I} V ⊑ [0, e + 1] L2.ⓑ{I} V.
+#L1 #L2 #e #HL12 #I #V elim I -I /2 width=1/
+qed.
+
+lemma lsubr_abbr_lt: ∀L1,L2,V,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
+                     L1. ⓓV ⊑ [0, e] L2.ⓓV.
+#L1 #L2 #V #e #HL12 #He >(plus_minus_m_m e 1) // /2 width=1/
+qed.
+
+lemma lsubr_abst_lt: ∀L1,L2,I,V1,V2,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
+                     L1. ⓑ{I}V1 ⊑ [0, e] L2. ⓛV2.
+#L1 #L2 #I #V1 #V2 #e #HL12 #He >(plus_minus_m_m e 1) // /2 width=1/
+qed.
+
+lemma lsubr_skip_lt: ∀L1,L2,d,e. L1 ⊑ [d - 1, e] L2 → 0 < d →
+                     ∀I1,I2,V1,V2. L1. ⓑ{I1} V1 ⊑ [d, e] L2. ⓑ{I2} V2.
+#L1 #L2 #d #e #HL12 #Hd >(plus_minus_m_m d 1) // /2 width=1/
+qed.
+
+lemma lsubr_bind_lt: ∀I,L1,L2,V,e. L1 ⊑ [0, e - 1] L2 → 0 < e →
+                     L1. ⓓV ⊑ [0, e] L2. ⓑ{I}V.
+* /2 width=1/ qed.
+
+lemma lsubr_refl: ∀d,e,L. L ⊑ [d, e] L.
+#d elim d -d
+[ #e elim e -e // #e #IHe #L elim L -L // /2 width=1/
+| #d #IHd #e #L elim L -L // /2 width=1/
+]
+qed.
+
+lemma TC_lsubr_trans: ∀S,R. lsubr_trans S R → lsubr_trans S (λL. (TC … (R L))).
+#S #R #HR #L1 #s1 #s2 #H elim H -s2
+[ /3 width=5/
+| #s #s2 #_ #Hs2 #IHs1 #L2 #d #e #HL12
+  lapply (HR … Hs2 … HL12) -HR -Hs2 -HL12 /3 width=3/
+]
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lsubr_inv_atom1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 → L1 = ⋆ →
+                          L2 = ⋆ ∨ (d = 0 ∧ e = 0).
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ /2 width=1/
+| /3 width=1/
+| #L1 #L2 #W #e #_ #H destruct
+| #L1 #L2 #I #W1 #W2 #e #_ #H destruct
+| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #H destruct
+]
+qed.
+
+lemma lsubr_inv_atom1: ∀L2,d,e. ⋆ ⊑ [d, e] L2 →
+                       L2 = ⋆ ∨ (d = 0 ∧ e = 0).
+/2 width=3/ qed-.
+
+fact lsubr_inv_skip1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
+                          ∀I1,K1,V1. L1 = K1.ⓑ{I1}V1 → 0 < d →
+                          ∃∃I2,K2,V2. K1 ⊑ [d - 1, e] K2 & L2 = K2.ⓑ{I2}V2.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #I1 #K1 #V1 #H destruct
+| #L1 #L2 #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #W #e #_ #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #I #W1 #W2 #e #_ #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #J1 #J2 #W1 #W2 #d #e #HL12 #I1 #K1 #V1 #H #_ destruct /2 width=5/
+]
+qed.
+
+lemma lsubr_inv_skip1: ∀I1,K1,L2,V1,d,e. K1.ⓑ{I1}V1 ⊑ [d, e] L2 → 0 < d →
+                       ∃∃I2,K2,V2. K1 ⊑ [d - 1, e] K2 & L2 = K2.ⓑ{I2}V2.
+/2 width=5/ qed-.
+
+fact lsubr_inv_atom2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 → L2 = ⋆ →
+                          L1 = ⋆ ∨ (d = 0 ∧ e = 0).
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ /2 width=1/
+| /3 width=1/
+| #L1 #L2 #W #e #_ #H destruct
+| #L1 #L2 #I #W1 #W2 #e #_ #H destruct
+| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #H destruct
+]
+qed.
+
+lemma lsubr_inv_atom2: ∀L1,d,e. L1 ⊑ [d, e] ⋆ →
+                       L1 = ⋆ ∨ (d = 0 ∧ e = 0).
+/2 width=3/ qed-.
+
+fact lsubr_inv_abbr2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
+                          ∀K2,V. L2 = K2.ⓓV → d = 0 → 0 < e →
+                          ∃∃K1. K1 ⊑ [0, e - 1] K2 & L1 = K1.ⓓV.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #K1 #V #H destruct
+| #L1 #L2 #K1 #V #_ #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #W #e #HL12 #K1 #V #H #_ #_ destruct /2 width=3/
+| #L1 #L2 #I #W1 #W2 #e #_ #K1 #V #H destruct
+| #L1 #L2 #I1 #I2 #W1 #W2 #d #e #_ #K1 #V #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma lsubr_inv_abbr2: ∀L1,K2,V,e. L1 ⊑ [0, e] K2.ⓓV → 0 < e →
+                       ∃∃K1. K1 ⊑ [0, e - 1] K2 & L1 = K1.ⓓV.
+/2 width=5/ qed-.
+
+fact lsubr_inv_skip2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
+                          ∀I2,K2,V2. L2 = K2.ⓑ{I2}V2 → 0 < d →
+                          ∃∃I1,K1,V1. K1 ⊑ [d - 1, e] K2 & L1 = K1.ⓑ{I1}V1.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #I1 #K1 #V1 #H destruct
+| #L1 #L2 #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #W #e #_ #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #I #W1 #W2 #e #_ #I1 #K1 #V1 #_ #H
+  elim (lt_zero_false … H)
+| #L1 #L2 #J1 #J2 #W1 #W2 #d #e #HL12 #I1 #K1 #V1 #H #_ destruct /2 width=5/
+]
+qed.
+
+lemma lsubr_inv_skip2: ∀I2,L1,K2,V2,d,e. L1 ⊑ [d, e] K2.ⓑ{I2}V2 → 0 < d →
+                       ∃∃I1,K1,V1. K1 ⊑ [d - 1, e] K2 & L1 = K1.ⓑ{I1}V1.
+/2 width=5/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+fact lsubr_fwd_length_full1_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
+                                 d = 0 → e = |L1| → |L1| ≤ |L2|.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize
+[ //
+| /2 width=1/
+| /3 width=1/
+| /3 width=1/
+| #L1 #L2 #_ #_ #_ #_ #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma lsubr_fwd_length_full1: ∀L1,L2. L1 ⊑ [0, |L1|] L2 → |L1| ≤ |L2|.
+/2 width=5/ qed-.
+
+fact lsubr_fwd_length_full2_aux: ∀L1,L2,d,e. L1 ⊑ [d, e] L2 →
+                                 d = 0 → e = |L2| → |L2| ≤ |L1|.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize
+[ //
+| /2 width=1/
+| /3 width=1/
+| /3 width=1/
+| #L1 #L2 #_ #_ #_ #_ #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma lsubr_fwd_length_full2: ∀L1,L2. L1 ⊑ [0, |L2|] L2 → |L2| ≤ |L1|.
+/2 width=5/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr_lbotr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/lsubr_lbotr.etc
new file mode 100644 (file)
index 0000000..b95a19b
--- /dev/null
@@ -0,0 +1,77 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⊒ [ term 46 d , break term 46 e ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'SubEqBottom $d $e $L2 }.
+
+include "basic_2/relocation/lsubr.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
+
+(* bottom element of the refinement *)
+definition lbotr: nat → nat → predicate lenv ≝
+   λd,e. NF_sn … (lsubr d e) (lsubr d e …).
+
+interpretation
+   "local environment full refinement (substitution)"
+   'SubEqBottom d e L = (lbotr d e L).
+
+(* Basic properties *********************************************************)
+
+lemma lbotr_atom: ∀d,e. ⊒[d, e] ⋆.
+#d #e #L #H
+elim (lsubr_inv_atom2 … H) -H
+[ #H destruct //
+| * #H1 #H2 destruct //
+]
+qed.
+
+lemma lbotr_OO: ∀L. ⊒[0, 0] L.
+// qed.
+
+lemma lbotr_abbr: ∀L,V,e. ⊒[0, e] L → ⊒[0, e + 1] L.ⓓV.
+#L #V #e #HL #K #H
+elim (lsubr_inv_abbr2 … H ?) -H // <minus_plus_m_m #X #HLX #H destruct
+lapply (HL … HLX) -HL -HLX /2 width=1/
+qed.
+
+lemma lbotr_abbr_O: ∀L,V. ⊒[0,1] L.ⓓV.
+#L #V
+@(lbotr_abbr … 0) //
+qed.
+
+lemma lbotr_skip: ∀I,L,V,d,e. ⊒[d, e] L → ⊒[d + 1, e] L.ⓑ{I}V.
+#I #L #V #d #e #HL #K #H
+elim (lsubr_inv_skip2 … H ?) -H // <minus_plus_m_m #J #X #W #HLX #H destruct
+lapply (HL … HLX) -HL -HLX /2 width=1/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lbotr_inv_bind: ∀I,L,V,e. ⊒[0, e] L.ⓑ{I}V → 0 < e →
+                      ⊒[0, e - 1] L ∧ I = Abbr.
+#I #L #V #e #HL #He
+lapply (HL (L.ⓓV) ?) /2 width=1/ #H
+elim (lsubr_inv_abbr2 … H ?) -H // #K #_ #H destruct
+@conj // #L #HKL
+lapply (HL (L.ⓓV) ?) -HL /2 width=1/ -HKL #H
+elim (lsubr_inv_abbr2 … H ?) -H // -He #X #HLX #H destruct //
+qed-.
+
+lemma lbotr_inv_skip: ∀I,L,V,d,e. ⊒[d, e] L.ⓑ{I}V → 0 < d → ⊒[d - 1, e] L.
+#I #L #V #d #e #HL #Hd #K #HLK
+lapply (HL (K.ⓑ{I}V) ?) -HL /2 width=1/ -HLK #H
+elim (lsubr_inv_skip2 … H ?) -H // -Hd #J #X #W #HKX #H destruct //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr.etc
new file mode 100644 (file)
index 0000000..a910ea7
--- /dev/null
@@ -0,0 +1,67 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lenv_px.ma".
+include "basic_2/reducibility/tpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+definition ltpr: relation lenv ≝ lpx tpr.
+
+interpretation
+  "context-free parallel reduction (environment)"
+  'PRed L1 L2 = (ltpr L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma ltpr_refl: reflexive … ltpr.
+/2 width=1/ qed.
+
+lemma ltpr_append: ∀K1,K2. K1 ➡ K2 → ∀L1,L2:lenv. L1 ➡ L2 → K1 @@ L1 ➡ K2 @@ L2.
+/2 width=1/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+(* Basic_1: was: wcpr0_gen_sort *)
+lemma ltpr_inv_atom1: ∀L2. ⋆ ➡ L2 → L2 = ⋆.
+/2 width=2 by lpx_inv_atom1/ qed-.
+
+(* Basic_1: was: wcpr0_gen_head *)
+lemma ltpr_inv_pair1: ∀K1,I,V1,L2. K1. ⓑ{I} V1 ➡ L2 →
+                      ∃∃K2,V2. K1 ➡ K2 & V1 ➡ V2 & L2 = K2. ⓑ{I} V2.
+/2 width=1 by lpx_inv_pair1/ qed-.
+
+lemma ltpr_inv_atom2: ∀L1. L1 ➡ ⋆ → L1 = ⋆.
+/2 width=2 by lpx_inv_atom2/ qed-.
+
+lemma ltpr_inv_pair2: ∀L1,K2,I,V2. L1 ➡ K2. ⓑ{I} V2 →
+                      ∃∃K1,V1. K1 ➡ K2 & V1 ➡ V2 & L1 = K1. ⓑ{I} V1.
+/2 width=1 by lpx_inv_pair2/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma ltpr_fwd_length: ∀L1,L2. L1 ➡ L2 → |L1| = |L2|.
+/2 width=2 by lpx_fwd_length/ qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma ltpr_inv_append1: ∀K1,L1. ∀L:lenv. K1 @@ L1 ➡ L →
+                        ∃∃K2,L2. K1 ➡ K2 & L1 ➡ L2 & L = K2 @@ L2.
+/2 width=1 by lpx_inv_append1/ qed-.
+
+lemma ltpr_inv_append2: ∀L:lenv. ∀K2,L2. L ➡ K2 @@ L2 →
+                        ∃∃K1,L1. K1 ➡ K2 & L1 ➡ L2 & L = K1 @@ L1.
+/2 width=1 by lpx_inv_append2/ qed-.
+
+(* Basic_1: removed theorems 2: wcpr0_getl wcpr0_getl_back *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_aaa.etc
new file mode 100644 (file)
index 0000000..5208a64
--- /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/static/aaa_ltpss_dx.ma".
+include "basic_2/static/lsuba_aaa.ma".
+include "basic_2/reducibility/ltpr_ldrop.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_ltpr_tpr_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A → ∀L2. L1 ➡ L2 →
+                         ∀T2. T1 ➡ T2 → L2 ⊢ T2 ⁝ A.
+#L1 #T1 @(f2_ind … fw … L1 T1) -L1 -T1 #n #IH #L1 * *
+[1,2,3:
+  #i #Hn #X #H1 #L2 #HL12 #Y #H2 destruct
+  >(tpr_inv_atom1 … H2) -Y
+|4,5: [ #a ] * #V1 #T1 #Hn #X #H1 #L2 #HL12 #Y #H2 destruct
+]
+[ >(aaa_inv_sort … H1) -X //
+| elim (aaa_inv_lref … H1) #I #K1 #V1 #HLK1 #HA
+  lapply (ldrop_pair2_fwd_fw … HLK1 (#i)) #HKV1
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #Y #H #HLK2
+  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
+  lapply (IH … HKV1 … HA … HK12 … HV12) -L1 -K1 -V1 /2 width=5/
+| elim (aaa_inv_gref … H1)
+| elim (aaa_inv_abbr … H1) -H1 #B #HB #HA
+  elim (tpr_inv_abbr1 … H2) -H2 *
+  [ #V2 #T #T2 #HV12 #HT1 #HT2 #H destruct
+    lapply (tps_lsubr_trans … HT2 (L2.ⓓV2) ?) -HT2 /2 width=1/ #HT2
+    lapply (IH … HB … HL12 … HV12) -HB /width=5/ #HB
+    lapply (IH … HA … (L2.ⓓV2) … HT1) -IH -HA -HT1 /width=5/ -T1 /2 width=1/ -L1 -V1 /3 width=5/
+  | -B #T #HT1 #HXT #H destruct
+    lapply (IH … HA … (L2.ⓓV1) … HT1) /width=5/ -T1 /2 width=1/ -L1 #HA
+    @(aaa_inv_lift … HA … HXT) /2 width=1/
+  ]
+| elim (aaa_inv_abst … H1) -H1 #B #A #HB #HA #H destruct
+  elim (tpr_inv_abst1 … H2) -H2 #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (IH … HB … HL12 … HV12) -HB /width=5/ #HB
+  lapply (IH … HA … (L2.ⓛV2) … HT12) -IH -HA -HT12 /width=5/ -T1 /2 width=1/
+| elim (aaa_inv_appl … H1) -H1 #B #HB #HA
+  elim (tpr_inv_appl1 … H2) -H2 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH … HB … HL12 … HV12) -HB -HV12 /width=5/ #HB
+    lapply (IH … HA … HL12 … HT12) -IH -HA -HL12 -HT12 /width=5/ /2 width=3/
+  | #b #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
+    elim (aaa_inv_abst … HA) -HA #B0 #A0 #HB0 #HA0 #H destruct
+    lapply (IH … HB … HL12 … HV12) -HB -HV12 /width=5/ #HB
+    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
+    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 // /2 width=1/ -T0 -L1 -V1 /4 width=7/
+  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
+    elim (aaa_inv_abbr … HA) -HA #B0 #HW0 #HT0
+    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
+    lapply (IH … HB … HL12 … HV10) -HB -HV10 /width=5/ #HV0
+    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 // /2 width=1/ -V1 -T0 -L1 -W0 #HT2
+    @(aaa_abbr … HW2) -HW2
+    @(aaa_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
+  ]
+| elim (aaa_inv_cast … H1) -H1 #HV1 #HT1
+  elim (tpr_inv_cast1 … H2) -H2
+  [ * #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
+    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
+  | -HV1 #HT1X
+     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
+  ]
+]
+qed.
+
+lemma aaa_ltpr_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. L1 ➡ L2 → L2 ⊢ T ⁝ A.
+/2 width=5/ qed.
+
+lemma aaa_tpr_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. T1 ➡ T2 → L ⊢ T2 ⁝ A.
+/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ldrop.etc
new file mode 100644 (file)
index 0000000..02404a1
--- /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/ldrop_lpx.ma".
+include "basic_2/substitution/fsup.ma".
+include "basic_2/reducibility/tpr_lift.ma".
+include "basic_2/reducibility/ltpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properies on local environment slicing ***********************************)
+
+(* Basic_1: was: wcpr0_drop *)
+lemma ltpr_ldrop_conf: dropable_sn ltpr.
+/3 width=3 by lpx_deliftable_dropable, tpr_inv_lift1/ qed.
+
+(* Basic_1: was: wcpr0_drop_back *)
+lemma ldrop_ltpr_trans: dedropable_sn ltpr.
+/2 width=3/ qed.
+
+lemma ltpr_ldrop_trans_O1: dropable_dx ltpr.
+/2 width=3/ qed.
+
+(* Properties on supclosure *************************************************)
+
+lemma fsub_tpr_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. T2 ➡ U2 →
+                      ∃∃L,U1. L1 ➡ L & T1 ➡ U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
+#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HK2
+elim (lift_total T d e) #U #HTU
+elim (ldrop_ltpr_trans … HLK1 … HK1) -HLK1 -HK1 #L #HL1 #HLK
+lapply (tpr_lift … HT1 … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpr.etc
new file mode 100644 (file)
index 0000000..4a27a6e
--- /dev/null
@@ -0,0 +1,29 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/tpr_tpr.ma".
+include "basic_2/reducibility/ltpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Main properties **********************************************************)
+
+theorem ltpr_conf: ∀L0:lenv. ∀L1. L0 ➡ L1 → ∀L2. L0 ➡ L2 →
+                   ∃∃L. L1 ➡ L & L2 ➡ L.
+#L0 #L1 #H elim H -L0 -L1 /2 width=3/
+#I #K0 #K1 #V0 #V1 #_ #HV01 #IHK01 #L2 #H
+elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK02 #HV02 #H destruct
+elim (IHK01 … HK02) -K0 #K #HK1 #HK2
+elim (tpr_conf … HV01 HV02) -V0 /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..00730b7
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_tpss.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properties concerning dx parallel unfold on local environments ***********)
+
+lemma ltpr_ltpss_dx_conf: ∀L1,K1,d,e. L1 ▶* [d, e] K1 → ∀L2. L1 ➡ L2 →
+                          ∃∃K2. L2 ▶* [d, e] K2 & K1 ➡ K2.
+#L1 #K1 #d #e #H elim H -L1 -K1 -d -e
+[ /2 width=3/
+| #L1 #I #V1 #X #H
+  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct /3 width=5/
+| #L1 #K1 #I #V1 #W1 #e #_ #HVW1 #IHLK1 #X #H
+  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
+  elim (IHLK1 … HL12) -L1 #K2 #HLK2 #HK12
+  elim (ltpr_tpr_tpss_conf … HK12 … HV12 … HVW1) -V1 /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d #e #_ #HVW1 #IHLK1 #X #H
+  elim (ltpr_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
+  elim (IHLK1 … HL12) -L1 #K2 #HLK2 #HK12
+  elim (ltpr_tpr_tpss_conf … HK12 … HV12 … HVW1) -V1 /3 width=5/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..79ffb7c
--- /dev/null
@@ -0,0 +1,31 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/reducibility/ltpr_ltpss_dx.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properties on sn parallel unfold on local environments *******************)
+
+(* Note: this can also be proved like ltpr_ltpss_dx_conf *)
+lemma ltpr_ltpss_sn_conf: ∀L1,K1,d,e. L1 ⊢ ▶* [d, e] K1 → ∀L2. L1 ➡ L2 →
+                          ∃∃K2. L2 ⊢ ▶* [d, e] K2 & K1 ➡ K2.
+#L1 #K1 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H
+@(ltpssa_ind … H) -K1 /2 width=3/
+#K #K1 #_ #HK1 #IHK #L2 #HL12
+elim (IHK … HL12) -L1 #K2 #HLK2 #HK2
+elim (ltpr_ltpss_dx_conf … HK1 … HK2) -K /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tps.etc
new file mode 100644 (file)
index 0000000..7f08be6
--- /dev/null
@@ -0,0 +1,57 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_ldrop.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properties concerning parallel substitution on terms *********************)
+
+(* Basic_1: was: pr0_subst1_fwd *)
+lemma ltpr_tps_conf: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶ [d, e] T2 → ∀L2. L1 ➡ L2 →
+                     ∃∃T. L2 ⊢ T1 ▶ [d, e] T & T2 ➡ T.
+#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
+[ /2 width=3/
+| #L1 #K1 #V1 #W1 #i #d #e #Hdi #Hide #HLK1 #HVW1 #L2 #HL12
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
+  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct -K1
+  elim (lift_total V2 0 (i+1)) #W2 #HVW2
+  lapply (tpr_lift … HV12 … HVW1 … HVW2) -V1 /3 width=4/
+| #L1 #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L2 #HL12
+  elim (IHV12 … HL12) -IHV12 #V #HV1 #HV2
+  elim (IHT12 (L2.ⓑ{I}V) ?) /2 width=1/ -L1 /3 width=5/
+| #L1 #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L2 #HL12
+  elim (IHV12 … HL12) -IHV12
+  elim (IHT12 … HL12) -L1 /3 width=5/
+]
+qed-.
+
+(* Basic_1: was: pr0_subst1_back *)
+lemma ltpr_tps_trans: ∀L2,T1,T2,d,e. L2 ⊢ T1 ▶ [d, e] T2 → ∀L1. L1 ➡ L2 →
+                      ∃∃T. L1 ⊢ T1 ▶ [d, e] T & T ➡ T2.
+#L2 #T1 #T2 #d #e #H elim H -L2 -T1 -T2 -d -e
+[ /2 width=3/
+| #L2 #K2 #V2 #W2 #i #d #e #Hdi #Hide #HLK2 #HVW2 #L1 #HL12
+  elim (ltpr_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
+  elim (ltpr_inv_pair2 … H) -H #K1 #V1 #HK12 #HV12 #H destruct -K2
+  elim (lift_total V1 0 (i+1)) #W1 #HVW1
+  lapply (tpr_lift … HV12 … HVW1 … HVW2) -V2 /3 width=4/
+| #L2 #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (IHV12 … HL12) -IHV12 #V #HV1 #HV2
+  elim (IHT12 (L1.ⓑ{I}V) ?) /2 width=1/ -L2 /3 width=5/
+| #L2 #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (IHV12 … HL12) -IHV12
+  elim (IHT12 … HL12) -L2 /3 width=5/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpr_tpss.etc
new file mode 100644 (file)
index 0000000..71586fa
--- /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/unfold/ltpss_dx_ltpss_dx.ma".
+include "basic_2/reducibility/ltpr_tps.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
+
+(* Properties on partial unfold for terms ***********************************)
+
+(* Basic_1: was: pr0_subst1 *)
+lemma ltpr_tpr_tps_conf: ∀T1,T2. T1 ➡ T2 →
+                         ∀L1,d,e,U1. L1 ⊢ T1 ▶ [d, e] U1 →
+                         ∀L2. L1 ➡ L2 →
+                         ∃∃U2. U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
+#T1 #T2 #H elim H -T1 -T2
+[ #I #L1 #d #e #U1 #H #L2 #HL12
+  elim (ltpr_tps_conf … H … HL12) -L1 /3 width=3/
+| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_flat1 … H) -H #W1 #U1 #HVW1 #HTU1 #H destruct
+  elim (IHV12 … HVW1 … HL12) -V1
+  elim (IHT12 … HTU1 … HL12) -T1 -HL12 /3 width=5/
+| #a #V1 #V2 #W #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_flat1 … H) -H #VV1 #Y #HVV1 #HY #HX destruct
+  elim (tps_inv_bind1 … HY) -HY #WW #TT1 #_ #HTT1 #H destruct
+  elim (IHV12 … HVV1 … HL12) -V1 #VV2 #HVV12 #HVV2
+  elim (IHT12 … HTT1 (L2. ⓛWW) ?) -T1 /2 width=1/ -HL12 #TT2 #HTT12 #HTT2
+  lapply (tpss_lsubr_trans … HTT2 (L2. ⓓVV2) ?) -HTT2 /3 width=5/
+| #a #I #V1 #V2 #T1 #T #T2 #HV12 #_ #HT2 #IHV12 #IHT1 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_bind1 … H) -H #W1 #U1 #HVW1 #HTU1 #H destruct
+  elim (IHV12 … HVW1 … HL12) -V1 #W2 #HW12 #HVW2
+  elim (IHT1 … HTU1 (L2. ⓑ{I} W2) ?) -T1 /2 width=1/ -HL12 #U #HU1 #HTU
+  elim (tpss_strip_neq … HTU … HT2 ?) -T /2 width=1/ #U2 #HU2 #HTU2
+  lapply (tps_lsubr_trans … HU2 (L2. ⓑ{I} V2) ?) -HU2 /2 width=1/ #HU2
+  elim (ltpss_dx_tps_conf … HU2 (L2. ⓑ{I} W2) (d + 1) e ?) -HU2 /2 width=1/ #U3 #HU3 #HU23
+  lapply (tps_lsubr_trans … HU3 (⋆. ⓑ{I} W2) ?) -HU3 /2 width=1/ #HU3
+  lapply (tpss_lsubr_trans … HU23 (L2. ⓑ{I} W2) ?) -HU23 /2 width=1/ #HU23
+  lapply (tpss_trans_eq … HTU2 … HU23) -U2 /3 width=5/
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_flat1 … H) -H #VV1 #Y #HVV1 #HY #HX destruct
+  elim (tps_inv_bind1 … HY) -HY #WW1 #TT1 #HWW1 #HTT1 #H destruct
+  elim (IHV12 … HVV1 … HL12) -V1 #VV2 #HVV12 #HVV2
+  elim (IHW12 … HWW1 … HL12) -W1 #WW2 #HWW12 #HWW2
+  elim (IHT12 … HTT1 (L2. ⓓWW2) ?) -T1 /2 width=1/ -HL12 #TT2 #HTT12 #HTT2
+  elim (lift_total VV2 0 1) #VV #H2VV
+  lapply (tpss_lift_ge … HVV2 (L2. ⓓWW2) … HV2 … H2VV) -V2 /2 width=1/ #HVV
+  @ex2_intro [2: @tpr_theta |1: skip |3: @tpss_bind [2: @tpss_flat ] ] /width=11/ (**) (* /4 width=11/ is too slow *)
+| #V #T1 #T #T2 #_ #HT2 #IHT1 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_bind1 … H) -H #W #U1 #_ #HTU1 #H destruct -V
+  elim (IHT1 … HTU1 (L2.ⓓW) ?) -T1 /2 width=1/ -HL12 #U #HU1 #HTU
+  elim (tpss_inv_lift1_ge … HTU L2 … HT2 ?) -T <minus_plus_m_m /3 width=3/
+| #V1 #T1 #T2 #_ #IHT12 #L1 #d #e #X #H #L2 #HL12
+  elim (tps_inv_flat1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct
+  elim (IHT12 … HTT1 … HL12) -T1 -HL12 /3 width=3/
+]
+qed-.
+
+lemma tpr_tps_conf_bind: ∀I,V1,V2,T1,T2,U1. V1 ➡ V2 → T1 ➡ T2 →
+                         ⋆. ⓑ{I} V1 ⊢ T1 ▶ [0, 1] U1 →
+                         ∃∃U2. U1 ➡ U2 & ⋆. ⓑ{I} V2 ⊢ T2 ▶ [0, 1] U2.
+#I #V1 #V2 #T1 #T2 #U1 #HV12 #HT12 #HTU1
+elim (ltpr_tpr_tps_conf … HT12 … HTU1 (⋆. ⓑ{I} V2) ?) -T1 /2 width=1/ -V1 #U2 #HU12 #HTU2
+lapply (tpss_inv_SO2 … HTU2) -HTU2 /2 width=3/
+qed-.
+
+lemma ltpr_tpr_tpss_conf: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. T1 ➡ T2 →
+                          ∀d,e,U1. L1 ⊢ T1 ▶* [d, e] U1 →
+                          ∃∃U2. U1 ➡ U2 & L2 ⊢ T2 ▶* [d, e] U2.
+#L1 #L2 #HL12 #T1 #T2 #HT12 #d #e #U1 #HTU1 @(tpss_ind … HTU1) -U1
+[ /2 width=3/
+| -HT12 #U #U1 #_ #HU1 * #T #HUT #HT2
+  elim (ltpr_tpr_tps_conf … HUT … HU1 … HL12) -U -HL12 #U2 #HU12 #HTU2
+  lapply (tpss_trans_eq … HT2 … HTU2) -T /2 width=3/
+]
+qed-.
+
+lemma tpr_tpss_conf: ∀T1,T2. T1 ➡ T2 →
+                     ∀L,U1,d,e. L ⊢ T1 ▶* [d, e] U1 →
+                     ∃∃U2. U1 ➡ U2 & L ⊢ T2 ▶* [d, e] U2.
+/2 width=5 by ltpr_tpr_tpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs.etc
new file mode 100644 (file)
index 0000000..8e0c32e
--- /dev/null
@@ -0,0 +1,90 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr.ma".
+include "basic_2/computation/tprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
+
+definition ltprs: relation lenv ≝ TC … ltpr.
+
+interpretation
+  "context-free parallel computation (environment)"
+  'PRedStar L1 L2 = (ltprs L1 L2).
+
+(* Basic eliminators ********************************************************)
+
+lemma ltprs_ind: ∀L1. ∀R:predicate lenv. R L1 →
+                 (∀L,L2. L1 ➡* L → L ➡ L2 → R L → R L2) →
+                 ∀L2. L1 ➡* L2 → R L2.
+#L1 #R #HL1 #IHL1 #L2 #HL12
+@(TC_star_ind … HL1 IHL1 … HL12) //
+qed-.
+
+lemma ltprs_ind_dx: ∀L2. ∀R:predicate lenv. R L2 →
+                    (∀L1,L. L1 ➡ L → L ➡* L2 → R L → R L1) →
+                    ∀L1. L1 ➡* L2 → R L1.
+#L2 #R #HL2 #IHL2 #L1 #HL12
+@(TC_star_ind_dx … HL2 IHL2 … HL12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma ltprs_refl: reflexive … ltprs.
+/2 width=1/ qed.
+
+lemma ltpr_ltprs: ∀L1,L2. L1 ➡ L2 → L1 ➡* L2.
+/2 width=1/ qed.
+
+lemma ltprs_strap1: ∀L1,L,L2. L1 ➡* L → L ➡ L2 → L1 ➡* L2.
+/2 width=3/ qed.
+
+lemma ltprs_strap2: ∀L1,L,L2. L1 ➡ L → L ➡* L2 → L1 ➡* L2.
+/2 width=3/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma ltprs_inv_atom1: ∀L2. ⋆ ➡* L2 → L2 = ⋆.
+#L2 #H @(ltprs_ind … H) -L2 //
+#L #L2 #_ #HL2 #IHL1 destruct
+>(ltpr_inv_atom1 … HL2) -L2 //
+qed-.
+
+lemma ltprs_inv_pair1: ∀I,K1,L2,V1. K1. ⓑ{I} V1 ➡* L2 →
+                       ∃∃K2,V2. K1 ➡* K2 & V1 ➡* V2 & L2 = K2. ⓑ{I} V2.
+#I #K1 #L2 #V1 #H @(ltprs_ind … H) -L2 /2 width=5/
+#L #L2 #_ #HL2 * #K #V #HK1 #HV1 #H destruct
+elim (ltpr_inv_pair1 … HL2) -HL2 #K2 #V2 #HK2 #HV2 #H destruct /3 width=5/
+qed-.
+
+lemma ltprs_inv_atom2: ∀L1. L1 ➡* ⋆ → L1 = ⋆.
+#L1 #H @(ltprs_ind_dx … H) -L1 //
+#L1 #L #HL1 #_ #IHL2 destruct
+>(ltpr_inv_atom2 … HL1) -L1 //
+qed-.
+
+lemma ltprs_inv_pair2: ∀I,L1,K2,V2. L1 ➡* K2. ⓑ{I} V2 →
+                       ∃∃K1,V1. K1 ➡* K2 & V1 ➡* V2 & L1 = K1. ⓑ{I} V1.
+#I #L1 #K2 #V2 #H @(ltprs_ind_dx … H) -L1 /2 width=5/
+#L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
+elim (ltpr_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct /3 width=5/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma ltprs_fwd_length: ∀L1,L2. L1 ➡* L2 → |L1| = |L2|.
+#L1 #L2 #H @(ltprs_ind … H) -L2 //
+#L #L2 #_ #HL2 #IHL1
+>IHL1 -L1 >(ltpr_fwd_length … HL2) -HL2 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_alt.etc
new file mode 100644 (file)
index 0000000..1d2db2d
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+notation "hvbox( T1 ➡ ➡ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PRedStarAlt $T1 $T2 }.
+
+include "basic_2/computation/ltprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
+
+(* alternative definition of ltprs *)
+definition ltprsa: relation lenv ≝ lpx tprs.
+
+interpretation
+  "context-free parallel computation (environment) alternative"
+  'PRedStarAlt L1 L2 = (ltprsa L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma ltprs_ltprsa: ∀L1,L2. L1 ➡* L2 → L1 ➡➡* L2.
+/2 width=1/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma ltprsa_ltprs: ∀L1,L2. L1 ➡➡* L2 → L1 ➡* L2.
+/2 width=1/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ldrop.etc
new file mode 100644 (file)
index 0000000..a7c3200
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_ldrop.ma".
+include "basic_2/computation/ltprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
+
+lemma ltprs_ldrop_conf: dropable_sn ltprs.
+/2 width=3/ qed.
+
+lemma ldrop_ltprs_trans: dedropable_sn ltprs.
+/2 width=3/ qed.
+
+lemma ltprs_ldrop_trans_O1: dropable_dx ltprs.
+/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ltprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltprs_ltprs.etc
new file mode 100644 (file)
index 0000000..7ededf2
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_ltpr.ma".
+include "basic_2/computation/ltprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ******************)
+
+(* Advanced properties ******************************************************)
+
+lemma ltprs_strip: ∀L1. ∀L:lenv. L ➡* L1 → ∀L2. L ➡ L2 →
+                   ∃∃L0. L1 ➡ L0 & L2 ➡* L0.
+/3 width=3/ qed.
+
+(* Main properties **********************************************************)
+
+theorem ltprs_conf: confluent … ltprs.
+/3 width=3/ qed.
+
+theorem ltprs_trans: Transitive … ltprs.
+/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx.etc
new file mode 100644 (file)
index 0000000..753c948
--- /dev/null
@@ -0,0 +1,278 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( T1 break ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStar $T1 $d $e $T2 }.
+
+include "basic_2/unfold/tpss.ma".
+
+(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Basic_1: includes: csubst1_bind *)
+inductive ltpss_dx: nat → nat → relation lenv ≝
+| ltpss_dx_atom : ∀d,e. ltpss_dx d e (⋆) (⋆)
+| ltpss_dx_pair : ∀L,I,V. ltpss_dx 0 0 (L. ⓑ{I} V) (L. ⓑ{I} V)
+| ltpss_dx_tpss2: ∀L1,L2,I,V1,V2,e.
+                  ltpss_dx 0 e L1 L2 → L2 ⊢ V1 ▶* [0, e] V2 →
+                  ltpss_dx 0 (e + 1) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
+| ltpss_dx_tpss1: ∀L1,L2,I,V1,V2,d,e.
+                  ltpss_dx d e L1 L2 → L2 ⊢ V1 ▶* [d, e] V2 →
+                  ltpss_dx (d + 1) e (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
+.
+
+interpretation "parallel unfold (local environment, dx variant)"
+   'PSubstStar L1 d e L2 = (ltpss_dx d e L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact ltpss_dx_inv_refl_O2_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → e = 0 → L1 = L2.
+#d #e #L1 #L2 #H elim H -d -e -L1 -L2 //
+[ #L1 #L2 #I #V1 #V2 #e #_ #_ #_ >commutative_plus normalize #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #HV12 #IHL12 #He destruct
+  >(IHL12 ?) -IHL12 // >(tpss_inv_refl_O2 … HV12) //
+]
+qed.
+
+lemma ltpss_dx_inv_refl_O2: ∀d,L1,L2. L1 ▶* [d, 0] L2 → L1 = L2.
+/2 width=4/ qed-.
+
+fact ltpss_dx_inv_atom1_aux: ∀d,e,L1,L2.
+                             L1 ▶* [d, e] L2 → L1 = ⋆ → L2 = ⋆.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ //
+| #L #I #V #H destruct
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
+]
+qed.
+
+lemma ltpss_dx_inv_atom1: ∀d,e,L2. ⋆ ▶* [d, e] L2 → L2 = ⋆.
+/2 width=5/ qed-.
+
+fact ltpss_dx_inv_tpss21_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → d = 0 → 0 < e →
+                              ∀K1,I,V1. L1 = K1. ⓑ{I} V1 →
+                              ∃∃K2,V2. K1 ▶* [0, e - 1] K2 &
+                                       K2 ⊢ V1 ▶* [0, e - 1] V2 &
+                                       L2 = K2. ⓑ{I} V2.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #_ #K1 #I #V1 #H destruct
+| #L1 #I #V #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K1 #J #W1 #H destruct /2 width=5/
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma ltpss_dx_inv_tpss21: ∀e,K1,I,V1,L2. K1. ⓑ{I} V1 ▶* [0, e] L2 → 0 < e →
+                           ∃∃K2,V2. K1 ▶* [0, e - 1] K2 &
+                                    K2 ⊢ V1 ▶* [0, e - 1] V2 &
+                                    L2 = K2. ⓑ{I} V2.
+/2 width=5/ qed-.
+
+fact ltpss_dx_inv_tpss11_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → 0 < d →
+                              ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
+                              ∃∃K2,V2. K1 ▶* [d - 1, e] K2 &
+                                       K2 ⊢ V1 ▶* [d - 1, e] V2 &
+                                       L2 = K2. ⓑ{I} V2.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #I #K1 #V1 #H destruct
+| #L #I #V #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K1 #W1 #H destruct /2 width=5/
+]
+qed.
+
+lemma ltpss_dx_inv_tpss11: ∀d,e,I,K1,V1,L2. K1. ⓑ{I} V1 ▶* [d, e] L2 → 0 < d →
+                           ∃∃K2,V2. K1 ▶* [d - 1, e] K2 &
+                                    K2 ⊢ V1 ▶* [d - 1, e] V2 &
+                                    L2 = K2. ⓑ{I} V2.
+/2 width=3/ qed-.
+
+fact ltpss_dx_inv_atom2_aux: ∀d,e,L1,L2.
+                             L1 ▶* [d, e] L2 → L2 = ⋆ → L1 = ⋆.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ //
+| #L #I #V #H destruct
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
+]
+qed.
+
+lemma ltpss_dx_inv_atom2: ∀d,e,L1. L1 ▶* [d, e] ⋆ → L1 = ⋆.
+/2 width=5/ qed-.
+
+fact ltpss_dx_inv_tpss22_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → d = 0 → 0 < e →
+                              ∀K2,I,V2. L2 = K2. ⓑ{I} V2 →
+                              ∃∃K1,V1. K1 ▶* [0, e - 1] K2 &
+                                       K2 ⊢ V1 ▶* [0, e - 1] V2 &
+                                       L1 = K1. ⓑ{I} V1.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #_ #K1 #I #V1 #H destruct
+| #L1 #I #V #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K2 #J #W2 #H destruct /2 width=5/
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma ltpss_dx_inv_tpss22: ∀e,L1,K2,I,V2. L1 ▶* [0, e] K2. ⓑ{I} V2 → 0 < e →
+                           ∃∃K1,V1. K1 ▶* [0, e - 1] K2 &
+                                    K2 ⊢ V1 ▶* [0, e - 1] V2 &
+                                    L1 = K1. ⓑ{I} V1.
+/2 width=5/ qed-.
+
+fact ltpss_dx_inv_tpss12_aux: ∀d,e,L1,L2. L1 ▶* [d, e] L2 → 0 < d →
+                              ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
+                              ∃∃K1,V1. K1 ▶* [d - 1, e] K2 &
+                                       K2 ⊢ V1 ▶* [d - 1, e] V2 &
+                                       L1 = K1. ⓑ{I} V1.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #I #K2 #V2 #H destruct
+| #L #I #V #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K2 #W2 #H destruct /2 width=5/
+]
+qed.
+
+lemma ltpss_dx_inv_tpss12: ∀L1,K2,I,V2,d,e. L1 ▶* [d, e] K2. ⓑ{I} V2 → 0 < d →
+                           ∃∃K1,V1. K1 ▶* [d - 1, e] K2 &
+                                    K2 ⊢ V1 ▶* [d - 1, e] V2 &
+                                    L1 = K1. ⓑ{I} V1.
+/2 width=3/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma ltpss_dx_tps2: ∀L1,L2,I,V1,V2,e.
+                     L1 ▶* [0, e] L2 → L2 ⊢ V1 ▶ [0, e] V2 →
+                     L1. ⓑ{I} V1 ▶* [0, e + 1] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_dx_tps1: ∀L1,L2,I,V1,V2,d,e.
+                     L1 ▶* [d, e] L2 → L2 ⊢ V1 ▶ [d, e] V2 →
+                     L1. ⓑ{I} V1 ▶* [d + 1, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_dx_tpss2_lt: ∀L1,L2,I,V1,V2,e.
+                         L1 ▶* [0, e - 1] L2 → L2 ⊢ V1 ▶* [0, e - 1] V2 →
+                         0 < e → L1. ⓑ{I} V1 ▶* [0, e] L2. ⓑ{I} V2.
+#L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #He
+>(plus_minus_m_m e 1) /2 width=1/
+qed.
+
+lemma ltpss_dx_tpss1_lt: ∀L1,L2,I,V1,V2,d,e.
+                         L1 ▶* [d - 1, e] L2 → L2 ⊢ V1 ▶* [d - 1, e] V2 →
+                         0 < d → L1. ⓑ{I} V1 ▶* [d, e] L2. ⓑ{I} V2.
+#L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #Hd
+>(plus_minus_m_m d 1) /2 width=1/
+qed.
+
+lemma ltpss_dx_tps2_lt: ∀L1,L2,I,V1,V2,e.
+                        L1 ▶* [0, e - 1] L2 → L2 ⊢ V1 ▶ [0, e - 1] V2 →
+                        0 < e → L1. ⓑ{I} V1 ▶* [0, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_dx_tps1_lt: ∀L1,L2,I,V1,V2,d,e.
+                        L1 ▶* [d - 1, e] L2 → L2 ⊢ V1 ▶ [d - 1, e] V2 →
+                        0 < d → L1. ⓑ{I} V1 ▶* [d, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+(* Basic_1: was by definition: csubst1_refl *)
+lemma ltpss_dx_refl: ∀L,d,e. L ▶* [d, e] L.
+#L elim L -L //
+#L #I #V #IHL * /2 width=1/ * /2 width=1/
+qed.
+
+lemma ltpss_dx_weak: ∀L1,L2,d1,e1. L1 ▶* [d1, e1] L2 →
+                     ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 → L1 ▶* [d2, e2] L2.
+#L1 #L2 #d1 #e1 #H elim H -L1 -L2 -d1 -e1 //
+[ #L1 #L2 #I #V1 #V2 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd2 #Hde2
+  lapply (le_n_O_to_eq … Hd2) #H destruct normalize in Hde2;
+  lapply (lt_to_le_to_lt 0 … Hde2) // #He2
+  lapply (le_plus_to_minus_r … Hde2) -Hde2 /3 width=5/
+| #L1 #L2 #I #V1 #V2 #d1 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd21 #Hde12
+  >plus_plus_comm_23 in Hde12; #Hde12
+  elim (le_to_or_lt_eq 0 d2 ?) // #H destruct
+  [ lapply (le_plus_to_minus_r … Hde12) -Hde12 <plus_minus // #Hde12
+    lapply (le_plus_to_minus … Hd21) -Hd21 #Hd21 /3 width=5/
+  | -Hd21 normalize in Hde12;
+    lapply (lt_to_le_to_lt 0 … Hde12) // #He2
+    lapply (le_plus_to_minus_r … Hde12) -Hde12
+    /3 width=5 by ltpss_dx_tpss2_lt, tpss_weak/ (**) (* /3 width=5/ used to work *)
+  ]
+]
+qed.
+
+lemma ltpss_dx_weak_full: ∀L1,L2,d,e. L1 ▶* [d, e] L2 → L1 ▶* [0, |L2|] L2.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
+// /3 width=2/ /3 width=3/
+qed.
+
+fact ltpss_dx_append_le_aux: ∀K1,K2,d,x. K1 ▶* [d, x] K2 → x = |K1| - d →
+                             ∀L1,L2,e. L1 ▶* [0, e] L2 → d ≤ |K1| →
+                             L1 @@ K1 ▶* [d, x + e] L2 @@ K2.
+#K1 #K2 #d #x #H elim H -K1 -K2 -d -x
+[ #d #x #H1 #L1 #L2 #e #HL12 #H2 destruct
+  lapply (le_n_O_to_eq … H2) -H2 #H destruct //
+| #K #I #V <minus_n_O normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #x #_ #HV12 <minus_n_O #IHK12 <minus_n_O #H #L1 #L2 #e #HL12 #_
+  lapply (injective_plus_l … H) -H #H destruct >plus_plus_comm_23
+  /4 width=5 by ltpss_dx_tpss2, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
+| #K1 #K2 #I #V1 #V2 #d #x #_ #HV12 #IHK12 normalize <minus_le_minus_minus_comm // <minus_plus_m_m #H1 #L1 #L2 #e #HL12 #H2 destruct
+  lapply (le_plus_to_le_r … H2) -H2 #Hd
+  /4 width=5 by ltpss_dx_tpss1, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
+]
+qed-.
+
+lemma ltpss_dx_append_le: ∀K1,K2,d. K1 ▶* [d, |K1| - d] K2 →
+                          ∀L1,L2,e. L1 ▶* [0, e] L2 → d ≤ |K1| →
+                          L1 @@ K1 ▶* [d, |K1| - d + e] L2 @@ K2.
+/2 width=1 by ltpss_dx_append_le_aux/ qed.
+
+lemma ltpss_dx_append_zero: ∀K1,K2. K1 ▶* [0, |K1|] K2 →
+                            ∀L1,L2,e. L1 ▶* [0, e] L2 →
+                            L1 @@ K1 ▶* [0, |K1| + e] L2 @@ K2.
+/2 width=1/ qed.
+
+lemma ltpss_dx_append_ge: ∀K1,K2,d,e. K1 ▶* [d, e] K2 →
+                          ∀L1,L2. L1 ▶* [d - |K1|, e] L2 → |K1| ≤ d →
+                          L1 @@ K1 ▶* [d, e] L2 @@ K2.
+#K1 #K2 #d #e #H elim H -K1 -K2 -d -e
+[ #d #e #L1 #L2 <minus_n_O //
+| #K #I #V #L1 #L2 #_ #H
+  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #e #_ #_ #_ #L1 #L2 #_ #H
+  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #d #e #_ #HV12 #IHK12 #L1 #L2
+  normalize <minus_le_minus_minus_comm // <minus_plus_m_m #HL12 #H
+  lapply (le_plus_to_le_r … H) -H /3 width=1/
+]
+qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma ltpss_dx_fwd_length: ∀L1,L2,d,e. L1 ▶* [d, e] L2 → |L1| = |L2|.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
+normalize //
+qed-.
+
+(* Basic_1: removed theorems 28:
+            csubst0_clear_O csubst0_drop_lt csubst0_drop_gt csubst0_drop_eq
+            csubst0_clear_O_back csubst0_clear_S csubst0_clear_trans
+            csubst0_drop_gt_back csubst0_drop_eq_back csubst0_drop_lt_back
+            csubst0_gen_sort csubst0_gen_head csubst0_getl_ge csubst0_getl_lt
+            csubst0_gen_S_bind_2 csubst0_getl_ge_back csubst0_getl_lt_back
+            csubst0_snd_bind csubst0_fst_bind csubst0_both_bind
+            csubst1_head csubst1_flat csubst1_gen_head
+            csubst1_getl_ge csubst1_getl_lt csubst1_getl_ge_back getl_csubst1
+            fsubst0_gen_base
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ldrop.etc
new file mode 100644 (file)
index 0000000..0b6c504
--- /dev/null
@@ -0,0 +1,230 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fsup.ma".
+include "basic_2/unfold/tpss_lift.ma".
+include "basic_2/unfold/ltpss_dx.ma".
+
+(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properies on local environment slicing ***********************************)
+
+lemma ltpss_dx_ldrop_conf_ge: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                              d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
+| //
+| normalize #K0 #K1 #I #V0 #V1 #e1 #_ #_ #IHK01 #L2 #e2 #H #He12
+  elim (le_inv_plus_l … He12) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
+| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
+]
+qed.
+
+lemma ltpss_dx_ldrop_trans_ge: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                               d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
+| //
+| normalize #K1 #K0 #I #V1 #V0 #e1 #_ #_ #IHK10 #L2 #e2 #H #He12
+  elim (le_inv_plus_l … He12) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK10 … HK0L2 ?) -K0 /2 width=1/
+| #K0 #K1 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK10 … HK0L2 ?) -IHK10 -HK0L2 /2 width=1/
+]
+qed.
+
+lemma ltpss_dx_ldrop_conf_be: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
+                              ∃∃L. L2 ▶* [0, d1 + e1 - e2] L & ⇩[0, e2] L1 ≡ L.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
+  lapply (le_n_O_to_eq … He2) -He2 #H destruct
+  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
+| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #_ #He21
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK01 -He21 destruct <minus_n_O /3 width=3/
+  | -HK01 -HV01 <minus_le_minus_minus_comm //
+    elim (IHK01 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
+  ]
+| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2 #He2de1
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  <minus_le_minus_minus_comm //
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  elim (IHK01 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
+]
+qed.
+
+lemma ltpss_dx_ldrop_trans_be: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
+                               ∃∃L. L ▶* [0, d1 + e1 - e2] L2 & ⇩[0, e2] L1 ≡ L.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
+  lapply (le_n_O_to_eq … He2) -He2 #H destruct
+  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
+| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #_ #He21
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK10 -He21 destruct <minus_n_O /3 width=3/
+  | -HK10 -HV10 <minus_le_minus_minus_comm //
+    elim (IHK10 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
+  ]
+| #K1 #K0 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2 #He2de1
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  <minus_le_minus_minus_comm //
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  elim (IHK10 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
+]
+qed.
+
+lemma ltpss_dx_ldrop_conf_le: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                              ∃∃L. L2 ▶* [d1 - e2, e1] L & ⇩[0, e2] L1 ≡ L.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #_ #L2 #e2 #H #He2
+  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
+  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
+| #K0 #K1 #I #V0 #V1 #d1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #He2d1
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK01 -He2d1 destruct <minus_n_O /3 width=3/
+  | -HK01 -HV01 <minus_le_minus_minus_comm //
+    elim (IHK01 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
+  ]
+]
+qed.
+
+lemma ltpss_dx_ldrop_trans_le: ∀L1,L0,d1,e1. L1 ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                               ∃∃L. L ▶* [d1 - e2, e1] L2 & ⇩[0, e2] L1 ≡ L.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #_ #L2 #e2 #H #He2
+  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
+  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
+| #K1 #K0 #I #V1 #V0 #d1 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #He2d1
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK10 -He2d1 destruct <minus_n_O /3 width=3/
+  | -HK10 -HV10 <minus_le_minus_minus_comm //
+    elim (IHK10 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
+  ]
+]
+qed.
+
+lemma ldrop_ltpss_dx_trans_le: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 → d1 ≤ d2 →
+                               ∃∃L2. L1 ▶* [d2 + e1, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_
+  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #Hd
+  elim (IHLK1 … HK12 Hd) -K1 -Hd /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #_ #HWV1 #IHLK1 #X #d2 #e2 #H #Hd12
+  elim (le_inv_plus_l … Hd12) -Hd12 #Hd12 #Hd2
+  elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+  elim (IHLK1 … HK12 … Hd12) -IHLK1 -HK12 <le_plus_minus_comm // #L2 #HL12 #HLK2
+  elim (lift_total W2 d1 e1) #V2 #HWV2
+  lapply (tpss_lift_ge … HW12 … HLK2 HWV1 … HWV2) -W1 // -Hd12
+  <le_plus_minus_comm // /4 width=5/
+]
+qed-.
+
+lemma ldrop_ltpss_dx_trans_be: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 →
+                               d2 ≤ d1 → d1 ≤ d2 + e2 →
+                               ∃∃L2. L1 ▶* [d2, e1 + e2] L2 &
+                                     ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_ #_
+  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H #_
+  lapply (le_n_O_to_eq … H) -H #H destruct /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H1 #H2
+  elim (IHLK1 … HK12 H1 H2) -K1 -H2
+  lapply (le_n_O_to_eq … H1) -H1 #H destruct /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #_ #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21 #Hd12
+  elim (eq_or_gt d2) #Hd2 [ -Hd21 elim (eq_or_gt e2) #He2 ] destruct
+  [ lapply (le_n_O_to_eq … Hd12) -Hd12 <plus_n_Sm #H destruct
+  | elim (ltpss_dx_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 // /2 width=1/ >plus_minus_commutative // #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_be … HW12 … HLK2 HWV1 … HWV2) -W1 // /2 width=1/
+    >plus_minus // >commutative_plus /4 width=5/
+  | elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // ] /2 width=1/ #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_be … HW12 … HLK2 HWV1 … HWV2) -W1 [ >plus_minus // ] /2 width=1/
+    >commutative_plus /3 width=5/
+  ]
+]
+qed-.
+
+lemma ldrop_ltpss_dx_trans_ge: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ▶* [d2, e2] K2 → d2 + e2 ≤ d1 →
+                               ∃∃L2. L1 ▶* [d2, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_
+  >(ltpss_dx_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H
+  elim (plus_le_0 … H) -H #H1 #H2 destruct /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H
+  elim (IHLK1 … HK12 H) -K1
+  elim (plus_le_0 … H) -H #H1 #H2 destruct #L2 #HL12
+  >(ltpss_dx_inv_refl_O2 … HL12) -L1 /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21
+  elim (eq_or_gt d2) #Hd2 [ elim (eq_or_gt e2) #He2 ] destruct
+  [ -IHLK1 -Hd21 <(ltpss_dx_inv_refl_O2 … H) -X /3 width=5/
+  | elim (ltpss_dx_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 /2 width=1/ #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_le … HW12 … HLK2 HWV1 … HWV2) -W1 /2 width=1/ /3 width=5/
+  | elim (ltpss_dx_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // /2 width=1/ ] #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_le … HW12 … HLK2 HWV1 … HWV2) -W1 [ >plus_minus // /2 width=1/ ] /3 width=5/
+  ]
+]
+qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma fsup_tps_trans_full: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶[0,|L2|] U2 →
+                           ∃∃L,U1. L1 ▶*[0,|L|] L & L ⊢ T1 ▶[0,|L|] U1 & ⦃L, U1⦄ ⊃ ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
+#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
+elim (lift_total T d e) #U #HTU
+elim (le_or_ge d (|K|)) #Hd
+[ elim (ldrop_ltpss_dx_trans_be … HLK1 … HK1 … Hd) // -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (tps_lift_be … HT1 … HL2K … HTU1 HTU … Hd) // -HT1 -HTU1 #HU1
+| elim (ldrop_ltpss_dx_trans_ge … HLK1 … HK1 Hd) -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (tps_lift_le … HT1 … HL2K … HTU1 HTU Hd) -HT1 -HTU1 #HU1
+]
+lapply (ltpss_dx_weak_full … HL12) -HL12 #HL12
+lapply (tps_weak_full … HU1) -HU1 #HU1
+@(ex3_2_intro … L2 U) // /2 width=7/ (**) (* explicit constructor: auto /3 width=14/ too slow *)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..74b898d
--- /dev/null
@@ -0,0 +1,106 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/ltpss_dx_tpss.ma".
+
+(* DX PARTIAL UNFOLD ON LOCAL ENVIRONMENTS **********************************)
+
+(* Advanced properties ******************************************************)
+
+lemma ltpss_dx_tpss_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                          ∀L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                          ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T &
+                               L1 ⊢ U2 ▶* [d1, e1] T.
+#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 @(tpss_ind … H) -U2 /2 width=3/
+#U #U2 #_ #HU2 * #X2 #HTX2 #HUX2
+elim (ltpss_dx_tps_conf … HU2 … HL01) -L0 #X1 #HUX1 #HU2X1
+elim (tpss_strip_eq … HUX2 … HUX1) -U #X #HX2 #HX1
+lapply (tpss_trans_eq … HU2X1 … HX1) -X1 /3 width=3/
+qed.
+
+lemma ltpss_dx_tpss_trans_down: ∀L0,L1,T2,U2,d1,e1,d2,e2. d2 + e2 ≤ d1 →
+                                L1 ▶* [d1, e1] L0 → L0 ⊢ T2 ▶* [d2, e2] U2 →
+                                ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T & L0 ⊢ T ▶* [d1, e1] U2.
+#L0 #L1 #T2 #U2 #d1 #e1 #d2 #e2 #Hde2d1 #HL10 #H @(tpss_ind … H) -U2
+[ /2 width=3/
+| #U #U2 #_ #HU2 * #T #HT2 #HTU
+  elim (tpss_strap1_down … HTU … HU2 ?) -U // #U #HTU #HU2
+  elim (ltpss_dx_tps_trans … HTU … HL10) -HTU -HL10 #X #HTX #HXU
+  lapply (tpss_trans_eq … HXU HU2) -U /3 width=3/
+]
+qed.
+
+lemma ltpss_dx_tpss_trans_eq: ∀L1,T2,U2,d,e. L1 ⊢ T2 ▶* [d, e] U2 →
+                              ∀L0. L0 ▶* [d, e] L1 → L0 ⊢ T2 ▶* [d, e] U2.
+#L1 #T2 @(f2_ind … fw … L1 T2) -L1 -T2 #n #IH #L1 *
+[ #I #Hn #W2 #d #e #H #L0 #HL01 destruct
+  elim (tpss_inv_atom1 … H) -H // *
+  #K1 #V1 #V2 #i #Hdi #Hide #HLK1 #HV12 #HVW2 #H destruct
+  lapply (ldrop_fwd_lw … HLK1) #H1 normalize in H1;
+  elim (ltpss_dx_ldrop_trans_be … HL01 … HLK1 ? ?) -HL01 -HLK1 // /2 width=2/ #X #H #HLK0
+  elim (ltpss_dx_inv_tpss22 … H ?) -H /2 width=1/ #K0 #V0 #HK01 #HV01 #H destruct
+  lapply (tpss_fwd_tw … HV01) #H2
+  lapply (transitive_le (♯{K1} + ♯{V0}) … H1) -H1 /2 width=1/ -H2 #H
+  lapply (tpss_trans_eq … HV01 HV12) -V1 #HV02
+  lapply (IH … HV02 … HK01) -IH -HV02 -HK01
+  [ normalize /2 width=1/ | /2 width=6/ ]
+| * [ #a ] #I #V2 #T2 #Hn #X #d #e #H #L0 #HL0 destruct
+  [ elim (tpss_inv_bind1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
+    lapply (tpss_lsubr_trans … HTU2 (L1. ⓑ{I} V2) ?) -HTU2 /2 width=1/ #HTU2
+    lapply (IH … HVW2 … HL0) -HVW2 [ /2 width=2/ ] #HVW2
+    lapply (IH … HTU2 (L0. ⓑ{I} V2) ?) -IH -HTU2 // /2 width=2/ -HL0 #HTU2
+    lapply (tpss_lsubr_trans … HTU2 (L0. ⓑ{I} W2) ?) -HTU2 /2 width=1/
+  | elim (tpss_inv_flat1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
+    lapply (IH … HVW2 … HL0) -HVW2 //
+    lapply (IH … HTU2 … HL0) -IH -HTU2 // -HL0 /2 width=1/
+]
+qed.
+
+lemma ltpss_dx_tps_trans_eq: ∀L0,L1,T2,U2,d,e. L0 ▶* [d, e] L1 →
+                             L1 ⊢ T2 ▶ [d, e] U2 → L0 ⊢ T2 ▶* [d, e] U2.
+/3 width=3/ qed.
+
+(* Main properties **********************************************************)
+
+theorem ltpss_dx_conf: ∀L0,L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                       ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
+                       ∃∃L. L1 ▶* [d2, e2] L & L2 ▶* [d1, e1] L.
+#L0 @(f_ind … lw … L0) -L0 #n #IH *
+[ #_ #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2 -n
+  >(ltpss_dx_inv_atom1 … H1) -L1
+  >(ltpss_dx_inv_atom1 … H2) -L2 /2 width=3/
+| #K0 #I0 #V0 #Hn #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2 destruct
+  elim (eq_or_gt d1) #Hd1 [ elim (eq_or_gt e1) #He1 ] destruct
+  [ lapply (ltpss_dx_inv_refl_O2 … H1) -H1 #H1
+  | elim (ltpss_dx_inv_tpss21 … H1 … He1) -H1 #K1 #V1 #HK01 #HV01 #H1
+  | elim (ltpss_dx_inv_tpss11 … H1 … Hd1) -H1 #K1 #V1 #HK01 #HV01 #H1
+  ] destruct
+  elim (eq_or_gt d2) #Hd2 [1,3,5: elim (eq_or_gt e2) #He2 ] destruct
+  [1,3,5: lapply (ltpss_dx_inv_refl_O2 … H2) -H2 #H2
+  |2,4,6: elim (ltpss_dx_inv_tpss21 … H2 … He2) -H2 #K2 #V2 #HK02 #HV02 #H2
+  |7,8,9: elim (ltpss_dx_inv_tpss11 … H2 … Hd2) -H2 #K2 #V2 #HK02 #HV02 #H2
+  ] destruct
+  [1: -IH /2 width=3/
+  |2,3,4,7: -IH /3 width=5/
+  |5,6,8,9:
+    elim (IH … HK01 … HK02) // -K0 #K #HK1 #HK2
+    elim (ltpss_dx_tpss_conf … HV01 … HK1) -HV01 #W1 #HW1 #HVW1
+    elim (ltpss_dx_tpss_conf … HV02 … HK2) -HV02 #W2 #HW2 #HVW2
+    elim (tpss_conf_eq … HW1 … HW2) -V0 #V #HW1 #HW2
+    lapply (tpss_trans_eq … HVW1 HW1) -W1
+    lapply (tpss_trans_eq … HVW2 HW2) -W2 /3 width=5/
+  ]
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tps.etc
new file mode 100644 (file)
index 0000000..b103066
--- /dev/null
@@ -0,0 +1,47 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_dx_ldrop.ma".
+
+(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properties concerning partial substitution on terms **********************)
+
+lemma ltpss_dx_tps_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                            ∀L1,d1,e1. L0 ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
+                            L1 ⊢ T2 ▶ [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ //
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01 #Hde1d2
+  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
+  lapply (ltpss_dx_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /2 width=4/
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01 #Hde1d2
+  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_dx_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
+| /3 width=4/
+]
+qed.
+
+lemma ltpss_dx_tps_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                             ∀L1,d1,e1. L1 ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
+                             L1 ⊢ T2 ▶ [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ //
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10 #Hde1d2
+  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
+  lapply (ltpss_dx_ldrop_trans_ge … HL10 … HLK0 ?) -L0 // /2 width=4/
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10 #Hde1d2
+  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_dx_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
+| /3 width=4/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_dx_tpss.etc
new file mode 100644 (file)
index 0000000..9c78759
--- /dev/null
@@ -0,0 +1,101 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_dx_tps.ma".
+
+(* DX PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properties concerning partial unfold on terms ****************************)
+
+lemma ltpss_dx_tpss_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                             ∀L1,d1,e1. L0 ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
+                             L1 ⊢ T2 ▶* [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU
+lapply (ltpss_dx_tps_conf_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
+qed.
+
+(* Basic_1: was: subst1_subst1_back *)
+lemma ltpss_dx_tps_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                         ∀L1,d1,e1. L0 ▶* [d1, e1] L1 →
+                         ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
+                              L1 ⊢ U2 ▶* [d1, e1] T.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ /2 width=3/
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01
+  elim (lt_or_ge i2 d1) #Hi2d1
+  [ elim (ltpss_dx_ldrop_conf_le … HL01 … HLK0 ?) -L0 /2 width=2/ #X #H #HLK1
+    elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK1) #H
+    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+    lapply (tpss_lift_ge … HV01 … H HVW0 … HVW1) -V0 -H // >minus_plus <plus_minus_m_m // /3 width=4/
+  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
+    [ elim (ltpss_dx_ldrop_conf_be … HL01 … HLK0 ? ?) -L0 // /2 width=2/ #X #H #HLK1
+      elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK1) #H
+      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+      lapply (tpss_lift_ge … HV01 … H HVW0 … HVW1) -V0 -H // normalize #HW01
+      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /2 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
+    | lapply (ltpss_dx_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /3 width=4/
+    ]
+  ]
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
+  elim (IHVW2 … HL01) -IHVW2 #V #HV2 #HVW2
+  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL01 /3 width=5/
+| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
+  elim (IHVW2 … HL01) -IHVW2
+  elim (IHTU2 … HL01) -IHTU2 -HL01 /3 width=5/
+]
+qed.
+
+lemma ltpss_dx_tpss_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                              ∀L1,d1,e1. L1 ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
+                              L1 ⊢ T2 ▶* [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU
+lapply (ltpss_dx_tps_trans_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
+qed.
+
+(* Basic_1: was: subst1_subst1 *)
+lemma ltpss_dx_tps_trans: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                          ∀L1,d1,e1. L1 ▶* [d1, e1] L0 →
+                          ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
+                               L0 ⊢ T ▶* [d1, e1] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ /2 width=3/
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10
+  elim (lt_or_ge i2 d1) #Hi2d1
+  [ elim (ltpss_dx_ldrop_trans_le … HL10 … HLK0 ?) -HL10 /2 width=2/ #X #H #HLK1
+    elim (ltpss_dx_inv_tpss12 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #H
+    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+    lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // >minus_plus <plus_minus_m_m /2 width=1/ /3 width=4/
+  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
+    [ elim (ltpss_dx_ldrop_trans_be … HL10 … HLK0 ? ?) -HL10 // /2 width=2/ #X #H #HLK1
+      elim (ltpss_dx_inv_tpss22 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #H
+      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+      lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // normalize #HW01
+      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /3 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
+    | lapply (ltpss_dx_ldrop_trans_ge … HL10 … HLK0 ?) -HL10 -HLK0 // /3 width=4/
+    ]
+  ]
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
+  elim (IHVW2 … HL10) -IHVW2 #V #HV2 #HVW2
+  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL10 /3 width=5/
+| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
+  elim (IHVW2 … HL10) -IHVW2
+  elim (IHTU2 … HL10) -IHTU2 -HL10 /3 width=5/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn.etc
new file mode 100644 (file)
index 0000000..577c150
--- /dev/null
@@ -0,0 +1,259 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( T1 break ⊢ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStarSn $T1 $d $e $T2 }.
+
+include "basic_2/unfold/tpss.ma".
+
+(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+inductive ltpss_sn: nat → nat → relation lenv ≝
+| ltpss_sn_atom : ∀d,e. ltpss_sn d e (⋆) (⋆)
+| ltpss_sn_pair : ∀L,I,V. ltpss_sn 0 0 (L. ⓑ{I} V) (L. ⓑ{I} V)
+| ltpss_sn_tpss2: ∀L1,L2,I,V1,V2,e.
+                  ltpss_sn 0 e L1 L2 → L1 ⊢ V1 ▶* [0, e] V2 →
+                  ltpss_sn 0 (e + 1) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
+| ltpss_sn_tpss1: ∀L1,L2,I,V1,V2,d,e.
+                  ltpss_sn d e L1 L2 → L1 ⊢ V1 ▶* [d, e] V2 →
+                  ltpss_sn (d + 1) e (L1. ⓑ{I} V1) (L2. ⓑ{I} V2)
+.
+
+interpretation "parallel unfold (local environment, sn variant)"
+   'PSubstStarSn L1 d e L2 = (ltpss_sn d e L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact ltpss_sn_inv_refl_O2_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → e = 0 → L1 = L2.
+#d #e #L1 #L2 #H elim H -d -e -L1 -L2 //
+[ #L1 #L2 #I #V1 #V2 #e #_ #_ #_ >commutative_plus normalize #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #HV12 #IHL12 #He destruct
+  >(IHL12 ?) -IHL12 // >(tpss_inv_refl_O2 … HV12) //
+]
+qed.
+
+lemma ltpss_sn_inv_refl_O2: ∀d,L1,L2. L1 ⊢ ▶* [d, 0] L2 → L1 = L2.
+/2 width=4/ qed-.
+
+fact ltpss_sn_inv_atom1_aux: ∀d,e,L1,L2.
+                             L1 ⊢ ▶* [d, e] L2 → L1 = ⋆ → L2 = ⋆.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ //
+| #L #I #V #H destruct
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
+]
+qed.
+
+lemma ltpss_sn_inv_atom1: ∀d,e,L2. ⋆ ⊢ ▶* [d, e] L2 → L2 = ⋆.
+/2 width=5/ qed-.
+
+fact ltpss_sn_inv_tpss21_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → d = 0 → 0 < e →
+                              ∀K1,I,V1. L1 = K1. ⓑ{I} V1 →
+                              ∃∃K2,V2. K1 ⊢ ▶* [0, e - 1] K2 &
+                                       K1 ⊢ V1 ▶* [0, e - 1] V2 &
+                                       L2 = K2. ⓑ{I} V2.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #_ #K1 #I #V1 #H destruct
+| #L1 #I #V #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K1 #J #W1 #H destruct /2 width=5/
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma ltpss_sn_inv_tpss21: ∀e,K1,I,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* [0, e] L2 → 0 < e →
+                           ∃∃K2,V2. K1 ⊢ ▶* [0, e - 1] K2 &
+                                    K1 ⊢ V1 ▶* [0, e - 1] V2 &
+                                    L2 = K2. ⓑ{I} V2.
+/2 width=5/ qed-.
+
+fact ltpss_sn_inv_tpss11_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → 0 < d →
+                              ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
+                              ∃∃K2,V2. K1 ⊢ ▶* [d - 1, e] K2 &
+                                       K1 ⊢ V1 ▶* [d - 1, e] V2 &
+                                       L2 = K2. ⓑ{I} V2.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #I #K1 #V1 #H destruct
+| #L #I #V #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K1 #W1 #H destruct /2 width=5/
+]
+qed.
+
+lemma ltpss_sn_inv_tpss11: ∀d,e,I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* [d, e] L2 → 0 < d →
+                           ∃∃K2,V2. K1 ⊢ ▶* [d - 1, e] K2 &
+                                    K1 ⊢ V1 ▶* [d - 1, e] V2 &
+                                    L2 = K2. ⓑ{I} V2.
+/2 width=3/ qed-.
+
+fact ltpss_sn_inv_atom2_aux: ∀d,e,L1,L2.
+                             L1 ⊢ ▶* [d, e] L2 → L2 = ⋆ → L1 = ⋆.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ //
+| #L #I #V #H destruct
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H destruct
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ #H destruct
+]
+qed.
+
+lemma ltpss_sn_inv_atom2: ∀d,e,L1. L1 ⊢ ▶* [d, e] ⋆ → L1 = ⋆.
+/2 width=5/ qed-.
+
+fact ltpss_sn_inv_tpss22_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → d = 0 → 0 < e →
+                              ∀K2,I,V2. L2 = K2. ⓑ{I} V2 →
+                              ∃∃K1,V1. K1 ⊢ ▶* [0, e - 1] K2 &
+                                       K1 ⊢ V1 ▶* [0, e - 1] V2 &
+                                       L1 = K1. ⓑ{I} V1.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #_ #K1 #I #V1 #H destruct
+| #L1 #I #V #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #_ #_ #K2 #J #W2 #H destruct /2 width=5/
+| #L1 #L2 #I #V1 #V2 #d #e #_ #_ >commutative_plus normalize #H destruct
+]
+qed.
+
+lemma ltpss_sn_inv_tpss22: ∀e,L1,K2,I,V2. L1 ⊢ ▶* [0, e] K2. ⓑ{I} V2 → 0 < e →
+                           ∃∃K1,V1. K1 ⊢ ▶* [0, e - 1] K2 &
+                                    K1 ⊢ V1 ▶* [0, e - 1] V2 &
+                                    L1 = K1. ⓑ{I} V1.
+/2 width=5/ qed-.
+
+fact ltpss_sn_inv_tpss12_aux: ∀d,e,L1,L2. L1 ⊢ ▶* [d, e] L2 → 0 < d →
+                              ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
+                              ∃∃K1,V1. K1 ⊢ ▶* [d - 1, e] K2 &
+                                       K1 ⊢ V1 ▶* [d - 1, e] V2 &
+                                       L1 = K1. ⓑ{I} V1.
+#d #e #L1 #L2 * -d -e -L1 -L2
+[ #d #e #_ #I #K2 #V2 #H destruct
+| #L #I #V #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #e #_ #_ #H elim (lt_refl_false … H)
+| #L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #_ #J #K2 #W2 #H destruct /2 width=5/
+]
+qed.
+
+lemma ltpss_sn_inv_tpss12: ∀L1,K2,I,V2,d,e. L1 ⊢ ▶* [d, e] K2. ⓑ{I} V2 → 0 < d →
+                           ∃∃K1,V1. K1 ⊢ ▶* [d - 1, e] K2 &
+                                    K1 ⊢ V1 ▶* [d - 1, e] V2 &
+                                    L1 = K1. ⓑ{I} V1.
+/2 width=3/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma ltpss_sn_tps2: ∀L1,L2,I,V1,V2,e.
+                     L1 ⊢ ▶* [0, e] L2 → L1 ⊢ V1 ▶ [0, e] V2 →
+                     L1. ⓑ{I} V1 ⊢ ▶* [0, e + 1] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_sn_tps1: ∀L1,L2,I,V1,V2,d,e.
+                     L1 ⊢ ▶* [d, e] L2 → L1 ⊢ V1 ▶ [d, e] V2 →
+                     L1. ⓑ{I} V1 ⊢ ▶* [d + 1, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_sn_tpss2_lt: ∀L1,L2,I,V1,V2,e.
+                         L1 ⊢ ▶* [0, e - 1] L2 → L1 ⊢ V1 ▶* [0, e - 1] V2 →
+                         0 < e → L1. ⓑ{I} V1 ⊢ ▶* [0, e] L2. ⓑ{I} V2.
+#L1 #L2 #I #V1 #V2 #e #HL12 #HV12 #He
+>(plus_minus_m_m e 1) /2 width=1/
+qed.
+
+lemma ltpss_sn_tpss1_lt: ∀L1,L2,I,V1,V2,d,e.
+                         L1 ⊢ ▶* [d - 1, e] L2 → L1 ⊢ V1 ▶* [d - 1, e] V2 →
+                         0 < d → L1. ⓑ{I} V1 ⊢ ▶* [d, e] L2. ⓑ{I} V2.
+#L1 #L2 #I #V1 #V2 #d #e #HL12 #HV12 #Hd
+>(plus_minus_m_m d 1) /2 width=1/
+qed.
+
+lemma ltpss_sn_tps2_lt: ∀L1,L2,I,V1,V2,e.
+                        L1 ⊢ ▶* [0, e - 1] L2 → L1 ⊢ V1 ▶ [0, e - 1] V2 →
+                        0 < e → L1. ⓑ{I} V1 ⊢ ▶* [0, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_sn_tps1_lt: ∀L1,L2,I,V1,V2,d,e.
+                        L1 ⊢ ▶* [d - 1, e] L2 → L1 ⊢ V1 ▶ [d - 1, e] V2 →
+                        0 < d → L1. ⓑ{I} V1 ⊢ ▶* [d, e] L2. ⓑ{I} V2.
+/3 width=1/ qed.
+
+lemma ltpss_sn_refl: ∀L,d,e. L ⊢ ▶* [d, e] L.
+#L elim L -L //
+#L #I #V #IHL * /2 width=1/ * /2 width=1/
+qed.
+
+lemma ltpss_sn_weak: ∀L1,L2,d1,e1. L1 ⊢ ▶* [d1, e1] L2 →
+                     ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 → L1 ⊢ ▶* [d2, e2] L2.
+#L1 #L2 #d1 #e1 #H elim H -L1 -L2 -d1 -e1 //
+[ #L1 #L2 #I #V1 #V2 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd2 #Hde2
+  lapply (le_n_O_to_eq … Hd2) #H destruct normalize in Hde2;
+  lapply (lt_to_le_to_lt 0 … Hde2) // #He2
+  lapply (le_plus_to_minus_r … Hde2) -Hde2 /3 width=5/
+| #L1 #L2 #I #V1 #V2 #d1 #e1 #_ #HV12 #IHL12 #d2 #e2 #Hd21 #Hde12
+  >plus_plus_comm_23 in Hde12; #Hde12
+  elim (le_to_or_lt_eq 0 d2 ?) // #H destruct
+  [ lapply (le_plus_to_minus_r … Hde12) -Hde12 <plus_minus // #Hde12
+    lapply (le_plus_to_minus … Hd21) -Hd21 #Hd21 /3 width=5/
+  | -Hd21 normalize in Hde12;
+    lapply (lt_to_le_to_lt 0 … Hde12) // #He2
+    lapply (le_plus_to_minus_r … Hde12) -Hde12
+    /3 width=5 by ltpss_sn_tpss2_lt, tpss_weak/ (**) (* /3 width=5/ used to work *)
+  ]
+]
+qed.
+
+lemma ltpss_sn_weak_full: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [0, |L1|] L2.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
+// /3 width=2/ /3 width=3/
+qed.
+
+fact ltpss_sn_append_le_aux: ∀K1,K2,d,x. K1 ⊢ ▶* [d, x] K2 → x = |K1| - d →
+                             ∀L1,L2,e. L1 ⊢ ▶* [0, e] L2 → d ≤ |K1| →
+                             L1 @@ K1 ⊢ ▶* [d, x + e] L2 @@ K2.
+#K1 #K2 #d #x #H elim H -K1 -K2 -d -x
+[ #d #x #H1 #L1 #L2 #e #HL12 #H2 destruct
+  lapply (le_n_O_to_eq … H2) -H2 #H destruct //
+| #K #I #V <minus_n_O normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #x #_ #HV12 <minus_n_O #IHK12 <minus_n_O #H #L1 #L2 #e #HL12 #_
+  lapply (injective_plus_l … H) -H #H destruct >plus_plus_comm_23
+  /4 width=5 by ltpss_sn_tpss2, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
+| #K1 #K2 #I #V1 #V2 #d #x #_ #HV12 #IHK12 normalize <minus_le_minus_minus_comm // <minus_plus_m_m #H1 #L1 #L2 #e #HL12 #H2 destruct
+  lapply (le_plus_to_le_r … H2) -H2 #Hd
+  /4 width=5 by ltpss_sn_tpss1, tpss_append, tpss_weak, monotonic_le_plus_r/ (**) (* too slow without trace *)
+]
+qed-.
+
+lemma ltpss_sn_append_le: ∀K1,K2,d. K1 ⊢ ▶* [d, |K1| - d] K2 →
+                          ∀L1,L2,e. L1 ⊢ ▶* [0, e] L2 → d ≤ |K1| →
+                          L1 @@ K1 ⊢ ▶* [d, |K1| - d + e] L2 @@ K2.
+/2 width=1 by ltpss_sn_append_le_aux/ qed.
+
+lemma ltpss_sn_append_ge: ∀K1,K2,d,e. K1 ⊢ ▶* [d, e] K2 →
+                          ∀L1,L2. L1 ⊢ ▶* [d - |K1|, e] L2 → |K1| ≤ d →
+                          L1 @@ K1 ⊢ ▶* [d, e] L2 @@ K2.
+#K1 #K2 #d #e #H elim H -K1 -K2 -d -e
+[ #d #e #L1 #L2 <minus_n_O //
+| #K #I #V #L1 #L2 #_ #H
+  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #e #_ #_ #_ #L1 #L2 #_ #H
+  lapply (le_n_O_to_eq … H) -H normalize <plus_n_Sm #H destruct
+| #K1 #K2 #I #V1 #V2 #d #e #_ #HV12 #IHK12 #L1 #L2
+  normalize <minus_le_minus_minus_comm // <minus_plus_m_m #HL12 #H
+  lapply (le_plus_to_le_r … H) -H /3 width=1/
+]
+qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma ltpss_sn_fwd_length: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → |L1| = |L2|.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
+normalize //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_alt.etc
new file mode 100644 (file)
index 0000000..d2cdba0
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+notation "hvbox( T1 break ⊢ ▶ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStarSnAlt $T1 $d $e $T2 }.
+
+include "basic_2/unfold/ltpss_dx_ltpss_dx.ma".
+include "basic_2/unfold/ltpss_sn_ltpss_sn.ma".
+
+(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* alternative definition of ltpss_sn *)
+definition ltpssa: nat → nat → relation lenv ≝
+                   λd,e. TC … (ltpss_dx d e).
+
+interpretation "parallel unfold (local environment, sn variant) alternative"
+   'PSubstStarSnAlt L1 d e L2 = (ltpssa d e L1 L2).
+
+(* Basic eliminators ********************************************************)
+
+lemma ltpssa_ind: ∀d,e,L1. ∀R:predicate lenv. R L1 →
+                  (∀L,L2. L1 ⊢ ▶▶* [d, e] L → L ▶* [d, e] L2 → R L → R L2) →
+                  ∀L2. L1 ⊢ ▶▶* [d, e] L2 → R L2.
+#d #e #L1 #R #HL1 #IHL1 #L2 #HL12 @(TC_star_ind … HL1 IHL1 … HL12) //
+qed-.
+
+lemma ltpssa_ind_dx: ∀d,e,L2. ∀R:predicate lenv. R L2 →
+                     (∀L1,L. L1 ▶* [d, e] L → L ⊢ ▶▶* [d, e] L2 → R L → R L1) →
+                     ∀L1. L1 ⊢ ▶▶* [d, e] L2 → R L1.
+#d #e #L2 #R #HL2 #IHL2 #L1 #HL12 @(TC_star_ind_dx … HL2 IHL2 … HL12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma ltpssa_refl: ∀L,d,e. L ⊢ ▶▶* [d, e] L.
+/2 width=1/ qed.
+
+lemma ltpssa_tpss2: ∀I,L1,V1,V2,e. L1 ⊢ V1 ▶*[0, e] V2 →
+                    ∀L2. L1 ⊢ ▶▶* [0, e] L2 →
+                    L1.ⓑ{I}V1 ⊢ ▶▶* [O, e + 1] L2.ⓑ{I}V2.
+#I #L1 #V1 #V2 #e #HV12 #L2 #H @(ltpssa_ind … H) -L2
+[ /3 width=1/ | /3 width=5/ ]
+qed.
+
+lemma ltpssa_tpss1: ∀I,L1,V1,V2,d,e. L1 ⊢ V1 ▶*[d, e] V2 →
+                    ∀L2. L1 ⊢ ▶▶* [d, e] L2 →
+                    L1.ⓑ{I}V1 ⊢ ▶▶* [d + 1, e] L2.ⓑ{I}V2.
+#I #L1 #V1 #V2 #d #e #HV12 #L2 #H @(ltpssa_ind … H) -L2
+[ /3 width=1/ | /3 width=5/ ]
+qed.
+
+lemma ltpss_sn_ltpssa: ∀L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 → L1 ⊢ ▶▶* [d, e] L2.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e // /2 width=1/
+qed.
+
+lemma ltpss_sn_dx_trans_eq: ∀L1,L,d,e. L1 ⊢ ▶* [d, e] L →
+                            ∀L2. L ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
+#L1 #L #d #e #H elim H -L1 -L -d -e
+[ #d #e #X #H
+  lapply (ltpss_dx_inv_atom1 … H) -H #H destruct //
+| #L #I #V #X #H
+  lapply (ltpss_dx_inv_refl_O2 … H) -H #H destruct //
+| #L1 #L #I #V1 #V #e #_ #HV1 #IHL1 #X #H
+  elim (ltpss_dx_inv_tpss21 … H ?) -H // <minus_plus_m_m
+  #L2 #V2 #HL2 #HV2 #H destruct
+  lapply (IHL1 … HL2) -L #HL12
+  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL12) -HV2 #HV2
+  lapply (tpss_trans_eq … HV1 HV2) -V /2 width=1/
+| #L1 #L #I #V1 #V #d #e #_ #HV1 #IHL1 #X #H
+  elim (ltpss_dx_inv_tpss11 … H ?) -H // <minus_plus_m_m
+  #L2 #V2 #HL2 #HV2 #H destruct
+  lapply (IHL1 … HL2) -L #HL12
+  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL12) -HV2 #HV2
+  lapply (tpss_trans_eq … HV1 HV2) -V /2 width=1/
+]
+qed.
+
+lemma ltpss_dx_sn_trans_eq: ∀L1,L,d,e. L1 ▶* [d, e] L →
+                            ∀L2. L ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
+/3 width=3/ qed.
+
+lemma ltpssa_strip: ∀L0,L1,d1,e1. L0 ⊢ ▶▶* [d1, e1] L1 →
+                    ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
+                    ∃∃L. L1 ▶* [d2, e2] L & L2 ⊢ ▶▶* [d1, e1] L.
+/3 width=3/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma ltpssa_ltpss_sn: ∀L1,L2,d,e. L1 ⊢ ▶▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
+#L1 #L2 #d #e #H @(ltpssa_ind … H) -L2 // /2 width=3/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma ltpss_sn_strip: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                      ∀L2,d2,e2. L0 ▶* [d2, e2] L2 →
+                      ∃∃L. L1 ▶* [d2, e2] L & L2 ⊢ ▶* [d1, e1] L.
+#L0 #L1 #d1 #e1 #H #L2 #d2 #e2 #HL02
+lapply (ltpss_sn_ltpssa … H) -H #HL01
+elim (ltpssa_strip … HL01 … HL02) -L0
+/3 width=3 by ltpssa_ltpss_sn, ex2_intro/
+qed.
+
+(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
+lemma ltpss_sn_tpss_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                          ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                          ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T &
+                               L0 ⊢ U2 ▶* [d1, e1] T.
+#L0 #T2 #U2 #d2 #e2 #HTU2 #L1 #d1 #e1 #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L1 /2 width=3/ -HTU2
+#L #L1 #H #HL1 * #T #HT2 #HU2T
+lapply (ltpssa_ltpss_sn … H) -H #HL0
+lapply (ltpss_sn_dx_trans_eq … HL0 … HL1) -HL0 #HL01
+elim (ltpss_dx_tpss_conf … HT2 … HL1) -HT2 -HL1 #T0 #HT20 #HT0
+lapply (ltpss_sn_tpss_trans_eq … HT0 … HL01) -HT0 -HL01 #HT0
+lapply (tpss_trans_eq … HU2T HT0) -T /2 width=3/
+qed.
+
+(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
+lemma ltpss_sn_tpss_trans_down: ∀L0,L1,T2,U2,d1,e1,d2,e2. d2 + e2 ≤ d1 →
+                                L1 ⊢ ▶* [d1, e1] L0 → L0 ⊢ T2 ▶* [d2, e2] U2 →
+                                ∃∃T. L1 ⊢ T2 ▶* [d2, e2] T & L1 ⊢ T ▶* [d1, e1] U2.
+#L0 #L1 #T2 #U2 #d1 #e1 #d2 #e2 #Hde2d1 #H #HTU2
+lapply (ltpss_sn_ltpssa … H) -H #HL10
+@(ltpssa_ind_dx … HL10) -L1 /2 width=3/ -HTU2
+#L1 #L #HL1 #_ * #T #HT2 #HTU2
+elim (ltpss_dx_tpss_trans_down … HL1 HT2) -HT2 // #T0 #HT20 #HT0 -Hde2d1
+lapply (tpss_trans_eq … HT0 HTU2) -T #HT0U2
+lapply (ltpss_dx_tpss_trans_eq … HT0U2 … HL1) -HT0U2 -HL1 /2 width=3/
+qed.
+
+(* Main properties **********************************************************)
+
+theorem ltpssa_conf: ∀L0,L1,d1,e1. L0 ⊢ ▶▶* [d1, e1] L1 →
+                     ∀L2,d2,e2. L0 ⊢ ▶▶* [d2, e2] L2 →
+                     ∃∃L. L1 ⊢ ▶▶* [d2, e2] L & L2 ⊢ ▶▶* [d1, e1] L.
+/3 width=3/ qed.
+
+(* Note: this should go in ltpss_sn_ltpss_sn.ma *)
+theorem ltpss_sn_conf: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                       ∀L2,d2,e2. L0 ⊢ ▶* [d2, e2] L2 →
+                       ∃∃L. L1 ⊢ ▶* [d2, e2] L & L2 ⊢ ▶* [d1, e1] L.
+#L0 #L1 #d1 #e1 #H1 #L2 #d2 #e2 #H2
+lapply (ltpss_sn_ltpssa … H1) -H1 #HL01
+lapply (ltpss_sn_ltpssa … H2) -H2 #HL02
+elim (ltpssa_conf … HL01 … HL02) -L0
+/3 width=3 by ltpssa_ltpss_sn, ex2_intro/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ldrop.etc
new file mode 100644 (file)
index 0000000..70167df
--- /dev/null
@@ -0,0 +1,231 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fsup.ma".
+include "basic_2/unfold/tpss_lift.ma".
+include "basic_2/unfold/ltpss_sn.ma".
+
+(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properies on local environment slicing ***********************************)
+
+lemma ltpss_sn_ldrop_conf_ge: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                              d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
+| //
+| normalize #K0 #K1 #I #V0 #V1 #e1 #_ #_ #IHK01 #L2 #e2 #H #He12
+  elim (le_inv_plus_l … He12) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
+| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK01 … HK0L2 ?) -K0 /2 width=1/
+]
+qed.
+
+lemma ltpss_sn_ldrop_trans_ge: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                               d1 + e1 ≤ e2 → ⇩[0, e2] L1 ≡ L2.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H //
+| //
+| normalize #K1 #K0 #I #V1 #V0 #e1 #_ #_ #IHK10 #L2 #e2 #H #He12
+  elim (le_inv_plus_l … He12) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK10 … HK0L2 ?) -K0 /2 width=1/
+| #K0 #K1 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  lapply (IHK10 … HK0L2 ?) -IHK10 -HK0L2 /2 width=1/
+]
+qed.
+
+lemma ltpss_sn_ldrop_conf_be: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
+                              ∃∃L. L2 ⊢ ▶* [0, d1 + e1 - e2] L & ⇩[0, e2] L1 ≡ L.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
+  lapply (le_n_O_to_eq … He2) -He2 #H destruct
+  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
+| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #_ #He21
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK01 -He21 destruct <minus_n_O /3 width=3/
+  | -HK01 -HV01 <minus_le_minus_minus_comm //
+    elim (IHK01 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
+  ]
+| #K0 #K1 #I #V0 #V1 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK01 #L2 #e2 #H #Hd1e2 #He2de1
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  <minus_le_minus_minus_comm //
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  elim (IHK01 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
+]
+qed.
+
+lemma ltpss_sn_ldrop_trans_be: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
+                               ∃∃L. L ⊢ ▶* [0, d1 + e1 - e2] L2 & ⇩[0, e2] L1 ≡ L.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| normalize #L #I #V #L2 #e2 #HL2 #_ #He2
+  lapply (le_n_O_to_eq … He2) -He2 #H destruct
+  lapply (ldrop_inv_refl … HL2) -HL2 #H destruct /2 width=3/
+| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #_ #He21
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK10 -He21 destruct <minus_n_O /3 width=3/
+  | -HK10 -HV10 <minus_le_minus_minus_comm //
+    elim (IHK10 … HK0L2 ? ?) -K0 // /2 width=1/ /3 width=3/
+  ]
+| #K1 #K0 #I #V1 #V0 #d1 #e1 >plus_plus_comm_23 #_ #_ #IHK10 #L2 #e2 #H #Hd1e2 #He2de1
+  elim (le_inv_plus_l … Hd1e2) #_ #He2
+  <minus_le_minus_minus_comm //
+  lapply (ldrop_inv_ldrop1 … H ?) -H // #HK0L2
+  elim (IHK10 … HK0L2 ? ?) -K0 /2 width=1/ /3 width=3/
+]
+qed.
+
+lemma ltpss_sn_ldrop_conf_le: ∀L0,L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                              ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                              ∃∃L. L2 ⊢ ▶* [d1 - e2, e1] L & ⇩[0, e2] L1 ≡ L.
+#L0 #L1 #d1 #e1 #H elim H -L0 -L1 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| normalize #K0 #K1 #I #V0 #V1 #e1 #HK01 #HV01 #_ #L2 #e2 #H #He2
+  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
+  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
+| #K0 #K1 #I #V0 #V1 #d1 #e1 #HK01 #HV01 #IHK01 #L2 #e2 #H #He2d1
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK01 -He2d1 destruct <minus_n_O /3 width=3/
+  | -HK01 -HV01 <minus_le_minus_minus_comm //
+    elim (IHK01 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
+  ]
+]
+qed.
+
+lemma ltpss_sn_ldrop_trans_le: ∀L1,L0,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
+                               ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                               ∃∃L. L ⊢ ▶* [d1 - e2, e1] L2 & ⇩[0, e2] L1 ≡ L.
+#L1 #L0 #d1 #e1 #H elim H -L1 -L0 -d1 -e1
+[ #d1 #e1 #L2 #e2 #H >(ldrop_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| normalize #K1 #K0 #I #V1 #V0 #e1 #HK10 #HV10 #_ #L2 #e2 #H #He2
+  lapply (le_n_O_to_eq … He2) -He2 #He2 destruct
+  lapply (ldrop_inv_refl … H) -H #H destruct /3 width=3/
+| #K1 #K0 #I #V1 #V0 #d1 #e1 #HK10 #HV10 #IHK10 #L2 #e2 #H #He2d1
+  lapply (ldrop_inv_O1 … H) -H * * #He2 #HK0L2
+  [ -IHK10 -He2d1 destruct <minus_n_O /3 width=3/
+  | -HK10 -HV10 <minus_le_minus_minus_comm //
+    elim (IHK10 … HK0L2 ?) -K0 /2 width=1/ /3 width=3/
+  ]
+]
+qed.
+
+lemma ldrop_ltpss_sn_trans_le: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 → d1 ≤ d2 →
+                               ∃∃L2. L1 ⊢ ▶* [d2 + e1, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_
+  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
+| /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #Hd
+  elim (IHLK1 … HK12 Hd) -K1 -Hd /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd12
+  elim (le_inv_plus_l … Hd12) -Hd12 #Hd12 #Hd2
+  elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+  elim (IHLK1 … HK12 … Hd12) -IHLK1 -HK12 <le_plus_minus_comm // #L2 #HL12 #HLK2
+  elim (lift_total W2 d1 e1) #V2 #HWV2
+  lapply (tpss_lift_ge … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 // -Hd12
+  <le_plus_minus_comm // /4 width=5/
+]
+qed-.
+
+lemma ldrop_ltpss_sn_trans_be: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 →
+                               d2 ≤ d1 → d1 ≤ d2 + e2 →
+                               ∃∃L2. L1 ⊢ ▶* [d2, e1 + e2] L2 &
+                                     ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_ #_
+  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H #_
+  lapply (le_n_O_to_eq … H) -H #H destruct /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H1 #H2
+  elim (IHLK1 … HK12 H1 H2) -K1 -H2
+  lapply (le_n_O_to_eq … H1) -H1 #H destruct /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21 #Hd12
+  elim (eq_or_gt d2) #Hd2 [ -Hd21 elim (eq_or_gt e2) #He2 ] destruct
+  [ lapply (le_n_O_to_eq … Hd12) -Hd12 <plus_n_Sm #H destruct
+  | elim (ltpss_sn_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 // /2 width=1/ >plus_minus_commutative // #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_be … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 // /2 width=1/
+    >plus_minus // >commutative_plus /4 width=5/
+  | elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // ] /2 width=1/ #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_be … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 [ >plus_minus // ] /2 width=1/
+    >commutative_plus /3 width=5/
+  ]
+]
+qed-.
+
+lemma ldrop_ltpss_sn_trans_ge: ∀L1,K1,d1,e1. ⇩[d1, e1] L1 ≡ K1 →
+                               ∀K2,d2,e2. K1 ⊢ ▶* [d2, e2] K2 → d2 + e2 ≤ d1 →
+                               ∃∃L2. L1 ⊢ ▶* [d2, e2] L2 & ⇩[d1, e1] L2 ≡ K2.
+#L1 #K1 #d1 #e1 #H elim H -L1 -K1 -d1 -e1
+[ #d1 #e1 #K2 #d2 #e2 #H #_
+  >(ltpss_sn_inv_atom1 … H) -H /2 width=3/
+| #K1 #I #V1 #K2 #d2 #e2 #HK12 #H
+  elim (plus_le_0 … H) -H #H1 #H2 destruct /2 width=3/
+| #L1 #K1 #I #V #e1 #_ #IHLK1 #K2 #d2 #e2 #HK12 #H
+  elim (IHLK1 … HK12 H) -K1
+  elim (plus_le_0 … H) -H #H1 #H2 destruct #L2 #HL12
+  >(ltpss_sn_inv_refl_O2 … HL12) -L1 /3 width=5/
+| #L1 #K1 #I #V1 #W1 #d1 #e1 #HLK1 #HWV1 #IHLK1 #X #d2 #e2 #H #Hd21
+  elim (eq_or_gt d2) #Hd2 [ elim (eq_or_gt e2) #He2 ] destruct
+  [ -IHLK1 -Hd21 <(ltpss_sn_inv_refl_O2 … H) -X /3 width=5/
+  | elim (ltpss_sn_inv_tpss21 … H He2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 /2 width=1/ #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_le … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 /2 width=1/ /3 width=5/
+  | elim (ltpss_sn_inv_tpss11 … H Hd2) -H #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHLK1 … HK12 …) -IHLK1 [2: >plus_minus // /2 width=1/ ] #L2 #HL12 #HLK2
+    elim (lift_total W2 d1 e1) #V2 #HWV2
+    lapply (tpss_lift_le … HW12 … HLK1 HWV1 … HWV2) -HLK1 -W1 [ >plus_minus // /2 width=1/ ] /3 width=5/
+  ]
+]
+qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma fsup_tpss_trans_full: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶*[0,|L2|] U2 →
+                            ∃∃L,U1. L1 ⊢ ▶*[0,|L1|] L & L ⊢ T1 ▶*[0,|L|] U1 & ⦃L, U1⦄ ⊃ ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [1,2,3,4,5: /3 width=5/ ]
+#L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
+elim (lift_total T d e) #U #HTU
+lapply (ltpss_sn_fwd_length … HK1) #H >H in HK1; -H #HK1
+elim (le_or_ge d (|K|)) #Hd
+[ elim (ldrop_ltpss_sn_trans_be … HLK1 … HK1 … Hd) // -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (tpss_lift_be … HT1 … Hd HL2K HTU1 … HTU) // -HT1 -HTU1 #HU1
+| elim (ldrop_ltpss_sn_trans_ge … HLK1 … HK1 Hd) -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (tpss_lift_le … HT1 … Hd HL2K HTU1 … HTU) -HT1 -HTU1 #HU1
+]
+lapply (ltpss_sn_weak_full … HL12) -HL12 #HL12
+lapply (tpss_weak_full … HU1) -HU1 #HU1
+@(ex3_2_intro … L2 U) // /2 width=7/ (**) (* explicit constructor: auto /3 width=14/ too slow *)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..67c287e
--- /dev/null
@@ -0,0 +1,81 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/ltpss_sn_tpss.ma".
+
+(* PARTIAL UNFOLD ON LOCAL ENVIRONMENTS *************************************)
+
+(* Advanced properties ******************************************************)
+
+lemma ltpss_sn_tpss_trans_eq: ∀L1,T2,U2,d,e. L1 ⊢ T2 ▶* [d, e] U2 →
+                              ∀L0. L0 ⊢ ▶* [d, e] L1 → L0 ⊢ T2 ▶* [d, e] U2.
+#L1 #T2 @(f2_ind … fw … L1 T2) -L1 -T2 #n #IH #L1 *
+[ #I #Hn #W2 #d #e #H #L0 #HL01 destruct
+  elim (tpss_inv_atom1 … H) -H // *
+  #K1 #V1 #V2 #i #Hdi #Hide #HLK1 #HV12 #HVW2 #H destruct
+  lapply (ldrop_fwd_lw … HLK1) #H1 normalize in H1;
+  elim (ltpss_sn_ldrop_trans_be … HL01 … HLK1 ? ?) -HL01 -HLK1 // /2 width=2/ #X #H #HLK0
+  elim (ltpss_sn_inv_tpss22 … H ?) -H /2 width=1/ #K0 #V0 #HK01 #HV01 #H destruct
+  lapply (IH … HV12 … HK01) -IH -HV12 -HK01 [ normalize /2 width=1/ ] #HV12
+  lapply (tpss_trans_eq … HV01 HV12) -V1 /2 width=6/
+| * [ #a ] #I #V2 #T2 #Hn #X #d #e #H #L0 #HL0 destruct
+  [ elim (tpss_inv_bind1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
+    lapply (tpss_lsubr_trans … HTU2 (L1. ⓑ{I} V2) ?) -HTU2 /2 width=1/ #HTU2
+    lapply (IH … HVW2 … HL0) -HVW2 [ /2 width=2/ ] #HVW2
+    lapply (IH … HTU2 (L0. ⓑ{I} V2) ?) -IH -HTU2 // /2 width=2/ -HL0 #HTU2
+    lapply (tpss_lsubr_trans … HTU2 (L0. ⓑ{I} W2) ?) -HTU2 /2 width=1/
+  | elim (tpss_inv_flat1 … H) -H #W2 #U2 #HVW2 #HTU2 #H destruct
+    lapply (IH … HVW2 … HL0) -HVW2 //
+    lapply (IH … HTU2 … HL0) -IH -HTU2 // -HL0 /2 width=1/
+]
+qed.
+
+lemma ltpss_sn_tps_trans_eq: ∀L0,L1,T2,U2,d,e. L0 ⊢ ▶* [d, e] L1 →
+                             L1 ⊢ T2 ▶ [d, e] U2 → L0 ⊢ T2 ▶* [d, e] U2.
+/3 width=3/ qed.
+
+(* Main properties **********************************************************)
+
+theorem ltpss_sn_trans_eq: ∀L1,L,d,e. L1 ⊢ ▶* [d, e] L →
+                           ∀L2. L ⊢ ▶* [d, e] L2 → L1 ⊢ ▶* [d, e] L2.
+#L1 #L #d #e #H elim H -L1 -L -d -e //
+[ #L1 #L #I #V1 #V #e #HL1 #HV1 #IHL1 #X #H
+  elim (ltpss_sn_inv_tpss21 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
+  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL1) -HV2 -HL1 #HV2
+  lapply (tpss_trans_eq … HV1 … HV2) -V /3 width=1/
+| #L1 #L #I #V1 #V #d #e #HL1 #HV1 #IHL1 #X #H
+  elim (ltpss_sn_inv_tpss11 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
+  lapply (ltpss_sn_tpss_trans_eq … HV2 … HL1) -HV2 -HL1 #HV2
+  lapply (tpss_trans_eq … HV1 … HV2) -V /3 width=1/
+]
+qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma tps_fwd_shift1: ∀L1,L,T1,T,d,e. L ⊢ L1 @@ T1 ▶ [d, e] T →
+                      ∃∃L2,T2. L @@ L1 ⊢ ▶* [d + |L1|, e] L @@ L2 &
+                               L @@ L2 ⊢ T1 ▶ [d + |L1|, e] T2 &
+                               T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1
+[ #L #T1 #T #d #e #HT1
+  @ex3_2_intro [3: // |5: // |4: normalize /2 width=1/ |1,2: skip ] (**) (* /2 width=4/ does not work *)
+| #I #L1 #V1 #IH #L #T1 #T #d #e >shift_append_assoc #H
+  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
+  <append_assoc >append_length <associative_plus
+  lapply (ltpss_sn_trans_eq (L.ⓑ{I}V1@@L1) … HL12) -HL12 /3 width=1/ #HL12
+  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tps.etc
new file mode 100644 (file)
index 0000000..1de83c6
--- /dev/null
@@ -0,0 +1,47 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_ldrop.ma".
+
+(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properties concerning partial substitution on terms **********************)
+
+lemma ltpss_sn_tps_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                            ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
+                            L1 ⊢ T2 ▶ [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ //
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01 #Hde1d2
+  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
+  lapply (ltpss_sn_ldrop_conf_ge … HL01 … HLK0 ?) -L0 // /2 width=4/
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01 #Hde1d2
+  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_sn_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
+| /3 width=4/
+]
+qed.
+
+lemma ltpss_sn_tps_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                             ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
+                             L1 ⊢ T2 ▶ [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ //
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10 #Hde1d2
+  lapply (transitive_le … Hde1d2 Hdi2) -Hde1d2 #Hde1i2
+  lapply (ltpss_sn_ldrop_trans_ge … HL10 … HLK0 ?) -L0 // /2 width=4/
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10 #Hde1d2
+  @tps_bind [ /2 width=4/ | @IHTU2 -IHTU2 -IHVW2 [3: /2 by ltpss_sn_tpss1/ |1,2: skip | /2 width=1/ ] ] (**) (* explicit constructor *)
+| /3 width=4/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ltpss_sn_tpss.etc
new file mode 100644 (file)
index 0000000..007613c
--- /dev/null
@@ -0,0 +1,101 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_tps.ma".
+
+(* SN PARALLEL UNFOLD ON LOCAL ENVIRONMENTS *********************************)
+
+(* Properties concerning partial unfold on terms ****************************)
+
+lemma ltpss_sn_tpss_conf_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                             ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 → d1 + e1 ≤ d2 →
+                             L1 ⊢ T2 ▶* [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU
+lapply (ltpss_sn_tps_conf_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
+qed.
+
+lemma ltpss_sn_tps_conf: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                         ∀L1,d1,e1. L0 ⊢ ▶* [d1, e1] L1 →
+                         ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
+                              L0 ⊢ U2 ▶* [d1, e1] T.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ /2 width=3/
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL01
+  elim (lt_or_ge i2 d1) #Hi2d1
+  [ elim (ltpss_sn_ldrop_conf_le … HL01 … HLK0 ?) /2 width=2/ #X #H #HLK1
+    elim (ltpss_sn_inv_tpss11 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #HLK0
+    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+    lapply (tpss_lift_ge … HV01 … HLK0 HVW0 … HVW1) -V0 -HLK0 // >minus_plus <plus_minus_m_m // /3 width=4/
+  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
+    [ elim (ltpss_sn_ldrop_conf_be … HL01 … HLK0 ? ?) -HL01 // /2 width=2/ #X #H #HLK1
+      elim (ltpss_sn_inv_tpss21 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK0) -HLK0 #HLK0
+      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+      lapply (tpss_lift_ge … HV01 … HLK0 HVW0 … HVW1) -V0 -HLK0 // normalize #HW01
+      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /2 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
+    | lapply (ltpss_sn_ldrop_conf_ge … HL01 … HLK0 ?) -HL01 -HLK0 // /3 width=4/
+    ]
+  ]
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
+  elim (IHVW2 … HL01) -IHVW2 #V #HV2 #HVW2
+  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL01 #T #HT2 #H
+  lapply (tpss_lsubr_trans … H (L0.ⓑ{I}V) ?) -H /2 width=1/ /3 width=5/
+| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL01
+  elim (IHVW2 … HL01) -IHVW2
+  elim (IHTU2 … HL01) -IHTU2 -HL01 /3 width=5/
+]
+qed.
+
+lemma ltpss_sn_tpss_trans_ge: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶* [d2, e2] U2 →
+                              ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 → d1 + e1 ≤ d2 →
+                              L1 ⊢ T2 ▶* [d2, e2] U2.
+#L0 #T2 #U2 #d2 #e2 #H #L1 #d1 #e1 #HL01 #Hde1d2 @(tpss_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU
+lapply (ltpss_sn_tps_trans_ge … HU2 … HL01 ?) -L0 // -Hde1d2 /2 width=3/
+qed.
+
+lemma ltpss_sn_tps_trans: ∀L0,T2,U2,d2,e2. L0 ⊢ T2 ▶ [d2, e2] U2 →
+                          ∀L1,d1,e1. L1 ⊢ ▶* [d1, e1] L0 →
+                          ∃∃T. L1 ⊢ T2 ▶ [d2, e2] T &
+                               L1 ⊢ T ▶* [d1, e1] U2.
+#L0 #T2 #U2 #d2 #e2 #H elim H -L0 -T2 -U2 -d2 -e2
+[ /2 width=3/
+| #L0 #K0 #V0 #W0 #i2 #d2 #e2 #Hdi2 #Hide2 #HLK0 #HVW0 #L1 #d1 #e1 #HL10
+  elim (lt_or_ge i2 d1) #Hi2d1
+  [ elim (ltpss_sn_ldrop_trans_le … HL10 … HLK0 ?) -L0 /2 width=2/ #X #H #HLK1
+    elim (ltpss_sn_inv_tpss12 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK1) #H
+    elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+    lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // >minus_plus <plus_minus_m_m /2 width=1/ /3 width=4/
+  | elim (lt_or_ge i2 (d1 + e1)) #Hde1i2
+    [ elim (ltpss_sn_ldrop_trans_be … HL10 … HLK0 ? ?) -L0 // /2 width=2/ #X #H #HLK1
+      elim (ltpss_sn_inv_tpss22 … H ?) -H /2 width=1/ #K1 #V1 #_ #HV01 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK1) #H
+      elim (lift_total V1 0 (i2 + 1)) #W1 #HVW1
+      lapply (tpss_lift_ge … HV01 … H HVW1 … HVW0) -V0 -H // normalize #HW01
+      lapply (tpss_weak … HW01 d1 e1 ? ?) [2: /3 width=1/ |3: /3 width=4/ ] >minus_plus >commutative_plus /2 width=1/
+    | lapply (ltpss_sn_ldrop_trans_ge … HL10 … HLK0 ?) -HL10 -HLK0 // /3 width=4/
+    ]
+  ]
+| #L0 #a #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
+  elim (IHVW2 … HL10) -IHVW2 #V #HV2 #HVW2
+  elim (IHTU2 (L1. ⓑ{I} V) (d1 + 1) e1 ?) -IHTU2 /2 width=1/ -HL10 #T #HT2 #H
+  lapply (tpss_lsubr_trans … H (L1.ⓑ{I}W2) ?) -H /2 width=1/ /3 width=5/
+| #L0 #I #V2 #W2 #T2 #U2 #d2 #e2 #_ #_ #IHVW2 #IHTU2 #L1 #d1 #e1 #HL10
+  elim (IHVW2 … HL10) -IHVW2
+  elim (IHTU2 … HL10) -IHTU2 -HL10 /3 width=5/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..ca55239
--- /dev/null
@@ -0,0 +1,87 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/dxprs_ltpss_dx.ma".
+include "basic_2/equivalence/cpcs_ltpss_dx.ma".
+include "basic_2/dynamic/snv_lift.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties about dx parallel unfold **************************************)
+
+lemma snv_ltpss_dx_tpss_conf: ∀h,g,L1,T1. ⦃h, L1⦄ ⊢ T1 ¡[g] →
+                              ∀L2,d,e. L1 ▶* [d, e] L2 →
+                              ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 ¡[g].
+#h #g #L1 #T1 #H elim H -L1 -T1
+[ #L1 #k #L2 #d #e #_ #X #H
+   >(tpss_inv_sort1 … H) -X //
+| #I #L1 #K1 #V1 #i #HLK1 #HV1 #IHV1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi [ | elim (lt_or_ge i (d + e)) #Hide ]
+    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 …) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_dx_inv_tpss11 … H …) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+      lapply (IHV1 … HK12 … HV12) -IHV1 -HK12 -HV12 /2 width=5/
+    | elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 …) -L1 // /2 width=2/ #X #H #HLK2
+      elim (ltpss_dx_inv_tpss21 … H …) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+      lapply (IHV1 … HK12 … HV12) -IHV1 -HK12 -HV12 /2 width=5/
+    | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=5/
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 …) -L1 // /2 width=2/ #X #H1 #H2
+    elim (ltpss_dx_inv_tpss21 … H1 …) -H1 /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … H2 … HLK2) -H2 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
+    lapply (IHV1 … HK12 … HV1W2) -IHV1 -HK12 -HV1W2 /2 width=7/
+  ]
+| #a #I #L1 #V1 #T1 #_ #_ #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (IHV1 … HL12 … HV12) -IHV1 #HV2
+  lapply (IHT1 … HT12) -IHT1 -HT12 /2 width=1/
+| #a #L1 #V1 #W1 #W0 #T1 #U1 #l #_ #_ #HVW1 #HW10 #HTU1 #IHV1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (IHV1 … HL12 … HV12) -IHV1 #HV2
+  lapply (IHT1 … HT12) -IHT1 /2 width=1/ #HT2
+  elim (ssta_ltpss_dx_tpss_conf … HVW1 … HL12 … HV12) -V1 #W2 #HVW2 #HW12
+  elim (dxprs_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -T1 #X #HTU2 #H
+  elim (tpss_inv_bind1 … H) -H #W #U2 #HW0 #_ #H -U1 destruct
+  elim (cprs_ltpss_dx_tpss2_conf … HW10 … HL12 … HW12 … HW0) -L1 -W1 -W0 #W0 #HW20 #HW0
+  lapply (dxprs_strap1 … (ⓛ{a}W0.U2) HTU2 ?) -HTU2 /3 width=3/ -HW0 /2 width=8/
+| #L1 #W1 #T1 #U1 #l #_ #_ #HTU1 #HUW1 #IHW1 #IHT1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
+  lapply (IHW1 … HL12 … HW12) -IHW1 #HW2
+  lapply (IHT1 … HL12 … HT12) -IHT1 #HT2
+  elim (ssta_ltpss_dx_tpss_conf … HTU1 … HL12 … HT12) -T1 #U2 #HTU2 #HU12
+  lapply (cpcs_ltpss_dx_tpss2_conf … HL12 … HUW1 … HU12 … HW12) -L1 -W1 -U1 /2 width=4/
+]
+qed-.
+
+lemma snv_ltpss_dx_conf: ∀h,g,L1,T. ⦃h, L1⦄ ⊢ T ¡[g] →
+                         ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T ¡[g].
+#h #g #L1 #T #HT #L2 #d #e #HL12
+@(snv_ltpss_dx_tpss_conf … HT … HL12) //
+qed-.
+
+lemma snv_tpss_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
+                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
+#h #g #L #T1 #HT1 #T2 #d #e #HT12
+@(snv_ltpss_dx_tpss_conf … HT1 … HT12) //
+qed-.
+
+lemma snv_tps_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
+                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
+#h #g #L #T1 #HT1 #T2 #d #e #HT12
+@(snv_tpss_conf … HT1 T2) /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/snv_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..3c80702
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/snv_ltpss_dx.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties about sn parallel unfold **************************************)
+
+lemma snv_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                         ∀T. ⦃h, L1⦄ ⊢ T ¡[g] → ⦃h, L2⦄ ⊢ T ¡[g].
+#h #g #L1 #L2 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 //
+#L #L2 #_ #HL2 #IHL1 #T1 #HT1
+lapply (IHL1 … HT1) -IHL1 -HT1 #HT1
+lapply (snv_ltpss_dx_conf … HT1 … HL2) -HT1 -HL2 //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..72eff78
--- /dev/null
@@ -0,0 +1,125 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/ltpss_dx_tpss.ma".
+include "basic_2/static/ssta_lift.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Properties about dx parallel unfold **************************************)
+
+(* Note: apparently this was missing in basic_1 *)
+lemma ssta_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                               ∀L2,d,e. L1 ▶* [d, e] L2 →
+                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
+                                     L2 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
+[ #L1 #k1 #l1 #Hkl1 #L2 #d #e #_ #T2 #H
+  >(tpss_inv_sort1 … H) -H /3 width=3/
+| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HVW1 ]
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi [ -HVW1 | ]
+    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+      elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
+      lapply (ldrop_fwd_ldrop2 … HLK2) #H
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1
+      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
+    | elim (lt_or_ge i (d + e)) #Hide [ -HVW1 | -Hdi -IHVW1 ]
+      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+        elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
+        lapply (ldrop_fwd_ldrop2 … HLK2) #H
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1 >minus_plus #H
+        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
+      | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
+    elim (IHVW1 … HK12 … HV1W2) -IHVW1 -HK12 -HV1W2 #V2 #HWV2 #HW1V2
+    elim (lift_total V2 0 (i+1)) #U2 #HVU2
+    lapply (ssta_lift … HWV2 … HLK2 … HWT2 … HVU2) -HWV2 -HWT2 #HTU2
+    lapply (tpss_lift_ge … HW1V2 … HLK2 … HWU1 … HVU2) // -HW1V2 -HLK2 -HWU1 -HVU2 >minus_plus #H
+    lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /2 width=3/
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
+    [ elim (ltpss_dx_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_dx_inv_tpss11 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+      elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
+      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1
+      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
+    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -Hdi ]
+      [ elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+        elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
+        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1 >minus_plus #H
+        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
+      | lapply (ltpss_dx_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
+    elim (ltpss_dx_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_dx_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
+  ]
+| #a #I #L1 #V1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
+| #L1 #V1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=5/
+| #L1 #W1 #T1 #U1 #l #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=3/
+]
+qed.
+
+lemma ssta_ltpss_dx_tps_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                              ∀L2,d,e. L1 ▶* [d, e] L2 →
+                              ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                              ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
+                                    L2 ⊢ U1 ▶* [d, e] U2.
+/3 width=5/ qed.
+
+lemma ssta_ltpss_dx_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
+                          ∀L2,d,e. L1 ▶* [d, e] L2 →
+                          ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L2 ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma ssta_tpss_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                      ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma ssta_tps_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                     ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
+                     ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/ssta_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..d554f1f
--- /dev/null
@@ -0,0 +1,53 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/static/ssta_ltpss_dx.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Properties about sn parallel unfold **************************************)
+
+lemma ssta_ltpss_sn_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
+                          ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                          ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T #U1 #l #HTU1 #L2 #d #e #HL12
+lapply (ltpss_sn_ltpssa … HL12) -HL12 #HL12
+@(ltpssa_ind … HL12) -L2 [ /2 width=3/ ] -HTU1
+#L #L2 #HL1 #HL2 * #U #HTU #HU1
+lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
+elim (ssta_ltpss_dx_conf … HTU … HL2) -HTU #U2 #HTU2 #HU2
+lapply (ltpss_dx_tpss_trans_eq … HU2 … HL2) -HU2 -HL2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL1) -HU2 -HL1 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed.
+
+lemma ssta_ltpss_sn_tpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                               ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                               ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
+                                     L1 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U1 #l #HTU1 #L2 #d #e #HL12 #T2 #HT12
+elim (ssta_ltpss_sn_conf … HTU1 … HL12) -HTU1 #U #HT1U #HU1
+elim (ssta_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed.
+
+lemma ssta_ltpss_sn_tps_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                              ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                              ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                              ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ &
+                                    L1 ⊢ U1 ▶* [d, e] U2.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss.etc
new file mode 100644 (file)
index 0000000..e0aa942
--- /dev/null
@@ -0,0 +1,55 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/ssta_ltpss.ma".
+include "basic_2/unwind/sstas.ma".
+
+(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENTON TERMS ***********************)
+
+(* Properties about parallel unfold *****************************************)
+
+lemma sstas_ltpss_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                             ∀L2,d,e. L1 ▶* [d, e] L2 →
+                             ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                             ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
+                                   L2 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U1 #H @(sstas_ind_alt … H) -T1
+[ #T1 #HUT1 #L2 #d #e #HL12 #U2 #HU12
+  elim (ssta_ltpss_tpss_conf … HUT1 … HL12 … HU12) -HUT1 -HL12 /3 width=3/
+| #T0 #U0 #l0 #HTU0 #_ #IHU01 #L2 #d #e #HL12 #T #HT0
+  elim (ssta_ltpss_tpss_conf … HTU0 … HL12 … HT0) -HTU0 -HT0 #U #HTU #HU0
+  elim (IHU01 … HL12 … HU0) -IHU01 -HL12 -U0 /3 width=4/
+]
+qed.
+
+lemma sstas_ltpss_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                            ∀L2,d,e. L1 ▶* [d, e] L2 →
+                            ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/3 width=5/ qed.
+
+lemma sstas_ltpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
+                        ∀L2,d,e. L1 ▶* [d, e] L2 →
+                        ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sstas_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
+                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sstas_tps_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
+                      ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
+                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_dx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_dx.etc
new file mode 100644 (file)
index 0000000..2a8f8e7
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/ssta_ltpss_dx.ma".
+include "basic_2/unwind/sstas.ma".
+
+(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS *********************)
+
+(* Properties about dx parallel unfold **************************************)
+
+lemma sstas_ltpss_dx_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                                ∀L2,d,e. L1 ▶* [d, e] L2 →
+                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
+                                      L2 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U1 #H @(sstas_ind_dx … H) -T1 /2 width=3/
+#T0 #U0 #l0 #HTU0 #_ #IHU01 #L2 #d #e #HL12 #T #HT0
+elim (ssta_ltpss_dx_tpss_conf … HTU0 … HL12 … HT0) -HTU0 -HT0 #U #HTU #HU0
+elim (IHU01 … HL12 … HU0) -IHU01 -HL12 -U0 /3 width=4/
+qed.
+
+lemma sstas_ltpss_dx_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                               ∀L2,d,e. L1 ▶* [d, e] L2 →
+                               ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/3 width=7 by step, sstas_ltpss_dx_tpss_conf/ qed. (**) (* auto fails without trace *)
+
+lemma sstas_ltpss_dx_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
+                           ∀L2,d,e. L1 ▶* [d, e] L2 →
+                           ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sstas_tpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
+                       ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sstas_tps_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
+                      ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
+                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sstas_ltpss_sn.etc
new file mode 100644 (file)
index 0000000..d066adb
--- /dev/null
@@ -0,0 +1,53 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/unwind/sstas_ltpss_dx.ma".
+
+(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ************************)
+
+(* Properties about sn parallel unfold *****************************************)
+
+lemma sstas_ltpss_sn_conf: ∀h,g,L1,L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                           ∀T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
+                           ∃∃U2. L1 ⊢ U1 ▶* [d, e] U2 & ⦃h, L2⦄ ⊢ T •*[g] U2.
+#h #g #L1 #L2 #d #e #H
+lapply (ltpss_sn_ltpssa … H) -H #H @(ltpssa_ind … H) -L2 /2 width=3/
+#L #L2 #HL1 #HL2 #IHL1 #T #U1 #H1
+lapply (ltpssa_ltpss_sn … HL1) -HL1 #HL1
+lapply (ltpss_sn_dx_trans_eq … HL1 … HL2) -HL1 #HL12
+elim (IHL1 … H1) -IHL1 -H1 #U #HU1 #HTU
+elim (sstas_ltpss_dx_conf … HTU … HL2) -HTU -HL2 #U2 #H2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed.
+
+lemma sstas_ltpss_sn_tpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                                ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                                ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                                ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
+                                      L1 ⊢ U1 ▶* [d, e] U2.
+#h #g #L1 #T1 #U1 #HTU1 #L2 #d #e #HL12 #T2 #HT12
+elim (sstas_ltpss_sn_conf … HL12 … HTU1) -HTU1 #U #HU1 #HT1U
+elim (sstas_tpss_conf … HT1U … HT12) -T1 #U2 #HTU2 #HU2
+lapply (ltpss_sn_tpss_trans_eq … HU2 … HL12) -HU2 -HL12 #HU2
+lapply (tpss_trans_eq … HU1 HU2) -U /2 width=3/
+qed.
+
+lemma sstas_ltpss_sn_tps_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                               ∀L2,d,e. L1 ⊢ ▶* [d, e] L2 →
+                               ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                               ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 &
+                                     L1 ⊢ U1 ▶* [d, e] U2.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/sta_ltpss.etc
new file mode 100644 (file)
index 0000000..b0232f5
--- /dev/null
@@ -0,0 +1,122 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/ltpss_tpss.ma".
+include "basic_2/static/sta_lift.ma".
+
+(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties about parallel unfold *****************************************)
+
+lemma sta_ltpss_tpss_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 • U1 →
+                           ∀L2,d,e. L1 ▶* [d, e] L2 →
+                           ∀T2. L2 ⊢ T1 ▶* [d, e] T2 →
+                           ∃∃U2. ⦃h, L2⦄ ⊢ T2 • U2 & L2 ⊢ U1 ▶* [d, e] U2.
+#h #L1 #T1 #U #H elim H -L1 -T1 -U
+[ #L1 #k1 #L2 #d #e #_ #T2 #H
+  >(tpss_inv_sort1 … H) -H /2 width=3/
+| #L1 #K1 #V1 #W1 #U1 #i #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HVW1 ]
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi [ -HVW1 | ]
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+      elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
+      lapply (ldrop_fwd_ldrop2 … HLK2) #H
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1
+      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
+    | elim (lt_or_ge i (d + e)) #Hide [ -HVW1 | -Hdi -IHVW1 ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+        elim (IHVW1 … HK12 … HV12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
+        lapply (ldrop_fwd_ldrop2 … HLK2) #H
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … H … HWU1 … HWU2) // -HW12 -H -HWU1 >minus_plus #H
+        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 #HV1W2
+    elim (IHVW1 … HK12 … HV1W2) -IHVW1 -HK12 -HV1W2 #V2 #HWV2 #HW1V2
+    elim (lift_total V2 0 (i+1)) #U2 #HVU2
+    lapply (sta_lift … HWV2 … HLK2 … HWT2 … HVU2) -HWV2 -HWT2 #HTU2
+    lapply (tpss_lift_ge … HW1V2 … HLK2 … HWU1 … HVU2) // -HW1V2 -HLK2 -HWU1 -HVU2 >minus_plus #H
+    lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /2 width=3/
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+      elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
+      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1
+      >minus_plus <plus_minus_m_m // -Hdi /3 width=6/
+    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -Hdi ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+        elim (IHWV1 … HK12 … HW12) -IHWV1 -HK12 #V2 #HWV2 #_
+        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) // -HW12 -HLK -HWU1 >minus_plus #H
+        lapply (tpss_weak … H d e ? ?) [1,2: normalize [ >commutative_plus <plus_minus_m_m // | /2 width=1/ ]] -Hdi -Hide /3 width=6/
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
+  ]
+| #I #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
+| #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=5/
+| #L1 #W1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
+  elim (IHTU1 … HT12) -IHTU1 -HT12 // -HL12 /3 width=3/
+]
+qed.
+
+lemma sta_ltpss_tps_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 • U1 →
+                          ∀L2,d,e. L1 ▶* [d, e] L2 →
+                          ∀T2. L2 ⊢ T1 ▶ [d, e] T2 →
+                          ∃∃U2. ⦃h, L2⦄ ⊢ T2 • U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/3 width=5/ qed.
+
+lemma sta_ltpss_conf: ∀h,L1,T,U1. ⦃h, L1⦄ ⊢ T • U1 →
+                      ∀L2,d,e. L1 ▶* [d, e] L2 →
+                      ∃∃U2. ⦃h, L2⦄ ⊢ T • U2 & L2 ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sta_tpss_conf: ∀h,L,T1,U1. ⦃h, L⦄ ⊢ T1 • U1 →
+                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                     ∃∃U2. ⦃h, L⦄ ⊢ T2 • U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
+
+lemma sta_tps_conf: ∀h,L,T1,U1. ⦃h, L⦄ ⊢ T1 • U1 →
+                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
+                    ∃∃U2. ⦃h, L⦄ ⊢ T2 • U2 & L ⊢ U1 ▶* [d, e] U2.
+/2 width=5/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr.etc
new file mode 100644 (file)
index 0000000..de987d6
--- /dev/null
@@ -0,0 +1,242 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( T1 ➡ break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PRed $T1 $T2 }.
+
+include "basic_2/substitution/tps.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
+
+(* Basic_1: includes: pr0_delta1 *)
+inductive tpr: relation term ≝
+| tpr_atom : ∀I. tpr (⓪{I}) (⓪{I})
+| tpr_flat : ∀I,V1,V2,T1,T2. tpr V1 V2 → tpr T1 T2 →
+             tpr (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+| tpr_beta : ∀a,V1,V2,W,T1,T2.
+             tpr V1 V2 → tpr T1 T2 → tpr (ⓐV1. ⓛ{a}W. T1) (ⓓ{a}V2. T2)
+| tpr_delta: ∀a,I,V1,V2,T1,T,T2.
+             tpr V1 V2 → tpr T1 T → ⋆. ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 →
+             tpr (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| tpr_theta: ∀a,V,V1,V2,W1,W2,T1,T2.
+             tpr V1 V2 → ⇧[0,1] V2 ≡ V → tpr W1 W2 → tpr T1 T2 →
+             tpr (ⓐV1. ⓓ{a}W1. T1) (ⓓ{a}W2. ⓐV. T2)
+| tpr_zeta : ∀V,T1,T,T2. tpr T1 T → ⇧[0, 1] T2 ≡ T → tpr (+ⓓV. T1) T2
+| tpr_tau  : ∀V,T1,T2. tpr T1 T2 → tpr (ⓝV. T1) T2
+.
+
+interpretation
+   "context-free parallel reduction (term)"
+   'PRed T1 T2 = (tpr T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma tpr_bind: ∀a,I,V1,V2,T1,T2. V1 ➡ V2 → T1 ➡ T2 → ⓑ{a,I} V1. T1 ➡ ⓑ{a,I} V2. T2.
+/2 width=3/ qed.
+
+(* Basic_1: was by definition: pr0_refl *)
+lemma tpr_refl: reflexive … tpr.
+#T elim T -T //
+#I elim I -I /2 width=1/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact tpr_inv_atom1_aux: ∀U1,U2. U1 ➡ U2 → ∀I. U1 = ⓪{I} → U2 = ⓪{I}.
+#U1 #U2 * -U1 -U2
+[ //
+| #I #V1 #V2 #T1 #T2 #_ #_ #k #H destruct
+| #a #V1 #V2 #W #T1 #T2 #_ #_ #k #H destruct
+| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #k #H destruct
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #k #H destruct
+| #V #T1 #T #T2 #_ #_ #k #H destruct
+| #V #T1 #T2 #_ #k #H destruct
+]
+qed.
+
+(* Basic_1: was: pr0_gen_sort pr0_gen_lref *)
+lemma tpr_inv_atom1: ∀I,U2. ⓪{I} ➡ U2 → U2 = ⓪{I}.
+/2 width=3/ qed-.
+
+fact tpr_inv_bind1_aux: ∀U1,U2. U1 ➡ U2 → ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
+                        (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
+                                    ⋆.  ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 &
+                                    U2 = ⓑ{a,I} V2. T2
+                        ) ∨
+                        ∃∃T. T1 ➡ T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
+#U1 #U2 * -U1 -U2
+[ #J #a #I #V #T #H destruct
+| #I1 #V1 #V2 #T1 #T2 #_ #_ #a #I #V #T #H destruct
+| #b #V1 #V2 #W #T1 #T2 #_ #_ #a #I #V #T #H destruct
+| #b #I1 #V1 #V2 #T1 #T #T2 #HV12 #HT1 #HT2 #a #I0 #V0 #T0 #H destruct /3 width=7/
+| #b #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #a #I0 #V0 #T0 #H destruct
+| #V #T1 #T #T2 #HT1 #HT2 #a #I0 #V0 #T0 #H destruct /3 width=3/
+| #V #T1 #T2 #_ #a #I0 #V0 #T0 #H destruct
+]
+qed.
+
+lemma tpr_inv_bind1: ∀V1,T1,U2,a,I. ⓑ{a,I} V1. T1 ➡ U2 →
+                     (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
+                                 ⋆.  ⓑ{I} V2 ⊢ T ▶ [0, 1] T2 &
+                                 U2 = ⓑ{a,I} V2. T2
+                     ) ∨
+                     ∃∃T. T1 ➡ T & ⇧[0,1] U2 ≡ T & a = true & I = Abbr.
+/2 width=3/ qed-.
+
+(* Basic_1: was pr0_gen_abbr *)
+lemma tpr_inv_abbr1: ∀a,V1,T1,U2. ⓓ{a}V1. T1 ➡ U2 →
+                     (∃∃V2,T,T2. V1 ➡ V2 & T1 ➡ T &
+                                 ⋆.  ⓓV2 ⊢ T ▶ [0, 1] T2 &
+                                 U2 = ⓓ{a}V2. T2
+                      ) ∨
+                      ∃∃T. T1 ➡ T & ⇧[0, 1] U2 ≡ T & a = true.
+#a #V1 #T1 #U2 #H
+elim (tpr_inv_bind1 … H) -H * /3 width=7/
+qed-.
+
+fact tpr_inv_flat1_aux: ∀U1,U2. U1 ➡ U2 → ∀I,V1,U0. U1 = ⓕ{I} V1. U0 →
+                        ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
+                                                 U2 = ⓕ{I} V2. T2
+                         | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
+                                                 U0 = ⓛ{a}W. T1 &
+                                                 U2 = ⓓ{a}V2. T2 & I = Appl
+                         | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
+                                                 ⇧[0,1] V2 ≡ V &
+                                                 U0 = ⓓ{a}W1. T1 &
+                                                 U2 = ⓓ{a}W2. ⓐV. T2 &
+                                                 I = Appl
+                         |                       (U0 ➡ U2 ∧ I = Cast).
+#U1 #U2 * -U1 -U2
+[ #I #J #V #T #H destruct
+| #I #V1 #V2 #T1 #T2 #HV12 #HT12 #J #V #T #H destruct /3 width=5/
+| #a #V1 #V2 #W #T1 #T2 #HV12 #HT12 #J #V #T #H destruct /3 width=9/
+| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #J #V0 #T0 #H destruct
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HV2 #HW12 #HT12 #J #V0 #T0 #H destruct /3 width=13/
+| #V #T1 #T #T2 #_ #_ #J #V0 #T0 #H destruct
+| #V #T1 #T2 #HT12 #J #V0 #T0 #H destruct /3 width=1/
+]
+qed.
+
+lemma tpr_inv_flat1: ∀V1,U0,U2,I. ⓕ{I} V1. U0 ➡ U2 →
+                     ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
+                                              U2 = ⓕ{I} V2. T2
+                      | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
+                                              U0 = ⓛ{a}W. T1 &
+                                              U2 = ⓓ{a}V2. T2 & I = Appl
+                      | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
+                                              ⇧[0,1] V2 ≡ V &
+                                              U0 = ⓓ{a}W1. T1 &
+                                              U2 = ⓓ{a}W2. ⓐV. T2 &
+                                              I = Appl
+                      |                       (U0 ➡ U2 ∧ I = Cast).
+/2 width=3/ qed-.
+
+(* Basic_1: was pr0_gen_appl *)
+lemma tpr_inv_appl1: ∀V1,U0,U2. ⓐV1. U0 ➡ U2 →
+                     ∨∨ ∃∃V2,T2.              V1 ➡ V2 & U0 ➡ T2 &
+                                              U2 = ⓐV2. T2
+                      | ∃∃a,V2,W,T1,T2.       V1 ➡ V2 & T1 ➡ T2 &
+                                              U0 = ⓛ{a}W. T1 &
+                                              U2 = ⓓ{a}V2. T2
+                      | ∃∃a,V2,V,W1,W2,T1,T2. V1 ➡ V2 & W1 ➡ W2 & T1 ➡ T2 &
+                                              ⇧[0,1] V2 ≡ V &
+                                              U0 = ⓓ{a}W1. T1 &
+                                              U2 = ⓓ{a}W2. ⓐV. T2.
+#V1 #U0 #U2 #H
+elim (tpr_inv_flat1 … H) -H *
+/3 width=5/ /3 width=9/ /3 width=13/
+#_ #H destruct
+qed-.
+
+(* Note: the main property of simple terms *)
+lemma tpr_inv_appl1_simple: ∀V1,T1,U. ⓐV1. T1 ➡ U → 𝐒⦃T1⦄ →
+                            ∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 &
+                                     U = ⓐV2. T2.
+#V1 #T1 #U #H #HT1
+elim (tpr_inv_appl1 … H) -H *
+[ /2 width=5/
+| #a #V2 #W #W1 #W2 #_ #_ #H #_ destruct
+  elim (simple_inv_bind … HT1)
+| #a #V2 #V #W1 #W2 #U1 #U2 #_ #_ #_ #_ #H #_ destruct
+  elim (simple_inv_bind … HT1)
+]
+qed-.
+
+(* Basic_1: was: pr0_gen_cast *)
+lemma tpr_inv_cast1: ∀V1,T1,U2. ⓝV1. T1 ➡ U2 →
+                       (∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 & U2 = ⓝV2. T2)
+                     ∨ T1 ➡ U2.
+#V1 #T1 #U2 #H
+elim (tpr_inv_flat1 … H) -H * /3 width=5/ #a #V2 #W #W1 #W2
+[ #_ #_ #_ #_ #H destruct
+| #T2 #U1 #_ #_ #_ #_ #_ #_ #H destruct
+]
+qed-.
+
+fact tpr_inv_lref2_aux: ∀T1,T2. T1 ➡ T2 → ∀i. T2 = #i →
+                        ∨∨        T1 = #i
+                         | ∃∃V,T. T ➡ #(i+1) & T1 = +ⓓV. T
+                         | ∃∃V,T. T ➡ #i & T1 = ⓝV. T.
+#T1 #T2 * -T1 -T2
+[ #I #i #H destruct /2 width=1/
+| #I #V1 #V2 #T1 #T2 #_ #_ #i #H destruct
+| #a #V1 #V2 #W #T1 #T2 #_ #_ #i #H destruct
+| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #_ #i #H destruct
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #i #H destruct
+| #V #T1 #T #T2 #HT1 #HT2 #i #H destruct
+  lapply (lift_inv_lref1_ge … HT2 ?) -HT2 // #H destruct /3 width=4/
+| #V #T1 #T2 #HT12 #i #H destruct /3 width=4/
+]
+qed.
+
+lemma tpr_inv_lref2: ∀T1,i. T1 ➡ #i →
+                     ∨∨        T1 = #i
+                      | ∃∃V,T. T ➡ #(i+1) & T1 = +ⓓV. T
+                      | ∃∃V,T. T ➡ #i & T1 = ⓝV. T.
+/2 width=3/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma tpr_fwd_bind1_minus: ∀I,V1,T1,T. -ⓑ{I}V1.T1 ➡ T → ∀b.
+                           ∃∃V2,T2. ⓑ{b,I}V1.T1 ➡ ⓑ{b,I}V2.T2 &
+                                    T = -ⓑ{I}V2.T2.
+#I #V1 #T1 #T #H #b elim (tpr_inv_bind1 … H) -H *
+[ #V2 #T0 #T2 #HV12 #HT10 #HT02 #H destruct /3 width=4/
+| #T2 #_ #_ #H destruct
+]
+qed-.
+
+lemma tpr_fwd_shift1: ∀L1,T1,T. L1 @@ T1 ➡ T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #T1 #T #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #T1 #X
+  >shift_append_assoc normalize #H
+  elim (tpr_inv_bind1 … H) -H *
+  [ #V0 #T0 #X0 #_ #HT10 #H0 #H destruct
+    elim (IH … HT10) -IH -T1 #L #T #HL1 #H destruct
+    elim (tps_fwd_shift1 … H0) -T #L2 #T2 #HL2 #H destruct
+    >append_length >HL1 >HL2 -L1 -L
+    @(ex2_2_intro … (⋆.ⓑ{I}V0@@L2) T2) [ >append_length ] // /2 width=3/ (**) (* explicit constructor *)
+  | #T #_ #_ #H destruct
+  ]
+]
+qed-.
+
+(* Basic_1: removed theorems 3:
+            pr0_subst0_back pr0_subst0_fwd pr0_subst0
+*)
+(* Basic_1: removed local theorems: 1: pr0_delta_tau *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_lift.etc
new file mode 100644 (file)
index 0000000..8d6b036
--- /dev/null
@@ -0,0 +1,121 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/tps_lift.ma".
+include "basic_2/reducibility/tpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
+
+(* Relocation properties ****************************************************)
+
+(* Basic_1: was: pr0_lift *)
+lemma tpr_lift: t_liftable tpr.
+#T1 #T2 #H elim H -T1 -T2
+[ * #i #U1 #d #e #HU1 #U2 #HU2
+  lapply (lift_mono … HU1 … HU2) -HU1 #H destruct
+  [ lapply (lift_inv_sort1 … HU2) -HU2 #H destruct //
+  | lapply (lift_inv_lref1 … HU2) * * #Hid #H destruct //
+  | lapply (lift_inv_gref1 … HU2) -HU2 #H destruct //
+  ]
+| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
+  elim (lift_inv_flat1 … HX1) -HX1 #W1 #U1 #HVW1 #HTU1 #HX1 destruct
+  elim (lift_inv_flat1 … HX2) -HX2 #W2 #U2 #HVW2 #HTU2 #HX2 destruct /3 width=4/
+| #a #V1 #V2 #W #T1 #T2 #_ #_ #IHV12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
+  elim (lift_inv_flat1 … HX1) -HX1 #V0 #X #HV10 #HX #HX1 destruct
+  elim (lift_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT10 #HX destruct
+  elim (lift_inv_bind1 … HX2) -HX2 #V3 #T3 #HV23 #HT23 #HX2 destruct /3 width=4/
+| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV12 #IHT1 #X1 #d #e #HX1 #X2 #HX2
+  elim (lift_inv_bind1 … HX1) -HX1 #W1 #U1 #HVW1 #HTU1 #HX1 destruct
+  elim (lift_inv_bind1 … HX2) -HX2 #W2 #U0 #HVW2 #HTU0 #HX2 destruct
+  elim (lift_total T (d + 1) e) #U #HTU
+  @tpr_delta
+  [4: @(tps_lift_le … HT2 … HTU HTU0 ?) /2 width=1/ |1: skip |2: /2 width=4/ |3: /2 width=4/ ] (**) (*/3. is too slow *)
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #X1 #d #e #HX1 #X2 #HX2
+  elim (lift_inv_flat1 … HX1) -HX1 #V0 #X #HV10 #HX #HX1 destruct
+  elim (lift_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT10 #HX destruct
+  elim (lift_inv_bind1 … HX2) -HX2 #W3 #X #HW23 #HX #HX2 destruct
+  elim (lift_inv_flat1 … HX) -HX #V3 #T3 #HV3 #HT23 #HX destruct
+  elim (lift_trans_ge … HV2 … HV3 ?) -V // /3 width=4/
+| #V #T1 #T #T2 #_ #HT2 #IHT1 #X #d #e #H #U2 #HTU2
+  elim (lift_inv_bind1 … H) -H #V3 #T3 #_ #HT13 #H destruct -V
+  elim (lift_conf_O1 … HTU2 … HT2) -T2 /3 width=4/
+| #V #T1 #T2 #_ #IHT12 #X #d #e #HX #T #HT2
+  elim (lift_inv_flat1 … HX) -HX #V0 #T0 #_ #HT0 #HX destruct /3 width=4/
+]
+qed.
+
+(* Basic_1: was: pr0_gen_lift *)
+lemma tpr_inv_lift1: t_deliftable_sn tpr.
+#T1 #T2 #H elim H -T1 -T2
+[ * #i #X #d #e #HX
+  [ lapply (lift_inv_sort2 … HX) -HX #H destruct /2 width=3/
+  | lapply (lift_inv_lref2 … HX) -HX * * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … HX) -HX #H destruct /2 width=3/
+  ]
+| #I #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #X #d #e #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #T0 #HV01 #HT01 #HX destruct
+  elim (IHV12 … HV01) -V1
+  elim (IHT12 … HT01) -T1 /3 width=5/
+| #a #V1 #V2 #W1 #T1 #T2 #_ #_ #IHV12 #IHT12 #X #d #e #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
+  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
+  elim (IHV12 … HV01) -V1
+  elim (IHT12 … HT01) -T1 /3 width=5/
+| #a #I #V1 #V2 #T1 #T #T2 #_ #_ #HT2 #IHV12 #IHT1 #X #d #e #HX
+  elim (lift_inv_bind2 … HX) -HX #W1 #U1 #HWV1 #HUT1 #HX destruct
+  elim (IHV12 … HWV1) -V1 #W2 #HWV2 #HW12
+  elim (IHT1 … HUT1) -T1 #U #HUT #HU1
+  elim (tps_inv_lift1_le … HT2 … HUT ?) -T // [3: /2 width=5/ |2: skip ] #U2 #HU2 #HUT2
+  @ex2_intro  [2: /2 width=2/ |1: skip |3: /2 width=3/ ] (**) (* /3 width=5/ is slow *)
+| #a #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #X #d #e #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
+  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
+  elim (IHV12 … HV01) -V1 #V3 #HV32 #HV03
+  elim (IHW12 … HW01) -W1 #W3 #HW32 #HW03
+  elim (IHT12 … HT01) -T1 #T3 #HT32 #HT03
+  elim (lift_trans_le … HV32 … HV2 ?) -V2 // #V2 #HV32 #HV2
+  @ex2_intro [2: /3 width=2/ |1: skip |3: /2 width=3/ ] (**) (* /4 width=5/ is slow *)
+| #V #T1 #T #T2 #_ #HT2 #IHT1 #X #d #e #HX
+  elim (lift_inv_bind2 … HX) -HX #V3 #T3 #_ #HT31 #H destruct
+  elim (IHT1 … HT31) -T1 #T1 #HT1 #HT31
+  elim (lift_div_le … HT2 … HT1 ?) -T // /3 width=5/
+| #V #T1 #T2 #_ #IHT12 #X #d #e #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #T0 #_ #HT01 #H destruct
+  elim (IHT12 … HT01) -T1 /3 width=3/
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+(* Basic_1: was pr0_gen_abst *)
+lemma tpr_inv_abst1: ∀a,V1,T1,U2. ⓛ{a}V1. T1 ➡ U2 →
+                     ∃∃V2,T2. V1 ➡ V2 & T1 ➡ T2 & U2 = ⓛ{a}V2. T2.
+#a #V1 #T1 #U2 #H elim (tpr_inv_bind1 … H) -H *
+[ #V2 #T #T2 #HV12 #HT1 #HT2
+  lapply (tps_inv_refl_SO2 … HT2 ???) -HT2 // /2 width=5/
+| #T2 #_ #_ #_ #H destruct
+]
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma tpr_fwd_abst1: ∀a,V1,T1,U2. ⓛ{a}V1.T1 ➡ U2 → ∀b,I,W.
+                     ∃∃V2,T2. ⓑ{b,I}W.T1 ➡ ⓑ{b,I}W.T2 &
+                              U2 = ⓛ{a}V2.T2.
+#a #V1 #T1 #U2 #H #b #I #W elim (tpr_inv_bind1 … H) -H *
+[ #V2 #T #T2 #HV12 #HT1 #HT2
+  lapply (tps_inv_refl_SO2 … HT2 ???) -HT2 // /3 width=4/
+| #T2 #_ #_ #_ #H destruct
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_tpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpr_tpr.etc
new file mode 100644 (file)
index 0000000..a733345
--- /dev/null
@@ -0,0 +1,261 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/ltpr_tpss.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
+
+(* Confluence lemmas ********************************************************)
+
+fact tpr_conf_atom_atom: ∀I. ∃∃X. ⓪{I} ➡ X & ⓪{I} ➡ X.
+/2 width=3/ qed.
+
+fact tpr_conf_flat_flat:
+   ∀I,V0,V1,T0,T1,V2,T2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
+   ∃∃T0. ⓕ{I} V1. T1 ➡ T0 & ⓕ{I} V2. T2 ➡ T0.
+#I #V0 #V1 #T0 #T1 #V2 #T2 #IH #HV01 #HV02 #HT01 #HT02
+elim (IH … HV01 … HV02) -HV01 -HV02 // #V #HV1 #HV2
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /3 width=5/
+qed.
+
+fact tpr_conf_flat_beta:
+   ∀a,V0,V1,T1,V2,W0,U0,T2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{U0} + 1) + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 →
+   U0 ➡ T2 → ⓛ{a}W0. U0 ➡ T1 →
+   ∃∃X. ⓐV1. T1 ➡ X & ⓓ{a}V2. T2 ➡ X.
+#a #V0 #V1 #T1 #V2 #W0 #U0 #T2 #IH #HV01 #HV02 #HT02 #H
+elim (tpr_inv_abst1 … H) -H #W1 #U1 #HW01 #HU01 #H destruct
+elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
+elim (IH … HT02 … HU01) -HT02 -HU01 -IH /2 width=1/ /3 width=5/
+qed.
+
+(* Basic-1: was:
+            pr0_cong_upsilon_refl pr0_cong_upsilon_zeta
+            pr0_cong_upsilon_cong pr0_cong_upsilon_delta
+*)
+fact tpr_conf_flat_theta:
+   ∀a,V0,V1,T1,V2,V,W0,W2,U0,U2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{U0} + 1) + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 → ⇧[O,1] V2 ≡ V →
+   W0 ➡ W2 → U0 ➡ U2 →  ⓓ{a}W0. U0 ➡ T1 →
+   ∃∃X. ⓐV1. T1 ➡ X & ⓓ{a}W2. ⓐV. U2 ➡ X.
+#a #V0 #V1 #T1 #V2 #V #W0 #W2 #U0 #U2 #IH #HV01 #HV02 #HV2 #HW02 #HU02 #H
+elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #VV #HVV1 #HVV2
+elim (lift_total VV 0 1) #VVV #HVV
+lapply (tpr_lift … HVV2 … HV2 … HVV) #HVVV
+elim (tpr_inv_abbr1 … H) -H *
+(* case 1: delta *)
+[ -HV2 -HVV2 #WW2 #UU2 #UU #HWW2 #HUU02 #HUU2 #H destruct
+  elim (IH … HW02 … HWW2) -HW02 -HWW2 /2 width=1/ #W #HW02 #HWW2
+  elim (IH … HU02 … HUU02) -HU02 -HUU02 -IH /2 width=1/ #U #HU2 #HUUU2
+  elim (tpr_tps_conf_bind … HWW2 HUUU2 … HUU2) -UU2 #UUU #HUUU2 #HUUU1
+  @ex2_intro
+  [2: @tpr_theta [6: @HVV |7: @HWW2 |8: @HUUU2 |1,2,3,4: skip | // ]
+  |1:skip
+  |3: @tpr_delta [3: @tpr_flat |1: skip ] /2 width=5/
+  ] (**) (* /5 width=14/ is too slow *)
+(* case 3: zeta *)
+| -HV2 -HW02 -HVV2 #U1 #HU01 #HTU1
+  elim (IH … HU01 … HU02) -HU01 -HU02 -IH // -U0 #U #HU1 #HU2
+  elim (tpr_inv_lift1 … HU1 … HTU1) -U1 #UU #HUU #HT1UU #H destruct
+  @(ex2_intro … (ⓐVV.UU)) /2 width=1/ /3 width=5/ (**) (* /4 width=9/ is too slow *)
+]
+qed.
+
+fact tpr_conf_flat_cast:
+   ∀X2,V0,V1,T0,T1. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → T0 ➡ T1 → T0 ➡ X2 →
+   ∃∃X. ⓝV1. T1 ➡ X & X2 ➡ X.
+#X2 #V0 #V1 #T0 #T1 #IH #_ #HT01 #HT02
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /3 width=3/
+qed.
+
+fact tpr_conf_beta_beta:
+   ∀a. ∀W0:term. ∀V0,V1,T0,T1,V2,T2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{T0} + 1) + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
+   ∃∃X. ⓓ{a}V1. T1 ➡X & ⓓ{a}V2. T2 ➡ X.
+#a #W0 #V0 #V1 #T0 #T1 #V2 #T2 #IH #HV01 #HV02 #HT01 #HT02
+elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH /2 width=1/ /3 width=5/
+qed.
+
+(* Basic_1: was: pr0_cong_delta pr0_delta_delta *)
+fact tpr_conf_delta_delta:
+   ∀a,I1,V0,V1,T0,T1,TT1,V2,T2,TT2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 → T0 ➡ T1 → T0 ➡ T2 →
+   ⋆. ⓑ{I1} V1 ⊢ T1 ▶ [O, 1] TT1 →
+   ⋆. ⓑ{I1} V2 ⊢ T2 ▶ [O, 1] TT2 →
+   ∃∃X. ⓑ{a,I1} V1. TT1 ➡ X & ⓑ{a,I1} V2. TT2 ➡ X.
+#a #I1 #V0 #V1 #T0 #T1 #TT1 #V2 #T2 #TT2 #IH #HV01 #HV02 #HT01 #HT02 #HTT1 #HTT2
+elim (IH … HV01 … HV02) -HV01 -HV02 // #V #HV1 #HV2
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH // #T #HT1 #HT2
+elim (tpr_tps_conf_bind … HV1 HT1 … HTT1) -T1 #U1 #TTU1 #HTU1
+elim (tpr_tps_conf_bind … HV2 HT2 … HTT2) -T2 #U2 #TTU2 #HTU2
+elim (tps_conf_eq … HTU1 … HTU2) -T #U #HU1 #HU2
+@ex2_intro [2,3: @tpr_delta |1: skip ] /width=10/ (**) (* /3 width=10/ is too slow *)
+qed.
+
+fact tpr_conf_delta_zeta:
+   ∀X2,V0,V1,T0,T1,TT1,T2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → T0 ➡ T1 → ⋆. ⓓV1 ⊢ T1 ▶ [O,1] TT1 →
+   T0 ➡ T2 → ⇧[O, 1] X2 ≡ T2 →
+   ∃∃X. +ⓓV1. TT1 ➡ X & X2 ➡ X.
+#X2 #V0 #V1 #T0 #T1 #TT1 #T2 #IH #_ #HT01 #HTT1 #HT02 #HXT2
+elim (IH … HT01 … HT02) -IH -HT01 -HT02 // -V0 -T0 #T #HT1 #HT2
+elim (tpr_tps_conf_bind ? ? V1 … HT1 HTT1) -T1 // #TT #HTT1 #HTT
+elim (tpr_inv_lift1 … HT2 … HXT2) -T2 #X #HXT #HX2
+lapply (tps_inv_lift1_eq … HTT … HXT) -HTT #H destruct /3 width=3/
+qed.
+
+(* Basic_1: was: pr0_upsilon_upsilon *)
+fact tpr_conf_theta_theta:
+   ∀a,VV1,V0,V1,W0,W1,T0,T1,V2,VV2,W2,T2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + (♯{W0} + ♯{T0} + 1) + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   V0 ➡ V1 → V0 ➡ V2 → W0 ➡ W1 → W0 ➡ W2 → T0 ➡ T1 → T0 ➡ T2 →
+   ⇧[O, 1] V1 ≡ VV1 → ⇧[O, 1] V2 ≡ VV2 →
+   ∃∃X. ⓓ{a}W1. ⓐVV1. T1 ➡ X & ⓓ{a}W2. ⓐVV2. T2 ➡ X.
+#a #VV1 #V0 #V1 #W0 #W1 #T0 #T1 #V2 #VV2 #W2 #T2 #IH #HV01 #HV02 #HW01 #HW02 #HT01 #HT02 #HVV1 #HVV2
+elim (IH … HV01 … HV02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
+elim (IH … HW01 … HW02) -HW01 -HW02 /2 width=1/ #W #HW1 #HW2
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH /2 width=1/ #T #HT1 #HT2
+elim (lift_total V 0 1) #VV #HVV
+lapply (tpr_lift … HV1 … HVV1 … HVV) -V1 #HVV1
+lapply (tpr_lift … HV2 … HVV2 … HVV) -V2 -HVV #HVV2
+@ex2_intro [2,3: @tpr_bind |1:skip ] /2 width=5/ (**) (* /4 width=5/ is too slow *)
+qed.
+
+fact tpr_conf_zeta_zeta:
+   ∀V0:term. ∀X2,TT0,T0,T1,TT2. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{TT0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   TT0 ➡ T0 → ⇧[O, 1] T1 ≡ T0 →
+   TT0 ➡ TT2 → ⇧[O, 1] X2 ≡ TT2 →
+   ∃∃X. T1 ➡ X & X2 ➡ X.
+#V0 #X2 #TT0 #T0 #T1 #TT2 #IH #HTT0 #HT10 #HTT02 #HXTT2
+elim (IH … HTT0 … HTT02) -IH -HTT0 -HTT02 // -V0 -TT0 #T #HT0 #HTT2
+elim (tpr_inv_lift1 … HT0 … HT10) -T0 #T0 #HT0 #HT10
+elim (tpr_inv_lift1 … HTT2 … HXTT2) -TT2 #TT2 #HTT2 #HXTT2
+lapply (lift_inj … HTT2 … HT0) -HTT2 #H destruct /2 width=3/
+qed.
+
+fact tpr_conf_tau_tau:
+   ∀V0,T0:term. ∀X2,T1. (
+      ∀X0:term. ♯{X0} < ♯{V0} + ♯{T0} + 1 →
+      ∀X1,X2. X0 ➡ X1 → X0 ➡ X2 →
+      ∃∃X. X1 ➡ X & X2 ➡ X
+   ) →
+   T0 ➡ T1 → T0 ➡ X2 →
+   ∃∃X. T1 ➡ X & X2 ➡ X.
+#V0 #T0 #X2 #T1 #IH #HT01 #HT02
+elim (IH … HT01 … HT02) -HT01 -HT02 -IH // /2 width=3/
+qed.
+
+(* Confluence ***************************************************************)
+
+(* Basic_1: was: pr0_confluence *)
+theorem tpr_conf: ∀T0:term. ∀T1,T2. T0 ➡ T1 → T0 ➡ T2 →
+                  ∃∃T. T1 ➡ T & T2 ➡ T.
+#T0 @(f_ind … tw … T0) -T0 #n #IH *
+[ #I #_ #X1 #X2 #H1 #H2 -n
+  >(tpr_inv_atom1 … H1) -X1
+  >(tpr_inv_atom1 … H2) -X2
+(* case 1: atom, atom *)
+  //
+| * [ #a ] #I #V0 #T0 #Hn #X1 #X2 #H1 #H2
+  [ elim (tpr_inv_bind1 … H1) -H1 *
+    [ #V1 #T1 #U1 #HV01 #HT01 #HTU1 #H1
+    | #T1 #HT01 #HXT1 #H11 #H12
+    ]
+    elim (tpr_inv_bind1 … H2) -H2 *
+    [1,3: #V2 #T2 #U2 #HV02 #HT02 #HTU2 #H2
+    |2,4: #T2 #HT02 #HXT2 #H21 #H22
+    ] destruct
+(* case 2: delta, delta *)
+    [ /3 width=11 by tpr_conf_delta_delta/ (**) (* /3 width=11/ is too slow *)
+(* case 3: zeta, delta (repeated) *)
+    | @ex2_commute /3 width=10 by tpr_conf_delta_zeta/
+(* case 4: delta, zeta *)
+    | /3 width=10 by tpr_conf_delta_zeta/ (**) (* /3 width=10/ is too slow *)
+(* case 5: zeta, zeta *)
+    | /3 width=9 by tpr_conf_zeta_zeta/ (**) (* /3 width=9/ is too slow *)
+    ]
+  | elim (tpr_inv_flat1 … H1) -H1 *
+    [ #V1 #T1 #HV01 #HT01 #H1
+    | #b1 #V1 #W1 #U1 #T1 #HV01 #HUT1 #H11 #H12 #H13
+    | #b1 #V1 #Y1 #W1 #Z1 #U1 #T1 #HV01 #HWZ1 #HUT1 #HVY1 #H11 #H12 #H13
+    | #HX1 #H1
+    ]
+    elim (tpr_inv_flat1 … H2) -H2 *
+    [1,5,9,13: #V2 #T2 #HV02 #HT02 #H2
+    |2,6,10,14: #b2 #V2 #W2 #U2 #T2 #HV02 #HUT2 #H21 #H22 #H23
+    |3,7,11,15: #b2 #V2 #Y2 #W2 #Z2 #U2 #T2 #HV02 #HWZ2 #HUT2 #HVY2 #H21 #H22 #H23
+    |4,8,12,16: #HX2 #H2
+    ] destruct
+(* case 6: flat, flat *)
+    [ /3 width=7 by tpr_conf_flat_flat/ (**) (* /3 width=7/ is too slow *)
+(* case 7: beta, flat (repeated) *)
+    | @ex2_commute /3 width=8 by tpr_conf_flat_beta/
+(* case 8: theta, flat (repeated) *)
+    | @ex2_commute /3 width=11 by tpr_conf_flat_theta/
+(* case 9: tau, flat (repeated) *)
+    | @ex2_commute /3 width=6 by tpr_conf_flat_cast/
+(* case 10: flat, beta *)
+    | /3 width=8 by tpr_conf_flat_beta/ (**) (* /3 width=8/ is too slow *)
+(* case 11: beta, beta *)
+    | /3 width=8 by tpr_conf_beta_beta/ (**) (* /3 width=8/ is too slow *)
+(* case 12: flat, theta *)
+    | /3 width=11 by tpr_conf_flat_theta/ (**) (* /3 width=11/ is too slow *)
+(* case 13: theta, theta *)
+    | /3 width=14 by tpr_conf_theta_theta/ (**) (* /3 width=14/ is too slow *)
+(* case 14: flat, tau *)
+    | /3 width=6 by tpr_conf_flat_cast/ (**) (* /3 width=6/ is too slow *)
+(* case 15: tau, tau *)
+    | /3 width=5 by tpr_conf_tau_tau/
+    ]
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs.etc
new file mode 100644 (file)
index 0000000..492b390
--- /dev/null
@@ -0,0 +1,94 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( T1 ➡ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PRedStar $T1 $T2 }.
+
+include "basic_2/reducibility/tpr.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
+
+(* Basic_1: includes: pr1_pr0 *)
+definition tprs: relation term ≝ TC … tpr.
+
+interpretation "context-free parallel computation (term)"
+   'PRedStar T1 T2 = (tprs T1 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma tprs_ind: ∀T1. ∀R:predicate term. R T1 →
+                (∀T,T2. T1 ➡* T → T ➡ T2 → R T → R T2) →
+                ∀T2. T1 ➡* T2 → R T2.
+#T1 #R #HT1 #IHT1 #T2 #HT12
+@(TC_star_ind … HT1 IHT1 … HT12) //
+qed-.
+
+lemma tprs_ind_dx: ∀T2. ∀R:predicate term. R T2 →
+                   (∀T1,T. T1 ➡ T → T ➡* T2 → R T → R T1) →
+                   ∀T1. T1 ➡* T2 → R T1.
+#T2 #R #HT2 #IHT2 #T1 #HT12
+@(TC_star_ind_dx … HT2 IHT2 … HT12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma tprs_refl: reflexive … tprs.
+/2 width=1/ qed.
+
+lemma tpr_tprs: ∀T1,T2. T1 ➡ T2 → T2 ➡* T2.
+/2 width=1/ qed.
+
+lemma tprs_strap1: ∀T1,T,T2. T1 ➡* T → T ➡ T2 → T1 ➡* T2.
+/2 width=3/ qed.
+
+lemma tprs_strap2: ∀T1,T,T2. T1 ➡ T → T ➡* T2 → T1 ➡* T2.
+/2 width=3/ qed.
+
+(* Basic_1: was only: pr1_head_1 *)
+lemma tprs_pair_sn: ∀I,T1,T2. T1 ➡ T2 → ∀V1,V2. V1 ➡* V2 →
+                    ②{I} V1. T1 ➡* ②{I} V2. T2.
+* [ #a ] #I #T1 #T2 #HT12 #V1 #V2 #H @(tprs_ind … H) -V2
+[1,3: /3 width=1/
+|2,4: #V #V2 #_ #HV2 #IHV1
+      @(tprs_strap1 … IHV1) -IHV1 /2 width=1/
+]
+qed.
+
+(* Basic_1: was only: pr1_head_2 *)
+lemma tprs_pair_dx: ∀I,V1,V2. V1 ➡ V2 → ∀T1,T2. T1 ➡* T2 →
+                    ②{I} V1. T1 ➡* ②{I} V2. T2.
+* [ #a ] #I #V1 #V2 #HV12 #T1 #T2 #H @(tprs_ind … H) -T2
+[1,3: /3 width=1/
+|2,4: #T #T2 #_ #HT2 #IHT1
+      @(tprs_strap1 … IHT1) -IHT1 /2 width=1/
+]
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma tprs_inv_atom1: ∀U2,k. ⋆k ➡* U2 → U2 = ⋆k.
+#U2 #k #H @(tprs_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU1 destruct
+>(tpr_inv_atom1 … HU2) -HU2 //
+qed-.
+
+lemma tprs_inv_cast1: ∀W1,T1,U2. ⓝW1.T1 ➡* U2 → T1 ➡* U2 ∨
+                      ∃∃W2,T2. W1 ➡* W2 & T1 ➡* T2 & U2 = ⓝW2.T2.
+#W1 #T1 #U2 #H @(tprs_ind … H) -U2 /3 width=5/
+#U #U2 #_ #HU2 * /3 width=3/ *
+#W #T #HW1 #HT1 #H destruct
+elim (tpr_inv_cast1 … HU2) -HU2 /3 width=3/ *
+#W2 #T2 #HW2 #HT2 #H destruct /4 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_lift.etc
new file mode 100644 (file)
index 0000000..d0d1734
--- /dev/null
@@ -0,0 +1,43 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/tpr_lift.ma".
+include "basic_2/computation/tprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma tprs_inv_abst1: ∀a,V1,T1,U2. ⓛ{a}V1. T1 ➡* U2 →
+                      ∃∃V2,T2. V1 ➡* V2 & T1 ➡* T2 & U2 = ⓛ{a}V2. T2.
+#a #V1 #T1 #U2 #H @(tprs_ind … H) -U2 /2 width=5/
+#U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
+elim (tpr_inv_abst1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
+qed-.
+
+lemma tprs_inv_abst: ∀a,V1,V2,T1,T2. ⓛ{a}V1. T1 ➡* ⓛ{a}V2. T2 →
+                     V1 ➡* V2 ∧ T1 ➡* T2.
+#a #V1 #V2 #T1 #T2 #H
+elim (tprs_inv_abst1 … H) -H #V #T #HV1 #HT1 #H destruct /2 width=1/
+qed-.
+
+(* Relocation properties ****************************************************)
+
+(* Note: this was missing in basic_1 *)
+lemma tprs_lift: t_liftable tprs.
+/3 width=7/ qed.
+
+(* Note: this was missing in basic_1 *)
+lemma tprs_inv_lift1: t_deliftable_sn tprs.
+/3 width=3 by tpr_inv_lift1, t_deliftable_sn_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_tprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tprs_tprs.etc
new file mode 100644 (file)
index 0000000..87a4a71
--- /dev/null
@@ -0,0 +1,43 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/tpr_tpr.ma".
+include "basic_2/computation/tprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON TERMS *******************************)
+
+(* Advanced properties ******************************************************)
+
+(* Basic_1: was: pr1_strip *)
+lemma tprs_strip: ∀T1,T. T ➡* T1 → ∀T2. T ➡ T2 →
+                  ∃∃T0. T1 ➡ T0 & T2 ➡* T0.
+/3 width=3 by TC_strip1, tpr_conf/ qed.
+
+(* Main propertis ***********************************************************)
+
+(* Basic_1: was: pr1_confluence *)
+theorem tprs_conf: confluent … tprs.
+/3 width=3/ qed.
+
+(* Basic_1: was: pr1_t *)
+theorem tprs_trans: Transitive … tprs.
+/2 width=3/ qed.
+
+(* Basic_1: was: pr1_comp *)
+lemma tprs_pair: ∀I,V1,V2. V1 ➡* V2 → ∀T1,T2. T1 ➡* T2 →
+                 ②{I} V1. T1 ➡* ②{I} V2. T2.
+#I #V1 #V2 #H @(tprs_ind … H) -V2 /2 width=1/
+#V #V2 #_ #HV2 #IHV1 #T1 #T2 #HT12
+@(tprs_trans … (②{I}V.T2)) /2 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps.etc
new file mode 100644 (file)
index 0000000..7d89243
--- /dev/null
@@ -0,0 +1,288 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 break ▶ [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubst $L $T1 $d $e $T2 }.
+
+include "basic_2/substitution/ldrop_append.ma".
+
+(* PARALLEL SUBSTITUTION ON TERMS *******************************************)
+
+inductive tps: nat → nat → lenv → relation term ≝
+| tps_atom : ∀L,I,d,e. tps d e L (⓪{I}) (⓪{I})
+| tps_subst: ∀L,K,V,W,i,d,e. d ≤ i → i < d + e →
+             ⇩[0, i] L ≡ K. ⓓV → ⇧[0, i + 1] V ≡ W → tps d e L (#i) W
+| tps_bind : ∀L,a,I,V1,V2,T1,T2,d,e.
+             tps d e L V1 V2 → tps (d + 1) e (L. ⓑ{I} V2) T1 T2 →
+             tps d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| tps_flat : ∀L,I,V1,V2,T1,T2,d,e.
+             tps d e L V1 V2 → tps d e L T1 T2 →
+             tps d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+.
+
+interpretation "parallel substritution (term)"
+   'PSubst L T1 d e T2 = (tps d e L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma tps_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶ [d, e] T2 →
+                       ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶ [d, e] T2.
+#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
+[ //
+| #L1 #K1 #V #W #i #d #e #Hdi #Hide #HLK1 #HVW #L2 #HL12
+  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /2 width=4/
+| /4 width=1/
+| /3 width=1/
+]
+qed.
+
+lemma tps_refl: ∀T,L,d,e. L ⊢ T ▶ [d, e] T.
+#T elim T -T //
+#I elim I -I /2 width=1/
+qed.
+
+(* Basic_1: was: subst1_ex *)
+lemma tps_full: ∀K,V,T1,L,d. ⇩[0, d] L ≡ (K. ⓓV) →
+                ∃∃T2,T. L ⊢ T1 ▶ [d, 1] T2 & ⇧[d, 1] T ≡ T2.
+#K #V #T1 elim T1 -T1
+[ * #i #L #d #HLK /2 width=4/
+  elim (lt_or_eq_or_gt i d) #Hid /3 width=4/
+  destruct
+  elim (lift_total V 0 (i+1)) #W #HVW
+  elim (lift_split … HVW i i ? ? ?) // /3 width=4/
+| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
+  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
+  [ elim (IHU1 (L. ⓑ{I} W2) (d+1) ?) -IHU1 /2 width=1/ -HLK /3 width=9/
+  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8/
+  ]
+]
+qed.
+
+lemma tps_weak: ∀L,T1,T2,d1,e1. L ⊢ T1 ▶ [d1, e1] T2 →
+                ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 →
+                L ⊢ T1 ▶ [d2, e2] T2.
+#L #T1 #T2 #d1 #e1 #H elim H -L -T1 -T2 -d1 -e1
+[ //
+| #L #K #V #W #i #d1 #e1 #Hid1 #Hide1 #HLK #HVW #d2 #e2 #Hd12 #Hde12
+  lapply (transitive_le … Hd12 … Hid1) -Hd12 -Hid1 #Hid2
+  lapply (lt_to_le_to_lt … Hide1 … Hde12) -Hide1 /2 width=4/
+| /4 width=3/
+| /4 width=1/
+]
+qed.
+
+lemma tps_weak_top: ∀L,T1,T2,d,e.
+                    L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶ [d, |L| - d] T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
+[ //
+| #L #K #V #W #i #d #e #Hdi #_ #HLK #HVW
+  lapply (ldrop_fwd_ldrop2_length … HLK) #Hi
+  lapply (le_to_lt_to_lt … Hdi Hi) /3 width=4/
+| normalize /2 width=1/
+| /2 width=1/
+]
+qed.
+
+lemma tps_weak_full: ∀L,T1,T2,d,e.
+                     L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶ [0, |L|] T2.
+#L #T1 #T2 #d #e #HT12
+lapply (tps_weak … HT12 0 (d + e) ? ?) -HT12 // #HT12
+lapply (tps_weak_top … HT12) //
+qed.
+
+lemma tps_split_up: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ∀i. d ≤ i → i ≤ d + e →
+                    ∃∃T. L ⊢ T1 ▶ [d, i - d] T & L ⊢ T ▶ [i, d + e - i] T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
+[ /2 width=3/
+| #L #K #V #W #i #d #e #Hdi #Hide #HLK #HVW #j #Hdj #Hjde
+  elim (lt_or_ge i j)
+  [ -Hide -Hjde
+    >(plus_minus_m_m j d) in ⊢ (% → ?); // -Hdj /3 width=4/
+  | -Hdi -Hdj #Hij
+    lapply (plus_minus_m_m … Hjde) -Hjde /3 width=8/
+  ]
+| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
+  elim (IHV12 i ? ?) -IHV12 // #V #HV1 #HV2
+  elim (IHT12 (i + 1) ? ?) -IHT12 /2 width=1/
+  -Hdi -Hide >arith_c1x #T #HT1 #HT2
+  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /3 width=5/
+| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
+  elim (IHV12 i ? ?) -IHV12 // elim (IHT12 i ? ?) -IHT12 //
+  -Hdi -Hide /3 width=5/
+]
+qed.
+
+lemma tps_split_down: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 →
+                      ∀i. d ≤ i → i ≤ d + e →
+                      ∃∃T. L ⊢ T1 ▶ [i, d + e - i] T &
+                           L ⊢ T ▶ [d, i - d] T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
+[ /2 width=3/
+| #L #K #V #W #i #d #e #Hdi #Hide #HLK #HVW #j #Hdj #Hjde
+  elim (lt_or_ge i j)
+  [ -Hide -Hjde >(plus_minus_m_m j d) in ⊢ (% → ?); // -Hdj /3 width=8/
+  | -Hdi -Hdj
+    >(plus_minus_m_m (d+e) j) in Hide; // -Hjde /3 width=4/
+  ]
+| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
+  elim (IHV12 i ? ?) -IHV12 // #V #HV1 #HV2
+  elim (IHT12 (i + 1) ? ?) -IHT12 /2 width=1/
+  -Hdi -Hide >arith_c1x #T #HT1 #HT2
+  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /3 width=5/
+| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #i #Hdi #Hide
+  elim (IHV12 i ? ?) -IHV12 // elim (IHT12 i ? ?) -IHT12 //
+  -Hdi -Hide /3 width=5/
+]
+qed.
+
+lemma tps_append: ∀K,T1,T2,d,e. K ⊢ T1 ▶ [d, e] T2 →
+                  ∀L. L @@ K ⊢ T1 ▶ [d, e] T2.
+#K #T1 #T2 #d #e #H elim H -K -T1 -T2 -d -e // /2 width=1/
+#K #K0 #V #W #i #d #e #Hdi #Hide #HK0 #HVW #L
+lapply (ldrop_fwd_ldrop2_length … HK0) #H
+@(tps_subst … (L@@K0) … HVW) // (**) (* /3/ does not work *)
+@(ldrop_O1_append_sn_le … HK0) /2 width=2/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact tps_inv_atom1_aux: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ∀I. T1 = ⓪{I} →
+                        T2 = ⓪{I} ∨
+                        ∃∃K,V,i. d ≤ i & i < d + e &
+                                 ⇩[O, i] L ≡ K. ⓓV &
+                                 ⇧[O, i + 1] V ≡ T2 &
+                                 I = LRef i.
+#L #T1 #T2 #d #e * -L -T1 -T2 -d -e
+[ #L #I #d #e #J #H destruct /2 width=1/
+| #L #K #V #T2 #i #d #e #Hdi #Hide #HLK #HVT2 #I #H destruct /3 width=8/
+| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #J #H destruct
+| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #J #H destruct
+]
+qed.
+
+lemma tps_inv_atom1: ∀L,T2,I,d,e. L ⊢ ⓪{I} ▶ [d, e] T2 →
+                     T2 = ⓪{I} ∨
+                     ∃∃K,V,i. d ≤ i & i < d + e &
+                              ⇩[O, i] L ≡ K. ⓓV &
+                              ⇧[O, i + 1] V ≡ T2 &
+                              I = LRef i.
+/2 width=3/ qed-.
+
+
+(* Basic_1: was: subst1_gen_sort *)
+lemma tps_inv_sort1: ∀L,T2,k,d,e. L ⊢ ⋆k ▶ [d, e] T2 → T2 = ⋆k.
+#L #T2 #k #d #e #H
+elim (tps_inv_atom1 … H) -H //
+* #K #V #i #_ #_ #_ #_ #H destruct
+qed-.
+
+(* Basic_1: was: subst1_gen_lref *)
+lemma tps_inv_lref1: ∀L,T2,i,d,e. L ⊢ #i ▶ [d, e] T2 →
+                     T2 = #i ∨
+                     ∃∃K,V. d ≤ i & i < d + e &
+                            ⇩[O, i] L ≡ K. ⓓV &
+                            ⇧[O, i + 1] V ≡ T2.
+#L #T2 #i #d #e #H
+elim (tps_inv_atom1 … H) -H /2 width=1/
+* #K #V #j #Hdj #Hjde #HLK #HVT2 #H destruct /3 width=4/
+qed-.
+
+lemma tps_inv_gref1: ∀L,T2,p,d,e. L ⊢ §p ▶ [d, e] T2 → T2 = §p.
+#L #T2 #p #d #e #H
+elim (tps_inv_atom1 … H) -H //
+* #K #V #i #_ #_ #_ #_ #H destruct
+qed-.
+
+fact tps_inv_bind1_aux: ∀d,e,L,U1,U2. L ⊢ U1 ▶ [d, e] U2 →
+                        ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
+                        ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 &
+                                 L. ⓑ{I} V2 ⊢ T1 ▶ [d + 1, e] T2 &
+                                 U2 = ⓑ{a,I} V2. T2.
+#d #e #L #U1 #U2 * -d -e -L -U1 -U2
+[ #L #k #d #e #a #I #V1 #T1 #H destruct
+| #L #K #V #W #i #d #e #_ #_ #_ #_ #a #I #V1 #T1 #H destruct
+| #L #b #J #V1 #V2 #T1 #T2 #d #e #HV12 #HT12 #a #I #V #T #H destruct /2 width=5/
+| #L #J #V1 #V2 #T1 #T2 #d #e #_ #_ #a #I #V #T #H destruct
+]
+qed.
+
+lemma tps_inv_bind1: ∀d,e,L,a,I,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶ [d, e] U2 →
+                     ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 &
+                              L. ⓑ{I} V2 ⊢ T1 ▶ [d + 1, e] T2 &
+                              U2 = ⓑ{a,I} V2. T2.
+/2 width=3/ qed-.
+
+fact tps_inv_flat1_aux: ∀d,e,L,U1,U2. L ⊢ U1 ▶ [d, e] U2 →
+                        ∀I,V1,T1. U1 = ⓕ{I} V1. T1 →
+                        ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 & L ⊢ T1 ▶ [d, e] T2 &
+                                 U2 =  ⓕ{I} V2. T2.
+#d #e #L #U1 #U2 * -d -e -L -U1 -U2
+[ #L #k #d #e #I #V1 #T1 #H destruct
+| #L #K #V #W #i #d #e #_ #_ #_ #_ #I #V1 #T1 #H destruct
+| #L #a #J #V1 #V2 #T1 #T2 #d #e #_ #_ #I #V #T #H destruct
+| #L #J #V1 #V2 #T1 #T2 #d #e #HV12 #HT12 #I #V #T #H destruct /2 width=5/
+]
+qed.
+
+lemma tps_inv_flat1: ∀d,e,L,I,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶ [d, e] U2 →
+                     ∃∃V2,T2. L ⊢ V1 ▶ [d, e] V2 & L ⊢ T1 ▶ [d, e] T2 &
+                              U2 =  ⓕ{I} V2. T2.
+/2 width=3/ qed-.
+
+fact tps_inv_refl_O2_aux: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → e = 0 → T1 = T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e
+[ //
+| #L #K #V #W #i #d #e #Hdi #Hide #_ #_ #H destruct
+  lapply (le_to_lt_to_lt … Hdi … Hide) -Hdi -Hide <plus_n_O #Hdd
+  elim (lt_refl_false … Hdd)
+| /3 width=1/
+| /3 width=1/
+]
+qed.
+
+lemma tps_inv_refl_O2: ∀L,T1,T2,d. L ⊢ T1 ▶ [d, 0] T2 → T1 = T2.
+/2 width=6/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma tps_fwd_tw: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ♯{T1} ≤ ♯{T2}.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e normalize
+/3 by monotonic_le_plus_l, le_plus/ (**) (* just /3 width=1/ is too slow *)
+qed-.
+
+lemma tps_fwd_shift1: ∀L1,L,T1,T,d,e. L ⊢ L1 @@ T1 ▶[d, e] T →
+                      ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#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 (tps_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 ] // /2 width=3/ (**) (* explicit constructor *)
+]
+qed-.
+
+(* Basic_1: removed theorems 25:
+            subst0_gen_sort subst0_gen_lref subst0_gen_head subst0_gen_lift_lt
+            subst0_gen_lift_false subst0_gen_lift_ge subst0_refl subst0_trans
+            subst0_lift_lt subst0_lift_ge subst0_lift_ge_S subst0_lift_ge_s
+            subst0_subst0 subst0_subst0_back subst0_weight_le subst0_weight_lt
+            subst0_confluence_neq subst0_confluence_eq subst0_tlt_head
+            subst0_confluence_lift subst0_tlt
+            subst1_head subst1_gen_head subst1_lift_S subst1_confluence_lift
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_lift.etc
new file mode 100644 (file)
index 0000000..1d65d8d
--- /dev/null
@@ -0,0 +1,294 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ldrop_ldrop.ma".
+include "basic_2/substitution/tps.ma".
+
+(* PARTIAL SUBSTITUTION ON TERMS ********************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+fact tps_inv_S2_aux: ∀L,T1,T2,d,e1. L ⊢ T1 ▶ [d, e1] T2 → ∀e2. e1 = e2 + 1 →
+                     ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶ [d + 1, e2] T2.
+#L #T1 #T2 #d #e1 #H elim H -L -T1 -T2 -d -e1
+[ //
+| #L #K0 #V0 #W #i #d #e1 #Hdi #Hide1 #HLK0 #HV0 #e2 #He12 #K #V #HLK destruct
+  elim (lt_or_ge i (d+1)) #HiSd
+  [ -Hide1 -HV0
+    lapply (le_to_le_to_eq … Hdi ?) /2 width=1/ #H destruct
+    lapply (ldrop_mono … HLK0 … HLK) #H destruct
+  | -V -Hdi /2 width=4/
+  ]
+| /4 width=3/
+| /3 width=3/
+]
+qed.
+
+lemma tps_inv_S2: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e + 1] T2 →
+                  ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶ [d + 1, e] T2.
+/2 width=3/ qed-.
+
+lemma tps_inv_refl_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶ [d, 1] T2 →
+                        ∀K,V. ⇩[0, d] L ≡ K. ⓛV → T1 = T2.
+#L #T1 #T2 #d #HT12 #K #V #HLK
+lapply (tps_inv_S2 … T1 T2 … 0 … HLK) -K // -HT12 #HT12
+lapply (tps_inv_refl_O2 … HT12) -HT12 //
+qed-.
+
+(* Relocation properties ****************************************************)
+
+(* Basic_1: was: subst1_lift_lt *)
+lemma tps_lift_le: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
+                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
+                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                   dt + et ≤ d →
+                   L ⊢ U1 ▶ [dt, et] U2.
+#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
+[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hdetd
+  lapply (lt_to_le_to_lt … Hidet … Hdetd) -Hdetd #Hid
+  lapply (lift_inv_lref1_lt … H … Hid) -H #H destruct
+  elim (lift_trans_ge … HVW … HWU2 ?) -W // <minus_plus #W #HVW #HWU2
+  elim (ldrop_trans_le … HLK … HKV ?) -K /2 width=2/ #X #HLK #H
+  elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K #Y #_ #HVY
+  >(lift_mono … HVY … HVW) -Y -HVW #H destruct /2 width=4/
+| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
+  @tps_bind [ /2 width=6/ | @IHT12 /2 width=6/ ] (**) (* /3 width=6/ is too slow, arith3 needed to avoid crash *)
+| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
+]
+qed.
+
+lemma tps_lift_be: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
+                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
+                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                   dt ≤ d → d ≤ dt + et →
+                   L ⊢ U1 ▶ [dt, et + e] U2.
+#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
+[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_ #_
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hdtd #_
+  elim (lift_inv_lref1 … H) -H * #Hid #H destruct
+  [ -Hdtd
+    lapply (lt_to_le_to_lt … (dt+et+e) Hidet ?) // -Hidet #Hidete
+    elim (lift_trans_ge … HVW … HWU2 ?) -W // <minus_plus #W #HVW #HWU2
+    elim (ldrop_trans_le … HLK … HKV ?) -K /2 width=2/ #X #HLK #H
+    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K #Y #_ #HVY
+    >(lift_mono … HVY … HVW) -V #H destruct /2 width=4/
+  | -Hdti
+    lapply (transitive_le … Hdtd Hid) -Hdtd #Hdti
+    lapply (lift_trans_be … HVW … HWU2 ? ?) -W // /2 width=1/ >plus_plus_comm_23 #HVU2
+    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=4/
+  ]
+| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdtd #Hddet
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
+  @tps_bind [ /2 width=6/ | @IHT12 [3,4: // | skip |5,6: /2 width=1/ | /2 width=1/ ]
+            ] (**) (* /3 width=6/ is too slow, simplification like tps_lift_le is too slow *)
+| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hdetd
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
+]
+qed.
+
+(* Basic_1: was: subst1_lift_ge *)
+lemma tps_lift_ge: ∀K,T1,T2,dt,et. K ⊢ T1 ▶ [dt, et] T2 →
+                   ∀L,U1,U2,d,e. ⇩[d, e] L ≡ K →
+                   ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                   d ≤ dt →
+                   L ⊢ U1 ▶ [dt + e, et] U2.
+#K #T1 #T2 #dt #et #H elim H -K -T1 -T2 -dt -et
+[ #K #I #dt #et #L #U1 #U2 #d #e #_ #H1 #H2 #_
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #K #KV #V #W #i #dt #et #Hdti #Hidet #HKV #HVW #L #U1 #U2 #d #e #HLK #H #HWU2 #Hddt
+  lapply (transitive_le … Hddt … Hdti) -Hddt #Hid
+  lapply (lift_inv_lref1_ge … H … Hid) -H #H destruct
+  lapply (lift_trans_be … HVW … HWU2 ? ?) -W // /2 width=1/ >plus_plus_comm_23 #HVU2
+  lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=4/
+| #K #a #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hddt
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct
+  @tps_bind [ /2 width=5/ | /3 width=5/ ] (**) (* explicit constructor *)
+| #K #I #V1 #V2 #T1 #T2 #dt #et #_ #_ #IHV12 #IHT12 #L #U1 #U2 #d #e #HLK #H1 #H2 #Hddt
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=5/
+]
+qed.
+
+(* Basic_1: was: subst1_gen_lift_lt *)
+lemma tps_inv_lift1_le: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                        dt + et ≤ d →
+                        ∃∃T2. K ⊢ T1 ▶ [dt, et] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
+[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
+  ]
+| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdetd
+  lapply (lt_to_le_to_lt … Hidet … Hdetd) -Hdetd #Hid
+  lapply (lift_inv_lref2_lt … H … Hid) -H #H destruct
+  elim (ldrop_conf_lt … HLK … HLKV ?) -L // #L #U #HKL #_ #HUV
+  elim (lift_trans_le … HUV … HVW ?) -V // >minus_plus <plus_minus_m_m // -Hid /3 width=4/
+| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1 ?) -V1 // #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1 ?) -IHU12 -HTU1 [3: /2 width=1/ |4: @ldrop_skip // |2: skip ] -HLK -Hdetd (**) (* /3 width=5/ is too slow *)
+  /3 width=5/
+| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1 ?) -V1 //
+  elim (IHU12 … HLK … HTU1 ?) -U1 -HLK // /3 width=5/
+]
+qed.
+
+lemma tps_inv_lift1_be: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                        dt ≤ d → d + e ≤ dt + et →
+                        ∃∃T2. K ⊢ T1 ▶ [dt, et - e] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
+[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
+  ]
+| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdtd #Hdedet
+  lapply (le_fwd_plus_plus_ge … Hdtd … Hdedet) #Heet
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ -Hdtd -Hidet
+    lapply (lt_to_le_to_lt … (dt + (et - e)) Hid ?) [ <le_plus_minus /2 width=1/ ] -Hdedet #Hidete
+    elim (ldrop_conf_lt … HLK … HLKV ?) -L // #L #U #HKL #_ #HUV
+    elim (lift_trans_le … HUV … HVW ?) -V // >minus_plus <plus_minus_m_m // -Hid /3 width=4/
+  | -Hdti -Hdedet
+    lapply (transitive_le … (i - e) Hdtd ?) /2 width=1/ -Hdtd #Hdtie
+    elim (le_inv_plus_l … Hid) #Hdie #Hei
+    lapply (ldrop_conf_ge … HLK … HLKV ?) -L // #HKV
+    elim (lift_split … HVW d (i - e + 1) ? ? ?) -HVW [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
+    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O #H
+    @ex2_intro [3: @H | skip | @tps_subst [3,5,6: // |1,2: skip | >commutative_plus >plus_minus // /2 width=1/ ] ] (**) (* explicit constructor, uses monotonic_lt_minus_l *)
+  ]
+| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdtd #Hdedet
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1 ? ?) -V1 // #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1 ? ?) -U1 [5: @ldrop_skip // |2: skip |3: >plus_plus_comm_23 >(plus_plus_comm_23 dt) /2 width=1/ |4: /2 width=1/ ] (**) (* 29s without the rewrites *)
+  /3 width=5/
+| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdtd #Hdedet
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1 ? ?) -V1 //
+  elim (IHU12 … HLK … HTU1 ? ?) -U1 -HLK // /3 width=5/
+]
+qed.
+
+(* Basic_1: was: subst1_gen_lift_ge *)
+lemma tps_inv_lift1_ge: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                        ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                        d + e ≤ dt →
+                        ∃∃T2. K ⊢ T1 ▶ [dt - e, et] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H elim H -L -U1 -U2 -dt -et
+[ #L * #i #dt #et #K #d #e #_ #T1 #H #_
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
+  ]
+| #L #KV #V #W #i #dt #et #Hdti #Hidet #HLKV #HVW #K #d #e #HLK #T1 #H #Hdedt
+  lapply (transitive_le … Hdedt … Hdti) #Hdei
+  elim (le_inv_plus_l … Hdedt) -Hdedt #_ #Hedt
+  elim (le_inv_plus_l … Hdei) #Hdie #Hei
+  lapply (lift_inv_lref2_ge … H … Hdei) -H #H destruct
+  lapply (ldrop_conf_ge … HLK … HLKV ?) -L // #HKV
+  elim (lift_split … HVW d (i - e + 1) ? ? ?) -HVW [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hdei -Hdie
+  #V0 #HV10 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O #H
+  @ex2_intro [3: @H | skip | @tps_subst [5,6: // |1,2: skip | /2 width=1/ | >plus_minus // /2 width=1/ ] ] (**) (* explicit constructor, uses monotonic_lt_minus_l *)
+| #L #a #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (le_inv_plus_l … Hdetd) #_ #Hedt
+  elim (IHV12 … HLK … HWV1 ?) -V1 // #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1 ?) -U1 [4: @ldrop_skip // |2: skip |3: /2 width=1/ ]
+  <plus_minus // /3 width=5/
+| #L #I #V1 #V2 #U1 #U2 #dt #et #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H #Hdetd
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1 ?) -V1 //
+  elim (IHU12 … HLK … HTU1 ?) -U1 -HLK // /3 width=5/
+]
+qed.
+
+(* Basic_1: was: subst1_gen_lift_eq *)
+lemma tps_inv_lift1_eq: ∀L,U1,U2,d,e.
+                        L ⊢ U1 ▶ [d, e] U2 → ∀T1. ⇧[d, e] T1 ≡ U1 → U1 = U2.
+#L #U1 #U2 #d #e #H elim H -L -U1 -U2 -d -e
+[ //
+| #L #K #V #W #i #d #e #Hdi #Hide #_ #_ #T1 #H
+  elim (lift_inv_lref2 … H) -H * #H
+  [ lapply (le_to_lt_to_lt … Hdi … H) -Hdi -H #H
+    elim (lt_refl_false … H)
+  | lapply (lt_to_le_to_lt … Hide … H) -Hide -H #H
+    elim (lt_refl_false … H)
+  ]
+| #L #a #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #X #HX
+  elim (lift_inv_bind2 … HX) -HX #V #T #HV1 #HT1 #H destruct
+  >IHV12 // >IHT12 //
+| #L #I #V1 #V2 #T1 #T2 #d #e #_ #_ #IHV12 #IHT12 #X #HX
+  elim (lift_inv_flat2 … HX) -HX #V #T #HV1 #HT1 #H destruct
+  >IHV12 // >IHT12 //
+]
+qed.
+(*
+      Theorem subst0_gen_lift_rev_ge: (t1,v,u2,i,h,d:?)
+                                      (subst0 i v t1 (lift h d u2)) ->
+                                      (le (plus d h) i) ->
+                                      (EX u1 | (subst0 (minus i h) v u1 u2) &
+                                               t1 = (lift h d u1)
+                                      ).
+
+
+      Theorem subst0_gen_lift_rev_lelt: (t1,v,u2,i,h,d:?)
+                                        (subst0 i v t1 (lift h d u2)) ->
+                                        (le d i) -> (lt i (plus d h)) ->
+                                        (EX u1 | t1 = (lift (minus (plus d h) (S i)) (S i) u1)).
+*)
+lemma tps_inv_lift1_ge_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                           d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
+                           ∃∃T2. K ⊢ T1 ▶ [d, dt + et - (d + e)] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
+elim (tps_split_up … HU12 (d + e) ? ?) -HU12 // -Hdedet #U #HU1 #HU2
+lapply (tps_weak … HU1 d e ? ?) -HU1 // [ >commutative_plus /2 width=1/ ] -Hddt -Hdtde #HU1
+lapply (tps_inv_lift1_eq … HU1 … HTU1) -HU1 #HU1 destruct
+elim (tps_inv_lift1_ge … HU2 … HLK … HTU1 ?) -U -L // <minus_plus_m_m /2 width=3/
+qed.
+
+lemma tps_inv_lift1_be_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                           dt ≤ d → dt + et ≤ d + e →
+                           ∃∃T2. K ⊢ T1 ▶ [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdetde
+lapply (tps_weak … HU12 dt (d + e - dt) ? ?) -HU12 // /2 width=3/ -Hdetde #HU12
+elim (tps_inv_lift1_be … HU12 … HLK … HTU1 ? ?) -U1 -L // /2 width=3/
+qed.
+
+lemma tps_inv_lift1_le_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶ [dt, et] U2 →
+                           ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                           dt ≤ d → d ≤ dt + et → dt + et ≤ d + e →
+                           ∃∃T2. K ⊢ T1 ▶ [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hdtd #Hddet #Hdetde
+elim (tps_split_up … HU12 d ? ?) -HU12 // #U #HU1 #HU2
+elim (tps_inv_lift1_le … HU1 … HLK … HTU1 ?) -U1 [2: >commutative_plus /2 width=1/ ] -Hdtd #T #HT1 #HTU
+lapply (tps_weak … HU2 d e ? ?) -HU2 // [ >commutative_plus <plus_minus_m_m // ] -Hddet -Hdetde #HU2
+lapply (tps_inv_lift1_eq … HU2 … HTU) -L #H destruct /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_tps.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tps_tps.etc
new file mode 100644 (file)
index 0000000..7e146c2
--- /dev/null
@@ -0,0 +1,132 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/tps_lift.ma".
+
+(* PARALLEL SUBSTITUTION ON TERMS *******************************************)
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: subst1_confluence_eq *)
+theorem tps_conf_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶ [d1, e1] T1 →
+                     ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 →
+                     ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T2 ▶ [d1, e1] T.
+#L #T0 #T1 #d1 #e1 #H elim H -L -T0 -T1 -d1 -e1
+[ /2 width=3/
+| #L #K1 #V1 #T1 #i0 #d1 #e1 #Hd1 #Hde1 #HLK1 #HVT1 #T2 #d2 #e2 #H
+  elim (tps_inv_lref1 … H) -H
+  [ #HX destruct /3 width=6/
+  | -Hd1 -Hde1 * #K2 #V2 #_ #_ #HLK2 #HVT2
+    lapply (ldrop_mono … HLK1 … HLK2) -HLK1 -HLK2 #H destruct
+    >(lift_mono … HVT1 … HVT2) -HVT1 -HVT2 /2 width=3/
+  ]
+| #L #a #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #X #d2 #e2 #HX
+  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V1) ?) -HT02 /2 width=1/ #HT02
+  elim (IHV01 … HV02) -V0 #V #HV1 #HV2
+  elim (IHT01 … HT02) -T0 #T #HT1 #HT2
+  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/
+  lapply (tps_lsubr_trans … HT2 (L. ⓑ{I} V) ?) -HT2 /3 width=5/
+| #L #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #X #d2 #e2 #HX
+  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  elim (IHV01 … HV02) -V0
+  elim (IHT01 … HT02) -T0 /3 width=5/
+]
+qed.
+
+(* Basic_1: was: subst1_confluence_neq *)
+theorem tps_conf_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶ [d1, e1] T1 →
+                      ∀L2,T2,d2,e2. L2 ⊢ T0 ▶ [d2, e2] T2 →
+                      (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
+                      ∃∃T. L2 ⊢ T1 ▶ [d2, e2] T & L1 ⊢ T2 ▶ [d1, e1] T.
+#L1 #T0 #T1 #d1 #e1 #H elim H -L1 -T0 -T1 -d1 -e1
+[ /2 width=3/
+| #L1 #K1 #V1 #T1 #i0 #d1 #e1 #Hd1 #Hde1 #HLK1 #HVT1 #L2 #T2 #d2 #e2 #H1 #H2
+  elim (tps_inv_lref1 … H1) -H1
+  [ #H destruct /3 width=6/
+  | -HLK1 -HVT1 * #K2 #V2 #Hd2 #Hde2 #_ #_ elim H2 -H2 #Hded
+    [ -Hd1 -Hde2
+      lapply (transitive_le … Hded Hd2) -Hded -Hd2 #H
+      lapply (lt_to_le_to_lt … Hde1 H) -Hde1 -H #H
+      elim (lt_refl_false … H)
+    | -Hd2 -Hde1
+      lapply (transitive_le … Hded Hd1) -Hded -Hd1 #H
+      lapply (lt_to_le_to_lt … Hde2 H) -Hde2 -H #H
+      elim (lt_refl_false … H)
+    ]
+  ]
+| #L1 #a #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #L2 #X #d2 #e2 #HX #H
+  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  elim (IHV01 … HV02 H) -V0 #V #HV1 #HV2
+  elim (IHT01 … HT02 ?) -T0
+  [ -H #T #HT1 #HT2
+    lapply (tps_lsubr_trans … HT1 (L2. ⓑ{I} V) ?) -HT1 /2 width=1/
+    lapply (tps_lsubr_trans … HT2 (L1. ⓑ{I} V) ?) -HT2 /2 width=1/ /3 width=5/
+  | -HV1 -HV2 >plus_plus_comm_23 >plus_plus_comm_23 in ⊢ (? ? %); elim H -H #H
+    [ @or_introl | @or_intror ] /2 by monotonic_le_plus_l/ (**) (* /3 / is too slow *)
+  ]
+| #L1 #I #V0 #V1 #T0 #T1 #d1 #e1 #_ #_ #IHV01 #IHT01 #L2 #X #d2 #e2 #HX #H
+  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  elim (IHV01 … HV02 H) -V0
+  elim (IHT01 … HT02 H) -T0 -H /3 width=5/
+]
+qed.
+
+(* Note: the constant 1 comes from tps_subst *)
+(* Basic_1: was: subst1_trans *)
+theorem tps_trans_ge: ∀L,T1,T0,d,e. L ⊢ T1 ▶ [d, e] T0 →
+                      ∀T2. L ⊢ T0 ▶ [d, 1] T2 → 1 ≤ e →
+                      L ⊢ T1 ▶ [d, e] T2.
+#L #T1 #T0 #d #e #H elim H -L -T1 -T0 -d -e
+[ #L #I #d #e #T2 #H #He
+  elim (tps_inv_atom1 … H) -H
+  [ #H destruct //
+  | * #K #V #i #Hd2i #Hide2 #HLK #HVT2 #H destruct
+    lapply (lt_to_le_to_lt … (d + e) Hide2 ?) /2 width=4/
+  ]
+| #L #K #V #V2 #i #d #e #Hdi #Hide #HLK #HVW #T2 #HVT2 #He
+  lapply (tps_weak … HVT2 0 (i +1) ? ?) -HVT2 /2 width=1/ #HVT2
+  <(tps_inv_lift1_eq … HVT2 … HVW) -HVT2 /2 width=4/
+| #L #a #I #V1 #V0 #T1 #T0 #d #e #_ #_ #IHV10 #IHT10 #X #H #He
+  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV02 #HT02 #H destruct
+  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V0) ?) -HT02 /2 width=1/ #HT02
+  lapply (IHT10 … HT02 He) -T0 #HT12
+  lapply (tps_lsubr_trans … HT12 (L. ⓑ{I} V2) ?) -HT12 /2 width=1/ /3 width=1/
+| #L #I #V1 #V0 #T1 #T0 #d #e #_ #_ #IHV10 #IHT10 #X #H #He
+  elim (tps_inv_flat1 … H) -H #V2 #T2 #HV02 #HT02 #H destruct /3 width=1/
+]
+qed.
+
+theorem tps_trans_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶ [d1, e1] T0 →
+                        ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 → d2 + e2 ≤ d1 →
+                        ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T ▶ [d1, e1] T2.
+#L #T1 #T0 #d1 #e1 #H elim H -L -T1 -T0 -d1 -e1
+[ /2 width=3/
+| #L #K #V #W #i1 #d1 #e1 #Hdi1 #Hide1 #HLK #HVW #T2 #d2 #e2 #HWT2 #Hde2d1
+  lapply (transitive_le … Hde2d1 Hdi1) -Hde2d1 #Hde2i1
+  lapply (tps_weak … HWT2 0 (i1 + 1) ? ?) -HWT2 normalize /2 width=1/ -Hde2i1 #HWT2
+  <(tps_inv_lift1_eq … HWT2 … HVW) -HWT2 /3 width=8/
+| #L #a #I #V1 #V0 #T1 #T0 #d1 #e1 #_ #_ #IHV10 #IHT10 #X #d2 #e2 #HX #de2d1
+  elim (tps_inv_bind1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  lapply (tps_lsubr_trans … HT02 (L. ⓑ{I} V0) ?) -HT02 /2 width=1/ #HT02
+  elim (IHV10 … HV02 ?) -IHV10 -HV02 // #V
+  elim (IHT10 … HT02 ?) -T0 /2 width=1/ #T #HT1 #HT2
+  lapply (tps_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/
+  lapply (tps_lsubr_trans … HT2 (L. ⓑ{I} V2) ?) -HT2 /2 width=1/ /3 width=6/
+| #L #I #V1 #V0 #T1 #T0 #d1 #e1 #_ #_ #IHV10 #IHT10 #X #d2 #e2 #HX #de2d1
+  elim (tps_inv_flat1 … HX) -HX #V2 #T2 #HV02 #HT02 #HX destruct
+  elim (IHV10 … HV02 ?) -V0 //
+  elim (IHT10 … HT02 ?) -T0 // /3 width=6/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss.etc
new file mode 100644 (file)
index 0000000..4337188
--- /dev/null
@@ -0,0 +1,188 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 break ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStar $L $T1 $d $e $T2 }.
+
+include "basic_2/substitution/tps.ma".
+
+(* PARTIAL UNFOLD ON TERMS **************************************************)
+
+definition tpss: nat → nat → lenv → relation term ≝
+                 λd,e,L. TC … (tps d e L).
+
+interpretation "partial unfold (term)"
+   'PSubstStar L T1 d e T2 = (tpss d e L T1 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma tpss_ind: ∀d,e,L,T1. ∀R:predicate term. R T1 →
+                (∀T,T2. L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶ [d, e] T2 → R T → R T2) →
+                ∀T2. L ⊢ T1 ▶* [d, e] T2 → R T2.
+#d #e #L #T1 #R #HT1 #IHT1 #T2 #HT12
+@(TC_star_ind … HT1 IHT1 … HT12) //
+qed-.
+
+lemma tpss_ind_dx: ∀d,e,L,T2. ∀R:predicate term. R T2 →
+                   (∀T1,T. L ⊢ T1 ▶ [d, e] T → L ⊢ T ▶* [d, e] T2 → R T → R T1) →
+                   ∀T1. L ⊢ T1 ▶* [d, e] T2 → R T1.
+#d #e #L #T2 #R #HT2 #IHT2 #T1 #HT12
+@(TC_star_ind_dx … HT2 IHT2 … HT12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma tps_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶ [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
+/2 width=1/ qed.
+
+lemma tpss_strap1: ∀L,T1,T,T2,d,e.
+                   L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
+/2 width=3/ qed.
+
+lemma tpss_strap2: ∀L,T1,T,T2,d,e.
+                   L ⊢ T1 ▶ [d, e] T → L ⊢ T ▶* [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
+/2 width=3/ qed.
+
+lemma tpss_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶* [d, e] T2 →
+                        ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶* [d, e] T2.
+/3 width=3/ qed.
+
+lemma tpss_refl: ∀d,e,L,T. L ⊢ T ▶* [d, e] T.
+/2 width=1/ qed.
+
+lemma tpss_bind: ∀L,V1,V2,d,e. L ⊢ V1 ▶* [d, e] V2 →
+                 ∀a,I,T1,T2. L. ⓑ{I} V2 ⊢ T1 ▶* [d + 1, e] T2 →
+                 L ⊢ ⓑ{a,I} V1. T1 ▶* [d, e] ⓑ{a,I} V2. T2.
+#L #V1 #V2 #d #e #HV12 elim HV12 -V2
+[ #V2 #HV12 #a #I #T1 #T2 #HT12 elim HT12 -T2
+  [ /3 width=5/
+  | #T #T2 #_ #HT2 #IHT @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
+  ]
+| #V #V2 #_ #HV12 #IHV #a #I #T1 #T2 #HT12
+  lapply (tpss_lsubr_trans … HT12 (L. ⓑ{I} V) ?) -HT12 /2 width=1/ #HT12
+  lapply (IHV a … HT12) -IHV -HT12 #HT12 @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
+]
+qed.
+
+lemma tpss_flat: ∀L,I,V1,V2,T1,T2,d,e.
+                 L ⊢ V1 ▶* [d, e] V2 → L ⊢ T1 ▶* [d, e] T2 →
+                 L ⊢ ⓕ{I} V1. T1 ▶* [d, e] ⓕ{I} V2. T2.
+#L #I #V1 #V2 #T1 #T2 #d #e #HV12 elim HV12 -V2
+[ #V2 #HV12 #HT12 elim HT12 -T2
+  [ /3 width=1/
+  | #T #T2 #_ #HT2 #IHT @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
+  ]
+| #V #V2 #_ #HV12 #IHV #HT12
+  lapply (IHV … HT12) -IHV -HT12 #HT12 @step /2 width=5/ (**) (* /3 width=5/ is too slow *)
+]
+qed.
+
+lemma tpss_weak: ∀L,T1,T2,d1,e1. L ⊢ T1 ▶* [d1, e1] T2 →
+                 ∀d2,e2. d2 ≤ d1 → d1 + e1 ≤ d2 + e2 →
+                 L ⊢ T1 ▶* [d2, e2] T2.
+#L #T1 #T2 #d1 #e1 #H #d1 #d2 #Hd21 #Hde12 @(tpss_ind … H) -T2
+[ //
+| #T #T2 #_ #HT12 #IHT
+  lapply (tps_weak … HT12 … Hd21 Hde12) -HT12 -Hd21 -Hde12 /2 width=3/
+]
+qed.
+
+lemma tpss_weak_top: ∀L,T1,T2,d,e.
+                     L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶* [d, |L| - d] T2.
+#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2
+[ //
+| #T #T2 #_ #HT12 #IHT
+  lapply (tps_weak_top … HT12) -HT12 /2 width=3/
+]
+qed.
+
+lemma tpss_weak_full: ∀L,T1,T2,d,e.
+                      L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶* [0, |L|] T2.
+#L #T1 #T2 #d #e #HT12
+lapply (tpss_weak … HT12 0 (d + e) ? ?) -HT12 // #HT12
+lapply (tpss_weak_top … HT12) //
+qed.
+
+lemma tpss_append: ∀K,T1,T2,d,e. K ⊢ T1 ▶* [d, e] T2 →
+                   ∀L. L @@ K ⊢ T1 ▶* [d, e] T2.
+#K #T1 #T2 #d #e #H @(tpss_ind … H) -T2 // /3 width=3/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+(* Note: this can be derived from tpss_inv_atom1 *)
+lemma tpss_inv_sort1: ∀L,T2,k,d,e. L ⊢ ⋆k ▶* [d, e] T2 → T2 = ⋆k.
+#L #T2 #k #d #e #H @(tpss_ind … H) -T2
+[ //
+| #T #T2 #_ #HT2 #IHT destruct
+  >(tps_inv_sort1 … HT2) -HT2 //
+]
+qed-.
+
+(* Note: this can be derived from tpss_inv_atom1 *)
+lemma tpss_inv_gref1: ∀L,T2,p,d,e. L ⊢ §p ▶* [d, e] T2 → T2 = §p.
+#L #T2 #p #d #e #H @(tpss_ind … H) -T2
+[ //
+| #T #T2 #_ #HT2 #IHT destruct
+  >(tps_inv_gref1 … HT2) -HT2 //
+]
+qed-.
+
+lemma tpss_inv_bind1: ∀d,e,L,a,I,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶* [d, e] U2 →
+                      ∃∃V2,T2. L ⊢ V1 ▶* [d, e] V2 &
+                               L. ⓑ{I} V2 ⊢ T1 ▶* [d + 1, e] T2 &
+                               U2 = ⓑ{a,I} V2. T2.
+#d #e #L #a #I #V1 #T1 #U2 #H @(tpss_ind … H) -U2
+[ /2 width=5/
+| #U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
+  elim (tps_inv_bind1 … HU2) -HU2 #V2 #T2 #HV2 #HT2 #H
+  lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V2) ?) -HT1 /2 width=1/ /3 width=5/
+]
+qed-.
+
+lemma tpss_inv_flat1: ∀d,e,L,I,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶* [d, e] U2 →
+                      ∃∃V2,T2. L ⊢ V1 ▶* [d, e] V2 & L ⊢ T1 ▶* [d, e] T2 &
+                               U2 =  ⓕ{I} V2. T2.
+#d #e #L #I #V1 #T1 #U2 #H @(tpss_ind … H) -U2
+[ /2 width=5/
+| #U #U2 #_ #HU2 * #V #T #HV1 #HT1 #H destruct
+  elim (tps_inv_flat1 … HU2) -HU2 /3 width=5/
+]
+qed-.
+
+lemma tpss_inv_refl_O2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 0] T2 → T1 = T2.
+#L #T1 #T2 #d #H @(tpss_ind … H) -T2
+[ //
+| #T #T2 #_ #HT2 #IHT <(tps_inv_refl_O2 … HT2) -HT2 //
+]
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma tpss_fwd_tw: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ♯{T1} ≤ ♯{T2}.
+#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT1
+lapply (tps_fwd_tw … HT2) -HT2 #HT2
+@(transitive_le … IHT1) //
+qed-.
+
+lemma tpss_fwd_shift1: ∀L,L1,T1,T,d,e. L ⊢ L1 @@ T1 ▶*[d, e] T →
+                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#L #L1 #T1 #T #d #e #H @(tpss_ind … H) -T
+[ /2 width=4/
+| #T #X #_ #H0 * #L0 #T0 #HL10 #H destruct
+  elim (tps_fwd_shift1 … H0) -H0 #L2 #T2 #HL02 #H destruct /2 width=4/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_alt.etc
new file mode 100644 (file)
index 0000000..f7670ea
--- /dev/null
@@ -0,0 +1,105 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 break ▶ ▶ * [ term 46 d , break term 46 e ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStarAlt $L $T1 $d $e $T2 }.
+
+include "basic_2/unfold/tpss_lift.ma".
+
+(* PARALLEL UNFOLD ON TERMS *************************************************)
+
+(* alternative definition of tpss *)
+inductive tpssa: nat → nat → lenv → relation term ≝
+| tpssa_atom : ∀L,I,d,e. tpssa d e L (⓪{I}) (⓪{I})
+| tpssa_subst: ∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
+               ⇩[0, i] L ≡ K. ⓓV1 → tpssa 0 (d + e - i - 1) K V1 V2 →
+               ⇧[0, i + 1] V2 ≡ W2 → tpssa d e L (#i) W2
+| tpssa_bind : ∀L,a,I,V1,V2,T1,T2,d,e.
+               tpssa d e L V1 V2 → tpssa (d + 1) e (L. ⓑ{I} V2) T1 T2 →
+               tpssa d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| tpssa_flat : ∀L,I,V1,V2,T1,T2,d,e.
+               tpssa d e L V1 V2 → tpssa d e L T1 T2 →
+               tpssa d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+.
+
+interpretation "parallel unfold (term) alternative"
+   'PSubstStarAlt L T1 d e T2 = (tpssa d e L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma tpssa_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ T1 ▶▶* [d, e] T2 →
+                         ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ T1 ▶▶* [d, e] T2.
+#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e
+[ //
+| #L1 #K1 #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /3 width=6/
+| /4 width=1/
+| /3 width=1/
+]
+qed.
+
+lemma tpssa_refl: ∀T,L,d,e. L ⊢ T ▶▶* [d, e] T.
+#T elim T -T //
+#I elim I -I /2 width=1/
+qed.
+
+lemma tpssa_tps_trans: ∀L,T1,T,d,e. L ⊢ T1 ▶▶* [d, e] T →
+                       ∀T2. L ⊢ T ▶ [d, e] T2 → L ⊢ T1 ▶▶* [d, e] T2.
+#L #T1 #T #d #e #H elim H -L -T1 -T -d -e
+[ #L #I #d #e #X #H
+  elim (tps_inv_atom1 … H) -H // * /2 width=6/
+| #L #K #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK #_ #HVW2 #IHV12 #T2 #H
+  lapply (ldrop_fwd_ldrop2 … HLK) #H0LK
+  lapply (tps_weak … H 0 (d+e) ? ?) -H // #H
+  elim (tps_inv_lift1_be … H … H0LK … HVW2 ? ?) -H -H0LK -HVW2 // /3 width=6/
+| #L #a #I #V1 #V #T1 #T #d #e #_ #_ #IHV1 #IHT1 #X #H
+  elim (tps_inv_bind1 … H) -H #V2 #T2 #HV2 #HT2 #H destruct
+  lapply (tps_lsubr_trans … HT2 (L.ⓑ{I}V) ?) -HT2 /2 width=1/ #HT2
+  lapply (IHV1 … HV2) -IHV1 -HV2 #HV12
+  lapply (IHT1 … HT2) -IHT1 -HT2 #HT12
+  lapply (tpssa_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/
+| #L #I #V1 #V #T1 #T #d #e #_ #_ #IHV1 #IHT1 #X #H
+  elim (tps_inv_flat1 … H) -H #V2 #T2 #HV2 #HT2 #H destruct /3 width=1/
+]
+qed.
+
+lemma tpss_tpssa: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 → L ⊢ T1 ▶▶* [d, e] T2.
+#L #T1 #T2 #d #e #H @(tpss_ind … H) -T2 // /2 width=3/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma tpssa_tpss: ∀L,T1,T2,d,e. L ⊢ T1 ▶▶* [d, e] T2 → L ⊢ T1 ▶* [d, e] T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e // /2 width=6/
+qed-.
+
+lemma tpss_ind_alt: ∀R:nat→nat→lenv→relation term.
+                    (∀L,I,d,e. R d e L (⓪{I}) (⓪{I})) →
+                    (∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
+                     ⇩[O, i] L ≡ K.ⓓV1 → K ⊢ V1 ▶* [O, d + e - i - 1] V2 →
+                     ⇧[O, i + 1] V2 ≡ W2 → R O (d+e-i-1) K V1 V2 → R d e L (#i) W2
+                    ) →
+                    (∀L,a,I,V1,V2,T1,T2,d,e. L ⊢ V1 ▶* [d, e] V2 →
+                     L.ⓑ{I}V2 ⊢ T1 ▶* [d + 1, e] T2 → R d e L V1 V2 →
+                     R (d+1) e (L.ⓑ{I}V2) T1 T2 → R d e L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
+                    ) →
+                    (∀L,I,V1,V2,T1,T2,d,e. L ⊢ V1 ▶* [d, e] V2 →
+                     L ⊢ T1 ▶* [d, e] T2 → R d e L V1 V2 →
+                     R d e L T1 T2 → R d e L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
+                    ) →
+                    ∀d,e,L,T1,T2. L ⊢ T1 ▶* [d, e] T2 → R d e L T1 T2.
+#R #H1 #H2 #H3 #H4 #d #e #L #T1 #T2 #H elim (tpss_tpssa … H) -L -T1 -T2 -d -e
+// /3 width=1 by tpssa_tpss/ /3 width=7 by tpssa_tpss/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_lift.etc
new file mode 100644 (file)
index 0000000..a68f86e
--- /dev/null
@@ -0,0 +1,196 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/tps_lift.ma".
+include "basic_2/unfold/tpss.ma".
+
+(* PARTIAL UNFOLD ON TERMS **************************************************)
+
+(* Advanced properties ******************************************************)
+
+lemma tpss_subst: ∀L,K,V,U1,i,d,e.
+                  d ≤ i → i < d + e →
+                  ⇩[0, i] L ≡ K. ⓓV → K ⊢ V ▶* [0, d + e - i - 1] U1 →
+                  ∀U2. ⇧[0, i + 1] U1 ≡ U2 → L ⊢ #i ▶* [d, e] U2.
+#L #K #V #U1 #i #d #e #Hdi #Hide #HLK #H @(tpss_ind … H) -U1
+[ /3 width=4/
+| #U #U1 #_ #HU1 #IHU #U2 #HU12
+  elim (lift_total U 0 (i+1)) #U0 #HU0
+  lapply (IHU … HU0) -IHU #H
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  lapply (tps_lift_ge … HU1 … HLK HU0 HU12 ?) -HU1 -HLK -HU0 -HU12 // normalize #HU02
+  lapply (tps_weak … HU02 d e ? ?) -HU02 [ >minus_plus >commutative_plus /2 width=1/ | /2 width=1/ | /2 width=3/ ]
+]
+qed.
+
+(* Advanced inverion lemmas *************************************************)
+
+lemma tpss_inv_atom1: ∀L,T2,I,d,e. L ⊢ ⓪{I} ▶* [d, e] T2 →
+                      T2 = ⓪{I} ∨
+                      ∃∃K,V1,V2,i. d ≤ i & i < d + e &
+                                   ⇩[O, i] L ≡ K. ⓓV1 &
+                                   K ⊢ V1 ▶* [0, d + e - i - 1] V2 &
+                                   ⇧[O, i + 1] V2 ≡ T2 &
+                                   I = LRef i.
+#L #T2 #I #d #e #H @(tpss_ind … H) -T2
+[ /2 width=1/
+| #T #T2 #_ #HT2 *
+  [ #H destruct
+    elim (tps_inv_atom1 … HT2) -HT2 [ /2 width=1/ | * /3 width=10/ ]
+  | * #K #V1 #V #i #Hdi #Hide #HLK #HV1 #HVT #HI
+    lapply (ldrop_fwd_ldrop2 … HLK) #H
+    elim (tps_inv_lift1_ge_up … HT2 … H … HVT ? ? ?) normalize -HT2 -H -HVT [2,3,4: /2 width=1/ ] #V2 <minus_plus #HV2 #HVT2
+    @or_intror @(ex6_4_intro … Hdi Hide HLK … HVT2 HI) /2 width=3/ (**) (* /4 width=10/ is too slow *)
+  ]
+]
+qed-.
+
+lemma tpss_inv_lref1: ∀L,T2,i,d,e. L ⊢ #i ▶* [d, e] T2 →
+                      T2 = #i ∨
+                      ∃∃K,V1,V2. d ≤ i & i < d + e &
+                                 ⇩[O, i] L ≡ K. ⓓV1 &
+                                 K ⊢ V1 ▶* [0, d + e - i - 1] V2 &
+                                 ⇧[O, i + 1] V2 ≡ T2.
+#L #T2 #i #d #e #H
+elim (tpss_inv_atom1 … H) -H /2 width=1/
+* #K #V1 #V2 #j #Hdj #Hjde #HLK #HV12 #HVT2 #H destruct /3 width=6/
+qed-.
+
+lemma tpss_inv_S2: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e + 1] T2 →
+                   ∀K,V. ⇩[0, d] L ≡ K. ⓛV → L ⊢ T1 ▶* [d + 1, e] T2.
+#L #T1 #T2 #d #e #H #K #V #HLK @(tpss_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT
+lapply (tps_inv_S2 … HT2 … HLK) -HT2 -HLK /2 width=3/
+qed-.
+
+lemma tpss_inv_refl_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 1] T2 →
+                         ∀K,V. ⇩[0, d] L ≡ K. ⓛV → T1 = T2.
+#L #T1 #T2 #d #H #K #V #HLK @(tpss_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT <(tps_inv_refl_SO2 … HT2 … HLK) //
+qed-.
+
+(* Relocation properties ****************************************************)
+
+lemma tpss_lift_le: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
+                    ∀L,U1,d,e. dt + et ≤ d → ⇩[d, e] L ≡ K →
+                    ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
+                    L ⊢ U1 ▶* [dt, et] U2.
+#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hdetd #HLK #HTU1 @(tpss_ind … H) -T2
+[ #U2 #H >(lift_mono … HTU1 … H) -H //
+| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
+  elim (lift_total T d e) #U #HTU
+  lapply (IHT … HTU) -IHT #HU1
+  lapply (tps_lift_le … HT2 … HLK HTU HTU2 ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
+]
+qed.
+
+lemma tpss_lift_be: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
+                    ∀L,U1,d,e. dt ≤ d → d ≤ dt + et →
+                    ⇩[d, e] L ≡ K → ⇧[d, e] T1 ≡ U1 →
+                    ∀U2. ⇧[d, e] T2 ≡ U2 → L ⊢ U1 ▶* [dt, et + e] U2.
+#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hdtd #Hddet #HLK #HTU1 @(tpss_ind … H) -T2
+[ #U2 #H >(lift_mono … HTU1 … H) -H //
+| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
+  elim (lift_total T d e) #U #HTU
+  lapply (IHT … HTU) -IHT #HU1
+  lapply (tps_lift_be … HT2 … HLK HTU HTU2 ? ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
+]
+qed.
+
+lemma tpss_lift_ge: ∀K,T1,T2,dt,et. K ⊢ T1 ▶* [dt, et] T2 →
+                    ∀L,U1,d,e. d ≤ dt → ⇩[d, e] L ≡ K →
+                    ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
+                    L ⊢ U1 ▶* [dt + e, et] U2.
+#K #T1 #T2 #dt #et #H #L #U1 #d #e #Hddt #HLK #HTU1 @(tpss_ind … H) -T2
+[ #U2 #H >(lift_mono … HTU1 … H) -H //
+| -HTU1 #T #T2 #_ #HT2 #IHT #U2 #HTU2
+  elim (lift_total T d e) #U #HTU
+  lapply (IHT … HTU) -IHT #HU1
+  lapply (tps_lift_ge … HT2 … HLK HTU HTU2 ?) -HT2 -HLK -HTU -HTU2 // /2 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_le: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         dt + et ≤ d →
+                         ∃∃T2. K ⊢ T1 ▶* [dt, et] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdetd @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_le … HU2 … HLK … HTU ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_be: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         dt ≤ d → d + e ≤ dt + et →
+                         ∃∃T2. K ⊢ T1 ▶* [dt, et - e] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdedet @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_be … HU2 … HLK … HTU ? ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_ge: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         d + e ≤ dt →
+                         ∃∃T2. K ⊢ T1 ▶* [dt - e, et] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdedt @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_ge … HU2 … HLK … HTU ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_eq: ∀L,U1,U2,d,e.
+                         L ⊢ U1 ▶* [d, e] U2 → ∀T1. ⇧[d, e] T1 ≡ U1 → U1 = U2.
+#L #U1 #U2 #d #e #H #T1 #HTU1 @(tpss_ind … H) -U2 //
+#U #U2 #_ #HU2 #IHU destruct
+<(tps_inv_lift1_eq … HU2 … HTU1) -HU2 -HTU1 //
+qed.
+
+lemma tpss_inv_lift1_ge_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                            d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
+                            ∃∃T2. K ⊢ T1 ▶* [d, dt + et - (d + e)] T2 &
+                                 ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_ge_up … HU2 … HLK … HTU ? ? ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_be_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                            dt ≤ d → dt + et ≤ d + e →
+                            ∃∃T2. K ⊢ T1 ▶* [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hdetde @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_be_up … HU2 … HLK … HTU ? ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
+
+lemma tpss_inv_lift1_le_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                            ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                            dt ≤ d → d ≤ dt + et → dt + et ≤ d + e →
+                            ∃∃T2. K ⊢ T1 ▶* [dt, d - dt] T2 & ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #H #K #d #e #HLK #T1 #HTU1 #Hdtd #Hddet #Hdetde @(tpss_ind … H) -U2
+[ /2 width=3/
+| -HTU1 #U #U2 #_ #HU2 * #T #HT1 #HTU
+  elim (tps_inv_lift1_le_up … HU2 … HLK … HTU ? ? ?) -HU2 -HLK -HTU // /3 width=3/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpr/tpss_tpss.etc
new file mode 100644 (file)
index 0000000..d124bb3
--- /dev/null
@@ -0,0 +1,96 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/tps_tps.ma".
+include "basic_2/unfold/tpss_lift.ma".
+
+(* PARTIAL UNFOLD ON TERMS **************************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma tpss_inv_SO2: ∀L,T1,T2,d. L ⊢ T1 ▶* [d, 1] T2 → L ⊢ T1 ▶ [d, 1] T2.
+#L #T1 #T2 #d #H @(tpss_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT1
+lapply (tps_trans_ge … IHT1 … HT2 ?) //
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma tpss_strip_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶* [d1, e1] T1 →
+                     ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 →
+                     ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T2 ▶* [d1, e1] T.
+/3 width=3/ qed.
+
+lemma tpss_strip_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶* [d1, e1] T1 →
+                      ∀L2,T2,d2,e2. L2 ⊢ T0 ▶ [d2, e2] T2 →
+                      (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
+                      ∃∃T. L2 ⊢ T1 ▶ [d2, e2] T & L1 ⊢ T2 ▶* [d1, e1] T.
+/3 width=3/ qed.
+
+lemma tpss_strap1_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶* [d1, e1] T0 →
+                        ∀T2,d2,e2. L ⊢ T0 ▶ [d2, e2] T2 → d2 + e2 ≤ d1 →
+                        ∃∃T. L ⊢ T1 ▶ [d2, e2] T & L ⊢ T ▶* [d1, e1] T2.
+/3 width=3/ qed.
+
+lemma tpss_strap2_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶ [d1, e1] T0 →
+                        ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 → d2 + e2 ≤ d1 →
+                        ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T ▶ [d1, e1] T2.
+/3 width=3/ qed.
+
+lemma tpss_split_up: ∀L,T1,T2,d,e. L ⊢ T1 ▶* [d, e] T2 →
+                     ∀i. d ≤ i → i ≤ d + e →
+                     ∃∃T. L ⊢ T1 ▶* [d, i - d] T & L ⊢ T ▶* [i, d + e - i] T2.
+#L #T1 #T2 #d #e #H #i #Hdi #Hide @(tpss_ind … H) -T2
+[ /2 width=3/
+| #T #T2 #_ #HT12 * #T3 #HT13 #HT3
+  elim (tps_split_up … HT12 … Hdi Hide) -HT12 -Hide #T0 #HT0 #HT02
+  elim (tpss_strap1_down … HT3 … HT0 ?) -T [2: >commutative_plus /2 width=1/ ]
+  /3 width=7 by ex2_intro, step/ (**) (* just /3 width=7/ is too slow *)
+]
+qed.
+
+lemma tpss_inv_lift1_up: ∀L,U1,U2,dt,et. L ⊢ U1 ▶* [dt, et] U2 →
+                         ∀K,d,e. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 →
+                         d ≤ dt → dt ≤ d + e → d + e ≤ dt + et →
+                         ∃∃T2. K ⊢ T1 ▶* [d, dt + et - (d + e)] T2 &
+                               ⇧[d, e] T2 ≡ U2.
+#L #U1 #U2 #dt #et #HU12 #K #d #e #HLK #T1 #HTU1 #Hddt #Hdtde #Hdedet
+elim (tpss_split_up … HU12 (d + e) ? ?) -HU12 // -Hdedet #U #HU1 #HU2
+lapply (tpss_weak … HU1 d e ? ?) -HU1 // [ >commutative_plus /2 width=1/ ] -Hddt -Hdtde #HU1
+lapply (tpss_inv_lift1_eq … HU1 … HTU1) -HU1 #HU1 destruct
+elim (tpss_inv_lift1_ge … HU2 … HLK … HTU1 ?) -HU2 -HLK -HTU1 // <minus_plus_m_m /2 width=3/
+qed.
+
+(* Main properties **********************************************************)
+
+theorem tpss_conf_eq: ∀L,T0,T1,d1,e1. L ⊢ T0 ▶* [d1, e1] T1 →
+                      ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 →
+                      ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T2 ▶* [d1, e1] T.
+/3 width=3/ qed.
+
+theorem tpss_conf_neq: ∀L1,T0,T1,d1,e1. L1 ⊢ T0 ▶* [d1, e1] T1 →
+                       ∀L2,T2,d2,e2. L2 ⊢ T0 ▶* [d2, e2] T2 →
+                       (d1 + e1 ≤ d2 ∨ d2 + e2 ≤ d1) →
+                       ∃∃T. L2 ⊢ T1 ▶* [d2, e2] T & L1 ⊢ T2 ▶* [d1, e1] T.
+/3 width=3/ qed.
+
+theorem tpss_trans_eq: ∀L,T1,T,T2,d,e.
+                       L ⊢ T1 ▶* [d, e] T → L ⊢ T ▶* [d, e] T2 →
+                       L ⊢ T1 ▶* [d, e] T2.
+/2 width=3/ qed.
+
+theorem tpss_trans_down: ∀L,T1,T0,d1,e1. L ⊢ T1 ▶* [d1, e1] T0 →
+                         ∀T2,d2,e2. L ⊢ T0 ▶* [d2, e2] T2 → d2 + e2 ≤ d1 →
+                         ∃∃T. L ⊢ T1 ▶* [d2, e2] T & L ⊢ T ▶* [d1, e1] T2.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys.etc
new file mode 100644 (file)
index 0000000..b3b5bc6
--- /dev/null
@@ -0,0 +1,177 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/psubststar_4.ma".
+include "basic_2/grammar/genv.ma".
+include "basic_2/substitution/lsuby.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
+
+(* avtivate genv *)
+inductive cpys: relation4 genv lenv term term ≝
+| cpys_atom : ∀I,G,L. cpys G L (⓪{I}) (⓪{I})
+| cpys_delta: ∀I,G,L,K,V,V2,W2,i.
+              ⇩[i] L ≡ K.ⓑ{I}V → cpys G K V V2 →
+              ⇧[0, i + 1] V2 ≡ W2 → cpys G L (#i) W2
+| cpys_bind : ∀a,I,G,L,V1,V2,T1,T2.
+              cpys G L V1 V2 → cpys G (L.ⓑ{I}V1) T1 T2 →
+              cpys G L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
+| cpys_flat : ∀I,G,L,V1,V2,T1,T2.
+              cpys G L V1 V2 → cpys G L T1 T2 →
+              cpys G L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
+.
+
+interpretation
+   "context-sensitive extended multiple substitution (term)"
+   'PSubstStar G L T1 T2 = (cpys G L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma lsuby_cpys_trans: ∀G. lsub_trans … (cpys G) lsuby.
+#G #L1 #T1 #T2 #H elim H -G -L1 -T1 -T2
+[ //
+| #I #G #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (lsuby_ldrop_trans … HL12 … HLK1) -HL12 -HLK1 *
+  /3 width=7 by cpys_delta/
+| /4 width=1 by lsuby_pair, cpys_bind/
+| /3 width=1 by cpys_flat/
+]
+qed-.
+
+(* Note: this is "∀L. reflexive … (cpys L)" *)
+lemma cpys_refl: ∀G,T,L. ⦃G, L⦄ ⊢ T ▶* T.
+#G #T elim T -T // * /2 width=1 by cpys_bind, cpys_flat/
+qed.
+
+lemma cpys_pair_sn: ∀I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ▶* V2 →
+                    ∀T. ⦃G, L⦄ ⊢ ②{I}V1.T ▶* ②{I}V2.T.
+* /2 width=1 by cpys_bind, cpys_flat/
+qed.
+
+lemma cpys_bind_ext: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ▶* V2 →
+                     ∀J,T1,T2. ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 →
+                     ∀a,I. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* ⓑ{a,I}V2.T2.
+/4 width=4 by lsuby_cpys_trans, cpys_bind, lsuby_pair/ qed.
+
+lemma cpys_delift: ∀I,G,K,V,T1,L,d. ⇩[d] L ≡ (K.ⓑ{I}V) →
+                   ∃∃T2,T.  ⦃G, L⦄ ⊢ T1 ▶* T2 & ⇧[d, 1] T ≡ T2.
+#I #G #K #V #T1 elim T1 -T1
+[ * /2 width=4 by cpys_atom, lift_sort, lift_gref, ex2_2_intro/
+  #i #L #d elim (lt_or_eq_or_gt i d) #Hid [1,3: /3 width=4 by cpys_atom, lift_lref_ge_minus, lift_lref_lt, ex2_2_intro/ ]
+  destruct
+  elim (lift_total V 0 (i+1)) #W #HVW
+  elim (lift_split … HVW i i) /3 width=7 by cpys_delta, ex2_2_intro/
+| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
+  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
+  [ elim (IHU1 (L. ⓑ{I}W1) (d+1)) -IHU1 /3 width=9 by cpys_bind, ldrop_drop, lift_bind, ex2_2_intro/
+  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8 by cpys_flat, lift_flat, ex2_2_intro/
+  ]
+]
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact cpys_inv_atom1_aux: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶* T2 → ∀J. T1 = ⓪{J} →
+                         T2 = ⓪{J} ∨
+                         ∃∃I,K,V,V2,i. ⇩[i] L ≡ K.ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
+                                       ⇧[O, i + 1] V2 ≡ T2 & J = LRef i.
+#G #L #T1 #T2 * -L -T1 -T2
+[ #I #G #L #J #H destruct /2 width=1 by or_introl/
+| #I #G #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #J #H destruct /3 width=9 by ex4_5_intro, or_intror/
+| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+]
+qed-.
+
+lemma cpys_inv_atom1: ∀J,G,L,T2. ⦃G, L⦄ ⊢ ⓪{J} ▶* T2 →
+                      T2 = ⓪{J} ∨
+                      ∃∃I,K,V,V2,i. ⇩[i] L ≡ K.ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
+                                    ⇧[O, i + 1] V2 ≡ T2 & J = LRef i.
+/2 width=3 by cpys_inv_atom1_aux/ qed-.
+
+lemma cpys_inv_sort1: ∀G,L,T2,k. ⦃G, L⦄ ⊢ ⋆k ▶* T2 → T2 = ⋆k.
+#G #L #T2 #k #H elim (cpys_inv_atom1 … H) -H // *
+#I #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+lemma cpys_inv_lref1: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ▶* T2 →
+                      T2 = #i ∨
+                      ∃∃I,K,V,V2. ⇩[i] L ≡ K. ⓑ{I}V & ⦃G, K⦄ ⊢ V ▶* V2 &
+                                  ⇧[O, i + 1] V2 ≡ T2.
+#G #L #T2 #i #H elim (cpys_inv_atom1 … H) -H /2 width=1 by or_introl/ *
+#I #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=7 by ex3_4_intro, or_intror/
+qed-.
+
+lemma cpys_inv_lref1_ge: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ▶* T2 → |L| ≤ i → T2 = #i.
+#G #L #T2 #i #H elim (cpys_inv_lref1 … H) -H // *
+#I #K #V1 #V2 #HLK #_ #_ #HL -V2 lapply (ldrop_fwd_length_lt2 … HLK) -K -I -V1
+#H elim (lt_refl_false i) /2 width=3 by lt_to_le_to_lt/
+qed-.
+
+lemma cpys_inv_gref1: ∀G,L,T2,p.  ⦃G, L⦄ ⊢ §p ▶* T2 → T2 = §p.
+#G #L #T2 #p #H elim (cpys_inv_atom1 … H) -H // *
+#I #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+fact cpys_inv_bind1_aux: ∀G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ▶* U2 →
+                         ∀a,J,V1,T1. U1 = ⓑ{a,J}V1.T1 →
+                         ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 &
+                                  U2 = ⓑ{a,J}V2.T2.
+#G #L #U1 #U2 * -L -U1 -U2
+[ #I #G #L #b #J #W #U1 #H destruct
+| #I #G #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W #U1 #H destruct
+| #a #I #G #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W #U1 #H destruct /2 width=5 by ex3_2_intro/
+| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W #U1 #H destruct
+]
+qed-.
+
+lemma cpys_inv_bind1: ∀a,I,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* U2 →
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ▶* T2 &
+                               U2 = ⓑ{a,I}V2.T2.
+/2 width=3 by cpys_inv_bind1_aux/ qed-.
+
+lemma cpys_inv_bind1_ext: ∀a,I,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* U2 → ∀J.
+                          ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L.ⓑ{J}V1⦄ ⊢ T1 ▶* T2 &
+                                   U2 = ⓑ{a,I}V2.T2.
+#a #I #G #L #V1 #T1 #U2 #H #J elim (cpys_inv_bind1 … H) -H
+#V2 #T2 #HV12 #HT12 #H destruct
+/4 width=5 by lsuby_cpys_trans, lsuby_pair, ex3_2_intro/
+qed-.
+
+fact cpys_inv_flat1_aux: ∀G,L,U,U2. ⦃G, L⦄ ⊢ U ▶* U2 →
+                         ∀J,V1,U1. U = ⓕ{J}V1.U1 →
+                         ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L⦄ ⊢ U1 ▶* T2 &
+                                  U2 = ⓕ{J}V2.T2.
+#G #L #U #U2 * -L -U -U2
+[ #I #G #L #J #W #U1 #H destruct
+| #I #G #L #K #V #V2 #W2 #i #_ #_ #_ #J #W #U1 #H destruct
+| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #J #W #U1 #H destruct
+| #I #G #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W #U1 #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+(* Note: lemma 1250 *)
+lemma cpys_inv_flat1: ∀I,G,L,V1,U1,U2. ⦃G, L⦄ ⊢ ⓕ{I}V1.U1 ▶* U2 →
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ▶* V2 & ⦃G, L⦄ ⊢ U1 ▶* T2 &
+                               U2 = ⓕ{I}V2.T2.
+/2 width=3 by cpys_inv_flat1_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma cpys_fwd_bind1: ∀a,I,G,L,V1,T1,T. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ▶* T → ∀b,J.
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ ⓑ{b,J}V1.T1 ▶* ⓑ{b,J}V2.T2 &
+                               T = ⓑ{a,I}V2.T2.
+#a #I #G #L #V1 #T1 #T #H #b #J elim (cpys_inv_bind1_ext … H J) -H
+#V2 #T2 #HV12 #HT12 #H destruct /3 width=4 by cpys_bind, ex2_2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_cpys.etc
new file mode 100644 (file)
index 0000000..7f423f6
--- /dev/null
@@ -0,0 +1,72 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lpx_sn.ma".
+include "basic_2/substitution/fqup.ma".
+include "basic_2/substitution/lpys_ldrop.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
+
+(* Main properties **********************************************************)
+
+theorem cpys_antisym: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ▶* T2 → ⦃G, L⦄ ⊢ T2 ▶* T1 → T1 = T2.
+#G #L #T1 #T2 #H elim H -G -L -T1 -T2 //
+[ #I #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #_ #HW2 lapply (ldrop_fwd_drop2 … HLK) -I -V1
+  #HLK elim (cpys_inv_lift1 … HW2 … HLK … HVW2) -L -HVW2
+  #X #H #_ elim (lift_inv_lref2_be … H) -G -K -V2 -W2 -X //
+| #a #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #H elim (cpys_inv_bind1 … H) -H
+  #V #T #HV2 #HT2 #H destruct
+  lapply (IHV12 HV2) #H destruct -IHV12 -HV2 /3 width=1 by eq_f2/
+| #I #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #H elim (cpys_inv_flat1 … H) -H
+  #V #T #HV2 #HT2 #H destruct /3 width=1 by eq_f2/
+]
+qed-.
+
+theorem cpys_trans_lpys: ∀G. lpx_sn_transitive (cpys G) (cpys G).
+#G0 #L0 #T0 @(fqup_wf_ind_eq … G0 L0 T0) -G0 -L0 -T0 #G0 #L0 #T0 #IH #G1 #L1 * [|*]
+[ #I #HG #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
+  elim (cpys_inv_atom1 … H1) -H1
+  [ #H destruct
+    elim (cpys_inv_atom1 … HT2) -HT2
+    [ #H destruct //
+    | * #I2 #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
+      elim (lpys_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
+      elim (lpys_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
+      lapply (fqup_lref … G1 … HLK1) /3 width=10 by cpys_delta/
+    ]
+  | * #I1 #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
+    elim (lpys_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+    elim (lpys_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
+    elim (cpys_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
+    lapply (fqup_lref … G1 … HLK1) /3 width=10 by cpys_delta/
+  ]
+| #a #I #V1 #T1 #HG #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpys_inv_bind1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
+  elim (cpys_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+  /4 width=5 by cpys_bind, lpys_pair/
+| #I #V1 #T1 #HG #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpys_inv_flat1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
+  elim (cpys_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct
+  /3 width=5 by cpys_flat/
+]
+qed-.
+
+theorem cpys_trans: ∀G,L. Transitive … (cpys G L).
+/2 width=5 by cpys_trans_lpys/ qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lpys_cpys_trans: ∀G. lsub_trans … (cpys G) (lpys G).
+/2 width=5 by cpys_trans_lpys/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/cpys_lift.etc
new file mode 100644 (file)
index 0000000..f435a86
--- /dev/null
@@ -0,0 +1,176 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fqus_alt.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED MULTIPLE SUBSTITUTION FOR TERMS ***************)
+
+(* Relocation properties ****************************************************)
+
+lemma cpys_lift: ∀G. l_liftable (cpys G).
+#G #K #T1 #T2 #H elim H -G -K -T1 -T2
+[ #I #G #K #L #s #d #e #_ #U1 #H1 #U2 #H2
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #I #G #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #s #d #e #HLK #U1 #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
+    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2 by lt_to_le/ #X #HLK #H
+    elim (ldrop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K #Y #HKV #HVY #H destruct /3 width=10 by cpys_delta/
+  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 /2 width=1 by le_S/ >plus_plus_comm_23 #HVU2
+    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K /3 width=7 by cpys_delta, ldrop_inv_gen/
+  ]
+| #a #I #G #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #s #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=6 by cpys_bind, ldrop_skip/
+| #I #G #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #s #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6 by cpys_flat/
+]
+qed.
+
+lemma cpys_inv_lift1: ∀G. l_deliftable_sn (cpys G).
+#G #L #U1 #U2 #H elim H -G -L -U1 -U2
+[ * #G #L #i #K #s #d #e #_ #T1 #H
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3 by cpys_atom, lift_sort, ex2_intro/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3 by cpys_atom, lift_lref_ge_minus, lift_lref_lt, ex2_intro/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3 by cpys_atom, lift_gref, ex2_intro/
+  ]
+| #I #G #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #s #d #e #HLK #T1 #H
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
+    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
+    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m /3 width=9 by cpys_delta, ex2_intro/
+  | elim (le_inv_plus_l … Hid) #Hdie #Hei
+    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
+    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 /3 width=1 by le_S, le_S_S/ -Hid -Hdie
+    #V1 #HV1 >plus_minus // <minus_minus /2 width=1 by le_S/ <minus_n_n <plus_n_O /3 width=9 by cpys_delta, ex2_intro/
+  ]
+| #a #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=6 by cpys_bind, ldrop_skip, lift_bind, ex2_intro/
+| #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -V1
+  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5 by cpys_flat, lift_flat, ex2_intro/
+]
+qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma fqu_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
+                      ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
+                      ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2 
+/3 width=3 by fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, cpys_pair_sn, cpys_bind, cpys_flat, ex2_intro/
+[ #I #G #L #V2 #U2 #HVU2
+  elim (lift_total U2 0 1)
+  /4 width=7 by fqu_drop, cpys_delta, ldrop_pair, ldrop_drop, ex2_intro/
+| #G #L #K #T1 #U1 #e #HLK1 #HTU1 #T2 #HTU2
+  elim (lift_total T2 0 (e+1))
+  /3 width=11 by cpys_lift, fqu_drop, ex2_intro/
+]
+qed-.
+
+lemma fquq_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
+                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
+                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐⸮ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (fqu_cpys_trans … HT12 … HTU2) /3 width=3 by fqu_fquq, ex2_intro/
+| * #H1 #H2 #H3 destruct /2 width=3 by ex2_intro/
+]
+qed-.
+
+lemma fqup_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
+                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
+                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐+ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
+[ #G2 #L2 #T2 #H12 #U2 #HTU2 elim (fqu_cpys_trans … H12 … HTU2) -T2
+  /3 width=3 by fqu_fqup, ex2_intro/
+| #G #G2 #L #L2 #T #T2 #_ #HT2 #IHT1 #U2 #HTU2
+  elim (fqu_cpys_trans … HT2 … HTU2) -T2 #T2 #HT2 #HTU2
+  elim (IHT1 … HT2) -T /3 width=7 by fqup_strap1, ex2_intro/
+]
+qed-.
+
+lemma fqus_cpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
+                       ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 →
+                       ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & ⦃G1, L1, U1⦄ ⊐* ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fqus_inv_gen … H) -H
+[ #HT12 elim (fqup_cpys_trans … HT12 … HTU2) /3 width=3 by fqup_fqus, ex2_intro/
+| * #H1 #H2 #H3 destruct /2 width=3 by ex2_intro/
+]
+qed-.
+
+lemma fqu_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
+                          ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
+                          ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+[ #I #G #L #V1 #V2 #HV12 #_ elim (lift_total V2 0 1)
+  #U2 #HVU2 @(ex3_intro … U2)
+  [1,3: /3 width=7 by fqu_drop, cpys_delta, ldrop_pair, ldrop_drop/
+  | #H destruct /2 width=7 by lift_inv_lref2_be/
+  ]
+| #I #G #L #V1 #T #V2 #HV12 #H @(ex3_intro … (②{I}V2.T))
+  [1,3: /2 width=4 by fqu_pair_sn, cpys_pair_sn/
+  | #H0 destruct /2 width=1 by/
+  ]
+| #a #I #G #L #V #T1 #T2 #HT12 #H @(ex3_intro … (ⓑ{a,I}V.T2))
+  [1,3: /2 width=4 by fqu_bind_dx, cpys_bind/
+  | #H0 destruct /2 width=1 by/
+  ]
+| #I #G #L #V #T1 #T2 #HT12 #H @(ex3_intro … (ⓕ{I}V.T2))
+  [1,3: /2 width=4 by fqu_flat_dx, cpys_flat/
+  | #H0 destruct /2 width=1 by/
+  ]
+| #G #L #K #T1 #U1 #e #HLK #HTU1 #T2 #HT12 #H elim (lift_total T2 0 (e+1))
+  #U2 #HTU2 @(ex3_intro … U2)
+  [1,3: /2 width=10 by cpys_lift, fqu_drop/
+  | #H0 destruct /3 width=5 by lift_inj/
+]
+qed-.
+
+lemma fquq_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
+                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
+                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐⸮ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H12 #U2 #HTU2 #H elim (fquq_inv_gen … H12) -H12
+[ #H12 elim (fqu_cpys_trans_neq … H12 … HTU2 H) -T2
+  /3 width=4 by fqu_fquq, ex3_intro/
+| * #HG #HL #HT destruct /3 width=4 by ex3_intro/
+]
+qed-.
+
+lemma fqup_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ →
+                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
+                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐+ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind_dx … H) -G1 -L1 -T1
+[ #G1 #L1 #T1 #H12 #U2 #HTU2 #H elim (fqu_cpys_trans_neq … H12 … HTU2 H) -T2
+  /3 width=4 by fqu_fqup, ex3_intro/
+| #G #G1 #L #L1 #T #T1 #H1 #_ #IH12 #U2 #HTU2 #H elim (IH12 … HTU2 H) -T2
+  #U1 #HTU1 #H #H12 elim (fqu_cpys_trans_neq … H1 … HTU1 H) -T1
+  /3 width=8 by fqup_strap2, ex3_intro/
+]
+qed-.
+
+lemma fqus_cpys_trans_neq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐* ⦃G2, L2, T2⦄ →
+                           ∀U2. ⦃G2, L2⦄ ⊢ T2 ▶* U2 → (T2 = U2 → ⊥) →
+                           ∃∃U1. ⦃G1, L1⦄ ⊢ T1 ▶* U1 & T1 = U1 → ⊥ & ⦃G1, L1, U1⦄ ⊐* ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H12 #U2 #HTU2 #H elim (fqus_inv_gen … H12) -H12
+[ #H12 elim (fqup_cpys_trans_neq … H12 … HTU2 H) -T2
+  /3 width=4 by fqup_fqus, ex3_intro/
+| * #HG #HL #HT destruct /3 width=4 by ex3_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys.etc
new file mode 100644 (file)
index 0000000..0a9563a
--- /dev/null
@@ -0,0 +1,61 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/psubstsnstar_3.ma".
+include "basic_2/relocation/lpx_sn.ma".
+include "basic_2/substitution/cpys.ma".
+
+(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
+
+definition lpys: relation3 genv lenv lenv ≝ λG. lpx_sn (cpys G).
+
+interpretation
+   "extended multiple substitution (local environment, sn variant)"
+   'PSubstSnStar G L1 L2 = (lpys G L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lpys_inv_atom1: ∀G,L2. ⦃G, ⋆⦄ ⊢ ▶* L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+lemma lpys_inv_pair1: ∀I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ▶* L2 →
+                      ∃∃K2,V2. ⦃G, K1⦄ ⊢ ▶* K2 & ⦃G, K1⦄ ⊢ V1 ▶* V2 &
+                               L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+lemma lpys_inv_atom2: ∀G,L1. ⦃G, L1⦄ ⊢ ▶* ⋆ → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+lemma lpys_inv_pair2: ∀I,G,L1,K2,V2. ⦃G, L1⦄ ⊢ ▶* K2.ⓑ{I}V2 →
+                      ∃∃K1,V1. ⦃G, K1⦄ ⊢ ▶* K2 & ⦃G, K1⦄ ⊢ V1 ▶* V2 &
+                               L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+lemma lpys_inv_pair: ∀I1,I2,G,L1,L2,V1,V2. ⦃G, L1.ⓑ{I1}V1⦄ ⊢ ▶* L2.ⓑ{I2}V2 →
+                     ∧∧ ⦃G, L1⦄ ⊢ ▶* L2 & ⦃G, L1⦄ ⊢ V1 ▶* V2 & I1 = I2.
+/2 width=1 by lpx_sn_inv_pair/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpys_refl: ∀G,L. ⦃G, L⦄ ⊢ ▶* L.
+/2 width=1 by lpx_sn_refl/ qed.
+
+lemma lpys_pair: ∀I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ▶* K2 → ⦃G, K1⦄ ⊢ V1 ▶* V2 →
+                 ⦃G, K1.ⓑ{I}V1⦄ ⊢ ▶* K2.ⓑ{I}V2.
+/2 width=1 by lpx_sn_pair/ qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpys_fwd_length: ∀G,L1,L2. ⦃G, L1⦄ ⊢ ▶* L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_ldrop.etc
new file mode 100644 (file)
index 0000000..db5037c
--- /dev/null
@@ -0,0 +1,78 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cpys_lift.ma".
+include "basic_2/substitution/lpys.ma".
+
+(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
+
+(* Properies on local environment slicing ***********************************)
+
+lemma lpys_ldrop_conf: ∀G. dropable_sn (lpys G).
+/3 width=6 by lpx_sn_deliftable_dropable, cpys_inv_lift1/ qed-.
+
+lemma ldrop_lpys_trans: ∀G. dedropable_sn (lpys G).
+/3 width=10 by lpx_sn_liftable_dedropable, cpys_lift/ qed-.
+
+lemma lpys_ldrop_trans_O1: ∀G. dropable_dx (lpys G).
+/2 width=3 by lpx_sn_dropable/ qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma fqu_lpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
+                      ∀K2. ⦃G2, L2⦄ ⊢ ▶* K2 →
+                      ∃∃K1,T. ⦃G1, L1⦄ ⊢ ▶* K1 & ⦃G1, L1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐ ⦃G2, K2, T2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+/3 width=5 by fqu_lref_O, fqu_pair_sn, fqu_flat_dx, lpys_pair, ex3_2_intro/
+[ #a #I #G2 #L2 #V2 #T2 #X #H elim (lpys_inv_pair1 … H) -H
+  #K2 #W2 #HLK2 #HVW2 #H destruct
+  /3 width=5 by fqu_fquq, cpys_pair_sn, fqu_bind_dx, ex3_2_intro/
+| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #K2 #HK12
+  elim (ldrop_lpys_trans … HLK1 … HK12) -HK12
+  /3 width=7 by fqu_drop, ex3_2_intro/
+]
+qed-.
+
+lemma fquq_lpys_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
+                       ∀K2. ⦃G2, L2⦄ ⊢ ▶* K2 →
+                       ∃∃K1,T. ⦃G1, L1⦄ ⊢ ▶* K1 & ⦃G1, L1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐⸮ ⦃G2, K2, T2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #K2 #HLK2 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (fqu_lpys_trans … HT12 … HLK2) /3 width=5 by fqu_fquq, ex3_2_intro/
+| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma lpys_fqu_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐ ⦃G2, L2, T2⦄ →
+                      ∀K1. ⦃G1, K1⦄ ⊢ ▶* L1 →
+                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ▶* L2.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+/3 width=7 by fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, lpys_pair, ex3_2_intro/
+[ #I #G1 #L1 #V1 #X #H elim (lpys_inv_pair2 … H) -H
+  #K1 #W1 #HKL1 #HWV1 #H destruct elim (lift_total V1 0 1)
+  /4 width=7 by cpys_delta, fqu_drop, ldrop_drop, ex3_2_intro/
+| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #L0 #HL01
+  elim (lpys_ldrop_trans_O1 … HL01 … HLK1) -L1
+  /3 width=5 by fqu_drop, ex3_2_intro/
+]
+qed-.
+
+lemma lpys_fquq_trans: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐⸮ ⦃G2, L2, T2⦄ →
+                       ∀K1. ⦃G1, K1⦄ ⊢ ▶* L1 →
+                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ▶* T & ⦃G1, K1, T⦄ ⊐⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ▶* L2.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #HKL1 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (lpys_fqu_trans … HT12 … HKL1) /3 width=5 by fqu_fquq, ex3_2_intro/
+| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_lpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lpys_lpys.etc
new file mode 100644 (file)
index 0000000..f5524bf
--- /dev/null
@@ -0,0 +1,23 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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".
+
+(* SN EXTENDED MULTIPLE SUBSTITUTION FOR LOCAL ENVIRONMENTS *****************)
+
+(* Main properties **********************************************************)
+
+theorem lpys_trans: ∀G. Transitive … (lpys G).
+/3 width=5 by lpx_sn_trans, cpys_trans_lpys/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lrsubeq_2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lrsubeq_2.etc
new file mode 100644 (file)
index 0000000..da28322
--- /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 ⊆ break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LRSubEq $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby.etc
new file mode 100644 (file)
index 0000000..c06429d
--- /dev/null
@@ -0,0 +1,95 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lrsubeq_2.ma".
+include "basic_2/relocation/ldrop.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR EXTENDED SUBSTITUTION *******************)
+
+inductive lsuby: relation lenv ≝
+| lsuby_atom: ∀L. lsuby L (⋆)
+| lsuby_pair: ∀I1,I2,L1,L2,V. lsuby L1 L2 → lsuby (L1.ⓑ{I1}V) (L2.ⓑ{I2}V)
+.
+
+interpretation
+  "local environment refinement (extended substitution)"
+  'LRSubEq L1 L2 = (lsuby L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lsuby_refl: ∀L. L ⊆ L.
+#L elim L -L /2 width=1 by lsuby_pair/
+qed.
+
+lemma lsuby_sym: ∀L1,L2. L1 ⊆ L2 → |L1| = |L2| → L2 ⊆ L1.
+#L1 #L2 #H elim H -L1 -L2
+[ #L1 #H >(length_inv_zero_dx … H) -L1 //
+| #I1 #I2 #L1 #L2 #V #_ #IHL12 #H lapply (injective_plus_l … H) -H
+  /3 width=1 by lsuby_pair/
+]
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lsuby_inv_atom1_aux: ∀L1,L2. L1 ⊆ L2 → L1 = ⋆ → L2 = ⋆.
+#L1 #L2 * -L1 -L2 //
+#I1 #I2 #L1 #L2 #V #_ #H destruct
+qed-.
+
+lemma lsuby_inv_atom1: ∀L2. ⋆ ⊆ L2 → L2 = ⋆.
+/2 width=3 by lsuby_inv_atom1_aux/ qed-.
+
+fact lsuby_inv_pair1_aux: ∀L1,L2. L1 ⊆ L2 → ∀J1,K1,W. L1 = K1.ⓑ{J1}W →
+                          L2 = ⋆ ∨ ∃∃I2,K2. K1 ⊆ K2 & L2 = K2.ⓑ{I2}W.
+#L1 #L2 * -L1 -L2
+[ #L #J1 #K1 #W #H destruct /2 width=1 by or_introl/
+| #I1 #I2 #L1 #L2 #V #HL12 #J1 #K1 #W #H destruct /3 width=4 by ex2_2_intro, or_intror/
+]
+qed-.
+
+lemma lsuby_inv_pair1: ∀I1,K1,L2,W. K1.ⓑ{I1}W ⊆ L2 →
+                       L2 = ⋆ ∨ ∃∃I2,K2. K1 ⊆ K2 & L2 = K2.ⓑ{I2}W.
+/2 width=4 by lsuby_inv_pair1_aux/ qed-.
+
+fact lsuby_inv_pair2_aux: ∀L1,L2. L1 ⊆ L2 → ∀J2,K2,W. L2 = K2.ⓑ{J2}W →
+                          ∃∃I1,K1. K1 ⊆ K2 & L1 = K1.ⓑ{I1}W.
+#L1 #L2 * -L1 -L2
+[ #L #J2 #K2 #W #H destruct
+| #I1 #I2 #L1 #L2 #V #HL12 #J2 #K2 #W #H destruct /2 width=4 by ex2_2_intro/
+]
+qed-.
+
+lemma lsuby_inv_pair2: ∀I2,L1,K2,W. L1 ⊆ K2.ⓑ{I2}W  →
+                       ∃∃I1,K1. K1 ⊆ K2 & L1 = K1.ⓑ{I1}W.
+/2 width=4 by lsuby_inv_pair2_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lsuby_fwd_length: ∀L1,L2. L1 ⊆ L2 → |L2| ≤ |L1|.
+#L1 #L2 #H elim H -L1 -L2 /2 width=1 by monotonic_le_plus_l/
+qed-.
+
+lemma lsuby_ldrop_trans: ∀L1,L2. L1 ⊆ L2 →
+                         ∀I2,K2,W,s,i. ⇩[s, 0, i] L2 ≡ K2.ⓑ{I2}W →
+                         ∃∃I1,K1. K1 ⊆ K2 & ⇩[s, 0, i] L1 ≡ K1.ⓑ{I1}W.
+#L1 #L2 #H elim H -L1 -L2
+[ #L #J2 #K2 #W #s #i #H
+  elim (ldrop_inv_atom1 … H) -H #H destruct
+| #I1 #I2 #L1 #L2 #V #HL12 #IHL12 #J2 #K2 #W #s #i #H
+  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct [ -IHL12 | -HL12 ]
+  [ /3 width=4 by ldrop_pair, ex2_2_intro/
+  | elim (IHL12 … HLK2) -IHL12 -HLK2 * /3 width=4 by ldrop_drop_lt, ex2_2_intro/
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby_lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/lsuby_lsuby.etc
new file mode 100644 (file)
index 0000000..254d629
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lsuby.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR EXTENDED SUBSTITUTION *******************)
+
+(* Main properties **********************************************************)
+
+theorem lsuby_trans: Transitive … lsuby.
+#L1 #L #H elim H -L1 -L
+[ #L1 #X #H lapply (lsuby_inv_atom1 … H) -H //
+| #I1 #I #L1 #L #V #_ #IHL1 #X #H elim (lsuby_inv_pair1 … H) -H // *
+  #I2 #L2 #HL2 #H destruct /3 width=1 by lsuby_pair/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubstsnstar_3.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubstsnstar_3.etc
new file mode 100644 (file)
index 0000000..0d6dffe
--- /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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ▶ * break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'PSubstSnStar $G $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubststar_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys0/psubststar_4.etc
new file mode 100644 (file)
index 0000000..0e76c6f
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStar $G $L $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/cpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/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_2A1/cpys2/cpx_cpys2.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/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_2A1/cpys2/cpxs_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/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_2A1/cpys2/lpx_cpys.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/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_2A1/cpys2/lsuby.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/cpys2/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_2A1/csup/csup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csup.etc
new file mode 100644 (file)
index 0000000..0a980f6
--- /dev/null
@@ -0,0 +1,88 @@
+(* Basic forward lemmas *****************************************************)
+
+lemma csup_fwd_ldrop: ∀L1,L2,T1,T2. ⦃L1, T1⦄ > ⦃L2, T2⦄ →
+                      ∃i. ⇩[0, i] L1 ≡ L2 ∨ ⇩[0, i] L2 ≡ L1.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /3 width=2/ /4 width=2/
+#I #L1 #K1 #V1 #i #HLK1
+lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 /3 width=2/
+qed-. 
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lift_csup_trans_eq: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
+                          ∀L,U2. ⦃L, U1⦄ > ⦃L, U2⦄ → 
+                          ∃T2. ⇧[d, e] T2 ≡ U2.
+#T1 #U1 #d #e * -T1 -U1 -d -e
+[5: #a #I #V1 #W1 #T1 #U1 #d #e #HVW1 #_ #L #X #H
+    elim (csup_inv_bind1 … H) -H *
+    [ #_ #H destruct /2 width=2/
+    | #H elim (discr_lpair_x_xy … H)
+    ]
+|6: #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HUT1 #L #X #H
+    elim (csup_inv_flat1 … H) -H #_ * #H destruct /2 width=2/
+]
+#i #d #e [2,3: #_ ] #L #X #H
+elim (csup_inv_atom1 … H) -H #I #j #HL #H destruct
+lapply (ldrop_pair2_fwd_cw … HL X) -HL #H
+elim (lt_refl_false … H)
+qed-.
+(*
+lemma lift_csup_trans_gt: ∀L1,L2,U1,U2. ⦃L1, U1⦄ > ⦃L2, U2⦄ →
+                          ⇩[0, 1] L2 ≡ L1 → ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
+                          ∃T2. ⇧[d + 1, e] T2 ≡ U2.
+#L1 #L2 #U1 #U2 * -L1 -L2 -U1 -U2
+[ #I #L1 #K1 #V #i #HLK1 #HKL1
+  lapply (ldrop_fwd_lw … HLK1) -HLK1 #HLK1
+  lapply (ldrop_fwd_lw … HKL1) -HKL1 #HKL1
+  lapply (transitive_le … HLK1 HKL1) -L1 normalize #H
+  
+  
+| #a
+| #a
+]
+#I #L1 #W1 #U1 #HL1
+  
+
+
+ #X #d #e #H
+  lapply (ldrop_inv_refl … HL1) -HL1
+| #a #I #L1 #W1 #U1 #j #HL1 #X #d #e #H
+  lapply (ldrop_inv_ldrop1 … HL1)
+
+  elim (lift_inv_bind2 … H) -H #W2 #U2 #HW21 #HU21 #H destruct 
+   
+
+ /3 width=2/ /4 width=2/
+
+*)
+
+
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma csup_inv_lref2_be: ∀L,U,i. ⦃L, U⦄ > ⦃L, #i⦄ →
+                         ∀T,d,e. ⇧[d, e] T ≡ U → d ≤ i → i < d + e → ⊥.
+#L #U #i #H #T #d #e #HTU #Hdi #Hide
+elim (lift_csup_trans_eq … HTU … H) -H -T #T #H
+elim (lift_inv_lref2_be … H ? ?) //
+qed-.
+
+
+fact csup_inv_all4_refl_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ > ⦃L2, T2⦄ → L1 = L2 →
+                             ∨∨ ∃∃a,I,U. T1 = ⓑ{a,I}T2.U
+                              | ∃∃I,W. T1 = ⓕ{I}W.T2
+                              | ∃∃I,U. T1 = ⓕ{I}T2.U.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /3 width=3/ /3 width=4/
+[ #I #L #K #V #i #HLK #H destruct
+  lapply (ldrop_pair2_fwd_cw … HLK V) -HLK #H
+  elim (lt_refl_false … H)
+| #a #I #L #V #T #H
+  elim (discr_lpair_x_xy … H)
+]
+qed-.
+
+lemma csup_inv_all4_refl: ∀L,T1,T2. ⦃L, T1⦄ > ⦃L, T2⦄ →
+                          ∨∨ ∃∃a,I,U. T1 = ⓑ{a,I}T2.U
+                           | ∃∃I,W. T1 = ⓕ{I}W.T2
+                           | ∃∃I,U. T1 = ⓕ{I}T2.U.
+/2 width=4 by csup_inv_all4_refl_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csup_csup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csup_csup.etc
new file mode 100644 (file)
index 0000000..661d896
--- /dev/null
@@ -0,0 +1,33 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ldrop_ldrop.ma".
+include "basic_2/substitution/csup.ma".
+
+(* SUPCLOSURE ***************************************************************)
+
+(* Main forward lemmas ******************************************************)
+
+theorem csup_trans_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ > ⦃L0, T2⦄ →
+                             ∀T3. ⦃L0, T2⦄ > ⦃L, T3⦄ →
+                             L = L0 ∨ ⦃L, T1⦄ > ⦃L, T3⦄.
+#L #L0 #T1 #T2 * -L -L0 -T1 -T2 /2 width=1/
+[ #I #L0 #K0 #V0 #i #HLK0 #T3 #H
+  lapply (ldrop_pair2_fwd_cw … HLK0 T3) -HLK0 #H1
+  lapply (csup_fwd_cw … H) -H #H2
+  lapply (transitive_lt … H1 H2) -H1 -H2 #H
+  elim (lt_refl_false … H)
+| #a #I #L0 #V2 #T2 #T3 #HT23
+  elim (csup_inv_ldrop … HT23 I V2 0 ?) -HT23 // #H1 #H2 destruct /2 width=1/
+  qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csups_csups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/csup/csups_csups.etc
new file mode 100644 (file)
index 0000000..9978429
--- /dev/null
@@ -0,0 +1,57 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/csup_csup.ma".
+include "basic_2/unfold/csups.ma".
+
+(* STAR-ITERATED SUPCLOSURE *************************************************)
+
+(* Advanced forward lemmas **************************************************)
+
+(*
+lemma csupp_strap2_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ > ⦃L0, T2⦄ →
+                             ∀T3. ⦃L0, T2⦄ >+ ⦃L, T3⦄ →
+                             L = L0 ∨ ⦃L, T1⦄ >+ ⦃L, T3⦄.
+#L #L0 #T1 #T2 * -L -L0 -T1 -T2 /2 width=1/
+[ #I #L0 #K0 #V0 #i #HLK0 #T3 #H
+  lapply (ldrop_pair2_fwd_cw … HLK0 T3) -HLK0 #H1
+  lapply (csupp_fwd_cw … H) -H #H2
+  lapply (transitive_lt … H1 H2) -H1 -H2 #H
+  elim (lt_refl_false … H)
+| #a #I #L0 #V2 #T2 #T3 #HT23
+  /3 width=5/
+
+  elim (csup_inv_ldrop … HT23 I V2 0 ?) -HT23 // #H1 #H2 destruct /2 width=1/
+  qed-.
+
+
+
+
+
+
+
+
+lemma csups_strap1_fwd_refl: ∀L,L0,T1,T2. ⦃L, T1⦄ >* ⦃L0, T2⦄ →
+                             ∀T3. ⦃L0, T2⦄ > ⦃L, T3⦄ → L = L0.
+#L #L0 #T1 #T2 #H @(csups_ind_dx … H) -L -T1 //
+#L1 #L #T1 #T #HL1 #_ #IHL0 #T3 #HL0
+lapply (csup_trans_fwd_refl … HL10) … HL0) -T2
+*) 
+lemma lift_csups_trans_aux: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
+                            ∀L1,L2,U2. ⦃L1, U1⦄ >* ⦃L2, U2⦄ → L1 = L2 →
+                            ∃T2. ⇧[d, e] T2 ≡ U2.
+#T1 #U1 #d #e #HTU1 #L1 #L2 #U2 #H @(csups_ind … H) -L2 -U2 /2 width=2/ -T1
+#L #L2 #U #U2 #HL1 #HL2 #IHL1 #H destruct
+
+* -T1 -U1 -d -e
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpcs_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpcs_delift.etc
new file mode 100644 (file)
index 0000000..7012ec1
--- /dev/null
@@ -0,0 +1,37 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/delift_lift.ma".
+include "basic_2/unfold/delift_delift.ma".
+include "basic_2/computation/cprs_delift.ma".
+include "basic_2/equivalence/cpcs_cpcs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
+
+(* Properties on inverse basic term relocation ******************************)
+
+lemma cpcs_zeta_delift_comm: ∀L,V,T1,T2. L.ⓓV ⊢ ▼*[O, 1] T1 ≡ T2 →
+                             L ⊢ T2 ⬌* +ⓓV.T1.
+/3 width=1/ qed.
+
+(* Basic_1: was only: pc3_gen_cabbr *)
+lemma thin_cpcs_delift_mono: ∀L,U1,U2. L ⊢ U1 ⬌* U2 →
+                             ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
+                             ∀T2. L ⊢ ▼*[d, e] U2 ≡ T2 → K ⊢ T1 ⬌* T2.
+#L #U1 #U2 #H #K #d #e #HLK #T1 #HTU1 #T2 #HTU2
+elim (cpcs_inv_cprs … H) -H #U #HU1 #HU2
+elim (thin_cprs_delift_conf … HU1 … HLK … HTU1) -U1 #T #HT1 #HUT
+elim (thin_cprs_delift_conf … HU2 … HLK … HTU2) -U2 -HLK #X #HT2 #H
+lapply (delift_mono … H … HUT) -L #H destruct /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpr_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cpr_delift.etc
new file mode 100644 (file)
index 0000000..04eb4ae
--- /dev/null
@@ -0,0 +1,37 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/thin_delift.ma".
+include "basic_2/reducibility/tpr_delift.ma".
+include "basic_2/reducibility/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON TERMS ****************************)
+
+(* Properties on inverse basic term relocation ******************************)
+
+(* Basic_1: was only: pr2_gen_cabbr *)
+lemma thin_cpr_delift_conf: ∀L,U1,U2. L ⊢ U1 ➡ U2 →
+                            ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
+                            ∃∃T2. K ⊢ T1 ➡ T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
+#L #U1 #U2 * #U #HU1 #HU2 #K #d #e #HLK #T1 #HTU1
+elim (tpr_delift_conf … HU1 … HTU1) -U1 #T #HT1 #HUT
+elim (le_or_ge (|L|) d) #Hd
+[ elim (thin_delift_tpss_conf_le … HU2 … HUT … HLK ?)
+| elim (le_or_ge (|L|) (d+e)) #Hde
+  [ elim (thin_delift_tpss_conf_le_up … HU2 … HUT … HLK ? ? ?)
+  | elim (thin_delift_tpss_conf_be … HU2 … HUT … HLK ? ?)
+  ]
+] -U -HLK // -Hd [2,3: -Hde] #T2 #HT2
+lapply (cpr_intro … HT1 HT2) -T /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cprs_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/cprs_delift.etc
new file mode 100644 (file)
index 0000000..6b78926
--- /dev/null
@@ -0,0 +1,37 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_delift.ma".
+include "basic_2/reducibility/cpr_cpr.ma".
+include "basic_2/computation/cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties on inverse basic term relocation ******************************)
+
+(* Note: this should be stated with tprs *)
+lemma cprs_zeta_delift: ∀L,V,T1,T2. L.ⓓV ⊢ ▼*[O, 1] T1 ≡ T2 → L ⊢ +ⓓV.T1 ➡* T2.
+#L #V #T1 #T2 * #T #HT1 #HT2
+@(cprs_strap2 … (+ⓓV.T)) [ /3 width=3/ | @inj /3 width=3/ ] (**) (* explicit constructor, /5 width=3/ is too slow *)
+qed.
+
+(* Basic_1: was only: pr3_gen_cabbr *)
+lemma thin_cprs_delift_conf: ∀L,U1,U2. L ⊢ U1 ➡* U2 →
+                             ∀K,d,e. ▼*[d, e] L ≡ K → ∀T1. L ⊢ ▼*[d, e] U1 ≡ T1 →
+                             ∃∃T2. K ⊢ T1 ➡* T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
+#L #U1 #U2 #H @(cprs_ind … H) -U2 /2 width=3/
+#U #U2 #_ #HU2 #IHU1 #K #d #e #HLK #T1 #HTU1
+elim (IHU1 … HLK … HTU1) -U1 #T #HT1 #HUT
+elim (thin_cpr_delift_conf … HU2 … HLK … HUT) -U -HLK /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift.etc
new file mode 100644 (file)
index 0000000..eda8396
--- /dev/null
@@ -0,0 +1,112 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'TSubst $L $T1 $d $e $T2 }.
+
+include "basic_2/unfold/tpss.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+definition delift: nat → nat → lenv → relation term ≝
+                   λd,e,L,T1,T2. ∃∃T. L ⊢ T1 ▶* [d, e] T & ⇧[d, e] T2 ≡ T.
+
+interpretation "inverse basic relocation (term)"
+   'TSubst L T1 d e T2 = (delift d e L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma lift_delift: ∀T1,T2,d,e. ⇧[d, e] T1 ≡ T2 →
+                   ∀L. L ⊢ ▼*[d, e] T2 ≡ T1.
+/2 width=3/ qed.
+
+lemma delift_refl_O2: ∀L,T,d. L ⊢ ▼*[d, 0] T ≡ T.
+/2 width=3/ qed.
+
+lemma delift_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ ▼*[d, e] T1 ≡ T2 →
+                          ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ ▼*[d, e] T1 ≡ T2.
+#L1 #T1 #T2 #d #e * /3 width=3/
+qed.
+
+lemma delift_sort: ∀L,d,e,k. L ⊢ ▼*[d, e] ⋆k ≡ ⋆k.
+/2 width=3/ qed.
+
+lemma delift_lref_lt: ∀L,d,e,i. i < d → L ⊢ ▼*[d, e] #i ≡ #i.
+/3 width=3/ qed.
+
+lemma delift_lref_ge: ∀L,d,e,i. d + e ≤ i → L ⊢ ▼*[d, e] #i ≡ #(i - e).
+/3 width=3/ qed.
+
+lemma delift_gref: ∀L,d,e,p. L ⊢ ▼*[d, e] §p ≡ §p.
+/2 width=3/ qed.
+
+lemma delift_bind: ∀a,I,L,V1,V2,T1,T2,d,e.
+                   L ⊢ ▼*[d, e] V1 ≡ V2 → L. ⓑ{I} V2 ⊢ ▼*[d+1, e] T1 ≡ T2 →
+                   L ⊢ ▼*[d, e] ⓑ{a,I} V1. T1 ≡ ⓑ{a,I} V2. T2.
+#a #I #L #V1 #V2 #T1 #T2 #d #e * #V #HV1 #HV2 * #T #HT1 #HT2
+lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V) ?) -HT1 /2 width=1/ /3 width=5/
+qed.
+
+lemma delift_flat: ∀I,L,V1,V2,T1,T2,d,e.
+                   L ⊢ ▼*[d, e] V1 ≡ V2 → L ⊢ ▼*[d, e] T1 ≡ T2 →
+                   L ⊢ ▼*[d, e] ⓕ{I} V1. T1 ≡ ⓕ{I} V2. T2.
+#I #L #V1 #V2 #T1 #T2 #d #e * #V #HV1 #HV2 * /3 width=5/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma delift_inv_sort1: ∀L,U2,d,e,k. L ⊢ ▼*[d, e] ⋆k ≡ U2 → U2 = ⋆k.
+#L #U2 #d #e #k * #U #HU
+>(tpss_inv_sort1 … HU) -HU #HU2
+>(lift_inv_sort2 … HU2) -HU2 //
+qed-.
+
+lemma delift_inv_gref1: ∀L,U2,d,e,p. L ⊢ ▼*[d, e] §p ≡ U2 → U2 = §p.
+#L #U #d #e #p * #U #HU
+>(tpss_inv_gref1 … HU) -HU #HU2
+>(lift_inv_gref2 … HU2) -HU2 //
+qed-.
+
+lemma delift_inv_bind1: ∀a,I,L,V1,T1,U2,d,e. L ⊢ ▼*[d, e] ⓑ{a,I} V1. T1 ≡ U2 →
+                        ∃∃V2,T2. L ⊢ ▼*[d, e] V1 ≡ V2 &
+                                 L. ⓑ{I} V2 ⊢ ▼*[d+1, e] T1 ≡ T2 &
+                                 U2 = ⓑ{a,I} V2. T2.
+#a #I #L #V1 #T1 #U2 #d #e * #U #HU #HU2
+elim (tpss_inv_bind1 … HU) -HU #V #T #HV1 #HT1 #X destruct
+elim (lift_inv_bind2 … HU2) -HU2 #V2 #T2 #HV2 #HT2
+lapply (tpss_lsubr_trans … HT1 (L. ⓑ{I} V2) ?) -HT1 /2 width=1/ /3 width=5/
+qed-.
+
+lemma delift_inv_flat1: ∀I,L,V1,T1,U2,d,e. L ⊢ ▼*[d, e] ⓕ{I} V1. T1 ≡ U2 →
+                        ∃∃V2,T2. L ⊢ ▼*[d, e] V1 ≡ V2 &
+                                 L ⊢ ▼*[d, e] T1 ≡ T2 &
+                                 U2 = ⓕ{I} V2. T2.
+#I #L #V1 #T1 #U2 #d #e * #U #HU #HU2
+elim (tpss_inv_flat1 … HU) -HU #V #T #HV1 #HT1 #X destruct
+elim (lift_inv_flat2 … HU2) -HU2 /3 width=5/
+qed-.
+
+lemma delift_inv_refl_O2: ∀L,T1,T2,d. L ⊢ ▼*[d, 0] T1 ≡ T2 → T1 = T2.
+#L #T1 #T2 #d * #T #HT1
+>(tpss_inv_refl_O2 … HT1) -HT1 #HT2
+>(lift_inv_refl_O2 … HT2) -HT2 //
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma delift_fwd_tw: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 → ♯{T1} ≤ ♯{T2}.
+#L #T1 #T2 #d #e * #T #HT1 #HT2
+>(lift_fwd_tw … HT2) -T2 /2 width=4 by tpss_fwd_tw/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_alt.etc
new file mode 100644 (file)
index 0000000..e229110
--- /dev/null
@@ -0,0 +1,104 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break ▼ ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'TSubstAlt $L $T1 $d $e $T2 }.
+
+include "basic_2/unfold/delift_lift.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+(* alternative definition of inverse basic term relocation *)
+inductive delifta: nat → nat → lenv → relation term ≝
+| delifta_sort   : ∀L,d,e,k. delifta d e L (⋆k) (⋆k)
+| delifta_lref_lt: ∀L,d,e,i. i < d → delifta d e L (#i) (#i)
+| delifta_lref_be: ∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
+                   ⇩[0, i] L ≡ K. ⓓV1 → delifta 0 (d + e - i - 1) K V1 V2 →
+                   ⇧[0, d] V2 ≡ W2 → delifta d e L (#i) W2
+| delifta_lref_ge: ∀L,d,e,i. d + e ≤ i → delifta d e L (#i) (#(i - e))
+| delifta_gref   : ∀L,d,e,p. delifta d e L (§p) (§p)
+| delifta_bind   : ∀L,a,I,V1,V2,T1,T2,d,e.
+                   delifta d e L V1 V2 → delifta (d + 1) e (L. ⓑ{I} V2) T1 T2 →
+                   delifta d e L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| delifta_flat   : ∀L,I,V1,V2,T1,T2,d,e.
+                   delifta d e L V1 V2 → delifta d e L T1 T2 →
+                   delifta d e L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+.
+
+interpretation "inverse basic relocation (term) alternative"
+   'TSubstAlt L T1 d e T2 = (delifta d e L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma delifta_lsubr_trans: ∀L1,T1,T2,d,e. L1 ⊢ ▼▼*[d, e] T1 ≡ T2 →
+                           ∀L2. L2 ⊑ [d, e] L1 → L2 ⊢ ▼▼*[d, e] T1 ≡ T2.
+#L1 #T1 #T2 #d #e #H elim H -L1 -T1 -T2 -d -e // /2 width=1/
+[ #L1 #K1 #V1 #V2 #W2 #i #d #e #Hdi #Hide #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (ldrop_lsubr_ldrop2_abbr … HL12 … HLK1 ? ?) -HL12 -HLK1 // /3 width=6/
+| /4 width=1/
+| /3 width=1/
+]
+qed.
+
+lemma delift_delifta: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 → L ⊢ ▼▼*[d, e] T1 ≡ T2.
+#L #T1 @(f2_ind … fw … L T1) -L -T1 #n #IH #L *
+[ * #i #Hn #T2 #d #e #H destruct
+  [ >(delift_inv_sort1 … H) -H //
+  | elim (delift_inv_lref1 … H) -H * /2 width=1/
+    #K #V1 #V2 #Hdi #Hide #HLK #HV12 #HVT2
+    lapply (ldrop_pair2_fwd_fw … HLK) #H
+    lapply (IH … HV12) // -H /2 width=6/
+  | >(delift_inv_gref1 … H) -H //
+  ]
+| * [ #a ] #I #V1 #T1 #Hn #X #d #e #H
+  [ elim (delift_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (delift_lsubr_trans … HT12 (L.ⓑ{I}V1) ?) -HT12 /2 width=1/ #HT12
+    lapply (IH … HV12) -HV12 // #HV12
+    lapply (IH … HT12) -IH -HT12 /2 width=1/ #HT12
+    lapply (delifta_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/
+  | elim (delift_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH … HV12) -HV12 //
+    lapply (IH … HT12) -IH -HT12 // /2 width=1/
+  ]
+]
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma delifta_delift: ∀L,T1,T2,d,e. L ⊢ ▼▼*[d, e] T1 ≡ T2 → L ⊢ ▼*[d, e] T1 ≡ T2.
+#L #T1 #T2 #d #e #H elim H -L -T1 -T2 -d -e // /2 width=1/ /2 width=6/
+qed-.
+
+lemma delift_ind_alt: ∀R:ℕ→ℕ→lenv→relation term.
+                      (∀L,d,e,k. R d e L (⋆k) (⋆k)) →
+                      (∀L,d,e,i. i < d → R d e L (#i) (#i)) →
+                      (∀L,K,V1,V2,W2,i,d,e. d ≤ i → i < d + e →
+                       ⇩[O, i] L ≡ K.ⓓV1 → K ⊢ ▼*[O, d + e - i - 1] V1 ≡ V2 →
+                       ⇧[O, d] V2 ≡ W2 → R O (d+e-i-1) K V1 V2 → R d e L (#i) W2
+                      ) →
+                      (∀L,d,e,i. d + e ≤ i → R d e L (#i) (#(i - e))) →
+                      (∀L,d,e,p. R d e L (§p) (§p)) →
+                      (∀L,a,I,V1,V2,T1,T2,d,e. L ⊢ ▼*[d, e] V1 ≡ V2 →
+                       L.ⓑ{I}V2 ⊢ ▼*[d + 1, e] T1 ≡ T2 → R d e L V1 V2 →
+                       R (d+1) e (L.ⓑ{I}V2) T1 T2 → R d e L (ⓑ{a,I}V1.T1) (ⓑ{a,I}V2.T2)
+                      ) →
+                      (∀L,I,V1,V2,T1,T2,d,e. L ⊢ ▼*[d, e] V1 ≡ V2 →
+                       L⊢ ▼*[d, e] T1 ≡ T2 → R d e L V1 V2 →
+                       R d e L T1 T2 → R d e L (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
+                      ) →
+                      ∀d,e,L,T1,T2. L ⊢ ▼*[d, e] T1 ≡ T2 → R d e L T1 T2.
+#R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #d #e #L #T1 #T2 #H elim (delift_delifta … H) -L -T1 -T2 -d -e
+// /2 width=1 by delifta_delift/ /3 width=1 by delifta_delift/ /3 width=7 by delifta_delift/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_delift.etc
new file mode 100644 (file)
index 0000000..a5c5635
--- /dev/null
@@ -0,0 +1,29 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/delift.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+(* Main properties **********************************************************)
+
+theorem delift_mono: ∀L,T,T1,T2,d,e.
+                     L ⊢ ▼*[d, e] T ≡ T1 → L ⊢ ▼*[d, e] T ≡ T2 → T1 = T2.
+#L #T #T1 #T2 #d #e * #U1 #H1TU1 #H2TU1 * #U2 #H1TU2 #H2TU2
+elim (tpss_conf_eq … H1TU1 … H1TU2) -T #U #HU1 #HU2
+lapply (tpss_inv_lift1_eq … HU1 … H2TU1) -HU1 #H destruct
+lapply (tpss_inv_lift1_eq … HU2 … H2TU2) -HU2 #H destruct
+lapply (lift_inj … H2TU1 … H2TU2) //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_lift.etc
new file mode 100644 (file)
index 0000000..8abaeb9
--- /dev/null
@@ -0,0 +1,164 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ldrop_lbotr.ma".
+include "basic_2/unfold/tpss_lift.ma".
+include "basic_2/unfold/delift.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+(* Advanced properties ******************************************************)
+
+lemma delift_lref_be: ∀L,K,V1,V2,U2,i,d,e. d ≤ i → i < d + e →
+                      ⇩[0, i] L ≡ K. ⓓV1 → K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 →
+                      ⇧[0, d] V2 ≡ U2 → L ⊢ ▼*[d, e] #i ≡ U2.
+#L #K #V1 #V2 #U2 #i #d #e #Hdi #Hide #HLK * #V #HV1 #HV2 #HVU2
+elim (lift_total V 0 (i+1)) #U #HVU
+lapply (lift_trans_be … HV2 … HVU ? ?) -HV2 // >minus_plus <plus_minus_m_m /2 width=1/ #HV2U
+lapply (lift_conf_be … HVU2 … HV2U ?) //
+>commutative_plus in ⊢ (??%??→?); <minus_plus_m_m /3 width=6/
+qed.
+
+lemma lbotr_delift: ∀L,T1,d,e. d + e ≤ |L| → ⊒[d, e] L →
+                    ∃T2. L ⊢ ▼*[d, e] T1 ≡ T2.
+#L #T1 @(f2_ind … fw … L T1) -L -T1
+#n #IH #L * * /2 width=2/
+[ #i #H #d #e #Hde #HL destruct
+  elim (lt_or_ge i d) #Hdi [ /3 width=2/ ]
+  elim (lt_or_ge i (d+e)) #Hide [2: /3 width=2/ ]
+  lapply (lt_to_le_to_lt … Hide Hde) #Hi
+  elim (ldrop_O1_lt … Hi) -Hi #I #K #V1 #HLK
+  lapply (lbotr_inv_ldrop … HLK … HL ? ?) // #H destruct
+  lapply (ldrop_pair2_fwd_fw … HLK (#i)) #HKL
+  lapply (ldrop_fwd_ldrop2 … HLK) #HLK0
+  lapply (ldrop_fwd_O1_length … HLK0) #H
+  lapply (lbotr_ldrop_trans_be_up … HLK0 … HL ? ?) -HLK0 -HL
+  [1,2: /2 width=1/ | <minus_n_O <minus_plus ] #HK
+  elim (IH … HKL … HK) -IH -HKL -HK
+  [2: >H -H /2 width=1/ ] -Hde -H #V2 #V12 (**) (* H erased two times *)
+  elim (lift_total V2 0 d) /3 width=7/
+| #a #I #V1 #T1 #H #d #e #Hde #HL destruct
+  elim (IH … V1 … Hde HL) // #V2 #HV12
+  elim (IH (L.ⓑ{I}V1) T1 … (d+1) e ??) -IH // [2,3: /2 width=1/ ] -Hde -HL #T2 #HT12
+  lapply (delift_lsubr_trans … HT12 (L.ⓑ{I}V2) ?) -HT12 /2 width=1/ /3 width=4/
+| #I #V1 #T1 #H #d #e #Hde #HL destruct
+  elim (IH … V1 … Hde HL) // #V2 #HV12
+  elim (IH … T1 … Hde HL) -IH -Hde -HL // /3 width=2/
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma delift_inv_lref1_lt: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 → i < d → U2 = #i.
+#L #U2 #i #d #e * #U #HU #HU2 #Hid
+elim (tpss_inv_lref1 … HU) -HU
+[ #H destruct >(lift_inv_lref2_lt … HU2) //
+| * #K #V1 #V2 #Hdi
+  lapply (lt_to_le_to_lt … Hid Hdi) -Hid -Hdi #Hi
+  elim (lt_refl_false … Hi)
+]
+qed-.
+
+lemma delift_inv_lref1_be: ∀L,U2,d,e,i. L ⊢ ▼*[d, e] #i ≡ U2 →
+                           d ≤ i → i < d + e →
+                           ∃∃K,V1,V2. ⇩[0, i] L ≡ K. ⓓV1 &
+                                      K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 &
+                                      ⇧[0, d] V2 ≡ U2.
+#L #U2 #d #e #i * #U #HU #HU2 #Hdi #Hide
+elim (tpss_inv_lref1 … HU) -HU
+[ #H destruct elim (lift_inv_lref2_be … HU2 ? ?) //
+| * #K #V1 #V #_ #_ #HLK #HV1 #HVU
+  elim (lift_div_be … HVU … HU2 ? ?) -U // /2 width=1/ /3 width=6/
+]
+qed-.
+
+lemma delift_inv_lref1_ge: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 →
+                           d + e ≤ i → U2 = #(i - e).
+#L #U2 #i #d #e * #U #HU #HU2 #Hdei
+elim (tpss_inv_lref1 … HU) -HU
+[ #H destruct >(lift_inv_lref2_ge … HU2) //
+| * #K #V1 #V2 #_ #Hide
+  lapply (lt_to_le_to_lt … Hide Hdei) -Hide -Hdei #Hi
+  elim (lt_refl_false … Hi)
+]
+qed-.
+
+lemma delift_inv_lref1: ∀L,U2,i,d,e. L ⊢ ▼*[d, e] #i ≡ U2 →
+                        ∨∨ (i < d ∧ U2 = #i)
+                        |  (∃∃K,V1,V2. d ≤ i & i < d + e &
+                                       ⇩[0, i] L ≡ K. ⓓV1 &
+                                       K ⊢ ▼*[0, d + e - i - 1] V1 ≡ V2 &
+                                       ⇧[0, d] V2 ≡ U2
+                           )
+                        |  (d + e ≤ i ∧ U2 = #(i - e)).
+#L #U2 #i #d #e #H
+elim (lt_or_ge i d) #Hdi
+[ elim (delift_inv_lref1_lt … H Hdi) -H /3 width=1/
+| elim (lt_or_ge i (d+e)) #Hide
+  [ elim (delift_inv_lref1_be … H Hdi Hide) -H /3 width=6/
+  | elim (delift_inv_lref1_ge … H Hide) -H /3 width=1/
+  ]
+]
+qed-.
+
+(* Properties on basic term relocation **************************************)
+
+lemma delift_lift_le: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
+                      ∀L,U1,d,e. dt + et ≤ d → ⇩[d, e] L ≡ K →
+                      ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d - et, e] T2 ≡ U2 →
+                      L ⊢ ▼*[dt, et] U1 ≡ U2.
+#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hdetd #HLK #HTU1 #U2 #HTU2
+elim (lift_total T d e) #U #HTU
+lapply (tpss_lift_le … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
+elim (lift_trans_ge … HT2 … HTU ?) -T // -Hdetd #T #HT2 #HTU
+>(lift_mono … HTU2 … HT2) -T2 /2 width=3/
+qed.
+
+lemma delift_lift_be: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
+                      ∀L,U1,d,e. dt ≤ d → d ≤ dt + et →
+                      ⇩[d, e] L ≡ K → ⇧[d, e] T1 ≡ U1 →
+                      L ⊢ ▼*[dt, et + e] U1 ≡ T2.
+#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hdtd #Hddet #HLK #HTU1
+elim (lift_total T d e) #U #HTU
+lapply (tpss_lift_be … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
+lapply (lift_trans_be … HT2 … HTU ? ?) -T // -Hdtd -Hddet /2 width=3/
+qed.
+
+lemma delift_lift_ge: ∀K,T1,T2,dt,et. K ⊢ ▼*[dt, et] T1 ≡ T2 →
+                      ∀L,U1,d,e. d ≤ dt → ⇩[d, e] L ≡ K →
+                      ⇧[d, e] T1 ≡ U1 → ∀U2. ⇧[d, e] T2 ≡ U2 →
+                      L ⊢ ▼*[dt + e, et] U1 ≡ U2.
+#K #T1 #T2 #dt #et * #T #HT1 #HT2 #L #U1 #d #e #Hddt #HLK #HTU1 #U2 #HTU2
+elim (lift_total T d e) #U #HTU
+lapply (tpss_lift_ge … HT1 … HLK HTU1 … HTU) -T1 -HLK // #HU1
+elim (lift_trans_le … HT2 … HTU ?) -T // -Hddt #T #HT2 #HTU
+>(lift_mono … HTU2 … HT2) -T2 /2 width=3/
+qed.
+
+lemma delift_inv_lift1_eq: ∀L,U1,T2,d,e. L ⊢ ▼*[d, e] U1 ≡ T2 →
+                           ∀K. ⇩[d, e] L ≡ K → ∀T1. ⇧[d, e] T1 ≡ U1 → T1 = T2.
+#L #U1 #T2 #d #e * #U2 #HU12 #HTU2 #K #HLK #T1 #HTU1
+lapply (tpss_inv_lift1_eq … HU12 … HTU1) -L -K #H destruct
+lapply (lift_inj … HTU1 … HTU2) -U2 //
+qed-.
+
+lemma delift_lift_div_be: ∀L,T1,T,d,e,i. L ⊢ ▼*[i, d + e - i] T1 ≡ T →
+                          ∀T2. ⇧[d, i - d] T2 ≡ T → d ≤ i → i ≤ d + e →
+                          L ⊢ ▼*[d, e] T1 ≡ T2.
+#L #T1 #T #d #e #i * #T0 #HT10 #HT0 #T2 #HT2 #Hdi #Hide
+lapply (tpss_weak … HT10 d e ? ?) -HT10 // [ >commutative_plus /2 width=1/ ] #HT10
+lapply (lift_trans_be … HT2 … HT0 ? ?) -T //
+>commutative_plus >commutative_plus in ⊢ (? ? (? % ?) ? ? → ?);
+<minus_le_minus_minus_comm // <plus_minus_m_m [ /2 width=3/ | /2 width=1/ ]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_ltpss.etc
new file mode 100644 (file)
index 0000000..2954223
--- /dev/null
@@ -0,0 +1,33 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_alt.ma".
+include "basic_2/unfold/delift.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+(* Properties on sn partial unfold on local environments ********************)
+
+lemma delift_ltpss_sn_conf_eq: ∀L,T1,T2,d,e. L ⊢ ▼*[d, e] T1 ≡ T2 →
+                               ∀K. L ⊢ ▶* [d, e] K → K ⊢ ▼*[d, e] T1 ≡ T2.
+#L #T1 #T2 #d #e * #T #HT1 #HT2 #K #HLK
+elim (ltpss_sn_tpss_conf … HT1 … HLK) -HT1 -HLK #T0 #HT10 #HT0
+lapply (tpss_inv_lift1_eq … HT0 … HT2) -HT0 #H destruct /2 width=3/
+qed.
+
+lemma ltpss_sn_delift_trans_eq: ∀L,K,d,e. L ⊢ ▶* [d, e] K →
+                                ∀T1,T2. K ⊢ ▼*[d, e] T1 ≡ T2 → L ⊢ ▼*[d, e] T1 ≡ T2.
+#L #K #d #e #HLK #T1 #T2 * #T #HT1 #HT2
+lapply (ltpss_sn_tpss_trans_eq … HT1 … HLK) -K /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_tpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/delift_tpss.etc
new file mode 100644 (file)
index 0000000..662ae56
--- /dev/null
@@ -0,0 +1,92 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/tpss_tpss.ma".
+include "basic_2/unfold/delift.ma".
+
+(* INVERSE BASIC TERM RELOCATION  *******************************************)
+
+(* Properties on partial unfold on terms ************************************)
+
+lemma delift_tpss_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                           ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                           ∀K. ⇩[dd, ee] L ≡ K → d + e ≤ dd →
+                           ∃∃T2. K ⊢ T1 ▶* [d, e] T2 & L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1
+elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
+elim (tpss_inv_lift1_le … HXU1 … HLK … HTX1 ?) -X1 -HLK // -H1 /3 width=5/
+qed.
+
+lemma delift_tps_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                          ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                          ∀K. ⇩[dd, ee] L ≡ K → d + e ≤ dd →
+                          ∃∃T2. K ⊢ T1 ▶* [d, e] T2 & L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=3/ qed.
+
+lemma delift_tpss_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                              ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                              ∀K. ⇩[dd, ee] L ≡ K →
+                              d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
+                              ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
+                                    L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1 #H2 #H3
+elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
+elim (tpss_inv_lift1_le_up … HXU1 … HLK … HTX1 ? ? ?) -X1 -HLK // -H1 -H2 -H3 /3 width=5/
+qed.
+
+lemma delift_tps_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                             ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                             ∀K. ⇩[dd, ee] L ≡ K →
+                             d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
+                             ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
+                                   L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=6/ qed.
+
+lemma delift_tpss_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                           ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                           ∀K. ⇩[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
+                           ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
+                                 L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee * #X1 #HUX1 #HTX1 #K #HLK #H1 #H2
+elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
+elim (tpss_inv_lift1_be … HXU1 … HLK … HTX1 ? ?) -X1 -HLK // -H1 -H2 /3 width=5/
+qed.
+
+lemma delift_tps_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                          ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                          ∀K. ⇩[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
+                          ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
+                                L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=3/ qed.
+
+lemma delift_tpss_conf_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                           ∀T. L ⊢ ▼*[d, e] U1 ≡ T → L ⊢ ▼*[d, e] U2 ≡ T.
+#L #U1 #U2 #d #e #HU12 #T * #X1 #HUX1 #HTX1
+elim (tpss_conf_eq … HU12 … HUX1) -U1 #U1 #HU21 #HXU1
+lapply (tpss_inv_lift1_eq … HXU1 … HTX1) -HXU1 #H destruct /2 width=3/
+qed.
+
+lemma delift_tps_conf_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                          ∀T. L ⊢ ▼*[d, e] U1 ≡ T → L ⊢ ▼*[d, e] U2 ≡ T.
+/3 width=3/ qed.
+
+lemma tpss_delift_trans_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                            ∀T. L ⊢ ▼*[d, e] U2 ≡ T → L ⊢ ▼*[d, e] U1 ≡ T.
+#L #U1 #U2 #d #e #HU12 #T * #X1 #HUX1 #HTX1
+lapply (tpss_trans_eq … HU12 … HUX1) -U2 /2 width=3/
+qed.
+
+lemma tps_delift_trans_eq: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                           ∀T. L ⊢ ▼*[d, e] U2 ≡ T → L ⊢ ▼*[d, e] U1 ≡ T.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin.etc
new file mode 100644 (file)
index 0000000..f92cd54
--- /dev/null
@@ -0,0 +1,41 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ▼ * [ term 46 d , break term 46 e ] break term 46 T1 ≡ break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'TSubst $T1 $d $e $T2 }.
+
+include "basic_2/unfold/ltpss_sn.ma".
+
+(* BASIC LOCAL ENVIRONMENT THINNING *****************************************)
+
+definition thin: nat → nat → relation lenv ≝
+                 λd,e,L1,L2. ∃∃L. L1 ⊢ ▶* [d, e] L & ⇩[d, e] L ≡ L2.
+
+interpretation "basic thinning (local environment)"
+   'TSubst L1 d e L2 = (thin d e L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma ldrop_thin: ∀L1,L2,d,e. ⇩[d, e] L1 ≡ L2 → ▼*[d, e] L1 ≡ L2.
+/2 width=3/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma thin_inv_thin1: ∀I,K1,V1,L2,e. ▼*[0, e] K1.ⓑ{I} V1 ≡ L2 → 0 < e →
+                      ▼*[0, e - 1] K1 ≡ L2.
+#I #K1 #V1 #L2 #e * #X #HK1 #HL2 #e
+elim (ltpss_sn_inv_tpss21 … HK1 ?) -HK1 // #K #V #HK1 #_ #H destruct
+lapply (ldrop_inv_ldrop1 … HL2 ?) -HL2 // /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_delift.etc
new file mode 100644 (file)
index 0000000..b5ffc5e
--- /dev/null
@@ -0,0 +1,102 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/delift_tpss.ma".
+include "basic_2/unfold/delift_ltpss.ma".
+include "basic_2/unfold/thin.ma".
+
+(* BASIC DELIFT ON LOCAL ENVIRONMENTS ***************************************)
+
+(* Inversion lemmas on inverse basic term relocation ************************)
+
+lemma thin_inv_delift1: ∀I,K1,V1,L2,d,e. ▼*[d, e] K1. ⓑ{I} V1 ≡ L2 → 0 < d →
+                        ∃∃K2,V2. ▼*[d - 1, e] K1 ≡ K2 &
+                                 K1 ⊢ ▼*[d - 1, e] V1 ≡ V2 &
+                                 L2 = K2. ⓑ{I} V2.
+#I #K1 #V1 #L2 #d #e * #X #HK1 #HL2 #e
+elim (ltpss_sn_inv_tpss11 … HK1 ?) -HK1 // #K #V #HK1 #HV1 #H destruct
+elim (ldrop_inv_skip1 … HL2 ?) -HL2 // #K2 #V2 #HK2 #HV2 #H destruct /3 width=5/
+qed-.
+
+(* Properties on inverse basic term relocation ******************************)
+
+lemma thin_delift: ∀L1,L2,d,e. ▼*[d, e] L1 ≡ L2 → ∀V1,V2. L1 ⊢ ▼*[d, e] V1 ≡ V2 →
+                   ∀I. ▼*[d + 1, e] L1.ⓑ{I}V1 ≡ L2.ⓑ{I}V2.
+#L1 #L2 #d #e * #L #HL1 #HL2 #V1 #V2 * #V #HV1 #HV2 #I
+elim (ltpss_sn_tpss_conf … HV1 … HL1) -HV1 #V0 #HV10 #HV0
+lapply (tpss_inv_lift1_eq … HV0 … HV2) -HV0 #H destruct
+lapply (ltpss_sn_tpss_trans_eq … HV10 … HL1) -HV10 /3 width=5/
+qed.
+
+lemma thin_delift_tpss_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                                ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                                ∀K. ▼*[dd, ee] L ≡ K → d + e ≤ dd →
+                                ∃∃T2. K ⊢ T1 ▶* [d, e] T2 &
+                                      L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdedd
+lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
+elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
+elim (delift_tpss_conf_le … HU1 … HUT1 … HYK ?) -HU1 -HUT1 -HYK // -Hdedd #T #HT1 #HUT
+lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
+lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
+qed.
+
+lemma thin_delift_tps_conf_le: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                               ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                               ∀K. ▼*[dd, ee] L ≡ K → d + e ≤ dd →
+                               ∃∃T2. K ⊢ T1 ▶* [d, e] T2 &
+                                     L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=3/ qed.
+
+lemma thin_delift_tpss_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                                   ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                                   ∀K. ▼*[dd, ee] L ≡ K →
+                                   d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
+                                   ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
+                                         L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdd #Hdde #Hddee
+lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
+elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
+elim (delift_tpss_conf_le_up … HU1 … HUT1 … HYK ? ? ?) -HU1 -HUT1 -HYK // -Hdd -Hdde -Hddee #T #HT1 #HUT
+lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
+lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
+qed.
+
+lemma thin_delift_tps_conf_le_up: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                                  ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                                  ∀K. ▼*[dd, ee] L ≡ K →
+                                  d ≤ dd → dd ≤ d + e → d + e ≤ dd + ee →
+                                  ∃∃T2. K ⊢ T1 ▶* [d, dd - d] T2 &
+                                        L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=6 by thin_delift_tpss_conf_le_up, tpss_strap2/ qed. (**) (* too slow without trace *)
+
+lemma thin_delift_tpss_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶* [d, e] U2 →
+                                ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                                ∀K. ▼*[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
+                                ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
+                                      L ⊢ ▼*[dd, ee] U2 ≡ T2.
+#L #U1 #U2 #d #e #HU12 #T1 #dd #ee #HUT1 #K * #Y #HLY #HYK #Hdd #Hddee
+lapply (delift_ltpss_sn_conf_eq … HUT1 … HLY) -HUT1 #HUT1
+elim (ltpss_sn_tpss_conf … HU12 … HLY) -HU12 #U #HU1 #HU2
+elim (delift_tpss_conf_be … HU1 … HUT1 … HYK ? ?) -HU1 -HUT1 -HYK // -Hdd -Hddee #T #HT1 #HUT
+lapply (ltpss_sn_delift_trans_eq … HLY … HUT) -HLY -HUT #HUT
+lapply (tpss_delift_trans_eq … HU2 … HUT) -U /2 width=3/
+qed.
+
+lemma thin_delift_tps_conf_be: ∀L,U1,U2,d,e. L ⊢ U1 ▶ [d, e] U2 →
+                               ∀T1,dd,ee. L ⊢ ▼*[dd, ee] U1 ≡ T1 →
+                               ∀K. ▼*[dd, ee] L ≡ K → d ≤ dd → dd + ee ≤ d + e →
+                               ∃∃T2. K ⊢ T1 ▶* [d, e - ee] T2 &
+                                     L ⊢ ▼*[dd, ee] U2 ≡ T2.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/thin_ldrop.etc
new file mode 100644 (file)
index 0000000..f26c26f
--- /dev/null
@@ -0,0 +1,58 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/ltpss_sn_ldrop.ma".
+include "basic_2/unfold/thin.ma".
+
+(* BASIC LOCAL ENVIRONMENT THINNING *****************************************)
+
+(* Properties on local environment slicing **********************************)
+
+lemma thin_ldrop_conf_ge: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
+                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                          d1 + e1 ≤ e2 → ⇩[0, e2 - e1] L1 ≡ L2.
+#L0 #L1 #d1 #e1 * /3 width=8 by ltpss_sn_ldrop_conf_ge, ldrop_conf_ge/
+qed.
+
+lemma thin_ldrop_conf_be: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
+                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → d1 ≤ e2 → e2 ≤ d1 + e1 →
+                          ∃∃L. ▼*[0, d1 + e1 - e2] L2 ≡ L & ⇩[0, d1] L1 ≡ L.
+#L0 #L1 #d1 #e1 * #L #HL0 #HL1 #L2 #e2 #HL02 #Hd1e2 #He2de1
+elim (ltpss_sn_ldrop_conf_be … HL0 … HL02 ? ?) -L0 // #L0 #HL20 #HL0
+elim (ldrop_conf_be … HL1 … HL0 ? ?) -L // -Hd1e2 -He2de1 /3 width=3/
+qed.
+
+lemma thin_ldrop_conf_le: ∀L0,L1,d1,e1. ▼*[d1, e1] L0 ≡ L1 →
+                          ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                          ∃∃L. ▼*[d1 - e2, e1] L2 ≡ L & ⇩[0, e2] L1 ≡ L.
+#L0 #L1 #d1 #e1 * #L #HL0 #HL1 #L2 #e2 #HL02 #He2d1
+elim (ltpss_sn_ldrop_conf_le … HL0 … HL02 ?) -L0 // #L0 #HL20 #HL0
+elim (ldrop_conf_le … HL1 … HL0 ?) -L // -He2d1 /3 width=3/
+qed.
+
+lemma thin_ldrop_trans_ge: ∀L1,L0,d1,e1. ▼*[d1, e1] L1 ≡ L0 →
+                           ∀L2,e2. ⇩[0, e2] L0 ≡ L2 →
+                           d1 ≤ e2 → ⇩[0, e1 + e2] L1 ≡ L2.
+#L1 #L0 #d1 #e1 * #L #HL1 #HL0 #L2 #e2 #HL02 #Hd1e2
+lapply (ldrop_trans_ge … HL0 … HL02 ?) -L0 // #HL2
+lapply (ltpss_sn_ldrop_trans_ge … HL1 … HL2 ?) -L // /2 width=1/
+qed.
+
+lemma thin_ldrop_trans_le: ∀L1,L0,d1,e1. ▼*[d1, e1] L1 ≡ L0 →
+                           ∀L2,e2. ⇩[0, e2] L0 ≡ L2 → e2 ≤ d1 →
+                           ∃∃L. ▼*[d1 - e2, e1] L ≡ L2 & ⇩[0, e2] L1 ≡ L.
+#L1 #L0 #d1 #e1 * #L #HL1 #HL0 #L2 #e2 #HL02 #He2d1
+elim (ldrop_trans_le … HL0 … HL02 He2d1) -L0 #L0 #HL0 #HL02
+elim (ltpss_sn_ldrop_trans_le … HL1 … HL0 He2d1) -L -He2d1 /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/tpr_delift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/delift/tpr_delift.etc
new file mode 100644 (file)
index 0000000..3fff8f2
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/delift.ma".
+include "basic_2/reducibility/ltpr_tpss.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON TERMS *********************************)
+
+(* Properties on inverse basic term relocation ******************************)
+
+lemma tpr_delift_conf: ∀U1,U2. U1 ➡ U2 → ∀L,T1,d,e. L ⊢ ▼*[d, e] U1 ≡ T1 →
+                       ∃∃T2. T1 ➡ T2 & L ⊢ ▼*[d, e] U2 ≡ T2.
+#U1 #U2 #HU12 #L #T1 #d #e * #W1 #HUW1 #HTW1
+elim (tpr_tpss_conf … HU12 … HUW1) -U1 #U1 #HWU1 #HU21
+elim (tpr_inv_lift1 … HWU1 … HTW1) -W1 /3 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/cpr_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/cpr_conj.etc
new file mode 100644 (file)
index 0000000..6ffdb54
--- /dev/null
@@ -0,0 +1,88 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpr_ldrop.ma".
+
+include "basic_2/unfold/fsups.ma".
+include "basic_2/reducibility/lpr_ldrop.ma".
+
+lamma pippo: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀V1,i. ⇧[i, 1] V1 ≡ T1 → T2 = #i → ⊥.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2
+[ #I #L1 #V #W1 #j #H1 #H2
+  elim (lift_inv_lref2 … H1) -H1 * #H1 #H3
+
+ HVT2 : ()
+ HV2 : (K2⊢V➡V2)
+
+
+thaorem cpr_trans_lpr: ∀L1,T1,T. L1 ⊢ T1 ➡ T → ∀L2. L1 ⊢ ➡ L2 →
+                       ∀T2. L2 ⊢ T ➡ T2 →
+                       (⦃L2, T2⦄ ⊃* ⦃L1, T1⦄ → ⊥) ∨ T1 = T.
+#L1 #T1 @(fsupp_wf_ind … L1 T1) -L1 -T1 #n #IH #L1 * [|*]
+[ #I #Hn #T #H1 #L2 #HL12 #T2 #HT2 destruct -IH
+  elim (cpr_inv_atom1 … H1) -H1
+  [ #H destruct
+    elim (cpr_inv_atom1 … HT2) -HT2
+    [ #H destruct //
+    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct //
+    ]
+  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
+    lapply (ldrop_pair2_fwd_fw … HLK1 (#i)) #HKV1
+    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
+    elim (lpr_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 #HLK2
+    elim (cpr_inv_lift1 … HT2 … HLK2 … HVT) -HT2 -HLK2 -HVT #V2 #HVT2 #HV2
+    @or_introl #H
+
+
+
+
+
+
+    elim (lift_inv_lref2 … HVT2) -HVT2 * #H #_
+    [ elim (lt_zero_false … H)
+    | >commutative_plus in H; >plus_plus_comm_23 #H
+      elim (le_plus_xySz_x_false … H)
+    ]
+  ]
+| #a #I #V1 #T1 #Hn #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpr_inv_bind1 … H1) -H1 *
+  [ #V #T #HV1 #HT1 #H destruct
+    elim (cpr_inv_bind1 … H2) -H2 *
+    [ #V2 #T2 #HV2 #HT2 #H destruct
+      elim (IH … HV1 … HV2) // #HV12 destruct
+      [ @or_introl #H destruct /2 width=1/
+      | elim (IH … HT1 … HT2) // /2 width=1/ -L1 -L2 #HT12 destruct
+        @or_introl #H destruct /2 width=1/
+      ]
+    | #T2 #HT2 #HXT2 #H1 #H2 destruct
+      elim (IH … HT1 … HT2) // /2 width=1/ -L1 -L2 #HT12 destruct
+      |        elim (term_eq_dec V1 V) #HV1 destruct
+
+    ]
+  | #Y1 #HTY1 #HXY1 #H11 #H12 destruct
+    elim (lift_total (+ⓓV1.T1) 0 1) #Y2 #HXY2
+    lapply (cpr_lift … H2 (L2.ⓓV1) … HXY1 … HXY2) /2 width=1/ -X1 /4 width=5/
+  ]
+| #I #V1 #T1 #Hn #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpr_inv_flat1 … H1) -H1 *
+  [ #V #T #HV1 #HT1 #H destruct
+    elim (cpr_inv_flat1 … H2) -H2 *
+    [ #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
+    | #HX2 #H destruct /3 width=5/
+    ]
+  | #HX1 #H destruct /3 width=5/
+]
+qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/etc/ldrop.etc
new file mode 100644 (file)
index 0000000..e4caef0
--- /dev/null
@@ -0,0 +1,11 @@
+lemma ldrop_bor1: ∀L1,L2,s1,s2,d,e. ⇩[s1, d, e] L1 ≡ L2 → ⇩[s1 ∨ s2, d, e] L1 ≡ L2.
+#L1 #L2 * /2 width=1 by ldrop_gen/
+qed.
+
+lemma ldrop_bor2: ∀L1,L2,s1,s2,d,e. ⇩[s2, d, e] L1 ≡ L2 → ⇩[s1 ∨ s2, d, e] L1 ≡ L2.
+#L1 #L2 #s1 #s2 >commutative_orb /2 width=1 by ldrop_bor1/
+qed.
+
+(* Basic_1: was: drop_conf_rev *)
+axiom ldrop_div: ∀e1,L1,L. ⇩[0, e1] L1 ≡ L → ∀e2,L2. ⇩[0, e2] L2 ≡ L →
+                 ∃∃L0. ⇩[0, e1] L0 ≡ L2 & ⇩[e1, e2] L0 ≡ L1.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbc_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbc_lift.etc
new file mode 100644 (file)
index 0000000..2862901
--- /dev/null
@@ -0,0 +1,9 @@
+include "basic_2/reduction/lpx_ldrop.ma".
+
+lemma lpx_fpbc_trans: ∀h,g,G1,G2,K1,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ →
+                      ⦃G1, K1⦄ ⊢ ➡[h, g] L1 →
+                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ≻[h, g] ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g] L2.
+#h #g #G1 #G2 #K1 #L1 #L2 #T1 #T2 * -G2 -L2 -T2
+[ #G2 #L2 #T2 #H12 #HKL1 elim (lpx_fqu_trans … H12 … HKL1) -L1
+  /3 width=5 by fpbc_fqu, ex3_2_intro/
+| #T2 #HT12 #H #HKL1  
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fleq/fpbs.etc
new file mode 100644 (file)
index 0000000..017421f
--- /dev/null
@@ -0,0 +1,49 @@
+lemma fpbs_fpbu_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                    ⦃G1, L1, T1⦄ ≡[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
+[ /2 width=1 by or_introl/
+| #G1 #G #L1 #L #T1 #T #H1 #_ * [ #H2 | * #G0 #L0 #T0 #H0 #H02 ]
+  elim (fpb_fpbu … H1) -H1 #H1
+  [ /3 width=1 by  
+*)
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim(fpbs_inv_alt … H) -H
+#L0 #L #T #HT1 #HT2 #HL0 #HL2 elim (eq_term_dec T1 T) #H destruct
+[ -HT1 elim (fqus_inv_gen … HT2) -HT2
+  [ #H elim (fqup_inv_step_sn … H) -H
+    /4 width=11 by fpbs_intro_alt, fpbu_fqu, ex2_3_intro, or_intror/
+  | * #HG #HL #HT destruct elim (lleq_dec T2 L0 L 0) #H
+    [ /4 width=3 by fleq_intro, lleq_trans, or_introl/
+    | elim (lpxs_nlleq_inv_step_sn … HL0 H) -HL0 -H
+      /5 width=7 by lpxs_lleq_fpbs, fpbu_lpx, lleq_trans, ex2_3_intro, or_intror/
+    ]
+  ]
+| elim (cpxs_neq_inv_step_sn … HT1 H) -HT1 -H
+  /5 width=11 by fpbs_intro_alt, fpbu_cpx, ex2_3_intro, or_intror/
+]
+qed-.
+
+(* alternative proof that needs decidability of bteq to go in fpbs.ma 
+ * or lpx_fpbc_trans to go in fpbs_lift.ma (possibly)  
+*)
+
+axiom lpx_bteq_trans: ∀h,g,G1,G2,L1,L,L2,T1,T2. ⦃G1, L1⦄ ⊢➡ [h, g] L →
+                      ⦃G1, L, T1⦄ ⋕[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⋕[h, g] ⦃G2, L2, T2⦄.
+
+lemma fpbs_fwd_fpb_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                       ⦃G1, L1, T1⦄ ⋕[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 @(fpbs_ind_dx … H) -G1 -L1 -T1 [ /2 width=1 by or_introl/ ] (**) (* auto fails without brackets *)
+#G1 #G #L1 #L #T1 #T *
+[ #G0 #L0 #T0 #H #H02 #IH1 elim (fquq_inv_gen … H) -H
+  [ -IH1 /4 width=5 by fpbc_fqu, ex2_3_intro, or_intror/
+  | -H02 * #HG #HL #HT destruct /2 width=1 by/
+  ]
+| #T0 #HT10 #H02 #IH02 elim (eq_term_dec T1 T0) #H destruct
+  [ -H02 /2 width=1 by/
+  | -IH02 /5 width=5 by fpbc_cpx, ex2_3_intro, or_intror/
+  ]
+| #L0 #HL10 #_ * [ /3 width=3 by or_introl, lpx_bteq_trans/ ]
+  * #G3 #L3 #T3 #H13 #H32
+
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa.etc
new file mode 100644 (file)
index 0000000..8f72937
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/rajust_5.ma".
+include "basic_2/substitution/drop.ma".
+
+(* AJUSTMENT ****************************************************************)
+
+inductive fpa (s:bool): bi_relation lenv term ≝
+| fpa_fwd: ∀L,K,T,U,d,e. ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U → fpa s K T L U
+| fpa_bwd: ∀L,K,T,U,d,e. ⇩[s, d, e] L ≡ K → ⇧[d, e] T ≡ U → fpa s L U K T
+.
+
+interpretation
+   "ajustment (restricted closure)"
+   'RAjust L1 T1 s L2 T2 = (fpa s L1 T1 L2 T2).
+
+(* Basic properties *********************************************************)
+
+lemma fpa_refl: ∀s. bi_reflexive … (fpa s).
+/2 width=4 by fpa_fwd/ qed.
+
+lemma fpa_sym: ∀s. bi_symmetric … (fpa s).
+#s #L1 #L2 #T1 #T2 * /2 width=4 by fpa_fwd, fpa_bwd/
+qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa_fpa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpa_fpa.etc
new file mode 100644 (file)
index 0000000..c62b8bf
--- /dev/null
@@ -0,0 +1,22 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fpa.ma".
+
+(* AJUSTMENT ****************************************************************)
+
+(* Main properties **********************************************************)
+
+theorem fpa_conf: ∀s. bi_confluent … (fpa s).
+/3 width=4 by fpa_sym, ex2_2_intro/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas.etc
new file mode 100644 (file)
index 0000000..6817d8c
--- /dev/null
@@ -0,0 +1,59 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/rajuststar_5.ma".
+include "basic_2/substitution/fpa.ma".
+
+(* MULTIPLE AJUSTMENT *******************************************************)
+
+definition fpas: bool → bi_relation lenv term ≝ λs. bi_TC … (fpa s).
+
+interpretation
+   "multiple ajustment (restricted closure)"
+   'RAjustStar L1 T1 s L2 T2 = (fpas s L1 T1 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma fpas_ind: ∀L1,T1,s. ∀R:relation2 …. R L1 T1 →
+                (∀L,L2,T,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳[s] ⦃L2, T2⦄ → R L T → R L2 T2) →
+                ∀L2,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ → R L2 T2.
+#L1 #T1 #s #R #IH1 #IH2 #L2 #T2 #H
+@(bi_TC_star_ind … IH1 IH2 L2 T2 H) //
+qed-.
+
+lemma fpas_ind_dx: ∀L2,T2,s. ∀R:relation2 …. R L2 T2 →
+                   (∀L1,L,T1,T. ⦃L1, T1⦄ ⇳[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ → R L T → R L1 T1) →
+                   ∀L1,T1. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ → R L1 T1.
+#L2 #T2 #s #R #IH1 #IH2 #L1 #T1 #H
+@(bi_TC_star_ind_dx … IH1 IH2 L1 T1 H) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma fpas_refl: ∀s. bi_reflexive … (fpas s).
+/2 width=1 by bi_inj/ qed.
+
+lemma fpas_sym: ∀s. bi_symmetric … (fpas s).
+/3 width=1 by fpa_sym, bi_TC_symmetric/ qed-.
+
+lemma fpa_fpas: ∀L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L2, T2⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
+/2 width=1 by bi_inj/ qed.
+
+lemma fpas_strap1: ∀L1,L,L2,T1,T,T2,s. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳[s] ⦃L2, T2⦄ →
+                   ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
+/2 width=4 by bi_step/ qed-.
+
+lemma fpas_strap2: ∀L1,L,L2,T1,T,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L, T⦄ → ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ →
+                   ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
+/2 width=4 by bi_TC_strap/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_fpas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_fpas.etc
new file mode 100644 (file)
index 0000000..28d648e
--- /dev/null
@@ -0,0 +1,40 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fpa_fpa.ma".
+include "basic_2/multiple/fpas.ma".
+
+(* MULTIPLE AJUSTMENT *******************************************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fpas_strip: ∀L0,L1,L2,T0,T1,T2,s. ⦃L0, T0⦄ ⇳[s] ⦃L1, T1⦄ → ⦃L0, T0⦄ ⇳*[s] ⦃L2, T2⦄ →
+                  ∃∃L,T. ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ & ⦃L2, T2⦄ ⇳[s] ⦃L, T⦄.
+/3 width=4 by fpa_conf, bi_TC_strip/ qed-.
+
+(* Main properties **********************************************************)
+
+theorem fpas_conf: ∀s. bi_confluent … (fpas s).
+/3 width=4 by fpa_conf, bi_TC_confluent/ qed-.
+
+theorem fpas_trans: ∀s. bi_transitive … (fpas s).
+/2 width=4 by bi_TC_transitive/ qed-.
+
+theorem fpas_canc_sn: ∀L,L1,L2,T,T1,T2,s.
+                      ⦃L, T⦄ ⇳*[s] ⦃L1, T1⦄→ ⦃L, T⦄ ⇳*[s] ⦃L2, T2⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
+/3 width=4 by fpas_trans, fpas_sym/ qed-.
+
+theorem fpas_canc_dx: ∀L1,L2,L,T1,T2,T,s.
+                      ⦃L1, T1⦄ ⇳*[s] ⦃L, T⦄ → ⦃L2, T2⦄ ⇳*[s] ⦃L, T⦄ → ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄.
+/3 width=4 by fpas_trans, fpas_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_vector.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/fpas_vector.etc
new file mode 100644 (file)
index 0000000..65e8190
--- /dev/null
@@ -0,0 +1,56 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/term_vector.ma".
+include "basic_2/multiple/fpas.ma".
+
+(* MULTIPLE VECTOR AJUSTMENT ************************************************)
+
+inductive fpasv (s:bool): bi_relation lenv (list term) ≝
+| fpasv_nil : ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄  → fpasv s L1 (◊) L2 (◊)
+| fpasv_cons: ∀L1,L2,T1s,T2s,T1,T2. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄  →
+              fpasv s L1 T1s L2 T2s →
+              fpasv s L1 (T1 @ T1s) L2 (T2 @ T2s)
+.
+
+interpretation
+   "multiple vector ajustment (restricted closure)"
+   'RAjustStar L1 T1s s L2 T2s = (fpasv s L1 T1s L2 T2s).
+
+(* Basic inversion lemmas ***************************************************)
+
+
+
+(* Basic_1: was just: lifts1_flat (left to right) *)
+lemma fpas_inv_applv1: ∀L1,L2,V1s,T1,X,s. ⦃L1, Ⓐ V1s.T1⦄ ⇳*[s] ⦃L2, X⦄ →
+                       ∃∃V2s,T2. ⦃L1, V1s⦄ ⇳*[s] ⦃L2, V2s⦄ & ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ &
+                                 X = Ⓐ V2s.T2.
+#L1 #L2 #V1s elim V1s -V1s
+[ #T1 #X #s #H
+  @(ex3_2_intro … (◊) X) /2 width=3 by fpasv_nil/ (**) (* explicit constructor *)
+| #V1 #V1s #IHV1s #T1 #X #s #H
+  elim (lifts_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
+  elim (IHV1s … HY) -IHV1s -HY #V2s #T2 #HV12s #HT12 #H destruct
+  @(ex3_2_intro) [4: // |3: /2 width=2 by liftsv_cons/ |1,2: skip | // ] (**) (* explicit constructor *)
+]
+qed-.
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was just: lifts1_flat (right to left) *)
+lemma lifts_applv: ∀V1s,V2s,des. ⇧*[des] V1s ≡ V2s →
+                   ∀T1,T2. ⇧*[des] T1 ≡ T2 →
+                   ⇧*[des] Ⓐ V1s. T1 ≡ Ⓐ V2s. T2.
+#V1s #V2s #des #H elim H -V1s -V2s /3 width=1 by lifts_flat/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp.etc
new file mode 100644 (file)
index 0000000..b9b2db8
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/genv.ma".
+include "basic_2/multiple/fpas.ma".
+
+(* GENERIC COMPUTATION PROPERTIES *******************************************)
+
+definition candidate: Type[0] ≝ relation3 genv lenv term.
+
+definition CP0 ≝ λRR:relation4 genv lenv term term. λRS:relation term.
+                 ∀G,L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳[s] ⦃L2, T2⦄ →
+                 NF … (RR G L1) RS T1 → NF … (RR G L2) RS T2.
+
+definition CP0s ≝ λRR:relation4 genv lenv term term. λRS:relation term.
+                  ∀G,L1,L2,T1,T2,s. ⦃L1, T1⦄ ⇳*[s] ⦃L2, T2⦄ →
+                  NF … (RR G L1) RS T1 → NF … (RR G L2) RS T2.
+
+definition CP1 ≝ λRR:relation4 genv lenv term term. λRS:relation term.
+                 ∀G,L. ∃k. NF … (RR G L) RS (⋆k).
+
+definition CP2 ≝ λRP:candidate.
+                 ∀G,L,T,k. RP G L (ⓐ⋆k.T) → RP G L T.
+
+(* requirements for generic computation properties *)
+record gcp (RR:relation4 genv lenv term term) (RS:relation term) (RP:candidate) : Prop ≝
+{ cp0: CP0 RR RS;
+  cp1: CP1 RR RS;
+  cp2: CP2 RP
+}.
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was just: nf2_lift1 *)
+lemma gcp_fpas: ∀RR,RS. CP0 RR RS → CP0s RR RS.
+#RR #RS #HRR #G #L1 #L2 #T1 #T2 #s #H @(fpas_ind … H) -L2 -T2 /3 width=5 by/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp_cr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/gcp_cr.etc
new file mode 100644 (file)
index 0000000..7649098
--- /dev/null
@@ -0,0 +1,185 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ineint_5.ma".
+include "basic_2/grammar/aarity.ma".
+include "basic_2/substitution/lift_vector.ma".
+include "basic_2/computation/gcp.ma".
+
+(* GENERIC COMPUTATION PROPERTIES *******************************************)
+
+definition S0 ≝ λC:candidate. ∀G,L1,L2,T1,T2. ⦃L1, T1⦄ ⇳[Ⓕ] ⦃L2, T2⦄ →
+                C G L1 T1 → C G L2 T2.
+
+definition S0s ≝ λC:candidate. ∀G,L1,L2,T1,T2. ⦃L1, T1⦄ ⇳*[Ⓕ] ⦃L2, T2⦄ →
+                 C G L1 T1 → C G L2 T2.
+
+(* Note: this is Girard's CR1 *)
+definition S1 ≝ λRP,C:candidate.
+                ∀G,L,T. C G L T → RP G L T.
+
+(* Note: this is Tait's iii, or Girard's CR4 *)
+definition S2 ≝ λRR:relation4 genv lenv term term. λRS:relation term. λRP,C:candidate.
+                ∀G,L,Vs. all … (RP G L) Vs →
+                ∀T. 𝐒⦃T⦄ → NF … (RR G L) RS T → C G L (ⒶVs.T).
+
+(* Note: this generalizes Tait's ii *)
+definition S3 ≝ λC:candidate.
+                ∀a,G,L,Vs,V,T,W.
+                C G L (ⒶVs.ⓓ{a}ⓝW.V.T) → C G L (ⒶVs.ⓐV.ⓛ{a}W.T).
+
+definition S4 ≝ λRP,C:candidate.
+                ∀G,L,Vs. all … (RP G L) Vs → ∀k. C G L (ⒶVs.⋆k).
+
+definition S5 ≝ λC:candidate. ∀I,G,L,K,Vs,V1,V2,i.
+                C G L (ⒶVs.V2) → ⇧[0, i+1] V1 ≡ V2 →
+                ⇩[i] L ≡ K.ⓑ{I}V1 → C G L (ⒶVs.#i).
+
+definition S6 ≝ λRP,C:candidate.
+                ∀G,L,V1s,V2s. ⇧[0, 1] V1s ≡ V2s →
+                ∀a,V,T. C G (L.ⓓV) (ⒶV2s.T) → RP G L V → C G L (ⒶV1s.ⓓ{a}V.T).
+
+definition S7 ≝ λC:candidate.
+                ∀G,L,Vs,T,W. C G L (ⒶVs.T) → C G L (ⒶVs.W) → C G L (ⒶVs.ⓝW.T).
+
+(* requirements for the generic reducibility candidate *)
+record gcr (RR:relation4 genv lenv term term) (RS:relation term) (RP,C:candidate) : Prop ≝
+{ s0: S0 C;
+  s1: S1 RP C;
+  s2: S2 RR RS RP C;
+  s3: S3 C;
+  s4: S4 RP C;
+  s5: S5 C;
+  s6: S6 RP C;
+  s7: S7 C
+}.
+
+(* the functional construction for candidates *)
+definition cfun: candidate → candidate → candidate ≝
+                 λC1,C2,G,K,T. ∀L,V,U. ⦃K, T⦄ ⇳*[Ⓕ] ⦃L, U⦄ →
+                 C1 G L V → C2 G L (ⓐV.U).
+
+(* the reducibility candidate associated to an atomic arity *)
+let rec acr (RP:candidate) (A:aarity) on A: candidate ≝
+match A with
+[ AAtom     ⇒ RP
+| APair B A ⇒ cfun (acr RP B) (acr RP A)
+].
+
+interpretation
+   "candidate of reducibility of an atomic arity (abstract)"
+   'InEInt RP G L T A = (acr RP A G L T).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was just: sc3_lift1 *)
+lemma gcr_fpas: ∀C. S0 C → S0s C.
+#C #HC #G #L1 #L2 #T1 #T2 #H @(fpas_ind … H) -L2 -T2 /3 width=5 by/
+qed.
+(*
+lemma rp_lifts: ∀RR,RS,RP. gcr RR RS RP RP →
+                ∀des,G,L0,L,V,V0. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] V ≡ V0 →
+                RP G L V → RP G L0 V0.
+#RR #RS #RP #HRP #des #G #L0 #L #V #V0 #HL0 #HV0 #HV
+@gcr_lifts /width=7 by/
+@(s0 … HRP)
+qed.
+
+(* Basic_1: was only: sns3_lifts1 *)
+lemma rp_liftsv_all: ∀RR,RS,RP. gcr RR RS RP RP →
+                     ∀des,G,L0,L,Vs,V0s. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] Vs ≡ V0s →
+                     all … (RP G L) Vs → all … (RP G L0) V0s.
+#RR #RS #RP #HRP #des #G #L0 #L #Vs #V0s #HL0 #H elim H -Vs -V0s normalize //
+#T1s #T2s #T1 #T2 #HT12 #_ #IHT2s * /3 width=7 by rp_lifts, conj/
+qed.
+*)
+(* Basic_1: was:
+   sc3_sn3 sc3_abst sc3_appl sc3_abbr sc3_bind sc3_cast sc3_lift
+*)
+lemma acr_gcr: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+               ∀A. gcr RR RS RP (acr RP A).
+#RR #RS #RP #H1RP #H2RP #A elim A -A //
+#B #A #IHB #IHA @mk_gcr
+[ /3 width=4 by fpas_strap2/
+| #G #L #T #H
+  elim (cp1 … H1RP G L) #k #HK
+  lapply (H L (⋆k) T ? ?) -H //
+  [ @(s2 … IHB … (◊)) //
+  | #H @(cp2 … H1RP … k) @(s1 … IHA) //
+  ]
+| #G #L #Vs #HVs #T #H1T #H2T #L0 #V0 #X #H #HB
+  elim (lifts_inv_applv1 … H) -H #V0s #T0 #HV0s #HT0 #H destruct
+  lapply (s1 … IHB … HB) #HV0
+  @(s2 … IHA … (V0 @ V0s))
+  /3 width=14 by rp_liftsv_all, gcp_lifts, cp0, lifts_simple_dx, conj/
+| #a #G #L #Vs #U #T #W #HA #L0 #V0 #X #des #HL0 #H #HB
+  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
+  elim (lifts_inv_flat1 … HY) -HY #U0 #X #HU0 #HX #H destruct
+  elim (lifts_inv_bind1 … HX) -HX #W0 #T0 #HW0 #HT0 #H destruct
+  @(s3 … IHA … (V0 @ V0s)) /5 width=6 by lifts_applv, lifts_flat, lifts_bind/
+| #G #L #Vs #HVs #k #L0 #V0 #X #des #HL0 #H #HB
+  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
+  >(lifts_inv_sort1 … HY) -Y
+  lapply (s1 … IHB … HB) #HV0
+  @(s4 … IHA … (V0 @ V0s)) /3 width=7 by rp_liftsv_all, conj/
+| #I #G #L #K #Vs #V1 #V2 #i #HA #HV12 #HLK #L0 #V0 #X #des #HL0 #H #HB
+  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
+  elim (lifts_inv_lref1 … HY) -HY #i0 #Hi0 #H destruct
+  elim (drops_drop_trans … HL0 … HLK) #X #des0 #i1 #HL02 #H #Hi1 #Hdes0
+  >(at_mono … Hi1 … Hi0) in HL02; -i1 #HL02
+  elim (drops_inv_skip2 … Hdes0 … H) -H -des0 #L2 #W1 #des0 #Hdes0 #HLK #HVW1 #H destruct
+  elim (lift_total W1 0 (i0 + 1)) #W2 #HW12
+  elim (lifts_lift_trans  … Hdes0 … HVW1 … HW12) // -Hdes0 -Hi0 #V3 #HV13 #HVW2
+  >(lift_mono … HV13 … HV12) in HVW2; -V3 #HVW2
+  @(s5 … IHA … (V0 @ V0s) … HW12 HL02) /3 width=5 by lifts_applv/
+| #G #L #V1s #V2s #HV12s #a #V #T #HA #HV #L0 #V10 #X #des #HL0 #H #HB
+  elim (lifts_inv_applv1 … H) -H #V10s #Y #HV10s #HY #H destruct
+  elim (lifts_inv_bind1 … HY) -HY #V0 #T0 #HV0 #HT0 #H destruct
+  elim (lift_total V10 0 1) #V20 #HV120
+  elim (liftv_total 0 1 V10s) #V20s #HV120s
+  @(s6 … IHA … (V10 @ V10s) (V20 @ V20s)) /3 width=7 by rp_lifts, liftv_cons/
+  @(HA … (des + 1)) /2 width=2 by drops_skip/
+  [ @lifts_applv //
+    elim (liftsv_liftv_trans_le … HV10s … HV120s) -V10s #V10s #HV10s #HV120s
+    >(liftv_mono … HV12s … HV10s) -V1s //
+  | @(s0 … IHB … HB … HV120) /2 width=2 by drop_drop/
+  ]
+| #G #L #Vs #T #W #HA #HW #L0 #V0 #X #des #HL0 #H #HB
+  elim (lifts_inv_applv1 … H) -H #V0s #Y #HV0s #HY #H destruct
+  elim (lifts_inv_flat1 … HY) -HY #W0 #T0 #HW0 #HT0 #H destruct
+  @(s7 … IHA … (V0 @ V0s)) /3 width=5 by lifts_applv/
+]
+qed.
+
+lemma acr_abst: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+                ∀a,G,L,W,T,A,B. ⦃G, L, W⦄ ϵ[RP] 〚B〛 → (
+                   ∀L0,V0,W0,T0,des. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] W ≡ W0 → ⇧*[des + 1] T ≡ T0 →
+                                   ⦃G, L0, V0⦄ ϵ[RP] 〚B〛 → ⦃G, L0, W0⦄ ϵ[RP] 〚B〛 → ⦃G, L0.ⓓⓝW0.V0, T0⦄ ϵ[RP] 〚A〛
+                ) →
+                ⦃G, L, ⓛ{a}W.T⦄ ϵ[RP] 〚②B.A〛.
+#RR #RS #RP #H1RP #H2RP #a #G #L #W #T #A #B #HW #HA #L0 #V0 #X #des #HL0 #H #HB
+lapply (acr_gcr … H1RP H2RP A) #HCA
+lapply (acr_gcr … H1RP H2RP B) #HCB
+elim (lifts_inv_bind1 … H) -H #W0 #T0 #HW0 #HT0 #H destruct
+lapply (gcr_lifts … HL0 … HW0 HW) -HW [ @(s0 … HCB) ] #HW0
+@(s3 … HCA … (◊))
+@(s6 … HCA … (◊) (◊)) //
+[ @(HA … HL0) //
+| lapply (s1 … HCB) -HCB #HCB
+  @(s7 … H2RP … (◊)) /2 width=1 by/
+]
+qed.
+
+(* Basic_1: removed theorems 2: sc3_arity_gen sc3_repl *)
+(* Basic_1: removed local theorems 1: sc3_sn3_abst *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajust_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajust_5.etc
new file mode 100644 (file)
index 0000000..ef0fbc4
--- /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( ⦃ term 46 L1, break term 46 T1 ⦄ ⇳ [ break term 46 s ] break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'RAjust $L1 $T1 $s $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajuststar_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpa/rajuststar_5.etc
new file mode 100644 (file)
index 0000000..7cf9191
--- /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( ⦃ term 46 L1, break term 46 T1 ⦄ ⇳ * [ break term 46 s ] break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'RAjustStar $L1 $T1 $s $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc.etc
new file mode 100644 (file)
index 0000000..9c803f0
--- /dev/null
@@ -0,0 +1,33 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazybtpredproper_8.ma".
+include "basic_2/multiple/fleq.ma".
+include "basic_2/reduction/fpbu.ma".
+
+(* "QRST" PROPER PARALLEL REDUCTION FOR CLOSURES ****************************)
+
+definition fpbc: ∀h. sd h → tri_relation genv lenv term ≝
+                 λh,g,G1,L1,T1,G2,L2,T2.
+                 ∃∃G,L,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ & ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄.
+
+interpretation
+   "'qrst' proper parallel reduction (closure)"
+   'LazyBTPRedProper h g G1 L1 T1 G2 L2 T2 = (fpbc h g G1 L1 T1 G2 L2 T2).
+
+(* Baic properties **********************************************************)
+
+lemma fpbu_fpbc: ∀h,g,G1,G2,L1,L2,T1,T2.
+                 ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄.
+/2 width=5 by ex2_3_intro/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc_fleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbc_fleq.etc
new file mode 100644 (file)
index 0000000..aa5cd7f
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/multiple/fleq_fleq.ma".
+include "basic_2/reduction/fpbu_fleq.ma".
+include "basic_2/reduction/fpbc.ma".
+
+(* "QRST" PROPER PARALLEL REDUCTION FOR CLOSURES ****************************)
+
+(* Properties on lazy equivalence on closures *******************************)
+
+lemma fpbc_fleq_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ →
+                       ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[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: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ≡[0] ⦃G, L, T⦄ →
+                       ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ≻≡[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/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg.etc
new file mode 100644 (file)
index 0000000..574c35e
--- /dev/null
@@ -0,0 +1,61 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazybtpredstarproper_8.ma".
+include "basic_2/reduction/fpbc.ma".
+
+(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
+
+definition fpbg: ∀h. sd h → tri_relation genv lenv term ≝
+                 λh,g. tri_TC … (fpbc h g).
+
+interpretation "'qrst' proper parallel computation (closure)"
+   'LazyBTPRedStarProper h g G1 L1 T1 G2 L2 T2 = (fpbg h g G1 L1 T1 G2 L2 T2).
+
+(* Basic properties *********************************************************)
+
+lemma fpbc_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ →
+                 ⦃G1, L1, T1⦄ >≡[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.
+                   ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ →
+                   ⦃G1, L1, T1⦄ >≡[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.
+                   ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
+                   ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
+/2 width=5 by tri_TC_strap/ qed.
+
+lemma fpbu_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h,g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
+/3 width=1 by fpbu_fpbc, fpbc_fpbg/ qed.
+
+(* Basic eliminators ********************************************************)
+
+lemma fpbg_ind: ∀h,g,G1,L1,T1. ∀R:relation3 ….
+                (∀G2,L2,T2. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
+                (∀G,G2,L,L2,T,T2. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
+                ∀G2,L2,T2. ⦃G1, L1, T1⦄ >≡[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 ….
+                   (∀G1,L1,T1. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1) →
+                   (∀G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≻≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
+                   ∀G1,L1,T1. ⦃G1, L1, T1⦄ >≡[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-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fleq.etc
new file mode 100644 (file)
index 0000000..754811e
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fpbc_fleq.ma".
+include "basic_2/computation/fpbg.ma".
+
+(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
+
+(* Properties on lazy equivalence for closures ******************************)
+
+lemma fpbg_fleq_trans: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ →
+                       ∀G2,L2,T2. ⦃G, L, T⦄ ≡[0] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[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: ∀h,g,G,G2,L,L2,T,T2. ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
+                       ∀G1,L1,T1. ⦃G1, L1, T1⦄ ≡[0] ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ >≡[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/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbg.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbg.etc
new file mode 100644 (file)
index 0000000..57dd5eb
--- /dev/null
@@ -0,0 +1,53 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fpbs_fpbu.ma".
+include "basic_2/computation/fpbs_fpbc.ma".
+include "basic_2/computation/fpbs_fpbs.ma".
+include "basic_2/computation/fpbg_fpbs.ma".
+
+(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpbg_inv_fpbu_sn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ >≡[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/
+| #G1 #G #L1 #L #T1 #T *
+  #G0 #L0 #T0 #H10 #H0 #_ *
+  /5 width=9 by fpbu_fpbs, fpbs_trans, fleq_fpbs, ex2_3_intro/
+]
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma fpbg_fwd_fpbs: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ >≡[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 *)
+/2 width=1 by fpbc_fpbs/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma fpbs_fpbu_trans: ∀h,g,F1,F2,K1,K2,T1,T2. ⦃F1, K1, T1⦄ ≥[h, g] ⦃F2, K2, T2⦄ →
+                       ∀G2,L2,U2. ⦃F2, K2, T2⦄ ≻[h, g] ⦃G2, L2, U2⦄ →
+                       ∃∃G1,L1,U1. ⦃F1, K1, T1⦄ ≻[h, g] ⦃G1, L1, U1⦄ & ⦃G1, L1, U1⦄ ≥[h, g] ⦃G2, L2, U2⦄.
+/5 width=5 by fpbg_inv_fpbu_sn, fpbs_fpbg_trans, fpbc_fpbg, fpbu_fpbc/ qed-.
+
+(* Man properties ***********************************************************)
+
+theorem fpbg_trans: ∀h,g. tri_transitive … (fpbg h g).
+/2 width=5 by tri_TC_transitive/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_fpbs.etc
new file mode 100644 (file)
index 0000000..4b86622
--- /dev/null
@@ -0,0 +1,88 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/lpxs_lleq.ma".
+include "basic_2/computation/fpbs_lift.ma".
+include "basic_2/computation/fpbg_fleq.ma".
+
+(* "QRST" PROPER PARALLEL COMPUTATION FOR CLOSURES **************************)
+
+(* Properties on "qrst" parallel reduction on closures **********************)
+
+lemma fpbg_fpb_trans: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2.
+                      ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                      ⦃G1, L1, T1⦄ >≡[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.
+                      ⦃G1, L1, T1⦄ ≽[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ →
+                      ⦃G1, L1, T1⦄ >≡[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-.
+
+(* Properties on "qrst" parallel compuutation on closures *******************)
+
+lemma fpbs_fpbg_trans: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G, L, T⦄ →
+                       ∀G2,L2,T2. ⦃G, L, T⦄ >≡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[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⦄ →
+                       ∀G1,L1,T1. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ >≡[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-.
+
+lemma fpbu_fpbs_fpbg: ∀h,g,G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G, L, T⦄ → 
+                      ∀G2,L2,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
+/3 width=5 by fpbg_fpbs_trans, fpbu_fpbg/ qed.
+
+(* Note: this is used in the closure proof *)
+lemma fqup_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊐+ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim (fqup_inv_step_sn … H) -H
+/3 width=5 by fqus_fpbs, fpbu_fqu, fpbu_fpbs_fpbg/
+qed.
+
+lemma cpxs_fpbg: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡*[h, g] T2 →
+                 (T1 = T2 → ⊥) → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
+#h #g #G #L #T1 #T2 #H #H0 elim (cpxs_neq_inv_step_sn … H … H0) -H -H0
+/4 width=5 by cpxs_fpbs, fpbu_cpx, fpbu_fpbs_fpbg/
+qed.
+
+lemma lstas_fpbg: ∀h,g,G,L,T1,T2,l2. ⦃G, L⦄ ⊢ T1 •*[h, l2] T2 → (T1 = T2 → ⊥) →
+                  ∀l1. l2 ≤ l1 → ⦃G, L⦄ ⊢ T1 ▪[h, g] l1 → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
+/3 width=5 by lstas_cpxs, cpxs_fpbg/ qed.
+
+lemma lpxs_fpbg: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
+                 (L1 ≡[T, 0] L2 → ⊥) → ⦃G, L1, T⦄ >≡[h, g] ⦃G, L2, T⦄.
+#h #g #G #L1 #L2 #T #H #H0 elim (lpxs_nlleq_inv_step_sn … H … H0) -H -H0
+/4 width=5 by fpbu_fpbs_fpbg, fpbu_lpx, lpxs_lleq_fpbs/
+qed.
+
+lemma fpbs_fpbg: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                 ⦃G1, L1, T1⦄ ≡[0] ⦃G2, L2, T2⦄ ∨
+                 ⦃G1, L1, T1⦄ >≡[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
+  [ /3 width=5 by fleq_trans, or_introl/
+  | /5 width=5 by fpbc_fpbg, fleq_fpbc_trans, fpbu_fpbc, or_intror/
+  | /3 width=5 by fpbg_fleq_trans, or_intror/
+  | /4 width=5 by fpbg_strap1, fpbu_fpbc, or_intror/
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbg_lift.etc
new file mode 100644 (file)
index 0000000..58ecd12
--- /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/fpbu_lift.ma".
+include "basic_2/computation/fpbg.ma".
+
+(* "QRST" PARALLEL COMPUTATION FOR CLOSURES *********************************)
+
+(* Advanced properties ******************************************************)
+
+lemma sta_fpbg: ∀h,g,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 ▪[h, g] l+1 →
+                ⦃G, L⦄ ⊢ T1 •*[h, 1] T2 → ⦃G, L, T1⦄ >≡[h, g] ⦃G, L, T2⦄.
+/4 width=2 by fpbu_fpbg, sta_fpbu/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbs_fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/fpbs_fpbc.etc
new file mode 100644 (file)
index 0000000..a88d519
--- /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/reduction/fpbc.ma".
+include "basic_2/computation/fpbs_fleq.ma".
+
+(* "QRST" PARALLEL COMPUTATION FOR CLOSURES *********************************)
+
+(* Properties on "qrst" proper parallel reduction for closures **************)
+
+lemma fpbc_fpbs: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻≡[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_fpb, fpbs_strap2, fleq_fpbs/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/lazybtpredproper_8.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpbc/lazybtpredproper_8.etc
new file mode 100644 (file)
index 0000000..6abdbeb
--- /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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≻≡ 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 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq.etc
new file mode 100644 (file)
index 0000000..c909e2e
--- /dev/null
@@ -0,0 +1,46 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/bteq_6.ma".
+include "basic_2/grammar/lenv_length.ma".
+include "basic_2/grammar/genv.ma".
+
+(* EQUIVALENT "BIG TREE" NORMAL FORMS ***************************************)
+
+definition bteq: tri_relation genv lenv term ≝
+                 λG1,L1,T1,G2,L2,T2.
+                 ∧∧ G1 = G2 & |L1| = |L2| & T1 = T2.
+
+interpretation
+   "equivalent 'big tree' normal forms (closure)"
+   'BTEq G1 L1 T1 G2 L2 T2 = (bteq G1 L1 T1 G2 L2 T2).
+
+(* Basic_properties *********************************************************)
+
+lemma bteq_refl: tri_reflexive … bteq.
+/2 width=1 by and3_intro/ qed.
+
+lemma bteq_sym: tri_symmetric … bteq.
+#G1 #G2 #L1 #L2 #T1 #T2 * //
+qed-.
+
+lemma bteq_dec: ∀G1,G2,L1,L2,T1,T2. Decidable (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄).
+#G1 #G2 #L1 #L2 #T1 #T2 elim (genv_eq_dec G1 G2)
+#H1G [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
+elim (eq_nat_dec (|L1|) (|L2|))
+#H1L [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
+elim (term_eq_dec T1 T2)
+#H1T [2: @or_intror * #H2G #H2L #H2T destruct /2 width=1 by/ ]
+/3 width=1 by and3_intro, or_introl/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_6.etc
new file mode 100644 (file)
index 0000000..5ee962f
--- /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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⋕ break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'BTEq $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_bteq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/bteq_bteq.etc
new file mode 100644 (file)
index 0000000..7870b26
--- /dev/null
@@ -0,0 +1,31 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/bteq.ma".
+
+(* EQUIVALENT "BIG TREE" NORMAL FORMS ***************************************)
+
+(* Main properties **********************************************************)
+
+theorem bteq_trans: tri_transitive … bteq.
+#G1 #G #L1 #L #T1 #T * //
+qed-.
+
+theorem bteq_canc_sn: ∀G,G1,G2,L,L1,L2,T,T1,T2. ⦃G, L, T⦄ ⋕ ⦃G1, L1, T1⦄ →
+                      ⦃G, L, T⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
+/3 width=5 by bteq_trans, bteq_sym/ qed-.
+
+theorem bteq_canc_dx: ∀G1,G2,G,L1,L2,L,T1,T2,T. ⦃G1, L1, T1⦄ ⋕ ⦃G, L, T⦄ →
+                      ⦃G2, L2, T2⦄ ⋕ ⦃G, L, T⦄ → ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
+/3 width=5 by bteq_trans, bteq_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/btpredsn_8.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/btpredsn_8.etc
new file mode 100644 (file)
index 0000000..0350d14
--- /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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⊢ ⋕ ➡ 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 @{ 'BTPRedSn $h $g $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpb.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpb.etc
new file mode 100644 (file)
index 0000000..e669834
--- /dev/null
@@ -0,0 +1,14 @@
+include "basic_2/reduction/fpn.ma".
+
+(* Basic forward lemmas *****************************************************)
+
+lemma fpb_bteq_fwd_fpn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                        ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=1 by and3_intro/
+[ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H
+  [ #H1 #H2 elim (fqu_fwd_bteq … H1 H2)
+  | * #HG #HL #HT #_ destruct //
+  ]
+| #T2 #HT12 * //
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbc.etc
new file mode 100644 (file)
index 0000000..1ed366c
--- /dev/null
@@ -0,0 +1,24 @@
+lemma fpb_fpbc_or_fpn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                       ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ ∨
+                       ⦃G1, L1, T1⦄ ⊢ ➡[h,g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2
+/3 width=1 by and3_intro, or_intror/
+[ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H [| * ]
+  /3 width=1 by fpbc_fqu, and3_intro, or_introl, or_intror/
+| #T2 #HT12 elim (eq_term_dec T1 T2) #H destruct
+  /4 width=1 by and3_intro, or_introl, or_intror, fpbc_cpx/
+]
+qed-.
+
+lemma fpb_fpbc: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) →
+                ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #H0 elim (fpb_fpbc_or_fpn … H) -H //
+#H elim H0 -H0 /2 width=3 by fpn_fwd_bteq/
+qed.
+
+lemma fpbc_fwd_bteq: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ →
+                     ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=8 by fqu_fwd_bteq/
+#T2 #_ #HT12 * /2 width=1 by/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbs_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpbs_conj.etc
new file mode 100644 (file)
index 0000000..8d0f137
--- /dev/null
@@ -0,0 +1,34 @@
+(*
+inclade "basic_2/computation/fpns.ma".
+inclade "basic_2/computation/fpbs.ma".
+inclade "basic_2/reduction/fpbc.ma".
+
+lemma fpn_dec: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+               Decidable (⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄).
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim (fpb_fpbc_or_fpn … H) -H /2 width=1 by or_introl/
+#H12 @or_intror
+#H @(fpbc_fwd_bteq … H12) -H12 @(fpn_fwd_bteq … H)
+qed-.
+*)
+(*
+lemma fpns_dec: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                Decidable (⦃G1, L1, T1⦄ ⊢ ➡*[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 #H #H2 *
+#H1 elim (fpn_dec … H2) -H2 #H2 /3 width=5 by fpns_strap1, or_introl/
+[ @or_intror #H12
+| @or_intror #H12 @H1 -H1
+*)
+(*
+inclade "basic_2/grammar/bteq_bteq.ma".
+inclade "basic_2/computation/fpns.ma".
+
+(* Advanced forward lemmas **************************************************)
+
+lemma fpbs_bteq_fwd_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                          ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpbs_ind … H) -G2 -L2 -T2 //
+#G #G2 #L #L2 #T #T2 #H1 #H2 #IH1 #H12 elim (bteq_dec G1 G L1 L T1 T)
+[ -H1 /4 width=10 by fpns_strap1, fpb_bteq_fwd_fpn, bteq_canc_sn/
+| -IH1 #H
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn.etc
new file mode 100644 (file)
index 0000000..406e6eb
--- /dev/null
@@ -0,0 +1,39 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/btpredsn_8.ma".
+include "basic_2/relocation/lleq.ma".
+include "basic_2/reduction/lpx.ma".
+
+(* REDUCTION FOR "BIG TREE" NORMAL FORMS ************************************)
+
+inductive fpn (h) (g) (G) (L1) (T): relation3 genv lenv term ≝
+| fpn_intro: ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → L1 ⋕[T] L2 → fpn h g G L1 T G L2 T
+.
+
+interpretation
+   "reduction for 'big tree' normal forms (closure)"
+   'BTPRedSn h g G1 L1 T1 G2 L2 T2 = (fpn h g G1 L1 T1 G2 L2 T2).
+
+(* Basic_properties *********************************************************)
+
+lemma fpn_refl: ∀h,g. tri_reflexive … (fpn h g).
+/2 width=1 by fpn_intro/ qed.
+
+(* Basic inversion lemmas ***************************************************) 
+
+lemma fpn_inv_gen: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ →
+                   ∧∧ G1 = G2 & ⦃G1, L1⦄ ⊢ ➡[h, g] L2 & L1 ⋕[T1] L2 & T1 = T2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=1 by and4_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn_fpn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpn_fpn.etc
new file mode 100644 (file)
index 0000000..adda4b5
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpx_lpx.ma".
+include "basic_2/reduction/fpn.ma".
+
+(* REDUCTION FOR "BIG TREE" NORMAL FORMS ************************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fpn_fqu_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
+                     ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
+                     ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
+#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
+#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqu_trans … H12 … HKL1 HV1) -L1
+/3 width=5 by fpn_intro, ex2_3_intro/
+qed-.
+
+lemma fpn_fquq_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
+                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
+                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃⸮ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
+#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
+#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fquq_trans … H12 … HKL1 HV1) -L1
+/3 width=5 by fpn_intro, ex2_3_intro/
+qed-.
+
+lemma fpn_fqup_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
+                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
+                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃+ ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
+#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
+#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqup_trans … H12 … HKL1 HV1) -L1
+/3 width=5 by fpn_intro, ex2_3_intro/
+qed-.
+
+lemma fpn_fqus_trans: ∀h,g,F1,G1,K1,L1,V1,T1. ⦃F1, K1, V1⦄ ⊢ ⋕➡[h, g] ⦃G1, L1, T1⦄ →
+                      ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
+                      ∃∃F2,K2,V2. ⦃F1, K1, V1⦄ ⊃* ⦃F2, K2, V2⦄ & ⦃F2, K2, V2⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄.
+#h #g #F1 #G1 #K1 #L1 #V1 #T1 * -G1 -L1 -T1
+#L1 #HKL1 #HV1 #G2 #L2 #T2 #H12 elim (lpx_lleq_fqus_trans … H12 … HKL1 HV1) -L1
+/3 width=5 by fpn_intro, ex2_3_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns.etc
new file mode 100644 (file)
index 0000000..0a208fe
--- /dev/null
@@ -0,0 +1,58 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/btpredsnstar_8.ma".
+include "basic_2/reduction/fpn.ma".
+
+(* COMPUTATION FOR "BIG TREE" NORMAL FORMS **********************************)
+
+definition fpns: ∀h. sd h → tri_relation genv lenv term ≝
+                 λh,g. tri_TC … (fpn h g).
+
+interpretation
+   "computation for 'big tree' normal forms (closure)"
+   'BTPRedSnStar h g G1 L1 T1 G2 L2 T2 = (fpns h g G1 L1 T1 G2 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma fpns_ind: ∀h,g,G1,L1,T1. ∀R:relation3 …. R G1 L1 T1 →
+                (∀G,G2,L,L2,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ → R G L T → R G2 L2 T2) →
+                ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2.
+#h #g #G1 #L1 #T1 #R #IH1 #IH2 #G2 #L2 #T2 #H
+lapply (tri_TC_star_ind … IH1 IH2 G2 L2 T2 H) //
+qed-.
+
+lemma fpns_ind_dx: ∀h,g,G2,L2,T2. ∀R:relation3 …. R G2 L2 T2 →
+                   (∀G1,G,L1,L,T1,T. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G, L, T⦄ → ⦃G, L, T⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G L T → R G1 L1 T1) →
+                   ∀G1,L1,T1. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → R G1 L1 T1.
+#h #g #G2 #L2 #T2 #R #IH1 #IH2 #G1 #L1 #T1 #H
+@(tri_TC_star_ind_dx … IH1 IH2 G1 L1 T1 H) //
+qed-.
+
+(* Basic_properties *********************************************************)
+
+lemma fpns_refl: ∀h,g. tri_reflexive … (fpns h g).
+/2 width=1 by tri_inj/ qed.
+
+lemma fpn_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ →
+                ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
+/2 width=1 by tri_inj/ qed.
+
+lemma fpns_strap1: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G, L, T⦄ →
+                   ⦃G, L, T⦄ ⊢ ⋕➡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
+/2 width=5 by tri_step/ qed-.
+
+lemma fpns_strap2: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡[h, g] ⦃G, L, T⦄ →
+                   ⦃G, L, T⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄.
+/2 width=5 by tri_TC_strap/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns_fpns.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fpns_fpns.etc
new file mode 100644 (file)
index 0000000..5aaea6a
--- /dev/null
@@ -0,0 +1,74 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lleq_lleq.ma".
+include "basic_2/computation/lpxs.ma".
+include "basic_2/computation/fpns.ma".
+
+(* COMPUTATION FOR "BIG TREE" NORMAL FORMS **********************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpns_inv_gen: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ⋕➡*[h, g] ⦃G2, L2, T2⦄ →
+                    ∧∧ G1 = G2 & ⦃G1, L1⦄ ⊢ ➡*[h, g] L2 & L1 ⋕[T1] L2 & T1 = T2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fpns_ind … H) -G2 -L2 -T2 /2 width=1 by and4_intro/
+#G #G2 #L #L2 #T #T2 #_ #H2 * #HG #HL1 #HT1 #HT destruct
+elim (fpn_inv_gen … H2) -H2 #HG #HL2 #HT #HT2 destruct
+/3 width=3 by lpxs_strap1, lleq_trans, and4_intro/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lpxs_lleq_fpns: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 → L1 ⋕[T] L2 →
+                      ⦃G, L1, T⦄ ⊢ ⋕➡*[h, g] ⦃G, L2, T⦄.
+#h #g #G #L1 #L2 #T #H @(lpxs_ind … H) -L2 //
+#L #L2 #HL1 #HL2 #IHL1 #HL12 elim (lleq_dec T L1 L) #HT
+[ -HL1 @fpns_strap1 [4: @IHL1 // |1,2,3: skip ]
+  /3 width=3 by fpn_intro, lleq_canc_sn/
+| -IHL1
+
+(* Main properties **********************************************************)
+
+theorem fpns_trans: tri_transitive … fqus.
+/2 width=5 by tri_TC_transitive/ qed-.
+
+
+(*
+lemma fpns_refl: ∀h,g. tri_reflexive … (fpns h g).
+/2 width=1 by and3_intro/ qed.
+
+lemma fpn_fpns: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄ →
+                ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * /3 width=1 by lpx_lpxs, and3_intro/
+qed.
+
+lemma fpns_strap1: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G, L, T⦄ →
+                   ⦃G, L, T⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 * #H1G #H1L #G1T *
+/3 width=3 by lpxs_strap1, and3_intro/
+qed-.
+
+lemma fpns_strap2: ∀h,g,G1,G,G2,L1,L,L2,T1,T,T2. ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G, L, T⦄ →
+                   ⦃G, L, T⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄.
+#h #g #G1 #G #G2 #L1 #L #L2 #T1 #T #T2 * #H1G #H1L #G1T *
+/3 width=3 by lpxs_strap2, and3_intro/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma fpns_fwd_bteq: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊢ ➡*[h, g] ⦃G2, L2, T2⦄ →
+                     ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 * /3 width=4 by lpxs_fwd_length, and3_intro/
+qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fqu.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fqu.etc
new file mode 100644 (file)
index 0000000..1e4defb
--- /dev/null
@@ -0,0 +1,14 @@
+include "basic_2/grammar/bteq.ma".
+
+lemma fqu_fwd_bteq: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
+                    ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+[ #I #G #L #V * #_ #H elim (plus_xSy_x_false … H)
+| #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_x … H)
+| #a #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_y … H)
+| #I #G #L #V #T * #_ #_ #H elim (discr_tpair_xy_y … H)
+| #G #L #K #T #U #e #HLK #_ * #_ #H
+  lapply (ldrop_fwd_length_lt4 … HLK ?) // >H -L #H
+  elim (lt_refl_false … H)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb.etc
new file mode 100644 (file)
index 0000000..3cd6861
--- /dev/null
@@ -0,0 +1,12 @@
+(* Basic eliminators ********************************************************)
+
+theorem fsb_ind_alt: ∀h,g. ∀R: relation3 …. (
+                        ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥[h,g] T1 → (
+                           ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                           (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → R G2 L2 T2
+                        ) → R G1 L1 T1
+                     ) →
+                     ∀G,L,T. ⦃G, L⦄ ⊢ ⦥[h, g] T → R G L T.
+#h #g #R #IH #G #L #T #H elim H -G -L -T
+/5 width=1 by fpb_fpbc, fsb_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/fsb_alt.etc
new file mode 100644 (file)
index 0000000..8c69a00
--- /dev/null
@@ -0,0 +1,105 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/btsnalt_5.ma".
+include "basic_2/computation/fpbs_fpbs.ma".
+include "basic_2/computation/fsb.ma".
+
+(* "BIG TREE" STRONGLY NORMALIZING TERMS ************************************)
+
+(* Note: alternative definition of fsb *)
+inductive fsba (h) (g): relation3 genv lenv term ≝
+| fsba_intro: ∀G1,L1,T1. (
+                 ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                 (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → fsba h g G2 L2 T2
+              ) → fsba h g G1 L1 T1.
+
+interpretation
+   "'big tree' strong normalization (closure) alternative"
+   'BTSNAlt h g G L T = (fsba h g G L T).
+
+(* Basic eliminators ********************************************************)
+
+theorem fsba_ind_alt: ∀h,g. ∀R: relation3 …. (
+                         ∀G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥⦥[h,g] T1 → (
+                            ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                            (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → R G2 L2 T2
+                         ) → R G1 L1 T1
+                      ) →
+                      ∀G,L,T. ⦃G, L⦄ ⊢ ⦥⦥[h, g] T → R G L T.
+#h #g #R #IH #G #L #T #H elim H -G -L -T
+/5 width=1 by fsba_intro/
+qed-.
+
+(* Basic_properties *********************************************************)
+
+fact fsba_intro_aux: ∀h,g,G1,L1,T1. (
+                        ∀G,G2,L,L2,T,T2. ⦃G, L, T⦄ ≥[h, g] ⦃G2, L2, T2⦄ →
+                        ⦃G1, L1, T1⦄ ⋕ ⦃G, L, T⦄ →
+                        (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → fsba h g G2 L2 T2
+                     ) → fsba h g G1 L1 T1.
+/4 width=5 by fsba_intro/ qed-.
+
+lemma fsba_fpbs_trans: ∀h,g,G1,L1,T1. ⦃G1, L1⦄ ⊢ ⦥⦥[h, g] T1 →
+                       ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≥[h, g] ⦃G2, L2, T2⦄ → ⦃G2, L2⦄ ⊢ ⦥⦥[h, g] T2.
+#h #g #G1 #L1 #T1 #H @(fsba_ind_alt … H) -G1 -L1 -T1
+#G1 #L1 #T1 #H0 #IH0 #G #L #T #H1 @fsba_intro
+#G2 #L2 #T2 #H2 #_ lapply (fpbs_trans … H1 … H2) -G -L -T
+#H12 elim (bteq_dec G1 G2 L1 L2 T1 T2) /3 width=6 by fpb_fpbs/
+-IH0 #H212 
+
+ -H0 -H #H @(IH0 … H) -IH0 -H // @(fpbs_trans … H1 … H2)    
+
+lemma fsba_intro_fpb: ∀h,g,G1,L1,T1. (
+                         ∀G2,L2,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
+                         (⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⊥) → ⦃G2, L2⦄ ⊢ ⦥⦥[h, g] T2
+                      ) → ⦃G1, L1⦄ ⊢ ⦥⦥[h, g] T1.
+#h #g #G1 #L1 #T1 #IH1 @fsba_intro_aux
+#G #G2 #L #L2 #T #T2 #H @(fpbs_ind_dx … H) -G -L -T
+[ #H1 #H2 -IH1 elim H2 -H2 //
+| #G0 #G #L0 #L #T0 #T #H10 #H12 #IH2 #H210 #H212 elim (bteq_dec G1 G L1 L T1 T) 
+  [ -IH1 -H210 -H10 -H12 /3 width=1 by/
+  | -IH2 -H212 #H21 lapply (IH1 … H21) -IH1 -H21
+    [
+    | -H10 -H210 #H 
+(*
+(* Main inversion lemmas ****************************************************)
+
+theorem fsba_inv_fsb: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⦥⦥[h, g] T → ⦃G, L⦄ ⊢ ⦥[h, g] T.
+#h #g #G #L #T #H elim H -G -L -T
+/5 width=12 by fsb_intro, fpb_fpbs, fpbc_fwd_fpb, fpbc_fwd_gen/
+qed-.
+
+(* Main properties **********************************************************)
+
+theorem fsb_fsba: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⦥[h, g] T → ⦃G, L⦄ ⊢ ⦥⦥[h, g] T.
+#h #g #G #L #T #H @(fsb_ind_alt … H) -G -L -T
+/4 width=1 by fsba_intro_fpb/
+qed.
+(*
+| fsba_intro: ∀G1,L1,T1. (
+                ∀G2,L2,T2.  ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → fsb h g G2 L2 T2
+              ) → fsb h g G1 L1 T1
+.
+
+
+
+(****************************************************************************)
+
+include "basic_2/substitution/fqup.ma".
+
+lemma fsb_csx: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ⦃G, L⦄ ⊢ ⦥[h, g] T.
+#h #g #G #L #T #H @(csx_ind … H) -T
+*)*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/lazyeq_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpn/lazyeq_6.etc
new file mode 100644 (file)
index 0000000..105a473
--- /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( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ⋕ break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'LazyEq $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr.etc
new file mode 100644 (file)
index 0000000..f58a52c
--- /dev/null
@@ -0,0 +1,59 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break ⦃ term 46 L1, break term 46 T1 ⦄ ➡ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRed $L $L1 $T1 $L2 $T2 }.
+
+include "basic_2/reducibility/cpr.ma".
+include "basic_2/reducibility/fpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
+
+definition cfpr: lenv → bi_relation lenv term ≝
+                 λL,L1,T1,L2,T2. |L1| = |L2| ∧ L ⊢ L1 @@ T1 ➡ L2 @@ T2.
+
+interpretation
+   "context-sensitive parallel reduction (closure)"
+   'FocalizedPRed L L1 T1 L2 T2 = (cfpr L L1 T1 L2 T2).
+
+(* Basic properties *********************************************************)
+
+lemma cfpr_refl: ∀L. bi_reflexive … (cfpr L).
+/2 width=1/ qed.
+
+lemma fpr_cfpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⋆ ⊢ ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 * /3 width=1/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma cfpr_inv_atom1: ∀L,L2,T1,T2. L ⊢ ⦃⋆, T1⦄ ➡ ⦃L2, T2⦄ → L ⊢ T1 ➡ T2 ∧ L2 = ⋆.
+#L #L2 #T1 #T2 * #H >(length_inv_zero_sn … H) /2 width=1/
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpr_inv_pair1_sn: ∀I,K1,L2,V1,T1,T2. ⦃⋆.ⓑ{I}V1@@K1, T1⦄ ➡ ⦃L2, T2⦄ →
+                        ∃∃K2,V2. V1 ➡ V2 &
+                                 ⋆.ⓑ{I}V2 ⊢ ⦃K1, T1⦄ ➡ ⦃K2, T2⦄  &
+                                 L2 = ⋆.ⓑ{I}V2@@K2.
+#I1 #K1 #L2 #V1 #T1 #T2 * >append_length #H
+elim (length_inv_pos_sn_append … H) -H #I2 #K2 #V2 #HK12 #H destruct
+>shift_append_assoc >shift_append_assoc normalize in ⊢ (%→?); #H
+elim (tpr_inv_bind1 … H) -H *
+[ #V0 #T #T0 #HV10 #HT1 #HT0 #H destruct /5 width=5/
+| #T0 #_ #_ #H destruct
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_aaa.etc
new file mode 100644 (file)
index 0000000..72802e4
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_aaa.ma".
+include "basic_2/reducibility/cfpr_cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_fpr_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                    ∀L2,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → L2 ⊢ T2 ⁝ A.
+#L1 #T1 #A #HT1 #L2 #T2 #H
+elim (fpr_inv_all … H) -H
+/4 width=5 by aaa_cpr_conf, aaa_ltpr_conf, aaa_ltpss_sn_conf/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cfpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cfpr.etc
new file mode 100644 (file)
index 0000000..f442be2
--- /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/reducibility/cpr_cpr.ma".
+include "basic_2/reducibility/cfpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
+
+(* Main properties **********************************************************)
+
+theorem cfpr_conf: ∀L. bi_confluent … (cfpr L).
+#L #L0 #L1 #T0 #T1 * #HL01 #HT01 #L2 #T2 * >HL01 #HL12 #HT02
+elim (cpr_conf … HT01 HT02) -L0 -T0 #X #H1 #H2
+elim (cpr_fwd_shift1 … H1) #L0 #T0 #HL10 #H destruct /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_cpr.etc
new file mode 100644 (file)
index 0000000..a1e20a0
--- /dev/null
@@ -0,0 +1,64 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_tpss.ma".
+include "basic_2/reducibility/cpr_cpr.ma".
+include "basic_2/reducibility/cfpr_ltpss.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fpr_all: ∀L1,L. L1 ➡ L → ∀L2,T1,T2. L ⊢ T1 ➡ T2 →
+               L ⊢ ▶* [0, |L|] L2 → ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
+#L1 #L #H elim H -L1 -L
+[ #L2 #T1 #T2 #HT12 #HL2
+  lapply (ltpss_sn_inv_atom1 … HL2) -HL2 #H destruct
+  lapply (cpr_inv_atom … HT12) -HT12 /2 width=1/
+| #I #L1 #L #V1 #V #_ #HV1 #IH #X #T1 #T2 #HT12 #H
+  elim (ltpss_sn_inv_tpss21 … H ?) -H // <minus_plus_m_m #L2 #V2 #HL2 #HV2 #H destruct
+  lapply (cpr_bind_dx false … HV1 HT12) -HV1 -HT12 #HT12
+  lapply (cpr_tpss_trans … HT12 (-ⓑ{I}V2.T2) 0 (|L|) ?) -HT12 /2 width=1/ -HV2 /3 width=1/
+]
+qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cfpr_inv_all: ∀L1,L2,L0,T1,T2. L0 ⊢ ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ →
+                    ∃∃L. L0 @@ L1 ➡ L0 @@ L & L0 @@ L ⊢ T1 ➡ T2 &
+                         L0 @@ L ⊢ ▶* [0, |L0| + |L|] L0 @@ L2.
+#L1 @(lenv_ind_dx … L1) -L1
+[ #L2 #L0 #T1 #T2 #H
+  elim (cfpr_inv_atom1 … H) -H #HT12 #H destruct /3 width=4/
+| #I #L1 #V1 #IH #X #L0 #T1 #T2 #H
+  elim (cfpr_inv_pair1 … H) -H #L2 #V #V2 #HV1 #HV2 #HT12 #H destruct
+  elim (IH … HT12) -IH -HT12 #L #HL1 #HT12 #HL2
+  elim (ltpr_inv_append1 … HL1) -HL1 #X #Y #HX #HY #H
+  lapply (ltpr_fwd_length … HX) -HX #HX
+  elim (append_inj_dx … H ?) -H // -HX #_ #H destruct -X
+  lapply (ltpss_sn_fwd_length … HL2) >append_length >append_length #H
+  lapply (injective_plus_r … H) -H #H
+  @(ex3_intro … (⋆.ⓑ{I}V@@Y)) <append_assoc // -HT12
+  <append_assoc [ /3 width=1/ ] -HV1 -HY
+  >append_length <associative_plus
+  @(ltpss_sn_dx_trans_eq … HL2) -HL2 >H -H >commutative_plus /3 width=1/
+]
+qed-.
+
+lemma fpr_inv_all: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ →
+                   ∃∃L. L1 ➡ L & L ⊢ T1 ➡ T2 & L ⊢ ▶* [0, |L|] L2.
+#L1 #L2 #T1 #T2 #H
+lapply (fpr_cfpr … H) -H #H
+elim (cfpr_inv_all … H) -H /2 width=4/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/cfpr_ltpss.etc
new file mode 100644 (file)
index 0000000..66e102e
--- /dev/null
@@ -0,0 +1,39 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cpr_lift.ma".
+include "basic_2/reducibility/cpr_ltpss_sn.ma".
+include "basic_2/reducibility/cfpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION ON CLOSURES *************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cfpr_inv_pair1: ∀I,L,K1,L2,V1,T1,T2. L ⊢ ⦃⋆.ⓑ{I}V1@@K1, T1⦄ ➡ ⦃L2, T2⦄ →
+                      ∃∃K2,V,V2. V1 ➡ V & L ⊢ V ▶* [0, |L|] V2 &
+                                 L.ⓑ{I}V ⊢ ⦃K1, T1⦄ ➡ ⦃K2, T2⦄  &
+                                 L2 = ⋆.ⓑ{I}V2@@K2.
+* #L #K1 #L2 #V1 #T1 #T2 * >append_length #H
+elim (length_inv_pos_sn_append … H) -H #I2 #K2 #V2 #HK12 #H destruct
+>shift_append_assoc >shift_append_assoc normalize in ⊢ (??%%→?); #H
+[ elim (cpr_inv_abbr1 … H) -H *
+  [ #V #V0 #T0 #HV1 #HV0 #HT10 #H destruct /3 width=7/
+  | #T0 #_ #_ #H destruct
+  ]
+| elim (cpr_inv_abst1 … H Abst V2) -H
+  #V #T * #V0 #HV10 #HV0 #HT1 #H destruct
+  lapply (ltpss_sn_cpr_trans (L.ⓛV0) … 0 (|L|+1) … HT1) -HT1 /2 width=1/ #HT12
+  /3 width=7/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc.etc
new file mode 100644 (file)
index 0000000..ee36247
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConv $L1 $T1 $L2 $T2 }.
+
+notation "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ ⬌ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConvAlt $L1 $T1 $L2 $T2 }.
+
+include "basic_2/reducibility/fpr.ma".
+
+(* CONTEXT-FREE PARALLEL CONVERSION ON CLOSURES *****************************)
+
+definition fpc: bi_relation lenv term ≝
+   λL1,T1,L2,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ ∨ ⦃L2, T2⦄ ➡ ⦃L1, T1⦄.
+
+interpretation
+   "context-free parallel conversion (closure)"
+   'FocalizedPConv L1 T1 L2 T2 = (fpc L1 T1 L2 T2).
+
+(* Basic properties *********************************************************)
+
+lemma fpc_refl: bi_reflexive … fpc.
+/2 width=1/ qed.
+
+lemma fpc_sym: bi_symmetric … fpc.
+#L1 #L2 #T1 #T2 * /2 width=1/
+qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma fpc_fwd_fpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌ ⦃L2, T2⦄ →
+                   ∃∃L,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ & ⦃L2, T2⦄ ➡ ⦃L, T⦄.
+#L1 #L2 #T1 #T2 * /2 width=4/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc_fpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpc_fpc.etc
new file mode 100644 (file)
index 0000000..22fc16f
--- /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/conversion/fpc.ma".
+
+(* CONTEXT-FREE PARALLEL CONVERSION ON CLOSURES *****************************)
+
+(* Main properties **********************************************************)
+
+theorem fpc_conf: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ⬌ ⦃L1, T1⦄ →
+                  ∀L2,T2. ⦃L0, T0⦄ ⬌ ⦃L2, T2⦄ →
+                  ∃∃L,T. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ & ⦃L2, T2⦄ ⬌ ⦃L, T⦄.
+/3 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs.etc
new file mode 100644 (file)
index 0000000..68c946c
--- /dev/null
@@ -0,0 +1,84 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConvStar $L1 $T1 $L2 $T2 }.
+
+notation "hvbox( ⦃ term 46 L1 , break term 46 T1 ⦄ ⬌ ⬌ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConvStarAlt $L1 $T1 $L2 $T2 }.
+
+include "basic_2/conversion/fpc.ma".
+
+(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
+
+definition fpcs: bi_relation lenv term ≝ bi_TC … fpc.
+
+interpretation "context-free parallel equivalence (closure)"
+   'FocalizedPConvStar L1 T1 L2 T2 = (fpcs L1 T1 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma fpcs_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
+                (∀L,L2,T,T2. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L, T⦄ ⬌ ⦃L2, T2⦄ → R L T → R L2 T2) →
+                ∀L2,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → R L2 T2.
+/3 width=7 by bi_TC_star_ind/ qed-.
+
+lemma fpcs_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
+                   (∀L1,L,T1,T. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → R L T → R L1 T1) →
+                   ∀L1,T1. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → R L1 T1.
+/3 width=7 by bi_TC_star_ind_dx/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma fpcs_refl: bi_reflexive … fpcs.
+/2 width=1/ qed.
+
+lemma fpcs_sym: bi_symmetric … fpcs.
+/3 width=1/ qed.
+
+lemma fpc_fpcs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/2 width=1/ qed.
+
+lemma fpcs_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L, T⦄ ⬌ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma fpcs_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⬌ ⦃L, T⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma fpcs_fpr_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=1/ qed.
+
+lemma fpcs_fpr_sn: ∀L1,L2,T1,T2. ⦃L2, T2⦄ ➡ ⦃L1, T1⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=1/ qed.
+
+lemma fpcs_fpr_strap1: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ →
+                       ∀L2,T2. ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4/ qed.
+
+lemma fpcs_fpr_strap2: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ →
+                       ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4/ qed.
+
+lemma fpcs_fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ →
+                    ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4/ qed.
+
+lemma fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4/ qed-.
+
+lemma fpcs_fpr_conf: ∀L1,L,T1,T. ⦃L, T⦄ ➡ ⦃L1, T1⦄ →
+                     ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_aaa.etc
new file mode 100644 (file)
index 0000000..9f4327b
--- /dev/null
@@ -0,0 +1,30 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fprs_aaa.ma".
+include "basic_2/equivalence/fpcs_fpcs.ma".
+
+(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
+
+(* Main properties about atomic arity assignment on terms *******************)
+
+theorem aaa_fpcs_mono: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ →
+                       ∀A1. L1 ⊢ T1 ⁝ A1 → ∀A2. L2 ⊢ T2 ⁝ A2 →
+                       A1 = A2.
+#L1 #L2 #T1 #T2 #H12 #A1 #HT1 #A2 #HT2
+elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
+lapply (aaa_fprs_conf … HT1 … H1) -L1 -T1 #HT1
+lapply (aaa_fprs_conf … HT2 … H2) -L2 -T2 #HT2
+lapply (aaa_mono … HT1 … HT2) -L -T //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_cpcs.etc
new file mode 100644 (file)
index 0000000..b1288f7
--- /dev/null
@@ -0,0 +1,86 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fprs_cprs.ma".
+include "basic_2/equivalence/cpcs_cpcs.ma".
+include "basic_2/equivalence/fpcs_fpcs.ma".
+
+(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fpcs_flat_dx_tpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
+                        ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ⬌* ⦃L2, ⓕ{I}V2.T2⦄.
+#L1 #L2 #T1 #T2 #HT12
+elim (fpcs_inv_fprs … HT12) -HT12
+/3 width=6 by fprs_flat_dx_tpr, fprs_div/ (**) (* auto too slow without trace *)
+qed.
+
+lemma fpcs_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄ →
+                  ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄.
+#I #L1 #L2 #V1 #V2 #T1 #T2 #H12
+elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
+elim (fprs_bind2_minus … H1) -H1 #W1 #U1 #HTU1 #H destruct
+elim (fprs_bind2_minus … H2) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
+qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpcs_inv_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄ →
+                      ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄.
+#I #L1 #L2 #V1 #V2 #T1 #T2 #H12
+elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
+elim (fprs_inv_pair1 … H1) -H1 #K1 #U1 #_ #HTU1 #H destruct
+elim (fprs_inv_pair1 … H2) -H2 #K2 #U2 #_ #HTU2 #H destruct /2 width=4/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma fpcs_fwd_bind_minus: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1, -ⓑ{I}V1.T1⦄ ⬌* ⦃L2, -ⓑ{I}V2.T2⦄ →
+                           ∀b. ⦃L1, ⓑ{b,I}V1.T1⦄ ⬌* ⦃L2, ⓑ{b,I}V2.T2⦄.
+#I #L1 #L2 #V1 #V2 #T1 #T2 #H12 #b
+elim (fpcs_inv_fprs … H12) -H12 #L #T #H1 #H2
+elim (fprs_fwd_bind2_minus … H1 b) -H1 #W1 #U1 #HTU1 #H destruct
+elim (fprs_fwd_bind2_minus … H2 b) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
+qed-.
+
+lemma fpcs_fwd_shift: ∀I,L1,L2,V1,V2,T1,T2. ⦃L1.ⓑ{I}V1, T1⦄ ⬌* ⦃L2.ⓑ{I}V2, T2⦄ →
+                      ∀b. ⦃L1, ⓑ{b,I}V1.T1⦄ ⬌* ⦃L2, ⓑ{b,I}V2.T2⦄.
+/3 width=1 by fpcs_inv_shift, fpcs_fwd_bind_minus/ qed-.
+
+lemma fpcs_fwd_abst24: ∀a,L1,L2,V1,V2,T1,T2. ⦃L1, ⓛ{a}V1.T1⦄ ⬌* ⦃L2, ⓛ{a}V2.T2⦄ →
+                       ∀b,I,W. ⦃L1, ⓑ{b,I}W.T1⦄ ⬌* ⦃L2, ⓑ{b,I}W.T2⦄.
+#a #L1 #L2 #V1 #V2 #T1 #T2 #H12 #b #I #W
+elim (fpcs_inv_fprs … H12) -H12 #L #U #H1 #H2
+elim (fprs_fwd_abst2 … H1 b I W) -H1 #W1 #U1 #HTU1 #H destruct
+elim (fprs_fwd_abst2 … H2 b I W) -H2 #W2 #U2 #HTU2 #H destruct /2 width=4/
+qed-.
+
+lemma fpcs_fwd_abst13: ∀L1,L2,V1,V2,T1,T2. ⦃L1.ⓛV1, T1⦄ ⬌* ⦃L2.ⓛV2, T2⦄ →
+                       ∀I,W. ⦃L1.ⓑ{I}W, T1⦄ ⬌* ⦃L2.ⓑ{I}W, T2⦄.
+/4 width=4 by fpcs_fwd_shift, fpcs_fwd_abst24, fpcs_shift/ qed-.
+
+(* Properties on context-sensitive parallel equivalence for terms ***********)
+
+lemma cpcs_fpcs: ∀L,T1,T2. L ⊢ T1 ⬌* T2 → ⦃L, T1⦄ ⬌* ⦃L, T2⦄.
+#L #T1 #T2 #H
+elim (cpcs_inv_cprs … H) -H /3 width=4 by fprs_div, cprs_fprs/ (**) (* too slow without trace *)
+qed.
+
+(* Inversion lemmas on context-sensitive parallel equivalence for terms *****)
+
+lemma fpcs_inv_cpcs: ∀L,T1,T2. ⦃L, T1⦄ ⬌* ⦃L, T2⦄ → L ⊢ T1 ⬌* T2.
+#L #T1 #T2 #H
+elim (fpcs_inv_fprs … H) -H /3 width=4 by cprs_div, fprs_fwd_cprs/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fpcs.etc
new file mode 100644 (file)
index 0000000..270e8dc
--- /dev/null
@@ -0,0 +1,66 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fprs_fprs.ma".
+include "basic_2/conversion/fpc_fpc.ma".
+include "basic_2/equivalence/fpcs_fprs.ma".
+
+(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpcs_inv_fprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ →
+                     ∃∃L,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ & ⦃L2, T2⦄ ➡* ⦃L, T⦄.
+#L1 #L2 #T1 #T2 #H @(fpcs_ind … H) -L2 -T2
+[ /3 width=4/
+| #L #L2 #T #T2 #_ #HT2 * #L0 #T0 #HT10 elim HT2 -HT2 #HT2 #HT0
+  [ elim (fprs_strip … HT2 … HT0) -L -T #L #T #HT2 #HT0
+    lapply (fprs_strap1 … HT10 … HT0) -L0 -T0 /2 width=4/
+  | lapply (fprs_strap2 … HT2 … HT0) -L -T /2 width=4/
+  ]
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma fpr_fprs_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
+elim (fprs_strip … HT2 … HT1) /2 width=4 by fpr_fprs_div/
+qed-.
+
+lemma fprs_fpr_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → ⦃L2, T2⦄ ⬌* ⦃L1, T1⦄.
+#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
+elim (fprs_strip … HT2 … HT1) /2 width=4 by fprs_fpr_div/
+qed-.
+
+lemma fprs_conf: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L #L1 #L2 #T #T1 #T2 #HT1 #HT2
+elim (fprs_conf … HT1 … HT2) /2 width=4/
+qed-.
+
+lemma fpcs_strip: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ⬌ ⦃L1, T1⦄ →
+                  ∀L2,T2. ⦃L0, T0⦄ ⬌* ⦃L2, T2⦄ →
+                  ∃∃L,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ & ⦃L2, T2⦄ ⬌ ⦃L, T⦄.
+/3 width=4/ qed.
+
+(* Main properties **********************************************************)
+
+theorem fpcs_trans: bi_transitive … fpcs.
+/2 width=4/ qed.
+
+theorem fpcs_canc_sn: ∀L,L1,L2,T,T1,T2. ⦃L, T⦄ ⬌* ⦃L1, T1⦄ → ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4 by fpcs_trans, fpcs_sym/ qed. (**) (* /3 width=3/ is too slow *)
+
+theorem fpcs_canc_dx: ∀L1,L2,L,T1,T2,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ⦃L2, T2⦄ ⬌* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4 by fpcs_trans, fpcs_sym/ qed. (**) (* /3 width=3/ is too slow *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpcs_fprs.etc
new file mode 100644 (file)
index 0000000..43239ea
--- /dev/null
@@ -0,0 +1,55 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fprs.ma".
+include "basic_2/equivalence/fpcs.ma".
+
+(* CONTEXT-FREE PARALLEL EQUIVALENCE ON CLOSURES ****************************)
+
+(* Properties on context-free parallel computation for closures *************)
+
+(* Note: was lemma 1000 *)
+lemma fpcs_fprs_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 /width=1/ /3 width=4/
+qed.
+
+lemma fpcs_fprs_sn: ∀L1,L2,T1,T2. ⦃L2, T2⦄ ➡* ⦃L1, T1⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 #H @(fprs_ind_dx … H) -L2 -T2 /width=1/ /3 width=4/
+qed.
+
+lemma fpcs_fprs_strap1: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ∀L2,T2. ⦃L, T⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L #T1 #T #HT1 #L2 #T2 #H @(fprs_ind … H) -L2 -T2 /width=1/ /2 width=4/
+qed.
+
+lemma fpcs_fprs_strap2: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L #T1 #T #H #L2 #T2 #HT2 @(fprs_ind_dx … H) -L1 -T1 /width=1/ /2 width=4/
+qed.
+
+lemma fpcs_fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ⬌* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L #T1 #T #HT1 #L2 #T2 #H @(fprs_ind_dx … H) -L2 -T2 /width=1/ /2 width=4/
+qed.
+
+lemma fpcs_fprs_conf: ∀L1,L,T1,T. ⦃L, T⦄ ➡* ⦃L1, T1⦄ → ∀L2,T2. ⦃L, T⦄ ⬌* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L #T1 #T #H #T2 #HT2 @(fprs_ind … H) -L1 -T1 /width=1/ /3 width=4 by fpcs_fpr_conf/ (**) (* /2 width=4/ does not work *)
+qed.
+
+lemma fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+#L1 #L #T1 #T #HT1 #T2 #L2 #H @(fprs_ind_dx … H) -L2 -T2 /2 width=1/ /2 width=4/
+qed.
+
+lemma fprs_fpr_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡ ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=7 by bi_step, fprs_div/ qed-.
+
+lemma fpr_fprs_div: ∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ∀L2,T2. ⦃L2, T2⦄ ➡* ⦃L, T⦄ → ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄.
+/3 width=4 by bi_step, fprs_div/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr.etc
new file mode 100644 (file)
index 0000000..3bb168f
--- /dev/null
@@ -0,0 +1,68 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ➡ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRed $L1 $T1 $L2 $T2 }.
+
+include "basic_2/reducibility/tpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
+
+definition fpr: bi_relation lenv term ≝
+                λL1,T1,L2,T2. |L1| = |L2| ∧ L1 @@ T1 ➡ L2 @@ T2.
+
+interpretation
+   "context-free parallel reduction (closure)"
+   'FocalizedPRed L1 T1 L2 T2 = (fpr L1 T1 L2 T2).
+
+(* Basic properties *********************************************************)
+
+lemma fpr_refl: bi_reflexive … fpr.
+/2 width=1/ qed.
+
+lemma fpr_shift: ∀I1,I2,L1,L2,V1,V2,T1,T2.
+                 ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
+                 ⦃L1.ⓑ{I1}V1, T1⦄ ➡ ⦃L2.ⓑ{I2}V2, T2⦄.
+#I1 #I2 #L1 #L2 #V1 #V2 #T1 #T2 * #HL12 #HT12
+@conj // normalize // (**) (* explicit constructor *)
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma fpr_inv_atom1: ∀L2,T1,T2. ⦃⋆, T1⦄ ➡ ⦃L2, T2⦄ → T1 ➡ T2 ∧ L2 = ⋆.
+#L2 #T1 #T2 * #H
+lapply (length_inv_zero_sn … H) -H #H destruct /2 width=1/
+qed-.
+
+lemma fpr_inv_atom3: ∀L1,T1,T2. ⦃L1,T1⦄ ➡ ⦃⋆,T2⦄ → T1 ➡ T2 ∧ L1 = ⋆.
+#L1 #T1 #T2 * #H
+lapply (length_inv_zero_dx … H) -H #H destruct /2 width=1/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma fpr_fwd_pair1: ∀I1,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I1}V1, T1⦄ ➡ ⦃L2, T2⦄ →
+                     ∃∃I2,K2,V2. ⦃K1, -ⓑ{I1}V1.T1⦄ ➡ ⦃K2, -ⓑ{I2}V2.T2⦄  &
+                                 L2 = K2.ⓑ{I2}V2.
+#I1 #K1 #L2 #V1 #T1 #T2 * #H
+elim (length_inv_pos_sn … H) -H #I2 #K2 #V2 #HK12 #H destruct /3 width=5/
+qed-.
+
+lemma fpr_fwd_pair3: ∀I2,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡ ⦃K2.ⓑ{I2}V2, T2⦄ →
+                     ∃∃I1,K1,V1. ⦃K1, -ⓑ{I1}V1.T1⦄ ➡ ⦃K2, -ⓑ{I2}V2.T2⦄  &
+                                 L1 = K1.ⓑ{I1}V1.
+#I2 #L1 #K2 #V2 #T1 #T2 * #H
+elim (length_inv_pos_dx … H) -H #I1 #K1 #V1 #HK12 #H destruct /3 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_cpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_cpr.etc
new file mode 100644 (file)
index 0000000..baa630f
--- /dev/null
@@ -0,0 +1,125 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/cfpr_cpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
+
+(* Properties on context-sensitive parallel reduction for terms *************)
+
+lemma ltpr_tpr_fpr: ∀L1,L2. L1 ➡ L2 → ∀T1,T2. T1 ➡ T2 → ⦃L1, T1⦄ ➡ ⦃L2, T2⦄.
+/3 width=4/ qed.
+
+lemma cpr_fpr: ∀L,T1,T2. L ⊢ T1 ➡ T2 → ⦃L, T1⦄ ➡ ⦃L, T2⦄.
+/2 width=4/ qed.
+
+lemma fpr_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ➡ ⦃K2, T2⦄ →
+                ∀d,e,L1. ⇩[d, e] L1 ≡ K1 →
+                ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                ∃∃L2. ⦃L1, U1⦄ ➡ ⦃L2, U2⦄ & ⇩[d, e] L2 ≡ K2.
+#K1 #K2 #T1 #T2 #HT12 #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
+elim (fpr_inv_all … HT12) -HT12 #K #HK1 #HT12 #HK2
+elim (ldrop_ltpr_trans … HLK1 … HK1) -K1 #L #HL1 #HLK
+lapply (cpr_lift … HLK … HTU1 … HTU2 HT12) -T1 -T2 #HU12
+elim (le_or_ge (|K|) d) #Hd
+[ elim (ldrop_ltpss_sn_trans_ge … HLK … HK2 …)
+| elim (ldrop_ltpss_sn_trans_be … HLK … HK2 …)
+] // -Hd #L2 #HL2 #HLK2
+lapply (ltpss_sn_weak_full … HL2) -K /3 width=4/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma fpr_flat_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
+                   ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ➡ ⦃L2, ⓕ{I}V2.T2⦄.
+#L1 #L2 #T1 #T2 #HT12
+elim (fpr_inv_all … HT12) -HT12 /4 width=4/
+qed.
+
+lemma fpr_bind_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ → ∀T1,T2. T1 ➡ T2 →
+                   ∀a,I. ⦃L1, ⓑ{a,I}V1.T1⦄ ➡ ⦃L2, ⓑ{a,I}V2.T2⦄.
+#L1 #L2 #V1 #V2 #H #T1 #T2 #HT12 #a #I
+elim (fpr_inv_all … H) /3 width=4/
+qed.
+
+lemma fpr_bind2_minus: ∀I,L1,L2,V1,T1,U2. ⦃L1, -ⓑ{I}V1.T1⦄ ➡ ⦃L2, U2⦄ →
+                       ∃∃V2,T2. ⦃L1.ⓑ{I}V1, T1⦄ ➡ ⦃L2.ⓑ{I}V2, T2⦄ &
+                                U2 = -ⓑ{I}V2.T2.
+#I1 #L1 #L2 #V1 #T1 #U2 #H
+elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
+elim (cpr_fwd_bind1_minus … H false) -H /4 width=4/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma fpr_fwd_bind2_minus: ∀I,L1,L,V1,T1,T. ⦃L1, -ⓑ{I}V1.T1⦄ ➡ ⦃L, T⦄ → ∀b.
+                           ∃∃V2,T2. ⦃L1, ⓑ{b,I}V1.T1⦄ ➡ ⦃L, ⓑ{b,I}V2.T2⦄ &
+                                    T = -ⓑ{I}V2.T2.
+#I #L1 #L #V1 #T1 #T #H1 #b
+elim (fpr_inv_all … H1) -H1 #L0 #HL10 #HT1 #HL0
+elim (cpr_fwd_bind1_minus … HT1 b) -HT1 /3 width=4/
+qed-.
+
+lemma fpr_fwd_shift_bind_minus: ∀I1,I2,L1,L2,V1,V2,T1,T2.
+                                ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
+                                ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ ∧ I1 = I2.
+* #I2 #L1 #L2 #V1 #V2 #T1 #T2 #H
+elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
+[ elim (cpr_inv_abbr1 … H) -H *
+  [ #V #V0 #T #HV1 #HV0 #_ #H destruct /4 width=4/
+  | #T #_ #_ #H destruct
+  ]
+| elim (cpr_inv_abst1 … H Abst V2) -H
+  #V #T #HV1 #_ #H destruct /3 width=4/
+]
+qed-.
+
+lemma fpr_fwd_abst2: ∀a,L1,L2,V1,T1,U2. ⦃L1, ⓛ{a}V1.T1⦄ ➡ ⦃L2, U2⦄ → ∀b,I,W.
+                     ∃∃V2,T2. ⦃L1, ⓑ{b,I}W.T1⦄ ➡ ⦃L2, ⓑ{b,I}W.T2⦄ &
+                              U2 = ⓛ{a}V2.T2.
+#a #L1 #L2 #V1 #T1 #U2 #H
+elim (fpr_inv_all … H) #L #HL1 #H #HL2 #b #I #W
+elim (cpr_fwd_abst1 … H b I W) -H /3 width=4/
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fpr_inv_pair1: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡ ⦃L2, T2⦄ →
+                     ∃∃K2,V2. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
+                              ⦃K1, -ⓑ{I}V1.T1⦄ ➡ ⦃K2, -ⓑ{I}V2.T2⦄ &
+                              L2 = K2.ⓑ{I}V2.
+#I1 #K1 #X #V1 #T1 #T2 #H
+elim (fpr_fwd_pair1 … H) -H #I2 #K2 #V2 #HT12 #H destruct
+elim (fpr_fwd_shift_bind_minus … HT12) #HV12 #H destruct /2 width=5/
+qed-.
+
+lemma fpr_inv_pair3: ∀I,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡ ⦃K2.ⓑ{I}V2, T2⦄ →
+                     ∃∃K1,V1. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
+                              ⦃K1, -ⓑ{I}V1.T1⦄ ➡ ⦃K2, -ⓑ{I}V2.T2⦄ &
+                              L1 = K1.ⓑ{I}V1.
+#I2 #X #K2 #V2 #T1 #T2 #H
+elim (fpr_fwd_pair3 … H) -H #I1 #K1 #V1 #HT12 #H destruct
+elim (fpr_fwd_shift_bind_minus … HT12) #HV12 #H destruct /2 width=5/
+qed-.
+
+(* More advanced forward lemmas *********************************************)
+
+lemma fpr_fwd_pair1_full: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡ ⦃L2, T2⦄ →
+                          ∀b. ∃∃K2,V2. ⦃K1, V1⦄  ➡ ⦃K2, V2⦄ &
+                                       ⦃K1, ⓑ{b,I}V1.T1⦄ ➡ ⦃K2, ⓑ{b,I}V2.T2⦄ &
+                                       L2 = K2.ⓑ{I}V2.
+#I #K1 #L2 #V1 #T1 #T2 #H #b
+elim (fpr_inv_pair1 … H) -H #K2 #V2 #HV12 #HT12 #H destruct
+elim (fpr_fwd_bind2_minus … HT12 b) -HT12 #W1 #U1 #HTU1 #H destruct /2 width=5/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fpr_fpr.etc
new file mode 100644 (file)
index 0000000..3f7ac2c
--- /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/reducibility/tpr_tpr.ma".
+include "basic_2/reducibility/fpr.ma".
+
+(* CONTEXT-FREE PARALLEL REDUCTION ON CLOSURES ******************************)
+
+(* Main properties **********************************************************)
+
+theorem fpr_conf: bi_confluent … fpr.
+#L0 #L1 #T0 #T1 * #HL01 #HT01 #L2 #T2 * >HL01 #HL12 #HT02
+elim (tpr_conf … HT01 HT02) -L0 -T0 #X #H1 #H2
+elim (tpr_fwd_shift1 … H1) #L #T #HL1 #H destruct /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs.etc
new file mode 100644 (file)
index 0000000..f42bdf7
--- /dev/null
@@ -0,0 +1,58 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 , term 46 T1 ⦄ ➡ * break ⦃ term 46 L2 , term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRedStar $L1 $T1 $L2 $T2 }.
+
+notation "hvbox( ⦃ term 46 L1 , term 46 T1 ⦄ ➡ ➡ * break ⦃ term 46 L2 , term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRedStarAlt $L1 $T1 $L2 $T2 }.
+
+include "basic_2/reducibility/fpr.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
+
+definition fprs: bi_relation lenv term ≝ bi_TC … fpr.
+
+interpretation "context-free parallel computation (closure)"
+   'FocalizedPRedStar L1 T1 L2 T2 = (fprs L1 T1 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma fprs_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
+                (∀L,L2,T,T2. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ → R L T → R L2 T2) →
+                ∀L2,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → R L2 T2.
+/3 width=7 by bi_TC_star_ind/ qed-.
+
+lemma fprs_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
+                   (∀L1,L,T1,T. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ → R L T → R L1 T1) →
+                   ∀L1,T1. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → R L1 T1.
+/3 width=7 by bi_TC_star_ind_dx/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma fpr_fprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
+/2 width=1/ qed.
+
+lemma fprs_refl: bi_reflexive … fprs.
+/2 width=1/ qed.
+
+lemma fprs_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ➡* ⦃L, T⦄ → ⦃L, T⦄ ➡ ⦃L2, T2⦄ →
+                   ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma fprs_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ➡ ⦃L, T⦄ → ⦃L, T⦄ ➡* ⦃L2, T2⦄ →
+                   ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
+/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_aaa.etc
new file mode 100644 (file)
index 0000000..b76637f
--- /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/reducibility/cfpr_aaa.ma".
+include "basic_2/computation/fprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_fprs_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A →
+                     ∀L2,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → L2 ⊢ T2 ⁝ A.
+#L1 #T1 #A #HT1 #L2 #T2 #HLT12
+@(bi_TC_Conf3 … HT1 ?? HLT12) /2 width=4/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_cprs.etc
new file mode 100644 (file)
index 0000000..9d4d954
--- /dev/null
@@ -0,0 +1,138 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/fpr_cpr.ma".
+include "basic_2/computation/cprs_lfprs.ma".
+include "basic_2/computation/lfprs_ltprs.ma".
+include "basic_2/computation/lfprs_fprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fprs_flat_dx_tpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ∀V1,V2. V1 ➡ V2 →
+                        ∀I. ⦃L1, ⓕ{I}V1.T1⦄ ➡* ⦃L2, ⓕ{I}V2.T2⦄.
+#L1 #L2 #T1 #T2 #HT12 @(fprs_ind … HT12) -L2 -T2 /3 width=1/
+#L #L2 #T #T2 #_ #HT2 #IHT2 #V1 #V2 #HV12 #I
+lapply (IHT2 … HV12 I) -IHT2 -HV12 /3 width=6/
+qed.
+
+lemma fprs_bind2_minus: ∀I,L1,L2,V1,T1,U2. ⦃L1, -ⓑ{I}V1.T1⦄ ➡* ⦃L2, U2⦄ →
+                        ∃∃V2,T2. ⦃L1.ⓑ{I}V1, T1⦄ ➡* ⦃L2.ⓑ{I}V2, T2⦄ &
+                                 U2 = -ⓑ{I}V2.T2.
+#I #L1 #L2 #V1 #T1 #U2 #H @(fprs_ind … H) -L2 -U2 /2 width=4/
+#L #L2 #U #U2 #_ #HU2 * #V #T #HT1 #H destruct
+elim (fpr_bind2_minus … HU2) -HU2 /3 width=4/
+qed-.
+
+lemma fprs_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ➡* ⦃K2, T2⦄ →
+                 ∀d,e,L1. ⇩[d, e] L1 ≡ K1 →
+                 ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                 ∃∃L2. ⦃L1, U1⦄ ➡* ⦃L2, U2⦄ & ⇩[d, e] L2 ≡ K2.
+#K1 #K2 #T1 #T2 #HT12 @(fprs_ind … HT12) -K2 -T2
+[ #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
+  >(lift_mono … HTU2 … HTU1) -U2 /2 width=3/
+| #K #K2 #T #T2 #_ #HT2 #IHT1 #d #e #L1 #HLK1 #U1 #U2 #HTU1 #HTU2
+  elim (lift_total T d e) #U #HTU
+  elim (IHT1 … HLK1 … HTU1 HTU) -K1 -T1 #L #HU1 #HKL
+  elim (fpr_lift … HT2 … HKL … HTU HTU2) -K -T -T2 /3 width=4/
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma fprs_inv_pair1: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡* ⦃L2, T2⦄ →
+                      ∃∃K2,V2. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
+                               ⦃K1, -ⓑ{I}V1.T1⦄ ➡* ⦃K2, -ⓑ{I}V2.T2⦄  &
+                               L2 = K2.ⓑ{I}V2.
+#I #K1 #L2 #V1 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 /2 width=5/
+#L #L2 #T #T2 #_ #HT2 * #K #V #HV1 #HT1 #H destruct
+elim (fpr_inv_pair1 … HT2) -HT2 #K2 #V2 #HV2 #HT2 #H destruct /3 width=5/
+qed-.
+
+lemma fprs_inv_pair3: ∀I,L1,K2,V2,T1,T2. ⦃L1, T1⦄ ➡* ⦃K2.ⓑ{I}V2, T2⦄ →
+                      ∃∃K1,V1. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
+                               ⦃K1, -ⓑ{I}V1.T1⦄ ➡* ⦃K2, -ⓑ{I}V2.T2⦄  &
+                               L1 = K1.ⓑ{I}V1.
+#I2 #L1 #K2 #V2 #T1 #T2 #H @(fprs_ind_dx … H) -L1 -T1 /2 width=5/
+#L1 #L #T1 #T #HT1 #_ * #K #V #HV2 #HT2 #H destruct
+elim (fpr_inv_pair3 … HT1) -HT1 #K1 #V1 #HV1 #HT1 #H destruct /3 width=5/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma fprs_fwd_bind2_minus: ∀I,L1,L,V1,T1,T. ⦃L1, -ⓑ{I}V1.T1⦄ ➡* ⦃L, T⦄ → ∀b.
+                            ∃∃V2,T2. ⦃L1, ⓑ{b,I}V1.T1⦄ ➡* ⦃L, ⓑ{b,I}V2.T2⦄ &
+                                     T = -ⓑ{I}V2.T2.
+#I #L1 #L #V1 #T1 #T #H1 #b @(fprs_ind … H1) -L -T /2 width=4/
+#L0 #L #T0 #T #_ #H0 * #W1 #U1 #HTU1 #H destruct
+elim (fpr_fwd_bind2_minus … H0 b) -H0 /3 width=4/
+qed-.
+
+lemma fprs_fwd_pair1_full: ∀I,K1,L2,V1,T1,T2. ⦃K1.ⓑ{I}V1, T1⦄ ➡* ⦃L2, T2⦄ →
+                           ∀b. ∃∃K2,V2. ⦃K1, V1⦄  ➡* ⦃K2, V2⦄ &
+                                        ⦃K1, ⓑ{b,I}V1.T1⦄ ➡* ⦃K2, ⓑ{b,I}V2.T2⦄ &
+                                        L2 = K2.ⓑ{I}V2.
+#I #K1 #L2 #V1 #T1 #T2 #H #b
+elim (fprs_inv_pair1 … H) -H #K2 #V2 #HV12 #HT12 #H destruct
+elim (fprs_fwd_bind2_minus … HT12 b) -HT12 #W1 #U1 #HTU1 #H destruct /2 width=5/
+qed-.
+
+lemma fprs_fwd_abst2: ∀a,L1,L2,V1,T1,U2. ⦃L1, ⓛ{a}V1.T1⦄ ➡* ⦃L2, U2⦄ → ∀b,I,W.
+                      ∃∃V2,T2. ⦃L1, ⓑ{b,I}W.T1⦄ ➡* ⦃L2, ⓑ{b,I}W.T2⦄ &
+                               U2 = ⓛ{a}V2.T2.
+#a #L1 #L2 #V1 #T1 #U2 #H #b #I #W @(fprs_ind … H) -L2 -U2 /2 width=4/
+#L #L2 #U #U2 #_ #H2 * #V #T #HT1 #H destruct
+elim (fpr_fwd_abst2 … H2 b I W) -H2 /3 width=4/
+qed-.
+
+(* Properties on context-sensitive parallel computation for terms ***********)
+
+lemma cprs_fprs: ∀L,T1,T2. L ⊢ T1 ➡* T2 → ⦃L, T1⦄ ➡* ⦃L, T2⦄.
+#L #T1 #T2 #H @(cprs_ind … H) -T2 // /3 width=4/
+qed.
+
+(* Forward lemmas on context-sensitive parallel computation for terms *******)
+
+lemma fprs_fwd_cprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → L1 ⊢ T1 ➡* T2.
+#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 //
+#L #L2 #T #T2 #H1 #H2 #IH1
+elim (fpr_inv_all … H2) -H2 #L0 #HL0 #HT2 #_ -L2
+lapply (lfprs_cpr_trans L1 … HT2) -HT2 /3 width=3/
+qed-.
+(*
+(* Advanced properties ******************************************************)
+
+lamma fpr_bind_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ → ∀T1,T2. T1 ➡ T2 →
+                   ∀a,I. ⦃L1, ⓑ{a,I}V1.T1⦄ ➡ ⦃L2, ⓑ{a,I}V2.T2⦄.
+#L1 #L2 #V1 #V2 #H #T1 #T2 #HT12 #a #I
+elim (fpr_inv_all … H) /3 width=4/
+qed.
+
+(* Advanced forward lemmas **************************************************)
+
+lamma fpr_fwd_shift_bind_minus: ∀I1,I2,L1,L2,V1,V2,T1,T2.
+                                ⦃L1, -ⓑ{I1}V1.T1⦄ ➡ ⦃L2, -ⓑ{I2}V2.T2⦄ →
+                                ⦃L1, V1⦄ ➡ ⦃L2, V2⦄ ∧ I1 = I2.
+* #I2 #L1 #L2 #V1 #V2 #T1 #T2 #H
+elim (fpr_inv_all … H) -H #L #HL1 #H #HL2
+[ elim (cpr_inv_abbr1 … H) -H *
+  [ #V #V0 #T #HV1 #HV0 #_ #H destruct /4 width=4/
+  | #T #_ #_ #H destruct
+  ]
+| elim (cpr_inv_abst1 … H Abst V2) -H
+  #V #T #HV1 #_ #H destruct /3 width=4/
+]
+qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/fprs_fprs.etc
new file mode 100644 (file)
index 0000000..e0c1b30
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/fpr_fpr.ma".
+include "basic_2/computation/fprs.ma".
+
+(* CONTEXT-FREE PARALLEL COMPUTATION ON CLOSURES ****************************)
+
+(* Advanced properties ******************************************************)
+
+lemma fprs_strip: ∀L0,L1,T0,T1. ⦃L0, T0⦄ ➡ ⦃L1, T1⦄ →
+                  ∀L2,T2. ⦃L0, T0⦄ ➡* ⦃L2, T2⦄ →
+                  ∃∃L,T. ⦃L1, T1⦄ ➡* ⦃L, T⦄ & ⦃L2, T2⦄ ➡ ⦃L, T⦄.
+#H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8
+/2 width=4/ qed.
+
+(* Main propertis ***********************************************************)
+
+theorem fprs_conf: bi_confluent … fprs.
+/2 width=4/ qed.
+
+theorem fprs_trans: bi_transitive … fprs.
+/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lenv_px_bi.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lenv_px_bi.etc
new file mode 100644 (file)
index 0000000..931d075
--- /dev/null
@@ -0,0 +1,88 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lenv_length.ma".
+
+(* POINTWISE EXTENSION OF A FOCALIZED REALTION FOR TERMS ********************)
+
+inductive lpx_bi (R:bi_relation lenv term): relation lenv ≝
+| lpx_bi_stom: lpx_bi R (⋆) (⋆)
+| lpx_bi_pair: ∀I,K1,K2,V1,V2.
+               lpx_bi R K1 K2 → R K1 V1 K2 V2 →
+               lpx_bi R (K1. ⓑ{I} V1) (K2. ⓑ{I} V2)
+.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lpx_bi_inv_atom1_aux: ∀R,L1,L2. lpx_bi R L1 L2 → L1 = ⋆ → L2 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_bi_inv_atom1: ∀R,L2. lpx_bi R (⋆) L2 → L2 = ⋆.
+/2 width=4 by lpx_bi_inv_atom1_aux/ qed-.
+
+fact lpx_bi_inv_pair1_aux: ∀R,L1,L2. lpx_bi R L1 L2 →
+                           ∀I,K1,V1. L1 = K1. ⓑ{I} V1 →
+                           ∃∃K2,V2. lpx_bi R K1 K2 &
+                                    R K1 V1 K2 V2 & L2 = K2. ⓑ{I} V2.
+#R #L1 #L2 * -L1 -L2
+[ #J #K1 #V1 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5/
+]
+qed-.
+
+lemma lpx_bi_inv_pair1: ∀R,I,K1,V1,L2. lpx_bi R (K1. ⓑ{I} V1) L2 →
+                        ∃∃K2,V2. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
+                                 L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_bi_inv_pair1_aux/ qed-.
+
+fact lpx_bi_inv_atom2_aux: ∀R,L1,L2. lpx_bi R L1 L2 → L2 = ⋆ → L1 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_bi_inv_atom2: ∀R,L1. lpx_bi R L1 (⋆) → L1 = ⋆.
+/2 width=4 by lpx_bi_inv_atom2_aux/ qed-.
+
+fact lpx_bi_inv_pair2_aux: ∀R,L1,L2. lpx_bi R L1 L2 →
+                           ∀I,K2,V2. L2 = K2. ⓑ{I} V2 →
+                           ∃∃K1,V1. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
+                                    L1 = K1. ⓑ{I} V1.
+#R #L1 #L2 * -L1 -L2
+[ #J #K2 #V2 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5/
+]
+qed-.
+
+lemma lpx_bi_inv_pair2: ∀R,I,L1,K2,V2. lpx_bi R L1 (K2. ⓑ{I} V2) →
+                        ∃∃K1,V1. lpx_bi R K1 K2 & R K1 V1 K2 V2 &
+                                 L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_bi_inv_pair2_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpx_bi_fwd_length: ∀R,L1,L2. lpx_bi R L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H -L1 -L2 normalize //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpx_bi_refl: ∀R. bi_reflexive ? ? R → reflexive … (lpx_bi R).
+#R #HR #L elim L -L // /2 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_alt.etc
new file mode 100644 (file)
index 0000000..95ec60b
--- /dev/null
@@ -0,0 +1,87 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L1 ⊢ ➡ ➡ break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'PRedSnAlt $L1 $L2 }.
+
+notation "hvbox( ⦃ term 46 L1 ⦄ ➡ ➡ break ⦃ term 46 L2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPRedAlt $L1 $L2 }.
+
+include "basic_2/grammar/lenv_px_bi.ma".
+include "basic_2/reducibility/fpr_cpr.ma".
+include "basic_2/reducibility/lfpr_fpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS **********************)
+
+(* alternative definition *)
+definition lfpra: relation lenv ≝ lpx_bi fpr.
+
+interpretation
+  "focalized parallel reduction (environment) alternative"
+  'FocalizedPRedAlt L1 L2 = (lfpra L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lfpra_refl: reflexive … lfpra.
+/2 width=1/ qed.
+
+lemma fpr_lfpra: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1⦄ ➡➡ ⦃L2⦄.
+#L1 elim L1 -L1
+[ #L2 #T1 #T2 #H
+  elim (fpr_inv_atom1 … H) -H #_ #H destruct //
+| #L1 #I #V1 #IH #L2 #T1 #T2 #H
+  elim (fpr_inv_pair1 … H) -H #L #V #HV1 #HL1 #H destruct /3 width=3/
+]
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lfpra_inv_atom1: ∀L2. ⦃⋆⦄ ➡➡ ⦃L2⦄ → L2 = ⋆.
+/2 width=2 by lpx_bi_inv_atom1/ qed-.
+
+lemma lfpra_inv_pair1: ∀K1,I,V1,L2. ⦃K1. ⓑ{I} V1⦄ ➡➡ ⦃L2⦄ →
+                       ∃∃K2,V2. ⦃K1⦄ ➡➡ ⦃K2⦄ & ⦃K1, V1⦄ ➡ ⦃K2, V2⦄ &
+                                L2 = K2. ⓑ{I} V2.
+/2 width=1 by lpx_bi_inv_pair1/ qed-.
+
+lemma lfpra_inv_atom2: ∀L1. ⦃L1⦄ ➡➡ ⦃⋆⦄ → L1 = ⋆.
+/2 width=2 by lpx_bi_inv_atom2/ qed-.
+
+lemma lfpra_inv_pair2: ∀L1,K2,I,V2. ⦃L1⦄ ➡➡ ⦃K2. ⓑ{I} V2⦄ →
+                       ∃∃K1,V1. ⦃K1⦄ ➡➡ ⦃K2⦄ & ⦃K1, V1⦄ ➡ ⦃K2, V2⦄ &
+                                L1 = K1. ⓑ{I} V1.
+/2 width=1 by lpx_bi_inv_pair2/ qed-.
+
+lemma lfpra_inv_fpr: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → ∀T.⦃L1, T⦄ ➡ ⦃L2, T⦄.
+#L1 #L2 * -L1 -L2 // /3 width=1/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lfpra_fwd_length: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → |L1| = |L2|.
+/2 width=2 by lpx_bi_fwd_length/ qed-.
+
+(* Main properties **********************************************************)
+
+theorem lfpr_lfpra: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ➡➡ ⦃L2⦄.
+#L1 #L2 #H
+lapply (lfpr_inv_fpr … H (⋆0)) -H /2 width=3/
+qed.
+
+theorem lfpra_lfpr: ∀L1,L2. ⦃L1⦄ ➡➡ ⦃L2⦄ → ⦃L1⦄ ➡ ⦃L2⦄.
+#L1 #L2 #H
+lapply (lfpra_inv_fpr … H (⋆0)) -H /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_fpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfpr_fpr.etc
new file mode 100644 (file)
index 0000000..f798d56
--- /dev/null
@@ -0,0 +1,31 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/lfpr.ma".
+include "basic_2/reducibility/cfpr_cpr.ma".
+
+(* FOCALIZED PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ***********************)
+
+(* Properties on context-free parallel reduction for closures ***************)
+
+lemma fpr_lfpr: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡ ⦃L2, T2⦄ → ⦃L1⦄ ➡ ⦃L2⦄.
+#L1 #L2 #T1 #T2 #H
+elim (fpr_inv_all … H) -H /2 width=3/
+qed.
+
+(* Inversion lemmas on context-free parallel reduction for closures *********)
+
+lemma lfpr_inv_fpr: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ∀T. ⦃L1, T⦄ ➡ ⦃L2, T⦄.
+#L1 #L2 * /2 width=4/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfprs_fprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fpr/lfprs_fprs.etc
new file mode 100644 (file)
index 0000000..a5c42ba
--- /dev/null
@@ -0,0 +1,41 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/lfpr_fpr.ma".
+include "basic_2/computation/fprs_fprs.ma".
+include "basic_2/computation/lfprs.ma".
+
+(* FOCALIZED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *********************)
+
+(* Inversion lemmas on context-free parallel reduction for closures *********)
+
+lemma lfprs_inv_fprs: ∀L1,L2. ⦃L1⦄ ➡* ⦃L2⦄ → ∀T. ⦃L1, T⦄ ➡* ⦃L2, T⦄.
+#L1 #L2 #H @(lfprs_ind … H) -L2 //
+#L #L2 #_ #HL2 #IHL1 #T
+lapply (lfpr_inv_fpr … HL2 T) -HL2 /3 width=4/
+qed-.
+
+(* Properties on context-free parallel computation for closures *************)
+
+lemma fprs_lfprs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1⦄ ➡* ⦃L2⦄.
+#L1 #L2 #T1 #T2 #H @(fprs_ind … H) -L2 -T2 // /3 width=5/
+qed.
+
+lemma lfprs_fprs_trans: ∀L1,L,L2,T1,T2. ⦃L1⦄ ➡* ⦃L⦄ → ⦃L, T1⦄ ➡* ⦃L2, T2⦄ → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
+#L1 #L #L2 #T1 #T2 #HL1 #HL2
+lapply (lfprs_inv_fprs … HL1 T1) -HL1 /2 width=4/
+qed.
+(*
+lamma lfprs_cprs_conf: ∀L1,L,L2,T1,T2. ⦃L1⦄ ➡* ⦃L2⦄ → L1 ⊢ T1 ➡* T2 → ⦃L1, T1⦄ ➡* ⦃L2, T2⦄.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsup.etc
new file mode 100644 (file)
index 0000000..077fd74
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+notation "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'RestSupTerm $L1 $T1 $L2 $T2 }.
+
+include "basic_2/grammar/cl_weight.ma".
+include "basic_2/substitution/lift.ma".
+
+(* RESTRICTED SUPCLOSURE ****************************************************)
+
+inductive frsup: bi_relation lenv term ≝
+| frsup_bind_sn: ∀a,I,L,V,T. frsup L (ⓑ{a,I}V.T) L V
+| frsup_bind_dx: ∀a,I,L,V,T. frsup L (ⓑ{a,I}V.T) (L.ⓑ{I}V) T
+| frsup_flat_sn: ∀I,L,V,T.   frsup L (ⓕ{I}V.T) L V
+| frsup_flat_dx: ∀I,L,V,T.   frsup L (ⓕ{I}V.T) L T
+.
+
+interpretation
+   "restricted structural predecessor (closure)"
+   'RestSupTerm L1 T1 L2 T2 = (frsup L1 T1 L2 T2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact frsup_inv_atom1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
+                          ∀J. T1 = ⓪{J} → ⊥.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #a #I #L #V #T #J #H destruct
+| #a #I #L #V #T #J #H destruct
+| #I #L #V #T #J #H destruct
+| #I #L #V #T #J #H destruct
+]
+qed-.
+
+lemma frsup_inv_atom1: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⧁ ⦃L2, T2⦄ → ⊥.
+/2 width=7 by frsup_inv_atom1_aux/ qed-.
+
+fact frsup_inv_bind1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
+                          ∀b,J,W,U. T1 = ⓑ{b,J}W.U →
+                          (L2 = L1 ∧ T2 = W) ∨
+                          (L2 = L1.ⓑ{J}W ∧ T2 = U).
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
+| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
+| #I #L #V #T #b #J #W #U #H destruct
+| #I #L #V #T #b #J #W #U #H destruct
+]
+qed-.
+
+lemma frsup_inv_bind1: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⧁ ⦃L2, T2⦄ →
+                       (L2 = L1 ∧ T2 = W) ∨
+                       (L2 = L1.ⓑ{J}W ∧ T2 = U).
+/2 width=4 by frsup_inv_bind1_aux/ qed-.
+
+fact frsup_inv_flat1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ →
+                          ∀J,W,U. T1 = ⓕ{J}W.U →
+                          L2 = L1 ∧ (T2 = W ∨ T2 = U).
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #a #I #L #V #T #J #W #U #H destruct
+| #a #I #L #V #T #J #W #U #H destruct
+| #I #L #V #T #J #W #U #H destruct /3 width=1/
+| #I #L #V #T #J #W #U #H destruct /3 width=1/
+]
+qed-.
+
+lemma frsup_inv_flat1: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⧁ ⦃L2, T2⦄ →
+                       L2 = L1 ∧ (T2 = W ∨ T2 = U).
+/2 width=4 by frsup_inv_flat1_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma frsup_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{L2, T2} < ♯{L1, T1}.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/
+qed-.
+
+lemma frsup_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/
+qed-.
+
+lemma frsup_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ♯{T2} < ♯{T1}.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2 /width=1/ /2 width=1 by le_minus_to_plus/
+qed-.
+
+lemma frsup_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #a
+| #a #I #L #V #_ @(ex_intro … (⋆.ⓑ{I}V)) //
+]
+#I #L #V #T @(ex_intro … (⋆)) //
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lift_frsup_trans: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
+                        ∀L,K,U2. ⦃L, U1⦄ ⧁ ⦃L @@ K, U2⦄ →
+                        ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
+#T1 #U1 #d #e * -T1 -U1 -d -e
+[5: #a #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HTU1 #L #K #X #H
+    elim (frsup_inv_bind1 … H) -H *
+    [ -HTU1 #H1 #H2 destruct
+      >(append_inv_refl_dx … H1) -L -K normalize /2 width=2/
+    | -HVW1 #H1 #H2 destruct
+      >(append_inv_pair_dx … H1) -L -K normalize /2 width=2/
+    ]
+|6: #I #V1 #W1 #T1 #U1 #d #e #HVW1 #HUT1 #L #K #X #H
+    elim (frsup_inv_flat1 … H) -H #H1 * #H2 destruct
+    >(append_inv_refl_dx … H1) -L -K normalize /2 width=2/
+]
+#i #d #e [2,3: #_ ] #L #K #X #H
+elim (frsup_inv_atom1 … H)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp.etc
new file mode 100644 (file)
index 0000000..9f7a8dc
--- /dev/null
@@ -0,0 +1,110 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ + break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'RestSupTermPlus $L1 $T1 $L2 $T2 }.
+
+include "basic_2/substitution/frsup.ma".
+
+(* PLUS-ITERATED RESTRICTED SUPCLOSURE **************************************)
+
+definition frsupp: bi_relation lenv term ≝ bi_TC … frsup.
+
+interpretation "plus-iterated restricted structural predecessor (closure)"
+   'RestSupTermPlus L1 T1 L2 T2 = (frsupp L1 T1 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma frsupp_ind: ∀L1,T1. ∀R:relation2 lenv term.
+                  (∀L2,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → R L2 T2) →
+                  (∀L,T,L2,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ → R L T → R L2 T2) →
+                  ∀L2,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → R L2 T2.
+#L1 #T1 #R #IH1 #IH2 #L2 #T2 #H
+@(bi_TC_ind … IH1 IH2 ? ? H)
+qed-.
+
+lemma frsupp_ind_dx: ∀L2,T2. ∀R:relation2 lenv term.
+                     (∀L1,T1. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → R L1 T1) →
+                     (∀L1,L,T1,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ → R L T → R L1 T1) →
+                     ∀L1,T1. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → R L1 T1.
+#L2 #T2 #R #IH1 #IH2 #L1 #T1 #H
+@(bi_TC_ind_dx … IH1 IH2 ? ? H)
+qed-.
+
+(* Baic inversion lemmas ****************************************************)
+
+lemma frsupp_inv_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ ∨
+                     ∃∃L,T. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ & ⦃L, T⦄ ⧁ ⦃L2, T2⦄.
+/2 width=1 by bi_TC_decomp_r/ qed-.
+
+lemma frsupp_inv_sn: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ ∨
+                     ∃∃L,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ & ⦃L, T⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=1 by bi_TC_decomp_l/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma frsup_frsupp: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=1/ qed.
+
+lemma frsupp_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ →
+                     ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma frsupp_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ →
+                     ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma frsupp_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{L2, T2} < ♯{L1, T1}.
+#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
+/3 width=3 by frsup_fwd_fw, transitive_lt/
+qed-.
+
+lemma frsupp_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
+#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
+/2 width=3 by frsup_fwd_lw/ (**) (* /3 width=5 by frsup_fwd_lw, transitive_le/ is too slow *)
+#L #T #L2 #T2 #_ #HL2 #HL1
+lapply (frsup_fwd_lw … HL2) -HL2 /2 width=3 by transitive_le/
+qed-.
+
+lemma frsupp_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ♯{T2} < ♯{T1}.
+#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2
+/3 width=3 by frsup_fwd_tw, transitive_lt/
+qed-.
+
+lemma frsupp_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
+#L1 #L2 #T1 #T2 #H @(frsupp_ind … H) -L2 -T2 /2 width=3 by frsup_fwd_append/
+#L #T #L2 #T2 #_ #HL2 * #K1 #H destruct
+elim (frsup_fwd_append … HL2) -HL2 #K2 #H destruct /2 width=2/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lift_frsupp_trans: ∀L,U1,K,U2. ⦃L, U1⦄ ⧁+ ⦃L @@ K, U2⦄ →
+                         ∀T1,d,e. ⇧[d, e] T1 ≡ U1 →
+                         ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
+#L #U1 @(f2_ind … fw … L U1) -L -U1 #n #IH
+#L #U1 #Hn #K #U2 #H #T1 #d #e #HTU1 destruct
+elim (frsupp_inv_sn … H) -H /2 width=5 by lift_frsup_trans/ *
+#L0 #U0 #HL0 #HL
+elim (frsup_fwd_append … HL0) #K0 #H destruct
+elim (frsupp_fwd_append … HL) #L0 >append_assoc #H
+elim (append_inj_dx … H ?) -H // #_ #H destruct
+<append_assoc in HL; #HL
+elim (lift_frsup_trans … HTU1 … HL0) -T1 #T #HTU
+lapply (frsup_fwd_fw … HL0) -HL0 #HL0
+elim (IH … HL … HTU) -IH -HL -T // -L -U1 -U0 /2 width=2/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp_frsupp.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsupp_frsupp.etc
new file mode 100644 (file)
index 0000000..92efe26
--- /dev/null
@@ -0,0 +1,22 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/frsupp.ma".
+
+(* PLUS-ITERATED RESTRICTED SUPCLOSURE **************************************)
+
+(* Main propertis ***********************************************************)
+
+theorem frsupp_trans: bi_transitive … frsupp.
+/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups.etc
new file mode 100644 (file)
index 0000000..6e70e76
--- /dev/null
@@ -0,0 +1,137 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1, break term 46 T1 ⦄ ⧁ * break ⦃ term 46 L2 , break term 46 T2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'RestSupTermStar $L1 $T1 $L2 $T2 }.
+
+include "basic_2/unfold/frsupp.ma".
+
+(* STAR-ITERATED RESTRICTED SUPCLOSURE **************************************)
+
+definition frsups: bi_relation lenv term ≝ bi_star … frsup.
+
+interpretation "star-iterated restricted structural predecessor (closure)"
+   'RestSupTermStar L1 T1 L2 T2 = (frsups L1 T1 L2 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma frsups_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
+                  (∀L,L2,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ → R L T → R L2 T2) →
+                  ∀L2,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → R L2 T2.
+#L1 #T1 #R #IH1 #IH2 #L2 #T2 #H
+@(bi_star_ind … IH1 IH2 ? ? H)
+qed-.
+
+lemma frsups_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
+                     (∀L1,L,T1,T. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁* ⦃L2, T2⦄ → R L T → R L1 T1) →
+                     ∀L1,T1. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → R L1 T1.
+#L2 #T2 #R #IH1 #IH2 #L1 #T1 #H
+@(bi_star_ind_dx … IH1 IH2 ? ? H)
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma frsups_refl: bi_reflexive … frsups.
+/2 width=1/ qed.
+
+lemma frsupp_frsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
+/2 width=1/ qed.
+
+lemma frsup_frsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
+/2 width=1/ qed.
+
+lemma frsups_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ → ⦃L, T⦄ ⧁ ⦃L2, T2⦄ →
+                     ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma frsups_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁ ⦃L, T⦄ → ⦃L, T⦄ ⧁* ⦃L2, T2⦄ →
+                     ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma frsups_frsupp_frsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁* ⦃L, T⦄ →
+                            ⦃L, T⦄ ⧁+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+lemma frsupp_frsups_frsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⧁+ ⦃L, T⦄ →
+                            ⦃L, T⦄ ⧁* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+/2 width=4/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma frsups_inv_all: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ →
+                      (L1 = L2 ∧ T1 = T2) ∨ ⦃L1, T1⦄ ⧁+ ⦃L2, T2⦄.
+#L1 #L2 #T1 #T2 * /2 width=1/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma frsups_fwd_fw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{L2, T2} ≤ ♯{L1, T1}.
+#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
+/3 width=1 by frsupp_fwd_fw, lt_to_le/
+qed-.
+
+lemma frsups_fwd_lw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{L1} ≤ ♯{L2}.
+#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
+/2 width=3 by frsupp_fwd_lw/
+qed-.
+
+lemma frsups_fwd_tw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ♯{T2} ≤ ♯{T1}.
+#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H [ * // ]
+/3 width=3 by frsupp_fwd_tw, lt_to_le/
+qed-.
+
+lemma frsups_fwd_append: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⧁* ⦃L2, T2⦄ → ∃L. L2 = L1 @@ L.
+#L1 #L2 #T1 #T2 #H elim (frsups_inv_all … H) -H
+[ * #H1 #H2 destruct
+  @(ex_intro … (⋆)) //
+| /2 width=3 by frsupp_fwd_append/
+qed-.
+
+(* Advanced forward lemmas ***************************************************)
+
+lemma lift_frsups_trans: ∀T1,U1,d,e. ⇧[d, e] T1 ≡ U1 →
+                         ∀L,K,U2. ⦃L, U1⦄ ⧁* ⦃L @@ K, U2⦄ →
+                         ∃T2. ⇧[d + |K|, e] T2 ≡ U2.
+#T1 #U1 #d #e #HTU1 #L #K #U2 #H elim (frsups_inv_all … H) -H
+[ * #H1 #H2 destruct
+  >(append_inv_refl_dx … (sym_eq … H1)) -H1 normalize /2 width=2/
+| /2 width=5 by lift_frsupp_trans/
+]
+qed-.
+
+(* Advanced inversion lemmas for frsupp **************************************)
+
+lemma frsupp_inv_atom1_frsups: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⧁+ ⦃L2, T2⦄ → ⊥.
+#J #L1 #L2 #T2 #H @(frsupp_ind … H) -L2 -T2 //
+#L2 #T2 #H elim (frsup_inv_atom1 … H)
+qed-.
+
+lemma frsupp_inv_bind1_frsups: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⧁+ ⦃L2, T2⦄ →
+                               ⦃L1, W⦄ ⧁* ⦃L2, T2⦄ ∨ ⦃L1.ⓑ{J}W, U⦄ ⧁* ⦃L2, T2⦄.
+#b #J #L1 #L2 #W #U #T2 #H @(frsupp_ind … H) -L2 -T2
+[ #L2 #T2 #H
+  elim (frsup_inv_bind1 … H) -H * #H1 #H2 destruct /2 width=1/
+| #L #T #L2 #T2 #_ #HT2 * /3 width=4/
+]
+qed-.
+
+lemma frsupp_inv_flat1_frsups: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⧁+ ⦃L2, T2⦄ →
+                               ⦃L1, W⦄ ⧁* ⦃L2, T2⦄ ∨ ⦃L1, U⦄ ⧁* ⦃L2, T2⦄.
+#J #L1 #L2 #W #U #T2 #H @(frsupp_ind … H) -L2 -T2
+[ #L2 #T2 #H
+  elim (frsup_inv_flat1 … H) -H #H1 * #H2 destruct /2 width=1/
+| #L #T #L2 #T2 #_ #HT2 * /3 width=4/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups_frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/frsups_frsups.etc
new file mode 100644 (file)
index 0000000..e7b7de2
--- /dev/null
@@ -0,0 +1,22 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/frsups.ma".
+
+(* STAR-ITERATED RESTRICTED SUPCLOSURE **************************************)
+
+(* Main propertis ***********************************************************)
+
+theorem frsups_trans: bi_transitive … frsups.
+/2 width=4/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/ssta_frsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/frsup/ssta_frsups.etc
new file mode 100644 (file)
index 0000000..9eb1fbd
--- /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/unfold/frsups.ma".
+include "basic_2/static/ssta.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma ssta_inv_frsupp: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → ⦃L, U⦄ ⧁+ ⦃L, T⦄ → ⊥.
+#h #g #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #l #_ #H
+  elim (frsupp_inv_atom1_frsups … H)
+| #L #K #V #W #U #i #l #_ #_ #HWU #_ #H
+  elim (lift_frsupp_trans … (⋆) … H … HWU) -U #X #H
+  elim (lift_inv_lref2_be … H ? ?) -H //
+| #L #K #W #V #U #i #l #_ #_ #HWU #_ #H
+  elim (lift_frsupp_trans … (⋆) … H … HWU) -U #X #H
+  elim (lift_inv_lref2_be … H ? ?) -H //
+| #a #I #L #V #T #U #l #_ #IHTU #H
+  elim (frsupp_inv_bind1_frsups … H) -H #H [2: /4 width=4/ ] -IHTU
+  lapply (frsups_fwd_fw … H) -H normalize
+  <associative_plus <associative_plus #H
+  elim (le_plus_xySz_x_false … H)
+| #L #V #T #U #l #_ #IHTU #H
+  elim (frsupp_inv_flat1_frsups … H) -H #H [2: /4 width=4/ ] -IHTU
+  lapply (frsups_fwd_fw … H) -H normalize
+  <associative_plus <associative_plus #H
+  elim (le_plus_xySz_x_false … H)
+| /3 width=4/
+]
+qed-.
+
+fact ssta_inv_refl_aux: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → T = U → ⊥.
+#h #g #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #l #_ #H
+  lapply (next_lt h k) destruct -H -e0 (**) (* destruct: these premises are not erased *)
+  <e1 -e1 #H elim (lt_refl_false … H)
+| #L #K #V #W #U #i #l #_ #_ #HWU #_ #H destruct
+  elim (lift_inv_lref2_be … HWU ? ?) -HWU //
+| #L #K #W #V #U #i #l #_ #_ #HWU #_ #H destruct
+  elim (lift_inv_lref2_be … HWU ? ?) -HWU //
+| #a #I #L #V #T #U #l #_ #IHTU #H destruct /2 width=1/
+| #L #V #T #U #l #_ #IHTU #H destruct /2 width=1/
+| #L #W #T #U #l #HTU #_ #H destruct
+  elim (ssta_inv_frsupp … HTU ?) -HTU /2 width=1/
+]
+qed-.
+
+lemma ssta_inv_refl: ∀h,g,T,L,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, T⦄ → ⊥.
+/2 width=8 by ssta_inv_refl_aux/ qed-.
+
+lemma ssta_inv_frsups: ∀h,g,L,T,U,l. ⦃h, L⦄ ⊢ T •[g] ⦃l, U⦄ → ⦃L, U⦄ ⧁* ⦃L, T⦄ → ⊥.
+#h #g #L #T #U #L #HTU #H elim (frsups_inv_all … H) -H
+[ * #_ #H destruct /2 width=6 by ssta_inv_refl/
+| /2 width=8 by ssta_inv_frsupp/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsup.etc
new file mode 100644 (file)
index 0000000..b3970be
--- /dev/null
@@ -0,0 +1,73 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ldrop.ma".
+
+(* SUPCLOSURE ***************************************************************)
+
+(* Basic inversion lemmas ***************************************************)
+
+fact fsup_inv_atom1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀J. T1 = ⓪{J} →
+                         (∃∃I,K,V. L1 = K.ⓑ{I}V & J = LRef 0 & L2 = K & T2 = V) ∨
+                         ∃∃I,K,V,i. ⦃K, #i⦄ ⊃ ⦃L2, T2⦄ & L1 = K.ⓑ{I}V & J = LRef (i+1).
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #I #L #V #J #H destruct /3 width=6/
+| #I #L #K #V #T #i #HLK #J #H destruct /3 width=7/
+| #a #I #L #V #T #J #H destruct
+| #a #I #L #V #T #J #H destruct
+| #I #L #V #T #J #H destruct
+| #I #L #V #T #J #H destruct
+]
+qed-.
+
+lemma fsup_inv_atom1: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⊃ ⦃L2, T2⦄ →
+                      (∃∃I,K,V. L1 = K.ⓑ{I}V & J = LRef 0 & L2 = K & T2 = V) ∨
+                      ∃∃I,K,V,i. ⦃K, #i⦄ ⊃ ⦃L2, T2⦄ & L1 = K.ⓑ{I}V & J = LRef (i+1).
+/2 width=3 by fsup_inv_atom1_aux/ qed-.
+
+fact fsup_inv_bind1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
+                         ∀b,J,W,U. T1 = ⓑ{b,J}W.U →
+                         (L2 = L1 ∧ T2 = W) ∨
+                         (L2 = L1.ⓑ{J}W ∧ T2 = U).
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #I #L #V #b #J #W #U #H destruct
+| #I #L #K #V #T #i #_ #b #J #W #U #H destruct
+| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
+| #a #I #L #V #T #b #J #W #U #H destruct /3 width=1/
+| #I #L #V #T #b #J #W #U #H destruct
+| #I #L #V #T #b #J #W #U #H destruct
+]
+qed-.
+
+lemma fsup_inv_bind1: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⊃ ⦃L2, T2⦄ →
+                      (L2 = L1 ∧ T2 = W) ∨
+                      (L2 = L1.ⓑ{J}W ∧ T2 = U).
+/2 width=4 by fsup_inv_bind1_aux/ qed-.
+
+fact fsup_inv_flat1_aux: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
+                         ∀J,W,U. T1 = ⓕ{J}W.U →
+                         L2 = L1 ∧ (T2 = W ∨ T2 = U).
+#L1 #L2 #T1 #T2 * -L1 -L2 -T1 -T2
+[ #I #L #K #J #W #U #H destruct
+| #I #L #K #V #T #i #_ #J #W #U #H destruct
+| #a #I #L #V #T #J #W #U #H destruct
+| #a #I #L #V #T #J #W #U #H destruct
+| #I #L #V #T #J #W #U #H destruct /3 width=1/
+| #I #L #V #T #J #W #U #H destruct /3 width=1/
+]
+qed-.
+
+lemma fsup_inv_flat1: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⊃ ⦃L2, T2⦄ →
+                      L2 = L1 ∧ (T2 = W ∨ T2 = U).
+/2 width=4 by fsup_inv_flat1_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/fsups.etc
new file mode 100644 (file)
index 0000000..36abe12
--- /dev/null
@@ -0,0 +1,29 @@
+(* Advanced inversion lemmas on plus-iterated supclosure ********************)
+
+lamma fsupp_inv_bind1_fsups: ∀b,J,G1,G2,L1,L2,W,U,T2. ⦃G1, L1, ⓑ{b,J}W.U⦄ ⊃+ ⦃G2, L2, T2⦄ →
+                             ⦃G1, L1, W⦄ ⊃* ⦃G2, L2, T2⦄ ∨ ⦃L1.ⓑ{J}W, U⦄ ⊃* ⦃G2, L2, T2⦄.
+#b #J #G1 #G2 #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -G2 -L2 -T2
+[ #G2 #L2 #T2 #H
+  elim (fsup_inv_bind1 … H) -H * #H1 #H2 #H3 destruct /2 width=1/
+| #G #G2 #L #L2 #T #T2 #_ #HT2 * /3 width=4/
+]
+qad-.
+
+lamma fsupp_inv_flat1_fsups: ∀J,G1,G2,L1,L2,W,U,T2. ⦃G1, L1, ⓕ{J}W.U⦄ ⊃+ ⦃G2, L2, T2⦄ →
+                             ⦃G1, L1, W⦄ ⊃* ⦃G2, L2, T2⦄ ∨ ⦃G1, L1, U⦄ ⊃* ⦃G2, L2, T2⦄.
+#J #G1 #G2 #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -G2 -L2 -T2
+[ #G2 #L2 #T2 #H
+  elim (fsup_inv_flat1 … H) -H #H1 * #H2 destruct /2 width=1/
+| #G #G2 #L #L2 #T #T2 #_ #HT2 * /3 width=4/
+]
+qad-.
+
+lamma fsupp_fsups: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄.
+/2 width=1 by tri_inj/ qed.
+
+lamma fsups_lref: ∀I,G,K,V,i,L. ⇩[0, i] L ≡ K.ⓑ{I}V → ⦃G, L, #i⦄ ⊃* ⦃G, K, V⦄.
+/3 width=5 by _/ qed.
+
+lamma fsups_lref_S_lt: ∀I,G1,G2,L,K,V,T,i.
+                       0 < i → ⦃G1, L, #(i-1)⦄ ⊃* ⦃G2, K, T⦄ → ⦃G1, L.ⓑ{I}V, #i⦄ ⊃+ ⦃G2, K, T⦄.
+/3 width=7 by _/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsup.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsup.etc
new file mode 100644 (file)
index 0000000..75ea3e5
--- /dev/null
@@ -0,0 +1,62 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fsup.ma".
+include "basic_2/substitution/ldrop_ldrop.ma".
+
+(* LOCAL ENVIRONMENT SLICING ************************************************)
+
+(* Inversion lemmas on supclosure *******************************************)
+
+lemma fsup_inv_atom1_ldrop: ∀K,V,L,I. ⦃L, ⓪{I}⦄ ⊃ ⦃K, V⦄ →
+                            ∃∃J,i. ⇩[0, i] L ≡ K.ⓑ{J}V & I = LRef i.
+#K #V #L @(f_ind … length … L) -L #n #IH #L #Hn #I #H
+elim (fsup_inv_atom1 … H) -H *
+[ #J #L0 #V0 #H1 #H2 #H3 #H4 destruct /2 width=4/
+| #J #L0 #V0 #i #HLK #H1 #H2 destruct
+  elim (IH … HLK) -IH -HLK [2: normalize // ] #I #j #HLK #H destruct /3 width=4/
+]
+qed-.
+
+(* Advanced eliminators on supclosure ***************************************)
+
+lemma fsup_ind_ldrop: ∀R:bi_relation lenv term.
+                      (∀I,L,K,V,i. ⇩[0, i] L ≡ K.ⓑ{I}V → R L (#i) K V) →
+                      (∀a,I,L,V,T. R L (ⓑ{a,I}V.T) L V) →
+                      (∀a,I,L,V,T. R L (ⓑ{a,I}V.T) (L.ⓑ{I}V) T) →
+                      (∀I,L,V,T. R L (ⓕ{I}V.T) L V) →
+                      (∀I,L,V,T. R L (ⓕ{I}V.T) L T) →
+                      ∀L1,T1,L2,T2. ⦃L1,T1⦄⊃⦃L2,T2⦄ → R L1 T1 L2 T2.
+#R #H1 #H2 #H3 #H4 #H5 #L1 #T1 #L2 #T2 #H elim H -L1 -T1 -L2 -T2 //
+[ /3 width=2/
+| #I #L #K #V #T #i #H #H1LK
+  elim (fsup_inv_atom1_ldrop … H) -H #J #j #H2LK #H destruct /3 width=2/
+]
+qed-.
+
+(* Advanced inversion lemmas on supclosure **********************************)
+
+lemma fsup_inv_ldrop: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ →
+                      ∀J,W,j. ⇩[0, j] L1 ≡ L2.ⓑ{J}W → T1 = #j ∧ T2 = W.
+#L1 #L2 #T1 #T2 #H @(fsup_ind_ldrop … H) -L1 -L2 -T1 -T2
+[ #I #L #K #V #i #HLKV #J #W #j #HLKW
+  elim (ldrop_conf_div … HLKV … HLKW) -L /2 width=1/
+| #a
+| #a
+]
+#I #L #V #T #J #W #j #H
+lapply (ldrop_pair2_fwd_fw … H W) -H #H
+[2: lapply (transitive_lt (♯{L,W}) … H) /2 width=1/ -H #H ]
+elim (lt_refl_false … H)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsups.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/fsup/ldrop_fsups.etc
new file mode 100644 (file)
index 0000000..dc4d7e9
--- /dev/null
@@ -0,0 +1,30 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/fsups.ma".
+include "basic_2/substitution/ldrop_fsup.ma".
+
+(* LOCAL ENVIRONMENT SLICING ************************************************)
+
+(* Inversion lemmas on plus-iterated supclosure  ****************************)
+
+lemma fsupp_inv_atom1_fsups: ∀J,L1,L2,T2. ⦃L1, ⓪{J}⦄ ⊃+ ⦃L2, T2⦄ →
+                             ∃∃I,K,V,i. ⇩[0, i] L1 ≡ K.ⓑ{I}V &
+                             ⦃K, V⦄ ⊃* ⦃L2, T2⦄ & J = LRef i.
+#J #L1 #L2 #T2 #H @(fsupp_ind … H) -L2 -T2
+[ #L2 #T2 #H
+  elim (fsup_inv_atom1_ldrop … H) -H * #i #HL12 #H destruct /2 width=7/
+| #L #T #L2 #T2 #_ #HT2 * #I #K #V #i #HLK #HVT #H destruct /3 width=8/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_aaa.etc
new file mode 100644 (file)
index 0000000..0ad8732
--- /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/multiple/lifts_lifts.ma".
+include "basic_2/multiple/drops_drops.ma".
+include "basic_2/static/aaa_lifts.ma".
+include "basic_2/static/aaa_aaa.ma".
+include "basic_2/computation/lsubc_drops.ma".
+
+(* GENERIC COMPUTATION PROPERTIES *******************************************)
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: sc3_arity_csubc *)
+theorem acr_aaa_csubc: ∀RR,RS,RP.
+                       gcp RR RS RP → gcr RR RS RP RP →
+                       ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
+                       ∀L2. G ⊢ L2 ⫃[RP] L1 → ⦃G, L2, T⦄ ϵ[RP] 〚A〛.
+#RR #RS #RP #H1RP #H2RP #G #L1 #T #A #H elim H -G -L1 -T -A
+[ #G #L1 #k #L2 #HL21
+  lapply (acr_gcr … H1RP H2RP (⓪)) #HAtom
+  lapply (s4 … HAtom G L2 (◊)) /2 width=1 by/
+| #I #G #L1 #K1 #V1 #B #i #HLK1 #HKV1B #IHB #L2 #HL21
+  lapply (acr_gcr … H1RP H2RP B) #HB
+  elim (lsubc_drop_O1_trans … HL21 … HLK1) -L1 #X #HLK2 #H
+  elim (lsubc_inv_pair2 … H) -H *
+  [ #K2 #HK21 #H destruct -HKV1B
+    lapply (drop_fwd_drop2 … HLK2) #H
+    elim (lift_total V1 0 (i +1)) #V #HV1
+    lapply (s5 … HB ? G ? ? (◊) … HV1 HLK2) /3 width=7 by s0/
+  | #K2 #V2 #A2 #HVA2 #H1V1A2 #H2V1A2 #_ #H1 #H2 destruct -IHB
+    lapply (aaa_mono … H2V1A2 … HKV1B) #H destruct -H2V1A2 -HKV1B
+    lapply (drop_fwd_drop2 … HLK2) #H
+    elim (lift_total V1 0 (i +1)) #V3 #HV13
+    elim (lift_total V2 0 (i +1)) #V #HV2
+    lapply (s5 … HB ? G ? ? (◊) … (ⓝV3.V) … HLK2) /2 width=1 by lift_flat/ -HLK2 
+    lapply (s7 … HB G L2 (◊)) /3 width=7 by s0/
+  ]
+| #a #G #L1 #V #T #B #A #_ #_ #IHB #IHA #L2 #HL21
+  lapply (acr_gcr … H1RP H2RP A) #HA
+  lapply (acr_gcr … H1RP H2RP B) #HB
+  lapply (s1 … HB) -HB #HB
+  lapply (s6 … HA G L2 (◊) (◊)) /4 width=1 by lsubc_pair/
+| #a #G #L1 #W #T #B #A #HLWB #_ #IHB #IHA #L2 #HL21
+  @(acr_abst  … H1RP H2RP) [ /2 width=5 by/ ]
+  #L3 #V3 #W3 #T3 #des3 #HL32 #HW03 #HT03 #H1B #H2B
+  @(gcr_lifts … L2.ⓓⓝW.V3,T … HL32)
+  elim (drops_lsubc_trans … H1RP H2RP … HL32 … HL21) -L2 #L2 #HL32 #HL21
+  lapply (aaa_lifts … L2 W3 … des3 … HLWB) -HLWB /2 width=4 by drops_trans, lifts_trans/ #HLW2B
+  @(s0 
+  
+  @(IHA (L2. ⓛW3) … (des3 + 1)) -IHA
+  /3 width=5 by lsubc_beta, drops_trans, drops_skip, lifts_trans/
+| #G #L #V #T #B #A #_ #_ #IHB #IHA #L0 #des #HL0 #X #H #L2 #HL20
+  elim (lifts_inv_flat1 … H) -H #V0 #T0 #HV0 #HT0 #H destruct
+  /3 width=10 by drops_nil, lifts_nil/
+| #G #L #V #T #A #_ #_ #IH1A #IH2A #L0 #des #HL0 #X #H #L2 #HL20
+  elim (lifts_inv_flat1 … H) -H #V0 #T0 #HV0 #HT0 #H destruct
+  lapply (acr_gcr … H1RP H2RP A) #HA
+  lapply (s7 … HA G L2 (◊)) /3 width=5 by/
+]
+qed.
+
+(* Basic_1: was: sc3_arity *)
+lemma acr_aaa: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+               ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦃G, L, T⦄ ϵ[RP] 〚A〛.
+/2 width=8 by drops_nil, lifts_nil, acr_aaa_csubc_lifts/ qed.
+
+lemma gcr_aaa: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+               ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → RP G L T.
+#RR #RS #RP #H1RP #H2RP #G #L #T #A #HT
+lapply (acr_gcr … H1RP H2RP A) #HA
+@(s1 … HA) /2 width=4 by acr_aaa/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_cr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/gcp/gcp_cr.etc
new file mode 100644 (file)
index 0000000..d8d3bbc
--- /dev/null
@@ -0,0 +1,177 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/ineint_5.ma".
+include "basic_2/grammar/aarity.ma".
+include "basic_2/multiple/mr2_mr2.ma".
+include "basic_2/multiple/lifts_lift_vector.ma".
+include "basic_2/multiple/drops_drop.ma".
+include "basic_2/computation/gcp.ma".
+
+(* GENERIC COMPUTATION PROPERTIES *******************************************)
+
+definition S0 ≝ λC:candidate. ∀G,L2,L1,T1,d,e.
+                C G L1 T1 → ∀T2. ⇩[Ⓕ, d, e] L2 ≡ L1 → ⇧[d, e] T1 ≡ T2 → C G L2 T2.
+
+definition S0s ≝ λC:candidate.
+                 ∀G,L1,L2,des. ⇩*[Ⓕ, des] L2 ≡ L1 →
+                 ∀T1,T2. ⇧*[des] T1 ≡ T2 → C G L1 T1 → C G L2 T2.
+
+(* Note: this is Girard's CR1 *)
+definition S1 ≝ λRP,C:candidate.
+                ∀G,L,T. C G L T → RP G L T.
+
+(* Note: this is Tait's iii, or Girard's CR4 *)
+definition S2 ≝ λRR:relation4 genv lenv term term. λRS:relation term. λRP,C:candidate.
+                ∀G,L,Vs. all … (RP G L) Vs →
+                ∀T. 𝐒⦃T⦄ → NF … (RR G L) RS T → C G L (ⒶVs.T).
+
+(* Note: this generalizes Tait's ii *)
+definition S3 ≝ λC:candidate.
+                ∀a,G,L,Vs,V,T,W.
+                C G L (ⒶVs.ⓓ{a}ⓝW.V.T) → C G L (ⒶVs.ⓐV.ⓛ{a}W.T).
+
+definition S4 ≝ λRP,C:candidate.
+                ∀G,L,Vs. all … (RP G L) Vs → ∀k. C G L (ⒶVs.⋆k).
+
+definition S5 ≝ λC:candidate. ∀I,G,L,K,Vs,V1,V2,i.
+                ⇩[i] L ≡ K.ⓑ{I}V1 → ⇧[0, i+1] V1 ≡ V2 →
+                C G L (ⒶVs.V2) → C G L (ⒶVs.#i).
+
+definition S6 ≝ λRP,C:candidate.
+                ∀G,L,V1s,V2s. ⇧[0, 1] V1s ≡ V2s →
+                ∀a,V,T. C G (L.ⓓV) (ⒶV2s.T) → RP G L V → C G L (ⒶV1s.ⓓ{a}V.T).
+
+definition S7 ≝ λC:candidate.
+                ∀G,L,Vs,T,W. C G L (ⒶVs.T) → C G L (ⒶVs.W) → C G L (ⒶVs.ⓝW.T).
+
+(* requirements for the generic reducibility candidate *)
+record gcr (RR:relation4 genv lenv term term) (RS:relation term) (RP,C:candidate) : Prop ≝
+{ (* s0: S0 C; *)
+  s1: S1 RP C;
+  s2: S2 RR RS RP C;
+  s3: S3 C;
+  s4: S4 RP C;
+  s5: S5 C;
+  s6: S6 RP C;
+  s7: S7 C
+}.
+
+(* the functional construction for candidates *)
+definition cfun: candidate → candidate → candidate ≝
+                 λC1,C2,G,K,T. ∀V. C1 G K V → C2 G K (ⓐV.T).
+
+(* the reducibility candidate associated to an atomic arity *)
+let rec acr (RP:candidate) (A:aarity) on A: candidate ≝
+match A with
+[ AAtom     ⇒ RP
+| APair B A ⇒ cfun (acr RP B) (acr RP A)
+].
+
+interpretation
+   "candidate of reducibility of an atomic arity (abstract)"
+   'InEInt RP G L T A = (acr RP A G L T).
+
+(* Basic properties *********************************************************)
+(*
+(* Basic_1: was: sc3_lift1 *)
+lemma gcr_lifts: ∀C. S0 C → S0s C.
+#C #HC #G #L1 #L2 #des #H elim H -L1 -L2 -des
+[ #L #T1 #T2 #H #HT1 <(lifts_inv_nil … H) -H //
+| #L1 #L #L2 #des #d #e #_ #HL2 #IHL #T2 #T1 #H #HLT2
+  elim (lifts_inv_cons … H) -H /3 width=10 by/
+]
+qed.
+*)
+axiom rp_lift: ∀RP. S0 RP.
+
+
+axiom rp_lifts: ∀RR,RS,RP. gcr RR RS RP RP →
+                ∀des,G,L0,L,V,V0. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] V ≡ V0 →
+                RP G L V → RP G L0 V0.
+(*
+#RR #RS #RP #HRP #des #G #L0 #L #V #V0 #HL0 #HV0 #HV
+@gcr_lifts /width=7 by/
+@(s0 … HRP)
+qed.
+*)
+(* Basic_1: was only: sns3_lifts1 *)
+axiom rp_liftsv_all: ∀RR,RS,RP. gcr RR RS RP RP →
+                     ∀des,G,L0,L,Vs,V0s. ⇩*[Ⓕ, des] L0 ≡ L → ⇧*[des] Vs ≡ V0s →
+                     all … (RP G L) Vs → all … (RP G L0) V0s.
+(*
+#RR #RS #RP #HRP #des #G #L0 #L #Vs #V0s #HL0 #H elim H -Vs -V0s normalize //
+#T1s #T2s #T1 #T2 #HT12 #_ #IHT2s * /3 width=7 by rp_lifts, conj/
+qed.
+*)
+
+lemma gcr_lift: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+                ∀A. S0 (acr RP A).
+#RR #RS #RP #H1RP #H2RP #A elim A -A /2 width=7 by rp_lift/
+#B #A #IHB #IHA #G #L2 #L1 #T1 #d #e #IH #T2 #HL21 #HT12 #V #HB
+@(IHA … HL21) [3: @(lift_flat … HT12) |1: skip |  
+
+(* Basic_1: was:
+   sc3_sn3 sc3_abst sc3_appl sc3_abbr sc3_bind sc3_cast sc3_lift
+*)
+lemma acr_gcr: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+               ∀A. gcr RR RS RP (acr RP A).
+#RR #RS #RP #H1RP #H2RP #A elim A -A //
+#B #A #IHB #IHA @mk_gcr
+[ #G #L #T #H
+  elim (cp1 … H1RP G L) #k #HK
+  lapply (H (⋆k) ?) -H
+  [ lapply (s2 … IHB G L (◊) … HK) //
+  | #H @(cp2 … H1RP … k) @(s1 … IHA) //
+  ]
+| #G #L #Vs #HVs #T #H1T #H2T #V #HB
+  lapply (s1 … IHB … HB) #HV
+  @(s2 … IHA … (V @ Vs))
+  /3 width=14 by rp_liftsv_all, gcp_lifts, cp0, lifts_simple_dx, conj/
+| #a #G #L #Vs #U #T #W #HA #V #HB
+  @(s3 … IHA … (V @ Vs)) /2 width=1 by/
+| #G #L #Vs #HVs #k #V #HB
+  lapply (s1 … IHB … HB) #HV
+  @(s4 … IHA … (V @ Vs)) /3 width=7 by rp_liftsv_all, conj/
+| #I #G #L #K #Vs #V1 #V2 #i #HLK #HV12 #HA #V #HB
+  @(s5 … IHA … (V @ Vs) … HLK HV12) /2 width=1 by/
+| #G #L #V1s #V2s #HV12s #a #W #T #HA #HW #V1 #HB
+  elim (lift_total V1 0 1) #V2 #HV12
+  @(s6 … IHA … (V1 @ V1s) (V2 @ V2s)) /2 width=1 by liftv_cons/
+  @HA @(gcr_lift … H1RP H2RP … HB … HV12) /2 width=2 by drop_drop/
+| #G #L #Vs #T #W #HA #HW #V #HB
+  @(s7 … IHA … (V @ Vs)) /2 width=1 by/
+]
+qed.
+
+lemma acr_abst: ∀RR,RS,RP. gcp RR RS RP → gcr RR RS RP RP →
+                ∀a,G,L,W,T,B,A. ⦃G, L, W⦄ ϵ[RP] 〚B〛 → (
+                   ∀V. ⦃G, L, V⦄ ϵ[RP] 〚B〛 → ⦃G, L.ⓓⓝW.V, T⦄ ϵ[RP] 〚A〛
+                ) →
+                ⦃G, L, ⓛ{a}W.T⦄ ϵ[RP] 〚②B.A〛.
+#RR #RS #RP #H1RP #H2RP #a #G #L #W #T #B #A #HW #HA #L0 #V0 #X #des #HL0 #H #HB
+lapply (acr_gcr … H1RP H2RP A) #HCA
+lapply (acr_gcr … H1RP H2RP B) #HCB
+elim (lifts_inv_bind1 … H) -H #W0 #T0 #HW0 #HT0 #H destruct
+lapply (gcr_lifts … HL0 … HW0 HW) -HW [ @(s0 … HCB) ] #HW0
+lapply (s3 … HCA … a G L0 (◊)) #H @H -H
+lapply (s6 … HCA G L0 (◊) (◊) ?) // #H @H -H
+[ @(HA … HL0) //
+| lapply (s1 … HCB) -HCB #HCB
+  lapply (s7 … H2RP G L0 (◊)) /3 width=1 by/
+]
+qed.
+
+(* Basic_1: removed theorems 2: sc3_arity_gen sc3_repl *)
+(* Basic_1: removed local theorems 1: sc3_sn3_abst *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas.etc
new file mode 100644 (file)
index 0000000..8cfaa34
--- /dev/null
@@ -0,0 +1,57 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : : * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'NativeTypeStarAlt $h $L $T1 $T2 }.
+
+include "basic_2/dynamic/nta.ma".
+
+(* HIGHER ORDER NATIVE TYPE ASSIGNMENT ON TERMS *****************************)
+
+definition ntas: sh → lenv → relation term ≝
+                 λh,L. star … (nta h L).
+
+interpretation "higher order native type assignment (term)"
+   'NativeTypeStar h L T U = (ntas h L T U).
+
+(* Basic eliminators ********************************************************)
+(*
+lemma cprs_ind: ∀L,T1. ∀R:predicate term. R T1 →
+                (∀T,T2. L ⊢ T1 ➡* T → L ⊢ T ➡ T2 → R T → R T2) →
+                ∀T2. L ⊢ T1 ➡* T2 → R T2.
+#L #T1 #R #HT1 #IHT1 #T2 #HT12
+@(TC_star_ind … HT1 IHT1 … HT12) //
+qed-.
+*)
+axiom ntas_ind_dx: ∀h,L,T2. ∀R:predicate term. R T2 →
+                   (∀T1,T. ⦃h, L⦄ ⊢ T1 : T → ⦃h, L⦄ ⊢ T :* T2 → R T → R T1) →
+                   ∀T1. ⦃h, L⦄ ⊢ T1 :* T2 → R T1.
+(*
+#h #L #T2 #R #HT2 #IHT2 #T1 #HT12
+@(star_ind_dx … HT2 IHT2 … HT12) //
+qed-.
+*)
+(* Basic properties *********************************************************)
+
+lemma ntas_refl: ∀h,L,T. ⦃h, L⦄ ⊢ T :* T.
+// qed.
+
+lemma ntas_strap1: ∀h,L,T1,T,T2.
+                   ⦃h, L⦄ ⊢ T1 :* T → ⦃h, L⦄  ⊢ T : T2 → ⦃h, L⦄  ⊢ T1 :* T2.
+/2 width=3/ qed.
+
+lemma ntas_strap2: ∀h,L,T1,T,T2.
+                   ⦃h, L⦄  ⊢ T1 : T → ⦃h, L⦄ ⊢ T :* T2 → ⦃h, L⦄ ⊢ T1 :* T2.
+/2 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/hod/ntas_lift.etc
new file mode 100644 (file)
index 0000000..1adced7
--- /dev/null
@@ -0,0 +1,71 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/nta_lift.ma".
+include "basic_2/hod/ntas.ma".
+
+(* HIGHER ORDER NATIVE TYPE ASSIGNMENT ON TERMS *****************************)
+
+(* Advanced properties on native type assignment for terms ******************)
+
+lemma nta_pure_ntas: ∀h,L,U,W,Y. ⦃h, L⦄ ⊢ U :* ⓛW.Y → ∀T. ⦃h, L⦄ ⊢ T : U →
+                     ∀V. ⦃h, L⦄ ⊢ V : W →  ⦃h, L⦄ ⊢ ⓐV.T : ⓐV.U.
+#h #L #U #W #Y #H @(ntas_ind_dx … H) -U /2 width=1/ /3 width=2/
+qed.
+
+axiom pippo: ∀h,L,T,W,Y. ⦃h, L⦄ ⊢ T :* ⓛW.Y → ∀U. ⦃h, L⦄ ⊢ T : U →
+             ∃Z. ⦃h, L⦄ ⊢ U :* ⓛW.Z.
+(* REQUIRES SUBJECT CONVERSION
+#h #L #T #W #Y #H @(ntas_ind_dx … H) -T
+[ #U #HYU
+  elim (nta_fwd_correct … HYU) #U0 #HU0 
+  elim (nta_inv_bind1 … HYU) #W0 #Y0 #HW0 #HY0 #HY0U
+*)
+
+(* Advanced inversion lemmas on native type assignment for terms ************)
+
+fact nta_inv_pure1_aux: ∀h,L,Z,U. ⦃h, L⦄ ⊢ Z : U → ∀X,Y. Z = ⓐY.X →
+                        ∃∃W,V,T. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V &
+                                 L ⊢ ⓐY.V ⬌* U & ⦃h, L⦄ ⊢ V :* ⓛW.T.
+#h #L #Z #U #H elim H -L -Z -U
+[ #L #k #X #Y #H destruct
+| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W #Z #U #HVW #HZU #_ #_ #X #Y #H destruct /2 width=7/
+| #L #V #W #Z #U #HZU #_ #_ #IHUW #X #Y #H destruct
+  elim (IHUW U Y ?) -IHUW // /3 width=9/
+| #L #Z #U #_ #_ #X #Y #H destruct
+| #L #Z #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
+  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #W #V #T #HYW #HXV #HU1 #HVT
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=7/
+]
+qed.
+
+(* Basic_1: was only: ty3_gen_appl *)
+lemma nta_inv_pure1: ∀h,L,Y,X,U. ⦃h, L⦄ ⊢ ⓐY.X : U →
+                     ∃∃W,V,T. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V &
+                              L ⊢ ⓐY.V ⬌* U & ⦃h, L⦄ ⊢ V :* ⓛW.T.
+/2 width=3/ qed-.
+
+axiom nta_inv_appl1: ∀h,L,Z,Y,X,U. ⦃h, L⦄ ⊢ ⓐZ.ⓛY.X : U →
+                     ∃∃W. ⦃h, L⦄ ⊢ Z : Y & ⦃h, L⦄ ⊢ ⓛY.X : ⓛY.W &
+                     L ⊢ ⓐZ.ⓛY.W ⬌* U.
+(* REQUIRES SUBJECT REDUCTION
+#h #L #Z #Y #X #U #H
+elim (nta_inv_pure1 … H) -H #W #V #T #HZW #HXV #HVU #HVT
+elim (nta_inv_bind1 … HXV) -HXV #Y0 #X0 #HY0 #HX0 #HX0V
+lapply (cpcs_trans … (ⓐZ.ⓛY.X0) … HVU) -HVU /2 width=1/ -HX0V #HX0U
+@(ex3_1_intro … HX0U) /2 width=2/
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/coeq_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/coeq_4.etc
new file mode 100644 (file)
index 0000000..8abd1ee
--- /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 d , break term 46 e ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'CoEq $d $e $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq.etc
new file mode 100644 (file)
index 0000000..5338c2a
--- /dev/null
@@ -0,0 +1,165 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lt.ma".
+include "basic_2/notation/relations/coeq_4.ma".
+include "basic_2/grammar/lenv_length.ma".
+
+(* COEQUIVALENCE FOR LOCAL ENVIRONMENTS *************************************)
+
+inductive lcoeq: relation4 ynat ynat lenv lenv ≝
+| lcoeq_atom: ∀d,e. lcoeq d e (⋆) (⋆)
+| lcoeq_zero: ∀I,L1,L2,V.
+              lcoeq 0 0 L1 L2 → lcoeq 0 0 (L1.ⓑ{I}V) (L2.ⓑ{I}V)
+| lcoeq_pair: ∀I1,I2,L1,L2,V1,V2,e. lcoeq 0 e L1 L2 →
+              lcoeq 0 (⫯e) (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2)
+| lcoeq_succ: ∀I,L1,L2,V,d,e.
+              lcoeq d e L1 L2 → lcoeq (⫯d) e (L1.ⓑ{I}V) (L2.ⓑ{I}V)
+.
+
+interpretation
+  "coequivalence (local environment)"
+  'CoEq d e L1 L2 = (lcoeq d e L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lcoeq_pair_lt: ∀I1,I2,L1,L2,V1,V2,e. L1 ≅[0, ⫰e] L2 → 0 < e →
+                     L1.ⓑ{I1}V1 ≅[0, e] L2.ⓑ{I2}V2.
+#I1 #I2 #L1 #L2 #V1 #V2 #e #HL12 #He <(ylt_inv_O1 … He) /2 width=1 by lcoeq_pair/
+qed.
+
+lemma lcoeq_succ_lt: ∀I,L1,L2,V,d,e. L1 ≅[⫰d, e] L2 → 0 < d →
+                     L1.ⓑ{I}V ≅[d, e] L2. ⓑ{I}V.
+#I #L1 #L2 #V #d #e #HL12 #Hd <(ylt_inv_O1 … Hd) /2 width=1 by lcoeq_succ/
+qed.
+
+lemma lcoeq_pair_O_Y: ∀L1,L2. L1 ≅[0, ∞] L2 →
+                      ∀I1,I2,V1,V2. L1.ⓑ{I1}V1 ≅[0,∞] L2.ⓑ{I2}V2.
+#L1 #L2 #HL12 #I1 #I2 #V1 #V2 lapply (lcoeq_pair I1 I2 … V1 V2 … HL12) -HL12 //
+qed.
+
+lemma lcoeq_refl: ∀L,d,e. L ≅[d, e] L.
+#L elim L -L //
+#L #I #V #IHL #d elim (ynat_cases … d) [| * #x ]
+#Hd destruct /2 width=1 by lcoeq_succ/
+#e elim (ynat_cases … e) [| * #x ]
+#He destruct /2 width=1 by lcoeq_zero, lcoeq_pair/
+qed.
+
+lemma lcoeq_O_Y: ∀L1,L2. |L1| = |L2| → L1 ≅[0, ∞] L2.
+#L1 elim L1 -L1 [| #L1 #I1 #V1 #IHL1 ]
+* [2,4: #L2 #I2 #V1 ] normalize /3 width=2 by lcoeq_pair_O_Y/
+<plus_n_Sm #H destruct
+qed.
+
+lemma lcoeq_sym: ∀d,e. symmetric … (lcoeq d e).
+#d #e #L1 #L2 #H elim H -L1 -L2
+/2 width=1 by lcoeq_zero, lcoeq_pair, lcoeq_succ/
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lcoeq_inv_atom1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 → L1 = ⋆ → L2 = ⋆.
+#L1 #L2 #d #e * -L1 -L2 -d -e //
+[ #I #L1 #L2 #V #_ #H destruct
+| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #H destruct
+| #I #L1 #L2 #V #d #e #_ #H destruct
+]
+qed-.
+
+lemma lcoeq_inv_atom1: ∀L2,d,e. ⋆ ≅[d, e] L2 → L2 = ⋆.
+/2 width=5 by lcoeq_inv_atom1_aux/ qed-.
+
+fact lcoeq_inv_zero1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
+                          ∀J,K1,W. L1 = K1.ⓑ{J}W → d = 0 → e = 0 →
+                          ∃∃K2. K1 ≅[0, 0] K2 & L2 = K2.ⓑ{J}W.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #J #K1 #W #H destruct
+| #I #L1 #L2 #V #HL12 #J #K1 #W #H destruct /2 width=3 by ex2_intro/
+| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #J #K1 #W #_ #_ #H elim (ysucc_inv_O_dx … H)
+| #I #L1 #L2 #V #d #e #_ #J #K1 #W #_ #H elim (ysucc_inv_O_dx … H)
+]
+qed-.
+
+lemma lcoeq_inv_zero1: ∀I,K1,L2,V. K1.ⓑ{I}V ≅[0, 0] L2 →
+                       ∃∃K2. K1 ≅[0, 0] K2 & L2 = K2.ⓑ{I}V.
+/2 width=7 by lcoeq_inv_zero1_aux/ qed-.
+
+fact lcoeq_inv_pair1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
+                          ∀J1,K1,W1. L1 = K1.ⓑ{J1}W1 → d = 0 → 0 < e →
+                          ∃∃J2,K2,W2. K1 ≅[0, ⫰e] K2 & L2 = K2.ⓑ{J2}W2.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #J1 #K1 #W1 #H destruct
+| #I #L1 #L2 #V #_ #J1 #K1 #W1 #_ #_ #H elim (ylt_yle_false … H) //
+| #I1 #I2 #L1 #L2 #V1 #V2 #e #HL12 #J1 #K1 #W1 #H #_ #_ destruct
+  /2 width=5 by ex2_3_intro/
+| #I #L1 #L2 #V #d #e #_ #J1 #K1 #W1 #_ #H elim (ysucc_inv_O_dx … H)
+]
+qed-.
+
+lemma lcoeq_inv_pair1: ∀I1,K1,L2,V1,e. K1.ⓑ{I1}V1 ≅[0, e] L2 → 0 < e →
+                       ∃∃I2,K2,V2. K1 ≅[0, ⫰e] K2 & L2 = K2.ⓑ{I2}V2.
+/2 width=7 by lcoeq_inv_pair1_aux/ qed-.
+
+fact lcoeq_inv_succ1_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
+                          ∀J,K1,W. L1 = K1.ⓑ{J}W → 0 < d →
+                          ∃∃K2. K1 ≅[⫰d, e] K2 & L2 = K2.ⓑ{J}W.
+#L1 #L2 #d #e * -L1 -L2 -d -e
+[ #d #e #J #K1 #W #H destruct
+| #I #L1 #L2 #V #_ #J #K1 #W #_ #H elim (ylt_yle_false … H) //
+| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #J #K1 #W #_ #H elim (ylt_yle_false … H) //
+| #I #L1 #L2 #V #d #e #HL12 #J #K1 #W #H destruct /2 width=3 by ex2_intro/
+]
+qed-.
+
+lemma lcoeq_inv_succ1: ∀I,K1,L2,V,d,e. K1.ⓑ{I}V ≅[d, e] L2 → 0 < d →
+                       ∃∃K2. K1 ≅[⫰d, e] K2 & L2 = K2.ⓑ{I}V.
+/2 width=3 by lcoeq_inv_succ1_aux/ qed-.
+
+lemma lcoeq_inv_atom2: ∀L1,d,e. L1 ≅[d, e] ⋆ → L1 = ⋆.
+/3 width=3 by lcoeq_inv_atom1, lcoeq_sym/ qed-.
+
+lemma lcoeq_inv_zero2: ∀I,K2,L1,V. L1 ≅[0, 0] K2.ⓑ{I}V →
+                       ∃∃K1. K1 ≅[0, 0] K2 & L1 = K1.ⓑ{I}V.
+#I #K2 #L1 #V #H elim (lcoeq_inv_zero1 … (lcoeq_sym … H)) -H
+/3 width=3 by lcoeq_sym, ex2_intro/
+qed-.
+
+lemma lcoeq_inv_pair2: ∀I2,K2,L1,V2,e. L1 ≅[0, e] K2.ⓑ{I2}V2 → 0 < e →
+                       ∃∃I1,K1,V1. K1 ≅[0, ⫰e] K2 & L1 = K1.ⓑ{I1}V1.
+#I2 #K2 #L1 #V2 #e #H #He elim (lcoeq_inv_pair1 … (lcoeq_sym … H)) -H
+/3 width=5 by lcoeq_sym, ex2_3_intro/
+qed-.
+
+lemma lcoeq_inv_succ2: ∀I,K2,L1,V,d,e. L1 ≅[d, e] K2.ⓑ{I}V → 0 < d →
+                       ∃∃K1. K1 ≅[⫰d, e] K2 & L1 = K1.ⓑ{I}V.
+#I #K2 #L1 #V #d #e #H #Hd elim (lcoeq_inv_succ1 … (lcoeq_sym … H)) -H
+/3 width=3 by lcoeq_sym, ex2_intro/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lcoeq_fwd_length: ∀L1,L2,d,e. L1 ≅[d, e] L2 → |L2| ≤ |L1|.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e normalize /2 width=1 by le_S_S/
+qed-.
+
+(* Advanced inversionn lemmas ***********************************************)
+
+fact lcoeq_inv_O2_aux: ∀L1,L2,d,e. L1 ≅[d, e] L2 → e = 0 → L1 = L2.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e /3 width=1 by eq_f3/
+#I1 #I2 #L1 #L2 #V1 #V2 #e #_ #_ #H elim (ysucc_inv_O_dx … H)
+qed-.
+
+lemma lcoeq_inv_O2: ∀L1,L2,d. L1 ≅[d, 0] L2 → L1 = L2.
+/2 width=4 by lcoeq_inv_O2_aux/ qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq_lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/lcoeq_lcoeq.etc
new file mode 100644 (file)
index 0000000..2977753
--- /dev/null
@@ -0,0 +1,29 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lcoeq.ma".
+
+(* COEQUIVALENCE FOR LOCAL ENVIRONMENTS *************************************)
+
+(* Main properties **********************************************************)
+
+theorem lcoeq_trans: ∀d,e. Transitive … (lcoeq d e).
+#d #e #L1 #L2 #H elim H -L1 -L2 -d -e //
+[ #I #L1 #L #V #HL1 #_ #X #H >(lcoeq_inv_O2 … HL1) -HL1 //
+| #I1 #I #L1 #L #V1 #V #e #_ #IHL1 #X #H elim (lcoeq_inv_pair1 … H) -H //
+  #I2 #L2 #V2 #HL2 #H destruct /3 width=1 by lcoeq_pair/
+| #I #L1 #L #V #d #e #_ #IHL1 #X #H elim (lcoeq_inv_succ1 … H) -H //
+  #L2 #HL2 #H destruct /3 width=1 by lcoeq_succ/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/ldrop_lcoeq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcoeq/ldrop_lcoeq.etc
new file mode 100644 (file)
index 0000000..4891949
--- /dev/null
@@ -0,0 +1,51 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_minus.ma".
+include "basic_2/grammar/lcoeq.ma".
+include "basic_2/relocation/ldrop.ma".
+
+(* BASIC SLICING FOR LOCAL ENVIRONMENTS *************************************)
+
+(* Properties on coequivalence **********************************************)
+
+lemma lcoeq_ldrop_trans_lt: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
+                            ∀I,K2,W,s,i. ⇩[s, 0, i] L2 ≡ K2.ⓑ{I}W → i < d →
+                            ∃∃K1. K1 ≅[⫰(d-i), e] K2 & ⇩[s, 0, i] L1 ≡ K1.ⓑ{I}W.
+#L1 #L2 #d #e #H elim H -L1 -L2 -d -e
+[ #d #e #J #K2 #W #s #i #H
+  elim (ldrop_inv_atom1 … H) -H #H destruct
+| #I #L1 #L2 #V #_ #_ #J #K2 #W #s #i #_ #H
+  elim (ylt_yle_false … H) //
+| #I1 #I2 #L1 #L2 #V1 #V2 #e #_ #_ #J #K2 #W #s #i #_ #H
+  elim (ylt_yle_false … H) //
+| #I #L1 #L2 #V #d #e #HL12 #IHL12 #J #K2 #W #s #i #H
+  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK1 [ -IHL12 | -HL12 ]
+  [ #_ destruct >ypred_succ
+    /2 width=3 by ldrop_pair, ex2_intro/
+  | lapply (ylt_inv_O1 i ?) /2 width=1 by ylt_inj/
+    #H <H -H #H lapply (ylt_inv_succ … H) -H
+    #Hie elim (IHL12 … HLK1) -IHL12 -HLK1 // -Hie
+    >yminus_succ <yminus_inj /3 width=3 by ldrop_drop_lt, ex2_intro/
+  ]
+]
+qed-.
+
+lemma lcoeq_ldrop_conf_lt: ∀L1,L2,d,e. L1 ≅[d, e] L2 →
+                           ∀I,K1,W,s,i. ⇩[s, 0, i] L1 ≡ K1.ⓑ{I}W → i < d →
+                           ∃∃K2. K1 ≅[⫰(d-i), e] K2 & ⇩[s, 0, i] L2 ≡ K2.ⓑ{I}W.
+#L1 #L2 #d #e #HL12 #I #K1 #W #s #i #HLK1 #Hid
+elim (lcoeq_ldrop_trans_lt … (lcoeq_sym … HL12) … HLK1) // -L1 -Hid
+/3 width=3 by lcoeq_sym, ex2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs.etc
new file mode 100644 (file)
index 0000000..d815739
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L1 ⊢ ⬌* break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'CPConvStar $L1 $L2 }.
+
+include "basic_2/grammar/lenv_px_sn.ma".
+include "basic_2/equivalence/cpcs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *************)
+
+definition lcpcs: relation lenv ≝ lpx_sn … cpcs.
+
+interpretation "context-sensitive parallel equivalence (local environment)"
+   'CPConvStar L1 L2 = (lcpcs L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lcpcs_inv_atom1: ∀L2. ⋆ ⊢ ⬌* L2 → L2 = ⋆.
+/2 width=2 by lpx_sn_inv_atom1/ qed-.
+
+lemma lcpcs_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ⬌* L2 →
+                       ∃∃K2,V2. K1 ⊢ ⬌* K2 & K1 ⊢ V1 ⬌* V2 & L2 = K2. ⓑ{I} V2.
+/2 width=1 by lpx_sn_inv_pair1/ qed-.
+
+lemma lcpcs_inv_atom2: ∀L1. L1 ⊢ ⬌* ⋆ → L1 = ⋆.
+/2 width=2 by lpx_sn_inv_atom2/ qed-.
+
+lemma lcpcs_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ⬌* K2. ⓑ{I} V2 →
+                       ∃∃K1,V1. K1 ⊢ ⬌* K2 & K1 ⊢ V1 ⬌* V2 & L1 = K1. ⓑ{I} V1.
+/2 width=1 by lpx_sn_inv_pair2/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lcpcs_fwd_length: ∀L1,L2. L1 ⊢ ⬌* L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lcpcs/lcpcs_ltpr.etc
new file mode 100644 (file)
index 0000000..ecc6be8
--- /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/reducibility/ltpr.ma".
+include "basic_2/equivalence/lcpcs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *************)
+
+(* Properties on context-free parallel reduction for local environments *****)
+
+lemma ltpr_lcpcs: ∀L1,L2. L1 ➡ L2 → L1 ⊢ ⬌* L2.
+#L1 #L2 #H elim H -L1 -L2 // /4 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lleq_alt/lazyeqalt_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq_fqus.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/lleq_alt/lleq_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/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_2A1/llneq/lazynegatedeq_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lazynegatedeq_4.etc
new file mode 100644 (file)
index 0000000..6b0cb85
--- /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 @{ 'LazyNegatedEq $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lazynegatedeqalt_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lazynegatedeqalt_4.etc
new file mode 100644 (file)
index 0000000..b150f63
--- /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 @{ 'LazyNegatedEqAlt $T $d $L1 $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq.etc
new file mode 100644 (file)
index 0000000..d41a4e8
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazynegatedeq_4.ma".
+include "basic_2/substitution/lleq.ma".
+
+(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
+
+definition llneq: relation4 ynat term lenv lenv ≝
+                  λd,T,L1,L2. |L1| = |L2| ∧ (L1 ⋕[T, d] L2 → ⊥).
+
+interpretation
+   "negated lazy equivalence (local environment)"
+   'LazyNegatedEq T d L1 L2 = (llneq d T L1 L2).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_alt.etc
new file mode 100644 (file)
index 0000000..00eb2c3
--- /dev/null
@@ -0,0 +1,68 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazynegatedeqalt_4.ma".
+include "basic_2/substitution/lleq_lleq.ma".
+include "basic_2/substitution/llneq.ma".
+
+(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
+
+(* alternative definition of llneq *)
+inductive llneqa: relation4 ynat term lenv lenv ≝
+| llneqa_neq:     ∀I1,I2,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
+                  ⇩[i]L1 ≡ K1.ⓑ{I1}V1 → ⇩[i]L2 ≡ K2.ⓑ{I2}V2 →
+                  |K1| = |K2| → (V1 = V2 → ⊥) → llneqa d (#i) L1 L2
+| llneqa_eq :     ∀I1,I2,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
+                  ⇩[i]L1 ≡ K1.ⓑ{I1}V → ⇩[i]L2 ≡ K2.ⓑ{I2}V →
+                  llneqa 0 (V) K1 K2 → llneqa d (#i) L1 L2
+| llneqa_bind_sn: ∀a,I,L1,L2,V,T,d.
+                  llneqa d V L1 L2 → llneqa d (ⓑ{a,I}V.T) L1 L2
+| llneqa_bind_dx: ∀a,I,L1,L2,V,T,d.
+                  llneqa (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) → llneqa d (ⓑ{a,I}V.T) L1 L2
+| llneqa_flat_sn: ∀I,L1,L2,V,T,d.
+                  llneqa d V L1 L2 → llneqa d (ⓕ{I}V.T) L1 L2
+| llneqa_flat_dx: ∀I,L1,L2,V,T,d.
+                  llneqa d T L1 L2 → llneqa d (ⓕ{I}V.T) L1 L2
+.
+
+interpretation
+   "negated lazy equivalence (local environment) alternative"
+   'LazyNegatedEqAlt T d L1 L2 = (llneqa d T L1 L2).
+
+(* Main properties **********************************************************)
+
+theorem llneq_llneqa: ∀T,L1,L2,d. L1 ⧣[T, d] L2 → L1 ⧣⧣[T, d] L2.
+#T #L1 @(f2_ind … rfw … L1 T) -L1 -T
+#n #IH #L1 * *
+[ #k #Hn #L2 #d * #HL12 #H elim H /2 width=1 by lleq_sort/
+| #i #Hn #L2 #d * #HL12 #H elim (ylt_split i d) #Hdi
+  [ elim H /2 width=1 by lleq_skip/ ]
+  elim (lt_or_ge i (|L1|)) #HiL1
+  [2: elim H /3 width=3 by lleq_free, le_repl_sn_aux/ ]
+  elim (ldrop_O1_lt … HiL1) #I1 #K1 #V1 #HLK1
+  elim (ldrop_O1_lt L2 i) /2 width=1 by/ #I2 #K2 #V2 #HLK2
+  lapply (ldrop_fwd_length_eq1 … HLK1 HLK2 HL12) normalize
+  elim (eq_term_dec V1 V2) #HnV12 destruct
+  [2: #H @(llneqa_neq … HLK1 … HLK2) /2 width=1 by/ ] (**) (* explicit constructor *)
+  elim (lleq_dec V2 K1 K2 0) #HnV2 [ elim H /2 width=8 by lleq_lref/ ]
+  #H @(llneqa_eq … HLK1 … HLK2) /4 width=2 by ldrop_fwd_rfw, conj/ (**) (* explicit constructor *)
+| #p #Hn #L2 #d * #HL12 #H elim H /2 width=1 by lleq_gref/
+| #a #I #V #T #Hn #L2 #d * #HL12 #H destruct elim (nlleq_inv_bind … H) -H
+  [ /5 width=1 by llneqa_bind_sn, conj/
+  | #H @llneqa_bind_dx @IH // @conj normalize /2 width=1 by/
+  ]
+| #I #V #T #Hn #L2 #d * #HL12 #H destruct elim (nlleq_inv_flat … H) -H
+  /5 width=1 by llneqa_flat_dx, llneqa_flat_sn, conj/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_ext.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/llneq_ext.etc
new file mode 100644 (file)
index 0000000..235d869
--- /dev/null
@@ -0,0 +1,33 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llneq_alt.ma".
+
+(* NEGATED LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma llneq_inv_atom1: ∀L1,L2,T,d. L1 ⧣⧣[T, d] L2 → |L1| ≤ d → ⊥.
+#L1 #L2 #T #d #H elim H -L1 -L2 -T -d /2 width=1 by/
+[ #I1 #I2 #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #_ #_ #_
+  >(ldrop_fwd_length … HLK1) -HLK1 normalize
+  #H lapply (yle_trans … H … Hdi) -d
+  /3 width=4 by yle_inv_inj, le_plus_xySz_x_false/
+| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #_ #_ #_
+  >(ldrop_fwd_length … HLK1) -HLK1 normalize
+  #H lapply (yle_trans … H … Hdi) -d
+  /3 width=4 by yle_inv_inj, le_plus_xySz_x_false/
+| #a #I #L1 <yplus_inj /4 width=1 by yle_succ/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lpxs_llneq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llneq/lpxs_llneq.etc
new file mode 100644 (file)
index 0000000..556d59b
--- /dev/null
@@ -0,0 +1,67 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llneq_alt.ma".
+include "basic_2/computation/lpxs_ldrop.ma".
+include "basic_2/computation/lpxs_cpxs.ma".
+
+(* SN EXTENDED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ******************)
+
+(* Forward lemmas on negated lazy equivalence for local environments ********)
+
+lemma lpxs_llneq_fwd_cpxs: ∀h,g,G,L1,L2,T,d. L1 ⧣⧣[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
+                           ∃∃T1,T2. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] T1 & ⦃G, L2⦄ ⊢ T ▶*[d, ∞] T2 &
+                                    ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 & (T1 = T2 → ⊥).
+#h #g #G #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+[ #I1 #I2 #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #_ #HnV12 #HL12
+  elim (lpxs_ldrop_conf … HLK1 … HL12) -HL12 #Y #H #HY
+  elim (lpxs_inv_pair1 … H) -H #Z #X #_ #HV12 #H destruct
+  lapply (ldrop_mono … HY … HLK2) -HY #H destruct
+  lapply (ldrop_fwd_drop2 … HLK1) #H2LK1
+  elim (lift_total V1 0 (i+1)) #T1 #HVT1
+  elim (lift_total V2 0 (i+1)) #T2 #HVT2
+  @(ex4_2_intro … T1 T2) /3 width=10 by cpxs_lift, cpys_subst, lift_inj/ (**) (* explicit constructor *)
+| #I1 #I2 #L1 #L2 #K1 #K2 #V #d #i #Hdi #HLK1 #HLK2 #_ #IHK12 #HL12
+  elim (lpxs_ldrop_conf … HLK1 … HL12) -HL12 #Y #H #HY
+  elim (lpxs_inv_pair1 … H) -H #Z #X #HK12 #_ #H destruct
+  lapply (ldrop_mono … HY … HLK2) -HY #H destruct
+  elim (IHK12 HK12) -IHK12 -HK12 #V1 #V2 #HV1 #HV2 #HV12 #HnV12
+  lapply (ldrop_fwd_drop2 … HLK1) #H2LK1
+  elim (lift_total V1 0 (i+1)) #T1 #HVT1
+  elim (lift_total V2 0 (i+1)) #T2 #HVT2
+  @(ex4_2_intro … T1 T2) /3 width=10 by cpxs_lift, cpys_subst_Y2, lift_inj/ (**) (* explicit constructor *)
+| #a #I #L1 #L2 #V #T #d #_ #IHV #HL12 elim (IHV HL12) -IHV -HL12
+  #V1 #V2 #HV1 #HV2 #HV12 #HnV12
+  @(ex4_2_intro … (ⓑ{a,I}V1.T) (ⓑ{a,I}V2.T)) /2 width=1 by cpys_bind, cpxs_pair_sn/
+  #H destruct /2 width=1 by/
+| #a #I #L1 #L2 #V #T #d #_ #IHT #HL12 elim (IHT ?) /2 width=1 by lpxs_pair_refl/ -IHT -HL12
+  #T1 #T2 #HT1 #HT2 #HT12 #HnT12
+  @(ex4_2_intro … (ⓑ{a,I}V.T1) (ⓑ{a,I}V.T2)) /2 width=1 by cpys_bind, cpxs_bind_dx/
+  #H destruct /2 width=1 by/
+| #I #L1 #L2 #V #T #d #_ #IHV #HL12 elim (IHV HL12) -IHV -HL12
+  #V1 #V2 #HV1 #HV2 #HV12 #HnV12
+  @(ex4_2_intro … (ⓕ{I}V1.T) (ⓕ{I}V2.T)) /2 width=1 by cpys_flat, cpxs_pair_sn/
+  #H destruct /2 width=1 by/
+| #I #L1 #L2 #V #T #d #_ #IHT #HL12 elim (IHT HL12) -IHT -HL12
+  #T1 #T2 #HT1 #HT2 #HT12 #HnT12
+  @(ex4_2_intro … (ⓕ{I}V.T1) (ⓕ{I}V.T2)) /2 width=1 by cpys_flat, cpxs_flat_dx/
+  #H destruct /2 width=1 by/
+]
+qed-.
+
+lemma lpxs_nlleq_fwd_cpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g] L2 →
+                           (L1 ⋕[T, d] L2 → ⊥) →
+                           ∃∃T1,T2. ⦃G, L1⦄ ⊢ T ▶*[d, ∞] T1 & ⦃G, L2⦄ ⊢ T ▶*[d, ∞] T2 &
+                                    ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 & (T1 = T2 → ⊥).
+/5 width=4 by lpxs_llneq_fwd_cpxs, lpxs_fwd_length, llneq_llneqa, conj/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cpcs_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cpcs_cpcs.etc
new file mode 100644 (file)
index 0000000..d31f9ca
--- /dev/null
@@ -0,0 +1,205 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/llprs_cprs.ma".
+include "basic_2/conversion/cpc_cpc.ma".
+include "basic_2/equivalence/cpcs_cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma cpcs_inv_cprs: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
+                     ∃∃T. ⦃G, L⦄ ⊢ T1 ➡* T & ⦃G, L⦄ ⊢ T2 ➡* T.
+#G #L #T1 #T2 #H @(cpcs_ind … H) -T2
+[ /3 width=3 by ex2_intro/
+| #T #T2 #_ #HT2 * #T0 #HT10 elim HT2 -HT2 #HT2 #HT0
+  [ elim (cprs_strip … HT0 … HT2) -T /3 width=3 by cprs_strap1, ex2_intro/
+  | /3 width=5 by cprs_strap2, ex2_intro/
+  ]
+]
+qed-.
+
+(* Basic_1: was: pc3_gen_sort *)
+lemma cpcs_inv_sort: ∀G,L,k1,k2. ⦃G, L⦄ ⊢ ⋆k1 ⬌* ⋆k2 → k1 = k2.
+#G #L #k1 #k2 #H elim (cpcs_inv_cprs … H) -H
+#T #H1 >(cprs_inv_sort1 … H1) -T #H2
+lapply (cprs_inv_sort1 … H2) -L #H destruct //
+qed-.
+
+lemma cpcs_inv_abst1: ∀a,G,L,W1,T1,T. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ⬌* T →
+                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T ➡* ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
+#a #G #L #W1 #T1 #T #H
+elim (cpcs_inv_cprs … H) -H #X #H1 #H2
+elim (cprs_inv_abst1 … H1) -H1 #W2 #T2 #HW12 #HT12 #H destruct
+/3 width=6 by cprs_bind, ex2_2_intro/
+qed-.
+
+lemma cpcs_inv_abst2: ∀a,G,L,W1,T1,T. ⦃G, L⦄ ⊢ T ⬌* ⓛ{a}W1.T1 →
+                      ∃∃W2,T2. ⦃G, L⦄ ⊢ T ➡* ⓛ{a}W2.T2 & ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2.
+/3 width=1 by cpcs_inv_abst1, cpcs_sym/ qed-.
+
+(* Basic_1: was: pc3_gen_sort_abst *)
+lemma cpcs_inv_sort_abst: ∀a,G,L,W,T,k. ⦃G, L⦄ ⊢ ⋆k ⬌* ⓛ{a}W.T → ⊥.
+#a #G #L #W #T #k #H
+elim (cpcs_inv_cprs … H) -H #X #H1
+>(cprs_inv_sort1 … H1) -X #H2
+elim (cprs_inv_abst1 … H2) -H2 #W0 #T0 #_ #_ #H destruct
+qed-.
+
+(* Basic_1: was: pc3_gen_lift *)
+lemma cpcs_inv_lift: ∀G,L,K,s,d,e. ⇩[s, d, e] L ≡ K →
+                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
+                     ⦃G, L⦄ ⊢ U1 ⬌* U2 → ⦃G, K⦄ ⊢ T1 ⬌* T2.
+#G #L #K #s #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #HU12
+elim (cpcs_inv_cprs … HU12) -HU12 #U #HU1 #HU2
+elim (cprs_inv_lift1 … HU1 … HLK … HTU1) -U1 #T #HTU #HT1
+elim (cprs_inv_lift1 … HU2 … HLK … HTU2) -L -U2 #X #HXU
+>(lift_inj … HXU … HTU) -X -U -d -e /2 width=3 by cprs_div/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma llpr_cpcs_trans: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡[T2, 0] L2 →
+                       ⦃G, L2⦄ ⊢ T1 ⬌* T2 → ⦃G, L1⦄ ⊢ T1 ⬌* T2.
+#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
+/4 width=5 by cprs_div, cprs_llpr_trans/
+qed-.
+
+lemma llprs_cpcs_trans: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡*[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡*[T2, 0] L2 →
+                        ⦃G, L2⦄ ⊢ T1 ⬌* T2 → ⦃G, L1⦄ ⊢ T1 ⬌* T2.
+#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
+/4 width=5 by cprs_div, llprs_cprs_trans/
+qed-.
+
+lemma cpr_cprs_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡ T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
+#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_strip … HT1 … HT2) -HT1 -HT2
+/2 width=3 by cpr_cprs_div/
+qed-.
+
+lemma cprs_cpr_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡ T2 → ⦃G, L⦄ ⊢ T2 ⬌* T1.
+#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_strip … HT1 … HT2) -HT1 -HT2
+/2 width=3 by cprs_cpr_div/
+qed-.
+
+lemma cprs_conf_cpcs: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ➡* T1 → ⦃G, L⦄ ⊢ T ➡* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
+#G #L #T #T1 #T2 #HT1 #HT2 elim (cprs_conf … HT1 … HT2) -HT1 -HT2
+/2 width=3 by cprs_div/
+qed-.
+
+(* Basic_1: was: pc3_wcpr0_t *)
+(* Basic_1: note: pc3_wcpr0_t should be renamed *)
+lemma llpr_cprs_conf: ∀G,L1,L2,T1. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 →
+                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
+#G #L1 #L2 #T1 #HL12 #T2 #HT12 elim (cprs_llpr_conf_dx … HT12 … HL12) -L1
+/2 width=3 by cprs_div/
+qed-.
+
+(* Basic_1: was only: pc3_pr0_pr2_t *)
+(* Basic_1: note: pc3_pr0_pr2_t should be renamed *)
+lemma llpr_cpr_conf: ∀G,L1,L2,T1. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 →
+                     ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
+/3 width=5 by llpr_cprs_conf, cpr_cprs/ qed-.
+
+(* Basic_1: was only: pc3_thin_dx *)
+lemma cpcs_flat: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 → ∀T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
+                 ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ⬌* ⓕ{I}V2.T2.
+#G #L #V1 #V2 #HV12 #T1 #T2 #HT12
+elim (cpcs_inv_cprs … HV12) -HV12
+elim (cpcs_inv_cprs … HT12) -HT12
+/3 width=5 by cprs_flat, cprs_div/
+qed.
+
+lemma cpcs_flat_dx_cpr_rev: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V2 ➡ V1 → ∀T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T2 →
+                            ∀I. ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ⬌* ⓕ{I}V2.T2.
+/3 width=1 by cpr_cpcs_sn, cpcs_flat/ qed.
+
+lemma cpcs_bind_dx: ∀a,I,G,L,V,T1,T2. ⦃G, L.ⓑ{I}V⦄ ⊢ T1 ⬌* T2 →
+                    ⦃G, L⦄ ⊢ ⓑ{a,I}V.T1 ⬌* ⓑ{a,I}V.T2.
+#a #I #G #L #V #T1 #T2 #HT12 elim (cpcs_inv_cprs … HT12) -HT12
+/3 width=5 by cprs_div, cprs_bind/
+qed.
+
+lemma cpcs_bind_sn: ∀a,I,G,L,V1,V2,T. ⦃G, L⦄ ⊢ V1 ⬌* V2 → ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T ⬌* ⓑ{a,I}V2. T.
+#a #I #G #L #V1 #V2 #T #HV12 elim (cpcs_inv_cprs … HV12) -HV12
+/3 width=5 by cprs_div, cprs_bind/
+qed.
+
+lemma lsubr_cpcs_trans: ∀G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ⬌* T2 →
+                        ∀L2. L2 ⊑ L1 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
+#G #L1 #T1 #T2 #HT12 elim (cpcs_inv_cprs … HT12) -HT12
+/3 width=5 by cprs_div, lsubr_cprs_trans/
+qed-.
+
+(* Basic_1: was: pc3_lift *)
+lemma cpcs_lift: ∀G,L,K,s,d,e. ⇩[s, d, e] L ≡ K →
+                 ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
+                 ⦃G, K⦄ ⊢ T1 ⬌* T2 → ⦃G, L⦄ ⊢ U1 ⬌* U2.
+#G #L #K #s #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #HT12
+elim (cpcs_inv_cprs … HT12) -HT12 #T #HT1 #HT2
+elim (lift_total T d e) /3 width=12 by cprs_div, cprs_lift/
+qed.
+
+lemma cpcs_strip: ∀G,L,T1,T. ⦃G, L⦄ ⊢ T ⬌* T1 → ∀T2. ⦃G, L⦄ ⊢ T ⬌ T2 →
+                  ∃∃T0. ⦃G, L⦄ ⊢ T1 ⬌ T0 & ⦃G, L⦄ ⊢ T2 ⬌* T0.
+#G #L #T1 #T @TC_strip1 /2 width=3 by cpc_conf/ qed-.
+
+(* More inversion lemmas ****************************************************)
+
+axiom cpcs_inv_abst_sn: ∀a1,a2,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a1}W1.T1 ⬌* ⓛ{a2}W2.T2 →
+                        ∧∧ ⦃G, L⦄ ⊢ W1 ⬌* W2 & ⦃G, L.ⓛW1⦄ ⊢ T1 ⬌* T2 & a1 = a2.
+(*
+#a1 #a2 #G #L #W1 #W2 #T1 #T2 #H
+elim (cpcs_inv_cprs … H) -H #T #H1 #H2
+elim (cprs_inv_abst1 … H1) -H1 #W0 #T0 #HW10 #HT10 #H destruct
+elim (cprs_inv_abst1 … H2) -H2 #W #T #HW2 #HT2 #H destruct
+lapply (llprs_cprs_conf … (L.ⓛW) … HT2) /2 width=1 by llprs_pair/ -HT2 #HT2
+lapply (llprs_cpcs_trans … (L.ⓛW1) … HT2) /2 width=1 by llprs_pair/ -HT2 #HT2
+/4 width=3 by and3_intro, cprs_div, cpcs_cprs_div, cpcs_sym/
+qed-.
+*)
+lemma cpcs_inv_abst_dx: ∀a1,a2,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a1}W1.T1 ⬌* ⓛ{a2}W2.T2 →
+                        ∧∧ ⦃G, L⦄ ⊢ W1 ⬌* W2 & ⦃G, L.ⓛW2⦄ ⊢ T1 ⬌* T2 & a1 = a2.
+#a1 #a2 #G #L #W1 #W2 #T1 #T2 #HT12 lapply (cpcs_sym … HT12) -HT12
+#HT12 elim (cpcs_inv_abst_sn … HT12) -HT12 /3 width=1 by cpcs_sym, and3_intro/
+qed-.
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was pc3_t *)
+theorem cpcs_trans: ∀G,L,T1,T. ⦃G, L⦄ ⊢ T1 ⬌* T → ∀T2. ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
+#G #L #T1 #T #HT1 #T2 @(trans_TC … HT1) qed-.
+
+theorem cpcs_canc_sn: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T ⬌* T1 → ⦃G, L⦄ ⊢ T ⬌* T2 → ⦃G, L⦄ ⊢ T1 ⬌* T2.
+/3 width=3 by cpcs_trans, cpcs_sym/ qed-.
+
+theorem cpcs_canc_dx: ∀G,L,T,T1,T2. ⦃G, L⦄ ⊢ T1 ⬌* T → ⦃G, L⦄ ⊢ T2 ⬌* T → ⦃G, L⦄ ⊢ T1 ⬌* T2.
+/3 width=3 by cpcs_trans, cpcs_sym/ qed-.
+
+lemma cpcs_bind1: ∀a,I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 →
+                  ∀T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ⬌* T2 →
+                  ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T1 ⬌* ⓑ{a,I}V2. T2.
+/3 width=3 by cpcs_trans, cpcs_bind_sn, cpcs_bind_dx/ qed.
+
+lemma cpcs_bind2: ∀a,I,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ⬌* V2 →
+                  ∀T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ⬌* T2 →
+                  ⦃G, L⦄ ⊢ ⓑ{a,I}V1. T1 ⬌* ⓑ{a,I}V2. T2.
+/3 width=3 by cpcs_trans, cpcs_bind_sn, cpcs_bind_dx/ qed.
+
+(* Basic_1: was: pc3_wcpr0 *)
+lemma llpr_cpcs_conf: ∀G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ ➡[T1, 0] L2 → ⦃G, L1⦄ ⊢ ➡[T2, 0] L2 →
+                      ⦃G, L1⦄ ⊢ T1 ⬌* T2 → ⦃G, L2⦄ ⊢ T1 ⬌* T2.
+#G #L1 #L2 #T1 #T2 #HT1 #HT2 #H elim (cpcs_inv_cprs … H) -H
+/3 width=5 by cpcs_canc_dx, llpr_cprs_conf/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_cprs.etc
new file mode 100644 (file)
index 0000000..a85488c
--- /dev/null
@@ -0,0 +1,166 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llpr_llpr.ma".
+include "basic_2/computation/cprs_lift.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: pr3_t *)
+(* Basic_1: includes: pr1_t *)
+theorem cprs_trans: ∀G,L. Transitive … (cprs G L).
+normalize /2 width=3 by trans_TC/ qed-. 
+
+(* Basic_1: was: pr3_confluence *)
+(* Basic_1: includes: pr1_confluence *)
+theorem cprs_conf: ∀G,L. confluent2 … (cprs G L) (cprs G L).
+normalize /3 width=3 by cpr_conf, TC_confluent2/ qed-.
+
+theorem cprs_bind: ∀a,I,G,L,V1,V2,T1,T2. ⦃G, L.ⓑ{I}V1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
+                   ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
+#a #I #G #L #V1 #V2 #T1 #T2 #HT12 #H @(cprs_ind … H) -V2
+/3 width=5 by cprs_trans, cprs_bind_dx/
+qed.
+
+(* Basic_1: was: pr3_flat *)
+theorem cprs_flat: ∀I,G,L,V1,V2,T1,T2. ⦃G, L⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
+                   ⦃G, L⦄ ⊢ ⓕ{I}V1.T1 ➡* ⓕ{I}V2.T2.
+#I #G #L #V1 #V2 #T1 #T2 #HT12 #H @(cprs_ind … H) -V2
+/3 width=3 by cprs_flat_dx, cprs_strap1, cpr_pair_sn/
+qed.
+
+theorem cprs_beta_rc: ∀a,G,L,V1,V2,W1,W2,T1,T2.
+                      ⦃G, L⦄ ⊢ V1 ➡ V2 → ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ W1 ➡* W2 →
+                      ⦃G, L⦄ ⊢ ⓐV1.ⓛ{a}W1.T1 ➡* ⓓ{a}ⓝW2.V2.T2.
+#a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #HV12 #HT12 #H @(cprs_ind … H) -W2 /2 width=1 by cprs_beta_dx/
+#W #W2 #_ #HW2 #IHW1 (**) (* fulla uto too slow 14s *)
+@(cprs_trans … IHW1) -IHW1 /3 width=1 by cprs_flat_dx, cprs_bind/
+qed.
+
+theorem cprs_beta: ∀a,G,L,V1,V2,W1,W2,T1,T2.
+                   ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 → ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L⦄ ⊢ V1 ➡* V2 →
+                   ⦃G, L⦄ ⊢ ⓐV1.ⓛ{a}W1.T1 ➡* ⓓ{a}ⓝW2.V2.T2.
+#a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #HT12 #HW12 #H @(cprs_ind … H) -V2 /2 width=1 by cprs_beta_rc/
+#V #V2 #_ #HV2 #IHV1
+@(cprs_trans … IHV1) -IHV1 /3 width=1 by cprs_flat_sn, cprs_bind/
+qed.
+
+theorem cprs_theta_rc: ∀a,G,L,V1,V,V2,W1,W2,T1,T2.
+                       ⦃G, L⦄ ⊢ V1 ➡ V → ⇧[0, 1] V ≡ V2 → ⦃G, L.ⓓW1⦄ ⊢ T1 ➡* T2 →
+                       ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L⦄ ⊢ ⓐV1.ⓓ{a}W1.T1 ➡* ⓓ{a}W2.ⓐV2.T2.
+#a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #HV1 #HV2 #HT12 #H elim H -W2
+/3 width=5 by cprs_trans, cprs_theta_dx, cprs_bind_dx/
+qed.
+
+theorem cprs_theta: ∀a,G,L,V1,V,V2,W1,W2,T1,T2.
+                    ⇧[0, 1] V ≡ V2 → ⦃G, L⦄ ⊢ W1 ➡* W2 → ⦃G, L.ⓓW1⦄ ⊢ T1 ➡* T2 →
+                    ⦃G, L⦄ ⊢ V1 ➡* V → ⦃G, L⦄ ⊢ ⓐV1.ⓓ{a}W1.T1 ➡* ⓓ{a}W2.ⓐV2.T2.
+#a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #HV2 #HW12 #HT12 #H @(TC_ind_dx … V1 H) -V1
+/3 width=3 by cprs_trans, cprs_theta_rc, cprs_flat_dx/
+qed.
+
+(* Advanced inversion lemmas ************************************************)
+
+(* Basic_1: was pr3_gen_appl *)
+lemma cprs_inv_appl1: ∀G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓐV1.T1 ➡* U2 →
+                      ∨∨ ∃∃V2,T2.       ⦃G, L⦄ ⊢ V1 ➡* V2 & ⦃G, L⦄ ⊢ T1 ➡* T2 &
+                                        U2 = ⓐV2. T2
+                       | ∃∃a,W,T.       ⦃G, L⦄ ⊢ T1 ➡* ⓛ{a}W.T &
+                                        ⦃G, L⦄ ⊢ ⓓ{a}ⓝW.V1.T ➡* U2
+                       | ∃∃a,V0,V2,V,T. ⦃G, L⦄ ⊢ V1 ➡* V0 & ⇧[0,1] V0 ≡ V2 &
+                                        ⦃G, L⦄ ⊢ T1 ➡* ⓓ{a}V.T &
+                                        ⦃G, L⦄ ⊢ ⓓ{a}V.ⓐV2.T ➡* U2.
+#G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /3 width=5 by or3_intro0, ex3_2_intro/
+#U #U2 #_ #HU2 * *
+[ #V0 #T0 #HV10 #HT10 #H destruct
+  elim (cpr_inv_appl1 … HU2) -HU2 *
+  [ #V2 #T2 #HV02 #HT02 #H destruct /4 width=5 by cprs_strap1, or3_intro0, ex3_2_intro/
+  | #a #V2 #W #W2 #T #T2 #HV02 #HW2 #HT2 #H1 #H2 destruct
+    lapply (cprs_strap1 … HV10 … HV02) -V0 #HV12
+    lapply (lsubr_cpr_trans … HT2 (L.ⓓⓝW.V1) ?) -HT2
+    /5 width=5 by cprs_flat_dx, cpr_cprs, cprs_bind, lsubr_abst, ex2_3_intro, or3_intro1/
+  | #a #V #V2 #W0 #W2 #T #T2 #HV0 #HV2 #HW02 #HT2 #H1 #H2 destruct
+    @or3_intro2 @(ex4_5_intro … HV2 HT10) /3 width=3 by cprs_flat_sn, cprs_strap1, cpr_cprs, cprs_bind/ (**) (* full auto is too slow 11s *)
+  ]
+| /4 width=9 by cprs_strap1, or3_intro1, ex2_3_intro/
+| /4 width=11 by cprs_strap1, or3_intro2, ex4_5_intro/
+]
+qed-.
+
+(* Properties concerning sn parallel reduction on local environments ********)
+
+(* Basic_1: was just: pr3_pr2_pr2_t *)
+(* Basic_1: includes: pr3_pr0_pr2_t *)
+lemma llpr_cpr_trans: ∀G. s_r_transitive … (cpr G) (llpr G 0).
+#G #L2 #T1 #T2 #HT12 elim HT12 -G -L2 -T1 -T2
+[ /2 width=3 by/
+| #G #L2 #K2 #V0 #V2 #W2 #i #HLK2 #_ #HVW2 #IHV02 #L1 #HL12
+  elim (llpr_inv_lref_ge_dx … HL12 … HLK2) -L2
+  /5 width=7 by cprs_delta, cprs_strap2, llpr_cpr_conf/
+| #a #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (llpr_inv_bind_O … HL12) -HL12 /4 width=1 by cprs_bind/
+| #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (llpr_inv_flat … HL12) -HL12 /3 width=1 by cprs_flat/
+| #G #L2 #V2 #T1 #T #T2 #_ #HT2 #IHT1 #L1 #HL12
+  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_zeta/
+| #G #L2 #V2 #T1 #T2 #HT12 #IHT12 #L1 #HL12
+  elim (llpr_inv_flat … HL12) /3 width=1 by cprs_tau/
+| #a #G #L2 #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #L1 #HL12
+  elim (llpr_inv_flat … HL12) -HL12 #HV1 #HL12
+  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_beta/
+| #a #G #L2 #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #L1 #HL12
+  elim (llpr_inv_flat … HL12) -HL12 #HV1 #HL12
+  elim (llpr_inv_bind_O … HL12) /3 width=3 by cprs_theta/
+]
+qed-.
+
+lemma cpr_bind2: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡ V2 → ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡ T2 →
+                 ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
+/4 width=9 by llpr_cpr_trans, cprs_bind_dx, llpr_bind_repl_O/ qed.
+
+(* Advanced properties ******************************************************)
+
+(* Basic_1: was only: pr3_pr2_pr3_t pr3_wcpr0_t *)
+lemma cprs_llpr_trans: ∀G. s_rs_transitive … (cpr G) (llpr G 0).
+/3 width=6 by llpr_cpr_trans, llpr_cpr_conf, s_r_trans_LTC1/ qed-.
+
+(* Basic_1: was: pr3_strip *)
+(* Basic_1: includes: pr1_strip *)
+lemma cprs_strip: ∀G,L. confluent2 … (cprs G L) (cpr G L).
+normalize /4 width=3 by cpr_conf, TC_strip1/ qed-.
+
+lemma cprs_llpr_conf_dx: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
+                         ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
+#G #L0 #T0 #T1 #H @(cprs_ind_dx … T0 H) -T0 /2 width=3 by ex2_intro/
+#T0 #T #HT0 #_ #IHT1 #L1 #HL01
+elim (IHT1 … L1) /2 by llpr_cpr_conf/ -IHT1 #T2 #HT12 #HT2
+elim (llpr_cpr_conf_dx … HT0 … HL01) -L0 #T3 #HT03 #HT3
+elim (cprs_strip … HT2 … HT3) -T
+/4 width=5 by cprs_strap2, cprs_strap1, ex2_intro/
+qed-.
+
+lemma cprs_llpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 →
+                         ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
+                         ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
+#G #L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cprs_llpr_conf_dx … HT01 … HL01)
+/4 width=5 by cprs_llpr_trans, cprs_llpr_conf, ex2_intro/
+qed-.
+
+lemma cprs_bind2_dx: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡ V2 →
+                     ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡* T2 →
+                     ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
+/4 width=9 by cprs_llpr_trans, cprs_bind_dx, llpr_bind_repl_O/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/cprs_lift.etc
new file mode 100644 (file)
index 0000000..27f0bb6
--- /dev/null
@@ -0,0 +1,63 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llpr_ldrop.ma".
+include "basic_2/computation/cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Advanced properties ******************************************************)
+
+(* Note: apparently this was missing in basic_1 *)
+lemma cprs_delta: ∀G,L,K,V,V2,i.
+                  ⇩[i] L ≡ K.ⓓV → ⦃G, K⦄ ⊢ V ➡* V2 →
+                  ∀W2. ⇧[0, i + 1] V2 ≡ W2 → ⦃G, L⦄ ⊢ #i ➡* W2.
+#G #L #K #V #V2 #i #HLK #H elim H -V2 [ /3 width=6 by cpr_cprs, cpr_delta/ ]
+#V1 #V2 #_ #HV12 #IHV1 #W2 #HVW2
+lapply (ldrop_fwd_drop2 … HLK) -HLK #HLK
+elim (lift_total V1 0 (i+1)) /4 width=12 by cpr_lift, cprs_strap1/
+qed.
+
+lemma cprs_llpr_conf: ∀G. s_r_confluent1 … (cprs G) (llpr G 0).
+/3 width=5 by llpr_cpr_conf, s_r_conf1_LTC1/ qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+(* Basic_1: was: pr3_gen_lref *)
+lemma cprs_inv_lref1: ∀G,L,T2,i. ⦃G, L⦄ ⊢ #i ➡* T2 →
+                      T2 = #i ∨
+                      ∃∃K,V1,T1. ⇩[i] L ≡ K.ⓓV1 & ⦃G, K⦄ ⊢ V1 ➡* T1 &
+                                 ⇧[0, i + 1] T1 ≡ T2.
+#G #L #T2 #i #H @(cprs_ind … H) -T2 /2 width=1 by or_introl/
+#T #T2 #_ #HT2 *
+[ #H destruct
+  elim (cpr_inv_lref1 … HT2) -HT2 /2 width=1 by or_introl/
+  * /4 width=6 by cpr_cprs, ex3_3_intro, or_intror/
+| * #K #V1 #T1 #HLK #HVT1 #HT1
+  lapply (ldrop_fwd_drop2 … HLK) #H0LK
+  elim (cpr_inv_lift1 … HT2 … H0LK … HT1) -H0LK -T
+ /4 width=6 by cprs_strap1, ex3_3_intro, or_intror/
+]
+qed-.
+
+(* Relocation properties ****************************************************)
+
+(* Basic_1: was: pr3_lift *)
+lemma cprs_lift: ∀G. l_liftable (cprs G).
+/3 width=10 by l_liftable_LTC, cpr_lift/ qed.
+
+(* Basic_1: was: pr3_gen_lift *)
+lemma cprs_inv_lift1: ∀G. l_deliftable_sn (cprs G).
+/3 width=6 by l_deliftable_sn_LTC, cpr_inv_lift1/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsn_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsn_5.etc
new file mode 100644 (file)
index 0000000..01ce586
--- /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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡ break [ term 46 T , break term 46 d ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LazyPRedSn $G $L1 $L2 $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsnstar_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/lazypredsnstar_5.etc
new file mode 100644 (file)
index 0000000..824933f
--- /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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡* break [ term 46 T , break term 46 d ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LazyPRedSnStar $G $L1 $L2 $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr.etc
new file mode 100644 (file)
index 0000000..e4c1a01
--- /dev/null
@@ -0,0 +1,51 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazypredsn_5.ma".
+include "basic_2/relocation/llpx_sn.ma".
+include "basic_2/reduction/cpr.ma".
+
+(* LAZY SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ************************)
+
+definition llpr: genv → relation4 ynat term lenv lenv ≝ λG. llpx_sn (cpr G).
+
+interpretation "lazy parallel reduction (local environment, sn variant)"
+   'LazyPRedSn G L1 L2 T d = (llpr G d T L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma llpr_inv_flat: ∀I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[ⓕ{I}V.T, d] L2 →
+                     ⦃G, L1⦄ ⊢ ➡[V, d] L2 ∧ ⦃G, L1⦄ ⊢ ➡[T, d] L2.
+/2 width=2 by llpx_sn_inv_flat/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma llpr_fwd_length: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L2 → |L1| = |L2|.
+/2 width=4 by llpx_sn_fwd_length/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma llpr_lref: ∀I,G,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
+                 ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                 ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 → ⦃G, K1⦄ ⊢ V1 ➡ V2 → ⦃G, L1⦄ ⊢ ➡[#i, d] L2.
+/2 width=9 by llpx_sn_lref/ qed.
+
+(* Note: lemma 250 *)
+lemma llpr_refl: ∀G,T,d. reflexive … (llpr G d T).
+/2 width=1 by llpx_sn_refl/ qed.
+
+(* Basic_1: removed theorems 5: wcpr0_gen_sort wcpr0_gen_head
+                                wcpr0_getl wcpr0_getl_back
+                                pr0_subst1_back
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_ldrop.etc
new file mode 100644 (file)
index 0000000..74f7cc6
--- /dev/null
@@ -0,0 +1,97 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fquq_alt.ma".
+include "basic_2/static/ssta_llpx_sn.ma".
+include "basic_2/reduction/cpr_lift.ma".
+include "basic_2/reduction/cpr_llpx_sn.ma".
+include "basic_2/reduction/llpr.ma".
+
+(* LAZY SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma llpr_inv_lref_ge_dx: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
+                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                    ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
+/2 width=5 by llpx_sn_inv_lref_ge_dx/ qed-.
+
+lemma llpr_inv_lref_ge_sn: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
+                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                    ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
+/2 width=5 by llpx_sn_inv_lref_ge_sn/ qed-.
+
+lemma llpr_inv_lref_ge_bi: ∀G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[#i, d] L2 → d ≤ i →
+                           ∀I1,I2,K1,K2,V1,V2.
+                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                           ∧∧ I1 = I2 & ⦃G, K1⦄ ⊢ ➡[V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2.
+/2 width=8 by llpx_sn_inv_lref_ge_bi/ qed-.
+
+lemma llpr_inv_bind_O: ∀a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡ [ⓑ{a,I}V.T, 0] L2 →
+                       ⦃G, L1⦄ ⊢ ➡[V, 0] L2 ∧ ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[T, 0] L2.ⓑ{I}V.
+/2 width=2 by llpx_sn_inv_bind_O/ qed-.
+
+lemma llpr_bind_repl_O: ∀I,G,L1,L2,V1,V2,T. ⦃G, L1.ⓑ{I}V1⦄ ⊢ ➡[T, 0] L2.ⓑ{I}V2 →
+                        ∀J,W1,W2. ⦃G, L1⦄ ⊢ ➡[W1, 0] L2 → ⦃G, L1⦄ ⊢ W1 ➡ W2 → ⦃G, L1.ⓑ{J}W1⦄ ⊢ ➡[T, 0] L2.ⓑ{J}W2.
+/2 width=4 by llpx_sn_bind_repl_O/ qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma llpr_ssta_conf: ∀h,g,G. s_r_confluent1 … (ssta h g G) (llpr G 0).
+/3 width=10 by ssta_llpx_sn_conf, cpr_lift/ qed-.
+
+lemma llpr_cpr_conf: ∀G. s_r_confluent1 … (cpr G) (llpr G 0).
+/3 width=10 by cpr_llpx_sn_conf, cpr_inv_lift1, cpr_lift/ qed-.
+
+(* Properties on context-sensitive parallel reduction for terms *************)
+
+lemma fqu_cpr_trans_dx: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
+                        ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
+                        ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+/3 width=10 by llpr_lref, cpr_pair_sn, cpr_atom, cpr_bind, cpr_flat, fqu_lref_O, fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, ldrop_pair, ex3_2_intro/
+#G #L #K #U #T #e #HLK #HUT #U2 #HU2
+elim (lift_total U2 0 (e+1)) #T2 #HUT2
+lapply (cpr_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9 by fqu_drop, ex3_2_intro/
+qed-.
+
+lemma fquq_cpr_trans_dx: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
+                         ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
+                         ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃⸮ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (fqu_cpr_trans_dx … HT12 … HTU2) /3 width=5 by fqu_fquq, ex3_2_intro/
+| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma fqu_cpr_trans_sn: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
+                        ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
+                        ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L1⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+/3 width=10 by llpr_lref, cpr_pair_sn, cpr_bind, cpr_flat, fqu_lref_O, fqu_pair_sn, fqu_bind_dx, fqu_flat_dx, ldrop_pair, ex3_2_intro/
+#G #L #K #U #T #e #HLK #HUT #U2 #HU2
+elim (lift_total U2 0 (e+1)) #T2 #HUT2
+lapply (cpr_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9 by fqu_drop, ex3_2_intro/
+qed-.
+
+lemma fquq_cpr_trans_sn: ∀G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
+                         ∀U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
+                         ∃∃L,U1. ⦃G1, L1⦄ ⊢ ➡[T1, 0] L & ⦃G1, L1⦄ ⊢ T1 ➡ U1 & ⦃G1, L, U1⦄ ⊃⸮ ⦃G2, L2, U2⦄.
+#G1 #G2 #L1 #L2 #T1 #T2 #H #U2 #HTU2 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (fqu_cpr_trans_sn … HT12 … HTU2) /3 width=5 by fqu_fquq, ex3_2_intro/
+| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_llpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpr_llpr.etc
new file mode 100644 (file)
index 0000000..4e5b9e2
--- /dev/null
@@ -0,0 +1,375 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_llpx_sn.ma".
+include "basic_2/substitution/fqup.ma".
+include "basic_2/reduction/llpr_ldrop.ma".
+
+(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
+
+(* Main properties on context-sensitive parallel reduction for terms ********)
+
+fact cpr_conf_llpr_atom_atom:
+   ∀I,G,L1,L2. ∃∃T. ⦃G, L1⦄ ⊢ ⓪{I} ➡ T & ⦃G, L2⦄ ⊢ ⓪{I} ➡ T.
+/2 width=3 by cpr_atom, ex2_intro/ qed-.
+
+fact cpr_conf_llpr_atom_delta:
+   ∀G,L0,i. (
+      ∀L,T. ⦃G, L0, #i⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀K0,V0. ⇩[i] L0 ≡ K0.ⓓV0 →
+   ∀V2. ⦃G, K0⦄ ⊢ V0 ➡ V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[#i, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[#i, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ #i ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
+#G #L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_lref_ge_sn … HL01 … HLK0) -HL01 // #K1 #V1 #HLK1 #HK01 #HV01
+elim (llpr_inv_lref_ge_sn … HL02 … HLK0) -HL02 // #K2 #W2 #HLK2 #HK02 #_
+lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
+lapply (fqup_lref … G … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1))
+/3 width=12 by cpr_lift, cpr_delta, ex2_intro/
+qed-.
+
+(* Basic_1: includes: pr0_delta_delta pr2_delta_delta *)
+fact cpr_conf_llpr_delta_delta:
+   ∀G,L0,i. (
+      ∀L,T. ⦃G, L0, #i⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀K0,V0. ⇩[i] L0 ≡ K0.ⓓV0 →
+   ∀V1. ⦃G, K0⦄ ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
+   ∀KX,VX. ⇩[i] L0 ≡ KX.ⓓVX →
+   ∀V2. ⦃G, KX⦄ ⊢ VX ➡ V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[#i, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[#i, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
+#G #L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
+#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+lapply (ldrop_mono … H … HLK0) -H #H destruct
+elim (llpr_inv_lref_ge_sn … HL01 … HLK0) -HL01 // #K1 #W1 #HLK1 #HK01 #_
+lapply (ldrop_fwd_drop2 … HLK1) -W1 #HLK1
+elim (llpr_inv_lref_ge_sn … HL02 … HLK0) -HL02 // #K2 #W2 #HLK2 #HK02 #_
+lapply (ldrop_fwd_drop2 … HLK2) -W2 #HLK2
+lapply (fqup_lref … G … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) /3 width=12 by cpr_lift, ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_bind_bind:
+   ∀a,I,G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, ⓑ{a,I}V0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0.ⓑ{I}V0⦄ ⊢ T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀T2. ⦃G, L0.ⓑ{I}V0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓑ{a,I}V0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓑ{a,I}V0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓑ{a,I}V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓑ{a,I}V2.T2 ➡ T.
+#a #I #G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
+elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) //
+elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH
+/3 width=5 by llpr_bind_repl_O, cpr_bind, ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_bind_zeta:
+   ∀G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, +ⓓV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T1 →
+   ∀T2. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ +ⓓV1.T1 ➡ T & ⦃G, L2⦄ ⊢ X2 ➡ T.
+#G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
+elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
+elim (IH … HT01 … HT02 (L1.ⓓV1) … (L2.ⓓV1)) -IH -HT01 -HT02 /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -T0 #T #HT1 #HT2
+elim (cpr_inv_lift1 … HT2 L2 … HXT2) -T2 /3 width=3 by cpr_zeta, ldrop_drop, ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_zeta_zeta:
+   ∀G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, +ⓓV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀T1. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
+   ∀T2. ⦃G, L0.ⓓV0⦄ ⊢ T0 ➡ T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[+ⓓV0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ X1 ➡ T & ⦃G, L2⦄ ⊢ X2 ➡ T.
+#G #L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
+#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_bind_O … HL01) -HL01 #H1V0 #H1T0
+elim (llpr_inv_bind_O … HL02) -HL02 #H2V0 #H2T0
+elim (IH … HT01 … HT02 (L1.ⓓV0) … (L2.ⓓV0)) -IH -HT01 -HT02 /2 width=4 by llpr_bind_repl_O/ -L0 -T0 #T #HT1 #HT2
+elim (cpr_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=2 by ldrop_drop/ #T1 #HT1 #HXT1
+elim (cpr_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=2 by ldrop_drop/ #T2 #HT2 #HXT2
+lapply (lift_inj … HT2 … HT1) -T #H destruct /2 width=3 by ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_flat_flat:
+   ∀I,G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, ⓕ{I}V0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓕ{I}V0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓕ{I}V0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓕ{I}V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓕ{I}V2.T2 ➡ T.
+#I #G #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #H1V0 #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #H2V0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) //
+elim (IH … HT01 … HT02 … H1T0 … H2T0) /3 width=5 by cpr_flat, ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_flat_tau:
+   ∀G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, ⓝV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓝV1.T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
+#G #L0 #V0 #T0 #IH #V1 #T1 #HT01
+#T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #_ #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #_ #H2T0
+elim (IH … HT01 … HT02 … H1T0 … H2T0) // -L0 -V0 -T0 /3 width=3 by cpr_tau, ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_tau_tau:
+   ∀G,L0,V0,T0. (
+      ∀L,T. ⦃G, L0, ⓝV0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀T2. ⦃G, L0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓝV0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ T1 ➡ T & ⦃G, L2⦄ ⊢ T2 ➡ T.
+#G #L0 #V0 #T0 #IH #T1 #HT01
+#T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #_ #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #_ #H2T0
+elim (IH … HT01 … HT02 … H1T0 … H2T0) // -L0 -V0 -T0 /2 width=3 by ex2_intro/
+qed-.
+
+fact cpr_conf_llpr_flat_beta:
+   ∀a,G,L0,V0,W0,T0. (
+      ∀L,T. ⦃G, L0, ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ ⓛ{a}W0.T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓐV1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}ⓝW2.V2.T2 ➡ T.
+#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #X #H
+#V2 #HV02 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (cpr_inv_abst1 … H) -H #W1 #T1 #HW01 #HT01 #H destruct
+elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
+elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
+elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
+elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/ #W #HW1 #HW2
+elim (IH … HT01 … HT02 (L1.ⓛW1) … (L2.ⓛW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
+lapply (lsubr_cpr_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /2 width=1 by lsubr_abst/ (**) (* full auto not tried *)
+/4 width=5 by cpr_bind, cpr_flat, cpr_beta, ex2_intro/
+qed-.
+
+(* Basic-1: includes:
+            pr0_cong_upsilon_refl pr0_cong_upsilon_zeta
+            pr0_cong_upsilon_cong pr0_cong_upsilon_delta
+*)
+fact cpr_conf_llpr_flat_theta:
+   ∀a,G,L0,V0,W0,T0. (
+      ∀L,T. ⦃G, L0, ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀T1. ⦃G, L0⦄ ⊢ ⓓ{a}W0.T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀U2. ⇧[O, 1] V2 ≡ U2 →
+   ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓐV1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}W2.ⓐU2.T2 ➡ T.
+#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #X #H
+#V2 #HV02 #U2 #HVU2 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
+elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
+elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
+elim (lift_total V 0 1) #U #HVU
+lapply (cpr_lift … HV2 (L2.ⓓW2) … HVU2 … HVU) -HVU2 /2 width=2 by ldrop_drop/ #HU2
+elim (cpr_inv_abbr1 … H) -H *
+[ #W1 #T1 #HW01 #HT01 #H destruct
+  elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/
+  elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0
+  /4 width=7 by cpr_bind, cpr_flat, cpr_theta, ex2_intro/
+| #T1 #HT01 #HXT1 #H destruct
+  elim (IH … HT01 … HT02 (L1.ⓓW2) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
+  elim (cpr_inv_lift1 … HT1 L1 … HXT1) -HXT1
+  /4 width=9 by cpr_flat, cpr_zeta, ldrop_drop, lift_flat, ex2_intro/
+]
+qed-.
+
+fact cpr_conf_llpr_beta_beta:
+   ∀a,G,L0,V0,W0,T0. (
+      ∀L,T. ⦃G, L0, ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀W1. ⦃G, L0⦄ ⊢ W0 ➡ W1 → ∀T1. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓛW0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓛ{a}W0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓓ{a}ⓝW1.V1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}ⓝW2.V2.T2 ➡ T.
+#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #W1 #HW01 #T1 #HT01
+#V2 #HV02 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
+elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
+elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
+elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1/ #W #HW1 #HW2
+elim (IH … HT01 … HT02 (L1.ⓛW1) … (L2.ⓛW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
+lapply (lsubr_cpr_trans … HT1 (L1.ⓓⓝW1.V1) ?) -HT1 /2 width=1 by lsubr_abst/
+lapply (lsubr_cpr_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /2 width=1 by lsubr_abst/
+/4 width=5 by cpr_bind, cpr_flat, ex2_intro/ (**) (* full auto not tried *)
+qed-.
+
+(* Basic_1: includes: pr0_upsilon_upsilon *)
+fact cpr_conf_llpr_theta_theta:
+   ∀a,G,L0,V0,W0,T0. (
+      ∀L,T. ⦃G, L0, ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃G, L, T⦄ →
+      ∀T1. ⦃G, L⦄ ⊢ T ➡ T1 → ∀T2. ⦃G, L⦄ ⊢ T ➡ T2 →
+      ∀L1. ⦃G, L⦄ ⊢ ➡[T, 0] L1 → ∀L2. ⦃G, L⦄ ⊢ ➡[T, 0] L2 →
+      ∃∃T0. ⦃G, L1⦄ ⊢ T1 ➡ T0 & ⦃G, L2⦄ ⊢ T2 ➡ T0
+   ) →
+   ∀V1. ⦃G, L0⦄ ⊢ V0 ➡ V1 → ∀U1. ⇧[O, 1] V1 ≡ U1 →
+   ∀W1. ⦃G, L0⦄ ⊢ W0 ➡ W1 → ∀T1. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T1 →
+   ∀V2. ⦃G, L0⦄ ⊢ V0 ➡ V2 → ∀U2. ⇧[O, 1] V2 ≡ U2 →
+   ∀W2. ⦃G, L0⦄ ⊢ W0 ➡ W2 → ∀T2. ⦃G, L0.ⓓW0⦄ ⊢ T0 ➡ T2 →
+   ∀L1. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L1 → ∀L2. ⦃G, L0⦄ ⊢ ➡[ⓐV0.ⓓ{a}W0.T0, 0] L2 →
+   ∃∃T. ⦃G, L1⦄ ⊢ ⓓ{a}W1.ⓐU1.T1 ➡ T & ⦃G, L2⦄ ⊢ ⓓ{a}W2.ⓐU2.T2 ➡ T.
+#a #G #L0 #V0 #W0 #T0 #IH #V1 #HV01 #U1 #HVU1 #W1 #HW01 #T1 #HT01
+#V2 #HV02 #U2 #HVU2 #W2 #HW02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (llpr_inv_flat … HL01) -HL01 #H1V0 #HL01
+elim (llpr_inv_bind_O … HL01) -HL01 #H1W0 #H1T0
+elim (llpr_inv_flat … HL02) -HL02 #H2V0 #HL02
+elim (llpr_inv_bind_O … HL02) -HL02 #H2W0 #H2T0
+elim (IH … HV01 … HV02 … H1V0 … H2V0) -HV01 -HV02 /2 width=1 by/ #V #HV1 #HV2
+elim (IH … HW01 … HW02 … H1W0 … H2W0) /2 width=1 by/
+elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=4 by llpr_bind_repl_O/ -L0 -V0 -W0 -T0
+elim (lift_total V 0 1) #U #HVU
+lapply (cpr_lift … HV1 (L1.ⓓW1) … HVU1 … HVU) -HVU1 /2 width=2 by ldrop_drop/
+lapply (cpr_lift … HV2 (L2.ⓓW2) … HVU2 … HVU) -HVU2 /2 width=2 by ldrop_drop/
+/4 width=7 by cpr_bind, cpr_flat, ex2_intro/ (**) (* full auto not tried *)
+qed-.
+
+theorem cpr_conf_llpr: ∀G. llpx_sn_confluent2 (cpr G) (cpr G).
+#G #L0 #T0 @(fqup_wf_ind_eq … G L0 T0) -G -L0 -T0 #G #L #T #IH #G0 #L0 * [| * ]
+[ #I0 #HG #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpr_inv_atom1 … H1) -H1
+  elim (cpr_inv_atom1 … H2) -H2
+  [ #H2 #H1 destruct
+    /2 width=1 by cpr_conf_llpr_atom_atom/
+  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
+    /3 width=10 by cpr_conf_llpr_atom_delta/
+  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
+    /4 width=10 by ex2_commute, cpr_conf_llpr_atom_delta/
+  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
+    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
+    /3 width=17 by cpr_conf_llpr_delta_delta/
+  ]
+| #a #I #V0 #T0 #HG #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpr_inv_bind1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #T1 #HT01 #HXT1 #H11 #H12
+  ]
+  elim (cpr_inv_bind1 … H2) -H2 *
+  [1,3: #V2 #T2 #HV02 #HT02 #H2
+  |2,4: #T2 #HT02 #HXT2 #H21 #H22
+  ] destruct
+  [ /3 width=10 by cpr_conf_llpr_bind_bind/
+  | /4 width=11 by ex2_commute, cpr_conf_llpr_bind_zeta/
+  | /3 width=11 by cpr_conf_llpr_bind_zeta/
+  | /3 width=12 by cpr_conf_llpr_zeta_zeta/
+  ]
+| #I #V0 #T0 #HG #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpr_inv_flat1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #HX1 #H1
+  | #a1 #V1 #Y1 #W1 #Z1 #T1 #HV01 #HYW1 #HZT1 #H11 #H12 #H13
+  | #a1 #V1 #U1 #Y1 #W1 #Z1 #T1 #HV01 #HVU1 #HYW1 #HZT1 #H11 #H12 #H13
+  ]
+  elim (cpr_inv_flat1 … H2) -H2 *
+  [1,5,9,13: #V2 #T2 #HV02 #HT02 #H2
+  |2,6,10,14: #HX2 #H2
+  |3,7,11,15: #a2 #V2 #Y2 #W2 #Z2 #T2 #HV02 #HYW2 #HZT2 #H21 #H22 #H23
+  |4,8,12,16: #a2 #V2 #U2 #Y2 #W2 #Z2 #T2 #HV02 #HVU2 #HYW2 #HZT2 #H21 #H22 #H23
+  ] destruct
+  [ /3 width=10 by cpr_conf_llpr_flat_flat/
+  | /4 width=8 by ex2_commute, cpr_conf_llpr_flat_tau/
+  | /4 width=12 by ex2_commute, cpr_conf_llpr_flat_beta/
+  | /4 width=14 by ex2_commute, cpr_conf_llpr_flat_theta/
+  | /3 width=8 by cpr_conf_llpr_flat_tau/
+  | /3 width=8 by cpr_conf_llpr_tau_tau/
+  | /3 width=12 by cpr_conf_llpr_flat_beta/
+  | /3 width=13 by cpr_conf_llpr_beta_beta/
+  | /3 width=14 by cpr_conf_llpr_flat_theta/
+  | /3 width=17 by cpr_conf_llpr_theta_theta/
+  ]
+]
+qed-.
+
+(* Basic_1: includes: pr0_confluence pr2_confluence *)
+theorem cpr_conf: ∀G,L. confluent … (cpr G L).
+/2 width=6 by cpr_conf_llpr/ qed-.
+
+(* Properties on context-sensitive parallel reduction for terms *************)
+
+lemma llpr_cpr_conf_dx: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
+                        ∃∃T. ⦃G, L1⦄ ⊢ T0 ➡ T & ⦃G, L1⦄ ⊢ T1 ➡ T.
+#G #L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpr_conf_llpr … HT01 T0 … HL01 … HL01) /2 width=3 by ex2_intro/
+qed-.
+
+lemma llpr_cpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 → ∀L1. ⦃G, L0⦄ ⊢ ➡[T0, 0] L1 →
+                        ∃∃T. ⦃G, L1⦄ ⊢ T0 ➡ T & ⦃G, L0⦄ ⊢ T1 ➡ T.
+#G #L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpr_conf_llpr … HT01 T0 … L0 … HL01) /2 width=3 by ex2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs.etc
new file mode 100644 (file)
index 0000000..d3c2a6f
--- /dev/null
@@ -0,0 +1,61 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazypredsnstar_5.ma".
+include "basic_2/reduction/llpr.ma".
+
+(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
+
+definition llprs: genv → relation4 ynat term lenv lenv ≝
+                  λG,d. LTC … (llpr G d).
+
+interpretation "lazy parallel computation (local environment, sn variant)"
+   'LazyPRedSnStar G L1 L2 T d = (llprs G d T L1 L2).
+
+(* Basic eliminators ********************************************************)
+
+lemma llprs_ind: ∀G,L1,T,d. ∀R:predicate lenv. R L1 →
+                 (∀L,L2. ⦃G, L1⦄ ⊢ ➡*[T, d] L → ⦃G, L⦄ ⊢ ➡[T, d] L2 → R L → R L2) →
+                 ∀L2. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → R L2.
+#G #L1 #T #d #R #HL1 #IHL1 #L2 #HL12
+@(TC_star_ind … HL1 IHL1 … HL12) //
+qed-.
+
+lemma llprs_ind_dx: ∀G,L2,T,d. ∀R:predicate lenv. R L2 →
+                    (∀L1,L. ⦃G, L1⦄ ⊢ ➡[T, d] L → ⦃G, L⦄ ⊢ ➡*[T, d] L2 → R L → R L1) →
+                    ∀L1. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → R L1.
+#G #L2 #T #d #R #HL2 #IHL2 #L1 #HL12
+@(TC_star_ind_dx … HL2 IHL2 … HL12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpr_llprs: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
+/2 width=1 by inj/ qed.
+
+lemma llprs_refl: ∀G,L,T,d. ⦃G, L⦄ ⊢ ➡*[T, d] L.
+/2 width=1 by lpr_llprs/ qed.
+
+lemma llprs_strap1: ∀G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[T, d] L → ⦃G, L⦄ ⊢ ➡[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
+normalize /2 width=3 by step/ qed-.
+
+lemma llprs_strap2: ∀G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡[T, d] L → ⦃G, L⦄ ⊢ ➡*[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[T, d] L2.
+normalize /2 width=3 by TC_strap/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma llprs_fwd_length: ∀G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[T, d] L2 → |L1| = |L2|.
+#G #L1 #L2 #T #d #H @(llprs_ind … H) -L2
+/3 width=6 by llpr_fwd_length, trans_eq/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_cprs.etc
new file mode 100644 (file)
index 0000000..b9bf0f9
--- /dev/null
@@ -0,0 +1,122 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_tc.ma".
+include "basic_2/computation/cprs_cprs.ma".
+include "basic_2/computation/llprs.ma".
+
+(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
+
+(* Advanced properties ******************************************************)
+
+lemma llprs_pair_dx: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡* V2 →
+                     ∀I,T. ⦃G, L.ⓑ{I}V1⦄ ⊢ ➡*[T, 0] L.ⓑ{I}V2.
+/2 width=1 by llpx_sn_TC_pair_dx/ qed.
+
+(* Properties on context-sensitive parallel computation for terms ***********)
+
+lemma llprs_cpr_trans: ∀G. s_r_transitive … (cpr G) (llprs G 0).
+/3 width=5 by cprs_llpr_trans, s_r_trans_LTC2/ qed-.
+
+(* Basic_1: was just: pr3_pr3_pr3_t *)
+lemma llprs_cprs_trans: ∀G. s_rs_transitive … (cpr G) (llprs G 0).
+#G @s_r_to_s_rs_trans @s_r_trans_LTC2
+/3 width=5 by cprs_llpr_trans, s_rs_trans_TC1/ (**) (* full auto too slow *)
+qed-.
+
+(* Note: this is an instance of a general theorem *)
+lemma llprs_cprs_conf_dx: ∀G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡* U2 →
+                          ∀L0. ⦃G2, L0⦄ ⊢ ➡*[T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[U2, O] L2.
+#G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llprs_ind_dx … H) -L0 //
+#L0 #L #HL0 #HL2 #IHL2 @(llprs_strap2 … IHL2) -IHL2
+lapply (llprs_cprs_trans … HTU2 … HL2) -L2 #HTU2
+/3 width=3 by cprs_llpr_trans, cprs_llpr_conf/
+qed-.
+
+(* Note: this is an instance of a general theorem *)
+lemma llprs_cpr_conf_dx: ∀G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡ U2 →
+                         ∀L0. ⦃G2, L0⦄ ⊢ ➡*[T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[U2, O] L2.
+#G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llprs_ind_dx … H) -L0 //
+#L0 #L #HL0 #HL2 #IHL2 @(llprs_strap2 … IHL2) -IHL2
+lapply (llprs_cpr_trans … HTU2 … HL2) -L2 #HTU2
+/3 width=3 by cprs_llpr_trans, cprs_llpr_conf/
+qed-.
+
+lemma llprs_cprs_conf_sn: ∀G,L0,L1,T0. ⦃G, L0⦄ ⊢ ➡*[T0, 0] L1 →
+                          ∀T1. ⦃G, L0⦄ ⊢ T0 ➡* T1 →
+                          ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
+#G #L0 #L1 #T0 #H @(llprs_ind_dx … H) -L0 /2 width=3 by ex2_intro/
+#L0 #L #HL0 #HL1 #IHL1 #T1 #HT01 elim (cprs_llpr_conf_sn … HT01 … HL0)
+#T2 #HT12 #HT02 elim (IHL1 … HT02) -IHL1 -HT02
+lapply (cprs_trans … HT01 … HT12) #HT02
+lapply (cprs_llpr_conf … HT02 … HL0) -HT02 -HL0
+/4 width=5 by cprs_llpr_trans, cprs_trans, ex2_intro/
+qed-.
+
+lemma llprs_cpr_conf_sn: ∀G,L0,T0,T1. ⦃G, L0⦄ ⊢ T0 ➡ T1 →
+                         ∀L1. ⦃G, L0⦄ ⊢ ➡*[T0, 0] L1 →
+                         ∃∃T. ⦃G, L0⦄ ⊢ T1 ➡* T & ⦃G, L1⦄ ⊢ T0 ➡* T.
+/3 width=3 by llprs_cprs_conf_sn, cpr_cprs/ qed-.
+
+lemma cprs_bind2: ∀G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡* V2 →
+                  ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡* T2 →
+                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡* ⓑ{a,I}V2.T2.
+/4 width=3 by llprs_cprs_trans, llprs_pair_dx, cprs_bind/ qed-.
+
+(* Inversion lemmas on context-sensitive parallel computation for terms *****)
+
+(* Basic_1: was: pr3_gen_abst *)
+lemma cprs_inv_abst1: ∀a,G,L,W1,T1,U2. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* U2 →
+                      ∃∃W2,T2. ⦃G, L⦄ ⊢ W1 ➡* W2 & ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2 &
+                               U2 = ⓛ{a}W2.T2.
+#a #G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /2 width=5 by ex3_2_intro/
+#U0 #U2 #_ #HU02 * #V0 #T0 #HV10 #HT10 #H destruct
+elim (cpr_inv_abst1 … HU02) -HU02 #V2 #T2 #HV02 #HT02 #H destruct
+lapply (llprs_cpr_trans … HT02 (L.ⓛV1) ?)
+/3 width=5 by llprs_pair_dx, cprs_trans, cprs_strap1, ex3_2_intro/
+qed-.
+
+lemma cprs_inv_abst: ∀a,G,L,W1,W2,T1,T2. ⦃G, L⦄ ⊢ ⓛ{a}W1.T1 ➡* ⓛ{a}W2.T2 →
+                     ⦃G, L⦄ ⊢ W1 ➡* W2 ∧ ⦃G, L.ⓛW1⦄ ⊢ T1 ➡* T2.
+#a #G #L #W1 #W2 #T1 #T2 #H
+elim (cprs_inv_abst1 … H) -H #W #T #HW1 #HT1 #H destruct /2 width=1 by conj/
+qed-.
+
+(* Basic_1: was pr3_gen_abbr *)
+lemma cprs_inv_abbr1: ∀a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓓ{a}V1.T1 ➡* U2 → (
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡* V2 & ⦃G, L.ⓓV1⦄ ⊢ T1 ➡* T2 &
+                               U2 = ⓓ{a}V2.T2
+                      ) ∨
+                      ∃∃T2. ⦃G, L.ⓓV1⦄ ⊢ T1 ➡* T2 & ⇧[0, 1] U2 ≡ T2 & a = true.
+#a #G #L #V1 #T1 #U2 #H @(cprs_ind … H) -U2 /3 width=5 by ex3_2_intro, or_introl/
+#U0 #U2 #_ #HU02 * *
+[ #V0 #T0 #HV10 #HT10 #H destruct
+  elim (cpr_inv_abbr1 … HU02) -HU02 *
+  [ #V2 #T2 #HV02 #HT02 #H destruct
+    lapply (llprs_cpr_trans … HT02 (L.ⓓV1) ?)
+    /4 width=5 by llprs_pair_dx, cprs_trans, cprs_strap1, ex3_2_intro, or_introl/
+  | #T2 #HT02 #HUT2
+    lapply (llprs_cpr_trans … HT02 (L.ⓓV1) ?) -HT02
+    /4 width=3 by llprs_pair_dx, cprs_trans, ex3_intro, or_intror/
+  ]
+| #U1 #HTU1 #HU01
+  elim (lift_total U2 0 1) #U #HU2
+  lapply (cpr_lift … HU02 (L.ⓓV1) … HU01 … HU2) -U0
+  /4 width=3 by cprs_strap1, ldrop_drop, ex3_intro, or_intror/
+]
+qed-.
+
+(* Note: we loose lprs_cprs_conf_dx and derivatives:
+         lprs_cpr_conf_dx lprs_cprs_conf
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_llprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llprs_llprs.etc
new file mode 100644 (file)
index 0000000..4f97672
--- /dev/null
@@ -0,0 +1,22 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/llprs.ma".
+
+(* LAZY SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ***********************)
+
+(* Main properties **********************************************************)
+
+theorem llprs_trans: ∀G,T,d. Transitive … (llprs G d T).
+normalize /2 width=3 by trans_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpx_sn_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpr/llpx_sn_llpx_sn.etc
new file mode 100644 (file)
index 0000000..0df9690
--- /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/relocation/llpx_sn.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+definition llpx_sn_confluent2: relation (lenv→relation term) ≝ λR1,R2.
+                               ∀L0,T0,T1. R1 L0 T0 T1 → ∀T2. R2 L0 T0 T2 →
+                               ∀L1. llpx_sn R1 0 T0 L0 L1 → ∀L2. llpx_sn R2 0 T0 L0 L2 →
+                               ∃∃T. R2 L1 T1 T & R1 L2 T2 T.
+
+(* Note: we miss llpx_sn_conf and derivatives: lpr_conf lprs_conf *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/cpxs_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/cpxs_llpx.etc
new file mode 100644 (file)
index 0000000..bec908e
--- /dev/null
@@ -0,0 +1,53 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llpx_ldrop.ma".
+include "basic_2/computation/cpxs_cpxs.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL COMPUTATION ON TERMS *****************)
+
+(* Properties on lazy sn reduction on local environments ********************)
+
+lemma cpxs_llpx_conf: ∀h,g,G. s_r_confluent1 … (cpxs h g G) (llpx h g G 0).
+/3 width=5 by llpx_cpx_conf, s_r_conf1_LTC1/ qed-.
+
+lemma llpx_cpx_trans: ∀h,g,G. s_r_transitive … (cpx h g G) (llpx h g G 0).
+#h #g #G #L2 #T1 #T2 #HT12 elim HT12 -G -L2 -T1 -T2
+[ /2 width=3 by/
+| /3 width=2 by cpx_cpxs, cpx_sort/
+| #I #G #L2 #K2 #V0 #V2 #W2 #i #HLK2 #_ #HVW2 #IHV02 #L1 #HL12
+  elim (llpx_inv_lref_ge_dx … HL12 … HLK2) -L2
+  /5 width=8 by cpxs_delta, cpxs_strap2, llpx_cpx_conf/
+| #a #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (llpx_inv_bind_O … HL12) -HL12 /4 width=1 by cpxs_bind/
+| #I #G #L2 #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L1 #HL12
+  elim (llpx_inv_flat … HL12) -HL12 /3 width=1 by cpxs_flat/
+| #G #L2 #V2 #T1 #T #T2 #_ #HT2 #IHT1 #L1 #HL12
+  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_zeta/
+| #G #L2 #V2 #T1 #T2 #HT12 #IHT12 #L1 #HL12
+  elim (llpx_inv_flat … HL12) /3 width=1 by cpxs_tau/
+| #G #L2 #V1 #V2 #T2 #HV12 #IHV12 #L1 #HL12
+  elim (llpx_inv_flat … HL12) /3 width=1 by cpxs_ti/
+| #a #G #L2 #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #L1 #HL12
+  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HL12
+  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_beta/
+| #a #G #L2 #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #L1 #HL12
+  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HL12
+  elim (llpx_inv_bind_O … HL12) /3 width=3 by cpxs_theta/
+]
+qed-.
+
+lemma llpx_cpxs_trans: ∀h,g,G. s_rs_transitive … (cpx h g G) (llpx h g G 0).
+#h #g #G @s_r_trans_LTC1 /2 width=3 by llpx_cpx_trans, llpx_cpx_conf/ (**) (* full auto fails here but works in cprs_cprs *)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpx.etc
new file mode 100644 (file)
index 0000000..c14492f
--- /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/computation/cpxs_llpx.ma".
+include "basic_2/computation/csx_alt.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED STRONGLY NORMALIZING TERMS ********************)
+
+(* Properties on lazy sn extended reduction for local environments **********)
+
+lemma csx_llpx_conf: ∀h,g,G,L1,T. ⦃G, L1⦄ ⊢ ⬊*[h, g] T →
+                     ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
+#h #g #G #L1 #T #H @(csx_ind_alt … H) -T
+/5 width=3 by csx_intro_cpxs, llpx_cpxs_trans, cpxs_llpx_conf/ (* 2 cpxs_llpx_trans *)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/csx_llpxs.etc
new file mode 100644 (file)
index 0000000..aad3e8b
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/csx_llpx.ma".
+include "basic_2/computation/llpxs.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED STRONGLY NORMALIZING TERMS ********************)
+
+(* Properties on lazy sn extended computation for local environments ********)
+
+lemma csx_llpxs_conf: ∀h,g,G,L1,T. ⦃G, L1⦄ ⊢ ⬊*[h, g] T →
+                      ∀L2.  ⦃G, L1⦄ ⊢ ➡*[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ ⬊*[h, g] T.
+#h #g #G #L1 #T #HT #L2 #H @(llpxs_ind … H) -L2 /3 by llpxs_strap1, csx_llpx_conf/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/fpbs_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/fpbs_lpr.etc
new file mode 100644 (file)
index 0000000..34b60ad
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lift.ma".
+include "basic_2/reduction/llpx_lpr.ma".
+include "basic_2/computation/fpbs.ma".
+
+(* "BIG TREE" PARALLEL COMPUTATION FOR CLOSURES *****************************)
+
+(* Properties on sn parallel reduction for local environments ***************)
+
+(* Note: this is used in the closure proof *)
+(* Note: original proof: /4 width=5 by fpbs_strap1, lpr_fpb, cpr_fpb/ *)
+(* Note: this should be moved *)
+lemma cpr_lpr_fpbs: ∀h,g,G,L1,L2,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L1⦄ ⊢ ➡ L2 →
+                    ⦃G, L1, T1⦄ ≥[h, g] ⦃G, L2, T2⦄.
+/5 width=5 by fpbs_strap1, cpr_fpb, fpb_llpx, lpr_llpx/ qed.
+
+(* Note: this is used in the closure proof *)
+(* Note: this should be moved *)
+lemma cpr_lpr_ssta_fpbs: ∀h,g,G,L1,L2,T1,T2,U2,l2.
+                         ⦃G, L1⦄ ⊢ T1 ➡ T2 → ⦃G, L1⦄ ⊢ ➡ L2 →
+                         ⦃G, L2⦄ ⊢ T2 ▪[h, g] l2+1 → ⦃G, L2⦄ ⊢ T2 •[h, g] U2 →
+                         ⦃G, L1, T1⦄ ≥[h, g] ⦃G, L2, U2⦄.
+/4 width=5 by fpbs_strap1, cpr_lpr_fpbs, ssta_cpx, fpb_cpx/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsn_7.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsn_7.etc
new file mode 100644 (file)
index 0000000..2350f5e
--- /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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡ break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LazyPRedSn $G $L1 $L2 $h $g $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsnstar_7.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazypredsnstar_7.etc
new file mode 100644 (file)
index 0000000..f8209e2
--- /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( ⦃ term 46 G , break term 46 L1 ⦄ ⊢ ➡* break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LazyPRedSnStar $G $L1 $L2 $h $g $T $d }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysn_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysn_6.etc
new file mode 100644 (file)
index 0000000..0c52a6e
--- /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( G ⊢ ⋕ ⬊ * break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L )"
+   non associative with precedence 45
+   for @{ 'LazySN $h $g $T $d $G $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysnalt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/lazysnalt_6.etc
new file mode 100644 (file)
index 0000000..0976a31
--- /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( G ⊢ ⋕ ⬊ ⬊ * break [ term 46 h , break term 46 g , break term 46 T , break term 46 d ] break term 46 L )"
+   non associative with precedence 45
+   for @{ 'LazySNAlt $h $g $T $d $G $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx.etc
new file mode 100644 (file)
index 0000000..3276008
--- /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/notation/relations/lazypredsn_7.ma".
+include "basic_2/relocation/llpx_sn.ma".
+include "basic_2/reduction/cpx.ma".
+
+(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
+
+definition llpx: ∀h. sd h → genv → relation4 ynat term lenv lenv ≝
+                 λh,g,G. llpx_sn (cpx h g  G).
+
+interpretation "lazy extended parallel reduction (local environment, sn variant)"
+   'LazyPRedSn G L1 L2 h g T d = (llpx h g G d T L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma llpx_inv_flat: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
+                     ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2 ∧ ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
+/2 width=2 by llpx_sn_inv_flat/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma llpx_fwd_length: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → |L1| = |L2|.
+/2 width=4 by llpx_sn_fwd_length/ qed-.
+
+lemma llpx_fwd_flat_dx: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
+                     ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
+/2 width=3 by llpx_sn_fwd_flat_dx/ qed-.
+
+lemma llpx_fwd_pair_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ②{I}V.T, d] L2 →
+                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
+/2 width=3 by llpx_sn_fwd_pair_sn/ qed-.
+
+(* Note: this might be removed *)
+lemma llpx_fwd_bind_sn: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, d] L2 →
+                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
+/2 width=4 by llpx_sn_fwd_bind_sn/ qed-.
+
+(* Note: this might be removed *)
+lemma llpx_fwd_bind_dx: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, d] L2 →
+                        ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, ⫯d] L2.ⓑ{I}V.
+/2 width=2 by llpx_sn_fwd_bind_dx/ qed-.
+
+(* Note: this might be removed *)
+lemma llpx_fwd_flat_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, ⓕ{I}V.T, d] L2 →
+                        ⦃G, L1⦄ ⊢ ➡[h, g, V, d] L2.
+/2 width=3 by llpx_sn_fwd_flat_sn/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma llpx_lref: ∀h,g,I,G,L1,L2,K1,K2,V1,V2,d,i. d ≤ yinj i →
+                 ⇩[i] L1 ≡ K1.ⓑ{I}V1 → ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                 ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 → ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 → ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2.
+/2 width=9 by llpx_sn_lref/ qed.
+
+lemma llpx_refl: ∀h,g,G,T,d. reflexive … (llpx h g G d T).
+/2 width=1 by llpx_sn_refl/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_aaa.etc
new file mode 100644 (file)
index 0000000..99eef8d
--- /dev/null
@@ -0,0 +1,82 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/aaa_lift.ma".
+include "basic_2/static/lsuba_aaa.ma".
+include "basic_2/reduction/llpx_ldrop.ma".
+
+(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+(* Note: lemma 500 *)
+lemma aaa_cpx_llpx_conf: ∀h,g,G,L1,T1,A. ⦃G, L1⦄ ⊢ T1 ⁝ A →
+                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                         ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T1, 0] L2 → ⦃G, L2⦄ ⊢ T2 ⁝ A.
+#h #g #G #L1 #T1 #A #H elim H -G -L1 -T1 -A
+[ #g #L1 #k #X #H elim (cpx_inv_sort1 … H) -H // * //
+| #I #G #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #X #H #L2 #HL12
+  elim (cpx_inv_lref1 … H) -H
+  [ #H destruct
+    elim (llpx_inv_lref_ge_sn … HL12 … HLK1) -L1 /3 width=6 by aaa_lref/
+  | * #J #Y #Z #V2 #H #HV12 #HV2
+    lapply (ldrop_mono … H … HLK1) -H #H destruct
+    elim (llpx_inv_lref_ge_sn … HL12 … HLK1) -L1 /3 width=8 by aaa_lift, ldrop_fwd_drop2/
+  ]
+| #a #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (llpx_inv_bind_O … HL12) -HL12 #HV1 #HT1
+  elim (cpx_inv_abbr1 … H) -H *
+  [ #V2 #T2 #HV12 #HT12 #H destruct /4 width=4 by llpx_bind_repl_O, aaa_abbr/
+  | #T2 #HT12 #HT2 #H destruct -IHV1 /3 width=8 by aaa_inv_lift, ldrop_drop/
+  ]
+| #a #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (llpx_inv_bind_O … HL12) -HL12 #HV1 #HT1
+  elim (cpx_inv_abst1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  /4 width=4 by llpx_bind_repl_O, aaa_abst/
+| #G #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HT1
+  elim (cpx_inv_appl1 … H) -H *
+  [ #V2 #T2 #HV12 #HT12 #H destruct /3 width=3 by aaa_appl/
+  | #b #V2 #W1 #W2 #U1 #U2 #HV12 #HW12 #HU12 #H1 #H2 destruct
+    lapply (IHV1 … HV12 … HV1) -IHV1 -HV12 #HV2
+    lapply (IHT1 (ⓛ{b}W2.U2) … HT1) -IHT1 /2 width=1 by cpx_bind/ -L1 #H
+    elim (aaa_inv_abst … H) -H #B0 #A0 #HW1 #HU2 #H destruct
+    /5 width=6 by lsuba_aaa_trans, lsuba_abbr, aaa_abbr, aaa_cast/
+  | #b #V #V2 #W1 #W2 #U1 #U2 #HV1 #HV2 #HW12 #HU12 #H1 #H2 destruct
+    lapply (aaa_lift G L2 … B … (L2.ⓓW2) … HV2) -HV2 /2 width=2 by ldrop_drop/ #HV2
+    lapply (IHT1 (ⓓ{b}W2.U2) … HT1) -IHT1 /2 width=1 by cpx_bind/ -L1 #H
+    elim (aaa_inv_abbr … H) -H /3 width=3 by aaa_abbr, aaa_appl/
+  ]
+| #G #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (llpx_inv_flat … HL12) -HL12 #HV1 #HT1
+  elim (cpx_inv_cast1 … H) -H
+  [ * #V2 #T2 #HV12 #HT12 #H destruct /3 width=1 by aaa_cast/
+  | -IHV1 /2 width=1 by/
+  | -IHT1 /2 width=1 by/
+  ]
+]
+qed-.
+
+lemma aaa_cpx_conf: ∀h,g,G,L,T1,A. ⦃G, L⦄ ⊢ T1 ⁝ A → ∀T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 → ⦃G, L⦄ ⊢ T2 ⁝ A.
+/2 width=7 by aaa_cpx_llpx_conf/ qed-.
+
+lemma aaa_llpx_conf: ∀h,g,G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
+/2 width=7 by aaa_cpx_llpx_conf/ qed-.
+
+lemma aaa_cpr_conf: ∀G,L,T1,A. ⦃G, L⦄ ⊢ T1 ⁝ A → ∀T2. ⦃G, L⦄ ⊢ T1 ➡ T2 → ⦃G, L⦄ ⊢ T2 ⁝ A.
+/3 width=5 by aaa_cpx_conf, cpr_cpx/ qed-.
+(*
+lamma aaa_llpr_conf: ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A → ∀L2. ⦃G, L1⦄ ⊢ ➡[T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
+/3 width=5 by aaa_llpx_conf, llpr_llpx/ qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_ldrop.etc
new file mode 100644 (file)
index 0000000..3e4bcab
--- /dev/null
@@ -0,0 +1,90 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_llpx_sn.ma".
+include "basic_2/reduction/cpx_lift.ma".
+include "basic_2/reduction/llpx.ma".
+
+(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma llpx_inv_lref_ge_dx: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
+                           ∀I,K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                           ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 &
+                                    ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
+/2 width=5 by llpx_sn_inv_lref_ge_dx/ qed-.
+
+lemma llpx_inv_lref_ge_sn: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
+                           ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                           ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                    ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
+/2 width=5 by llpx_sn_inv_lref_ge_sn/ qed-.
+
+lemma llpx_inv_lref_ge_bi: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡[h, g, #i, d] L2 → d ≤ i →
+                           ∀I1,I2,K1,K2,V1,V2.
+                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                           ∧∧ I1 = I2 & ⦃G, K1⦄ ⊢ ➡[h, g, V1, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2.
+/2 width=8 by llpx_sn_inv_lref_ge_bi/ qed-.
+
+lemma llpx_inv_bind_O: ∀h,g,a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡ [h, g, ⓑ{a,I}V.T, 0] L2 →
+                       ⦃G, L1⦄ ⊢ ➡[h, g, V, 0] L2 ∧ ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V.
+/2 width=2 by llpx_sn_inv_bind_O/ qed-.
+
+lemma llpx_bind_repl_O: ∀h,g,I,G,L1,L2,V1,V2,T. ⦃G, L1.ⓑ{I}V1⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V2 →
+                        ∀J,W1,W2. ⦃G, L1⦄ ⊢ ➡[h, g, W1, 0] L2 → ⦃G, L1⦄ ⊢ W1 ➡[h, g] W2 → ⦃G, L1.ⓑ{J}W1⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{J}W2.
+/2 width=4 by llpx_sn_bind_repl_O/ qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma llpx_fwd_bind_O_dx: ∀h,g,a,I,G,L1,L2,V,T. ⦃G, L1⦄ ⊢ ➡[h, g, ⓑ{a,I}V.T, 0] L2 →
+                          ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡[h, g, T, 0] L2.ⓑ{I}V.
+/2 width=3 by llpx_sn_fwd_bind_O_dx/ qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma llpx_cpx_conf: ∀h,g,G. s_r_confluent1 … (cpx h g G) (llpx h g G 0).
+/3 width=10 by cpx_llpx_sn_conf, cpx_inv_lift1, cpx_lift/ qed-.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma llpx_ldrop_trans_O: ∀h,g,G,L1,L2,U. ⦃G, L1⦄ ⊢ ➡[h, g, U, 0] L2 →
+                          ∀K2,e. ⇩[e] L2 ≡ K2 → ∀T. ⇧[0, e] T ≡ U →
+                          ∃∃K1. ⇩[e] L1 ≡ K1 & ⦃G, K1⦄ ⊢ ➡[h, g, T, 0] K2.
+/2 width=5 by llpx_sn_ldrop_trans_O/ qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma llpx_fqu_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃ ⦃G2, L2, T2⦄ →
+                      ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
+                      ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ⊃ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H elim H -G1 -G2 -L1 -L2 -T1 -T2
+/3 width=7 by llpx_fwd_bind_O_dx, llpx_fwd_pair_sn,llpx_fwd_flat_dx, ex3_2_intro/
+[ #I #G1 #L1 #V1 #K1 #H elim (llpx_inv_lref_ge_dx … H) -H [5,6: // |2,3,4: skip ]
+  #Y1 #W1 #HKL1 #HW1 #HWV1 elim (lift_total V1 0 1)
+  /4 width=7 by llpx_cpx_conf, cpx_delta, fqu_drop, ldrop_fwd_drop2, ex3_2_intro/
+| #G #L1 #K1 #T1 #U1 #e #HLK1 #HTU1 #L0 #HU1
+  elim (llpx_ldrop_trans_O … HU1 … HLK1) -L1
+  /3 width=5 by fqu_drop, ex3_2_intro/
+]
+qed-.
+
+lemma llpx_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
+                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
+                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡[h, g] T & ⦃G1, K1, T⦄ ⊃⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H #K1 #HKL1 elim (fquq_inv_gen … H) -H
+[ #HT12 elim (llpx_fqu_trans … HT12 … HKL1) /3 width=5 by fqu_fquq, ex3_2_intro/
+| * #H1 #H2 #H3 destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lleq.etc
new file mode 100644 (file)
index 0000000..e936cc5
--- /dev/null
@@ -0,0 +1,31 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lleq.ma".
+include "basic_2/reduction/llpx.ma".
+
+(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
+
+(* Properties on lazy equivalence for local environments ********************)
+
+lemma llpx_lrefl: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
+/2 width=1 by llpx_sn_lrefl/ qed-.
+
+lemma lleq_llpx_trans: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 →
+                       ∀L.⦃G, L2⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L.
+/3 width=3 by lleq_cpx_trans, lleq_llpx_sn_trans/ qed-.
+
+lemma lleq_llpx_conf: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 →
+                      ∀L.⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L2⦄ ⊢ ➡[h, g, T, d] L.
+/3 width=3 by lleq_cpx_trans, lleq_llpx_sn_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpx_lpr.etc
new file mode 100644 (file)
index 0000000..6ceb64b
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lpx_sn.ma".
+include "basic_2/reduction/lpr.ma".
+include "basic_2/reduction/llpx.ma".
+
+(* LAZY SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ***************)
+
+(* Properties on sn parallel reduction **************************************)
+
+(* Note: this should be moved *)
+lemma lpr_llpx: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2.
+/3 width=4 by cpr_cpx, lpx_sn_llpx_sn, llpx_sn_co/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs.etc
new file mode 100644 (file)
index 0000000..750d0b5
--- /dev/null
@@ -0,0 +1,89 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazypredsnstar_7.ma".
+include "basic_2/reduction/llpx.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
+
+definition llpxs: ∀h. sd h → genv → relation4 ynat term lenv lenv ≝
+                  λh,g,G,d. LTC … (llpx h g G d).
+
+interpretation "lazy extended parallel computation (local environment, sn variant)"
+   'LazyPRedSnStar G L1 L2 h g T d = (llpxs h g G d T L1 L2).
+
+(* Basic eliminators ********************************************************)
+
+lemma llpxs_ind: ∀h,g,G,L1,T,d. ∀R:predicate lenv. R L1 →
+                 (∀L,L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡[h, g, T, d] L2 → R L → R L2) →
+                 ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → R L2.
+#h #g #G #L1 #T #d #R #HL1 #IHL1 #L2 #HL12
+@(TC_star_ind … HL1 IHL1 … HL12) //
+qed-.
+
+lemma llpxs_ind_dx: ∀h,g,G,L2,T,d. ∀R:predicate lenv. R L2 →
+                    (∀L1,L. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → R L → R L1) →
+                    ∀L1. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → R L1.
+#h #g #G #L2 #T #d #R #HL2 #IHL2 #L1 #HL12
+@(TC_star_ind_dx … HL2 IHL2 … HL12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma llpx_llpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+normalize /2 width=1 by inj/ qed.
+
+lemma llpxs_refl: ∀h,g,G,L,T,d. ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L.
+/2 width=1 by llpx_llpxs/ qed.
+
+lemma llpxs_strap1: ∀h,g,G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+normalize /2 width=3 by step/ qed.
+
+lemma llpxs_strap2: ∀h,g,G,L1,L,L2,T,d. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L → ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+normalize /2 width=3 by TC_strap/ qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma llpxs_fwd_length: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → |L1| = |L2|.
+#h #g #G #L1 #L2 #T #d #H @(llpxs_ind … H) -L2
+/3 width=8 by llpx_fwd_length, trans_eq/
+qed-.
+
+(* Note: this might be moved *)
+lemma llpxs_fwd_bind_sn: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
+                         ⦃G, L1⦄ ⊢ ➡*[h, g, V, d] L2.
+#h #g #a #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
+/3 width=6 by llpx_fwd_bind_sn, llpxs_strap1/
+qed-.
+
+(* Note: this might be moved *)
+lemma llpxs_fwd_bind_dx: ∀h,g,a,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
+                         ⦃G, L1.ⓑ{I}V⦄ ⊢ ➡*[h, g, T, ⫯d] L2.ⓑ{I}V.
+#h #g #a #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
+/3 width=6 by llpx_fwd_bind_dx, llpxs_strap1/
+qed-.
+
+(* Note: this might be moved *)
+lemma llpxs_fwd_flat_sn: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
+                         ⦃G, L1⦄ ⊢ ➡*[h, g, V, d] L2.
+#h #g #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
+/3 width=6 by llpx_fwd_flat_sn, llpxs_strap1/
+qed-.
+
+(* Note: this might be moved *)
+lemma llpxs_fwd_flat_dx: ∀h,g,I,G,L1,L2,V,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
+                         ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+#h #g #I #G #L1 #L2 #V #T #d #H @(llpxs_ind … H) -L2
+/3 width=6 by llpx_fwd_flat_dx, llpxs_strap1/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_aaa.etc
new file mode 100644 (file)
index 0000000..ededb03
--- /dev/null
@@ -0,0 +1,31 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llpx_aaa.ma".
+include "basic_2/computation/llpxs.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
+
+(* Properties about atomic arity assignment on terms ************************)
+
+lemma aaa_llpxs_conf: ∀h,g,G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
+                      ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
+#h #g #G #L1 #T #A #HT #L2 #HL12
+@(TC_Conf3 … (λL,A. ⦃G, L⦄ ⊢ T ⁝ A) … HT ? HL12) /2 width=5 by aaa_llpx_conf/
+qed-.
+(*
+lamma aaa_llprs_conf: ∀G,L1,T,A. ⦃G, L1⦄ ⊢ T ⁝ A →
+                      ∀L2. ⦃G, L1⦄ ⊢ ➡*[T, 0] L2 → ⦃G, L2⦄ ⊢ T ⁝ A.
+/3 width=5 by aaa_llpxs_conf, llprs_llpxs/ qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_cpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_cpxs.etc
new file mode 100644 (file)
index 0000000..35472d7
--- /dev/null
@@ -0,0 +1,172 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_tc.ma".
+include "basic_2/computation/cpxs_llpx.ma".
+include "basic_2/computation/llpxs.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
+
+(* Advanced properties ******************************************************)
+
+lemma llpxs_pair_dx: ∀h,g,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 →
+                     ∀I,T. ⦃G, L.ⓑ{I}V1⦄ ⊢ ➡*[h, g, T, 0] L.ⓑ{I}V2.
+/2 width=1 by llpx_sn_TC_pair_dx/ qed.
+
+(* Properties on context-sensitive extended parallel computation for terms **)
+
+lemma llpxs_cpx_trans: ∀h,g,G. s_r_transitive … (cpx h g G) (llpxs h g G 0).
+/3 width=5 by s_r_trans_LTC2, llpx_cpxs_trans/ qed-.
+
+lemma llpxs_cpxs_trans: ∀h,g,G. s_rs_transitive … (cpx h g G) (llpxs h g G 0).
+#h #g #G @s_r_to_s_rs_trans @s_r_trans_LTC2
+/3 width=5 by llpx_cpxs_trans, s_rs_trans_TC1/ (**) (* full auto too slow *)
+qed-.
+
+(* Note: this is an instance of a general theorem *)
+lemma llpxs_cpxs_conf_dx: ∀h,g,G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡*[h, g] U2 →
+                          ∀L0. ⦃G2, L0⦄ ⊢ ➡*[h, g, T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[h, g, U2, O] L2.
+#h #g #G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llpxs_ind_dx … H) -L0 //
+#L0 #L #HL0 #HL2 #IHL2 @(llpxs_strap2 … IHL2) -IHL2
+lapply (llpxs_cpxs_trans … HTU2 … HL2) -L2 #HTU2
+/3 width=3 by llpx_cpxs_trans, cpxs_llpx_conf/
+qed-.
+
+(* Note: this is an instance of a general theorem *)
+lemma llpxs_cpx_conf_dx: ∀h,g,G2,L2,T2,U2. ⦃G2, L2⦄ ⊢ T2 ➡[h, g] U2 →
+                         ∀L0. ⦃G2, L0⦄ ⊢ ➡*[h, g, T2, O] L2 → ⦃G2, L0⦄ ⊢ ➡*[h, g, U2, O] L2.
+#h #g #G2 #L2 #T2 #U2 #HTU2 #L0 #H @(llpxs_ind_dx … H) -L0 //
+#L0 #L #HL0 #HL2 #IHL2 @(llpxs_strap2 … IHL2) -IHL2
+lapply (llpxs_cpx_trans … HTU2 … HL2) -L2 #HTU2
+/3 width=3 by llpx_cpxs_trans, cpxs_llpx_conf/
+qed-.
+
+lemma cpxs_bind2: ∀h,g,G,L,V1,V2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 →
+                  ∀I,T1,T2. ⦃G, L.ⓑ{I}V2⦄ ⊢ T1 ➡*[h, g] T2 →
+                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V1.T1 ➡*[h, g] ⓑ{a,I}V2.T2.
+/4 width=5 by llpxs_cpxs_trans, llpxs_pair_dx, cpxs_bind/ qed.
+
+(* Advanced forward lemmas **************************************************)
+
+(* Note: this might be moved *)
+lemma llpxs_fwd_lref_ge_sn: ∀h,g,G,L1,L2,d,i. ⦃G, L1⦄ ⊢ ➡*[h, g, #i, d] L2 → d ≤ i →
+                            ∀I,K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                            ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 &
+                                     ⦃G, K1⦄ ⊢ ➡*[h, g, V2, 0] K2 & ⦃G, K1⦄ ⊢ V1 ➡*[h, g] V2.
+#h #g #G #L1 #L2 #d #i #H #Hdi #I #K1 #V1 #HLK1 @(llpxs_ind … H) -L2 /2 width=5 by ex3_2_intro/ -HLK1
+#L #L2 #_ #HL2 * #K #V #HLK #HK1 #HV1 elim (llpx_inv_lref_ge_sn … HL2 … HLK) // -HL2 -HLK -Hdi
+#K2 #V2 #HLK2 #HK2 #HV2
+@(ex3_2_intro … HLK2) -HLK2
+[ /3 width=5 by llpxs_cpx_conf_dx, llpxs_strap1, llpx_cpx_conf/
+| /3 width=5 by llpxs_cpx_trans, cpxs_trans/
+]
+qed-.
+
+(* Inversion lemmas on context-sensitive ext parallel computation for terms *)
+
+lemma cpxs_inv_abst1: ∀h,g,a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓛ{a}V1.T1 ➡*[h, g] U2 →
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 & ⦃G, L.ⓛV1⦄ ⊢ T1 ➡*[h, g] T2 &
+                               U2 = ⓛ{a}V2.T2.
+#h #g #a #G #L #V1 #T1 #U2 #H @(cpxs_ind … H) -U2 /2 width=5 by ex3_2_intro/
+#U0 #U2 #_ #HU02 * #V0 #T0 #HV10 #HT10 #H destruct
+elim (cpx_inv_abst1 … HU02) -HU02 #V2 #T2 #HV02 #HT02 #H destruct
+lapply (llpxs_cpx_trans … HT02 (L.ⓛV1) ?)
+/3 width=5 by llpxs_pair_dx, cpxs_trans, cpxs_strap1, ex3_2_intro/
+qed-.
+
+lemma cpxs_inv_abbr1: ∀h,g,a,G,L,V1,T1,U2. ⦃G, L⦄ ⊢ ⓓ{a}V1.T1 ➡*[h, g] U2 → (
+                      ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡*[h, g] V2 & ⦃G, L.ⓓV1⦄ ⊢ T1 ➡*[h, g] T2 &
+                               U2 = ⓓ{a}V2.T2
+                      ) ∨
+                      ∃∃T2. ⦃G, L.ⓓV1⦄ ⊢ T1 ➡*[h, g] T2 & ⇧[0, 1] U2 ≡ T2 & a = true.
+#h #g #a #G #L #V1 #T1 #U2 #H @(cpxs_ind … H) -U2 /3 width=5 by ex3_2_intro, or_introl/
+#U0 #U2 #_ #HU02 * *
+[ #V0 #T0 #HV10 #HT10 #H destruct
+  elim (cpx_inv_abbr1 … HU02) -HU02 *
+  [ #V2 #T2 #HV02 #HT02 #H destruct
+    lapply (llpxs_cpx_trans … HT02 (L.ⓓV1) ?)
+    /4 width=5 by llpxs_pair_dx, cpxs_trans, cpxs_strap1, ex3_2_intro, or_introl/
+  | #T2 #HT02 #HUT2
+    lapply (llpxs_cpx_trans … HT02 (L.ⓓV1) ?) -HT02
+    /4 width=3 by llpxs_pair_dx, cpxs_trans, ex3_intro, or_intror/
+  ]
+| #U1 #HTU1 #HU01
+  elim (lift_total U2 0 1) #U #HU2
+  /6 width=12 by cpxs_strap1, cpx_lift, ldrop_drop, ex3_intro, or_intror/
+]
+qed-.
+
+(* Properties on supclosure *************************************************)
+
+lemma llpx_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
+                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
+                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃+ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqup_ind … H) -G2 -L2 -T2
+[ #G2 #L2 #T2 #H12 #K1 #HKL1 elim (llpx_fqu_trans … H12 … HKL1) -L1
+  /3 width=5 by cpx_cpxs, fqu_fqup, ex3_2_intro/
+| #G #G2 #L #L2 #T #T2 #_ #H2 #IH1 #K1 #HLK1 elim (IH1 … HLK1) -L1
+  #L0 #T0 #HT10 #HT0 #HL0 elim (llpx_fqu_trans … H2 … HL0) -L
+  #L #T3 #HT3 #HT32 #HL2 elim (fqup_cpx_trans … HT0 … HT3) -T
+  /3 width=7 by cpxs_strap1, fqup_strap1, ex3_2_intro/
+]
+qed-.
+
+lemma llpx_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
+                       ∀K1. ⦃G1, K1⦄ ⊢ ➡[h, g, T1, 0] L1 →
+                       ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃* ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #H @(fqus_ind … H) -G2 -L2 -T2 /2 width=5 by ex3_2_intro/
+#G #G2 #L #L2 #T #T2 #_ #H2 #IH1 #K1 #HLK1 elim (IH1 … HLK1) -L1
+#L0 #T0 #HT10 #HT0 #HL0 elim (llpx_fquq_trans … H2 … HL0) -L
+#L #T3 #HT3 #HT32 #HL2 elim (fqus_cpx_trans … HT0 … HT3) -T
+/3 width=7 by cpxs_strap1, fqus_strap1, ex3_2_intro/
+qed-.
+
+lemma llpxs_fquq_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ →
+                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
+                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃⸮ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
+[ /2 width=5 by ex3_2_intro/
+| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
+  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
+  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
+  elim (llpx_fquq_trans … HT2 … HK1) -K
+  /3 width=7 by llpxs_strap2, cpxs_strap1, ex3_2_intro/
+]
+qed-.
+
+lemma llpxs_fqup_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃+ ⦃G2, L2, T2⦄ →
+                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
+                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃+ ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
+[ /2 width=5 by ex3_2_intro/
+| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
+  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
+  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
+  elim (llpx_fqup_trans … HT2 … HK1) -K
+  /3 width=7 by llpxs_strap2, cpxs_trans, ex3_2_intro/
+]
+qed-.
+
+lemma llpxs_fqus_trans: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ⊃* ⦃G2, L2, T2⦄ →
+                        ∀K1. ⦃G1, K1⦄ ⊢ ➡*[h, g, T1, 0] L1 →
+                        ∃∃K2,T. ⦃G1, K1⦄ ⊢ T1 ➡*[h, g] T & ⦃G1, K1, T⦄ ⊃* ⦃G2, K2, T2⦄ & ⦃G2, K2⦄ ⊢ ➡*[h, g, T2, 0] L2.
+#h #g #G1 #G2 #L1 #L2 #T1 #T2 #HT12 #K1 #H @(llpxs_ind_dx … H) -K1
+[ /2 width=5 by ex3_2_intro/
+| #K1 #K #HK1 #_ * #L #T #HT1 #HT2 #HL2 -HT12
+  lapply (llpx_cpxs_trans … HT1 … HK1) -HT1 #HT1
+  lapply (cpxs_llpx_conf … HT1 … HK1) -HK1 #HK1
+  elim (llpx_fqus_trans … HT2 … HK1) -K
+  /3 width=7 by llpxs_strap2, cpxs_trans, ex3_2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lleq.etc
new file mode 100644 (file)
index 0000000..a38ba39
--- /dev/null
@@ -0,0 +1,66 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_leq.ma".
+include "basic_2/reduction/llpx_lleq.ma".
+include "basic_2/computation/cpxs_lleq.ma".
+include "basic_2/computation/llpxs_cpxs.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS *************)
+
+(* Properties on lazy equivalence for local environments ********************)
+
+lemma llpxs_lrefl: ∀h,g,G,L1,L2,T,d. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+/3 width=1 by llpx_lrefl, llpx_llpxs/ qed-.
+
+lemma lleq_llpxs_trans: ∀h,g,G,L2,L,T,d. ⦃G, L2⦄ ⊢ ➡*[h, g, T, d] L →
+                        ∀L1. L1 ⋕[T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L.
+#h #g #G #L2 #L #T #d #H @(llpxs_ind … H) -L
+/3 width=3 by llpxs_strap1, llpxs_lrefl/
+qed-.
+
+lemma lleq_llpxs_conf: ∀h,g,G,L1,L,T,d. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L →
+                       ∀L2. L1 ⋕[T, d] L2 → ⦃G, L2⦄ ⊢ ➡*[h, g, T, d] L.
+/3 width=3 by lleq_llpxs_trans, lleq_sym/ qed-.
+(*
+foct 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 &
+                                   (∀T. L0 ⋕[T, d] L2 ↔ L1 ⋕[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/
+| #I1 #I0 #L1 #L0 #V1 #V0 #_ #_ #He destruct
+| #I #L1 #L0 #V1 #e #HL10 #IHL10 #He #Y #H
+  elim (lpxs_inv_pair1 … H) -H #L2 #V2 #HL02 #HV02 #H destruct
+  lapply (ysucc_inv_Y_dx … He) -He #He
+  elim (IHL10 … HL02) // -IHL10 -HL02 #L #HL2 #HL1 #IH
+  @(ex3_intro … (L.ⓑ{I}V2)) /3 width=3 by lpxs_pair, leq_cpxs_trans, leq_pair/
+  #T elim (IH T) #HL0dx #HL0sn
+  @conj #H @(lleq_leq_repl … H) -H /3 width=1 by leq_sym, leq_pair_O_Y/
+| #I1 #I0 #L1 #L0 #V1 #V0 #d #e #HL10 #IHL10 #He #Y #H
+  elim (lpxs_inv_pair1 … H) -H #L2 #V2 #HL02 #HV02 #H destruct
+  elim (IHL10 … HL02) // -IHL10 -HL02 #L #HL2 #HL1 #IH
+  @(ex3_intro … (L.ⓑ{I1}V1)) /3 width=1 by lpxs_pair, leq_succ/
+  #T elim (IH T) #HL0dx #HL0sn
+  @conj #H @(lleq_leq_repl … H) -H /3 width=1 by leq_sym, leq_succ/
+]
+qed-.
+
+lamma 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 &
+                                (∀T. L0 ⋕[T, d] L2 ↔ L1 ⋕[T, d] L).
+/2 width=1 by leq_lpxs_trans_lleq_aux/ qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_llpxs.etc
new file mode 100644 (file)
index 0000000..d316c52
--- /dev/null
@@ -0,0 +1,22 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/llpxs.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
+
+(* Main properties **********************************************************)
+
+theorem llpxs_trans: ∀h,g,G,T,d. Transitive … (llpxs h g G d T).
+normalize /2 width=3 by trans_TC/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llpxs_lprs.etc
new file mode 100644 (file)
index 0000000..32d7bbc
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/llpx_lpr.ma".
+include "basic_2/computation/lprs.ma".
+include "basic_2/computation/llpxs.ma".
+
+(* LAZY SN EXTENDED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS **************)
+
+(* Properties on sn parallel computation ************************************)
+
+(* Note: this should be moved *)
+lemma lprs_llpxs: ∀h,g,G,L1,L2,T,d. ⦃G, L1⦄ ⊢ ➡* L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2.
+normalize /3 width=3 by lpr_llpx, monotonic_TC/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx.etc
new file mode 100644 (file)
index 0000000..286d064
--- /dev/null
@@ -0,0 +1,57 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazysn_6.ma".
+include "basic_2/substitution/lleq.ma".
+include "basic_2/reduction/llpx.ma".
+
+(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
+
+definition llsx: ∀h. sd h → relation4 ynat term genv lenv ≝
+                 λh,g,d,T,G. SN … (llpx h g G d T) (lleq d T).
+
+interpretation
+   "lazy extended strong normalization (local environment)"
+   'LazySN h g d T G L = (llsx h g T d G L).
+
+(* Basic eliminators ********************************************************)
+
+lemma llsx_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
+                (∀L1. G ⊢ ⋕⬊*[h, g, T, d] L1 →
+                      (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
+                      R L1
+                ) →
+                ∀L. G ⊢ ⋕⬊*[h, g, T, d] L → R L.
+#h #g #G #T #d #R #H0 #L1 #H elim H -L1
+/5 width=1 by lleq_sym, SN_intro/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma llsx_intro: ∀h,g,G,L1,T,d.
+                  (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊*[h, g, T, d] L2) →
+                  G ⊢ ⋕⬊*[h, g, T, d] L1.
+/5 width=1 by lleq_sym, SN_intro/ qed.
+
+lemma llsx_sort: ∀h,g,G,L,d,k. G ⊢ ⋕⬊*[h, g, ⋆k, d] L.
+#h #g #G #L1 #d #k @llsx_intro
+#L2 #HL12 #H elim H -H
+/3 width=6 by llpx_fwd_length, lleq_sort/
+qed.
+
+lemma llsx_gref: ∀h,g,G,L,d,p. G ⊢ ⋕⬊*[h, g, §p, d] L.
+#h #g #G #L1 #d #p @llsx_intro
+#L2 #HL12 #H elim H -H
+/3 width=6 by llpx_fwd_length, lleq_gref/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_alt.etc
new file mode 100644 (file)
index 0000000..0d23439
--- /dev/null
@@ -0,0 +1,107 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lazysnalt_6.ma".
+include "basic_2/substitution/lleq_lleq.ma".
+include "basic_2/computation/llpxs_lleq.ma".
+include "basic_2/computation/llsx.ma".
+
+(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
+
+(* alternative definition of llsx *)
+definition llsxa: ∀h. sd h → relation4 ynat term genv lenv ≝
+                  λh,g,d,T,G. SN … (llpxs h g G d T) (lleq d T).
+
+interpretation
+   "lazy extended strong normalization (local environment) alternative"
+   'LazySNAlt h g d T G L = (llsxa h g T d G L).
+
+(* Basic eliminators ********************************************************)
+
+lemma llsxa_ind: ∀h,g,G,T,d. ∀R:predicate lenv.
+                 (∀L1. G ⊢ ⋕⬊⬊*[h, g, T, d] L1 →
+                       (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
+                       R L1
+                 ) →
+                 ∀L. G ⊢ ⋕⬊⬊*[h, g, T, d] L → R L.
+#h #g #G #T #d #R #H0 #L1 #H elim H -L1
+/5 width=1 by lleq_sym, SN_intro/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma llsxa_intro: ∀h,g,G,L1,T,d.
+                   (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[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 llsxa_intro_aux: ∀h,g,G,L1,T,d.
+                      (∀L,L2. ⦃G, L⦄ ⊢ ➡*[h, g, T, d] L2 → L1 ⋕[T, d] L → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊⬊*[h, g, T, d] L2) →
+                      G ⊢ ⋕⬊⬊*[h, g, T, d] L1.
+/4 width=3 by llsxa_intro/ qed-.
+
+lemma llsxa_llpxs_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊⬊*[h, g, T, d] L1 →
+                         ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → G ⊢ ⋕⬊⬊*[h, g, T, d] L2.
+#h #g #G #L1 #T #d #H @(llsxa_ind … H) -L1 #L1 #HL1 #IHL1 #L2 #HL12 @llsxa_intro
+elim (lleq_dec T L1 L2 d) /4 width=4 by lleq_llpxs_trans, lleq_canc_sn/
+qed-.
+
+lemma llsxa_intro_llpx: ∀h,g,G,L1,T,d.
+                        (∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊⬊*[h, g, T, d] L2) →
+                        G ⊢ ⋕⬊⬊*[h, g, T, d] L1.
+#h #g #G #L1 #T #d #IH @llsxa_intro_aux
+#L #L2 #H @(llpxs_ind_dx … H) -L
+[ #H destruct #H elim H //
+| #L0 #L elim (lleq_dec T L1 L d)
+  /4 width=3 by llsxa_llpxs_trans, lleq_llpx_trans/
+]
+qed.
+
+(* Main properties **********************************************************)
+
+theorem llsx_llsxa: ∀h,g,G,L,T,d. G ⊢ ⋕⬊*[h, g, T, d] L → G ⊢ ⋕⬊⬊*[h, g, T, d] L.
+#h #g #G #L #T #d #H @(llsx_ind … H) -L
+/4 width=1 by llsxa_intro_llpx/
+qed.
+
+(* Main inversion lemmas ****************************************************)
+
+theorem llsxa_inv_llsx: ∀h,g,G,L,T,d. G ⊢ ⋕⬊⬊*[h, g, T, d] L → G ⊢ ⋕⬊*[h, g, T, d] L.
+#h #g #G #L #T #d #H @(llsxa_ind … H) -L
+/4 width=1 by llsx_intro, llpx_llpxs/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma llsx_intro_alt: ∀h,g,G,L1,T,d.
+                      (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → G ⊢ ⋕⬊*[h, g, T, d] L2) →
+                      G ⊢ ⋕⬊*[h, g, T, d] L1.
+/6 width=1 by llsxa_inv_llsx, llsx_llsxa, llsxa_intro/ qed.
+
+lemma llsx_llpxs_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊*[h, g, T, d] L1 →
+                        ∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → G ⊢ ⋕⬊*[h, g, T, d] L2.
+/4 width=3 by llsxa_inv_llsx, llsx_llsxa, llsxa_llpxs_trans/
+qed-.
+
+(* Advanced eliminators *****************************************************)
+
+lemma llsx_ind_alt: ∀h,g,G,T,d. ∀R:predicate lenv.
+                    (∀L1. G ⊢ ⋕⬊*[h, g, T, d] L1 →
+                          (∀L2. ⦃G, L1⦄ ⊢ ➡*[h, g, T, d] L2 → (L1 ⋕[T, d] L2 → ⊥) → R L2) →
+                          R L1
+                    ) →
+                    ∀L. G ⊢ ⋕⬊*[h, g, T, d] L → R L.
+#h #g #G #T #d #R #IH #L #H @(llsxa_ind h g G T d … L)
+/4 width=1 by llsxa_inv_llsx, llsx_llsxa/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_csx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_csx.etc
new file mode 100644 (file)
index 0000000..9c28473
--- /dev/null
@@ -0,0 +1,96 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/csx_lift.ma".
+include "basic_2/computation/csx_llpxs.ma".
+include "basic_2/computation/llsx_ldrop.ma".
+include "basic_2/computation/llsx_llpx.ma".
+include "basic_2/computation/llsx_llpxs.ma".
+(*
+axiom cpx_llpx_trans: ∀h,g,G,L1,T1,T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                      ∀L2. ⦃G, L1⦄⊢ ➡[h, g, T2, O] L2 → 
+                      ∃∃L. ⦃G, L1⦄⊢ ➡[h, g, T1, O] L & L ⋕[T2, 0] L2.
+(*
+fact llsx_cpx_trans_aux: ∀h,g,G,L0,T1,T2. ⦃G, L0⦄ ⊢ T1 ➡[h, g] T2 →
+                         ∀L1,d. G ⊢ ⋕⬊*[h, g, T1, d] L1 → d = 0 → 
+                         L0 ⋕[T1, d] L1 → ∀L2. L1 ⋕[T2, d] L2 →
+                         G ⊢ ⋕⬊*[h, g, T2, d] L2.
+#h #g #G #L0 #T1 #T2 #HT12 #L1 #d #H @(llsx_ind … H) -L1
+#L1 #_ #IHL1 #Hd #He011 #L2 #He122 @llsx_intro
+#L3 #Hx223 #Hn223 destruct
+lapply (lleq_cpx_conf_sn … HT12 … He011) #He021
+lapply (lleq_cpx_conf … HT12 … He011) -HT12 #HT12
+lapply (lleq_llpx_trans … He122 … Hx223) -Hx223 #Hx123
+elim (cpx_llpx_trans … HT12 … Hx123) -Hx123 #L4 #Hx114 #He423
+(* lapply (lleq_cpx_conf … Hx114 … He011) #He120 *)
+@(IHL1 … Hx114) // -IHL1
+[ #HL13 @HnL2 -HnL2  
+*)
+
+fact llsx_cpx_trans_aux: ∀h,g,G,L1,T1,d. G ⊢ ⋕⬊*[h, g, T1, d] L1 → d = 0 →
+                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 →
+                         ∀L2. L1 ⋕[T1, d] L2 → G ⊢ ⋕⬊*[h, g, T2, 0] L2.
+#h #g #G #L1 #T1 #d #H @(llsx_ind … H) -L1
+#L1 #_ #IHL1 #Hd #T2 #HT12 #L2 #He112 @llsx_intro
+#L3 #Hx223 #Hn223 destruct
+lapply (lleq_cpx_conf_sn … HT12 … He112) #He122
+lapply (lleq_cpx_conf … HT12 … He112) -HT12 #HT12
+elim (cpx_llpx_trans … HT12 … Hx223) #L4 #Hx214 #He423
+@(IHL1 … L4) //
+*)
+axiom llsx_cpx_trans_O: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡[h, g] T2 →
+                        G ⊢ ⋕⬊*[h, g, T1, 0] L → G ⊢ ⋕⬊*[h, g, T2, 0] L.
+
+(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
+
+(* Advanced properties ******************************************************)
+
+lemma llsx_lref_be_lpxs: ∀h,g,I,G,K1,V,i,d. d ≤ yinj i → ⦃G, K1⦄ ⊢ ⬊*[h, g] V →
+                         ∀K2. G ⊢ ⋕⬊*[h, g, V, 0] K2 → ⦃G, K1⦄ ⊢ ➡*[h, g, V, 0] K2 →
+                         ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V → G ⊢ ⋕⬊*[h, g, #i, d] L2.
+#h #g #I #G #K1 #V #i #d #Hdi #H @(csx_ind_alt … H) -V
+#V0 #_ #IHV0 #K2 #H @(llsx_ind … H) -K2
+#K0 #HK0 #IHK0 #HK10 #L0 #HLK0 @llsx_intro
+#L2 #HL02 #HnL02 elim (llpx_inv_lref_ge_sn … HL02 … HLK0) // -HL02
+#K2 #V2 #HLK2 #HK02 #HV02 elim (eq_term_dec V0 V2)
+#HnV02 destruct [ -IHV0 -HV02 -HK0 | -IHK0 -HnL02 -HLK0 ]
+[ /4 width=7 by llpxs_strap1, lleq_lref/
+| lapply (llpx_cpx_conf … HV02 … HK02) -HK02 #HK02
+  @(IHV0 … HnV02 … HLK2) -IHV0 -HnV02 -HLK2
+  /3 width=3 by llsx_cpx_trans_O, llpxs_cpx_conf_dx, llsx_llpx_trans, llpxs_cpx_trans, llpxs_strap1/
+]
+qed.
+
+lemma llsx_lref_be: ∀h,g,I,G,K,V,i,d. d ≤ yinj i → ⦃G, K⦄ ⊢ ⬊*[h, g] V →
+                    G ⊢ ⋕⬊*[h, g, V, 0] K →
+                    ∀L. ⇩[i] L ≡ K.ⓑ{I}V → G ⊢ ⋕⬊*[h, g, #i, d] L.
+/2 width=8 by llsx_lref_be_lpxs/ qed.
+
+(* Main properties **********************************************************)
+
+theorem csx_llsx: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ∀d. G ⊢ ⋕⬊*[h, g, T, d] L.
+#h #g #G #L #T @(fqup_wf_ind_eq … G L T) -G -L -T
+#Z #Y #X #IH #G #L * * //
+[ #i #HG #HL #HT #H #d destruct
+  elim (lt_or_ge i (|L|)) /2 width=1 by llsx_lref_free/
+  elim (ylt_split i d) /2 width=1 by llsx_lref_skip/
+  #Hdi #Hi elim (ldrop_O1_lt … Hi) -Hi
+  #I #K #V #HLK lapply (csx_inv_lref_bind … HLK … H) -H
+  /4 width=6 by llsx_lref_be, fqup_lref/
+| #a #I #V #T #HG #HL #HT #H #d destruct
+  elim (csx_fwd_bind … H) -H /3 width=1 by llsx_bind/
+| #I #V #T #HG #HL #HT #H #d destruct
+  elim (csx_fwd_flat … H) -H /3 width=1 by llsx_flat/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_ldrop.etc
new file mode 100644 (file)
index 0000000..2d16e32
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_ldrop.ma".
+include "basic_2/computation/llsx.ma".
+
+(* LAZY SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS *****************)
+
+(* Advanced properties ******************************************************)
+
+lemma llsx_lref_free: ∀h,g,G,L,d,i. |L| ≤ i → G ⊢ ⋕⬊*[h, g, #i, d] L.
+#h #g #G #L1 #d #i #HL1 @llsx_intro
+#L2 #HL12 #H elim H -H
+/4 width=8 by llpx_fwd_length, lleq_free, le_repl_sn_conf_aux/
+qed.
+
+lemma llsx_lref_skip: ∀h,g,G,L,d,i. yinj i < d → G ⊢ ⋕⬊*[h, g, #i, d] L.
+#h #g #G #L1 #d #i #HL1 @llsx_intro
+#L2 #HL12 #H elim H -H
+/3 width=6 by llpx_fwd_length, lleq_skip/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpx.etc
new file mode 100644 (file)
index 0000000..9392afb
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_lleq.ma".
+include "basic_2/reduction/llpx_lleq.ma".
+include "basic_2/computation/llsx.ma".
+
+(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
+
+(* Advanced properties ******************************************************)
+
+lemma llsx_llpx_trans: ∀h,g,G,L1,T,d. G ⊢ ⋕⬊*[h, g, T, d] L1 →
+                       ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g, T, d] L2 → G ⊢ ⋕⬊*[h, g, T, d] L2.
+#h #g #G #L1 #T #d #H @(llsx_ind … H) -L1 #L1 #HL1 #IHL1 #L2 #HL12 @llsx_intro
+elim (lleq_dec T L1 L2 d) /4 width=4 by lleq_llpx_trans, lleq_canc_sn/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpxs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx/llsx_llpxs.etc
new file mode 100644 (file)
index 0000000..af37a37
--- /dev/null
@@ -0,0 +1,66 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/llpxs_llpxs.ma".
+include "basic_2/computation/llsx_alt.ma".
+
+(* SN EXTENDED STRONGLY NORMALIZING LOCAL ENVIRONMENTS **********************)
+
+(* Advanced properties ******************************************************)
+
+fact llsx_bind_llpxs_aux: ∀h,g,a,I,G,L1,V,d. G ⊢ ⋕⬊*[h, g, V, d] L1 →
+                          ∀Y,T. G ⊢ ⋕⬊*[h, g, T, ⫯d] Y →
+                          ∀L2. Y = L2.ⓑ{I}V → ⦃G, L1⦄ ⊢ ➡*[h, g, ⓑ{a,I}V.T, d] L2 →
+                          G ⊢ ⋕⬊*[h, g, ⓑ{a,I}V.T, d] L2.
+#h #g #a #I #G #L1 #V #d #H @(llsx_ind_alt … H) -L1
+#L1 #HL1 #IHL1 #Y #T #H @(llsx_ind_alt … H) -Y
+#Y #HY #IHY #L2 #H #HL12 destruct @llsx_intro_alt
+#L0 #HL20 lapply (llpxs_fwd_bind_dx … HL20)
+lapply (llpxs_trans … HL12 … HL20)
+#HL10 #HT #H elim (nlleq_inv_bind … H) -H [ -HL1 -IHY | -HY -IHL1 ]
+[ #HnV elim (lleq_dec V L1 L2 d)
+  [  -HL20 #HV @(IHL1 … L0)
+     /3 width=4 by llsx_llpxs_trans, llpxs_fwd_bind_sn, lleq_canc_sn/ (**) (* full auto too slow *)
+  | -HnV -HL10
+     /3 width=4 by llsx_llpxs_trans, llpxs_fwd_bind_sn/
+  ]
+| /3 width=4 by/
+]
+qed-.
+
+lemma llsx_bind: ∀h,g,a,I,G,L,V,d. G ⊢ ⋕⬊*[h, g, V, d] L →
+                 ∀T. G ⊢ ⋕⬊*[h, g, T, ⫯d] L.ⓑ{I}V →
+                 G ⊢ ⋕⬊*[h, g, ⓑ{a,I}V.T, d] L.
+/2 width=3 by llsx_bind_llpxs_aux/ qed.
+
+lemma llsx_flat_llpxs: ∀h,g,I,G,L1,V,d. G ⊢ ⋕⬊*[h, g, V, d] L1 →
+                       ∀L2,T. G ⊢ ⋕⬊*[h, g, T, d] L2 → ⦃G, L1⦄ ⊢ ➡*[h, g, ⓕ{I}V.T, d] L2 →
+                       G ⊢ ⋕⬊*[h, g, ⓕ{I}V.T, d] L2.
+#h #g #I #G #L1 #V #d #H @(llsx_ind_alt … H) -L1
+#L1 #HL1 #IHL1 #L2 #T #H @(llsx_ind_alt … H) -L2
+#L2 #HL2 #IHL2 #HL12 @llsx_intro_alt
+#L0 #HL20 lapply (llpxs_fwd_flat_dx … HL20)
+lapply (llpxs_trans … HL12 … HL20)
+#HL10 #HT #H elim (nlleq_inv_flat … H) -H [ -HL1 -IHL2 | -HL2 -IHL1 ]
+[ #HnV elim (lleq_dec V L1 L2 d)
+  [ #HV @(IHL1 … L0) /3 width=3 by llsx_llpxs_trans, llpxs_fwd_flat_sn, lleq_canc_sn/ (**) (* full auto too slow: 47s *)
+  | -HnV -HL10 /3 width=4 by llsx_llpxs_trans, llpxs_fwd_flat_sn/
+  ]
+| /3 width=1 by/
+]
+qed-.
+
+lemma llsx_flat: ∀h,g,I,G,L,V,d. G ⊢ ⋕⬊*[h, g, V, d] L →
+                 ∀T. G ⊢ ⋕⬊*[h, g, T, d] L → G ⊢ ⋕⬊*[h, g, ⓕ{I}V.T, d] L.
+/2 width=3 by llsx_flat_llpxs/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/llpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/llpx_sn_tc.etc
new file mode 100644 (file)
index 0000000..682b48c
--- /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/relocation/ldrop_leq.ma".
+include "basic_2/relocation/llpx_sn.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+definition TC_llpx_sn_confluent1: relation (relation3 lenv term term) ≝ λS,R.
+                                  ∀Ls,T1,T2. S Ls T1 T2 →
+                                  ∀Ld. TC … (llpx_sn R 0 T1) Ls Ld → TC … (llpx_sn R 0 T2) Ls Ld.
+
+lemma TC_llpx_sn_s_confluent: ∀S,R. (llpx_sn_confluent1 S R) → TC_llpx_sn_confluent1 S R.
+#S #R #HSR #Ls #T1 #T2 #HT12 #Ld #H
+generalize in match HT12; -HT12
+@(TC_ind_dx … Ls H) -Ls
+[ /3 width=3 by inj/
+| #Ls #L #HLs #_ #IHLd #HT12
+  @(TC_strap … L) /2 width=3 by/ @IHLd -IHLd
+
+lemma TC_llpx_sn_lref_refl: ∀R. (∀L.reflexive … (R L)) →
+                            ∀I,L1,K1,K2,V,d,i. d ≤ yinj i → ⇩[i] L1 ≡ K1.ⓑ{I}V →
+                            TC lenv (llpx_sn R 0 V) K1 K2 →
+                            ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V → TC … (llpx_sn R d (#i)) L1 L2.
+#R #HR #I #L1 #K1 #K2 #V #d #i #Hdi #HLK1 #H @(TC_star_ind … K2 H) -K2
+[ /2 width=1 by llpx_sn_refl/
+| /4 width=9 by llpx_sn_refl, llpx_sn_lref, inj/
+| #K #K2 #_ #HV #IHK1 #L2 #HLK2 lapply (ldrop_fwd_length … HLK2)
+  #H elim (ldrop_O1_ex (K.ⓑ{I}V) i L2) [2: normalize in H ⊢ %; >(llpx_sn_fwd_length … HV) ]
+  /4 width=11 by llpx_sn_lref, step/
+]
+qed-.
+
+lemma TC_llpx_sn_lref: ∀R. (∀L.reflexive … (R L)) → (llpx_sn_confluent1 R R) →
+                       ∀I,K1,V1,V2,d,i. d ≤ yinj i → LTC … R K1 V1 V2 →
+                       ∀K2. TC lenv (llpx_sn R 0 V1) K1 K2 → ∀L1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                       ∀L2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 → TC … (llpx_sn R d (#i)) L1 L2.
+#R #H1R #H2R #I #K1 #V1 #V2 #d #i #Hdi #H @(TC_star_ind_dx … V1 H) -V1
+[ /2 width=1 by llpx_sn_refl/
+| /2 width=7 by TC_llpx_sn_lref_refl/
+| #V1 #V #HV1 #_ #IHV2 #K2 #HK12 #L1 #HLK1 #L2 #HLK2
+  lapply (ldrop_fwd_length … HLK1)
+  #H elim (ldrop_O1_ex (K1.ⓑ{I}V) i L1) [2: normalize in H ⊢ %; // ] -H
+  #L #_ #HLK @(TC_strap … L)
+  [ @(llpx_sn_lref … HLK1 … HLK) /2 width=1 by llpx_sn_refl/
+  | @(IHV2 … HLK … HLK2)
+    -HLK1 -HLK2 -HLK -IHV2 -Hdi @(TC_llpx_sn_s_confluent R R … HK12) //
+  ]
+]
+
+
+lemma llpx_sn_LTC_TC_llpx_sn: ∀R. (∀L. reflexive … (R L)) →
+                              ∀L1,L2,T,d. llpx_sn (LTC … R) d T L1 L2 →
+                              TC … (llpx_sn R d T) L1 L2.
+#R #HR #L1 #L2 #T #d #H elim H -L1 -L2
+/3 width=3 by llpx_sn_gref, llpx_sn_free, llpx_sn_skip, llpx_sn_sort, inj/
+[ #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #_ #HV12 #IHV1   
+
+(* Properties on transitive_closure *****************************************)
+
+lemma TC_lpx_sn_pair: ∀R. (∀L. reflexive … (R L)) →
+                      ∀I,L1,L2. TC … (lpx_sn R) L1 L2 →
+                      ∀V1,V2. LTC … R L1 V1 V2 →
+                      TC … (lpx_sn R) (L1. ⓑ{I} V1) (L2. ⓑ{I} V2).
+#R #HR #I #L1 #L2 #HL12 #V1 #V2 #H @(TC_star_ind_dx … V1 H) -V1 //
+[ /2 width=1 by TC_lpx_sn_pair_refl/
+| /4 width=3 by TC_strap, lpx_sn_pair, lpx_sn_refl/
+]
+qed-.
+
+lemma lpx_sn_LTC_TC_lpx_sn: ∀R. (∀L. reflexive … (R L)) →
+                            ∀L1,L2. lpx_sn (LTC … R) L1 L2 →
+                            TC … (lpx_sn R) L1 L2.
+#R #HR #L1 #L2 #H elim H -L1 -L2
+/2 width=1 by TC_lpx_sn_pair, lpx_sn_atom, inj/
+qed-.
+
+(* Inversion lemmas on transitive closure ***********************************)
+
+lemma TC_lpx_sn_inv_atom2: ∀R,L1. TC … (lpx_sn R) L1 (⋆) → L1 = ⋆.
+#R #L1 #H @(TC_ind_dx … L1 H) -L1
+[ /2 width=2 by lpx_sn_inv_atom2/
+| #L1 #L #HL1 #_ #IHL2 destruct /2 width=2 by lpx_sn_inv_atom2/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_pair2: ∀R. s_rs_trans … R (lpx_sn R) →
+                           ∀I,L1,K2,V2. TC  … (lpx_sn R) L1 (K2.ⓑ{I}V2) →
+                           ∃∃K1,V1. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L1 = K1. ⓑ{I} V1.
+#R #HR #I #L1 #K2 #V2 #H @(TC_ind_dx … L1 H) -L1
+[ #L1 #H elim (lpx_sn_inv_pair2 … H) -H /3 width=5 by inj, ex3_2_intro/
+| #L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
+  elim (lpx_sn_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct
+  lapply (HR … HV2 … HK1) -HR -HV2 /3 width=5 by TC_strap, ex3_2_intro/
+]
+qed-.
+
+lemma TC_lpx_sn_ind: ∀R. s_rs_trans … R (lpx_sn R) →
+                     ∀S:relation lenv.
+                     S (⋆) (⋆) → (
+                        ∀I,K1,K2,V1,V2.
+                        TC … (lpx_sn R) K1 K2 → LTC … R K1 V1 V2 →
+                        S K1 K2 → S (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
+                     ) →
+                     ∀L2,L1. TC … (lpx_sn R) L1 L2 → S L1 L2.
+#R #HR #S #IH1 #IH2 #L2 elim L2 -L2
+[ #X #H >(TC_lpx_sn_inv_atom2 … H) -X //
+| #L2 #I #V2 #IHL2 #X #H
+  elim (TC_lpx_sn_inv_pair2 … H) // -H -HR
+  #L1 #V1 #HL12 #HV12 #H destruct /3 width=1 by/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_atom1: ∀R,L2. TC … (lpx_sn R) (⋆) L2 → L2 = ⋆.
+#R #L2 #H elim H -L2
+[ /2 width=2 by lpx_sn_inv_atom1/
+| #L #L2 #_ #HL2 #IHL1 destruct /2 width=2 by lpx_sn_inv_atom1/
+]
+qed-.
+
+fact TC_lpx_sn_inv_pair1_aux: ∀R. s_rs_trans … R (lpx_sn R) →
+                              ∀L1,L2. TC … (lpx_sn R) L1 L2 →
+                              ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
+                              ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L2 = K2. ⓑ{I} V2.
+#R #HR #L1 #L2 #H @(TC_lpx_sn_ind … H) // -HR -L1 -L2
+[ #J #K #W #H destruct
+| #I #L1 #L2 #V1 #V2 #HL12 #HV12 #_ #J #K #W #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_pair1: ∀R. s_rs_trans … R (lpx_sn R) →
+                           ∀I,K1,L2,V1. TC … (lpx_sn R) (K1.ⓑ{I}V1) L2 →
+                           ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … R K1 V1 V2 & L2 = K2. ⓑ{I} V2.
+/2 width=3 by TC_lpx_sn_inv_pair1_aux/ qed-.
+
+lemma TC_lpx_sn_inv_lpx_sn_LTC: ∀R. s_rs_trans … R (lpx_sn R) →
+                                ∀L1,L2. TC … (lpx_sn R) L1 L2 →
+                                lpx_sn (LTC … R) L1 L2.
+/3 width=4 by TC_lpx_sn_ind, lpx_sn_pair/ qed-.
+
+(* Forward lemmas on transitive closure *************************************)
+
+lemma TC_lpx_sn_fwd_length: ∀R,L1,L2. TC … (lpx_sn R) L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H -L2
+[ #L2 #HL12 >(lpx_sn_fwd_length … HL12) -HL12 //
+| #L #L2 #_ #HL2 #IHL1
+  >IHL1 -L1 >(lpx_sn_fwd_length … HL2) -HL2 //
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/lpx_conj.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/llpx_sn/lpx_conj.etc
new file mode 100644 (file)
index 0000000..5950f1b
--- /dev/null
@@ -0,0 +1,120 @@
+include "basic_2/relocation/lleq_alt.ma".
+include "basic_2/reduction/cpx_lleq.ma".
+include "basic_2/reduction/lpx_lleq.ma".
+
+lemma not_ex_to_all_not: ∀A:Type[0]. ∀R:predicate A.
+                         ((∃a. R a)→⊥) → (∀a. R a → ⊥).
+/3 width=2 by ex_intro/ qed-.
+
+lemma lt_repl_sn_trans_tw: ∀L1,L2,T1,T2. ♯{L1, T1} < ♯{L2, T2} →
+                           ∀U1. ♯{U1} = ♯{T1} → ♯{L1, U1} < ♯{L2, T2}.
+normalize in ⊢ (?→?→?→?→?%%→?→?→?%%); //
+qed-.
+
+axiom cpx_fwd_lift1: ∀h,g,G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ➡[h, g] U2 →
+                     ∀T1,d,e. ⇧[d, e] T1 ≡ U1 → ∃T2. ⇧[d, e] T2 ≡ U2.
+(*
+#h #g #G #L #U1 #U2 #H elim H -G -L -U1 -U2
+[ * #i #G #L #T1 #d #e #H
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=2 by ex_intro/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=2 by lift_lref_ge_minus, lift_lref_lt, ex_intro/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=2 by ex_intro/
+  ]
+| #G #L #k #l #Hkl #T1 #d #e #H
+  lapply (lift_inv_sort2 … H) -H #H destruct /3 width=3 by ex_intro/
+| #I #G #L #K #V1 #V2 #W2 #i #HLK #HV12 #HVW2 #IHV2 #T1 #d #e #H
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
+    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
+    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m /3 width=9 by cpx_delta, ex2_intro/
+  | elim (le_inv_plus_l … Hid) #Hdie #Hei
+    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
+    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 /3 width=1 by le_S, le_S_S/ -Hid -Hdie
+    #V1 #HV1 >plus_minus // <minus_minus /2 width=1 by le_S/ <minus_n_n <plus_n_O /3 width=9 by cpx_delta, ex2_intro/
+  ]
+| #a #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=6 by cpx_bind, ldrop_skip, lift_bind, ex2_intro/
+| #I #G #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -V1
+  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5 by cpx_flat, lift_flat, ex2_intro/
+| #G #L #V #U1 #U #U2 #_ #HU2 #IHU1 #K #s #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHU1 (K.ⓓW1) s … HTU1) /2 width=1/ -L -U1 #T #HTU #HT1
+  elim (lift_div_le … HU2 … HTU) -U /3 width=5 by cpx_zeta, ex2_intro/
+| #G #L #V #U1 #U2 #_ #IHU12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHU12 … HLK … HTU1) -L -U1 /3 width=3 by cpx_tau, ex2_intro/
+| #G #L #V1 #V2 #U1 #_ #IHV12 #K #s #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -L -V1 /3 width=3 by cpx_ti, ex2_intro/
+| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #K #s #d #e #HLK #X #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
+  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
+  elim (IHV12 … HLK … HV01) -V1 #V3 #HV32 #HV03
+  elim (IHT12 (K.ⓛW0) s … HT01) -T1 /2 width=1 by ldrop_skip/ #T3 #HT32 #HT03
+  elim (IHW12 … HLK … HW01) -W1
+  /4 width=7 by cpx_beta, lift_bind, lift_flat, ex2_intro/
+| #a #G #L #V1 #V #V2 #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV1 #IHW12 #IHT12 #K #s #d #e #HLK #X #HX
+  elim (lift_inv_flat2 … HX) -HX #V0 #Y #HV01 #HY #HX destruct
+  elim (lift_inv_bind2 … HY) -HY #W0 #T0 #HW01 #HT01 #HY destruct
+  elim (IHV1 … HLK … HV01) -V1 #V3 #HV3 #HV03
+  elim (IHT12 (K.ⓓW0) s … HT01) -T1 /2 width=1 by ldrop_skip/ #T3 #HT32 #HT03
+  elim (IHW12 … HLK … HW01) -W1 #W3 #HW32 #HW03
+  elim (lift_trans_le … HV3 … HV2) -V
+  /4 width=9 by cpx_theta, lift_bind, lift_flat, ex2_intro/
+]
+qed-.
+*)
+lemma cpx_fwd_nlift2: ∀h,g,G,L,U1,U2. ⦃G, L⦄ ⊢ U1 ➡[h, g] U2 → ∀d,e.
+                      (∀T2. ⇧[d, e] T2 ≡ U2 → ⊥) → (∀T1. ⇧[d, e] T1 ≡ U1 → ⊥).
+#h #g #G #L #U1 #U2 #HU12 #d #e #HnU2 #T1 #HTU1
+elim (cpx_fwd_lift1 … HU12 … HTU1) -L -U1 /2 width=2 by/
+qed-.
+
+fact lleq_lpx_cpx_trans_aux: ∀h,g,G,T1,L1s,L1d,d. L1s ⋕[T1, d] L1d →
+                             ∀Y,L2d. ⦃G, Y⦄ ⊢ ➡[h, g] L2d → Y = L1d → d = 0 →
+                             ∀T2. ⦃G, L1d⦄ ⊢ T1 ➡[h, g] T2 →
+                             ∃∃L2s. ⦃G, L1s⦄ ⊢ ➡[h, g] L2s & L2s ⋕[T2, d] L2d.
+#h #g #G #T1 #L1s @(f2_ind … rfw … L1s T1) -L1s -T1 #n #IH
+#Ys #U1 #Hn #Yd #d #HU1 elim (lleq_fwd_alt … HU1) #H #IHU1
+#Y #L2d * -Y -L2d
+[ -IH -IHU1 -HU1 #HY #Hd #U2 #HU12 destruct
+  >(length_inv_zero_dx … H) -Ys /2 width=3 by ex2_intro/
+| #Id #L1d #L2d #W1d #W2d #HL12d #HW12d #HY #Hd #U2 #HU12 destruct
+  elim (length_inv_pos_dx … H) -H #Is #L1s #W1s #_ #H destruct
+  elim (is_lift_dec U1 0 1) [ -IHU1 -HW12d | -HU1 ]
+  [ * #T1 #HTU1 lapply (lift_fwd_tw … HTU1) #H
+    lapply (lleq_inv_lift_le … HU1 L1s L1d … HTU1 ?) -HU1 /2 width=1 by ldrop_drop/
+    #HT1 elim (cpx_inv_lift1 … HU12 L1d … HTU1) -HU12 -HTU1 /2 width=4 by ldrop_drop/
+    #T2 #HTU2 #HT12 elim (IH … HT1 … HL12d … HT12) /2 width=3 by lt_repl_sn_trans_tw/ -IH -HT1 -HT12 -H
+    #L2s #HL12s #HT2 @(ex2_intro … (L2s.ⓑ{Is}W1s))
+    /3 width=10 by lleq_lift_le, lpx_pair, ldrop_drop/ (**) (* full auto too slow *)
+  | #HnU1 lapply (not_ex_to_all_not … HnU1) -HnU1 #HnU1
+    elim (IHU1 … HnU1) [2,3,4: // |5,6,7,8,9,10: skip ] -HnU1 #H1 #H2 #HW1s destruct
+    elim (IH … HW1s … HL12d … HW12d) // #L2s #HL12s #HW2d
+    @(ex2_intro … (L2s.ⓑ{Id}W2d)) /3 width=3 by lleq_cpx_trans, lpx_pair/
+    lapply (lleq_fwd_length … HW2d) #HL2sd -HW12d -HW1s
+    @lleq_intro_alt [ normalize // ] -HL2sd
+    #I2s #I2d #K2s #K2d #V2s #V2d #i @(nat_ind_plus … i) -i
+    [ #_ #_ #HLK2s #HLK2d -IH -IHU1 -HU12 -HL12s -HL12d
+      lapply (ldrop_inv_O2 … HLK2s) -HLK2s #H destruct
+      lapply (ldrop_inv_O2 … HLK2d) -HLK2d #H destruct /2 width=1 by and3_intro/
+    | #i #_ #_ #HnU2 #HLK2s #HLK2d
+      lapply (cpx_fwd_nlift2 … HU12 … HnU2) -HU12 -HnU2 #HnU1
+      lapply (ldrop_inv_drop1 … HLK2s) -HLK2s #HLK2s
+      lapply (ldrop_inv_drop1 … HLK2d) -HLK2d #HLK2d
+      elim (lpx_ldrop_trans_O1 … HL12s … HLK2s) -L2s #Y #HLK1s #H
+      elim (lpx_inv_pair2 … H) -H #K1s #V1s #HK12s #HV12s #H destruct
+      elim (lpx_ldrop_trans_O1 … HL12d … HLK2d) -L2d #Y #HLK1d #H
+      elim (lpx_inv_pair2 … H) -H #K1d #V1d #HK12d #HV12d #H destruct
+      elim (IHU1 … HnU1) [2,3,4: /2 width=2 by ldrop_drop/ | 5,6,7,8,9,10: skip ] -IHU1 -HnU1 -HLK1d
+      #H1 #H2 #HV1d destruct
+      lapply (ldrop_fwd_rfw … HLK1s) -HLK1s #H
+      elim (IH … HV1d … HK12d … HV12d) // -IH -HV1d -HK12d -HV12d
+      [ #Y #H1Y #H2Y   
+       
+      
+
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc.etc
new file mode 100644 (file)
index 0000000..b80b290
--- /dev/null
@@ -0,0 +1,41 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 ⦄ ⬌ ⬌ break ⦃ term 46 L2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConvAlt $L1 $L2 }.
+
+include "basic_2/reducibility/lfpr.ma".
+
+(* FOCALIZED PARALLEL CONVERSION ON LOCAL ENVIRONMENTS **********************)
+
+definition lfpc: relation lenv ≝
+   λL1,L2. ⦃L1⦄ ➡ ⦃L2⦄ ∨ ⦃L2⦄ ➡ ⦃L1⦄.
+
+interpretation
+   "focalized parallel conversion (local environment)"
+   'FocalizedPConv L1 L2 = (lfpc L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lfpc_refl: ∀L. ⦃L⦄ ⬌ ⦃L⦄.
+/2 width=1/ qed.
+
+lemma lfpc_sym: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ⦃L2⦄ ⬌ ⦃L1⦄.
+#L1 #L2 * /2 width=1/
+qed.
+
+lemma lfpc_lfpr: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ∃∃L. ⦃L1⦄ ➡ ⦃L⦄ & ⦃L2⦄ ➡ ⦃L⦄.
+#L1 #L2 * /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc_lfpc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpc_lfpc.etc
new file mode 100644 (file)
index 0000000..69e444a
--- /dev/null
@@ -0,0 +1,23 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/conversion/lfpc.ma".
+
+(* FOCALIZED PARALLEL CONVERSION ON LOCAL ENVIRONMENTS **********************)
+
+(* Main properties **********************************************************)
+
+theorem lfpc_conf: ∀L0,L1,L2. ⦃L0⦄ ⬌ ⦃L1⦄ → ⦃L0⦄ ⬌ ⦃L2⦄ →
+                   ∃∃L. ⦃L1⦄ ⬌ ⦃L⦄ & ⦃L2⦄ ⬌ ⦃L⦄.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs.etc
new file mode 100644 (file)
index 0000000..3674637
--- /dev/null
@@ -0,0 +1,76 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 L1 ⦄ ⬌ ⬌ * break ⦃ term 46 L2 ⦄ )"
+   non associative with precedence 45
+   for @{ 'FocalizedPConvStarAlt $L1 $L2 }.
+
+include "basic_2/conversion/lfpc.ma".
+
+(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
+
+definition lfpcs: relation lenv ≝ TC … lfpc.
+
+interpretation "focalized parallel equivalence (local environment)"
+   'FocalizedPConvStar L1 L2 = (lfpcs L1 L2).
+
+(* Basic eliminators ********************************************************)
+
+lemma lfpcs_ind: ∀L1. ∀R:predicate lenv. R L1 →
+                 (∀L,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L⦄ ⬌ ⦃L2⦄ → R L → R L2) →
+                 ∀L2. ⦃L1⦄ ⬌* ⦃L2⦄ → R L2.
+#L1 #R #HL1 #IHL1 #L2 #HL12 @(TC_star_ind … HL1 IHL1 … HL12) //
+qed-.
+
+lemma lfpcs_ind_dx: ∀L2. ∀R:predicate lenv. R L2 →
+                    (∀L1,L. ⦃L1⦄ ⬌ ⦃L⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → R L → R L1) →
+                    ∀L1. ⦃L1⦄ ⬌* ⦃L2⦄ → R L1.
+#L2 #R #HL2 #IHL2 #L1 #HL12
+@(TC_star_ind_dx … HL2 IHL2 … HL12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lfpcs_refl: reflexive … lfpcs.
+/2 width=1/ qed.
+
+lemma lfpcs_sym: symmetric … lfpcs.
+/3 width=1/ qed.
+
+lemma lfpc_lfpcs: ∀L1,L2. ⦃L1⦄ ⬌ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/2 width=1/ qed.
+
+lemma lfpcs_strap1: ∀L1,L,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L⦄ ⬌ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/2 width=3/ qed.
+
+lemma lfpcs_strap2: ∀L1,L,L2. ⦃L1⦄ ⬌ ⦃L⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/2 width=3/ qed.
+
+lemma lfpcs_lfpr_dx: ∀L1,L2. ⦃L1⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=1/ qed.
+
+lemma lfpcs_lfpr_sn: ∀L1,L2. ⦃L2⦄ ➡ ⦃L1⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=1/ qed.
+
+lemma lfpcs_lfpr_strap1: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ➡ ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3/ qed.
+
+lemma lfpcs_lfpr_strap2: ∀L1,L. ⦃L1⦄ ➡ ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3/ qed.
+
+lemma lfpcs_lfpr_div: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡ ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3/ qed.
+
+lemma lfpcs_lfpr_conf: ∀L1,L. ⦃L⦄ ➡ ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_aaa.etc
new file mode 100644 (file)
index 0000000..b7cea0b
--- /dev/null
@@ -0,0 +1,30 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/lfprs_aaa.ma".
+include "basic_2/equivalence/lfpcs_lfpcs.ma".
+
+(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
+
+(* Main properties about atomic arity assignment on terms *******************)
+
+theorem aaa_lfpcs_mono: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
+                        ∀T,A1. L1 ⊢ T ⁝ A1 → ∀A2. L2 ⊢ T ⁝ A2 →
+                        A1 = A2.
+#L1 #L2 #HL12 #T #A1 #HT1 #A2 #HT2
+elim (lfpcs_inv_lfprs … HL12) -HL12 #L #HL1 #HL2
+lapply (aaa_lfprs_conf … HT1 … HL1) -L1 #HT1
+lapply (aaa_lfprs_conf … HT2 … HL2) -L2 #HT2
+lapply (aaa_mono … HT1 … HT2) -L -T //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_fpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_fpcs.etc
new file mode 100644 (file)
index 0000000..8f36888
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/fprs_cprs.ma".
+include "basic_2/computation/lfprs_fprs.ma".
+include "basic_2/equivalence/fpcs_fpcs.ma".
+include "basic_2/equivalence/lfpcs_lfpcs.ma".
+
+(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
+
+(* Inversion lemmas on context-free parallel equivalence for closures *******)
+
+lemma lfpcs_inv_fpcs: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ → ∀T. ⦃L1, T⦄ ⬌* ⦃L2, T⦄.
+#L1 #L2 #HL12 #T
+elim (lfpcs_inv_lfprs … HL12) -HL12 #L #HL1 #HL2
+lapply (lfprs_inv_fprs … HL1 T) -HL1
+lapply (lfprs_inv_fprs … HL2 T) -HL2 /2 width=4/
+qed-.
+
+(* Properties on context-free parallel equivalence for closures *************)
+
+lemma fpcs_lfpcs: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⬌* ⦃L2, T2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L2 #T1 #T2 #HT12
+elim (fpcs_inv_fprs … HT12) -HT12 /3 width=5 by fprs_lfprs, lfprs_div/ (**) (* auto too slow without trace *)
+qed.
+
+lemma fpcs_lift: ∀K1,K2,T1,T2. ⦃K1, T1⦄ ⬌* ⦃K2, T2⦄ →
+                 ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
+                 ∀d,e. ⇩[d, e] L1 ≡ K1 → ⇩[d, e] L2 ≡ K2 →
+                 ∀U1,U2. ⇧[d, e] T1 ≡ U1 → ⇧[d, e] T2 ≡ U2 →
+                 ⦃L1, U1⦄ ⬌* ⦃L2, U2⦄.
+#K1 #K2 #T1 #T2 #HT12 #L1 #L2 #HL12 #d #e #HLK1 #HLK2 #U1 #U2 #HTU1 #HTU2
+elim (fpcs_inv_fprs … HT12) -HT12 #K #T #HT1 #HT2
+elim (lift_total T d e) #U #HTU
+elim (fprs_lift … HT1 … HLK1 … HTU1 HTU) -K1 -T1 #K1 #HU1 #_
+elim (fprs_lift … HT2 … HLK2 … HTU2 HTU) -K2 -T2 -T #K2 #HU2 #_ -K -d -e
+lapply (lfpcs_lfprs_conf K1 … HL12) -HL12 /2 width=3/ #H
+lapply (lfpcs_lfprs_strap1 … H K2 ?) -H /2 width=3/ #HK12
+lapply (lfpcs_inv_fpcs … HK12 U) -HK12 #HU
+/3 width=4 by fpcs_fprs_strap2, fpcs_fprs_div/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfpcs.etc
new file mode 100644 (file)
index 0000000..1e95217
--- /dev/null
@@ -0,0 +1,50 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/lfprs_lfprs.ma".
+include "basic_2/conversion/lfpc_lfpc.ma".
+include "basic_2/equivalence/lfpcs_lfprs.ma".
+
+(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma lfpcs_inv_lfprs: ∀L1,L2. ⦃L1⦄ ⬌* ⦃L2⦄ →
+                       ∃∃L. ⦃L1⦄ ➡* ⦃L⦄ & ⦃L2⦄ ➡* ⦃L⦄.
+#L1 #L2 #H @(lfpcs_ind … H) -L2
+[ /3 width=3/
+| #L #L2 #_ #HL2 * #L0 #HL10 elim HL2 -HL2 #HL2 #HL0
+  [ elim (lfprs_strip … HL0 … HL2) -L #L #HL0 #HL2
+    lapply (lfprs_strap1 … HL10 … HL0) -L0 /2 width=3/
+  | lapply (lfprs_strap2 … HL2 … HL0) -L /2 width=3/
+  ]
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lfpcs_strip: ∀L,L1. ⦃L⦄ ⬌* ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌ ⦃L2⦄ →
+                   ∃∃L0. ⦃L1⦄ ⬌ ⦃L0⦄ & ⦃L2⦄ ⬌* ⦃L0⦄.
+/3 width=3/ qed.
+
+(* Main properties **********************************************************)
+
+theorem lfpcs_trans: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/2 width=3/ qed.
+
+theorem lfpcs_canc_sn: ∀L,L1,L2. ⦃L⦄ ⬌* ⦃L1⦄ → ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3 by lfpcs_trans, lfpcs_sym/ qed.
+
+theorem lfpcs_canc_dx: ∀L,L1,L2. ⦃L1⦄ ⬌* ⦃L⦄ → ⦃L2⦄ ⬌* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+/3 width=3 by lfpcs_trans, lfpcs_sym/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpc/lfpcs_lfprs.etc
new file mode 100644 (file)
index 0000000..baf2caf
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/lfprs.ma".
+include "basic_2/equivalence/lfpcs.ma".
+
+(* FOCALIZED PARALLEL EQUIVALENCE ON LOCAL ENVIRONMENTS *********************)
+
+(* Properties on focalized computation for local environments ***************)
+
+lemma lfpcs_lfprs_dx: ∀L1,L2. ⦃L1⦄ ➡* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L2 #H @(lfprs_ind … H) -L2 /width=1/ /3 width=3/
+qed.
+
+lemma lfpcs_lfprs_sn: ∀L1,L2. ⦃L2⦄ ➡* ⦃L1⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L2 #H @(lfprs_ind_dx … H) -L2 /width=1/ /3 width=3/
+qed.
+
+lemma lfpcs_lfprs_strap1: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L⦄ ➡* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L #HL1 #L2 #H @(lfprs_ind … H) -L2 /width=1/ /2 width=3/
+qed.
+
+lemma lfpcs_lfprs_strap2: ∀L1,L. ⦃L1⦄ ➡* ⦃L⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L #H #L2 #HL2 @(lfprs_ind_dx … H) -L1 /width=1/ /2 width=3/
+qed.
+
+lemma lfpcs_lfprs_div: ∀L1,L. ⦃L1⦄ ⬌* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L #HL1 #L2 #H @(lfprs_ind_dx … H) -L2 /width=1/ /2 width=3/
+qed.
+
+lemma lfpcs_lfprs_conf: ∀L1,L. ⦃L⦄ ➡* ⦃L1⦄ → ∀L2. ⦃L⦄ ⬌* ⦃L2⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L #H #L2 #HL2 @(lfprs_ind … H) -L1 /width=1/ /2 width=3/
+qed.
+
+lemma lfprs_div: ∀L1,L. ⦃L1⦄ ➡* ⦃L⦄ → ∀L2. ⦃L2⦄ ➡* ⦃L⦄ → ⦃L1⦄ ⬌* ⦃L2⦄.
+#L1 #L #HL1 #L2 #H @(lfprs_ind_dx … H) -L2 /2 width=1/ /2 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpr_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpr_llpx_sn.etc
new file mode 100644 (file)
index 0000000..4db8587
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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".
+include "basic_2/reduction/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
+
+(* Properties on lazy sn pointwise extensions *******************************)
+
+lemma cpr_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
+                            (∀I.l_liftable (R I)) →
+                            (∀I.l_deliftable_sn (R I)) →
+                        ∀G. s_r_confluent1 … (cpr G) (llpx_sn R 0).
+#R #H1R #H2R #H3R #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
+[ //
+| #G #Ls #Ks #V1s #V2s #W2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
+| #a #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
+| #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+| #G #Ls #V #T1 #T2 #T #_ #HT2 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /3 width=10 by llpx_sn_inv_lift_le, ldrop_drop/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
+| #a #G #Ls #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_flat, llpx_sn_bind/
+| #a #G #Ls #V1 #V2 #V #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H //
+  #HW1 #HT1 @llpx_sn_bind_O /2 width=1 by/ @llpx_sn_flat (**) (* full auto too slow *)
+  [ /3 width=10 by llpx_sn_lift_le, ldrop_drop/
+  | /3 width=4 by llpx_sn_bind_repl_O/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpx_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/cpx_llpx_sn.etc
new file mode 100644 (file)
index 0000000..4181064
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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".
+include "basic_2/reduction/cpx.ma".
+
+(* CONTEXT-SENSITIVE EXTENDED PARALLEL REDUCTION FOR TERMS ******************)
+
+(* Properties on lazy sn pointwise extensions *******************************)
+
+(* Note: lemma 1000 *)
+lemma cpx_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
+                            (∀I.l_liftable (R I)) →
+                            (∀I.l_deliftable_sn (R I)) →
+                        ∀h,g,G. s_r_confluent1 … (cpx h g G) (llpx_sn R 0).
+#R #H1R #H2R #H3R #h #g #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
+[ //
+| /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
+| #I #G #Ls #Ks #V1s #V2s #W2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
+| #a #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
+| #I #G #Ls #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+| #G #Ls #V #T1 #T2 #T #_ #HT2 #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /3 width=10 by llpx_sn_inv_lift_le, ldrop_drop/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
+| #G #Ls #V1 #V2 #T #_ #IHV12 #Ld #H elim (llpx_sn_inv_flat … H) -H /2 width=1 by/
+| #a #G #Ls #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_flat, llpx_sn_bind/
+| #a #G #Ls #V1 #V2 #V #W1 #W2 #T1 #T2 #_ #HV2 #_ #_ #IHV12 #IHW12 #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  #HV1 #H elim (llpx_sn_inv_bind_O … H) -H //
+  #HW1 #HT1 @llpx_sn_bind_O /2 width=1 by/ @llpx_sn_flat (**) (* full auto too slow *)
+  [ /3 width=10 by llpx_sn_lift_le, ldrop_drop/
+  | /3 width=4 by llpx_sn_bind_repl_O/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lleq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lleq.etc
new file mode 100644 (file)
index 0000000..dc138a4
--- /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/llpx_sn.ma".
+
+(* LAZY EQUIVALENCE FOR LOCAL ENVIRONMENTS **********************************)
+
+definition ceq: relation4 bind2 lenv term term ≝ λI,L,T1,T2. T1 = T2.
+
+definition lleq: relation4 ynat term lenv lenv ≝ llpx_sn ceq.
+
+interpretation
+   "lazy equivalence (local environment)"
+   'LazyEq T d L1 L2 = (lleq d T L1 L2).
+
+definition lleq_transitive: predicate (relation4 bind2 lenv term term) ≝
+           λR. ∀I,L2,T1,T2. R I L2 T1 T2 → ∀L1. L1 ≡[T1, 0] L2 → R I L1 T1 T2.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lleq_ind: ∀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
+                ) → (
+                   ∀I,L1,L2,K1,K2,V,d,i. d ≤ yinj i →
+                   ⇩[i] L1 ≡ K1.ⓑ{I}V → ⇩[i] L2 ≡ K2.ⓑ{I}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 H -L1 -L2 -T -d /2 width=8 by/
+qed-.
+
+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.
+/2 width=2 by llpx_sn_inv_bind/ 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.
+/2 width=2 by llpx_sn_inv_flat/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lleq_fwd_length: ∀L1,L2,T,d. L1 ≡[T, d] L2 → |L1| = |L2|.
+/2 width=4 by llpx_sn_fwd_length/ qed-.
+
+lemma lleq_fwd_lref: ∀L1,L2,d,i. L1 ≡[#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 ≡[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: ∀L1,L2,T,d. L1 ≡[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: ∀L1,L2,T,d. L1 ≡[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 ≡[ⓑ{a,I}V.T, d] L2 → L1 ≡[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 ≡[ⓑ{a,I}V.T, d] L2 → L1.ⓑ{I}V ≡[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 ≡[ⓕ{I}V.T, d] L2 → L1 ≡[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 ≡[ⓕ{I}V.T, d] L2 → L1 ≡[T, d] L2.
+/2 width=3 by llpx_sn_fwd_flat_dx/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lleq_sort: ∀L1,L2,d,k. |L1| = |L2| → L1 ≡[⋆k, d] L2.
+/2 width=1 by llpx_sn_sort/ qed.
+
+lemma lleq_skip: ∀L1,L2,d,i. yinj i < d → |L1| = |L2| → L1 ≡[#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 ≡[V, 0] K2 → L1 ≡[#i, d] L2.
+/2 width=9 by llpx_sn_lref/ qed.
+
+lemma lleq_free: ∀L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| → L1 ≡[#i, d] L2.
+/2 width=1 by llpx_sn_free/ qed.
+
+lemma lleq_gref: ∀L1,L2,d,p. |L1| = |L2| → L1 ≡[§p, d] L2.
+/2 width=1 by llpx_sn_gref/ 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.
+/2 width=1 by llpx_sn_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.
+/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: ∀L1,L2,T. |L1| = |L2| → L1 ≡[T, ∞] L2.
+/2 width=1 by llpx_sn_Y/ qed.
+
+lemma lleq_sym: ∀d,T. symmetric … (lleq d T).
+#d #T #L1 #L2 #H @(lleq_ind … H) -d -T -L1 -L2
+/2 width=7 by lleq_sort, lleq_skip, lleq_lref, lleq_free, lleq_gref, lleq_bind, lleq_flat/
+qed-.
+
+lemma lleq_ge_up: ∀L1,L2,U,dt. L1 ≡[U, dt] L2 →
+                  ∀T,d,e. ⇧[d, e] T ≡ U →
+                  dt ≤ d + e → L1 ≡[U, d] L2.
+/2 width=6 by llpx_sn_ge_up/ qed-.
+
+lemma lleq_ge: ∀L1,L2,T,d1. L1 ≡[T, d1] L2 → ∀d2. d1 ≤ d2 → L1 ≡[T, d2] L2.
+/2 width=3 by llpx_sn_ge/ 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.
+/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)) →
+                     ∀L1,L2,T,d. L1 ≡[T, d] L2 → llpx_sn R d T L1 L2.
+/2 width=3 by llpx_sn_co/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn.etc
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/etc_2A1/lpx_sn/llpx_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_alt.etc
new file mode 100644 (file)
index 0000000..0916edb
--- /dev/null
@@ -0,0 +1,62 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_alt.ma".
+include "basic_2/substitution/llpx_sn_alt_rec.ma".
+
+(* LAZY SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS ****)
+
+(* alternative definition of llpx_sn (not recursive) *)
+definition llpx_sn_alt: 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 **********************************************************)
+
+theorem llpx_sn_llpx_sn_alt: ∀R,T,L1,L2,d. llpx_sn R d T L1 L2 → llpx_sn_alt R d T L1 L2.
+#R #U #L1 @(f2_ind … rfw … L1 U) -L1 -U
+#n #IHn #L1 #U #Hn #L2 #d #H elim (llpx_sn_inv_alt_r … H) -H
+#HL12 #IHU @conj //
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #H #HLK1 #HLK2 elim (frees_inv_ge … H) -H //
+[ -n #HnU elim (IHU … HnU HLK1 HLK2) -IHU -HnU -HLK1 -HLK2 /2 width=1 by conj/
+| * #J1 #K10 #W10 #j #Hdj #Hji #HLK10 #HnW10 #HnU destruct
+  lapply (ldrop_fwd_drop2 … HLK10) #H
+  lapply (ldrop_conf_ge … H … HLK1 ?) -H /2 width=1 by lt_to_le/ <minus_plus #HK10
+  elim (ldrop_O1_lt (Ⓕ) L2 j) [2: <HL12 /2 width=5 by ldrop_fwd_length_lt2/ ] #J2 #K20 #W20 #HLK20
+  lapply (ldrop_fwd_drop2 … HLK20) #H
+  lapply (ldrop_conf_ge … H … HLK2 ?) -H /2 width=1 by lt_to_le/ <minus_plus #HK20
+  elim (IHn K10 W10 … K20 0) -IHn -HL12 /3 width=6 by ldrop_fwd_rfw/
+  elim (IHU … HnU HLK10 HLK20) -IHU -HnU -HLK10 -HLK20 //
+]
+qed.
+
+theorem llpx_sn_alt_inv_llpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt R d T L1 L2 → llpx_sn R d T L1 L2.
+#R #U #L1 @(f2_ind … rfw … L1 U) -L1 -U
+#n #IHn #L1 #U #Hn #L2 #d * #HL12 #IHU @llpx_sn_intro_alt_r //
+#I1 #I2 #K1 #K2 #V1 #V2 #i #Hdi #HnU #HLK1 #HLK2 destruct
+elim (IHU … HLK1 HLK2) /3 width=6 by nlift_frees/
+#H #HV12 @and3_intro // @IHn -IHn /3 width=6 by ldrop_fwd_rfw/
+lapply (ldrop_fwd_drop2 … HLK1) #H1
+lapply (ldrop_fwd_drop2 … HLK2) -HLK2 #H2
+@conj [ @(ldrop_fwd_length_eq1 … H1 H2) // ] -HL12
+#Z1 #Z2 #Y1 #Y2 #X1 #X2 #j #_
+>(minus_plus_m_m j (i+1)) in ⊢ (%→?); >commutative_plus <minus_plus
+#HnV1 #HKY1 #HKY2 (**) (* full auto too slow *)
+lapply (ldrop_trans_ge … H1 … HKY1 ?) -H1 -HKY1 // #HLY1
+lapply (ldrop_trans_ge … H2 … HKY2 ?) -H2 -HKY2 // #HLY2
+/4 width=14 by frees_be, yle_plus_dx2_trans, yle_succ_dx/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_alt_rec.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_alt_rec.etc
new file mode 100644 (file)
index 0000000..2671af0
--- /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_alt_r (R:relation4 bind2 lenv term term): relation4 ynat term lenv lenv ≝
+| llpx_sn_alt_r_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 R 0 V1 K1 K2
+                       ) → |L1| = |L2| → llpx_sn_alt_r R d T L1 L2
+.
+
+(* Compact definition of llpx_sn_alt_r **************************************)
+
+lemma llpx_sn_alt_r_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 R 0 V1 K1 K2
+                               ) → llpx_sn_alt_r R d T L1 L2.
+#R #L1 #L2 #T #d #HL12 #IH @llpx_sn_alt_r_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_r_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 R 0 V1 K1 K2 & S 0 V1 K1 K2
+                             ) → S d T L1 L2) →
+                             ∀L1,L2,T,d. llpx_sn_alt_r 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_r_inv_alt: ∀R,L1,L2,T,d. llpx_sn_alt_r 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 R 0 V1 K1 K2.
+#R #L1 #L2 #T #d #H @(llpx_sn_alt_r_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_r_inv_flat: ∀R,I,L1,L2,V,T,d. llpx_sn_alt_r R d (ⓕ{I}V.T) L1 L2 →
+                              llpx_sn_alt_r R d V L1 L2 ∧ llpx_sn_alt_r R d T L1 L2.
+#R #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H
+#HL12 #IH @conj @llpx_sn_alt_r_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_r_inv_bind: ∀R,a,I,L1,L2,V,T,d. llpx_sn_alt_r R d (ⓑ{a,I}V.T) L1 L2 →
+                              llpx_sn_alt_r R d V L1 L2 ∧ llpx_sn_alt_r R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V).
+#R #a #I #L1 #L2 #V #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H
+#HL12 #IH @conj @llpx_sn_alt_r_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_r_fwd_length: ∀R,L1,L2,T,d. llpx_sn_alt_r R d T L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #T #d #H elim (llpx_sn_alt_r_inv_alt … H) -H //
+qed-.
+
+lemma llpx_sn_alt_r_fwd_lref: ∀R,L1,L2,d,i. llpx_sn_alt_r 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 R (yinj 0) V1 K1 K2 &
+                                                  R I K1 V1 V2 & d ≤ yinj i.
+#R #L1 #L2 #d #i #H elim (llpx_sn_alt_r_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_r_sort: ∀R,L1,L2,d,k. |L1| = |L2| → llpx_sn_alt_r R d (⋆k) L1 L2.
+#R #L1 #L2 #d #k #HL12 @llpx_sn_alt_r_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (⋆k)) //
+qed.
+
+lemma llpx_sn_alt_r_gref: ∀R,L1,L2,d,p. |L1| = |L2| → llpx_sn_alt_r R d (§p) L1 L2.
+#R #L1 #L2 #d #p #HL12 @llpx_sn_alt_r_intro_alt // -HL12
+#I1 #I2 #K1 #K2 #V1 #V2 #i #_ #H elim (H (§p)) //
+qed.
+
+lemma llpx_sn_alt_r_skip: ∀R,L1,L2,d,i. |L1| = |L2| → yinj i < d → llpx_sn_alt_r R d (#i) L1 L2.
+#R #L1 #L2 #d #i #HL12 #Hid @llpx_sn_alt_r_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_r_free: ∀R,L1,L2,d,i. |L1| ≤ i → |L2| ≤ i → |L1| = |L2| →
+                          llpx_sn_alt_r R d (#i) L1 L2.
+#R #L1 #L2 #d #i #HL1 #_ #HL12 @llpx_sn_alt_r_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_r_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 R 0 V1 K1 K2 → R I K1 V1 V2 →
+                          llpx_sn_alt_r R d (#i) L1 L2.
+#R #I #L1 #L2 #K1 #K2 #V1 #V2 #d #i #Hdi #HLK1 #HLK2 #HK12 #HV12 @llpx_sn_alt_r_intro_alt
+[ lapply (llpx_sn_alt_r_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_r_flat: ∀R,I,L1,L2,V,T,d.
+                          llpx_sn_alt_r R d V L1 L2 → llpx_sn_alt_r R d T L1 L2 →
+                          llpx_sn_alt_r R d (ⓕ{I}V.T) L1 L2.
+#R #I #L1 #L2 #V #T #d #HV #HT
+elim (llpx_sn_alt_r_inv_alt … HV) -HV #HL12 #IHV
+elim (llpx_sn_alt_r_inv_alt … HT) -HT #_ #IHT
+@llpx_sn_alt_r_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_r_bind: ∀R,a,I,L1,L2,V,T,d.
+                          llpx_sn_alt_r R d V L1 L2 →
+                          llpx_sn_alt_r R (⫯d) T (L1.ⓑ{I}V) (L2.ⓑ{I}V) →
+                          llpx_sn_alt_r R d (ⓑ{a,I}V.T) L1 L2.
+#R #a #I #L1 #L2 #V #T #d #HV #HT
+elim (llpx_sn_alt_r_inv_alt … HV) -HV #HL12 #IHV
+elim (llpx_sn_alt_r_inv_alt … HT) -HT #_ #IHT
+@llpx_sn_alt_r_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: ∀R,L1,L2,T,d. llpx_sn R d T L1 L2 → llpx_sn_alt_r R d T L1 L2.
+#R #L1 #L2 #T #d #H elim H -L1 -L2 -T -d
+/2 width=9 by llpx_sn_alt_r_sort, llpx_sn_alt_r_gref, llpx_sn_alt_r_skip, llpx_sn_alt_r_free, llpx_sn_alt_r_lref, llpx_sn_alt_r_flat, llpx_sn_alt_r_bind/
+qed.
+
+(* Main inversion lemmas ****************************************************)
+
+theorem llpx_sn_alt_r_inv_lpx_sn: ∀R,T,L1,L2,d. llpx_sn_alt_r 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_r_fwd_length, llpx_sn_gref, llpx_sn_sort/
+| #i #Hn #L2 #d #H lapply (llpx_sn_alt_r_fwd_length … H)
+  #HL12 elim (llpx_sn_alt_r_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_r_inv_bind … H) -H
+  /3 width=1 by llpx_sn_bind/
+| #I #V #T #Hn #L2 #d #H elim (llpx_sn_alt_r_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+]
+qed-.
+
+(* Alternative definition of llpx_sn (recursive) ****************************)
+
+lemma llpx_sn_intro_alt_r: ∀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_r_inv_lpx_sn
+@llpx_sn_alt_r_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_r, and3_intro/
+qed.
+
+lemma llpx_sn_ind_alt_r: ∀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_r … H) -H
+#H @(llpx_sn_alt_r_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_r_inv_lpx_sn, and4_intro/
+qed-.
+
+lemma llpx_sn_inv_alt_r: ∀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_r … H) -H
+#H elim (llpx_sn_alt_r_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_r_inv_lpx_sn, and3_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_ldrop.etc
new file mode 100644 (file)
index 0000000..509a836
--- /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/etc_2A1/lpx_sn/llpx_sn_lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_lpx_sn.etc
new file mode 100644 (file)
index 0000000..21a88ca
--- /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/etc_2A1/lpx_sn/llpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/llpx_sn_tc.etc
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.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpr.etc
new file mode 100644 (file)
index 0000000..fd05f63
--- /dev/null
@@ -0,0 +1,61 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/predsn_3.ma".
+include "basic_2/relocation/lpx_sn.ma".
+include "basic_2/reduction/cpr.ma".
+
+(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
+
+definition lpr: relation3 genv lenv lenv ≝ λG. lpx_sn (λ_.cpr G).
+
+interpretation "parallel reduction (local environment, sn variant)"
+   'PRedSn G L1 L2 = (lpr G L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+(* Basic_1: includes: wcpr0_gen_sort *)
+lemma lpr_inv_atom1: ∀G,L2. ⦃G, ⋆⦄ ⊢ ➡ L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+(* Basic_1: includes: wcpr0_gen_head *)
+lemma lpr_inv_pair1: ∀I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡ L2 →
+                     ∃∃K2,V2. ⦃G, K1⦄ ⊢ ➡ K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2 & L2 = K2.ⓑ{I}V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+lemma lpr_inv_atom2: ∀G,L1. ⦃G, L1⦄ ⊢ ➡ ⋆ → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+lemma lpr_inv_pair2: ∀I,G,L1,K2,V2. ⦃G, L1⦄ ⊢ ➡ K2.ⓑ{I}V2 →
+                     ∃∃K1,V1. ⦃G, K1⦄ ⊢ ➡ K2 & ⦃G, K1⦄ ⊢ V1 ➡ V2 & L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+(* Basic properties *********************************************************)
+
+(* Note: lemma 250 *)
+lemma lpr_refl: ∀G,L. ⦃G, L⦄ ⊢ ➡ L.
+/2 width=1 by lpx_sn_refl/ qed.
+
+lemma lpr_pair: ∀I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ➡ K2 → ⦃G, K1⦄ ⊢ V1 ➡ V2 →
+                ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡ K2.ⓑ{I}V2.
+/2 width=1 by lpx_sn_pair/ qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpr_fwd_length: ∀G,L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
+
+(* Basic_1: removed theorems 3: wcpr0_getl wcpr0_getl_back
+                                pr0_subst1_back
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx.etc
new file mode 100644 (file)
index 0000000..2482329
--- /dev/null
@@ -0,0 +1,65 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/predsn_5.ma".
+include "basic_2/reduction/lpr.ma".
+include "basic_2/reduction/cpx.ma".
+
+(* SN EXTENDED PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS ********************)
+
+definition lpx: ∀h. sd h → relation3 genv lenv lenv ≝
+                λh,g,G. lpx_sn (λ_.cpx h g G).
+
+interpretation "extended parallel reduction (local environment, sn variant)"
+   'PRedSn h g G L1 L2 = (lpx h g G L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lpx_inv_atom1: ∀h,g,G,L2. ⦃G, ⋆⦄ ⊢ ➡[h, g] L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+lemma lpx_inv_pair1: ∀h,g,I,G,K1,V1,L2. ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡[h, g] L2 →
+                     ∃∃K2,V2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 &
+                              L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+lemma lpx_inv_atom2: ∀h,g,G,L1.  ⦃G, L1⦄ ⊢ ➡[h, g] ⋆ → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+lemma lpx_inv_pair2: ∀h,g,I,G,L1,K2,V2.  ⦃G, L1⦄ ⊢ ➡[h, g] K2.ⓑ{I}V2 →
+                     ∃∃K1,V1. ⦃G, K1⦄ ⊢ ➡[h, g] K2 & ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 &
+                             L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+lemma lpx_inv_pair: ∀h,g,I1,I2,G,L1,L2,V1,V2.  ⦃G, L1.ⓑ{I1}V1⦄ ⊢ ➡[h, g] L2.ⓑ{I2}V2 →
+                    ∧∧ ⦃G, L1⦄ ⊢ ➡[h, g] L2 & ⦃G, L1⦄ ⊢ V1 ➡[h, g] V2 & I1 = I2.
+/2 width=1 by lpx_sn_inv_pair/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpx_refl: ∀h,g,G,L.  ⦃G, L⦄ ⊢ ➡[h, g] L.
+/2 width=1 by lpx_sn_refl/ qed.
+
+lemma lpx_pair: ∀h,g,I,G,K1,K2,V1,V2. ⦃G, K1⦄ ⊢ ➡[h, g] K2 → ⦃G, K1⦄ ⊢ V1 ➡[h, g] V2 →
+                ⦃G, K1.ⓑ{I}V1⦄ ⊢ ➡[h, g] K2.ⓑ{I}V2.
+/2 width=1 by lpx_sn_pair/ qed.
+
+lemma lpr_lpx: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L1⦄ ⊢ ➡[h, g] L2.
+#h #g #G #L1 #L2 #H elim H -L1 -L2 /3 width=1 by lpx_pair, cpr_cpx/
+qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpx_fwd_length: ∀h,g,G,L1,L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn.etc
new file mode 100644 (file)
index 0000000..eb640da
--- /dev/null
@@ -0,0 +1,89 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lenv_length.ma".
+
+(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
+
+inductive lpx_sn (R:relation4 bind2 lenv term term): relation lenv ≝
+| lpx_sn_atom: lpx_sn R (⋆) (⋆)
+| lpx_sn_pair: ∀I,K1,K2,V1,V2.
+               lpx_sn R K1 K2 → R I K1 V1 V2 →
+               lpx_sn R (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
+.
+
+(* Basic properties *********************************************************)
+
+lemma lpx_sn_refl: ∀R. (∀I,L. reflexive ? (R I L)) → reflexive … (lpx_sn R).
+#R #HR #L elim L -L /2 width=1 by lpx_sn_atom, lpx_sn_pair/
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lpx_sn_inv_atom1_aux: ∀R,L1,L2. lpx_sn R L1 L2 → L1 = ⋆ → L2 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_sn_inv_atom1: ∀R,L2. lpx_sn R (⋆) L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+fact lpx_sn_inv_pair1_aux: ∀R,L1,L2. lpx_sn R L1 L2 → ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
+                           ∃∃K2,V2. lpx_sn R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
+#R #L1 #L2 * -L1 -L2
+[ #J #K1 #V1 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #L #W #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma lpx_sn_inv_pair1: ∀R,I,K1,V1,L2. lpx_sn R (K1.ⓑ{I}V1) L2 →
+                        ∃∃K2,V2. lpx_sn R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+fact lpx_sn_inv_atom2_aux: ∀R,L1,L2. lpx_sn R L1 L2 → L2 = ⋆ → L1 = ⋆.
+#R #L1 #L2 * -L1 -L2
+[ //
+| #I #K1 #K2 #V1 #V2 #_ #_ #H destruct
+]
+qed-.
+
+lemma lpx_sn_inv_atom2: ∀R,L1. lpx_sn R L1 (⋆) → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+fact lpx_sn_inv_pair2_aux: ∀R,L1,L2. lpx_sn R L1 L2 → ∀I,K2,V2. L2 = K2.ⓑ{I}V2 →
+                           ∃∃K1,V1. lpx_sn R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
+#R #L1 #L2 * -L1 -L2
+[ #J #K2 #V2 #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #J #K #W #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma lpx_sn_inv_pair2: ∀R,I,L1,K2,V2. lpx_sn R L1 (K2.ⓑ{I}V2) →
+                        ∃∃K1,V1. lpx_sn R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+lemma lpx_sn_inv_pair: ∀R,I1,I2,L1,L2,V1,V2.
+                       lpx_sn R (L1.ⓑ{I1}V1) (L2.ⓑ{I2}V2) →
+                       ∧∧ lpx_sn R L1 L2 & R I1 L1 V1 V2 & I1 = I2.
+#R #I1 #I2 #L1 #L2 #V1 #V2 #H elim (lpx_sn_inv_pair1 … H) -H
+#L0 #V0 #HL10 #HV10 #H destruct /2 width=1 by and3_intro/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpx_sn_fwd_length: ∀R,L1,L2. lpx_sn R L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H -L1 -L2 normalize //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_alt.etc
new file mode 100644 (file)
index 0000000..8a0aa39
--- /dev/null
@@ -0,0 +1,125 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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.ma".
+include "basic_2/relocation/lpx_sn.ma".
+
+(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
+
+(* alternative definition of lpx_sn *)
+definition lpx_sn_alt: relation4 bind2 lenv term term → relation lenv ≝
+                       λR,L1,L2. |L1| = |L2| ∧
+                       (∀I1,I2,K1,K2,V1,V2,i.
+                          ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                          I1 = I2 ∧ R I1 K1 V1 V2
+                       ).
+
+(* Basic forward lemmas ******************************************************)
+
+lemma lpx_sn_alt_fwd_length: ∀R,L1,L2. lpx_sn_alt R L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H //
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lpx_sn_alt_inv_atom1: ∀R,L2. lpx_sn_alt R (⋆) L2 → L2 = ⋆.
+#R #L2 #H lapply (lpx_sn_alt_fwd_length … H) -H
+normalize /2 width=1 by length_inv_zero_sn/
+qed-.
+
+lemma lpx_sn_alt_inv_pair1: ∀R,I,L2,K1,V1. lpx_sn_alt R (K1.ⓑ{I}V1) L2 →
+                            ∃∃K2,V2. lpx_sn_alt R K1 K2 & R I K1 V1 V2 & L2 = K2.ⓑ{I}V2.
+#R #I1 #L2 #K1 #V1 #H elim H -H
+#H #IH elim (length_inv_pos_sn … H) -H
+#I2 #K2 #V2 #HK12 #H destruct
+elim (IH I1 I2 K1 K2 V1 V2 0) //
+#H #HV12 destruct @(ex3_2_intro … K2 V2) // -HV12
+@conj // -HK12
+#J1 #J2 #L1 #L2 #W1 #W2 #i #HKL1 #HKL2 elim (IH J1 J2 L1 L2 W1 W2 (i+1)) -IH
+/2 width=1 by ldrop_drop, conj/
+qed-.
+
+lemma lpx_sn_alt_inv_atom2: ∀R,L1. lpx_sn_alt R L1 (⋆) → L1 = ⋆.
+#R #L1 #H lapply (lpx_sn_alt_fwd_length … H) -H
+normalize /2 width=1 by length_inv_zero_dx/
+qed-.
+
+lemma lpx_sn_alt_inv_pair2: ∀R,I,L1,K2,V2. lpx_sn_alt R L1 (K2.ⓑ{I}V2) →
+                            ∃∃K1,V1. lpx_sn_alt R K1 K2 & R I K1 V1 V2 & L1 = K1.ⓑ{I}V1.
+#R #I2 #L1 #K2 #V2 #H elim H -H
+#H #IH elim (length_inv_pos_dx … H) -H
+#I1 #K1 #V1 #HK12 #H destruct
+elim (IH I1 I2 K1 K2 V1 V2 0) //
+#H #HV12 destruct @(ex3_2_intro … K1 V1) // -HV12
+@conj // -HK12
+#J1 #J2 #L1 #L2 #W1 #W2 #i #HKL1 #HKL2 elim (IH J1 J2 L1 L2 W1 W2 (i+1)) -IH
+/2 width=1 by ldrop_drop, conj/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpx_sn_alt_atom: ∀R. lpx_sn_alt R (⋆) (⋆).
+#R @conj //
+#I1 #I2 #K1 #K2 #V1 #V2 #i #HLK1 elim (ldrop_inv_atom1 … HLK1) -HLK1
+#H destruct
+qed.
+
+lemma lpx_sn_alt_pair: ∀R,I,L1,L2,V1,V2.
+                       lpx_sn_alt R L1 L2 → R I L1 V1 V2 →
+                       lpx_sn_alt R (L1.ⓑ{I}V1) (L2.ⓑ{I}V2).
+#R #I #L1 #L2 #V1 #V2 #H #HV12 elim H -H
+#HL12 #IH @conj normalize //
+#I1 #I2 #K1 #K2 #W1 #W2 #i @(nat_ind_plus … i) -i
+[ #HLK1 #HLK2
+  lapply (ldrop_inv_O2 … HLK1) -HLK1 #H destruct
+  lapply (ldrop_inv_O2 … HLK2) -HLK2 #H destruct
+  /2 width=1 by conj/
+| -HL12 -HV12 /3 width=6 by ldrop_inv_drop1/
+]
+qed.
+
+(* Main properties **********************************************************)
+
+theorem lpx_sn_lpx_sn_alt: ∀R,L1,L2. lpx_sn R L1 L2 → lpx_sn_alt R L1 L2.
+#R #L1 #L2 #H elim H -L1 -L2
+/2 width=1 by lpx_sn_alt_atom, lpx_sn_alt_pair/
+qed.
+
+(* Main inversion lemmas ****************************************************)
+
+theorem lpx_sn_alt_inv_lpx_sn: ∀R,L1,L2. lpx_sn_alt R L1 L2 → lpx_sn R L1 L2.
+#R #L1 elim L1 -L1
+[ #L2 #H lapply (lpx_sn_alt_inv_atom1 … H) -H //
+| #L1 #I #V1 #IH #X #H elim (lpx_sn_alt_inv_pair1 … H) -H
+  #L2 #V2 #HL12 #HV12 #H destruct /3 width=1 by lpx_sn_pair/
+]
+qed-.
+
+(* alternative definition of lpx_sn *****************************************)
+
+lemma lpx_sn_intro_alt: ∀R,L1,L2. |L1| = |L2| →
+                        (∀I1,I2,K1,K2,V1,V2,i.
+                           ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                           I1 = I2 ∧ R I1 K1 V1 V2
+                        ) → lpx_sn R L1 L2.
+/4 width=4 by lpx_sn_alt_inv_lpx_sn, conj/ qed.
+
+lemma lpx_sn_inv_alt: ∀R,L1,L2. lpx_sn R L1 L2 →
+                      |L1| = |L2| ∧
+                      ∀I1,I2,K1,K2,V1,V2,i.
+                      ⇩[i] L1 ≡ K1.ⓑ{I1}V1 → ⇩[i] L2 ≡ K2.ⓑ{I2}V2 →
+                      I1 = I2 ∧ R I1 K1 V1 V2.
+#R #L1 #L2 #H lapply (lpx_sn_lpx_sn_alt … H) -H
+#H elim H -H /3 width=4 by conj/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_ldrop.etc
new file mode 100644 (file)
index 0000000..2b44e20
--- /dev/null
@@ -0,0 +1,104 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpx_sn.ma".
+
+(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
+
+(* Properies on dropping ****************************************************)
+
+lemma lpx_sn_ldrop_conf: ∀R,L1,L2. lpx_sn R L1 L2 →
+                         ∀I,K1,V1,i. ⇩[i] L1 ≡ K1.ⓑ{I}V1 →
+                         ∃∃K2,V2. ⇩[i] L2 ≡ K2.ⓑ{I}V2 & lpx_sn R K1 K2 & R I K1 V1 V2.
+#R #L1 #L2 #H elim H -L1 -L2
+[ #I0 #K0 #V0 #i #H elim (ldrop_inv_atom1 … H) -H #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #IHK12 #I0 #K0 #V0 #i #H elim (ldrop_inv_O1_pair1 … H) * -H
+  [ -IHK12 #H1 #H2 destruct /3 width=5 by ldrop_pair, ex3_2_intro/
+  | -HK12 -HV12 #Hi #HK10 elim (IHK12 … HK10) -IHK12 -HK10
+    /3 width=5 by ldrop_drop_lt, ex3_2_intro/
+  ]
+]
+qed-.
+
+lemma lpx_sn_ldrop_trans: ∀R,L1,L2. lpx_sn R L1 L2 →
+                          ∀I,K2,V2,i. ⇩[i] L2 ≡ K2.ⓑ{I}V2 →
+                          ∃∃K1,V1. ⇩[i] L1 ≡ K1.ⓑ{I}V1 & lpx_sn R K1 K2 & R I K1 V1 V2.
+#R #L1 #L2 #H elim H -L1 -L2
+[ #I0 #K0 #V0 #i #H elim (ldrop_inv_atom1 … H) -H #H destruct
+| #I #K1 #K2 #V1 #V2 #HK12 #HV12 #IHK12 #I0 #K0 #V0 #i #H elim (ldrop_inv_O1_pair1 … H) * -H
+  [ -IHK12 #H1 #H2 destruct /3 width=5 by ldrop_pair, ex3_2_intro/
+  | -HK12 -HV12 #Hi #HK10 elim (IHK12 … HK10) -IHK12 -HK10
+    /3 width=5 by ldrop_drop_lt, ex3_2_intro/
+  ]
+]
+qed-.
+
+lemma lpx_sn_deliftable_dropable: ∀R. (∀I. l_deliftable_sn (R I)) → dropable_sn (lpx_sn R).
+#R #HR #L1 #K1 #s #d #e #H elim H -L1 -K1 -d -e
+[ #d #e #He #X #H >(lpx_sn_inv_atom1 … H) -H
+  /4 width=3 by ldrop_atom, lpx_sn_atom, ex2_intro/
+| #I #K1 #V1 #X #H elim (lpx_sn_inv_pair1 … H) -H
+  #L2 #V2 #HL12 #HV12 #H destruct
+  /3 width=5 by ldrop_pair, lpx_sn_pair, ex2_intro/
+| #I #L1 #K1 #V1 #e #_ #IHLK1 #X #H elim (lpx_sn_inv_pair1 … H) -H
+  #L2 #V2 #HL12 #HV12 #H destruct
+  elim (IHLK1 … HL12) -L1 /3 width=3 by ldrop_drop, ex2_intro/
+| #I #L1 #K1 #V1 #W1 #d #e #HLK1 #HWV1 #IHLK1 #X #H
+  elim (lpx_sn_inv_pair1 … H) -H #L2 #V2 #HL12 #HV12 #H destruct
+  elim (HR … HV12 … HLK1 … HWV1) -V1
+  elim (IHLK1 … HL12) -L1 /3 width=5 by ldrop_skip, lpx_sn_pair, ex2_intro/
+]
+qed-.
+
+lemma lpx_sn_liftable_dedropable: ∀R. (∀I,L. reflexive ? (R I L)) →
+                                  (∀I. l_liftable (R I)) → dedropable_sn (lpx_sn R).
+#R #H1R #H2R #L1 #K1 #s #d #e #H elim H -L1 -K1 -d -e
+[ #d #e #He #X #H >(lpx_sn_inv_atom1 … H) -H
+  /4 width=4 by ldrop_atom, lpx_sn_atom, ex3_intro/
+| #I #K1 #V1 #X #H elim (lpx_sn_inv_pair1 … H) -H
+  #K2 #V2 #HK12 #HV12 #H destruct
+  lapply (lpx_sn_fwd_length … HK12)
+  #H @(ex3_intro … (K2.ⓑ{I}V2)) (**) (* explicit constructor *)
+  /3 width=1 by lpx_sn_pair, monotonic_le_plus_l/
+  @leq_O2 normalize //
+| #I #L1 #K1 #V1 #e #_ #IHLK1 #K2 #HK12 elim (IHLK1 … HK12) -K1
+  /3 width=5 by ldrop_drop, leq_pair, lpx_sn_pair, ex3_intro/
+| #I #L1 #K1 #V1 #W1 #d #e #HLK1 #HWV1 #IHLK1 #X #H
+  elim (lpx_sn_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
+  elim (lift_total W2 d e) #V2 #HWV2
+  lapply (H2R … HW12 … HLK1 … HWV1 … HWV2) -W1
+  elim (IHLK1 … HK12) -K1
+  /3 width=6 by ldrop_skip, leq_succ, lpx_sn_pair, ex3_intro/
+]
+qed-.
+
+fact lpx_sn_dropable_aux: ∀R,L2,K2,s,d,e. ⇩[s, d, e] L2 ≡ K2 → ∀L1. lpx_sn R L1 L2 →
+                          d = 0 → ∃∃K1. ⇩[s, 0, e] L1 ≡ K1 & lpx_sn R K1 K2.
+#R #L2 #K2 #s #d #e #H elim H -L2 -K2 -d -e
+[ #d #e #He #X #H >(lpx_sn_inv_atom2 … H) -H 
+  /4 width=3 by ldrop_atom, lpx_sn_atom, ex2_intro/
+| #I #K2 #V2 #X #H elim (lpx_sn_inv_pair2 … H) -H
+  #K1 #V1 #HK12 #HV12 #H destruct
+  /3 width=5 by ldrop_pair, lpx_sn_pair, ex2_intro/
+| #I #L2 #K2 #V2 #e #_ #IHLK2 #X #H #_ elim (lpx_sn_inv_pair2 … H) -H
+  #L1 #V1 #HL12 #HV12 #H destruct
+  elim (IHLK2 … HL12) -L2 /3 width=3 by ldrop_drop, ex2_intro/
+| #I #L2 #K2 #V2 #W2 #d #e #_ #_ #_ #L1 #_
+  <plus_n_Sm #H destruct
+]
+qed-.
+
+lemma lpx_sn_dropable: ∀R. dropable_dx (lpx_sn R).
+/2 width=5 by lpx_sn_dropable_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_lpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_lpx_sn.etc
new file mode 100644 (file)
index 0000000..bd72cf6
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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.ma".
+
+(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
+
+definition lpx_sn_confluent: relation (relation3 lenv term term) ≝ λR1,R2.
+                             ∀L0,T0,T1. R1 L0 T0 T1 → ∀T2. R2 L0 T0 T2 →
+                             ∀L1. lpx_sn (λ_.R1) L0 L1 → ∀L2. lpx_sn (λ_.R2) L0 L2 →
+                             ∃∃T. R2 L1 T1 T & R1 L2 T2 T.
+
+definition lpx_sn_transitive: relation (relation3 lenv term term) ≝ λR1,R2.
+                              ∀L1,T1,T. R1 L1 T1 T → ∀L2. lpx_sn (λ_.R1) L1 L2 →
+                              ∀T2. R2 L2 T T2 → R1 L1 T1 T2.
+
+(* Main properties **********************************************************)
+
+theorem lpx_sn_trans: ∀R. lpx_sn_transitive R R → Transitive … (lpx_sn (λ_.R)).
+#R #HR #L1 #L #H elim H -L1 -L //
+#I #L1 #L #V1 #V #HL1 #HV1 #IHL1 #X #H
+elim (lpx_sn_inv_pair1 … H) -H #L2 #V2 #HL2 #HV2 #H destruct /3 width=5 by lpx_sn_pair/
+qed-.
+
+theorem lpx_sn_conf: ∀R1,R2. lpx_sn_confluent R1 R2 →
+                     confluent2 … (lpx_sn (λ_.R1)) (lpx_sn (λ_.R2)).
+#R1 #R2 #HR12 #L0 @(f_ind … length … L0) -L0 #n #IH *
+[ #_ #X1 #H1 #X2 #H2 -n
+  >(lpx_sn_inv_atom1 … H1) -X1
+  >(lpx_sn_inv_atom1 … H2) -X2 /2 width=3 by lpx_sn_atom, ex2_intro/
+| #L0 #I #V0 #Hn #X1 #H1 #X2 #H2 destruct
+  elim (lpx_sn_inv_pair1 … H1) -H1 #L1 #V1 #HL01 #HV01 #H destruct
+  elim (lpx_sn_inv_pair1 … H2) -H2 #L2 #V2 #HL02 #HV02 #H destruct
+  elim (IH … HL01 … HL02) -IH normalize // #L #HL1 #HL2
+  elim (HR12 … HV01 … HV02 … HL01 … HL02) -L0 -V0 /3 width=5 by lpx_sn_pair, ex2_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_tc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/lpx_sn_tc.etc
new file mode 100644 (file)
index 0000000..2a3a87c
--- /dev/null
@@ -0,0 +1,119 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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.ma".
+
+(* SN POINTWISE EXTENSION OF A CONTEXT-SENSITIVE REALTION FOR TERMS *********)
+
+(* Properties on transitive_closure *****************************************)
+
+lemma TC_lpx_sn_pair_refl: ∀R. (∀I,L. reflexive … (R I L)) →
+                           ∀L1,L2. TC … (lpx_sn R) L1 L2 →
+                           ∀I,V. TC … (lpx_sn R) (L1.ⓑ{I}V) (L2. ⓑ{I}V).
+#R #HR #L1 #L2 #H @(TC_star_ind … L2 H) -L2
+[ /2 width=1 by lpx_sn_refl/
+| /3 width=1 by TC_reflexive, lpx_sn_refl/
+| /3 width=5 by lpx_sn_pair, step/
+]
+qed-.
+
+lemma TC_lpx_sn_pair: ∀R. (∀I,L. reflexive … (R I L)) →
+                      ∀I,L1,L2. TC … (lpx_sn R) L1 L2 →
+                      ∀V1,V2. LTC … (R I) L1 V1 V2 →
+                      TC … (lpx_sn R) (L1.ⓑ{I}V1) (L2. ⓑ{I}V2).
+#R #HR #I #L1 #L2 #HL12 #V1 #V2 #H @(TC_star_ind_dx … V1 H) -V1 //
+[ /2 width=1 by TC_lpx_sn_pair_refl/
+| /4 width=3 by TC_strap, lpx_sn_pair, lpx_sn_refl/
+]
+qed-.
+
+lemma lpx_sn_LTC_TC_lpx_sn: ∀R. (∀I,L. reflexive … (R I L)) →
+                            ∀L1,L2. lpx_sn (λI.LTC … (R I)) L1 L2 →
+                            TC … (lpx_sn R) L1 L2.
+#R #HR #L1 #L2 #H elim H -L1 -L2
+/2 width=1 by TC_lpx_sn_pair, lpx_sn_atom, inj/
+qed-.
+
+(* Inversion lemmas on transitive closure ***********************************)
+
+lemma TC_lpx_sn_inv_atom2: ∀R,L1. TC … (lpx_sn R) L1 (⋆) → L1 = ⋆.
+#R #L1 #H @(TC_ind_dx … L1 H) -L1
+[ /2 width=2 by lpx_sn_inv_atom2/
+| #L1 #L #HL1 #_ #IHL2 destruct /2 width=2 by lpx_sn_inv_atom2/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_pair2: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
+                           ∀I,L1,K2,V2. TC  … (lpx_sn R) L1 (K2.ⓑ{I}V2) →
+                           ∃∃K1,V1. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L1 = K1.ⓑ{I}V1.
+#R #HR #I #L1 #K2 #V2 #H @(TC_ind_dx … L1 H) -L1
+[ #L1 #H elim (lpx_sn_inv_pair2 … H) -H /3 width=5 by inj, ex3_2_intro/
+| #L1 #L #HL1 #_ * #K #V #HK2 #HV2 #H destruct
+  elim (lpx_sn_inv_pair2 … HL1) -HL1 #K1 #V1 #HK1 #HV1 #H destruct
+  lapply (HR … HV2 … HK1) -HR -HV2 /3 width=5 by TC_strap, ex3_2_intro/
+]
+qed-.
+
+lemma TC_lpx_sn_ind: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
+                     ∀S:relation lenv.
+                     S (⋆) (⋆) → (
+                        ∀I,K1,K2,V1,V2.
+                        TC … (lpx_sn R) K1 K2 → LTC … (R I) K1 V1 V2 →
+                        S K1 K2 → S (K1.ⓑ{I}V1) (K2.ⓑ{I}V2)
+                     ) →
+                     ∀L2,L1. TC … (lpx_sn R) L1 L2 → S L1 L2.
+#R #HR #S #IH1 #IH2 #L2 elim L2 -L2
+[ #X #H >(TC_lpx_sn_inv_atom2 … H) -X //
+| #L2 #I #V2 #IHL2 #X #H
+  elim (TC_lpx_sn_inv_pair2 … H) // -H -HR
+  #L1 #V1 #HL12 #HV12 #H destruct /3 width=1 by/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_atom1: ∀R,L2. TC … (lpx_sn R) (⋆) L2 → L2 = ⋆.
+#R #L2 #H elim H -L2
+[ /2 width=2 by lpx_sn_inv_atom1/
+| #L #L2 #_ #HL2 #IHL1 destruct /2 width=2 by lpx_sn_inv_atom1/
+]
+qed-.
+
+fact TC_lpx_sn_inv_pair1_aux: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
+                              ∀L1,L2. TC … (lpx_sn R) L1 L2 →
+                              ∀I,K1,V1. L1 = K1.ⓑ{I}V1 →
+                              ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L2 = K2. ⓑ{I} V2.
+#R #HR #L1 #L2 #H @(TC_lpx_sn_ind … H) // -HR -L1 -L2
+[ #J #K #W #H destruct
+| #I #L1 #L2 #V1 #V2 #HL12 #HV12 #_ #J #K #W #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma TC_lpx_sn_inv_pair1: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
+                           ∀I,K1,L2,V1. TC … (lpx_sn R) (K1.ⓑ{I}V1) L2 →
+                           ∃∃K2,V2. TC … (lpx_sn R) K1 K2 & LTC … (R I) K1 V1 V2 & L2 = K2. ⓑ{I} V2.
+/2 width=3 by TC_lpx_sn_inv_pair1_aux/ qed-.
+
+lemma TC_lpx_sn_inv_lpx_sn_LTC: ∀R. (∀I.s_rs_transitive … (R I) (λ_.lpx_sn R)) →
+                                ∀L1,L2. TC … (lpx_sn R) L1 L2 →
+                                lpx_sn (λI.LTC … (R I)) L1 L2.
+/3 width=4 by TC_lpx_sn_ind, lpx_sn_pair/ qed-.
+
+(* Forward lemmas on transitive closure *************************************)
+
+lemma TC_lpx_sn_fwd_length: ∀R,L1,L2. TC … (lpx_sn R) L1 L2 → |L1| = |L2|.
+#R #L1 #L2 #H elim H -L2
+[ #L2 #HL12 >(lpx_sn_fwd_length … HL12) -HL12 //
+| #L #L2 #_ #HL2 #IHL1
+  >IHL1 -L1 >(lpx_sn_fwd_length … HL2) -HL2 //
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/ssta_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lpx_sn/ssta_llpx_sn.etc
new file mode 100644 (file)
index 0000000..3b1db6a
--- /dev/null
@@ -0,0 +1,44 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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".
+include "basic_2/static/ssta.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ******************************)
+
+(* Properties on lazy sn pointwise extensions *******************************)
+
+lemma ssta_llpx_sn_conf: ∀R. (∀I,L.reflexive … (R I L)) →
+                             (∀I.l_liftable (R I)) →
+                         ∀h,g,G. s_r_confluent1 … (ssta h g G) (llpx_sn R 0).
+#R #H1R #H2R #h #g #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
+[ /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
+| #G #Ls #Ks #V1s #W2s #V2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
+| #G #Ls #Ks #V1s #W1s #l #i #HLKs #Hl #HVW1s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (ldrop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (ldrop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HVW1s) -HLKs -HLKd -HVW1s /2 width=1 by/ (**) (* full auto too slow *)
+| #a #I #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubn/lsubn_lsubn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubn/lsubn_lsubn.etc
new file mode 100644 (file)
index 0000000..9ef3dda
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/lsubn_nta.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
+
+(* Main properties **********************************************************)
+
+(* Note: new property *)
+theorem lsubn_trans: ∀h,L1,L. h ⊢ L1 :⊑ L → ∀L2. h ⊢ L :⊑ L2 → h ⊢ L1 :⊑ L2.
+#h #L1 #L #H elim H -L1 -L
+[ #X #H >(lsubn_inv_atom1 … H) -H //
+| #I #L1 #L #V #HL1 #H1W #IHL1 #X #H
+  elim (lsubn_inv_pair1 … H) -H * #L2
+  [ #HL2 #H #H2W destruct /4 width=1/
+  | #W #H1VW #H2VW #HL2 #H1 #H2 destruct /3 width=3/
+  ]
+| #L1 #L #V1 #W1 #H1VW1 #H2VW1 #HL1 #IHL1 #X #H
+  elim (lsubn_inv_pair1 … H) -H * #L2
+  [ #HL2 #H #HW destruct /3 width=1/
+  | #V #_ #_ #_ #_ #H destruct
+  ]
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/aaa_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/aaa_lpss.etc
new file mode 100644 (file)
index 0000000..e930823
--- /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/substitution/lpss_ldrop.ma".
+include "basic_2/static/aaa_lift.ma".
+
+(* ATONIC ARITY ASSIGNMENT ON TERMS *****************************************)
+
+(* Properties about sn parallel substitution ********************************)
+
+(* Note: lemma 500 *)
+lemma aaa_cpss_lpss_conf: ∀L1,T1,A. L1 ⊢ T1 ⁝ A → ∀T2. L1 ⊢ T1 ▶* T2 →
+                          ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T2 ⁝ A.
+#L1 #T1 #A #H elim H -L1 -T1 -A
+[ #L1 #k #X #H
+  >(cpss_inv_sort1 … H) -H //
+| #I #L1 #K1 #V1 #B #i #HLK1 #_ #IHV1 #X #H #L2 #HL12
+  elim (cpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
+  | * #Y #Z #V2 #H #HV12 #HV2
+    lapply (ldrop_mono … H … HLK1) -H #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #Z #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 /3 width=7/
+  ]
+| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=2/
+| #a #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /4 width=1/
+| #L1 #V1 #T1 #B #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=3/
+| #L1 #V1 #T1 #A #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct /3 width=1/
+]
+qed-.
+
+lemma aaa_cpss_conf: ∀L,T1,A. L ⊢ T1 ⁝ A → ∀T2. L ⊢ T1 ▶* T2 → L ⊢ T2 ⁝ A.
+/2 width=5 by aaa_cpss_lpss_conf/ qed-.
+
+lemma aaa_lpss_conf: ∀L1,T,A. L1 ⊢ T ⁝ A → ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T ⁝ A.
+/2 width=5 by aaa_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpcs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpcs_lpss.etc
new file mode 100644 (file)
index 0000000..09d2975
--- /dev/null
@@ -0,0 +1,50 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/cprs_lpss.ma".
+include "basic_2/equivalence/cpcs_cpcs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL EQUIVALENCE ON TERMS **************************)
+
+(* Properties on sn parallel substitution for local environments ************)
+
+lemma cpcs_lpss_conf: ∀L1,T1,T2. L1 ⊢ T1 ⬌* T2 →
+                      ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T1 ⬌* T2.
+#L1 #T1 #T2 #H #L2 #HL12
+elim (cpcs_inv_cprs … H) -H #T #HT1 #HT2
+elim (cprs_lpss_conf_dx … HT1 … HL12) -HT1 #U1 #H1 #HTU1
+elim (cprs_lpss_conf_dx … HT2 … HL12) -L1 #U2 #H2 #HTU2
+elim (cpss_conf … H1 … H2) -T #U #HU1 #HU2
+lapply (cprs_cpss_trans … HTU1 … HU1) -U1
+lapply (cprs_cpss_trans … HTU2 … HU2) -U2 /2 width=3/
+qed-.
+
+lemma cpcs_cpss_lpss_conf: ∀L1,T,T2. L1 ⊢ T ⬌* T2 → ∀T1. L1 ⊢ T ▶* T1 →
+                           ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T1 ⬌* T2.
+#L1 #T #T2 #HT2 #T1 #HT1 #L2 #HL12
+lapply (cpcs_lpss_conf … HT2 … HL12) -HT2 #HT2
+elim (lpss_cpss_conf_dx … HT1 … HL12) -L1 #T0 #HT0 #HT10
+lapply (cpcs_cpss_conf … HT0 … HT2) -T #HT02
+lapply (cpcs_cpss_strap2 … HT10 … HT02) -T0 //
+qed-.
+
+lemma cpcs_cpss2_lpss_conf: ∀L1,T1,T2. L1 ⊢ T1 ⬌* T2 →
+                            ∀T3. L1 ⊢ T1 ▶* T3 → ∀T4. L1 ⊢ T2 ▶* T4 →
+                            ∀L2. L1 ⊢ ▶* L2 → L2 ⊢ T3 ⬌* T4.
+#L1 #T1 #T2 #HT12 #T3 #HT13 #T4 #HT24 #L2 #HL12
+lapply (cpcs_cpss_lpss_conf … HT12 … HT13 … HL12) -T1 #HT32
+elim (lpss_cpss_conf_dx … HT24 … HL12) -L1 #T #HT2 #HT4
+lapply (cpcs_cpss_strap1 … HT32 … HT2) -T2 #HT3
+lapply (cpcs_cpss_div … HT3 … HT4) -T //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs.etc
new file mode 100644 (file)
index 0000000..4112036
--- /dev/null
@@ -0,0 +1,227 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 ➤ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PRestStar $L $T1 $T2 }.
+
+include "basic_2/substitution/cpss.ma".
+
+(* CONTEXT-SENSITIVE RESTRICTED PARALLEL COMPUTATION FOR TERMS **************)
+
+inductive cpqs: lenv → relation term ≝
+| cpqs_atom : ∀I,L. cpqs L (⓪{I}) (⓪{I})
+| cpqs_delta: ∀L,K,V,V2,W2,i.
+              ⇩[0, i] L ≡ K. ⓓV → cpqs K V V2 →
+              ⇧[0, i + 1] V2 ≡ W2 → cpqs L (#i) W2
+| cpqs_bind : ∀a,I,L,V1,V2,T1,T2.
+              cpqs L V1 V2 → cpqs (L. ⓑ{I} V1) T1 T2 →
+              cpqs L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| cpqs_flat : ∀I,L,V1,V2,T1,T2.
+              cpqs L V1 V2 → cpqs L T1 T2 →
+              cpqs L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+| cpqs_zeta : ∀L,V,T1,T,T2. cpqs (L.ⓓV) T1 T →
+              ⇧[0, 1] T2 ≡ T → cpqs L (+ⓓV. T1) T2
+| cpqs_tau  : ∀L,V,T1,T2. cpqs L T1 T2 → cpqs L (ⓝV. T1) T2
+.
+
+interpretation "context-sensitive restricted parallel computation (term)"
+   'PRestStar L T1 T2 = (cpqs L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma cpqs_lsubr_trans: lsub_trans … cpqs lsubr.
+#L1 #T1 #T2 #H elim H -L1 -T1 -T2
+[ //
+| #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (lsubr_fwd_ldrop2_abbr … HL12 … HLK1) -HL12 -HLK1 /3 width=6/
+| /4 width=1/
+|4,6: /3 width=1/
+| /4 width=3/
+]
+qed-.
+
+lemma cpss_cpqs: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➤* T2.
+#L #T1 #T2 #H elim H -L -T1 -T2 // /2 width=1/ /2 width=6/
+qed.
+
+lemma cpqs_refl: ∀T,L. L ⊢ T ➤* T.
+/2 width=1/ qed.
+
+lemma cpqs_delift: ∀L,K,V,T1,d. ⇩[0, d] L ≡ (K. ⓓV) →
+                   ∃∃T2,T. L ⊢ T1 ➤* T2 & ⇧[d, 1] T ≡ T2.
+#L #K #V #T1 #d #HLK
+elim (cpss_delift … T1 … HLK) -HLK /3 width=4/
+qed-.
+
+lemma cpqs_append: l_appendable_sn … cpqs.
+#K #T1 #T2 #H elim H -K -T1 -T2 // /2 width=1/ /2 width=3/
+#K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpqs_delta … (L@@K0) V1 … HVW2) //
+@(ldrop_O1_append_sn_le … HK0) /2 width=2/ (**) (* /3/ does not work *)
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact cpqs_inv_atom1_aux: ∀L,T1,T2. L ⊢ T1 ➤* T2 → ∀I. T1 = ⓪{I} →
+                         T2 = ⓪{I} ∨
+                         ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
+                                     K ⊢ V ➤* V2 &
+                                     ⇧[O, i + 1] V2 ≡ T2 &
+                                     I = LRef i.
+#L #T1 #T2 * -L -T1 -T2
+[ #I #L #J #H destruct /2 width=1/
+| #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #J #H destruct /3 width=8/
+| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+| #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+| #L #V #T1 #T #T2 #_ #_ #J #H destruct
+| #L #V #T1 #T2 #_ #J #H destruct
+]
+qed-.
+
+lemma cpqs_inv_atom1: ∀I,L,T2. L ⊢ ⓪{I} ➤* T2 →
+                      T2 = ⓪{I} ∨
+                      ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
+                                  K ⊢ V ➤* V2 &
+                                  ⇧[O, i + 1] V2 ≡ T2 &
+                                  I = LRef i.
+/2 width=3 by cpqs_inv_atom1_aux/ qed-.
+
+lemma cpqs_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ➤* T2 → T2 = ⋆k.
+#L #T2 #k #H
+elim (cpqs_inv_atom1 … H) -H //
+* #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+lemma cpqs_inv_lref1: ∀L,T2,i. L ⊢ #i ➤* T2 →
+                      T2 = #i ∨
+                      ∃∃K,V,V2. ⇩[O, i] L ≡ K. ⓓV &
+                                K ⊢ V ➤* V2 &
+                                ⇧[O, i + 1] V2 ≡ T2.
+#L #T2 #i #H
+elim (cpqs_inv_atom1 … H) -H /2 width=1/
+* #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=6/
+qed-.
+
+lemma cpqs_inv_gref1: ∀L,T2,p. L ⊢ §p ➤* T2 → T2 = §p.
+#L #T2 #p #H
+elim (cpqs_inv_atom1 … H) -H //
+* #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+fact cpqs_inv_bind1_aux: ∀L,U1,U2. L ⊢ U1 ➤* U2 →
+                         ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 → (
+                         ∃∃V2,T2. L ⊢ V1 ➤* V2 &
+                                  L. ⓑ{I} V1 ⊢ T1 ➤* T2 &
+                                  U2 = ⓑ{a,I} V2. T2
+                         ) ∨
+                         ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
+#L #U1 #U2 * -L -U1 -U2
+[ #I #L #b #J #W1 #U1 #H destruct
+| #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W1 #U1 #H destruct
+| #a #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W1 #U1 #H destruct /3 width=5/
+| #I #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W1 #U1 #H destruct
+| #L #V #T1 #T #T2 #HT1 #HT2 #b #J #W1 #U1 #H destruct /3 width=3/
+| #L #V #T1 #T2 #_ #b #J #W1 #U1 #H destruct
+]
+qed-.
+
+lemma cpqs_inv_bind1: ∀a,I,L,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ➤* U2 → (
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
+                               L. ⓑ{I} V1 ⊢ T1 ➤* T2 &
+                               U2 = ⓑ{a,I} V2. T2
+                      ) ∨
+                      ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true & I = Abbr.
+/2 width=3 by cpqs_inv_bind1_aux/ qed-.
+
+lemma cpqs_inv_abbr1: ∀a,L,V1,T1,U2. L ⊢ ⓓ{a} V1. T1 ➤* U2 → (
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
+                               L. ⓓ V1 ⊢ T1 ➤* T2 &
+                               U2 = ⓓ{a} V2. T2
+                      ) ∨
+                      ∃∃T. L.ⓓV1 ⊢ T1 ➤* T & ⇧[0, 1] U2 ≡ T & a = true.
+#a #L #V1 #T1 #U2 #H
+elim (cpqs_inv_bind1 … H) -H * /3 width=3/ /3 width=5/
+qed-.
+
+lemma cpqs_inv_abst1: ∀a,L,V1,T1,U2. L ⊢ ⓛ{a} V1. T1 ➤* U2 →
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 &
+                               L. ⓛ V1 ⊢ T1 ➤* T2 &
+                               U2 = ⓛ{a} V2. T2.
+#a #L #V1 #T1 #U2 #H
+elim (cpqs_inv_bind1 … H) -H *
+[ /3 width=5/
+| #T #_ #_ #_ #H destruct
+]
+qed-.
+
+fact cpqs_inv_flat1_aux: ∀L,U1,U2. L ⊢ U1 ➤* U2 →
+                         ∀I,V1,T1. U1 = ⓕ{I} V1. T1 → (
+                         ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
+                                  U2 = ⓕ{I} V2. T2
+                         ) ∨
+                         (L ⊢ T1 ➤* U2 ∧ I = Cast).
+#L #U1 #U2 * -L -U1 -U2
+[ #I #L #J #W1 #U1 #H destruct
+| #L #K #V #V2 #W2 #i #_ #_ #_ #J #W1 #U1 #H destruct
+| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #W1 #U1 #H destruct
+| #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W1 #U1 #H destruct /3 width=5/
+| #L #V #T1 #T #T2 #_ #_ #J #W1 #U1 #H destruct
+| #L #V #T1 #T2 #HT12 #J #W1 #U1 #H destruct /3 width=1/
+]
+qed-.
+
+lemma cpqs_inv_flat1: ∀I,L,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ➤* U2 → (
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
+                               U2 = ⓕ{I} V2. T2
+                      ) ∨
+                      (L ⊢ T1 ➤* U2 ∧ I = Cast).
+/2 width=3 by cpqs_inv_flat1_aux/ qed-.
+
+lemma cpqs_inv_appl1: ∀L,V1,T1,U2. L ⊢ ⓐ V1. T1 ➤* U2 →
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
+                               U2 = ⓐ V2. T2.
+#L #V1 #T1 #U2 #H elim (cpqs_inv_flat1 … H) -H *
+[ /3 width=5/
+| #_ #H destruct
+]
+qed-.
+
+lemma cpqs_inv_cast1: ∀L,V1,T1,U2. L ⊢ ⓝ V1. T1 ➤* U2 → (
+                      ∃∃V2,T2. L ⊢ V1 ➤* V2 & L ⊢ T1 ➤* T2 &
+                               U2 = ⓝ V2. T2
+                      ) ∨
+                      L ⊢ T1 ➤* U2.
+#L #V1 #T1 #U2 #H elim (cpqs_inv_flat1 … H) -H * /2 width=1/ /3 width=5/
+qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma cpqs_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ➤* T →
+                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X
+  >shift_append_assoc normalize #H
+  elim (cpqs_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 ] // /2 width=3/ (**) (* explicit constructor *)
+  | #T #_ #_ #H destruct
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpqs_lift.etc
new file mode 100644 (file)
index 0000000..78529b6
--- /dev/null
@@ -0,0 +1,81 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/cpqs.ma".
+
+(* CONTEXT-SENSITIVE RESTRICTED PARALLEL COMPUTATION FOR TERMS **************)
+
+(* Relocation properties ****************************************************)
+
+lemma cpqs_lift: l_liftable cpqs.
+#K #T1 #T2 #H elim H -K -T1 -T2
+[ #I #K #L #d #e #_ #U1 #H1 #U2 #H2
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #d #e #HLK #U1 #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
+    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2/ #X #HLK #H
+    elim (ldrop_inv_skip2 … H) -H /2 width=1/ -Hid #K #Y #HKV #HVY #H destruct /3 width=8/
+  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 // /2 width=1/ >plus_plus_comm_23 #HVU2
+    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=6/
+  ]
+| #a #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=5/
+| #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
+| #K #V #T1 #T #T2 #_ #HT2 #IHT1 #L #d #e #HLK #U1 #H #U2 #HTU2
+  elim (lift_inv_bind1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct
+  elim (lift_conf_O1 … HTU2 … HT2) -T2 /4 width=5/
+| #K #V #T1 #T2 #_ #IHT12 #L #d #e #HLK #U1 #H #U2 #HTU2
+  elim (lift_inv_flat1 … H) -H #VV1 #TT1 #HVV1 #HTT1 #H destruct /3 width=5/
+] 
+qed.
+
+lemma cpqs_inv_lift1: l_deliftable_sn cpqs.
+#L #U1 #U2 #H elim H -L -U1 -U2
+[ * #L #i #K #d #e #_ #T1 #H
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
+  ]
+| #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #d #e #HLK #T1 #H
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
+    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
+    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m // -Hid /3 width=8/
+  | elim (le_inv_plus_l … Hid) #Hdie #Hei
+    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
+    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
+    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O /3 width=8/
+  ]
+| #a #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=5/
+| #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -V1
+  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5/
+| #L #V #U1 #U #U2 #_ #HU2 #IHU1 #K #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHU1 (K.ⓓW1) … HTU1) /2 width=1/ -L -U1 #T #HTU #HT1
+  elim (lift_div_le … HU2 … HTU) -U // /3 width=5/
+| #L #V #U1 #U2 #_ #IHU12 #K #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHU12 … HLK … HTU1) -L -U1 /3 width=3/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cprs_lpss.etc
new file mode 100644 (file)
index 0000000..9887fa7
--- /dev/null
@@ -0,0 +1,92 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpss_lpss.ma".
+include "basic_2/reduction/lpr_lpss.ma".
+include "basic_2/computation/cprs.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL COMPUTATION ON TERMS **************************)
+
+(* Properties on parallel substitution for terms ****************************)
+
+(* Basic_1: was: pr3_subst1 *)
+lemma cprs_cpss_conf: ∀L,T0,T1. L ⊢ T0 ➡* T1 → ∀T2. L ⊢ T0 ▶* T2 →
+                      ∃∃T. L ⊢ T1 ▶* T & L ⊢ T2 ➡* T.
+#L @TC_strip1 /2 width=3 by cpr_cpss_conf/ qed-. (**) (* auto /3 width=3/ fails because a δ-expansion gets in the way *)
+
+(* Properties on sn parallel substitution for local environments ************)
+
+lemma cprs_lpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➡* T1 → ∀L1. L0 ⊢ ▶* L1 →
+                         ∃∃T. L1 ⊢ T1 ▶* T & L1 ⊢ T0 ➡* T.
+#L0 #T0 #T1 #H elim H -T1
+[ #T1 #HT01 #L1 #HL01
+  elim (cpr_lpss_conf_dx … HT01 … HL01) -L0 /3 width=3/
+| #T #T1 #_ #HT1 #IHT0 #L1 #HL01
+  elim (IHT0 … HL01) #T2 #HT2 #HT02
+  elim (cpr_lpss_conf_dx … HT1 … HL01) -L0 #T3 #HT13 #HT3
+  elim (cpr_cpss_conf … HT3 … HT2) -T #T #HT3 #HT2
+  lapply (cpss_trans … HT13 … HT3) -T3
+  lapply (cprs_strap1 … HT02 … HT2) -T2 /2 width=3/
+]
+qed-.
+
+lemma cprs_lpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➡* T1 → ∀L1. L0 ⊢ ▶* L1 →
+                         ∃∃T. L0 ⊢ T1 ▶* T & L1 ⊢ T0 ➡* T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cprs_lpss_conf_dx … HT01 … HL01) -HT01 #T #HT1
+lapply (lpss_cpss_trans … HL01 … HT1) -HT1 /2 width=3/
+qed-.
+
+lemma cprs_cpss_lpss_conf_sn: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
+                              ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
+                              ∃∃U2. L2 ⊢ T2 ➡* U2 & L1 ⊢ U1 ▶* U2.
+#L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
+elim (cprs_cpss_conf … HTU1 … HT12) -T1 #U #HU1 #HT2U
+elim (cprs_lpss_conf_sn … HT2U … HL12) -HT2U -HL12 #U2 #HU2 #HTU2
+lapply (cpss_trans … HU1 … HU2) -U /2 width=3/
+qed-.
+
+lemma cprs_cpss_lpss_conf_dx: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 →
+                              ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
+                              ∃∃U2. L2 ⊢ T2 ➡* U2 & L2 ⊢ U1 ▶* U2.
+#L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
+elim (cprs_lpss_conf_dx … HTU1 … HL12) -HTU1 #U2 #HU12 #HT1U2
+elim (lpss_cpss_conf_dx … HT12 … HL12) -L1 #T #HT1 #HT2
+elim (cprs_cpss_conf … HT1U2 … HT1) -T1 #U #HU2 #HTU
+lapply (cpss_trans … HU12 … HU2) -U2
+lapply (cpss_cprs_trans … HT2 … HTU) -T /2 width=3/
+qed-.
+
+
+lemma cprs_cpss2_lpss_conf_sn: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 → ∀T2. L1 ⊢ T1 ▶* T2 →
+                               ∀U2. L1 ⊢ U1 ▶* U2 → ∀L2. L1 ⊢ ▶* L2 →
+                               ∃∃U. L2 ⊢ T2 ➡* U & L1 ⊢ U2 ▶* U.
+#L1 #T1 #U1 #HTU1 #T2 #HT12 #U2 #HU12 #L2 #HL12
+elim (cprs_cpss_lpss_conf_sn … HTU1 … HT12 … HL12) -T1 #T1 #HT21 #HUT1
+elim (cpss_conf … HU12 … HUT1) -U1 #U1 #HU21 #HTU1
+elim (lpss_cpss_conf_sn … HTU1 … HL12) -HTU1 -HL12 #U2 #HT1U2 #HU12
+lapply (cpss_trans … HU21 … HU12) -U1
+lapply (cprs_cpss_trans … HT21 … HT1U2) -T1 /2 width=3/
+qed-.
+
+lemma cprs_cpss2_lpss_conf_dx: ∀L1,T1,U1. L1 ⊢ T1 ➡* U1 → ∀T2. L1 ⊢ T1 ▶* T2 →
+                               ∀U2. L1 ⊢ U1 ▶* U2 → ∀L2. L1 ⊢ ▶* L2 →
+                               ∃∃U. L2 ⊢ T2 ➡* U & L2 ⊢ U2 ▶* U.
+#L1 #T1 #U1 #HTU1 #T2 #HT12 #U2 #HU12 #L2 #HL12
+elim (cprs_cpss_lpss_conf_dx … HTU1 … HT12 … HL12) -T1 #T1 #HT21 #HUT1
+elim (lpss_cpss_conf_dx … HU12 … HL12) -L1 #U #HU1 #HU2
+elim (cpss_conf … HU1 … HUT1) -U1 #U1 #HU1 #HTU1
+lapply (cpss_trans … HU2 … HU1) -U
+lapply (cprs_cpss_trans … HT21 … HTU1) -T1 /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss.etc
new file mode 100644 (file)
index 0000000..16b9608
--- /dev/null
@@ -0,0 +1,199 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 ▶* break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStar $L $T1 $T2 }.
+
+include "basic_2/grammar/cl_shift.ma".
+include "basic_2/relocation/ldrop_append.ma".
+include "basic_2/substitution/lsubr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL SUBSTITUTION FOR TERMS ************************)
+
+inductive cpss: lenv → relation term ≝
+| cpss_atom : ∀I,L. cpss L (⓪{I}) (⓪{I})
+| cpss_delta: ∀L,K,V,V2,W2,i.
+              ⇩[0, i] L ≡ K. ⓓV → cpss K V V2 →
+              ⇧[0, i + 1] V2 ≡ W2 → cpss L (#i) W2
+| cpss_bind : ∀a,I,L,V1,V2,T1,T2.
+              cpss L V1 V2 → cpss (L. ⓑ{I} V1) T1 T2 →
+              cpss L (ⓑ{a,I} V1. T1) (ⓑ{a,I} V2. T2)
+| cpss_flat : ∀I,L,V1,V2,T1,T2.
+              cpss L V1 V2 → cpss L T1 T2 →
+              cpss L (ⓕ{I} V1. T1) (ⓕ{I} V2. T2)
+.
+
+interpretation "context-sensitive parallel substitution (term)"
+   'PSubstStar L T1 T2 = (cpss L T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma cpss_lsubr_trans: lsub_trans … cpss lsubr.
+#L1 #T1 #T2 #H elim H -L1 -T1 -T2
+[ //
+| #L1 #K1 #V1 #V2 #W2 #i #HLK1 #_ #HVW2 #IHV12 #L2 #HL12
+  elim (lsubr_fwd_ldrop2_abbr … HL12 … HLK1) -HL12 -HLK1 /3 width=6/
+| /4 width=1/
+| /3 width=1/
+]
+qed-.
+
+(* Basic_1: was by definition: subst1_refl *)
+lemma cpss_refl: ∀T,L. L ⊢ T ▶* T.
+#T elim T -T //
+#I elim I -I /2 width=1/
+qed.
+
+(* Basic_1: was only: subst1_ex *)
+lemma cpss_delift: ∀K,V,T1,L,d. ⇩[0, d] L ≡ (K. ⓓV) →
+                   ∃∃T2,T. L ⊢ T1 ▶* T2 & ⇧[d, 1] T ≡ T2.
+#K #V #T1 elim T1 -T1
+[ * #i #L #d #HLK /2 width=4/
+  elim (lt_or_eq_or_gt i d) #Hid /3 width=4/
+  destruct
+  elim (lift_total V 0 (i+1)) #W #HVW
+  elim (lift_split … HVW i i) // /3 width=6/
+| * [ #a ] #I #W1 #U1 #IHW1 #IHU1 #L #d #HLK
+  elim (IHW1 … HLK) -IHW1 #W2 #W #HW12 #HW2
+  [ elim (IHU1 (L. ⓑ{I} W1) (d+1)) -IHU1 /2 width=1/ -HLK /3 width=9/
+  | elim (IHU1 … HLK) -IHU1 -HLK /3 width=8/
+  ]
+]
+qed-.
+
+lemma cpss_append: l_appendable_sn … cpss.
+#K #T1 #T2 #H elim H -K -T1 -T2 // /2 width=1/
+#K #K0 #V1 #V2 #W2 #i #HK0 #_ #HVW2 #IHV12 #L
+lapply (ldrop_fwd_length_lt2 … HK0) #H
+@(cpss_delta … (L@@K0) V1 … HVW2) //
+@(ldrop_O1_append_sn_le … HK0) /2 width=2/ (**) (* /3/ does not work *)
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact cpss_inv_atom1_aux: ∀L,T1,T2. L ⊢ T1 ▶* T2 → ∀I. T1 = ⓪{I} →
+                         T2 = ⓪{I} ∨
+                         ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
+                                     K ⊢ V ▶* V2 &
+                                     ⇧[O, i + 1] V2 ≡ T2 &
+                                     I = LRef i.
+#L #T1 #T2 * -L -T1 -T2
+[ #I #L #J #H destruct /2 width=1/
+| #L #K #V #V2 #T2 #i #HLK #HV2 #HVT2 #I #H destruct /3 width=8/
+| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+| #I #L #V1 #V2 #T1 #T2 #_ #_ #J #H destruct
+]
+qed-.
+
+lemma cpss_inv_atom1: ∀I,L,T2. L ⊢ ⓪{I} ▶* T2 →
+                      T2 = ⓪{I} ∨
+                      ∃∃K,V,V2,i. ⇩[O, i] L ≡ K. ⓓV &
+                                  K ⊢ V ▶* V2 &
+                                  ⇧[O, i + 1] V2 ≡ T2 &
+                                  I = LRef i.
+/2 width=3 by cpss_inv_atom1_aux/ qed-.
+
+(* Basic_1: was only: subst1_gen_sort *)
+lemma cpss_inv_sort1: ∀L,T2,k. L ⊢ ⋆k ▶* T2 → T2 = ⋆k.
+#L #T2 #k #H
+elim (cpss_inv_atom1 … H) -H //
+* #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+(* Basic_1: was only: subst1_gen_lref *)
+lemma cpss_inv_lref1: ∀L,T2,i. L ⊢ #i ▶* T2 →
+                      T2 = #i ∨
+                      ∃∃K,V,V2. ⇩[O, i] L ≡ K. ⓓV &
+                                K ⊢ V ▶* V2 &
+                                ⇧[O, i + 1] V2 ≡ T2.
+#L #T2 #i #H
+elim (cpss_inv_atom1 … H) -H /2 width=1/
+* #K #V #V2 #j #HLK #HV2 #HVT2 #H destruct /3 width=6/
+qed-.
+
+lemma cpss_inv_gref1: ∀L,T2,p. L ⊢ §p ▶* T2 → T2 = §p.
+#L #T2 #p #H
+elim (cpss_inv_atom1 … H) -H //
+* #K #V #V2 #i #_ #_ #_ #H destruct
+qed-.
+
+fact cpss_inv_bind1_aux: ∀L,U1,U2. L ⊢ U1 ▶* U2 →
+                         ∀a,I,V1,T1. U1 = ⓑ{a,I} V1. T1 →
+                         ∃∃V2,T2. L ⊢ V1 ▶* V2 &
+                                  L. ⓑ{I} V1 ⊢ T1 ▶* T2 &
+                                  U2 = ⓑ{a,I} V2. T2.
+#L #U1 #U2 * -L -U1 -U2
+[ #I #L #b #J #W1 #U1 #H destruct
+| #L #K #V #V2 #W2 #i #_ #_ #_ #b #J #W1 #U1 #H destruct
+| #a #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #b #J #W1 #U1 #H destruct /2 width=5/
+| #I #L #V1 #V2 #T1 #T2 #_ #_ #b #J #W1 #U1 #H destruct
+]
+qed-.
+
+lemma cpss_inv_bind1: ∀a,I,L,V1,T1,U2. L ⊢ ⓑ{a,I} V1. T1 ▶* U2 →
+                      ∃∃V2,T2. L ⊢ V1 ▶* V2 &
+                               L. ⓑ{I} V1 ⊢ T1 ▶* T2 &
+                               U2 = ⓑ{a,I} V2. T2.
+/2 width=3 by cpss_inv_bind1_aux/ qed-.
+
+fact cpss_inv_flat1_aux: ∀L,U1,U2. L ⊢ U1 ▶* U2 →
+                         ∀I,V1,T1. U1 = ⓕ{I} V1. T1 →
+                         ∃∃V2,T2. L ⊢ V1 ▶* V2 & L ⊢ T1 ▶* T2 &
+                                  U2 =  ⓕ{I} V2. T2.
+#L #U1 #U2 * -L -U1 -U2
+[ #I #L #J #W1 #U1 #H destruct
+| #L #K #V #V2 #W2 #i #_ #_ #_ #J #W1 #U1 #H destruct
+| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #J #W1 #U1 #H destruct
+| #I #L #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W1 #U1 #H destruct /2 width=5/
+]
+qed-.
+
+lemma cpss_inv_flat1: ∀I,L,V1,T1,U2. L ⊢ ⓕ{I} V1. T1 ▶* U2 →
+                      ∃∃V2,T2. L ⊢ V1 ▶* V2 & L ⊢ T1 ▶* T2 &
+                               U2 =  ⓕ{I} V2. T2.
+/2 width=3 by cpss_inv_flat1_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma cpss_fwd_tw: ∀L,T1,T2. L ⊢ T1 ▶* T2 → ♯{T1} ≤ ♯{T2}.
+#L #T1 #T2 #H elim H -L -T1 -T2 normalize
+/3 width=1 by monotonic_le_plus_l, le_plus/ (**) (* auto is too slow without trace *)
+qed-.
+
+lemma cpss_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ▶* T →
+                       ∃∃L2,T2. |L1| = |L2| & T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1 normalize
+[ #L #T1 #T #HT1
+  @(ex2_2_intro … (⋆)) // (**) (* explicit constructor *)
+| #I #L1 #V1 #IH #L #T1 #X
+  >shift_append_assoc normalize #H
+  elim (cpss_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 ] // /2 width=3/ (**) (* explicit constructor *)
+]
+qed-.
+
+(* Basic_1: removed theorems 27:
+            subst0_gen_sort subst0_gen_lref subst0_gen_head subst0_gen_lift_lt
+            subst0_gen_lift_false subst0_gen_lift_ge subst0_refl subst0_trans
+            subst0_lift_lt subst0_lift_ge subst0_lift_ge_S subst0_lift_ge_s
+            subst0_subst0 subst0_subst0_back subst0_weight_le subst0_weight_lt
+            subst0_confluence_neq subst0_confluence_eq subst0_tlt_head
+            subst0_confluence_lift subst0_tlt
+            subst1_head subst1_gen_head subst1_lift_S subst1_confluence_lift
+            subst1_gen_lift_eq subst1_confluence_neq
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/cpss_lift.etc
new file mode 100644 (file)
index 0000000..9745b6c
--- /dev/null
@@ -0,0 +1,71 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cpss.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL SUBSTITUTION FOR TERMS ************************)
+
+(* Relocation properties ****************************************************)
+
+(* Basic_1: was only: subst1_lift_lt subst1_lift_ge *)
+lemma cpss_lift: l_liftable cpss.
+#K #T1 #T2 #H elim H -K -T1 -T2
+[ #I #K #L #d #e #_ #U1 #H1 #U2 #H2
+  >(lift_mono … H1 … H2) -H1 -H2 //
+| #K #KV #V #V2 #W2 #i #HKV #HV2 #HVW2 #IHV2 #L #d #e #HLK #U1 #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HVW2 … HWU2) -W2 // <minus_plus #W2 #HVW2 #HWU2
+    elim (ldrop_trans_le … HLK … HKV) -K /2 width=2/ #X #HLK #H
+    elim (ldrop_inv_skip2 … H) -H /2 width=1/ -Hid #K #Y #HKV #HVY #H destruct /3 width=8/
+  | lapply (lift_trans_be … HVW2 … HWU2 ? ?) -W2 // /2 width=1/ >plus_plus_comm_23 #HVU2
+    lapply (ldrop_trans_ge_comm … HLK … HKV ?) -K // -Hid /3 width=6/
+  ]
+| #a #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_bind1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /4 width=5/
+| #I #K #V1 #V2 #T1 #T2 #_ #_ #IHV12 #IHT12 #L #d #e #HLK #U1 #H1 #U2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #VV1 #TT1 #HVV1 #HTT1 #H1 destruct
+  elim (lift_inv_flat1 … H2) -H2 #VV2 #TT2 #HVV2 #HTT2 #H2 destruct /3 width=6/
+]
+qed.
+
+(* Basic_1: was only: subst1_gen_lift_lt subst1_gen_lift_ge *)
+lemma cpss_inv_lift1: l_deliftable_sn cpss.
+#L #U1 #U2 #H elim H -L -U1 -U2
+[ * #L #i #K #d #e #_ #T1 #H
+  [ lapply (lift_inv_sort2 … H) -H #H destruct /2 width=3/
+  | elim (lift_inv_lref2 … H) -H * #Hid #H destruct /3 width=3/
+  | lapply (lift_inv_gref2 … H) -H #H destruct /2 width=3/
+  ]
+| #L #LV #V #V2 #W2 #i #HLV #HV2 #HVW2 #IHV2 #K #d #e #HLK #T1 #H
+  elim (lift_inv_lref2 … H) -H * #Hid #H destruct
+  [ elim (ldrop_conf_lt … HLK … HLV) -L // #L #U #HKL #HLV #HUV
+    elim (IHV2 … HLV … HUV) -V #U2 #HUV2 #HU2
+    elim (lift_trans_le … HUV2 … HVW2) -V2 // >minus_plus <plus_minus_m_m // -Hid /3 width=8/
+  | elim (le_inv_plus_l … Hid) #Hdie #Hei
+    lapply (ldrop_conf_ge … HLK … HLV ?) -L // #HKLV
+    elim (lift_split … HVW2 d (i - e + 1)) -HVW2 [4: // |3: /2 width=1/ |2: /3 width=1/ ] -Hid -Hdie
+    #V1 #HV1 >plus_minus // <minus_minus // /2 width=1/ <minus_n_n <plus_n_O /3 width=8/
+  ]
+| #a #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
+  elim (lift_inv_bind2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -IHV12 #W2 #HW12 #HWV2
+  elim (IHU12 … HTU1) -IHU12 -HTU1 /3 width=5/
+| #I #L #V1 #V2 #U1 #U2 #_ #_ #IHV12 #IHU12 #K #d #e #HLK #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #HWV1 #HTU1 #H destruct
+  elim (IHV12 … HLK … HWV1) -V1
+  elim (IHU12 … HLK … HTU1) -U1 -HLK /3 width=5/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/dxprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/dxprs_lpss.etc
new file mode 100644 (file)
index 0000000..a14c551
--- /dev/null
@@ -0,0 +1,46 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/sstas_lpss.ma".
+include "basic_2/computation/cprs_lpss.ma".
+include "basic_2/computation/dxprs.ma".
+
+(* DECOMPOSED EXTENDED PARALLEL COMPUTATION ON TERMS ************************)
+
+(* Properties about sn parallel substitution for local environments *********)
+
+lemma dxprs_lpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*➡*[g] U1 → ∀L2. L1 ⊢ ▶* L2 →
+                       ∃∃U2. ⦃h, L2⦄ ⊢ T •*➡*[g] U2 & L1 ⊢ U1 ▶* U2.
+#h #g #L1 #T #U1 * #U #HTU #HU1 #L2 #HL12
+elim (sstas_lpss_conf … HTU … HL12) -HTU #U0 #HTU0 #HU0
+elim (cprs_cpss_conf … HU1 … HU0) -U #U #HU1 #HU0
+elim (cprs_lpss_conf_sn … HU0 … HL12) -HU0 -HL12 #U2 #HU2 #HU02
+lapply (cpss_trans … HU1 … HU2) -U /3 width=3/
+qed-.
+
+lemma dxprs_cpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*➡*[g] U1 → ∀T2. L ⊢ T1 ▶* T2 →
+                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*➡*[g] U2 & L ⊢ U1 ▶* U2.
+#h #g #L #T1 #U1 * #W1 #HTW1 #HWU1 #T2 #HT12
+elim (sstas_cpss_conf … HTW1 … HT12) -T1 #W2 #HTW2 #HW12
+elim (cprs_cpss_conf … HWU1 … HW12) -W1 /3 width=3/
+qed-.
+
+lemma dxprs_cpss_lpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*➡*[g] U1 →
+                            ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
+                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*➡*[g] U2 & L1 ⊢ U1 ▶* U2.
+#h #g #L1 #T1 #U1 #HTU1 #T2 #HT12 #L2 #HL12
+elim (dxprs_cpss_conf … HTU1 … HT12) -T1 #U2 #HTU2 #HU12
+elim (dxprs_lpss_conf … HTU2 … HL12) -HTU2 -HL12 #U #HT2U #HU2
+lapply (cpss_trans … HU12 … HU2) -U2 /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs.etc
new file mode 100644 (file)
index 0000000..402af46
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+notation "hvbox( T1 ⊢ ➤ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PRestStarSn $T1 $T2 }.
+
+include "basic_2/substitution/lpss.ma".
+include "basic_2/unfold/cpqs.ma".
+
+(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
+
+definition lpqs: relation lenv ≝ lpx_sn cpqs. 
+
+interpretation "restricted parallel computation (local environment, sn variant)"
+   'PRestStarSn L1 L2 = (lpqs L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lpqs_inv_atom1: ∀L2. ⋆ ⊢ ➤* L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+lemma lpqs_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ➤* L2 →
+                      ∃∃K2,V2. K1 ⊢ ➤* K2 & K1 ⊢ V1 ➤* V2 & L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+lemma lpqs_inv_atom2: ∀L1. L1 ⊢ ➤* ⋆ → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+lemma lpqs_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ➤* K2. ⓑ{I} V2 →
+                      ∃∃K1,V1. K1 ⊢ ➤* K2 & K1 ⊢ V1 ➤* V2 & L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lpqs_refl: ∀L. L ⊢ ➤* L.
+/2 width=1 by lpx_sn_refl/ qed.
+
+lemma lpqs_pair: ∀I,K1,K2,V1,V2. K1 ⊢ ➤* K2 → K1 ⊢ V1 ➤* V2 →
+                 K1.ⓑ{I}V1 ⊢ ➤* K2.ⓑ{I}V2.
+/2 width=1/ qed.
+
+lemma lpqs_append: ∀K1,K2. K1 ⊢ ➤* K2 → ∀L1,L2. L1 ⊢ ➤* L2 →
+                   L1 @@ K1 ⊢ ➤* L2 @@ K2.
+/3 width=1 by lpx_sn_append, cpqs_append/ qed.
+
+lemma lpss_lpqs: ∀L1,L2. L1 ⊢ ▶* L2 → L1 ⊢ ➤* L2.
+#L1 #L2 #H elim H -L1 -L2 // /3 width=1/
+qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpqs_fwd_length: ∀L1,L2. L1 ⊢ ➤* L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpqs_fwd_append1: ∀K1,L1,L. K1 @@ L1 ⊢ ➤* L →
+                        ∃∃K2,L2. K1 ⊢ ➤* K2 & L = K2 @@ L2.
+/2 width=2 by lpx_sn_fwd_append1/ qed-.
+
+lemma lpqs_fwd_append2: ∀L,K2,L2. L ⊢ ➤* K2 @@ L2 →
+                        ∃∃K1,L1. K1 ⊢ ➤* K2 & L = K1 @@ L1.
+/2 width=2 by lpx_sn_fwd_append2/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_cpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_cpqs.etc
new file mode 100644 (file)
index 0000000..7b8f17b
--- /dev/null
@@ -0,0 +1,71 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lpx_sn_lpx_sn.ma".
+include "basic_2/substitution/fsupp.ma".
+include "basic_2/unfold/lpqs_ldrop.ma".
+
+(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
+
+(* Main properties on context-sensitive rest parallel computation for terms *)
+
+theorem cpqs_trans_lpqs: lpx_sn_transitive cpqs cpqs.
+#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L0 #T0 #IH #L1 * [|*]
+[ #I #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
+  elim (cpqs_inv_atom1 … H1) -H1
+  [ #H destruct
+    elim (cpqs_inv_atom1 … HT2) -HT2
+    [ #H destruct //
+    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
+      elim (lpqs_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
+      elim (lpqs_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
+      lapply (fsupp_lref … HLK1) /3 width=9/
+    ]
+  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
+    elim (lpqs_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+    elim (lpqs_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+    elim (cpqs_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
+    lapply (fsupp_lref … HLK1) /3 width=9/
+  ]
+| #a #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpqs_inv_bind1 … H1) -H1 *
+  [ #V #T #HV1 #HT1 #H destruct
+    elim (cpqs_inv_bind1 … H2) -H2 *
+    [ #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
+    | #T2 #HT2 #HXT2 #H1 #H2 destruct /4 width=5/
+    ]
+  | #Y1 #HTY1 #HXY1 #H11 #H12 destruct
+    elim (lift_total X2 0 1) #Y2 #HXY2
+    lapply (cpqs_lift … H2 (L2.ⓓV1) … HXY1 … HXY2) /2 width=1/ -X1 /4 width=5/
+  ]
+| #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpqs_inv_flat1 … H1) -H1 *
+  [ #V #T #HV1 #HT1 #H destruct
+    elim (cpqs_inv_flat1 … H2) -H2 *
+    [ #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
+    | #HX2 #H destruct /3 width=5/
+    ]
+  | #HX1 #H destruct /3 width=5/
+]
+qed-.
+
+theorem cpqs_trans: ∀L. Transitive … (cpqs L).
+/2 width=5 by cpqs_trans_lpqs/ qed-.
+
+(* Properties on context-sensitive rest. parallel computation for terms *****)
+
+lemma lpqs_cpqs_trans: ∀L1,L2. L1 ⊢ ➤* L2 →
+                       ∀T1,T2. L2 ⊢ T1 ➤* T2 → L1 ⊢ T1 ➤* T2.
+/2 width=5 by cpqs_trans_lpqs/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_ldrop.etc
new file mode 100644 (file)
index 0000000..e121c0c
--- /dev/null
@@ -0,0 +1,47 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fsup.ma".
+include "basic_2/relocation/ldrop_lpx_sn.ma".
+include "basic_2/unfold/cpqs_lift.ma".
+include "basic_2/unfold/lpqs.ma".
+
+(* SN RESTRICTED PARALLEL COMPUTATION FOR LOCAL ENVIRONMENTS ****************)
+
+(* Properies on local environment slicing ***********************************)
+
+lemma lpqs_ldrop_conf: dropable_sn lpqs.
+/3 width=5 by lpx_sn_deliftable_dropable, cpqs_inv_lift1/ qed-.
+
+lemma ldrop_lpqs_trans: dedropable_sn lpqs.
+/3 width=9 by lpx_sn_liftable_dedropable, cpqs_lift/ qed-.
+
+lemma lpqs_ldrop_trans_O1: dropable_dx lpqs.
+/2 width=3 by lpx_sn_dropable/ qed-.
+
+(* Properties on context-sensitive rest. parallel computation for terms *****)
+
+lemma fsup_cpqs_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ➤* U2 →
+                       ∃∃L,U1. L1 ⊢ ➤* L & L ⊢ T1 ➤* U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [2: * ] [1,2,3,4,5: /3 width=5/ ]
+[ #L #K #U #T #d #e #HLK #HUT #He #U2 #HU2
+  elim (lift_total U2 d e) #T2 #HUT2
+  lapply (cpqs_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9/
+| #L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+  elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
+  elim (lift_total T d e) #U #HTU
+  elim (ldrop_lpqs_trans … HLK1 … HK1) -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (cpqs_lift … HT1 … HL2K … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_lpqs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpqs_lpqs.etc
new file mode 100644 (file)
index 0000000..13f221e
--- /dev/null
@@ -0,0 +1,267 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/lpqs_cpqs.ma".
+
+(* SN RESTRICTED PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS *****************)
+
+(* Main properties on context-sensitive rest parallel computation for terms *)
+
+fact cpqs_conf_lpqs_atom_atom:
+   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ➤* T & L2 ⊢ ⓪{I} ➤* T.
+/2 width=3/ qed-.
+
+fact cpqs_conf_lpqs_atom_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V2. K0 ⊢ V0 ➤* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ #i ➤* T & L2 ⊢ T2 ➤* T.
+#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+elim (lpqs_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpqs_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
+elim (lpqs_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpqs_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpqs_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
+qed-.
+
+fact cpqs_conf_lpqs_delta_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V1. K0 ⊢ V0 ➤* V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
+   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
+   ∀V2. KX ⊢ VX ➤* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ T1 ➤* T & L2 ⊢ T2 ➤* T.
+#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
+#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+lapply (ldrop_mono … H … HLK0) -H #H destruct
+elim (lpqs_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpqs_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
+elim (lpqs_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpqs_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpqs_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
+lapply (cpqs_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
+qed-.
+
+fact cpqs_conf_lpqs_bind_bind:
+   ∀a,I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ➤* T1 →
+   ∀V2. L0 ⊢ V0 ➤* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ➤* T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ➤* T & L2 ⊢ ⓑ{a,I}V2.T2 ➤* T.
+#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
+qed-.
+
+fact cpqs_conf_lpqs_bind_zeta:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0.ⓓV0 ⊢ T0 ➤* T1 →
+   ∀T2. L0.ⓓV0 ⊢ T0 ➤* T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ +ⓓV1.T1 ➤* T & L2 ⊢ X2 ➤* T.
+#L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 (L1.ⓓV1) … (L2.ⓓV1)) -IH -HT01 -HT02 // /2 width=1/ -L0 -V0 -T0 #T #HT1 #HT2
+elim (cpqs_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=1/ /3 width=3/
+qed-.
+
+fact cpqs_conf_lpqs_zeta_zeta:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀T1. L0.ⓓV0 ⊢ T0 ➤* T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
+   ∀T2. L0.ⓓV0 ⊢ T0 ➤* T2 → ∀X2. ⇧[O, 1] X2 ≡ T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ X1 ➤* T & L2 ⊢ X2 ➤* T.
+#L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
+#T2 #HT02 #X2 #HXT2 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 (L1.ⓓV0) … (L2.ⓓV0)) -IH -HT01 -HT02 // /2 width=1/ -L0 -T0 #T #HT1 #HT2
+elim (cpqs_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=1/ #T1 #HT1 #HXT1
+elim (cpqs_inv_lift1 … HT2 L2 … HXT2) -T2 /2 width=1/ #T2 #HT2 #HXT2 
+lapply (lift_inj … HT2 … HT1) -T #H destruct /2 width=3/
+qed-.
+
+fact cpqs_conf_lpqs_flat_flat:
+   ∀I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➤* V1 → ∀T1. L0 ⊢ T0 ➤* T1 →
+   ∀V2. L0 ⊢ V0 ➤* V2 → ∀T2. L0 ⊢ T0 ➤* T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ➤* T & L2 ⊢ ⓕ{I}V2.T2 ➤* T.
+#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
+qed-.
+
+fact cpqs_conf_lpqs_flat_tau:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀V1,T1. L0 ⊢ T0 ➤* T1 → ∀T2. L0 ⊢ T0 ➤* T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ ⓝV1.T1 ➤* T & L2 ⊢ T2 ➤* T.
+#L0 #V0 #T0 #IH #V1 #T1 #HT01
+#T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /3 width=3/
+qed-.
+
+fact cpqs_conf_lpqs_tau_tau:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ➤* T1 → ∀T2. L ⊢ T ➤* T2 →
+      ∀L1. L ⊢ ➤* L1 → ∀L2. L ⊢ ➤* L2 →
+      ∃∃T0. L1 ⊢ T1 ➤* T0 & L2 ⊢ T2 ➤* T0
+   ) →
+   ∀T1. L0 ⊢ T0 ➤* T1 → ∀T2. L0 ⊢ T0 ➤* T2 →
+   ∀L1. L0 ⊢ ➤* L1 → ∀L2. L0 ⊢ ➤* L2 →
+   ∃∃T. L1 ⊢ T1 ➤* T & L2 ⊢ T2 ➤* T.
+#L0 #V0 #T0 #IH #T1 #HT01
+#T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /2 width=3/
+qed-.
+
+theorem cpqs_conf_lpqs: lpx_sn_confluent cpqs cpqs.
+#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
+[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpqs_inv_atom1 … H1) -H1
+  elim (cpqs_inv_atom1 … H2) -H2
+  [ #H2 #H1 destruct
+    /2 width=1 by cpqs_conf_lpqs_atom_atom/
+  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
+    /3 width=10 by cpqs_conf_lpqs_atom_delta/
+  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
+    /4 width=10 by ex2_commute, cpqs_conf_lpqs_atom_delta/
+  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
+    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
+    /3 width=17 by cpqs_conf_lpqs_delta_delta/
+  ]
+| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpqs_inv_bind1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #T1 #HT01 #HXT1 #H11 #H12
+  ]
+  elim (cpqs_inv_bind1 … H2) -H2 *
+  [1,3: #V2 #T2 #HV02 #HT02 #H2
+  |2,4: #T2 #HT02 #HXT2 #H21 #H22
+  ] destruct
+  [ /3 width=10 by cpqs_conf_lpqs_bind_bind/
+  | /4 width=11 by ex2_commute, cpqs_conf_lpqs_bind_zeta/
+  | /3 width=11 by cpqs_conf_lpqs_bind_zeta/
+  | /3 width=12 by cpqs_conf_lpqs_zeta_zeta/
+  ]
+| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpqs_inv_flat1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #HX1 #H1
+  ]
+  elim (cpqs_inv_flat1 … H2) -H2 *
+  [1,3: #V2 #T2 #HV02 #HT02 #H2
+  |2,4: #HX2 #H2
+  ] destruct
+  [ /3 width=10 by cpqs_conf_lpqs_flat_flat/
+  | /4 width=8 by ex2_commute, cpqs_conf_lpqs_flat_tau/
+  | /3 width=8 by cpqs_conf_lpqs_flat_tau/
+  | /3 width=7 by cpqs_conf_lpqs_tau_tau/
+  ]
+]
+qed-.
+
+theorem cpqs_conf: ∀L. confluent … (cpqs L).
+/2 width=6 by cpqs_conf_lpqs/ qed-.
+
+(* Properties on context-sensitive rest. parallel computation for terms *****)
+
+lemma lpqs_cpqs_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➤* T1 → ∀L1. L0 ⊢ ➤* L1 →
+                         ∃∃T. L1 ⊢ T0 ➤* T & L1 ⊢ T1 ➤* T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpqs_conf_lpqs … HT01 T0 … HL01 … HL01) // -L0 /2 width=3/
+qed-.
+
+lemma lpqs_cpqs_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➤* T1 → ∀L1. L0 ⊢ ➤* L1 →
+                         ∃∃T. L1 ⊢ T0 ➤* T & L0 ⊢ T1 ➤* T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpqs_conf_lpqs … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
+qed-.
+
+(* Main properties **********************************************************)
+
+theorem lpqs_conf: confluent … lpqs.
+/3 width=6 by lpx_sn_conf, cpqs_conf_lpqs/
+qed-.
+
+theorem lpqs_trans: Transitive … lpqs.
+/3 width=5 by lpx_sn_trans, cpqs_trans_lpqs/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma cpqs_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ➤* T →
+                       ∃∃L2,T2. L @@ L1 ⊢ ➤* L @@ L2 & L @@ L1 ⊢ T1 ➤* T2 &
+                                T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1
+[ #L #T1 #T #HT1
+  @ex3_2_intro [3: // |4,5: // |1,2: skip ] (**) (* /2 width=4/ does not work *)
+| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
+  elim (cpqs_inv_bind1 … H) -H *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
+    lapply (lpqs_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1/ #HL12
+    @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
+  | #T #_ #_ #H destruct
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpr_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpr_lpss.etc
new file mode 100644 (file)
index 0000000..9ce690f
--- /dev/null
@@ -0,0 +1,279 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lpx_sn_lpx_sn.ma".
+include "basic_2/substitution/fsupp.ma".
+include "basic_2/substitution/lpss_ldrop.ma".
+include "basic_2/reduction/lpr_ldrop.ma".
+
+(* SN PARALLEL REDUCTION FOR LOCAL ENVIRONMENTS *****************************)
+
+(* Properties on context-sensitive parallel substitution for terms **********)
+
+fact cpr_cpss_conf_lpr_lpss_atom_atom:
+   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ▶* T & L2 ⊢ ⓪{I} ➡ T.
+/2 width=3/ qed-.
+
+fact cpr_cpss_conf_lpr_lpss_atom_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V2. K0 ⊢ V0 ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ #i ▶* T & L2 ⊢ T2 ➡ T.
+#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpr_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
+elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpr_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_delta_atom:
+   ∀L0,i. (
+      ∀L,T.⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V1. K0 ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ #i ➡ T.
+#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1 #L1 #HL01 #L2 #HL02
+elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpss_inv_pair1 … H2) -H2 #K2 #V2 #HK02 #HV02 #H destruct
+elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpr_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1 /3 width=9/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_delta_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V1. K0 ⊢ V0 ➡ V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
+   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
+   ∀V2. KX ⊢ VX ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ T2 ➡ T.
+#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
+#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+lapply (ldrop_mono … H … HLK0) -H #H destruct
+elim (lpr_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpr_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
+elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
+lapply (cpr_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_bind_bind:
+   ∀a,I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ➡ T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ▶* T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ▶* T & L2 ⊢ ⓑ{a,I}V2.T2 ➡ T.
+#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_bind_zeta:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,+ⓓV0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀T1. L0.ⓓV0 ⊢ T0 ➡ T1 → ∀X1. ⇧[O, 1] X1 ≡ T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓓV0 ⊢ T0 ▶* T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ X1 ▶* T & L2 ⊢ +ⓓV2.T2 ➡ T.
+#L0 #V0 #T0 #IH #T1 #HT01 #X1 #HXT1
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 (L1.ⓓV2) … (L2.ⓓV2)) -IH -HT01 -HT02 // /2 width=1/ /3 width=1/ -L0 -V0 -T0 #T #HT1 #HT2
+elim (cpss_inv_lift1 … HT1 L1 … HXT1) -T1 /2 width=1/ /3 width=9/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_flat_flat:
+   ∀I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0 ⊢ T0 ➡ T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ T0 ▶* T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ▶* T & L2 ⊢ ⓕ{I}V2.T2 ➡ T.
+#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_flat_tau:
+   ∀L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓝV0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀T1. L0 ⊢ T0 ➡ T1 → ∀V2,T2. L0 ⊢ T0 ▶* T2 → 
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ ⓝV2.T2 ➡ T.
+#L0 #V0 #T0 #IH #T1 #HT01
+#V2 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HT01 … HT02 … HL01 … HL02) // -L0 -V0 -T0 /3 width=3/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_flat_beta:
+   ∀a,L0,V0,W0,T0. (
+      ∀L,T. ⦃L0,ⓐV0.ⓛ{a}W0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➡ V1 → ∀T1. L0.ⓛW0 ⊢ T0 ➡ T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ ⓛ{a}W0.T0 ▶* T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓓ{a}V1.T1 ▶* T & L2 ⊢ ⓐV2.T2 ➡ T.
+#a #L0 #V0 #W0 #T0 #IH #V1 #HV01 #T1 #HT01 
+#V2 #HV02 #X #H #L1 #HL01 #L2 #HL02
+elim (cpss_inv_bind1 … H) -H #W2 #T2 #HW02 #HT02 #H destruct
+elim (IH … HV01 … HV02 … HL01 … HL02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
+elim (IH … HT01 … HT02 (L1.ⓛW2) … (L2.ⓛW2)) /2 width=1/ /3 width=1/ -L0 -V0 -W0 -T0 #T #HT1 #HT2
+lapply (cpss_lsubr_trans … HT1 (L1.ⓓV1) ?) -HT1 /2 width=1/ /3 width=5/
+qed-.
+
+fact cpr_cpss_conf_lpr_lpss_flat_theta:
+   ∀a,L0,V0,W0,T0. (
+      ∀L,T. ⦃L0,ⓐV0.ⓓ{a}W0.T0⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ➡ T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ➡ L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ➡ T0
+   ) →
+   ∀V1. L0 ⊢ V0 ➡ V1 → ∀U1. ⇧[O, 1] V1 ≡ U1 →
+   ∀W1. L0 ⊢ W0 ➡ W1 → ∀T1. L0.ⓓW0 ⊢ T0 ➡ T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ ⓓ{a}W0.T0 ▶* T2 →
+   ∀L1. L0 ⊢ ➡ L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓓ{a}W1.ⓐU1.T1 ▶* T & L2 ⊢ ⓐV2.T2 ➡ T.
+#a #L0 #V0 #W0 #T0 #IH #V1 #HV01 #U1 #HVU1 #W1 #HW01 #T1 #HT01
+#V2 #HV02 #X #H #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) -HV01 -HV02 /2 width=1/ #V #HV1 #HV2
+elim (lift_total V 0 1) #U #HVU
+lapply (cpss_lift … HV1 (L1.ⓓW1) … HVU1 … HVU) -HVU1 /2 width=1/ #HU1
+elim (cpss_inv_bind1 … H) -H #W2 #T2 #HW02 #HT02 #H destruct
+elim (IH … HW01 … HW02 … HL01 … HL02) /2 width=1/
+elim (IH … HT01 … HT02 (L1.ⓓW1) … (L2.ⓓW2)) /2 width=1/ -L0 -V0 -W0 -T0
+/4 width=9 by ex2_intro, cpr_theta, cpss_bind, cpss_flat/ (**) (* auto too slow without trace *)
+qed-.
+
+lemma cpr_cpss_conf_lpr_lpss: lpx_sn_confluent cpr cpss.
+#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
+[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpr_inv_atom1 … H1) -H1
+  elim (cpss_inv_atom1 … H2) -H2
+  [ #H2 #H1 destruct
+    /2 width=1 by cpr_cpss_conf_lpr_lpss_atom_atom/
+  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
+    /3 width=10 by cpr_cpss_conf_lpr_lpss_atom_delta/
+  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
+    /3 width=10 by cpr_cpss_conf_lpr_lpss_delta_atom/
+  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
+    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
+    /3 width=17 by cpr_cpss_conf_lpr_lpss_delta_delta/
+  ]
+| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H2
+  elim (cpr_inv_bind1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #T1 #HT01 #HXT1 #H11 #H12
+  ] destruct
+  [ /3 width=10 by cpr_cpss_conf_lpr_lpss_bind_bind/
+  | /3 width=11 by cpr_cpss_conf_lpr_lpss_bind_zeta/
+  ]
+| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H2
+  elim (cpr_inv_flat1 … H1) -H1 *
+  [ #V1 #T1 #HV01 #HT01 #H1
+  | #HX1 #H1
+  | #a1 #V1 #Y1 #Z1 #T1 #HV01 #HZT1 #H11 #H12 #H13
+  | #a1 #V1 #U1 #Y1 #W1 #Z1 #T1 #HV01 #HVU1 #HYW1 #HZT1 #H11 #H12 #H13
+  ] destruct
+  [ /3 width=10 by cpr_cpss_conf_lpr_lpss_flat_flat/
+  | /3 width=8 by cpr_cpss_conf_lpr_lpss_flat_tau/
+  | /3 width=11 by cpr_cpss_conf_lpr_lpss_flat_beta/
+  | /3 width=14 by cpr_cpss_conf_lpr_lpss_flat_theta/
+  ]
+]
+qed-.
+
+(* Basic_1: includes: pr0_subst1 *)
+(* Basic_1: was: pr2_subst1 *)
+lemma cpr_cpss_conf: ∀L. confluent2 … (cpr L) (cpss L).
+/2 width=6 by cpr_cpss_conf_lpr_lpss/ qed-.
+
+lemma cpr_lpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ➡ T1 → ∀L1. L0 ⊢ ▶* L1 →
+                        ∃∃T. L1 ⊢ T1 ▶* T & L1 ⊢ T0 ➡ T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpr_cpss_conf_lpr_lpss … HT01 T0 … L1 … HL01) // /2 width=1/ -L0 /2 width=3/
+qed-.
+
+lemma cpr_lpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ➡ T1 → ∀L1. L0 ⊢ ▶* L1 →
+                        ∃∃T. L0 ⊢ T1 ▶* T & L1 ⊢ T0 ➡ T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpr_cpss_conf_lpr_lpss … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
+qed-.
+
+(* Basic_1: includes: pr0_subst1_fwd *)
+lemma lpr_cpss_conf: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ➡ L1 →
+                     ∃∃T. L1 ⊢ T0 ▶* T & L0 ⊢ T1 ➡ T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpr_cpss_conf_lpr_lpss ?? T0 … HT01 … HL01 L0) // -HT01 -HL01 /2 width=3/
+qed-.
+
+(* Properties on sn parallel substitution on local environments *************)
+
+lemma lpr_lpss_conf: confluent2 … lpr lpss.
+/3 width=6 by lpx_sn_conf, cpr_cpss_conf_lpr_lpss/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lprs_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lprs_lpss.etc
new file mode 100644 (file)
index 0000000..ed9e7d0
--- /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/lpr_lpss.ma".
+include "basic_2/computation/lprs.ma".
+
+(* SN PARALLEL COMPUTATION ON LOCAL ENVIRONMENTS ****************************)
+
+(* Properties on sn parallel substitution on local environments *************)
+
+lemma lprs_lpss_conf: confluent2 … lprs lpss.
+/3 width=3 by TC_strip1, lpr_lpss_conf/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss.etc
new file mode 100644 (file)
index 0000000..6d57e17
--- /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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+notation "hvbox( T1 ⊢ ▶ * break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStarSn $T1 $T2 }.
+
+include "basic_2/grammar/lpx_sn.ma".
+include "basic_2/substitution/cpss.ma".
+
+(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
+
+(* Basic_1: includes: csubst1_bind *)
+definition lpss: relation lenv ≝ lpx_sn cpss. 
+
+interpretation "parallel substitution (local environment, sn variant)"
+   'PSubstStarSn L1 L2 = (lpss L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lpss_inv_atom1: ∀L2. ⋆ ⊢ ▶* L2 → L2 = ⋆.
+/2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
+
+lemma lpss_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* L2 →
+                      ∃∃K2,V2. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L2 = K2. ⓑ{I} V2.
+/2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
+
+lemma lpss_inv_atom2: ∀L1. L1 ⊢ ▶* ⋆ → L1 = ⋆.
+/2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
+
+lemma lpss_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ▶* K2. ⓑ{I} V2 →
+                       ∃∃K1,V1. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L1 = K1. ⓑ{I} V1.
+/2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was by definition: csubst1_refl *)
+lemma lpss_refl: ∀L. L ⊢ ▶* L.
+/2 width=1 by lpx_sn_refl/ qed.
+
+lemma lpss_pair: ∀I,K1,K2,V1,V2. K1 ⊢ ▶* K2 → K1 ⊢ V1 ▶* V2 →
+                 K1.ⓑ{I}V1 ⊢ ▶* K2.ⓑ{I}V2.
+/2 width=1/ qed.
+
+lemma lpss_append: ∀K1,K2. K1 ⊢ ▶* K2 → ∀L1,L2. L1 ⊢ ▶* L2 →
+                    L1 @@ K1 ⊢ ▶* L2 @@ K2.
+/3 width=1 by lpx_sn_append, cpss_append/ qed.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lpss_fwd_length: ∀L1,L2. L1 ⊢ ▶* L2 → |L1| = |L2|.
+/2 width=2 by lpx_sn_fwd_length/ qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lpss_fwd_append1: ∀K1,L1,L. K1 @@ L1 ⊢ ▶* L →
+                        ∃∃K2,L2. K1 ⊢ ▶* K2 & L = K2 @@ L2.
+/2 width=2 by lpx_sn_fwd_append1/ qed-.
+
+lemma lpss_fwd_append2: ∀L,K2,L2. L ⊢ ▶* K2 @@ L2 →
+                        ∃∃K1,L1. K1 ⊢ ▶* K2 & L = K1 @@ L1.
+/2 width=2 by lpx_sn_fwd_append2/ qed-.
+
+(* Basic_1: removed theorems 28:
+            csubst0_clear_O csubst0_drop_lt csubst0_drop_gt csubst0_drop_eq
+            csubst0_clear_O_back csubst0_clear_S csubst0_clear_trans
+            csubst0_drop_gt_back csubst0_drop_eq_back csubst0_drop_lt_back
+            csubst0_gen_sort csubst0_gen_head csubst0_getl_ge csubst0_getl_lt
+            csubst0_gen_S_bind_2 csubst0_getl_ge_back csubst0_getl_lt_back
+            csubst0_snd_bind csubst0_fst_bind csubst0_both_bind
+            csubst1_head csubst1_flat csubst1_gen_head
+            csubst1_getl_ge csubst1_getl_lt csubst1_getl_ge_back getl_csubst1
+            fsubst0_gen_base
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_cpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_cpss.etc
new file mode 100644 (file)
index 0000000..71ab873
--- /dev/null
@@ -0,0 +1,60 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/lpx_sn_lpx_sn.ma".
+include "basic_2/substitution/fsupp.ma".
+include "basic_2/substitution/lpss_ldrop.ma".
+
+(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
+
+(* Main properties on context-sensitive parallel substitution for terms *****)
+
+theorem cpss_trans_lpss: lpx_sn_transitive cpss cpss.
+#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L0 #T0 #IH #L1 * [|*]
+[ #I #HL #HT #T #H1 #L2 #HL12 #T2 #HT2 destruct
+  elim (cpss_inv_atom1 … H1) -H1
+  [ #H destruct
+    elim (cpss_inv_atom1 … HT2) -HT2
+    [ #H destruct //
+    | * #K2 #V #V2 #i #HLK2 #HV2 #HVT2 #H destruct
+      elim (lpss_ldrop_trans_O1 … HL12 … HLK2) -L2 #X #HLK1 #H
+      elim (lpss_inv_pair2 … H) -H #K1 #V1 #HK12 #HV1 #H destruct
+      lapply (fsupp_lref … HLK1) /3 width=9/
+    ]
+  | * #K1 #V1 #V #i #HLK1 #HV1 #HVT #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #W2 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+    elim (cpss_inv_lift1 … HT2 … HLK2 … HVT) -L2 -T
+    lapply (fsupp_lref … HLK1) /3 width=9/
+  ]
+| #a #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpss_inv_bind1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
+  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct /4 width=5/
+| #I #V1 #T1 #HL #HT #X1 #H1 #L2 #HL12 #X2 #H2
+  elim (cpss_inv_flat1 … H1) -H1 #V #T #HV1 #HT1 #H destruct
+  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV2 #HT2 #H destruct /3 width=5/
+]
+qed-.
+
+(* Basic_1: was only: subst1_trans *)
+theorem cpss_trans: ∀L. Transitive … (cpss L).
+/2 width=5 by cpss_trans_lpss/ qed-.
+
+(* Properties on context-sensitive parallel substitution for terms **********)
+
+(* Basic_1: was only: subst1_subst1 *)
+lemma lpss_cpss_trans: ∀L1,L2. L1 ⊢ ▶* L2 →
+                       ∀T1,T2. L2 ⊢ T1 ▶* T2 → L1 ⊢ T1 ▶* T2.
+/2 width=5 by cpss_trans_lpss/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_ldrop.etc
new file mode 100644 (file)
index 0000000..7a549f1
--- /dev/null
@@ -0,0 +1,47 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/fsup.ma".
+include "basic_2/relocation/ldrop_lpx_sn.ma".
+include "basic_2/substitution/cpss_lift.ma".
+include "basic_2/substitution/lpss.ma".
+
+(* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
+
+(* Properies on local environment slicing ***********************************)
+
+lemma lpss_ldrop_conf: dropable_sn lpss.
+/3 width=5 by lpx_sn_deliftable_dropable, cpss_inv_lift1/ qed-.
+
+lemma ldrop_lpss_trans: dedropable_sn lpss.
+/3 width=9 by lpx_sn_liftable_dedropable, cpss_lift/ qed-.
+
+lemma lpss_ldrop_trans_O1: dropable_dx lpss.
+/2 width=3 by lpx_sn_dropable/ qed-.
+
+(* Properties on context-sensitive parallel substitution for terms **********)
+
+lemma fsup_cpss_trans: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ∀U2. L2 ⊢ T2 ▶* U2 →
+                       ∃∃L,U1. L1 ⊢ ▶* L & L ⊢ T1 ▶* U1 & ⦃L, U1⦄ ⊃ ⦃L2, U2⦄.
+#L1 #L2 #T1 #T2 #H elim H -L1 -L2 -T1 -T2 [2: * ] [1,2,3,4,5: /3 width=5/ ]
+[ #L #K #U #T #d #e #HLK #HUT #He #U2 #HU2
+  elim (lift_total U2 d e) #T2 #HUT2
+  lapply (cpss_lift … HU2 … HLK … HUT … HUT2) -HU2 -HUT /3 width=9/
+| #L1 #K1 #K2 #T1 #T2 #U1 #d #e #HLK1 #HTU1 #_ #IHT12 #U2 #HTU2
+  elim (IHT12 … HTU2) -IHT12 -HTU2 #K #T #HK1 #HT1 #HT2
+  elim (lift_total T d e) #U #HTU
+  elim (ldrop_lpss_trans … HLK1 … HK1) -HLK1 -HK1 #L2 #HL12 #HL2K
+  lapply (cpss_lift … HT1 … HL2K … HTU1 … HTU) -HT1 -HTU1 /3 width=11/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lpss_lpss.etc
new file mode 100644 (file)
index 0000000..12bb02b
--- /dev/null
@@ -0,0 +1,180 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpss_cpss.ma".
+
+(* SN PARALLEL SUBSTITUTION ON LOCAL ENVIRONMENTS ***************************)
+
+(* Main properties on context-sensitive parallel substitution for terms *****)
+
+fact cpss_conf_lpss_atom_atom:
+   ∀I,L1,L2. ∃∃T. L1 ⊢ ⓪{I} ▶* T & L2 ⊢ ⓪{I} ▶* T.
+/2 width=3/ qed-.
+
+fact cpss_conf_lpss_atom_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V2. K0 ⊢ V0 ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ #i ▶* T & L2 ⊢ T2 ▶* T.
+#L0 #i #IH #K0 #V0 #HLK0 #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+elim (lpss_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpss_inv_pair1 … H1) -H1 #K1 #V1 #HK01 #HV01 #H destruct
+elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpss_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 /3 width=6/
+qed-.
+
+fact cpss_conf_lpss_delta_delta:
+   ∀L0,i. (
+      ∀L,T. ⦃L0, #i⦄ ⊃+ ⦃L, T⦄ →
+      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
+   ) →
+   ∀K0,V0. ⇩[O, i] L0 ≡ K0.ⓓV0 →
+   ∀V1. K0 ⊢ V0 ▶* V1 → ∀T1. ⇧[O, i + 1] V1 ≡ T1 →
+   ∀KX,VX. ⇩[O, i] L0 ≡ KX.ⓓVX →
+   ∀V2. KX ⊢ VX ▶* V2 → ∀T2. ⇧[O, i + 1] V2 ≡ T2 →
+   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ T1 ▶* T & L2 ⊢ T2 ▶* T.
+#L0 #i #IH #K0 #V0 #HLK0 #V1 #HV01 #T1 #HVT1
+#KX #VX #H #V2 #HV02 #T2 #HVT2 #L1 #HL01 #L2 #HL02
+lapply (ldrop_mono … H … HLK0) -H #H destruct
+elim (lpss_ldrop_conf … HLK0 … HL01) -HL01 #X1 #H1 #HLK1
+elim (lpss_inv_pair1 … H1) -H1 #K1 #W1 #HK01 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK1) -W1 #HLK1
+elim (lpss_ldrop_conf … HLK0 … HL02) -HL02 #X2 #H2 #HLK2
+elim (lpss_inv_pair1 … H2) -H2 #K2 #W2 #HK02 #_ #H destruct
+lapply (ldrop_fwd_ldrop2 … HLK2) -W2 #HLK2
+lapply (fsupp_lref … HLK0) -HLK0 #HLK0
+elim (IH … HLK0 … HV01 … HV02 … HK01 … HK02) -L0 -K0 -V0 #V #HV1 #HV2
+elim (lift_total V 0 (i+1)) #T #HVT
+lapply (cpss_lift … HV1 … HLK1 … HVT1 … HVT) -K1 -V1
+lapply (cpss_lift … HV2 … HLK2 … HVT2 … HVT) -K2 -V2 -V /2 width=3/
+qed-.
+
+fact cpss_conf_lpss_bind_bind:
+   ∀a,I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓑ{a,I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
+   ) →
+   ∀V1. L0 ⊢ V0 ▶* V1 → ∀T1. L0.ⓑ{I}V0 ⊢ T0 ▶* T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0.ⓑ{I}V0 ⊢ T0 ▶* T2 →
+   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓑ{a,I}V1.T1 ▶* T & L2 ⊢ ⓑ{a,I}V2.T2 ▶* T.
+#a #I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 (L1.ⓑ{I}V1) … (L2.ⓑ{I}V2)) -IH // /2 width=1/ /3 width=5/
+qed-.
+
+fact cpss_conf_lpss_flat_flat:
+   ∀I,L0,V0,T0. (
+      ∀L,T. ⦃L0,ⓕ{I}V0.T0⦄ ⊃+ ⦃L,T⦄ →
+      ∀T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ▶* T2 →
+      ∀L1. L ⊢ ▶* L1 → ∀L2. L ⊢ ▶* L2 →
+      ∃∃T0. L1 ⊢ T1 ▶* T0 & L2 ⊢ T2 ▶* T0
+   ) →
+   ∀V1. L0 ⊢ V0 ▶* V1 → ∀T1. L0 ⊢ T0 ▶* T1 →
+   ∀V2. L0 ⊢ V0 ▶* V2 → ∀T2. L0 ⊢ T0 ▶* T2 →
+   ∀L1. L0 ⊢ ▶* L1 → ∀L2. L0 ⊢ ▶* L2 →
+   ∃∃T. L1 ⊢ ⓕ{I}V1.T1 ▶* T & L2 ⊢ ⓕ{I}V2.T2 ▶* T.
+#I #L0 #V0 #T0 #IH #V1 #HV01 #T1 #HT01
+#V2 #HV02 #T2 #HT02 #L1 #HL01 #L2 #HL02
+elim (IH … HV01 … HV02 … HL01 … HL02) //
+elim (IH … HT01 … HT02 … HL01 … HL02) // /3 width=5/
+qed-.
+
+theorem cpss_conf_lpss: lpx_sn_confluent cpss cpss.
+#L0 #T0 @(fsupp_wf_ind … L0 T0) -L0 -T0 #L #T #IH #L0 * [|*]
+[ #I0 #HL #HT #T1 #H1 #T2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpss_inv_atom1 … H1) -H1
+  elim (cpss_inv_atom1 … H2) -H2
+  [ #H2 #H1 destruct
+    /2 width=1 by cpss_conf_lpss_atom_atom/
+  | * #K0 #V0 #V2 #i2 #HLK0 #HV02 #HVT2 #H2 #H1 destruct
+    /3 width=10 by cpss_conf_lpss_atom_delta/
+  | #H2 * #K0 #V0 #V1 #i1 #HLK0 #HV01 #HVT1 #H1 destruct
+    /4 width=10 by ex2_commute, cpss_conf_lpss_atom_delta/
+  | * #X #Y #V2 #z #H #HV02 #HVT2 #H2
+    * #K0 #V0 #V1 #i #HLK0 #HV01 #HVT1 #H1 destruct
+    /3 width=17 by cpss_conf_lpss_delta_delta/
+  ]
+| #a #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpss_inv_bind1 … H1) -H1 #V1 #T1 #HV01 #HT01 #H destruct
+  elim (cpss_inv_bind1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct
+  /3 width=10 by cpss_conf_lpss_bind_bind/
+| #I #V0 #T0 #HL #HT #X1 #H1 #X2 #H2 #L1 #HL01 #L2 #HL02 destruct
+  elim (cpss_inv_flat1 … H1) -H1 #V1 #T1 #HV01 #HT01 #H destruct
+  elim (cpss_inv_flat1 … H2) -H2 #V2 #T2 #HV02 #HT02 #H destruct
+  /3 width=10 by cpss_conf_lpss_flat_flat/
+]
+qed-.
+
+(* Basic_1: was only: subst1_confluence_eq *)
+theorem cpss_conf: ∀L. confluent … (cpss L).
+/2 width=6 by cpss_conf_lpss/ qed-.
+
+(* Properties on context-sensitive parallel substitution for terms **********)
+
+(* Basic_1: was only: subst1_subst1_back *)
+lemma lpss_cpss_conf_dx: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ▶* L1 →
+                         ∃∃T. L1 ⊢ T0 ▶* T & L1 ⊢ T1 ▶* T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpss_conf_lpss … HT01 T0 … HL01 … HL01) // -L0 /2 width=3/
+qed-.
+
+lemma lpss_cpss_conf_sn: ∀L0,T0,T1. L0 ⊢ T0 ▶* T1 → ∀L1. L0 ⊢ ▶* L1 →
+                         ∃∃T. L1 ⊢ T0 ▶* T & L0 ⊢ T1 ▶* T.
+#L0 #T0 #T1 #HT01 #L1 #HL01
+elim (cpss_conf_lpss … HT01 T0 … L0 … HL01) // -HT01 -HL01 /2 width=3/
+qed-.
+
+(* Main properties **********************************************************)
+
+theorem lpss_conf: confluent … lpss.
+/3 width=6 by lpx_sn_conf, cpss_conf_lpss/
+qed-.
+
+theorem lpss_trans: Transitive … lpss.
+/3 width=5 by lpx_sn_trans, cpss_trans_lpss/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma cpss_fwd_shift1: ∀L1,L,T1,T. L ⊢ L1 @@ T1 ▶* T →
+                       ∃∃L2,T2. L @@ L1 ⊢ ▶* L @@ L2 & L @@ L1 ⊢ T1 ▶* T2 &
+                                T = L2 @@ T2.
+#L1 @(lenv_ind_dx … L1) -L1
+[ #L #T1 #T #HT1
+  @ex3_2_intro [3: // |4,5: // |1,2: skip ] (**) (* /2 width=4/ does not work *)
+| #I #L1 #V1 #IH #L #T1 #T >shift_append_assoc #H <append_assoc
+  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IH … HT12) -IH -HT12 #L2 #T #HL12 #HT1 #H destruct
+  lapply (lpss_trans … HL12 (L.ⓑ{I}V2@@L2) ?) -HL12 /3 width=1/ #HL12
+  @(ex3_2_intro … (⋆.ⓑ{I}V2@@L2)) [4: /2 width=3/ | skip ] <append_assoc // (**) (* explicit constructor *)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr.etc
new file mode 100644 (file)
index 0000000..c41ab19
--- /dev/null
@@ -0,0 +1,104 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L1 ⓝ ⊑ break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LRSubEqT $L1 $L2 }.
+
+include "basic_2/relocation/ldrop.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
+
+inductive lsubr: relation lenv ≝
+| lsubr_sort: ∀L. lsubr L (⋆)
+| lsubr_abbr: ∀L1,L2,V. lsubr L1 L2 → lsubr (L1. ⓓV) (L2.ⓓV)
+| lsubr_abst: ∀I,L1,L2,V1,V2. lsubr L1 L2 → lsubr (L1. ⓑ{I}V1) (L2. ⓛV2)
+.
+
+interpretation
+  "local environment refinement (substitution)"
+  'CrSubEq L1 L2 = (lsubr L1 L2).
+
+(* Basic properties *********************************************************)
+
+lemma lsubr_bind: ∀I,L1,L2,V. L1 ⊑ L2 → L1. ⓑ{I} V ⊑ L2.ⓑ{I} V.
+* /2 width=1/ qed.
+
+lemma lsubr_abbr: ∀I,L1,L2,V. L1 ⊑ L2 → L1. ⓓV ⊑ L2. ⓑ{I}V.
+* /2 width=1/ qed.
+
+lemma lsubr_refl: ∀L. L ⊑ L.
+#L elim L -L // /2 width=1/
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lsubr_inv_atom1_aux: ∀L1,L2. L1 ⊑ L2 → L1 = ⋆ → L2 = ⋆.
+#L1 #L2 * -L1 -L2 //
+[ #L1 #L2 #V #_ #H destruct
+| #I #L1 #L2 #V1 #V2 #_ #H destruct
+]
+qed-.
+
+lemma lsubr_inv_atom1: ∀L2. ⋆ ⊑ L2 → L2 = ⋆.
+/2 width=3 by lsubr_inv_atom1_aux/ qed-.
+
+fact lsubr_inv_abbr2_aux: ∀L1,L2. L1 ⊑ L2 → ∀K2,W. L2 = K2.ⓓW →
+                          ∃∃K1. K1 ⊑ K2 & L1 = K1.ⓓW.
+#L1 #L2 * -L1 -L2
+[ #L #K2 #W #H destruct
+| #L1 #L2 #V #HL12 #K2 #W #H destruct /2 width=3/
+| #I #L1 #L2 #V1 #V2 #_ #K2 #W #H destruct
+]
+qed-.
+
+lemma lsubr_inv_abbr2: ∀L1,K2,W. L1 ⊑ K2.ⓓW →
+                       ∃∃K1. K1 ⊑ K2 & L1 = K1.ⓓW.
+/2 width=3 by lsubr_inv_abbr2_aux/ qed-.
+
+fact lsubr_inv_abst2_aux: ∀L1,L2. L1 ⊑ L2 → ∀K2,W2. L2 = K2.ⓛW2 →
+                          ∃∃I,K1,W1. K1 ⊑ K2 & L1 = K1.ⓑ{I}W1.
+#L1 #L2 * -L1 -L2
+[ #L #K2 #W2 #H destruct
+| #L1 #L2 #V #_ #K2 #W2 #H destruct
+| #I #L1 #L2 #V1 #V2 #HL12 #K2 #W2 #H destruct /2 width=5/
+]
+qed-.
+
+lemma lsubr_inv_abst2: ∀L1,K2,W2. L1 ⊑ K2.ⓛW2 →
+                       ∃∃I,K1,W1. K1 ⊑ K2 & L1 = K1.ⓑ{I}W1.
+/2 width=4 by lsubr_inv_abst2_aux/ qed-.
+
+(* Basic forward lemmas *****************************************************)
+
+lemma lsubr_fwd_length: ∀L1,L2. L1 ⊑ L2 → |L2| ≤ |L1|.
+#L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+lemma lsubr_fwd_ldrop2_abbr: ∀L1,L2. L1 ⊑ L2 →
+                             ∀K2,W,i. ⇩[0, i] L2 ≡ K2. ⓓW →
+                             ∃∃K1. K1 ⊑ K2 & ⇩[0, i] L1 ≡ K1. ⓓW.
+#L1 #L2 #H elim H -L1 -L2
+[ #L #K2 #W #i #H
+  elim (ldrop_inv_atom1 … H) -H #H destruct
+| #L1 #L2 #V #HL12 #IHL12 #K2 #W #i #H
+  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct [ -IHL12 | -HL12 ]
+  [ /2 width=3/
+  | elim (IHL12 … HLK2) -IHL12 -HLK2 /3 width=3/
+  ]
+| #I #L1 #L2 #V1 #V2 #_ #IHL12 #K2 #W #i #H
+  elim (ldrop_inv_O1_pair1 … H) -H * #Hi #HLK2 destruct
+  elim (IHL12 … HLK2) -IHL12 -HLK2 /3 width=3/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_etc.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_etc.etc
new file mode 100644 (file)
index 0000000..107109a
--- /dev/null
@@ -0,0 +1,64 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+lemma lsubr_fwd_lsubr: ∀L1,L2. L1 ⓝ⊑ L2 → L1 ⊑ L2.
+#L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+lemma cpqs_cpr: ∀L,T1,T2. L ⊢ T1 ➤* T2 → L ⊢ T1 ➡ T2.
+#L #T1 #T2 #H elim H -L -T1 -T2 // /2 width=1/ /2 width=6/
+qed.
+
+lemma cpss_cpr: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➡ T2.
+/3 width=1/ qed.
+
+lemma lpqs_lpr: ∀L1,L2. L1 ⊢ ➤* L2 → L1 ⊢ ➡ L2.
+#L1 #L2 #H elim H -L1 -L2 // /3 width=1/
+qed.
+
+lemma lpss_lpr: ∀L1,L2. L1 ⊢ ▶* L2 → L1 ⊢ ➡ L2.
+/3 width=1/ qed.
+
+lemma cpss_fwd_cir_eq: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ 𝐈⦃T1⦄ → T2 = T1.
+/3 width=3 by cpr_fwd_cir, cpss_cpr/ qed-.
+
+lemma cpss_cprs: ∀L,T1,T2. L ⊢ T1 ▶* T2 → L ⊢ T1 ➡* T2.
+/3 width=1/ qed.
+
+lemma cprs_cpss_trans: ∀L,T1,T. L ⊢ T1 ➡* T → ∀T2. L ⊢ T ▶* T2 → L ⊢ T1 ➡* T2.
+/3 width=3/ qed-.
+
+lemma cpss_cprs_trans: ∀L,T1,T. L ⊢ T1 ▶* T → ∀T2. L ⊢ T ➡* T2 → L ⊢ T1 ➡* T2.
+/3 width=3/ qed-.
+
+lemma cpcs_cpss_strap1: ∀L,T1,T. L ⊢ T1 ⬌* T → ∀T2. L ⊢ T ▶* T2 → L ⊢ T1 ⬌* T2.
+#L #T1 #T #HT1 #T2 #HT2
+@(cpcs_cpr_strap1 … HT1) -T1 /2 width=3/
+qed-.
+
+lemma cpcs_cpss_strap2: ∀L,T1,T. L ⊢ T1 ▶* T → ∀T2. L ⊢ T ⬌* T2 → L ⊢ T1 ⬌* T2.
+#L #T1 #T #HT1 #T2 #HT2
+@(cpcs_cpr_strap2 … HT2) -T2 /2 width=3/
+qed-.
+
+lemma cpcs_cpss_conf: ∀L,T,T1. L ⊢ T ▶* T1 → ∀T2. L ⊢ T ⬌* T2 → L ⊢ T1 ⬌* T2.
+#L #T #T1 #HT1 #T2 #HT2
+@(cpcs_cpr_conf … HT2) -T2 /2 width=3/
+qed-.
+
+lemma cpcs_cpss_div: ∀L,T1,T. L ⊢ T1 ⬌* T → ∀T2. L ⊢ T2 ▶* T → L ⊢ T1 ⬌* T2.
+#L #T1 #T #HT1 #T2 #HT2
+@(cpcs_cpr_div … HT1) -T1 /2 width=3/
+qed-.
+
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_lsubr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/lsubr_lsubr.etc
new file mode 100644 (file)
index 0000000..98f3227
--- /dev/null
@@ -0,0 +1,66 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lsubr.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR SUBSTITUTION ****************************)
+
+(* Auxiliary inversion lemmas ***********************************************)
+
+fact lsubr_inv_abbr1_aux: ∀L1,L2. L1 ⊑ L2 → ∀K1,W. L1 = K1.ⓓW →
+                          ∨∨ L2 = ⋆
+                           | ∃∃K2. K1 ⊑ K2 & L2 = K2.ⓓW
+                           | ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
+#L1 #L2 * -L1 -L2
+[ #L #K1 #W #H destruct /2 width=1/
+| #L1 #L2 #V #HL12 #K1 #W #H destruct /3 width=3/
+| #I #L1 #L2 #V1 #V2 #HL12 #K1 #W #H destruct /3 width=4/
+]
+qed-.
+
+lemma lsubr_inv_abbr1: ∀K1,L2,W. K1.ⓓW ⊑ L2 →
+                       ∨∨ L2 = ⋆
+                        | ∃∃K2. K1 ⊑ K2 & L2 = K2.ⓓW
+                        | ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
+/2 width=3 by lsubr_inv_abbr1_aux/ qed-.
+
+fact lsubr_inv_abst1_aux: ∀L1,L2. L1 ⊑ L2 → ∀K1,W1. L1 = K1.ⓛW1 →
+                          L2 = ⋆ ∨
+                          ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
+#L1 #L2 * -L1 -L2
+[ #L #K1 #W1 #H destruct /2 width=1/
+| #L1 #L2 #V #_ #K1 #W1 #H destruct
+| #I #L1 #L2 #V1 #V2 #HL12 #K1 #W1 #H destruct /3 width=4/
+]
+qed-.
+
+lemma lsubr_inv_abst1: ∀K1,L2,W1. K1.ⓛW1 ⊑ L2 →
+                       L2 = ⋆ ∨
+                       ∃∃K2,W2. K1 ⊑ K2 & L2 = K2.ⓛW2.
+/2 width=4 by lsubr_inv_abst1_aux/ qed-.
+
+(* Main properties **********************************************************)
+
+theorem lsubr_trans: Transitive … lsubr.
+#L1 #L #H elim H -L1 -L
+[ #L1 #X #H
+  lapply (lsubr_inv_atom1 … H) -H //
+| #L1 #L #V #_ #IHL1 #X #H
+  elim (lsubr_inv_abbr1 … H) -H // *
+  #L2 [2: #V2 ] #HL2 #H destruct /3 width=1/
+| #I #L1 #L #V1 #V #_ #IHL1 #X #H
+  elim (lsubr_inv_abst1 … H) -H // *
+  #L2 #V2 #HL2 #H destruct /3 width=1/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/snv_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/snv_lpss.etc
new file mode 100644 (file)
index 0000000..91d34b1
--- /dev/null
@@ -0,0 +1,73 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/dxprs_lpss.ma".
+include "basic_2/equivalence/cpcs_lpss.ma".
+include "basic_2/dynamic/snv_lift.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties about sn parallel substitution for local environments *********)
+
+lemma snv_cpss_lpss_conf: ∀h,g,L1,T1. ⦃h, L1⦄ ⊢ T1 ¡[g] → ∀T2. L1 ⊢ T1 ▶* T2 →
+                          ∀L2. L1 ⊢ ▶* L2 → ⦃h, L2⦄ ⊢ T2 ¡[g].
+#h #g #L1 #T1 #H elim H -L1 -T1
+[ #L1 #k #X #H #L2 #_
+   >(cpss_inv_sort1 … H) -X //
+| #I #L1 #K1 #V1 #i #HLK1 #_ #IHV1 #W2 #H #L2 #HL12
+  elim (cpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
+    lapply (IHV1 … HV12 … HK12) -IHV1 -HV12 -HK12 /2 width=5/
+  | * #K0 #V0 #V2 #HLK0 #HV12 #HVW2
+    lapply (ldrop_mono … HLK0 … HLK1) -HLK0 #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -L1 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -V #HLK2
+    lapply (IHV1 … HV12 … HK12) -IHV1 -HV12 -HK12 /2 width=7/
+  ]
+| #a #I #L1 #V1 #T1 #_ #_ #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (IHV1 … HV12 … HL12) -IHV1 #HV2
+  lapply (IHT1 … HT12 (L2.ⓑ{I}V2) ?) -IHT1 -HT12 /2 width=1/
+| #a #L1 #V1 #W1 #W0 #T1 #U1 #l #_ #_ #HVW1 #HW10 #HTU1 #IHV1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (IHV1 … HV12 … HL12) -IHV1 #HV2
+  lapply (IHT1 … HT12 … HL12) -IHT1 #HT2
+  elim (ssta_cpss_lpss_conf … HVW1 … HV12 … HL12) -V1 #W2 #HVW2 #HW12
+  elim (dxprs_cpss_lpss_conf … HTU1 … HT12 … HL12) -T1 #X #HTU2 #H
+  elim (cpss_inv_bind1 … H) -H #W #U2 #HW0 #_ #H -U1 destruct
+  elim (cprs_cpss2_lpss_conf_dx … HW10 … HW12 … HW0 … HL12) -L1 -W1 -W0 #W0 #HW20 #HW0
+  lapply (dxprs_strap1 … (ⓛ{a}W0.U2) HTU2 ?) -HTU2 /3 width=3/ -HW0 /2 width=8/
+| #L1 #W1 #T1 #U1 #l #_ #_ #HTU1 #HUW1 #IHW1 #IHT1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
+  lapply (IHW1 … HW12 … HL12) -IHW1 #HW2
+  lapply (IHT1 … HT12 … HL12) -IHT1 #HT2
+  elim (ssta_cpss_lpss_conf … HTU1 … HT12 … HL12) -T1 #U2 #HTU2 #HU12
+  lapply (cpcs_cpss2_lpss_conf … HUW1 … HU12 … HW12 … HL12) -L1 -W1 -U1 /2 width=4/
+]
+qed-.
+
+lemma snv_lpss_conf: ∀h,g,L1,T. ⦃h, L1⦄ ⊢ T ¡[g] →
+                     ∀L2. L1 ⊢ ▶* L2 → ⦃h, L2⦄ ⊢ T ¡[g].
+#h #g #L1 #T #HT #L2 #HL12
+@(snv_cpss_lpss_conf … HT … HL12) //
+qed-.
+
+lemma snv_cpss_conf: ∀h,g,L,T1. ⦃h, L⦄ ⊢ T1 ¡[g] →
+                     ∀T2. L ⊢ T1 ▶* T2 → ⦃h, L⦄ ⊢ T2 ¡[g].
+#h #g #L #T1 #HT1 #T2 #HT12
+@(snv_cpss_lpss_conf … HT1 … HT12) //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/ssta_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/ssta_lpss.etc
new file mode 100644 (file)
index 0000000..7471b23
--- /dev/null
@@ -0,0 +1,81 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lpss_ldrop.ma".
+include "basic_2/static/ssta_lift.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Properties about sn parallel substitution ********************************)
+
+(* Note: apparently this was missing in basic_1 *)
+lemma ssta_cpss_lpss_conf: ∀h,g,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                           ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
+                           ∃∃U2. ⦃h, L2⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* U2.
+#h #g #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
+[ #L1 #k1 #l1 #Hkl1 #X #H
+  >(cpss_inv_sort1 … H) -H /3 width=3/
+| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #_ #HWU1 #IHVW1 #X #H #L2 #HL12
+  elim (cpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
+    elim (IHVW1 … HV12 … HK12) -IHVW1 -HV12 -HK12 #W2 #HVW2 #HW12
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 /3 width=6/
+  | * #Y #Z #V2 #H #HV12 #HV2
+    lapply (ldrop_mono … H … HLK1) -H #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #Z #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #V0 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -V0 #HLK2
+    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
+    elim (IHVW1 … HV12 … HK12) -IHVW1 -HK12 -HV12 #W2 #HVW2 #HW12
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (ssta_lift … HVW2 … HLK2 … HV2 … HWU2) -HVW2 -HLK2 -HV2
+    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 -HWU2 /3 width=3/
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #_ #HWU1 #IHWV1 #X #H #L2 #HL12
+  elim (cpss_inv_lref1 … H) -H [ | -IHWV1 -HWU1 -HL12 ]
+  [ #H destruct
+    elim (lpss_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+    elim (lpss_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
+    elim (IHWV1 … HW12 … HK12) -IHWV1 -HK12 #V2 #HWV2 #_
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (cpss_lift … HW12 … HLK1 … HWU1 … HWU2) -HW12 -HLK1 -HWU1 /3 width=6/ 
+  | * #K2 #V2 #W2 #HLK2 #_ #_
+    lapply (ldrop_mono … HLK2 … HLK1) -HLK1 -HLK2 #H destruct
+  ]
+| #a #I #L1 #V1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
+  elim (cpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12 (L2.ⓑ{I}V2)) -IHTU1 -HT12 /2 width=1/ -HL12 /3 width=5/
+| #L1 #V1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  elim (IHTU1 … HT12 … HL12) -IHTU1 -HT12 -HL12 /3 width=5/
+| #L1 #W1 #T1 #U1 #l #_ #IHTU1 #X #H #L2 #HL12
+  elim (cpss_inv_flat1 … H) -H #W2 #T2 #HW12 #HT12 #H destruct
+  elim (IHTU1 … HT12 … HL12) -IHTU1 -HT12 -HL12 /3 width=3/
+]
+qed-.
+
+lemma ssta_cpss_conf: ∀h,g,L,T1,U1,l. ⦃h, L⦄ ⊢ T1 •[g] ⦃l, U1⦄ →
+                      ∀T2. L ⊢ T1 ▶* T2 →
+                      ∃∃U2. ⦃h, L⦄ ⊢ T2 •[g] ⦃l, U2⦄ & L ⊢ U1 ▶* U2.
+/2 width=3 by ssta_cpss_lpss_conf/ qed-.
+
+lemma ssta_lpss_conf: ∀h,g,L1,T,U1,l. ⦃h, L1⦄ ⊢ T •[g] ⦃l, U1⦄ →
+                      ∀L2. L1 ⊢ ▶* L2 →
+                      ∃∃U2. ⦃h, L2⦄ ⊢ T •[g] ⦃l, U2⦄ & L1 ⊢ U1 ▶* U2.
+/2 width=3 by ssta_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/sstas_lpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/lsubr/sstas_lpss.etc
new file mode 100644 (file)
index 0000000..3ecbc22
--- /dev/null
@@ -0,0 +1,39 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/ssta_lpss.ma".
+include "basic_2/unfold/sstas.ma".
+
+(* ITERATED STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS *********************)
+
+(* Properties about sn parallel substitution for local environments *********)
+
+lemma sstas_cpss_lpss_conf: ∀h,g,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 •*[g] U1 →
+                            ∀T2. L1 ⊢ T1 ▶* T2 → ∀L2. L1 ⊢ ▶* L2 →
+                            ∃∃U2. ⦃h, L2⦄ ⊢ T2 •*[g] U2 & L1 ⊢ U1 ▶* U2.
+#h #g #L1 #T1 #U1 #H @(sstas_ind_dx … H) -T1 /2 width=3/
+#T0 #U0 #l0 #HTU0 #_ #IHU01 #T #HT0 #L2 #HL12
+elim (ssta_cpss_lpss_conf … HTU0 … HT0 … HL12) -HTU0 -HT0 #U #HTU #HU0
+elim (IHU01 … HU0 … HL12) -IHU01 -U0 -HL12 /3 width=4/
+qed-.
+
+lemma sstas_cpss_conf: ∀h,g,L,T1,U1. ⦃h, L⦄ ⊢ T1 •*[g] U1 →
+                       ∀T2. L ⊢ T1 ▶* T2 →
+                       ∃∃U2. ⦃h, L⦄ ⊢ T2 •*[g] U2 & L ⊢ U1 ▶* U2.
+/2 width=3 by sstas_cpss_lpss_conf/ qed-.
+
+lemma sstas_lpss_conf: ∀h,g,L1,T,U1. ⦃h, L1⦄ ⊢ T •*[g] U1 →
+                       ∀L2. L1 ⊢ ▶* L2 →
+                       ∃∃U2. ⦃h, L2⦄ ⊢ T •*[g] U2 & L1 ⊢ U1 ▶* U2.
+/2 width=3 by sstas_cpss_lpss_conf/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn.etc
new file mode 100644 (file)
index 0000000..c4359c3
--- /dev/null
@@ -0,0 +1,118 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( h ⊢ break term 46 L1 : ⊑ break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'CrSubEqN $h $L1 $L2 }.
+
+notation "hvbox( h ⊢ break term 46 L1 : : ⊑ break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'CrSubEqNAlt $h $L1 $L2 }.
+
+include "basic_2/dynamic/nta.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
+
+(* Note: may not be transitive *)
+inductive lsubn (h:sh): relation lenv ≝
+| lsubn_atom: lsubn h (⋆) (⋆)
+| lsubn_pair: ∀I,L1,L2,W. lsubn h L1 L2 → lsubn h (L1. ⓑ{I} W) (L2. ⓑ{I} W)
+| lsubn_abbr: ∀L1,L2,V,W. ⦃h, L1⦄ ⊢ V : W → ⦃h, L2⦄ ⊢ V : W →
+              lsubn h L1 L2 → lsubn h (L1. ⓓV) (L2. ⓛW)
+.
+
+interpretation
+  "local environment refinement (native type assigment)"
+  'CrSubEqN h L1 L2 = (lsubn h L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lsubn_inv_atom1_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 = ⋆ → L2 = ⋆.
+#h #L1 #L2 * -L1 -L2
+[ //
+| #I #L1 #L2 #V #_ #H destruct
+| #L1 #L2 #V #W #_ #_ #_ #H destruct
+]
+qed.
+
+lemma lsubn_inv_atom1: ∀h,L2. h ⊢ ⋆ :⊑ L2 → L2 = ⋆.
+/2 width=4/ qed-.
+
+fact lsubn_inv_pair1_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀I,K1,V. L1 = K1. ⓑ{I} V →
+                          (∃∃K2. h ⊢ K1 :⊑ K2 & L2 = K2. ⓑ{I} V) ∨
+                          ∃∃K2,W. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
+                                  h ⊢ K1 :⊑ K2 & L2 = K2. ⓛW & I = Abbr.
+#h #L1 #L2 * -L1 -L2
+[ #I #K1 #V #H destruct
+| #J #L1 #L2 #V #HL12 #I #K1 #W #H destruct /3 width=3/
+| #L1 #L2 #V #W #H1VW #H2VW #HL12 #I #K1 #V1 #H destruct /3 width=7/
+]
+qed.
+
+lemma lsubn_inv_pair1: ∀h,I,K1,L2,V. h ⊢ K1. ⓑ{I} V :⊑ L2 →
+                       (∃∃K2. h ⊢ K1 :⊑ K2 & L2 = K2. ⓑ{I} V) ∨
+                       ∃∃K2,W. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
+                               h ⊢ K1 :⊑ K2 & L2 = K2. ⓛW & I = Abbr.
+/2 width=3/ qed-.
+
+fact lsubn_inv_atom2_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L2 = ⋆ → L1 = ⋆.
+#h #L1 #L2 * -L1 -L2
+[ //
+| #I #L1 #L2 #V #_ #H destruct
+| #L1 #L2 #V #W #_ #_ #_ #H destruct
+]
+qed.
+
+lemma lsubc_inv_atom2: ∀h,L1. h ⊢ L1 :⊑ ⋆ → L1 = ⋆.
+/2 width=4/ qed-.
+
+fact lsubn_inv_pair2_aux: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀I,K2,W. L2 = K2. ⓑ{I} W →
+                          (∃∃K1. h ⊢ K1 :⊑ K2 & L1 = K1. ⓑ{I} W) ∨
+                          ∃∃K1,V. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
+                                  h ⊢ K1 :⊑ K2 & L1 = K1. ⓓV & I = Abst.
+#h #L1 #L2 * -L1 -L2
+[ #I #K2 #W #H destruct
+| #J #L1 #L2 #V #HL12 #I #K2 #W #H destruct /3 width=3/
+| #L1 #L2 #V #W #H1VW #H2VW #HL12 #I #K2 #W2 #H destruct /3 width=7/
+]
+qed.
+
+(* Basic_1: was: csubt_gen_bind *)
+lemma lsubn_inv_pair2: ∀h,I,L1,K2,W. h ⊢ L1 :⊑ K2. ⓑ{I} W →
+                       (∃∃K1. h ⊢ K1 :⊑ K2 & L1 = K1. ⓑ{I} W) ∨
+                       ∃∃K1,V. ⦃h, K1⦄ ⊢ V : W & ⦃h, K2⦄ ⊢ V : W &
+                               h ⊢ K1 :⊑ K2 & L1 = K1. ⓓV & I = Abst.
+/2 width=3/ qed-.
+
+(* Basic_forward lemmas *****************************************************)
+
+lemma lsubn_fwd_lsubs1: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 ≼[0, |L1|] L2.
+#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+lemma lsubn_fwd_lsubs2: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → L1 ≼[0, |L2|] L2.
+#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: csubt_refl *)
+lemma lsubn_refl: ∀h,L. h ⊢ L :⊑ L.
+#h #L elim L -L // /2 width=1/
+qed.
+
+(* Basic_1: removed theorems 6:
+            csubt_gen_flat csubt_drop_flat csubt_clear_conf
+            csubt_getl_abbr csubt_getl_abst csubt_ty3_ld
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_cpcs.etc
new file mode 100644 (file)
index 0000000..5f610bc
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_cpcs.ma".
+include "basic_2/dynamic/lsubn.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
+
+(* Properties on context-sensitive parallel equivalence for terms ***********)
+
+(* Basic_1: was: csubt_pr2 *)
+lemma cpr_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
+                       ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
+/3 width=4 by lsubn_fwd_lsubs2, cpr_lsubs_trans/ qed.
+
+lemma cprs_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
+                        ∀T1,T2. L2 ⊢ T1 ➡* T2 → L1 ⊢ T1 ➡* T2.
+/3 width=4 by lsubn_fwd_lsubs2, cprs_lsubs_trans/ qed.
+
+(* Basic_1: was: csubt_pc3 *)
+lemma cpcs_lsubn_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 →
+                        ∀T1,T2. L2 ⊢ T1 ⬌* T2 → L1 ⊢ T1 ⬌* T2.
+/3 width=4 by lsubn_fwd_lsubs2, cpcs_lsubs_trans/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_ldrop.etc
new file mode 100644 (file)
index 0000000..a16fff6
--- /dev/null
@@ -0,0 +1,64 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/lsubn.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
+
+(* Properties concerning basic local environment slicing ********************)
+
+(* Note: the constant 0 cannot be generalized *)
+lemma lsubn_ldrop_O1_conf: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀K1,e. ⇩[0, e] L1 ≡ K1 →
+                           ∃∃K2. h ⊢ K1 :⊑ K2 & ⇩[0, e] L2 ≡ K2.
+#h #L1 #L2 #H elim H -L1 -L2
+[ /2 width=3/
+| #I #L1 #L2 #V #_ #IHL12 #K1 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK1
+  [ destruct
+    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK1) -L1 /3 width=3/
+  ]
+| #L1 #L2 #V #W #H1VW #H2VW #_ #IHL12 #K1 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK1
+  [ destruct
+    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK1) -L1 /3 width=3/
+  ]
+]
+qed.
+
+(* Note: the constant 0 cannot be generalized *)
+(* Basic_1: was only: csubt_drop_abbr csubt_drop_abst *)
+lemma lsubn_ldrop_O1_trans: ∀h,L1,L2. h ⊢ L1 :⊑ L2 → ∀K2,e. ⇩[0, e] L2 ≡ K2 →
+                            ∃∃K1. h ⊢ K1 :⊑ K2 & ⇩[0, e] L1 ≡ K1.
+#h #L1 #L2 #H elim H -L1 -L2
+[ /2 width=3/
+| #I #L1 #L2 #V #_ #IHL12 #K2 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK2
+  [ destruct
+    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK2) -L2 /3 width=3/
+  ]
+| #L1 #L2 #V #W #H1VW #H2VW #_ #IHL12 #K2 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK2
+  [ destruct
+    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK2) -L2 /3 width=3/
+  ]
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/lsubn_nta.etc
new file mode 100644 (file)
index 0000000..5832b00
--- /dev/null
@@ -0,0 +1,47 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/nta_nta.ma".
+include "basic_2/dynamic/lsubn_ldrop.ma".
+include "basic_2/dynamic/lsubn_cpcs.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR NATIVE TYPE ASSIGNMENT ******************)
+
+(* Properties concerning atomic arity assignment ****************************)
+
+(* Note: the corresponding confluence property does not hold *)
+(* Basic_1: was: csubt_ty3 *)
+lemma lsubn_nta_trans: ∀h,L2,T,U. ⦃h, L2⦄ ⊢ T : U → ∀L1. h ⊢ L1 :⊑ L2 →
+                       ⦃h, L1⦄ ⊢ T : U.
+#h #L2 #T #U #H elim H -L2 -T -U
+[ //
+| #L2 #K2 #V2 #W2 #U2 #i #HLK2 #_ #WU2 #IHVW2 #L1 #HL12
+  elim (lsubn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
+  elim (lsubn_inv_pair2 … H) -H * #K1
+  [ #HK12 #H destruct /3 width=6/
+  | #V1 #_ #_ #_ #_ #H destruct
+  ]
+| #L2 #K2 #W2 #V2 #U2 #i #HLK2 #_ #HWU2 #IHWV2 #L1 #HL12
+  elim (lsubn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
+  elim (lsubn_inv_pair2 … H) -H * #K1 [ | -IHWV2 ]
+  [ #HK12 #H destruct /3 width=6/
+  | #V1 #H1V1W2 #_ #_ #H #_ destruct /2 width=6/
+  ]
+| /4 width=2/
+| /3 width=1/
+| /3 width=2/
+| /3 width=1/
+| /4 width=6/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta.etc
new file mode 100644 (file)
index 0000000..fa4a8ed
--- /dev/null
@@ -0,0 +1,53 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sh.ma".
+include "basic_2/equivalence/cpcs.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+inductive nta (h:sh): lenv → relation term ≝
+| nta_sort: ∀L,k. nta h L (⋆k) (⋆(next h k))
+| nta_ldef: ∀L,K,V,W,U,i. ⇩[0, i] L ≡ K. ⓓV → nta h K V W →
+            ⇧[0, i + 1] W ≡ U → nta h L (#i) U
+| nta_ldec: ∀L,K,W,V,U,i. ⇩[0, i] L ≡ K. ⓛW → nta h K W V →
+            ⇧[0, i + 1] W ≡ U → nta h L (#i) U
+| nta_bind: ∀I,L,V,W,T,U. nta h L V W → nta h (L. ⓑ{I} V) T U →
+            nta h L (ⓑ{I}V.T) (ⓑ{I}V.U)
+| nta_appl: ∀L,V,W,T,U. nta h L V W → nta h L (ⓛW.T) (ⓛW.U) →
+            nta h L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
+| nta_pure: ∀L,V,W,T,U. nta h L T U → nta h L (ⓐV.U) W →
+            nta h L (ⓐV.T) (ⓐV.U)
+| nta_cast: ∀L,T,U. nta h L T U → nta h L (ⓝU. T) U
+| nta_conv: ∀L,T,U1,U2,V2. nta h L T U1 → L ⊢ U1 ⬌* U2 → nta h L U2 V2 →
+            nta h L T U2
+.
+
+interpretation "native type assignment (term)"
+   'NativeType h L T U = (nta h L T U).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: ty3_cast *)
+lemma nta_cast_old: ∀h,L,W,T,U.
+                    ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ U : W → ⦃h, L⦄ ⊢ ⓝU.T : ⓝW.U.
+/4 width=3/ qed.
+
+(* Basic_1: was: ty3_typecheck *)
+lemma nta_typecheck: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃T0. ⦃h, L⦄ ⊢ ⓝU.T : T0.
+/3 width=2/ qed.
+
+(* Basic_1: removed theorems 4:
+            ty3_getl_subst0 ty3_fsubst0 ty3_csubst0 ty3_subst0
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_aaa.etc
new file mode 100644 (file)
index 0000000..9628569
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/csn_aaa.ma".
+include "basic_2/equivalence/lcpcs_aaa.ma".
+include "basic_2/dynamic/nta.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Forward lemmas on atomic arity assignment for terms **********************)
+
+lemma nta_fwd_aaa: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃∃A. L ⊢ T ⁝ A & L ⊢ U ⁝ A.
+#h #L #T #U #H elim H -L -T -U
+[ /2 width=3/
+| #L #K #V #W #U #i #HLK #_ #HWU * #B #HV #HW
+  lapply (ldrop_fwd_ldrop2 … HLK) /3 width=9/
+| #L #K #W #V #U #i #HLK #_ #HWU * #B #HW #_ -V
+  lapply (ldrop_fwd_ldrop2 … HLK) /3 width=9/
+| * #L #V #W #T #U #_ #_ * #B #HV #HW * #A #HT #HU
+  [ /3 width=3/ | /3 width=5/ ]
+| #L #V #W #T #U #_ #_ * #B #HV #HW * #X #H1 #H2
+  elim (aaa_inv_abst … H1) -H1 #B1 #A1 #HW1 #HT #H destruct
+  elim (aaa_inv_abst … H2) -H2 #B2 #A #_ #HU #H destruct
+  lapply (aaa_mono … HW1 … HW) -HW1 #H destruct /4 width=5/
+| #L #V #W #T #U #_ #_ * #X #HT #HUX * #A #H #_ -W
+  elim (aaa_inv_appl … H) -H #B #HV #HUA
+  lapply (aaa_mono … HUA … HUX) -HUX #H destruct /3 width=5/
+| #L #T #U #_ * #A #HT #HU /3 width=3/
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ * #X #HT #HU1 * #A #HU2 #_
+  lapply (aaa_cpcs_mono … HU12 … HU1 … HU2) -U1 #H destruct /2 width=3/
+]
+qed-.
+
+(* Note: this is the stong normalization property *)
+(* Basic_1: was only: ty3_sn3 *)
+theorem nta_fwd_csn: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → L ⊢ ⬇* T ∧ L ⊢ ⬇* U.
+#h #L #T #U #H elim (nta_fwd_aaa … H) -H /3 width=2/
+qed-. 
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_alt.etc
new file mode 100644 (file)
index 0000000..8cbd595
--- /dev/null
@@ -0,0 +1,190 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_cpcs.ma".
+include "basic_2/dynamic/nta.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* alternative definition of nta *)
+inductive ntaa (h:sh): lenv → relation term ≝
+| ntaa_sort: ∀L,k. ntaa h L (⋆k) (⋆(next h k))
+| ntaa_ldef: ∀L,K,V,W,U,i. ⇩[0, i] L ≡ K. ⓓV → ntaa h K V W →
+             ⇧[0, i + 1] W ≡ U → ntaa h L (#i) U
+| ntaa_ldec: ∀L,K,W,V,U,i. ⇩[0, i] L ≡ K. ⓛW → ntaa h K W V →
+             ⇧[0, i + 1] W ≡ U → ntaa h L (#i) U
+| ntaa_bind: ∀I,L,V,W,T,U. ntaa h L V W → ntaa h (L. ⓑ{I} V) T U →
+             ntaa h L (ⓑ{I}V.T) (ⓑ{I}V.U)
+| ntaa_appl: ∀L,V,W,T,U. ntaa h L V W → ntaa h L (ⓛW.T) (ⓛW.U) →
+             ntaa h L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
+| ntaa_pure: ∀L,V,W,T,U. ntaa h L T U → ntaa h L (ⓐV.U) W →
+             ntaa h L (ⓐV.T) (ⓐV.U)
+| ntaa_cast: ∀L,T,U,W. ntaa h L T U → ntaa h L U W → ntaa h L (ⓝU. T) U
+| ntaa_conv: ∀L,T,U1,U2,V2. ntaa h L T U1 → L ⊢ U1 ⬌* U2 → ntaa h L U2 V2 →
+             ntaa h L T U2
+.
+
+interpretation "native type assignment (term) alternative"
+   'NativeTypeAlt h L T U = (ntaa h L T U).
+
+(* Advanced inversion lemmas ************************************************)
+
+fact ntaa_inv_bind1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ∀J,X,Y. T = ⓑ{J}Y.X →
+                         ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y :: Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :: Z2 &
+                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
+#h #L #T #U #H elim H -L -T -U
+[ #L #k #J #X #Y #H destruct
+| #L #K #V #W #U #i #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #K #W #V #U #i #_ #_ #_ #_ #J #X #Y #H destruct
+| #I #L #V #W #T #U #HVW #HTU #_ #_ #J #X #Y #H destruct /2 width=3/
+| #L #V #W #T #U #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #T #U #W #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #J #X #Y #H destruct
+  elim (IHTU1 ????) -IHTU1 [5: // |2,3,4: skip ] #Z1 #Z2 #HZ1 #HZ2 #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
+]
+qed.
+
+lemma ntaa_inv_bind1: ∀h,J,L,Y,X,U. ⦃h, L⦄ ⊢ ⓑ{J}Y.X :: U →
+                      ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y :: Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :: Z2 &
+                               L ⊢ ⓑ{J}Y.Z2 ⬌* U.
+/2 width=3/ qed-.                            
+
+lemma ntaa_nta: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ⦃h, L⦄ ⊢ T : U.
+#h #L #T #U #H elim H -L -T -U
+// /2 width=1/ /2 width=2/ /2 width=3/ /2 width=6/
+qed-.
+
+(* Properties on relocation *************************************************)
+
+lemma ntaa_lift: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 :: U1 → ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
+                 ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 → ⦃h, L2⦄ ⊢ T2 :: U2.
+#h #L1 #T1 #U1 #H elim H -L1 -T1 -U1
+[ #L1 #k #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  >(lift_inv_sort1 … H1) -X1
+  >(lift_inv_sort1 … H2) -X2 //
+| #L1 #K1 #V1 #W1 #W #i #HLK1 #_ #HW1 #IHVW1 #L2 #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // #W2 #HW12 #HWU2
+    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
+    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
+    /3 width=8/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
+    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
+  ]
+| #L1 #K1 #W1 #V1 #W #i #HLK1 #_ #HW1 #IHWV1 #L2 #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // <minus_plus #W #HW1 #HWU2
+    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
+    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
+    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
+    elim (lift_total V1 (d-i-1) e) /3 width=8/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
+    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct
+  elim (lift_total W1 d e) /4 width=6/
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #V2 #X #HV12 #H1 #H destruct
+  elim (lift_inv_bind1 … H1) -H1 #W2 #T2 #HW12 #HT12 #H destruct
+  elim (lift_inv_flat1 … H2) -H2 #Y2 #X #HY #H2 #H destruct
+  elim (lift_inv_bind1 … H2) -H2 #X2 #U2 #HX #HU12 #H destruct
+  lapply (lift_mono … HY … HV12) -HY #H destruct
+  lapply (lift_mono … HX … HW12) -HX #H destruct /4 width=6/
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct
+  elim (lift_total W1 d e) /4 width=6/
+| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X #H #U2 #HU12
+  elim (lift_inv_flat1 … H) -H #X2 #T2 #HUX2 #HT12 #H destruct
+  lapply (lift_mono … HUX2 … HU12) -HUX2 #H destruct
+  elim (lift_total W1 d e) /3 width=6/
+| #L1 #T1 #U11 #U12 #V12 #_ #HU112 #_ #IHTU11 #IHUV12 #L2 #d #e #HL21 #U1 #HTU1 #U2 #HU12
+  elim (lift_total U11 d e) #U #HU11
+  elim (lift_total V12 d e) #V22 #HV122
+  lapply (cpcs_lift … HL21 … HU11 … HU12 HU112) -HU112 /3 width=6/
+]
+qed.
+
+(* Advanced forvard lemmas **************************************************)
+
+lemma ntaa_fwd_correct: ∀h,L,T,U. ⦃h, L⦄ ⊢ T :: U → ∃T0. ⦃h, L⦄ ⊢ U :: T0.
+#h #L #T #U #H elim H -L -T -U
+[ /2 width=2/
+| #L #K #V #W #W0 #i #HLK #_ #HW0 * #V0 #HWV0
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  elim (lift_total V0 0 (i+1)) /3 width=10/
+| #L #K #W #V #V0 #i #HLK #HWV #HWV0 #_
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  elim (lift_total V 0 (i+1)) /3 width=10/
+| #I #L #V #W #T #U #HVW #_ #_ * /3 width=2/
+| #L #V #W #T #U #HVW #_ #_ * #X #H
+  elim (ntaa_inv_bind1 … H) -H /4 width=2/
+| #L #V #W #T #U #_ #HUW * #T0 #HUT0 /3 width=2/
+| /2 width=2/
+| /2 width=2/
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma nta_ntaa: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ T :: U.
+#h #L #T #U #H elim H -L -T -U
+// /2 width=1/ /2 width=2/ /2 width=3/ /2 width=6/
+#L #T #U #_ #HTU
+elim (ntaa_fwd_correct … HTU) /2 width=2/
+qed.
+
+(* Advanced eliminators *****************************************************)
+
+lemma nta_ind_alt: ∀h. ∀R:lenv→relation term.
+   (∀L,k. R L ⋆k ⋆(next h k)) →
+   (∀L,K,V,W,U,i.
+      ⇩[O, i] L ≡ K.ⓓV → ⦃h, K⦄ ⊢ V : W → ⇧[O, i + 1] W ≡ U →
+      R K V W → R L (#i) U 
+   ) →
+   (∀L,K,W,V,U,i.
+      ⇩[O, i] L ≡ K.ⓛW → ⦃h, K⦄ ⊢ W : V → ⇧[O, i + 1] W ≡ U →
+      R K W V → R L (#i) U
+   ) →
+   (∀I,L,V,W,T,U.
+      ⦃h, L⦄ ⊢ V : W → ⦃h, L.ⓑ{I}V⦄ ⊢ T : U →
+      R L V W → R (L.ⓑ{I}V) T U → R L (ⓑ{I}V.T) (ⓑ{I}V.U)
+   ) →
+   (∀L,V,W,T,U.
+      ⦃h, L⦄ ⊢ V : W → ⦃h, L⦄ ⊢ (ⓛW.T):(ⓛW.U) →
+      R L V W →R L (ⓛW.T) (ⓛW.U) →R L (ⓐV.ⓛW.T) (ⓐV.ⓛW.U)
+   ) →
+   (∀L,V,W,T,U.
+      ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ (ⓐV.U) : W →
+      R L T U → R L (ⓐV.U) W → R L (ⓐV.T) (ⓐV.U)
+   ) →
+   (∀L,T,U,W.
+      ⦃h, L⦄ ⊢ T : U → ⦃h, L⦄ ⊢ U : W →
+      R L T U → R L U W → R L (ⓝU.T) U
+   ) →
+   (∀L,T,U1,U2,V2.
+      ⦃h, L⦄ ⊢ T : U1 → L ⊢ U1 ⬌* U2 → ⦃h, L⦄ ⊢ U2 : V2 →
+      R L T U1 →R L U2 V2 →R L T U2
+   ) →
+   ∀L,T,U. ⦃h, L⦄ ⊢ T : U → R L T U.
+#h #R #H1 #H2 #H3 #H4 #H5 #H6 #H7 #H8 #L #T #U #H elim (nta_ntaa … H) -L -T -U
+// /3 width=1 by ntaa_nta/ /3 width=3 by ntaa_nta/ /3 width=4 by ntaa_nta/
+/3 width=7 by ntaa_nta/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_lift.etc
new file mode 100644 (file)
index 0000000..57e06a1
--- /dev/null
@@ -0,0 +1,144 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/nta_alt.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+fact nta_inv_sort1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀k0. T = ⋆k0 →
+                        L ⊢ ⋆(next h k0) ⬌* U.
+#h #L #T #U #H elim H -L -T -U
+[ #L #k #k0 #H destruct //
+| #L #K #V #W #U #i #_ #_ #_ #_ #k0 #H destruct
+| #L #K #W #V #U #i #_ #_ #_ #_ #k0 #H destruct
+| #I #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #k0 #H destruct
+| #L #T #U #_ #_ #k0 #H destruct
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #k0 #H destruct
+  lapply (IHTU1 ??) -IHTU1 [ // | skip ] #Hk0
+  lapply (cpcs_trans … Hk0 … HU12) -U1 //
+]
+qed.
+
+(* Basic_1: was: ty3_gen_sort *)
+lemma nta_inv_sort1: ∀h,L,U,k. ⦃h, L⦄ ⊢ ⋆k : U → L ⊢ ⋆(next h k) ⬌* U.
+/2 width=3/ qed-.
+
+fact nta_inv_lref1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀j. T = #j →
+                        (∃∃K,V,W,U0. ⇩[0, j] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V : W &
+                                     ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                        ) ∨
+                        (∃∃K,W,V,U0. ⇩[0, j] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W : V &
+                                     ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                        ).
+#h #L #T #U #H elim H -L -T -U
+[ #L #k #j #H destruct
+| #L #K #V #W #U #i #HLK #HVW #HWU #_ #j #H destruct /3 width=8/
+| #L #K #W #V #U #i #HLK #HWV #HWU #_ #j #H destruct /3 width=8/
+| #I #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #j #H destruct
+| #L #T #U #_ #_ #j #H destruct
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #j #H destruct
+  elim (IHTU1 ??) -IHTU1 [4: // |2: skip ] * #K #V #W #U0 #HLK #HVW #HWU0 #HU01
+  lapply (cpcs_trans … HU01 … HU12) -U1 /3 width=8/
+]
+qed.
+
+(* Basic_1: was ty3_gen_lref *)
+lemma nta_inv_lref1: ∀h,L,U,i. ⦃h, L⦄ ⊢ #i : U →
+                     (∃∃K,V,W,U0. ⇩[0, i] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V : W &
+                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                     ) ∨
+                     (∃∃K,W,V,U0. ⇩[0, i] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W : V &
+                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                     ).
+/2 width=3/ qed-.
+
+(* Basic_1: was: ty3_gen_bind *)
+lemma nta_inv_bind1: ∀h,I,L,Y,X,U. ⦃h, L⦄ ⊢ ⓑ{I}Y.X : U →
+                     ∃∃Z1,Z2. ⦃h, L⦄ ⊢ Y : Z1 & ⦃h, L.ⓑ{I}Y⦄ ⊢ X : Z2 &
+                              L ⊢ ⓑ{I}Y.Z2 ⬌* U.
+#h #I #L #Y #X #U #H
+elim (ntaa_inv_bind1 … (nta_ntaa … H)) -H /3 width=3 by ntaa_nta, ex3_2_intro/
+qed-.
+
+fact nta_inv_cast1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. T = ⓝY.X →
+                     ⦃h, L⦄ ⊢ X : Y ∧ L ⊢ Y ⬌* U.
+#h #L #T #U #H elim H -L -T -U
+[ #L #k #X #Y #H destruct
+| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
+| #L #T #U #HTU #_ #X #Y #H destruct /2 width=1/
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
+  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #HXY #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=1/
+]
+qed.
+
+(* Basic_1: was: ty3_gen_cast *)
+lemma nta_inv_cast1: ∀h,L,X,Y,U. ⦃h, L⦄ ⊢ ⓝY.X : U →  ⦃h, L⦄ ⊢ X : Y ∧ L ⊢ Y ⬌* U.
+/2 width=3/ qed-.
+
+(* Advanced forvard lemmas **************************************************)
+
+fact nta_fwd_pure1_aux: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. T = ⓐY.X →
+                        ∃∃V,W. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V & L ⊢ ⓐY.V ⬌* U.
+#h #L #T #U #H elim H -L -T -U
+[ #L #k #X #Y #H destruct
+| #L #K #V #W #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #L #K #W #V #U #i #_ #_ #_ #_ #X #Y #H destruct
+| #I #L #V #W #T #U #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W #T #U #HVW #HTU #_ #_ #X #Y #H destruct /2 width=3/
+| #L #V #W #T #U #HTU #_ #_ #IHUW #X #Y #H destruct
+  elim (IHUW U Y ?) -IHUW // /2 width=3/
+| #L #T #U #_ #_ #X #Y #H destruct
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
+  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #V #W #HYW #HXV #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
+]
+qed.
+
+lemma nta_fwd_pure1: ∀h,L,X,Y,U. ⦃h, L⦄ ⊢ ⓐY.X : U →
+                     ∃∃V,W. ⦃h, L⦄ ⊢ Y : W & ⦃h, L⦄ ⊢ X : V & L ⊢ ⓐY.V ⬌* U.
+/2 width=3/ qed-.
+
+(* Basic_1: was: ty3_correct *)
+lemma nta_fwd_correct: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∃T0. ⦃h, L⦄ ⊢ U : T0.
+#h #L #T #U #H
+elim (ntaa_fwd_correct … (nta_ntaa … H)) -H /3 width=2 by ntaa_nta, ex_intro/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+(* Basic_1: was: ty3_appl *)
+lemma nta_appl_old: ∀h,L,V,W,T,U. ⦃h, L⦄ ⊢ V : W → ⦃h, L⦄ ⊢ T : ⓛW.U →
+                    ⦃h, L⦄ ⊢ ⓐV.T : ⓐV.ⓛW.U.
+#h #L #V #W #T #U #HVW #HTU
+elim (nta_fwd_correct … HTU) #X #H
+elim (nta_inv_bind1 … H) -H /4 width=2/
+qed.
+
+(* Properties on relocation *************************************************)
+
+(* Basic_1: was: ty3_lift *)
+lemma nta_lift: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 → ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
+                ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 → ⦃h, L2⦄ ⊢ T2 : U2.
+/4 width=9 by ntaa_nta, nta_ntaa, ntaa_lift/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpr.etc
new file mode 100644 (file)
index 0000000..c461e9f
--- /dev/null
@@ -0,0 +1,235 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_delift.ma".
+include "basic_2/dynamic/nta.ma".
+(*
+lemma pippo: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U → ∀X,Y. L ⊢ T ➡* ⓛX.Y →
+             ∃Z. L ⊢ U ➡* ⓛX.Z.
+#h #L #T #U #H elim H -L -T -U
+[
+|
+|
+|
+| #L #V #W #T #U #_ #_ #IHVW #IHTU #X #Y #H  
+| #L #V #W #T #U #_ #HUW #IHTU #IHUW #X #Y #HTY
+  elim (cprs_inv_appl_abst … HTY) -HTY #W1 #T1 #W2 #T2 #HT1 #HT12 #HYT2
+  elim (IHTU … HT1) -IHTU -HT1 #U1 #HU1 
+  
+  
+   *
+  [ #V0 #T0 #_ #_ #H destruct
+  | #V0 #W0 #T0 #HV0 #HT0 #HTY
+    elim (IHTU … HT0) -IHTU -HT0 #Z #HUZ
+    elim (cprs_inv_abbr1 … HTY) -HTY *
+    [ #V1 #T1 #_ #_ #H destruct #X0  
+
+*)
+
+(*
+
+include "basic_2/computation/cprs_lcprs.ma".
+
+
+
+
+include "basic_2/dynamic/nta_ltpss.ma".
+include "basic_2/dynamic/nta_thin.ma".
+include "basic_2/dynamic/lsubn_nta.ma".
+
+include "basic_2/hod/ntas_lift.ma".
+
+  
+  elim (nta_inv_pure1 … HUW) -HUW #V0 #U0 #U1 #HV0 #HU0 #HU0W #HU01
+  @(ex2_2_intro … HYW)
+  [2: 
+
+
+axiom pippo_aux: ∀h,L,Z,U. ⦃h, L⦄ ⊢ Z : U → ∀Y,X. Z = ⓐY.X →
+                 ∀W,T. L ⊢ X ➡* ⓛW.T → ⦃h, L⦄ ⊢ Y : W.
+#h #L #Z #U #H elim H -L -Z -U
+[
+|
+|
+|
+|
+| #L #V #W #T #U #HTU #_ #_ #IHUW #Y #X #H #W0 #T0 #HX destruct 
+  lapply (IHUW Y U ? ?) -IHUW -W // #T 
+  @(ex2_2_intro … HYW)
+  [2: 
+
+axiom pippo: ∀h,L,V,X,U. ⦃h, L⦄ ⊢ ⓐV.X : U →
+             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ V : W.
+#h #L #V #X #Y #H 
+
+*)
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties on context-free parallel reduction for local environments ******)
+(*
+axiom nta_ltpr_cprs_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
+                          ∀T2. L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 : U.
+#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
+[ #L1 #k #L2 #_ #T2 #H
+  >(cprs_inv_sort1 … H) -H //
+|
+|
+|
+|
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #HL12 #T2 #H
+  elim (cprs_inv_appl1 … H) -H *
+  [ #V2 #T0 #HV12 #HT10 #H destruct
+    elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=2/ ] #U
+    @(nta_conv … (ⓐV2.U1)) (* /2 width=1/*) [ /4 width=2/] (**) (* explicit constructor, /5 width=5/ is too slow *)
+  | #V2 #W2 #T0 #HV12 #HT10 #HT02
+    lapply (IHTU1 … HL12 (ⓛW2.T0) ?) -IHTU1 /2 width=1/ -HT10 #H
+    elim (nta_inv_bind1 … H) -H #W #U0 #HW2 #HTU0 #HU01
+    elim (cpcs_inv_abst1 … HU01) -HU01 #W #U #HU1 #HU0
+    lapply (IHUW1 … HL12 (ⓐV2.ⓛW.U) ?) -IHUW1 -HL12 /2 width=1/ -HV12 #H
+    
+    
+    
+    elim (nta_fwd_pure1 … H) -H #W0 #U2 #HVU2 #H #HW01
+    elim (nta_inv_bind1 … H) -H #W3 #U3 #HW3 #HU3 #H
+    elim (cpcs_inv_abst1 … H) -H #W4 #U4  
+*)      
+(*
+axiom nta_ltpr_tpr_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
+                         ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
+#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
+[ #L1 #k #L2 #_ #T2 #H
+  >(tpr_inv_atom1 … H) -H //
+| #L1 #K1 #V1 #W #U #i #HLK1 #_ #HWU #IHV1 #L2 #HL12 #T2 #H
+  >(tpr_inv_atom1 … H) -T2
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
+  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
+| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #HL12 #T2 #H
+  >(tpr_inv_atom1 … H) -T2
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
+  elim (ltpr_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
+  lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+  elim (lift_total V1 0 (i+1)) #W #HW
+  lapply (nta_lift h … HLK … HWU1 … HW) /2 width=1/ -HLK -HW
+  elim (lift_total W2 0 (i+1)) #U2 #HWU2
+  lapply (tpr_lift … HW12 … HWU1 … HWU2) -HWU1 #HU12
+  @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /3 width=6/ is too slow *)
+| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H
+  elim (tpr_inv_bind1 … H) -H *
+  [ #V2 #T0 #T2 #HV12 #HT10 #HT02 #H destruct
+    lapply (IHVW1 … HL12 … HV12) #HV2W1
+    lapply (IHVW1 L2 … V1 ?) // -IHVW1 #HWV1
+    lapply (IHTU1 (L2.ⓑ{I}V2) … HT10) -HT10 /2 width=1/ #HT0U1
+    lapply (IHTU1 (L2.ⓑ{I}V1) ? T1 ?) -IHTU1 // /2 width=1/ -HL12 #H
+    lapply (tps_lsubs_trans … HT02 (L2.ⓑ{I}V2) ?) -HT02 /2 width=1/ #HT02
+    lapply (nta_tps_conf … HT0U1 … HT02) -T0 #HT2U1
+    elim (nta_fwd_correct … H) -H #U2 #HU12
+    @(nta_conv … (ⓑ{I}V2.U1)) /2 width=2/ /3 width=1/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+  | #T #HT1 #HTX #H destruct
+    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HVW1
+    elim (lift_total X 0 1) #Y #HXY
+    lapply (tpr_lift … HTX … HT1 … HXY) -T #H
+    lapply (IHTU1 (L2.ⓓV1) … H) -T1 /2 width=1/ -L1 #H
+    elim (nta_fwd_correct … H) #T1 #HUT1
+    elim (nta_thin_conf … H L2 0 (0+1) ? ?) -H /2 width=1/ /3 width=1/ #T #U #HTU #H
+    normalize in ⊢ (??%??? → ?); #HU1
+    lapply (delift_inv_lift1_eq … H L2 … HXY) -Y /2 width=1/ #H destruct
+    @(nta_conv … U) // /2 width=2/
+  ]
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H
+  elim (tpr_inv_appl1 … H) -H *
+  [ #V2 #Y #HV12 #HY #H destruct
+    elim (tpr_inv_abst1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
+    lapply (IHTU1 L2 ? (ⓛW1.T1) ?) // #H
+    elim (nta_fwd_correct … H) -H #X #H
+    elim (nta_inv_bind1 … H) -H #W #U #HW #HU #_
+    @(nta_conv … (ⓐV2.ⓛW1.U1)) /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
+    lapply (IHVW1 … HL12 … HV12) #HVW2
+    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HV1W2
+    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 -HL12 /2 width=1/ -HT02 #H1
+    elim (nta_fwd_correct … H1) #T #H2
+    elim (nta_inv_bind1 … H1) -H1 #W #U2 #HW2 #HTU2 #H
+    elim (cpcs_inv_abst … H Abst W2) -H #_ #HU21
+    elim (nta_inv_bind1 … H2) -H2 #W0 #U0 #_ #H #_ -T -W0
+    lapply (lsubn_nta_trans … HTU2 (L2.ⓓV2) ?) -HTU2 /2 width=1/ #HTU2
+    @(nta_conv … (ⓓV2.U2)) /2 width=2/ /3 width=2/ (**) (* explicit constructor, /4 width=5/ is too slow *)
+  | #V0 #V2 #W0 #W2 #T0 #T2 #_ #_ #_ #_ #H destruct
+  ]
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #HL12 #X #H
+  elim (tpr_inv_appl1 … H) -H *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=2/ ] #U
+    @(nta_conv … (ⓐV2.U1)) /2 width=1/ /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
+    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 /2 width=1/ -T0 #H
+    elim (nta_inv_bind1 … H) -H #W #U2 #HW2 #HTU2 #HU21
+    lapply (IHUW1 … HL12 (ⓐV2.U1) ?) -IHUW1 -HL12 /2 width=1/ #H
+    elim (nta_inv_pure1 … H) -H #V0 #U0 #U #HV20 #HU10 #HU0W1 #HU0
+    @(nta_conv … (ⓓV2.U2))
+    [2: @nta_bind //
+        @(lsubn_nta_trans … HTU2) @lsubn_abbr //
+(*
+    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HB
+    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
+    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 /width=5/ -T0 /2 width=1/ -L1 -V1 /4 width=7/
+*)
+*)
+(*
+axiom pippo: ⦃h, L⦄ ⊢ ⓐV.X : Y →
+             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ ⓐV : W.
+
+*)
+(* SEGMENT 2
+| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
+  lapply (cpr_tpss … HU12) /4 width=4/
+| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
+  @(nta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
+]
+qed.
+*)
+
+(* SEGMENT 3
+fact nta_ltpr_tpr_conf_aux: ∀h,L,T,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → L = L1 → T = T1 →
+                            ∀L2. L1 ➡ L2 → ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
+  
+  
+  | #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
+    elim (nta_inv_abbr … HT1) -HT1 #B0 #HW0 #HT0
+    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
+    lapply (IH … HV1 … HL12 … HV10) -HV1 -HV10 /width=5/ #HV0
+    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 /width=5/ -V1 -T0 /2 width=1/ -L1 -W0 #HT2
+    @(nta_abbr … HW2) -HW2
+    @(nta_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
+  ]
+| #L1 #V1 #T1 #A #HV1 #HT1 #H1 #H2 #L2 #HL12 #X #H destruct
+  elim (tpr_inv_cast1 … H) -H
+  [ * #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
+    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
+  | -HV1 #HT1X
+     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
+  ]
+]
+qed.
+
+/2 width=9/ qed.
+
+axiom nta_ltpr_conf: ∀L1,T,A. L1 ⊢ T : A → ∀L2. L1 ➡ L2 → L2 ⊢ T : A.
+/2 width=5/ qed.
+
+axiom nta_tpr_conf: ∀L,T1,A. L ⊢ T1 : A → ∀T2. T1 ➡ T2 → L ⊢ T2 : A.
+/2 width=5/ qed.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_ltpss.etc
new file mode 100644 (file)
index 0000000..828fd82
--- /dev/null
@@ -0,0 +1,121 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_ltpss.ma".
+include "basic_2/dynamic/nta_nta.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties about parallel unfold *****************************************)
+
+lemma nta_ltpss_tpss_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U →
+                           ∀L2,d,e. L1 ▶* [d, e] L2 →
+                           ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 : U.
+#h #L1 #T1 #U #H @(nta_ind_alt … H) -L1 -T1 -U
+[ #L1 #k #L2 #d #e #_ #T2 #H
+  >(tpss_inv_sort1 … H) -H //
+| #L1 #K1 #V1 #W #U #i #HLK1 #_ #HWU #IHV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
+      /3 width=7/
+    | elim (lt_or_ge i (d + e)) #Hide [ | -Hdi ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
+        /3 width=7/
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=7/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=9/
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
+  [ #H destruct
+    elim (lift_total V1 0 (i+1)) #W #HW
+    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #W2 #HK12 #HW12 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+      lapply (nta_lift h … HLK … HWU1 … HW) /2 width=4/ -HW
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
+      lapply (cpr_tpss … HU12) -HU12 #HU12
+      @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -HW -Hdi ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #W2 #HK12 #HW12 #H destruct
+        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+        lapply (nta_lift h … HLK … HWU1 … HW) /2 width=4/ -HW
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
+        lapply (cpr_tpss … HU12) -HU12 #HU12
+        @(nta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HV
+  lapply (IHTU1 (L2.ⓑ{I}V1) (d+1) e ? T1 ?) // /2 width=1/ #H
+  elim (nta_fwd_correct … H) -H #U2 #HU12
+  @(nta_conv … (ⓑ{I}V2.U1)) /3 width=2/ /3 width=4/ /4 width=4/ (**) (* explicit constructor, /5 width=6/ is too slow *)
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
+  elim (tpss_inv_bind1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HV
+  lapply (IHTU1 L2 d e ? (ⓛW1.T1) ?) // #H
+  elim (nta_fwd_correct … H) -H #X #H
+  elim (nta_inv_bind1 … H) -H #W #U #HW #HU #_
+  @(nta_conv … (ⓐV2.ⓛW1.U1)) /3 width=2/ /3 width=4/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HV
+  elim (nta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) ?) [2: /3 width=4/ ] #U #HU
+  @(nta_conv … (ⓐV2.U1)) // /3 width=1/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
+  lapply (cpr_tpss … HU12) /4 width=4/
+| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
+  @(nta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
+]
+qed.
+
+lemma nta_ltpss_tps_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U →
+                          ∀L2,d,e. L1 ▶* [d, e] L2 →
+                          ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → ⦃h, L2⦄ ⊢ T2 : U.
+/3 width=7/ qed.
+
+lemma nta_ltpss_conf: ∀h,L1,T,U. ⦃h, L1⦄ ⊢ T : U →
+                      ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T : U.
+/2 width=7/ qed.
+
+lemma nta_tpss_conf: ∀h,L,T1,U. ⦃h, L⦄ ⊢ T1 : U →
+                     ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 : U.
+/2 width=7/ qed.
+
+lemma nta_tps_conf: ∀h,L,T1,U. ⦃h, L⦄ ⊢ T1 : U →
+                    ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 : U.
+/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_nta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_nta.etc
new file mode 100644 (file)
index 0000000..05eb6c5
--- /dev/null
@@ -0,0 +1,59 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/nta_lift.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: ty3_unique *)
+theorem nta_mono: ∀h,L,T,U1. ⦃h, L⦄ ⊢ T : U1 → ∀U2. ⦃h, L⦄ ⊢ T : U2 →
+                  L ⊢ U1 ⬌* U2.
+#h #L #T #U1 #H elim H -L -T -U1
+[ #L #k #X #H
+  lapply (nta_inv_sort1 … H) -H //
+| #L #K #V #W11 #W12 #i #HLK #_ #HW112 #IHVW11 #X #H
+  elim (nta_inv_lref1 … H) -H * #K0 #V0 #W21 #W22 #HLK0 #HVW21 #HW212 #HX
+  lapply (ldrop_mono … HLK0 … HLK) -HLK0 #H destruct
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  @(cpcs_trans … HX) -X /3 width=9 by cpcs_lift/ (**) (* to slow without trace *)
+| #L #K #W #V1 #V #i #HLK #_ #HWV #_ #X #H
+  elim (nta_inv_lref1 … H) -H * #K0 #W0 #V2 #V0 #HLK0 #_ #HWV0 #HX
+  lapply (ldrop_mono … HLK0 … HLK) -HLK0 -HLK #H destruct
+  lapply (lift_mono … HWV0 … HWV) -HWV0 -HWV #H destruct //
+| #I #L #V #W1 #T #U1 #_ #_ #_ #IHTU1 #X #H
+  elim (nta_inv_bind1 … H) -H #W2 #U2 #_ #HTU2 #H
+  @(cpcs_trans … H) -X /3 width=1/
+| #L #V #W1 #T #U1 #_ #_ #_ #IHTU1 #X #H
+  elim (nta_fwd_pure1 … H) -H #U2 #W2 #_ #HTU2 #H
+  @(cpcs_trans … H) -X /3 width=1/
+| #L #V #W1 #T #U1 #_ #_ #IHTU1 #_ #X #H
+  elim (nta_fwd_pure1 … H) -H #U2 #W2 #_ #HTU2 #H
+  @(cpcs_trans … H) -X /3 width=1/
+| #L #T #U1 #_ #_ #X #H
+  elim (nta_inv_cast1 … H) -H //
+| #L #T #U11 #U12 #V12 #_ #HU112 #_ #IHTU11 #_ #U2 #HTU2
+  @(cpcs_canc_sn … HU112) -U12 /2 width=1/
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma nta_cast_alt: ∀h,L,T,W,U. ⦃h, L⦄ ⊢ T : W → ⦃h, L⦄ ⊢ T : U →
+             ⦃h, L⦄ ⊢ ⓝW.T : U.
+#h #L #T #W #U #HTW #HTU
+lapply (nta_mono … HTW … HTU) #HWU
+elim (nta_fwd_correct … HTU) -HTU /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_sta.etc
new file mode 100644 (file)
index 0000000..6268b98
--- /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/static/sta.ma".
+include "basic_2/equivalence/cpcs_cpcs.ma".
+include "basic_2/dynamic/nta.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties on static type assignment *************************************)
+
+lemma nta_fwd_sta: ∀h,L,T,U. ⦃h, L⦄ ⊢ T : U →
+                   ∃∃U0. ⦃h, L⦄ ⊢ T • U0 & L ⊢ U0 ⬌* U.
+#h #L #T #U #H elim H -L -T -U
+[ /2 width=3/
+| #L #K #V #W1 #V1 #i #HLK #_ #HWV1 * #W0 #HVW0 #HW01
+  elim (lift_total W0 0 (i+1)) #V0 #HWV0
+  lapply (ldrop_fwd_ldrop2 … HLK) #HLK0
+  lapply (cpcs_lift … HLK0 … HWV0 … HWV1 HW01) -HLK0 -HWV1 -HW01 /3 width=6/
+| #L #K #W #V1 #W1 #i #HLK #HWV1 #HW1 * /3 width=6/
+| #I #L #V #W #T #U #_ #_ * #W0 #_ #_ * /3 width=3/
+| #L #V #W #T #U #_ #_ * #W0 #_ #HW0 * #X #H #HX
+  elim (sta_inv_bind1 … H) -H #U0 #HTU0 #H destruct
+  @(ex2_1_intro … (ⓐV.ⓛW.U0)) /2 width=1/ /3 width=1/
+| #L #V #W #T #U #_ #_ * #U0 #HTU0 #HU0 #_ -W
+  @(ex2_1_intro … (ⓐV.U0)) /2 width=1/
+| #L #T #U #HTU * #U0 #HTU0 #HU0 /3 width=3/
+| #L #T #U1 #U2 #V2 #_ #HU12 #_ * #U0 #HTU0 #HU01 #_
+  lapply (cpcs_trans … HU01 … HU12) -U1 /2 width=3/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/nta/nta_thin.etc
new file mode 100644 (file)
index 0000000..f927f84
--- /dev/null
@@ -0,0 +1,116 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/thin_ldrop.ma".
+include "basic_2/equivalence/cpcs_delift.ma".
+include "basic_2/dynamic/nta_lift.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties on basic local environment thinning ***************************)
+
+(* Note: this is known as the substitution lemma *)
+(* Basic_1: was only: ty3_gen_cabbr *)
+lemma nta_thin_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 →
+                     ∀L2,d,e. ≽ [d, e] L1 → L1 ▼*[d, e] ≡ L2 →
+                     ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 : U2 &
+                              L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
+#h #L1 #T1 #U1 #H elim H -L1 -T1 -U1
+[ /2 width=5/
+| #L1 #K1 #V1 #W1 #U1 #i #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL1 #HL12
+  elim (lt_or_ge i d) #Hdi [ -HVW1 ]
+  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
+    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
+    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
+    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+    elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #X2 #W2 #HVW2 #H #HW12
+    lapply (delift_mono … H … HV12) -H -HV12 #H destruct
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (ldrop_fwd_ldrop2 … HLK1) -V1 #HLK1
+    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
+    >minus_plus <plus_minus_m_m // /3 width=6/
+  | elim (lt_or_ge i (d+e)) #Hide [ -HVW1 | -Hdi -IHVW1 -HL1 ]
+    [ lapply (sfr_ldrop_trans_be_up … HLK1 … HL1 ? ?) -HL1 // /2 width=2/ <minus_n_O #H
+      elim (sfr_inv_bind … H ?) -H /2 width=1/ #HK1 #_
+      elim (thin_ldrop_conf_be … HL12 … HLK1 ? ?) -HL12 /2 width=2/ #K2 #H #HLK2
+      lapply (thin_inv_thin1 … H ?) -H /2 width=1/ #HK12
+      elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #V2 #W2 #HVW2 #HV12 #HW12
+      elim (lift_total V2 0 d) #T2 #HVT2
+      elim (lift_total W2 0 d) #U2 #HWU2
+      elim (lift_total W2 0 (i+1)) #U #HW2U
+      lapply (nta_lift … HVW2 … HLK2 … HVT2 … HWU2) -HVW2 -HLK2 #HTU2
+      lapply (ldrop_fwd_ldrop2 … HLK1) #HLK0
+      lapply (delift_lift_ge … HW12 … HLK0 HWU1 … HW2U) -HW12 -HLK0 -HWU1 // >minus_plus #HU1
+      lapply (lift_conf_be … HWU2 … HW2U ?) -W2 /2 width=1/ #HU2
+      lapply (delift_lift_div_be … HU1 … HU2 ? ?) -U // /2 width=1/ /3 width=8/
+    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
+      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
+      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
+      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
+      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
+    ]
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL1 #HL12
+  elim (lt_or_ge i d) #Hdi [ -HWV1 | -IHWV1 ]
+  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
+    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
+    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
+    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHWV1 … HK1 HK12) -IHWV1 -HK1 -HK12 #X2 #V2 #HWV2 #H #_
+    lapply (delift_mono … H … HW12) -H #H destruct
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
+    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
+    >minus_plus <plus_minus_m_m // /3 width=6/
+  | elim (lt_or_ge i (d+e)) #Hide [ -HWV1 -HWU1 -HL12 | -Hdi -HL1 ]
+    [ lapply (sfr_inv_ldrop … HLK1 … HL1 ? ?) -HLK1 -HL1 // -Hdi -Hide #H destruct 
+    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
+      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
+      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
+      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
+      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
+    ]
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
+  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #_
+  elim (IHTU1 (L2.ⓑ{I}V2) (d+1) e ? ?) -IHTU1 /2 width=1/ -HL1 -HL12 #T2 #U2 #HTU2 #HT12 #HU12
+  lapply (delift_lsubs_trans … HT12 (L1.ⓑ{I}V2) ?) -HT12 /2 width=1/
+  lapply (delift_lsubs_trans … HU12 (L1.ⓑ{I}V2) ?) -HU12 /2 width=1/ /3 width=7/
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
+  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #HW12
+  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 #X2 #Y2 #HXY2 #HX2 #HY2
+  elim (delift_inv_bind1 … HX2) -HX2 #Z21 #T2 #HZ21 #HT12 #H destruct
+  elim (delift_inv_bind1 … HY2) -HY2 #Z22 #U2 #HZ22 #HU12 #H destruct
+  lapply (delift_mono … HZ21 … HW12) -HZ21 #H destruct
+  lapply (delift_mono … HZ22 … HW12) -HZ22 #H destruct
+  @(ex3_2_intro … (ⓐV2.ⓛW2.T2) (ⓐV2.ⓛW2.U2)) /3 width=1/ (**) (* explict constructor, /4 depth=?/ is too slow *)
+| #L1 #V1 #W1 #T1 #U1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
+  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
+  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #X2 #W2 #HXW2 #H #HW12
+  elim (delift_inv_flat1 … H) -H #V2 #Y2 #HV12 #HY2 #H destruct
+  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=7/
+| #L1 #T1 #U1 #_ #IHTU1 #L2 #d #e #HL1 #HL12
+  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 /3 width=5/
+| #L1 #T1 #U11 #U12 #V1 #_ #HU112 #_ #IHT1 #IHU12 #L2 #d #e #HL1 #HL12
+  elim (IHT1 … HL1 HL12) -IHT1 #T2 #U21 #HT2 #HT12 #HU121
+  elim (IHU12 … HL1 HL12) -IHU12 -HL1 #U22 #V2 #HU22 #HU122 #_
+  lapply (thin_cpcs_delift_mono … HU112 … HL12 … HU121 … HU122) -HU112 -HL12 -HU121 /3 width=5/
+]
+qed.
+
+lemma nta_ldrop_conf: ∀h,L1,T1,U1. ⦃h, L1⦄ ⊢ T1 : U1 →
+                      ∀L2,d,e. ≽ [d, e] L1 → ⇩[d, e] L1 ≡ L2 →
+                      ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 : U2 &
+                               L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
+/3 width=1/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn.etc
new file mode 100644 (file)
index 0000000..f6b5450
--- /dev/null
@@ -0,0 +1,110 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( h ⊢ break term 46 L1 : ⊑ [ ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'StratifiedCrSubEqN $h $L1 $L2 }.
+
+include "basic_2/dynamic/snta.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
+
+(* Note: may not be transitive *)
+inductive lsubsn (h:sh): relation lenv ≝
+| lsubsn_atom: lsubsn h (⋆) (⋆)
+| lsubsn_pair: ∀I,L1,L2,W. lsubsn h L1 L2 →
+               lsubsn h (L1. ⓑ{I} W) (L2. ⓑ{I} W)
+| lsubsn_abbr: ∀L1,L2,V,W,l. ⦃h, L1⦄ ⊢ V :[l+1] W → ⦃h, L2⦄ ⊢ V :[l+1] W →
+               lsubsn h L1 L2 → lsubsn h (L1. ⓓV) (L2. ⓛW)
+.
+
+interpretation
+  "local environment refinement (stratified native type assigment)"
+  'StratifiedCrSubEqN h L1 L2 = (lsubsn h L1 L2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact lsubsn_inv_atom1_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 = ⋆ → L2 = ⋆.
+#h #L1 #L2 * -L1 -L2
+[ //
+| #I #L1 #L2 #V #_ #H destruct
+| #L1 #L2 #V #W #l #_ #_ #_ #H destruct
+]
+qed.
+
+lemma lsubsn_inv_atom1: ∀h,L2. h ⊢ ⋆ :⊑[] L2 → L2 = ⋆.
+/2 width=5/ qed-.
+
+fact lsubsn_inv_pair1_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                           ∀I,K1,V. L1 = K1. ⓑ{I} V →
+                           (∃∃K2. h ⊢ K1 :⊑[] K2 & L2 = K2. ⓑ{I} V) ∨
+                           ∃∃K2,W,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
+                                     h ⊢ K1 :⊑[] K2 & L2 = K2. ⓛW & I = Abbr.
+#h #L1 #L2 * -L1 -L2
+[ #I #K1 #V #H destruct
+| #J #L1 #L2 #V #HL12 #I #K1 #W #H destruct /3 width=3/
+| #L1 #L2 #V #W #l #H1VW #H2VW #HL12 #I #K1 #V1 #H destruct /3 width=7/
+]
+qed.
+
+lemma lsubsn_inv_pair1: ∀h,I,K1,L2,V. h ⊢ K1. ⓑ{I} V :⊑[] L2 →
+                        (∃∃K2. h ⊢ K1 :⊑[] K2 & L2 = K2. ⓑ{I} V) ∨
+                        ∃∃K2,W,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
+                                  h ⊢ K1 :⊑[] K2 & L2 = K2. ⓛW & I = Abbr.
+/2 width=3/ qed-.
+
+fact lsubsn_inv_atom2_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L2 = ⋆ → L1 = ⋆.
+#h #L1 #L2 * -L1 -L2
+[ //
+| #I #L1 #L2 #V #_ #H destruct
+| #L1 #L2 #V #W #l #_ #_ #_ #H destruct
+]
+qed.
+
+lemma lsubsn_inv_atom2: ∀h,L1. h ⊢ L1 :⊑[] ⋆ → L1 = ⋆.
+/2 width=5/ qed-.
+
+fact lsubsn_inv_pair2_aux: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                           ∀I,K2,W. L2 = K2. ⓑ{I} W →
+                           (∃∃K1. h ⊢ K1 :⊑[] K2 & L1 = K1. ⓑ{I} W) ∨
+                           ∃∃K1,V,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
+                                     h ⊢ K1 :⊑[] K2 & L1 = K1. ⓓV & I = Abst.
+#h #L1 #L2 * -L1 -L2
+[ #I #K2 #W #H destruct
+| #J #L1 #L2 #V #HL12 #I #K2 #W #H destruct /3 width=3/
+| #L1 #L2 #V #W #l #H1VW #H2VW #HL12 #I #K2 #W2 #H destruct /3 width=7/
+]
+qed.
+
+lemma lsubsn_inv_pair2: ∀h,I,L1,K2,W. h ⊢ L1 :⊑[] K2. ⓑ{I} W →
+                        (∃∃K1. h ⊢ K1 :⊑[] K2 & L1 = K1. ⓑ{I} W) ∨
+                        ∃∃K1,V,l. ⦃h, K1⦄ ⊢ V :[l+1] W & ⦃h, K2⦄ ⊢ V :[l+1] W &
+                                  h ⊢ K1 :⊑[] K2 & L1 = K1. ⓓV & I = Abst.
+/2 width=3/ qed-.
+
+(* Basic_forward lemmas *****************************************************)
+
+lemma lsubsn_fwd_lsubs1: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 ≼[0, |L1|] L2.
+#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+lemma lsubsn_fwd_lsubs2: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 → L1 ≼[0, |L2|] L2.
+#h #L1 #L2 #H elim H -L1 -L2 // /2 width=1/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lsubsn_refl: ∀h,L. h ⊢ L :⊑[] L.
+#h #L elim L -L // /2 width=1/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_cpcs.etc
new file mode 100644 (file)
index 0000000..38f7e17
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_cpcs.ma".
+include "basic_2/dynamic/lsubsn.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
+
+(* Properties on context-sensitive parallel equivalence for terms ***********)
+
+lemma cpr_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                        ∀T1,T2. L2 ⊢ T1 ➡ T2 → L1 ⊢ T1 ➡ T2.
+/3 width=5 by lsubsn_fwd_lsubs2, cpr_lsubs_trans/ qed-.
+
+lemma cprs_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                         ∀T1,T2. L2 ⊢ T1 ➡* T2 → L1 ⊢ T1 ➡* T2.
+/3 width=5 by lsubsn_fwd_lsubs2, cprs_lsubs_trans/ qed-.
+
+lemma cpcs_lsubsn_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                         ∀T1,T2. L2 ⊢ T1 ⬌* T2 → L1 ⊢ T1 ⬌* T2.
+/3 width=5 by lsubsn_fwd_lsubs2, cpcs_lsubs_trans/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_ldrop.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_ldrop.etc
new file mode 100644 (file)
index 0000000..0928837
--- /dev/null
@@ -0,0 +1,65 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/lsubsn.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
+
+(* Properties concerning basic local environment slicing ********************)
+
+(* Note: the constant 0 cannot be generalized *)
+lemma lsubsn_ldrop_O1_conf: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                            ∀K1,e. ⇩[0, e] L1 ≡ K1 →
+                            ∃∃K2. h ⊢ K1 :⊑[] K2 & ⇩[0, e] L2 ≡ K2.
+#h #L1 #L2 #H elim H -L1 -L2
+[ /2 width=3/
+| #I #L1 #L2 #V #_ #IHL12 #K1 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK1
+  [ destruct
+    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK1) -L1 /3 width=3/
+  ]
+| #L1 #L2 #V #W #l #H1VW #H2VW #_ #IHL12 #K1 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK1
+  [ destruct
+    elim (IHL12 L1 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK1) -L1 /3 width=3/
+  ]
+]
+qed.
+
+(* Note: the constant 0 cannot be generalized *)
+lemma lsubsn_ldrop_O1_trans: ∀h,L1,L2. h ⊢ L1 :⊑[] L2 →
+                             ∀K2,e. ⇩[0, e] L2 ≡ K2 →
+                             ∃∃K1. h ⊢ K1 :⊑[] K2 & ⇩[0, e] L1 ≡ K1.
+#h #L1 #L2 #H elim H -L1 -L2
+[ /2 width=3/
+| #I #L1 #L2 #V #_ #IHL12 #K2 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK2
+  [ destruct
+    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK2) -L2 /3 width=3/
+  ]
+| #L1 #L2 #V #W #l #H1VW #H2VW #_ #IHL12 #K2 #e #H
+  elim (ldrop_inv_O1 … H) -H * #He #HLK2
+  [ destruct
+    elim (IHL12 L2 0 ?) -IHL12 // #X #HL12 #H
+    <(ldrop_inv_refl … H) in HL12; -H /3 width=3/
+  | elim (IHL12 … HLK2) -L2 /3 width=3/
+  ]
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/lsubsn_snta.etc
new file mode 100644 (file)
index 0000000..c621530
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/snta_snta.ma".
+include "basic_2/dynamic/lsubsn_ldrop.ma".
+include "basic_2/dynamic/lsubsn_cpcs.ma".
+
+(* LOCAL ENVIRONMENT REFINEMENT FOR STRATIFIED NATIVE TYPE ASSIGNMENT *******)
+
+(* Properties concerning stratified native type assignment ******************)
+
+(* Note: the corresponding confluence property does not hold *)
+lemma lsubsn_snta_trans: ∀h,L2,T,U,l. ⦃h, L2⦄ ⊢ T :[l] U →
+                         ∀L1. h ⊢ L1 :⊑[] L2 → ⦃h, L1⦄ ⊢ T :[l] U.
+#h #L2 #T #U #l #H elim H -L2 -T -U -l
+[ //
+| #L2 #K2 #V2 #W2 #U2 #i #l #HLK2 #_ #WU2 #IHVW2 #L1 #HL12
+  elim (lsubsn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
+  elim (lsubsn_inv_pair2 … H) -H * #K1
+  [ #HK12 #H destruct /3 width=6/
+  | #V1 #l0 #_ #_ #_ #_ #H destruct
+  ]
+| #L2 #K2 #W2 #V2 #U2 #i #l #HLK2 #HWV2 #HWU2 #IHWV2 #L1 #HL12
+  elim (lsubsn_ldrop_O1_trans … HL12 … HLK2) -L2 #X #H #HLK1
+  elim (lsubsn_inv_pair2 … H) -H * #K1 [ -HWV2 | -IHWV2 ]
+  [ #HK12 #H destruct /3 width=6/
+  | #V1 #l0 #H1 #H2 #_ #H #_ destruct
+    elim (snta_fwd_correct … H2) -H2 #V #H
+    elim (snta_mono … HWV2 … H) -HWV2 -H /2 width=6/
+  ]
+| /4 width=3/
+| /3 width=2/
+| /3 width=2/
+| /3 width=1/
+| #L2 #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #IHUV2 #L1 #HL12
+  lapply (cpcs_lsubsn_trans … HL12 … HU12) -HU12 /3 width=3/
+]
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta.etc
new file mode 100644 (file)
index 0000000..71ed421
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : * break [ l ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'NativeTypeStar $h $l $L $T1 $T2 }.
+
+notation "hvbox( ⦃ h , break L ⦄ ⊢ break term 46 T1 : break [ l ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'StratifiedNativeType $h $l $L $T1 $T2 }.
+
+include "basic_2/static/sh.ma".
+include "basic_2/equivalence/cpcs.ma".
+
+(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
+
+inductive snta (h:sh): nat → lenv → relation term ≝
+| snta_sort: ∀L,k. snta h 0 L (⋆k) (⋆(next h k))
+| snta_ldef: ∀L,K,V,W,U,i,l. ⇩[0, i] L ≡ K. ⓓV → snta h l K V W →
+             ⇧[0, i + 1] W ≡ U → snta h l L (#i) U
+| snta_ldec: ∀L,K,W,V,U,i,l. ⇩[0, i] L ≡ K. ⓛW → snta h l K W V →
+             ⇧[0, i + 1] W ≡ U → snta h (l+1) L (#i) U
+| snta_bind: ∀I,L,V,W,T,U,l1,l2. snta h l1 L V W → snta h l2 (L. ⓑ{I} V) T U →
+             snta h l2 L (ⓑ{I}V.T) (ⓑ{I}V.U)
+| snta_appl: ∀L,V,W1,W2,T,U,l1,l2. snta h (l1+1) L V W2 →
+             snta h l2 L (ⓛW1.T) (ⓛW2.U) →
+             snta h l2 L (ⓐV.ⓛW1.T) (ⓐV.ⓛW2.U)
+| snta_pure: ∀L,V,T,U,W,l. snta h (l+1) L T U → snta h l L (ⓐV.U) W →
+             snta h (l+1) L (ⓐV.T) (ⓐV.U)
+| snta_cast: ∀L,T,U,W,l1,l2. snta h l2 L T U → snta h l1 L U W →
+             snta h l2 L (ⓝU.T) U
+| snta_conv: ∀L,T,U1,U2,V2,l. snta h l L T U1 → L ⊢ U1 ⬌* U2 →
+             snta h (l-1) L U2 V2 → snta h l L T U2
+.
+
+interpretation "stratified native type assignment (term)"
+   'StratifiedNativeType h l L T U = (snta h l L T U).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_lift.etc
new file mode 100644 (file)
index 0000000..424bfe8
--- /dev/null
@@ -0,0 +1,238 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/equivalence/cpcs_cpcs.ma".
+include "basic_2/dynamic/snta.ma".
+
+(* NATIVE TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+fact snta_inv_sort1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀k0. T = ⋆k0 →
+                         l = 0 ∧ L ⊢ ⋆(next h k0) ⬌* U.
+#h #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #k0 #H destruct /2 width=1/
+| #L #K #V #W #U #i #l #_ #_ #_ #_ #k0 #H destruct
+| #L #K #W #V #U #i #l #_ #_ #_ #_ #k0 #H destruct
+| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
+| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
+| #L #V #T #U #W #l #_ #_ #_ #_ #k0 #H destruct
+| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #k0 #H destruct
+| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #k0 #H destruct
+  elim (IHTU1 ??) -IHTU1 [3: // |2: skip ] #H #Hk0
+  lapply (cpcs_trans … Hk0 … HU12) -U1 /2 width=1/
+]
+qed.
+
+lemma snta_inv_sort1: ∀h,L,U,k,l. ⦃h, L⦄ ⊢ ⋆k :[l] U →
+                      l = 0 ∧ L ⊢ ⋆(next h k) ⬌* U.
+/2 width=4/ qed-.
+
+fact snta_inv_lref1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀j. T = #j →
+                         (∃∃K,V,W,U0. ⇩[0, j] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V :[l] W &
+                                      ⇧[0, j + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                         ) ∨
+                         (∃∃K,W,V,U0. ⇩[0, j] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W :[l-1] V &
+                                      ⇧[0, j + 1] W ≡ U0 & l > 0 & L ⊢ U0 ⬌* U
+                         ).
+#h #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #j #H destruct
+| #L #K #V #W #U #i #l #HLK #HVW #HWU #_ #j #H destruct /3 width=8/
+| #L #K #W #V #U #i #l #HLK #HWV #HWU #_ #j #H destruct /3 width=8/
+| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #j #H destruct
+| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #j #H destruct
+| #L #V #T #U #W #l #_ #_ #_ #_ #j #H destruct
+| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #j #H destruct
+| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #j #H destruct
+  elim (IHTU1 ??) -IHTU1 [4: // |2: skip ] * #K #V #W #U0 #HLK #HVW #HWU0 [2: #H ] #HU01
+  lapply (cpcs_trans … HU01 … HU12) -U1 /3 width=8/
+]
+qed.
+
+lemma snta_inv_lref1: ∀h,L,U,i,l. ⦃h, L⦄ ⊢ #i :[l] U →
+                     (∃∃K,V,W,U0. ⇩[0, i] L ≡ K. ⓓV & ⦃h, K⦄ ⊢ V :[l] W &
+                                  ⇧[0, i + 1] W ≡ U0 & L ⊢ U0 ⬌* U
+                     ) ∨
+                     (∃∃K,W,V,U0. ⇩[0, i] L ≡ K. ⓛW & ⦃h, K⦄ ⊢ W :[l-1] V &
+                                  ⇧[0, i + 1] W ≡ U0 & l > 0 & L ⊢ U0 ⬌* U
+                     ).
+/2 width=3/ qed-.
+
+fact snta_inv_bind1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀J,X,Y. T = ⓑ{J}Y.X →
+                         ∃∃Z1,Z2,l0. ⦃h, L⦄ ⊢ Y :[l0] Z1 &
+                                  ⦃h, L.ⓑ{J}Y⦄ ⊢ X :[l] Z2 &
+                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
+#h #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #J #X #Y #H destruct
+| #L #K #V #W #U #i #l #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #K #W #V #U #i #l #_ #_ #_ #_ #J #X #Y #H destruct
+| #I #L #V #W #T #U #l1 #l2 #HVW #HTU #_ #_ #J #X #Y #H destruct /2 width=3/
+| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #V #T #U #W #l #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #J #X #Y #H destruct
+| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #J #X #Y #H destruct
+  elim (IHTU1 ????) -IHTU1 [5: // |2,3,4: skip ] #Z1 #Z2 #l0 #HZ1 #HZ2 #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
+]
+qed.
+
+lemma snta_inv_bind1: ∀h,J,L,Y,X,U,l. ⦃h, L⦄ ⊢ ⓑ{J}Y.X :[l] U →
+                      ∃∃Z1,Z2,l0. ⦃h, L⦄ ⊢ Y :[l0] Z1 & ⦃h, L.ⓑ{J}Y⦄ ⊢ X :[l] Z2 &
+                                  L ⊢ ⓑ{J}Y.Z2 ⬌* U.
+/2 width=3/ qed-.
+
+fact snta_inv_cast1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀X,Y. T = ⓝY.X →
+                      ⦃h, L⦄ ⊢ X :[l] Y ∧ L ⊢ Y ⬌* U.
+#h #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #X #Y #H destruct
+| #L #K #V #W #U #i #l #_ #_ #_ #_ #X #Y #H destruct
+| #L #K #W #V #U #i #l #_ #_ #_ #_ #X #Y #H destruct
+| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W1 #W2 #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #T #U #W #l #_ #_ #_ #_ #X #Y #H destruct
+| #L #T #U #W #l1 #l2 #HTU #_ #_ #_ #X #Y #H destruct /2 width=1/
+| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
+  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #HXY #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=1/
+]
+qed.
+
+lemma snta_inv_cast1: ∀h,L,X,Y,U,l. ⦃h, L⦄ ⊢ ⓝY.X :[l] U →
+                      ⦃h, L⦄ ⊢ X :[l] Y ∧ L ⊢ Y ⬌* U.
+/2 width=3/ qed-.
+
+(* Properties on relocation *************************************************)
+
+lemma snta_lift: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
+                 ∀L2,d,e. ⇩[d, e] L2 ≡ L1 →
+                 ∀T2. ⇧[d, e] T1 ≡ T2 → ∀U2. ⇧[d, e] U1 ≡ U2 →
+                 ⦃h, L2⦄ ⊢ T2 :[l] U2.
+#h #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
+[ #L1 #k #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  >(lift_inv_sort1 … H1) -X1
+  >(lift_inv_sort1 … H2) -X2 //
+| #L1 #K1 #V1 #W1 #W #i #l #HLK1 #_ #HW1 #IHVW1 #L2 #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // #W2 #HW12 #HWU2
+    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
+    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
+    /3 width=8/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
+    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
+  ]
+| #L1 #K1 #W1 #V1 #W #i #l #HLK1 #_ #HW1 #IHWV1 #L2 #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2 ?) -W // <minus_plus #W #HW1 #HWU2
+    elim (ldrop_trans_le … HL21 … HLK1 ?) -L1 /2 width=2/ #X #HLK2 #H
+    elim (ldrop_inv_skip2 … H ?) -H /2 width=1/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
+    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
+    elim (lift_total V1 (d-i-1) e) /3 width=8/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W // /2 width=1/ #HW1U2
+    lapply (ldrop_trans_ge … HL21 … HLK1 ?) -L1 // -Hid /3 width=8/
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct
+  elim (lift_total W1 d e) /4 width=6/
+| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #V2 #X #HV12 #H1 #H destruct
+  elim (lift_inv_bind1 … H1) -H1 #W21 #T2 #HW121 #HT12 #H destruct
+  elim (lift_inv_flat1 … H2) -H2 #Y2 #X #HY #H2 #H destruct
+  elim (lift_inv_bind1 … H2) -H2 #W22 #U2 #HW122 #HU12 #H destruct
+  lapply (lift_mono … HY … HV12) -HY #H destruct /4 width=6/
+| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct
+  elim (lift_total W1 d e) #W2 #HW12 /4 width=6/
+| #L1 #T1 #U1 #W1 #l1 #l2 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL21 #X #H #U2 #HU12
+  elim (lift_inv_flat1 … H) -H #X2 #T2 #HUX2 #HT12 #H destruct
+  lapply (lift_mono … HUX2 … HU12) -HUX2 #H destruct
+  elim (lift_total W1 d e) /3 width=6/
+| #L1 #T1 #U11 #U12 #V12 #l #_ #HU112 #_ #IHTU11 #IHUV12 #L2 #d #e #HL21 #U1 #HTU1 #U2 #HU12
+  elim (lift_total U11 d e) #U #HU11
+  elim (lift_total V12 d e) #V22 #HV122
+  lapply (cpcs_lift … HL21 … HU11 … HU12 HU112) -HU112 /3 width=6/
+]
+qed.
+
+(* Advanced forvard lemmas **************************************************)
+
+fact snta_fwd_pure1_aux: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ∀X,Y. T = ⓐY.X →
+                         ∃∃V,W,l0. ⦃h, L⦄ ⊢ Y :[l0+1] W & ⦃h, L⦄ ⊢ X :[l] V &
+                                   L ⊢ ⓐY.V ⬌* U.
+#h #L #T #U #l #H elim H -L -T -U -l
+[ #L #k #X #Y #H destruct
+| #L #K #V #W #U #i #l #_ #_ #_ #_ #X #Y #H destruct
+| #L #K #W #V #U #i #l #_ #_ #_ #_ #X #Y #H destruct
+| #I #L #V #W #T #U #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
+| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #_ #_ #X #Y #H destruct /2 width=3/
+| #L #V #T #U #W #l #HTU #_ #_ #IHU #X #Y #H destruct
+  elim (IHU U Y ?) -IHU // /3 width=3/
+| #L #T #U #W #l1 #l2 #_ #_ #_ #_ #X #Y #H destruct
+| #L #T #U1 #U2 #V2 #l #_ #HU12 #_ #IHTU1 #_ #X #Y #H destruct
+  elim (IHTU1 ???) -IHTU1 [4: // |2,3: skip ] #V #W #l0 #HYW #HXV #HU1
+  lapply (cpcs_trans … HU1 … HU12) -U1 /2 width=3/
+]
+qed.
+
+lemma snta_fwd_pure1: ∀h,L,X,Y,U,l. ⦃h, L⦄ ⊢ ⓐY.X :[l] U →
+                      ∃∃V,W,l0. ⦃h, L⦄ ⊢ Y :[l0+1] W & ⦃h, L⦄ ⊢ X :[l] V &
+                                L ⊢ ⓐY.V ⬌* U.
+/2 width=3/ qed-.
+
+lemma snta_fwd_correct: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U →
+                        ∃T0. ⦃h, L⦄ ⊢ U :[l-1] T0.
+#h #L #T #U #l #H elim H -L -T -U -l
+[ /2 width=2/
+| #L #K #V #W #W0 #i #l #HLK #_ #HW0 * #V0 #HWV0
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  elim (lift_total V0 0 (i+1)) /3 width=10/
+| #L #K #W #V #V0 #i #l #HLK #HWV #HWV0 #_
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  elim (lift_total V 0 (i+1)) /3 width=10/
+| #I #L #V #W #T #U #l1 #l2 #HVW #_ #_ * /3 width=3/
+| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #_ #_ * #X #H
+  elim (snta_inv_bind1 … H) -H /4 width=5/   
+| /3 width=2/
+| /2 width=2/
+| /2 width=2/
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma snta_cast_short: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U → ⦃h, L⦄ ⊢ ⓝU.T :[l] U.
+#h #L #T #U #l #HTU
+elim (snta_fwd_correct … HTU) /2 width=3/
+qed.
+
+lemma snta_typecheck: ∀h,L,T,U,l. ⦃h, L⦄ ⊢ T :[l] U →
+                      ∃T0. ⦃h, L⦄ ⊢ ⓝU.T :[l] T0.
+/3 width=2/ qed.
+
+lemma snta_cast_old: ∀h,L,W,T,U,l.
+                    ⦃h, L⦄ ⊢ T :[l] U → ⦃h, L⦄ ⊢ U :[l-1] W → ⦃h, L⦄ ⊢ ⓝU.T :[l] ⓝW.U.
+#h #L #W #T #U #l #HTU #HUW
+@(snta_conv … U) /2 width=2/ /3 width=1/ (**) (* /4 width=3/ is a bit slow *)
+qed.
+
+lemma snta_appl_old: ∀h,L,V,W,T,U,l1,l2.
+                     ⦃h, L⦄ ⊢ V :[l1+1] W → ⦃h, L⦄ ⊢ T :[l2+1] ⓛW.U →
+                     ⦃h, L⦄ ⊢ ⓐV.T :[l2+1] ⓐV.ⓛW.U.
+#h #L #V #W #T #U #l1 #l2 #HVW #HTU
+elim (snta_fwd_correct … HTU) #X #H
+elim (snta_inv_bind1 … H) -H /4 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpr.etc
new file mode 100644 (file)
index 0000000..77b62e4
--- /dev/null
@@ -0,0 +1,278 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/snta_ltpss.ma".
+include "basic_2/dynamic/snta_thin.ma".
+include "basic_2/dynamic/lsubsn_snta.ma".
+
+(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
+(*
+lemma snta_fwd_abst: ∀h,L,W1,W2,T,U,l2. ⦃h, L⦄ ⊢ ⓛW1.T :[l2] ⓛW2.U →
+                     ∃∃V1,V2,l1. ⦃h, L⦄ ⊢ W1 :[l1] V1 & ⦃h, L⦄ ⊢ W2 :[l1] V2 &
+                                 L ⊢ W1 ⬌* W2.
+#h #L #W1 #W2 #T #U #l2 #HTU
+elim (snta_fwd_correct … HTU) #X #H
+elim (snta_inv_bind1 … H) -H #W #T0 #l #HW2 #_ #_ -X
+elim (snta_inv_bind1 … HTU) -HTU #V1 #U0 #l0 #HWV1 #_ #H
+elim (cpcs_inv_abst … H Abst W1) -H
+#HW12 #_ -U0
+@(ex3_3_intro … HWV1 … HW12)
+[3: @(snta_conv … HTU0 HU0) 
+
+ /3 width=3/
+
+*)
+(*
+#h #L #V #T #U #l2 #HTU
+elim (snta_fwd_correct … HTU) #X #H
+elim (snta_inv_bind1 … H) -H #W #T0 #l1 #HVW #HUT0 #_ -X
+elim (snta_inv_bind1 … HTU) -HTU #W0 #U0 #l0 #_ #HTU0 #H -l0
+elim (cpcs_inv_abst … H Abst V) -H /3 width=3/
+qed-.
+*)
+(*
+lemma snta_fwd_appl1_sound_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
+                                        l < l0 → ⦃h, L1⦄ ⊢ T1 :[l] U →
+                                        L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
+                                       ) →
+                                ∀L,T,U,l2. ⦃h, L⦄ ⊢ T :[l2] U →
+                                ∀Z,Y,X1. T = ⓐZ.ⓛY.X1 → l0 = l2 →
+                                ∃l1. ⦃h, L⦄ ⊢ Z :[l1+1] Y.
+#h #l0 #IH #L #T #U #l2 #H elim H -L -T -U -l2
+[
+|
+|
+|
+| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #_ #_ #Z #Y #X1 #H1 #H2 destruct -IH
+  elim (snta_fwd_abst … HTU) -X1 -U -l2 #Y0 #W0 #l0 #HY0 #H1 #HYW2
+  elim (snta_fwd_correct … HVW2) #W #H2
+  elim (snta_mono … H1 … H2) -H1 -H2 #H #_ destruct -W0 -W /4 width=6/
+| #L #V #T #U #W #l #HTU #HUW #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
+  elim (snta_inv_abst_sn … HTU) -HTU #Y0 #l0 #HY0 #HX12
+|
+| #L #T #U1 #U2 #V2 #l #HTU1 #HU12 #HUV2 #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+lemma snta_inv_appl_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
+                                 l < l0 + 1 → ⦃h, L1⦄ ⊢ T1 :[l] U →
+                                 L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
+                                ) →
+                         ∀L,T,U,l2. ⦃h, L⦄ ⊢ T :[l2] U →
+                         ∀Z,Y,X1,X2. T = ⓐZ.ⓛY.X1 → U = ⓐZ.ⓛY.X2 → l0 = l2 →
+                         ∃∃l1. ⦃h, L⦄ ⊢ Z :[l1+1] Y & ⦃h, L.ⓛY⦄ ⊢ X1 :[l2] X2.
+#h #l0 #IH #L #T #U #l2 * -L -T -U -l2
+[
+|
+|
+|
+| #L #V #W1 #W2 #T #U #l1 #l2 #HVW2 #HTU #Z #Y #X1 #X2 #H1 #H2 #H3 destruct -IH
+  elim (snta_inv_abst … HTU) -HTU /2 width=2/
+| #L #V #T #U #W #l #HTU #HUW #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
+  elim (snta_inv_abst … HTU) -HTU #Y0 #l0 #HY0 #HX12
+|
+| #L #T #U1 #U2 #V2 #l #HTU1 #HU12 #HUV2 #Z #Y #X1 #X2 #H1 #H2 #H3 destruct
+  
+   /2 width=2/
+
+
+axiom pippo: ∀h,l0. (∀L1,L2,T1,T2,U,l.
+                l < l0 + 1 → ⦃h, L1⦄ ⊢ T1 :[l] U →
+                L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
+             ) →
+             ∀L,T1,U1,l. ⦃h, L⦄ ⊢ T1 :[l] U1 →
+             ∀V2,W2,T2. L ⊢ T1 ➡* ⓐV2.ⓛW2.T2 → l0 = l →
+             ∃l0. ⦃h, L2⦄ ⊢ V2 :[l0+1] W2.
+(*
+#h #l #IH #L1 #T1 #U1 #l1 * -L1 -T1 -U1 -l1
+[
+|
+|
+|
+| #L1 #V1 #W1 #T1 #U1 #l1 #HVW1 #HTU1 #Y1 #X1 #H1 #L2 #Y2 #HL12 #HY12 #Z2 #X2 #HX12 #H2 destruct
+  elim (IH ??? Y2 … HVW1 HL12 ?) -HVW1 // [2: /3 width=1/ ] -HY12 #l21 #HY2W1 #H1l21 #H2l21
+  elim (IH … HTU1 HL12 HX12) -IH -HTU1 -HL12 -HX12 // #l22 #H #_ #H2l22
+  elim (snta_inv_bind1 … H) -H #Z #X #HZ2 #_ #H
+  elim (cpcs_inv_abst … H Abst W1) -H #H #_
+  lapply (transitive_le … (l21+l22) … H1l21 ?) -H1l21 // #Hl21
+  @(ex3_1_intro … Hl21) [2: /3 width=1/ ]
+  @(snta_conv … W1) /2 width=2/ (**) (* explicit constructors *)
+| #L1 #V1 #T1 #U1 #W1 #l1 #HTU1 #HUW1 #Y1 #X1 #H1 #L2 #Y2 #HL12 #HY12 #Z2 #X2 #HX12 #H2 destruct
+
+*)
+(* Properties on context-free parallel reduction for local environments *****)
+*)
+fact snta_ltpr_tpr_conf_aux: ∀h,l0. (∀L1,L2,T1,T2,U,l.
+                                l < l0 → ⦃h, L1⦄ ⊢ T1 :[l] U →
+                                L1 ➡ L2 → L2 ⊢ T1 ➡* T2 → ⦃h, L2⦄ ⊢ T2 :[l] U
+                             ) →
+                             ∀L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U → ∀L2. L1 ➡ L2 →
+                             ∀T2. T1 ➡ T2 → l0 = l → ⦃h, L2⦄ ⊢ T2 :[l] U.
+#h #l0 #IH #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
+[ #L1 #k1 #L2 #_ #T2 #H #_ -l0
+  >(tpr_inv_atom1 … H) -H //
+| #L1 #K1 #V1 #W #U #i1 #l #HLK1 #_ #HWU #IHV1 #L2 #HL12 #T2 #H #Hl -IH
+  >(tpr_inv_atom1 … H) -T2
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
+  elim (ltpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct /3 width=6/
+| #L1 #K1 #W1 #V1 #U1 #i1 #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #HL12 #T2 #H #Hl -IH
+(*  
+  >(tpr_inv_atom1 … H) -T2
+  elim (ltpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #HLK2 #H
+  elim (ltpr_inv_pair1 … H) -H #K2 #W2 #HK12 #HW12 #H destruct
+  lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+  elim (lift_total V1 0 (i+1)) #W #HW
+  lapply (snta_lift h … HLK … HWU1 … HW) /2 width=1/ -HLK -HW
+  elim (lift_total W2 0 (i+1)) #U2 #HWU2
+  lapply (tpr_lift … HW12 … HWU1 … HWU2) -HWU1 #HU12
+  @(snta_conv … U2) /2 width=1/ /3 width=6/ (**) (* explicit constructor, /3 width=6/ is too slow *)
+*)
+| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H #Hl -IH
+(*  
+  elim (tpr_inv_bind1 … H) -H *
+  [ #V2 #T #T2 #HV12 #HT1 #HT2 #H destruct
+    lapply (IHVW1 … HL12 … HV12) #HV2W1
+    lapply (IHVW1 L2 … V1 ?) // -IHVW1 #HWV1
+    lapply (IHTU1 (L2.ⓑ{I}V2) … HT1) -HT1 /2 width=1/ #HTU1
+    lapply (IHTU1 (L2.ⓑ{I}V1) ? T1 ?) -IHTU1 // /2 width=1/ -HL12 #H
+    lapply (tps_lsubs_trans … HT2 (L2.ⓑ{I}V2) ?) -HT2 /2 width=1/ #HT2
+    lapply (snta_tps_conf … HTU1 … HT2) -T #HT2U1
+    elim (snta_fwd_correct … H) -H #U2 #HU12
+    @(snta_conv … (ⓑ{I}V2.U1)) /2 width=2/ /3 width=1/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+  | #T #HT1 #HTX #H destruct
+    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HVW1
+    lapply (IHTU1 (L2.ⓓV1) … HT1) -T1 /2 width=1/ -L1 #H
+    elim (snta_fwd_correct … H) #T1 #HUT1
+    elim (snta_ldrop_conf … H L2 0 1 ? ?) -H // /2 width=1/ #T0 #U0 #HTU0 #H #HU10
+    lapply (delift_inv_lift1_eq … H L2 … HTX) -H -HTX /2 width=1/ #H destruct
+    @(snta_conv … HTU0) /2 width=2/
+  ]
+*)
+| #L1 #V1 #W11 #W2 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #HL12 #X #H #Hl -IH
+(*
+  elim (tpr_inv_appl1 … H) -H *
+  [ #V2 #Y #HV12 #HY #H destruct
+    elim (tpr_inv_abst1 … HY) -HY #W2 #T2 #HW12 #HT12 #H destruct
+    lapply (IHTU1 L2 ? (ⓛW1.T1) ?) // #H
+    elim (snta_fwd_correct … H) -H #X #H
+    elim (snta_inv_bind1 … H) -H #W #U #HW #HU #_
+    @(snta_conv … (ⓐV2.ⓛW1.U1)) /4 width=2/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+  | #V2 #W2 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
+    lapply (IHVW1 … HL12 … HV12) #HVW2
+    lapply (IHVW1 … HL12 V1 ?) -IHVW1 // #HV1W2
+    lapply (IHTU1 … HL12 (ⓛW2.T2) ?) -IHTU1 -HL12 /2 width=1/ -HT02 #H1
+    elim (snta_fwd_correct … H1) #T #H2
+    elim (snta_inv_bind1 … H1) -H1 #W #U2 #HW2 #HTU2 #H
+    elim (cpcs_inv_abst … H Abst W2) -H #_ #HU21
+    elim (snta_inv_bind1 … H2) -H2 #W0 #U0 #_ #H #_ -T -W0
+    lapply (lsubsn_snta_trans … HTU2 (L2.ⓓV2) ?) -HTU2 /2 width=1/ #HTU2
+    @(snta_conv … (ⓓV2.U2)) /2 width=2/ /3 width=2/ (**) (* explicit constructor, /4 width=5/ is too slow *)
+  | #V0 #V2 #W0 #W2 #T0 #T2 #_ #_ #_ #_ #H destruct
+  ]
+*)
+| #L1 #V1 #T1 #U1 #W1 #l #_ #HUW1 #IHTU1 #_ #L2 #HL12 #X #H #Hl
+  elim (tpr_inv_appl1 … H) -H *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (cpr_tpr … HV12 L2) #HV
+    elim (snta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) (l+1) ?) [2: /3 width=6/ ] #U
+    @(snta_conv … (ⓐV2.U1)) /2 width=1/ -HV12 /4 width=8 by snta_pure, cprs_flat_dx/ (**) (* explicit constructor, /4 width=8/ is too slow without trace *)
+  | #V2 #W0 #T0 #T2 #HV12 #HT02 #H1 #H2 destruct
+    lapply (IHTU1 … HL12 (ⓛW0.T2) ? ?) -IHTU1 // /2 width=1/ -T0 #H1
+    lapply (IH … (ⓐV2.U1) … HUW1 HL12 ?) // /3 width=1/ #H2
+    lapply (snta_pure … H1 H2) -H2 #H
+    elim (snta_inv_bind1 … H1) -H1 #V0 #U2 #l1 #HWV0 #HTU2 #HU21
+    @(snta_conv … (ⓓV2.U2)) (**) (* explicit constructor *)
+    [2:
+(*
+        @snta_bind /3 width=2/ /3 width=6/ (**) (* /4 width=6/ is a bit slow *)
+*)
+    |3: @(cpcs_cpr_conf … (ⓐV1.ⓛW0.U2)) /2 width=1/
+    |4: /2 width=5/
+    | skip
+    ]
+(*
+    elim (snta_fwd_pure1 … H) -H #T1 #W2 #HVW2 #HUT1 #HTW1
+
+    elim (cpcs_inv_abst1 … HU21) #W3 #U3 #HU13 #H
+    elim (cprs_inv_abst … H Abst W0) -H #HW03 #_
+    elim (pippo … IH … HUW1 ? V2 W3 U3 HL12 ? ?) -IH -HUW1 -HL12 // /3 width=1/ -HU13 #l2 #HV2W3
+    lapply (snta_conv h L2 V2 W3 W0 V0 (l1+1) ? ? ?) /2 width=1/ -HV2W3 -HW03 -HWV0 #HV2W0    
+*)    
+(* SEGMENT 1.5
+    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HB
+    lapply (IH … HB0  … HL12 W2 ?) -HB0 /width=5/ #HB0
+    lapply (IH … HA0 … (L2.ⓛW2) … HT02) -IH -HA0 -HT02 /width=5/ -T0 /2 width=1/ -L1 -V1 /4 width=7/
+    
+axiom pippo: ⦃h, L⦄ ⊢ ⓐV.X : Y →
+             ∃∃W,T. L ⊢ X ➡* ⓛW.T & ⦃h, L⦄ ⊢ ⓐV : W.
+
+*)
+(* SEGMENT 2
+| #L1 #T1 #U1 #W1 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
+  lapply (cpr_tpss … HU12) /4 width=4/
+| #L1 #T1 #U11 #U12 #U #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
+  @(snta_conv … U11) /2 width=5/ (**) (* explicot constructor, /3 width=7/ is too slow *)
+]
+qed.
+*)
+
+(* SEGMENT 3
+fact snta_ltpr_tpr_conf_aux: ∀h,L,T,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → L = L1 → T = T1 →
+                            ∀L2. L1 ➡ L2 → ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
+  
+  
+  | #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HW02 #HT02 #HV02 #H1 #H2 destruct
+    elim (snta_inv_abbr … HT1) -HT1 #B0 #HW0 #HT0
+    lapply (IH … HW0  … HL12 … HW02) -HW0 /width=5/ #HW2
+    lapply (IH … HV1 … HL12 … HV10) -HV1 -HV10 /width=5/ #HV0
+    lapply (IH … HT0 … (L2.ⓓW2) … HT02) -IH -HT0 -HT02 /width=5/ -V1 -T0 /2 width=1/ -L1 -W0 #HT2
+    @(snta_abbr … HW2) -HW2
+    @(snta_appl … HT2) -HT2 /3 width=7/ (**) (* explict constructors, /5 width=7/ is too slow *)
+  ]
+| #L1 #V1 #T1 #A #HV1 #HT1 #H1 #H2 #L2 #HL12 #X #H destruct
+  elim (tpr_inv_cast1 … H) -H
+  [ * #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH … HV1 … HL12 … HV12) -HV1 -HV12 /width=5/ #HV2
+    lapply (IH … HT1 … HL12 … HT12) -IH -HT1 -HL12 -HT12 /width=5/ -L1 -V1 -T1 /2 width=1/
+  | -HV1 #HT1X
+     lapply (IH … HT1 … HL12 … HT1X) -IH -HT1 -HL12 -HT1X /width=5/
+  ]
+]
+qed.
+
+lemma snta_ltpr_tpr_conf: ∀h,L1,T1,U. ⦃h, L1⦄ ⊢ T1 : U → ∀L2. L1 ➡ L2 →
+                         ∀T2. T1 ➡ T2 → ⦃h, L2⦄ ⊢ T2 : U.
+
+/2 width=9/ qed.
+
+axiom snta_ltpr_conf: ∀L1,T,A. L1 ⊢ T : A → ∀L2. L1 ➡ L2 → L2 ⊢ T : A.
+/2 width=5/ qed.
+
+axiom snta_tpr_conf: ∀L,T1,A. L ⊢ T1 : A → ∀T2. T1 ➡ T2 → L ⊢ T2 : A.
+/2 width=5/ qed.
+*)
+*)*)
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_ltpss.etc
new file mode 100644 (file)
index 0000000..0e5f393
--- /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/equivalence/cpcs_ltpss.ma".
+include "basic_2/dynamic/snta_snta.ma".
+
+(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Properties about parallel unfold *****************************************)
+
+lemma snta_ltpss_tpss_conf: ∀h,L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U →
+                            ∀L2,d,e. L1 ▶* [d, e] L2 →
+                            ∀T2. L2 ⊢ T1 ▶* [d, e] T2 → ⦃h, L2⦄ ⊢ T2 :[l] U.
+#h #L1 #T1 #U #l #H elim H -L1 -T1 -U -l
+[ #L1 #k #L2 #d #e #_ #T2 #H
+  >(tpss_inv_sort1 … H) -H //
+| #L1 #K1 #V1 #W #U #i #l #HLK1 #_ #HWU #IHV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H
+  [ #H destruct
+    elim (lt_or_ge i d) #Hdi
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #V2 #HK12 #HV12 #H destruct
+      /3 width=7/
+    | elim (lt_or_ge i (d + e)) #Hide [ | -Hdi ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #V2 #HK12 #HV12 #H destruct
+        /3 width=7/
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /3 width=7/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #HVW2 #HWT2
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #HK12 #HV12 #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 #H destruct
+    lapply (ldrop_fwd_ldrop2 … HLK2) -HLK2 #HLK2
+    lapply (tpss_trans_eq … HV12 HVW2) -V2 /3 width=9/
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL12 #T2 #H
+  elim (tpss_inv_lref1 … H) -H [ | -HWV1 -HWU1 -IHWV1 ]
+  [ #H destruct
+    elim (lift_total V1 0 (i+1)) #W #HW
+    elim (lt_or_ge i d) #Hdi [ -HWV1 ]
+    [ elim (ltpss_ldrop_conf_le … HL12 … HLK1 ?) -L1 /2 width=2/ #X #H #HLK2
+      elim (ltpss_inv_tpss11 … H ?) -H /2 width=1/ -Hdi #K2 #W2 #HK12 #HW12 #H destruct
+      lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+      lapply (snta_lift h … HLK … HWU1 … HW) [ /2 width=4/ | skip ] -HW #H
+      elim (lift_total W2 0 (i+1)) #U2 #HWU2
+      lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
+      lapply (cpr_tpss … HU12) -HU12 #HU12
+      @(snta_conv … U2) // /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+    | elim (lt_or_ge i (d + e)) #Hide [ -HWV1 | -IHWV1 -HW -Hdi ]
+      [ elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HLK2
+        elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K2 #W2 #HK12 #HW12 #H destruct
+        lapply (ldrop_fwd_ldrop2 … HLK2) #HLK
+        lapply (snta_lift h … HLK … HWU1 … HW) [ /2 width=4/ | skip ] -HW #H
+        elim (lift_total W2 0 (i+1)) #U2 #HWU2
+        lapply (tpss_lift_ge … HW12 … HLK … HWU1 … HWU2) -HLK -HWU1 // #HU12
+        lapply (cpr_tpss … HU12) -HU12 #HU12
+        @(snta_conv … U2) // /2 width=1/ /3 width=6/ (**) (* explicit constructor, /4 width=6/ is too slow *)
+      | lapply (ltpss_ldrop_conf_ge … HL12 … HLK1 ?) -L1 // -Hide /2 width=6/
+      ]
+    ]
+  | * #K2 #V2 #W2 #Hdi #Hide #HLK2 #_ #_
+    elim (ltpss_ldrop_conf_be … HL12 … HLK1 ? ?) -L1 // /2 width=2/ #X #H #HL2K0
+    elim (ltpss_inv_tpss21 … H ?) -H /2 width=1/ -Hdi -Hide #K0 #V0 #_ #_ #H destruct
+    lapply (ldrop_mono … HL2K0 … HLK2) -HL2K0 -HLK2 #H destruct
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_bind1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HV
+  lapply (IHTU1 (L2.ⓑ{I}V1) (d+1) e ? T1 ?) // /2 width=1/ #H
+  elim (snta_fwd_correct … H) -H #U2 #HU12
+  @(snta_conv … (ⓑ{I}V2.U1)) /3 width=2/ /3 width=4/ /4 width=4/ (**) (* explicit constructor, /5 width=6/ is too slow *)
+| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #Y #HV12 #HY #H destruct
+  elim (tpss_inv_bind1 … HY) -HY #W21 #T2 #HW121 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HVV12
+  lapply (IHTU1 L2 d e ? (ⓛW21.T2) ?) -IHTU1 // /2 width=1/ -HW121 -HT12 #H0
+  elim (snta_fwd_correct … H0) #X #H
+  elim (snta_inv_bind1 … H) -H #W #U #l0 #HW #HU #_
+  @(snta_conv … (ⓐV2.ⓛW12.U1)) /3 width=2/ /3 width=4/ /3 width=5/ (**) (* explicit constructor, /4 width=5/ is too slow *)
+| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (tpss_inv_flat1 … H) -H #V2 #T2 #HV12 #HT12 #H destruct
+  lapply (cpr_tpss … HV12) #HV
+  elim (snta_fwd_correct h L2 (ⓐV1.T1) (ⓐV1.U1) (l+1) ?) [2: /3 width=4/ ] #U
+  @(snta_conv … (ⓐV2.U1)) /3 width=1/ /4 width=5/ (**) (* explicit constructor, /5 width=5/ is too slow *)
+| #L1 #T1 #U1 #W1 #l1 #l2 #HTU1 #HUW1 #IHTU1 #IHUW1 #L2 #d #e #HL12 #X #H
+  elim (snta_fwd_correct … HTU1) -HTU1 #U #H
+  elim (snta_mono … HUW1 … H) -HUW1 -H #H #_ -U destruct
+  elim (tpss_inv_flat1 … H) -H #U2 #T2 #HU12 #HT12 #H destruct
+  lapply (cpr_tpss … HU12) #HU /4 width=4/
+| #L1 #T1 #U11 #U12 #U #l #_ #HU112 #_ #IHTU11 #IHU12 #L2 #d #e #HL12 #T2 #HT12
+  @(snta_conv … U11) /2 width=5/ (**) (* explicit constructor, /3 width=7/ is too slow *)
+]
+qed.
+
+lemma snta_ltpss_tps_conf: ∀h,L1,T1,U,l. ⦃h, L1⦄ ⊢ T1 :[l] U →
+                           ∀L2,d,e. L1 ▶* [d, e] L2 →
+                           ∀T2. L2 ⊢ T1 ▶ [d, e] T2 → ⦃h, L2⦄ ⊢ T2 :[l] U.
+/3 width=7/ qed.
+
+lemma snta_ltpss_conf: ∀h,L1,T,U,l. ⦃h, L1⦄ ⊢ T :[l] U →
+                       ∀L2,d,e. L1 ▶* [d, e] L2 → ⦃h, L2⦄ ⊢ T :[l] U.
+/2 width=7/ qed.
+
+lemma snta_tpss_conf: ∀h,L,T1,U,l. ⦃h, L⦄ ⊢ T1 :[l] U →
+                      ∀T2,d,e. L ⊢ T1 ▶* [d, e] T2 → ⦃h, L⦄ ⊢ T2 :[l] U.
+/2 width=7/ qed.
+
+lemma snta_tps_conf: ∀h,L,T1,U,l. ⦃h, L⦄ ⊢ T1 :[l] U →
+                     ∀T2,d,e. L ⊢ T1 ▶ [d, e] T2 → ⦃h, L⦄ ⊢ T2 :[l] U.
+/2 width=7/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_snta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_snta.etc
new file mode 100644 (file)
index 0000000..db71e11
--- /dev/null
@@ -0,0 +1,65 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/snta_lift.ma".
+
+(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Main properties **********************************************************)
+
+theorem snta_mono: ∀h,L,T,U1,l1. ⦃h, L⦄ ⊢ T :[l1] U1 →
+                   ∀U2,l2. ⦃h, L⦄ ⊢ T :[l2] U2 → l1 = l2 ∧ L ⊢ U1 ⬌* U2.
+#h #L #T #U1 #l1 #H elim H -L -T -U1 -l1
+[ #L #k #X #l2 #H
+  lapply (snta_inv_sort1 … H) -H * /2 width=1/
+| #L #K #V #W11 #W12 #i #l1 #HLK #_ #HW112 #IHVW11 #X #l2 #H
+  elim (snta_inv_lref1 … H) -H * #K0 #V0 #W21 #W22 #HLK0 #HVW21 #HW212 #HX
+  lapply (ldrop_mono … HLK0 … HLK) -HLK0 #H destruct
+  lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
+  elim (IHVW11 … HVW21) -IHVW11 -HVW21 #Hl12 #HW121
+  lapply (cpcs_lift … HLK … HW112 … HW212 ?) // -K -W11 -W21 /3 width=3/
+| #L #K #W #V1 #V #i #l1 #HLK #_ #HWV #IHWV1 #X #l2 #H
+  elim (snta_inv_lref1 … H) -H * #K0 #W0 #V2 #V0 #HLK0 #HW0V2 #HWV0 [2: #HL2 ] #HX
+  lapply (ldrop_mono … HLK0 … HLK) -HLK0 -HLK #H destruct
+  lapply (lift_mono … HWV0 … HWV) -HWV0 -HWV #H destruct
+  elim (IHWV1 … HW0V2) -IHWV1 -HW0V2 /3 width=1/
+| #I #L #V #W1 #T #U1 #l10 #l1 #_ #_ #_ #IHTU1 #X #l2 #H
+  elim (snta_inv_bind1 … H) -H #W2 #U2 #l20 #_ #HTU2 #H
+  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
+  lapply (cpcs_trans … (ⓑ{I}V.U1) … H) -H /2 width=1/
+| #L #V #W #W1 #T #U1 #l10 #l1 #_ #_ #_ #IHTU1 #X #l2 #H
+  elim (snta_fwd_pure1 … H) -H #U2 #W2 #l20 #_ #HTU2 #H
+  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
+  lapply (cpcs_trans … (ⓐV.ⓛW1.U1) … H) -H /2 width=1/
+| #L #V #T #U1 #W1 #l1 #_ #_ #IHTU1 #_ #X #l2 #H
+  elim (snta_fwd_pure1 … H) -H #U2 #W2 #l20 #_ #HTU2 #H
+  elim (IHTU1 … HTU2) -IHTU1 -HTU2 #Hl12 #HU12
+  lapply (cpcs_trans … (ⓐV.U1) … H) -H /2 width=1/
+| #L #T #U1 #W1 #l10 #l1 #_ #_ #IHTU1 #_ #X #l2 #H
+  elim (snta_inv_cast1 … H) -H #HTU1
+  elim (IHTU1 … HTU1) -IHTU1 -HTU1 /2 width=1/
+| #L #T #U11 #U12 #V12 #l1 #_ #HU112 #_ #IHTU11 #_ #U2 #l2 #HTU2
+  elim (IHTU11 … HTU2) -IHTU11 -HTU2 #Hl12 #H
+  lapply (cpcs_canc_sn … HU112 … H) -U11 /2 width=1/
+]
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma snta_cast_alt: ∀h,L,T,W,U,l. ⦃h, L⦄ ⊢ T :[l] W → ⦃h, L⦄ ⊢ T :[l] U →
+             ⦃h, L⦄ ⊢ ⓝW.T :[l] U.
+#h #L #T #W #U #l #HTW #HTU
+elim (snta_mono … HTW … HTU) #_ #HWU
+elim (snta_fwd_correct … HTU) -HTU /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_thin.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snta/snta_thin.etc
new file mode 100644 (file)
index 0000000..ceb5375
--- /dev/null
@@ -0,0 +1,116 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/thin_ldrop.ma".
+include "basic_2/equivalence/cpcs_delift.ma".
+include "basic_2/dynamic/snta_lift.ma".
+
+(* STRATIFIED NATIVE TYPE ASSIGNMENT ON TERMS *******************************)
+
+(* Properties on basic local environment thinning ***************************)
+
+(* Note: this is known as the substitution lemma *)
+lemma snta_thin_conf: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
+                      ∀L2,d,e. ≽ [d, e] L1 → L1 ▼*[d, e] ≡ L2 →
+                      ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 :[l] U2 &
+                               L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
+#h #L1 #T1 #U1 #l #H elim H -L1 -T1 -U1 -l
+[ /2 width=5/
+| #L1 #K1 #V1 #W1 #U1 #i #l #HLK1 #HVW1 #HWU1 #IHVW1 #L2 #d #e #HL1 #HL12
+  elim (lt_or_ge i d) #Hdi [ -HVW1 ]
+  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
+    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
+    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
+    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #V2 #HK12 #HV12 #H destruct
+    elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #X2 #W2 #HVW2 #H #HW12
+    lapply (delift_mono … H … HV12) -H -HV12 #H destruct
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (ldrop_fwd_ldrop2 … HLK1) -V1 #HLK1
+    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
+    >minus_plus <plus_minus_m_m // /3 width=6/
+  | elim (lt_or_ge i (d+e)) #Hide [ -HVW1 | -Hdi -IHVW1 -HL1 ]
+    [ lapply (sfr_ldrop_trans_be_up … HLK1 … HL1 ? ?) -HL1 // /2 width=2/ <minus_n_O #H
+      elim (sfr_inv_bind … H ?) -H /2 width=1/ #HK1 #_
+      elim (thin_ldrop_conf_be … HL12 … HLK1 ? ?) -HL12 /2 width=2/ #K2 #H #HLK2
+      lapply (thin_inv_thin1 … H ?) -H /2 width=1/ #HK12
+      elim (IHVW1 … HK1 HK12) -IHVW1 -HK1 -HK12 #V2 #W2 #HVW2 #HV12 #HW12
+      elim (lift_total V2 0 d) #T2 #HVT2
+      elim (lift_total W2 0 d) #U2 #HWU2
+      elim (lift_total W2 0 (i+1)) #U #HW2U
+      lapply (snta_lift … HVW2 … HLK2 … HVT2 … HWU2) -HVW2 -HLK2 #HTU2
+      lapply (ldrop_fwd_ldrop2 … HLK1) #HLK0
+      lapply (delift_lift_ge … HW12 … HLK0 HWU1 … HW2U) -HW12 -HLK0 -HWU1 // >minus_plus #HU1
+      lapply (lift_conf_be … HWU2 … HW2U ?) -W2 /2 width=1/ #HU2
+      lapply (delift_lift_div_be … HU1 … HU2 ? ?) -U // /2 width=1/ /3 width=8/
+    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
+      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
+      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
+      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
+      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
+    ]
+  ]
+| #L1 #K1 #W1 #V1 #U1 #i #l #HLK1 #HWV1 #HWU1 #IHWV1 #L2 #d #e #HL1 #HL12
+  elim (lt_or_ge i d) #Hdi [ -HWV1 | -IHWV1 ]
+  [ lapply (sfr_ldrop_trans_ge … HLK1 … HL1 ?) -HL1 /2 width=2/ #H
+    lapply (sfr_inv_skip … H ?) -H /2 width=1/ #HK1
+    elim (thin_ldrop_conf_le … HL12 … HLK1 ?) -HL12 /2 width=2/ #X #H #HLK2
+    elim (thin_inv_delift1 … H ?) -H /2 width=1/ #K2 #W2 #HK12 #HW12 #H destruct
+    elim (IHWV1 … HK1 HK12) -IHWV1 -HK1 -HK12 #X2 #V2 #HWV2 #H #_
+    lapply (delift_mono … H … HW12) -H #H destruct
+    elim (lift_total W2 0 (i+1)) #U2 #HWU2
+    lapply (ldrop_fwd_ldrop2 … HLK1) -HLK1 #HLK1
+    lapply (delift_lift_ge … HW12 … HLK1 HWU1 … HWU2) -HW12 -HLK1 -HWU1 //
+    >minus_plus <plus_minus_m_m // /3 width=6/
+  | elim (lt_or_ge i (d+e)) #Hide [ -HWV1 -HWU1 -HL12 | -Hdi -HL1 ]
+    [ lapply (sfr_inv_ldrop … HLK1 … HL1 ? ?) -HLK1 -HL1 // -Hdi -Hide #H destruct 
+    | lapply (transitive_le … (i+1) Hide ?) /2 width=1/ #Hdei
+      lapply (thin_ldrop_conf_ge … HL12 … HLK1 ?) -HL12 -HLK1 // #HL2K1
+      elim (lift_split … HWU1 d (i+1-e) ? ? ?) -HWU1 // /2 width=1/ #W
+      <plus_minus in ⊢ (??%??→?); /2 width=2/ #HW1
+      <minus_minus // /2 width=2/ -Hdei >commutative_plus <minus_n_n /3 width=6/
+    ]
+  ]
+| #I #L1 #V1 #W1 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
+  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W2 #HVW2 #HV12 #_
+  elim (IHTU1 (L2.ⓑ{I}V2) (d+1) e ? ?) -IHTU1 /2 width=1/ -HL1 -HL12 #T2 #U2 #HTU2 #HT12 #HU12
+  lapply (delift_lsubs_trans … HT12 (L1.ⓑ{I}V2) ?) -HT12 /2 width=1/
+  lapply (delift_lsubs_trans … HU12 (L1.ⓑ{I}V2) ?) -HU12 /2 width=1/ /3 width=7/
+| #L1 #V1 #W11 #W12 #T1 #U1 #l1 #l2 #_ #_ #IHVW1 #IHTU1 #L2 #d #e #HL1 #HL12
+  elim (IHVW1 … HL1 HL12) -IHVW1 #V2 #W22 #HVW2 #HV12 #HW122
+  elim (IHTU1 … HL1 HL12) -IHTU1 -HL1 -HL12 #X2 #Y2 #HXY2 #HX2 #HY2
+  elim (delift_inv_bind1 … HX2) -HX2 #W21 #T2 #W121 #HT12 #H destruct
+  elim (delift_inv_bind1 … HY2) -HY2 #X #U2 #HX #HU12 #H destruct
+  lapply (delift_mono … HX … HW122) -HX #H destruct
+  @(ex3_2_intro … (ⓐV2.ⓛW21.T2) (ⓐV2.ⓛW22.U2)) [ /2 width=2/ | 2,3: /3 width=1/ ] (**) (* explict constructor, /4 depth=?/ is too slow *)
+| #L1 #V1 #T1 #U1 #W1 #l #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
+  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
+  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #X2 #W2 #HXW2 #H #HW12
+  elim (delift_inv_flat1 … H) -H #V2 #Y2 #HV12 #HY2 #H destruct
+  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=7/
+| #L1 #T1 #U1 #W1 #l1 #l2 #_ #_ #IHTU1 #IHUW1 #L2 #d #e #HL1 #HL12
+  elim (IHTU1 … HL1 HL12) -IHTU1 #T2 #U2 #HTU2 #HT12 #HU12
+  elim (IHUW1 … HL1 HL12) -IHUW1 -HL1 -HL12 #Y2 #W2 #HUW2 #HY2 #HW12
+  lapply (delift_mono … HY2 … HU12) -HY2 #H destruct /3 width=5/
+| #L1 #T1 #U11 #U12 #V1 #l #_ #HU112 #_ #IHT1 #IHU12 #L2 #d #e #HL1 #HL12
+  elim (IHT1 … HL1 HL12) -IHT1 #T2 #U21 #HT2 #HT12 #HU121
+  elim (IHU12 … HL1 HL12) -IHU12 -HL1 #U22 #V2 #HU22 #HU122 #_
+  lapply (thin_cpcs_delift_mono … HU112 … HL12 … HU121 … HU122) -HU112 -HL12 -HU121 /3 width=5/
+]
+qed.
+
+lemma snta_ldrop_conf: ∀h,L1,T1,U1,l. ⦃h, L1⦄ ⊢ T1 :[l] U1 →
+                       ∀L2,d,e. ≽ [d, e] L1 → ⇩[d, e] L1 ≡ L2 →
+                       ∃∃T2,U2. ⦃h, L2⦄ ⊢ T2 :[l] U2 &
+                                L1 ⊢ T1 ▼*[d, e] ≡ T2 & L1 ⊢ U1 ▼*[d, e] ≡ U2.
+/3 width=1/ qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_cpcs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_cpcs.etc
new file mode 100644 (file)
index 0000000..9e68edf
--- /dev/null
@@ -0,0 +1,182 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/lstas_lstas.ma".
+include "basic_2/computation/fpbs_lift.ma".
+include "basic_2/computation/fpbg_fleq.ma".
+include "basic_2/equivalence/cpes_cpds.ma".
+include "basic_2/dynamic/snv.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Inductive premises for the preservation results **************************)
+
+definition IH_snv_cpx_lpx: ∀h:sh. sd h → relation3 genv lenv term ≝
+                           λh,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                           ∀T2. ⦃G, L1⦄ ⊢ T1 ➡[h, g] T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
+
+definition IH_da_cpr_lpr: ∀h:sh. sd h → relation3 genv lenv term ≝
+                          λ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.
+
+definition IH_lstas_cpr_lpr: ∀h:sh. sd h → relation3 genv lenv term ≝
+                             λ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, l2] U1 →
+                             ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                             ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*[h, l2] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
+
+(* Properties for the preservation results **********************************)
+
+fact snv_cpr_lpr_aux: ∀h,g,G0,L0,T0.
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
+/3 width=6 by lpr_lpx, cpr_cpx/ qed-.
+
+fact snv_sta_aux: ∀h,g,G0,L0,T0.
+                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                  ∀G,L,T. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L, T⦄ → ⦃G, L⦄ ⊢ T ¡[h, g] →
+                  ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 →
+                  ∀U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ U ¡[h, g].
+/3 width=6 by sta_cpx/ qed-.
+
+fact snv_cpxs_lpx_aux: ∀h,g,G0,L0,T0.
+                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                       ∀T2. ⦃G, L1⦄ ⊢ T1 ➡*[h, g] T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡[h, g] L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
+#h #g #G0 #L0 #T0 #IH #G #L1 #T1 #HLT0 #HT1 #T2 #H
+@(cpxs_ind … H) -T2 /4 width=6 by fpbg_fpbs_trans, cpxs_fpbs/
+qed-.
+
+fact snv_cprs_lpr_aux: ∀h,g,G0,L0,T0.
+                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                       ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L2⦄ ⊢ T2 ¡[h, g].
+/3 width=10 by snv_cpxs_lpx_aux, cprs_cpxs, lpr_lpx/ qed-.
+
+fact snv_lstas_aux: ∀h,g,G0,L0,T0.
+                    (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                    ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 → ⦃G, L1⦄ ⊢ U1 ¡[h, g].
+/3 width=12 by snv_cpxs_lpx_aux, lstas_cpxs/ qed-.
+
+fact da_cprs_lpr_aux: ∀h,g,G0,L0,T0.
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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
+@(cprs_ind … H) -T2 /4 width=10 by snv_cprs_lpr_aux, fpbg_fpbs_trans, cprs_fpbs/
+qed-.
+
+fact da_cpcs_aux: ∀h,g,G0,L0,T0.
+                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                  (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                  ∀G,L,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L, T1⦄ → ⦃G, L⦄ ⊢ T1 ¡[h, g] →
+                  ∀T2. ⦃G0, L0, T0⦄ >≡[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
+elim (cpcs_inv_cprs … H) -H /4 width=18 by da_cprs_lpr_aux, da_mono/
+qed-.
+
+fact sta_cpr_lpr_aux: ∀h,g,G0,L0,T0.
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                      ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T1⦄ → ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                      ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l+1 →
+                      ∀U1. ⦃G, L1⦄ ⊢ T1 •[h] U1 →
+                      ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                      ∃∃U2. ⦃G, L2⦄ ⊢ T2 •[h] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
+#h #g #G0 #L0 #T0 #IH #G #L1 #T1 #H01 #HT1 #l #Hl #U1 #HTU1 #T2 #HT12 #L2 #HL12
+elim (IH … H01 … 1 … Hl U1 … HT12 … HL12) -H01 -Hl -HT12 -HL12
+/3 width=3 by lstas_inv_SO, sta_lstas, ex2_intro/
+qed-.
+
+fact lstas_cprs_lpr_aux: ∀h,g,G0,L0,T0.
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                         ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 →
+                         ∀T2. ⦃G, L1⦄ ⊢ T1 ➡* T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                         ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*[h, l2] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
+#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G #L1 #T1 #H01 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 #H
+@(cprs_ind … H) -T2 [ /2 width=10 by/ ]
+#T #T2 #HT1T #HTT2 #IHT1 #L2 #HL12
+elim (IHT1 L1) // -IHT1 #U #HTU #HU1
+elim (IH1 … Hl21 … HTU … HTT2 … HL12) -IH1 -HTU -HTT2
+[2: /3 width=12 by da_cprs_lpr_aux/
+|3: /3 width=10 by snv_cprs_lpr_aux/
+|4: /3 width=5 by fpbg_fpbs_trans, cprs_fpbs/
+] -G0 -L0 -T0 -T1 -T -l1
+/4 width=5 by lpr_cpcs_conf, cpcs_trans, ex2_intro/
+qed-.
+
+fact lstas_cpcs_lpr_aux: ∀h,g,G0,L0,T0.
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                         (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                         ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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, l] U1 →
+                         ∀T2. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G, L1, T2⦄ → ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
+                         ∀l2. l ≤ l2 → ⦃G, L1⦄ ⊢ T2 ▪[h, g] l2 → ∀U2. ⦃G, L1⦄ ⊢ T2 •*[h, 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
+elim (cpcs_inv_cprs … H) -H #T #H1 #H2
+elim (lstas_cprs_lpr_aux … H01 HT1 … Hl1 HTl1 … HTU1 … H1 … HL12) -T1 /2 width=1 by/ #W1 #H1 #HUW1
+elim (lstas_cprs_lpr_aux … H02 HT2 … Hl2 HTl2 … HTU2 … H2 … HL12) -T2 /2 width=1 by/ #W2 #H2 #HUW2 -L0 -T0
+lapply (lstas_mono … H1 … H2) -h -T -l #H destruct /2 width=3 by cpcs_canc_dx/
+qed-.
+
+fact lstas_cpds_aux: ∀h,g,G0,L0,T0.
+                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                     ∀G,L,T1. ⦃G0, L0, T0⦄ >≡[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, l2] U1 → ∀T2. ⦃G, L⦄ ⊢ T1 •*➡*[h, g] T2 →
+                     ∃∃U2,l. l ≤ l2 & ⦃G, L⦄ ⊢ T2 •*[h, l] U2 & ⦃G, L⦄ ⊢ U1 •*⬌*[h, g] U2.
+#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G #L #T1 #H01 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 * #T #l0 #l #Hl0 #H #HT1T #HTT2
+lapply (da_mono … H … Hl1) -H #H destruct
+lapply (lstas_da_conf … HTU1 … Hl1) #Hl12
+elim (le_or_ge l2 l) #Hl2
+[ lapply (lstas_conf_le … HTU1 … HT1T) -HT1T
+  /5 width=11 by cpds_cpes_dx, monotonic_le_minus_l, ex3_2_intro, ex4_3_intro/
+| lapply (lstas_da_conf … HT1T … Hl1) #Hl1l
+  lapply (lstas_conf_le … HT1T … HTU1) -HTU1 // #HTU1
+  elim (lstas_cprs_lpr_aux … IH3 IH2 IH1 … Hl1l … HTU1 … HTT2 L) -IH2 -IH1 -Hl1l -HTU1 -HTT2
+  /3 width=12 by snv_lstas_aux, cpcs_cpes, fpbg_fpbs_trans, lstas_fpbs, monotonic_le_minus_l, ex3_2_intro/
+]
+qed-.
+
+fact cpds_cpr_lpr_aux: ∀h,g,G0,L0,T0.
+                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                       (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                       ∀G,L1,T1. ⦃G0, L0, T0⦄ >≡[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.
+#h #g #G0 #L0 #T0 #IH2 #IH1 #G #L1 #T1 #H01 #HT1 #U1 * #W1 #l1 #l2 #Hl21 #Hl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
+elim (IH1 … H01 … HTW1 … HT12 … HL12) -IH1 // #W2 #HTW2 #HW12
+lapply (IH2 … H01 … Hl1 … HT12 … HL12) -L0 -T0 // -T1
+lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
+lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
+elim (cpcs_inv_cprs … H) -H /3 width=7 by ex4_3_intro, ex2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_da_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_da_lpr.etc
new file mode 100644 (file)
index 0000000..119a402
--- /dev/null
@@ -0,0 +1,93 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/lsubd_da.ma".
+include "basic_2/computation/cpds_cpds.ma".
+include "basic_2/dynamic/snv_aaa.ma".
+include "basic_2/dynamic/snv_cpcs.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties on degree assignment for terms ********************************)
+
+fact da_cpr_lpr_aux: ∀h,g,G0,L0,T0.
+                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                     (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[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 #IH2 #IH1 #G1 #L1 * * [|||| * ]
+[ #k #_ #_ #_ #_ #l #H2 #X3 #H3 #L2 #_ -IH2 -IH1
+  lapply (da_inv_sort … H2) -H2
+  lapply (cpr_inv_sort1 … H3) -H3 #H destruct /2 width=1 by da_sort/
+| #i #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
+  elim (snv_inv_lref … H1) -H1 #I0 #K0 #X0 #H #HX0
+  elim (da_inv_lref … H2) -H2 * #K1 [ #V1 | #W1 #l1 ] #HLK1 [ #HV1 | #HW1 #H ] destruct
+  lapply (ldrop_mono … H … HLK1) -H #H destruct
+  elim (cpr_inv_lref1 … H3) -H3
+  [1,3: #H destruct
+    lapply (fqup_lref … G1 … HLK1)
+    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
+    elim (lpr_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
+    /4 width=10 by da_ldef, da_ldec, fqup_fpbg/
+  |2,4: * #K0 #V0 #W0 #H #HVW0 #HW0
+    lapply (ldrop_mono … H … HLK1) -H #H destruct
+    lapply (fqup_lref … G1 … HLK1)
+    elim (lpr_ldrop_conf … HLK1 … HL12) -HLK1 -HL12 #X #H #HLK2
+    elim (lpr_inv_pair1 … H) -H #K2 #V2 #HK12 #_ #H destruct
+    lapply (ldrop_fwd_drop2 … HLK2) -V2
+    /4 width=8 by da_lift, fqup_fpbg/
+  ]
+| #p #_ #_ #HT0 #H1 destruct -IH2 -IH1
+  elim (snv_inv_gref … H1)
+| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
+  elim (snv_inv_bind … H1) -H1 #_ #HT1
+  lapply (da_inv_bind … H2) -H2
+  elim (cpr_inv_bind1 … H3) -H3 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    /4 width=9 by da_bind, fqup_fpbg, lpr_pair/
+  | #T2 #HT12 #HT2 #H1 #H2 destruct
+    /4 width=11 by da_inv_lift, fqup_fpbg, lpr_pair, ldrop_drop/
+  ]
+| #V1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct
+  elim (snv_inv_appl … H1) -H1 #b0 #W1 #W0 #T0 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HT10
+  lapply (da_inv_flat … H2) -H2 #Hl
+  elim (cpr_inv_appl1 … H3) -H3 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct -IH2 /4 width=7 by da_flat, fqup_fpbg/
+  | #b #V2 #W #W2 #U1 #U2 #HV12 #HW2 #HU12 #H1 #H2 destruct
+    elim (snv_inv_bind … HT1) -HT1 #HW #HU1
+    lapply (da_inv_bind … Hl) -Hl #Hl
+    elim (cpds_inv_abst1 … HT10) -HT10 #W3 #U3 #HW3 #_ #H destruct -U3
+    lapply (cprs_div … HW3 … HW10) -W3 #HWW1
+    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #H
+    elim (snv_fwd_da … HW) #l1 #Hl1
+    lapply (snv_lstas_aux … IH2 … HV1 … 1 … Hl0 W1 ?) /2 width=2 by fqup_fpbg, sta_lstas/ #HW1
+    lapply (da_cpcs_aux … IH2 IH1 … Hl1 … H … HWW1) -H
+    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
+    lapply (IH1 … HV1 … Hl0 … HV12 … HL12) -HV1 -Hl0 -HV12 [ /2 by fqup_fpbg/ ] #Hl0
+    lapply (IH1 … Hl1 … HW2 … HL12) -Hl1 // /2 width=1 by fqup_fpbg/ -HW
+    lapply (IH1 … HU1 … Hl … HU12 (L2.ⓛW2) ?) -IH1 -HU1 -Hl -HU12 [1,2: /2 by fqup_fpbg, lpr_pair/ ] -HL12 -HW2
+    /4 width=6 by da_bind, lsubd_da_trans, lsubd_abbr/
+  | #b #V #V2 #W #W2 #U1 #U2 #HV1 #HV2 #HW2 #HU12 #H1 #H2 destruct -IH2 -V -W0 -T0 -l0 -HV1 -HVW1
+    elim (snv_inv_bind … HT1) -HT1 #_
+    lapply (da_inv_bind … Hl) -Hl
+    /5 width=9 by da_bind, da_flat, fqup_fpbg, lpr_pair/
+  ]
+| #W1 #T1 #HG0 #HL0 #HT0 #H1 #l #H2 #X3 #H3 #L2 #HL12 destruct -IH2
+  elim (snv_inv_cast … H1) -H1 #U1 #l0 #HW1 #HT1 #Hl0 #HTU1 #HUW1
+  lapply (da_inv_flat … H2) -H2 #Hl
+  elim (cpr_inv_cast1 … H3) -H3
+  [ * #W2 #T2 #HW12 #HT12 #H destruct /4 width=7 by da_flat, fqup_fpbg/
+  | /3 width=7 by fqup_fpbg/
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lpx.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lpx.etc
new file mode 100644 (file)
index 0000000..0839b45
--- /dev/null
@@ -0,0 +1,135 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/dynamic/snv_lift.ma".
+include "basic_2/dynamic/snv_cpcs.ma".
+include "basic_2/dynamic/lsubsv_snv.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties on context-free parallel reduction for local environments *****)
+
+fact snv_cpx_lpx_aux: ∀h,g,G0,L0,T0.
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                      (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                      ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_snv_cpx_lpx h g G1 L1 T1.
+#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
+[ #k #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #_ destruct -IH3 -IH2 -IH1 -H1
+  elim (cpx_inv_sort1 … H2) -H2 // * //
+| #i #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2
+  elim (snv_inv_lref … H1) -H1 #I #K1 #V1 #HLK1 #HV1
+  elim (lpx_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+  elim (lpx_inv_pair1 … H) -H #K2 #V2 #HK12 #HV12 #H destruct
+  lapply (fqup_lref … G1 … HLK1) #HKL
+  elim (cpx_inv_lref1 … H2) -H2
+  [ #H destruct -HLK1 /4 width=10 by fqup_fpbg, snv_lref/
+  | * #I0 #K0 #V0 #W0 #H #HVW0 #W0 -HV12
+    lapply (ldrop_mono … H … HLK1) -HLK1 -H #H destruct
+    lapply (ldrop_fwd_drop2 … HLK2) -HLK2 /4 width=8 by fqup_fpbg, snv_lift/
+  ]
+| #p #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2 -IH1
+  elim (snv_inv_gref … H1)
+| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct -IH3 -IH2
+  elim (snv_inv_bind … H1) -H1 #HV1 #HT1
+  elim (cpx_inv_bind1 … H2) -H2 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct /4 width=8 by fqup_fpbg, snv_bind, lpx_pair/
+  | #T2 #HT12 #HXT2 #H1 #H2 destruct -HV1
+    /4 width=10 by fqup_fpbg, snv_inv_lift, lpx_pair, ldrop_drop/
+  ]
+| #V1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct
+  elim (snv_inv_appl … H1) -H1 #a #W10 #W1 #U1 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HTU1
+  elim (cpx_inv_appl1 … H2) -H2 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    lapply (IH1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2
+    lapply (IH1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ #HT2
+(*    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #H2l0
+    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HVW1 … HV12 … HL12) -Hl0 -HVW1 -HV12 /2 width=1 by fqup_fpbg/ -HV1 #W2 #HVW2 #HW12
+    elim (cpds_cpr_lpr_aux … IH2 IH3 … HTU1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -HT12 -HTU1 #X #HTU2 #H
+    elim (cprs_inv_abst1 … H) -H #W20 #U2 #HW120 #_ #H destruct
+    lapply (lpr_cprs_conf … HL12 … HW10) -L1 #HW10
+    lapply (cpcs_cprs_strap1 … HW10 … HW120) -W1 #HW120
+    lapply (cpcs_canc_sn … HW12 HW120) -W10 #HW20
+    elim (cpcs_inv_cprs … HW20) -HW20 #W0 #HW20 #HW200
+    lapply (cpds_cprs_trans … (ⓛ{a}W0.U2) HTU2 ?)
+    /2 width=7 by snv_appl, cprs_bind/ *)
+  | #b #V2 #W20 #W2 #T20 #T2 #HV12 #HW202 #HT202 #H1 #H2 destruct
+    elim (snv_inv_bind … HT1) -HT1 #HW20 #HT20
+    elim (cpds_inv_abst1 … HTU1) -HTU1 #W30 #T30 #HW230 #_ #H destruct -T30
+    lapply (cprs_div … HW10 … HW230) -W30 #HW120
+    lapply (snv_sta_aux … IH1 … Hl0 … HVW1) /2 width=1 by fqup_fpbg/ #HW10
+    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #HlW10
+    elim (snv_fwd_da … HW20) #l #Hl
+    lapply (da_cpcs_aux … IH1 IH2 … HlW10 … Hl … HW120) // -HlW10
+    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
+(*    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HlV2
+    lapply (IH2 … Hl … HW202 … HL12) /2 width=1 by fqup_fpbg/ #HlW2
+    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HVW1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #W3 #HV2W3 #HW103
+    lapply (da_sta_conf … HV2W3 … HlV2) <minus_plus_m_m #HlW3
+    lapply (cpcs_cpr_strap1 … HW120 … HW202) -HW120 #HW102
+    lapply (lpr_cpcs_conf … HL12 … HW102) -HW102 #HW102
+    lapply (cpcs_canc_sn … HW103 … HW102) -W10 #HW32
+    lapply (IH1 … HV12 … HL12) /2 width=1 by fqup_fpbg/ -HV1 #HV2
+    lapply (IH1 … HW202 … HL12) /2 width=1 by fqup_fpbg/ -HW20 #HW2
+    lapply (IH1 … HT20 … HT202 … (L2.ⓛW2) ?) /2 width=1 by fqup_fpbg, lpr_pair/ -HT20 #HT2
+    lapply (snv_sta_aux … IH4 … HlV2 … HV2W3)
+    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/ #HW3
+    lapply (lsubsv_snv_trans … HT2 (L2.ⓓⓝW2.V2) ?) -HT2 /3 width=3 by snv_bind, snv_cast/
+    @(lsubsv_abbr … l) /3 width=7 by fqup_fpbg/ #W #W0 #l0 #Hl0 #HV2W #HW20
+    lapply (lstas_sta_conf_pos … HV2W3 … HV2W) -HV2W #HW3W
+    @(lstas_cpcs_lpr_aux … IH1 IH2 IH3 … HlW3 … HW3W … HlW2 … HW20 … HW32) //
+    [ /3 width=9 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_sta_fpbs/
+    | /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/
+    ] *)
+  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HV02 #HW02 #HT02 #H1 #H2 destruct
+    elim (snv_inv_bind … HT1) -HT1 #HW0 #HT0
+    elim (cpds_inv_abbr_abst … HTU1) -HTU1 #X #HTU0 #HX #H destruct
+    elim (lift_inv_bind1 … HX) -HX #W3 #U3 #HW13 #_ #H destruct
+(*    lapply (lpr_cpr_conf … HL12 … HW10) -HW10 #HW10 
+    elim (cpds_cpr_lpr_aux … IH2 IH3 … HTU0 … HT02 (L2.ⓓW2)) /2 width=1 by fqup_fpbg, lpr_pair/ -HTU0 #X #HTU2 #H
+    elim (cprs_inv_abst1 … H) -H #W #U2 #HW1 #_ #H destruct -U3
+    elim (sta_cpr_lpr_aux … IH3 … HVW1 … HV10 … HL12) /2 width=2 by fqup_fpbg/ -IH3 -HVW1 #X #H1 #H2
+    lapply (cpcs_canc_sn … H2 HW10) -W10 #H2
+    elim (lift_total X 0 1) #W20 #H3
+    lapply (sta_lift … H1 (L2.ⓓW2) … HV02 … H3) /2 width=2 by ldrop_drop/ -H1 #HVW20
+    lapply (cpcs_lift … (L2.ⓓW2) … H3 … HW13 H2) /2 width=2 by ldrop_drop/ -HW13 -H3 -H2 #HW320
+    lapply (cpcs_cprs_strap1 … HW320 … HW1) -W3 #HW20
+    elim (cpcs_inv_cprs … HW20) -HW20 #W3 #HW203 #HW3
+    lapply (cpds_cprs_trans … (ⓛ{a}W3.U2) HTU2 ?) /2 width=1 by cprs_bind/ -HW3 -HTU2 #HTU2
+    lapply (IH2 … Hl0 … HV10 … HL12) /2 width=1 by fqup_fpbg/ -IH2 -Hl0 #Hl0
+    lapply (da_lift … Hl0 (L2.ⓓW2) … HV02) /2 width=2 by ldrop_drop/ -Hl0 #Hl0
+    lapply (IH1 … HW02 … HL12) /2 width=1 by fqup_fpbg/ -HW0 #HW2
+    lapply (IH1 … HV10 … HL12) /2 width=1 by fqup_fpbg/ -HV1 -HV10 #HV0
+    lapply (IH1 … HT02 (L2.ⓓW2) ?) /2 width=1 by fqup_fpbg, lpr_pair/ -L1 #HT2
+    lapply (snv_lift … HV0 (L2.ⓓW2) … HV02) /3 width=7 by snv_bind, snv_appl, ldrop_drop/ *)
+  ]
+| #W1 #T1 #HG0 #HL0 #HT0 #H1 #X #H2 #L2 #HL12 destruct
+  elim (snv_inv_cast … H1) -H1 #U1 #l0 #HW1 #HT1 #Hl0 #HTU1 #HUW1
+  elim (cpx_inv_cast1 … H2) -H2
+  [ * #W2 #T2 #HW12 #HT12 #H destruct
+(*    lapply (cpcs_cprs_strap1 … HUW1 W2 ?) /2 width=1 by cpr_cprs/ -HUW1 #H1
+*)    lapply (IH1 … HW12 … HL12) /2 width=1 by fqup_fpbg/ -HW1 -HW12 #HW2
+    lapply (IH1 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -IH1 #HT2
+(*    elim (sta_cpr_lpr_aux … IH3 … Hl0 … HTU1 … HT12 … HL12) /2 width=2 by fqup_fpbg/ -IH3 -HTU1 #U2 #HTU2 #HU12
+    lapply (IH2 … Hl0 … HT12 … HL12) /2 width=1 by fqup_fpbg/ -IH2 -HT1 -HT12 -Hl0 #Hl0
+    /4 width=7 by snv_cast, lpr_cpcs_conf, cpcs_canc_sn/ *)
+  | #H -IH3 -IH2 -HW1 -HTU1 -HUW1
+    lapply (IH1 … H … HL12) -IH1 -H -HL12 /2 width=1 by fqup_fpbg/
+  | #H -IH3 -IH2 -HTU1 -HUW1
+    lapply (IH1 … H … HL12) -IH1 -H -HL12 /2 width=1 by fqup_fpbg/
+  ]
+]
+[4: @snv_cast //
+qed-.
+snv_lstas, snv_cpr_lpr
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lstas_lpr.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv/snv_lstas_lpr.etc
new file mode 100644 (file)
index 0000000..3e1ed02
--- /dev/null
@@ -0,0 +1,150 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/cpds_cpds.ma".
+include "basic_2/dynamic/snv_aaa.ma".
+include "basic_2/dynamic/snv_cpcs.ma".
+include "basic_2/dynamic/lsubsv_lstas.ma".
+
+(* STRATIFIED NATIVE VALIDITY FOR TERMS *************************************)
+
+(* Properties on sn parallel reduction for local environments ***************)
+
+fact lstas_cpr_lpr_aux: ∀h,g,G0,L0,T0.
+                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_snv_cpx_lpx h g G1 L1 T1) →
+                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_da_cpr_lpr h g G1 L1 T1) →
+                        (∀G1,L1,T1. ⦃G0, L0, T0⦄ >≡[h, g] ⦃G1, L1, T1⦄ → IH_lstas_cpr_lpr h g G1 L1 T1) →
+                        ∀G1,L1,T1. G0 = G1 → L0 = L1 → T0 = T1 → IH_lstas_cpr_lpr h g G1 L1 T1.
+#h #g #G0 #L0 #T0 #IH3 #IH2 #IH1 #G1 #L1 * * [|||| * ]
+[ #k #_ #_ #_ #_ #l1 #l2 #_ #_ #X2 #H2 #X3 #H3 #L2 #_ -IH3 -IH2 -IH1
+  >(lstas_inv_sort1 … H2) -X2
+  >(cpr_inv_sort1 … H3) -X3 /2 width=3 by ex2_intro/
+| #i #HG0 #HL0 #HT0 #H1 #l1 #l2 @(nat_ind_plus … l2) -l2 [ #_ | #l2 #_ #Hl21 ] #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3
+  [ lapply (lstas_inv_O … H2) -H2 #H destruct -IH1 -H1 -l1 /4 width=5 by lpr_cpcs_conf, cpr_cpcs_dx, ex2_intro/ ]
+  elim (snv_inv_lref … H1) -H1 #I0 #K0 #X0 #HK0 #HX0
+  elim (da_inv_lref … Hl1) -Hl1 * #K1 [ #V1 | #W1 #l0 ] #HLK1 [ #HVl1 | #HWl1 #H destruct ]
+  lapply (ldrop_mono … HK0 … HLK1) -HK0 #H destruct
+  elim (lstas_inv_lref1 … H2) -H2 * #K0 #V0 #W0 [2,4: #X0 ] #HK0 [1,2: #_ -X0 ] #HVW0 #HX2
+  lapply (ldrop_mono … HK0 … HLK1) -HK0 #H destruct
+  [ lapply (le_plus_to_le_r … Hl21) -Hl21 #Hl21 ]
+  lapply (fqup_lref … G1 … HLK1) #HKV1
+  elim (lpr_ldrop_conf … HLK1 … HL12) -HL12 #X #H #HLK2
+  elim (lpr_inv_pair1 … H) -H #K2 [ #W2 | #V2 ] #HK12 [ #HW12 | #HV12 ] #H destruct
+  lapply (ldrop_fwd_drop2 … HLK2) #H2
+  elim (cpr_inv_lref1 … H3) -H3
+  [1,3: #H destruct -HLK1
+  |2,4: * #K0 #V0 #X0 #H #HVX0 #HX0
+        lapply (ldrop_mono … H … HLK1) -H -HLK1 #H destruct
+  ]
+  [ lapply (IH2 … HWl1 … HW12 … HK12) /2 width=1 by fqup_fpbg/ -IH2 #H
+    elim (da_inv_sta … H) -H
+    elim (IH1 … HWl1 … HVW0 … HW12 … HK12) -IH1 -HVW0 /2 width=1 by fqup_fpbg/ #V2 #HWV2 #HV2
+    elim (lift_total V2 0 (i+1))
+    /3 width=12 by cpcs_lift, lstas_ldec, ex2_intro/
+  | elim (IH1 … HVl1 … HVW0 … HV12 … HK12) -IH1 -HVl1 -HVW0 -HV12 -HK12 -IH2 /2 width=1 by fqup_fpbg/ #W2 #HVW2 #HW02
+    elim (lift_total W2 0 (i+1))
+    /4 width=12 by cpcs_lift, lstas_ldef, ex2_intro/
+  | elim (IH1 … HVl1 … HVW0 … HVX0 … HK12) -IH1 -HVl1 -HVW0 -HVX0 -HK12 -IH2 -V2 /2 width=1 by fqup_fpbg/ -l1 #W2 #HXW2 #HW02
+    elim (lift_total W2 0 (i+1))
+    /3 width=12 by cpcs_lift, lstas_lift, ex2_intro/
+  ]
+| #p #_ #_ #HT0 #H1 destruct -IH3 -IH2 -IH1
+  elim (snv_inv_gref … H1)
+| #a #I #V1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 #Hl21 #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3 -IH2
+  elim (snv_inv_bind … H1) -H1 #_ #HT1
+  lapply (da_inv_bind … Hl1) -Hl1 #Hl1
+  elim (lstas_inv_bind1 … H2) -H2 #U1 #HTU1 #H destruct
+  elim (cpr_inv_bind1 … H3) -H3 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct
+    elim (IH1 … Hl1 … HTU1 … HT12 (L2.ⓑ{I}V2)) -IH1 -Hl1 -HTU1 -HT12 /2 width=1 by fqup_fpbg, lpr_pair/ -T1
+    /4 width=5 by cpcs_bind2, lpr_cpr_conf, lstas_bind, ex2_intro/
+  | #T3 #HT13 #HXT3 #H1 #H2 destruct
+    elim (IH1 … Hl1 … HTU1 … HT13 (L2.ⓓV1)) -IH1 -Hl1 -HTU1 -HT13 /2 width=1 by fqup_fpbg, lpr_pair/ -T1 -HL12 #U3 #HTU3 #HU13
+    elim (lstas_inv_lift1 … HTU3 L2 … HXT3) -T3
+    /5 width=8 by cpcs_cpr_strap1, cpcs_bind1, cpr_zeta, ldrop_drop, ex2_intro/
+  ]
+| #V1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 #Hl21 #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct
+  elim (snv_inv_appl … H1) -H1 #a #W1 #W10 #U10 #l0 #HV1 #HT1 #Hl0 #HVW1 #HW10 #HTU10
+  lapply (da_inv_flat … Hl1) -Hl1 #Hl1
+  elim (lstas_inv_appl1 … H2) -H2 #U1 #HTU1 #H destruct
+  elim (cpr_inv_appl1 … H3) -H3 *
+  [ #V2 #T2 #HV12 #HT12 #H destruct -a -l0 -W1 -W10 -U10 -HV1 -IH3 -IH2
+    elim (IH1 … Hl1 … HTU1 … HT12 … HL12) -IH1 -Hl1 -HTU1
+    /4 width=5 by fqup_fpbg, cpcs_flat, lpr_cpr_conf, lstas_appl, ex2_intro/
+  | #b #V2 #W2 #W3 #T2 #T3 #HV12 #HW23 #HT23 #H1 #H2 destruct
+    elim (snv_inv_bind … HT1) -HT1 #HW2 #HT2
+    lapply (da_inv_bind … Hl1) -Hl1 #Hl1
+    elim (lstas_inv_bind1 … HTU1) -HTU1 #U2 #HTU2 #H destruct
+    elim (cpds_inv_abst1 … HTU10) -HTU10 #W0 #U0 #HW20 #_ #H destruct
+    lapply (cprs_div … HW10 … HW20) -W0 #HW12
+    lapply (da_sta_conf … HVW1 … Hl0) <minus_plus_m_m #H
+    elim (snv_fwd_da … HW2) #l #Hl
+    lapply (snv_lstas_aux … IH3 … HV1 … 1 … Hl0 W1 ?) /2 width=1 by fqup_fpbg, sta_lstas/ #HW1
+    lapply (da_cpcs_aux … IH3 IH2 … H … Hl … HW12) // -H
+    /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, sta_fpbs/ #H destruct
+    lapply (snv_cpr_lpr_aux … IH3 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2
+    lapply (IH2 … Hl0 … HV12 … HL12) /2 width=1 by fqup_fpbg/ #HV2l
+    elim (IH1 … 1 … Hl0 … W1 … HV12 … HL12) /2 width=1 by fqup_fpbg, sta_lstas/ -HVW1 #W4 #H #HW14
+    lapply (lstas_inv_SO … H) #HV2W4
+    lapply (da_sta_conf … HV2W4 … HV2l) <minus_plus_m_m #HW4l
+    lapply (snv_lstas_aux … IH3 … HV2 … HV2l … H) -H /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/ #HW4
+    lapply (snv_cpr_lpr_aux … IH3 … HW23 … HL12) /2 width=1 by fqup_fpbg/ #HW3
+    lapply (IH2 … Hl … HW23 … HL12) /2 width=1 by fqup_fpbg/ #HW3l
+    elim (IH1 … Hl1 … HTU2 … HT23 (L2.ⓛW3)) -HTU2 /2 width=1 by fqup_fpbg, lpr_pair/ #U3 #HTU3 #HU23
+    lapply (cpcs_cpr_strap1 … HW12 … HW23) #H
+    lapply (lpr_cpcs_conf … HL12 … H) -H #H
+    lapply (cpcs_canc_sn … HW14 H) -H #HW43
+    elim (lsubsv_lstas_trans … g … HTU3 … Hl21 … (L2.ⓓⓝW3.V2)) -HTU3
+    [ #U4 #HT3U4 #HU43 -HW12 -HW3 -HW3l -W4 -IH3 -IH2
+      @(ex2_intro … (ⓓ{b}ⓝW3.V2.U4)) /2 width=1 by lstas_bind/ -HT3U4
+      @(cpcs_canc_dx … (ⓓ{b}ⓝW3.V2.U3)) /2 width=1 by cpcs_bind_dx/ -HU43
+      @(cpcs_cpr_strap1 … (ⓐV2.ⓛ{b}W3.U3)) /2 width=1 by cpr_beta/
+      /4 width=3 by cpcs_flat, cpcs_bind2, lpr_cpr_conf/
+    | -U3
+      @(lsubsv_abbr … l) /3 width=7 by fqup_fpbg/
+      #W #W0 #l0 #Hl0 #HV2W #HW30
+      lapply (lstas_sta_conf_pos … HV2W4 … HV2W) -HV2W #HW4W
+      @(lstas_cpcs_lpr_aux … IH3 IH2 IH1 … Hl0 … HW4W … Hl0 … HW30 … HW43) //
+      [ /3 width=9 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_sta_fpbs/
+      | /3 width=5 by fpbg_fpbs_trans, fqup_fpbg, cpr_lpr_fpbs/
+      ]
+    | -IH3 -IH1 /3 width=9 by fqup_fpbg, lpr_pair/
+    ]
+  | #b #V0 #V2 #W0 #W2 #T0 #T2 #HV10 #HV02 #HW02 #HT02 #H1 #H2 destruct -a -l0 -W1 -W10 -HV1 -IH3 -IH2
+    elim (snv_inv_bind … HT1) -HT1 #_ #HT0
+    lapply (da_inv_bind … Hl1) -Hl1 #Hl1
+    elim (lstas_inv_bind1 … HTU1) -HTU1 #U0 #HTU0 #H destruct
+    elim (IH1 … Hl1 … HTU0 … HT02 (L2.ⓓW2)) -IH1 -Hl1 -HTU0 /2 width=1 by fqup_fpbg, lpr_pair/ -T0 #U2 #HTU2 #HU02
+    lapply (lpr_cpr_conf … HL12 … HV10) -HV10 #HV10
+    lapply (lpr_cpr_conf … HL12 … HW02) -L1 #HW02
+    lapply (cpcs_bind2 b … HW02 … HU02) -HW02 -HU02 #HU02
+    lapply (cpcs_flat … HV10 … HU02 Appl) -HV10 -HU02 #HU02
+    lapply (cpcs_cpr_strap1 … HU02 (ⓓ{b}W2.ⓐV2.U2) ?)
+    /4 width=3 by lstas_appl, lstas_bind, cpr_theta, ex2_intro/
+  ]
+| #W1 #T1 #HG0 #HL0 #HT0 #H1 #l1 #l2 @(nat_ind_plus … l2) -l2 [ #_ | #l2 #_ #Hl21 ] #Hl1 #X2 #H2 #X3 #H3 #L2 #HL12 destruct -IH3 -IH2
+  [ lapply (lstas_inv_O … H2) -H2 #H destruct -IH1 -H1 -l1 /4 width=5 by lpr_cpcs_conf, cpr_cpcs_dx, ex2_intro/ ]
+  elim (snv_inv_cast … H1) -H1 #U1 #l #_ #HT1 #_ #_ #_ -U1 -l
+  lapply (da_inv_flat … Hl1) -Hl1 #Hl1
+  lapply (lstas_inv_cast1 … H2) -H2 #HTU1
+  elim (cpr_inv_cast1 … H3) -H3
+  [ * #U2 #T2 #_ #HT12 #H destruct
+    elim (IH1 … Hl1 … HTU1 … HT12 … HL12) -IH1 -Hl1 -HTU1 -HL12
+    /3 width=3 by fqup_fpbg, lstas_cast, ex2_intro/
+  | #HT1X3
+    elim (IH1 … Hl1 … HTU1 … HT1X3 … HL12) -IH1 -Hl1 -HTU1 -HL12
+    /2 width=3 by fqup_fpbg, ex2_intro/
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv_preserve.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/snv_preserve.etc
new file mode 100644 (file)
index 0000000..8da0347
--- /dev/null
@@ -0,0 +1,78 @@
+lemma da_cpcs: ∀h,g,G,L,T1. ⦃G, L⦄ ⊢ T1 ¡[h, g] →
+               ∀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 #G #L #T1 #HT1 #T2 #HT2 #l1 #Hl1 #l2 #Hl2 #H
+elim (cpcs_inv_cprs … H) -H /3 width=12 by da_cprs_lpr, da_mono/
+qed-.
+
+lemma sta_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                   ∀l. ⦃G, L1⦄ ⊢ T1 ▪[h, g] l+1 →
+                   ∀U1. ⦃G, L1⦄ ⊢ T1 •[h] U1 →
+                   ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                   ∃∃U2. ⦃G, L2⦄ ⊢ T2 •[h] U2 & ⦃G, L2⦄ ⊢ U1 ⬌* U2.
+#h #g #G #L1 #T1 #HT1 #l #Hl #U1 #HTU1 #T2 #HT12 #L2 #HL12
+elim (lstas_cpr_lpr  … 1 … Hl U1 … HT12 … HL12) -Hl -HT12 -HL12
+/3 width=3 by lstas_inv_SO, sta_lstas, ex2_intro/
+qed-.
+
+lemma snv_sta: ∀h,g,G,L,T. ⦃G, L⦄ ⊢ T ¡[h, g] →
+               ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 →
+               ∀U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ U ¡[h, g].
+/3 width=7 by lstas_inv_SO, sta_lstas, snv_lstas/ qed-.
+
+lemma lstas_cpds: ∀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, l2] U1 → ∀T2. ⦃G, L⦄ ⊢ T1 •*➡*[h, g] T2 →
+                  ∃∃U2,l. l ≤ l2 & ⦃G, L⦄ ⊢ T2 •*[h, l] U2 & ⦃G, L⦄ ⊢ U1 •*⬌*[h, g] U2.
+#h #g #G #L #T1 #HT1 #l1 #l2 #Hl21 #Hl1 #U1 #HTU1 #T2 * #T #l0 #l #Hl0 #H #HT1T #HTT2
+lapply (da_mono … H … Hl1) -H #H destruct
+lapply (lstas_da_conf … HTU1 … Hl1) #Hl12
+elim (le_or_ge l2 l) #Hl2
+[ lapply (lstas_conf_le … HTU1 … HT1T) -HT1T //
+  /5 width=11 by cpds_cpes_dx, monotonic_le_minus_l, ex3_2_intro, ex4_3_intro/
+| lapply (lstas_da_conf … HT1T … Hl1) #Hl1l
+  lapply (lstas_conf_le … HT1T … HTU1) -HTU1 // #HTU1
+  elim (lstas_cprs_lpr … Hl1l … HTU1 … HTT2 L) -Hl1l -HTU1 -HTT2
+  /3 width=7 by snv_lstas, cpcs_cpes, monotonic_le_minus_l, ex3_2_intro/
+]
+qed-.
+
+lemma cpds_cpr_lpr: ∀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.
+#h #g #G #L1 #T1 #HT1 #U1 * #W1 #l1 #l2 #Hl21 #Hl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
+elim (lstas_cpr_lpr … Hl1 … HTW1 … HT12 … HL12) // #W2 #HTW2 #HW12
+lapply (da_cpr_lpr … Hl1 … HT12 … HL12) // -T1
+lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
+lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
+elim (cpcs_inv_cprs … H) -H /3 width=7 by ex4_3_intro, ex2_intro/
+qed-.
+
+(* Note: missing da_scpds_lpr, da_scpes *)
+
+lemma scpds_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                     ∀U1,l. ⦃G, L1⦄ ⊢ T1 •*➡*[h, g, l] U1 →
+                     ∀T2. ⦃G, L1⦄ ⊢ T1 ➡ T2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                     ∃∃U2. ⦃G, L2⦄ ⊢ T2 •*➡*[h, g, l] U2 & ⦃G, L2⦄ ⊢ U1 ➡* U2.
+#h #g #G #L1 #T1 #HT1 #U1 #l2 * #W1 #l1 #Hl21 #HTl1 #HTW1 #HWU1 #T2 #HT12 #L2 #HL12
+elim (lstas_cpr_lpr … HTl1 … HTW1 … HT12 … HL12) // #W2 #HTW2 #HW12
+lapply (da_cpr_lpr … HTl1 … HT12 … HL12) // -T1
+lapply (lpr_cprs_conf … HL12 … HWU1) -L1 #HWU1
+lapply (cpcs_canc_sn … HW12 HWU1) -W1 #H
+elim (cpcs_inv_cprs … H) -H /3 width=6 by ex4_2_intro, ex2_intro/
+qed-.
+
+lemma scpes_cpr_lpr: ∀h,g,G,L1,T1. ⦃G, L1⦄ ⊢ T1 ¡[h, g] →
+                     ∀T2. ⦃G, L1⦄ ⊢ T2 ¡[h, g] →
+                     ∀l1,l2. ⦃G, L1⦄ ⊢ T1 •*⬌*[h, g, l1, l2] T2 →
+                     ∀U1. ⦃G, L1⦄ ⊢ T1 ➡ U1 → ∀U2. ⦃G, L1⦄ ⊢ T2 ➡ U2 → ∀L2. ⦃G, L1⦄ ⊢ ➡ L2 →
+                     ⦃G, L2⦄ ⊢ U1 •*⬌*[h, g, l1, l2] U2.
+#h #g #G #L1 #T1 #HT1 #T2 #HT2 #l1 #l2 * #T0 #HT10 #HT20 #U1 #HTU1 #U2 #HTU2 #L2 #HL12
+elim (scpds_cpr_lpr … HT10 … HTU1 … HL12) -HT10 -HTU1 // #X1 #HUX1 #H1
+elim (scpds_cpr_lpr … HT20 … HTU2 … HL12) -HT20 -HTU2 // #X2 #HUX2 #H2
+elim (cprs_conf … H1 … H2) -T0 /3 width=5 by scpds_div, scpds_cprs_trans/
+qed-.
+
+(* Note: missing lstas_scpds, scpes_le *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_aaa.etc
new file mode 100644 (file)
index 0000000..dccb10f
--- /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/static/da_sta.ma".
+include "basic_2/static/sta_aaa.ma".
+
+(* DEGREE ASSIGNMENT FOR TERMS **********************************************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+lemma aaa_da: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ∃l. ⦃G, L⦄ ⊢ T ▪[h, g] l.
+#h #g #G #L #T #A #H elim (aaa_sta h … H) -A /2 width=2 by sta_da/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/da_sta.etc
new file mode 100644 (file)
index 0000000..4f45a81
--- /dev/null
@@ -0,0 +1,86 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sta.ma".
+include "basic_2/static/da_da.ma".
+
+(* Properties on static type assignment for terms ***************************)
+
+lemma da_sta_conf: ∀h,g,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
+                   ∀l. ⦃G, L⦄ ⊢ T ▪[h, g] l → ⦃G, L⦄ ⊢ U ▪[h, g] l-1.
+#h #g #G #L #T #U #H elim H -G -L -T -U
+[ #G #L #k #l #H
+  lapply (da_inv_sort … H) -H /3 width=1 by da_sort, deg_next/
+| #G #L #K #V #U #W #i #HLK #_ #HWU #IHVW #l #H
+  elim (da_inv_lref … H) -H * #K0 #V0 [| #l0] #HLK0 #HV0
+  lapply (drop_mono … HLK0 … HLK) -HLK0 #H destruct
+  lapply (drop_fwd_drop2 … HLK) -HLK /3 width=8 by da_lift/
+| #G #L #K #W #V #U #i #HLK #_ #HWU #IHWV #l #H
+  elim (da_inv_lref … H) -H * #K0 #V0 [| #l0] #HLK0 #HV0 [| #H0 ]
+  lapply (drop_mono … HLK0 … HLK) -HLK0 #H destruct
+  lapply (drop_fwd_drop2 … HLK) -HLK /3 width=8 by da_lift/
+| #a #I #G #L #V #T #U #_ #IHTU #l #H
+  lapply (da_inv_bind … H) -H /3 width=1 by da_bind/
+| #G #L #V #T #U #_ #IHTU #l #H
+  lapply (da_inv_flat … H) -H /3 width=1 by da_flat/
+| #G #L #W #T #U #_ #IHTU #l #H
+  lapply (da_inv_flat … H) -H /2 width=1 by/
+]
+qed-.
+
+lemma sta_da: ∀h,g,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
+              ∃l. ⦃G, L⦄ ⊢ T ▪[h, g] l.
+#h #g #G #L #T #U #H elim H -G -L -T -U
+[ #G #L #k elim (deg_total h g k) /3 width=2 by da_sort, ex_intro/
+| #G #L #K #V #W #W0 #i #HLK #_ #_ * /3 width=5 by da_ldef, ex_intro/
+| #G #L #K #W #V #W0 #i #HLK #_ #_ * /3 width=5 by da_ldec, ex_intro/
+| #a #I #G #L #V #T #U #_ * /3 width=2 by da_bind, ex_intro/
+| #G #L #V #T #U #_ * /3 width=2 by da_flat, ex_intro/
+| #G #L #W #T #U #_ * /3 width=2 by da_flat, ex_intro/
+]
+qed-.
+
+lemma sta_da_ge: ∀h,G,L,T,U,l0. ⦃G, L⦄ ⊢ T •[h] U →
+                 ∃∃g,l. ⦃G, L⦄ ⊢ T ▪[h, g] l & l0 ≤ l.
+#h #G #L #T #U #l0 #H elim H -G -L -T -U
+[ /3 width=4 by da_sort, ex2_2_intro/
+| #G #L #K #V #W #W0 #i #HLK #_ #_ * /3 width=5 by da_ldef, ex2_2_intro/
+| #G #L #K #W #V #W0 #i #HLK #_ #_ * /4 width=5 by da_ldec, lt_to_le, le_S_S, ex2_2_intro/
+| #a #I #G #L #V #T #U #_ * /3 width=4 by da_bind, ex2_2_intro/
+| #G #L #V #T #U #_ * /3 width=4 by da_flat, ex2_2_intro/
+| #G #L #W #T #U #_ * /3 width=4 by da_flat, ex2_2_intro/
+]
+qed-.
+
+(* Inversion lrmmas on static type assignment for terms *********************)
+
+lemma da_inv_sta: ∀h,g,G,L,T,l. ⦃G, L⦄ ⊢ T ▪[h, g] l →
+                  ∃U. ⦃G, L⦄ ⊢ T •[h] U.
+#h #g #G #L #T #l #H elim H -G -L -T -l
+[ /2 width=2/
+| #G #L #K #V #i #l #HLK #_ * #W #HVW
+  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldef, ex_intro/
+| #G #L #K #W #i #l #HLK #_ * #V #HWV
+  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldec, ex_intro/
+| #a #I #G #L #V #T #l #_ * /3 width=2 by sta_bind, ex_intro/
+| * #G #L #V #T #l #_ * /3 width=2 by sta_appl, sta_cast, ex_intro/
+]
+qed-.
+
+lemma sta_inv_refl_pos: ∀h,g,G,L,T,l. ⦃G, L⦄ ⊢ T ▪[h, g] l+1 → ⦃G, L⦄ ⊢ T •[h] T → ⊥.
+#h #g #G #L #T #l #H1T #HTT
+lapply (da_sta_conf … HTT … H1T) -HTT <minus_plus_m_m #H2T
+lapply (da_mono … H2T … H1T) -h -G -L -T #H
+elim (plus_xySz_x_false 0 l 0) //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas.etc
new file mode 100644 (file)
index 0000000..feed03e
--- /dev/null
@@ -0,0 +1,133 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/statictypestar_6.ma".
+include "basic_2/static/sta.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+definition lstas: ∀h. genv → lenv → nat → relation term ≝
+                  λh,G,L. lstar … (sta h G L).
+
+interpretation "nat-iterated static type assignment (term)"
+   'StaticTypeStar h G L l T U = (lstas h G L l T U).
+
+(* Basic eliminators ********************************************************)
+
+lemma lstas_ind_sn: ∀h,G,L,U2. ∀R:relation2 nat term.
+                    R 0 U2 → (
+                       ∀l,T,U1. ⦃G, L⦄ ⊢ T •[h] U1 → ⦃G, L⦄ ⊢ U1 •* [h, l] U2 →
+                       R l U1 → R (l+1) T
+                    ) →
+                    ∀l,T. ⦃G, L⦄ ⊢ T •*[h, l] U2 → R l T.
+/3 width=5 by lstar_ind_l/ qed-.
+
+lemma lstas_ind_dx: ∀h,G,L,T. ∀R:relation2 nat term.
+                    R 0 T → (
+                       ∀l,U1,U2. ⦃G, L⦄ ⊢ T •* [h, l] U1 →  ⦃G, L⦄ ⊢ U1 •[h] U2 →
+                       R l U1 → R (l+1) U2
+                    ) →
+                    ∀l,U. ⦃G, L⦄ ⊢ T •*[h, l] U → R l U.
+/3 width=5 by lstar_ind_r/ qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma lstas_inv_O: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •*[h, 0] U → T = U.
+/2 width=4 by lstar_inv_O/ qed-.
+
+lemma lstas_inv_SO: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •*[h, 1] U → ⦃G, L⦄ ⊢ T •[h] U.
+/2 width=1 by lstar_inv_step/ qed-.
+
+lemma lstas_inv_step_sn: ∀h,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
+                         ∃∃T. ⦃G, L⦄ ⊢ T1 •[h] T & ⦃G, L⦄ ⊢ T •*[h, l] T2.
+/2 width=3 by lstar_inv_S/ qed-.
+
+lemma lstas_inv_step_dx: ∀h,G,L,T1,T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
+                         ∃∃T. ⦃G, L⦄ ⊢ T1 •*[h, l] T & ⦃G, L⦄ ⊢ T •[h] T2.
+/2 width=3 by lstar_inv_S_dx/ qed-.
+
+lemma lstas_inv_sort1: ∀h,G,L,X,k,l. ⦃G, L⦄ ⊢ ⋆k •*[h, l] X → X = ⋆((next h)^l k).
+#h #G #L #X #k #l #H @(lstas_ind_dx … H) -X -l //
+#l #X #X0 #_ #H #IHX destruct
+lapply (sta_inv_sort1 … H) -H #H destruct
+>iter_SO //
+qed-.
+
+lemma lstas_inv_gref1: ∀h,G,L,X,p,l. ⦃G, L⦄ ⊢ §p •*[h, l+1] X → ⊥.
+#h #G #L #X #p #l #H elim (lstas_inv_step_sn … H) -H
+#U #H #HUX elim (sta_inv_gref1 … H)
+qed-.
+
+lemma lstas_inv_bind1: ∀h,a,I,G,L,V,T,X,l. ⦃G, L⦄ ⊢ ⓑ{a,I}V.T •*[h, l] X →
+                       ∃∃U. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U & X = ⓑ{a,I}V.U.
+#h #a #I #G #L #V #T #X #l #H @(lstas_ind_dx … H) -X -l /2 width=3 by ex2_intro/
+#l #X #X0 #_ #HX0 * #U #HTU #H destruct
+elim (sta_inv_bind1 … HX0) -HX0 #U0 #HU0 #H destruct /3 width=3 by lstar_dx, ex2_intro/
+qed-.
+
+lemma lstas_inv_appl1: ∀h,G,L,V,T,X,l. ⦃G, L⦄ ⊢ ⓐV.T •*[h, l] X →
+                       ∃∃U. ⦃G, L⦄ ⊢ T •*[h, l] U & X = ⓐV.U.
+#h #G #L #V #T #X #l #H @(lstas_ind_dx … H) -X -l /2 width=3 by ex2_intro/
+#l #X #X0 #_ #HX0 * #U #HTU #H destruct
+elim (sta_inv_appl1 … HX0) -HX0 #U0 #HU0 #H destruct /3 width=3 by lstar_dx, ex2_intro/
+qed-.
+
+lemma lstas_inv_cast1: ∀h,G,L,W,T,U,l. ⦃G, L⦄ ⊢ ⓝW.T •*[h, l+1] U → ⦃G, L⦄ ⊢ T •*[h, l+1] U.
+#h #G #L #W #T #X #l #H elim (lstas_inv_step_sn … H) -H
+#U #H #HUX lapply (sta_inv_cast1 … H) -H /2 width=3 by lstar_S/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma lstas_refl: ∀h,G,L. reflexive … (lstas h G L 0).
+// qed.
+
+lemma sta_lstas: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ T •*[h, 1] U.
+/2 width=1 by lstar_step/ qed.
+
+lemma lstas_step_sn: ∀h,G,L,T1,U1,U2,l. ⦃G, L⦄ ⊢ T1 •[h] U1 → ⦃G, L⦄ ⊢ U1 •*[h, l] U2 →
+                     ⦃G, L⦄ ⊢ T1 •*[h, l+1] U2.
+/2 width=3 by lstar_S/ qed.
+
+lemma lstas_step_dx: ∀h,G,L,T1,T2,U2,l. ⦃G, L⦄ ⊢ T1 •*[h, l] T2 → ⦃G, L⦄ ⊢ T2 •[h] U2 →
+                     ⦃G, L⦄ ⊢ T1 •*[h, l+1] U2.
+/2 width=3 by lstar_dx/ qed.
+
+lemma lstas_split: ∀h,G,L. inv_ltransitive … (lstas h G L).
+/2 width=1 by lstar_inv_ltransitive/ qed-.
+
+lemma lstas_sort: ∀h,G,L,l,k. ⦃G, L⦄ ⊢ ⋆k •*[h, l] ⋆((next h)^l k).
+#h #G #L #l @(nat_ind_plus … l) -l //
+#l #IHl #k >iter_SO /2 width=3 by sta_sort, lstas_step_dx/
+qed.
+
+lemma lstas_bind: ∀h,I,G,L,V,T,U,l. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U →
+                  ∀a. ⦃G, L⦄ ⊢ ⓑ{a,I}V.T •*[h, l] ⓑ{a,I}V.U.
+#h #I #G #L #V #T #U #l #H @(lstas_ind_dx … H) -U -l /3 width=3 by sta_bind, lstar_O, lstas_step_dx/
+qed.
+
+lemma lstas_appl: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U →
+                  ∀V.⦃G, L⦄ ⊢ ⓐV.T •*[h, l] ⓐV.U.
+#h #G #L #T #U #l #H @(lstas_ind_dx … H) -U -l /3 width=3 by sta_appl, lstar_O, lstas_step_dx/
+qed.
+
+lemma lstas_cast: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l+1] U →
+                  ∀W. ⦃G, L⦄ ⊢ ⓝW.T •*[h, l+1] U.
+#h #G #L #T #U #l #H elim (lstas_inv_step_sn … H) -H /3 width=3 by sta_cast, lstas_step_sn/
+qed.
+
+(* Basic_1: removed theorems 7:
+            sty1_abbr sty1_appl sty1_bind sty1_cast2
+            sty1_correct sty1_lift sty1_trans
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_aaa.etc
new file mode 100644 (file)
index 0000000..7497f44
--- /dev/null
@@ -0,0 +1,23 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sta_aaa.ma".
+include "basic_2/unfold/lstas.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+lemma lstas_aaa_conf: ∀h,G,L,l. Conf3 … (aaa G L) (lstas h G L l).
+/3 width=6 by sta_aaa_conf, lstar_Conf3/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_alt.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_alt.etc
new file mode 100644 (file)
index 0000000..0ad7b9b
--- /dev/null
@@ -0,0 +1,102 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/statictypestaralt_6.ma".
+include "basic_2/unfold/lstas_lift.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+(* alternative definition of lstas *)
+inductive lstasa (h): genv → relation4 lenv nat term term ≝
+| lstasa_O   : ∀G,L,T. lstasa h G L 0 T T
+| lstasa_sort: ∀G,L,l,k. lstasa h G L l (⋆k) (⋆((next h)^l k))
+| lstasa_ldef: ∀G,L,K,V,W,U,i,l. ⇩[i] L ≡ K.ⓓV → lstasa h G K (l+1) V W →
+               ⇧[0, i+1] W ≡ U → lstasa h G L (l+1) (#i) U
+| lstasa_ldec: ∀G,L,K,W,V,V0,U,i,l. ⇩[i] L ≡ K.ⓛW → ⦃G, K⦄ ⊢ W •[h] V0 →
+               lstasa h G K l W V → ⇧[0, i+1] V ≡ U → lstasa h G L (l+1) (#i) U
+| lstasa_bind: ∀a,I,G,L,V,T,U,l. lstasa h G (L.ⓑ{I}V) l T U →
+               lstasa h G L l (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
+| lstasa_appl: ∀G,L,V,T,U,l. lstasa h G L l T U → lstasa h G L l (ⓐV.T) (ⓐV.U)
+| lstasa_cast: ∀G,L,W,T,U,l. lstasa h G L (l+1) T U → lstasa h G L (l+1) (ⓝW.T) U
+.
+
+interpretation "nat-iterated static type assignment (term) alternative"
+   'StaticTypeStarAlt h G L l T U = (lstasa h G L l T U).
+
+(* Base properties **********************************************************)
+
+lemma sta_lstasa: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ⦃G, L⦄ ⊢ T ••*[h, 1] U.
+#h #G #L #T #U #H elim H -G -L -T -U
+/2 width=8 by lstasa_O, lstasa_sort, lstasa_ldef, lstasa_ldec, lstasa_bind, lstasa_appl, lstasa_cast/
+qed.
+
+lemma lstasa_step_dx: ∀h,G,L,T1,T,l. ⦃G, L⦄ ⊢ T1 ••*[h, l] T →
+                      ∀T2. ⦃G, L⦄ ⊢ T •[h] T2 → ⦃G, L⦄ ⊢ T1 ••*[h, l+1] T2.
+#h #G #L #T1 #T #l #H elim H -G -L -T1 -T -l
+[ /2 width=1 by sta_lstasa/
+| #G #L #l #k #X #H >(sta_inv_sort1 … H) -X >commutative_plus //
+| #G #L #K #V #W #U #i #l #HLK #_ #HWU #IHVW #U2 #HU2
+  lapply (drop_fwd_drop2 … HLK) #H
+  elim (sta_inv_lift1 … HU2 … H … HWU) -H -U /3 width=6 by lstasa_ldef/
+| #G #L #K #W #V #V0 #U #i #l #HLK #HWl0 #_ #HVU #IHWV #U2 #HU2
+  lapply (drop_fwd_drop2 … HLK) #H
+  elim (sta_inv_lift1 … HU2 … H … HVU) -H -U /3 width=8 by lstasa_ldec/
+| #a #I #G #L #V #T1 #U1 #l #_ #IHTU1 #X #H
+  elim (sta_inv_bind1 … H) -H #U #HU1 #H destruct /3 width=1 by lstasa_bind/
+| #G #L #V #T1 #U1 #l #_ #IHTU1 #X #H
+  elim (sta_inv_appl1 … H) -H #U #HU1 #H destruct /3 width=1 by lstasa_appl/
+| /3 width=1 by lstasa_cast/
+]
+qed.
+
+(* Main properties **********************************************************)
+
+theorem lstas_lstasa: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U → ⦃G, L⦄ ⊢ T ••*[h, l] U.
+#h #G #L #T #U #l #H @(lstas_ind_dx … H) -U -l /2 width=3 by lstasa_step_dx, lstasa_O/
+qed.
+
+(* Main inversion lemmas ****************************************************)
+
+theorem lstasa_inv_lstas: ∀h,G,L,T,U,l. ⦃G, L⦄ ⊢ T ••*[h, l] U → ⦃G, L⦄ ⊢ T •*[h, l] U.
+#h #G #L #T #U #l #H elim H -G -L -T -U -l
+/2 width=8 by lstas_inv_SO, lstas_ldec, lstas_ldef, lstas_cast, lstas_appl, lstas_bind/
+qed-.
+
+(* Advanced eliminators *****************************************************)
+
+lemma lstas_ind_alt: ∀h. ∀R:genv→relation4 lenv nat term term.
+                     (∀G,L,T. R G L O T T) →
+                     (∀G,L,l,k. R G L l (⋆k) (⋆((next h)^l k))) → (
+                        ∀G,L,K,V,W,U,i,l.
+                        ⇩[i] L ≡ K.ⓓV → ⦃G, K⦄ ⊢ V •*[h, l+1] W → ⇧[O, i+1] W ≡ U →
+                        R G K (l+1) V W → R G L (l+1) (#i) U
+                     ) → (
+                        ∀G,L,K,W,V,V0,U,i,l.
+                        ⇩[i] L ≡ K.ⓛW → ⦃G, K⦄ ⊢ W •[h] V0 →
+                        ⦃G, K⦄ ⊢ W •*[h, l]V → ⇧[O, i+1] V ≡ U →
+                        R G K l W V → R G L (l+1) (#i) U
+                     ) → (
+                        ∀a,I,G,L,V,T,U,l. ⦃G, L.ⓑ{I}V⦄ ⊢ T •*[h, l] U →
+                        R G (L.ⓑ{I}V) l T U → R G L l (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
+                     ) → (
+                        ∀G,L,V,T,U,l. ⦃G, L⦄ ⊢ T •*[h, l] U →
+                        R G L l T U → R G L l (ⓐV.T) (ⓐV.U)
+                     ) → (
+                        ∀G,L,W,T,U,l. ⦃G, L⦄⊢ T •*[h, l+1] U →
+                        R G L (l+1) T U → R G L (l+1) (ⓝW.T) U
+                     ) →
+                     ∀G,L,l,T,U. ⦃G, L⦄ ⊢ T •*[h, l] U → R G L l T U.
+#h #R #IH1 #IH2 #IH3 #IH4 #IH5 #IH6 #IH7 #G #L #l #T #U #H
+elim (lstas_lstasa … H) /3 width=10 by lstasa_inv_lstas/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_da.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_da.etc
new file mode 100644 (file)
index 0000000..8b11d1d
--- /dev/null
@@ -0,0 +1,40 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/unfold/lstas.ma".
+include "basic_2/static/da_sta.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+(* Properties on degree assignment for terms ********************************)
+
+lemma lstas_da_conf: ∀h,g,G,L,T,U,l1. ⦃G, L⦄ ⊢ T •*[h, l1] U →
+                     ∀l2. ⦃G, L⦄ ⊢ T ▪[h, g] l2 → ⦃G, L⦄ ⊢ U ▪[h, g] l2-l1.
+#h #g #G #L #T #U #l1 #H @(lstas_ind_dx … H) -U -l1 //
+#l1 #U #U0 #_ #HU0 #IHTU #l2 #HT
+<minus_plus /3 width=3 by da_sta_conf/
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma lstas_inv_refl_pos: ∀h,G,L,T,l. ⦃G, L⦄ ⊢ T •*[h, l+1] T → ⊥.
+#h #G #L #T #l #H elim (lstas_inv_step_sn … H)
+#U #HTU #_ elim (sta_da_ge … (l+1) HTU) -U
+#g #l0 #HT #Hl0 lapply (lstas_da_conf … H … HT) -H
+#H0T lapply (da_mono … HT … H0T) -h -G -L -T
+#H elim (discr_x_minus_xy … H) -H
+[ #H destruct /2 width=3 by le_plus_xSy_O_false/
+| -Hl0 <plus_n_Sm #H destruct 
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lift.etc
new file mode 100644 (file)
index 0000000..947c162
--- /dev/null
@@ -0,0 +1,81 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sta_lift.ma".
+include "basic_2/unfold/lstas.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+(* Properties on relocation *************************************************)
+
+lemma lstas_lift: ∀h,G,l. l_liftable (llstar … (sta h G) l).
+/3 width=10 by l_liftable_llstar, sta_lift/ qed.
+
+(* Inversion lemmas on relocation *******************************************)
+
+lemma lstas_inv_lift1: ∀h,G,l. l_deliftable_sn (llstar … (sta h G) l).
+/3 width=6 by l_deliftable_sn_llstar, sta_inv_lift1/ qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma lstas_inv_lref1: ∀h,G,L,U,i,l. ⦃G, L⦄ ⊢ #i •*[h, l+1] U →
+                       (∃∃K,V,W. ⇩[i] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •*[h, l+1] W &
+                                 ⇧[0, i+1] W ≡ U
+                       ) ∨
+                       (∃∃K,W,V,V0. ⇩[i] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V0 &
+                                    ⦃G, K⦄ ⊢ W •*[h, l] V & ⇧[0, i+1] V ≡ U
+                        ).
+#h #G #L #U #i #l #H elim (lstas_inv_step_sn … H) -H
+#X #H #HXU elim (sta_inv_lref1 … H) -H
+* #K #V #W #HLK #HVW #HWX
+lapply (drop_fwd_drop2 … HLK) #H0LK
+elim (lstas_inv_lift1 … HXU … H0LK … HWX) -H0LK -X
+/4 width=8 by lstas_step_sn, ex4_4_intro, ex3_3_intro, or_introl, or_intror/
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+lemma lstas_fwd_correct: ∀h,G,L,T1,U1. ⦃G, L⦄ ⊢ T1 •[h] U1 →
+                         ∀T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l] T2 →
+                         ∃U2. ⦃G, L⦄ ⊢ T2 •[h] U2.
+#h #G #L #T1 #U1 #HTU1 #T2 #l #H @(lstas_ind_dx … H) -l -T2 /2 width=3 by ex_intro/ -HTU1
+#l #T #T2 #_ #HT2 #_ -T1 -U1 -l
+elim (sta_fwd_correct … HT2) -T /2 width=2 by ex_intro/
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lstas_total: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U →
+                   ∀l. ∃U0. ⦃G, L⦄ ⊢ T •*[h, l] U0.
+#h #G #L #T #U #HTU #l @(nat_ind_plus … l) -l /2 width=2 by ex_intro/
+#l * #U0 #HTU0 elim (lstas_fwd_correct … HTU … HTU0) -U
+/3 width=4 by lstas_step_dx, ex_intro/
+qed-.
+
+lemma lstas_ldef: ∀h,G,L,K,V,i. ⇩[i] L ≡ K.ⓓV →
+                  ∀W,l. ⦃G, K⦄ ⊢ V •*[h, l+1] W →
+                  ∀U. ⇧[0, i+1] W ≡ U → ⦃G, L⦄ ⊢ #i •*[h, l+1] U.
+#h #G #L #K #V #i #HLK #W #l #HVW #U #HWU
+lapply (drop_fwd_drop2 … HLK)
+elim (lstas_inv_step_sn … HVW) -HVW #W0
+elim (lift_total W0 0 (i+1)) /3 width=12 by lstas_step_sn, sta_ldef, lstas_lift/
+qed.
+
+lemma lstas_ldec: ∀h,G,L,K,W,i. ⇩[i] L ≡ K.ⓛW → ∀V0. ⦃G, K⦄ ⊢ W •[h] V0 →
+                  ∀V,l. ⦃G, K⦄ ⊢ W •*[h, l] V →
+                  ∀U. ⇧[0, i+1] V ≡ U → ⦃G, L⦄ ⊢ #i •*[h, l+1] U.
+#h #G #L #K #W #i #HLK #V0 #HWV0 #V #l #HWV #U #HVU
+lapply (drop_fwd_drop2 … HLK) #H
+elim (lift_total W 0 (i+1)) /3 width=12 by lstas_step_sn, sta_ldec, lstas_lift/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lstas.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/lstas_lstas.etc
new file mode 100644 (file)
index 0000000..58614e3
--- /dev/null
@@ -0,0 +1,51 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sta_sta.ma".
+include "basic_2/unfold/lstas_lift.ma".
+
+(* NAT-ITERATED STATIC TYPE ASSIGNMENT FOR TERMS ****************************)
+
+(* Main properties **********************************************************)
+
+theorem lstas_trans: ∀h,G,L. ltransitive … (lstas h G L).
+/2 width=3 by lstar_ltransitive/ qed-.
+
+theorem lstas_mono: ∀h,G,L,l. singlevalued … (lstas h G L l).
+/3 width=7 by sta_mono, lstar_singlevalued/ qed-.
+
+theorem lstas_conf_le: ∀h,G,L,T,U1,l1. ⦃G, L⦄ ⊢ T •*[h, l1] U1 →
+                       ∀U2,l2. l1 ≤ l2 → ⦃G, L⦄ ⊢ T •*[h, l2] U2 →
+                       ⦃G, L⦄ ⊢ U1 •*[h, l2-l1] U2.
+#h #G #L #T #U1 #l1 #HTU1 #U2 #l2 #Hl12
+>(plus_minus_m_m … Hl12) in ⊢ (%→?); -Hl12 >commutative_plus #H
+elim (lstas_split … H) -H #U #HTU
+>(lstas_mono … HTU … HTU1) -T //
+qed-.
+
+(* Advanced properties ******************************************************)
+
+lemma lstas_sta_conf_pos: ∀h,G,L,T,U1. ⦃G, L⦄ ⊢ T •[h] U1 →
+                          ∀U2,l. ⦃G, L⦄ ⊢ T •*[h, l+1] U2 → ⦃G, L⦄ ⊢ U1 •*[h, l] U2.
+#h #G #L #T #U1 #HTU1 #U2 #l #HTU2
+lapply (lstas_conf_le … T U1 1 … HTU2) -HTU2 /2 width=1 by sta_lstas/
+qed-.
+
+lemma lstas_strip_pos: ∀h,G,L,T1,U1. ⦃G, L⦄ ⊢ T1 •[h] U1 →
+                       ∀T2,l. ⦃G, L⦄ ⊢ T1 •*[h, l+1] T2 →
+                       ∃∃U2. ⦃G, L⦄ ⊢ T2 •[h] U2 & ⦃G, L⦄ ⊢ U1 •*[h, l+1] U2.
+#h #G #L #T1 #U1 #HTU1 #T2 #l #HT12
+elim (lstas_fwd_correct … HTU1 … HT12)
+lapply (lstas_sta_conf_pos … HTU1 … HT12) -T1 /3 width=5 by lstas_step_dx, ex2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta.etc
new file mode 100644 (file)
index 0000000..fc6bf6a
--- /dev/null
@@ -0,0 +1,143 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/statictype_5.ma".
+include "basic_2/grammar/genv.ma".
+include "basic_2/substitution/drop.ma".
+include "basic_2/static/sh.ma".
+
+(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* activate genv *)
+inductive sta (h:sh): relation4 genv lenv term term ≝
+| sta_sort: ∀G,L,k. sta h G L (⋆k) (⋆(next h k))
+| sta_ldef: ∀G,L,K,V,W,U,i. ⇩[i] L ≡ K.ⓓV → sta h G K V W →
+            ⇧[0, i + 1] W ≡ U → sta h G L (#i) U
+| sta_ldec: ∀G,L,K,W,V,U,i. ⇩[i] L ≡ K.ⓛW → sta h G K W V →
+            ⇧[0, i + 1] W ≡ U → sta h G L (#i) U
+| sta_bind: ∀a,I,G,L,V,T,U. sta h G (L.ⓑ{I}V) T U →
+            sta h G L (ⓑ{a,I}V.T) (ⓑ{a,I}V.U)
+| sta_appl: ∀G,L,V,T,U. sta h G L T U → sta h G L (ⓐV.T) (ⓐV.U)
+| sta_cast: ∀G,L,W,T,U. sta h G L T U → sta h G L (ⓝW.T) U
+.
+
+interpretation "static type assignment (term)"
+   'StaticType h G L T U = (sta h G L T U).
+
+(* Basic inversion lemmas ************************************************)
+
+fact sta_inv_sort1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀k0. T = ⋆k0 →
+                        U = ⋆(next h k0).
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #k0 #H destruct //
+| #G #L #K #V #W #U #i #_ #_ #_ #k0 #H destruct
+| #G #L #K #W #V #U #i #_ #_ #_ #k0 #H destruct
+| #a #I #G #L #V #T #U #_ #k0 #H destruct
+| #G #L #V #T #U #_ #k0 #H destruct
+| #G #L #W #T #U #_ #k0 #H destruct
+qed-.
+
+(* Basic_1: was: sty0_gen_sort *)
+lemma sta_inv_sort1: ∀h,G,L,U,k. ⦃G, L⦄ ⊢ ⋆k •[h] U → U = ⋆(next h k).
+/2 width=5 by sta_inv_sort1_aux/ qed-.
+
+fact sta_inv_lref1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀j. T = #j →
+                        (∃∃K,V,W. ⇩[j] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •[h] W &
+                                  ⇧[0, j+1] W ≡ U
+                        ) ∨
+                        (∃∃K,W,V. ⇩[j] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V &
+                                  ⇧[0, j+1] W ≡ U
+                        ).
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #j #H destruct
+| #G #L #K #V #W #U #i #HLK #HVW #HWU #j #H destruct /3 width=6 by or_introl, ex3_3_intro/
+| #G #L #K #W #V #U #i #HLK #HWV #HWU #j #H destruct /3 width=6 by or_intror, ex3_3_intro/
+| #a #I #G #L #V #T #U #_ #j #H destruct
+| #G #L #V #T #U #_ #j #H destruct
+| #G #L #W #T #U #_ #j #H destruct
+]
+qed-.
+
+(* Basic_1: was sty0_gen_lref *)
+lemma sta_inv_lref1: ∀h,G,L,U,i. ⦃G, L⦄ ⊢ #i •[h] U →
+                     (∃∃K,V,W. ⇩[i] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V •[h] W &
+                               ⇧[0, i+1] W ≡ U
+                     ) ∨
+                     (∃∃K,W,V. ⇩[i] L ≡ K.ⓛW & ⦃G, K⦄ ⊢ W •[h] V &
+                               ⇧[0, i+1] W ≡ U
+                     ).
+/2 width=3 by sta_inv_lref1_aux/ qed-.
+
+fact sta_inv_gref1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀p0. T = §p0 → ⊥.
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #p0 #H destruct
+| #G #L #K #V #W #U #i #_ #_ #_ #p0 #H destruct
+| #G #L #K #W #V #U #i #_ #_ #_ #p0 #H destruct
+| #a #I #G #L #V #T #U #_ #p0 #H destruct
+| #G #L #V #T #U #_ #p0 #H destruct
+| #G #L #W #T #U #_ #p0 #H destruct
+qed-.
+
+lemma sta_inv_gref1: ∀h,G,L,U,p. ⦃G, L⦄ ⊢ §p •[h] U → ⊥.
+/2 width=8 by sta_inv_gref1_aux/ qed-.
+
+fact sta_inv_bind1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀b,J,X,Y. T = ⓑ{b,J}Y.X →
+                        ∃∃Z. ⦃G, L.ⓑ{J}Y⦄ ⊢ X •[h] Z & U = ⓑ{b,J}Y.Z.
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #b #J #X #Y #H destruct
+| #G #L #K #V #W #U #i #_ #_ #_ #b #J #X #Y #H destruct
+| #G #L #K #W #V #U #i #_ #_ #_ #b #J #X #Y #H destruct
+| #a #I #G #L #V #T #U #HTU #b #J #X #Y #H destruct /2 width=3 by ex2_intro/
+| #G #L #V #T #U #_ #b #J #X #Y #H destruct
+| #G #L #W #T #U #_ #b #J #X #Y #H destruct
+]
+qed-.
+
+(* Basic_1: was: sty0_gen_bind *)
+lemma sta_inv_bind1: ∀h,b,J,G,L,Y,X,U. ⦃G, L⦄ ⊢ ⓑ{b,J}Y.X •[h] U →
+                     ∃∃Z. ⦃G, L.ⓑ{J}Y⦄ ⊢ X •[h] Z & U = ⓑ{b,J}Y.Z.
+/2 width=3 by sta_inv_bind1_aux/ qed-.
+
+fact sta_inv_appl1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀X,Y. T = ⓐY.X →
+                        ∃∃Z. ⦃G, L⦄ ⊢ X •[h] Z & U = ⓐY.Z.
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #X #Y #H destruct
+| #G #L #K #V #W #U #i #_ #_ #_ #X #Y #H destruct
+| #G #L #K #W #V #U #i #_ #_ #_ #X #Y #H destruct
+| #a #I #G #L #V #T #U #_ #X #Y #H destruct
+| #G #L #V #T #U #HTU #X #Y #H destruct /2 width=3 by ex2_intro/
+| #G #L #W #T #U #_ #X #Y #H destruct
+]
+qed-.
+
+(* Basic_1: was: sty0_gen_appl *)
+lemma sta_inv_appl1: ∀h,G,L,Y,X,U. ⦃G, L⦄ ⊢ ⓐY.X •[h] U →
+                     ∃∃Z. ⦃G, L⦄ ⊢ X •[h] Z & U = ⓐY.Z.
+/2 width=3 by sta_inv_appl1_aux/ qed-.
+
+fact sta_inv_cast1_aux: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∀X,Y. T = ⓝY.X →
+                     ⦃G, L⦄ ⊢ X •[h] U.
+#h #G #L #T #U * -G -L -T -U
+[ #G #L #k #X #Y #H destruct
+| #G #L #K #V #W #U #i #_ #_ #_ #X #Y #H destruct
+| #G #L #K #W #V #U #i #_ #_ #_ #X #Y #H destruct
+| #a #I #G #L #V #T #U #_ #X #Y #H destruct
+| #G #L #V #T #U #_ #X #Y #H destruct
+| #G #L #W #T #U #HTU #X #Y #H destruct //
+]
+qed-.
+
+(* Basic_1: was: sty0_gen_cast *)
+lemma sta_inv_cast1: ∀h,G,L,X,Y,U. ⦃G, L⦄ ⊢ ⓝY.X •[h] U → ⦃G, L⦄ ⊢ X •[h] U.
+/2 width=4 by sta_inv_cast1_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_aaa.etc
new file mode 100644 (file)
index 0000000..affd2ed
--- /dev/null
@@ -0,0 +1,52 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/sta.ma".
+include "basic_2/static/aaa_lift.ma".
+
+(* STATIC TYPE ASSIGNMENT FOR TERMS *****************************************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+lemma aaa_sta: ∀h,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ∃U. ⦃G, L⦄ ⊢ T •[h] U.
+#h #G #L #T #A #H elim H -G -L -T -A
+[ /2 width=2 by sta_sort, ex_intro/
+| * #G #L #K [ #V | #W ] #B #i #HLK #_ * [ #W | #V ] #HVW
+  elim (lift_total W 0 (i+1)) /3 width=7 by sta_ldef, sta_ldec, ex_intro/
+| #a #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_bind, ex_intro/
+| #a #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_bind, ex_intro/
+| #G #L #V #T #B #A #_ #_ #_ * /3 width=2 by sta_appl, ex_intro/
+| #G #L #W #T #A #_ #_ #_ * /3 width=2 by sta_cast, ex_intro/
+]
+qed-.
+
+lemma sta_aaa_conf: ∀h,G,L. Conf3 … (aaa G L) (sta h G L).
+#h #G #L #T #A #H elim H -G -L -T -A
+[ #G #L #k #U #H
+  lapply (sta_inv_sort1 … H) -H #H destruct //
+| #I #G #L #K #V #B #i #HLK #HV #IHV #U #H
+  elim (sta_inv_lref1 … H) -H * #K0 #V0 #W0 #HLK0 #HVW0 #HU
+  lapply (drop_mono … HLK0 … HLK) -HLK0 #H0 destruct
+  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
+  @(aaa_lift … HLK … HU) -HU -L /2 width=2 by/
+| #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
+  elim (sta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2 by aaa_abbr/
+| #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
+  elim (sta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2 by aaa_abst/
+| #G #L #V #T #B #A #HV #_ #_ #IHT #X #H
+  elim (sta_inv_appl1 … H) -H #U #HTU #H destruct /3 width=3 by aaa_appl/
+| #G #L #V #T #A #_ #_ #IHV #IHT #X #H
+  lapply (sta_inv_cast1 … H) -H /2 width=2 by/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_lift.etc
new file mode 100644 (file)
index 0000000..4d34287
--- /dev/null
@@ -0,0 +1,113 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/drop_drop.ma".
+include "basic_2/static/sta.ma".
+
+(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Properties on relocation *************************************************)
+
+(* Basic_1: was: sty0_lift *)
+lemma sta_lift: ∀h,G. l_liftable (sta h G).
+#h #G #L1 #T1 #U1 #H elim H -G -L1 -T1 -U1
+[ #G #L1 #k #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
+  >(lift_inv_sort1 … H1) -X1
+  >(lift_inv_sort1 … H2) -X2 //
+| #G #L1 #K1 #V1 #W1 #W #i #HLK1 #_ #HW1 #IHVW1 #L2 #s #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2) -W // #W2 #HW12 #HWU2
+    elim (drop_trans_le … HL21 … HLK1) -L1 /2 width=2 by lt_to_le/ #X #HLK2 #H
+    elim (drop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K2 #V2 #HK21 #HV12 #H destruct
+    /3 width=9 by sta_ldef/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W /2 width=1 by le_S/ #HW1U2
+    lapply (drop_trans_ge … HL21 … HLK1 ?) -L1 /3 width=9 by sta_ldef, drop_inv_gen/
+  ]
+| #G #L1 #K1 #W1 #V1 #W #i #HLK1 #_ #HW1 #IHWV1 #L2 #s #d #e #HL21 #X #H #U2 #HWU2
+  elim (lift_inv_lref1 … H) * #Hid #H destruct
+  [ elim (lift_trans_ge … HW1 … HWU2) -W // <minus_plus #W #HW1 #HWU2
+    elim (drop_trans_le … HL21 … HLK1) -L1 /2 width=2 by lt_to_le/ #X #HLK2 #H
+    elim (drop_inv_skip2 … H) -H /2 width=1 by lt_plus_to_minus_r/ -Hid #K2 #W2 #HK21 #HW12 #H destruct
+    lapply (lift_mono … HW1 … HW12) -HW1 #H destruct
+    elim (lift_total V1 (d-i-1) e) /3 width=9 by sta_ldec/
+  | lapply (lift_trans_be … HW1 … HWU2 ? ?) -W /2 width=1 by le_S/ #HW1U2
+    lapply (drop_trans_ge … HL21 … HLK1 ?) -L1 /3 width=9 by sta_ldec, drop_inv_gen/
+  ]
+| #a #I #G #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_bind1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_bind1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct /4 width=6 by sta_bind, drop_skip/
+| #G #L1 #V1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X1 #H1 #X2 #H2
+  elim (lift_inv_flat1 … H1) -H1 #V2 #T2 #HV12 #HT12 #H destruct
+  elim (lift_inv_flat1 … H2) -H2 #X #U2 #H1 #HU12 #H2 destruct
+  lapply (lift_mono … H1 … HV12) -H1 #H destruct /4 width=6 by sta_appl/
+| #G #L1 #W1 #T1 #U1 #_ #IHTU1 #L2 #s #d #e #HL21 #X #H #U2 #HU12
+  elim (lift_inv_flat1 … H) -H #W2 #T2 #_ #HT12 #H destruct /3 width=6 by sta_cast/
+]
+qed.
+
+(* Note: apparently this was missing in basic_1 *)
+lemma sta_inv_lift1: ∀h,G. l_deliftable_sn (sta h G).
+#h #G #L2 #T2 #U2 #H elim H -G -L2 -T2 -U2
+[ #G #L2 #k #L1 #s #d #e #_ #X #H
+  >(lift_inv_sort2 … H) -X /2 width=3 by sta_sort, lift_sort, ex2_intro/
+| #G #L2 #K2 #V2 #W2 #W #i #HLK2 #HVW2 #HW2 #IHVW2 #L1 #s #d #e #HL21 #X #H
+  elim (lift_inv_lref2 … H) * #Hid #H destruct [ -HVW2 | -IHVW2 ]
+  [ elim (drop_conf_lt … HL21 … HLK2) -L2 // #K1 #V1 #HLK1 #HK21 #HV12
+    elim (IHVW2 … HK21 … HV12) -K2 -V2 #W1 #HW12 #HVW1
+    elim (lift_trans_le … HW12 … HW2) -W2 // >minus_plus <plus_minus_m_m /3 width=8 by sta_ldef, ex2_intro/
+  | lapply (drop_conf_ge … HL21 … HLK2 ?) -L2 // #HL1K2
+    elim (le_inv_plus_l … Hid) -Hid #Hdie #ei
+    elim (lift_split … HW2 d (i-e+1)) -HW2 /2 width=1 by le_S_S, le_S/
+    #W0 #HW20 <le_plus_minus_comm // >minus_minus_m_m /3 width=8 by sta_ldef, le_S, ex2_intro/
+  ]
+| #G #L2 #K2 #W2 #V2 #W #i #HLK2 #HWV2 #HW2 #IHWV2 #L1 #s #d #e #HL21 #X #H
+  elim (lift_inv_lref2 … H) * #Hid #H destruct [ -HWV2 | -IHWV2 ]
+  [ elim (drop_conf_lt … HL21 … HLK2) -L2 // #K1 #W1 #HLK1 #HK21 #HW12
+    elim (IHWV2 … HK21 … HW12) -K2 #V1 #_ #HWV1
+    elim (lift_trans_le … HW12 … HW2) -W2 // >minus_plus <plus_minus_m_m /3 width=8 by sta_ldec, ex2_intro/
+  | lapply (drop_conf_ge … HL21 … HLK2 ?) -L2 // #HL1K2
+    elim (le_inv_plus_l … Hid) -Hid #Hdie #ei
+    elim (lift_split … HW2 d (i-e+1)) -HW2 /2 width=1 by le_S_S, le_S/
+    #W0 #HW20 <le_plus_minus_comm // >minus_minus_m_m /3 width=8 by sta_ldec, le_S, ex2_intro/
+  ]
+| #a #I #G #L2 #V2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
+  elim (lift_inv_bind2 … H) -H #V1 #T1 #HV12 #HT12 #H destruct
+  elim (IHTU2 (L1.ⓑ{I}V1) … HT12) -IHTU2 -HT12 /3 width=5 by sta_bind, drop_skip, lift_bind, ex2_intro/
+| #G #L2 #V2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
+  elim (lift_inv_flat2 … H) -H #V1 #T1 #HV12 #HT12 #H destruct
+  elim (IHTU2 … HL21 … HT12) -L2 -HT12 /3 width=5 by sta_appl, lift_flat, ex2_intro/
+| #G #L2 #W2 #T2 #U2 #_ #IHTU2 #L1 #s #d #e #HL21 #X #H
+  elim (lift_inv_flat2 … H) -H #W1 #T1 #_ #HT12 #H destruct
+  elim (IHTU2 … HL21 … HT12) -L2 -HT12 /3 width=3 by sta_cast, ex2_intro/
+]
+qed-.
+
+(* Advanced forward lemmas **************************************************)
+
+(* Basic_1: was: sty0_correct *)
+lemma sta_fwd_correct: ∀h,G,L,T,U. ⦃G, L⦄ ⊢ T •[h] U → ∃T0. ⦃G, L⦄ ⊢ U •[h] T0.
+#h #G #L #T #U #H elim H -G -L -T -U
+[ /2 width=2/
+| #G #L #K #V #W #W0 #i #HLK #_ #HW0 * #V0 #HWV0
+  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
+  elim (lift_total V0 0 (i+1)) /3 width=11 by ex_intro, sta_lift/
+| #G #L #K #W #V #V0 #i #HLK #HWV #HWV0 #_
+  lapply (drop_fwd_drop2 … HLK) -HLK #HLK
+  elim (lift_total V 0 (i+1)) /3 width=11 by ex_intro, sta_lift/
+| #a #I #G #L #V #T #U #_ * /3 width=2 by sta_bind, ex_intro/
+| #G #L #V #T #U #_ * #T0 #HUT0 /3 width=2 by sta_appl, ex_intro/
+| #G #L #W #T #U #_ * /2 width=2 by ex_intro/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_llpx_sn.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_llpx_sn.etc
new file mode 100644 (file)
index 0000000..3adf28f
--- /dev/null
@@ -0,0 +1,43 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/multiple/llpx_sn_drop.ma".
+include "basic_2/static/sta.ma".
+
+(* STRATIFIED STATIC TYPE ASSIGNMENT FOR TERMS ******************************)
+
+(* Properties on lazy sn pointwise extensions *******************************)
+
+lemma sta_llpx_sn_conf: ∀R. (∀L. reflexive … (R L)) → l_liftable R →
+                        ∀h,G. s_r_confluent1 … (sta h G) (llpx_sn R 0).
+#R #H1R #H2R #h #G #Ls #T1 #T2 #H elim H -G -Ls -T1 -T2
+[ /3 width=4 by llpx_sn_fwd_length, llpx_sn_sort/
+| #G #Ls #Ks #V1s #W2s #V2s #i #HLKs #_ #HVW2s #IHV12s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (drop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (drop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HVW2s) -HLKs -HLKd -HVW2s /2 width=1 by/ (**) (* full auto too slow *)
+| #G #Ls #Ks #V1s #W1s #V2s #i #HLKs #_ #HV12s #IHVW1s #Ld #H elim (llpx_sn_inv_lref_ge_sn … H … HLKs) // -H
+  #Kd #V1d #HLKd #HV1s #HV1sd
+  lapply (drop_fwd_drop2 … HLKs) -HLKs #HLKs
+  lapply (drop_fwd_drop2 … HLKd) -HLKd #HLKd
+  @(llpx_sn_lift_le … HLKs HLKd … HV12s) -HLKs -HLKd -HV12s /2 width=1 by/ (**) (* full auto too slow *)
+| #a #I #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_bind_O … H) -H
+  /4 width=5 by llpx_sn_bind_repl_SO, llpx_sn_bind/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+| #G #Ls #V #T1 #T2 #_ #IHT12 #Ld #H elim (llpx_sn_inv_flat … H) -H
+  /3 width=1 by llpx_sn_flat/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_sta.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/sta_sta.etc
new file mode 100644 (file)
index 0000000..6d54d56
--- /dev/null
@@ -0,0 +1,43 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/drop_drop.ma".
+include "basic_2/static/sta.ma".
+
+(* STATIC TYPE ASSIGNMENT ON TERMS ******************************************)
+
+(* Main properties **********************************************************)
+
+(* Note: apparently this was missing in basic_1 *)
+theorem sta_mono: ∀h,G,L. singlevalued … (sta h G L).
+#h #G #L #T #U1 #H elim H -G -L -T -U1
+[ #G #L #k #X #H >(sta_inv_sort1 … H) -X //
+| #G #L #K #V #W #U1 #i #HLK #_ #HWU1 #IHVW #U2 #H
+  elim (sta_inv_lref1 … H) -H * #K0 #V0 #W0 #HLK0 #HVW0 #HW0U2
+  lapply (drop_mono … HLK0 … HLK) -HLK -HLK0 #H destruct
+  lapply (IHVW … HVW0) -IHVW -HVW0 #H destruct
+  >(lift_mono … HWU1 … HW0U2) -W0 -U1 //
+| #G #L #K #W #V #U1 #i #HLK #_ #HWU1 #IHWV #U2 #H
+  elim (sta_inv_lref1 … H) -H * #K0 #W0 #V0 #HLK0 #HWV0 #HV0U2
+  lapply (drop_mono … HLK0 … HLK) -HLK -HLK0 #H destruct
+  lapply (IHWV … HWV0) -IHWV -HWV0 #H destruct
+  >(lift_mono … HWU1 … HV0U2) -W -U1 //
+| #a #I #G #L #V #T #U1 #_ #IHTU1 #X #H
+  elim (sta_inv_bind1 … H) -H #U2 #HTU2 #H destruct /3 width=1 by eq_f/
+| #G #L #V #T #U1 #_ #IHTU1 #X #H
+  elim (sta_inv_appl1 … H) -H #U2 #HTU2 #H destruct /3 width=1 by eq_f/
+| #G #L #W #T #U1 #_ #IHTU1 #U2 #H
+  lapply (sta_inv_cast1 … H) -H /2 width=1 by/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictype_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictype_5.etc
new file mode 100644 (file)
index 0000000..9249be4
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • break [ term 46 h ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'StaticType $h $G $L $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictypestaralt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/sta/statictypestaralt_6.etc
new file mode 100644 (file)
index 0000000..a6e46be
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • • * break [ term 46 h , break term 46 l ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'StaticTypeStarAlt $h $G $L $l $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/chnf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/chnf.etc
new file mode 100644 (file)
index 0000000..f6106d3
--- /dev/null
@@ -0,0 +1,40 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break 𝐇𝐍 ⦃ term 46 T ⦄ )"
+   non associative with precedence 45
+   for @{ 'HdNormal $L $T }.
+
+include "basic_2/reduction/cpr_tshf.ma".
+
+(* CONTEXT-SENSITIVE WEAK HEAD NORMAL TERMS *********************************)
+
+definition chnf: lenv → predicate term ≝ λL. NF … (cpr L) tshf.
+
+interpretation
+   "context-sensitive head normality (term)"
+   'HdNormal L T = (chnf L T).
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma chnf_inv_tshf: ∀L,T. L ⊢ 𝐇𝐍⦃T⦄ → T ≈ T.
+normalize /2 width=1/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma tshf_thnf: ∀T. T ≈ T → ⋆ ⊢ 𝐇𝐍⦃T⦄.
+#T #HT #T2 #H elim (cpr_fwd_tshf1 … H) -H //
+#H elim H //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/cpr_tshf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/cpr_tshf.etc
new file mode 100644 (file)
index 0000000..0fc5e1d
--- /dev/null
@@ -0,0 +1,46 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/grammar/tshf.ma".
+include "basic_2/reduction/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
+
+(* Forward lemmas on same head forms for terms ******************************)
+
+lemma cpr_fwd_tshf1: ∀L,T1,T2. L ⊢ T1 ➡ T2 → T1 ≈ T1 →
+                     T2 ≈ T1 ∨ (L = ⋆ → ⊥).
+#L #T1 #T2 #H elim H -L -T1 -T2
+[ /2 width=1/
+| #L #K #V1 #V2 #W2 #i #HLK #_ #_ #_ #_
+  @or_intror #H destruct
+  lapply (ldrop_inv_atom1 … HLK) -HLK #H destruct
+| #a #I #L #V1 #V2 #T1 #T2 #_ #_ #_ #_ #H
+  elim (tshf_inv_bind1 … H) -H #W2 #U2 #H1 * #H2 destruct /2 width=1/
+| #I #L #V1 #V2 #T1 #T2 #_ #_ #_ #IHT12 #H
+  elim (tshf_inv_flat1 … H) -H #W2 #U2 #HT1U2 #HT1 #_ #H1 #H2 destruct
+  lapply (IHT12 HT1U2) -IHT12 -HT1U2 * #HUT2 /3 width=1/
+  lapply (simple_tshf_repl_sn … HUT2 HT1) /3 width=1/
+| #L #V #T #T1 #T2 #_ #_ #_ #H
+  elim (tshf_inv_bind1 … H) -H #W2 #U2 #H1 * #H2 destruct
+| #L #V #T1 #T2 #_ #_ #H
+  elim (tshf_inv_flat1 … H) -H #W2 #U2 #_ #_ #_ #H destruct
+| #a #L #V1 #V2 #W #T1 #T2 #_ #_ #_ #_ #H
+  elim (tshf_inv_flat1 … H) -H #W2 #U2 #_ #H
+  elim (simple_inv_bind … H)
+| #a #L #V2 #V1 #V #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #H
+  elim (tshf_inv_flat1 … H) -H #U1 #U2 #_ #H
+  elim (simple_inv_bind … H)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/tshf.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/tshf/tshf.etc
new file mode 100644 (file)
index 0000000..583c3f4
--- /dev/null
@@ -0,0 +1,98 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( L ⊢ break term 46 T1 ≈ break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'Hom $L $T1 $T2 }.
+
+notation "hvbox( L ⊢ break 𝐇𝐑 ⦃ term 46 T ⦄ )"
+   non associative with precedence 45
+   for @{ 'HdReducible $L $T }.
+
+notation "hvbox( L ⊢ break 𝐇𝐈 ⦃ term 46 T ⦄ )"
+   non associative with precedence 45
+   for @{ 'NotHdReducible $L $T }.
+
+include "basic_2/grammar/term_simple.ma".
+
+(* SAME HEAD TERM FORMS *****************************************************)
+
+inductive tshf: relation term ≝
+   | tshf_atom: ∀I. tshf (⓪{I}) (⓪{I})
+   | tshf_abbr: ∀V1,V2,T1,T2. tshf (-ⓓV1. T1) (-ⓓV2. T2)
+   | tshf_abst: ∀a,V1,V2,T1,T2. tshf (ⓛ{a}V1. T1) (ⓛ{a}V2. T2)
+   | tshf_appl: ∀V1,V2,T1,T2. tshf T1 T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄ →
+                tshf (ⓐV1. T1) (ⓐV2. T2)
+.
+
+interpretation "same head form (term)" 'napart T1 T2 = (tshf T1 T2).
+
+(* Basic properties *********************************************************)
+
+lemma tshf_sym: ∀T1,T2. T1 ≈ T2 → T2 ≈ T1.
+#T1 #T2 #H elim H -T1 -T2 /2 width=1/
+qed.
+
+lemma tshf_refl2: ∀T1,T2. T1 ≈ T2 → T2 ≈ T2.
+#T1 #T2 #H elim H -T1 -T2 // /2 width=1/
+qed.
+
+lemma tshf_refl1: ∀T1,T2. T1 ≈ T2 → T1 ≈ T1.
+/3 width=2/ qed.
+
+lemma simple_tshf_repl_dx: ∀T1,T2. T1 ≈ T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄.
+#T1 #T2 #H elim H -T1 -T2 //
+[ #V1 #V2 #T1 #T2 #H
+  elim (simple_inv_bind … H)
+| #a #V1 #V2 #T1 #T2 #H
+  elim (simple_inv_bind … H)
+]
+qed. (**) (* remove from index *)
+
+lemma simple_tshf_repl_sn: ∀T1,T2. T1 ≈ T2 → 𝐒⦃T2⦄ → 𝐒⦃T1⦄.
+/3 width=3/ qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact tshf_inv_bind1_aux: ∀T1,T2. T1 ≈ T2 → ∀a,I,W1,U1. T1 = ⓑ{a,I}W1.U1 →
+                         ∃∃W2,U2. T2 = ⓑ{a,I}W2. U2 &
+                                  (Bind2 a I = Bind2 false Abbr ∨ I = Abst).
+#T1 #T2 * -T1 -T2
+[ #J #a #I #W1 #U1 #H destruct
+| #V1 #V2 #T1 #T2 #a #I #W1 #U1 #H destruct /3 width=3/
+| #b #V1 #V2 #T1 #T2 #a #I #W1 #U1 #H destruct /3 width=3/
+| #V1 #V2 #T1 #T2 #_ #_ #_ #a #I #W1 #U1 #H destruct
+]
+qed.
+
+lemma tshf_inv_bind1: ∀a,I,W1,U1,T2. ⓑ{a,I}W1.U1 ≈ T2 →
+                      ∃∃W2,U2. T2 = ⓑ{a,I}W2. U2 &
+                               (Bind2 a I = Bind2 false Abbr ∨ I = Abst).
+/2 width=5/ qed-.
+
+fact tshf_inv_flat1_aux: ∀T1,T2. T1 ≈ T2 → ∀I,W1,U1. T1 = ⓕ{I}W1.U1 →
+                         ∃∃W2,U2. U1 ≈ U2 & 𝐒⦃U1⦄ & 𝐒⦃U2⦄ &
+                                  I = Appl & T2 = ⓐW2. U2.
+#T1 #T2 * -T1 -T2
+[ #J #I #W1 #U1 #H destruct
+| #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct
+| #a #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct
+| #V1 #V2 #T1 #T2 #HT12 #HT1 #HT2 #I #W1 #U1 #H destruct /2 width=5/
+]
+qed.
+
+lemma tshf_inv_flat1: ∀I,W1,U1,T2. ⓕ{I}W1.U1 ≈ T2 →
+                      ∃∃W2,U2. U1 ≈ U2 & 𝐒⦃U1⦄ & 𝐒⦃U2⦄ &
+                               I = Appl & T2 = ⓐW2. U2.
+/2 width=4/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_aaa.etc
new file mode 100644 (file)
index 0000000..98fe013
--- /dev/null
@@ -0,0 +1,25 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/ssta_aaa.ma".
+include "basic_2/reducibility/cpr_aaa.ma".
+include "basic_2/reducibility/xpr.ma".
+
+(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+lemma xpr_aaa: ∀h,g,L,T,A. L ⊢ T ⁝ A → ∀U. ⦃h, L⦄ ⊢ T •➡[g] U → L ⊢ U ⁝ A.
+#h #g #L #T #A #HT #U * /2 width=3/ /2 width=6/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lift.etc
new file mode 100644 (file)
index 0000000..8f5deca
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/ssta_lift.ma".
+include "basic_2/reducibility/cpr_lift.ma".
+include "basic_2/reducibility/xpr.ma".
+
+(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma xpr_inv_abst1: ∀h,g,a,L,V1,T1,U2. ⦃h, L⦄ ⊢ ⓛ{a}V1.T1 •➡[g] U2 →
+                     ∃∃V2,T2. L ⊢ V1 ➡ V2 & ⦃h, L. ⓛV1⦄ ⊢ T1 •➡[g] T2 &
+                              U2 = ⓛ{a}V2. T2.
+#h #g #a #L #V1 #T1 #U2 *
+[ #H elim (cpr_inv_abst1 … H Abst V1) /3 width=5/
+| #l #H elim (ssta_inv_bind1 … H) /3 width=5/
+]
+qed-.
+
+(* Relocation properties ****************************************************)
+
+lemma xpr_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K →
+                ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀T2,U2. ⇧[d, e] T2 ≡ U2 →
+                ∀h,g. ⦃h, K⦄ ⊢ T1 •➡[g] T2 → ⦃h, L⦄ ⊢ U1 •➡[g] U2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #T2 #U2 #HTU2 #h #g *
+/3 width=9/ /3 width=10/
+qed.
+
+lemma xpr_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
+                     ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀h,g,U2. ⦃h, L⦄ ⊢ U1 •➡[g] U2 →
+                     ∃∃T2. ⇧[d, e] T2 ≡ U2 & ⦃h, K⦄ ⊢ T1 •➡[g] T2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #U2 * [ #HU12 | #l #HU12 ]
+[ elim (cpr_inv_lift1 … HLK … HTU1 … HU12) -L -U1 /3 width=3/
+| elim (ssta_inv_lift1 … HU12 … HLK … HTU1) -L -U1 /3 width=4/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lsubss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xpr_lsubss.etc
new file mode 100644 (file)
index 0000000..bc66cd2
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/static/lsubss_ssta.ma".
+include "basic_2/reducibility/xpr.ma".
+
+(* EXTENDED PARALLEL REDUCTION ON TERMS *************************************)
+
+(* Properties on lenv ref for stratified type assignment ********************)
+
+lemma lsubss_xpr_trans: ∀h,g,L1,L2. h ⊢ L1 •⊑[g] L2 →
+                        ∀T1,T2. ⦃h, L2⦄ ⊢ T1 •➡[g] T2 → ⦃h, L1⦄ ⊢ T1 •➡[g] T2.
+#h #g #L1 #L2 #HL12 #T1 #T2 * [ | #l ] #HT12
+[ lapply (lsubss_fwd_lsubs2 … HL12) -HL12 /3 width=3/
+| /3 width=4/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs.etc
new file mode 100644 (file)
index 0000000..bffc4e7
--- /dev/null
@@ -0,0 +1,72 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "hvbox( ⦃ term 46 h , break term 46 L ⦄ ⊢ break term 46 T1 • ➡ * break [ term 46 g ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'XPRedStar $h $g $L $T1 $T2 }.
+
+notation "hvbox( ⦃ term 46 h , break term 46 L ⦄ ⊢ • ⬊ * break [ term 46 g ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'XSN $h $g $L $T }.
+
+include "basic_2/static/lsubss.ma".
+include "basic_2/reducibility/xpr.ma".
+(*
+include "basic_2/reducibility/cnf.ma".
+*)
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+definition xprs: ∀h. sd h → lenv → relation term ≝
+                 λh,g,L. TC … (xpr h g L).
+
+interpretation "extended parallel computation (term)"
+   'XPRedStar h g L T1 T2 = (xprs h g L T1 T2).
+
+(* Basic eliminators ********************************************************)
+
+lemma xprs_ind: ∀h,g,L,T1. ∀R:predicate term. R T1 →
+                (∀T,T2. ⦃h, L⦄ ⊢ T1 •➡*[g] T → ⦃h, L⦄ ⊢ T •➡[g] T2 → R T → R T2) →
+                ∀T2. ⦃h, L⦄ ⊢ T1 •➡*[g] T2 → R T2.
+#h #g #L #T1 #R #HT1 #IHT1 #T2 #HT12
+@(TC_star_ind … HT1 IHT1 … HT12) //
+qed-.
+
+lemma xprs_ind_dx: ∀h,g,L,T2. ∀R:predicate term. R T2 →
+                   (∀T1,T. ⦃h, L⦄ ⊢ T1 •➡[g] T → ⦃h, L⦄ ⊢ T •➡*[g] T2 → R T → R T1) →
+                   ∀T1. ⦃h, L⦄ ⊢ T1 •➡*[g] T2 → R T1.
+#h #g #L #T2 #R #HT2 #IHT2 #T1 #HT12
+@(TC_star_ind_dx … HT2 IHT2 … HT12) //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma xprs_refl: ∀h,g,L. reflexive … (xprs h g L).
+/2 width=1/ qed.
+
+lemma xprs_strap1: ∀h,g,L,T1,T,T2.
+                   ⦃h, L⦄ ⊢ T1 •➡*[g] T → ⦃h, L⦄ ⊢ T •➡[g] T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
+/2 width=3/ qed.
+
+lemma xprs_strap2: ∀h,g,L,T1,T,T2.
+                   ⦃h, L⦄ ⊢ T1 •➡[g] T → ⦃h, L⦄ ⊢ T •➡*[g] T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
+/2 width=3/ qed.
+
+(* Basic inversion lemmas ***************************************************)
+(*
+axiom xprs_inv_cnf1: ∀L,T,U. L ⊢ T ➡* U → L ⊢ 𝐍⦃T⦄ → T = U.
+#L #T #U #H @(xprs_ind_dx … H) -T //
+#T0 #T #H1T0 #_ #IHT #H2T0
+lapply (H2T0 … H1T0) -H1T0 #H destruct /2 width=1/
+qed-.
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_aaa.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_aaa.etc
new file mode 100644 (file)
index 0000000..5beb8fe
--- /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/reducibility/xpr_aaa.ma".
+include "basic_2/computation/xprs.ma".
+
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+(* Properties on atomic arity assignment for terms **************************)
+
+lemma xprs_aaa: ∀h,g,L,T,A. L ⊢ T ⁝ A → ∀U. ⦃h, L⦄ ⊢ T •➡*[g] U → L ⊢ U ⁝ A.
+#h #g #L #T #A #HT #U #H @(xprs_ind … H) -U // /2 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_cprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_cprs.etc
new file mode 100644 (file)
index 0000000..13a4f88
--- /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/computation/cprs.ma".
+include "basic_2/computation/xprs.ma".
+
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+(* properties on context sensitive parallel computation for terms ***********)
+
+lemma cprs_xprs: ∀h,g,L,T1,T2. L ⊢ T1 ➡* T2 → ⦃h, L⦄ ⊢ T1 •➡*[g] T2.
+#h #g #L #T1 #T2 #H @(cprs_ind … H) -T2 // /3 width=3/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lift.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lift.etc
new file mode 100644 (file)
index 0000000..cb151a1
--- /dev/null
@@ -0,0 +1,50 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/xpr_lift.ma".
+include "basic_2/computation/cprs.ma".
+include "basic_2/computation/xprs.ma".
+
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+(* Advanced forward lemmas **************************************************)
+
+lemma xprs_fwd_abst1: ∀h,g,a,L,V1,T1,U2. ⦃h, L⦄ ⊢ ⓛ{a}V1. T1 •➡*[g] U2 →
+                      ∃∃V2,T2. L ⊢ V1 ➡* V2 & U2 = ⓛ{a}V2. T2.
+#h #g #a #L #V1 #T1 #U2 #H @(xprs_ind … H) -U2 /2 width=4/
+#U #U2 #_ #HU2 * #V #T #HV1 #H destruct
+elim (xpr_inv_abst1 … HU2) -HU2 #V2 #T2 #HV2 #_ #H destruct /3 width=4/
+qed-.
+
+(* Relocation properties ****************************************************)
+
+lemma xprs_lift: ∀L,K,d,e. ⇩[d, e] L ≡ K → ∀T1,U1. ⇧[d, e] T1 ≡ U1 →
+                 ∀h,g,T2. ⦃h, K⦄ ⊢ T1 •➡*[g] T2 → ∀U2. ⇧[d, e] T2 ≡ U2 →
+                 ⦃h, L⦄ ⊢ U1 •➡*[g] U2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #T2 #HT12 @(xprs_ind … HT12) -T2
+[ -HLK #T2 #HT12
+   <(lift_mono … HTU1 … HT12) -T1 //
+| -HTU1 #T #T2 #_ #HT2 #IHT2 #U2 #HTU2
+  elim (lift_total T d e) #U #HTU
+  lapply (xpr_lift … HLK … HTU … HTU2 … HT2) -T2 -HLK /3 width=3/
+]
+qed.
+
+lemma xprs_inv_lift1: ∀L,K,d,e. ⇩[d, e] L ≡ K →
+                      ∀T1,U1. ⇧[d, e] T1 ≡ U1 → ∀h,g,U2. ⦃h, L⦄ ⊢ U1 •➡*[g] U2 →
+                      ∃∃T2. ⇧[d, e] T2 ≡ U2 & ⦃h, K⦄ ⊢ T1 •➡*[g] T2.
+#L #K #d #e #HLK #T1 #U1 #HTU1 #h #g #U2 #HU12 @(xprs_ind … HU12) -U2 /2 width=3/
+-HTU1 #U #U2 #_ #HU2 * #T #HTU #HT1
+elim (xpr_inv_lift1 … HLK … HTU … HU2) -U -HLK /3 width=5/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lsubss.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_lsubss.etc
new file mode 100644 (file)
index 0000000..c883c14
--- /dev/null
@@ -0,0 +1,27 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/reducibility/xpr_lsubss.ma".
+include "basic_2/computation/xprs.ma".
+
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+(* Properties on lenv ref for stratified type assignment ********************)
+
+lemma lsubss_xprs_trans: ∀h,g,L1,L2. h ⊢ L1 •⊑[g] L2 →
+                         ∀T1,T2. ⦃h, L2⦄ ⊢ T1 •➡*[g] T2 → ⦃h, L1⦄ ⊢ T1 •➡*[g] T2.
+#h #g #L1 #L2 #HL12 #T1 #T2 #H @(xprs_ind … H) -T2 //
+#T #T2 #_ #HT2 #IHT1
+lapply (lsubss_xpr_trans … HL12 … HT2) -L2 /2 width=3/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_xprs.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_2A1/xpr/xprs_xprs.etc
new file mode 100644 (file)
index 0000000..9593f05
--- /dev/null
@@ -0,0 +1,20 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/computation/xprs.ma".
+
+(* EXTENDED PARALLEL COMPUTATION ON TERMS ***********************************)
+
+theorem xprs_trans: ∀h,g,L. transitive … (xprs h g L).
+/2 width=3/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq.etc
new file mode 100644 (file)
index 0000000..57ecbaf
--- /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/syntax/lenv.ma".
+
+(* CONTEXT-SENSITIVE EQUIVALENCES FOR TERMS *********************************)
+
+definition ceq: relation3 lenv term term ≝ λL,T1,T2. T1 = T2.
+
+definition cfull: relation3 lenv term term ≝ λL,T1,T2. ⊤.
+
+(* Basic properties *********************************************************)
+
+lemma ceq_refl (L): reflexive … (ceq L).
+// qed.
+
+lemma cfull_refl (L): reflexive … (cfull L).
+// qed.
+
+lemma ceq_sym (L): symmetric … (ceq L).
+// qed-.
+
+lemma cfull_sym (L): symmetric … (cfull L).
+// qed-.
+
+lemma cfull_top (R:relation3 lenv term term) (L) (T1) (T2):
+                R L T1 T2 → cfull L T1 T2.
+// qed-.
+
+lemma ceq_cfull (L) (T1) (T2): ceq L T1 T2 → cfull L T1 T2.
+// qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq_ceq.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/ceq_ceq.etc
new file mode 100644 (file)
index 0000000..b17b186
--- /dev/null
@@ -0,0 +1,37 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/ceq.ma".
+
+(* CONTEXT-SENSITIVE EQUIVALENCES FOR TERMS *********************************)
+
+(* Main properties **********************************************************)
+
+theorem ceq_trans (L): Transitive … (ceq L).
+// qed-.
+
+lemma ceq_canc_sn (L): left_cancellable … (ceq L).
+// qed-.
+
+lemma ceq_canc_dx (L): right_cancellable … (ceq L).
+// qed-.
+
+theorem cfull_trans (L): Transitive … (cfull L).
+// qed-.
+
+lemma cfull_canc_sn (L): left_cancellable … (cfull L).
+// qed-.
+
+lemma cfull_canc_dx (L): right_cancellable … (cfull L).
+// qed-.
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.etc
new file mode 100644 (file)
index 0000000..1f2f97e
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/cir.ma".
+include "basic_2/reduction/cpr.ma".
+
+(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
+
+(* Advanced forward lemmas on irreducibility ********************************)
+
+lemma cpr_fwd_cir: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡ T2 → ⦃G, L⦄ ⊢ ➡ 𝐈⦃T1⦄ → T2 = T1.
+#G #L #T1 #T2 #H elim H -G -L -T1 -T2
+[ //
+| #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #IHV12 #H
+  elim (cir_inv_delta … HLK) //
+| #a * #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #H
+  [ elim (cir_inv_bind … H) -H #HV1 #HT1 * #H destruct
+    lapply (IHV1 … HV1) -IHV1 -HV1 #H destruct
+    lapply (IHT1 … HT1) -IHT1 #H destruct //
+  | elim (cir_inv_ib2 … H) -H /3 width=2 by or_introl, eq_f2/
+  ]
+| * #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #H
+  [ elim (cir_inv_appl … H) -H #HV1 #HT1 #_
+    >IHV1 -IHV1 // -HV1 >IHT1 -IHT1 //
+  | elim (cir_inv_ri2 … H) /2 width=1 by/
+  ]
+| #G #L #V1 #T1 #T #T2 #_ #_ #_ #H
+  elim (cir_inv_ri2 … H) /2 width=1 by or_introl/
+| #G #L #V1 #T1 #T2 #_ #_ #H
+  elim (cir_inv_ri2 … H) /2 width=1 by/
+| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #H
+  elim (cir_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+| #a #G #L #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #H
+  elim (cir_inv_appl … H) -H #_ #_ #H
+  elim (simple_inv_bind … H)
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.ma b/matita/matita/contribs/lambdadelta/basic_2/etc_new/cpr/cpr_cir.ma
deleted file mode 100644 (file)
index 1f2f97e..0000000
+++ /dev/null
@@ -1,49 +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/cir.ma".
-include "basic_2/reduction/cpr.ma".
-
-(* CONTEXT-SENSITIVE PARALLEL REDUCTION FOR TERMS ***************************)
-
-(* Advanced forward lemmas on irreducibility ********************************)
-
-lemma cpr_fwd_cir: ∀G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡ T2 → ⦃G, L⦄ ⊢ ➡ 𝐈⦃T1⦄ → T2 = T1.
-#G #L #T1 #T2 #H elim H -G -L -T1 -T2
-[ //
-| #G #L #K #V1 #V2 #W2 #i #HLK #_ #HVW2 #IHV12 #H
-  elim (cir_inv_delta … HLK) //
-| #a * #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #H
-  [ elim (cir_inv_bind … H) -H #HV1 #HT1 * #H destruct
-    lapply (IHV1 … HV1) -IHV1 -HV1 #H destruct
-    lapply (IHT1 … HT1) -IHT1 #H destruct //
-  | elim (cir_inv_ib2 … H) -H /3 width=2 by or_introl, eq_f2/
-  ]
-| * #G #L #V1 #V2 #T1 #T2 #_ #_ #IHV1 #IHT1 #H
-  [ elim (cir_inv_appl … H) -H #HV1 #HT1 #_
-    >IHV1 -IHV1 // -HV1 >IHT1 -IHT1 //
-  | elim (cir_inv_ri2 … H) /2 width=1 by/
-  ]
-| #G #L #V1 #T1 #T #T2 #_ #_ #_ #H
-  elim (cir_inv_ri2 … H) /2 width=1 by or_introl/
-| #G #L #V1 #T1 #T2 #_ #_ #H
-  elim (cir_inv_ri2 … H) /2 width=1 by/
-| #a #G #L #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #H
-  elim (cir_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-| #a #G #L #V #V1 #V2 #W1 #W2 #T1 #T2 #_ #_ #_ #_ #_ #_ #_ #H
-  elim (cir_inv_appl … H) -H #_ #_ #H
-  elim (simple_inv_bind … H)
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/lazyor_5.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/lazyor_5.etc
new file mode 100644 (file)
index 0000000..70d3a1c
--- /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 f ] break term 46 L2 ≡ break term 46 L )"
+   non associative with precedence 45
+   for @{ 'LazyOr $L1 $T $f $L2 $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/lrsubeq_4.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/lrsubeq_4.etc
new file mode 100644 (file)
index 0000000..6135be4
--- /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 l , break term 46 m ] break term 46 L2 )"
+   non associative with precedence 45
+   for @{ 'LRSubEq $L1 $l $k $L2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubst_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubst_6.etc
new file mode 100644 (file)
index 0000000..56cb72e
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ [ term 46 l , break term 46 m ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubst $G $L $T1 $l $k $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststar_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststar_6.etc
new file mode 100644 (file)
index 0000000..90362ed
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ * [ term 46 l , break term 46 m ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStar $G $L $T1 $l $k $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststaralt_6.etc b/matita/matita/contribs/lambdadelta/basic_2/etc_new/psubststaralt_6.etc
new file mode 100644 (file)
index 0000000..80a29a8
--- /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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ ▶ * [ term 46 l , break term 46 m ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'PSubstStarAlt $G $L $T1 $l $k $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/aarity.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/aarity.ma
deleted file mode 100644 (file)
index 7f44246..0000000
+++ /dev/null
@@ -1,73 +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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* THE FORMAL SYSTEM λδ: MATITA SOURCE FILES
- * Initial invocation: - Patience on me to gain peace and perfection! -
- *)
-
-include "ground_2/lib/star.ma".
-include "basic_2/notation/constructors/item0_0.ma".
-include "basic_2/notation/constructors/snitem2_2.ma".
-
-(* ATOMIC ARITY *************************************************************)
-
-inductive aarity: Type[0] ≝
-  | AAtom: aarity                   (* atomic aarity construction *)
-  | APair: aarity → aarity → aarity (* binary aarity construction *)
-.
-
-interpretation "atomic arity construction (atomic)"
-   'Item0 = AAtom.
-
-interpretation "atomic arity construction (binary)"
-   'SnItem2 A1 A2 = (APair A1 A2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact destruct_apair_apair_aux: ∀A1,A2,B1,B2. ②B1.A1 = ②B2.A2 → B1 = B2 ∧ A1 = A2.
-#A1 #A2 #B1 #B2 #H destruct /2 width=1 by conj/
-qed-.
-
-lemma discr_apair_xy_x: ∀A,B. ②B.A = B → ⊥.
-#A #B elim B -B
-[ #H destruct
-| #Y #X #IHY #_ #H elim (destruct_apair_apair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
-]
-qed-.
-
-lemma discr_tpair_xy_y: ∀B,A. ②B. A = A → ⊥.
-#B #A elim A -A
-[ #H destruct
-| #Y #X #_ #IHX #H elim (destruct_apair_apair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
-]
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma eq_aarity_dec: ∀A1,A2:aarity. Decidable (A1 = A2).
-#A1 elim A1 -A1
-[ #A2 elim A2 -A2 /2 width=1 by or_introl/
-  #B2 #A2 #_ #_ @or_intror #H destruct
-| #B1 #A1 #IHB1 #IHA1 #A2 elim A2 -A2
-  [ -IHB1 -IHA1 @or_intror #H destruct
-  | #B2 #A2 #_ #_ elim (IHB1 B2) -IHB1
-    [ #H destruct elim (IHA1 A2) -IHA1
-      [ #H destruct /2 width=1 by or_introl/
-      | #HA12 @or_intror #H destruct /2 width=1 by/
-      ]
-    | -IHA1 #HB12 @or_intror #H destruct /2 width=1 by/
-    ]
-  ]
-]
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/append.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/append.ma
deleted file mode 100644 (file)
index cdbb45d..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 "ground_2/notation/functions/append_2.ma".
-include "basic_2/notation/functions/snbind2_3.ma".
-include "basic_2/notation/functions/snabbr_2.ma".
-include "basic_2/notation/functions/snabst_2.ma".
-include "basic_2/grammar/lenv.ma".
-
-(* APPEND FOR LOCAL ENVIRONMENTS ********************************************)
-
-rec definition append L K on K ≝ match K with
-[ LAtom       ⇒ L
-| LPair K I V ⇒ (append L K).ⓑ{I}V
-].
-
-interpretation "append (local environment)" 'Append L1 L2 = (append L1 L2).
-
-interpretation "local environment tail binding construction (binary)"
-   'SnBind2 I T L = (append (LPair LAtom I T) L).
-
-interpretation "tail abbreviation (local environment)"
-   'SnAbbr T L = (append (LPair LAtom Abbr T) L).
-
-interpretation "tail abstraction (local environment)"
-   'SnAbst L T = (append (LPair LAtom Abst T) L).
-
-definition d_appendable_sn: predicate (lenv→relation term) ≝ λR.
-                            ∀K,T1,T2. R K T1 T2 → ∀L. R (L@@K) T1 T2.
-
-(* Basic properties *********************************************************)
-
-lemma append_atom: ∀L. L @@ ⋆ = L.
-// qed.
-
-lemma append_pair: ∀I,L,K,V. L@@(K.ⓑ{I}V) = (L@@K).ⓑ{I}V.
-// qed.
-
-lemma append_atom_sn: ∀L. ⋆@@L = L.
-#L elim L -L //
-#L #I #V >append_pair //
-qed.
-
-lemma append_assoc: associative … append.
-#L1 #L2 #L3 elim L3 -L3 //
-qed.
-
-lemma append_shift: ∀L,K,I,V. L@@(ⓑ{I}V.K) = (L.ⓑ{I}V)@@K.
-#L #K #I #V <append_assoc //
-qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma append_inj_sn: ∀K,L1,L2. L1@@K = L2@@K → L1 = L2.
-#K elim K -K //
-#K #I #V #IH #L1 #L2 >append_pair #H
-elim (destruct_lpair_lpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/append_length.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/append_length.ma
deleted file mode 100644 (file)
index 21e5a86..0000000
+++ /dev/null
@@ -1,116 +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/grammar/lenv_length.ma".
-include "basic_2/grammar/append.ma".
-
-(* APPEND FOR LOCAL ENVIRONMENTS ********************************************)
-
-(* Properties with length for local environments ****************************)
-
-lemma append_length: ∀L1,L2. |L1 @@ L2| = |L1| + |L2|.
-#L1 #L2 elim L2 -L2 //
-#L2 #I #V2 >append_pair >length_pair >length_pair //
-qed.
-
-lemma ltail_length: ∀I,L,V. |ⓑ{I}V.L| = ⫯|L|.
-#I #L #V >append_length //
-qed.
-
-(* Basic_1: was just: chead_ctail *)
-lemma lpair_ltail: ∀L,I,V. ∃∃J,K,W. L.ⓑ{I}V = ⓑ{J}W.K & |L| = |K|.
-#L elim L -L /2 width=5 by ex2_3_intro/
-#L #Z #X #IHL #I #V elim (IHL Z X) -IHL
-#J #K #W #H #_ >H -H >ltail_length
-@(ex2_3_intro … J (K.ⓑ{I}V) W) /2 width=1 by length_pair/
-qed-.
-
-(* Advanced inversion lemmas on length for local environments ***************)
-
-(* Basic_2A1: was: length_inv_pos_dx_ltail *)
-lemma length_inv_succ_dx_ltail: ∀L,l. |L| = ⫯l →
-                               ∃∃I,K,V. |K| = l & L = ⓑ{I}V.K.
-#Y #l #H elim (length_inv_succ_dx … H) -H #I #L #V #Hl #HLK destruct
-elim (lpair_ltail L I V) /2 width=5 by ex2_3_intro/
-qed-.
-
-(* Basic_2A1: was: length_inv_pos_sn_ltail *)
-lemma length_inv_succ_sn_ltail: ∀L,l. ⫯l = |L| →
-                               ∃∃I,K,V. l = |K| & L = ⓑ{I}V.K.
-#Y #l #H elim (length_inv_succ_sn … H) -H #I #L #V #Hl #HLK destruct
-elim (lpair_ltail L I V) /2 width=5 by ex2_3_intro/
-qed-.
-
-(* Inversion lemmas with length for local environments **********************)
-
-(* Basic_2A1: was: append_inj_sn *)
-lemma append_inj_length_sn: ∀K1,K2,L1,L2. L1 @@ K1 = L2 @@ K2 → |K1| = |K2| →
-                            L1 = L2 ∧ K1 = K2.
-#K1 elim K1 -K1
-[ * /2 width=1 by conj/
-  #K2 #I2 #V2 #L1 #L2 #_ >length_atom >length_pair
-  #H destruct
-| #K1 #I1 #V1 #IH *
-  [ #L1 #L2 #_ >length_atom >length_pair
-    #H destruct
-  | #K2 #I2 #V2 #L1 #L2 #H1 #H2
-    elim (destruct_lpair_lpair_aux … H1) -H1 #H1 #H3 #H4 destruct (**) (* destruct lemma needed *)
-    elim (IH … H1) -IH -H1 /2 width=1 by conj/
-  ]
-]
-qed-.
-
-(* Note: lemma 750 *)
-(* Basic_2A1: was: append_inj_dx *)
-lemma append_inj_length_dx: ∀K1,K2,L1,L2. L1 @@ K1 = L2 @@ K2 → |L1| = |L2| →
-                            L1 = L2 ∧ K1 = K2.
-#K1 elim K1 -K1
-[ * /2 width=1 by conj/
-  #K2 #I2 #V2 #L1 #L2 >append_atom >append_pair #H destruct
-  >length_pair >append_length >plus_n_Sm
-  #H elim (plus_xSy_x_false … H)
-| #K1 #I1 #V1 #IH *
-  [ #L1 #L2 >append_pair >append_atom #H destruct
-    >length_pair >append_length >plus_n_Sm #H
-    lapply (discr_plus_x_xy … H) -H #H destruct
-  | #K2 #I2 #V2 #L1 #L2 >append_pair >append_pair #H1 #H2
-    elim (destruct_lpair_lpair_aux … H1) -H1 #H1 #H3 #H4 destruct (**) (* destruct lemma needed *)
-    elim (IH … H1) -IH -H1 /2 width=1 by conj/
-  ]
-]
-qed-.
-
-(* Advanced inversion lemmas ************************************************)
-
-lemma append_inj_dx: ∀L,K1,K2. L@@K1 = L@@K2 → K1 = K2.
-#L #K1 #K2 #H elim (append_inj_length_dx … H) -H //
-qed-.
-
-lemma append_inv_refl_dx: ∀L,K. L@@K = L → K = ⋆.
-#L #K #H elim (append_inj_dx … (⋆) … H) //
-qed-.
-
-lemma append_inv_pair_dx: ∀I,L,K,V. L@@K = L.ⓑ{I}V → K = ⋆.ⓑ{I}V.
-#I #L #K #V #H elim (append_inj_dx … (⋆.ⓑ{I}V) … H) //
-qed-.
-
-(* Basic eliminators ********************************************************)
-
-(* Basic_1: was: c_tail_ind *)
-lemma lenv_ind_alt: ∀R:predicate lenv.
-                    R (⋆) → (∀I,L,T. R L → R (ⓑ{I}T.L)) →
-                    ∀L. R L.
-#R #IH1 #IH2 #L @(f_ind … length … L) -L #x #IHx * // -IH1
-#L #I #V #H destruct elim (lpair_ltail L I V) /4 width=1 by/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/ceq.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/ceq.ma
deleted file mode 100644 (file)
index abd6b25..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/grammar/lenv.ma".
-
-(* CONTEXT-SENSITIVE EQUIVALENCES FOR TERMS *********************************)
-
-definition ceq: relation3 lenv term term ≝ λL,T1,T2. T1 = T2.
-
-definition cfull: relation3 lenv term term ≝ λL,T1,T2. ⊤.
-
-(* Basic properties *********************************************************)
-
-lemma ceq_refl (L): reflexive … (ceq L).
-// qed.
-
-lemma cfull_refl (L): reflexive … (cfull L).
-// qed.
-
-lemma ceq_sym (L): symmetric … (ceq L).
-// qed-.
-
-lemma cfull_sym (L): symmetric … (cfull L).
-// qed-.
-
-lemma cfull_top (R:relation3 lenv term term) (L) (T1) (T2):
-                R L T1 T2 → cfull L T1 T2.
-// qed-.
-
-lemma ceq_cfull (L) (T1) (T2): ceq L T1 T2 → cfull L T1 T2.
-// qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/ceq_ceq.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/ceq_ceq.ma
deleted file mode 100644 (file)
index 142f3b8..0000000
+++ /dev/null
@@ -1,37 +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/grammar/ceq.ma".
-
-(* CONTEXT-SENSITIVE EQUIVALENCES FOR TERMS *********************************)
-
-(* Main properties **********************************************************)
-
-theorem ceq_trans (L): Transitive … (ceq L).
-// qed-.
-
-lemma ceq_canc_sn (L): left_cancellable … (ceq L).
-// qed-.
-
-lemma ceq_canc_dx (L): right_cancellable … (ceq L).
-// qed-.
-
-theorem cfull_trans (L): Transitive … (cfull L).
-// qed-.
-
-lemma cfull_canc_sn (L): left_cancellable … (cfull L).
-// qed-.
-
-lemma cfull_canc_dx (L): right_cancellable … (cfull L).
-// qed-.
\ No newline at end of file
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/cl_restricted_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/cl_restricted_weight.ma
deleted file mode 100644 (file)
index fcf5607..0000000
+++ /dev/null
@@ -1,51 +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/functions/weight_2.ma".
-include "basic_2/grammar/lenv_weight.ma".
-
-(* WEIGHT OF A RESTRICTED CLOSURE *******************************************)
-
-definition rfw: lenv → term → ? ≝ λL,T. ♯{L} + ♯{T}.
-
-interpretation "weight (restricted closure)" 'Weight L T = (rfw L T).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: flt_shift *)
-lemma rfw_shift: ∀p,I,K,V,T. ♯{K.ⓑ{I}V, T} < ♯{K, ⓑ{p,I}V.T}.
-normalize /2 width=1 by monotonic_le_plus_r/
-qed.
-
-lemma rfw_tpair_sn: ∀I,L,V,T. ♯{L, V} < ♯{L, ②{I}V.T}.
-normalize in ⊢ (?→?→?→?→?%%); //
-qed.
-
-lemma rfw_tpair_dx: ∀I,L,V,T. ♯{L, T} < ♯{L, ②{I}V.T}.
-normalize in ⊢ (?→?→?→?→?%%); //
-qed.
-
-lemma rfw_lpair_sn: ∀I,L,V,T. ♯{L, V} < ♯{L.ⓑ{I}V, T}.
-normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
-qed.
-
-lemma rfw_lpair_dx: ∀I,L,V,T. ♯{L, T} < ♯{L.ⓑ{I}V, T}.
-normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
-qed.
-
-(* Basic_1: removed theorems 7:
-            flt_thead_sx flt_thead_dx flt_trans
-            flt_arith0 flt_arith1 flt_arith2 flt_wf_ind
-*)
-(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/cl_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/cl_weight.ma
deleted file mode 100644 (file)
index bd837d4..0000000
+++ /dev/null
@@ -1,49 +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/functions/weight_3.ma".
-include "basic_2/grammar/lenv_weight.ma".
-include "basic_2/grammar/genv.ma".
-
-(* WEIGHT OF A CLOSURE ******************************************************)
-
-(* activate genv *)
-definition fw: genv → lenv → term → ? ≝ λG,L,T. ♯{L} + ♯{T}.
-
-interpretation "weight (closure)" 'Weight G L T = (fw G L T).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: flt_shift *)
-lemma fw_shift: ∀p,I,G,K,V,T. ♯{G, K.ⓑ{I}V, T} < ♯{G, K, ⓑ{p,I}V.T}.
-normalize /2 width=1 by monotonic_le_plus_r/
-qed.
-
-lemma fw_tpair_sn: ∀I,G,L,V,T. ♯{G, L, V} < ♯{G, L, ②{I}V.T}.
-normalize in ⊢ (?→?→?→?→?→?%%); //
-qed.
-
-lemma fw_tpair_dx: ∀I,G,L,V,T. ♯{G, L, T} < ♯{G, L, ②{I}V.T}.
-normalize in ⊢ (?→?→?→?→?→?%%); //
-qed.
-
-lemma fw_lpair_sn: ∀I,G,L,V,T. ♯{G, L, V} < ♯{G, L.ⓑ{I}V, T}.
-normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
-qed.
-
-(* Basic_1: removed theorems 7:
-            flt_thead_sx flt_thead_dx flt_trans
-            flt_arith0 flt_arith1 flt_arith2 flt_wf_ind
-*)
-(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/genv.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/genv.ma
deleted file mode 100644 (file)
index c614e0f..0000000
+++ /dev/null
@@ -1,41 +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/lib/list2.ma".
-include "basic_2/notation/constructors/star_0.ma".
-include "basic_2/notation/constructors/dxbind2_3.ma".
-include "basic_2/notation/constructors/dxabbr_2.ma".
-include "basic_2/notation/constructors/dxabst_2.ma".
-include "basic_2/grammar/term.ma".
-
-(* GLOBAL ENVIRONMENTS ******************************************************)
-
-(* global environments *)
-definition genv ≝ list2 bind2 term.
-
-interpretation "sort (global environment)"
-   'Star = (nil2 bind2 term).
-
-interpretation "global environment binding construction (binary)"
-   'DxBind2 L I T = (cons2 bind2 term I T L).
-
-interpretation "abbreviation (global environment)"
-   'DxAbbr L T = (cons2 bind2 term Abbr T L).
-
-interpretation "abstraction (global environment)"
-   'DxAbst L T = (cons2 bind2 term Abst T L).
-
-(* Basic properties *********************************************************)
-
-axiom eq_genv_dec: ∀G1,G2:genv. Decidable (G1 = G2).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/item.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/item.ma
deleted file mode 100644 (file)
index ab861be..0000000
+++ /dev/null
@@ -1,88 +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/lib/bool.ma".
-include "ground_2/lib/arith.ma".
-
-(* ITEMS ********************************************************************)
-
-(* atomic items *)
-inductive item0: Type[0] ≝
-   | Sort: nat → item0 (* sort: starting at 0 *)
-   | LRef: nat → item0 (* reference by index: starting at 0 *)
-   | GRef: nat → item0 (* reference by position: starting at 0 *)
-.
-
-(* binary binding items *)
-inductive bind2: Type[0] ≝
-  | Abbr: bind2 (* abbreviation *)
-  | Abst: bind2 (* abstraction *)
-.
-
-(* binary non-binding items *)
-inductive flat2: Type[0] ≝
-  | Appl: flat2 (* application *)
-  | Cast: flat2 (* explicit type annotation *)
-.
-
-(* binary items *)
-inductive item2: Type[0] ≝
-  | Bind2: bool → bind2 → item2 (* polarized binding item *)
-  | Flat2: flat2 → item2        (* non-binding item *)
-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact destruct_sort_sort_aux: ∀s1,s2. Sort s1 = Sort s2 → s1 = s2.
-#s1 #s2 #H destruct //
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma eq_item0_dec: ∀I1,I2:item0. Decidable (I1 = I2).
-* #i1 * #i2 [2,3,4,6,7,8: @or_intror #H destruct ]
-[2: elim (eq_nat_dec i1 i2) |1,3: elim (eq_nat_dec i1 i2) ] /2 width=1 by or_introl/
-#Hni12 @or_intror #H destruct /2 width=1 by/
-qed-.
-
-(* Basic_1: was: bind_dec *)
-lemma eq_bind2_dec: ∀I1,I2:bind2. Decidable (I1 = I2).
-* * /2 width=1 by or_introl/
-@or_intror #H destruct
-qed-.
-
-(* Basic_1: was: flat_dec *)
-lemma eq_flat2_dec: ∀I1,I2:flat2. Decidable (I1 = I2).
-* * /2 width=1 by or_introl/
-@or_intror #H destruct
-qed-.
-
-(* Basic_1: was: kind_dec *)
-lemma eq_item2_dec: ∀I1,I2:item2. Decidable (I1 = I2).
-* [ #p1 ] #I1 * [1,3: #p2 ] #I2
-[2,3: @or_intror #H destruct
-| elim (eq_bool_dec p1 p2) #Hp
-  [ elim (eq_bind2_dec I1 I2) /2 width=1 by or_introl/ #HI ]
-  @or_intror #H destruct /2 width=1 by/
-| elim (eq_flat2_dec I1 I2) /2 width=1 by or_introl/ #HI
-  @or_intror #H destruct /2 width=1 by/
-]
-qed-.
-
-(* Basic_1: removed theorems 21:
-            s_S s_plus s_plus_sym s_minus minus_s_s s_le s_lt s_inj s_inc
-            s_arith0 s_arith1
-            r_S r_plus r_plus_sym r_minus r_dis s_r r_arith0 r_arith1
-            not_abbr_abst bind_dec_not
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv.ma
deleted file mode 100644 (file)
index 80738eb..0000000
+++ /dev/null
@@ -1,71 +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/constructors/star_0.ma".
-include "basic_2/notation/constructors/dxbind2_3.ma".
-include "basic_2/notation/constructors/dxabbr_2.ma".
-include "basic_2/notation/constructors/dxabst_2.ma".
-include "basic_2/grammar/term.ma".
-
-(* LOCAL ENVIRONMENTS *******************************************************)
-
-(* local environments *)
-inductive lenv: Type[0] ≝
-| LAtom: lenv                       (* empty *)
-| LPair: lenv → bind2 → term → lenv (* binary binding construction *)
-.
-
-interpretation "sort (local environment)"
-   'Star = LAtom.
-
-interpretation "local environment binding construction (binary)"
-   'DxBind2 L I T = (LPair L I T).
-
-interpretation "abbreviation (local environment)"
-   'DxAbbr L T = (LPair L Abbr T).
-
-interpretation "abstraction (local environment)"
-   'DxAbst L T = (LPair L Abst T).
-
-(* Basic properties *********************************************************)
-
-lemma eq_lenv_dec: ∀L1,L2:lenv. Decidable (L1 = L2).
-#L1 elim L1 -L1 [| #L1 #I1 #V1 #IHL1 ] * [2,4: #L2 #I2 #V2 ]
-[1,4: @or_intror #H destruct
-| elim (eq_bind2_dec I1 I2) #HI
-  [ elim (eq_term_dec V1 V2) #HV
-    [ elim (IHL1 L2) -IHL1 /2 width=1 by or_introl/ #HL ]
-  ]
-  @or_intror #H destruct /2 width=1 by/
-| /2 width=1 by or_introl/
-]
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact destruct_lpair_lpair_aux: ∀I1,I2,L1,L2,V1,V2. L1.ⓑ{I1}V1 = L2.ⓑ{I2}V2 →
-                               ∧∧L1 = L2 & I1 = I2 & V1 = V2.
-#I1 #I2 #L1 #L2 #V1 #V2 #H destruct /2 width=1 by and3_intro/
-qed-.
-
-lemma discr_lpair_x_xy: ∀I,V,L. L = L.ⓑ{I}V → ⊥.
-#I #V #L elim L -L
-[ #H destruct
-| #L #J #W #IHL #H
-  elim (destruct_lpair_lpair_aux … H) -H #H1 #H2 #H3 destruct /2 width=1 by/ (**) (* destruct lemma needed *)
-]
-qed-.
-
-lemma discr_lpair_xy_x: ∀I,V,L. L.ⓑ{I}V = L→ ⊥.
-/2 width=4 by discr_lpair_x_xy/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_length.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_length.ma
deleted file mode 100644 (file)
index a7a99ba..0000000
+++ /dev/null
@@ -1,58 +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/grammar/lenv.ma".
-
-(* LENGTH OF A LOCAL ENVIRONMENT ********************************************)
-
-rec definition length L ≝ match L with
-[ LAtom       ⇒ 0
-| LPair L _ _ ⇒ ⫯(length L)
-].
-
-interpretation "length (local environment)" 'card L = (length L).
-
-(* Basic properties *********************************************************)
-
-lemma length_atom: |⋆| = 0.
-// qed.
-
-lemma length_pair: ∀I,L,V. |L.ⓑ{I}V| = ⫯|L|.
-// qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma length_inv_zero_dx: ∀L. |L| = 0 → L = ⋆.
-* // #L #I #V >length_pair
-#H destruct
-qed-.
-
-lemma length_inv_zero_sn: ∀L. 0 = |L| → L = ⋆.
-/2 width=1 by length_inv_zero_dx/ qed-.
-
-(* Basic_2A1: was: length_inv_pos_dx *)
-lemma length_inv_succ_dx: ∀n,L. |L| = ⫯n →
-                          ∃∃I,K,V. |K| = n & L = K. ⓑ{I}V.
-#n * /3 width=5 by injective_S, ex2_3_intro/
->length_atom #H destruct
-qed-.
-
-(* Basic_2A1: was: length_inv_pos_sn *)
-lemma length_inv_succ_sn: ∀n,L. ⫯n = |L| →
-                          ∃∃I,K,V. n = |K| & L = K. ⓑ{I}V.
-#l #L #H lapply (sym_eq ??? H) -H 
-#H elim (length_inv_succ_dx … H) -H /2 width=5 by ex2_3_intro/
-qed-.
-
-(* Basic_2A1: removed theorems 1: length_inj *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/lenv_weight.ma
deleted file mode 100644 (file)
index c9d79e5..0000000
+++ /dev/null
@@ -1,34 +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/grammar/term_weight.ma".
-include "basic_2/grammar/lenv.ma".
-
-(* WEIGHT OF A LOCAL ENVIRONMENT ********************************************)
-
-rec definition lw L ≝ match L with
-[ LAtom       ⇒ 0
-| LPair L _ V ⇒ lw L + ♯{V}
-].
-
-interpretation "weight (local environment)" 'Weight L = (lw L).
-
-(* Basic properties *********************************************************)
-
-lemma lw_pair: ∀I,L,V. ♯{L} < ♯{L.ⓑ{I}V}.
-/3 width=1 by lt_plus_to_minus_r, monotonic_lt_plus_r/ qed.
-
-(* Basic_1: removed theorems 4: clt_cong clt_head clt_thead clt_wf_ind *)
-(* Basic_1: removed local theorems 1: clt_wf__q_ind *)
-(* Basic_1: note: clt_thead should be renamed clt_ctail *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/term.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/term.ma
deleted file mode 100644 (file)
index ff00f4f..0000000
+++ /dev/null
@@ -1,153 +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/constructors/item0_1.ma".
-include "basic_2/notation/constructors/snitem2_3.ma".
-include "basic_2/notation/constructors/snbind2_4.ma".
-include "basic_2/notation/constructors/snbind2pos_3.ma".
-include "basic_2/notation/constructors/snbind2neg_3.ma".
-include "basic_2/notation/constructors/snflat2_3.ma".
-include "basic_2/notation/constructors/star_1.ma".
-include "basic_2/notation/constructors/lref_1.ma".
-include "basic_2/notation/constructors/gref_1.ma".
-include "basic_2/notation/constructors/snabbr_3.ma".
-include "basic_2/notation/constructors/snabbrpos_2.ma".
-include "basic_2/notation/constructors/snabbrneg_2.ma".
-include "basic_2/notation/constructors/snabst_3.ma".
-include "basic_2/notation/constructors/snabstpos_2.ma".
-include "basic_2/notation/constructors/snabstneg_2.ma".
-include "basic_2/notation/constructors/snappl_2.ma".
-include "basic_2/notation/constructors/sncast_2.ma".
-include "basic_2/grammar/item.ma".
-
-(* TERMS ********************************************************************)
-
-(* terms *)
-inductive term: Type[0] ≝
-  | TAtom: item0 → term               (* atomic item construction *)
-  | TPair: item2 → term → term → term (* binary item construction *)
-.
-
-interpretation "term construction (atomic)"
-   'Item0 I = (TAtom I).
-
-interpretation "term construction (binary)"
-   'SnItem2 I T1 T2 = (TPair I T1 T2).
-
-interpretation "term binding construction (binary)"
-   'SnBind2 p I T1 T2 = (TPair (Bind2 p I) T1 T2).
-
-interpretation "term positive binding construction (binary)"
-   'SnBind2Pos I T1 T2 = (TPair (Bind2 true I) T1 T2).
-
-interpretation "term negative binding construction (binary)"
-   'SnBind2Neg I T1 T2 = (TPair (Bind2 false I) T1 T2).
-
-interpretation "term flat construction (binary)"
-   'SnFlat2 I T1 T2 = (TPair (Flat2 I) T1 T2).
-
-interpretation "sort (term)"
-   'Star s = (TAtom (Sort s)).
-
-interpretation "local reference (term)"
-   'LRef i = (TAtom (LRef i)).
-
-interpretation "global reference (term)"
-   'GRef l = (TAtom (GRef l)).
-
-interpretation "abbreviation (term)"
-   'SnAbbr p T1 T2 = (TPair (Bind2 p Abbr) T1 T2).
-
-interpretation "positive abbreviation (term)"
-   'SnAbbrPos T1 T2 = (TPair (Bind2 true Abbr) T1 T2).
-
-interpretation "negative abbreviation (term)"
-   'SnAbbrNeg T1 T2 = (TPair (Bind2 false Abbr) T1 T2).
-
-interpretation "abstraction (term)"
-   'SnAbst p T1 T2 = (TPair (Bind2 p Abst) T1 T2).
-
-interpretation "positive abstraction (term)"
-   'SnAbstPos T1 T2 = (TPair (Bind2 true Abst) T1 T2).
-
-interpretation "negative abstraction (term)"
-   'SnAbstNeg T1 T2 = (TPair (Bind2 false Abst) T1 T2).
-
-interpretation "application (term)"
-   'SnAppl T1 T2 = (TPair (Flat2 Appl) T1 T2).
-
-interpretation "native type annotation (term)"
-   'SnCast T1 T2 = (TPair (Flat2 Cast) T1 T2).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: term_dec *)
-lemma eq_term_dec: ∀T1,T2:term. Decidable (T1 = T2).
-#T1 elim T1 -T1 #I1 [| #V1 #T1 #IHV1 #IHT1 ] * #I2 [2,4: #V2 #T2 ]
-[1,4: @or_intror #H destruct
-| elim (eq_item2_dec I1 I2) #HI
-  [ elim (IHV1 V2) -IHV1 #HV
-    [ elim (IHT1 T2) -IHT1 /2 width=1 by or_introl/ #HT ]
-  ]
-  @or_intror #H destruct /2 width=1 by/
-| elim (eq_item0_dec I1 I2) /2 width=1 by or_introl/ #HI
-  @or_intror #H destruct /2 width=1 by/
-]
-qed-.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact destruct_tatom_tatom_aux: ∀I1,I2. ⓪{I1} = ⓪{I2} → I1 = I2.
-#I1 #I2 #H destruct //
-qed-.
-
-fact destruct_tpair_tpair_aux: ∀I1,I2,T1,T2,V1,V2. ②{I1}T1.V1 = ②{I2}T2.V2 →
-                               ∧∧T1 = T2 & I1 = I2 & V1 = V2.
-#I1 #I2 #T1 #T2 #V1 #V2 #H destruct /2 width=1 by and3_intro/
-qed-.
-
-lemma discr_tpair_xy_x: ∀I,T,V. ②{I}V.T = V → ⊥.
-#I #T #V elim V -V
-[ #J #H destruct
-| #J #W #U #IHW #_ #H elim (destruct_tpair_tpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
-]
-qed-.
-
-(* Basic_1: was: thead_x_y_y *)
-lemma discr_tpair_xy_y: ∀I,V,T. ②{I}V.T = T → ⊥.
-#I #V #T elim T -T
-[ #J #H destruct
-| #J #W #U #_ #IHU #H elim (destruct_tpair_tpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
-]
-qed-.
-
-lemma eq_false_inv_tpair_sn: ∀I,V1,T1,V2,T2.
-                             (②{I}V1.T1 = ②{I}V2.T2 → ⊥) →
-                             (V1 = V2 → ⊥) ∨ (V1 = V2 ∧ (T1 = T2 → ⊥)).
-#I #V1 #T1 #V2 #T2 #H
-elim (eq_term_dec V1 V2) /3 width=1 by or_introl/ #HV12 destruct
-@or_intror @conj // #HT12 destruct /2 width=1 by/
-qed-.
-
-lemma eq_false_inv_tpair_dx: ∀I,V1,T1,V2,T2.
-                             (②{I} V1. T1 = ②{I}V2.T2 → ⊥) →
-                             (T1 = T2 → ⊥) ∨ (T1 = T2 ∧ (V1 = V2 → ⊥)).
-#I #V1 #T1 #V2 #T2 #H
-elim (eq_term_dec T1 T2) /3 width=1 by or_introl/ #HT12 destruct
-@or_intror @conj // #HT12 destruct /2 width=1 by/
-qed-.
-
-(* Basic_1: removed theorems 3:
-            not_void_abst not_abbr_void not_abst_void
-*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/term_simple.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/term_simple.ma
deleted file mode 100644 (file)
index 6332ff1..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/notation/relations/simple_1.ma".
-include "basic_2/grammar/term.ma".
-
-(* SIMPLE (NEUTRAL) TERMS ***************************************************)
-
-inductive simple: predicate term ≝
-   | simple_atom: ∀I. simple (⓪{I})
-   | simple_flat: ∀I,V,T. simple (ⓕ{I} V. T)
-.
-
-interpretation "simple (term)" 'Simple T = (simple T).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact simple_inv_bind_aux: ∀T. 𝐒⦃T⦄ → ∀p,J,W,U. T = ⓑ{p,J}W.U → ⊥.
-#T * -T
-[ #I #p #J #W #U #H destruct
-| #I #V #T #a #J #W #U #H destruct
-]
-qed-.
-
-lemma simple_inv_bind: ∀p,I,V,T. 𝐒⦃ⓑ{p,I} V. T⦄ → ⊥.
-/2 width=7 by simple_inv_bind_aux/ qed-.
-
-lemma simple_inv_pair: ∀I,V,T.  𝐒⦃②{I}V.T⦄ → ∃J. I = Flat2 J.
-* /2 width=2 by ex_intro/
-#p #I #V #T #H elim (simple_inv_bind … H)
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/term_vector.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/term_vector.ma
deleted file mode 100644 (file)
index d33d4b4..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 "ground_2/lib/list.ma".
-include "basic_2/notation/functions/snapplvector_2.ma".
-include "basic_2/grammar/term_simple.ma".
-
-(* TERMS ********************************************************************)
-
-rec definition applv Vs T on Vs ≝
-  match Vs with
-  [ nil        ⇒ T
-  | cons hd tl ⇒ ⓐhd. (applv tl T)
-  ].
-
-interpretation "application to vector (term)"
-   'SnApplVector Vs T = (applv Vs T).
-
-(* Basic properties *********************************************************)
-
-lemma applv_nil: ∀T. Ⓐ◊.T = T.
-// qed.
-
-lemma applv_cons: ∀V,Vs,T. ⒶV@Vs.T = ⓐV.ⒶVs.T.
-// qed.
-
-(* Properties with simple terms *********************************************)
-
-lemma applv_simple: ∀T,Vs. 𝐒⦃T⦄ → 𝐒⦃ⒶVs.T⦄.
-#T * //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/term_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/term_weight.ma
deleted file mode 100644 (file)
index 2365926..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/notation/functions/weight_1.ma".
-include "basic_2/grammar/term.ma".
-
-(* WEIGHT OF A TERM *********************************************************)
-
-rec definition tw T ≝ match T with
-[ TAtom _     ⇒ 1
-| TPair _ V T ⇒ tw V + tw T + 1
-].
-
-interpretation "weight (term)" 'Weight T = (tw T).
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: tweight_lt *)
-lemma tw_pos: ∀T. 1 ≤ ♯{T}.
-#T elim T -T //
-qed.
-
-(* Basic_1: removed theorems 11:
-            wadd_le wadd_lt wadd_O weight_le weight_eq weight_add_O
-            weight_add_S tlt_trans tlt_head_sx tlt_head_dx tlt_wf_ind
-*)
-(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts.ma
deleted file mode 100644 (file)
index d3bc8ee..0000000
+++ /dev/null
@@ -1,108 +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/topiso_2.ma".
-include "basic_2/grammar/term_simple.ma".
-
-(* SAME TOP TERM STRUCTURE **************************************************)
-
-inductive tsts: relation term ≝
-   | tsts_atom: ∀I. tsts (⓪{I}) (⓪{I})
-   | tsts_pair: ∀I,V1,V2,T1,T2. tsts (②{I}V1.T1) (②{I}V2.T2)
-.
-
-interpretation "same top structure (term)" 'TopIso T1 T2 = (tsts T1 T2).
-
-(* Basic inversion lemmas ***************************************************)
-
-fact tsts_inv_atom1_aux: ∀T1,T2. T1 ≂ T2 → ∀I. T1 = ⓪{I} → T2 = ⓪{I}.
-#T1 #T2 * -T1 -T2 //
-#J #V1 #V2 #T1 #T2 #I #H destruct
-qed-.
-
-(* Basic_1: was: iso_gen_sort iso_gen_lref *)
-lemma tsts_inv_atom1: ∀I,T2. ⓪{I} ≂ T2 → T2 = ⓪{I}.
-/2 width=3 by tsts_inv_atom1_aux/ qed-.
-
-fact tsts_inv_pair1_aux: ∀T1,T2. T1 ≂ T2 → ∀I,W1,U1. T1 = ②{I}W1.U1 →
-                         ∃∃W2,U2. T2 = ②{I}W2. U2.
-#T1 #T2 * -T1 -T2
-[ #J #I #W1 #U1 #H destruct
-| #J #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct /2 width=3 by ex1_2_intro/
-]
-qed-.
-
-(* Basic_1: was: iso_gen_head *)
-lemma tsts_inv_pair1: ∀I,W1,U1,T2. ②{I}W1.U1 ≂ T2 →
-                      ∃∃W2,U2. T2 = ②{I}W2. U2.
-/2 width=5 by tsts_inv_pair1_aux/ qed-.
-
-fact tsts_inv_atom2_aux: ∀T1,T2. T1 ≂ T2 → ∀I. T2 = ⓪{I} → T1 = ⓪{I}.
-#T1 #T2 * -T1 -T2 //
-#J #V1 #V2 #T1 #T2 #I #H destruct
-qed-.
-
-lemma tsts_inv_atom2: ∀I,T1. T1 ≂ ⓪{I} → T1 = ⓪{I}.
-/2 width=3 by tsts_inv_atom2_aux/ qed-.
-
-fact tsts_inv_pair2_aux: ∀T1,T2. T1 ≂ T2 → ∀I,W2,U2. T2 = ②{I}W2.U2 →
-                         ∃∃W1,U1. T1 = ②{I}W1.U1.
-#T1 #T2 * -T1 -T2
-[ #J #I #W2 #U2 #H destruct
-| #J #V1 #V2 #T1 #T2 #I #W2 #U2 #H destruct /2 width=3 by ex1_2_intro/
-]
-qed-.
-
-lemma tsts_inv_pair2: ∀I,T1,W2,U2. T1 ≂ ②{I}W2.U2 →
-                      ∃∃W1,U1. T1 = ②{I}W1.U1.
-/2 width=5 by tsts_inv_pair2_aux/ qed-.
-
-(* Basic properties *********************************************************)
-
-(* Basic_1: was: iso_refl *)
-lemma tsts_refl: reflexive … tsts.
-#T elim T -T //
-qed.
-
-lemma tsts_sym: symmetric … tsts.
-#T1 #T2 #H elim H -T1 -T2 //
-qed-.
-
-lemma tsts_dec: ∀T1,T2. Decidable (T1 ≂ T2).
-* #I1 [2: #V1 #T1 ] * #I2 [2,4: #V2 #T2 ]
-[ elim (eq_item2_dec I1 I2) #HI12
-  [ destruct /2 width=1 by tsts_pair, or_introl/
-  | @or_intror #H
-    elim (tsts_inv_pair1 … H) -H #V #T #H destruct /2 width=1 by/
-  ]
-| @or_intror #H
-  lapply (tsts_inv_atom1 … H) -H #H destruct
-| @or_intror #H
-  lapply (tsts_inv_atom2 … H) -H #H destruct
-| elim (eq_item0_dec I1 I2) #HI12
-  [ destruct /2 width=1 by or_introl/
-  | @or_intror #H
-    lapply (tsts_inv_atom2 … H) -H #H destruct /2 width=1 by/
-  ]
-]
-qed.
-
-lemma simple_tsts_repl_dx: ∀T1,T2. T1 ≂ T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄.
-#T1 #T2 * -T1 -T2 //
-#I #V1 #V2 #T1 #T2 #H
-elim (simple_inv_pair … H) -H #J #H destruct //
-qed-.
-
-lemma simple_tsts_repl_sn: ∀T1,T2. T1 ≂ T2 → 𝐒⦃T2⦄ → 𝐒⦃T1⦄.
-/3 width=3 by simple_tsts_repl_dx, tsts_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_tsts.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_tsts.ma
deleted file mode 100644 (file)
index d46b497..0000000
+++ /dev/null
@@ -1,32 +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/grammar/tsts.ma".
-
-(* SAME TOP TERM STRUCTURE **************************************************)
-
-(* Main properties **********************************************************)
-
-(* Basic_1: was: iso_trans *)
-theorem tsts_trans: Transitive … tsts.
-#T1 #T * -T1 -T //
-#I #V1 #V #T1 #T #X #H
-elim (tsts_inv_pair1 … H) -H #V2 #T2 #H destruct //
-qed-.
-
-theorem tsts_canc_sn: ∀T,T1. T ≂ T1 → ∀T2. T ≂ T2 → T1 ≂ T2.
-/3 width=3 by tsts_trans, tsts_sym/ qed-.
-
-theorem tsts_canc_dx: ∀T1,T. T1 ≂ T → ∀T2. T2 ≂ T → T1 ≂ T2.
-/3 width=3 by tsts_trans, tsts_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_vector.ma b/matita/matita/contribs/lambdadelta/basic_2/grammar/tsts_vector.ma
deleted file mode 100644 (file)
index e903706..0000000
+++ /dev/null
@@ -1,30 +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/grammar/term_vector.ma".
-include "basic_2/grammar/tsts.ma".
-
-(* SAME TOP TERM STRUCTURE **************************************************)
-
-(* Advanced inversion lemmas ************************************************)
-
-(* Basic_1: was only: iso_flats_lref_bind_false iso_flats_flat_bind_false *)
-lemma tsts_inv_bind_applv_simple: ∀p,I,Vs,V2,T1,T2. ⒶVs.T1 ≂ ⓑ{p,I}V2.T2 →
-                                  𝐒⦃T1⦄ → ⊥.
-#p #I #Vs #V2 #T1 #T2 #H elim (tsts_inv_pair2 … H) -H
-#V0 #T0 elim Vs -Vs normalize
-[ #H destruct #H /2 width=5 by simple_inv_bind/
-| #V #Vs #_ #H destruct
-]
-qed-.
index bf8778e2d8783c0c2e7143bf5ae665cc780a1799..a1cb0e0d1ffd934e32782e0975d176485bed39f4 100644 (file)
@@ -26,9 +26,9 @@ i,j    : local reference depth (de Bruijn's)
 k,l    : global reference level
 m      : 
 n      : type iterations
-o      : sort degree parameter
+o      : sort degree parameter (origin)
 p,q    : binder polarity
-r      : reduction kind parameter (true = ordinary, false = extended)
+r      :
 s      : sort index
 t,u    :
 v,w    : local reference position level (de Bruijn's) (RTM)
index afd2f189242421edff40af9022f3ac8ae4d7ec27..80ba76465c8bc72485d1919d59e0a490d10332f6 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( T1 . break ⓓ T2 )"
+notation "hvbox( L . break ⓓ T1 )"
  left associative with precedence 48
- for @{ 'DxAbbr $T1 $T2 }.
+ for @{ 'DxAbbr $L $T1 }.
index 43e324eae26bc18640fad7403b9258e7c7efad35..5455e678e33fce6a4dd8ebfb25f706b66c313920 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( T1 . break ⓛ T2 )"
+notation "hvbox( L . break ⓛ T1 )"
  left associative with precedence 49
- for @{ 'DxAbst $T1 $T2 }.
+ for @{ 'DxAbst $L $T1 }.
index bbded1eabf7e8d6d2242a98e247287f3ed1aa7a6..b276334f1909e6a9d07256b838e1040b5acc9d75 100644 (file)
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation > "hvbox( T . break ②{ term 46 I } break term 47 T1 )"
+notation > "hvbox( L . break ②{ term 46 I } break term 47 T1 )"
  non associative with precedence 46
- for @{ 'DxBind2 $T $I $T1 }.
+ for @{ 'DxBind2 $L $I $T1 }.
 
-notation "hvbox( T . break ⓑ { term 46 I } break term 48 T1 )"
+notation "hvbox( L . break ⓑ { term 46 I } break term 48 T1 )"
  non associative with precedence 47
- for @{ 'DxBind2 $T $I $T1 }.
+ for @{ 'DxBind2 $L $I $T1 }.
index 68a41ffc0f6a5df105489a6d17cef5850b43c574..7e58d203e03b548fc53ad5b4da19c411f84f11ad 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≽ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≽ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'BTPRed $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
index 97ea5b59ff4e6a301d9bb873f3221c7a289b1986..2e0ebf5a053a8454668f035f9d613bc5fdc175fe 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≽ ≽ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≽ ≽ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'BTPRedAlt $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
index 2dce25d436de1f9d9aa44bf4ef25b2921da3b078..e036aa7d5c54157d6e6a967315bb17494d840a09 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≻ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≻ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'BTPRedProper $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
index c48d221d40f115a912a6be176d34b7f1da816032..6d216e2faa58cd8d885a3092ff646cfa158194bf 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≥ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≥ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'BTPRedStar $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
index 79b3fd9d274cd1b4a931aabb83cb4f86b566364a..3b2cd2bfe8c788427ac10071b0582e476513ea86 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≥ ≥ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ ≥ ≥ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'BTPRedStarAlt $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
index 06d5b7b88ffdb4912646835406ba1fd6e5834e40..7abf15de85462246c9ad329a32cb8fc3fa948cdd 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦥ [ term 46 o, break term 46 h ] break ⦃ term 46 G, break term 46 L, break term 46 T ⦄ )"
+notation "hvbox( ⦥ [ term 46 h, break term 46 o ] break ⦃ term 46 G, break term 46 L, break term 46 T ⦄ )"
    non associative with precedence 45
    for @{ 'BTSN $h $o $G $L $T }.
index c303e309ef75f8fafdbfa761dc266faebfb9dc7c..5e9d1ec67e69a2ea741231c39b06cb63958383ed 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦥ ⦥ [ term 46 o, break term 46 h ] break ⦃ term 46 G, break term 46 L, break term 46 T ⦄ )"
+notation "hvbox( ⦥ ⦥ [ term 46 h, break term 46 o ] break ⦃ term 46 G, break term 46 L, break term 46 T ⦄ )"
    non associative with precedence 45
    for @{ 'BTSNAlt $h $o $G $L $T }.
index e9c9e645d64da087ab92539ceb44e640a5d54af2..ef632cba93c7c69d22b237a3b2c75954e37b92e6 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( G ⊢ ~ ⬊ * break [ term 46 o , break term 46 h , break term 46 f ] break term 46 L )"
+notation "hvbox( G ⊢ ~ ⬊ * break [ term 46 h , break term 46 o , break term 46 f ] break term 46 L )"
    non associative with precedence 45
    for @{ 'CoSN $h $o $f $G $L }.
index 8ae707641d9643830af74d8f7e56f1c751969c0e..8d37f521747d6e1f2ede222596a5012d4b8d1cd4 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • * ⬌ * break [ term 46 o , break term 46 h , break term 46 n1 , break term 46 n2 ] break term 46 T2 )"
+notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • * ⬌ * break [ term 46 h , break term 46 o , break term 46 n1 , break term 46 n2 ] break term 46 T2 )"
    non associative with precedence 45
    for @{ 'DPConvStar $h $o $n1 $n2 $G $L $T1 $T2 }.
index a85c0e4f890c3cc3a437814b4dc37f81d14b2a83..d9ab259abde18c8e87eabb749719910620b09c7c 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • * ➡ * break [ term 46 o , break term 46 h , break term 46 n ] break term 46 T2 )"
+notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 • * ➡ * break [ term 46 h , break term 46 o , break term 46 n ] break term 46 T2 )"
    non associative with precedence 45
    for @{ 'DPRedStar $h $o $n $G $L $T1 $T2 }.
index c99a3af6de02c4bded3fdeb7b76b2600b9b7d1d2..9c1252ac74025b1586ed4ca169cecd5ec9c27f0d 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ >≡ break [ term 46 o, break term 46 h ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G1, break term 46 L1, break term 46 T1 ⦄ >≡ break [ term 46 h, break term 46 o ] break ⦃ term 46 G2, break term 46 L2 , break term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'LazyBTPRedStarProper $h $o $G1 $L1 $T1 $G2 $L2 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyeq_4.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyeq_4.ma
new file mode 100644 (file)
index 0000000..aec1914
--- /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( T1 ≡ break [ term 46 h , term 46 o ] break term 46 T2 )"
+   non associative with precedence 45
+   for @{ 'LazyEq $h $o $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyor_5.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lazyor_5.ma
deleted file mode 100644 (file)
index 70d3a1c..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 f ] break term 46 L2 ≡ break term 46 L )"
-   non associative with precedence 45
-   for @{ 'LazyOr $L1 $T $f $L2 $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lrsubeq_4.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/lrsubeq_4.ma
deleted file mode 100644 (file)
index 6135be4..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 l , break term 46 m ] break term 46 L2 )"
-   non associative with precedence 45
-   for @{ 'LRSubEq $L1 $l $k $L2 }.
index f39c6bcc7b12466aa6f763b9f7121711131bf4a5..d404926bf05448fb43f987157e90493f3d4e69db 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( G ⊢ break term 46 L1 ⫃ ¡ break [ term 46 o, break term 46 h ] break term 46 L2 )"
+notation "hvbox( G ⊢ break term 46 L1 ⫃ ¡ break [ term 46 h, break term 46 o ] break term 46 L2 )"
    non associative with precedence 45
    for @{ 'LRSubEqV $h $o $G $L1 $L2 }.
index 50e2452c2cfe181ae5d8f2bbd9154843171a3719..4efadabad0a22b747d4935702690ad9ad8ba2f35 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T ¡ break [ term 46 o, break term 46 h ] )"
+notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T ¡ break [ term 46 h, break term 46 o ] )"
    non associative with precedence 45
    for @{ 'NativeValid $h $o $G $L $T }.
index 2cd233332d9eae59ee6932d0b1043254e1585115..d387e60be7cbcdaacfea773c8c5f191af5b9a378 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T ¡ break [ term 46 o , break term 46 h , break term 46 d ] )"
+notation "hvbox( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T ¡ break [ term 46 h , break term 46 o , break term 46 d ] )"
    non associative with precedence 45
    for @{ 'NativeValid $h $o $d $G $L $T }.
index 80c61f26f23c289c9e6b10120383286a28bad280..391f21f3c0b30aa1c80d5a3d1d5e7e7de3bbf9fc 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ➡ * break [ term 46 o , break term 46 h ] break 𝐍 ⦃ term 46 T2 ⦄ )"
+notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ➡ * break [ term 46 h , break term 46 o ] break 𝐍 ⦃ term 46 T2 ⦄ )"
    non associative with precedence 45
    for @{ 'PRedEval $h $o $G $L $T1 $T2 }.
index 3b12bc0e90184d45f24caa26a2c15d7882d92308..bb2d10464d0010500f74db93ead4bc28a3c70358 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G, break term 46 L1 ⦄ ⊢ ➡ * break [ term 46 o , break term 46 h ] break term 46 L2 )"
+notation "hvbox( ⦃ term 46 G, break term 46 L1 ⦄ ⊢ ➡ * break [ term 46 h , break term 46 o ] break term 46 L2 )"
    non associative with precedence 45
    for @{ 'PRedSnStar $h $o $G $L1 $L2 }.
index b336dd9d70f1ab7bff5366f60f7db66ae9a48fb0..265244809b2a9962e2fdf3749cbd04221aff9fd8 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ➡ * break [ term 46 o , break term 46 h ] break term 46 T2 )"
+notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ break term 46 T1 ➡ * break [ term 46 h , break term 46 o ] break term 46 T2 )"
    non associative with precedence 45
    for @{ 'PRedStar $h $o $G $L $T1 $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubst_6.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubst_6.ma
deleted file mode 100644 (file)
index 56cb72e..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ [ term 46 l , break term 46 m ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubst $G $L $T1 $l $k $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststar_6.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststar_6.ma
deleted file mode 100644 (file)
index 90362ed..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ * [ term 46 l , break term 46 m ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStar $G $L $T1 $l $k $T2 }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststaralt_6.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/relations/psubststaralt_6.ma
deleted file mode 100644 (file)
index 80a29a8..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( ⦃ term 46 G , break term 46 L ⦄ ⊢ break term 46 T1 break ▶ ▶ * [ term 46 l , break term 46 m ] break term 46 T2 )"
-   non associative with precedence 45
-   for @{ 'PSubstStarAlt $G $L $T1 $l $k $T2 }.
index 050140b69fb467b2f777e950ac65ce8edf92798a..4ac3bc7aa5b89c964ec39dafe0954b07b56dadfa 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ ⬊ * break [ term 46 o, break term 46 h ] break term 46 T )"
+notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ ⬊ * break [ term 46 h, break term 46 o ] break term 46 T )"
    non associative with precedence 45
    for @{ 'SN $h $o $G $L $T }.
index ea018c41b2ca83525148a0b72b590a14b3cf13b1..268bd0b61c472948650ae3fb03a76895fff9247a 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( G ⊢ ⬊ * break [ term 46 o , break term 46 h , break term 46 T , break term 46 f ] break term 46 L )"
+notation "hvbox( G ⊢ ⬊ * break [ term 46 h , break term 46 o , break term 46 T , break term 46 f ] break term 46 L )"
    non associative with precedence 45
    for @{ 'SN $h $o $T $f $G $L }.
index 0c624b913dd94f973128a7695a3ec7fe8df26df9..59196e5b129af6ae9da788ee41cec7631d8a9b2a 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ ⬊ ⬊ * break [ term 46 o , break term 46 h ] break term 46 T )"
+notation "hvbox( ⦃ term 46 G, break term 46 L ⦄ ⊢ ⬊ ⬊ * break [ term 46 h , break term 46 o ] break term 46 T )"
    non associative with precedence 45
    for @{ 'SNAlt $h $o $G $L $T }.
index 09e6918e09b51bf513a96657e3dd1f8e1b31844a..8f59a5f1c8ba61b1b9e1b4b55ac143b22d25c444 100644 (file)
@@ -14,6 +14,6 @@
 
 (* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
 
-notation "hvbox( G ⊢ ⬊ ⬊ * break [ term 46 o , break term 46 h , break term 46 T , break term 46 f ] break term 46 L )"
+notation "hvbox( G ⊢ ⬊ ⬊ * break [ term 46 h , break term 46 o , break term 46 T , break term 46 f ] break term 46 L )"
    non associative with precedence 45
    for @{ 'SNAlt $h $o $T $f $G $L }.
index 546485cb5ab7b6292a4ec8b987fef3a9a1cda26f..7426ebb5359d0571b79f40bb4c0bd6059001a69f 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/lenv_length.ma".
+include "basic_2/syntax/lenv_length.ma".
 include "basic_2/relocation/drops.ma".
 
 (* GENERIC SLICING FOR LOCAL ENVIRONMENTS ***********************************)
@@ -37,7 +37,7 @@ theorem drops_fwd_length_eq1: ∀b1,b2,f,L1,K1. ⬇*[b1, f] L1 ≡ K1 →
 | #f #I1 #L1 #K1 #V1 #V2 #_ #_ #IH #X2 #Y2 #HX #H elim (length_inv_succ_sn … H) -H
   #I2 #L2 #V2 #H12 #H destruct elim (drops_inv_skip1 … HX) -HX
   #K2 #W2 #HLK2 #_ #H destruct
-  lapply (IH … HLK2 H12) -f /2 width=1 by/ (**) (* full auto fails *)
+  lapply (IH … HLK2 H12) -f >length_pair >length_pair /2 width=1 by/ (**) (* full auto fails *)
 ]
 qed-.  
 
@@ -47,8 +47,8 @@ lemma drops_fwd_fcla: ∀f,L1,L2. ⬇*[Ⓣ, f] L1 ≡ L2 →
                       ∃∃n. 𝐂⦃f⦄ ≡ n & |L1| = |L2| + n.
 #f #L1 #L2 #H elim H -f -L1 -L2
 [ /4 width=3 by fcla_isid, ex2_intro/
-| #f #I #L1 #L2 #V #_ * /3 width=3 by fcla_next, ex2_intro, eq_f/
-| #f #I #L1 #L2 #V1 #V2 #_ #_ * /3 width=3 by fcla_push, ex2_intro/
+| #f #I #L1 #L2 #V #_ * >length_pair /3 width=3 by fcla_next, ex2_intro, eq_f/
+| #f #I #L1 #L2 #V1 #V2 #_ #_ * >length_pair >length_pair /3 width=3 by fcla_push, ex2_intro/
 ]
 qed-.
 
@@ -56,7 +56,7 @@ qed-.
 lemma drops_fcla_fwd: ∀f,L1,L2,n. ⬇*[Ⓣ, f] L1 ≡ L2 → 𝐂⦃f⦄ ≡ n →
                       |L1| = |L2| + n.
 #f #l1 #l2 #n #Hf #Hn elim (drops_fwd_fcla … Hf) -Hf
-#m #Hm #H <(fcla_mono … Hm … Hn) -f //
+#k #Hm #H <(fcla_mono … Hm … Hn) -f //
 qed-.
 
 lemma drops_fwd_fcla_le2: ∀f,L1,L2. ⬇*[Ⓣ, f] L1 ≡ L2 →
@@ -68,7 +68,7 @@ qed-.
 lemma drops_fcla_fwd_le2: ∀f,L1,L2,n. ⬇*[Ⓣ, f] L1 ≡ L2 → 𝐂⦃f⦄ ≡ n →
                           n ≤ |L1|.
 #f #L1 #L2 #n #H #Hn elim (drops_fwd_fcla_le2 … H) -H
-#m #Hm #H <(fcla_mono … Hm … Hn) -f //
+#k #Hm #H <(fcla_mono … Hm … Hn) -f //
 qed-.
 
 lemma drops_fwd_fcla_lt2: ∀f,L1,I2,K2,V2. ⬇*[Ⓣ, f] L1 ≡ K2.ⓑ{I2}V2 →
@@ -82,7 +82,7 @@ lemma drops_fcla_fwd_lt2: ∀f,L1,I2,K2,V2,n.
                           ⬇*[Ⓣ, f] L1 ≡ K2.ⓑ{I2}V2 → 𝐂⦃f⦄ ≡ n →
                           n < |L1|.
 #f #L1 #I2 #K2 #V2 #n #H #Hn elim (drops_fwd_fcla_lt2 … H) -H
-#m #Hm #H <(fcla_mono … Hm … Hn) -f //
+#k #Hm #H <(fcla_mono … Hm … Hn) -f //
 qed-.
 
 (* Basic_2A1: includes: drop_fwd_length_lt4 *)
index c6899fd3effa741504a8ab75355b618792b35f52..c9934f66450fd0686db6bdc11e79e66d2f7d3492 100644 (file)
@@ -21,8 +21,7 @@ include "basic_2/relocation/drops_lexs.ma".
 
 lemma lreq_co_dedropable: co_dedropable_sn lreq.
 @lexs_liftable_co_dedropable
-/2 width=6 by cfull_lift, ceq_lift, cfull_refl, ceq_refl/
-qed-.
+/2 width=6 by cfull_lift, ceq_lift/ qed-.
 
 lemma lreq_co_dropable_sn: co_dropable_sn lreq.
 @lexs_co_dropable_sn qed-.
@@ -56,5 +55,4 @@ lemma drops_lreq_trans_next: ∀f1,K1,K2. K1 ≡[f1] K2 →
                              ∃∃L2. ⬇*[b,f] L2.ⓑ{I}V ≡ K2 & L1 ≡[f2] L2 & L1.ⓑ{I}V ≡[f] L2.ⓑ{I}V.
 #f1 #K1 #K2 #HK12 #b #f #I #L1 #V #HLK1 #f2 #Hf2
 elim (drops_lexs_trans_next … HK12 … HLK1 … Hf2) -f1 -K1
-/2 width=6 by cfull_lift, ceq_lift, cfull_refl, ceq_refl, ex3_intro/
-qed-.
+/2 width=6 by cfull_lift, ceq_lift, ex3_intro/ qed-.
index 7cbe05e1e0905029e65eaa26473fc2fa2377f7fb..1840b91224496ff5100cde2cc082660dcdf7d052 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/cl_restricted_weight.ma".
+include "basic_2/syntax/cl_restricted_weight.ma".
 include "basic_2/relocation/lifts_weight.ma".
 include "basic_2/relocation/drops.ma".
 
index 9587c2659096f70d55dffa66440463219951e36a..e99ea0393c3c992e54cf8c82c91ddeec2c4869ab 100644 (file)
@@ -14,7 +14,7 @@
 
 include "ground_2/relocation/rtmap_sle.ma".
 include "basic_2/notation/relations/relationstar_5.ma".
-include "basic_2/grammar/lenv.ma".
+include "basic_2/syntax/lenv.ma".
 
 (* GENERIC ENTRYWISE EXTENSION OF CONTEXT-SENSITIVE REALTIONS FOR TERMS *****)
 
index e407927a25ce70f8b7d2b3bc11a65d40aff2c3a7..972c773ed34b92954ccb6e89eb76bf52baa5d00d 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/lenv_length.ma".
+include "basic_2/syntax/lenv_length.ma".
 include "basic_2/relocation/lexs.ma".
 
 (* GENERIC ENTRYWISE EXTENSION OF CONTEXT-SENSITIVE REALTIONS FOR TERMS *****)
@@ -22,4 +22,5 @@ include "basic_2/relocation/lexs.ma".
 (* Basic_2A1: includes: lpx_sn_fwd_length *)
 lemma lexs_fwd_length: ∀RN,RP,f,L1,L2. L1 ⦻*[RN, RP, f] L2 → |L1| = |L2|.
 #RM #RP #f #L1 #L2 #H elim H -f -L1 -L2 //
+#f #I #L1 #L2 #V1 #V2 >length_pair >length_pair //
 qed-.
index d7176d732ac91d30bcfd8d3e1a9a6f654fb02679..73f3be9e7f48bb30597a0689c733e6f73e395eac 100644 (file)
@@ -15,7 +15,7 @@
 
 include "ground_2/relocation/nstream_after.ma".
 include "basic_2/notation/relations/rliftstar_3.ma".
-include "basic_2/grammar/term.ma".
+include "basic_2/syntax/term.ma".
 
 (* GENERIC RELOCATION FOR TERMS *********************************************)
 
index a8a9cc13350254ac6adfdf66038de4ecf789a42b..9afa0c02fd605f06fcb5df89bfe5228055990a71 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_simple.ma".
+include "basic_2/syntax/term_simple.ma".
 include "basic_2/relocation/lifts.ma".
 
 (* GENERIC RELOCATION FOR TERMS *********************************************)
index 1662b56d2b15fe938935f2b6d29caaf32bae79e9..26d395f19fc833ba9dadb90596e8b798816106de 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_vector.ma".
+include "basic_2/syntax/term_vector.ma".
 include "basic_2/relocation/lifts.ma".
 
 (* GENERIC RELOCATION FOR TERM VECTORS *************************************)
index a2e774964f01c25652937343870b86f41f1ba239..c6ad5b974b2e94113fdb4c1b15128aa858f5bc4a 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_weight.ma".
+include "basic_2/syntax/term_weight.ma".
 include "basic_2/relocation/lifts.ma".
 
 (* GENERIC RELOCATION FOR TERMS *********************************************)
index b5ee58d79f3c5e698a0b6afc7b126cd35046676e..aa2956699a2f5843037548398ebfe9ca17c1b149 100644 (file)
@@ -13,7 +13,6 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/lazyeq_3.ma".
-include "basic_2/grammar/ceq.ma".
 include "basic_2/relocation/lexs.ma".
 
 (* RANGED EQUIVALENCE FOR LOCAL ENVIRONMENTS ********************************)
index 6434ff37fd9e36a344c4ebd527bd74cd6b244821..c9d5f5ae92ff9b906524387f60fbbbec945f50ad 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/tsts.ma".
+include "basic_2/syntax/tsts.ma".
 include "basic_2/computation/lpxs_cpxs.ma".
 
 (* CONTEXT-SENSITIVE EXTENDED PARALLEL COMPUTATION ON TERMS *****************)
index 738d5907a2eb6e68d2472916e30caa5f2462b8f0..6252ed90eae75ba248f860f05d52a673e2745c49 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/tsts_vector.ma".
+include "basic_2/syntax/tsts_vector.ma".
 include "basic_2/substitution/lift_vector.ma".
 include "basic_2/computation/cpxs_tsts.ma".
 
index dd01e6a24b5d33cf2d63ca6eba0ae252cdb5bff7..1c239f8f82adc5077c67fcb7b6ef91f875a945ef 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/tsts_tsts.ma".
+include "basic_2/syntax/tsts_tsts.ma".
 include "basic_2/computation/cpxs_cpxs.ma".
 include "basic_2/computation/csx_alt.ma".
 include "basic_2/computation/csx_lift.ma".
index 95269945f490d24cf17d67131b86ea10d2726e8d..7d23b2f92f414d2e4bcbda29f78d21c288405c7a 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_vector.ma".
+include "basic_2/syntax/term_vector.ma".
 include "basic_2/computation/csx.ma".
 
 (* CONTEXT-SENSITIVE EXTENDED STRONGLY NORMALIZING TERM VECTORS *************)
index 61e9182cddc67468886273cadf30862dbaee3fa5..12c66156498a80b5e948ad23a58bc143f39b81c7 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/genv.ma".
+include "basic_2/syntax/genv.ma".
 include "basic_2/multiple/drops.ma".
 
 (* GENERIC COMPUTATION PROPERTIES *******************************************)
index 13b57701c069d591d1d54fc1e015b4f2e9ef3d17..3d11439002f366df33b36239ea3772968cecb39a 100644 (file)
@@ -13,7 +13,7 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/ineint_5.ma".
-include "basic_2/grammar/aarity.ma".
+include "basic_2/syntax/aarity.ma".
 include "basic_2/multiple/mr2_mr2.ma".
 include "basic_2/multiple/lifts_lift_vector.ma".
 include "basic_2/multiple/drops_drop.ma".
index 73be2e83d9d4a073d125a35db0940884240868b4..b682e561dff764cb8fc8feeabe755c352cab2425 100644 (file)
 include "ground_2/steps/rtc_max.ma".
 include "ground_2/steps/rtc_plus.ma".
 include "basic_2/notation/relations/predty_7.ma".
-include "basic_2/grammar/lenv.ma".
-include "basic_2/grammar/genv.ma".
+include "basic_2/syntax/item_sh.ma".
+include "basic_2/syntax/lenv.ma".
+include "basic_2/syntax/genv.ma".
 include "basic_2/relocation/lifts.ma".
-include "basic_2/static/sh.ma".
 
 (* COUNTED CONTEXT-SENSITIVE PARALLEL RT-TRANSITION FOR TERMS ***************)
 
index 0afd4cabb92814026224b81f400ee0d750249ca0..506386e4272ed940c0e5f457657fb90306752491 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/term_simple.ma".
+include "basic_2/syntax/term_simple.ma".
 include "basic_2/rt_transition/cpg.ma".
 
 (* COUNTED CONTEXT-SENSITIVE PARALLEL RT-TRANSITION FOR TERMS ***************)
index 2ff07da04ca26bf94df279fea83aaf9efec723c9..c207e05c10d2eb047276fb7faa1ea29e311fe06b 100644 (file)
@@ -124,8 +124,8 @@ lemma cpm_inv_atom1: ∀n,h,J,G,L,T2. ⦃G, L⦄ ⊢ ⓪{J} ➡[n, h] T2 →
                       | ∃∃s. T2 = ⋆(next h s) & J = Sort s & n = 1
                       | ∃∃K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[n, h] V2 & ⬆*[1] V2 ≡ T2 &
                                    L = K.ⓓV1 & J = LRef 0
-                      | ∃∃m,K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[m, h] V2 & ⬆*[1] V2 ≡ T2 &
-                                     L = K.ⓛV1 & J = LRef 0 & n = ⫯m
+                      | ∃∃k,K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[k, h] V2 & ⬆*[1] V2 ≡ T2 &
+                                     L = K.ⓛV1 & J = LRef 0 & n = ⫯k
                       | ∃∃I,K,V,T,i. ⦃G, K⦄ ⊢ #i ➡[n, h] T & ⬆*[1] T ≡ T2 &
                                      L = K.ⓑ{I}V & J = LRef (⫯i).
 #n #h #J #G #L #T2 * #c #Hc #H elim (cpg_inv_atom1 … H) -H *
@@ -134,7 +134,7 @@ lemma cpm_inv_atom1: ∀n,h,J,G,L,T2. ⦃G, L⦄ ⊢ ⓪{J} ➡[n, h] T2 →
 | #cV #K #V1 #V2 #HV12 #HVT2 #H1 #H2 #H3 destruct
   /4 width=6 by or5_intro2, ex4_3_intro, ex2_intro/
 | #cV #K #V1 #V2 #HV12 #HVT2 #H1 #H2 #H3 destruct
-  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #m #Hc #H destruct
+  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #k #Hc #H destruct
   /4 width=9 by or5_intro3, ex5_4_intro, ex2_intro/
 | #I #K #V1 #V2 #i #HV2 #HVT2 #H1 #H2 destruct
   /4 width=9 by or5_intro4, ex4_5_intro, ex2_intro/
@@ -153,14 +153,14 @@ lemma cpm_inv_zero1: ∀n,h,G,L,T2. ⦃G, L⦄ ⊢ #0 ➡[n, h] T2 →
                      ∨∨ (T2 = #0 ∧ n = 0)
                       | ∃∃K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[n, h] V2 & ⬆*[1] V2 ≡ T2 &
                                    L = K.ⓓV1
-                      | ∃∃m,K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[m, h] V2 & ⬆*[1] V2 ≡ T2 &
-                                     L = K.ⓛV1 & n = ⫯m.
+                      | ∃∃k,K,V1,V2. ⦃G, K⦄ ⊢ V1 ➡[k, h] V2 & ⬆*[1] V2 ≡ T2 &
+                                     L = K.ⓛV1 & n = ⫯k.
 #n #h #G #L #T2 * #c #Hc #H elim (cpg_inv_zero1 … H) -H *
 [ #H1 #H2 destruct /4 width=1 by isrt_inv_00, or3_intro0, conj/
 | #cV #K #V1 #V2 #HV12 #HVT2 #H1 #H2 destruct
   /4 width=8 by or3_intro1, ex3_3_intro, ex2_intro/
 | #cV #K #V1 #V2 #HV12 #HVT2 #H1 #H2 destruct
-  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #m #Hc #H destruct
+  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #k #Hc #H destruct
   /4 width=8 by or3_intro2, ex4_4_intro, ex2_intro/
 ]
 qed-.
@@ -263,7 +263,7 @@ lemma cpm_inv_cast1: ∀n,h,G,L,V1,U1,U2. ⦃G, L⦄ ⊢ ⓝV1.U1 ➡[n, h] U2 
                      ∨∨ ∃∃V2,T2. ⦃G, L⦄ ⊢ V1 ➡[n, h] V2 & ⦃G, L⦄ ⊢ U1 ➡[n, h] T2 &
                                  U2 = ⓝV2.T2
                       | ⦃G, L⦄ ⊢ U1 ➡[n, h] U2
-                      | ∃∃m. ⦃G, L⦄ ⊢ V1 ➡[m, h] U2 & n = ⫯m.
+                      | ∃∃k. ⦃G, L⦄ ⊢ V1 ➡[k, h] U2 & n = ⫯k.
 #n #h #G #L #V1 #U1 #U2 * #c #Hc #H elim (cpg_inv_cast1 … H) -H *
 [ #cV #cT #V2 #T2 #HV12 #HT12 #HcVT #H1 #H2 destruct
   elim (isrt_inv_max … Hc) -Hc #nV #nT #HcV #HcT #H destruct
@@ -273,7 +273,7 @@ lemma cpm_inv_cast1: ∀n,h,G,L,V1,U1,U2. ⦃G, L⦄ ⊢ ⓝV1.U1 ➡[n, h] U2 
 | #cU #U12 #H destruct
   /4 width=3 by isrt_inv_plus_O_dx, or3_intro1, ex2_intro/
 | #cU #H12 #H destruct
-  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #m #Hc #H destruct
+  elim (isrt_inv_plus_SO_dx … Hc) -Hc // #k #Hc #H destruct
   /4 width=3 by or3_intro2, ex2_intro/
 ]
 qed-.
index 786d2f9ce164817a442252ff32db91230d63e882..fbcd7958d4776e6ec180603c5e5601a0981d7e9b 100644 (file)
@@ -42,8 +42,8 @@ lemma cpm_inv_atom1_drops: ∀n,h,I,G,L,T2. ⦃G, L⦄ ⊢ ⓪{I} ➡[n, h] T2 
                             | ∃∃s. T2 = ⋆(next h s) & I = Sort s & n = 1
                             | ∃∃K,V,V2,i. ⬇*[i] L ≡ K.ⓓV & ⦃G, K⦄ ⊢ V ➡[n, h] V2 &
                                           ⬆*[⫯i] V2 ≡ T2 & I = LRef i
-                            | ∃∃m,K,V,V2,i. ⬇*[i] L ≡ K.ⓛV & ⦃G, K⦄ ⊢ V ➡[m, h] V2 &
-                                            ⬆*[⫯i] V2 ≡ T2 & I = LRef i & n = ⫯m.
+                            | ∃∃k,K,V,V2,i. ⬇*[i] L ≡ K.ⓛV & ⦃G, K⦄ ⊢ V ➡[k, h] V2 &
+                                            ⬆*[⫯i] V2 ≡ T2 & I = LRef i & n = ⫯k.
 #n #h #I #G #L #T2 * #c #Hc #H elim (cpg_inv_atom1_drops … H) -H *
 [ #H1 #H2 destruct lapply (isrt_inv_00 … Hc) -Hc
   /3 width=1 by or4_intro0, conj/
@@ -61,8 +61,8 @@ lemma cpm_inv_lref1_drops: ∀n,h,G,L,T2,i. ⦃G, L⦄ ⊢ #i ➡[n, h] T2 →
                            ∨∨ T2 = #i ∧ n = 0
                             | ∃∃K,V,V2. ⬇*[i] L ≡ K. ⓓV & ⦃G, K⦄ ⊢ V ➡[n, h] V2 &
                                         ⬆*[⫯i] V2 ≡ T2
-                            | ∃∃m,K,V,V2. ⬇*[i] L ≡ K. ⓛV & ⦃G, K⦄ ⊢ V ➡[m, h] V2 &
-                                          ⬆*[⫯i] V2 ≡ T2 & n = ⫯m.
+                            | ∃∃k,K,V,V2. ⬇*[i] L ≡ K. ⓛV & ⦃G, K⦄ ⊢ V ➡[k, h] V2 &
+                                          ⬆*[⫯i] V2 ≡ T2 & n = ⫯k.
 #n #h #G #L #T2 #i * #c #Hc #H elim (cpg_inv_lref1_drops … H) -H *
 [ #H1 #H2 destruct lapply (isrt_inv_00 … Hc) -Hc
   /3 width=1 by or3_intro0, conj/
index 48d281e4f27144c0a292c36af19b191ecbfa3570..c7c28703669fb4fde68ed1cc7cdde314bcef77ab 100644 (file)
@@ -27,7 +27,7 @@ lemma cpr_inv_atom1_drops: ∀h,I,G,L,T2. ⦃G, L⦄ ⊢ ⓪{I} ➡[h] T2 →
 [ /2 width=1 by or_introl/
 | #s #_ #_ #H destruct
 | /3 width=8 by ex4_4_intro, or_intror/
-| #m #K #V1 #V2 #i #_ #_ #_ #_ #H destruct
+| #k #K #V1 #V2 #i #_ #_ #_ #_ #H destruct
 ]
 qed-.
 
@@ -40,6 +40,6 @@ lemma cpr_inv_lref1_drops: ∀h,G,L,T2,i. ⦃G, L⦄ ⊢ #i ➡[h] T2 →
 #h #G #L #T2 #i #H elim (cpm_inv_lref1_drops … H) -H *
 [ /2 width=1 by or_introl/
 | /3 width=6 by ex3_3_intro, or_intror/
-| #m #K #V1 #V2 #_ #_ #_ #H destruct
+| #k #K #V1 #V2 #_ #_ #_ #H destruct
 ]
 qed-.
index 043d01598be81263c10ff5b8ff8e8e99e3f193e0..f5ef91e0cf714e9e755b0afe05aa6a4fe5fc47b7 100644 (file)
@@ -13,8 +13,8 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/supterm_6.ma".
-include "basic_2/grammar/lenv.ma".
-include "basic_2/grammar/genv.ma".
+include "basic_2/syntax/lenv.ma".
+include "basic_2/syntax/genv.ma".
 include "basic_2/relocation/lifts.ma".
 
 (* SUPCLOSURE ***************************************************************)
index 9719388a5d527c2eb2a30ba9f8544fbce8058bc9..c64b9ed5e5d5033ffbd7256dbf3b0a4253ca9d14 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/lenv_length.ma".
+include "basic_2/syntax/lenv_length.ma".
 include "basic_2/s_transition/fqu.ma".
 
 (* SUPCLOSURE ***************************************************************)
index 8969786c941c446a7664d21d3b7e9d20b1df359a..93148750f5544f527d8ae52189a25eef0eb2bd0d 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/cl_weight.ma".
+include "basic_2/syntax/cl_weight.ma".
 include "basic_2/relocation/lifts_weight.ma".
 include "basic_2/s_transition/fqu.ma".
 
index a57a60b24a7a12b08e52e63088bdb8dc0fa8b9d2..94cfde2f55596b8fe5fe09f98ed528b4573532e1 100644 (file)
@@ -13,9 +13,9 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/atomicarity_4.ma".
-include "basic_2/grammar/aarity.ma".
-include "basic_2/grammar/lenv.ma".
-include "basic_2/grammar/genv.ma".
+include "basic_2/syntax/aarity.ma".
+include "basic_2/syntax/lenv.ma".
+include "basic_2/syntax/genv.ma".
 
 (* ATONIC ARITY ASSIGNMENT FOR TERMS ****************************************)
 
index 5911dddfec361647781617494411dd91c5092e6f..de1568f2d84676f1b95658313e0eb2a4788ac2f7 100644 (file)
@@ -14,7 +14,7 @@
 
 include "ground_2/relocation/rtmap_sor.ma".
 include "basic_2/notation/relations/freestar_3.ma".
-include "basic_2/grammar/lenv.ma".
+include "basic_2/syntax/lenv.ma".
 
 (* CONTEXT-SENSITIVE FREE VARIABLES *****************************************)
 
index 2064f1217b2379ca75319ac8e88af4bfa70f8516..92888ef469eac6ddc990da415c4aa0d02071d441 100644 (file)
@@ -14,7 +14,6 @@
 
 include "ground_2/relocation/rtmap_id.ma".
 include "basic_2/notation/relations/relationstar_4.ma".
-include "basic_2/grammar/ceq.ma".
 include "basic_2/relocation/lexs.ma".
 include "basic_2/static/frees.ma".
 
index fe7ce260856c39122a88958771e137e5de3acb28..352626ccd8f4d7051afad29b3a8117b6a357e7ad 100644 (file)
@@ -13,7 +13,7 @@
 (**************************************************************************)
 
 include "basic_2/notation/relations/lrsubeqc_2.ma".
-include "basic_2/grammar/lenv.ma".
+include "basic_2/syntax/lenv.ma".
 
 (* RESTRICTED REFINEMENT FOR LOCAL ENVIRONMENTS *****************************)
 
index e240002bf39a6fcaa70321e550b4bb690c52d922..9c6beef120bd08f226502783f89e77affc48c81c 100644 (file)
@@ -12,7 +12,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/lenv_length.ma".
+include "basic_2/syntax/lenv_length.ma".
 include "basic_2/static/lsubr.ma".
 
 (* RESTRICTED REFINEMENT FOR LOCAL ENVIRONMENTS *****************************)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/static/sd.ma b/matita/matita/contribs/lambdadelta/basic_2/static/sd.ma
deleted file mode 100644 (file)
index bf75345..0000000
+++ /dev/null
@@ -1,124 +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/static/sh.ma".
-
-(* SORT DEGREE **************************************************************)
-
-(* sort degree specification *)
-record sd (h:sh): Type[0] ≝ {
-   deg      : relation nat;                            (* degree of the sort *)
-   deg_total: ∀s. ∃d. deg s d;                         (* functional relation axioms *)
-   deg_mono : ∀s,d1,d2. deg s d1 → deg s d2 → d1 = d2;
-   deg_next : ∀s,d. deg s d → deg (next h s) (⫰d)      (* compatibility condition *)
-}.
-
-(* Notable specifications ***************************************************)
-
-definition deg_O: relation nat ≝ λs,d. d = 0.
-
-definition sd_O: ∀h. sd h ≝ λh. mk_sd h deg_O ….
-/2 width=2 by le_n_O_to_eq, le_n, ex_intro/ defined.
-
-(* Basic_2A1: includes: deg_SO_pos *)
-inductive deg_SO (h:sh) (s:nat) (s0:nat): predicate nat ≝
-| deg_SO_succ : ∀n. (next h)^n s0 = s → deg_SO h s s0 (⫯n)
-| deg_SO_zero: ((∃n. (next h)^n s0 = s) → ⊥) → deg_SO h s s0 0
-.
-
-fact deg_SO_inv_succ_aux: ∀h,s,s0,n0. deg_SO h s s0 n0 → ∀n. n0 = ⫯n →
-                          (next h)^n s0 = s.
-#h #s #s0 #n0 * -n0
-[ #n #Hn #x #H destruct //
-| #_ #x #H destruct
-]
-qed-.
-
-(* Basic_2A1: was: deg_SO_inv_pos *)
-lemma deg_SO_inv_succ: ∀h,s,s0,n. deg_SO h s s0 (⫯n) → (next h)^n s0 = s.
-/2 width=3 by deg_SO_inv_succ_aux/ qed-.
-
-lemma deg_SO_refl: ∀h,s. deg_SO h s s 1.
-#h #s @(deg_SO_succ … 0 ?) //
-qed.
-
-lemma deg_SO_gt: ∀h,s1,s2. s1 < s2 → deg_SO h s1 s2 0.
-#h #s1 #s2 #HK12 @deg_SO_zero * #n elim n -n normalize
-[ #H destruct
-  elim (lt_refl_false … HK12)
-| #n #_ #H
-  lapply (next_lt h ((next h)^n s2)) >H -H #H
-  lapply (transitive_lt … H HK12) -s1 #H1
-  lapply (nexts_le h s2 n) #H2
-  lapply (le_to_lt_to_lt … H2 H1) -h -n #H
-  elim (lt_refl_false … H)
-]
-qed.
-
-definition sd_SO: ∀h. nat → sd h ≝ λh,s. mk_sd h (deg_SO h s) ….
-[ #s0
-  lapply (nexts_dec h s0 s) *
-  [ * /3 width=2 by deg_SO_succ, ex_intro/ | /4 width=2 by deg_SO_zero, ex_intro/ ]
-| #K0 #d1 #d2 * [ #n1 ] #H1 * [1,3: #n2 ] #H2 //
-  [ < H2 in H1; -H2 #H
-    lapply (nexts_inj … H) -H #H destruct //
-  | elim H1 /2 width=2 by ex_intro/
-  | elim H2 /2 width=2 by ex_intro/
-  ]
-| #s0 #n *
-  [ #d #H destruct elim d -d normalize
-    /2 width=1 by deg_SO_gt, deg_SO_succ, next_lt/
-  | #H1 @deg_SO_zero * #d #H2 destruct
-    @H1 -H1 @(ex_intro … (⫯d)) /2 width=1 by sym_eq/ (**) (* explicit constructor *)
-  ]
-]
-defined.
-
-rec definition sd_d (h:sh) (s:nat) (d:nat) on d : sd h ≝
-   match d with
-   [ O   ⇒ sd_O h
-   | S d ⇒ match d with
-           [ O ⇒ sd_SO h s
-           | _ ⇒ sd_d h (next h s) d
-           ]
-   ].
-
-(* Basic inversion lemmas ***************************************************)
-
-lemma deg_inv_pred: ∀h,o,s,d. deg h o (next h s) (⫯d) → deg h o s (⫯⫯d).
-#h #o #s #d #H1
-elim (deg_total h o s) #n #H0
-lapply (deg_next … H0) #H2
-lapply (deg_mono … H1 H2) -H1 -H2 #H >H >S_pred /2 width=2 by ltn_to_ltO/
-qed-.
-
-lemma deg_inv_prec: ∀h,o,s,n,d. deg h o ((next h)^n s) (⫯d) → deg h o s (⫯(d+n)).
-#h #o #s #n elim n -n normalize /3 width=1 by deg_inv_pred/
-qed-.
-
-(* Basic properties *********************************************************)
-
-lemma deg_iter: ∀h,o,s,d,n. deg h o s d → deg h o ((next h)^n s) (d-n).
-#h #o #s #d #n elim n -n normalize /3 width=1 by deg_next/
-qed.
-
-lemma deg_next_SO: ∀h,o,s,d. deg h o s (⫯d) → deg h o (next h s) d.
-/2 width=1 by deg_next/ qed-.
-
-lemma sd_d_SS: ∀h,s,d. sd_d h s (⫯⫯d) = sd_d h (next h s) (⫯d).
-// qed.
-
-lemma sd_d_correct: ∀h,d,s. deg h (sd_d h s d) s d.
-#h #d elim d -d // #d elim d -d /3 width=1 by deg_inv_pred/
-qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/static/sh.ma b/matita/matita/contribs/lambdadelta/basic_2/static/sh.ma
deleted file mode 100644 (file)
index d51bd19..0000000
+++ /dev/null
@@ -1,44 +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/lib/arith.ma".
-
-(* SORT HIERARCHY ***********************************************************)
-
-(* sort hierarchy specification *)
-record sh: Type[0] ≝ {
-   next   : nat → nat;     (* next sort in the hierarchy *)
-   next_lt: ∀s. s < next s (* strict monotonicity condition *)
-}.
-
-definition sh_N: sh ≝ mk_sh S ….
-// defined.
-
-(* Basic properties *********************************************************)
-
-lemma nexts_le: ∀h,s,n. s ≤ (next h)^n s.
-#h #s #n elim n -n // normalize #n #IH
-lapply (next_lt h ((next h)^n s)) #H
-lapply (le_to_lt_to_lt … IH H) -IH -H /2 width=2 by lt_to_le/
-qed.
-
-lemma nexts_lt: ∀h,s,n. s < (next h)^(⫯n) s.
-#h #s #n normalize
-lapply (nexts_le h s n) #H
-@(le_to_lt_to_lt … H) //
-qed.
-
-axiom nexts_dec: ∀h,s1,s2. Decidable (∃n. (next h)^n s1 = s2).
-
-axiom nexts_inj: ∀h,s,n1,n2. (next h)^n1 s = (next h)^n2 s → n1 = n2.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/aarity.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/aarity.ma
new file mode 100644 (file)
index 0000000..7f44246
--- /dev/null
@@ -0,0 +1,73 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* THE FORMAL SYSTEM λδ: MATITA SOURCE FILES
+ * Initial invocation: - Patience on me to gain peace and perfection! -
+ *)
+
+include "ground_2/lib/star.ma".
+include "basic_2/notation/constructors/item0_0.ma".
+include "basic_2/notation/constructors/snitem2_2.ma".
+
+(* ATOMIC ARITY *************************************************************)
+
+inductive aarity: Type[0] ≝
+  | AAtom: aarity                   (* atomic aarity construction *)
+  | APair: aarity → aarity → aarity (* binary aarity construction *)
+.
+
+interpretation "atomic arity construction (atomic)"
+   'Item0 = AAtom.
+
+interpretation "atomic arity construction (binary)"
+   'SnItem2 A1 A2 = (APair A1 A2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact destruct_apair_apair_aux: ∀A1,A2,B1,B2. ②B1.A1 = ②B2.A2 → B1 = B2 ∧ A1 = A2.
+#A1 #A2 #B1 #B2 #H destruct /2 width=1 by conj/
+qed-.
+
+lemma discr_apair_xy_x: ∀A,B. ②B.A = B → ⊥.
+#A #B elim B -B
+[ #H destruct
+| #Y #X #IHY #_ #H elim (destruct_apair_apair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
+]
+qed-.
+
+lemma discr_tpair_xy_y: ∀B,A. ②B. A = A → ⊥.
+#B #A elim A -A
+[ #H destruct
+| #Y #X #_ #IHX #H elim (destruct_apair_apair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
+]
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma eq_aarity_dec: ∀A1,A2:aarity. Decidable (A1 = A2).
+#A1 elim A1 -A1
+[ #A2 elim A2 -A2 /2 width=1 by or_introl/
+  #B2 #A2 #_ #_ @or_intror #H destruct
+| #B1 #A1 #IHB1 #IHA1 #A2 elim A2 -A2
+  [ -IHB1 -IHA1 @or_intror #H destruct
+  | #B2 #A2 #_ #_ elim (IHB1 B2) -IHB1
+    [ #H destruct elim (IHA1 A2) -IHA1
+      [ #H destruct /2 width=1 by or_introl/
+      | #HA12 @or_intror #H destruct /2 width=1 by/
+      ]
+    | -IHA1 #HB12 @or_intror #H destruct /2 width=1 by/
+    ]
+  ]
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/append.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/append.ma
new file mode 100644 (file)
index 0000000..f78ecb5
--- /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 "ground_2/notation/functions/append_2.ma".
+include "basic_2/notation/functions/snbind2_3.ma".
+include "basic_2/notation/functions/snabbr_2.ma".
+include "basic_2/notation/functions/snabst_2.ma".
+include "basic_2/syntax/lenv.ma".
+
+(* APPEND FOR LOCAL ENVIRONMENTS ********************************************)
+
+rec definition append L K on K ≝ match K with
+[ LAtom       ⇒ L
+| LPair K I V ⇒ (append L K).ⓑ{I}V
+].
+
+interpretation "append (local environment)" 'Append L1 L2 = (append L1 L2).
+
+interpretation "local environment tail binding construction (binary)"
+   'SnBind2 I T L = (append (LPair LAtom I T) L).
+
+interpretation "tail abbreviation (local environment)"
+   'SnAbbr T L = (append (LPair LAtom Abbr T) L).
+
+interpretation "tail abstraction (local environment)"
+   'SnAbst L T = (append (LPair LAtom Abst T) L).
+
+definition d_appendable_sn: predicate (lenv→relation term) ≝ λR.
+                            ∀K,T1,T2. R K T1 T2 → ∀L. R (L@@K) T1 T2.
+
+(* Basic properties *********************************************************)
+
+lemma append_atom: ∀L. L @@ ⋆ = L.
+// qed.
+
+lemma append_pair: ∀I,L,K,V. L@@(K.ⓑ{I}V) = (L@@K).ⓑ{I}V.
+// qed.
+
+lemma append_atom_sn: ∀L. ⋆@@L = L.
+#L elim L -L //
+#L #I #V >append_pair //
+qed.
+
+lemma append_assoc: associative … append.
+#L1 #L2 #L3 elim L3 -L3 //
+qed.
+
+lemma append_shift: ∀L,K,I,V. L@@(ⓑ{I}V.K) = (L.ⓑ{I}V)@@K.
+#L #K #I #V <append_assoc //
+qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma append_inj_sn: ∀K,L1,L2. L1@@K = L2@@K → L1 = L2.
+#K elim K -K //
+#K #I #V #IH #L1 #L2 >append_pair #H
+elim (destruct_lpair_lpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/append_length.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/append_length.ma
new file mode 100644 (file)
index 0000000..cab2cb8
--- /dev/null
@@ -0,0 +1,116 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/lenv_length.ma".
+include "basic_2/syntax/append.ma".
+
+(* APPEND FOR LOCAL ENVIRONMENTS ********************************************)
+
+(* Properties with length for local environments ****************************)
+
+lemma append_length: ∀L1,L2. |L1 @@ L2| = |L1| + |L2|.
+#L1 #L2 elim L2 -L2 //
+#L2 #I #V2 >append_pair >length_pair >length_pair //
+qed.
+
+lemma ltail_length: ∀I,L,V. |ⓑ{I}V.L| = ⫯|L|.
+#I #L #V >append_length //
+qed.
+
+(* Basic_1: was just: chead_ctail *)
+lemma lpair_ltail: ∀L,I,V. ∃∃J,K,W. L.ⓑ{I}V = ⓑ{J}W.K & |L| = |K|.
+#L elim L -L /2 width=5 by ex2_3_intro/
+#L #Z #X #IHL #I #V elim (IHL Z X) -IHL
+#J #K #W #H #_ >H -H >ltail_length
+@(ex2_3_intro … J (K.ⓑ{I}V) W) /2 width=1 by length_pair/
+qed-.
+
+(* Advanced inversion lemmas on length for local environments ***************)
+
+(* Basic_2A1: was: length_inv_pos_dx_ltail *)
+lemma length_inv_succ_dx_ltail: ∀L,l. |L| = ⫯l →
+                                ∃∃I,K,V. |K| = l & L = ⓑ{I}V.K.
+#Y #l #H elim (length_inv_succ_dx … H) -H #I #L #V #Hl #HLK destruct
+elim (lpair_ltail L I V) /2 width=5 by ex2_3_intro/
+qed-.
+
+(* Basic_2A1: was: length_inv_pos_sn_ltail *)
+lemma length_inv_succ_sn_ltail: ∀L,l. ⫯l = |L| →
+                                ∃∃I,K,V. l = |K| & L = ⓑ{I}V.K.
+#Y #l #H elim (length_inv_succ_sn … H) -H #I #L #V #Hl #HLK destruct
+elim (lpair_ltail L I V) /2 width=5 by ex2_3_intro/
+qed-.
+
+(* Inversion lemmas with length for local environments **********************)
+
+(* Basic_2A1: was: append_inj_sn *)
+lemma append_inj_length_sn: ∀K1,K2,L1,L2. L1 @@ K1 = L2 @@ K2 → |K1| = |K2| →
+                            L1 = L2 ∧ K1 = K2.
+#K1 elim K1 -K1
+[ * /2 width=1 by conj/
+  #K2 #I2 #V2 #L1 #L2 #_ >length_atom >length_pair
+  #H destruct
+| #K1 #I1 #V1 #IH *
+  [ #L1 #L2 #_ >length_atom >length_pair
+    #H destruct
+  | #K2 #I2 #V2 #L1 #L2 #H1 >length_pair >length_pair #H2
+    elim (destruct_lpair_lpair_aux … H1) -H1 #H1 #H3 #H4 destruct (**) (* destruct lemma needed *)
+    elim (IH … H1) -IH -H1 /3 width=4 by conj/
+  ]
+]
+qed-.
+
+(* Note: lemma 750 *)
+(* Basic_2A1: was: append_inj_dx *)
+lemma append_inj_length_dx: ∀K1,K2,L1,L2. L1 @@ K1 = L2 @@ K2 → |L1| = |L2| →
+                            L1 = L2 ∧ K1 = K2.
+#K1 elim K1 -K1
+[ * /2 width=1 by conj/
+  #K2 #I2 #V2 #L1 #L2 >append_atom >append_pair #H destruct
+  >length_pair >append_length >plus_n_Sm
+  #H elim (plus_xSy_x_false … H)
+| #K1 #I1 #V1 #IH *
+  [ #L1 #L2 >append_pair >append_atom #H destruct
+    >length_pair >append_length >plus_n_Sm #H
+    lapply (discr_plus_x_xy … H) -H #H destruct
+  | #K2 #I2 #V2 #L1 #L2 >append_pair >append_pair #H1 #H2
+    elim (destruct_lpair_lpair_aux … H1) -H1 #H1 #H3 #H4 destruct (**) (* destruct lemma needed *)
+    elim (IH … H1) -IH -H1 /2 width=1 by conj/
+  ]
+]
+qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma append_inj_dx: ∀L,K1,K2. L@@K1 = L@@K2 → K1 = K2.
+#L #K1 #K2 #H elim (append_inj_length_dx … H) -H //
+qed-.
+
+lemma append_inv_refl_dx: ∀L,K. L@@K = L → K = ⋆.
+#L #K #H elim (append_inj_dx … (⋆) … H) //
+qed-.
+
+lemma append_inv_pair_dx: ∀I,L,K,V. L@@K = L.ⓑ{I}V → K = ⋆.ⓑ{I}V.
+#I #L #K #V #H elim (append_inj_dx … (⋆.ⓑ{I}V) … H) //
+qed-.
+
+(* Basic eliminators ********************************************************)
+
+(* Basic_1: was: c_tail_ind *)
+lemma lenv_ind_alt: ∀R:predicate lenv.
+                    R (⋆) → (∀I,L,T. R L → R (ⓑ{I}T.L)) →
+                    ∀L. R L.
+#R #IH1 #IH2 #L @(f_ind … length … L) -L #x #IHx * // -IH1
+#L #I #V #H destruct elim (lpair_ltail L I V) /4 width=1 by/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/cl_restricted_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/cl_restricted_weight.ma
new file mode 100644 (file)
index 0000000..32fd773
--- /dev/null
@@ -0,0 +1,51 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/functions/weight_2.ma".
+include "basic_2/syntax/lenv_weight.ma".
+
+(* WEIGHT OF A RESTRICTED CLOSURE *******************************************)
+
+definition rfw: lenv → term → ? ≝ λL,T. ♯{L} + ♯{T}.
+
+interpretation "weight (restricted closure)" 'Weight L T = (rfw L T).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: flt_shift *)
+lemma rfw_shift: ∀p,I,K,V,T. ♯{K.ⓑ{I}V, T} < ♯{K, ⓑ{p,I}V.T}.
+normalize /2 width=1 by monotonic_le_plus_r/
+qed.
+
+lemma rfw_tpair_sn: ∀I,L,V,T. ♯{L, V} < ♯{L, ②{I}V.T}.
+normalize in ⊢ (?→?→?→?→?%%); //
+qed.
+
+lemma rfw_tpair_dx: ∀I,L,V,T. ♯{L, T} < ♯{L, ②{I}V.T}.
+normalize in ⊢ (?→?→?→?→?%%); //
+qed.
+
+lemma rfw_lpair_sn: ∀I,L,V,T. ♯{L, V} < ♯{L.ⓑ{I}V, T}.
+normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
+qed.
+
+lemma rfw_lpair_dx: ∀I,L,V,T. ♯{L, T} < ♯{L.ⓑ{I}V, T}.
+normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
+qed.
+
+(* Basic_1: removed theorems 7:
+            flt_thead_sx flt_thead_dx flt_trans
+            flt_arith0 flt_arith1 flt_arith2 flt_wf_ind
+*)
+(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/cl_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/cl_weight.ma
new file mode 100644 (file)
index 0000000..b933688
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/functions/weight_3.ma".
+include "basic_2/syntax/lenv_weight.ma".
+include "basic_2/syntax/genv.ma".
+
+(* WEIGHT OF A CLOSURE ******************************************************)
+
+(* activate genv *)
+definition fw: genv → lenv → term → ? ≝ λG,L,T. ♯{L} + ♯{T}.
+
+interpretation "weight (closure)" 'Weight G L T = (fw G L T).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: flt_shift *)
+lemma fw_shift: ∀p,I,G,K,V,T. ♯{G, K.ⓑ{I}V, T} < ♯{G, K, ⓑ{p,I}V.T}.
+normalize /2 width=1 by monotonic_le_plus_r/
+qed.
+
+lemma fw_tpair_sn: ∀I,G,L,V,T. ♯{G, L, V} < ♯{G, L, ②{I}V.T}.
+normalize in ⊢ (?→?→?→?→?→?%%); //
+qed.
+
+lemma fw_tpair_dx: ∀I,G,L,V,T. ♯{G, L, T} < ♯{G, L, ②{I}V.T}.
+normalize in ⊢ (?→?→?→?→?→?%%); //
+qed.
+
+lemma fw_lpair_sn: ∀I,G,L,V,T. ♯{G, L, V} < ♯{G, L.ⓑ{I}V, T}.
+normalize /3 width=1 by monotonic_lt_plus_l, monotonic_le_plus_r/
+qed.
+
+(* Basic_1: removed theorems 7:
+            flt_thead_sx flt_thead_dx flt_trans
+            flt_arith0 flt_arith1 flt_arith2 flt_wf_ind
+*)
+(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/deq.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/deq.ma
new file mode 100644 (file)
index 0000000..a14f7e3
--- /dev/null
@@ -0,0 +1,104 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/item_sd.ma".
+include "basic_2/syntax/lenv.ma".
+
+(* DEGREE-BASED EQUIVALENCE ON TERMS ****************************************)
+
+inductive deq (h) (o): relation term ≝
+| deq_sort: ∀s1,s2,d. deg h o s1 d → deg h o s2 d → deq h o (⋆s1) (⋆s2)
+| deq_lref: ∀i. deq h o (#i) (#i)
+| deq_gref: ∀l. deq h o (§l) (§l)
+| deq_pair: ∀I,V1,V2,T1,T2. deq h o V1 V2 → deq h o T1 T2 → deq h o (②{I}V1.T1) (②{I}V2.T2)
+.
+
+interpretation
+   "degree-based equivalence (terms)"
+   'LazyEq h o T1 T2 = (deq h o T1 T2).
+
+definition cdeq: ∀h. sd h → relation3 lenv term term ≝
+                 λh,o,L. deq h o.
+
+(* Basic properties *********************************************************)
+
+lemma deq_refl: ∀h,o. reflexive … (deq h o).
+#h #o #T elim T -T /2 width=1 by deq_pair/
+* /2 width=1 by deq_lref, deq_gref/
+#s elim (deg_total h o s) /2 width=3 by deq_sort/
+qed.
+
+lemma deq_sym: ∀h,o. symmetric … (deq h o).
+#h #o #T1 #T2 #H elim H -T1 -T2
+/2 width=3 by deq_sort, deq_lref, deq_gref, deq_pair/
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact deq_inv_sort1_aux: ∀h,o,X,Y. X ≡[h, o] Y → ∀s1. X = ⋆s1 →
+                        ∃∃s2,d. deg h o s1 d & deg h o s2 d & Y = ⋆s2.
+#h #o #X #Y * -X -Y
+[ #s1 #s2 #d #Hs1 #Hs2 #s #H destruct /2 width=5 by ex3_2_intro/
+| #i #s #H destruct
+| #l #s #H destruct
+| #I #V1 #V2 #T1 #T2 #_ #_ #s #H destruct
+]
+qed-.
+
+lemma deq_inv_sort1: ∀h,o,Y,s1. ⋆s1 ≡[h, o] Y →
+                     ∃∃s2,d. deg h o s1 d & deg h o s2 d & Y = ⋆s2.
+/2 width=3 by deq_inv_sort1_aux/ qed-.
+
+fact deq_inv_lref1_aux: ∀h,o,X,Y. X ≡[h, o] Y → ∀i. X = #i → Y = #i.
+#h #o #X #Y * -X -Y //
+[ #s1 #s2 #d #_ #_ #j #H destruct
+| #I #V1 #V2 #T1 #T2 #_ #_ #j #H destruct
+]
+qed-.
+
+lemma deq_inv_lref1: ∀h,o,Y,i. #i ≡[h, o] Y → Y = #i.
+/2 width=5 by deq_inv_lref1_aux/ qed-.
+
+fact deq_inv_gref1_aux: ∀h,o,X,Y. X ≡[h, o] Y → ∀l. X = §l → Y = §l.
+#h #o #X #Y * -X -Y //
+[ #s1 #s2 #d #_ #_ #k #H destruct
+| #I #V1 #V2 #T1 #T2 #_ #_ #k #H destruct
+]
+qed-.
+
+lemma deq_inv_gref1: ∀h,o,Y,l. §l ≡[h, o] Y → Y = §l.
+/2 width=5 by deq_inv_gref1_aux/ qed-.
+
+fact deq_inv_pair1_aux: ∀h,o,X,Y. X ≡[h, o] Y → ∀I,V1,T1. X = ②{I}V1.T1 →
+                        ∃∃V2,T2. V1 ≡[h, o] V2 & T1 ≡[h, o] T2 & Y = ②{I}V2.T2.
+#h #o #X #Y * -X -Y
+[ #s1 #s2 #d #_ #_ #J #W1 #U1 #H destruct
+| #i #J #W1 #U1 #H destruct
+| #l #J #W1 #U1 #H destruct
+| #I #V1 #V2 #T1 #T2 #HV #HT #J #W1 #U1 #H destruct /2 width=5 by ex3_2_intro/
+]
+qed-.
+
+lemma deq_inv_pair1: ∀h,o,I,V1,T1,Y. ②{I}V1.T1 ≡[h, o] Y →
+                     ∃∃V2,T2. V1 ≡[h, o] V2 & T1 ≡[h, o] T2 & Y = ②{I}V2.T2.
+/2 width=3 by deq_inv_pair1_aux/ qed-.
+
+(* Advanced inversion lemmas ************************************************)
+
+lemma deq_inv_sort1_deg: ∀h,o,Y,s1. ⋆s1 ≡[h, o] Y → ∀d. deg h o s1 d →
+                         ∃∃s2. deg h o s2 d & Y = ⋆s2.
+#h #o #Y #s1 #H #d #Hs1 elim (deq_inv_sort1 … H) -H
+#s2 #x #Hx <(deg_mono h o … Hx … Hs1) -s1 -d /2 width=3 by ex2_intro/  
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/deq_deq.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/deq_deq.ma
new file mode 100644 (file)
index 0000000..b69e2dc
--- /dev/null
@@ -0,0 +1,30 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/deq.ma".
+
+(* DEGREE-BASED EQUIVALENCE ON TERMS ****************************************)
+
+(* Main properties **********************************************************)
+
+theorem deq_trans: ∀h,o. Transitive … (deq h o).
+#h #o #T1 #T #H elim H -T1 -T
+[ #s1 #s #d #Hs1 #Hs #X #H
+  elim (deq_inv_sort1_deg … H … Hs) -s /2 width=3 by deq_sort/
+| #i1 #i #H <(deq_inv_lref1 … H) -H //
+| #l1 #l #H <(deq_inv_gref1 … H) -H //
+| #I #V1 #V #T1 #T #_ #_ #IHV #IHT #X #H destruct
+  elim (deq_inv_pair1 … H) -H /3 width=1 by deq_pair/
+]
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/genv.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/genv.ma
new file mode 100644 (file)
index 0000000..8483917
--- /dev/null
@@ -0,0 +1,41 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lib/list2.ma".
+include "basic_2/notation/constructors/star_0.ma".
+include "basic_2/notation/constructors/dxbind2_3.ma".
+include "basic_2/notation/constructors/dxabbr_2.ma".
+include "basic_2/notation/constructors/dxabst_2.ma".
+include "basic_2/syntax/term.ma".
+
+(* GLOBAL ENVIRONMENTS ******************************************************)
+
+(* global environments *)
+definition genv ≝ list2 bind2 term.
+
+interpretation "sort (global environment)"
+   'Star = (nil2 bind2 term).
+
+interpretation "global environment binding construction (binary)"
+   'DxBind2 L I T = (cons2 bind2 term I T L).
+
+interpretation "abbreviation (global environment)"
+   'DxAbbr L T = (cons2 bind2 term Abbr T L).
+
+interpretation "abstraction (global environment)"
+   'DxAbst L T = (cons2 bind2 term Abst T L).
+
+(* Basic properties *********************************************************)
+
+axiom eq_genv_dec: ∀G1,G2:genv. Decidable (G1 = G2).
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/item.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/item.ma
new file mode 100644 (file)
index 0000000..ab861be
--- /dev/null
@@ -0,0 +1,88 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lib/bool.ma".
+include "ground_2/lib/arith.ma".
+
+(* ITEMS ********************************************************************)
+
+(* atomic items *)
+inductive item0: Type[0] ≝
+   | Sort: nat → item0 (* sort: starting at 0 *)
+   | LRef: nat → item0 (* reference by index: starting at 0 *)
+   | GRef: nat → item0 (* reference by position: starting at 0 *)
+.
+
+(* binary binding items *)
+inductive bind2: Type[0] ≝
+  | Abbr: bind2 (* abbreviation *)
+  | Abst: bind2 (* abstraction *)
+.
+
+(* binary non-binding items *)
+inductive flat2: Type[0] ≝
+  | Appl: flat2 (* application *)
+  | Cast: flat2 (* explicit type annotation *)
+.
+
+(* binary items *)
+inductive item2: Type[0] ≝
+  | Bind2: bool → bind2 → item2 (* polarized binding item *)
+  | Flat2: flat2 → item2        (* non-binding item *)
+.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact destruct_sort_sort_aux: ∀s1,s2. Sort s1 = Sort s2 → s1 = s2.
+#s1 #s2 #H destruct //
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma eq_item0_dec: ∀I1,I2:item0. Decidable (I1 = I2).
+* #i1 * #i2 [2,3,4,6,7,8: @or_intror #H destruct ]
+[2: elim (eq_nat_dec i1 i2) |1,3: elim (eq_nat_dec i1 i2) ] /2 width=1 by or_introl/
+#Hni12 @or_intror #H destruct /2 width=1 by/
+qed-.
+
+(* Basic_1: was: bind_dec *)
+lemma eq_bind2_dec: ∀I1,I2:bind2. Decidable (I1 = I2).
+* * /2 width=1 by or_introl/
+@or_intror #H destruct
+qed-.
+
+(* Basic_1: was: flat_dec *)
+lemma eq_flat2_dec: ∀I1,I2:flat2. Decidable (I1 = I2).
+* * /2 width=1 by or_introl/
+@or_intror #H destruct
+qed-.
+
+(* Basic_1: was: kind_dec *)
+lemma eq_item2_dec: ∀I1,I2:item2. Decidable (I1 = I2).
+* [ #p1 ] #I1 * [1,3: #p2 ] #I2
+[2,3: @or_intror #H destruct
+| elim (eq_bool_dec p1 p2) #Hp
+  [ elim (eq_bind2_dec I1 I2) /2 width=1 by or_introl/ #HI ]
+  @or_intror #H destruct /2 width=1 by/
+| elim (eq_flat2_dec I1 I2) /2 width=1 by or_introl/ #HI
+  @or_intror #H destruct /2 width=1 by/
+]
+qed-.
+
+(* Basic_1: removed theorems 21:
+            s_S s_plus s_plus_sym s_minus minus_s_s s_le s_lt s_inj s_inc
+            s_arith0 s_arith1
+            r_S r_plus r_plus_sym r_minus r_dis s_r r_arith0 r_arith1
+            not_abbr_abst bind_dec_not
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/item_sd.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/item_sd.ma
new file mode 100644 (file)
index 0000000..3387066
--- /dev/null
@@ -0,0 +1,124 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/item_sh.ma".
+
+(* SORT DEGREE **************************************************************)
+
+(* sort degree specification *)
+record sd (h:sh): Type[0] ≝ {
+   deg      : relation nat;                            (* degree of the sort *)
+   deg_total: ∀s. ∃d. deg s d;                         (* functional relation axioms *)
+   deg_mono : ∀s,d1,d2. deg s d1 → deg s d2 → d1 = d2;
+   deg_next : ∀s,d. deg s d → deg (next h s) (⫰d)      (* compatibility condition *)
+}.
+
+(* Notable specifications ***************************************************)
+
+definition deg_O: relation nat ≝ λs,d. d = 0.
+
+definition sd_O: ∀h. sd h ≝ λh. mk_sd h deg_O ….
+/2 width=2 by le_n_O_to_eq, le_n, ex_intro/ defined.
+
+(* Basic_2A1: includes: deg_SO_pos *)
+inductive deg_SO (h:sh) (s:nat) (s0:nat): predicate nat ≝
+| deg_SO_succ : ∀n. (next h)^n s0 = s → deg_SO h s s0 (⫯n)
+| deg_SO_zero: ((∃n. (next h)^n s0 = s) → ⊥) → deg_SO h s s0 0
+.
+
+fact deg_SO_inv_succ_aux: ∀h,s,s0,n0. deg_SO h s s0 n0 → ∀n. n0 = ⫯n →
+                          (next h)^n s0 = s.
+#h #s #s0 #n0 * -n0
+[ #n #Hn #x #H destruct //
+| #_ #x #H destruct
+]
+qed-.
+
+(* Basic_2A1: was: deg_SO_inv_pos *)
+lemma deg_SO_inv_succ: ∀h,s,s0,n. deg_SO h s s0 (⫯n) → (next h)^n s0 = s.
+/2 width=3 by deg_SO_inv_succ_aux/ qed-.
+
+lemma deg_SO_refl: ∀h,s. deg_SO h s s 1.
+#h #s @(deg_SO_succ … 0 ?) //
+qed.
+
+lemma deg_SO_gt: ∀h,s1,s2. s1 < s2 → deg_SO h s1 s2 0.
+#h #s1 #s2 #HK12 @deg_SO_zero * #n elim n -n normalize
+[ #H destruct
+  elim (lt_refl_false … HK12)
+| #n #_ #H
+  lapply (next_lt h ((next h)^n s2)) >H -H #H
+  lapply (transitive_lt … H HK12) -s1 #H1
+  lapply (nexts_le h s2 n) #H2
+  lapply (le_to_lt_to_lt … H2 H1) -h -n #H
+  elim (lt_refl_false … H)
+]
+qed.
+
+definition sd_SO: ∀h. nat → sd h ≝ λh,s. mk_sd h (deg_SO h s) ….
+[ #s0
+  lapply (nexts_dec h s0 s) *
+  [ * /3 width=2 by deg_SO_succ, ex_intro/ | /4 width=2 by deg_SO_zero, ex_intro/ ]
+| #K0 #d1 #d2 * [ #n1 ] #H1 * [1,3: #n2 ] #H2 //
+  [ < H2 in H1; -H2 #H
+    lapply (nexts_inj … H) -H #H destruct //
+  | elim H1 /2 width=2 by ex_intro/
+  | elim H2 /2 width=2 by ex_intro/
+  ]
+| #s0 #n *
+  [ #d #H destruct elim d -d normalize
+    /2 width=1 by deg_SO_gt, deg_SO_succ, next_lt/
+  | #H1 @deg_SO_zero * #d #H2 destruct
+    @H1 -H1 @(ex_intro … (⫯d)) /2 width=1 by sym_eq/ (**) (* explicit constructor *)
+  ]
+]
+defined.
+
+rec definition sd_d (h:sh) (s:nat) (d:nat) on d : sd h ≝
+   match d with
+   [ O   ⇒ sd_O h
+   | S d ⇒ match d with
+           [ O ⇒ sd_SO h s
+           | _ ⇒ sd_d h (next h s) d
+           ]
+   ].
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma deg_inv_pred: ∀h,o,s,d. deg h o (next h s) (⫯d) → deg h o s (⫯⫯d).
+#h #o #s #d #H1
+elim (deg_total h o s) #n #H0
+lapply (deg_next … H0) #H2
+lapply (deg_mono … H1 H2) -H1 -H2 #H >H >S_pred /2 width=2 by ltn_to_ltO/
+qed-.
+
+lemma deg_inv_prec: ∀h,o,s,n,d. deg h o ((next h)^n s) (⫯d) → deg h o s (⫯(d+n)).
+#h #o #s #n elim n -n normalize /3 width=1 by deg_inv_pred/
+qed-.
+
+(* Basic properties *********************************************************)
+
+lemma deg_iter: ∀h,o,s,d,n. deg h o s d → deg h o ((next h)^n s) (d-n).
+#h #o #s #d #n elim n -n normalize /3 width=1 by deg_next/
+qed.
+
+lemma deg_next_SO: ∀h,o,s,d. deg h o s (⫯d) → deg h o (next h s) d.
+/2 width=1 by deg_next/ qed-.
+
+lemma sd_d_SS: ∀h,s,d. sd_d h s (⫯⫯d) = sd_d h (next h s) (⫯d).
+// qed.
+
+lemma sd_d_correct: ∀h,d,s. deg h (sd_d h s d) s d.
+#h #d elim d -d // #d elim d -d /3 width=1 by deg_inv_pred/
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/item_sh.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/item_sh.ma
new file mode 100644 (file)
index 0000000..d51bd19
--- /dev/null
@@ -0,0 +1,44 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/lib/arith.ma".
+
+(* SORT HIERARCHY ***********************************************************)
+
+(* sort hierarchy specification *)
+record sh: Type[0] ≝ {
+   next   : nat → nat;     (* next sort in the hierarchy *)
+   next_lt: ∀s. s < next s (* strict monotonicity condition *)
+}.
+
+definition sh_N: sh ≝ mk_sh S ….
+// defined.
+
+(* Basic properties *********************************************************)
+
+lemma nexts_le: ∀h,s,n. s ≤ (next h)^n s.
+#h #s #n elim n -n // normalize #n #IH
+lapply (next_lt h ((next h)^n s)) #H
+lapply (le_to_lt_to_lt … IH H) -IH -H /2 width=2 by lt_to_le/
+qed.
+
+lemma nexts_lt: ∀h,s,n. s < (next h)^(⫯n) s.
+#h #s #n normalize
+lapply (nexts_le h s n) #H
+@(le_to_lt_to_lt … H) //
+qed.
+
+axiom nexts_dec: ∀h,s1,s2. Decidable (∃n. (next h)^n s1 = s2).
+
+axiom nexts_inj: ∀h,s,n1,n2. (next h)^n1 s = (next h)^n2 s → n1 = n2.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv.ma
new file mode 100644 (file)
index 0000000..cfefa7f
--- /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/notation/constructors/star_0.ma".
+include "basic_2/notation/constructors/dxbind2_3.ma".
+include "basic_2/notation/constructors/dxabbr_2.ma".
+include "basic_2/notation/constructors/dxabst_2.ma".
+include "basic_2/syntax/term.ma".
+
+(* LOCAL ENVIRONMENTS *******************************************************)
+
+(* local environments *)
+inductive lenv: Type[0] ≝
+| LAtom: lenv                       (* empty *)
+| LPair: lenv → bind2 → term → lenv (* binary binding construction *)
+.
+
+interpretation "sort (local environment)"
+   'Star = LAtom.
+
+interpretation "local environment binding construction (binary)"
+   'DxBind2 L I T = (LPair L I T).
+
+interpretation "abbreviation (local environment)"
+   'DxAbbr L T = (LPair L Abbr T).
+
+interpretation "abstraction (local environment)"
+   'DxAbst L T = (LPair L Abst T).
+
+definition ceq: relation3 lenv term term ≝ λL,T1,T2. T1 = T2.
+
+definition cfull: relation3 lenv term term ≝ λL,T1,T2. ⊤.
+
+(* Basic properties *********************************************************)
+
+lemma eq_lenv_dec: ∀L1,L2:lenv. Decidable (L1 = L2).
+#L1 elim L1 -L1 [| #L1 #I1 #V1 #IHL1 ] * [2,4: #L2 #I2 #V2 ]
+[1,4: @or_intror #H destruct
+| elim (eq_bind2_dec I1 I2) #HI
+  [ elim (eq_term_dec V1 V2) #HV
+    [ elim (IHL1 L2) -IHL1 /2 width=1 by or_introl/ #HL ]
+  ]
+  @or_intror #H destruct /2 width=1 by/
+| /2 width=1 by or_introl/
+]
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact destruct_lpair_lpair_aux: ∀I1,I2,L1,L2,V1,V2. L1.ⓑ{I1}V1 = L2.ⓑ{I2}V2 →
+                               ∧∧L1 = L2 & I1 = I2 & V1 = V2.
+#I1 #I2 #L1 #L2 #V1 #V2 #H destruct /2 width=1 by and3_intro/
+qed-.
+
+lemma discr_lpair_x_xy: ∀I,V,L. L = L.ⓑ{I}V → ⊥.
+#I #V #L elim L -L
+[ #H destruct
+| #L #J #W #IHL #H
+  elim (destruct_lpair_lpair_aux … H) -H #H1 #H2 #H3 destruct /2 width=1 by/ (**) (* destruct lemma needed *)
+]
+qed-.
+
+lemma discr_lpair_xy_x: ∀I,V,L. L.ⓑ{I}V = L→ ⊥.
+/2 width=4 by discr_lpair_x_xy/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_length.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_length.ma
new file mode 100644 (file)
index 0000000..41e09d5
--- /dev/null
@@ -0,0 +1,58 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/lenv.ma".
+
+(* LENGTH OF A LOCAL ENVIRONMENT ********************************************)
+
+rec definition length L ≝ match L with
+[ LAtom       ⇒ 0
+| LPair L _ _ ⇒ ⫯(length L)
+].
+
+interpretation "length (local environment)" 'card L = (length L).
+
+(* Basic properties *********************************************************)
+
+lemma length_atom: |⋆| = 0.
+// qed.
+
+lemma length_pair: ∀I,L,V. |L.ⓑ{I}V| = ⫯|L|.
+// qed.
+
+(* Basic inversion lemmas ***************************************************)
+
+lemma length_inv_zero_dx: ∀L. |L| = 0 → L = ⋆.
+* // #L #I #V >length_pair
+#H destruct
+qed-.
+
+lemma length_inv_zero_sn: ∀L. 0 = |L| → L = ⋆.
+/2 width=1 by length_inv_zero_dx/ qed-.
+
+(* Basic_2A1: was: length_inv_pos_dx *)
+lemma length_inv_succ_dx: ∀n,L. |L| = ⫯n →
+                          ∃∃I,K,V. |K| = n & L = K. ⓑ{I}V.
+#n * [ >length_atom #H destruct ]
+#L #I #V >length_pair /3 width=5 by ex2_3_intro, injective_S/
+qed-.
+
+(* Basic_2A1: was: length_inv_pos_sn *)
+lemma length_inv_succ_sn: ∀n,L. ⫯n = |L| →
+                          ∃∃I,K,V. n = |K| & L = K. ⓑ{I}V.
+#l #L #H lapply (sym_eq ??? H) -H 
+#H elim (length_inv_succ_dx … H) -H /2 width=5 by ex2_3_intro/
+qed-.
+
+(* Basic_2A1: removed theorems 1: length_inj *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/lenv_weight.ma
new file mode 100644 (file)
index 0000000..1a61b7d
--- /dev/null
@@ -0,0 +1,34 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/term_weight.ma".
+include "basic_2/syntax/lenv.ma".
+
+(* WEIGHT OF A LOCAL ENVIRONMENT ********************************************)
+
+rec definition lw L ≝ match L with
+[ LAtom       ⇒ 0
+| LPair L _ V ⇒ lw L + ♯{V}
+].
+
+interpretation "weight (local environment)" 'Weight L = (lw L).
+
+(* Basic properties *********************************************************)
+
+lemma lw_pair: ∀I,L,V. ♯{L} < ♯{L.ⓑ{I}V}.
+/3 width=1 by lt_plus_to_minus_r, monotonic_lt_plus_r/ qed.
+
+(* Basic_1: removed theorems 4: clt_cong clt_head clt_thead clt_wf_ind *)
+(* Basic_1: removed local theorems 1: clt_wf__q_ind *)
+(* Basic_1: note: clt_thead should be renamed clt_ctail *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/term.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/term.ma
new file mode 100644 (file)
index 0000000..ccbb494
--- /dev/null
@@ -0,0 +1,153 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/constructors/item0_1.ma".
+include "basic_2/notation/constructors/snitem2_3.ma".
+include "basic_2/notation/constructors/snbind2_4.ma".
+include "basic_2/notation/constructors/snbind2pos_3.ma".
+include "basic_2/notation/constructors/snbind2neg_3.ma".
+include "basic_2/notation/constructors/snflat2_3.ma".
+include "basic_2/notation/constructors/star_1.ma".
+include "basic_2/notation/constructors/lref_1.ma".
+include "basic_2/notation/constructors/gref_1.ma".
+include "basic_2/notation/constructors/snabbr_3.ma".
+include "basic_2/notation/constructors/snabbrpos_2.ma".
+include "basic_2/notation/constructors/snabbrneg_2.ma".
+include "basic_2/notation/constructors/snabst_3.ma".
+include "basic_2/notation/constructors/snabstpos_2.ma".
+include "basic_2/notation/constructors/snabstneg_2.ma".
+include "basic_2/notation/constructors/snappl_2.ma".
+include "basic_2/notation/constructors/sncast_2.ma".
+include "basic_2/syntax/item.ma".
+
+(* TERMS ********************************************************************)
+
+(* terms *)
+inductive term: Type[0] ≝
+  | TAtom: item0 → term               (* atomic item construction *)
+  | TPair: item2 → term → term → term (* binary item construction *)
+.
+
+interpretation "term construction (atomic)"
+   'Item0 I = (TAtom I).
+
+interpretation "term construction (binary)"
+   'SnItem2 I T1 T2 = (TPair I T1 T2).
+
+interpretation "term binding construction (binary)"
+   'SnBind2 p I T1 T2 = (TPair (Bind2 p I) T1 T2).
+
+interpretation "term positive binding construction (binary)"
+   'SnBind2Pos I T1 T2 = (TPair (Bind2 true I) T1 T2).
+
+interpretation "term negative binding construction (binary)"
+   'SnBind2Neg I T1 T2 = (TPair (Bind2 false I) T1 T2).
+
+interpretation "term flat construction (binary)"
+   'SnFlat2 I T1 T2 = (TPair (Flat2 I) T1 T2).
+
+interpretation "sort (term)"
+   'Star s = (TAtom (Sort s)).
+
+interpretation "local reference (term)"
+   'LRef i = (TAtom (LRef i)).
+
+interpretation "global reference (term)"
+   'GRef l = (TAtom (GRef l)).
+
+interpretation "abbreviation (term)"
+   'SnAbbr p T1 T2 = (TPair (Bind2 p Abbr) T1 T2).
+
+interpretation "positive abbreviation (term)"
+   'SnAbbrPos T1 T2 = (TPair (Bind2 true Abbr) T1 T2).
+
+interpretation "negative abbreviation (term)"
+   'SnAbbrNeg T1 T2 = (TPair (Bind2 false Abbr) T1 T2).
+
+interpretation "abstraction (term)"
+   'SnAbst p T1 T2 = (TPair (Bind2 p Abst) T1 T2).
+
+interpretation "positive abstraction (term)"
+   'SnAbstPos T1 T2 = (TPair (Bind2 true Abst) T1 T2).
+
+interpretation "negative abstraction (term)"
+   'SnAbstNeg T1 T2 = (TPair (Bind2 false Abst) T1 T2).
+
+interpretation "application (term)"
+   'SnAppl T1 T2 = (TPair (Flat2 Appl) T1 T2).
+
+interpretation "native type annotation (term)"
+   'SnCast T1 T2 = (TPair (Flat2 Cast) T1 T2).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: term_dec *)
+lemma eq_term_dec: ∀T1,T2:term. Decidable (T1 = T2).
+#T1 elim T1 -T1 #I1 [| #V1 #T1 #IHV1 #IHT1 ] * #I2 [2,4: #V2 #T2 ]
+[1,4: @or_intror #H destruct
+| elim (eq_item2_dec I1 I2) #HI
+  [ elim (IHV1 V2) -IHV1 #HV
+    [ elim (IHT1 T2) -IHT1 /2 width=1 by or_introl/ #HT ]
+  ]
+  @or_intror #H destruct /2 width=1 by/
+| elim (eq_item0_dec I1 I2) /2 width=1 by or_introl/ #HI
+  @or_intror #H destruct /2 width=1 by/
+]
+qed-.
+
+(* Basic inversion lemmas ***************************************************)
+
+fact destruct_tatom_tatom_aux: ∀I1,I2. ⓪{I1} = ⓪{I2} → I1 = I2.
+#I1 #I2 #H destruct //
+qed-.
+
+fact destruct_tpair_tpair_aux: ∀I1,I2,T1,T2,V1,V2. ②{I1}T1.V1 = ②{I2}T2.V2 →
+                               ∧∧T1 = T2 & I1 = I2 & V1 = V2.
+#I1 #I2 #T1 #T2 #V1 #V2 #H destruct /2 width=1 by and3_intro/
+qed-.
+
+lemma discr_tpair_xy_x: ∀I,T,V. ②{I}V.T = V → ⊥.
+#I #T #V elim V -V
+[ #J #H destruct
+| #J #W #U #IHW #_ #H elim (destruct_tpair_tpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
+]
+qed-.
+
+(* Basic_1: was: thead_x_y_y *)
+lemma discr_tpair_xy_y: ∀I,V,T. ②{I}V.T = T → ⊥.
+#I #V #T elim T -T
+[ #J #H destruct
+| #J #W #U #_ #IHU #H elim (destruct_tpair_tpair_aux … H) -H /2 width=1 by/ (**) (* destruct lemma needed *)
+]
+qed-.
+
+lemma eq_false_inv_tpair_sn: ∀I,V1,T1,V2,T2.
+                             (②{I}V1.T1 = ②{I}V2.T2 → ⊥) →
+                             (V1 = V2 → ⊥) ∨ (V1 = V2 ∧ (T1 = T2 → ⊥)).
+#I #V1 #T1 #V2 #T2 #H
+elim (eq_term_dec V1 V2) /3 width=1 by or_introl/ #HV12 destruct
+@or_intror @conj // #HT12 destruct /2 width=1 by/
+qed-.
+
+lemma eq_false_inv_tpair_dx: ∀I,V1,T1,V2,T2.
+                             (②{I} V1. T1 = ②{I}V2.T2 → ⊥) →
+                             (T1 = T2 → ⊥) ∨ (T1 = T2 ∧ (V1 = V2 → ⊥)).
+#I #V1 #T1 #V2 #T2 #H
+elim (eq_term_dec T1 T2) /3 width=1 by or_introl/ #HT12 destruct
+@or_intror @conj // #HT12 destruct /2 width=1 by/
+qed-.
+
+(* Basic_1: removed theorems 3:
+            not_void_abst not_abbr_void not_abst_void
+*)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/term_simple.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/term_simple.ma
new file mode 100644 (file)
index 0000000..50e2595
--- /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/notation/relations/simple_1.ma".
+include "basic_2/syntax/term.ma".
+
+(* SIMPLE (NEUTRAL) TERMS ***************************************************)
+
+inductive simple: predicate term ≝
+   | simple_atom: ∀I. simple (⓪{I})
+   | simple_flat: ∀I,V,T. simple (ⓕ{I} V. T)
+.
+
+interpretation "simple (term)" 'Simple T = (simple T).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact simple_inv_bind_aux: ∀T. 𝐒⦃T⦄ → ∀p,J,W,U. T = ⓑ{p,J}W.U → ⊥.
+#T * -T
+[ #I #p #J #W #U #H destruct
+| #I #V #T #a #J #W #U #H destruct
+]
+qed-.
+
+lemma simple_inv_bind: ∀p,I,V,T. 𝐒⦃ⓑ{p,I} V. T⦄ → ⊥.
+/2 width=7 by simple_inv_bind_aux/ qed-.
+
+lemma simple_inv_pair: ∀I,V,T.  𝐒⦃②{I}V.T⦄ → ∃J. I = Flat2 J.
+* /2 width=2 by ex_intro/
+#p #I #V #T #H elim (simple_inv_bind … H)
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/term_vector.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/term_vector.ma
new file mode 100644 (file)
index 0000000..1de2ef3
--- /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 "ground_2/lib/list.ma".
+include "basic_2/notation/functions/snapplvector_2.ma".
+include "basic_2/syntax/term_simple.ma".
+
+(* TERMS ********************************************************************)
+
+rec definition applv Vs T on Vs ≝
+  match Vs with
+  [ nil        ⇒ T
+  | cons hd tl ⇒ ⓐhd. (applv tl T)
+  ].
+
+interpretation "application to vector (term)"
+   'SnApplVector Vs T = (applv Vs T).
+
+(* Basic properties *********************************************************)
+
+lemma applv_nil: ∀T. Ⓐ◊.T = T.
+// qed.
+
+lemma applv_cons: ∀V,Vs,T. ⒶV@Vs.T = ⓐV.ⒶVs.T.
+// qed.
+
+(* Properties with simple terms *********************************************)
+
+lemma applv_simple: ∀T,Vs. 𝐒⦃T⦄ → 𝐒⦃ⒶVs.T⦄.
+#T * //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/term_weight.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/term_weight.ma
new file mode 100644 (file)
index 0000000..9076a9b
--- /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/notation/functions/weight_1.ma".
+include "basic_2/syntax/term.ma".
+
+(* WEIGHT OF A TERM *********************************************************)
+
+rec definition tw T ≝ match T with
+[ TAtom _     ⇒ 1
+| TPair _ V T ⇒ tw V + tw T + 1
+].
+
+interpretation "weight (term)" 'Weight T = (tw T).
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: tweight_lt *)
+lemma tw_pos: ∀T. 1 ≤ ♯{T}.
+#T elim T -T //
+qed.
+
+(* Basic_1: removed theorems 11:
+            wadd_le wadd_lt wadd_O weight_le weight_eq weight_add_O
+            weight_add_S tlt_trans tlt_head_sx tlt_head_dx tlt_wf_ind
+*)
+(* Basic_1: removed local theorems 1: q_ind *)
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts.ma
new file mode 100644 (file)
index 0000000..281f7fc
--- /dev/null
@@ -0,0 +1,108 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/topiso_2.ma".
+include "basic_2/syntax/term_simple.ma".
+
+(* SAME TOP TERM STRUCTURE **************************************************)
+
+inductive tsts: relation term ≝
+   | tsts_atom: ∀I. tsts (⓪{I}) (⓪{I})
+   | tsts_pair: ∀I,V1,V2,T1,T2. tsts (②{I}V1.T1) (②{I}V2.T2)
+.
+
+interpretation "same top structure (term)" 'TopIso T1 T2 = (tsts T1 T2).
+
+(* Basic inversion lemmas ***************************************************)
+
+fact tsts_inv_atom1_aux: ∀T1,T2. T1 ≂ T2 → ∀I. T1 = ⓪{I} → T2 = ⓪{I}.
+#T1 #T2 * -T1 -T2 //
+#J #V1 #V2 #T1 #T2 #I #H destruct
+qed-.
+
+(* Basic_1: was: iso_gen_sort iso_gen_lref *)
+lemma tsts_inv_atom1: ∀I,T2. ⓪{I} ≂ T2 → T2 = ⓪{I}.
+/2 width=3 by tsts_inv_atom1_aux/ qed-.
+
+fact tsts_inv_pair1_aux: ∀T1,T2. T1 ≂ T2 → ∀I,W1,U1. T1 = ②{I}W1.U1 →
+                         ∃∃W2,U2. T2 = ②{I}W2. U2.
+#T1 #T2 * -T1 -T2
+[ #J #I #W1 #U1 #H destruct
+| #J #V1 #V2 #T1 #T2 #I #W1 #U1 #H destruct /2 width=3 by ex1_2_intro/
+]
+qed-.
+
+(* Basic_1: was: iso_gen_head *)
+lemma tsts_inv_pair1: ∀I,W1,U1,T2. ②{I}W1.U1 ≂ T2 →
+                      ∃∃W2,U2. T2 = ②{I}W2. U2.
+/2 width=5 by tsts_inv_pair1_aux/ qed-.
+
+fact tsts_inv_atom2_aux: ∀T1,T2. T1 ≂ T2 → ∀I. T2 = ⓪{I} → T1 = ⓪{I}.
+#T1 #T2 * -T1 -T2 //
+#J #V1 #V2 #T1 #T2 #I #H destruct
+qed-.
+
+lemma tsts_inv_atom2: ∀I,T1. T1 ≂ ⓪{I} → T1 = ⓪{I}.
+/2 width=3 by tsts_inv_atom2_aux/ qed-.
+
+fact tsts_inv_pair2_aux: ∀T1,T2. T1 ≂ T2 → ∀I,W2,U2. T2 = ②{I}W2.U2 →
+                         ∃∃W1,U1. T1 = ②{I}W1.U1.
+#T1 #T2 * -T1 -T2
+[ #J #I #W2 #U2 #H destruct
+| #J #V1 #V2 #T1 #T2 #I #W2 #U2 #H destruct /2 width=3 by ex1_2_intro/
+]
+qed-.
+
+lemma tsts_inv_pair2: ∀I,T1,W2,U2. T1 ≂ ②{I}W2.U2 →
+                      ∃∃W1,U1. T1 = ②{I}W1.U1.
+/2 width=5 by tsts_inv_pair2_aux/ qed-.
+
+(* Basic properties *********************************************************)
+
+(* Basic_1: was: iso_refl *)
+lemma tsts_refl: reflexive … tsts.
+#T elim T -T //
+qed.
+
+lemma tsts_sym: symmetric … tsts.
+#T1 #T2 #H elim H -T1 -T2 //
+qed-.
+
+lemma tsts_dec: ∀T1,T2. Decidable (T1 ≂ T2).
+* #I1 [2: #V1 #T1 ] * #I2 [2,4: #V2 #T2 ]
+[ elim (eq_item2_dec I1 I2) #HI12
+  [ destruct /2 width=1 by tsts_pair, or_introl/
+  | @or_intror #H
+    elim (tsts_inv_pair1 … H) -H #V #T #H destruct /2 width=1 by/
+  ]
+| @or_intror #H
+  lapply (tsts_inv_atom1 … H) -H #H destruct
+| @or_intror #H
+  lapply (tsts_inv_atom2 … H) -H #H destruct
+| elim (eq_item0_dec I1 I2) #HI12
+  [ destruct /2 width=1 by or_introl/
+  | @or_intror #H
+    lapply (tsts_inv_atom2 … H) -H #H destruct /2 width=1 by/
+  ]
+]
+qed.
+
+lemma simple_tsts_repl_dx: ∀T1,T2. T1 ≂ T2 → 𝐒⦃T1⦄ → 𝐒⦃T2⦄.
+#T1 #T2 * -T1 -T2 //
+#I #V1 #V2 #T1 #T2 #H
+elim (simple_inv_pair … H) -H #J #H destruct //
+qed-.
+
+lemma simple_tsts_repl_sn: ∀T1,T2. T1 ≂ T2 → 𝐒⦃T2⦄ → 𝐒⦃T1⦄.
+/3 width=3 by simple_tsts_repl_dx, tsts_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_tsts.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_tsts.ma
new file mode 100644 (file)
index 0000000..59dfd02
--- /dev/null
@@ -0,0 +1,32 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/tsts.ma".
+
+(* SAME TOP TERM STRUCTURE **************************************************)
+
+(* Main properties **********************************************************)
+
+(* Basic_1: was: iso_trans *)
+theorem tsts_trans: Transitive … tsts.
+#T1 #T * -T1 -T //
+#I #V1 #V #T1 #T #X #H
+elim (tsts_inv_pair1 … H) -H #V2 #T2 #H destruct //
+qed-.
+
+theorem tsts_canc_sn: ∀T,T1. T ≂ T1 → ∀T2. T ≂ T2 → T1 ≂ T2.
+/3 width=3 by tsts_trans, tsts_sym/ qed-.
+
+theorem tsts_canc_dx: ∀T1,T. T1 ≂ T → ∀T2. T2 ≂ T → T1 ≂ T2.
+/3 width=3 by tsts_trans, tsts_sym/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_vector.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/tsts_vector.ma
new file mode 100644 (file)
index 0000000..9341af6
--- /dev/null
@@ -0,0 +1,30 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/syntax/term_vector.ma".
+include "basic_2/syntax/tsts.ma".
+
+(* SAME TOP TERM STRUCTURE **************************************************)
+
+(* Advanced inversion lemmas ************************************************)
+
+(* Basic_1: was only: iso_flats_lref_bind_false iso_flats_flat_bind_false *)
+lemma tsts_inv_bind_applv_simple: ∀p,I,Vs,V2,T1,T2. ⒶVs.T1 ≂ ⓑ{p,I}V2.T2 →
+                                  𝐒⦃T1⦄ → ⊥.
+#p #I #Vs #V2 #T1 #T2 #H elim (tsts_inv_pair2 … H) -H
+#V0 #T0 elim Vs -Vs normalize
+[ #H destruct #H /2 width=5 by simple_inv_bind/
+| #V #Vs #_ #H destruct
+]
+qed-.
index 172b43b1d8e1c693230a18502341aa2176d12d9f..cd88f565a13aaab9020ecf4611e2e629e38c646e 100644 (file)
@@ -162,10 +162,6 @@ table {
    ]
    class "green"
    [ { "static typing" * } {
-        [ { "parameters" * } {
-             [ "sh" "sd" * ]
-          }
-        ]
         [ { "restricted ref. for atomic arity assignment" * } {
              [ "lsuba ( ? ⊢ ? ⫃⁝ ? )" "lsuba_drops" + "lsuba_lsubr" + "lsuba_aaa" + "lsuba_lsuba" * ]
           }
@@ -241,13 +237,13 @@ table {
      }
    ]
    class "red"
-   [ { "grammar" * } {
+   [ { "syntax" * } {
         [ { "append for local environments" * } {
              [ "append ( ? @@ ? )" "append_length" * ]
           }
         ]
-        [ { "context-sensitive equivalences for terms" * } {
-             [ "ceq" "ceq_ceq" * ]
+        [ { "degree-based equivalence for terms" * } {
+             [ "deq ( ? ≡[?,?] ? ) " "deq_deq" * ]
           }
         ]
         [ { "same top term structure" * } {
@@ -255,17 +251,34 @@ table {
           }
         ]
         [ { "closures" * } {
-             [ "cl_weight ( ♯{?,?,?} )" "cl_restricted_weight ( ♯{?,?} )" * ]
+             [ "cl_weight ( ♯{?,?,?} )" * ]
+             [ "cl_restricted_weight ( ♯{?,?} )" * ]
           }
         ]
-        [ { "internal syntax" * } {
+        [ { "global environments" * } {
              [ "genv" * ]
-             [ "lenv" "lenv_weight ( ♯{?} )" "lenv_length ( |?| )" * ]
-             [ "term" "term_weight ( ♯{?} )" "term_simple ( 𝐒⦃?⦄ )" "term_vector ( Ⓐ?.? )" * ]
+          }
+        ]
+        [ { "local environments" * } {
+             [ "lenv_length ( |?| )" * ]
+             [ "lenv_weight ( ♯{?} )" * ]
+             [ "lenv" * ]
+          }
+        ]
+        [ { "terms" * } {
+             [ "term_vector ( Ⓐ?.? )" * ]
+             [ "term_simple ( 𝐒⦃?⦄ )"  * ]
+             [ "term_weight ( ♯{?} )" * ]
+             [ "term" * ]
+          }
+        ]
+        [ { "items" * } {
+             [ "item_sd" * ]
+             [ "item_sh" * ]
              [ "item" * ]
           }
         ]
-        [ { "external syntax" * } {
+        [ { "atomic arities" * } {
              [ "aarity" * ]
           }
         ]
index 739dd9871902248d2d25818512ec32546308522f..2f053dec9c5122002d2c3f915c6f74b3764d00af 100644 (file)
@@ -1,6 +1,6 @@
 #!/bin/sh
-#for MA in `find -name "*.ma"`; do
-for MA in `find -name "cpg*.ma" -or -name "cpx*.ma"`; do
+for MA in `find -name "*.ma"`; do
+#for MA in `find -name "cpg*.ma" -or -name "cpx*.ma"`; do
    echo ${MA}; sed "s!$1!$2!g" ${MA} > ${MA}.new
    if diff ${MA} ${MA}.new > /dev/null; 
       then rm -f ${MA}.new;