]> matita.cs.unibo.it Git - helm.git/commitdiff
update in delayed_updating
authorFerruccio Guidi <ferruccio.guidi@unibo.it>
Mon, 10 Jan 2022 15:49:52 +0000 (16:49 +0100)
committerFerruccio Guidi <ferruccio.guidi@unibo.it>
Mon, 10 Jan 2022 15:49:52 +0000 (16:49 +0100)
+ proper condition for path
+ relation between lift and append proved

matita/matita/contribs/lambdadelta/delayed_updating/etc/path_proper.etc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/delayed_updating/substitution/lift_structure.ma
matita/matita/contribs/lambdadelta/delayed_updating/syntax/path_proper.ma [new file with mode: 0644]

diff --git a/matita/matita/contribs/lambdadelta/delayed_updating/etc/path_proper.etc b/matita/matita/contribs/lambdadelta/delayed_updating/etc/path_proper.etc
new file mode 100644 (file)
index 0000000..d5287e5
--- /dev/null
@@ -0,0 +1,17 @@
+(* Constructions with path_append *******************************************)
+
+lemma ppc_append_sn (p2) (p1): Ꝕp2 → Ꝕ(p1●p2).
+#p2 * /2 width=3 by ppc_lcons/
+qed.
+
+lemma ppc_append_dx (p1) (p2): Ꝕp1 → Ꝕ(p1●p2).
+#p1 #p2 #Hp1
+elim (ppc_inv_lcons … Hp1) -Hp1 #l #q1 #H destruct
+/2 width=3 by ppc_lcons/
+qed.
+
+(* Constructions with path_rcons ********************************************)
+
+lemma ppc_rcons (q) (l): Ꝕ(q◖l).
+/2 width=1 by ppc_lcons, ppc_append_sn/
+qed.
index d18f72b52d1c152285d8643c05b3a7eac40d93e2..961a5c435ef8b0f3d2cbd106a5bc80279ccf85db 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "delayed_updating/syntax/path_structure.ma".
 include "delayed_updating/substitution/lift_eq.ma".
+include "delayed_updating/syntax/path_structure.ma".
+include "delayed_updating/syntax/path_proper.ma".
 
 (* LIFT FOR PATH ***********************************************************)
 
-(* Constructions with structure ********************************************)
+(* Basic constructions with structure **************************************)
+
+lemma structure_lift (p) (f):
+      ⊗p = ⊗↑[f]p.
+#p @(path_ind_lift … p) -p // #p #IH #f
+<lift_path_L_sn //
+qed.
+
+lemma lift_structure (p) (f):
+      ⊗p = ↑[f]⊗p.
+#p @(path_ind_lift … p) -p //
+qed.
+
+(* Properties with proper condition for path ********************************)
+
+lemma lift_append_proper_dx (p2) (p1) (f): Ꝕp2 →
+      (⊗p1)●(↑[↑[p1]f]p2) = ↑[f](p1●p2).
+#p2 #p1 @(path_ind_lift … p1) -p1 //
+[ #n | #n #l #p1 |*: #p1 ] #IH #f #Hp2
+[ elim (ppc_inv_lcons … Hp2) -Hp2 #l #q #H destruct //
+| <lift_path_d_lcons_sn <IH //
+| <lift_path_L_sn <IH //
+| <lift_path_A_sn <IH //
+| <lift_path_S_sn <IH //
+]
+qed-.
+
+(* Advanced constructions with structure ************************************)
 
 lemma lift_d_empty_dx (n) (p) (f):
       (⊗p)◖𝗱((↑[p]f)@❨n❩) = ↑[f](p◖𝗱n).
-#n #p @(path_ind_lift … p) -p // [ #m #l #p |*: #p ] #IH #f
-[ <lift_rmap_d_sn <lift_path_d_lcons_sn //
-| <lift_rmap_L_sn <lift_path_L_sn <IH //
-| <lift_rmap_A_sn <lift_path_A_sn <IH //
-| <lift_rmap_S_sn <lift_path_S_sn <IH //
-]
+/3 width=3 by ppc_lcons, lift_append_proper_dx/
 qed.
 
 lemma lift_L_dx (p) (f):
       (⊗p)◖𝗟 = ↑[f](p◖𝗟).
-#p @(path_ind_lift … p) -p // #m #l #p #IH #f
-<lift_path_d_lcons_sn //
+/3 width=3 by ppc_lcons, lift_append_proper_dx/
 qed.
 
 lemma lift_A_dx (p) (f):
       (⊗p)◖𝗔 = ↑[f](p◖𝗔).
-#p @(path_ind_lift … p) -p // #m #l #p #IH #f
-<lift_path_d_lcons_sn //
+/3 width=3 by ppc_lcons, lift_append_proper_dx/
 qed.
 
 lemma lift_S_dx (p) (f):
       (⊗p)◖𝗦 = ↑[f](p◖𝗦).
-#p @(path_ind_lift … p) -p // #m #l #p #IH #f
-<lift_path_d_lcons_sn //
-qed.
-
-lemma structure_lift (p) (f):
-      ⊗p = ⊗↑[f]p.
-#p @(path_ind_lift … p) -p // #p #IH #f
-<lift_path_L_sn //
-qed.
-
-lemma lift_structure (p) (f):
-      ⊗p = ↑[f]⊗p.
-#p @(path_ind_lift … p) -p //
+/3 width=3 by ppc_lcons, lift_append_proper_dx/
 qed.
diff --git a/matita/matita/contribs/lambdadelta/delayed_updating/syntax/path_proper.ma b/matita/matita/contribs/lambdadelta/delayed_updating/syntax/path_proper.ma
new file mode 100644 (file)
index 0000000..e519394
--- /dev/null
@@ -0,0 +1,43 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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.ma".
+include "delayed_updating/notation/relations/predicate_p_tail_1.ma".
+include "ground/xoa/ex_1_2.ma".
+
+(* PROPER CONDITION FOR PATH ************************************************)
+
+definition ppc: predicate path ≝
+           λp. 𝐞 = p → ⊥
+.
+
+interpretation
+  "proper condition (path)"
+  'PredicatePTail p = (ppc p).
+
+(* Basic constructions ******************************************************)
+
+lemma ppc_lcons (l) (q): Ꝕ(l◗q).
+#l #p #H destruct
+qed.
+
+(* Basic inversions ********************************************************)
+
+lemma ppc_inv_lcons (p):
+      Ꝕp → ∃∃l,q. l◗q = p.
+*
+[ #H elim H -H //
+| #l #q #_ /2 width=3 by ex1_2_intro/
+]
+qed-.