]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/delayed_updating/reduction/dfr_ifr.ma
update in delayed_updating
[helm.git] / matita / matita / contribs / lambdadelta / delayed_updating / reduction / dfr_ifr.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 "delayed_updating/reduction/dfr.ma".
16 include "delayed_updating/reduction/ifr.ma".
17 include "delayed_updating/substitution/fsubst_lift.ma".
18 include "delayed_updating/substitution/fsubst_eq.ma".
19 include "delayed_updating/substitution/lift_constructors.ma".
20 include "delayed_updating/substitution/lift_preterm_eq.ma".
21 include "delayed_updating/substitution/lift_structure_depth.ma".
22 include "delayed_updating/syntax/prototerm_proper_constructors.ma".
23 include "delayed_updating/syntax/path_structure_depth.ma".
24 include "ground/relocation/tr_pap_pushs.ma".
25
26 (* DELAYED FOCUSED REDUCTION ************************************************)
27
28 lemma dfr_lift_bi (f) (p) (q) (t1) (t2): t1 ϵ 𝐓 →
29       t1 ➡𝐝𝐟[p,q] t2 → ↑[f]t1 ➡𝐟[⊗p,⊗q] ↑[f]t2.
30 #f #p #q #t1 #t2 #H0t1
31 * #b #n * #Hb #Hn  #Ht1 #Ht2
32 @(ex1_2_intro … (⊗b) (↑❘⊗q❘)) @and4_intro
33 [ //
34 | #g <lift_rmap_structure <depth_structure
35   >tr_pushs_swap <tr_pap_pushs_le //
36 | lapply (in_comp_lift_bi f … Ht1) -Ht1 -H0t1 -Hb -Ht2
37   <lift_path_d_empty_dx //
38 | lapply (lift_term_eq_repl_dx f … Ht2) -Ht2 #Ht2
39   @(subset_eq_trans … Ht2) -t2
40   @(subset_eq_trans … (lift_fsubst …))
41   [ <structure_append <structure_A_sn <structure_append <structure_L_sn
42     @fsubst_eq_repl [ // ]
43     @(subset_eq_trans … (lift_iref …))
44     @(subset_eq_canc_sn … (lift_term_eq_repl_dx …))
45     [ @lift_grafted_S /2 width=2 by ex_intro/ | skip ]
46     @(subset_eq_trans … (lift_term_after …))
47     @(subset_eq_canc_dx … (lift_term_after …))
48     @lift_term_eq_repl_sn -t1
49   | //
50   | /2 width=2 by ex_intro/
51   | //
52   ]
53 ]