(* *)
(**************************************************************************)
-include "delayed_updating/syntax/path_depth.ma".
-include "delayed_updating/syntax/path_structure.ma".
-include "delayed_updating/syntax/path_balanced.ma".
include "delayed_updating/syntax/prototerm_constructors.ma".
include "delayed_updating/syntax/prototerm_equivalence.ma".
include "delayed_updating/substitution/fsubst.ma".
+include "delayed_updating/substitution/lift.ma".
+include "delayed_updating/syntax/path_structure.ma".
+include "delayed_updating/syntax/path_balanced.ma".
+include "delayed_updating/syntax/path_depth.ma".
include "delayed_updating/notation/relations/black_rightarrow_df_4.ma".
+include "ground/xoa/ex_1_2.ma".
+include "ground/xoa/and_4.ma".
(* DELAYED FOCUSED REDUCTION ************************************************)
definition dfr (p) (q): relation2 prototerm prototerm ≝
- λt1,t2. ∃b.
+ λt1,t2. ∃∃b,n.
let r ≝ p●𝗔◗b●𝗟◗q in
- ∧∧ ⊗b ϵ 𝐁 & r◖𝗱❘q❘ ϵ t1 &
- t1[⋔r←𝛗❘q❘.(t1⋔(p◖𝗦))] ⇔ t2
+ ∧∧ ⊗b ϵ 𝐁 & ❘q❘ = (↑[q]𝐢)@❨n❩ & r◖𝗱n ϵ t1 &
+ t1[⋔r←𝛗n.(t1⋔(p◖𝗦))] ⇔ t2
.
interpretation
include "delayed_updating/reduction/dfr.ma".
include "delayed_updating/reduction/ifr.ma".
include "delayed_updating/substitution/fsubst_lift.ma".
+include "delayed_updating/substitution/lift_structure_depth.ma".
include "delayed_updating/syntax/prototerm_proper_constructors.ma".
+include "delayed_updating/syntax/path_structure_depth.ma".
+include "ground/relocation/tr_id_pap.ma".
+include "ground/relocation/tr_id_pushs.ma".
(* DELAYED FOCUSED REDUCTION ************************************************)
lemma dfr_lift_bi (f) (p) (q) (t1) (t2): t1 ϵ 𝐓 →
t1 ➡𝐝𝐟[p,q] t2 → ↑[f]t1 ➡𝐟[⊗p,⊗q] ↑[f]t2.
#f #p #q #t1 #t2 #H0t1
-* #b * #Hb #Ht1 #Ht2
-@(ex_intro … (⊗b)) @and3_intro
+* #b #n * #Hb #Hn #Ht1 #Ht2
+@(ex1_2_intro … (⊗b) (❘⊗q❘)) @and4_intro
[ //
-| lapply (in_comp_lift_bi f … Ht1) -Ht1 #Ht1
+| //
+| lapply (in_comp_lift_bi f … Ht1) -Ht1 -H0t1 -Hb -Ht2 #Ht1
+ <depth_structure
| lapply (eq_lift_bi f … Ht2) -Ht2 #Ht2
@(subset_eq_trans … Ht2) -t2
@(subset_eq_trans … (lift_fsubst …))
| //
]
]
-
-
(* *)
(**************************************************************************)
+include "delayed_updating/substitution/fsubst.ma".
+include "delayed_updating/substitution/lift_prototerm.ma".
include "delayed_updating/syntax/path_depth.ma".
include "delayed_updating/syntax/path_structure.ma".
include "delayed_updating/syntax/path_balanced.ma".
-include "delayed_updating/substitution/fsubst.ma".
-include "delayed_updating/substitution/lift_prototerm.ma".
include "delayed_updating/notation/relations/black_rightarrow_f_4.ma".
+include "ground/xoa/ex_1_2.ma".
+include "ground/xoa/and_4.ma".
(* IMMEDIATE FOCUSED REDUCTION ************************************************)
definition ifr (p) (q): relation2 prototerm prototerm ≝
- λt1,t2. ∃b.
+ λt1,t2. ∃∃b,n.
let r ≝ p●𝗔◗b●𝗟◗q in
- ∧∧ ⊗b ϵ 𝐁 & r◖𝗱❘q❘ ϵ t1 &
- t1[⋔r←↑[𝐮❨❘q❘❩](t1⋔(p◖𝗦))] ⇔ t2
+ ∧∧ ⊗b ϵ 𝐁 & ❘q❘ = (↑[q]𝐢)@❨n❩ & r◖𝗱n ϵ t1 &
+ t1[⋔r←↑[𝐮❨n❩](t1⋔(p◖𝗦))] ⇔ t2
.
interpretation
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||M|| *)
+(* ||A|| A project by Andrea Asperti *)
+(* ||T|| *)
+(* ||I|| Developers: *)
+(* ||T|| The HELM team. *)
+(* ||A|| http://helm.cs.unibo.it *)
+(* \ / *)
+(* \ / This file is distributed under the terms of the *)
+(* v GNU General Public License Version 2 *)
+(* *)
+(**************************************************************************)
+
+include "delayed_updating/substitution/lift.ma".
+include "delayed_updating/syntax/path_structure.ma".
+include "delayed_updating/syntax/path_depth.ma".
+include "ground/relocation/tr_pushs.ma".
+include "ground/arith/nat_pred_succ.ma".
+
+(* LIFT FOR PATH ***********************************************************)
+
+(* Basic constructions with structure and depth ****************************)
+
+lemma lift_rmap_structure (p) (f):
+ (⫯*[↓❘p❘]f) = ↑[⊗p]f.
+#p elim p -p //
+* [ #n ] #p #IH #f //
+[ <lift_rmap_L_sn <IH -IH >tr_pushs_swap //
+| <lift_rmap_A_sn //
+| <lift_rmap_S_sn //
+]
+qed.
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||M|| *)
+(* ||A|| A project by Andrea Asperti *)
+(* ||T|| *)
+(* ||I|| Developers: *)
+(* ||T|| The HELM team. *)
+(* ||A|| http://helm.cs.unibo.it *)
+(* \ / *)
+(* \ / This file is distributed under the terms of the *)
+(* v GNU General Public License Version 2 *)
+(* *)
+(**************************************************************************)
+
+include "delayed_updating/syntax/path_structure.ma".
+include "delayed_updating/syntax/path_depth.ma".
+
+(* STRUCTURE FOR PATH *******************************************************)
+
+(* Constructions with depth *************************************************)
+
+lemma depth_structure (p):
+ ❘p❘ = ❘⊗p❘.
+#p elim p -p //
+* [ #n ] #p #IH //
+[ <structure_L_sn <depth_L <depth_L //
+| <structure_A_sn <depth_A <depth_A //
+| <structure_S_sn <depth_S <depth_S //
+]
+qed.