X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;ds=sidebyside;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fground%2Flib%2Flist_eq.ma;h=a245308908e22e08ccaa6bfe376eec3d5804e188;hb=8fdf1af656038d0245eba64ff2531bbe94ce0e9e;hp=6f89d187f16bc09ec3f438eac960a7b9bb885dba;hpb=68b4f2490c12139c03760b39895619e63b0f38c9;p=helm.git diff --git a/matita/matita/contribs/lambdadelta/ground/lib/list_eq.ma b/matita/matita/contribs/lambdadelta/ground/lib/list_eq.ma index 6f89d187f..a24530890 100644 --- a/matita/matita/contribs/lambdadelta/ground/lib/list_eq.ma +++ b/matita/matita/contribs/lambdadelta/ground/lib/list_eq.ma @@ -15,39 +15,40 @@ include "ground/notation/relations/ringeq_3.ma". include "ground/lib/list.ma". -(* EXTENSIONAL EQUIVALENCE OF LISTS *****************************************) +(* EXTENSIONAL EQUIVALENCE FOR LISTS ****************************************) -rec definition eq_list A (l1,l2:list A) on l1 ≝ +rec definition list_eq A (l1,l2:list A) on l1 ≝ match l1 with -[ nil ⇒ +[ list_nil ⇒ match l2 with - [ nil ⇒ ⊤ - | cons _ _ ⇒ ⊥ + [ list_nil ⇒ ⊤ + | list_cons _ _ ⇒ ⊥ ] -| cons a1 l1 ⇒ +| list_cons a1 l1 ⇒ match l2 with - [ nil ⇒ ⊥ - | cons a2 l2 ⇒ a1 = a2 ∧ eq_list A l1 l2 + [ list_nil ⇒ ⊥ + | list_cons a2 l2 ⇒ a1 = a2 ∧ list_eq A l1 l2 ] ]. -interpretation "extensional equivalence (list)" - 'RingEq A l1 l2 = (eq_list A l1 l2). +interpretation + "extensional equivalence (lists)" + 'RingEq A l1 l2 = (list_eq A l1 l2). -(* Basic properties *********************************************************) +(* Basic constructions ******************************************************) -lemma eq_list_refl (A): reflexive … (eq_list A). +lemma list_eq_refl (A): reflexive … (list_eq A). #A #l elim l -l /2 width=1 by conj/ qed. -(* Main properties **********************************************************) +(* Main constructions *******************************************************) -theorem eq_eq_list (A,l1,l2): l1 = l2 → l1 ≗{A} l2. +theorem eq_list_eq (A,l1,l2): l1 = l2 → l1 ≗{A} l2. // qed. -(* Main inversion propertiess ***********************************************) +(* Main inversions **********************************************************) -theorem eq_list_inv_eq (A,l1,l2): l1 ≗{A} l2 → l1 = l2. +theorem list_eq_inv_eq (A,l1,l2): l1 ≗{A} l2 → l1 = l2. #A #l1 elim l1 -l1 [| #a1 #l1 #IH ] * [ // | #a2 #l2 #H elim H