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_uni_compose.ma".
include "ground/relocation/tr_pap_pushs.ma".
+include "ground/lib/stream_eq_eq.ma".
+
(* DELAYED FOCUSED REDUCTION ************************************************)
lemma dfr_lift_bi (f) (p) (q) (t1) (t2): t1 Ļµ š ā
| lapply (lift_term_eq_repl_dx f ā¦ Ht2) -Ht2 #Ht2
@(subset_eq_trans ā¦ Ht2) -t2
@(subset_eq_trans ā¦ (lift_fsubst ā¦))
- [ <structure_append <structure_A_sn <structure_append <structure_L_sn
+ [ <lift_rmap_append <lift_rmap_A_sn <lift_rmap_append <lift_rmap_L_sn
+ <structure_append <structure_A_sn <structure_append <structure_L_sn
+ <depth_plus <depth_L_sn <depth_structure <depth_structure
@fsubst_eq_repl [ // ]
@(subset_eq_trans ā¦ (lift_iref ā¦))
@(subset_eq_canc_sn ā¦ (lift_term_eq_repl_dx ā¦))
@(subset_eq_trans ā¦ (lift_term_after ā¦))
@(subset_eq_canc_dx ā¦ (lift_term_after ā¦))
@lift_term_eq_repl_sn -t1
+ @(stream_eq_trans ā¦ (tr_compose_uni_dx ā¦))
+(*
+ >nrplus_inj_dx <tr_pap_plus
+*)
| //
| /2 width=2 by ex_intro/
| //
(**************************************************************************)
include "delayed_updating/syntax/path.ma".
-include "ground/arith/nat_succ.ma".
+include "ground/arith/nat_plus.ma".
include "ground/notation/functions/verticalbars_1.ma".
(* DEPTH FOR PATH ***********************************************************)
lemma depth_empty: š = āšā.
// qed.
-lemma depth_d (q) (n): āqā = āš±nāqā.
+lemma depth_d_sn (q) (n): āqā = āš±nāqā.
// qed.
-lemma depth_m (q): āqā = āšŗāqā.
+lemma depth_m_sn (q): āqā = āšŗāqā.
// qed.
-lemma depth_L (q): āāqā = āšāqā.
+lemma depth_L_sn (q): āāqā = āšāqā.
// qed.
-lemma depth_A (q): āqā = āšāqā.
+lemma depth_A_sn (q): āqā = āšāqā.
// qed.
-lemma depth_S (q): āqā = āš¦āqā.
+lemma depth_S_sn (q): āqā = āš¦āqā.
// qed.
+
+(* Advanced constructions with nplus ****************************************)
+
+lemma depth_plus (p1) (p2):
+ āp2ā+āp1ā = āp1āp2ā.
+#p1 elim p1 -p1 //
+* [ #n ] #p1 #IH #p2 <list_append_lcons_sn
+[ <depth_d_sn <depth_d_sn //
+| <depth_m_sn <depth_m_sn //
+| <depth_L_sn <depth_L_sn //
+| <depth_A_sn <depth_A_sn //
+| <depth_S_sn <depth_S_sn //
+]
+qed.
ā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 //
+[ <structure_L_sn <depth_L_sn <depth_L_sn //
+| <structure_A_sn <depth_A_sn <depth_A_sn //
+| <structure_S_sn <depth_S_sn <depth_S_sn //
]
qed.