]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambda_delta/basic_2/reducibility/ltpr.ma
a910ea7df3f835c0520b6d1b5a6420915bf2f8f1
[helm.git] / matita / matita / contribs / lambda_delta / basic_2 / reducibility / ltpr.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.ma".
16 include "basic_2/reducibility/tpr.ma".
17
18 (* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
19
20 definition ltpr: relation lenv ≝ lpx tpr.
21
22 interpretation
23   "context-free parallel reduction (environment)"
24   'PRed L1 L2 = (ltpr L1 L2).
25
26 (* Basic properties *********************************************************)
27
28 lemma ltpr_refl: reflexive … ltpr.
29 /2 width=1/ qed.
30
31 lemma ltpr_append: ∀K1,K2. K1 ➡ K2 → ∀L1,L2:lenv. L1 ➡ L2 → K1 @@ L1 ➡ K2 @@ L2.
32 /2 width=1/ qed.
33
34 (* Basic inversion lemmas ***************************************************)
35
36 (* Basic_1: was: wcpr0_gen_sort *)
37 lemma ltpr_inv_atom1: ∀L2. ⋆ ➡ L2 → L2 = ⋆.
38 /2 width=2 by lpx_inv_atom1/ qed-.
39
40 (* Basic_1: was: wcpr0_gen_head *)
41 lemma ltpr_inv_pair1: ∀K1,I,V1,L2. K1. ⓑ{I} V1 ➡ L2 →
42                       ∃∃K2,V2. K1 ➡ K2 & V1 ➡ V2 & L2 = K2. ⓑ{I} V2.
43 /2 width=1 by lpx_inv_pair1/ qed-.
44
45 lemma ltpr_inv_atom2: ∀L1. L1 ➡ ⋆ → L1 = ⋆.
46 /2 width=2 by lpx_inv_atom2/ qed-.
47
48 lemma ltpr_inv_pair2: ∀L1,K2,I,V2. L1 ➡ K2. ⓑ{I} V2 →
49                       ∃∃K1,V1. K1 ➡ K2 & V1 ➡ V2 & L1 = K1. ⓑ{I} V1.
50 /2 width=1 by lpx_inv_pair2/ qed-.
51
52 (* Basic forward lemmas *****************************************************)
53
54 lemma ltpr_fwd_length: ∀L1,L2. L1 ➡ L2 → |L1| = |L2|.
55 /2 width=2 by lpx_fwd_length/ qed-.
56
57 (* Advanced inversion lemmas ************************************************)
58
59 lemma ltpr_inv_append1: ∀K1,L1. ∀L:lenv. K1 @@ L1 ➡ L →
60                         ∃∃K2,L2. K1 ➡ K2 & L1 ➡ L2 & L = K2 @@ L2.
61 /2 width=1 by lpx_inv_append1/ qed-.
62
63 lemma ltpr_inv_append2: ∀L:lenv. ∀K2,L2. L ➡ K2 @@ L2 →
64                         ∃∃K1,L1. K1 ➡ K2 & L1 ➡ L2 & L = K1 @@ L1.
65 /2 width=1 by lpx_inv_append2/ qed-.
66
67 (* Basic_1: removed theorems 2: wcpr0_getl wcpr0_getl_back *)