]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/substitution/lpss.ma
- we are committing just the components before "reducibility"
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / substitution / lpss.ma
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 include "basic_2/grammar/lenv_px_sn.ma".
16 include "basic_2/substitution/cpss.ma".
17
18 (* SN PARALLEL SUBSTITUTION FOR LOCAL ENVIRONMENTS **************************)
19
20 (* Basic_1: includes: csubst1_bind *)
21 definition lpss: relation lenv ≝ lpx_sn cpss. 
22
23 interpretation "parallel substitution (local environment, sn variant)"
24    'PSubstStarSn L1 L2 = (lpss L1 L2).
25
26 (* Basic inversion lemmas ***************************************************)
27
28 lemma lpss_inv_atom1: ∀L2. ⋆ ⊢ ▶* L2 → L2 = ⋆.
29 /2 width=4 by lpx_sn_inv_atom1_aux/ qed-.
30
31 lemma lpss_inv_pair1: ∀I,K1,V1,L2. K1. ⓑ{I} V1 ⊢ ▶* L2 →
32                       ∃∃K2,V2. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L2 = K2. ⓑ{I} V2.
33 /2 width=3 by lpx_sn_inv_pair1_aux/ qed-.
34
35 lemma lpss_inv_atom2: ∀L1. L1 ⊢ ▶* ⋆ → L1 = ⋆.
36 /2 width=4 by lpx_sn_inv_atom2_aux/ qed-.
37
38 lemma lpss_inv_pair2: ∀I,L1,K2,V2. L1 ⊢ ▶* K2. ⓑ{I} V2 →
39                        ∃∃K1,V1. K1 ⊢ ▶* K2 & K1 ⊢ V1 ▶* V2 & L1 = K1. ⓑ{I} V1.
40 /2 width=3 by lpx_sn_inv_pair2_aux/ qed-.
41
42 (* Basic properties *********************************************************)
43
44 (* Basic_1: was by definition: csubst1_refl *)
45 lemma lpss_refl: ∀L. L ⊢ ▶* L.
46 /2 width=1 by lpx_sn_refl/ qed.
47
48 lemma lpss_append: ∀K1,K2. K1 ⊢ ▶* K2 → ∀L1,L2. L1 ⊢ ▶* L2 →
49                     L1 @@ K1 ⊢ ▶* L2 @@ K2.
50 /3 width=1 by lpx_sn_append, cpss_append/ qed.
51
52 (* Basic forward lemmas *****************************************************)
53
54 lemma lpss_fwd_length: ∀L1,L2. L1 ⊢ ▶* L2 → |L1| = |L2|.
55 /2 width=2 by lpx_sn_fwd_length/ qed-.
56
57 (* Advanced forward lemmas **************************************************)
58
59 lemma lpss_fwd_append1: ∀K1,L1,L. K1 @@ L1 ⊢ ▶* L →
60                         ∃∃K2,L2. K1 ⊢ ▶* K2 & L = K2 @@ L2.
61 /2 width=2 by lpx_sn_fwd_append1/ qed-.
62
63 lemma lpss_fwd_append2: ∀L,K2,L2. L ⊢ ▶* K2 @@ L2 →
64                         ∃∃K1,L1. K1 ⊢ ▶* K2 & L = K1 @@ L1.
65 /2 width=2 by lpx_sn_fwd_append2/ qed-.
66
67 (* Basic_1: removed theorems 28:
68             csubst0_clear_O csubst0_drop_lt csubst0_drop_gt csubst0_drop_eq
69             csubst0_clear_O_back csubst0_clear_S csubst0_clear_trans
70             csubst0_drop_gt_back csubst0_drop_eq_back csubst0_drop_lt_back
71             csubst0_gen_sort csubst0_gen_head csubst0_getl_ge csubst0_getl_lt
72             csubst0_gen_S_bind_2 csubst0_getl_ge_back csubst0_getl_lt_back
73             csubst0_snd_bind csubst0_fst_bind csubst0_both_bind
74             csubst1_head csubst1_flat csubst1_gen_head
75             csubst1_getl_ge csubst1_getl_lt csubst1_getl_ge_back getl_csubst1
76             fsubst0_gen_base
77 *)