]> matita.cs.unibo.it Git - helm.git/commitdiff
the previous commit was incomplete :(
authorFerruccio Guidi <ferruccio.guidi@unibo.it>
Thu, 30 Nov 2017 13:16:15 +0000 (13:16 +0000)
committerFerruccio Guidi <ferruccio.guidi@unibo.it>
Thu, 30 Nov 2017 13:16:15 +0000 (13:16 +0000)
matita/matita/contribs/lambdadelta/basic_2/notation/functions/voidstar_2.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/voids.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/syntax/voids_length.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/basic_2/web/basic_2_src.tbl

diff --git a/matita/matita/contribs/lambdadelta/basic_2/notation/functions/voidstar_2.ma b/matita/matita/contribs/lambdadelta/basic_2/notation/functions/voidstar_2.ma
new file mode 100644 (file)
index 0000000..4c95b41
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* NOTATION FOR THE FORMAL SYSTEM λδ ****************************************)
+
+notation "hvbox( ⓧ* [ term 46 n ] term 46 L )"
+   non associative with precedence 46
+   for @{ 'VoidStar $n $L }.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/voids.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/voids.ma
new file mode 100644 (file)
index 0000000..766eefd
--- /dev/null
@@ -0,0 +1,48 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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 "basic_2/notation/functions/voidstar_2.ma".
+include "basic_2/syntax/lenv.ma".
+
+(* EXTENSION OF A LOCAL ENVIRONMENT WITH EXCLUSION BINDERS ******************)
+
+rec definition voids (L:lenv) (n:nat) on n: lenv ≝ match n with
+[ O ⇒ L | S m ⇒ (voids L m).ⓧ ].
+
+interpretation "extension with exclusion binders (local environment)"
+   'VoidStar n L = (voids L n).
+
+(* Basic properties *********************************************************)
+
+lemma voids_zero: ∀L. L = ⓧ*[0]L.
+// qed.
+
+lemma voids_succ: ∀L,n. (ⓧ*[n]L).ⓧ = ⓧ*[⫯n]L.
+// qed.
+
+(* Advanced properties ******************************************************)
+
+lemma voids_next: ∀n,L. ⓧ*[n](L.ⓧ) = ⓧ*[⫯n]L.
+#n elim n -n //
+qed.
+
+(* Main inversion properties ************************************************)
+
+theorem voids_inj: ∀n. injective … (λL. ⓧ*[n]L).
+#n elim n -n //
+#n #IH #L1 #L2
+<voids_succ <voids_succ #H
+elim (destruct_lbind_lbind_aux … H) -H (**) (* destruct lemma needed *)
+/2 width=1 by/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/basic_2/syntax/voids_length.ma b/matita/matita/contribs/lambdadelta/basic_2/syntax/voids_length.ma
new file mode 100644 (file)
index 0000000..510a05f
--- /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 "basic_2/syntax/lenv_length.ma".
+include "basic_2/syntax/voids.ma".
+
+(* EXTENSION OF A LOCAL ENVIRONMENT WITH EXCLUSION BINDERS ******************)
+
+(* Properties with length for local environments ****************************)
+
+lemma length_void: ∀L,n. n+|L| = |ⓧ*[n]L|.
+#L #n elim n -n //
+#n #IH <voids_succ >length_bind <IH -IH //
+qed.
+
+(* Main forward properties with length for local environments ***************)
+
+theorem voids_inj_length: ∀n1,n2,L1,L2. ⓧ*[n1]L1 = ⓧ*[n2]L2 →
+                          |L1| = |L2| → n1 = n2 ∧ L1 = L2.
+#n1 elim n1 -n1
+[ * /2 width=1 by conj/ #n2 #L1 #L2 | #n1 #IH * [ | #n2 ] #L1 #L2 ]
+[ <voids_zero #H destruct
+  <length_void <commutative_plus #H
+  elim (plus_xSy_x_false … H)
+| <voids_zero #H destruct
+  <length_void <commutative_plus #H
+  elim (plus_xSy_x_false … (sym_eq … H))
+| <voids_succ <voids_succ #H #HL12
+  elim (destruct_lbind_lbind_aux … H) -H (**) (* destruct lemma needed *)
+  #H #_ elim (IH … H HL12) -IH -H -HL12 /2 width=1 by conj/
+]
+qed-.
index ff9f5ecf7f287ef8cb3ef0f319279c0876beda0d..4368142cb476779fc4b97d676daa16d1559d7eb5 100644 (file)
@@ -263,6 +263,7 @@ table {
         [ { "local environments" * } {
              [ [ "" ] "ceq_ext" "ceq_ext_ceq_ext" * ]
              [ [ "" ] "cext2" * ]
+             [ [ "" ] "lenv_voids ( ⓧ*[?]? )" * ]
              [ [ "" ] "lenv_length ( |?| )" * ]
              [ [ "" ] "lenv_weight ( ♯{?} )" * ]
              [ [ "" ] "lenv" * ]