]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/reduction/fpb.ma
1abe847ab69ef5fa143cf38bea1943615a9f57ad
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / reduction / fpb.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/notation/relations/btpred_8.ma".
16 include "basic_2/relocation/fquq_alt.ma".
17 include "basic_2/reduction/fpn.ma".
18
19 (* "BIG TREE" PARALLEL REDUCTION FOR CLOSURES *******************************)
20
21 inductive fpb (h) (g) (G1) (L1) (T1): relation3 genv lenv term ≝
22 | fpb_fquq: ∀G2,L2,T2. ⦃G1, L1, T1⦄ ⊃⸮ ⦃G2, L2, T2⦄ → fpb h g G1 L1 T1 G2 L2 T2
23 | fpb_cpx : ∀T2. ⦃G1, L1⦄ ⊢ T1 ➡[h, g] T2 → fpb h g G1 L1 T1 G1 L1 T2
24 | fpb_lpx : ∀L2. ⦃G1, L1⦄ ⊢ ➡[h, g] L2 → fpb h g G1 L1 T1 G1 L2 T1
25 .
26
27 interpretation
28    "'big tree' parallel reduction (closure)"
29    'BTPRed h g G1 L1 T1 G2 L2 T2 = (fpb h g G1 L1 T1 G2 L2 T2).
30
31 (* Basic properties *********************************************************)
32
33 lemma fpb_refl: ∀h,g. tri_reflexive … (fpb h g).
34 /2 width=1 by fpb_cpx/ qed.
35
36 lemma cpr_fpb: ∀h,g,G,L,T1,T2. ⦃G, L⦄ ⊢ T1 ➡ T2 → ⦃G, L, T1⦄ ≽[h, g] ⦃G, L, T2⦄. 
37 /3 width=1 by fpb_cpx, cpr_cpx/ qed.
38
39 lemma lpr_fpb: ∀h,g,G,L1,L2,T. ⦃G, L1⦄ ⊢ ➡ L2 → ⦃G, L1, T⦄ ≽[h, g] ⦃G, L2, T⦄.
40 /3 width=1 by fpb_lpx, lpr_lpx/ qed.
41
42 (* Basic forward lemmas *****************************************************)
43
44 lemma fpb_bteq_fwd_fpn: ∀h,g,G1,G2,L1,L2,T1,T2. ⦃G1, L1, T1⦄ ≽[h, g] ⦃G2, L2, T2⦄ →
45                         ⦃G1, L1, T1⦄ ⋕ ⦃G2, L2, T2⦄ → ⦃G1, L1, T1⦄ ⊢ ➡[h, g] ⦃G2, L2, T2⦄.
46 #h #g #G1 #G2 #L1 #L2 #T1 #T2 * -G2 -L2 -T2 /2 width=1 by and3_intro/
47 [ #G2 #L2 #T2 #H elim (fquq_inv_gen … H) -H
48   [ #H1 #H2 elim (fqu_fwd_bteq … H1 H2)
49   | * #HG #HL #HT #_ destruct //
50   ]
51 | #T2 #HT12 * //
52 ]
53 qed-.