1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "basic_2/syntax/lenv_length.ma".
16 include "basic_2/syntax/voids.ma".
18 (* EXTENSION OF A LOCAL ENVIRONMENT WITH EXCLUSION BINDERS ******************)
20 (* Properties with length for local environments ****************************)
22 lemma length_void: ∀L,n. n+|L| = |ⓧ*[n]L|.
24 #n #IH <voids_succ >length_bind <IH -IH //
27 lemma length_void_le: ∀L,n. |L| ≤ |ⓧ*[n]L|.
30 (* Main forward properties with length for local environments ***************)
32 theorem voids_inj_length: ∀n1,n2,L1,L2. ⓧ*[n1]L1 = ⓧ*[n2]L2 →
33 |L1| = |L2| → n1 = n2 ∧ L1 = L2.
35 [ * /2 width=1 by conj/ #n2 #L1 #L2 | #n1 #IH * [ | #n2 ] #L1 #L2 ]
36 [ <voids_zero #H destruct
37 <length_void <commutative_plus #H
38 elim (plus_xSy_x_false … H)
39 | <voids_zero #H destruct
40 <length_void <commutative_plus #H
41 elim (plus_xSy_x_false … (sym_eq … H))
42 | <voids_succ <voids_succ #H #HL12
43 elim (destruct_lbind_lbind_aux … H) -H (**) (* destruct lemma needed *)
44 #H #_ elim (IH … H HL12) -IH -H -HL12 /2 width=1 by conj/