1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "basic_2/grammar/lenv_px.ma".
16 include "basic_2/reducibility/tpr.ma".
18 (* CONTEXT-FREE PARALLEL REDUCTION ON LOCAL ENVIRONMENTS ********************)
20 definition ltpr: relation lenv ≝ lpx tpr.
23 "context-free parallel reduction (environment)"
24 'PRed L1 L2 = (ltpr L1 L2).
26 (* Basic properties *********************************************************)
28 lemma ltpr_refl: reflexive … ltpr.
31 lemma ltpr_append: ∀K1,K2. K1 ➡ K2 → ∀L1,L2:lenv. L1 ➡ L2 → K1 @@ L1 ➡ K2 @@ L2.
34 (* Basic inversion lemmas ***************************************************)
36 (* Basic_1: was: wcpr0_gen_sort *)
37 lemma ltpr_inv_atom1: ∀L2. ⋆ ➡ L2 → L2 = ⋆.
38 /2 width=2 by lpx_inv_atom1/ qed-.
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-.
45 lemma ltpr_inv_atom2: ∀L1. L1 ➡ ⋆ → L1 = ⋆.
46 /2 width=2 by lpx_inv_atom2/ qed-.
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-.
52 (* Basic forward lemmas *****************************************************)
54 lemma ltpr_fwd_length: ∀L1,L2. L1 ➡ L2 → |L1| = |L2|.
55 /2 width=2 by lpx_fwd_length/ qed-.
57 (* Advanced inversion lemmas ************************************************)
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-.
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-.
67 (* Basic_1: removed theorems 2: wcpr0_getl wcpr0_getl_back *)