(* Basic_2A1: was: length_inv_pos_dx_ltail *)
lemma length_inv_succ_dx_ltail: ∀L,n. |L| = ↑n →
(* Basic_2A1: was: length_inv_pos_dx_ltail *)
lemma length_inv_succ_dx_ltail: ∀L,n. |L| = ↑n →
-elim (lenv_case_tail … L) [2: * #K #J ]
-#H destruct /2 width=4 by ex2_2_intro/
+elim (lenv_case_tail … L) [| * #K #J ] #H destruct
+/2 width=4 by ex2_2_intro/
+@(ex2_2_intro … (J) (K.ⓘ[I])) // (**) (* auto fails *)
+>ltail_length >length_bind //
qed-.
(* Basic_2A1: was: length_inv_pos_sn_ltail *)
lemma length_inv_succ_sn_ltail: ∀L,n. ↑n = |L| →
qed-.
(* Basic_2A1: was: length_inv_pos_sn_ltail *)
lemma length_inv_succ_sn_ltail: ∀L,n. ↑n = |L| →
-elim (lenv_case_tail … L) [2: * #K #J ]
-#H destruct /2 width=4 by ex2_2_intro/
+elim (lenv_case_tail … L) [| * #K #J ] #H destruct
+/2 width=4 by ex2_2_intro/
+@(ex2_2_intro … (J) (K.ⓘ[I])) // (**) (* auto fails *)
+>ltail_length >length_bind //
qed-.
(* Inversion lemmas with length for local environments **********************)
(* Basic_2A1: was: append_inj_sn *)
lemma append_inj_length_sn: ∀K1,K2,L1,L2. L1 + K1 = L2 + K2 → |K1| = |K2| →
qed-.
(* Inversion lemmas with length for local environments **********************)
(* Basic_2A1: was: append_inj_sn *)
lemma append_inj_length_sn: ∀K1,K2,L1,L2. L1 + K1 = L2 + K2 → |K1| = |K2| →
elim (destruct_lbind_lbind_aux … H1) -H1 #H1 #H3 destruct (**) (* destruct lemma needed *)
elim (IH … H1) -IH -H1 /3 width=4 by conj/
]
elim (destruct_lbind_lbind_aux … H1) -H1 #H1 #H3 destruct (**) (* destruct lemma needed *)
elim (IH … H1) -IH -H1 /3 width=4 by conj/
]
(* Note: lemma 750 *)
(* Basic_2A1: was: append_inj_dx *)
lemma append_inj_length_dx: ∀K1,K2,L1,L2. L1 + K1 = L2 + K2 → |L1| = |L2| →
(* Note: lemma 750 *)
(* Basic_2A1: was: append_inj_dx *)
lemma append_inj_length_dx: ∀K1,K2,L1,L2. L1 + K1 = L2 + K2 → |L1| = |L2| →
| #K2 #I2 #L1 #L2 >append_bind >append_bind #H1 #H2
elim (destruct_lbind_lbind_aux … H1) -H1 #H1 #H3 destruct (**) (* destruct lemma needed *)
elim (IH … H1) -IH -H1 /2 width=1 by conj/
| #K2 #I2 #L1 #L2 >append_bind >append_bind #H1 #H2
elim (destruct_lbind_lbind_aux … H1) -H1 #H1 #H3 destruct (**) (* destruct lemma needed *)
elim (IH … H1) -IH -H1 /2 width=1 by conj/
-lemma append_inv_pair_dx: ∀I,L,K,V. L+K = L.ⓑ{I}V → K = ⋆.ⓑ{I}V.
-#I #L #K #V #H elim (append_inj_dx … (⋆.ⓑ{I}V) … H) //
+lemma append_inv_pair_dx: ∀I,L,K,V. L+K = L.ⓑ[I]V → K = ⋆.ⓑ[I]V.
+#I #L #K #V #H elim (append_inj_dx … (⋆.ⓑ[I]V) … H) //
(* Basic_1: was: c_tail_ind *)
(* Basic_2A1: was: lenv_ind_alt *)
lemma lenv_ind_tail: ∀Q:predicate lenv.
(* Basic_1: was: c_tail_ind *)
(* Basic_2A1: was: lenv_ind_alt *)
lemma lenv_ind_tail: ∀Q:predicate lenv.
- Q (⋆) → (∀I,L. Q L → Q (ⓘ{I}.L)) → ∀L. Q L.
-#Q #IH1 #IH2 #L @(f_ind … length … L) -L #x #IHx * //
+ Q (⋆) → (∀I,L. Q L → Q (ⓘ[I].L)) → ∀L. Q L.
+#Q #IH1 #IH2 #L @(wf1_ind_nlt … length … L) -L #x #IHx * //