T).(clt (CHead c k t) (CHead d k t))))))
\def
\lambda (c: C).(\lambda (d: C).(\lambda (H: (lt (cweight c) (cweight
-d))).(\lambda (_: K).(\lambda (t: T).(lt_le_S (plus (cweight c) (tweight t))
-(plus (cweight d) (tweight t)) (plus_lt_compat_r (cweight c) (cweight d)
-(tweight t) H)))))).
+d))).(\lambda (_: K).(\lambda (t: T).(plus_lt_compat_r (cweight c) (cweight
+d) (tweight t) H))))).
theorem clt_head:
\forall (k: K).(\forall (c: C).(\forall (u: T).(clt c (CHead c k u))))
\def
\lambda (_: K).(\lambda (c: C).(\lambda (u: T).(eq_ind_r nat (plus (cweight
-c) O) (\lambda (n: nat).(lt n (plus (cweight c) (tweight u)))) (lt_le_S (plus
-(cweight c) O) (plus (cweight c) (tweight u)) (plus_le_lt_compat (cweight c)
-(cweight c) O (tweight u) (le_n (cweight c)) (tweight_lt u))) (cweight c)
-(plus_n_O (cweight c))))).
+c) O) (\lambda (n: nat).(lt n (plus (cweight c) (tweight u))))
+(plus_le_lt_compat (cweight c) (cweight c) O (tweight u) (le_n (cweight c))
+(tweight_lt u)) (cweight c) (plus_n_O (cweight c))))).
theorem clt_wf__q_ind:
\forall (P: ((C \to Prop))).(((\forall (n: nat).((\lambda (P0: ((C \to
(h2: nat).(\lambda (H: (eq A (aplus g a1 h1) (aplus g a2 h2))).(\lambda (h:
nat).(nat_ind (\lambda (n: nat).(eq A (aplus g a1 (plus n h1)) (aplus g a2
(plus n h2)))) H (\lambda (n: nat).(\lambda (H0: (eq A (aplus g a1 (plus n
-h1)) (aplus g a2 (plus n h2)))).(sym_eq A (asucc g (aplus g a2 (plus n h2)))
-(asucc g (aplus g a1 (plus n h1))) (sym_eq A (asucc g (aplus g a1 (plus n
-h1))) (asucc g (aplus g a2 (plus n h2))) (sym_eq A (asucc g (aplus g a2 (plus
-n h2))) (asucc g (aplus g a1 (plus n h1))) (f_equal2 G A A asucc g g (aplus g
-a2 (plus n h2)) (aplus g a1 (plus n h1)) (refl_equal G g) (sym_eq A (aplus g
-a1 (plus n h1)) (aplus g a2 (plus n h2)) H0))))))) h))))))).
+h1)) (aplus g a2 (plus n h2)))).(f_equal2 G A A asucc g g (aplus g a1 (plus n
+h1)) (aplus g a2 (plus n h2)) (refl_equal G g) H0))) h))))))).
theorem aplus_assoc:
\forall (g: G).(\forall (a: A).(\forall (h1: nat).(\forall (h2: nat).(eq A
n)) (\lambda (n0: nat).(\lambda (H0: (eq A (aplus g (asucc g (aplus g a n))
n0) (asucc g (aplus g a (plus n n0))))).(eq_ind nat (S (plus n n0)) (\lambda
(n1: nat).(eq A (asucc g (aplus g (asucc g (aplus g a n)) n0)) (asucc g
-(aplus g a n1)))) (sym_eq A (asucc g (asucc g (aplus g a (plus n n0))))
-(asucc g (aplus g (asucc g (aplus g a n)) n0)) (sym_eq A (asucc g (aplus g
-(asucc g (aplus g a n)) n0)) (asucc g (asucc g (aplus g a (plus n n0))))
-(sym_eq A (asucc g (asucc g (aplus g a (plus n n0)))) (asucc g (aplus g
-(asucc g (aplus g a n)) n0)) (f_equal2 G A A asucc g g (asucc g (aplus g a
-(plus n n0))) (aplus g (asucc g (aplus g a n)) n0) (refl_equal G g) (sym_eq A
-(aplus g (asucc g (aplus g a n)) n0) (asucc g (aplus g a (plus n n0)))
-H0))))) (plus n (S n0)) (plus_n_Sm n n0)))) h2)))) h1))).
+(aplus g a n1)))) (f_equal2 G A A asucc g g (aplus g (asucc g (aplus g a n))
+n0) (asucc g (aplus g a (plus n n0))) (refl_equal G g) H0) (plus n (S n0))
+(plus_n_Sm n n0)))) h2)))) h1))).
theorem aplus_asucc:
\forall (g: G).(\forall (h: nat).(\forall (a: A).(eq A (aplus g (asucc g a)
(CHead c (Bind b) t) (\lambda (c0: C).(le (cweight c0) (plus (cweight c)
(tweight t)))) (le_n (plus (cweight c) (tweight t))) c2 (clear_gen_bind b c
c2 t H1)))) (\lambda (f: F).(\lambda (H1: (clear (CHead c (Flat f) t)
-c2)).(le_S_n (cweight c2) (plus (cweight c) (tweight t)) (le_n_S (cweight c2)
-(plus (cweight c) (tweight t)) (le_plus_trans (cweight c2) (cweight c)
-(tweight t) (H c2 (clear_gen_flat f c c2 t H1))))))) k H0))))))) c1).
+c2)).(le_plus_trans (cweight c2) (cweight c) (tweight t) (H c2
+(clear_gen_flat f c c2 t H1))))) k H0))))))) c1).
(t0: T).(\lambda (t3: T).(\lambda (H0: (pr2 c1 t0 t3)).(\lambda (t4:
T).(\lambda (_: (pc3 c1 t3 t4)).(\lambda (H2: ((\forall (c2: C).((csubt g c1
c2) \to (pc3 c2 t3 t4))))).(\lambda (c2: C).(\lambda (H3: (csubt g c1
-c2)).(pc3_pr2_u c2 t3 t0 (csubt_pr2 g c1 t0 t3 H0 c2 H3) t4 (H2 c2
-H3)))))))))) (\lambda (t0: T).(\lambda (t3: T).(\lambda (H0: (pr2 c1 t0
-t3)).(\lambda (t4: T).(\lambda (_: (pc3 c1 t0 t4)).(\lambda (H2: ((\forall
+c2)).(pc3_t t3 c2 t0 (pc3_pr2_r c2 t0 t3 (csubt_pr2 g c1 t0 t3 H0 c2 H3)) t4
+(H2 c2 H3)))))))))) (\lambda (t0: T).(\lambda (t3: T).(\lambda (H0: (pr2 c1
+t0 t3)).(\lambda (t4: T).(\lambda (_: (pc3 c1 t0 t4)).(\lambda (H2: ((\forall
(c2: C).((csubt g c1 c2) \to (pc3 c2 t0 t4))))).(\lambda (c2: C).(\lambda
(H3: (csubt g c1 c2)).(pc3_t t0 c2 t3 (pc3_pr2_x c2 t3 t0 (csubt_pr2 g c1 t0
t3 H0 c2 H3)) t4 (H2 c2 H3)))))))))) t1 t2 H))))).
include "aprem/defs.ma".
-include "gz/defs.ma".
+include "ex0/defs.ma".
include "wcpr0/defs.ma".
(CHead x4 k t0)) \to (\forall (x6: C).((drop h0 n (CHead c0 k (lift h (r k n)
t0)) x6) \to (eq C (CHead x4 k t0) x6)))))) H10 x3 (lift_inj x5 x3 h (r k n)
H11)) in (eq_ind_r T x3 (\lambda (t0: T).(eq C (CHead x4 k t0) (CHead x0 k
-x3))) (sym_eq C (CHead x0 k x3) (CHead x4 k x3) (sym_eq C (CHead x4 k x3)
-(CHead x0 k x3) (sym_eq C (CHead x0 k x3) (CHead x4 k x3) (f_equal3 C K T C
-CHead x0 x4 k k x3 x3 (H x0 (r k n) h H5 x4 H8) (refl_equal K k) (refl_equal
-T x3))))) x5 (lift_inj x5 x3 h (r k n) H11))))) x1 H6)) x2 H3))))))
-(drop_gen_skip_l c0 x1 t h n k H1))))))) (drop_gen_skip_l c0 x2 t h n k
-H2)))))))) d))))))) c).
+x3))) (f_equal3 C K T C CHead x4 x0 k k x3 x3 (sym_eq C x0 x4 (H x0 (r k n) h
+H5 x4 H8)) (refl_equal K k) (refl_equal T x3)) x5 (lift_inj x5 x3 h (r k n)
+H11))))) x1 H6)) x2 H3)))))) (drop_gen_skip_l c0 x1 t h n k H1)))))))
+(drop_gen_skip_l c0 x2 t h n k H2)))))))) d))))))) c).
theorem drop_conf_lt:
\forall (k: K).(\forall (i: nat).(\forall (u: T).(\forall (c0: C).(\forall
i))) (ptrans hds0 i)) v))))) (\lambda (x: C).(\lambda (H18: (drop1 (ptrans
hds0 i) x e1)).(\lambda (H19: (getl (trans hds0 i) c3 (CHead x (Bind b)
(lift1 (ptrans hds0 i) v)))).(let H_x0 \def (drop_getl_trans_lt (trans hds0
-i) d (le_S_n (S (trans hds0 i)) d (lt_le_S (S (trans hds0 i)) (S d) (blt_lt
-(S d) (S (trans hds0 i)) H16))) c2 c3 h H14 b x (lift1 (ptrans hds0 i) v)
+i) d (blt_lt d (trans hds0 i) H16) c2 c3 h H14 b x (lift1 (ptrans hds0 i) v)
H19) in (let H20 \def H_x0 in (ex2_ind C (\lambda (e2: C).(getl (trans hds0
i) c2 (CHead e2 (Bind b) (lift h (minus d (S (trans hds0 i))) (lift1 (ptrans
hds0 i) v))))) (\lambda (e2: C).(drop h (minus d (S (trans hds0 i))) e2 x))
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||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 *)
+(* *)
+(**************************************************************************)
+
+(* This file was automatically generated: do not edit *********************)
+
+set "baseuri" "cic:/matita/LAMBDA-TYPES/LambdaDelta-1/ex0/defs".
+
+include "A/defs.ma".
+
+include "G/defs.ma".
+
+definition gz:
+ G
+\def
+ mk_G S lt_n_Sn.
+
+inductive leqz: A \to (A \to Prop) \def
+| leqz_sort: \forall (h1: nat).(\forall (h2: nat).(\forall (n1: nat).(\forall
+(n2: nat).((eq nat (plus h1 n2) (plus h2 n1)) \to (leqz (ASort h1 n1) (ASort
+h2 n2))))))
+| leqz_head: \forall (a1: A).(\forall (a2: A).((leqz a1 a2) \to (\forall (a3:
+A).(\forall (a4: A).((leqz a3 a4) \to (leqz (AHead a1 a3) (AHead a2 a4))))))).
+
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||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 *)
+(* *)
+(**************************************************************************)
+
+(* This file was automatically generated: do not edit *********************)
+
+set "baseuri" "cic:/matita/LAMBDA-TYPES/LambdaDelta-1/ex0/props".
+
+include "ex0/defs.ma".
+
+include "leq/defs.ma".
+
+include "aplus/props.ma".
+
+theorem aplus_gz_le:
+ \forall (k: nat).(\forall (h: nat).(\forall (n: nat).((le h k) \to (eq A
+(aplus gz (ASort h n) k) (ASort O (plus (minus k h) n))))))
+\def
+ \lambda (k: nat).(nat_ind (\lambda (n: nat).(\forall (h: nat).(\forall (n0:
+nat).((le h n) \to (eq A (aplus gz (ASort h n0) n) (ASort O (plus (minus n h)
+n0))))))) (\lambda (h: nat).(\lambda (n: nat).(\lambda (H: (le h O)).(let H_y
+\def (le_n_O_eq h H) in (eq_ind nat O (\lambda (n0: nat).(eq A (ASort n0 n)
+(ASort O n))) (refl_equal A (ASort O n)) h H_y))))) (\lambda (k0:
+nat).(\lambda (IH: ((\forall (h: nat).(\forall (n: nat).((le h k0) \to (eq A
+(aplus gz (ASort h n) k0) (ASort O (plus (minus k0 h) n)))))))).(\lambda (h:
+nat).(nat_ind (\lambda (n: nat).(\forall (n0: nat).((le n (S k0)) \to (eq A
+(asucc gz (aplus gz (ASort n n0) k0)) (ASort O (plus (match n with [O
+\Rightarrow (S k0) | (S l) \Rightarrow (minus k0 l)]) n0)))))) (\lambda (n:
+nat).(\lambda (_: (le O (S k0))).(eq_ind A (aplus gz (asucc gz (ASort O n))
+k0) (\lambda (a: A).(eq A a (ASort O (S (plus k0 n))))) (eq_ind_r A (ASort O
+(plus (minus k0 O) (S n))) (\lambda (a: A).(eq A a (ASort O (S (plus k0
+n))))) (eq_ind nat k0 (\lambda (n0: nat).(eq A (ASort O (plus n0 (S n)))
+(ASort O (S (plus k0 n))))) (eq_ind nat (S (plus k0 n)) (\lambda (n0:
+nat).(eq A (ASort O n0) (ASort O (S (plus k0 n))))) (refl_equal A (ASort O (S
+(plus k0 n)))) (plus k0 (S n)) (plus_n_Sm k0 n)) (minus k0 O) (minus_n_O k0))
+(aplus gz (ASort O (S n)) k0) (IH O (S n) (le_O_n k0))) (asucc gz (aplus gz
+(ASort O n) k0)) (aplus_asucc gz k0 (ASort O n))))) (\lambda (n:
+nat).(\lambda (_: ((\forall (n0: nat).((le n (S k0)) \to (eq A (asucc gz
+(aplus gz (ASort n n0) k0)) (ASort O (plus (match n with [O \Rightarrow (S
+k0) | (S l) \Rightarrow (minus k0 l)]) n0))))))).(\lambda (n0: nat).(\lambda
+(H0: (le (S n) (S k0))).(ex2_ind nat (\lambda (n1: nat).(eq nat (S k0) (S
+n1))) (\lambda (n1: nat).(le n n1)) (eq A (asucc gz (aplus gz (ASort (S n)
+n0) k0)) (ASort O (plus (minus k0 n) n0))) (\lambda (x: nat).(\lambda (H1:
+(eq nat (S k0) (S x))).(\lambda (H2: (le n x)).(let H3 \def (f_equal nat nat
+(\lambda (e: nat).(match e in nat return (\lambda (_: nat).nat) with [O
+\Rightarrow k0 | (S n1) \Rightarrow n1])) (S k0) (S x) H1) in (let H4 \def
+(eq_ind_r nat x (\lambda (n1: nat).(le n n1)) H2 k0 H3) in (eq_ind A (aplus
+gz (ASort n n0) k0) (\lambda (a: A).(eq A (asucc gz (aplus gz (ASort (S n)
+n0) k0)) a)) (eq_ind A (aplus gz (asucc gz (ASort (S n) n0)) k0) (\lambda (a:
+A).(eq A a (aplus gz (ASort n n0) k0))) (refl_equal A (aplus gz (ASort n n0)
+k0)) (asucc gz (aplus gz (ASort (S n) n0) k0)) (aplus_asucc gz k0 (ASort (S
+n) n0))) (ASort O (plus (minus k0 n) n0)) (IH n n0 H4))))))) (le_gen_S n (S
+k0) H0)))))) h)))) k).
+
+theorem aplus_gz_ge:
+ \forall (n: nat).(\forall (k: nat).(\forall (h: nat).((le k h) \to (eq A
+(aplus gz (ASort h n) k) (ASort (minus h k) n)))))
+\def
+ \lambda (n: nat).(\lambda (k: nat).(nat_ind (\lambda (n0: nat).(\forall (h:
+nat).((le n0 h) \to (eq A (aplus gz (ASort h n) n0) (ASort (minus h n0)
+n))))) (\lambda (h: nat).(\lambda (_: (le O h)).(eq_ind nat h (\lambda (n0:
+nat).(eq A (ASort h n) (ASort n0 n))) (refl_equal A (ASort h n)) (minus h O)
+(minus_n_O h)))) (\lambda (k0: nat).(\lambda (IH: ((\forall (h: nat).((le k0
+h) \to (eq A (aplus gz (ASort h n) k0) (ASort (minus h k0) n)))))).(\lambda
+(h: nat).(nat_ind (\lambda (n0: nat).((le (S k0) n0) \to (eq A (asucc gz
+(aplus gz (ASort n0 n) k0)) (ASort (minus n0 (S k0)) n)))) (\lambda (H: (le
+(S k0) O)).(ex2_ind nat (\lambda (n0: nat).(eq nat O (S n0))) (\lambda (n0:
+nat).(le k0 n0)) (eq A (asucc gz (aplus gz (ASort O n) k0)) (ASort O n))
+(\lambda (x: nat).(\lambda (H0: (eq nat O (S x))).(\lambda (_: (le k0
+x)).(let H2 \def (eq_ind nat O (\lambda (ee: nat).(match ee in nat return
+(\lambda (_: nat).Prop) with [O \Rightarrow True | (S _) \Rightarrow False]))
+I (S x) H0) in (False_ind (eq A (asucc gz (aplus gz (ASort O n) k0)) (ASort O
+n)) H2))))) (le_gen_S k0 O H))) (\lambda (n0: nat).(\lambda (_: (((le (S k0)
+n0) \to (eq A (asucc gz (aplus gz (ASort n0 n) k0)) (ASort (minus n0 (S k0))
+n))))).(\lambda (H0: (le (S k0) (S n0))).(ex2_ind nat (\lambda (n1: nat).(eq
+nat (S n0) (S n1))) (\lambda (n1: nat).(le k0 n1)) (eq A (asucc gz (aplus gz
+(ASort (S n0) n) k0)) (ASort (minus n0 k0) n)) (\lambda (x: nat).(\lambda
+(H1: (eq nat (S n0) (S x))).(\lambda (H2: (le k0 x)).(let H3 \def (f_equal
+nat nat (\lambda (e: nat).(match e in nat return (\lambda (_: nat).nat) with
+[O \Rightarrow n0 | (S n1) \Rightarrow n1])) (S n0) (S x) H1) in (let H4 \def
+(eq_ind_r nat x (\lambda (n1: nat).(le k0 n1)) H2 n0 H3) in (eq_ind A (aplus
+gz (ASort n0 n) k0) (\lambda (a: A).(eq A (asucc gz (aplus gz (ASort (S n0)
+n) k0)) a)) (eq_ind A (aplus gz (asucc gz (ASort (S n0) n)) k0) (\lambda (a:
+A).(eq A a (aplus gz (ASort n0 n) k0))) (refl_equal A (aplus gz (ASort n0 n)
+k0)) (asucc gz (aplus gz (ASort (S n0) n) k0)) (aplus_asucc gz k0 (ASort (S
+n0) n))) (ASort (minus n0 k0) n) (IH n0 H4))))))) (le_gen_S k0 (S n0) H0)))))
+h)))) k)).
+
+theorem next_plus_gz:
+ \forall (n: nat).(\forall (h: nat).(eq nat (next_plus gz n h) (plus h n)))
+\def
+ \lambda (n: nat).(\lambda (h: nat).(nat_ind (\lambda (n0: nat).(eq nat
+(next_plus gz n n0) (plus n0 n))) (refl_equal nat n) (\lambda (n0:
+nat).(\lambda (H: (eq nat (next_plus gz n n0) (plus n0 n))).(f_equal nat nat
+S (next_plus gz n n0) (plus n0 n) H))) h)).
+
+theorem leqz_leq:
+ \forall (a1: A).(\forall (a2: A).((leq gz a1 a2) \to (leqz a1 a2)))
+\def
+ \lambda (a1: A).(\lambda (a2: A).(\lambda (H: (leq gz a1 a2)).(leq_ind gz
+(\lambda (a: A).(\lambda (a0: A).(leqz a a0))) (\lambda (h1: nat).(\lambda
+(h2: nat).(\lambda (n1: nat).(\lambda (n2: nat).(\lambda (k: nat).(\lambda
+(H0: (eq A (aplus gz (ASort h1 n1) k) (aplus gz (ASort h2 n2) k))).(lt_le_e k
+h1 (leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H1: (lt k h1)).(lt_le_e k h2
+(leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H2: (lt k h2)).(let H3 \def
+(eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a (aplus gz (ASort
+h2 n2) k))) H0 (ASort (minus h1 k) n1) (aplus_gz_ge n1 k h1 (le_S_n k h1
+(le_S (S k) h1 H1)))) in (let H4 \def (eq_ind A (aplus gz (ASort h2 n2) k)
+(\lambda (a: A).(eq A (ASort (minus h1 k) n1) a)) H3 (ASort (minus h2 k) n2)
+(aplus_gz_ge n2 k h2 (le_S_n k h2 (le_S (S k) h2 H2)))) in (let H5 \def
+(f_equal A nat (\lambda (e: A).(match e in A return (\lambda (_: A).nat) with
+[(ASort n _) \Rightarrow n | (AHead _ _) \Rightarrow ((let rec minus (n: nat)
+on n: (nat \to nat) \def (\lambda (m: nat).(match n with [O \Rightarrow O |
+(S k0) \Rightarrow (match m with [O \Rightarrow (S k0) | (S l) \Rightarrow
+(minus k0 l)])])) in minus) h1 k)])) (ASort (minus h1 k) n1) (ASort (minus h2
+k) n2) H4) in ((let H6 \def (f_equal A nat (\lambda (e: A).(match e in A
+return (\lambda (_: A).nat) with [(ASort _ n) \Rightarrow n | (AHead _ _)
+\Rightarrow n1])) (ASort (minus h1 k) n1) (ASort (minus h2 k) n2) H4) in
+(\lambda (H7: (eq nat (minus h1 k) (minus h2 k))).(eq_ind nat n1 (\lambda (n:
+nat).(leqz (ASort h1 n1) (ASort h2 n))) (eq_ind nat h1 (\lambda (n:
+nat).(leqz (ASort h1 n1) (ASort n n1))) (leqz_sort h1 h1 n1 n1 (refl_equal
+nat (plus h1 n1))) h2 (minus_minus k h1 h2 (le_S_n k h1 (le_S (S k) h1 H1))
+(le_S_n k h2 (le_S (S k) h2 H2)) H7)) n2 H6))) H5))))) (\lambda (H2: (le h2
+k)).(let H3 \def (eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a
+(aplus gz (ASort h2 n2) k))) H0 (ASort (minus h1 k) n1) (aplus_gz_ge n1 k h1
+(le_S_n k h1 (le_S (S k) h1 H1)))) in (let H4 \def (eq_ind A (aplus gz (ASort
+h2 n2) k) (\lambda (a: A).(eq A (ASort (minus h1 k) n1) a)) H3 (ASort O (plus
+(minus k h2) n2)) (aplus_gz_le k h2 n2 H2)) in (let H5 \def (eq_ind nat
+(minus h1 k) (\lambda (n: nat).(eq A (ASort n n1) (ASort O (plus (minus k h2)
+n2)))) H4 (S (minus h1 (S k))) (minus_x_Sy h1 k H1)) in (let H6 \def (eq_ind
+A (ASort (S (minus h1 (S k))) n1) (\lambda (ee: A).(match ee in A return
+(\lambda (_: A).Prop) with [(ASort n _) \Rightarrow (match n in nat return
+(\lambda (_: nat).Prop) with [O \Rightarrow False | (S _) \Rightarrow True])
+| (AHead _ _) \Rightarrow False])) I (ASort O (plus (minus k h2) n2)) H5) in
+(False_ind (leqz (ASort h1 n1) (ASort h2 n2)) H6)))))))) (\lambda (H1: (le h1
+k)).(lt_le_e k h2 (leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H2: (lt k
+h2)).(let H3 \def (eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A
+a (aplus gz (ASort h2 n2) k))) H0 (ASort O (plus (minus k h1) n1))
+(aplus_gz_le k h1 n1 H1)) in (let H4 \def (eq_ind A (aplus gz (ASort h2 n2)
+k) (\lambda (a: A).(eq A (ASort O (plus (minus k h1) n1)) a)) H3 (ASort
+(minus h2 k) n2) (aplus_gz_ge n2 k h2 (le_S_n k h2 (le_S (S k) h2 H2)))) in
+(let H5 \def (sym_eq A (ASort O (plus (minus k h1) n1)) (ASort (minus h2 k)
+n2) H4) in (let H6 \def (eq_ind nat (minus h2 k) (\lambda (n: nat).(eq A
+(ASort n n2) (ASort O (plus (minus k h1) n1)))) H5 (S (minus h2 (S k)))
+(minus_x_Sy h2 k H2)) in (let H7 \def (eq_ind A (ASort (S (minus h2 (S k)))
+n2) (\lambda (ee: A).(match ee in A return (\lambda (_: A).Prop) with [(ASort
+n _) \Rightarrow (match n in nat return (\lambda (_: nat).Prop) with [O
+\Rightarrow False | (S _) \Rightarrow True]) | (AHead _ _) \Rightarrow
+False])) I (ASort O (plus (minus k h1) n1)) H6) in (False_ind (leqz (ASort h1
+n1) (ASort h2 n2)) H7))))))) (\lambda (H2: (le h2 k)).(let H3 \def (eq_ind A
+(aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a (aplus gz (ASort h2 n2)
+k))) H0 (ASort O (plus (minus k h1) n1)) (aplus_gz_le k h1 n1 H1)) in (let H4
+\def (eq_ind A (aplus gz (ASort h2 n2) k) (\lambda (a: A).(eq A (ASort O
+(plus (minus k h1) n1)) a)) H3 (ASort O (plus (minus k h2) n2)) (aplus_gz_le
+k h2 n2 H2)) in (let H5 \def (f_equal A nat (\lambda (e: A).(match e in A
+return (\lambda (_: A).nat) with [(ASort _ n) \Rightarrow n | (AHead _ _)
+\Rightarrow ((let rec plus (n: nat) on n: (nat \to nat) \def (\lambda (m:
+nat).(match n with [O \Rightarrow m | (S p) \Rightarrow (S (plus p m))])) in
+plus) (minus k h1) n1)])) (ASort O (plus (minus k h1) n1)) (ASort O (plus
+(minus k h2) n2)) H4) in (let H_y \def (plus_plus k h1 h2 n1 n2 H1 H2 H5) in
+(leqz_sort h1 h2 n1 n2 H_y))))))))))))))) (\lambda (a0: A).(\lambda (a3:
+A).(\lambda (_: (leq gz a0 a3)).(\lambda (H1: (leqz a0 a3)).(\lambda (a4:
+A).(\lambda (a5: A).(\lambda (_: (leq gz a4 a5)).(\lambda (H3: (leqz a4
+a5)).(leqz_head a0 a3 H1 a4 a5 H3))))))))) a1 a2 H))).
+
+theorem leq_leqz:
+ \forall (a1: A).(\forall (a2: A).((leqz a1 a2) \to (leq gz a1 a2)))
+\def
+ \lambda (a1: A).(\lambda (a2: A).(\lambda (H: (leqz a1 a2)).(leqz_ind
+(\lambda (a: A).(\lambda (a0: A).(leq gz a a0))) (\lambda (h1: nat).(\lambda
+(h2: nat).(\lambda (n1: nat).(\lambda (n2: nat).(\lambda (H0: (eq nat (plus
+h1 n2) (plus h2 n1))).(leq_sort gz h1 h2 n1 n2 (plus h1 h2) (eq_ind_r A
+(ASort (minus h1 (plus h1 h2)) (next_plus gz n1 (minus (plus h1 h2) h1)))
+(\lambda (a: A).(eq A a (aplus gz (ASort h2 n2) (plus h1 h2)))) (eq_ind_r A
+(ASort (minus h2 (plus h1 h2)) (next_plus gz n2 (minus (plus h1 h2) h2)))
+(\lambda (a: A).(eq A (ASort (minus h1 (plus h1 h2)) (next_plus gz n1 (minus
+(plus h1 h2) h1))) a)) (eq_ind_r nat h2 (\lambda (n: nat).(eq A (ASort (minus
+h1 (plus h1 h2)) (next_plus gz n1 n)) (ASort (minus h2 (plus h1 h2))
+(next_plus gz n2 (minus (plus h1 h2) h2))))) (eq_ind_r nat h1 (\lambda (n:
+nat).(eq A (ASort (minus h1 (plus h1 h2)) (next_plus gz n1 h2)) (ASort (minus
+h2 (plus h1 h2)) (next_plus gz n2 n)))) (eq_ind_r nat O (\lambda (n: nat).(eq
+A (ASort n (next_plus gz n1 h2)) (ASort (minus h2 (plus h1 h2)) (next_plus gz
+n2 h1)))) (eq_ind_r nat O (\lambda (n: nat).(eq A (ASort O (next_plus gz n1
+h2)) (ASort n (next_plus gz n2 h1)))) (eq_ind_r nat (plus h2 n1) (\lambda (n:
+nat).(eq A (ASort O n) (ASort O (next_plus gz n2 h1)))) (eq_ind_r nat (plus
+h1 n2) (\lambda (n: nat).(eq A (ASort O (plus h2 n1)) (ASort O n))) (f_equal
+nat A (ASort O) (plus h2 n1) (plus h1 n2) (sym_eq nat (plus h1 n2) (plus h2
+n1) H0)) (next_plus gz n2 h1) (next_plus_gz n2 h1)) (next_plus gz n1 h2)
+(next_plus_gz n1 h2)) (minus h2 (plus h1 h2)) (O_minus h2 (plus h1 h2)
+(le_plus_r h1 h2))) (minus h1 (plus h1 h2)) (O_minus h1 (plus h1 h2)
+(le_plus_l h1 h2))) (minus (plus h1 h2) h2) (minus_plus_r h1 h2)) (minus
+(plus h1 h2) h1) (minus_plus h1 h2)) (aplus gz (ASort h2 n2) (plus h1 h2))
+(aplus_asort_simpl gz (plus h1 h2) h2 n2)) (aplus gz (ASort h1 n1) (plus h1
+h2)) (aplus_asort_simpl gz (plus h1 h2) h1 n1)))))))) (\lambda (a0:
+A).(\lambda (a3: A).(\lambda (_: (leqz a0 a3)).(\lambda (H1: (leq gz a0
+a3)).(\lambda (a4: A).(\lambda (a5: A).(\lambda (_: (leqz a4 a5)).(\lambda
+(H3: (leq gz a4 a5)).(leq_head gz a0 a3 H1 a4 a5 H3))))))))) a1 a2 H))).
+
(CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef
O)) (TLRef (S (S O))) t)) (pc3_t x0 (CHead (CHead (CHead (CSort O) (Bind
Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S (S
-O))) H41 (lift (S O) O (TLRef O)) (pc3_s (CHead (CHead (CHead (CSort O) (Bind
-Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) x0 (lift (S O)
-O (TLRef O)) H22)) (TLRef (plus O (S O))) (lift_lref_ge O (S O) O (le_n O)))
-in (let H44 \def H43 in (ex2_ind T (\lambda (t: T).(pr3 (CHead (CHead (CHead
-(CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef
-O)) (TLRef (S (S O))) t)) (\lambda (t: T).(pr3 (CHead (CHead (CHead (CSort O)
-(Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef
-(S O)) t)) P (\lambda (x14: T).(\lambda (H45: (pr3 (CHead (CHead (CHead
-(CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef
-O)) (TLRef (S (S O))) x14)).(\lambda (H46: (pr3 (CHead (CHead (CHead (CSort
-O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O))
-(TLRef (S O)) x14)).(let H47 \def (eq_ind_r T x14 (\lambda (t: T).(eq T
-(TLRef (S (S O))) t)) (nf2_pr3_unfold (CHead (CHead (CHead (CSort O) (Bind
-Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S (S
-O))) x14 H45 (nf2_lref_abst (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort
-O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (CSort O) (TSort O) (S (S
-O)) (getl_clear_bind Abst (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort
-O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (CHead (CHead (CSort O)
-(Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (TLRef O) (clear_bind Abst
-(CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (TLRef
-O)) (CHead (CSort O) (Bind Abst) (TSort O)) (S O) (getl_head (Bind Abst) O
-(CHead (CSort O) (Bind Abst) (TSort O)) (CHead (CSort O) (Bind Abst) (TSort
-O)) (getl_refl Abst (CSort O) (TSort O)) (TSort O))))) (TLRef (S O))
+O))) H41 (lift (S O) O (TLRef O)) (ex2_sym T (pr3 (CHead (CHead (CHead (CSort
+O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (lift
+(S O) O (TLRef O))) (pr3 (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort
+O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) x0) H22)) (TLRef (plus O (S
+O))) (lift_lref_ge O (S O) O (le_n O))) in (let H44 \def H43 in (ex2_ind T
+(\lambda (t: T).(pr3 (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O))
+(Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S (S O))) t)) (\lambda
+(t: T).(pr3 (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind Abst)
+(TSort O)) (Bind Abst) (TLRef O)) (TLRef (S O)) t)) P (\lambda (x14:
+T).(\lambda (H45: (pr3 (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O))
+(Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S (S O)))
+x14)).(\lambda (H46: (pr3 (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort
+O)) (Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S O)) x14)).(let
+H47 \def (eq_ind_r T x14 (\lambda (t: T).(eq T (TLRef (S (S O))) t))
+(nf2_pr3_unfold (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind
+Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S (S O))) x14 H45
+(nf2_lref_abst (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind
+Abst) (TSort O)) (Bind Abst) (TLRef O)) (CSort O) (TSort O) (S (S O))
+(getl_clear_bind Abst (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O))
+(Bind Abst) (TSort O)) (Bind Abst) (TLRef O)) (CHead (CHead (CSort O) (Bind
+Abst) (TSort O)) (Bind Abst) (TSort O)) (TLRef O) (clear_bind Abst (CHead
+(CHead (CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O)) (TLRef O))
+(CHead (CSort O) (Bind Abst) (TSort O)) (S O) (getl_head (Bind Abst) O (CHead
+(CSort O) (Bind Abst) (TSort O)) (CHead (CSort O) (Bind Abst) (TSort O))
+(getl_refl Abst (CSort O) (TSort O)) (TSort O))))) (TLRef (S O))
(nf2_pr3_unfold (CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind
Abst) (TSort O)) (Bind Abst) (TLRef O)) (TLRef (S O)) x14 H46 (nf2_lref_abst
(CHead (CHead (CHead (CSort O) (Bind Abst) (TSort O)) (Bind Abst) (TSort O))
\forall (k: K).(\forall (c: C).(\forall (u: T).(\forall (t: T).(flt c u c
(THead k u t)))))
\def
- \lambda (_: K).(\lambda (c: C).(\lambda (u: T).(\lambda (t: T).(lt_le_S
-(plus (cweight c) (tweight u)) (plus (cweight c) (S (plus (tweight u)
-(tweight t)))) (plus_le_lt_compat (cweight c) (cweight c) (tweight u) (S
-(plus (tweight u) (tweight t))) (le_n (cweight c)) (le_lt_n_Sm (tweight u)
-(plus (tweight u) (tweight t)) (le_plus_l (tweight u) (tweight t)))))))).
+ \lambda (_: K).(\lambda (c: C).(\lambda (u: T).(\lambda (t:
+T).(plus_le_lt_compat (cweight c) (cweight c) (tweight u) (S (plus (tweight
+u) (tweight t))) (le_n (cweight c)) (le_n_S (tweight u) (plus (tweight u)
+(tweight t)) (le_plus_l (tweight u) (tweight t))))))).
theorem flt_thead_dx:
\forall (k: K).(\forall (c: C).(\forall (u: T).(\forall (t: T).(flt c t c
(THead k u t)))))
\def
- \lambda (_: K).(\lambda (c: C).(\lambda (u: T).(\lambda (t: T).(lt_le_S
-(plus (cweight c) (tweight t)) (plus (cweight c) (S (plus (tweight u)
-(tweight t)))) (plus_le_lt_compat (cweight c) (cweight c) (tweight t) (S
-(plus (tweight u) (tweight t))) (le_n (cweight c)) (le_lt_n_Sm (tweight t)
-(plus (tweight u) (tweight t)) (le_plus_r (tweight u) (tweight t)))))))).
+ \lambda (_: K).(\lambda (c: C).(\lambda (u: T).(\lambda (t:
+T).(plus_le_lt_compat (cweight c) (cweight c) (tweight t) (S (plus (tweight
+u) (tweight t))) (le_n (cweight c)) (le_n_S (tweight t) (plus (tweight u)
+(tweight t)) (le_plus_r (tweight u) (tweight t))))))).
theorem flt_shift:
\forall (k: K).(\forall (c: C).(\forall (u: T).(\forall (t: T).(flt (CHead c
\forall (k: K).(\forall (c: C).(\forall (t: T).(\forall (i: nat).(flt c t
(CHead c k t) (TLRef i)))))
\def
- \lambda (_: K).(\lambda (c: C).(\lambda (t: T).(\lambda (_: nat).(le_S_n (S
-(plus (cweight c) (tweight t))) (plus (plus (cweight c) (tweight t)) (S O))
-(lt_le_S (S (plus (cweight c) (tweight t))) (S (plus (plus (cweight c)
-(tweight t)) (S O))) (lt_n_S (plus (cweight c) (tweight t)) (plus (plus
-(cweight c) (tweight t)) (S O)) (lt_x_plus_x_Sy (plus (cweight c) (tweight
-t)) O))))))).
+ \lambda (_: K).(\lambda (c: C).(\lambda (t: T).(\lambda (_:
+nat).(lt_x_plus_x_Sy (plus (cweight c) (tweight t)) O)))).
theorem flt_arith1:
\forall (k1: K).(\forall (c1: C).(\forall (c2: C).(\forall (t1: T).((cle
(H: (lt (plus (cweight c1) (tweight t1)) (plus (cweight c2) (S O)))).(\lambda
(_: K).(\lambda (t2: T).(\lambda (_: nat).(lt_le_trans (plus (cweight c1)
(tweight t1)) (plus (cweight c2) (S O)) (plus (plus (cweight c2) (tweight
-t2)) (S O)) H (le_S_n (plus (cweight c2) (S O)) (plus (plus (cweight c2)
-(tweight t2)) (S O)) (lt_le_S (plus (cweight c2) (S O)) (S (plus (plus
-(cweight c2) (tweight t2)) (S O))) (le_lt_n_Sm (plus (cweight c2) (S O))
-(plus (plus (cweight c2) (tweight t2)) (S O)) (plus_le_compat (cweight c2)
-(plus (cweight c2) (tweight t2)) (S O) (S O) (le_plus_l (cweight c2) (tweight
-t2)) (le_n (S O)))))))))))))).
+t2)) (S O)) H (plus_le_compat (cweight c2) (plus (cweight c2) (tweight t2))
+(S O) (S O) (le_plus_l (cweight c2) (tweight t2)) (le_n (S O))))))))))).
theorem flt_wf__q_ind:
\forall (P: ((C \to (T \to Prop)))).(((\forall (n: nat).((\lambda (P0: ((C
+++ /dev/null
-(**************************************************************************)
-(* ___ *)
-(* ||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 *)
-(* *)
-(**************************************************************************)
-
-(* This file was automatically generated: do not edit *********************)
-
-set "baseuri" "cic:/matita/LAMBDA-TYPES/LambdaDelta-1/gz/defs".
-
-include "A/defs.ma".
-
-include "G/defs.ma".
-
-definition gz:
- G
-\def
- mk_G S lt_n_Sn.
-
-inductive leqz: A \to (A \to Prop) \def
-| leqz_sort: \forall (h1: nat).(\forall (h2: nat).(\forall (n1: nat).(\forall
-(n2: nat).((eq nat (plus h1 n2) (plus h2 n1)) \to (leqz (ASort h1 n1) (ASort
-h2 n2))))))
-| leqz_head: \forall (a1: A).(\forall (a2: A).((leqz a1 a2) \to (\forall (a3:
-A).(\forall (a4: A).((leqz a3 a4) \to (leqz (AHead a1 a3) (AHead a2 a4))))))).
-
+++ /dev/null
-(**************************************************************************)
-(* ___ *)
-(* ||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 *)
-(* *)
-(**************************************************************************)
-
-(* This file was automatically generated: do not edit *********************)
-
-set "baseuri" "cic:/matita/LAMBDA-TYPES/LambdaDelta-1/gz/props".
-
-include "gz/defs.ma".
-
-include "leq/defs.ma".
-
-include "aplus/props.ma".
-
-theorem aplus_gz_le:
- \forall (k: nat).(\forall (h: nat).(\forall (n: nat).((le h k) \to (eq A
-(aplus gz (ASort h n) k) (ASort O (plus (minus k h) n))))))
-\def
- \lambda (k: nat).(nat_ind (\lambda (n: nat).(\forall (h: nat).(\forall (n0:
-nat).((le h n) \to (eq A (aplus gz (ASort h n0) n) (ASort O (plus (minus n h)
-n0))))))) (\lambda (h: nat).(\lambda (n: nat).(\lambda (H: (le h O)).(let H_y
-\def (le_n_O_eq h H) in (eq_ind nat O (\lambda (n0: nat).(eq A (ASort n0 n)
-(ASort O n))) (refl_equal A (ASort O n)) h H_y))))) (\lambda (k0:
-nat).(\lambda (IH: ((\forall (h: nat).(\forall (n: nat).((le h k0) \to (eq A
-(aplus gz (ASort h n) k0) (ASort O (plus (minus k0 h) n)))))))).(\lambda (h:
-nat).(nat_ind (\lambda (n: nat).(\forall (n0: nat).((le n (S k0)) \to (eq A
-(asucc gz (aplus gz (ASort n n0) k0)) (ASort O (plus (match n with [O
-\Rightarrow (S k0) | (S l) \Rightarrow (minus k0 l)]) n0)))))) (\lambda (n:
-nat).(\lambda (_: (le O (S k0))).(eq_ind A (aplus gz (asucc gz (ASort O n))
-k0) (\lambda (a: A).(eq A a (ASort O (S (plus k0 n))))) (eq_ind_r A (ASort O
-(plus (minus k0 O) (S n))) (\lambda (a: A).(eq A a (ASort O (S (plus k0
-n))))) (eq_ind nat k0 (\lambda (n0: nat).(eq A (ASort O (plus n0 (S n)))
-(ASort O (S (plus k0 n))))) (eq_ind nat (S (plus k0 n)) (\lambda (n0:
-nat).(eq A (ASort O n0) (ASort O (S (plus k0 n))))) (refl_equal A (ASort O (S
-(plus k0 n)))) (plus k0 (S n)) (plus_n_Sm k0 n)) (minus k0 O) (minus_n_O k0))
-(aplus gz (ASort O (S n)) k0) (IH O (S n) (le_O_n k0))) (asucc gz (aplus gz
-(ASort O n) k0)) (aplus_asucc gz k0 (ASort O n))))) (\lambda (n:
-nat).(\lambda (_: ((\forall (n0: nat).((le n (S k0)) \to (eq A (asucc gz
-(aplus gz (ASort n n0) k0)) (ASort O (plus (match n with [O \Rightarrow (S
-k0) | (S l) \Rightarrow (minus k0 l)]) n0))))))).(\lambda (n0: nat).(\lambda
-(H0: (le (S n) (S k0))).(ex2_ind nat (\lambda (n1: nat).(eq nat (S k0) (S
-n1))) (\lambda (n1: nat).(le n n1)) (eq A (asucc gz (aplus gz (ASort (S n)
-n0) k0)) (ASort O (plus (minus k0 n) n0))) (\lambda (x: nat).(\lambda (H1:
-(eq nat (S k0) (S x))).(\lambda (H2: (le n x)).(let H3 \def (f_equal nat nat
-(\lambda (e: nat).(match e in nat return (\lambda (_: nat).nat) with [O
-\Rightarrow k0 | (S n1) \Rightarrow n1])) (S k0) (S x) H1) in (let H4 \def
-(eq_ind_r nat x (\lambda (n1: nat).(le n n1)) H2 k0 H3) in (eq_ind A (aplus
-gz (ASort n n0) k0) (\lambda (a: A).(eq A (asucc gz (aplus gz (ASort (S n)
-n0) k0)) a)) (eq_ind A (aplus gz (asucc gz (ASort (S n) n0)) k0) (\lambda (a:
-A).(eq A a (aplus gz (ASort n n0) k0))) (refl_equal A (aplus gz (ASort n n0)
-k0)) (asucc gz (aplus gz (ASort (S n) n0) k0)) (aplus_asucc gz k0 (ASort (S
-n) n0))) (ASort O (plus (minus k0 n) n0)) (IH n n0 H4))))))) (le_gen_S n (S
-k0) H0)))))) h)))) k).
-
-theorem aplus_gz_ge:
- \forall (n: nat).(\forall (k: nat).(\forall (h: nat).((le k h) \to (eq A
-(aplus gz (ASort h n) k) (ASort (minus h k) n)))))
-\def
- \lambda (n: nat).(\lambda (k: nat).(nat_ind (\lambda (n0: nat).(\forall (h:
-nat).((le n0 h) \to (eq A (aplus gz (ASort h n) n0) (ASort (minus h n0)
-n))))) (\lambda (h: nat).(\lambda (_: (le O h)).(eq_ind nat h (\lambda (n0:
-nat).(eq A (ASort h n) (ASort n0 n))) (refl_equal A (ASort h n)) (minus h O)
-(minus_n_O h)))) (\lambda (k0: nat).(\lambda (IH: ((\forall (h: nat).((le k0
-h) \to (eq A (aplus gz (ASort h n) k0) (ASort (minus h k0) n)))))).(\lambda
-(h: nat).(nat_ind (\lambda (n0: nat).((le (S k0) n0) \to (eq A (asucc gz
-(aplus gz (ASort n0 n) k0)) (ASort (minus n0 (S k0)) n)))) (\lambda (H: (le
-(S k0) O)).(ex2_ind nat (\lambda (n0: nat).(eq nat O (S n0))) (\lambda (n0:
-nat).(le k0 n0)) (eq A (asucc gz (aplus gz (ASort O n) k0)) (ASort O n))
-(\lambda (x: nat).(\lambda (H0: (eq nat O (S x))).(\lambda (_: (le k0
-x)).(let H2 \def (eq_ind nat O (\lambda (ee: nat).(match ee in nat return
-(\lambda (_: nat).Prop) with [O \Rightarrow True | (S _) \Rightarrow False]))
-I (S x) H0) in (False_ind (eq A (asucc gz (aplus gz (ASort O n) k0)) (ASort O
-n)) H2))))) (le_gen_S k0 O H))) (\lambda (n0: nat).(\lambda (_: (((le (S k0)
-n0) \to (eq A (asucc gz (aplus gz (ASort n0 n) k0)) (ASort (minus n0 (S k0))
-n))))).(\lambda (H0: (le (S k0) (S n0))).(ex2_ind nat (\lambda (n1: nat).(eq
-nat (S n0) (S n1))) (\lambda (n1: nat).(le k0 n1)) (eq A (asucc gz (aplus gz
-(ASort (S n0) n) k0)) (ASort (minus n0 k0) n)) (\lambda (x: nat).(\lambda
-(H1: (eq nat (S n0) (S x))).(\lambda (H2: (le k0 x)).(let H3 \def (f_equal
-nat nat (\lambda (e: nat).(match e in nat return (\lambda (_: nat).nat) with
-[O \Rightarrow n0 | (S n1) \Rightarrow n1])) (S n0) (S x) H1) in (let H4 \def
-(eq_ind_r nat x (\lambda (n1: nat).(le k0 n1)) H2 n0 H3) in (eq_ind A (aplus
-gz (ASort n0 n) k0) (\lambda (a: A).(eq A (asucc gz (aplus gz (ASort (S n0)
-n) k0)) a)) (eq_ind A (aplus gz (asucc gz (ASort (S n0) n)) k0) (\lambda (a:
-A).(eq A a (aplus gz (ASort n0 n) k0))) (refl_equal A (aplus gz (ASort n0 n)
-k0)) (asucc gz (aplus gz (ASort (S n0) n) k0)) (aplus_asucc gz k0 (ASort (S
-n0) n))) (ASort (minus n0 k0) n) (IH n0 H4))))))) (le_gen_S k0 (S n0) H0)))))
-h)))) k)).
-
-theorem next_plus_gz:
- \forall (n: nat).(\forall (h: nat).(eq nat (next_plus gz n h) (plus h n)))
-\def
- \lambda (n: nat).(\lambda (h: nat).(nat_ind (\lambda (n0: nat).(eq nat
-(next_plus gz n n0) (plus n0 n))) (refl_equal nat n) (\lambda (n0:
-nat).(\lambda (H: (eq nat (next_plus gz n n0) (plus n0 n))).(f_equal nat nat
-S (next_plus gz n n0) (plus n0 n) H))) h)).
-
-theorem leqz_leq:
- \forall (a1: A).(\forall (a2: A).((leq gz a1 a2) \to (leqz a1 a2)))
-\def
- \lambda (a1: A).(\lambda (a2: A).(\lambda (H: (leq gz a1 a2)).(leq_ind gz
-(\lambda (a: A).(\lambda (a0: A).(leqz a a0))) (\lambda (h1: nat).(\lambda
-(h2: nat).(\lambda (n1: nat).(\lambda (n2: nat).(\lambda (k: nat).(\lambda
-(H0: (eq A (aplus gz (ASort h1 n1) k) (aplus gz (ASort h2 n2) k))).(lt_le_e k
-h1 (leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H1: (lt k h1)).(lt_le_e k h2
-(leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H2: (lt k h2)).(let H3 \def
-(eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a (aplus gz (ASort
-h2 n2) k))) H0 (ASort (minus h1 k) n1) (aplus_gz_ge n1 k h1 (le_S_n k h1
-(le_S (S k) h1 H1)))) in (let H4 \def (eq_ind A (aplus gz (ASort h2 n2) k)
-(\lambda (a: A).(eq A (ASort (minus h1 k) n1) a)) H3 (ASort (minus h2 k) n2)
-(aplus_gz_ge n2 k h2 (le_S_n k h2 (le_S (S k) h2 H2)))) in (let H5 \def
-(f_equal A nat (\lambda (e: A).(match e in A return (\lambda (_: A).nat) with
-[(ASort n _) \Rightarrow n | (AHead _ _) \Rightarrow ((let rec minus (n: nat)
-on n: (nat \to nat) \def (\lambda (m: nat).(match n with [O \Rightarrow O |
-(S k0) \Rightarrow (match m with [O \Rightarrow (S k0) | (S l) \Rightarrow
-(minus k0 l)])])) in minus) h1 k)])) (ASort (minus h1 k) n1) (ASort (minus h2
-k) n2) H4) in ((let H6 \def (f_equal A nat (\lambda (e: A).(match e in A
-return (\lambda (_: A).nat) with [(ASort _ n) \Rightarrow n | (AHead _ _)
-\Rightarrow n1])) (ASort (minus h1 k) n1) (ASort (minus h2 k) n2) H4) in
-(\lambda (H7: (eq nat (minus h1 k) (minus h2 k))).(eq_ind nat n1 (\lambda (n:
-nat).(leqz (ASort h1 n1) (ASort h2 n))) (eq_ind nat h1 (\lambda (n:
-nat).(leqz (ASort h1 n1) (ASort n n1))) (leqz_sort h1 h1 n1 n1 (refl_equal
-nat (plus h1 n1))) h2 (minus_minus k h1 h2 (le_S_n k h1 (le_S (S k) h1 H1))
-(le_S_n k h2 (le_S (S k) h2 H2)) H7)) n2 H6))) H5))))) (\lambda (H2: (le h2
-k)).(let H3 \def (eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a
-(aplus gz (ASort h2 n2) k))) H0 (ASort (minus h1 k) n1) (aplus_gz_ge n1 k h1
-(le_S_n k h1 (le_S (S k) h1 H1)))) in (let H4 \def (eq_ind A (aplus gz (ASort
-h2 n2) k) (\lambda (a: A).(eq A (ASort (minus h1 k) n1) a)) H3 (ASort O (plus
-(minus k h2) n2)) (aplus_gz_le k h2 n2 H2)) in (let H5 \def (eq_ind nat
-(minus h1 k) (\lambda (n: nat).(eq A (ASort n n1) (ASort O (plus (minus k h2)
-n2)))) H4 (S (minus h1 (S k))) (minus_x_Sy h1 k H1)) in (let H6 \def (eq_ind
-A (ASort (S (minus h1 (S k))) n1) (\lambda (ee: A).(match ee in A return
-(\lambda (_: A).Prop) with [(ASort n _) \Rightarrow (match n in nat return
-(\lambda (_: nat).Prop) with [O \Rightarrow False | (S _) \Rightarrow True])
-| (AHead _ _) \Rightarrow False])) I (ASort O (plus (minus k h2) n2)) H5) in
-(False_ind (leqz (ASort h1 n1) (ASort h2 n2)) H6)))))))) (\lambda (H1: (le h1
-k)).(lt_le_e k h2 (leqz (ASort h1 n1) (ASort h2 n2)) (\lambda (H2: (lt k
-h2)).(let H3 \def (eq_ind A (aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A
-a (aplus gz (ASort h2 n2) k))) H0 (ASort O (plus (minus k h1) n1))
-(aplus_gz_le k h1 n1 H1)) in (let H4 \def (eq_ind A (aplus gz (ASort h2 n2)
-k) (\lambda (a: A).(eq A (ASort O (plus (minus k h1) n1)) a)) H3 (ASort
-(minus h2 k) n2) (aplus_gz_ge n2 k h2 (le_S_n k h2 (le_S (S k) h2 H2)))) in
-(let H5 \def (sym_eq A (ASort O (plus (minus k h1) n1)) (ASort (minus h2 k)
-n2) H4) in (let H6 \def (eq_ind nat (minus h2 k) (\lambda (n: nat).(eq A
-(ASort n n2) (ASort O (plus (minus k h1) n1)))) H5 (S (minus h2 (S k)))
-(minus_x_Sy h2 k H2)) in (let H7 \def (eq_ind A (ASort (S (minus h2 (S k)))
-n2) (\lambda (ee: A).(match ee in A return (\lambda (_: A).Prop) with [(ASort
-n _) \Rightarrow (match n in nat return (\lambda (_: nat).Prop) with [O
-\Rightarrow False | (S _) \Rightarrow True]) | (AHead _ _) \Rightarrow
-False])) I (ASort O (plus (minus k h1) n1)) H6) in (False_ind (leqz (ASort h1
-n1) (ASort h2 n2)) H7))))))) (\lambda (H2: (le h2 k)).(let H3 \def (eq_ind A
-(aplus gz (ASort h1 n1) k) (\lambda (a: A).(eq A a (aplus gz (ASort h2 n2)
-k))) H0 (ASort O (plus (minus k h1) n1)) (aplus_gz_le k h1 n1 H1)) in (let H4
-\def (eq_ind A (aplus gz (ASort h2 n2) k) (\lambda (a: A).(eq A (ASort O
-(plus (minus k h1) n1)) a)) H3 (ASort O (plus (minus k h2) n2)) (aplus_gz_le
-k h2 n2 H2)) in (let H5 \def (f_equal A nat (\lambda (e: A).(match e in A
-return (\lambda (_: A).nat) with [(ASort _ n) \Rightarrow n | (AHead _ _)
-\Rightarrow ((let rec plus (n: nat) on n: (nat \to nat) \def (\lambda (m:
-nat).(match n with [O \Rightarrow m | (S p) \Rightarrow (S (plus p m))])) in
-plus) (minus k h1) n1)])) (ASort O (plus (minus k h1) n1)) (ASort O (plus
-(minus k h2) n2)) H4) in (let H_y \def (plus_plus k h1 h2 n1 n2 H1 H2 H5) in
-(leqz_sort h1 h2 n1 n2 H_y))))))))))))))) (\lambda (a0: A).(\lambda (a3:
-A).(\lambda (_: (leq gz a0 a3)).(\lambda (H1: (leqz a0 a3)).(\lambda (a4:
-A).(\lambda (a5: A).(\lambda (_: (leq gz a4 a5)).(\lambda (H3: (leqz a4
-a5)).(leqz_head a0 a3 H1 a4 a5 H3))))))))) a1 a2 H))).
-
-theorem leq_leqz:
- \forall (a1: A).(\forall (a2: A).((leqz a1 a2) \to (leq gz a1 a2)))
-\def
- \lambda (a1: A).(\lambda (a2: A).(\lambda (H: (leqz a1 a2)).(leqz_ind
-(\lambda (a: A).(\lambda (a0: A).(leq gz a a0))) (\lambda (h1: nat).(\lambda
-(h2: nat).(\lambda (n1: nat).(\lambda (n2: nat).(\lambda (H0: (eq nat (plus
-h1 n2) (plus h2 n1))).(leq_sort gz h1 h2 n1 n2 (plus h1 h2) (eq_ind_r A
-(ASort (minus h1 (plus h1 h2)) (next_plus gz n1 (minus (plus h1 h2) h1)))
-(\lambda (a: A).(eq A a (aplus gz (ASort h2 n2) (plus h1 h2)))) (eq_ind_r A
-(ASort (minus h2 (plus h1 h2)) (next_plus gz n2 (minus (plus h1 h2) h2)))
-(\lambda (a: A).(eq A (ASort (minus h1 (plus h1 h2)) (next_plus gz n1 (minus
-(plus h1 h2) h1))) a)) (eq_ind_r nat h2 (\lambda (n: nat).(eq A (ASort (minus
-h1 (plus h1 h2)) (next_plus gz n1 n)) (ASort (minus h2 (plus h1 h2))
-(next_plus gz n2 (minus (plus h1 h2) h2))))) (eq_ind_r nat h1 (\lambda (n:
-nat).(eq A (ASort (minus h1 (plus h1 h2)) (next_plus gz n1 h2)) (ASort (minus
-h2 (plus h1 h2)) (next_plus gz n2 n)))) (eq_ind_r nat O (\lambda (n: nat).(eq
-A (ASort n (next_plus gz n1 h2)) (ASort (minus h2 (plus h1 h2)) (next_plus gz
-n2 h1)))) (eq_ind_r nat O (\lambda (n: nat).(eq A (ASort O (next_plus gz n1
-h2)) (ASort n (next_plus gz n2 h1)))) (eq_ind_r nat (plus h2 n1) (\lambda (n:
-nat).(eq A (ASort O n) (ASort O (next_plus gz n2 h1)))) (eq_ind_r nat (plus
-h1 n2) (\lambda (n: nat).(eq A (ASort O (plus h2 n1)) (ASort O n))) (f_equal
-nat A (ASort O) (plus h2 n1) (plus h1 n2) (sym_eq nat (plus h1 n2) (plus h2
-n1) H0)) (next_plus gz n2 h1) (next_plus_gz n2 h1)) (next_plus gz n1 h2)
-(next_plus_gz n1 h2)) (minus h2 (plus h1 h2)) (O_minus h2 (plus h1 h2)
-(le_plus_r h1 h2))) (minus h1 (plus h1 h2)) (O_minus h1 (plus h1 h2)
-(le_plus_l h1 h2))) (minus (plus h1 h2) h2) (minus_plus_r h1 h2)) (minus
-(plus h1 h2) h1) (minus_plus h1 h2)) (aplus gz (ASort h2 n2) (plus h1 h2))
-(aplus_asort_simpl gz (plus h1 h2) h2 n2)) (aplus gz (ASort h1 n1) (plus h1
-h2)) (aplus_asort_simpl gz (plus h1 h2) h1 n1)))))))) (\lambda (a0:
-A).(\lambda (a3: A).(\lambda (_: (leqz a0 a3)).(\lambda (H1: (leq gz a0
-a3)).(\lambda (a4: A).(\lambda (a5: A).(\lambda (_: (leqz a4 a5)).(\lambda
-(H3: (leq gz a4 a5)).(leq_head gz a0 a3 H1 a4 a5 H3))))))))) a1 a2 H))).
-
n3)) (\lambda (H10: (lt k k0)).(let H_y \def (aplus_reg_r g (ASort h1 n1)
(ASort h2 n2) k k H0 (minus k0 k)) in (let H11 \def (eq_ind_r nat (plus
(minus k0 k) k) (\lambda (n: nat).(eq A (aplus g (ASort h1 n1) n) (aplus g
-(ASort h2 n2) n))) H_y k0 (le_plus_minus_sym k k0 (le_S_n k k0 (le_S (S k) k0
-H10)))) in (leq_sort g h1 h3 n1 n3 k0 (trans_eq A (aplus g (ASort h1 n1) k0)
-(aplus g (ASort h2 n2) k0) (aplus g (ASort h3 n3) k0) H11 H9))))) (\lambda
-(H10: (le k0 k)).(let H_y \def (aplus_reg_r g (ASort h2 n2) (ASort h3 n3) k0
-k0 H9 (minus k k0)) in (let H11 \def (eq_ind_r nat (plus (minus k k0) k0)
-(\lambda (n: nat).(eq A (aplus g (ASort h2 n2) n) (aplus g (ASort h3 n3) n)))
-H_y k (le_plus_minus_sym k0 k H10)) in (leq_sort g h1 h3 n1 n3 k (trans_eq A
-(aplus g (ASort h1 n1) k) (aplus g (ASort h2 n2) k) (aplus g (ASort h3 n3) k)
-H0 H11))))))) a3 H8)) n0 (sym_eq nat n0 n2 H7))) h0 (sym_eq nat h0 h2 H6)))
-H5)) H4 H2))) | (leq_head a0 a4 H2 a5 a6 H3) \Rightarrow (\lambda (H4: (eq A
-(AHead a0 a5) (ASort h2 n2))).(\lambda (H5: (eq A (AHead a4 a6) a3)).((let H6
-\def (eq_ind A (AHead a0 a5) (\lambda (e: A).(match e in A return (\lambda
-(_: A).Prop) with [(ASort _ _) \Rightarrow False | (AHead _ _) \Rightarrow
-True])) I (ASort h2 n2) H4) in (False_ind ((eq A (AHead a4 a6) a3) \to ((leq
-g a0 a4) \to ((leq g a5 a6) \to (leq g (ASort h1 n1) a3)))) H6)) H5 H2
-H3)))]) in (H2 (refl_equal A (ASort h2 n2)) (refl_equal A a3)))))))))))
-(\lambda (a3: A).(\lambda (a4: A).(\lambda (_: (leq g a3 a4)).(\lambda (H1:
-((\forall (a5: A).((leq g a4 a5) \to (leq g a3 a5))))).(\lambda (a5:
-A).(\lambda (a6: A).(\lambda (_: (leq g a5 a6)).(\lambda (H3: ((\forall (a7:
-A).((leq g a6 a7) \to (leq g a5 a7))))).(\lambda (a0: A).(\lambda (H4: (leq g
-(AHead a4 a6) a0)).(let H5 \def (match H4 in leq return (\lambda (a:
-A).(\lambda (a7: A).(\lambda (_: (leq ? a a7)).((eq A a (AHead a4 a6)) \to
-((eq A a7 a0) \to (leq g (AHead a3 a5) a0)))))) with [(leq_sort h1 h2 n1 n2 k
-H5) \Rightarrow (\lambda (H6: (eq A (ASort h1 n1) (AHead a4 a6))).(\lambda
-(H7: (eq A (ASort h2 n2) a0)).((let H8 \def (eq_ind A (ASort h1 n1) (\lambda
-(e: A).(match e in A return (\lambda (_: A).Prop) with [(ASort _ _)
-\Rightarrow True | (AHead _ _) \Rightarrow False])) I (AHead a4 a6) H6) in
-(False_ind ((eq A (ASort h2 n2) a0) \to ((eq A (aplus g (ASort h1 n1) k)
-(aplus g (ASort h2 n2) k)) \to (leq g (AHead a3 a5) a0))) H8)) H7 H5))) |
-(leq_head a7 a8 H5 a9 a10 H6) \Rightarrow (\lambda (H7: (eq A (AHead a7 a9)
-(AHead a4 a6))).(\lambda (H8: (eq A (AHead a8 a10) a0)).((let H9 \def
-(f_equal A A (\lambda (e: A).(match e in A return (\lambda (_: A).A) with
-[(ASort _ _) \Rightarrow a9 | (AHead _ a) \Rightarrow a])) (AHead a7 a9)
-(AHead a4 a6) H7) in ((let H10 \def (f_equal A A (\lambda (e: A).(match e in
-A return (\lambda (_: A).A) with [(ASort _ _) \Rightarrow a7 | (AHead a _)
-\Rightarrow a])) (AHead a7 a9) (AHead a4 a6) H7) in (eq_ind A a4 (\lambda (a:
-A).((eq A a9 a6) \to ((eq A (AHead a8 a10) a0) \to ((leq g a a8) \to ((leq g
-a9 a10) \to (leq g (AHead a3 a5) a0)))))) (\lambda (H11: (eq A a9
+(ASort h2 n2) n))) H_y k0 (le_plus_minus_sym k k0 (le_trans k (S k) k0 (le_S
+k k (le_n k)) H10))) in (leq_sort g h1 h3 n1 n3 k0 (trans_eq A (aplus g
+(ASort h1 n1) k0) (aplus g (ASort h2 n2) k0) (aplus g (ASort h3 n3) k0) H11
+H9))))) (\lambda (H10: (le k0 k)).(let H_y \def (aplus_reg_r g (ASort h2 n2)
+(ASort h3 n3) k0 k0 H9 (minus k k0)) in (let H11 \def (eq_ind_r nat (plus
+(minus k k0) k0) (\lambda (n: nat).(eq A (aplus g (ASort h2 n2) n) (aplus g
+(ASort h3 n3) n))) H_y k (le_plus_minus_sym k0 k H10)) in (leq_sort g h1 h3
+n1 n3 k (trans_eq A (aplus g (ASort h1 n1) k) (aplus g (ASort h2 n2) k)
+(aplus g (ASort h3 n3) k) H0 H11))))))) a3 H8)) n0 (sym_eq nat n0 n2 H7))) h0
+(sym_eq nat h0 h2 H6))) H5)) H4 H2))) | (leq_head a0 a4 H2 a5 a6 H3)
+\Rightarrow (\lambda (H4: (eq A (AHead a0 a5) (ASort h2 n2))).(\lambda (H5:
+(eq A (AHead a4 a6) a3)).((let H6 \def (eq_ind A (AHead a0 a5) (\lambda (e:
+A).(match e in A return (\lambda (_: A).Prop) with [(ASort _ _) \Rightarrow
+False | (AHead _ _) \Rightarrow True])) I (ASort h2 n2) H4) in (False_ind
+((eq A (AHead a4 a6) a3) \to ((leq g a0 a4) \to ((leq g a5 a6) \to (leq g
+(ASort h1 n1) a3)))) H6)) H5 H2 H3)))]) in (H2 (refl_equal A (ASort h2 n2))
+(refl_equal A a3))))))))))) (\lambda (a3: A).(\lambda (a4: A).(\lambda (_:
+(leq g a3 a4)).(\lambda (H1: ((\forall (a5: A).((leq g a4 a5) \to (leq g a3
+a5))))).(\lambda (a5: A).(\lambda (a6: A).(\lambda (_: (leq g a5
+a6)).(\lambda (H3: ((\forall (a7: A).((leq g a6 a7) \to (leq g a5
+a7))))).(\lambda (a0: A).(\lambda (H4: (leq g (AHead a4 a6) a0)).(let H5 \def
+(match H4 in leq return (\lambda (a: A).(\lambda (a7: A).(\lambda (_: (leq ?
+a a7)).((eq A a (AHead a4 a6)) \to ((eq A a7 a0) \to (leq g (AHead a3 a5)
+a0)))))) with [(leq_sort h1 h2 n1 n2 k H5) \Rightarrow (\lambda (H6: (eq A
+(ASort h1 n1) (AHead a4 a6))).(\lambda (H7: (eq A (ASort h2 n2) a0)).((let H8
+\def (eq_ind A (ASort h1 n1) (\lambda (e: A).(match e in A return (\lambda
+(_: A).Prop) with [(ASort _ _) \Rightarrow True | (AHead _ _) \Rightarrow
+False])) I (AHead a4 a6) H6) in (False_ind ((eq A (ASort h2 n2) a0) \to ((eq
+A (aplus g (ASort h1 n1) k) (aplus g (ASort h2 n2) k)) \to (leq g (AHead a3
+a5) a0))) H8)) H7 H5))) | (leq_head a7 a8 H5 a9 a10 H6) \Rightarrow (\lambda
+(H7: (eq A (AHead a7 a9) (AHead a4 a6))).(\lambda (H8: (eq A (AHead a8 a10)
+a0)).((let H9 \def (f_equal A A (\lambda (e: A).(match e in A return (\lambda
+(_: A).A) with [(ASort _ _) \Rightarrow a9 | (AHead _ a) \Rightarrow a]))
+(AHead a7 a9) (AHead a4 a6) H7) in ((let H10 \def (f_equal A A (\lambda (e:
+A).(match e in A return (\lambda (_: A).A) with [(ASort _ _) \Rightarrow a7 |
+(AHead a _) \Rightarrow a])) (AHead a7 a9) (AHead a4 a6) H7) in (eq_ind A a4
+(\lambda (a: A).((eq A a9 a6) \to ((eq A (AHead a8 a10) a0) \to ((leq g a a8)
+\to ((leq g a9 a10) \to (leq g (AHead a3 a5) a0)))))) (\lambda (H11: (eq A a9
a6)).(eq_ind A a6 (\lambda (a: A).((eq A (AHead a8 a10) a0) \to ((leq g a4
a8) \to ((leq g a a10) \to (leq g (AHead a3 a5) a0))))) (\lambda (H12: (eq A
(AHead a8 a10) a0)).(eq_ind A (AHead a8 a10) (\lambda (a: A).((leq g a4 a8)
(eq_ind nat (plus n0 h) (\lambda (n1: nat).(eq T (TLRef n0) (TLRef n1))) (let
H5 \def (eq_ind nat n (\lambda (n1: nat).(lt n1 d)) H (plus n0 h) H4) in
(le_false d n0 (eq T (TLRef n0) (TLRef (plus n0 h))) H1 (lt_le_S n0 d
-(le_lt_trans n0 (plus n0 h) d (le_plus_l n0 h) H5)))) n (sym_eq nat n (plus
-n0 h) H4))))]) in (H3 (refl_equal T (TLRef (plus n0 h)))))))))) (\lambda (k:
-K).(\lambda (t0: T).(\lambda (_: (((eq T (TLRef n) (lift h d t0)) \to (eq T
-t0 (TLRef n))))).(\lambda (t1: T).(\lambda (_: (((eq T (TLRef n) (lift h d
-t1)) \to (eq T t1 (TLRef n))))).(\lambda (H2: (eq T (TLRef n) (lift h d
-(THead k t0 t1)))).(let H3 \def (eq_ind T (lift h d (THead k t0 t1)) (\lambda
-(t2: T).(eq T (TLRef n) t2)) H2 (THead k (lift h d t0) (lift h (s k d) t1))
-(lift_head k t0 t1 h d)) in (let H4 \def (match H3 in eq return (\lambda (t2:
-T).(\lambda (_: (eq ? ? t2)).((eq T t2 (THead k (lift h d t0) (lift h (s k d)
-t1))) \to (eq T (THead k t0 t1) (TLRef n))))) with [refl_equal \Rightarrow
-(\lambda (H4: (eq T (TLRef n) (THead k (lift h d t0) (lift h (s k d)
-t1)))).(let H5 \def (eq_ind T (TLRef n) (\lambda (e: T).(match e in T return
-(\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
-\Rightarrow True | (THead _ _ _) \Rightarrow False])) I (THead k (lift h d
-t0) (lift h (s k d) t1)) H4) in (False_ind (eq T (THead k t0 t1) (TLRef n))
-H5)))]) in (H4 (refl_equal T (THead k (lift h d t0) (lift h (s k d)
-t1)))))))))))) t))))).
+(lt_le_trans n0 (S (plus n0 h)) d (le_lt_n_Sm n0 (plus n0 h) (le_plus_l n0
+h)) (lt_le_S (plus n0 h) d H5))))) n (sym_eq nat n (plus n0 h) H4))))]) in
+(H3 (refl_equal T (TLRef (plus n0 h)))))))))) (\lambda (k: K).(\lambda (t0:
+T).(\lambda (_: (((eq T (TLRef n) (lift h d t0)) \to (eq T t0 (TLRef
+n))))).(\lambda (t1: T).(\lambda (_: (((eq T (TLRef n) (lift h d t1)) \to (eq
+T t1 (TLRef n))))).(\lambda (H2: (eq T (TLRef n) (lift h d (THead k t0
+t1)))).(let H3 \def (eq_ind T (lift h d (THead k t0 t1)) (\lambda (t2: T).(eq
+T (TLRef n) t2)) H2 (THead k (lift h d t0) (lift h (s k d) t1)) (lift_head k
+t0 t1 h d)) in (let H4 \def (match H3 in eq return (\lambda (t2: T).(\lambda
+(_: (eq ? ? t2)).((eq T t2 (THead k (lift h d t0) (lift h (s k d) t1))) \to
+(eq T (THead k t0 t1) (TLRef n))))) with [refl_equal \Rightarrow (\lambda
+(H4: (eq T (TLRef n) (THead k (lift h d t0) (lift h (s k d) t1)))).(let H5
+\def (eq_ind T (TLRef n) (\lambda (e: T).(match e in T return (\lambda (_:
+T).Prop) with [(TSort _) \Rightarrow False | (TLRef _) \Rightarrow True |
+(THead _ _ _) \Rightarrow False])) I (THead k (lift h d t0) (lift h (s k d)
+t1)) H4) in (False_ind (eq T (THead k t0 t1) (TLRef n)) H5)))]) in (H4
+(refl_equal T (THead k (lift h d t0) (lift h (s k d) t1)))))))))))) t))))).
theorem lift_gen_lref_false:
\forall (h: nat).(\forall (d: nat).(\forall (n: nat).((le d n) \to ((lt n
plus) n h)])) (TLRef (plus n h)) (TLRef n0) H3) in (eq_ind nat (plus n h)
(\lambda (n1: nat).(eq T (TLRef n1) (TLRef n))) (let H5 \def (eq_ind_r nat n0
(\lambda (n1: nat).(lt n1 d)) H1 (plus n h) H4) in (le_false d n (eq T (TLRef
-(plus n h)) (TLRef n)) H (lt_le_S n d (le_lt_trans n (plus n h) d (le_plus_l
-n h) H5)))) n0 H4)))]) in (H3 (refl_equal T (TLRef n0)))))) (\lambda (H1: (le
-d n0)).(let H2 \def (eq_ind T (lift h d (TLRef n0)) (\lambda (t0: T).(eq T
-(TLRef (plus n h)) t0)) H0 (TLRef (plus n0 h)) (lift_lref_ge n0 h d H1)) in
-(let H3 \def (match H2 in eq return (\lambda (t0: T).(\lambda (_: (eq ? ?
-t0)).((eq T t0 (TLRef (plus n0 h))) \to (eq T (TLRef n0) (TLRef n))))) with
-[refl_equal \Rightarrow (\lambda (H3: (eq T (TLRef (plus n h)) (TLRef (plus
-n0 h)))).(let H4 \def (f_equal T nat (\lambda (e: T).(match e in T return
-(\lambda (_: T).nat) with [(TSort _) \Rightarrow ((let rec plus (n1: nat) on
-n1: (nat \to nat) \def (\lambda (m: nat).(match n1 with [O \Rightarrow m | (S
-p) \Rightarrow (S (plus p m))])) in plus) n h) | (TLRef n1) \Rightarrow n1 |
-(THead _ _ _) \Rightarrow ((let rec plus (n1: nat) on n1: (nat \to nat) \def
-(\lambda (m: nat).(match n1 with [O \Rightarrow m | (S p) \Rightarrow (S
-(plus p m))])) in plus) n h)])) (TLRef (plus n h)) (TLRef (plus n0 h)) H3) in
-(eq_ind nat (plus n h) (\lambda (_: nat).(eq T (TLRef n0) (TLRef n)))
-(f_equal nat T TLRef n0 n (simpl_plus_r h n0 n (sym_eq nat (plus n h) (plus
-n0 h) H4))) (plus n0 h) H4)))]) in (H3 (refl_equal T (TLRef (plus n0
-h)))))))))) (\lambda (k: K).(\lambda (t0: T).(\lambda (_: (((eq T (TLRef
-(plus n h)) (lift h d t0)) \to (eq T t0 (TLRef n))))).(\lambda (t1:
-T).(\lambda (_: (((eq T (TLRef (plus n h)) (lift h d t1)) \to (eq T t1 (TLRef
-n))))).(\lambda (H2: (eq T (TLRef (plus n h)) (lift h d (THead k t0
-t1)))).(let H3 \def (eq_ind T (lift h d (THead k t0 t1)) (\lambda (t2: T).(eq
-T (TLRef (plus n h)) t2)) H2 (THead k (lift h d t0) (lift h (s k d) t1))
-(lift_head k t0 t1 h d)) in (let H4 \def (match H3 in eq return (\lambda (t2:
-T).(\lambda (_: (eq ? ? t2)).((eq T t2 (THead k (lift h d t0) (lift h (s k d)
-t1))) \to (eq T (THead k t0 t1) (TLRef n))))) with [refl_equal \Rightarrow
-(\lambda (H4: (eq T (TLRef (plus n h)) (THead k (lift h d t0) (lift h (s k d)
-t1)))).(let H5 \def (eq_ind T (TLRef (plus n h)) (\lambda (e: T).(match e in
-T return (\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
-\Rightarrow True | (THead _ _ _) \Rightarrow False])) I (THead k (lift h d
-t0) (lift h (s k d) t1)) H4) in (False_ind (eq T (THead k t0 t1) (TLRef n))
-H5)))]) in (H4 (refl_equal T (THead k (lift h d t0) (lift h (s k d)
-t1)))))))))))) t))))).
+(plus n h)) (TLRef n)) H (lt_le_S n d (simpl_lt_plus_r h n d (lt_le_trans
+(plus n h) d (plus d h) H5 (le_plus_l d h)))))) n0 H4)))]) in (H3 (refl_equal
+T (TLRef n0)))))) (\lambda (H1: (le d n0)).(let H2 \def (eq_ind T (lift h d
+(TLRef n0)) (\lambda (t0: T).(eq T (TLRef (plus n h)) t0)) H0 (TLRef (plus n0
+h)) (lift_lref_ge n0 h d H1)) in (let H3 \def (match H2 in eq return (\lambda
+(t0: T).(\lambda (_: (eq ? ? t0)).((eq T t0 (TLRef (plus n0 h))) \to (eq T
+(TLRef n0) (TLRef n))))) with [refl_equal \Rightarrow (\lambda (H3: (eq T
+(TLRef (plus n h)) (TLRef (plus n0 h)))).(let H4 \def (f_equal T nat (\lambda
+(e: T).(match e in T return (\lambda (_: T).nat) with [(TSort _) \Rightarrow
+((let rec plus (n1: nat) on n1: (nat \to nat) \def (\lambda (m: nat).(match
+n1 with [O \Rightarrow m | (S p) \Rightarrow (S (plus p m))])) in plus) n h)
+| (TLRef n1) \Rightarrow n1 | (THead _ _ _) \Rightarrow ((let rec plus (n1:
+nat) on n1: (nat \to nat) \def (\lambda (m: nat).(match n1 with [O
+\Rightarrow m | (S p) \Rightarrow (S (plus p m))])) in plus) n h)])) (TLRef
+(plus n h)) (TLRef (plus n0 h)) H3) in (eq_ind nat (plus n h) (\lambda (_:
+nat).(eq T (TLRef n0) (TLRef n))) (f_equal nat T TLRef n0 n (simpl_plus_r h
+n0 n (sym_eq nat (plus n h) (plus n0 h) H4))) (plus n0 h) H4)))]) in (H3
+(refl_equal T (TLRef (plus n0 h)))))))))) (\lambda (k: K).(\lambda (t0:
+T).(\lambda (_: (((eq T (TLRef (plus n h)) (lift h d t0)) \to (eq T t0 (TLRef
+n))))).(\lambda (t1: T).(\lambda (_: (((eq T (TLRef (plus n h)) (lift h d
+t1)) \to (eq T t1 (TLRef n))))).(\lambda (H2: (eq T (TLRef (plus n h)) (lift
+h d (THead k t0 t1)))).(let H3 \def (eq_ind T (lift h d (THead k t0 t1))
+(\lambda (t2: T).(eq T (TLRef (plus n h)) t2)) H2 (THead k (lift h d t0)
+(lift h (s k d) t1)) (lift_head k t0 t1 h d)) in (let H4 \def (match H3 in eq
+return (\lambda (t2: T).(\lambda (_: (eq ? ? t2)).((eq T t2 (THead k (lift h
+d t0) (lift h (s k d) t1))) \to (eq T (THead k t0 t1) (TLRef n))))) with
+[refl_equal \Rightarrow (\lambda (H4: (eq T (TLRef (plus n h)) (THead k (lift
+h d t0) (lift h (s k d) t1)))).(let H5 \def (eq_ind T (TLRef (plus n h))
+(\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort _)
+\Rightarrow False | (TLRef _) \Rightarrow True | (THead _ _ _) \Rightarrow
+False])) I (THead k (lift h d t0) (lift h (s k d) t1)) H4) in (False_ind (eq
+T (THead k t0 t1) (TLRef n)) H5)))]) in (H4 (refl_equal T (THead k (lift h d
+t0) (lift h (s k d) t1)))))))))))) t))))).
theorem lift_gen_head:
\forall (k: K).(\forall (u: T).(\forall (t: T).(\forall (x: T).(\forall (h:
K).(\lambda (t0: T).(\lambda (H: ((\forall (d: nat).(eq T (lift O d t0)
t0)))).(\lambda (t1: T).(\lambda (H0: ((\forall (d: nat).(eq T (lift O d t1)
t1)))).(\lambda (d: nat).(eq_ind_r T (THead k (lift O d t0) (lift O (s k d)
-t1)) (\lambda (t2: T).(eq T t2 (THead k t0 t1))) (sym_eq T (THead k t0 t1)
-(THead k (lift O d t0) (lift O (s k d) t1)) (sym_eq T (THead k (lift O d t0)
-(lift O (s k d) t1)) (THead k t0 t1) (sym_eq T (THead k t0 t1) (THead k (lift
-O d t0) (lift O (s k d) t1)) (f_equal3 K T T T THead k k t0 (lift O d t0) t1
-(lift O (s k d) t1) (refl_equal K k) (sym_eq T (lift O d t0) t0 (H d))
-(sym_eq T (lift O (s k d) t1) t1 (H0 (s k d))))))) (lift O d (THead k t0 t1))
-(lift_head k t0 t1 O d)))))))) t).
+t1)) (\lambda (t2: T).(eq T t2 (THead k t0 t1))) (f_equal3 K T T T THead k k
+(lift O d t0) t0 (lift O (s k d) t1) t1 (refl_equal K k) (H d) (H0 (s k d)))
+(lift O d (THead k t0 t1)) (lift_head k t0 t1 O d)))))))) t).
theorem lift_lref_gt:
\forall (d: nat).(\forall (n: nat).((lt d n) \to (eq T (lift (S O) d (TLRef
(H3: (eq T t1 (THead (Bind b) x0 x1))).(\lambda (H4: (eq T (lift h d t) (lift
h d x0))).(\lambda (H5: (eq T (lift h (S d) t0) (lift h (S d) x1))).(eq_ind_r
T (THead (Bind b) x0 x1) (\lambda (t2: T).(eq T (THead (Bind b) t t0) t2))
-(sym_eq T (THead (Bind b) x0 x1) (THead (Bind b) t t0) (sym_eq T (THead (Bind
-b) t t0) (THead (Bind b) x0 x1) (sym_eq T (THead (Bind b) x0 x1) (THead (Bind
-b) t t0) (f_equal3 K T T T THead (Bind b) (Bind b) x0 t x1 t0 (refl_equal K
-(Bind b)) (sym_eq T t x0 (H x0 h d H4)) (sym_eq T t0 x1 (H0 x1 h (S d)
-H5)))))) t1 H3)))))) (lift_gen_bind b (lift h d t) (lift h (S d) t0) t1 h d
-H2)))))))))))) (\lambda (f: F).(\lambda (t: T).(\lambda (H: ((\forall (t0:
-T).(\forall (h: nat).(\forall (d: nat).((eq T (lift h d t) (lift h d t0)) \to
-(eq T t t0))))))).(\lambda (t0: T).(\lambda (H0: ((\forall (t1: T).(\forall
-(h: nat).(\forall (d: nat).((eq T (lift h d t0) (lift h d t1)) \to (eq T t0
-t1))))))).(\lambda (t1: T).(\lambda (h: nat).(\lambda (d: nat).(\lambda (H1:
-(eq T (lift h d (THead (Flat f) t t0)) (lift h d t1))).(let H2 \def (eq_ind T
-(lift h d (THead (Flat f) t t0)) (\lambda (t2: T).(eq T t2 (lift h d t1))) H1
-(THead (Flat f) (lift h d t) (lift h d t0)) (lift_flat f t t0 h d)) in
-(ex3_2_ind T T (\lambda (y: T).(\lambda (z: T).(eq T t1 (THead (Flat f) y
-z)))) (\lambda (y: T).(\lambda (_: T).(eq T (lift h d t) (lift h d y))))
-(\lambda (_: T).(\lambda (z: T).(eq T (lift h d t0) (lift h d z)))) (eq T
-(THead (Flat f) t t0) t1) (\lambda (x0: T).(\lambda (x1: T).(\lambda (H3: (eq
-T t1 (THead (Flat f) x0 x1))).(\lambda (H4: (eq T (lift h d t) (lift h d
-x0))).(\lambda (H5: (eq T (lift h d t0) (lift h d x1))).(eq_ind_r T (THead
-(Flat f) x0 x1) (\lambda (t2: T).(eq T (THead (Flat f) t t0) t2)) (sym_eq T
-(THead (Flat f) x0 x1) (THead (Flat f) t t0) (sym_eq T (THead (Flat f) t t0)
-(THead (Flat f) x0 x1) (sym_eq T (THead (Flat f) x0 x1) (THead (Flat f) t t0)
-(f_equal3 K T T T THead (Flat f) (Flat f) x0 t x1 t0 (refl_equal K (Flat f))
-(sym_eq T t x0 (H x0 h d H4)) (sym_eq T t0 x1 (H0 x1 h d H5)))))) t1 H3))))))
+(f_equal3 K T T T THead (Bind b) (Bind b) t x0 t0 x1 (refl_equal K (Bind b))
+(H x0 h d H4) (H0 x1 h (S d) H5)) t1 H3)))))) (lift_gen_bind b (lift h d t)
+(lift h (S d) t0) t1 h d H2)))))))))))) (\lambda (f: F).(\lambda (t:
+T).(\lambda (H: ((\forall (t0: T).(\forall (h: nat).(\forall (d: nat).((eq T
+(lift h d t) (lift h d t0)) \to (eq T t t0))))))).(\lambda (t0: T).(\lambda
+(H0: ((\forall (t1: T).(\forall (h: nat).(\forall (d: nat).((eq T (lift h d
+t0) (lift h d t1)) \to (eq T t0 t1))))))).(\lambda (t1: T).(\lambda (h:
+nat).(\lambda (d: nat).(\lambda (H1: (eq T (lift h d (THead (Flat f) t t0))
+(lift h d t1))).(let H2 \def (eq_ind T (lift h d (THead (Flat f) t t0))
+(\lambda (t2: T).(eq T t2 (lift h d t1))) H1 (THead (Flat f) (lift h d t)
+(lift h d t0)) (lift_flat f t t0 h d)) in (ex3_2_ind T T (\lambda (y:
+T).(\lambda (z: T).(eq T t1 (THead (Flat f) y z)))) (\lambda (y: T).(\lambda
+(_: T).(eq T (lift h d t) (lift h d y)))) (\lambda (_: T).(\lambda (z: T).(eq
+T (lift h d t0) (lift h d z)))) (eq T (THead (Flat f) t t0) t1) (\lambda (x0:
+T).(\lambda (x1: T).(\lambda (H3: (eq T t1 (THead (Flat f) x0 x1))).(\lambda
+(H4: (eq T (lift h d t) (lift h d x0))).(\lambda (H5: (eq T (lift h d t0)
+(lift h d x1))).(eq_ind_r T (THead (Flat f) x0 x1) (\lambda (t2: T).(eq T
+(THead (Flat f) t t0) t2)) (f_equal3 K T T T THead (Flat f) (Flat f) t x0 t0
+x1 (refl_equal K (Flat f)) (H x0 h d H4) (H0 x1 h d H5)) t1 H3))))))
(lift_gen_flat f (lift h d t) (lift h d t0) t1 h d H2)))))))))))) k)) x).
theorem lift_gen_lift:
H2))) (\lambda (H3: (le d2 n)).(lt_le_e n (plus d2 h2) (ex2 T (\lambda (t2:
T).(eq T x (lift h1 d1 t2))) (\lambda (t2: T).(eq T (TLRef n) (lift h2 d2
t2)))) (\lambda (H4: (lt n (plus d2 h2))).(lift_gen_lref_false h2 (plus d2
-h1) (plus n h1) (le_S_n (plus d2 h1) (plus n h1) (lt_le_S (plus d2 h1) (S
-(plus n h1)) (le_lt_n_Sm (plus d2 h1) (plus n h1) (plus_le_compat d2 n h1 h1
-H3 (le_n h1))))) (eq_ind_r nat (plus (plus d2 h2) h1) (\lambda (n0: nat).(lt
-(plus n h1) n0)) (lt_le_S (plus n h1) (plus (plus d2 h2) h1)
-(plus_lt_compat_r n (plus d2 h2) h1 H4)) (plus (plus d2 h1) h2)
-(plus_permute_2_in_3 d2 h1 h2)) x H2 (ex2 T (\lambda (t2: T).(eq T x (lift h1
-d1 t2))) (\lambda (t2: T).(eq T (TLRef n) (lift h2 d2 t2)))))) (\lambda (H4:
-(le (plus d2 h2) n)).(let H5 \def (eq_ind nat (plus n h1) (\lambda (n0:
-nat).(eq T (TLRef n0) (lift h2 (plus d2 h1) x))) H2 (plus (minus (plus n h1)
-h2) h2) (le_plus_minus_sym h2 (plus n h1) (le_plus_trans h2 n h1
-(le_trans_plus_r d2 h2 n H4)))) in (eq_ind_r T (TLRef (minus (plus n h1) h2))
-(\lambda (t: T).(ex2 T (\lambda (t2: T).(eq T t (lift h1 d1 t2))) (\lambda
-(t2: T).(eq T (TLRef n) (lift h2 d2 t2))))) (ex_intro2 T (\lambda (t2: T).(eq
-T (TLRef (minus (plus n h1) h2)) (lift h1 d1 t2))) (\lambda (t2: T).(eq T
-(TLRef n) (lift h2 d2 t2))) (TLRef (minus n h2)) (eq_ind_r nat (plus (minus n
-h2) h1) (\lambda (n0: nat).(eq T (TLRef n0) (lift h1 d1 (TLRef (minus n
-h2))))) (eq_ind_r T (TLRef (plus (minus n h2) h1)) (\lambda (t: T).(eq T
-(TLRef (plus (minus n h2) h1)) t)) (refl_equal T (TLRef (plus (minus n h2)
-h1))) (lift h1 d1 (TLRef (minus n h2))) (lift_lref_ge (minus n h2) h1 d1
-(le_trans d1 d2 (minus n h2) H (le_minus d2 n h2 H4)))) (minus (plus n h1)
-h2) (le_minus_plus h2 n (le_trans_plus_r d2 h2 n H4) h1)) (eq_ind_r nat (plus
-(minus n h2) h2) (\lambda (n0: nat).(eq T (TLRef n0) (lift h2 d2 (TLRef
-(minus n0 h2))))) (eq_ind_r T (TLRef (plus (minus (plus (minus n h2) h2) h2)
-h2)) (\lambda (t: T).(eq T (TLRef (plus (minus n h2) h2)) t)) (f_equal nat T
-TLRef (plus (minus n h2) h2) (plus (minus (plus (minus n h2) h2) h2) h2)
-(f_equal2 nat nat nat plus (minus n h2) (minus (plus (minus n h2) h2) h2) h2
-h2 (sym_eq nat (minus (plus (minus n h2) h2) h2) (minus n h2) (minus_plus_r
-(minus n h2) h2)) (refl_equal nat h2))) (lift h2 d2 (TLRef (minus (plus
-(minus n h2) h2) h2))) (lift_lref_ge (minus (plus (minus n h2) h2) h2) h2 d2
-(le_minus d2 (plus (minus n h2) h2) h2 (plus_le_compat d2 (minus n h2) h2 h2
-(le_minus d2 n h2 H4) (le_n h2))))) n (le_plus_minus_sym h2 n
-(le_trans_plus_r d2 h2 n H4)))) x (lift_gen_lref_ge h2 (plus d2 h1) (minus
-(plus n h1) h2) (arith0 h2 d2 n H4 h1) x H5)))))))))))))))))) (\lambda (k:
+h1) (plus n h1) (plus_le_compat d2 n h1 h1 H3 (le_n h1)) (eq_ind_r nat (plus
+(plus d2 h2) h1) (\lambda (n0: nat).(lt (plus n h1) n0)) (plus_lt_compat_r n
+(plus d2 h2) h1 H4) (plus (plus d2 h1) h2) (plus_permute_2_in_3 d2 h1 h2)) x
+H2 (ex2 T (\lambda (t2: T).(eq T x (lift h1 d1 t2))) (\lambda (t2: T).(eq T
+(TLRef n) (lift h2 d2 t2)))))) (\lambda (H4: (le (plus d2 h2) n)).(let H5
+\def (eq_ind nat (plus n h1) (\lambda (n0: nat).(eq T (TLRef n0) (lift h2
+(plus d2 h1) x))) H2 (plus (minus (plus n h1) h2) h2) (le_plus_minus_sym h2
+(plus n h1) (le_plus_trans h2 n h1 (le_trans h2 (plus d2 h2) n (le_plus_r d2
+h2) H4)))) in (eq_ind_r T (TLRef (minus (plus n h1) h2)) (\lambda (t: T).(ex2
+T (\lambda (t2: T).(eq T t (lift h1 d1 t2))) (\lambda (t2: T).(eq T (TLRef n)
+(lift h2 d2 t2))))) (ex_intro2 T (\lambda (t2: T).(eq T (TLRef (minus (plus n
+h1) h2)) (lift h1 d1 t2))) (\lambda (t2: T).(eq T (TLRef n) (lift h2 d2 t2)))
+(TLRef (minus n h2)) (eq_ind_r nat (plus (minus n h2) h1) (\lambda (n0:
+nat).(eq T (TLRef n0) (lift h1 d1 (TLRef (minus n h2))))) (eq_ind_r T (TLRef
+(plus (minus n h2) h1)) (\lambda (t: T).(eq T (TLRef (plus (minus n h2) h1))
+t)) (refl_equal T (TLRef (plus (minus n h2) h1))) (lift h1 d1 (TLRef (minus n
+h2))) (lift_lref_ge (minus n h2) h1 d1 (le_trans d1 d2 (minus n h2) H
+(le_minus d2 n h2 H4)))) (minus (plus n h1) h2) (le_minus_plus h2 n (le_trans
+h2 (plus d2 h2) n (le_plus_r d2 h2) H4) h1)) (eq_ind_r nat (plus (minus n h2)
+h2) (\lambda (n0: nat).(eq T (TLRef n0) (lift h2 d2 (TLRef (minus n0 h2)))))
+(eq_ind_r T (TLRef (plus (minus (plus (minus n h2) h2) h2) h2)) (\lambda (t:
+T).(eq T (TLRef (plus (minus n h2) h2)) t)) (f_equal nat T TLRef (plus (minus
+n h2) h2) (plus (minus (plus (minus n h2) h2) h2) h2) (f_equal2 nat nat nat
+plus (minus n h2) (minus (plus (minus n h2) h2) h2) h2 h2 (sym_eq nat (minus
+(plus (minus n h2) h2) h2) (minus n h2) (minus_plus_r (minus n h2) h2))
+(refl_equal nat h2))) (lift h2 d2 (TLRef (minus (plus (minus n h2) h2) h2)))
+(lift_lref_ge (minus (plus (minus n h2) h2) h2) h2 d2 (le_minus d2 (plus
+(minus n h2) h2) h2 (plus_le_compat d2 (minus n h2) h2 h2 (le_minus d2 n h2
+H4) (le_n h2))))) n (le_plus_minus_sym h2 n (le_trans h2 (plus d2 h2) n
+(le_plus_r d2 h2) H4)))) x (lift_gen_lref_ge h2 (plus d2 h1) (minus (plus n
+h1) h2) (arith0 h2 d2 n H4 h1) x H5)))))))))))))))))) (\lambda (k:
K).(\lambda (t: T).(\lambda (H: ((\forall (x: T).(\forall (h1: nat).(\forall
(h2: nat).(\forall (d1: nat).(\forall (d2: nat).((le d1 d2) \to ((eq T (lift
h1 d1 t) (lift h2 (plus d2 h1) x)) \to (ex2 T (\lambda (t2: T).(eq T x (lift
(\lambda (t2: T).(eq T (THead (Bind b) (lift h2 d2 x2) (lift h2 (S d2) x3))
t2)) (refl_equal T (THead (Bind b) (lift h2 d2 x2) (lift h2 (S d2) x3)))
(lift h2 d2 (THead (Bind b) x2 x3)) (lift_bind b x2 x3 h2 d2))) t0 H13) x1
-H12)))) (H0 x1 h1 h2 (S d1) (S d2) (le_S_n (S d1) (S d2) (lt_le_S (S d1) (S
-(S d2)) (lt_n_S d1 (S d2) (le_lt_n_Sm d1 d2 H1)))) H11)))) t H9) x0 H8)))) (H
-x0 h1 h2 d1 d2 H1 H6)) x H5)))))) (lift_gen_bind b (lift h1 d1 t) (lift h1 (S
-d1) t0) x h2 (plus d2 h1) H4))))) (\lambda (f: F).(\lambda (H3: (eq T (lift
-h1 d1 (THead (Flat f) t t0)) (lift h2 (plus d2 h1) x))).(let H4 \def (eq_ind
-T (lift h1 d1 (THead (Flat f) t t0)) (\lambda (t2: T).(eq T t2 (lift h2 (plus
-d2 h1) x))) H3 (THead (Flat f) (lift h1 d1 t) (lift h1 d1 t0)) (lift_flat f t
-t0 h1 d1)) in (ex3_2_ind T T (\lambda (y: T).(\lambda (z: T).(eq T x (THead
-(Flat f) y z)))) (\lambda (y: T).(\lambda (_: T).(eq T (lift h1 d1 t) (lift
-h2 (plus d2 h1) y)))) (\lambda (_: T).(\lambda (z: T).(eq T (lift h1 d1 t0)
-(lift h2 (plus d2 h1) z)))) (ex2 T (\lambda (t2: T).(eq T x (lift h1 d1 t2)))
-(\lambda (t2: T).(eq T (THead (Flat f) t t0) (lift h2 d2 t2)))) (\lambda (x0:
-T).(\lambda (x1: T).(\lambda (H5: (eq T x (THead (Flat f) x0 x1))).(\lambda
-(H6: (eq T (lift h1 d1 t) (lift h2 (plus d2 h1) x0))).(\lambda (H7: (eq T
-(lift h1 d1 t0) (lift h2 (plus d2 h1) x1))).(eq_ind_r T (THead (Flat f) x0
-x1) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h1 d1 t3)))
-(\lambda (t3: T).(eq T (THead (Flat f) t t0) (lift h2 d2 t3))))) (ex2_ind T
-(\lambda (t2: T).(eq T x0 (lift h1 d1 t2))) (\lambda (t2: T).(eq T t (lift h2
-d2 t2))) (ex2 T (\lambda (t2: T).(eq T (THead (Flat f) x0 x1) (lift h1 d1
-t2))) (\lambda (t2: T).(eq T (THead (Flat f) t t0) (lift h2 d2 t2))))
-(\lambda (x2: T).(\lambda (H8: (eq T x0 (lift h1 d1 x2))).(\lambda (H9: (eq T
-t (lift h2 d2 x2))).(eq_ind_r T (lift h1 d1 x2) (\lambda (t2: T).(ex2 T
-(\lambda (t3: T).(eq T (THead (Flat f) t2 x1) (lift h1 d1 t3))) (\lambda (t3:
-T).(eq T (THead (Flat f) t t0) (lift h2 d2 t3))))) (eq_ind_r T (lift h2 d2
-x2) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead (Flat f) (lift h1
-d1 x2) x1) (lift h1 d1 t3))) (\lambda (t3: T).(eq T (THead (Flat f) t2 t0)
-(lift h2 d2 t3))))) (ex2_ind T (\lambda (t2: T).(eq T x1 (lift h1 d1 t2)))
-(\lambda (t2: T).(eq T t0 (lift h2 d2 t2))) (ex2 T (\lambda (t2: T).(eq T
-(THead (Flat f) (lift h1 d1 x2) x1) (lift h1 d1 t2))) (\lambda (t2: T).(eq T
-(THead (Flat f) (lift h2 d2 x2) t0) (lift h2 d2 t2)))) (\lambda (x3:
-T).(\lambda (H10: (eq T x1 (lift h1 d1 x3))).(\lambda (H11: (eq T t0 (lift h2
-d2 x3))).(eq_ind_r T (lift h1 d1 x3) (\lambda (t2: T).(ex2 T (\lambda (t3:
-T).(eq T (THead (Flat f) (lift h1 d1 x2) t2) (lift h1 d1 t3))) (\lambda (t3:
-T).(eq T (THead (Flat f) (lift h2 d2 x2) t0) (lift h2 d2 t3))))) (eq_ind_r T
-(lift h2 d2 x3) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead (Flat
-f) (lift h1 d1 x2) (lift h1 d1 x3)) (lift h1 d1 t3))) (\lambda (t3: T).(eq T
-(THead (Flat f) (lift h2 d2 x2) t2) (lift h2 d2 t3))))) (ex_intro2 T (\lambda
-(t2: T).(eq T (THead (Flat f) (lift h1 d1 x2) (lift h1 d1 x3)) (lift h1 d1
-t2))) (\lambda (t2: T).(eq T (THead (Flat f) (lift h2 d2 x2) (lift h2 d2 x3))
-(lift h2 d2 t2))) (THead (Flat f) x2 x3) (eq_ind_r T (THead (Flat f) (lift h1
-d1 x2) (lift h1 d1 x3)) (\lambda (t2: T).(eq T (THead (Flat f) (lift h1 d1
-x2) (lift h1 d1 x3)) t2)) (refl_equal T (THead (Flat f) (lift h1 d1 x2) (lift
-h1 d1 x3))) (lift h1 d1 (THead (Flat f) x2 x3)) (lift_flat f x2 x3 h1 d1))
-(eq_ind_r T (THead (Flat f) (lift h2 d2 x2) (lift h2 d2 x3)) (\lambda (t2:
-T).(eq T (THead (Flat f) (lift h2 d2 x2) (lift h2 d2 x3)) t2)) (refl_equal T
-(THead (Flat f) (lift h2 d2 x2) (lift h2 d2 x3))) (lift h2 d2 (THead (Flat f)
-x2 x3)) (lift_flat f x2 x3 h2 d2))) t0 H11) x1 H10)))) (H0 x1 h1 h2 d1 d2 H1
-H7)) t H9) x0 H8)))) (H x0 h1 h2 d1 d2 H1 H6)) x H5)))))) (lift_gen_flat f
-(lift h1 d1 t) (lift h1 d1 t0) x h2 (plus d2 h1) H4))))) k H2)))))))))))))
-t1).
+H12)))) (H0 x1 h1 h2 (S d1) (S d2) (le_n_S d1 d2 H1) H11)))) t H9) x0 H8))))
+(H x0 h1 h2 d1 d2 H1 H6)) x H5)))))) (lift_gen_bind b (lift h1 d1 t) (lift h1
+(S d1) t0) x h2 (plus d2 h1) H4))))) (\lambda (f: F).(\lambda (H3: (eq T
+(lift h1 d1 (THead (Flat f) t t0)) (lift h2 (plus d2 h1) x))).(let H4 \def
+(eq_ind T (lift h1 d1 (THead (Flat f) t t0)) (\lambda (t2: T).(eq T t2 (lift
+h2 (plus d2 h1) x))) H3 (THead (Flat f) (lift h1 d1 t) (lift h1 d1 t0))
+(lift_flat f t t0 h1 d1)) in (ex3_2_ind T T (\lambda (y: T).(\lambda (z:
+T).(eq T x (THead (Flat f) y z)))) (\lambda (y: T).(\lambda (_: T).(eq T
+(lift h1 d1 t) (lift h2 (plus d2 h1) y)))) (\lambda (_: T).(\lambda (z:
+T).(eq T (lift h1 d1 t0) (lift h2 (plus d2 h1) z)))) (ex2 T (\lambda (t2:
+T).(eq T x (lift h1 d1 t2))) (\lambda (t2: T).(eq T (THead (Flat f) t t0)
+(lift h2 d2 t2)))) (\lambda (x0: T).(\lambda (x1: T).(\lambda (H5: (eq T x
+(THead (Flat f) x0 x1))).(\lambda (H6: (eq T (lift h1 d1 t) (lift h2 (plus d2
+h1) x0))).(\lambda (H7: (eq T (lift h1 d1 t0) (lift h2 (plus d2 h1)
+x1))).(eq_ind_r T (THead (Flat f) x0 x1) (\lambda (t2: T).(ex2 T (\lambda
+(t3: T).(eq T t2 (lift h1 d1 t3))) (\lambda (t3: T).(eq T (THead (Flat f) t
+t0) (lift h2 d2 t3))))) (ex2_ind T (\lambda (t2: T).(eq T x0 (lift h1 d1
+t2))) (\lambda (t2: T).(eq T t (lift h2 d2 t2))) (ex2 T (\lambda (t2: T).(eq
+T (THead (Flat f) x0 x1) (lift h1 d1 t2))) (\lambda (t2: T).(eq T (THead
+(Flat f) t t0) (lift h2 d2 t2)))) (\lambda (x2: T).(\lambda (H8: (eq T x0
+(lift h1 d1 x2))).(\lambda (H9: (eq T t (lift h2 d2 x2))).(eq_ind_r T (lift
+h1 d1 x2) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead (Flat f) t2
+x1) (lift h1 d1 t3))) (\lambda (t3: T).(eq T (THead (Flat f) t t0) (lift h2
+d2 t3))))) (eq_ind_r T (lift h2 d2 x2) (\lambda (t2: T).(ex2 T (\lambda (t3:
+T).(eq T (THead (Flat f) (lift h1 d1 x2) x1) (lift h1 d1 t3))) (\lambda (t3:
+T).(eq T (THead (Flat f) t2 t0) (lift h2 d2 t3))))) (ex2_ind T (\lambda (t2:
+T).(eq T x1 (lift h1 d1 t2))) (\lambda (t2: T).(eq T t0 (lift h2 d2 t2)))
+(ex2 T (\lambda (t2: T).(eq T (THead (Flat f) (lift h1 d1 x2) x1) (lift h1 d1
+t2))) (\lambda (t2: T).(eq T (THead (Flat f) (lift h2 d2 x2) t0) (lift h2 d2
+t2)))) (\lambda (x3: T).(\lambda (H10: (eq T x1 (lift h1 d1 x3))).(\lambda
+(H11: (eq T t0 (lift h2 d2 x3))).(eq_ind_r T (lift h1 d1 x3) (\lambda (t2:
+T).(ex2 T (\lambda (t3: T).(eq T (THead (Flat f) (lift h1 d1 x2) t2) (lift h1
+d1 t3))) (\lambda (t3: T).(eq T (THead (Flat f) (lift h2 d2 x2) t0) (lift h2
+d2 t3))))) (eq_ind_r T (lift h2 d2 x3) (\lambda (t2: T).(ex2 T (\lambda (t3:
+T).(eq T (THead (Flat f) (lift h1 d1 x2) (lift h1 d1 x3)) (lift h1 d1 t3)))
+(\lambda (t3: T).(eq T (THead (Flat f) (lift h2 d2 x2) t2) (lift h2 d2
+t3))))) (ex_intro2 T (\lambda (t2: T).(eq T (THead (Flat f) (lift h1 d1 x2)
+(lift h1 d1 x3)) (lift h1 d1 t2))) (\lambda (t2: T).(eq T (THead (Flat f)
+(lift h2 d2 x2) (lift h2 d2 x3)) (lift h2 d2 t2))) (THead (Flat f) x2 x3)
+(eq_ind_r T (THead (Flat f) (lift h1 d1 x2) (lift h1 d1 x3)) (\lambda (t2:
+T).(eq T (THead (Flat f) (lift h1 d1 x2) (lift h1 d1 x3)) t2)) (refl_equal T
+(THead (Flat f) (lift h1 d1 x2) (lift h1 d1 x3))) (lift h1 d1 (THead (Flat f)
+x2 x3)) (lift_flat f x2 x3 h1 d1)) (eq_ind_r T (THead (Flat f) (lift h2 d2
+x2) (lift h2 d2 x3)) (\lambda (t2: T).(eq T (THead (Flat f) (lift h2 d2 x2)
+(lift h2 d2 x3)) t2)) (refl_equal T (THead (Flat f) (lift h2 d2 x2) (lift h2
+d2 x3))) (lift h2 d2 (THead (Flat f) x2 x3)) (lift_flat f x2 x3 h2 d2))) t0
+H11) x1 H10)))) (H0 x1 h1 h2 d1 d2 H1 H7)) t H9) x0 H8)))) (H x0 h1 h2 d1 d2
+H1 H6)) x H5)))))) (lift_gen_flat f (lift h1 d1 t) (lift h1 d1 t0) x h2 (plus
+d2 h1) H4))))) k H2))))))))))))) t1).
theorem lift_free:
\forall (t: T).(\forall (h: nat).(\forall (k: nat).(\forall (d:
(plus n k)) (\lambda (t0: T).(eq T (TLRef (plus n k)) t0)) (refl_equal T
(TLRef (plus n k))) (lift k e (TLRef n)) (lift_lref_ge n k e H0)) (lift h d
(TLRef n)) (lift_lref_lt n h d H1)) (lift h (plus d k) (TLRef (plus n k)))
-(lift_lref_lt (plus n k) h (plus d k) (lt_le_S (plus n k) (plus d k)
-(plus_lt_compat_r n d k H1))))) (\lambda (H1: (le d n)).(eq_ind_r T (TLRef
-(plus (plus n k) h)) (\lambda (t0: T).(eq T t0 (lift k e (lift h d (TLRef
-n))))) (eq_ind_r T (TLRef (plus n h)) (\lambda (t0: T).(eq T (TLRef (plus
-(plus n k) h)) (lift k e t0))) (eq_ind_r T (TLRef (plus (plus n h) k))
-(\lambda (t0: T).(eq T (TLRef (plus (plus n k) h)) t0)) (f_equal nat T TLRef
-(plus (plus n k) h) (plus (plus n h) k) (sym_eq nat (plus (plus n h) k) (plus
-(plus n k) h) (plus_permute_2_in_3 n h k))) (lift k e (TLRef (plus n h)))
-(lift_lref_ge (plus n h) k e (le_S_n e (plus n h) (lt_le_S e (S (plus n h))
-(le_lt_n_Sm e (plus n h) (le_plus_trans e n h H0)))))) (lift h d (TLRef n))
-(lift_lref_ge n h d H1)) (lift h (plus d k) (TLRef (plus n k))) (lift_lref_ge
-(plus n k) h (plus d k) (le_S_n (plus d k) (plus n k) (lt_le_S (plus d k) (S
-(plus n k)) (le_lt_n_Sm (plus d k) (plus n k) (plus_le_compat d n k k H1
-(le_n k))))))))) (plus k d) (plus_comm k d)) (lift k e (TLRef n))
-(lift_lref_ge n k e H0)))))))))) (\lambda (k: K).(\lambda (t0: T).(\lambda
-(H: ((\forall (h: nat).(\forall (k0: nat).(\forall (d: nat).(\forall (e:
-nat).((le e d) \to (eq T (lift h (plus k0 d) (lift k0 e t0)) (lift k0 e (lift
-h d t0)))))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (h: nat).(\forall
-(k0: nat).(\forall (d: nat).(\forall (e: nat).((le e d) \to (eq T (lift h
-(plus k0 d) (lift k0 e t1)) (lift k0 e (lift h d t1)))))))))).(\lambda (h:
+(lift_lref_lt (plus n k) h (plus d k) (plus_lt_compat_r n d k H1)))) (\lambda
+(H1: (le d n)).(eq_ind_r T (TLRef (plus (plus n k) h)) (\lambda (t0: T).(eq T
+t0 (lift k e (lift h d (TLRef n))))) (eq_ind_r T (TLRef (plus n h)) (\lambda
+(t0: T).(eq T (TLRef (plus (plus n k) h)) (lift k e t0))) (eq_ind_r T (TLRef
+(plus (plus n h) k)) (\lambda (t0: T).(eq T (TLRef (plus (plus n k) h)) t0))
+(f_equal nat T TLRef (plus (plus n k) h) (plus (plus n h) k) (sym_eq nat
+(plus (plus n h) k) (plus (plus n k) h) (plus_permute_2_in_3 n h k))) (lift k
+e (TLRef (plus n h))) (lift_lref_ge (plus n h) k e (le_plus_trans e n h H0)))
+(lift h d (TLRef n)) (lift_lref_ge n h d H1)) (lift h (plus d k) (TLRef (plus
+n k))) (lift_lref_ge (plus n k) h (plus d k) (plus_le_compat d n k k H1 (le_n
+k)))))) (plus k d) (plus_comm k d)) (lift k e (TLRef n)) (lift_lref_ge n k e
+H0)))))))))) (\lambda (k: K).(\lambda (t0: T).(\lambda (H: ((\forall (h:
+nat).(\forall (k0: nat).(\forall (d: nat).(\forall (e: nat).((le e d) \to (eq
+T (lift h (plus k0 d) (lift k0 e t0)) (lift k0 e (lift h d
+t0)))))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (h: nat).(\forall (k0:
+nat).(\forall (d: nat).(\forall (e: nat).((le e d) \to (eq T (lift h (plus k0
+d) (lift k0 e t1)) (lift k0 e (lift h d t1)))))))))).(\lambda (h:
nat).(\lambda (k0: nat).(\lambda (d: nat).(\lambda (e: nat).(\lambda (H1: (le
e d)).(eq_ind_r T (THead k (lift k0 e t0) (lift k0 (s k e) t1)) (\lambda (t2:
T).(eq T (lift h (plus k0 d) t2) (lift k0 e (lift h d (THead k t0 t1)))))
(weight_map f (TLRef n))) (lift h d (TLRef n)) (lift_lref_lt n h d H0)))
(\lambda (H0: (le d n)).(eq_ind_r T (TLRef (plus n h)) (\lambda (t0: T).(eq
nat (weight_map f t0) (weight_map f (TLRef n)))) (eq_ind_r nat O (\lambda
-(n0: nat).(eq nat (f (plus n h)) n0)) (H (plus n h) (le_S_n d (plus n h)
-(le_n_S d (plus n h) (le_plus_trans d n h H0)))) (f n) (H n H0)) (lift h d
-(TLRef n)) (lift_lref_ge n h d H0))))))))) (\lambda (k: K).(\lambda (t0:
-T).(\lambda (H: ((\forall (h: nat).(\forall (d: nat).(\forall (f: ((nat \to
-nat))).(((\forall (m: nat).((le d m) \to (eq nat (f m) O)))) \to (eq nat
-(weight_map f (lift h d t0)) (weight_map f t0)))))))).(\lambda (t1:
-T).(\lambda (H0: ((\forall (h: nat).(\forall (d: nat).(\forall (f: ((nat \to
-nat))).(((\forall (m: nat).((le d m) \to (eq nat (f m) O)))) \to (eq nat
-(weight_map f (lift h d t1)) (weight_map f t1)))))))).(\lambda (h:
-nat).(\lambda (d: nat).(\lambda (f: ((nat \to nat))).(\lambda (H1: ((\forall
-(m: nat).((le d m) \to (eq nat (f m) O))))).(K_ind (\lambda (k0: K).(eq nat
-(weight_map f (lift h d (THead k0 t0 t1))) (weight_map f (THead k0 t0 t1))))
-(\lambda (b: B).(eq_ind_r T (THead (Bind b) (lift h d t0) (lift h (s (Bind b)
-d) t1)) (\lambda (t2: T).(eq nat (weight_map f t2) (weight_map f (THead (Bind
-b) t0 t1)))) (B_ind (\lambda (b0: B).(eq nat (match b0 with [Abbr \Rightarrow
-(S (plus (weight_map f (lift h d t0)) (weight_map (wadd f (S (weight_map f
-(lift h d t0)))) (lift h (S d) t1)))) | Abst \Rightarrow (S (plus (weight_map
-f (lift h d t0)) (weight_map (wadd f O) (lift h (S d) t1)))) | Void
-\Rightarrow (S (plus (weight_map f (lift h d t0)) (weight_map (wadd f O)
-(lift h (S d) t1))))]) (match b0 with [Abbr \Rightarrow (S (plus (weight_map
-f t0) (weight_map (wadd f (S (weight_map f t0))) t1))) | Abst \Rightarrow (S
-(plus (weight_map f t0) (weight_map (wadd f O) t1))) | Void \Rightarrow (S
-(plus (weight_map f t0) (weight_map (wadd f O) t1)))]))) (eq_ind_r nat
-(weight_map f t0) (\lambda (n: nat).(eq nat (S (plus n (weight_map (wadd f (S
-n)) (lift h (S d) t1)))) (S (plus (weight_map f t0) (weight_map (wadd f (S
-(weight_map f t0))) t1))))) (eq_ind_r nat (weight_map (wadd f (S (weight_map
-f t0))) t1) (\lambda (n: nat).(eq nat (S (plus (weight_map f t0) n)) (S (plus
-(weight_map f t0) (weight_map (wadd f (S (weight_map f t0))) t1)))))
-(refl_equal nat (S (plus (weight_map f t0) (weight_map (wadd f (S (weight_map
-f t0))) t1)))) (weight_map (wadd f (S (weight_map f t0))) (lift h (S d) t1))
-(H0 h (S d) (wadd f (S (weight_map f t0))) (\lambda (m: nat).(\lambda (H2:
-(le (S d) m)).(ex2_ind nat (\lambda (n: nat).(eq nat m (S n))) (\lambda (n:
-nat).(le d n)) (eq nat (wadd f (S (weight_map f t0)) m) O) (\lambda (x:
-nat).(\lambda (H3: (eq nat m (S x))).(\lambda (H4: (le d x)).(eq_ind_r nat (S
-x) (\lambda (n: nat).(eq nat (wadd f (S (weight_map f t0)) n) O)) (H1 x H4) m
-H3)))) (le_gen_S d m H2)))))) (weight_map f (lift h d t0)) (H h d f H1))
-(eq_ind_r nat (weight_map (wadd f O) t1) (\lambda (n: nat).(eq nat (S (plus
-(weight_map f (lift h d t0)) n)) (S (plus (weight_map f t0) (weight_map (wadd
-f O) t1))))) (f_equal nat nat S (plus (weight_map f (lift h d t0))
-(weight_map (wadd f O) t1)) (plus (weight_map f t0) (weight_map (wadd f O)
-t1)) (f_equal2 nat nat nat plus (weight_map f (lift h d t0)) (weight_map f
-t0) (weight_map (wadd f O) t1) (weight_map (wadd f O) t1) (H h d f H1)
-(refl_equal nat (weight_map (wadd f O) t1)))) (weight_map (wadd f O) (lift h
-(S d) t1)) (H0 h (S d) (wadd f O) (\lambda (m: nat).(\lambda (H2: (le (S d)
+(n0: nat).(eq nat (f (plus n h)) n0)) (H (plus n h) (le_plus_trans d n h H0))
+(f n) (H n H0)) (lift h d (TLRef n)) (lift_lref_ge n h d H0))))))))) (\lambda
+(k: K).(\lambda (t0: T).(\lambda (H: ((\forall (h: nat).(\forall (d:
+nat).(\forall (f: ((nat \to nat))).(((\forall (m: nat).((le d m) \to (eq nat
+(f m) O)))) \to (eq nat (weight_map f (lift h d t0)) (weight_map f
+t0)))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (h: nat).(\forall (d:
+nat).(\forall (f: ((nat \to nat))).(((\forall (m: nat).((le d m) \to (eq nat
+(f m) O)))) \to (eq nat (weight_map f (lift h d t1)) (weight_map f
+t1)))))))).(\lambda (h: nat).(\lambda (d: nat).(\lambda (f: ((nat \to
+nat))).(\lambda (H1: ((\forall (m: nat).((le d m) \to (eq nat (f m)
+O))))).(K_ind (\lambda (k0: K).(eq nat (weight_map f (lift h d (THead k0 t0
+t1))) (weight_map f (THead k0 t0 t1)))) (\lambda (b: B).(eq_ind_r T (THead
+(Bind b) (lift h d t0) (lift h (s (Bind b) d) t1)) (\lambda (t2: T).(eq nat
+(weight_map f t2) (weight_map f (THead (Bind b) t0 t1)))) (B_ind (\lambda
+(b0: B).(eq nat (match b0 with [Abbr \Rightarrow (S (plus (weight_map f (lift
+h d t0)) (weight_map (wadd f (S (weight_map f (lift h d t0)))) (lift h (S d)
+t1)))) | Abst \Rightarrow (S (plus (weight_map f (lift h d t0)) (weight_map
+(wadd f O) (lift h (S d) t1)))) | Void \Rightarrow (S (plus (weight_map f
+(lift h d t0)) (weight_map (wadd f O) (lift h (S d) t1))))]) (match b0 with
+[Abbr \Rightarrow (S (plus (weight_map f t0) (weight_map (wadd f (S
+(weight_map f t0))) t1))) | Abst \Rightarrow (S (plus (weight_map f t0)
+(weight_map (wadd f O) t1))) | Void \Rightarrow (S (plus (weight_map f t0)
+(weight_map (wadd f O) t1)))]))) (eq_ind_r nat (weight_map f t0) (\lambda (n:
+nat).(eq nat (S (plus n (weight_map (wadd f (S n)) (lift h (S d) t1)))) (S
+(plus (weight_map f t0) (weight_map (wadd f (S (weight_map f t0))) t1)))))
+(eq_ind_r nat (weight_map (wadd f (S (weight_map f t0))) t1) (\lambda (n:
+nat).(eq nat (S (plus (weight_map f t0) n)) (S (plus (weight_map f t0)
+(weight_map (wadd f (S (weight_map f t0))) t1))))) (refl_equal nat (S (plus
+(weight_map f t0) (weight_map (wadd f (S (weight_map f t0))) t1))))
+(weight_map (wadd f (S (weight_map f t0))) (lift h (S d) t1)) (H0 h (S d)
+(wadd f (S (weight_map f t0))) (\lambda (m: nat).(\lambda (H2: (le (S d)
m)).(ex2_ind nat (\lambda (n: nat).(eq nat m (S n))) (\lambda (n: nat).(le d
-n)) (eq nat (wadd f O m) O) (\lambda (x: nat).(\lambda (H3: (eq nat m (S
-x))).(\lambda (H4: (le d x)).(eq_ind_r nat (S x) (\lambda (n: nat).(eq nat
-(wadd f O n) O)) (H1 x H4) m H3)))) (le_gen_S d m H2)))))) (eq_ind_r nat
-(weight_map (wadd f O) t1) (\lambda (n: nat).(eq nat (S (plus (weight_map f
-(lift h d t0)) n)) (S (plus (weight_map f t0) (weight_map (wadd f O) t1)))))
-(f_equal nat nat S (plus (weight_map f (lift h d t0)) (weight_map (wadd f O)
-t1)) (plus (weight_map f t0) (weight_map (wadd f O) t1)) (f_equal2 nat nat
-nat plus (weight_map f (lift h d t0)) (weight_map f t0) (weight_map (wadd f
-O) t1) (weight_map (wadd f O) t1) (H h d f H1) (refl_equal nat (weight_map
-(wadd f O) t1)))) (weight_map (wadd f O) (lift h (S d) t1)) (H0 h (S d) (wadd
-f O) (\lambda (m: nat).(\lambda (H2: (le (S d) m)).(ex2_ind nat (\lambda (n:
-nat).(eq nat m (S n))) (\lambda (n: nat).(le d n)) (eq nat (wadd f O m) O)
-(\lambda (x: nat).(\lambda (H3: (eq nat m (S x))).(\lambda (H4: (le d
-x)).(eq_ind_r nat (S x) (\lambda (n: nat).(eq nat (wadd f O n) O)) (H1 x H4)
-m H3)))) (le_gen_S d m H2)))))) b) (lift h d (THead (Bind b) t0 t1))
-(lift_head (Bind b) t0 t1 h d))) (\lambda (f0: F).(eq_ind_r T (THead (Flat
-f0) (lift h d t0) (lift h (s (Flat f0) d) t1)) (\lambda (t2: T).(eq nat
-(weight_map f t2) (weight_map f (THead (Flat f0) t0 t1)))) (f_equal nat nat S
-(plus (weight_map f (lift h d t0)) (weight_map f (lift h d t1))) (plus
-(weight_map f t0) (weight_map f t1)) (f_equal2 nat nat nat plus (weight_map f
-(lift h d t0)) (weight_map f t0) (weight_map f (lift h d t1)) (weight_map f
-t1) (H h d f H1) (H0 h d f H1))) (lift h d (THead (Flat f0) t0 t1))
-(lift_head (Flat f0) t0 t1 h d))) k)))))))))) t).
+n)) (eq nat (wadd f (S (weight_map f t0)) m) O) (\lambda (x: nat).(\lambda
+(H3: (eq nat m (S x))).(\lambda (H4: (le d x)).(eq_ind_r nat (S x) (\lambda
+(n: nat).(eq nat (wadd f (S (weight_map f t0)) n) O)) (H1 x H4) m H3))))
+(le_gen_S d m H2)))))) (weight_map f (lift h d t0)) (H h d f H1)) (eq_ind_r
+nat (weight_map (wadd f O) t1) (\lambda (n: nat).(eq nat (S (plus (weight_map
+f (lift h d t0)) n)) (S (plus (weight_map f t0) (weight_map (wadd f O)
+t1))))) (f_equal nat nat S (plus (weight_map f (lift h d t0)) (weight_map
+(wadd f O) t1)) (plus (weight_map f t0) (weight_map (wadd f O) t1)) (f_equal2
+nat nat nat plus (weight_map f (lift h d t0)) (weight_map f t0) (weight_map
+(wadd f O) t1) (weight_map (wadd f O) t1) (H h d f H1) (refl_equal nat
+(weight_map (wadd f O) t1)))) (weight_map (wadd f O) (lift h (S d) t1)) (H0 h
+(S d) (wadd f O) (\lambda (m: nat).(\lambda (H2: (le (S d) m)).(ex2_ind nat
+(\lambda (n: nat).(eq nat m (S n))) (\lambda (n: nat).(le d n)) (eq nat (wadd
+f O m) O) (\lambda (x: nat).(\lambda (H3: (eq nat m (S x))).(\lambda (H4: (le
+d x)).(eq_ind_r nat (S x) (\lambda (n: nat).(eq nat (wadd f O n) O)) (H1 x
+H4) m H3)))) (le_gen_S d m H2)))))) (eq_ind_r nat (weight_map (wadd f O) t1)
+(\lambda (n: nat).(eq nat (S (plus (weight_map f (lift h d t0)) n)) (S (plus
+(weight_map f t0) (weight_map (wadd f O) t1))))) (f_equal nat nat S (plus
+(weight_map f (lift h d t0)) (weight_map (wadd f O) t1)) (plus (weight_map f
+t0) (weight_map (wadd f O) t1)) (f_equal2 nat nat nat plus (weight_map f
+(lift h d t0)) (weight_map f t0) (weight_map (wadd f O) t1) (weight_map (wadd
+f O) t1) (H h d f H1) (refl_equal nat (weight_map (wadd f O) t1))))
+(weight_map (wadd f O) (lift h (S d) t1)) (H0 h (S d) (wadd f O) (\lambda (m:
+nat).(\lambda (H2: (le (S d) m)).(ex2_ind nat (\lambda (n: nat).(eq nat m (S
+n))) (\lambda (n: nat).(le d n)) (eq nat (wadd f O m) O) (\lambda (x:
+nat).(\lambda (H3: (eq nat m (S x))).(\lambda (H4: (le d x)).(eq_ind_r nat (S
+x) (\lambda (n: nat).(eq nat (wadd f O n) O)) (H1 x H4) m H3)))) (le_gen_S d
+m H2)))))) b) (lift h d (THead (Bind b) t0 t1)) (lift_head (Bind b) t0 t1 h
+d))) (\lambda (f0: F).(eq_ind_r T (THead (Flat f0) (lift h d t0) (lift h (s
+(Flat f0) d) t1)) (\lambda (t2: T).(eq nat (weight_map f t2) (weight_map f
+(THead (Flat f0) t0 t1)))) (f_equal nat nat S (plus (weight_map f (lift h d
+t0)) (weight_map f (lift h d t1))) (plus (weight_map f t0) (weight_map f t1))
+(f_equal2 nat nat nat plus (weight_map f (lift h d t0)) (weight_map f t0)
+(weight_map f (lift h d t1)) (weight_map f t1) (H h d f H1) (H0 h d f H1)))
+(lift h d (THead (Flat f0) t0 t1)) (lift_head (Flat f0) t0 t1 h d)))
+k)))))))))) t).
theorem lift_weight:
\forall (t: T).(\forall (h: nat).(\forall (d: nat).(eq nat (weight (lift h d
t))))) (\lambda (is2: PList).(\lambda (t: T).(refl_equal T (lift1 is2 t))))
(\lambda (n: nat).(\lambda (n0: nat).(\lambda (p: PList).(\lambda (H:
((\forall (is2: PList).(\forall (t: T).(eq T (lift1 p (lift1 is2 t)) (lift1
-(papp p is2) t)))))).(\lambda (is2: PList).(\lambda (t: T).(sym_eq T (lift n
-n0 (lift1 (papp p is2) t)) (lift n n0 (lift1 p (lift1 is2 t))) (sym_eq T
-(lift n n0 (lift1 p (lift1 is2 t))) (lift n n0 (lift1 (papp p is2) t))
-(sym_eq T (lift n n0 (lift1 (papp p is2) t)) (lift n n0 (lift1 p (lift1 is2
-t))) (f_equal3 nat nat T T lift n n n0 n0 (lift1 (papp p is2) t) (lift1 p
-(lift1 is2 t)) (refl_equal nat n) (refl_equal nat n0) (sym_eq T (lift1 p
-(lift1 is2 t)) (lift1 (papp p is2) t) (H is2 t)))))))))))) is1).
+(papp p is2) t)))))).(\lambda (is2: PList).(\lambda (t: T).(f_equal3 nat nat
+T T lift n n n0 n0 (lift1 p (lift1 is2 t)) (lift1 (papp p is2) t) (refl_equal
+nat n) (refl_equal nat n0) (H is2 t)))))))) is1).
theorem lift1_xhg:
\forall (hds: PList).(\forall (t: T).(eq T (lift1 (Ss hds) (lift (S O) O t))
theorem llt_head_sx:
\forall (a1: A).(\forall (a2: A).(llt a1 (AHead a1 a2)))
\def
- \lambda (a1: A).(\lambda (a2: A).(le_S_n (S (lweight a1)) (S (plus (lweight
-a1) (lweight a2))) (le_n_S (S (lweight a1)) (S (plus (lweight a1) (lweight
-a2))) (le_n_S (lweight a1) (plus (lweight a1) (lweight a2)) (le_plus_l
-(lweight a1) (lweight a2)))))).
+ \lambda (a1: A).(\lambda (a2: A).(le_n_S (lweight a1) (plus (lweight a1)
+(lweight a2)) (le_plus_l (lweight a1) (lweight a2)))).
theorem llt_head_dx:
\forall (a1: A).(\forall (a2: A).(llt a2 (AHead a1 a2)))
\def
- \lambda (a1: A).(\lambda (a2: A).(le_S_n (S (lweight a2)) (S (plus (lweight
-a1) (lweight a2))) (le_n_S (S (lweight a2)) (S (plus (lweight a1) (lweight
-a2))) (le_n_S (lweight a2) (plus (lweight a1) (lweight a2)) (le_plus_r
-(lweight a1) (lweight a2)))))).
+ \lambda (a1: A).(\lambda (a2: A).(le_n_S (lweight a2) (plus (lweight a1)
+(lweight a2)) (le_plus_r (lweight a1) (lweight a2)))).
theorem llt_wf__q_ind:
\forall (P: ((A \to Prop))).(((\forall (n: nat).((\lambda (P0: ((A \to
g n) h))))
\def
\lambda (g: G).(\lambda (h: nat).(nat_ind (\lambda (n: nat).(\forall (n0:
-nat).(lt n0 (next_plus g (next g n0) n)))) (\lambda (n: nat).(le_S_n (S n)
-(next g n) (lt_le_S (S n) (S (next g n)) (lt_n_S n (next g n) (next_lt g
-n))))) (\lambda (n: nat).(\lambda (H: ((\forall (n0: nat).(lt n0 (next_plus g
-(next g n0) n))))).(\lambda (n0: nat).(eq_ind nat (next_plus g (next g (next
-g n0)) n) (\lambda (n1: nat).(lt n0 n1)) (lt_trans n0 (next g n0) (next_plus
-g (next g (next g n0)) n) (next_lt g n0) (H (next g n0))) (next g (next_plus
-g (next g n0) n)) (next_plus_next g (next g n0) n))))) h)).
+nat).(lt n0 (next_plus g (next g n0) n)))) (\lambda (n: nat).(next_lt g n))
+(\lambda (n: nat).(\lambda (H: ((\forall (n0: nat).(lt n0 (next_plus g (next
+g n0) n))))).(\lambda (n0: nat).(eq_ind nat (next_plus g (next g (next g n0))
+n) (\lambda (n1: nat).(lt n0 n1)) (lt_trans n0 (next g n0) (next_plus g (next
+g (next g n0)) n) (next_lt g n0) (H (next g n0))) (next g (next_plus g (next
+g n0) n)) (next_plus_next g (next g n0) n))))) h)).
u2 H5) (\lambda (b: B).(\lambda (u: T).(pc3_pr3_t (CHead c (Bind b) u) t1 x1
(H15 b u) t2 (H6 b u))))))))) H12)))))))) H7))))))) H3))))) H0))))))).
+theorem pc3_gen_abst_shift:
+ \forall (c: C).(\forall (u: T).(\forall (t1: T).(\forall (t2: T).((pc3 c
+(THead (Bind Abst) u t1) (THead (Bind Abst) u t2)) \to (pc3 (CHead c (Bind
+Abst) u) t1 t2)))))
+\def
+ \lambda (c: C).(\lambda (u: T).(\lambda (t1: T).(\lambda (t2: T).(\lambda
+(H: (pc3 c (THead (Bind Abst) u t1) (THead (Bind Abst) u t2))).(let H_x \def
+(pc3_gen_abst c u u t1 t2 H) in (let H0 \def H_x in (and_ind (pc3 c u u)
+(\forall (b: B).(\forall (u0: T).(pc3 (CHead c (Bind b) u0) t1 t2))) (pc3
+(CHead c (Bind Abst) u) t1 t2) (\lambda (_: (pc3 c u u)).(\lambda (H2:
+((\forall (b: B).(\forall (u0: T).(pc3 (CHead c (Bind b) u0) t1 t2))))).(H2
+Abst u))) H0))))))).
+
theorem pc3_gen_lift:
\forall (c: C).(\forall (t1: T).(\forall (t2: T).(\forall (h: nat).(\forall
(d: nat).((pc3 c (lift h d t1) (lift h d t2)) \to (\forall (e: C).((drop h d
t2)).(pc3_left_ind c (\lambda (t: T).(\lambda (t0: T).(pc3 c t t0))) (\lambda
(t: T).(pc3_refl c t)) (\lambda (t0: T).(\lambda (t3: T).(\lambda (H0: (pr2 c
t0 t3)).(\lambda (t4: T).(\lambda (_: (pc3_left c t3 t4)).(\lambda (H2: (pc3
-c t3 t4)).(pc3_pr2_u c t3 t0 H0 t4 H2))))))) (\lambda (t0: T).(\lambda (t3:
-T).(\lambda (H0: (pr2 c t0 t3)).(\lambda (t4: T).(\lambda (_: (pc3_left c t0
-t4)).(\lambda (H2: (pc3 c t0 t4)).(pc3_t t0 c t3 (pc3_pr2_x c t3 t0 H0) t4
-H2))))))) t1 t2 H)))).
+c t3 t4)).(pc3_t t3 c t0 (pc3_pr2_r c t0 t3 H0) t4 H2))))))) (\lambda (t0:
+T).(\lambda (t3: T).(\lambda (H0: (pr2 c t0 t3)).(\lambda (t4: T).(\lambda
+(_: (pc3_left c t0 t4)).(\lambda (H2: (pc3 c t0 t4)).(pc3_t t0 c t3
+(pc3_pr2_x c t3 t0 H0) t4 H2))))))) t1 t2 H)))).
theorem pc3_ind_left:
\forall (c: C).(\forall (P: ((T \to (T \to Prop)))).(((\forall (t: T).(P t
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||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 *)
+(* *)
+(**************************************************************************)
+
+(* This file was automatically generated: do not edit *********************)
+
+set "baseuri" "cic:/matita/LAMBDA-TYPES/LambdaDelta-1/pc3/nf2".
+
+include "pc3/defs.ma".
+
+include "nf2/pr3.ma".
+
+theorem pc3_nf2:
+ \forall (c: C).(\forall (t1: T).(\forall (t2: T).((pc3 c t1 t2) \to ((nf2 c
+t1) \to ((nf2 c t2) \to (eq T t1 t2))))))
+\def
+ \lambda (c: C).(\lambda (t1: T).(\lambda (t2: T).(\lambda (H: (pc3 c t1
+t2)).(\lambda (H0: (nf2 c t1)).(\lambda (H1: (nf2 c t2)).(let H2 \def H in
+(ex2_ind T (\lambda (t: T).(pr3 c t1 t)) (\lambda (t: T).(pr3 c t2 t)) (eq T
+t1 t2) (\lambda (x: T).(\lambda (H3: (pr3 c t1 x)).(\lambda (H4: (pr3 c t2
+x)).(let H_y \def (nf2_pr3_unfold c t1 x H3 H0) in (let H5 \def (eq_ind_r T x
+(\lambda (t: T).(pr3 c t2 t)) H4 t1 H_y) in (let H6 \def (eq_ind_r T x
+(\lambda (t: T).(pr3 c t1 t)) H3 t1 H_y) in (let H_y0 \def (nf2_pr3_unfold c
+t2 t1 H5 H1) in (let H7 \def (eq_ind T t2 (\lambda (t: T).(pr3 c t t1)) H5 t1
+H_y0) in (eq_ind_r T t1 (\lambda (t: T).(eq T t1 t)) (refl_equal T t1) t2
+H_y0))))))))) H2))))))).
+
Abbr) d) t0)) t)) (pr0_delta (lift h d u1) (lift h d u2) (H1 h d) (lift h (S
d) t0) (lift h (S d) t3) (H3 h (S d)) (lift h (S d) w) (let d' \def (S d) in
(eq_ind nat (minus (S d) (S O)) (\lambda (n: nat).(subst0 O (lift h n u2)
-(lift h d' t3) (lift h d' w))) (subst0_lift_lt t3 w u2 O H4 (S d) (lt_le_S O
-(S d) (le_lt_n_Sm O d (le_O_n d))) h) d (eq_ind nat d (\lambda (n: nat).(eq
-nat n d)) (refl_equal nat d) (minus d O) (minus_n_O d))))) (lift h d (THead
-(Bind Abbr) u2 w)) (lift_head (Bind Abbr) u2 w h d)) (lift h d (THead (Bind
-Abbr) u1 t0)) (lift_head (Bind Abbr) u1 t0 h d)))))))))))))) (\lambda (b:
-B).(\lambda (H0: (not (eq B b Abst))).(\lambda (t0: T).(\lambda (t3:
-T).(\lambda (_: (pr0 t0 t3)).(\lambda (H2: ((\forall (h: nat).(\forall (d:
-nat).(pr0 (lift h d t0) (lift h d t3)))))).(\lambda (u: T).(\lambda (h:
-nat).(\lambda (d: nat).(eq_ind_r T (THead (Bind b) (lift h d u) (lift h (s
-(Bind b) d) (lift (S O) O t0))) (\lambda (t: T).(pr0 t (lift h d t3)))
-(eq_ind nat (plus (S O) d) (\lambda (n: nat).(pr0 (THead (Bind b) (lift h d
-u) (lift h n (lift (S O) O t0))) (lift h d t3))) (eq_ind_r T (lift (S O) O
-(lift h d t0)) (\lambda (t: T).(pr0 (THead (Bind b) (lift h d u) t) (lift h d
-t3))) (pr0_zeta b H0 (lift h d t0) (lift h d t3) (H2 h d) (lift h d u)) (lift
-h (plus (S O) d) (lift (S O) O t0)) (lift_d t0 h (S O) d O (le_O_n d))) (S d)
-(refl_equal nat (S d))) (lift h d (THead (Bind b) u (lift (S O) O t0)))
-(lift_head (Bind b) u (lift (S O) O t0) h d))))))))))) (\lambda (t0:
-T).(\lambda (t3: T).(\lambda (_: (pr0 t0 t3)).(\lambda (H1: ((\forall (h:
-nat).(\forall (d: nat).(pr0 (lift h d t0) (lift h d t3)))))).(\lambda (u:
-T).(\lambda (h: nat).(\lambda (d: nat).(eq_ind_r T (THead (Flat Cast) (lift h
-d u) (lift h (s (Flat Cast) d) t0)) (\lambda (t: T).(pr0 t (lift h d t3)))
-(pr0_epsilon (lift h (s (Flat Cast) d) t0) (lift h d t3) (H1 h d) (lift h d
-u)) (lift h d (THead (Flat Cast) u t0)) (lift_head (Flat Cast) u t0 h
-d))))))))) t1 t2 H))).
+(lift h d' t3) (lift h d' w))) (subst0_lift_lt t3 w u2 O H4 (S d) (le_n_S O d
+(le_O_n d)) h) d (eq_ind nat d (\lambda (n: nat).(eq nat n d)) (refl_equal
+nat d) (minus d O) (minus_n_O d))))) (lift h d (THead (Bind Abbr) u2 w))
+(lift_head (Bind Abbr) u2 w h d)) (lift h d (THead (Bind Abbr) u1 t0))
+(lift_head (Bind Abbr) u1 t0 h d)))))))))))))) (\lambda (b: B).(\lambda (H0:
+(not (eq B b Abst))).(\lambda (t0: T).(\lambda (t3: T).(\lambda (_: (pr0 t0
+t3)).(\lambda (H2: ((\forall (h: nat).(\forall (d: nat).(pr0 (lift h d t0)
+(lift h d t3)))))).(\lambda (u: T).(\lambda (h: nat).(\lambda (d:
+nat).(eq_ind_r T (THead (Bind b) (lift h d u) (lift h (s (Bind b) d) (lift (S
+O) O t0))) (\lambda (t: T).(pr0 t (lift h d t3))) (eq_ind nat (plus (S O) d)
+(\lambda (n: nat).(pr0 (THead (Bind b) (lift h d u) (lift h n (lift (S O) O
+t0))) (lift h d t3))) (eq_ind_r T (lift (S O) O (lift h d t0)) (\lambda (t:
+T).(pr0 (THead (Bind b) (lift h d u) t) (lift h d t3))) (pr0_zeta b H0 (lift
+h d t0) (lift h d t3) (H2 h d) (lift h d u)) (lift h (plus (S O) d) (lift (S
+O) O t0)) (lift_d t0 h (S O) d O (le_O_n d))) (S d) (refl_equal nat (S d)))
+(lift h d (THead (Bind b) u (lift (S O) O t0))) (lift_head (Bind b) u (lift
+(S O) O t0) h d))))))))))) (\lambda (t0: T).(\lambda (t3: T).(\lambda (_:
+(pr0 t0 t3)).(\lambda (H1: ((\forall (h: nat).(\forall (d: nat).(pr0 (lift h
+d t0) (lift h d t3)))))).(\lambda (u: T).(\lambda (h: nat).(\lambda (d:
+nat).(eq_ind_r T (THead (Flat Cast) (lift h d u) (lift h (s (Flat Cast) d)
+t0)) (\lambda (t: T).(pr0 t (lift h d t3))) (pr0_epsilon (lift h (s (Flat
+Cast) d) t0) (lift h d t3) (H1 h d) (lift h d u)) (lift h d (THead (Flat
+Cast) u t0)) (lift_head (Flat Cast) u t0 h d))))))))) t1 t2 H))).
theorem pr0_subst0_back:
\forall (u2: T).(\forall (t1: T).(\forall (t2: T).(\forall (i: nat).((subst0
(\lambda (w2: T).(pr0 (THead (Bind b) u (lift (S O) O x0)) w2)) (\lambda (w2:
T).(subst0 i v2 t4 w2)) x1 (pr0_zeta b H0 x0 x1 H12 u) H13))))) H11)) (H2 v1
x0 i H10 v2 H4))) x H8) w1 H6)))) (subst0_gen_lift_ge v1 t3 x (s (Bind b) i)
-(S O) O H7 (le_S_n (S O) (S i) (lt_le_S (S O) (S (S i)) (lt_n_S O (S i)
-(le_lt_n_Sm O i (le_O_n i)))))))))) H5)) (\lambda (H5: (ex3_2 T T (\lambda
-(u2: T).(\lambda (t5: T).(eq T w1 (THead (Bind b) u2 t5)))) (\lambda (u2:
-T).(\lambda (_: T).(subst0 i v1 u u2))) (\lambda (_: T).(\lambda (t5:
+(S O) O H7 (le_n_S O i (le_O_n i))))))) H5)) (\lambda (H5: (ex3_2 T T
+(\lambda (u2: T).(\lambda (t5: T).(eq T w1 (THead (Bind b) u2 t5)))) (\lambda
+(u2: T).(\lambda (_: T).(subst0 i v1 u u2))) (\lambda (_: T).(\lambda (t5:
T).(subst0 (s (Bind b) i) v1 (lift (S O) O t3) t5))))).(ex3_2_ind T T
(\lambda (u2: T).(\lambda (t5: T).(eq T w1 (THead (Bind b) u2 t5)))) (\lambda
(u2: T).(\lambda (_: T).(subst0 i v1 u u2))) (\lambda (_: T).(\lambda (t5:
T).(subst0 i v2 t4 w2))) (ex_intro2 T (\lambda (w2: T).(pr0 (THead (Bind b)
x0 (lift (S O) O x)) w2)) (\lambda (w2: T).(subst0 i v2 t4 w2)) x2 (pr0_zeta
b H0 x x2 H13 x0) H14))))) H12)) (H2 v1 x i H11 v2 H4))) x1 H9) w1 H6))))
-(subst0_gen_lift_ge v1 t3 x1 (s (Bind b) i) (S O) O H8 (le_S_n (S O) (S i)
-(lt_le_S (S O) (S (S i)) (lt_n_S O (S i) (le_lt_n_Sm O i (le_O_n
-i)))))))))))) H5)) (subst0_gen_head (Bind b) v1 u (lift (S O) O t3) w1 i
+(subst0_gen_lift_ge v1 t3 x1 (s (Bind b) i) (S O) O H8 (le_n_S O i (le_O_n
+i))))))))) H5)) (subst0_gen_head (Bind b) v1 u (lift (S O) O t3) w1 i
H3))))))))))))))) (\lambda (t3: T).(\lambda (t4: T).(\lambda (H0: (pr0 t3
t4)).(\lambda (H1: ((\forall (v1: T).(\forall (w1: T).(\forall (i:
nat).((subst0 i v1 t3 w1) \to (\forall (v2: T).((pr0 v1 v2) \to (or (pr0 w1
(Bind x0) x1 x2)) (refl_equal T (THead (Bind x0) x4 (THead (Flat Appl) (lift
(S O) O x8) x5))) (pr2_delta c d u i H8 u1 x3 H15 x8 H27) (pr2_free c x1 x4
H16) (pr2_free (CHead c (Bind x0) x4) x2 x5 H17))) x7 H25)))))
-(subst0_gen_lift_ge u x3 x7 (s (Bind x0) i) (S O) O H24 (le_S_n (S O) (S i)
-(lt_le_S (S O) (S (S i)) (lt_n_S O (S i) (le_lt_n_Sm O i (le_O_n i))))))) x6
-H23)))) H22)) (\lambda (H22: (ex2 T (\lambda (t3: T).(eq T x6 (THead (Flat
-Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat Appl) (s
-(Bind x0) i)) u x5 t3)))).(ex2_ind T (\lambda (t3: T).(eq T x6 (THead (Flat
-Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat Appl) (s
-(Bind x0) i)) u x5 t3)) (or3 (ex3_2 T T (\lambda (u2: T).(\lambda (t3: T).(eq
-T (THead (Bind x0) x4 x6) (THead (Flat Appl) u2 t3)))) (\lambda (u2:
+(subst0_gen_lift_ge u x3 x7 (s (Bind x0) i) (S O) O H24 (le_n_S O i (le_O_n
+i)))) x6 H23)))) H22)) (\lambda (H22: (ex2 T (\lambda (t3: T).(eq T x6 (THead
+(Flat Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat Appl)
+(s (Bind x0) i)) u x5 t3)))).(ex2_ind T (\lambda (t3: T).(eq T x6 (THead
+(Flat Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat Appl)
+(s (Bind x0) i)) u x5 t3)) (or3 (ex3_2 T T (\lambda (u2: T).(\lambda (t3:
+T).(eq T (THead (Bind x0) x4 x6) (THead (Flat Appl) u2 t3)))) (\lambda (u2:
T).(\lambda (_: T).(pr2 c u1 u2))) (\lambda (_: T).(\lambda (t3: T).(pr2 c
(THead (Bind x0) x1 x2) t3)))) (ex4_4 T T T T (\lambda (y1: T).(\lambda (z1:
T).(\lambda (_: T).(\lambda (_: T).(eq T (THead (Bind x0) x1 x2) (THead (Bind
H16) (pr2_delta (CHead c (Bind x0) x4) d u (S i) (getl_clear_bind x0 (CHead c
(Bind x0) x4) c x4 (clear_bind x0 c x4) (CHead d (Bind Abbr) u) i H8) x2 x5
H17 x8 H25))) x7 H26))))) (subst0_gen_lift_ge u x3 x7 (s (Bind x0) i) (S O) O
-H24 (le_S_n (S O) (S i) (lt_le_S (S O) (S (S i)) (lt_n_S O (S i) (le_lt_n_Sm
-O i (le_O_n i))))))) x6 H23)))))) H22)) (subst0_gen_head (Flat Appl) u (lift
-(S O) O x3) x5 x6 (s (Bind x0) i) H21)) x H20)))) H19)) (\lambda (H19: (ex3_2
-T T (\lambda (u2: T).(\lambda (t3: T).(eq T x (THead (Bind x0) u2 t3))))
-(\lambda (u2: T).(\lambda (_: T).(subst0 i u x4 u2))) (\lambda (_:
+H24 (le_n_S O i (le_O_n i)))) x6 H23)))))) H22)) (subst0_gen_head (Flat Appl)
+u (lift (S O) O x3) x5 x6 (s (Bind x0) i) H21)) x H20)))) H19)) (\lambda
+(H19: (ex3_2 T T (\lambda (u2: T).(\lambda (t3: T).(eq T x (THead (Bind x0)
+u2 t3)))) (\lambda (u2: T).(\lambda (_: T).(subst0 i u x4 u2))) (\lambda (_:
T).(\lambda (t3: T).(subst0 (s (Bind x0) i) u (THead (Flat Appl) (lift (S O)
O x3) x5) t3))))).(ex3_2_ind T T (\lambda (u2: T).(\lambda (t3: T).(eq T x
(THead (Bind x0) u2 t3)))) (\lambda (u2: T).(\lambda (_: T).(subst0 i u x4
(Bind x0) x1 x2)) (refl_equal T (THead (Bind x0) x6 (THead (Flat Appl) (lift
(S O) O x9) x5))) (pr2_delta c d u i H8 u1 x3 H15 x9 H28) (pr2_delta c d u i
H8 x1 x4 H16 x6 H21) (pr2_free (CHead c (Bind x0) x6) x2 x5 H17))) x8
-H26))))) (subst0_gen_lift_ge u x3 x8 (s (Bind x0) i) (S O) O H25 (le_S_n (S
-O) (S i) (lt_le_S (S O) (S (S i)) (lt_n_S O (S i) (le_lt_n_Sm O i (le_O_n
-i))))))) x7 H24)))) H23)) (\lambda (H23: (ex2 T (\lambda (t3: T).(eq T x7
-(THead (Flat Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat
-Appl) (s (Bind x0) i)) u x5 t3)))).(ex2_ind T (\lambda (t3: T).(eq T x7
+H26))))) (subst0_gen_lift_ge u x3 x8 (s (Bind x0) i) (S O) O H25 (le_n_S O i
+(le_O_n i)))) x7 H24)))) H23)) (\lambda (H23: (ex2 T (\lambda (t3: T).(eq T
+x7 (THead (Flat Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s
+(Flat Appl) (s (Bind x0) i)) u x5 t3)))).(ex2_ind T (\lambda (t3: T).(eq T x7
(THead (Flat Appl) (lift (S O) O x3) t3))) (\lambda (t3: T).(subst0 (s (Flat
Appl) (s (Bind x0) i)) u x5 t3)) (or3 (ex3_2 T T (\lambda (u2: T).(\lambda
(t3: T).(eq T (THead (Bind x0) x6 x7) (THead (Flat Appl) u2 t3)))) (\lambda
c d u i H8 x1 x4 H16 x6 H21) (pr2_delta (CHead c (Bind x0) x6) d u (S i)
(getl_clear_bind x0 (CHead c (Bind x0) x6) c x6 (clear_bind x0 c x6) (CHead d
(Bind Abbr) u) i H8) x2 x5 H17 x9 H26))) x8 H27))))) (subst0_gen_lift_ge u x3
-x8 (s (Bind x0) i) (S O) O H25 (le_S_n (S O) (S i) (lt_le_S (S O) (S (S i))
-(lt_n_S O (S i) (le_lt_n_Sm O i (le_O_n i))))))) x7 H24)))))) H23))
+x8 (s (Bind x0) i) (S O) O H25 (le_n_S O i (le_O_n i)))) x7 H24)))))) H23))
(subst0_gen_head (Flat Appl) u (lift (S O) O x3) x5 x7 (s (Bind x0) i) H22))
x H20)))))) H19)) (subst0_gen_head (Bind x0) u x4 (THead (Flat Appl) (lift (S
O) O x3) x5) x i H18)) t1 H13)))))))))))))) H11)) (pr0_gen_appl u1 t1 t2
\def
\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (i: nat).(\forall (j:
nat).((le i j) \to (le (s k0 i) (s k0 j)))))) (\lambda (_: B).(\lambda (i:
-nat).(\lambda (j: nat).(\lambda (H: (le i j)).(le_S_n (S i) (S j) (lt_le_S (S
-i) (S (S j)) (lt_n_S i (S j) (le_lt_n_Sm i j H)))))))) (\lambda (_:
+nat).(\lambda (j: nat).(\lambda (H: (le i j)).(le_n_S i j H))))) (\lambda (_:
F).(\lambda (i: nat).(\lambda (j: nat).(\lambda (H: (le i j)).H)))) k).
theorem s_lt:
\def
\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (i: nat).(\forall (j:
nat).((lt i j) \to (lt (s k0 i) (s k0 j)))))) (\lambda (_: B).(\lambda (i:
-nat).(\lambda (j: nat).(\lambda (H: (lt i j)).(le_S_n (S (S i)) (S j) (le_n_S
-(S (S i)) (S j) (le_n_S (S i) j H))))))) (\lambda (_: F).(\lambda (i:
-nat).(\lambda (j: nat).(\lambda (H: (lt i j)).H)))) k).
+nat).(\lambda (j: nat).(\lambda (H: (lt i j)).(le_n_S (S i) j H))))) (\lambda
+(_: F).(\lambda (i: nat).(\lambda (j: nat).(\lambda (H: (lt i j)).H)))) k).
theorem s_inj:
\forall (k: K).(\forall (i: nat).(\forall (j: nat).((eq nat (s k i) (s k j))
u) (lift (plus h (S n)) O u))) (eq_ind_r nat (plus h (S n)) (\lambda (n0:
nat).(eq T (lift n0 O u) (lift (plus h (S n)) O u))) (refl_equal T (lift
(plus h (S n)) O u)) (S (plus h n)) (plus_n_Sm h n)) (plus n h) (plus_comm n
-h)) (lift h d (lift (S n) O u)) (lift_free u (S n) h O d (le_trans d (S n)
-(plus O (S n)) (le_S d n H1) (le_n (plus O (S n)))) (le_O_n d))) (subst0_lref
-u n)) (minus (plus n h) h) (minus_plus_r n h)) x H4) i H3))) (subst0_gen_lref
-u x i (plus n h) H2)))))))))))) (\lambda (k: K).(\lambda (t: T).(\lambda (H:
+h)) (lift h d (lift (S n) O u)) (lift_free u (S n) h O d (le_trans_plus_r O d
+(plus O (S n)) (plus_le_compat O O d (S n) (le_n O) (le_S d n H1))) (le_O_n
+d))) (subst0_lref u n)) (minus (plus n h) h) (minus_plus_r n h)) x H4) i
+H3))) (subst0_gen_lref u x i (plus n h) H2)))))))))))) (\lambda (k:
+K).(\lambda (t: T).(\lambda (H: ((\forall (x: T).(\forall (i: nat).(\forall
+(h: nat).(\forall (d: nat).((subst0 i u (lift h d t) x) \to ((le (plus d h)
+i) \to (ex2 T (\lambda (t2: T).(eq T x (lift h d t2))) (\lambda (t2:
+T).(subst0 (minus i h) u t t2))))))))))).(\lambda (t0: T).(\lambda (H0:
((\forall (x: T).(\forall (i: nat).(\forall (h: nat).(\forall (d:
-nat).((subst0 i u (lift h d t) x) \to ((le (plus d h) i) \to (ex2 T (\lambda
-(t2: T).(eq T x (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u t
-t2))))))))))).(\lambda (t0: T).(\lambda (H0: ((\forall (x: T).(\forall (i:
-nat).(\forall (h: nat).(\forall (d: nat).((subst0 i u (lift h d t0) x) \to
-((le (plus d h) i) \to (ex2 T (\lambda (t2: T).(eq T x (lift h d t2)))
-(\lambda (t2: T).(subst0 (minus i h) u t0 t2))))))))))).(\lambda (x:
-T).(\lambda (i: nat).(\lambda (h: nat).(\lambda (d: nat).(\lambda (H1:
-(subst0 i u (lift h d (THead k t t0)) x)).(\lambda (H2: (le (plus d h)
-i)).(let H3 \def (eq_ind T (lift h d (THead k t t0)) (\lambda (t2: T).(subst0
-i u t2 x)) H1 (THead k (lift h d t) (lift h (s k d) t0)) (lift_head k t t0 h
-d)) in (or3_ind (ex2 T (\lambda (u2: T).(eq T x (THead k u2 (lift h (s k d)
-t0)))) (\lambda (u2: T).(subst0 i u (lift h d t) u2))) (ex2 T (\lambda (t2:
-T).(eq T x (THead k (lift h d t) t2))) (\lambda (t2: T).(subst0 (s k i) u
-(lift h (s k d) t0) t2))) (ex3_2 T T (\lambda (u2: T).(\lambda (t2: T).(eq T
-x (THead k u2 t2)))) (\lambda (u2: T).(\lambda (_: T).(subst0 i u (lift h d
-t) u2))) (\lambda (_: T).(\lambda (t2: T).(subst0 (s k i) u (lift h (s k d)
-t0) t2)))) (ex2 T (\lambda (t2: T).(eq T x (lift h d t2))) (\lambda (t2:
-T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (H4: (ex2 T (\lambda
-(u2: T).(eq T x (THead k u2 (lift h (s k d) t0)))) (\lambda (u2: T).(subst0 i
-u (lift h d t) u2)))).(ex2_ind T (\lambda (u2: T).(eq T x (THead k u2 (lift h
-(s k d) t0)))) (\lambda (u2: T).(subst0 i u (lift h d t) u2)) (ex2 T (\lambda
-(t2: T).(eq T x (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead
-k t t0) t2))) (\lambda (x0: T).(\lambda (H5: (eq T x (THead k x0 (lift h (s k
-d) t0)))).(\lambda (H6: (subst0 i u (lift h d t) x0)).(eq_ind_r T (THead k x0
-(lift h (s k d) t0)) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift
-h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3))))
-(ex2_ind T (\lambda (t2: T).(eq T x0 (lift h d t2))) (\lambda (t2: T).(subst0
-(minus i h) u t t2)) (ex2 T (\lambda (t2: T).(eq T (THead k x0 (lift h (s k
-d) t0)) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0)
-t2))) (\lambda (x1: T).(\lambda (H7: (eq T x0 (lift h d x1))).(\lambda (H8:
-(subst0 (minus i h) u t x1)).(eq_ind_r T (lift h d x1) (\lambda (t2: T).(ex2
-T (\lambda (t3: T).(eq T (THead k t2 (lift h (s k d) t0)) (lift h d t3)))
-(\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (eq_ind T (lift
-h d (THead k x1 t0)) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift
-h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3))))
-(ex_intro2 T (\lambda (t2: T).(eq T (lift h d (THead k x1 t0)) (lift h d
-t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0) t2)) (THead k x1
-t0) (refl_equal T (lift h d (THead k x1 t0))) (subst0_fst u x1 t (minus i h)
-H8 t0 k)) (THead k (lift h d x1) (lift h (s k d) t0)) (lift_head k x1 t0 h
-d)) x0 H7)))) (H x0 i h d H6 H2)) x H5)))) H4)) (\lambda (H4: (ex2 T (\lambda
-(t2: T).(eq T x (THead k (lift h d t) t2))) (\lambda (t2: T).(subst0 (s k i)
-u (lift h (s k d) t0) t2)))).(ex2_ind T (\lambda (t2: T).(eq T x (THead k
-(lift h d t) t2))) (\lambda (t2: T).(subst0 (s k i) u (lift h (s k d) t0)
-t2)) (ex2 T (\lambda (t2: T).(eq T x (lift h d t2))) (\lambda (t2: T).(subst0
-(minus i h) u (THead k t t0) t2))) (\lambda (x0: T).(\lambda (H5: (eq T x
-(THead k (lift h d t) x0))).(\lambda (H6: (subst0 (s k i) u (lift h (s k d)
-t0) x0)).(eq_ind_r T (THead k (lift h d t) x0) (\lambda (t2: T).(ex2 T
-(\lambda (t3: T).(eq T t2 (lift h d t3))) (\lambda (t3: T).(subst0 (minus i
-h) u (THead k t t0) t3)))) (ex2_ind T (\lambda (t2: T).(eq T x0 (lift h (s k
-d) t2))) (\lambda (t2: T).(subst0 (minus (s k i) h) u t0 t2)) (ex2 T (\lambda
-(t2: T).(eq T (THead k (lift h d t) x0) (lift h d t2))) (\lambda (t2:
+nat).((subst0 i u (lift h d t0) x) \to ((le (plus d h) i) \to (ex2 T (\lambda
+(t2: T).(eq T x (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u t0
+t2))))))))))).(\lambda (x: T).(\lambda (i: nat).(\lambda (h: nat).(\lambda
+(d: nat).(\lambda (H1: (subst0 i u (lift h d (THead k t t0)) x)).(\lambda
+(H2: (le (plus d h) i)).(let H3 \def (eq_ind T (lift h d (THead k t t0))
+(\lambda (t2: T).(subst0 i u t2 x)) H1 (THead k (lift h d t) (lift h (s k d)
+t0)) (lift_head k t t0 h d)) in (or3_ind (ex2 T (\lambda (u2: T).(eq T x
+(THead k u2 (lift h (s k d) t0)))) (\lambda (u2: T).(subst0 i u (lift h d t)
+u2))) (ex2 T (\lambda (t2: T).(eq T x (THead k (lift h d t) t2))) (\lambda
+(t2: T).(subst0 (s k i) u (lift h (s k d) t0) t2))) (ex3_2 T T (\lambda (u2:
+T).(\lambda (t2: T).(eq T x (THead k u2 t2)))) (\lambda (u2: T).(\lambda (_:
+T).(subst0 i u (lift h d t) u2))) (\lambda (_: T).(\lambda (t2: T).(subst0 (s
+k i) u (lift h (s k d) t0) t2)))) (ex2 T (\lambda (t2: T).(eq T x (lift h d
+t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda
+(H4: (ex2 T (\lambda (u2: T).(eq T x (THead k u2 (lift h (s k d) t0))))
+(\lambda (u2: T).(subst0 i u (lift h d t) u2)))).(ex2_ind T (\lambda (u2:
+T).(eq T x (THead k u2 (lift h (s k d) t0)))) (\lambda (u2: T).(subst0 i u
+(lift h d t) u2)) (ex2 T (\lambda (t2: T).(eq T x (lift h d t2))) (\lambda
+(t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (x0: T).(\lambda
+(H5: (eq T x (THead k x0 (lift h (s k d) t0)))).(\lambda (H6: (subst0 i u
+(lift h d t) x0)).(eq_ind_r T (THead k x0 (lift h (s k d) t0)) (\lambda (t2:
+T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d t3))) (\lambda (t3: T).(subst0
+(minus i h) u (THead k t t0) t3)))) (ex2_ind T (\lambda (t2: T).(eq T x0
+(lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u t t2)) (ex2 T (\lambda
+(t2: T).(eq T (THead k x0 (lift h (s k d) t0)) (lift h d t2))) (\lambda (t2:
T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (x1: T).(\lambda (H7:
-(eq T x0 (lift h (s k d) x1))).(\lambda (H8: (subst0 (minus (s k i) h) u t0
-x1)).(eq_ind_r T (lift h (s k d) x1) (\lambda (t2: T).(ex2 T (\lambda (t3:
-T).(eq T (THead k (lift h d t) t2) (lift h d t3))) (\lambda (t3: T).(subst0
-(minus i h) u (THead k t t0) t3)))) (eq_ind T (lift h d (THead k t x1))
-(\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d t3))) (\lambda
-(t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (let H9 \def (eq_ind_r
-nat (minus (s k i) h) (\lambda (n: nat).(subst0 n u t0 x1)) H8 (s k (minus i
-h)) (s_minus k i h (le_trans_plus_r d h i H2))) in (ex_intro2 T (\lambda (t2:
-T).(eq T (lift h d (THead k t x1)) (lift h d t2))) (\lambda (t2: T).(subst0
-(minus i h) u (THead k t t0) t2)) (THead k t x1) (refl_equal T (lift h d
-(THead k t x1))) (subst0_snd k u x1 t0 (minus i h) H9 t))) (THead k (lift h d
-t) (lift h (s k d) x1)) (lift_head k t x1 h d)) x0 H7)))) (H0 x0 (s k i) h (s
-k d) H6 (eq_ind nat (s k (plus d h)) (\lambda (n: nat).(le n (s k i))) (s_le
-k (plus d h) i H2) (plus (s k d) h) (s_plus k d h)))) x H5)))) H4)) (\lambda
-(H4: (ex3_2 T T (\lambda (u2: T).(\lambda (t2: T).(eq T x (THead k u2 t2))))
-(\lambda (u2: T).(\lambda (_: T).(subst0 i u (lift h d t) u2))) (\lambda (_:
-T).(\lambda (t2: T).(subst0 (s k i) u (lift h (s k d) t0) t2))))).(ex3_2_ind
-T T (\lambda (u2: T).(\lambda (t2: T).(eq T x (THead k u2 t2)))) (\lambda
-(u2: T).(\lambda (_: T).(subst0 i u (lift h d t) u2))) (\lambda (_:
-T).(\lambda (t2: T).(subst0 (s k i) u (lift h (s k d) t0) t2))) (ex2 T
-(\lambda (t2: T).(eq T x (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h)
-u (THead k t t0) t2))) (\lambda (x0: T).(\lambda (x1: T).(\lambda (H5: (eq T
-x (THead k x0 x1))).(\lambda (H6: (subst0 i u (lift h d t) x0)).(\lambda (H7:
-(subst0 (s k i) u (lift h (s k d) t0) x1)).(eq_ind_r T (THead k x0 x1)
-(\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d t3))) (\lambda
-(t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (ex2_ind T (\lambda (t2:
-T).(eq T x1 (lift h (s k d) t2))) (\lambda (t2: T).(subst0 (minus (s k i) h)
-u t0 t2)) (ex2 T (\lambda (t2: T).(eq T (THead k x0 x1) (lift h d t2)))
-(\lambda (t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (x2:
-T).(\lambda (H8: (eq T x1 (lift h (s k d) x2))).(\lambda (H9: (subst0 (minus
-(s k i) h) u t0 x2)).(ex2_ind T (\lambda (t2: T).(eq T x0 (lift h d t2)))
-(\lambda (t2: T).(subst0 (minus i h) u t t2)) (ex2 T (\lambda (t2: T).(eq T
-(THead k x0 x1) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead
-k t t0) t2))) (\lambda (x3: T).(\lambda (H10: (eq T x0 (lift h d
-x3))).(\lambda (H11: (subst0 (minus i h) u t x3)).(eq_ind_r T (lift h d x3)
-(\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead k t2 x1) (lift h d
-t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (eq_ind_r
-T (lift h (s k d) x2) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead k
-(lift h d x3) t2) (lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u
-(THead k t t0) t3)))) (eq_ind T (lift h d (THead k x3 x2)) (\lambda (t2:
+(eq T x0 (lift h d x1))).(\lambda (H8: (subst0 (minus i h) u t x1)).(eq_ind_r
+T (lift h d x1) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead k t2
+(lift h (s k d) t0)) (lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u
+(THead k t t0) t3)))) (eq_ind T (lift h d (THead k x1 t0)) (\lambda (t2:
T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d t3))) (\lambda (t3: T).(subst0
-(minus i h) u (THead k t t0) t3)))) (let H12 \def (eq_ind_r nat (minus (s k
-i) h) (\lambda (n: nat).(subst0 n u t0 x2)) H9 (s k (minus i h)) (s_minus k i
-h (le_trans_plus_r d h i H2))) in (ex_intro2 T (\lambda (t2: T).(eq T (lift h
-d (THead k x3 x2)) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u
-(THead k t t0) t2)) (THead k x3 x2) (refl_equal T (lift h d (THead k x3 x2)))
-(subst0_both u t x3 (minus i h) H11 k t0 x2 H12))) (THead k (lift h d x3)
-(lift h (s k d) x2)) (lift_head k x3 x2 h d)) x1 H8) x0 H10)))) (H x0 i h d
-H6 H2))))) (H0 x1 (s k i) h (s k d) H7 (eq_ind nat (s k (plus d h)) (\lambda
-(n: nat).(le n (s k i))) (s_le k (plus d h) i H2) (plus (s k d) h) (s_plus k
-d h)))) x H5)))))) H4)) (subst0_gen_head k u (lift h d t) (lift h (s k d) t0)
-x i H3)))))))))))))) t1)).
+(minus i h) u (THead k t t0) t3)))) (ex_intro2 T (\lambda (t2: T).(eq T (lift
+h d (THead k x1 t0)) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u
+(THead k t t0) t2)) (THead k x1 t0) (refl_equal T (lift h d (THead k x1 t0)))
+(subst0_fst u x1 t (minus i h) H8 t0 k)) (THead k (lift h d x1) (lift h (s k
+d) t0)) (lift_head k x1 t0 h d)) x0 H7)))) (H x0 i h d H6 H2)) x H5)))) H4))
+(\lambda (H4: (ex2 T (\lambda (t2: T).(eq T x (THead k (lift h d t) t2)))
+(\lambda (t2: T).(subst0 (s k i) u (lift h (s k d) t0) t2)))).(ex2_ind T
+(\lambda (t2: T).(eq T x (THead k (lift h d t) t2))) (\lambda (t2: T).(subst0
+(s k i) u (lift h (s k d) t0) t2)) (ex2 T (\lambda (t2: T).(eq T x (lift h d
+t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda
+(x0: T).(\lambda (H5: (eq T x (THead k (lift h d t) x0))).(\lambda (H6:
+(subst0 (s k i) u (lift h (s k d) t0) x0)).(eq_ind_r T (THead k (lift h d t)
+x0) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d t3)))
+(\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (ex2_ind T
+(\lambda (t2: T).(eq T x0 (lift h (s k d) t2))) (\lambda (t2: T).(subst0
+(minus (s k i) h) u t0 t2)) (ex2 T (\lambda (t2: T).(eq T (THead k (lift h d
+t) x0) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0)
+t2))) (\lambda (x1: T).(\lambda (H7: (eq T x0 (lift h (s k d) x1))).(\lambda
+(H8: (subst0 (minus (s k i) h) u t0 x1)).(eq_ind_r T (lift h (s k d) x1)
+(\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T (THead k (lift h d t) t2)
+(lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3))))
+(eq_ind T (lift h d (THead k t x1)) (\lambda (t2: T).(ex2 T (\lambda (t3:
+T).(eq T t2 (lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t
+t0) t3)))) (let H9 \def (eq_ind_r nat (minus (s k i) h) (\lambda (n:
+nat).(subst0 n u t0 x1)) H8 (s k (minus i h)) (s_minus k i h (le_trans_plus_r
+d h i H2))) in (ex_intro2 T (\lambda (t2: T).(eq T (lift h d (THead k t x1))
+(lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead k t t0) t2))
+(THead k t x1) (refl_equal T (lift h d (THead k t x1))) (subst0_snd k u x1 t0
+(minus i h) H9 t))) (THead k (lift h d t) (lift h (s k d) x1)) (lift_head k t
+x1 h d)) x0 H7)))) (H0 x0 (s k i) h (s k d) H6 (eq_ind nat (s k (plus d h))
+(\lambda (n: nat).(le n (s k i))) (s_le k (plus d h) i H2) (plus (s k d) h)
+(s_plus k d h)))) x H5)))) H4)) (\lambda (H4: (ex3_2 T T (\lambda (u2:
+T).(\lambda (t2: T).(eq T x (THead k u2 t2)))) (\lambda (u2: T).(\lambda (_:
+T).(subst0 i u (lift h d t) u2))) (\lambda (_: T).(\lambda (t2: T).(subst0 (s
+k i) u (lift h (s k d) t0) t2))))).(ex3_2_ind T T (\lambda (u2: T).(\lambda
+(t2: T).(eq T x (THead k u2 t2)))) (\lambda (u2: T).(\lambda (_: T).(subst0 i
+u (lift h d t) u2))) (\lambda (_: T).(\lambda (t2: T).(subst0 (s k i) u (lift
+h (s k d) t0) t2))) (ex2 T (\lambda (t2: T).(eq T x (lift h d t2))) (\lambda
+(t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (x0: T).(\lambda
+(x1: T).(\lambda (H5: (eq T x (THead k x0 x1))).(\lambda (H6: (subst0 i u
+(lift h d t) x0)).(\lambda (H7: (subst0 (s k i) u (lift h (s k d) t0)
+x1)).(eq_ind_r T (THead k x0 x1) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq
+T t2 (lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0)
+t3)))) (ex2_ind T (\lambda (t2: T).(eq T x1 (lift h (s k d) t2))) (\lambda
+(t2: T).(subst0 (minus (s k i) h) u t0 t2)) (ex2 T (\lambda (t2: T).(eq T
+(THead k x0 x1) (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u (THead
+k t t0) t2))) (\lambda (x2: T).(\lambda (H8: (eq T x1 (lift h (s k d)
+x2))).(\lambda (H9: (subst0 (minus (s k i) h) u t0 x2)).(ex2_ind T (\lambda
+(t2: T).(eq T x0 (lift h d t2))) (\lambda (t2: T).(subst0 (minus i h) u t
+t2)) (ex2 T (\lambda (t2: T).(eq T (THead k x0 x1) (lift h d t2))) (\lambda
+(t2: T).(subst0 (minus i h) u (THead k t t0) t2))) (\lambda (x3: T).(\lambda
+(H10: (eq T x0 (lift h d x3))).(\lambda (H11: (subst0 (minus i h) u t
+x3)).(eq_ind_r T (lift h d x3) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T
+(THead k t2 x1) (lift h d t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead
+k t t0) t3)))) (eq_ind_r T (lift h (s k d) x2) (\lambda (t2: T).(ex2 T
+(\lambda (t3: T).(eq T (THead k (lift h d x3) t2) (lift h d t3))) (\lambda
+(t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (eq_ind T (lift h d
+(THead k x3 x2)) (\lambda (t2: T).(ex2 T (\lambda (t3: T).(eq T t2 (lift h d
+t3))) (\lambda (t3: T).(subst0 (minus i h) u (THead k t t0) t3)))) (let H12
+\def (eq_ind_r nat (minus (s k i) h) (\lambda (n: nat).(subst0 n u t0 x2)) H9
+(s k (minus i h)) (s_minus k i h (le_trans_plus_r d h i H2))) in (ex_intro2 T
+(\lambda (t2: T).(eq T (lift h d (THead k x3 x2)) (lift h d t2))) (\lambda
+(t2: T).(subst0 (minus i h) u (THead k t t0) t2)) (THead k x3 x2) (refl_equal
+T (lift h d (THead k x3 x2))) (subst0_both u t x3 (minus i h) H11 k t0 x2
+H12))) (THead k (lift h d x3) (lift h (s k d) x2)) (lift_head k x3 x2 h d))
+x1 H8) x0 H10)))) (H x0 i h d H6 H2))))) (H0 x1 (s k i) h (s k d) H7 (eq_ind
+nat (s k (plus d h)) (\lambda (n: nat).(le n (s k i))) (s_le k (plus d h) i
+H2) (plus (s k d) h) (s_plus k d h)))) x H5)))))) H4)) (subst0_gen_head k u
+(lift h d t) (lift h (s k d) t0) x i H3)))))))))))))) t1)).
(lift h d u1) (lift h d u2) i0 (H1 d H4 h) k (lift h (s k d) t0) (lift h (s k
d) t3) (eq_ind nat (minus (s k d) (s k (S i0))) (\lambda (n: nat).(subst0 (s
k i0) (lift h n v) (lift h (s k d) t0) (lift h (s k d) t3))) (H5 (s k d)
-(lt_le_S (s k i0) (s k d) (s_lt k i0 d H4)) h) (minus d (S i0)) (minus_s_s k
-d (S i0)))) (lift h d (THead k u2 t3)) (lift_head k u2 t3 h d)) (lift h d
-(THead k u1 t0)) (lift_head k u1 t0 h d))))))))))))))))) i u t1 t2 H))))).
+(s_lt k i0 d H4) h) (minus d (S i0)) (minus_s_s k d (S i0)))) (lift h d
+(THead k u2 t3)) (lift_head k u2 t3 h d)) (lift h d (THead k u1 t0))
+(lift_head k u1 t0 h d))))))))))))))))) i u t1 t2 H))))).
theorem subst0_lift_ge:
\forall (t1: T).(\forall (t2: T).(\forall (u: T).(\forall (i: nat).(\forall
f g H2 O O (le_n O) n))))))))) b)) (\lambda (_: F).(\lambda (f0: ((nat \to
nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m: nat).(le (f0
m) (g m))))).(\lambda (H3: (lt (weight_map f0 (lift (S i) O v)) (g
-i))).(lt_le_S (plus (weight_map f0 u2) (weight_map f0 t0)) (S (plus
-(weight_map g u1) (weight_map g t0))) (le_lt_n_Sm (plus (weight_map f0 u2)
-(weight_map f0 t0)) (plus (weight_map g u1) (weight_map g t0))
-(plus_le_compat (weight_map f0 u2) (weight_map g u1) (weight_map f0 t0)
-(weight_map g t0) (H1 f0 g H2 H3) (weight_le t0 f0 g H2))))))))) k)))))))))
-(\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (v: T).(\forall (t2:
-T).(\forall (t1: T).(\forall (i: nat).((subst0 (s k0 i) v t1 t2) \to
-(((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
-nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S (s k0 i)) O v)) (g (s
-k0 i))) \to (le (weight_map f t2) (weight_map g t1))))))) \to (\forall (u0:
-T).(\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
-nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to
-(le (weight_map f (THead k0 u0 t2)) (weight_map g (THead k0 u0
-t1))))))))))))))) (\lambda (b: B).(B_ind (\lambda (b0: B).(\forall (v:
-T).(\forall (t2: T).(\forall (t1: T).(\forall (i: nat).((subst0 (s (Bind b0)
-i) v t1 t2) \to (((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
+i))).(le_n_S (plus (weight_map f0 u2) (weight_map f0 t0)) (plus (weight_map g
+u1) (weight_map g t0)) (plus_le_compat (weight_map f0 u2) (weight_map g u1)
+(weight_map f0 t0) (weight_map g t0) (H1 f0 g H2 H3) (weight_le t0 f0 g
+H2)))))))) k))))))))) (\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (v:
+T).(\forall (t2: T).(\forall (t1: T).(\forall (i: nat).((subst0 (s k0 i) v t1
+t2) \to (((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
-(s (Bind b0) i)) O v)) (g (s (Bind b0) i))) \to (le (weight_map f t2)
-(weight_map g t1))))))) \to (\forall (u0: T).(\forall (f: ((nat \to
-nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
-\to ((lt (weight_map f (lift (S i) O v)) (g i)) \to (le (weight_map f (THead
-(Bind b0) u0 t2)) (weight_map g (THead (Bind b0) u0 t1)))))))))))))))
-(\lambda (v: T).(\lambda (t2: T).(\lambda (t1: T).(\lambda (i: nat).(\lambda
-(_: (subst0 (S i) v t1 t2)).(\lambda (H1: ((\forall (f: ((nat \to
+(s k0 i)) O v)) (g (s k0 i))) \to (le (weight_map f t2) (weight_map g
+t1))))))) \to (\forall (u0: T).(\forall (f: ((nat \to nat))).(\forall (g:
+((nat \to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map
+f (lift (S i) O v)) (g i)) \to (le (weight_map f (THead k0 u0 t2))
+(weight_map g (THead k0 u0 t1))))))))))))))) (\lambda (b: B).(B_ind (\lambda
+(b0: B).(\forall (v: T).(\forall (t2: T).(\forall (t1: T).(\forall (i:
+nat).((subst0 (s (Bind b0) i) v t1 t2) \to (((\forall (f: ((nat \to
nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
-\to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (le (weight_map f
-t2) (weight_map g t1)))))))).(\lambda (u0: T).(\lambda (f: ((nat \to
-nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m: nat).(le (f
-m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
+\to ((lt (weight_map f (lift (S (s (Bind b0) i)) O v)) (g (s (Bind b0) i)))
+\to (le (weight_map f t2) (weight_map g t1))))))) \to (\forall (u0:
+T).(\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
+nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to
+(le (weight_map f (THead (Bind b0) u0 t2)) (weight_map g (THead (Bind b0) u0
+t1))))))))))))))) (\lambda (v: T).(\lambda (t2: T).(\lambda (t1: T).(\lambda
+(i: nat).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H1: ((\forall (f:
+((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
+(g m)))) \to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (le
+(weight_map f t2) (weight_map g t1)))))))).(\lambda (u0: T).(\lambda (f:
+((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m:
+nat).(le (f m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
i))).(le_n_S (plus (weight_map f u0) (weight_map (wadd f (S (weight_map f
u0))) t2)) (plus (weight_map g u0) (weight_map (wadd g (S (weight_map g u0)))
t1)) (plus_le_compat (weight_map f u0) (weight_map g u0) (weight_map (wadd f
(weight_le u0 f g H2) (H1 (wadd f (S (weight_map f u0))) (wadd g (S
(weight_map g u0))) (\lambda (m: nat).(wadd_le f g H2 (S (weight_map f u0))
(S (weight_map g u0)) (le_n_S (weight_map f u0) (weight_map g u0) (weight_le
-u0 f g H2)) m)) (lt_le_S (weight_map (wadd f (S (weight_map f u0))) (lift (S
-(S i)) O v)) (wadd g (S (weight_map g u0)) (S i)) (eq_ind nat (weight_map f
-(lift (S i) O v)) (\lambda (n: nat).(lt n (g i))) H3 (weight_map (wadd f (S
-(weight_map f u0))) (lift (S (S i)) O v)) (lift_weight_add_O (S (weight_map f
-u0)) v (S i) f))))))))))))))))) (\lambda (v: T).(\lambda (t2: T).(\lambda
-(t1: T).(\lambda (i: nat).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H1:
-((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
-nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S (S i)) O v)) (g (S
-i))) \to (le (weight_map f t2) (weight_map g t1)))))))).(\lambda (u0:
-T).(\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2:
-((\forall (m: nat).(le (f m) (g m))))).(\lambda (H3: (lt (weight_map f (lift
-(S i) O v)) (g i))).(le_n_S (plus (weight_map f u0) (weight_map (wadd f O)
-t2)) (plus (weight_map g u0) (weight_map (wadd g O) t1)) (plus_le_compat
-(weight_map f u0) (weight_map g u0) (weight_map (wadd f O) t2) (weight_map
-(wadd g O) t1) (weight_le u0 f g H2) (H1 (wadd f O) (wadd g O) (\lambda (m:
-nat).(wadd_le f g H2 O O (le_n O) m)) (eq_ind nat (weight_map f (lift (S i) O
-v)) (\lambda (n: nat).(lt n (g i))) H3 (weight_map (wadd f O) (lift (S (S i))
-O v)) (lift_weight_add_O O v (S i) f)))))))))))))))) (\lambda (v: T).(\lambda
-(t2: T).(\lambda (t1: T).(\lambda (i: nat).(\lambda (_: (subst0 (S i) v t1
+u0 f g H2)) m)) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda (n:
+nat).(lt n (g i))) H3 (weight_map (wadd f (S (weight_map f u0))) (lift (S (S
+i)) O v)) (lift_weight_add_O (S (weight_map f u0)) v (S i) f))))))))))))))))
+(\lambda (v: T).(\lambda (t2: T).(\lambda (t1: T).(\lambda (i: nat).(\lambda
+(_: (subst0 (S i) v t1 t2)).(\lambda (H1: ((\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
+\to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (le (weight_map f
+t2) (weight_map g t1)))))))).(\lambda (u0: T).(\lambda (f: ((nat \to
+nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m: nat).(le (f
+m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
+i))).(le_n_S (plus (weight_map f u0) (weight_map (wadd f O) t2)) (plus
+(weight_map g u0) (weight_map (wadd g O) t1)) (plus_le_compat (weight_map f
+u0) (weight_map g u0) (weight_map (wadd f O) t2) (weight_map (wadd g O) t1)
+(weight_le u0 f g H2) (H1 (wadd f O) (wadd g O) (\lambda (m: nat).(wadd_le f
+g H2 O O (le_n O) m)) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda
+(n: nat).(lt n (g i))) H3 (weight_map (wadd f O) (lift (S (S i)) O v))
+(lift_weight_add_O O v (S i) f)))))))))))))))) (\lambda (v: T).(\lambda (t2:
+T).(\lambda (t1: T).(\lambda (i: nat).(\lambda (_: (subst0 (S i) v t1
t2)).(\lambda (H1: ((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
(S i)) O v)) (g (S i))) \to (le (weight_map f t2) (weight_map g
(S i) O v)) (g i)) \to (le (weight_map f0 t2) (weight_map g
t1)))))))).(\lambda (u0: T).(\lambda (f0: ((nat \to nat))).(\lambda (g: ((nat
\to nat))).(\lambda (H2: ((\forall (m: nat).(le (f0 m) (g m))))).(\lambda
-(H3: (lt (weight_map f0 (lift (S i) O v)) (g i))).(lt_le_S (plus (weight_map
-f0 u0) (weight_map f0 t2)) (S (plus (weight_map g u0) (weight_map g t1)))
-(le_lt_n_Sm (plus (weight_map f0 u0) (weight_map f0 t2)) (plus (weight_map g
-u0) (weight_map g t1)) (plus_le_compat (weight_map f0 u0) (weight_map g u0)
-(weight_map f0 t2) (weight_map g t1) (weight_le u0 f0 g H2) (H1 f0 g H2
-H3)))))))))))))))) k)) (\lambda (v: T).(\lambda (u1: T).(\lambda (u2:
-T).(\lambda (i: nat).(\lambda (_: (subst0 i v u1 u2)).(\lambda (H1: ((\forall
-(f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f
-m) (g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to (le
-(weight_map f u2) (weight_map g u1)))))))).(\lambda (k: K).(K_ind (\lambda
-(k0: K).(\forall (t1: T).(\forall (t2: T).((subst0 (s k0 i) v t1 t2) \to
-(((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
-nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S (s k0 i)) O v)) (g (s
-k0 i))) \to (le (weight_map f t2) (weight_map g t1))))))) \to (\forall (f:
-((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
-(g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to (le (weight_map
-f (THead k0 u2 t2)) (weight_map g (THead k0 u1 t1)))))))))))) (\lambda (b:
-B).(B_ind (\lambda (b0: B).(\forall (t1: T).(\forall (t2: T).((subst0 (s
-(Bind b0) i) v t1 t2) \to (((\forall (f: ((nat \to nat))).(\forall (g: ((nat
+(H3: (lt (weight_map f0 (lift (S i) O v)) (g i))).(le_n_S (plus (weight_map
+f0 u0) (weight_map f0 t2)) (plus (weight_map g u0) (weight_map g t1))
+(plus_le_compat (weight_map f0 u0) (weight_map g u0) (weight_map f0 t2)
+(weight_map g t1) (weight_le u0 f0 g H2) (H1 f0 g H2 H3))))))))))))))) k))
+(\lambda (v: T).(\lambda (u1: T).(\lambda (u2: T).(\lambda (i: nat).(\lambda
+(_: (subst0 i v u1 u2)).(\lambda (H1: ((\forall (f: ((nat \to nat))).(\forall
+(g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt
+(weight_map f (lift (S i) O v)) (g i)) \to (le (weight_map f u2) (weight_map
+g u1)))))))).(\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (t1:
+T).(\forall (t2: T).((subst0 (s k0 i) v t1 t2) \to (((\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
+\to ((lt (weight_map f (lift (S (s k0 i)) O v)) (g (s k0 i))) \to (le
+(weight_map f t2) (weight_map g t1))))))) \to (\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
+\to ((lt (weight_map f (lift (S i) O v)) (g i)) \to (le (weight_map f (THead
+k0 u2 t2)) (weight_map g (THead k0 u1 t1)))))))))))) (\lambda (b: B).(B_ind
+(\lambda (b0: B).(\forall (t1: T).(\forall (t2: T).((subst0 (s (Bind b0) i) v
+t1 t2) \to (((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
+nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
+(s (Bind b0) i)) O v)) (g (s (Bind b0) i))) \to (le (weight_map f t2)
+(weight_map g t1))))))) \to (\forall (f: ((nat \to nat))).(\forall (g: ((nat
\to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f
-(lift (S (s (Bind b0) i)) O v)) (g (s (Bind b0) i))) \to (le (weight_map f
-t2) (weight_map g t1))))))) \to (\forall (f: ((nat \to nat))).(\forall (g:
-((nat \to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map
-f (lift (S i) O v)) (g i)) \to (le (weight_map f (THead (Bind b0) u2 t2))
+(lift (S i) O v)) (g i)) \to (le (weight_map f (THead (Bind b0) u2 t2))
(weight_map g (THead (Bind b0) u1 t1)))))))))))) (\lambda (t1: T).(\lambda
(t2: T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3: ((\forall (f:
((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
(S (weight_map f u2))) t2) (weight_map (wadd g (S (weight_map g u1))) t1) (H1
f g H4 H5) (H3 (wadd f (S (weight_map f u2))) (wadd g (S (weight_map g u1)))
(\lambda (m: nat).(wadd_le f g H4 (S (weight_map f u2)) (S (weight_map g u1))
-(le_n_S (weight_map f u2) (weight_map g u1) (H1 f g H4 H5)) m)) (lt_le_S
-(weight_map (wadd f (S (weight_map f u2))) (lift (S (S i)) O v)) (wadd g (S
-(weight_map g u1)) (S i)) (eq_ind nat (weight_map f (lift (S i) O v))
-(\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f (S (weight_map f u2)))
-(lift (S (S i)) O v)) (lift_weight_add_O (S (weight_map f u2)) v (S i)
-f)))))))))))))) (\lambda (t1: T).(\lambda (t2: T).(\lambda (_: (subst0 (S i)
-v t1 t2)).(\lambda (H3: ((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
-nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
-(S i)) O v)) (g (S i))) \to (le (weight_map f t2) (weight_map g
-t1)))))))).(\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to
-nat))).(\lambda (H4: ((\forall (m: nat).(le (f m) (g m))))).(\lambda (H5: (lt
-(weight_map f (lift (S i) O v)) (g i))).(le_n_S (plus (weight_map f u2)
-(weight_map (wadd f O) t2)) (plus (weight_map g u1) (weight_map (wadd g O)
-t1)) (plus_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd f
-O) t2) (weight_map (wadd g O) t1) (H1 f g H4 H5) (H3 (wadd f O) (wadd g O)
-(\lambda (m: nat).(wadd_le f g H4 O O (le_n O) m)) (eq_ind nat (weight_map f
-(lift (S i) O v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f O)
-(lift (S (S i)) O v)) (lift_weight_add_O O v (S i) f))))))))))))) (\lambda
-(t1: T).(\lambda (t2: T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3:
+(le_n_S (weight_map f u2) (weight_map g u1) (H1 f g H4 H5)) m)) (eq_ind nat
+(weight_map f (lift (S i) O v)) (\lambda (n: nat).(lt n (g i))) H5
+(weight_map (wadd f (S (weight_map f u2))) (lift (S (S i)) O v))
+(lift_weight_add_O (S (weight_map f u2)) v (S i) f))))))))))))) (\lambda (t1:
+T).(\lambda (t2: T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3:
((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S (S i)) O v)) (g (S
i))) \to (le (weight_map f t2) (weight_map g t1)))))))).(\lambda (f: ((nat
(H1 f g H4 H5) (H3 (wadd f O) (wadd g O) (\lambda (m: nat).(wadd_le f g H4 O
O (le_n O) m)) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda (n:
nat).(lt n (g i))) H5 (weight_map (wadd f O) (lift (S (S i)) O v))
-(lift_weight_add_O O v (S i) f))))))))))))) b)) (\lambda (_: F).(\lambda (t1:
-T).(\lambda (t2: T).(\lambda (_: (subst0 i v t1 t2)).(\lambda (H3: ((\forall
-(f0: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le
-(f0 m) (g m)))) \to ((lt (weight_map f0 (lift (S i) O v)) (g i)) \to (le
-(weight_map f0 t2) (weight_map g t1)))))))).(\lambda (f0: ((nat \to
-nat))).(\lambda (g: ((nat \to nat))).(\lambda (H4: ((\forall (m: nat).(le (f0
-m) (g m))))).(\lambda (H5: (lt (weight_map f0 (lift (S i) O v)) (g
-i))).(lt_le_S (plus (weight_map f0 u2) (weight_map f0 t2)) (S (plus
-(weight_map g u1) (weight_map g t1))) (le_lt_n_Sm (plus (weight_map f0 u2)
+(lift_weight_add_O O v (S i) f))))))))))))) (\lambda (t1: T).(\lambda (t2:
+T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3: ((\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
+\to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (le (weight_map f
+t2) (weight_map g t1)))))))).(\lambda (f: ((nat \to nat))).(\lambda (g: ((nat
+\to nat))).(\lambda (H4: ((\forall (m: nat).(le (f m) (g m))))).(\lambda (H5:
+(lt (weight_map f (lift (S i) O v)) (g i))).(le_n_S (plus (weight_map f u2)
+(weight_map (wadd f O) t2)) (plus (weight_map g u1) (weight_map (wadd g O)
+t1)) (plus_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd f
+O) t2) (weight_map (wadd g O) t1) (H1 f g H4 H5) (H3 (wadd f O) (wadd g O)
+(\lambda (m: nat).(wadd_le f g H4 O O (le_n O) m)) (eq_ind nat (weight_map f
+(lift (S i) O v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f O)
+(lift (S (S i)) O v)) (lift_weight_add_O O v (S i) f))))))))))))) b))
+(\lambda (_: F).(\lambda (t1: T).(\lambda (t2: T).(\lambda (_: (subst0 i v t1
+t2)).(\lambda (H3: ((\forall (f0: ((nat \to nat))).(\forall (g: ((nat \to
+nat))).(((\forall (m: nat).(le (f0 m) (g m)))) \to ((lt (weight_map f0 (lift
+(S i) O v)) (g i)) \to (le (weight_map f0 t2) (weight_map g
+t1)))))))).(\lambda (f0: ((nat \to nat))).(\lambda (g: ((nat \to
+nat))).(\lambda (H4: ((\forall (m: nat).(le (f0 m) (g m))))).(\lambda (H5:
+(lt (weight_map f0 (lift (S i) O v)) (g i))).(le_n_S (plus (weight_map f0 u2)
(weight_map f0 t2)) (plus (weight_map g u1) (weight_map g t1))
(plus_le_compat (weight_map f0 u2) (weight_map g u1) (weight_map f0 t2)
-(weight_map g t1) (H1 f0 g H4 H5) (H3 f0 g H4 H5))))))))))))) k)))))))) d u t
+(weight_map g t1) (H1 f0 g H4 H5) (H3 f0 g H4 H5)))))))))))) k)))))))) d u t
z H))))).
theorem subst0_weight_lt:
(plus_lt_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd f (S
(weight_map f u2))) t0) (weight_map (wadd g (S (weight_map g u1))) t0) (H1 f
g H2 H3) (weight_le t0 (wadd f (S (weight_map f u2))) (wadd g (S (weight_map
-g u1))) (\lambda (n: nat).(wadd_le f g H2 (S (weight_map f u2)) (S
-(weight_map g u1)) (le_S (S (weight_map f u2)) (weight_map g u1) (lt_le_S
-(weight_map f u2) (weight_map g u1) (H1 f g H2 H3))) n))))))))) (\lambda (f:
+g u1))) (\lambda (n: nat).(wadd_lt f g H2 (S (weight_map f u2)) (S
+(weight_map g u1)) (lt_n_S (weight_map f u2) (weight_map g u1) (H1 f g H2
+H3)) n))))))))) (\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to
+nat))).(\lambda (H2: ((\forall (m: nat).(le (f m) (g m))))).(\lambda (H3: (lt
+(weight_map f (lift (S i) O v)) (g i))).(lt_n_S (plus (weight_map f u2)
+(weight_map (wadd f O) t0)) (plus (weight_map g u1) (weight_map (wadd g O)
+t0)) (plus_lt_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd
+f O) t0) (weight_map (wadd g O) t0) (H1 f g H2 H3) (weight_le t0 (wadd f O)
+(wadd g O) (\lambda (n: nat).(le_S_n (wadd f O n) (wadd g O n) (le_n_S (wadd
+f O n) (wadd g O n) (wadd_le f g H2 O O (le_n O) n))))))))))) (\lambda (f:
((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m:
nat).(le (f m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
i))).(lt_n_S (plus (weight_map f u2) (weight_map (wadd f O) t0)) (plus
f u2) (weight_map g u1) (weight_map (wadd f O) t0) (weight_map (wadd g O) t0)
(H1 f g H2 H3) (weight_le t0 (wadd f O) (wadd g O) (\lambda (n: nat).(le_S_n
(wadd f O n) (wadd g O n) (le_n_S (wadd f O n) (wadd g O n) (wadd_le f g H2 O
-O (le_n O) n))))))))))) (\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to
-nat))).(\lambda (H2: ((\forall (m: nat).(le (f m) (g m))))).(\lambda (H3: (lt
-(weight_map f (lift (S i) O v)) (g i))).(lt_n_S (plus (weight_map f u2)
-(weight_map (wadd f O) t0)) (plus (weight_map g u1) (weight_map (wadd g O)
-t0)) (plus_lt_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd
-f O) t0) (weight_map (wadd g O) t0) (H1 f g H2 H3) (weight_le t0 (wadd f O)
-(wadd g O) (\lambda (n: nat).(le_S_n (wadd f O n) (wadd g O n) (le_n_S (wadd
-f O n) (wadd g O n) (wadd_le f g H2 O O (le_n O) n))))))))))) b)) (\lambda
-(_: F).(\lambda (f0: ((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda
-(H2: ((\forall (m: nat).(le (f0 m) (g m))))).(\lambda (H3: (lt (weight_map f0
-(lift (S i) O v)) (g i))).(lt_n_S (plus (weight_map f0 u2) (weight_map f0
-t0)) (plus (weight_map g u1) (weight_map g t0)) (plus_lt_le_compat
-(weight_map f0 u2) (weight_map g u1) (weight_map f0 t0) (weight_map g t0) (H1
-f0 g H2 H3) (weight_le t0 f0 g H2)))))))) k))))))))) (\lambda (k: K).(K_ind
-(\lambda (k0: K).(\forall (v: T).(\forall (t2: T).(\forall (t1: T).(\forall
-(i: nat).((subst0 (s k0 i) v t1 t2) \to (((\forall (f: ((nat \to
+O (le_n O) n))))))))))) b)) (\lambda (_: F).(\lambda (f0: ((nat \to
+nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m: nat).(le (f0
+m) (g m))))).(\lambda (H3: (lt (weight_map f0 (lift (S i) O v)) (g
+i))).(lt_n_S (plus (weight_map f0 u2) (weight_map f0 t0)) (plus (weight_map g
+u1) (weight_map g t0)) (plus_lt_le_compat (weight_map f0 u2) (weight_map g
+u1) (weight_map f0 t0) (weight_map g t0) (H1 f0 g H2 H3) (weight_le t0 f0 g
+H2)))))))) k))))))))) (\lambda (k: K).(K_ind (\lambda (k0: K).(\forall (v:
+T).(\forall (t2: T).(\forall (t1: T).(\forall (i: nat).((subst0 (s k0 i) v t1
+t2) \to (((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
+nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
+(s k0 i)) O v)) (g (s k0 i))) \to (lt (weight_map f t2) (weight_map g
+t1))))))) \to (\forall (u0: T).(\forall (f: ((nat \to nat))).(\forall (g:
+((nat \to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map
+f (lift (S i) O v)) (g i)) \to (lt (weight_map f (THead k0 u0 t2))
+(weight_map g (THead k0 u0 t1))))))))))))))) (\lambda (b: B).(B_ind (\lambda
+(b0: B).(\forall (v: T).(\forall (t2: T).(\forall (t1: T).(\forall (i:
+nat).((subst0 (s (Bind b0) i) v t1 t2) \to (((\forall (f: ((nat \to
nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
-\to ((lt (weight_map f (lift (S (s k0 i)) O v)) (g (s k0 i))) \to (lt
-(weight_map f t2) (weight_map g t1))))))) \to (\forall (u0: T).(\forall (f:
-((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
-(g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to (lt (weight_map
-f (THead k0 u0 t2)) (weight_map g (THead k0 u0 t1))))))))))))))) (\lambda (b:
-B).(B_ind (\lambda (b0: B).(\forall (v: T).(\forall (t2: T).(\forall (t1:
-T).(\forall (i: nat).((subst0 (s (Bind b0) i) v t1 t2) \to (((\forall (f:
-((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
-(g m)))) \to ((lt (weight_map f (lift (S (s (Bind b0) i)) O v)) (g (s (Bind
-b0) i))) \to (lt (weight_map f t2) (weight_map g t1))))))) \to (\forall (u0:
+\to ((lt (weight_map f (lift (S (s (Bind b0) i)) O v)) (g (s (Bind b0) i)))
+\to (lt (weight_map f t2) (weight_map g t1))))))) \to (\forall (u0:
T).(\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S i) O v)) (g i)) \to
(lt (weight_map f (THead (Bind b0) u0 t2)) (weight_map g (THead (Bind b0) u0
f (S (weight_map f u0))) t2) (weight_map (wadd g (S (weight_map g u0))) t1)
(weight_le u0 f g H2) (H1 (wadd f (S (weight_map f u0))) (wadd g (S
(weight_map g u0))) (\lambda (m: nat).(wadd_le f g H2 (S (weight_map f u0))
-(S (weight_map g u0)) (lt_le_S (weight_map f u0) (S (weight_map g u0))
-(le_lt_n_Sm (weight_map f u0) (weight_map g u0) (weight_le u0 f g H2))) m))
-(lt_le_S (weight_map (wadd f (S (weight_map f u0))) (lift (S (S i)) O v))
-(wadd g (S (weight_map g u0)) (S i)) (eq_ind nat (weight_map f (lift (S i) O
-v)) (\lambda (n: nat).(lt n (g i))) H3 (weight_map (wadd f (S (weight_map f
-u0))) (lift (S (S i)) O v)) (lift_weight_add_O (S (weight_map f u0)) v (S i)
-f))))))))))))))))) (\lambda (v: T).(\lambda (t2: T).(\lambda (t1: T).(\lambda
-(i: nat).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H1: ((\forall (f:
-((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m)
-(g m)))) \to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (lt
-(weight_map f t2) (weight_map g t1)))))))).(\lambda (u0: T).(\lambda (f:
-((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m:
-nat).(le (f m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
+(S (weight_map g u0)) (le_n_S (weight_map f u0) (weight_map g u0) (weight_le
+u0 f g H2)) m)) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda (n:
+nat).(lt n (g i))) H3 (weight_map (wadd f (S (weight_map f u0))) (lift (S (S
+i)) O v)) (lift_weight_add_O (S (weight_map f u0)) v (S i) f))))))))))))))))
+(\lambda (v: T).(\lambda (t2: T).(\lambda (t1: T).(\lambda (i: nat).(\lambda
+(_: (subst0 (S i) v t1 t2)).(\lambda (H1: ((\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m))))
+\to ((lt (weight_map f (lift (S (S i)) O v)) (g (S i))) \to (lt (weight_map f
+t2) (weight_map g t1)))))))).(\lambda (u0: T).(\lambda (f: ((nat \to
+nat))).(\lambda (g: ((nat \to nat))).(\lambda (H2: ((\forall (m: nat).(le (f
+m) (g m))))).(\lambda (H3: (lt (weight_map f (lift (S i) O v)) (g
i))).(lt_n_S (plus (weight_map f u0) (weight_map (wadd f O) t2)) (plus
(weight_map g u0) (weight_map (wadd g O) t1)) (plus_le_lt_compat (weight_map
f u0) (weight_map g u0) (weight_map (wadd f O) t2) (weight_map (wadd g O) t1)
t1)) (plus_lt_le_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd
f (S (weight_map f u2))) t2) (weight_map (wadd g (S (weight_map g u1))) t1)
(H1 f g H4 H5) (subst0_weight_le v t1 t2 (S i) H2 (wadd f (S (weight_map f
-u2))) (wadd g (S (weight_map g u1))) (\lambda (m: nat).(wadd_le f g H4 (S
-(weight_map f u2)) (S (weight_map g u1)) (le_S (S (weight_map f u2))
-(weight_map g u1) (lt_le_S (weight_map f u2) (weight_map g u1) (H1 f g H4
-H5))) m)) (lt_le_S (weight_map (wadd f (S (weight_map f u2))) (lift (S (S i))
-O v)) (wadd g (S (weight_map g u1)) (S i)) (eq_ind nat (weight_map f (lift (S
-i) O v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f (S
-(weight_map f u2))) (lift (S (S i)) O v)) (lift_weight_add_O (S (weight_map f
-u2)) v (S i) f)))))))))))))) (\lambda (t1: T).(\lambda (t2: T).(\lambda (_:
-(subst0 (S i) v t1 t2)).(\lambda (H3: ((\forall (f: ((nat \to nat))).(\forall
-(g: ((nat \to nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt
-(weight_map f (lift (S (S i)) O v)) (g (S i))) \to (lt (weight_map f t2)
-(weight_map g t1)))))))).(\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to
+u2))) (wadd g (S (weight_map g u1))) (\lambda (m: nat).(wadd_lt f g H4 (S
+(weight_map f u2)) (S (weight_map g u1)) (lt_n_S (weight_map f u2)
+(weight_map g u1) (H1 f g H4 H5)) m)) (eq_ind nat (weight_map f (lift (S i) O
+v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f (S (weight_map f
+u2))) (lift (S (S i)) O v)) (lift_weight_add_O (S (weight_map f u2)) v (S i)
+f))))))))))))) (\lambda (t1: T).(\lambda (t2: T).(\lambda (_: (subst0 (S i) v
+t1 t2)).(\lambda (H3: ((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
+nat))).(((\forall (m: nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S
+(S i)) O v)) (g (S i))) \to (lt (weight_map f t2) (weight_map g
+t1)))))))).(\lambda (f: ((nat \to nat))).(\lambda (g: ((nat \to
nat))).(\lambda (H4: ((\forall (m: nat).(le (f m) (g m))))).(\lambda (H5: (lt
(weight_map f (lift (S i) O v)) (g i))).(lt_n_S (plus (weight_map f u2)
(weight_map (wadd f O) t2)) (plus (weight_map g u1) (weight_map (wadd g O)
t1)) (plus_lt_compat (weight_map f u2) (weight_map g u1) (weight_map (wadd f
O) t2) (weight_map (wadd g O) t1) (H1 f g H4 H5) (H3 (wadd f O) (wadd g O)
(\lambda (m: nat).(le_S_n (wadd f O m) (wadd g O m) (le_n_S (wadd f O m)
-(wadd g O m) (wadd_le f g H4 O O (le_n O) m)))) (lt_le_S (weight_map (wadd f
-O) (lift (S (S i)) O v)) (wadd g O (S i)) (eq_ind nat (weight_map f (lift (S
-i) O v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f O) (lift (S
-(S i)) O v)) (lift_weight_add_O O v (S i) f)))))))))))))) (\lambda (t1:
-T).(\lambda (t2: T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3:
+(wadd g O m) (wadd_le f g H4 O O (le_n O) m)))) (eq_ind nat (weight_map f
+(lift (S i) O v)) (\lambda (n: nat).(lt n (g i))) H5 (weight_map (wadd f O)
+(lift (S (S i)) O v)) (lift_weight_add_O O v (S i) f))))))))))))) (\lambda
+(t1: T).(\lambda (t2: T).(\lambda (_: (subst0 (S i) v t1 t2)).(\lambda (H3:
((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (m:
nat).(le (f m) (g m)))) \to ((lt (weight_map f (lift (S (S i)) O v)) (g (S
i))) \to (lt (weight_map f t2) (weight_map g t1)))))))).(\lambda (f: ((nat
u2) (weight_map g u1) (weight_map (wadd f O) t2) (weight_map (wadd g O) t1)
(H1 f g H4 H5) (H3 (wadd f O) (wadd g O) (\lambda (m: nat).(le_S_n (wadd f O
m) (wadd g O m) (le_n_S (wadd f O m) (wadd g O m) (wadd_le f g H4 O O (le_n
-O) m)))) (lt_le_S (weight_map (wadd f O) (lift (S (S i)) O v)) (wadd g O (S
-i)) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda (n: nat).(lt n (g
-i))) H5 (weight_map (wadd f O) (lift (S (S i)) O v)) (lift_weight_add_O O v
-(S i) f)))))))))))))) b)) (\lambda (_: F).(\lambda (t1: T).(\lambda (t2:
+O) m)))) (eq_ind nat (weight_map f (lift (S i) O v)) (\lambda (n: nat).(lt n
+(g i))) H5 (weight_map (wadd f O) (lift (S (S i)) O v)) (lift_weight_add_O O
+v (S i) f))))))))))))) b)) (\lambda (_: F).(\lambda (t1: T).(\lambda (t2:
T).(\lambda (_: (subst0 i v t1 t2)).(\lambda (H3: ((\forall (f0: ((nat \to
nat))).(\forall (g: ((nat \to nat))).(((\forall (m: nat).(le (f0 m) (g m))))
\to ((lt (weight_map f0 (lift (S i) O v)) (g i)) \to (lt (weight_map f0 t2)
include "tau1/cnt.ma".
-include "gz/props.ma".
+include "ex0/props.ma".
include "wcpr0/fwd.ma".
((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (n: nat).(le (f n)
(g n)))) \to (le (weight_map f t1) (weight_map g t1))))))).(\lambda (f: ((nat
\to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H1: ((\forall (n: nat).(le
-(f n) (g n))))).(le_S_n (S (plus (weight_map f t0) (weight_map (wadd f O)
-t1))) (S (plus (weight_map g t0) (weight_map (wadd g O) t1))) (le_n_S (S
-(plus (weight_map f t0) (weight_map (wadd f O) t1))) (S (plus (weight_map g
-t0) (weight_map (wadd g O) t1))) (le_n_S (plus (weight_map f t0) (weight_map
-(wadd f O) t1)) (plus (weight_map g t0) (weight_map (wadd g O) t1))
-(plus_le_compat (weight_map f t0) (weight_map g t0) (weight_map (wadd f O)
-t1) (weight_map (wadd g O) t1) (H f g H1) (H0 (wadd f O) (wadd g O) (\lambda
-(n: nat).(wadd_le f g H1 O O (le_n O) n)))))))))))))) (\lambda (t0:
-T).(\lambda (H: ((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
-nat))).(((\forall (n: nat).(le (f n) (g n)))) \to (le (weight_map f t0)
-(weight_map g t0))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (f: ((nat
-\to nat))).(\forall (g: ((nat \to nat))).(((\forall (n: nat).(le (f n) (g
-n)))) \to (le (weight_map f t1) (weight_map g t1))))))).(\lambda (f: ((nat
+(f n) (g n))))).(le_n_S (plus (weight_map f t0) (weight_map (wadd f O) t1))
+(plus (weight_map g t0) (weight_map (wadd g O) t1)) (plus_le_compat
+(weight_map f t0) (weight_map g t0) (weight_map (wadd f O) t1) (weight_map
+(wadd g O) t1) (H f g H1) (H0 (wadd f O) (wadd g O) (\lambda (n:
+nat).(wadd_le f g H1 O O (le_n O) n)))))))))))) (\lambda (t0: T).(\lambda (H:
+((\forall (f: ((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (n:
+nat).(le (f n) (g n)))) \to (le (weight_map f t0) (weight_map g
+t0))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (f: ((nat \to
+nat))).(\forall (g: ((nat \to nat))).(((\forall (n: nat).(le (f n) (g n))))
+\to (le (weight_map f t1) (weight_map g t1))))))).(\lambda (f: ((nat \to
+nat))).(\lambda (g: ((nat \to nat))).(\lambda (H1: ((\forall (n: nat).(le (f
+n) (g n))))).(le_n_S (plus (weight_map f t0) (weight_map (wadd f O) t1))
+(plus (weight_map g t0) (weight_map (wadd g O) t1)) (plus_le_compat
+(weight_map f t0) (weight_map g t0) (weight_map (wadd f O) t1) (weight_map
+(wadd g O) t1) (H f g H1) (H0 (wadd f O) (wadd g O) (\lambda (n:
+nat).(wadd_le f g H1 O O (le_n O) n)))))))))))) b)) (\lambda (_: F).(\lambda
+(t0: T).(\lambda (H: ((\forall (f0: ((nat \to nat))).(\forall (g: ((nat \to
+nat))).(((\forall (n: nat).(le (f0 n) (g n)))) \to (le (weight_map f0 t0)
+(weight_map g t0))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (f0: ((nat
+\to nat))).(\forall (g: ((nat \to nat))).(((\forall (n: nat).(le (f0 n) (g
+n)))) \to (le (weight_map f0 t1) (weight_map g t1))))))).(\lambda (f0: ((nat
\to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H1: ((\forall (n: nat).(le
-(f n) (g n))))).(le_S_n (S (plus (weight_map f t0) (weight_map (wadd f O)
-t1))) (S (plus (weight_map g t0) (weight_map (wadd g O) t1))) (le_n_S (S
-(plus (weight_map f t0) (weight_map (wadd f O) t1))) (S (plus (weight_map g
-t0) (weight_map (wadd g O) t1))) (le_n_S (plus (weight_map f t0) (weight_map
-(wadd f O) t1)) (plus (weight_map g t0) (weight_map (wadd g O) t1))
-(plus_le_compat (weight_map f t0) (weight_map g t0) (weight_map (wadd f O)
-t1) (weight_map (wadd g O) t1) (H f g H1) (H0 (wadd f O) (wadd g O) (\lambda
-(n: nat).(wadd_le f g H1 O O (le_n O) n)))))))))))))) b)) (\lambda (_:
-F).(\lambda (t0: T).(\lambda (H: ((\forall (f0: ((nat \to nat))).(\forall (g:
-((nat \to nat))).(((\forall (n: nat).(le (f0 n) (g n)))) \to (le (weight_map
-f0 t0) (weight_map g t0))))))).(\lambda (t1: T).(\lambda (H0: ((\forall (f0:
-((nat \to nat))).(\forall (g: ((nat \to nat))).(((\forall (n: nat).(le (f0 n)
-(g n)))) \to (le (weight_map f0 t1) (weight_map g t1))))))).(\lambda (f0:
-((nat \to nat))).(\lambda (g: ((nat \to nat))).(\lambda (H1: ((\forall (n:
-nat).(le (f0 n) (g n))))).(lt_le_S (plus (weight_map f0 t0) (weight_map f0
-t1)) (S (plus (weight_map g t0) (weight_map g t1))) (le_lt_n_Sm (plus
-(weight_map f0 t0) (weight_map f0 t1)) (plus (weight_map g t0) (weight_map g
-t1)) (plus_le_compat (weight_map f0 t0) (weight_map g t0) (weight_map f0 t1)
-(weight_map g t1) (H f0 g H1) (H0 f0 g H1)))))))))))) k)) t).
+(f0 n) (g n))))).(le_n_S (plus (weight_map f0 t0) (weight_map f0 t1)) (plus
+(weight_map g t0) (weight_map g t1)) (plus_le_compat (weight_map f0 t0)
+(weight_map g t0) (weight_map f0 t1) (weight_map g t1) (H f0 g H1) (H0 f0 g
+H1))))))))))) k)) t).
theorem weight_eq:
\forall (t: T).(\forall (f: ((nat \to nat))).(\forall (g: ((nat \to
O) t) (weight_map (wadd (\lambda (_: nat).O) (S m)) t)))
\def
\lambda (t: T).(\lambda (m: nat).(weight_le t (wadd (\lambda (_: nat).O) O)
-(wadd (\lambda (_: nat).O) (S m)) (\lambda (n: nat).(le_S_n (wadd (\lambda
-(_: nat).O) O n) (wadd (\lambda (_: nat).O) (S m) n) (le_n_S (wadd (\lambda
-(_: nat).O) O n) (wadd (\lambda (_: nat).O) (S m) n) (wadd_le (\lambda (_:
-nat).O) (\lambda (_: nat).O) (\lambda (_: nat).(le_n O)) O (S m) (le_O_n (S
-m)) n)))))).
+(wadd (\lambda (_: nat).O) (S m)) (\lambda (n: nat).(wadd_le (\lambda (_:
+nat).O) (\lambda (_: nat).O) (\lambda (_: nat).(le_n O)) O (S m) (le_S O m
+(le_O_n m)) n)))).
theorem tlt_trans:
\forall (v: T).(\forall (u: T).(\forall (t: T).((tlt u v) \to ((tlt v t) \to
\Rightarrow (S (plus (weight_map (\lambda (_: nat).O) u) (weight_map (wadd
(\lambda (_: nat).O) O) t))) | Void \Rightarrow (S (plus (weight_map (\lambda
(_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O) t)))]))))) (\lambda
-(u: T).(\lambda (t: T).(le_S_n (S (weight_map (\lambda (_: nat).O) u)) (S
-(plus (weight_map (\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_:
-nat).O) (S (weight_map (\lambda (_: nat).O) u))) t))) (le_n_S (S (weight_map
-(\lambda (_: nat).O) u)) (S (plus (weight_map (\lambda (_: nat).O) u)
-(weight_map (wadd (\lambda (_: nat).O) (S (weight_map (\lambda (_: nat).O)
-u))) t))) (le_n_S (weight_map (\lambda (_: nat).O) u) (plus (weight_map
-(\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) (S (weight_map
-(\lambda (_: nat).O) u))) t)) (le_plus_l (weight_map (\lambda (_: nat).O) u)
-(weight_map (wadd (\lambda (_: nat).O) (S (weight_map (\lambda (_: nat).O)
-u))) t))))))) (\lambda (u: T).(\lambda (t: T).(le_S_n (S (weight_map (\lambda
-(_: nat).O) u)) (S (plus (weight_map (\lambda (_: nat).O) u) (weight_map
-(wadd (\lambda (_: nat).O) O) t))) (le_n_S (S (weight_map (\lambda (_:
-nat).O) u)) (S (plus (weight_map (\lambda (_: nat).O) u) (weight_map (wadd
-(\lambda (_: nat).O) O) t))) (le_n_S (weight_map (\lambda (_: nat).O) u)
-(plus (weight_map (\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_:
-nat).O) O) t)) (le_plus_l (weight_map (\lambda (_: nat).O) u) (weight_map
-(wadd (\lambda (_: nat).O) O) t))))))) (\lambda (u: T).(\lambda (t:
-T).(le_S_n (S (weight_map (\lambda (_: nat).O) u)) (S (plus (weight_map
-(\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O) t)))
-(le_n_S (S (weight_map (\lambda (_: nat).O) u)) (S (plus (weight_map (\lambda
-(_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O) t))) (le_n_S
+(u: T).(\lambda (t: T).(le_n_S (weight_map (\lambda (_: nat).O) u) (plus
+(weight_map (\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) (S
+(weight_map (\lambda (_: nat).O) u))) t)) (le_plus_l (weight_map (\lambda (_:
+nat).O) u) (weight_map (wadd (\lambda (_: nat).O) (S (weight_map (\lambda (_:
+nat).O) u))) t))))) (\lambda (u: T).(\lambda (t: T).(le_n_S (weight_map
+(\lambda (_: nat).O) u) (plus (weight_map (\lambda (_: nat).O) u) (weight_map
+(wadd (\lambda (_: nat).O) O) t)) (le_plus_l (weight_map (\lambda (_: nat).O)
+u) (weight_map (wadd (\lambda (_: nat).O) O) t))))) (\lambda (u: T).(\lambda
+(t: T).(le_n_S (weight_map (\lambda (_: nat).O) u) (plus (weight_map (\lambda
+(_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O) t)) (le_plus_l
+(weight_map (\lambda (_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O)
+t))))) b)) (\lambda (_: F).(\lambda (u: T).(\lambda (t: T).(le_n_S
(weight_map (\lambda (_: nat).O) u) (plus (weight_map (\lambda (_: nat).O) u)
-(weight_map (wadd (\lambda (_: nat).O) O) t)) (le_plus_l (weight_map (\lambda
-(_: nat).O) u) (weight_map (wadd (\lambda (_: nat).O) O) t))))))) b))
-(\lambda (_: F).(\lambda (u: T).(\lambda (t: T).(le_S_n (S (weight_map
-(\lambda (_: nat).O) u)) (S (plus (weight_map (\lambda (_: nat).O) u)
-(weight_map (\lambda (_: nat).O) t))) (le_n_S (S (weight_map (\lambda (_:
-nat).O) u)) (S (plus (weight_map (\lambda (_: nat).O) u) (weight_map (\lambda
-(_: nat).O) t))) (le_n_S (weight_map (\lambda (_: nat).O) u) (plus
-(weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t))
-(le_plus_l (weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_:
-nat).O) t)))))))) k).
+(weight_map (\lambda (_: nat).O) t)) (le_plus_l (weight_map (\lambda (_:
+nat).O) u) (weight_map (\lambda (_: nat).O) t)))))) k).
theorem tlt_head_dx:
\forall (k: K).(\forall (u: T).(\forall (t: T).(tlt t (THead k u t))))
(wadd (\lambda (_: nat).O) (S (weight_map (\lambda (_: nat).O) u))) t)))))))
(\lambda (u: T).(\lambda (t: T).(eq_ind_r nat (weight_map (\lambda (_:
nat).O) t) (\lambda (n: nat).(lt (weight_map (\lambda (_: nat).O) t) (S (plus
-(weight_map (\lambda (_: nat).O) u) n)))) (le_S_n (S (weight_map (\lambda (_:
-nat).O) t)) (S (plus (weight_map (\lambda (_: nat).O) u) (weight_map (\lambda
-(_: nat).O) t))) (le_n_S (S (weight_map (\lambda (_: nat).O) t)) (S (plus
-(weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t)))
-(le_n_S (weight_map (\lambda (_: nat).O) t) (plus (weight_map (\lambda (_:
-nat).O) u) (weight_map (\lambda (_: nat).O) t)) (le_plus_r (weight_map
-(\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t))))) (weight_map
-(wadd (\lambda (_: nat).O) O) t) (weight_add_O t)))) (\lambda (u: T).(\lambda
-(t: T).(eq_ind_r nat (weight_map (\lambda (_: nat).O) t) (\lambda (n:
-nat).(lt (weight_map (\lambda (_: nat).O) t) (S (plus (weight_map (\lambda
-(_: nat).O) u) n)))) (le_S_n (S (weight_map (\lambda (_: nat).O) t)) (S (plus
-(weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t)))
-(le_n_S (S (weight_map (\lambda (_: nat).O) t)) (S (plus (weight_map (\lambda
-(_: nat).O) u) (weight_map (\lambda (_: nat).O) t))) (le_n_S (weight_map
-(\lambda (_: nat).O) t) (plus (weight_map (\lambda (_: nat).O) u) (weight_map
-(\lambda (_: nat).O) t)) (le_plus_r (weight_map (\lambda (_: nat).O) u)
-(weight_map (\lambda (_: nat).O) t))))) (weight_map (wadd (\lambda (_:
-nat).O) O) t) (weight_add_O t)))) b)) (\lambda (_: F).(\lambda (u:
-T).(\lambda (t: T).(le_S_n (S (weight_map (\lambda (_: nat).O) t)) (S (plus
-(weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t)))
-(le_n_S (S (weight_map (\lambda (_: nat).O) t)) (S (plus (weight_map (\lambda
-(_: nat).O) u) (weight_map (\lambda (_: nat).O) t))) (le_n_S (weight_map
-(\lambda (_: nat).O) t) (plus (weight_map (\lambda (_: nat).O) u) (weight_map
-(\lambda (_: nat).O) t)) (le_plus_r (weight_map (\lambda (_: nat).O) u)
-(weight_map (\lambda (_: nat).O) t)))))))) k).
+(weight_map (\lambda (_: nat).O) u) n)))) (le_n_S (weight_map (\lambda (_:
+nat).O) t) (plus (weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_:
+nat).O) t)) (le_plus_r (weight_map (\lambda (_: nat).O) u) (weight_map
+(\lambda (_: nat).O) t))) (weight_map (wadd (\lambda (_: nat).O) O) t)
+(weight_add_O t)))) (\lambda (u: T).(\lambda (t: T).(eq_ind_r nat (weight_map
+(\lambda (_: nat).O) t) (\lambda (n: nat).(lt (weight_map (\lambda (_:
+nat).O) t) (S (plus (weight_map (\lambda (_: nat).O) u) n)))) (le_n_S
+(weight_map (\lambda (_: nat).O) t) (plus (weight_map (\lambda (_: nat).O) u)
+(weight_map (\lambda (_: nat).O) t)) (le_plus_r (weight_map (\lambda (_:
+nat).O) u) (weight_map (\lambda (_: nat).O) t))) (weight_map (wadd (\lambda
+(_: nat).O) O) t) (weight_add_O t)))) b)) (\lambda (_: F).(\lambda (u:
+T).(\lambda (t: T).(le_n_S (weight_map (\lambda (_: nat).O) t) (plus
+(weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_: nat).O) t))
+(le_plus_r (weight_map (\lambda (_: nat).O) u) (weight_map (\lambda (_:
+nat).O) t)))))) k).
theorem tlt_wf__q_ind:
\forall (P: ((T \to Prop))).(((\forall (n: nat).((\lambda (P0: ((T \to
T).(ty3 g c2 t t4)) P (\lambda (x2: T).(\lambda (_: (pc3 c2 (THead (Flat
Cast) x2 t) t3)).(\lambda (H15: (ty3 g c2 t0 t)).(\lambda (H16: (ty3 g c2 t
x2)).(let H_y \def (ty3_unique g c2 t x2 H16 x H6) in (let H_y0 \def
-(ty3_unique g c2 t0 t H15 x0 H9) in (H12 (pc3_s c2 x0 t H_y0) P)))))))
-(ty3_gen_cast g c2 t0 t t3 H13))))))) H11))))) (ty3_correct g c2 t0 x0 H9))))
-H8)) (\lambda (H8: ((\forall (t3: T).((ty3 g c2 t0 t3) \to (\forall (P:
-Prop).P))))).(or_intror (ex T (\lambda (t3: T).(ty3 g c2 (THead (Flat Cast) t
-t0) t3))) (\forall (t3: T).((ty3 g c2 (THead (Flat Cast) t t0) t3) \to
-(\forall (P: Prop).P))) (\lambda (t3: T).(\lambda (H9: (ty3 g c2 (THead (Flat
-Cast) t t0) t3)).(\lambda (P: Prop).(ex3_ind T (\lambda (t4: T).(pc3 c2
-(THead (Flat Cast) t4 t) t3)) (\lambda (_: T).(ty3 g c2 t0 t)) (\lambda (t4:
-T).(ty3 g c2 t t4)) P (\lambda (x0: T).(\lambda (_: (pc3 c2 (THead (Flat
-Cast) x0 t) t3)).(\lambda (H11: (ty3 g c2 t0 t)).(\lambda (_: (ty3 g c2 t
-x0)).(H8 t H11 P))))) (ty3_gen_cast g c2 t0 t t3 H9))))))) H7)))) H5))
-(\lambda (H5: ((\forall (t3: T).((ty3 g c2 t t3) \to (\forall (P:
+(ty3_unique g c2 t0 t H15 x0 H9) in (H12 (ex2_sym T (pr3 c2 t) (pr3 c2 x0)
+H_y0) P))))))) (ty3_gen_cast g c2 t0 t t3 H13))))))) H11))))) (ty3_correct g
+c2 t0 x0 H9)))) H8)) (\lambda (H8: ((\forall (t3: T).((ty3 g c2 t0 t3) \to
+(\forall (P: Prop).P))))).(or_intror (ex T (\lambda (t3: T).(ty3 g c2 (THead
+(Flat Cast) t t0) t3))) (\forall (t3: T).((ty3 g c2 (THead (Flat Cast) t t0)
+t3) \to (\forall (P: Prop).P))) (\lambda (t3: T).(\lambda (H9: (ty3 g c2
+(THead (Flat Cast) t t0) t3)).(\lambda (P: Prop).(ex3_ind T (\lambda (t4:
+T).(pc3 c2 (THead (Flat Cast) t4 t) t3)) (\lambda (_: T).(ty3 g c2 t0 t))
+(\lambda (t4: T).(ty3 g c2 t t4)) P (\lambda (x0: T).(\lambda (_: (pc3 c2
+(THead (Flat Cast) x0 t) t3)).(\lambda (H11: (ty3 g c2 t0 t)).(\lambda (_:
+(ty3 g c2 t x0)).(H8 t H11 P))))) (ty3_gen_cast g c2 t0 t t3 H9))))))) H7))))
+H5)) (\lambda (H5: ((\forall (t3: T).((ty3 g c2 t t3) \to (\forall (P:
Prop).P))))).(or_intror (ex T (\lambda (t3: T).(ty3 g c2 (THead (Flat Cast) t
t0) t3))) (\forall (t3: T).((ty3 g c2 (THead (Flat Cast) t t0) t3) \to
(\forall (P: Prop).P))) (\lambda (t3: T).(\lambda (H6: (ty3 g c2 (THead (Flat
include "ty3/arity.ma".
+include "pc3/nf2.ma".
+
include "nf2/arity.ma".
+definition ty3_nf2_inv_abst_premise:
+ C \to (T \to (T \to Prop))
+\def
+ \lambda (c: C).(\lambda (w: T).(\lambda (u: T).(\forall (d: C).(\forall (wi:
+T).(\forall (i: nat).((getl i c (CHead d (Bind Abst) wi)) \to (\forall (vs:
+TList).((pc3 c (THeads (Flat Appl) vs (lift (S i) O wi)) (THead (Bind Abst) w
+u)) \to False)))))))).
+
+theorem ty3_nf2_inv_abst_premise_csort:
+ \forall (w: T).(\forall (u: T).(\forall (m: nat).(ty3_nf2_inv_abst_premise
+(CSort m) w u)))
+\def
+ \lambda (w: T).(\lambda (u: T).(\lambda (m: nat).(\lambda (d: C).(\lambda
+(wi: T).(\lambda (i: nat).(\lambda (H: (getl i (CSort m) (CHead d (Bind Abst)
+wi))).(\lambda (vs: TList).(\lambda (_: (pc3 (CSort m) (THeads (Flat Appl) vs
+(lift (S i) O wi)) (THead (Bind Abst) w u))).(getl_gen_sort m i (CHead d
+(Bind Abst) wi) H False))))))))).
+
theorem ty3_nf2_inv_all:
\forall (g: G).(\forall (c: C).(\forall (t: T).(\forall (u: T).((ty3 g c t
u) \to ((nf2 c t) \to (or3 (ex3_2 T T (\lambda (w: T).(\lambda (u0: T).(eq T
x0 x1 (refl_equal T (THeads (Flat Appl) x0 (TLRef x1))) H4 H5)) t H3)))))))
H2)) H1)))))))).
+theorem ty3_nf2_gen__ty3_nf2_inv_abst_aux:
+ \forall (c: C).(\forall (w1: T).(\forall (u1: T).((ty3_nf2_inv_abst_premise
+c w1 u1) \to (\forall (t: T).(\forall (w2: T).(\forall (u2: T).((pc3 c (THead
+(Flat Appl) t (THead (Bind Abst) w2 u2)) (THead (Bind Abst) w1 u1)) \to
+(ty3_nf2_inv_abst_premise c w2 u2))))))))
+\def
+ \lambda (c: C).(\lambda (w1: T).(\lambda (u1: T).(\lambda (H: ((\forall (d:
+C).(\forall (wi: T).(\forall (i: nat).((getl i c (CHead d (Bind Abst) wi))
+\to (\forall (vs: TList).((pc3 c (THeads (Flat Appl) vs (lift (S i) O wi))
+(THead (Bind Abst) w1 u1)) \to False)))))))).(\lambda (t: T).(\lambda (w2:
+T).(\lambda (u2: T).(\lambda (H0: (pc3 c (THead (Flat Appl) t (THead (Bind
+Abst) w2 u2)) (THead (Bind Abst) w1 u1))).(\lambda (d: C).(\lambda (wi:
+T).(\lambda (i: nat).(\lambda (H1: (getl i c (CHead d (Bind Abst)
+wi))).(\lambda (vs: TList).(\lambda (H2: (pc3 c (THeads (Flat Appl) vs (lift
+(S i) O wi)) (THead (Bind Abst) w2 u2))).(H d wi i H1 (TCons t vs) (pc3_t
+(THead (Flat Appl) t (THead (Bind Abst) w2 u2)) c (THead (Flat Appl) t
+(THeads (Flat Appl) vs (lift (S i) O wi))) (pc3_thin_dx c (THeads (Flat Appl)
+vs (lift (S i) O wi)) (THead (Bind Abst) w2 u2) H2 t Appl) (THead (Bind Abst)
+w1 u1) H0))))))))))))))).
+
+theorem ty3_nf2_inv_abst:
+ \forall (g: G).(\forall (c: C).(\forall (t: T).(\forall (w: T).(\forall (u:
+T).((ty3 g c t (THead (Bind Abst) w u)) \to ((nf2 c t) \to ((nf2 c w) \to
+((ty3_nf2_inv_abst_premise c w u) \to (ex4_2 T T (\lambda (v: T).(\lambda (_:
+T).(eq T t (THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g
+c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v
+u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w)
+v))))))))))))
+\def
+ \lambda (g: G).(\lambda (c: C).(\lambda (t: T).(\lambda (w: T).(\lambda (u:
+T).(\lambda (H: (ty3 g c t (THead (Bind Abst) w u))).(\lambda (H0: (nf2 c
+t)).(\lambda (H1: (nf2 c w)).(\lambda (H2: (ty3_nf2_inv_abst_premise c w
+u)).(let H_x \def (ty3_nf2_inv_all g c t (THead (Bind Abst) w u) H H0) in
+(let H3 \def H_x in (or3_ind (ex3_2 T T (\lambda (w0: T).(\lambda (u0: T).(eq
+T t (THead (Bind Abst) w0 u0)))) (\lambda (w0: T).(\lambda (_: T).(nf2 c
+w0))) (\lambda (w0: T).(\lambda (u0: T).(nf2 (CHead c (Bind Abst) w0) u0))))
+(ex nat (\lambda (n: nat).(eq T t (TSort n)))) (ex3_2 TList nat (\lambda (ws:
+TList).(\lambda (i: nat).(eq T t (THeads (Flat Appl) ws (TLRef i)))))
+(\lambda (ws: TList).(\lambda (_: nat).(nfs2 c ws))) (\lambda (_:
+TList).(\lambda (i: nat).(nf2 c (TLRef i))))) (ex4_2 T T (\lambda (v:
+T).(\lambda (_: T).(eq T t (THead (Bind Abst) w v)))) (\lambda (_:
+T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g
+(CHead c (Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c
+(Bind Abst) w) v)))) (\lambda (H4: (ex3_2 T T (\lambda (w0: T).(\lambda (u0:
+T).(eq T t (THead (Bind Abst) w0 u0)))) (\lambda (w0: T).(\lambda (_: T).(nf2
+c w0))) (\lambda (w0: T).(\lambda (u0: T).(nf2 (CHead c (Bind Abst) w0)
+u0))))).(ex3_2_ind T T (\lambda (w0: T).(\lambda (u0: T).(eq T t (THead (Bind
+Abst) w0 u0)))) (\lambda (w0: T).(\lambda (_: T).(nf2 c w0))) (\lambda (w0:
+T).(\lambda (u0: T).(nf2 (CHead c (Bind Abst) w0) u0))) (ex4_2 T T (\lambda
+(v: T).(\lambda (_: T).(eq T t (THead (Bind Abst) w v)))) (\lambda (_:
+T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g
+(CHead c (Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c
+(Bind Abst) w) v)))) (\lambda (x0: T).(\lambda (x1: T).(\lambda (H5: (eq T t
+(THead (Bind Abst) x0 x1))).(\lambda (H6: (nf2 c x0)).(\lambda (H7: (nf2
+(CHead c (Bind Abst) x0) x1)).(let H8 \def (eq_ind T t (\lambda (t0: T).(ty3
+g c t0 (THead (Bind Abst) w u))) H (THead (Bind Abst) x0 x1) H5) in (eq_ind_r
+T (THead (Bind Abst) x0 x1) (\lambda (t0: T).(ex4_2 T T (\lambda (v:
+T).(\lambda (_: T).(eq T t0 (THead (Bind Abst) w v)))) (\lambda (_:
+T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g
+(CHead c (Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c
+(Bind Abst) w) v))))) (ex_ind T (\lambda (t0: T).(ty3 g c (THead (Bind Abst)
+w u) t0)) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (THead (Bind Abst)
+x0 x1) (THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w
+w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v)))) (\lambda
+(x: T).(\lambda (H9: (ty3 g c (THead (Bind Abst) w u) x)).(ex4_3_ind T T T
+(\lambda (t2: T).(\lambda (_: T).(\lambda (_: T).(pc3 c (THead (Bind Abst) w
+t2) x)))) (\lambda (_: T).(\lambda (t0: T).(\lambda (_: T).(ty3 g c w t0))))
+(\lambda (t2: T).(\lambda (_: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst)
+w) u t2)))) (\lambda (t2: T).(\lambda (_: T).(\lambda (t1: T).(ty3 g (CHead c
+(Bind Abst) w) t2 t1)))) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T
+(THead (Bind Abst) x0 x1) (THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda
+(w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c
+(Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind
+Abst) w) v)))) (\lambda (x2: T).(\lambda (x3: T).(\lambda (x4: T).(\lambda
+(_: (pc3 c (THead (Bind Abst) w x2) x)).(\lambda (H11: (ty3 g c w
+x3)).(\lambda (H12: (ty3 g (CHead c (Bind Abst) w) u x2)).(\lambda (_: (ty3 g
+(CHead c (Bind Abst) w) x2 x4)).(ex4_3_ind T T T (\lambda (t2: T).(\lambda
+(_: T).(\lambda (_: T).(pc3 c (THead (Bind Abst) x0 t2) (THead (Bind Abst) w
+u))))) (\lambda (_: T).(\lambda (t0: T).(\lambda (_: T).(ty3 g c x0 t0))))
+(\lambda (t2: T).(\lambda (_: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst)
+x0) x1 t2)))) (\lambda (t2: T).(\lambda (_: T).(\lambda (t1: T).(ty3 g (CHead
+c (Bind Abst) x0) t2 t1)))) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T
+(THead (Bind Abst) x0 x1) (THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda
+(w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c
+(Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind
+Abst) w) v)))) (\lambda (x5: T).(\lambda (x6: T).(\lambda (x7: T).(\lambda
+(H14: (pc3 c (THead (Bind Abst) x0 x5) (THead (Bind Abst) w u))).(\lambda (_:
+(ty3 g c x0 x6)).(\lambda (H16: (ty3 g (CHead c (Bind Abst) x0) x1
+x5)).(\lambda (_: (ty3 g (CHead c (Bind Abst) x0) x5 x7)).(and_ind (pc3 c x0
+w) (\forall (b: B).(\forall (u0: T).(pc3 (CHead c (Bind b) u0) x5 u))) (ex4_2
+T T (\lambda (v: T).(\lambda (_: T).(eq T (THead (Bind Abst) x0 x1) (THead
+(Bind Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0)))
+(\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v)))) (\lambda
+(H18: (pc3 c x0 w)).(\lambda (H19: ((\forall (b: B).(\forall (u0: T).(pc3
+(CHead c (Bind b) u0) x5 u))))).(let H_y \def (pc3_nf2 c x0 w H18 H6 H1) in
+(let H20 \def (eq_ind T x0 (\lambda (t0: T).(ty3 g (CHead c (Bind Abst) t0)
+x1 x5)) H16 w H_y) in (let H21 \def (eq_ind T x0 (\lambda (t0: T).(nf2 (CHead
+c (Bind Abst) t0) x1)) H7 w H_y) in (eq_ind_r T w (\lambda (t0: T).(ex4_2 T T
+(\lambda (v: T).(\lambda (_: T).(eq T (THead (Bind Abst) t0 x1) (THead (Bind
+Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v))))) (ex4_2_intro T T
+(\lambda (v: T).(\lambda (_: T).(eq T (THead (Bind Abst) w x1) (THead (Bind
+Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v))) x1 x3 (refl_equal T
+(THead (Bind Abst) w x1)) H11 (ty3_conv g (CHead c (Bind Abst) w) u x2 H12 x1
+x5 H20 (H19 Abst w)) H21) x0 H_y)))))) (pc3_gen_abst c x0 w x5 u H14)))))))))
+(ty3_gen_bind g Abst c x0 x1 (THead (Bind Abst) w u) H8)))))))))
+(ty3_gen_bind g Abst c w u x H9)))) (ty3_correct g c (THead (Bind Abst) x0
+x1) (THead (Bind Abst) w u) H8)) t H5))))))) H4)) (\lambda (H4: (ex nat
+(\lambda (n: nat).(eq T t (TSort n))))).(ex_ind nat (\lambda (n: nat).(eq T t
+(TSort n))) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T t (THead (Bind
+Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v)))) (\lambda (x:
+nat).(\lambda (H5: (eq T t (TSort x))).(let H6 \def (eq_ind T t (\lambda (t0:
+T).(ty3 g c t0 (THead (Bind Abst) w u))) H (TSort x) H5) in (eq_ind_r T
+(TSort x) (\lambda (t0: T).(ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T
+t0 (THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w
+w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v)))))
+(pc3_gen_sort_abst c w u (next g x) (ty3_gen_sort g c (THead (Bind Abst) w u)
+x H6) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (TSort x) (THead (Bind
+Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v u))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v))))) t H5)))) H4)) (\lambda
+(H4: (ex3_2 TList nat (\lambda (ws: TList).(\lambda (i: nat).(eq T t (THeads
+(Flat Appl) ws (TLRef i))))) (\lambda (ws: TList).(\lambda (_: nat).(nfs2 c
+ws))) (\lambda (_: TList).(\lambda (i: nat).(nf2 c (TLRef i)))))).(ex3_2_ind
+TList nat (\lambda (ws: TList).(\lambda (i: nat).(eq T t (THeads (Flat Appl)
+ws (TLRef i))))) (\lambda (ws: TList).(\lambda (_: nat).(nfs2 c ws)))
+(\lambda (_: TList).(\lambda (i: nat).(nf2 c (TLRef i)))) (ex4_2 T T (\lambda
+(v: T).(\lambda (_: T).(eq T t (THead (Bind Abst) w v)))) (\lambda (_:
+T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g
+(CHead c (Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c
+(Bind Abst) w) v)))) (\lambda (x0: TList).(\lambda (x1: nat).(\lambda (H5:
+(eq T t (THeads (Flat Appl) x0 (TLRef x1)))).(\lambda (_: (nfs2 c
+x0)).(\lambda (H7: (nf2 c (TLRef x1))).(let H8 \def (eq_ind T t (\lambda (t0:
+T).(ty3 g c t0 (THead (Bind Abst) w u))) H (THeads (Flat Appl) x0 (TLRef x1))
+H5) in (eq_ind_r T (THeads (Flat Appl) x0 (TLRef x1)) (\lambda (t0: T).(ex4_2
+T T (\lambda (v: T).(\lambda (_: T).(eq T t0 (THead (Bind Abst) w v))))
+(\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0))) (\lambda (v: T).(\lambda
+(_: T).(ty3 g (CHead c (Bind Abst) w) v u))) (\lambda (v: T).(\lambda (_:
+T).(nf2 (CHead c (Bind Abst) w) v))))) (let H9 \def H2 in ((let H10 \def H8
+in (unintro T u (\lambda (t0: T).((ty3 g c (THeads (Flat Appl) x0 (TLRef x1))
+(THead (Bind Abst) w t0)) \to ((ty3_nf2_inv_abst_premise c w t0) \to (ex4_2 T
+T (\lambda (v: T).(\lambda (_: T).(eq T (THeads (Flat Appl) x0 (TLRef x1))
+(THead (Bind Abst) w v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c w w0)))
+(\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) w) v t0)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) w) v)))))))
+(unintro T w (\lambda (t0: T).(\forall (x: T).((ty3 g c (THeads (Flat Appl)
+x0 (TLRef x1)) (THead (Bind Abst) t0 x)) \to ((ty3_nf2_inv_abst_premise c t0
+x) \to (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (THeads (Flat Appl)
+x0 (TLRef x1)) (THead (Bind Abst) t0 v)))) (\lambda (_: T).(\lambda (w0:
+T).(ty3 g c t0 w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind
+Abst) t0) v x))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst)
+t0) v)))))))) (TList_ind (\lambda (t0: TList).(\forall (x: T).(\forall (x2:
+T).((ty3 g c (THeads (Flat Appl) t0 (TLRef x1)) (THead (Bind Abst) x x2)) \to
+((ty3_nf2_inv_abst_premise c x x2) \to (ex4_2 T T (\lambda (v: T).(\lambda
+(_: T).(eq T (THeads (Flat Appl) t0 (TLRef x1)) (THead (Bind Abst) x v))))
+(\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda
+(_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_:
+T).(nf2 (CHead c (Bind Abst) x) v))))))))) (\lambda (x: T).(\lambda (x2:
+T).(\lambda (H11: (ty3 g c (TLRef x1) (THead (Bind Abst) x x2))).(\lambda
+(H12: (ty3_nf2_inv_abst_premise c x x2)).(or_ind (ex3_3 C T T (\lambda (_:
+C).(\lambda (_: T).(\lambda (t0: T).(pc3 c (lift (S x1) O t0) (THead (Bind
+Abst) x x2))))) (\lambda (e: C).(\lambda (u0: T).(\lambda (_: T).(getl x1 c
+(CHead e (Bind Abbr) u0))))) (\lambda (e: C).(\lambda (u0: T).(\lambda (t0:
+T).(ty3 g e u0 t0))))) (ex3_3 C T T (\lambda (_: C).(\lambda (u0: T).(\lambda
+(_: T).(pc3 c (lift (S x1) O u0) (THead (Bind Abst) x x2))))) (\lambda (e:
+C).(\lambda (u0: T).(\lambda (_: T).(getl x1 c (CHead e (Bind Abst) u0)))))
+(\lambda (e: C).(\lambda (u0: T).(\lambda (t0: T).(ty3 g e u0 t0))))) (ex4_2
+T T (\lambda (v: T).(\lambda (_: T).(eq T (TLRef x1) (THead (Bind Abst) x
+v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x) v)))) (\lambda (H13: (ex3_3 C
+T T (\lambda (_: C).(\lambda (_: T).(\lambda (t0: T).(pc3 c (lift (S x1) O
+t0) (THead (Bind Abst) x x2))))) (\lambda (e: C).(\lambda (u0: T).(\lambda
+(_: T).(getl x1 c (CHead e (Bind Abbr) u0))))) (\lambda (e: C).(\lambda (u0:
+T).(\lambda (t0: T).(ty3 g e u0 t0)))))).(ex3_3_ind C T T (\lambda (_:
+C).(\lambda (_: T).(\lambda (t0: T).(pc3 c (lift (S x1) O t0) (THead (Bind
+Abst) x x2))))) (\lambda (e: C).(\lambda (u0: T).(\lambda (_: T).(getl x1 c
+(CHead e (Bind Abbr) u0))))) (\lambda (e: C).(\lambda (u0: T).(\lambda (t0:
+T).(ty3 g e u0 t0)))) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (TLRef
+x1) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c x
+w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v x2)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x) v)))) (\lambda
+(x3: C).(\lambda (x4: T).(\lambda (x5: T).(\lambda (_: (pc3 c (lift (S x1) O
+x5) (THead (Bind Abst) x x2))).(\lambda (H15: (getl x1 c (CHead x3 (Bind
+Abbr) x4))).(\lambda (_: (ty3 g x3 x4 x5)).(nf2_gen_lref c x3 x4 x1 H15 H7
+(ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (TLRef x1) (THead (Bind
+Abst) x v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x) v))))))))))) H13)) (\lambda
+(H13: (ex3_3 C T T (\lambda (_: C).(\lambda (u0: T).(\lambda (_: T).(pc3 c
+(lift (S x1) O u0) (THead (Bind Abst) x x2))))) (\lambda (e: C).(\lambda (u0:
+T).(\lambda (_: T).(getl x1 c (CHead e (Bind Abst) u0))))) (\lambda (e:
+C).(\lambda (u0: T).(\lambda (t0: T).(ty3 g e u0 t0)))))).(ex3_3_ind C T T
+(\lambda (_: C).(\lambda (u0: T).(\lambda (_: T).(pc3 c (lift (S x1) O u0)
+(THead (Bind Abst) x x2))))) (\lambda (e: C).(\lambda (u0: T).(\lambda (_:
+T).(getl x1 c (CHead e (Bind Abst) u0))))) (\lambda (e: C).(\lambda (u0:
+T).(\lambda (t0: T).(ty3 g e u0 t0)))) (ex4_2 T T (\lambda (v: T).(\lambda
+(_: T).(eq T (TLRef x1) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda
+(w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c
+(Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind
+Abst) x) v)))) (\lambda (x3: C).(\lambda (x4: T).(\lambda (x5: T).(\lambda
+(H14: (pc3 c (lift (S x1) O x4) (THead (Bind Abst) x x2))).(\lambda (H15:
+(getl x1 c (CHead x3 (Bind Abst) x4))).(\lambda (_: (ty3 g x3 x4 x5)).(let
+H_x0 \def (H12 x3 x4 x1 H15 TNil H14) in (let H17 \def H_x0 in (False_ind
+(ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (TLRef x1) (THead (Bind
+Abst) x v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v:
+T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v:
+T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x) v)))) H17))))))))) H13))
+(ty3_gen_lref g c (THead (Bind Abst) x x2) x1 H11)))))) (\lambda (t0:
+T).(\lambda (t1: TList).(\lambda (H11: ((\forall (x: T).(\forall (x2:
+T).((ty3 g c (THeads (Flat Appl) t1 (TLRef x1)) (THead (Bind Abst) x x2)) \to
+((ty3_nf2_inv_abst_premise c x x2) \to (ex4_2 T T (\lambda (v: T).(\lambda
+(_: T).(eq T (THeads (Flat Appl) t1 (TLRef x1)) (THead (Bind Abst) x v))))
+(\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda
+(_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_:
+T).(nf2 (CHead c (Bind Abst) x) v)))))))))).(\lambda (x: T).(\lambda (x2:
+T).(\lambda (H12: (ty3 g c (THead (Flat Appl) t0 (THeads (Flat Appl) t1
+(TLRef x1))) (THead (Bind Abst) x x2))).(\lambda (H13:
+(ty3_nf2_inv_abst_premise c x x2)).(ex3_2_ind T T (\lambda (u0: T).(\lambda
+(t2: T).(pc3 c (THead (Flat Appl) t0 (THead (Bind Abst) u0 t2)) (THead (Bind
+Abst) x x2)))) (\lambda (u0: T).(\lambda (t2: T).(ty3 g c (THeads (Flat Appl)
+t1 (TLRef x1)) (THead (Bind Abst) u0 t2)))) (\lambda (u0: T).(\lambda (_:
+T).(ty3 g c t0 u0))) (ex4_2 T T (\lambda (v: T).(\lambda (_: T).(eq T (THead
+(Flat Appl) t0 (THeads (Flat Appl) t1 (TLRef x1))) (THead (Bind Abst) x v))))
+(\lambda (_: T).(\lambda (w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda
+(_: T).(ty3 g (CHead c (Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_:
+T).(nf2 (CHead c (Bind Abst) x) v)))) (\lambda (x3: T).(\lambda (x4:
+T).(\lambda (H14: (pc3 c (THead (Flat Appl) t0 (THead (Bind Abst) x3 x4))
+(THead (Bind Abst) x x2))).(\lambda (H15: (ty3 g c (THeads (Flat Appl) t1
+(TLRef x1)) (THead (Bind Abst) x3 x4))).(\lambda (_: (ty3 g c t0 x3)).(let
+H_y \def (ty3_nf2_gen__ty3_nf2_inv_abst_aux c x x2 H13 t0 x3 x4 H14) in (let
+H_x0 \def (H11 x3 x4 H15 H_y) in (let H17 \def H_x0 in (ex4_2_ind T T
+(\lambda (v: T).(\lambda (_: T).(eq T (THeads (Flat Appl) t1 (TLRef x1))
+(THead (Bind Abst) x3 v)))) (\lambda (_: T).(\lambda (w0: T).(ty3 g c x3
+w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x3) v x4)))
+(\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x3) v))) (ex4_2 T T
+(\lambda (v: T).(\lambda (_: T).(eq T (THead (Flat Appl) t0 (THeads (Flat
+Appl) t1 (TLRef x1))) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda
+(w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c
+(Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind
+Abst) x) v)))) (\lambda (x5: T).(\lambda (x6: T).(\lambda (H18: (eq T (THeads
+(Flat Appl) t1 (TLRef x1)) (THead (Bind Abst) x3 x5))).(\lambda (_: (ty3 g c
+x3 x6)).(\lambda (_: (ty3 g (CHead c (Bind Abst) x3) x5 x4)).(\lambda (_:
+(nf2 (CHead c (Bind Abst) x3) x5)).(TList_ind (\lambda (t2: TList).((eq T
+(THeads (Flat Appl) t2 (TLRef x1)) (THead (Bind Abst) x3 x5)) \to (ex4_2 T T
+(\lambda (v: T).(\lambda (_: T).(eq T (THead (Flat Appl) t0 (THeads (Flat
+Appl) t2 (TLRef x1))) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda
+(w0: T).(ty3 g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c
+(Bind Abst) x) v x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind
+Abst) x) v)))))) (\lambda (H22: (eq T (THeads (Flat Appl) TNil (TLRef x1))
+(THead (Bind Abst) x3 x5))).(let H23 \def (eq_ind T (TLRef x1) (\lambda (ee:
+T).(match ee in T return (\lambda (_: T).Prop) with [(TSort _) \Rightarrow
+False | (TLRef _) \Rightarrow True | (THead _ _ _) \Rightarrow False])) I
+(THead (Bind Abst) x3 x5) H22) in (False_ind (ex4_2 T T (\lambda (v:
+T).(\lambda (_: T).(eq T (THead (Flat Appl) t0 (THeads (Flat Appl) TNil
+(TLRef x1))) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda (w0: T).(ty3
+g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v
+x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x) v))))
+H23))) (\lambda (t2: T).(\lambda (t3: TList).(\lambda (_: (((eq T (THeads
+(Flat Appl) t3 (TLRef x1)) (THead (Bind Abst) x3 x5)) \to (ex4_2 T T (\lambda
+(v: T).(\lambda (_: T).(eq T (THead (Flat Appl) t0 (THeads (Flat Appl) t3
+(TLRef x1))) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda (w0: T).(ty3
+g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind Abst) x) v
+x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x)
+v))))))).(\lambda (H22: (eq T (THeads (Flat Appl) (TCons t2 t3) (TLRef x1))
+(THead (Bind Abst) x3 x5))).(let H23 \def (eq_ind T (THead (Flat Appl) t2
+(THeads (Flat Appl) t3 (TLRef x1))) (\lambda (ee: T).(match ee in T return
+(\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
+\Rightarrow False | (THead k _ _) \Rightarrow (match k in K return (\lambda
+(_: K).Prop) with [(Bind _) \Rightarrow False | (Flat _) \Rightarrow
+True])])) I (THead (Bind Abst) x3 x5) H22) in (False_ind (ex4_2 T T (\lambda
+(v: T).(\lambda (_: T).(eq T (THead (Flat Appl) t0 (THeads (Flat Appl) (TCons
+t2 t3) (TLRef x1))) (THead (Bind Abst) x v)))) (\lambda (_: T).(\lambda (w0:
+T).(ty3 g c x w0))) (\lambda (v: T).(\lambda (_: T).(ty3 g (CHead c (Bind
+Abst) x) v x2))) (\lambda (v: T).(\lambda (_: T).(nf2 (CHead c (Bind Abst) x)
+v)))) H23)))))) t1 H18))))))) H17))))))))) (ty3_gen_appl g c t0 (THeads (Flat
+Appl) t1 (TLRef x1)) (THead (Bind Abst) x x2) H12))))))))) x0)) H10)) H9)) t
+H5))))))) H4)) H3))))))))))).
+
(\lambda (t8: T).(ty3 g c2 t8 x1)) H30 t5 (lift_inj t5 x0 (S O) O H28)) in
(ty3_conv g c2 (THead (Bind Void) u (lift (S O) O x1)) (THead (Bind Void) u
t4) (ty3_bind g c2 u t0 (H1 c2 H6 u (pr0_refl u)) Void (lift (S O) O x1) t4
-H31 x H25) t5 x1 H32 (pc3_pr2_x c2 x1 (THead (Bind Void) u (lift (S O) O x1))
-(pr2_free c2 (THead (Bind Void) u (lift (S O) O x1)) x1 (pr0_zeta Void H23 x1
-x1 (pr0_refl x1) u))))) t3 H29))))))) H27)))))) b H18 (H5 (CHead c2 (Bind b)
-u) (wcpr0_comp c c2 H6 u u (pr0_refl u) (Bind b)) t3 (pr0_refl t3)) H22 (H20
-(CHead c2 (Bind b) u) (wcpr0_comp c c2 H6 u u (pr0_refl u) (Bind b)) (lift (S
-O) O t5) (pr0_lift t6 t5 H19 (S O) O))))) (ty3_correct g (CHead c2 (Bind b)
-u) t3 t4 (H5 (CHead c2 (Bind b) u) (wcpr0_comp c c2 H6 u u (pr0_refl u) (Bind
-b)) t3 (pr0_refl t3)))))))) t7 (sym_eq T t7 t5 H17))) t2 H16)) u0 (sym_eq T
-u0 u H15))) b0 (sym_eq B b0 b H14))) H13)) H12)) H11 H8 H9))) | (pr0_epsilon
-t6 t7 H8 u0) \Rightarrow (\lambda (H9: (eq T (THead (Flat Cast) u0 t6) (THead
-(Bind b) u t2))).(\lambda (H10: (eq T t7 t5)).((let H11 \def (eq_ind T (THead
-(Flat Cast) u0 t6) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop)
-with [(TSort _) \Rightarrow False | (TLRef _) \Rightarrow False | (THead k _
-_) \Rightarrow (match k in K return (\lambda (_: K).Prop) with [(Bind _)
+H31 x H25) t5 x1 H32 (pc3_s c2 x1 (THead (Bind Void) u (lift (S O) O x1))
+(pc3_pr2_r c2 (THead (Bind Void) u (lift (S O) O x1)) x1 (pr2_free c2 (THead
+(Bind Void) u (lift (S O) O x1)) x1 (pr0_zeta Void H23 x1 x1 (pr0_refl x1)
+u)))))) t3 H29))))))) H27)))))) b H18 (H5 (CHead c2 (Bind b) u) (wcpr0_comp c
+c2 H6 u u (pr0_refl u) (Bind b)) t3 (pr0_refl t3)) H22 (H20 (CHead c2 (Bind
+b) u) (wcpr0_comp c c2 H6 u u (pr0_refl u) (Bind b)) (lift (S O) O t5)
+(pr0_lift t6 t5 H19 (S O) O))))) (ty3_correct g (CHead c2 (Bind b) u) t3 t4
+(H5 (CHead c2 (Bind b) u) (wcpr0_comp c c2 H6 u u (pr0_refl u) (Bind b)) t3
+(pr0_refl t3)))))))) t7 (sym_eq T t7 t5 H17))) t2 H16)) u0 (sym_eq T u0 u
+H15))) b0 (sym_eq B b0 b H14))) H13)) H12)) H11 H8 H9))) | (pr0_epsilon t6 t7
+H8 u0) \Rightarrow (\lambda (H9: (eq T (THead (Flat Cast) u0 t6) (THead (Bind
+b) u t2))).(\lambda (H10: (eq T t7 t5)).((let H11 \def (eq_ind T (THead (Flat
+Cast) u0 t6) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with
+[(TSort _) \Rightarrow False | (TLRef _) \Rightarrow False | (THead k _ _)
+\Rightarrow (match k in K return (\lambda (_: K).Prop) with [(Bind _)
\Rightarrow False | (Flat _) \Rightarrow True])])) I (THead (Bind b) u t2)
H9) in (False_ind ((eq T t7 t5) \to ((pr0 t6 t7) \to (ty3 g c2 t5 (THead
(Bind b) u t3)))) H11)) H10 H8)))]) in (H8 (refl_equal T (THead (Bind b) u
(lift (S O) O v2) (lift (S O) O (THead (Bind Abst) u t0)))) (pr0_upsilon b
H16 v2 v2 (pr0_refl v2) u2 u2 (pr0_refl u2) (lift (S O) O (THead (Bind Abst)
u t0)) (lift (S O) O (THead (Bind Abst) u t0)) (pr0_refl (lift (S O) O (THead
-(Bind Abst) u t0)))) (THead (Flat Appl) w (THead (Bind Abst) u t0)) (pc1_s
-(THead (Flat Appl) v2 (THead (Bind b) u2 (lift (S O) O (THead (Bind Abst) u
-t0)))) (THead (Flat Appl) w (THead (Bind Abst) u t0)) (pc1_head w v2
-(pc1_pr0_r w v2 H17) (THead (Bind Abst) u t0) (THead (Bind b) u2 (lift (S O)
-O (THead (Bind Abst) u t0))) (pc1_pr0_x (THead (Bind Abst) u t0) (THead (Bind
-b) u2 (lift (S O) O (THead (Bind Abst) u t0))) (pr0_zeta b H16 (THead (Bind
-Abst) u t0) (THead (Bind Abst) u t0) (pr0_refl (THead (Bind Abst) u t0)) u2))
-(Flat Appl)))) c2) (THead (Bind Abst) (lift (S O) O u) (lift (S O) (S O) t0))
-(lift_bind Abst u t0 (S O) O)))))))))) (ty3_gen_bind g Abst (CHead c2 (Bind
-b) u2) (lift (S O) O u) (lift (S O) (S O) t0) (lift (S O) O x) H33)))))))))))
-(ty3_gen_bind g b c2 u2 t4 (THead (Bind Abst) u t0) (H20 c2 H4 (THead (Bind
-b) u2 t4) (pr0_comp u1 u2 H18 t3 t4 H19 (Bind b)))))))))))) (ty3_gen_bind g
-Abst c2 u t0 x H23))))) (ty3_correct g c2 (THead (Bind b) u2 t4) (THead (Bind
-Abst) u t0) (H20 c2 H4 (THead (Bind b) u2 t4) (pr0_comp u1 u2 H18 t3 t4 H19
-(Bind b))))))))))) t2 H15)) v H14)) v1 (sym_eq T v1 w H13))) H12)) H11 H6 H7
-H8 H9))) | (pr0_delta u1 u2 H6 t3 t4 H7 w0 H8) \Rightarrow (\lambda (H9: (eq
-T (THead (Bind Abbr) u1 t3) (THead (Flat Appl) w v))).(\lambda (H10: (eq T
-(THead (Bind Abbr) u2 w0) t2)).((let H11 \def (eq_ind T (THead (Bind Abbr) u1
-t3) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort
-_) \Rightarrow False | (TLRef _) \Rightarrow False | (THead k _ _)
-\Rightarrow (match k in K return (\lambda (_: K).Prop) with [(Bind _)
-\Rightarrow True | (Flat _) \Rightarrow False])])) I (THead (Flat Appl) w v)
-H9) in (False_ind ((eq T (THead (Bind Abbr) u2 w0) t2) \to ((pr0 u1 u2) \to
-((pr0 t3 t4) \to ((subst0 O u2 t4 w0) \to (ty3 g c2 t2 (THead (Flat Appl) w
-(THead (Bind Abst) u t0))))))) H11)) H10 H6 H7 H8))) | (pr0_zeta b H6 t3 t4
-H7 u0) \Rightarrow (\lambda (H8: (eq T (THead (Bind b) u0 (lift (S O) O t3))
-(THead (Flat Appl) w v))).(\lambda (H9: (eq T t4 t2)).((let H10 \def (eq_ind
-T (THead (Bind b) u0 (lift (S O) O t3)) (\lambda (e: T).(match e in T return
+(Bind Abst) u t0)))) (THead (Flat Appl) w (THead (Bind Abst) u t0)) (pc1_head
+v2 w (pc1_pr0_x v2 w H17) (THead (Bind b) u2 (lift (S O) O (THead (Bind Abst)
+u t0))) (THead (Bind Abst) u t0) (pc1_pr0_r (THead (Bind b) u2 (lift (S O) O
+(THead (Bind Abst) u t0))) (THead (Bind Abst) u t0) (pr0_zeta b H16 (THead
+(Bind Abst) u t0) (THead (Bind Abst) u t0) (pr0_refl (THead (Bind Abst) u
+t0)) u2)) (Flat Appl))) c2) (THead (Bind Abst) (lift (S O) O u) (lift (S O)
+(S O) t0)) (lift_bind Abst u t0 (S O) O)))))))))) (ty3_gen_bind g Abst (CHead
+c2 (Bind b) u2) (lift (S O) O u) (lift (S O) (S O) t0) (lift (S O) O x)
+H33))))))))))) (ty3_gen_bind g b c2 u2 t4 (THead (Bind Abst) u t0) (H20 c2 H4
+(THead (Bind b) u2 t4) (pr0_comp u1 u2 H18 t3 t4 H19 (Bind b))))))))))))
+(ty3_gen_bind g Abst c2 u t0 x H23))))) (ty3_correct g c2 (THead (Bind b) u2
+t4) (THead (Bind Abst) u t0) (H20 c2 H4 (THead (Bind b) u2 t4) (pr0_comp u1
+u2 H18 t3 t4 H19 (Bind b))))))))))) t2 H15)) v H14)) v1 (sym_eq T v1 w H13)))
+H12)) H11 H6 H7 H8 H9))) | (pr0_delta u1 u2 H6 t3 t4 H7 w0 H8) \Rightarrow
+(\lambda (H9: (eq T (THead (Bind Abbr) u1 t3) (THead (Flat Appl) w
+v))).(\lambda (H10: (eq T (THead (Bind Abbr) u2 w0) t2)).((let H11 \def
+(eq_ind T (THead (Bind Abbr) u1 t3) (\lambda (e: T).(match e in T return
(\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
\Rightarrow False | (THead k _ _) \Rightarrow (match k in K return (\lambda
(_: K).Prop) with [(Bind _) \Rightarrow True | (Flat _) \Rightarrow
-False])])) I (THead (Flat Appl) w v) H8) in (False_ind ((eq T t4 t2) \to
-((not (eq B b Abst)) \to ((pr0 t3 t4) \to (ty3 g c2 t2 (THead (Flat Appl) w
-(THead (Bind Abst) u t0)))))) H10)) H9 H6 H7))) | (pr0_epsilon t3 t4 H6 u0)
-\Rightarrow (\lambda (H7: (eq T (THead (Flat Cast) u0 t3) (THead (Flat Appl)
-w v))).(\lambda (H8: (eq T t4 t2)).((let H9 \def (eq_ind T (THead (Flat Cast)
-u0 t3) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with
-[(TSort _) \Rightarrow False | (TLRef _) \Rightarrow False | (THead k _ _)
-\Rightarrow (match k in K return (\lambda (_: K).Prop) with [(Bind _)
-\Rightarrow False | (Flat f) \Rightarrow (match f in F return (\lambda (_:
-F).Prop) with [Appl \Rightarrow False | Cast \Rightarrow True])])])) I (THead
-(Flat Appl) w v) H7) in (False_ind ((eq T t4 t2) \to ((pr0 t3 t4) \to (ty3 g
-c2 t2 (THead (Flat Appl) w (THead (Bind Abst) u t0))))) H9)) H8 H6)))]) in
-(H6 (refl_equal T (THead (Flat Appl) w v)) (refl_equal T t2))))))))))))))))
-(\lambda (c: C).(\lambda (t2: T).(\lambda (t3: T).(\lambda (_: (ty3 g c t2
-t3)).(\lambda (H1: ((\forall (c2: C).((wcpr0 c c2) \to (\forall (t4: T).((pr0
-t2 t4) \to (ty3 g c2 t4 t3))))))).(\lambda (t0: T).(\lambda (_: (ty3 g c t3
-t0)).(\lambda (H3: ((\forall (c2: C).((wcpr0 c c2) \to (\forall (t4: T).((pr0
-t3 t4) \to (ty3 g c2 t4 t0))))))).(\lambda (c2: C).(\lambda (H4: (wcpr0 c
-c2)).(\lambda (t4: T).(\lambda (H5: (pr0 (THead (Flat Cast) t3 t2) t4)).(let
-H6 \def (match H5 in pr0 return (\lambda (t5: T).(\lambda (t6: T).(\lambda
-(_: (pr0 t5 t6)).((eq T t5 (THead (Flat Cast) t3 t2)) \to ((eq T t6 t4) \to
-(ty3 g c2 t4 (THead (Flat Cast) t0 t3))))))) with [(pr0_refl t5) \Rightarrow
-(\lambda (H6: (eq T t5 (THead (Flat Cast) t3 t2))).(\lambda (H7: (eq T t5
-t4)).(eq_ind T (THead (Flat Cast) t3 t2) (\lambda (t6: T).((eq T t6 t4) \to
-(ty3 g c2 t4 (THead (Flat Cast) t0 t3)))) (\lambda (H8: (eq T (THead (Flat
-Cast) t3 t2) t4)).(eq_ind T (THead (Flat Cast) t3 t2) (\lambda (t6: T).(ty3 g
-c2 t6 (THead (Flat Cast) t0 t3))) (ty3_cast g c2 t2 t3 (H1 c2 H4 t2 (pr0_refl
-t2)) t0 (H3 c2 H4 t3 (pr0_refl t3))) t4 H8)) t5 (sym_eq T t5 (THead (Flat
-Cast) t3 t2) H6) H7))) | (pr0_comp u1 u2 H6 t5 t6 H7 k) \Rightarrow (\lambda
-(H8: (eq T (THead k u1 t5) (THead (Flat Cast) t3 t2))).(\lambda (H9: (eq T
-(THead k u2 t6) t4)).((let H10 \def (f_equal T T (\lambda (e: T).(match e in
-T return (\lambda (_: T).T) with [(TSort _) \Rightarrow t5 | (TLRef _)
-\Rightarrow t5 | (THead _ _ t7) \Rightarrow t7])) (THead k u1 t5) (THead
-(Flat Cast) t3 t2) H8) in ((let H11 \def (f_equal T T (\lambda (e: T).(match
-e in T return (\lambda (_: T).T) with [(TSort _) \Rightarrow u1 | (TLRef _)
-\Rightarrow u1 | (THead _ t7 _) \Rightarrow t7])) (THead k u1 t5) (THead
-(Flat Cast) t3 t2) H8) in ((let H12 \def (f_equal T K (\lambda (e: T).(match
-e in T return (\lambda (_: T).K) with [(TSort _) \Rightarrow k | (TLRef _)
-\Rightarrow k | (THead k0 _ _) \Rightarrow k0])) (THead k u1 t5) (THead (Flat
-Cast) t3 t2) H8) in (eq_ind K (Flat Cast) (\lambda (k0: K).((eq T u1 t3) \to
-((eq T t5 t2) \to ((eq T (THead k0 u2 t6) t4) \to ((pr0 u1 u2) \to ((pr0 t5
-t6) \to (ty3 g c2 t4 (THead (Flat Cast) t0 t3)))))))) (\lambda (H13: (eq T u1
-t3)).(eq_ind T t3 (\lambda (t7: T).((eq T t5 t2) \to ((eq T (THead (Flat
-Cast) u2 t6) t4) \to ((pr0 t7 u2) \to ((pr0 t5 t6) \to (ty3 g c2 t4 (THead
-(Flat Cast) t0 t3))))))) (\lambda (H14: (eq T t5 t2)).(eq_ind T t2 (\lambda
-(t7: T).((eq T (THead (Flat Cast) u2 t6) t4) \to ((pr0 t3 u2) \to ((pr0 t7
-t6) \to (ty3 g c2 t4 (THead (Flat Cast) t0 t3)))))) (\lambda (H15: (eq T
-(THead (Flat Cast) u2 t6) t4)).(eq_ind T (THead (Flat Cast) u2 t6) (\lambda
-(t7: T).((pr0 t3 u2) \to ((pr0 t2 t6) \to (ty3 g c2 t7 (THead (Flat Cast) t0
-t3))))) (\lambda (H16: (pr0 t3 u2)).(\lambda (H17: (pr0 t2 t6)).(ex_ind T
-(\lambda (t7: T).(ty3 g c2 t0 t7)) (ty3 g c2 (THead (Flat Cast) u2 t6) (THead
-(Flat Cast) t0 t3)) (\lambda (x: T).(\lambda (H18: (ty3 g c2 t0 x)).(ty3_conv
-g c2 (THead (Flat Cast) t0 t3) (THead (Flat Cast) x t0) (ty3_cast g c2 t3 t0
-(H3 c2 H4 t3 (pr0_refl t3)) x H18) (THead (Flat Cast) u2 t6) (THead (Flat
-Cast) t0 u2) (ty3_cast g c2 t6 u2 (ty3_conv g c2 u2 t0 (H3 c2 H4 u2 H16) t6
-t3 (H1 c2 H4 t6 H17) (pc3_pr2_r c2 t3 u2 (pr2_free c2 t3 u2 H16))) t0 (H3 c2
-H4 u2 H16)) (pc3_pr2_x c2 (THead (Flat Cast) t0 u2) (THead (Flat Cast) t0 t3)
-(pr2_thin_dx c2 t3 u2 (pr2_free c2 t3 u2 H16) t0 Cast))))) (ty3_correct g c2
-t3 t0 (H3 c2 H4 t3 (pr0_refl t3)))))) t4 H15)) t5 (sym_eq T t5 t2 H14))) u1
-(sym_eq T u1 t3 H13))) k (sym_eq K k (Flat Cast) H12))) H11)) H10)) H9 H6
-H7))) | (pr0_beta u v1 v2 H6 t5 t6 H7) \Rightarrow (\lambda (H8: (eq T (THead
-(Flat Appl) v1 (THead (Bind Abst) u t5)) (THead (Flat Cast) t3 t2))).(\lambda
-(H9: (eq T (THead (Bind Abbr) v2 t6) t4)).((let H10 \def (eq_ind T (THead
-(Flat Appl) v1 (THead (Bind Abst) u t5)) (\lambda (e: T).(match e in T return
+False])])) I (THead (Flat Appl) w v) H9) in (False_ind ((eq T (THead (Bind
+Abbr) u2 w0) t2) \to ((pr0 u1 u2) \to ((pr0 t3 t4) \to ((subst0 O u2 t4 w0)
+\to (ty3 g c2 t2 (THead (Flat Appl) w (THead (Bind Abst) u t0))))))) H11))
+H10 H6 H7 H8))) | (pr0_zeta b H6 t3 t4 H7 u0) \Rightarrow (\lambda (H8: (eq T
+(THead (Bind b) u0 (lift (S O) O t3)) (THead (Flat Appl) w v))).(\lambda (H9:
+(eq T t4 t2)).((let H10 \def (eq_ind T (THead (Bind b) u0 (lift (S O) O t3))
+(\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort _)
+\Rightarrow False | (TLRef _) \Rightarrow False | (THead k _ _) \Rightarrow
+(match k in K return (\lambda (_: K).Prop) with [(Bind _) \Rightarrow True |
+(Flat _) \Rightarrow False])])) I (THead (Flat Appl) w v) H8) in (False_ind
+((eq T t4 t2) \to ((not (eq B b Abst)) \to ((pr0 t3 t4) \to (ty3 g c2 t2
+(THead (Flat Appl) w (THead (Bind Abst) u t0)))))) H10)) H9 H6 H7))) |
+(pr0_epsilon t3 t4 H6 u0) \Rightarrow (\lambda (H7: (eq T (THead (Flat Cast)
+u0 t3) (THead (Flat Appl) w v))).(\lambda (H8: (eq T t4 t2)).((let H9 \def
+(eq_ind T (THead (Flat Cast) u0 t3) (\lambda (e: T).(match e in T return
(\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
\Rightarrow False | (THead k _ _) \Rightarrow (match k in K return (\lambda
(_: K).Prop) with [(Bind _) \Rightarrow False | (Flat f) \Rightarrow (match f
-in F return (\lambda (_: F).Prop) with [Appl \Rightarrow True | Cast
-\Rightarrow False])])])) I (THead (Flat Cast) t3 t2) H8) in (False_ind ((eq T
-(THead (Bind Abbr) v2 t6) t4) \to ((pr0 v1 v2) \to ((pr0 t5 t6) \to (ty3 g c2
-t4 (THead (Flat Cast) t0 t3))))) H10)) H9 H6 H7))) | (pr0_upsilon b H6 v1 v2
-H7 u1 u2 H8 t5 t6 H9) \Rightarrow (\lambda (H10: (eq T (THead (Flat Appl) v1
+in F return (\lambda (_: F).Prop) with [Appl \Rightarrow False | Cast
+\Rightarrow True])])])) I (THead (Flat Appl) w v) H7) in (False_ind ((eq T t4
+t2) \to ((pr0 t3 t4) \to (ty3 g c2 t2 (THead (Flat Appl) w (THead (Bind Abst)
+u t0))))) H9)) H8 H6)))]) in (H6 (refl_equal T (THead (Flat Appl) w v))
+(refl_equal T t2)))))))))))))))) (\lambda (c: C).(\lambda (t2: T).(\lambda
+(t3: T).(\lambda (_: (ty3 g c t2 t3)).(\lambda (H1: ((\forall (c2: C).((wcpr0
+c c2) \to (\forall (t4: T).((pr0 t2 t4) \to (ty3 g c2 t4 t3))))))).(\lambda
+(t0: T).(\lambda (_: (ty3 g c t3 t0)).(\lambda (H3: ((\forall (c2: C).((wcpr0
+c c2) \to (\forall (t4: T).((pr0 t3 t4) \to (ty3 g c2 t4 t0))))))).(\lambda
+(c2: C).(\lambda (H4: (wcpr0 c c2)).(\lambda (t4: T).(\lambda (H5: (pr0
+(THead (Flat Cast) t3 t2) t4)).(let H6 \def (match H5 in pr0 return (\lambda
+(t5: T).(\lambda (t6: T).(\lambda (_: (pr0 t5 t6)).((eq T t5 (THead (Flat
+Cast) t3 t2)) \to ((eq T t6 t4) \to (ty3 g c2 t4 (THead (Flat Cast) t0
+t3))))))) with [(pr0_refl t5) \Rightarrow (\lambda (H6: (eq T t5 (THead (Flat
+Cast) t3 t2))).(\lambda (H7: (eq T t5 t4)).(eq_ind T (THead (Flat Cast) t3
+t2) (\lambda (t6: T).((eq T t6 t4) \to (ty3 g c2 t4 (THead (Flat Cast) t0
+t3)))) (\lambda (H8: (eq T (THead (Flat Cast) t3 t2) t4)).(eq_ind T (THead
+(Flat Cast) t3 t2) (\lambda (t6: T).(ty3 g c2 t6 (THead (Flat Cast) t0 t3)))
+(ty3_cast g c2 t2 t3 (H1 c2 H4 t2 (pr0_refl t2)) t0 (H3 c2 H4 t3 (pr0_refl
+t3))) t4 H8)) t5 (sym_eq T t5 (THead (Flat Cast) t3 t2) H6) H7))) | (pr0_comp
+u1 u2 H6 t5 t6 H7 k) \Rightarrow (\lambda (H8: (eq T (THead k u1 t5) (THead
+(Flat Cast) t3 t2))).(\lambda (H9: (eq T (THead k u2 t6) t4)).((let H10 \def
+(f_equal T T (\lambda (e: T).(match e in T return (\lambda (_: T).T) with
+[(TSort _) \Rightarrow t5 | (TLRef _) \Rightarrow t5 | (THead _ _ t7)
+\Rightarrow t7])) (THead k u1 t5) (THead (Flat Cast) t3 t2) H8) in ((let H11
+\def (f_equal T T (\lambda (e: T).(match e in T return (\lambda (_: T).T)
+with [(TSort _) \Rightarrow u1 | (TLRef _) \Rightarrow u1 | (THead _ t7 _)
+\Rightarrow t7])) (THead k u1 t5) (THead (Flat Cast) t3 t2) H8) in ((let H12
+\def (f_equal T K (\lambda (e: T).(match e in T return (\lambda (_: T).K)
+with [(TSort _) \Rightarrow k | (TLRef _) \Rightarrow k | (THead k0 _ _)
+\Rightarrow k0])) (THead k u1 t5) (THead (Flat Cast) t3 t2) H8) in (eq_ind K
+(Flat Cast) (\lambda (k0: K).((eq T u1 t3) \to ((eq T t5 t2) \to ((eq T
+(THead k0 u2 t6) t4) \to ((pr0 u1 u2) \to ((pr0 t5 t6) \to (ty3 g c2 t4
+(THead (Flat Cast) t0 t3)))))))) (\lambda (H13: (eq T u1 t3)).(eq_ind T t3
+(\lambda (t7: T).((eq T t5 t2) \to ((eq T (THead (Flat Cast) u2 t6) t4) \to
+((pr0 t7 u2) \to ((pr0 t5 t6) \to (ty3 g c2 t4 (THead (Flat Cast) t0
+t3))))))) (\lambda (H14: (eq T t5 t2)).(eq_ind T t2 (\lambda (t7: T).((eq T
+(THead (Flat Cast) u2 t6) t4) \to ((pr0 t3 u2) \to ((pr0 t7 t6) \to (ty3 g c2
+t4 (THead (Flat Cast) t0 t3)))))) (\lambda (H15: (eq T (THead (Flat Cast) u2
+t6) t4)).(eq_ind T (THead (Flat Cast) u2 t6) (\lambda (t7: T).((pr0 t3 u2)
+\to ((pr0 t2 t6) \to (ty3 g c2 t7 (THead (Flat Cast) t0 t3))))) (\lambda
+(H16: (pr0 t3 u2)).(\lambda (H17: (pr0 t2 t6)).(ex_ind T (\lambda (t7:
+T).(ty3 g c2 t0 t7)) (ty3 g c2 (THead (Flat Cast) u2 t6) (THead (Flat Cast)
+t0 t3)) (\lambda (x: T).(\lambda (H18: (ty3 g c2 t0 x)).(ty3_conv g c2 (THead
+(Flat Cast) t0 t3) (THead (Flat Cast) x t0) (ty3_cast g c2 t3 t0 (H3 c2 H4 t3
+(pr0_refl t3)) x H18) (THead (Flat Cast) u2 t6) (THead (Flat Cast) t0 u2)
+(ty3_cast g c2 t6 u2 (ty3_conv g c2 u2 t0 (H3 c2 H4 u2 H16) t6 t3 (H1 c2 H4
+t6 H17) (pc3_pr2_r c2 t3 u2 (pr2_free c2 t3 u2 H16))) t0 (H3 c2 H4 u2 H16))
+(pc3_s c2 (THead (Flat Cast) t0 u2) (THead (Flat Cast) t0 t3) (pc3_pr2_r c2
+(THead (Flat Cast) t0 t3) (THead (Flat Cast) t0 u2) (pr2_thin_dx c2 t3 u2
+(pr2_free c2 t3 u2 H16) t0 Cast)))))) (ty3_correct g c2 t3 t0 (H3 c2 H4 t3
+(pr0_refl t3)))))) t4 H15)) t5 (sym_eq T t5 t2 H14))) u1 (sym_eq T u1 t3
+H13))) k (sym_eq K k (Flat Cast) H12))) H11)) H10)) H9 H6 H7))) | (pr0_beta u
+v1 v2 H6 t5 t6 H7) \Rightarrow (\lambda (H8: (eq T (THead (Flat Appl) v1
+(THead (Bind Abst) u t5)) (THead (Flat Cast) t3 t2))).(\lambda (H9: (eq T
+(THead (Bind Abbr) v2 t6) t4)).((let H10 \def (eq_ind T (THead (Flat Appl) v1
+(THead (Bind Abst) u t5)) (\lambda (e: T).(match e in T return (\lambda (_:
+T).Prop) with [(TSort _) \Rightarrow False | (TLRef _) \Rightarrow False |
+(THead k _ _) \Rightarrow (match k in K return (\lambda (_: K).Prop) with
+[(Bind _) \Rightarrow False | (Flat f) \Rightarrow (match f in F return
+(\lambda (_: F).Prop) with [Appl \Rightarrow True | Cast \Rightarrow
+False])])])) I (THead (Flat Cast) t3 t2) H8) in (False_ind ((eq T (THead
+(Bind Abbr) v2 t6) t4) \to ((pr0 v1 v2) \to ((pr0 t5 t6) \to (ty3 g c2 t4
+(THead (Flat Cast) t0 t3))))) H10)) H9 H6 H7))) | (pr0_upsilon b H6 v1 v2 H7
+u1 u2 H8 t5 t6 H9) \Rightarrow (\lambda (H10: (eq T (THead (Flat Appl) v1
(THead (Bind b) u1 t5)) (THead (Flat Cast) t3 t2))).(\lambda (H11: (eq T
(THead (Bind b) u2 (THead (Flat Appl) (lift (S O) O v2) t6)) t4)).((let H12
\def (eq_ind T (THead (Flat Appl) v1 (THead (Bind b) u1 t5)) (\lambda (e:
t))) (eq_ind nat (S (plus h (minus n h))) (\lambda (n0: nat).(pc3 c0 (lift n0
O t) (lift (S n) O t))) (eq_ind nat n (\lambda (n0: nat).(pc3 c0 (lift (S n0)
O t) (lift (S n) O t))) (pc3_refl c0 (lift (S n) O t)) (plus h (minus n h))
-(le_plus_minus h n (le_trans_plus_r x1 h n H8))) (plus h (S (minus n h)))
-(plus_n_Sm h (minus n h))) (lift h x1 (lift (S (minus n h)) O t)) (lift_free
-t (S (minus n h)) h O x1 (le_trans x1 (S (minus n h)) (plus O (S (minus n
-h))) (le_S_minus x1 h n H8) (le_n (plus O (S (minus n h))))) (le_O_n x1)))
-(ty3_abbr g (minus n h) e d0 u (getl_drop_conf_ge n (CHead d0 (Bind Abbr) u)
-c0 H1 e h x1 H5 H8) t H2)) x0 H9))) H7)) H6)))))))))))))))) (\lambda (n:
-nat).(\lambda (c0: C).(\lambda (d0: C).(\lambda (u: T).(\lambda (H1: (getl n
-c0 (CHead d0 (Bind Abst) u))).(\lambda (t: T).(\lambda (H2: (ty3 g d0 u
-t)).(\lambda (H3: ((\forall (x0: T).(\forall (x1: nat).((eq T u (lift h x1
-x0)) \to (\forall (e: C).((drop h x1 d0 e) \to (ex2 T (\lambda (t2: T).(pc3
-d0 (lift h x1 t2) t)) (\lambda (t2: T).(ty3 g e x0 t2)))))))))).(\lambda (x0:
-T).(\lambda (x1: nat).(\lambda (H4: (eq T (TLRef n) (lift h x1 x0))).(\lambda
-(e: C).(\lambda (H5: (drop h x1 c0 e)).(let H_x \def (lift_gen_lref x0 x1 h n
-H4) in (let H6 \def H_x in (or_ind (land (lt n x1) (eq T x0 (TLRef n))) (land
-(le (plus x1 h) n) (eq T x0 (TLRef (minus n h)))) (ex2 T (\lambda (t2:
+(le_plus_minus h n (le_trans h (plus x1 h) n (le_plus_r x1 h) H8))) (plus h
+(S (minus n h))) (plus_n_Sm h (minus n h))) (lift h x1 (lift (S (minus n h))
+O t)) (lift_free t (S (minus n h)) h O x1 (le_trans x1 (S (minus n h)) (plus
+O (S (minus n h))) (le_S_minus x1 h n H8) (le_n (plus O (S (minus n h)))))
+(le_O_n x1))) (ty3_abbr g (minus n h) e d0 u (getl_drop_conf_ge n (CHead d0
+(Bind Abbr) u) c0 H1 e h x1 H5 H8) t H2)) x0 H9))) H7)) H6))))))))))))))))
+(\lambda (n: nat).(\lambda (c0: C).(\lambda (d0: C).(\lambda (u: T).(\lambda
+(H1: (getl n c0 (CHead d0 (Bind Abst) u))).(\lambda (t: T).(\lambda (H2: (ty3
+g d0 u t)).(\lambda (H3: ((\forall (x0: T).(\forall (x1: nat).((eq T u (lift
+h x1 x0)) \to (\forall (e: C).((drop h x1 d0 e) \to (ex2 T (\lambda (t2:
+T).(pc3 d0 (lift h x1 t2) t)) (\lambda (t2: T).(ty3 g e x0
+t2)))))))))).(\lambda (x0: T).(\lambda (x1: nat).(\lambda (H4: (eq T (TLRef
+n) (lift h x1 x0))).(\lambda (e: C).(\lambda (H5: (drop h x1 c0 e)).(let H_x
+\def (lift_gen_lref x0 x1 h n H4) in (let H6 \def H_x in (or_ind (land (lt n
+x1) (eq T x0 (TLRef n))) (land (le (plus x1 h) n) (eq T x0 (TLRef (minus n
+h)))) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O u)))
+(\lambda (t2: T).(ty3 g e x0 t2))) (\lambda (H7: (land (lt n x1) (eq T x0
+(TLRef n)))).(and_ind (lt n x1) (eq T x0 (TLRef n)) (ex2 T (\lambda (t2:
T).(pc3 c0 (lift h x1 t2) (lift (S n) O u))) (\lambda (t2: T).(ty3 g e x0
-t2))) (\lambda (H7: (land (lt n x1) (eq T x0 (TLRef n)))).(and_ind (lt n x1)
-(eq T x0 (TLRef n)) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S
-n) O u))) (\lambda (t2: T).(ty3 g e x0 t2))) (\lambda (H8: (lt n
-x1)).(\lambda (H9: (eq T x0 (TLRef n))).(eq_ind_r T (TLRef n) (\lambda (t0:
-T).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O u))) (\lambda
-(t2: T).(ty3 g e t0 t2)))) (let H10 \def (eq_ind nat x1 (\lambda (n0:
-nat).(drop h n0 c0 e)) H5 (S (plus n (minus x1 (S n)))) (lt_plus_minus n x1
-H8)) in (ex3_2_ind T C (\lambda (v: T).(\lambda (_: C).(eq T u (lift h (minus
-x1 (S n)) v)))) (\lambda (v: T).(\lambda (e0: C).(getl n e (CHead e0 (Bind
-Abst) v)))) (\lambda (_: T).(\lambda (e0: C).(drop h (minus x1 (S n)) d0
-e0))) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O u)))
-(\lambda (t2: T).(ty3 g e (TLRef n) t2))) (\lambda (x2: T).(\lambda (x3:
-C).(\lambda (H11: (eq T u (lift h (minus x1 (S n)) x2))).(\lambda (H12: (getl
-n e (CHead x3 (Bind Abst) x2))).(\lambda (H13: (drop h (minus x1 (S n)) d0
-x3)).(let H14 \def (eq_ind T u (\lambda (t0: T).(\forall (x4: T).(\forall
-(x5: nat).((eq T t0 (lift h x5 x4)) \to (\forall (e0: C).((drop h x5 d0 e0)
-\to (ex2 T (\lambda (t2: T).(pc3 d0 (lift h x5 t2) t)) (\lambda (t2: T).(ty3
-g e0 x4 t2))))))))) H3 (lift h (minus x1 (S n)) x2) H11) in (let H15 \def
-(eq_ind T u (\lambda (t0: T).(ty3 g d0 t0 t)) H2 (lift h (minus x1 (S n)) x2)
-H11) in (eq_ind_r T (lift h (minus x1 (S n)) x2) (\lambda (t0: T).(ex2 T
-(\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O t0))) (\lambda (t2:
-T).(ty3 g e (TLRef n) t2)))) (let H16 \def (H14 x2 (minus x1 (S n))
-(refl_equal T (lift h (minus x1 (S n)) x2)) x3 H13) in (ex2_ind T (\lambda
-(t2: T).(pc3 d0 (lift h (minus x1 (S n)) t2) t)) (\lambda (t2: T).(ty3 g x3
-x2 t2)) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O (lift h
-(minus x1 (S n)) x2)))) (\lambda (t2: T).(ty3 g e (TLRef n) t2))) (\lambda
-(x4: T).(\lambda (_: (pc3 d0 (lift h (minus x1 (S n)) x4) t)).(\lambda (H18:
-(ty3 g x3 x2 x4)).(eq_ind_r nat (plus (S n) (minus x1 (S n))) (\lambda (n0:
-nat).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h n0 t2) (lift (S n) O (lift h
-(minus n0 (S n)) x2)))) (\lambda (t2: T).(ty3 g e (TLRef n) t2)))) (ex_intro2
-T (\lambda (t2: T).(pc3 c0 (lift h (plus (S n) (minus x1 (S n))) t2) (lift (S
-n) O (lift h (minus (plus (S n) (minus x1 (S n))) (S n)) x2)))) (\lambda (t2:
-T).(ty3 g e (TLRef n) t2)) (lift (S n) O x2) (eq_ind_r T (lift (S n) O (lift
-h (minus x1 (S n)) x2)) (\lambda (t0: T).(pc3 c0 t0 (lift (S n) O (lift h
-(minus (plus (S n) (minus x1 (S n))) (S n)) x2)))) (eq_ind nat x1 (\lambda
-(n0: nat).(pc3 c0 (lift (S n) O (lift h (minus x1 (S n)) x2)) (lift (S n) O
-(lift h (minus n0 (S n)) x2)))) (pc3_refl c0 (lift (S n) O (lift h (minus x1
-(S n)) x2))) (plus (S n) (minus x1 (S n))) (le_plus_minus (S n) x1 H8)) (lift
-h (plus (S n) (minus x1 (S n))) (lift (S n) O x2)) (lift_d x2 h (S n) (minus
-x1 (S n)) O (le_O_n (minus x1 (S n))))) (ty3_abst g n e x3 x2 H12 x4 H18)) x1
-(le_plus_minus (S n) x1 H8))))) H16)) u H11)))))))) (getl_drop_conf_lt Abst
-c0 d0 u n H1 e h (minus x1 (S n)) H10))) x0 H9))) H7)) (\lambda (H7: (land
-(le (plus x1 h) n) (eq T x0 (TLRef (minus n h))))).(and_ind (le (plus x1 h)
-n) (eq T x0 (TLRef (minus n h))) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1
-t2) (lift (S n) O u))) (\lambda (t2: T).(ty3 g e x0 t2))) (\lambda (H8: (le
-(plus x1 h) n)).(\lambda (H9: (eq T x0 (TLRef (minus n h)))).(eq_ind_r T
-(TLRef (minus n h)) (\lambda (t0: T).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h
-x1 t2) (lift (S n) O u))) (\lambda (t2: T).(ty3 g e t0 t2)))) (ex_intro2 T
+t2))) (\lambda (H8: (lt n x1)).(\lambda (H9: (eq T x0 (TLRef n))).(eq_ind_r T
+(TLRef n) (\lambda (t0: T).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2)
+(lift (S n) O u))) (\lambda (t2: T).(ty3 g e t0 t2)))) (let H10 \def (eq_ind
+nat x1 (\lambda (n0: nat).(drop h n0 c0 e)) H5 (S (plus n (minus x1 (S n))))
+(lt_plus_minus n x1 H8)) in (ex3_2_ind T C (\lambda (v: T).(\lambda (_:
+C).(eq T u (lift h (minus x1 (S n)) v)))) (\lambda (v: T).(\lambda (e0:
+C).(getl n e (CHead e0 (Bind Abst) v)))) (\lambda (_: T).(\lambda (e0:
+C).(drop h (minus x1 (S n)) d0 e0))) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h
+x1 t2) (lift (S n) O u))) (\lambda (t2: T).(ty3 g e (TLRef n) t2))) (\lambda
+(x2: T).(\lambda (x3: C).(\lambda (H11: (eq T u (lift h (minus x1 (S n))
+x2))).(\lambda (H12: (getl n e (CHead x3 (Bind Abst) x2))).(\lambda (H13:
+(drop h (minus x1 (S n)) d0 x3)).(let H14 \def (eq_ind T u (\lambda (t0:
+T).(\forall (x4: T).(\forall (x5: nat).((eq T t0 (lift h x5 x4)) \to (\forall
+(e0: C).((drop h x5 d0 e0) \to (ex2 T (\lambda (t2: T).(pc3 d0 (lift h x5 t2)
+t)) (\lambda (t2: T).(ty3 g e0 x4 t2))))))))) H3 (lift h (minus x1 (S n)) x2)
+H11) in (let H15 \def (eq_ind T u (\lambda (t0: T).(ty3 g d0 t0 t)) H2 (lift
+h (minus x1 (S n)) x2) H11) in (eq_ind_r T (lift h (minus x1 (S n)) x2)
+(\lambda (t0: T).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O
+t0))) (\lambda (t2: T).(ty3 g e (TLRef n) t2)))) (let H16 \def (H14 x2 (minus
+x1 (S n)) (refl_equal T (lift h (minus x1 (S n)) x2)) x3 H13) in (ex2_ind T
+(\lambda (t2: T).(pc3 d0 (lift h (minus x1 (S n)) t2) t)) (\lambda (t2:
+T).(ty3 g x3 x2 t2)) (ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S
+n) O (lift h (minus x1 (S n)) x2)))) (\lambda (t2: T).(ty3 g e (TLRef n)
+t2))) (\lambda (x4: T).(\lambda (_: (pc3 d0 (lift h (minus x1 (S n)) x4)
+t)).(\lambda (H18: (ty3 g x3 x2 x4)).(eq_ind_r nat (plus (S n) (minus x1 (S
+n))) (\lambda (n0: nat).(ex2 T (\lambda (t2: T).(pc3 c0 (lift h n0 t2) (lift
+(S n) O (lift h (minus n0 (S n)) x2)))) (\lambda (t2: T).(ty3 g e (TLRef n)
+t2)))) (ex_intro2 T (\lambda (t2: T).(pc3 c0 (lift h (plus (S n) (minus x1 (S
+n))) t2) (lift (S n) O (lift h (minus (plus (S n) (minus x1 (S n))) (S n))
+x2)))) (\lambda (t2: T).(ty3 g e (TLRef n) t2)) (lift (S n) O x2) (eq_ind_r T
+(lift (S n) O (lift h (minus x1 (S n)) x2)) (\lambda (t0: T).(pc3 c0 t0 (lift
+(S n) O (lift h (minus (plus (S n) (minus x1 (S n))) (S n)) x2)))) (eq_ind
+nat x1 (\lambda (n0: nat).(pc3 c0 (lift (S n) O (lift h (minus x1 (S n)) x2))
+(lift (S n) O (lift h (minus n0 (S n)) x2)))) (pc3_refl c0 (lift (S n) O
+(lift h (minus x1 (S n)) x2))) (plus (S n) (minus x1 (S n))) (le_plus_minus
+(S n) x1 H8)) (lift h (plus (S n) (minus x1 (S n))) (lift (S n) O x2))
+(lift_d x2 h (S n) (minus x1 (S n)) O (le_O_n (minus x1 (S n))))) (ty3_abst g
+n e x3 x2 H12 x4 H18)) x1 (le_plus_minus (S n) x1 H8))))) H16)) u H11))))))))
+(getl_drop_conf_lt Abst c0 d0 u n H1 e h (minus x1 (S n)) H10))) x0 H9)))
+H7)) (\lambda (H7: (land (le (plus x1 h) n) (eq T x0 (TLRef (minus n
+h))))).(and_ind (le (plus x1 h) n) (eq T x0 (TLRef (minus n h))) (ex2 T
+(\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O u))) (\lambda (t2:
+T).(ty3 g e x0 t2))) (\lambda (H8: (le (plus x1 h) n)).(\lambda (H9: (eq T x0
+(TLRef (minus n h)))).(eq_ind_r T (TLRef (minus n h)) (\lambda (t0: T).(ex2 T
(\lambda (t2: T).(pc3 c0 (lift h x1 t2) (lift (S n) O u))) (\lambda (t2:
-T).(ty3 g e (TLRef (minus n h)) t2)) (lift (S (minus n h)) O u) (eq_ind_r T
-(lift (plus h (S (minus n h))) O u) (\lambda (t0: T).(pc3 c0 t0 (lift (S n) O
-u))) (eq_ind nat (S (plus h (minus n h))) (\lambda (n0: nat).(pc3 c0 (lift n0
-O u) (lift (S n) O u))) (eq_ind nat n (\lambda (n0: nat).(pc3 c0 (lift (S n0)
-O u) (lift (S n) O u))) (pc3_refl c0 (lift (S n) O u)) (plus h (minus n h))
-(le_plus_minus h n (le_trans_plus_r x1 h n H8))) (plus h (S (minus n h)))
-(plus_n_Sm h (minus n h))) (lift h x1 (lift (S (minus n h)) O u)) (lift_free
-u (S (minus n h)) h O x1 (le_trans x1 (S (minus n h)) (plus O (S (minus n
-h))) (le_S_minus x1 h n H8) (le_n (plus O (S (minus n h))))) (le_O_n x1)))
-(ty3_abst g (minus n h) e d0 u (getl_drop_conf_ge n (CHead d0 (Bind Abst) u)
-c0 H1 e h x1 H5 H8) t H2)) x0 H9))) H7)) H6)))))))))))))))) (\lambda (c0:
-C).(\lambda (u: T).(\lambda (t: T).(\lambda (H1: (ty3 g c0 u t)).(\lambda
-(H2: ((\forall (x0: T).(\forall (x1: nat).((eq T u (lift h x1 x0)) \to
-(\forall (e: C).((drop h x1 c0 e) \to (ex2 T (\lambda (t2: T).(pc3 c0 (lift h
-x1 t2) t)) (\lambda (t2: T).(ty3 g e x0 t2)))))))))).(\lambda (b: B).(\lambda
-(t2: T).(\lambda (t3: T).(\lambda (H3: (ty3 g (CHead c0 (Bind b) u) t2
-t3)).(\lambda (H4: ((\forall (x0: T).(\forall (x1: nat).((eq T t2 (lift h x1
-x0)) \to (\forall (e: C).((drop h x1 (CHead c0 (Bind b) u) e) \to (ex2 T
-(\lambda (t4: T).(pc3 (CHead c0 (Bind b) u) (lift h x1 t4) t3)) (\lambda (t4:
-T).(ty3 g e x0 t4)))))))))).(\lambda (t0: T).(\lambda (H5: (ty3 g (CHead c0
-(Bind b) u) t3 t0)).(\lambda (H6: ((\forall (x0: T).(\forall (x1: nat).((eq T
-t3 (lift h x1 x0)) \to (\forall (e: C).((drop h x1 (CHead c0 (Bind b) u) e)
-\to (ex2 T (\lambda (t4: T).(pc3 (CHead c0 (Bind b) u) (lift h x1 t4) t0))
-(\lambda (t4: T).(ty3 g e x0 t4)))))))))).(\lambda (x0: T).(\lambda (x1:
-nat).(\lambda (H7: (eq T (THead (Bind b) u t2) (lift h x1 x0))).(\lambda (e:
-C).(\lambda (H8: (drop h x1 c0 e)).(ex3_2_ind T T (\lambda (y0: T).(\lambda
-(z: T).(eq T x0 (THead (Bind b) y0 z)))) (\lambda (y0: T).(\lambda (_: T).(eq
-T u (lift h x1 y0)))) (\lambda (_: T).(\lambda (z: T).(eq T t2 (lift h (S x1)
-z)))) (ex2 T (\lambda (t4: T).(pc3 c0 (lift h x1 t4) (THead (Bind b) u t3)))
-(\lambda (t4: T).(ty3 g e x0 t4))) (\lambda (x2: T).(\lambda (x3: T).(\lambda
-(H9: (eq T x0 (THead (Bind b) x2 x3))).(\lambda (H10: (eq T u (lift h x1
-x2))).(\lambda (H11: (eq T t2 (lift h (S x1) x3))).(eq_ind_r T (THead (Bind
-b) x2 x3) (\lambda (t4: T).(ex2 T (\lambda (t5: T).(pc3 c0 (lift h x1 t5)
-(THead (Bind b) u t3))) (\lambda (t5: T).(ty3 g e t4 t5)))) (let H12 \def
-(eq_ind T t2 (\lambda (t4: T).(\forall (x4: T).(\forall (x5: nat).((eq T t4
-(lift h x5 x4)) \to (\forall (e0: C).((drop h x5 (CHead c0 (Bind b) u) e0)
-\to (ex2 T (\lambda (t5: T).(pc3 (CHead c0 (Bind b) u) (lift h x5 t5) t3))
-(\lambda (t5: T).(ty3 g e0 x4 t5))))))))) H4 (lift h (S x1) x3) H11) in (let
-H13 \def (eq_ind T t2 (\lambda (t4: T).(ty3 g (CHead c0 (Bind b) u) t4 t3))
-H3 (lift h (S x1) x3) H11) in (let H14 \def (eq_ind T u (\lambda (t4: T).(ty3
-g (CHead c0 (Bind b) t4) (lift h (S x1) x3) t3)) H13 (lift h x1 x2) H10) in
-(let H15 \def (eq_ind T u (\lambda (t4: T).(\forall (x4: T).(\forall (x5:
-nat).((eq T (lift h (S x1) x3) (lift h x5 x4)) \to (\forall (e0: C).((drop h
-x5 (CHead c0 (Bind b) t4) e0) \to (ex2 T (\lambda (t5: T).(pc3 (CHead c0
-(Bind b) t4) (lift h x5 t5) t3)) (\lambda (t5: T).(ty3 g e0 x4 t5)))))))))
-H12 (lift h x1 x2) H10) in (let H16 \def (eq_ind T u (\lambda (t4:
-T).(\forall (x4: T).(\forall (x5: nat).((eq T t3 (lift h x5 x4)) \to (\forall
-(e0: C).((drop h x5 (CHead c0 (Bind b) t4) e0) \to (ex2 T (\lambda (t5:
-T).(pc3 (CHead c0 (Bind b) t4) (lift h x5 t5) t0)) (\lambda (t5: T).(ty3 g e0
-x4 t5))))))))) H6 (lift h x1 x2) H10) in (let H17 \def (eq_ind T u (\lambda
-(t4: T).(ty3 g (CHead c0 (Bind b) t4) t3 t0)) H5 (lift h x1 x2) H10) in (let
-H18 \def (eq_ind T u (\lambda (t4: T).(\forall (x4: T).(\forall (x5:
-nat).((eq T t4 (lift h x5 x4)) \to (\forall (e0: C).((drop h x5 c0 e0) \to
-(ex2 T (\lambda (t5: T).(pc3 c0 (lift h x5 t5) t)) (\lambda (t5: T).(ty3 g e0
-x4 t5))))))))) H2 (lift h x1 x2) H10) in (let H19 \def (eq_ind T u (\lambda
-(t4: T).(ty3 g c0 t4 t)) H1 (lift h x1 x2) H10) in (eq_ind_r T (lift h x1 x2)
-(\lambda (t4: T).(ex2 T (\lambda (t5: T).(pc3 c0 (lift h x1 t5) (THead (Bind
-b) t4 t3))) (\lambda (t5: T).(ty3 g e (THead (Bind b) x2 x3) t5)))) (let H20
-\def (H18 x2 x1 (refl_equal T (lift h x1 x2)) e H8) in (ex2_ind T (\lambda
-(t4: T).(pc3 c0 (lift h x1 t4) t)) (\lambda (t4: T).(ty3 g e x2 t4)) (ex2 T
-(\lambda (t4: T).(pc3 c0 (lift h x1 t4) (THead (Bind b) (lift h x1 x2) t3)))
-(\lambda (t4: T).(ty3 g e (THead (Bind b) x2 x3) t4))) (\lambda (x4:
-T).(\lambda (_: (pc3 c0 (lift h x1 x4) t)).(\lambda (H22: (ty3 g e x2
-x4)).(let H23 \def (H15 x3 (S x1) (refl_equal T (lift h (S x1) x3)) (CHead e
-(Bind b) x2) (drop_skip_bind h x1 c0 e H8 b x2)) in (ex2_ind T (\lambda (t4:
-T).(pc3 (CHead c0 (Bind b) (lift h x1 x2)) (lift h (S x1) t4) t3)) (\lambda
-(t4: T).(ty3 g (CHead e (Bind b) x2) x3 t4)) (ex2 T (\lambda (t4: T).(pc3 c0
+T).(ty3 g e t0 t2)))) (ex_intro2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2)
+(lift (S n) O u))) (\lambda (t2: T).(ty3 g e (TLRef (minus n h)) t2)) (lift
+(S (minus n h)) O u) (eq_ind_r T (lift (plus h (S (minus n h))) O u) (\lambda
+(t0: T).(pc3 c0 t0 (lift (S n) O u))) (eq_ind nat (S (plus h (minus n h)))
+(\lambda (n0: nat).(pc3 c0 (lift n0 O u) (lift (S n) O u))) (eq_ind nat n
+(\lambda (n0: nat).(pc3 c0 (lift (S n0) O u) (lift (S n) O u))) (pc3_refl c0
+(lift (S n) O u)) (plus h (minus n h)) (le_plus_minus h n (le_trans h (plus
+x1 h) n (le_plus_r x1 h) H8))) (plus h (S (minus n h))) (plus_n_Sm h (minus n
+h))) (lift h x1 (lift (S (minus n h)) O u)) (lift_free u (S (minus n h)) h O
+x1 (le_trans x1 (S (minus n h)) (plus O (S (minus n h))) (le_S_minus x1 h n
+H8) (le_n (plus O (S (minus n h))))) (le_O_n x1))) (ty3_abst g (minus n h) e
+d0 u (getl_drop_conf_ge n (CHead d0 (Bind Abst) u) c0 H1 e h x1 H5 H8) t H2))
+x0 H9))) H7)) H6)))))))))))))))) (\lambda (c0: C).(\lambda (u: T).(\lambda
+(t: T).(\lambda (H1: (ty3 g c0 u t)).(\lambda (H2: ((\forall (x0: T).(\forall
+(x1: nat).((eq T u (lift h x1 x0)) \to (\forall (e: C).((drop h x1 c0 e) \to
+(ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) t)) (\lambda (t2: T).(ty3 g e
+x0 t2)))))))))).(\lambda (b: B).(\lambda (t2: T).(\lambda (t3: T).(\lambda
+(H3: (ty3 g (CHead c0 (Bind b) u) t2 t3)).(\lambda (H4: ((\forall (x0:
+T).(\forall (x1: nat).((eq T t2 (lift h x1 x0)) \to (\forall (e: C).((drop h
+x1 (CHead c0 (Bind b) u) e) \to (ex2 T (\lambda (t4: T).(pc3 (CHead c0 (Bind
+b) u) (lift h x1 t4) t3)) (\lambda (t4: T).(ty3 g e x0 t4)))))))))).(\lambda
+(t0: T).(\lambda (H5: (ty3 g (CHead c0 (Bind b) u) t3 t0)).(\lambda (H6:
+((\forall (x0: T).(\forall (x1: nat).((eq T t3 (lift h x1 x0)) \to (\forall
+(e: C).((drop h x1 (CHead c0 (Bind b) u) e) \to (ex2 T (\lambda (t4: T).(pc3
+(CHead c0 (Bind b) u) (lift h x1 t4) t0)) (\lambda (t4: T).(ty3 g e x0
+t4)))))))))).(\lambda (x0: T).(\lambda (x1: nat).(\lambda (H7: (eq T (THead
+(Bind b) u t2) (lift h x1 x0))).(\lambda (e: C).(\lambda (H8: (drop h x1 c0
+e)).(ex3_2_ind T T (\lambda (y0: T).(\lambda (z: T).(eq T x0 (THead (Bind b)
+y0 z)))) (\lambda (y0: T).(\lambda (_: T).(eq T u (lift h x1 y0)))) (\lambda
+(_: T).(\lambda (z: T).(eq T t2 (lift h (S x1) z)))) (ex2 T (\lambda (t4:
+T).(pc3 c0 (lift h x1 t4) (THead (Bind b) u t3))) (\lambda (t4: T).(ty3 g e
+x0 t4))) (\lambda (x2: T).(\lambda (x3: T).(\lambda (H9: (eq T x0 (THead
+(Bind b) x2 x3))).(\lambda (H10: (eq T u (lift h x1 x2))).(\lambda (H11: (eq
+T t2 (lift h (S x1) x3))).(eq_ind_r T (THead (Bind b) x2 x3) (\lambda (t4:
+T).(ex2 T (\lambda (t5: T).(pc3 c0 (lift h x1 t5) (THead (Bind b) u t3)))
+(\lambda (t5: T).(ty3 g e t4 t5)))) (let H12 \def (eq_ind T t2 (\lambda (t4:
+T).(\forall (x4: T).(\forall (x5: nat).((eq T t4 (lift h x5 x4)) \to (\forall
+(e0: C).((drop h x5 (CHead c0 (Bind b) u) e0) \to (ex2 T (\lambda (t5:
+T).(pc3 (CHead c0 (Bind b) u) (lift h x5 t5) t3)) (\lambda (t5: T).(ty3 g e0
+x4 t5))))))))) H4 (lift h (S x1) x3) H11) in (let H13 \def (eq_ind T t2
+(\lambda (t4: T).(ty3 g (CHead c0 (Bind b) u) t4 t3)) H3 (lift h (S x1) x3)
+H11) in (let H14 \def (eq_ind T u (\lambda (t4: T).(ty3 g (CHead c0 (Bind b)
+t4) (lift h (S x1) x3) t3)) H13 (lift h x1 x2) H10) in (let H15 \def (eq_ind
+T u (\lambda (t4: T).(\forall (x4: T).(\forall (x5: nat).((eq T (lift h (S
+x1) x3) (lift h x5 x4)) \to (\forall (e0: C).((drop h x5 (CHead c0 (Bind b)
+t4) e0) \to (ex2 T (\lambda (t5: T).(pc3 (CHead c0 (Bind b) t4) (lift h x5
+t5) t3)) (\lambda (t5: T).(ty3 g e0 x4 t5))))))))) H12 (lift h x1 x2) H10) in
+(let H16 \def (eq_ind T u (\lambda (t4: T).(\forall (x4: T).(\forall (x5:
+nat).((eq T t3 (lift h x5 x4)) \to (\forall (e0: C).((drop h x5 (CHead c0
+(Bind b) t4) e0) \to (ex2 T (\lambda (t5: T).(pc3 (CHead c0 (Bind b) t4)
+(lift h x5 t5) t0)) (\lambda (t5: T).(ty3 g e0 x4 t5))))))))) H6 (lift h x1
+x2) H10) in (let H17 \def (eq_ind T u (\lambda (t4: T).(ty3 g (CHead c0 (Bind
+b) t4) t3 t0)) H5 (lift h x1 x2) H10) in (let H18 \def (eq_ind T u (\lambda
+(t4: T).(\forall (x4: T).(\forall (x5: nat).((eq T t4 (lift h x5 x4)) \to
+(\forall (e0: C).((drop h x5 c0 e0) \to (ex2 T (\lambda (t5: T).(pc3 c0 (lift
+h x5 t5) t)) (\lambda (t5: T).(ty3 g e0 x4 t5))))))))) H2 (lift h x1 x2) H10)
+in (let H19 \def (eq_ind T u (\lambda (t4: T).(ty3 g c0 t4 t)) H1 (lift h x1
+x2) H10) in (eq_ind_r T (lift h x1 x2) (\lambda (t4: T).(ex2 T (\lambda (t5:
+T).(pc3 c0 (lift h x1 t5) (THead (Bind b) t4 t3))) (\lambda (t5: T).(ty3 g e
+(THead (Bind b) x2 x3) t5)))) (let H20 \def (H18 x2 x1 (refl_equal T (lift h
+x1 x2)) e H8) in (ex2_ind T (\lambda (t4: T).(pc3 c0 (lift h x1 t4) t))
+(\lambda (t4: T).(ty3 g e x2 t4)) (ex2 T (\lambda (t4: T).(pc3 c0 (lift h x1
+t4) (THead (Bind b) (lift h x1 x2) t3))) (\lambda (t4: T).(ty3 g e (THead
+(Bind b) x2 x3) t4))) (\lambda (x4: T).(\lambda (_: (pc3 c0 (lift h x1 x4)
+t)).(\lambda (H22: (ty3 g e x2 x4)).(let H23 \def (H15 x3 (S x1) (refl_equal
+T (lift h (S x1) x3)) (CHead e (Bind b) x2) (drop_skip_bind h x1 c0 e H8 b
+x2)) in (ex2_ind T (\lambda (t4: T).(pc3 (CHead c0 (Bind b) (lift h x1 x2))
+(lift h (S x1) t4) t3)) (\lambda (t4: T).(ty3 g (CHead e (Bind b) x2) x3 t4))
+(ex2 T (\lambda (t4: T).(pc3 c0 (lift h x1 t4) (THead (Bind b) (lift h x1 x2)
+t3))) (\lambda (t4: T).(ty3 g e (THead (Bind b) x2 x3) t4))) (\lambda (x5:
+T).(\lambda (H24: (pc3 (CHead c0 (Bind b) (lift h x1 x2)) (lift h (S x1) x5)
+t3)).(\lambda (H25: (ty3 g (CHead e (Bind b) x2) x3 x5)).(ex_ind T (\lambda
+(t4: T).(ty3 g (CHead e (Bind b) x2) x5 t4)) (ex2 T (\lambda (t4: T).(pc3 c0
(lift h x1 t4) (THead (Bind b) (lift h x1 x2) t3))) (\lambda (t4: T).(ty3 g e
-(THead (Bind b) x2 x3) t4))) (\lambda (x5: T).(\lambda (H24: (pc3 (CHead c0
-(Bind b) (lift h x1 x2)) (lift h (S x1) x5) t3)).(\lambda (H25: (ty3 g (CHead
-e (Bind b) x2) x3 x5)).(ex_ind T (\lambda (t4: T).(ty3 g (CHead e (Bind b)
-x2) x5 t4)) (ex2 T (\lambda (t4: T).(pc3 c0 (lift h x1 t4) (THead (Bind b)
-(lift h x1 x2) t3))) (\lambda (t4: T).(ty3 g e (THead (Bind b) x2 x3) t4)))
-(\lambda (x6: T).(\lambda (H26: (ty3 g (CHead e (Bind b) x2) x5
-x6)).(ex_intro2 T (\lambda (t4: T).(pc3 c0 (lift h x1 t4) (THead (Bind b)
-(lift h x1 x2) t3))) (\lambda (t4: T).(ty3 g e (THead (Bind b) x2 x3) t4))
-(THead (Bind b) x2 x5) (eq_ind_r T (THead (Bind b) (lift h x1 x2) (lift h (S
-x1) x5)) (\lambda (t4: T).(pc3 c0 t4 (THead (Bind b) (lift h x1 x2) t3)))
-(pc3_head_2 c0 (lift h x1 x2) (lift h (S x1) x5) t3 (Bind b) H24) (lift h x1
-(THead (Bind b) x2 x5)) (lift_bind b x2 x5 h x1)) (ty3_bind g e x2 x4 H22 b
-x3 x5 H25 x6 H26)))) (ty3_correct g (CHead e (Bind b) x2) x3 x5 H25)))))
-H23))))) H20)) u H10))))))))) x0 H9)))))) (lift_gen_bind b u t2 x0 h x1
-H7)))))))))))))))))))) (\lambda (c0: C).(\lambda (w: T).(\lambda (u:
+(THead (Bind b) x2 x3) t4))) (\lambda (x6: T).(\lambda (H26: (ty3 g (CHead e
+(Bind b) x2) x5 x6)).(ex_intro2 T (\lambda (t4: T).(pc3 c0 (lift h x1 t4)
+(THead (Bind b) (lift h x1 x2) t3))) (\lambda (t4: T).(ty3 g e (THead (Bind
+b) x2 x3) t4)) (THead (Bind b) x2 x5) (eq_ind_r T (THead (Bind b) (lift h x1
+x2) (lift h (S x1) x5)) (\lambda (t4: T).(pc3 c0 t4 (THead (Bind b) (lift h
+x1 x2) t3))) (pc3_head_2 c0 (lift h x1 x2) (lift h (S x1) x5) t3 (Bind b)
+H24) (lift h x1 (THead (Bind b) x2 x5)) (lift_bind b x2 x5 h x1)) (ty3_bind g
+e x2 x4 H22 b x3 x5 H25 x6 H26)))) (ty3_correct g (CHead e (Bind b) x2) x3 x5
+H25))))) H23))))) H20)) u H10))))))))) x0 H9)))))) (lift_gen_bind b u t2 x0 h
+x1 H7)))))))))))))))))))) (\lambda (c0: C).(\lambda (w: T).(\lambda (u:
T).(\lambda (H1: (ty3 g c0 w u)).(\lambda (H2: ((\forall (x0: T).(\forall
(x1: nat).((eq T w (lift h x1 x0)) \to (\forall (e: C).((drop h x1 c0 e) \to
(ex2 T (\lambda (t2: T).(pc3 c0 (lift h x1 t2) u)) (\lambda (t2: T).(ty3 g e
(t0: T).(ty3 g (CHead c (Bind Abst) u) t3 t0)))) (ex2 T (\lambda (w: T).(ty3
g c u w)) (\lambda (_: T).(ty3 g (CHead c (Bind Abst) u) t1 t2))) (\lambda
(x0: T).(\lambda (x1: T).(\lambda (x2: T).(\lambda (_: (pc3 c (THead (Bind
-Abst) u x0) x)).(\lambda (_: (ty3 g c u x1)).(\lambda (H3: (ty3 g (CHead c
+Abst) u x0) x)).(\lambda (H2: (ty3 g c u x1)).(\lambda (H3: (ty3 g (CHead c
(Bind Abst) u) t2 x0)).(\lambda (_: (ty3 g (CHead c (Bind Abst) u) x0
x2)).(ex4_3_ind T T T (\lambda (t3: T).(\lambda (_: T).(\lambda (_: T).(pc3 c
(THead (Bind Abst) u t3) (THead (Bind Abst) u t2))))) (\lambda (_:
T).(\lambda (_: T).(\lambda (t0: T).(ty3 g (CHead c (Bind Abst) u) t3 t0))))
(ex2 T (\lambda (w: T).(ty3 g c u w)) (\lambda (_: T).(ty3 g (CHead c (Bind
Abst) u) t1 t2))) (\lambda (x3: T).(\lambda (x4: T).(\lambda (x5: T).(\lambda
-(H5: (pc3 c (THead (Bind Abst) u x3) (THead (Bind Abst) u t2))).(\lambda (H6:
+(H5: (pc3 c (THead (Bind Abst) u x3) (THead (Bind Abst) u t2))).(\lambda (_:
(ty3 g c u x4)).(\lambda (H7: (ty3 g (CHead c (Bind Abst) u) t1 x3)).(\lambda
-(_: (ty3 g (CHead c (Bind Abst) u) x3 x5)).(and_ind (pc3 c u u) (\forall (b:
-B).(\forall (u0: T).(pc3 (CHead c (Bind b) u0) x3 t2))) (ex2 T (\lambda (w:
-T).(ty3 g c u w)) (\lambda (_: T).(ty3 g (CHead c (Bind Abst) u) t1 t2)))
-(\lambda (_: (pc3 c u u)).(\lambda (H10: ((\forall (b: B).(\forall (u0:
-T).(pc3 (CHead c (Bind b) u0) x3 t2))))).(ex_intro2 T (\lambda (w: T).(ty3 g
-c u w)) (\lambda (_: T).(ty3 g (CHead c (Bind Abst) u) t1 t2)) x4 H6
-(ty3_conv g (CHead c (Bind Abst) u) t2 x0 H3 t1 x3 H7 (H10 Abst u)))))
-(pc3_gen_abst c u u x3 t2 H5))))))))) (ty3_gen_bind g Abst c u t1 (THead
+(_: (ty3 g (CHead c (Bind Abst) u) x3 x5)).(let H_y \def (pc3_gen_abst_shift
+c u x3 t2 H5) in (ex_intro2 T (\lambda (w: T).(ty3 g c u w)) (\lambda (_:
+T).(ty3 g (CHead c (Bind Abst) u) t1 t2)) x1 H2 (ty3_conv g (CHead c (Bind
+Abst) u) t2 x0 H3 t1 x3 H7 H_y)))))))))) (ty3_gen_bind g Abst c u t1 (THead
(Bind Abst) u t2) H))))))))) (ty3_gen_bind g Abst c u t2 x H0))))
(ty3_correct g c (THead (Bind Abst) u t1) (THead (Bind Abst) u t2) H))))))).
u0 H0 t3 x2 (ty3_sconv g c0 t3 x H16 (THead (Bind Abst) u0 t) (THead (Bind
Abst) u0 x2) (ty3_bind g c0 u0 x3 H20 Abst t x2 H21 x4 H22) H15)) (THead
(Flat Appl) w v) (THead (Flat Appl) w (THead (Bind Abst) u0 t)) (ty3_appl g
-c0 w u0 H0 v t H2) (pc3_s c0 (THead (Flat Appl) w (THead (Bind Abst) u0 t))
-(THead (Flat Appl) w t3) (pc3_thin_dx c0 t3 (THead (Bind Abst) u0 t) H15 w
-Appl)))))))))) (ty3_gen_bind g Abst c0 u0 t x1 H18)))) (ty3_correct g c0 v
-(THead (Bind Abst) u0 t) H2)))) (ty3_correct g c0 w u0 H0)))) (ty3_correct g
-c0 v t3 H_y))))) t2 H13)) t0 (sym_eq T t0 v H12))) v0 (sym_eq T v0 w H11)))
-H10))) c1 (sym_eq C c1 c0 H6) H7 H8 H5)))) | (tau0_cast c1 v1 v2 H5 t0 t3 H6)
-\Rightarrow (\lambda (H7: (eq C c1 c0)).(\lambda (H8: (eq T (THead (Flat
-Cast) v1 t0) (THead (Flat Appl) w v))).(\lambda (H9: (eq T (THead (Flat Cast)
-v2 t3) t2)).(eq_ind C c0 (\lambda (c2: C).((eq T (THead (Flat Cast) v1 t0)
-(THead (Flat Appl) w v)) \to ((eq T (THead (Flat Cast) v2 t3) t2) \to ((tau0
-g c2 v1 v2) \to ((tau0 g c2 t0 t3) \to (ty3 g c0 (THead (Flat Appl) w v)
-t2)))))) (\lambda (H10: (eq T (THead (Flat Cast) v1 t0) (THead (Flat Appl) w
-v))).(let H11 \def (eq_ind T (THead (Flat Cast) v1 t0) (\lambda (e: T).(match
+c0 w u0 H0 v t H2) (pc3_thin_dx c0 (THead (Bind Abst) u0 t) t3 (ty3_unique g
+c0 v (THead (Bind Abst) u0 t) H2 t3 H_y) w Appl))))))))) (ty3_gen_bind g Abst
+c0 u0 t x1 H18)))) (ty3_correct g c0 v (THead (Bind Abst) u0 t) H2))))
+(ty3_correct g c0 w u0 H0)))) (ty3_correct g c0 v t3 H_y))))) t2 H13)) t0
+(sym_eq T t0 v H12))) v0 (sym_eq T v0 w H11))) H10))) c1 (sym_eq C c1 c0 H6)
+H7 H8 H5)))) | (tau0_cast c1 v1 v2 H5 t0 t3 H6) \Rightarrow (\lambda (H7: (eq
+C c1 c0)).(\lambda (H8: (eq T (THead (Flat Cast) v1 t0) (THead (Flat Appl) w
+v))).(\lambda (H9: (eq T (THead (Flat Cast) v2 t3) t2)).(eq_ind C c0 (\lambda
+(c2: C).((eq T (THead (Flat Cast) v1 t0) (THead (Flat Appl) w v)) \to ((eq T
+(THead (Flat Cast) v2 t3) t2) \to ((tau0 g c2 v1 v2) \to ((tau0 g c2 t0 t3)
+\to (ty3 g c0 (THead (Flat Appl) w v) t2)))))) (\lambda (H10: (eq T (THead
+(Flat Cast) v1 t0) (THead (Flat Appl) w v))).(let H11 \def (eq_ind T (THead
+(Flat Cast) v1 t0) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop)
+with [(TSort _) \Rightarrow False | (TLRef _) \Rightarrow False | (THead k _
+_) \Rightarrow (match k in K return (\lambda (_: K).Prop) with [(Bind _)
+\Rightarrow False | (Flat f) \Rightarrow (match f in F return (\lambda (_:
+F).Prop) with [Appl \Rightarrow False | Cast \Rightarrow True])])])) I (THead
+(Flat Appl) w v) H10) in (False_ind ((eq T (THead (Flat Cast) v2 t3) t2) \to
+((tau0 g c0 v1 v2) \to ((tau0 g c0 t0 t3) \to (ty3 g c0 (THead (Flat Appl) w
+v) t2)))) H11))) c1 (sym_eq C c1 c0 H7) H8 H9 H5 H6))))]) in (H5 (refl_equal
+C c0) (refl_equal T (THead (Flat Appl) w v)) (refl_equal T t2))))))))))))))
+(\lambda (c0: C).(\lambda (t2: T).(\lambda (t3: T).(\lambda (H0: (ty3 g c0 t2
+t3)).(\lambda (H1: ((\forall (t4: T).((tau0 g c0 t2 t4) \to (ty3 g c0 t2
+t4))))).(\lambda (t0: T).(\lambda (_: (ty3 g c0 t3 t0)).(\lambda (H3:
+((\forall (t4: T).((tau0 g c0 t3 t4) \to (ty3 g c0 t3 t4))))).(\lambda (t4:
+T).(\lambda (H4: (tau0 g c0 (THead (Flat Cast) t3 t2) t4)).(let H5 \def
+(match H4 in tau0 return (\lambda (c1: C).(\lambda (t: T).(\lambda (t5:
+T).(\lambda (_: (tau0 ? c1 t t5)).((eq C c1 c0) \to ((eq T t (THead (Flat
+Cast) t3 t2)) \to ((eq T t5 t4) \to (ty3 g c0 (THead (Flat Cast) t3 t2)
+t4)))))))) with [(tau0_sort c1 n) \Rightarrow (\lambda (H5: (eq C c1
+c0)).(\lambda (H6: (eq T (TSort n) (THead (Flat Cast) t3 t2))).(\lambda (H7:
+(eq T (TSort (next g n)) t4)).(eq_ind C c0 (\lambda (_: C).((eq T (TSort n)
+(THead (Flat Cast) t3 t2)) \to ((eq T (TSort (next g n)) t4) \to (ty3 g c0
+(THead (Flat Cast) t3 t2) t4)))) (\lambda (H8: (eq T (TSort n) (THead (Flat
+Cast) t3 t2))).(let H9 \def (eq_ind T (TSort n) (\lambda (e: T).(match e in T
+return (\lambda (_: T).Prop) with [(TSort _) \Rightarrow True | (TLRef _)
+\Rightarrow False | (THead _ _ _) \Rightarrow False])) I (THead (Flat Cast)
+t3 t2) H8) in (False_ind ((eq T (TSort (next g n)) t4) \to (ty3 g c0 (THead
+(Flat Cast) t3 t2) t4)) H9))) c1 (sym_eq C c1 c0 H5) H6 H7)))) | (tau0_abbr
+c1 d v i H5 w H6) \Rightarrow (\lambda (H7: (eq C c1 c0)).(\lambda (H8: (eq T
+(TLRef i) (THead (Flat Cast) t3 t2))).(\lambda (H9: (eq T (lift (S i) O w)
+t4)).(eq_ind C c0 (\lambda (c2: C).((eq T (TLRef i) (THead (Flat Cast) t3
+t2)) \to ((eq T (lift (S i) O w) t4) \to ((getl i c2 (CHead d (Bind Abbr) v))
+\to ((tau0 g d v w) \to (ty3 g c0 (THead (Flat Cast) t3 t2) t4)))))) (\lambda
+(H10: (eq T (TLRef i) (THead (Flat Cast) t3 t2))).(let H11 \def (eq_ind T
+(TLRef i) (\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with
+[(TSort _) \Rightarrow False | (TLRef _) \Rightarrow True | (THead _ _ _)
+\Rightarrow False])) I (THead (Flat Cast) t3 t2) H10) in (False_ind ((eq T
+(lift (S i) O w) t4) \to ((getl i c0 (CHead d (Bind Abbr) v)) \to ((tau0 g d
+v w) \to (ty3 g c0 (THead (Flat Cast) t3 t2) t4)))) H11))) c1 (sym_eq C c1 c0
+H7) H8 H9 H5 H6)))) | (tau0_abst c1 d v i H5 w H6) \Rightarrow (\lambda (H7:
+(eq C c1 c0)).(\lambda (H8: (eq T (TLRef i) (THead (Flat Cast) t3
+t2))).(\lambda (H9: (eq T (lift (S i) O v) t4)).(eq_ind C c0 (\lambda (c2:
+C).((eq T (TLRef i) (THead (Flat Cast) t3 t2)) \to ((eq T (lift (S i) O v)
+t4) \to ((getl i c2 (CHead d (Bind Abst) v)) \to ((tau0 g d v w) \to (ty3 g
+c0 (THead (Flat Cast) t3 t2) t4)))))) (\lambda (H10: (eq T (TLRef i) (THead
+(Flat Cast) t3 t2))).(let H11 \def (eq_ind T (TLRef i) (\lambda (e: T).(match
e in T return (\lambda (_: T).Prop) with [(TSort _) \Rightarrow False |
-(TLRef _) \Rightarrow False | (THead k _ _) \Rightarrow (match k in K return
-(\lambda (_: K).Prop) with [(Bind _) \Rightarrow False | (Flat f) \Rightarrow
-(match f in F return (\lambda (_: F).Prop) with [Appl \Rightarrow False |
-Cast \Rightarrow True])])])) I (THead (Flat Appl) w v) H10) in (False_ind
-((eq T (THead (Flat Cast) v2 t3) t2) \to ((tau0 g c0 v1 v2) \to ((tau0 g c0
-t0 t3) \to (ty3 g c0 (THead (Flat Appl) w v) t2)))) H11))) c1 (sym_eq C c1 c0
-H7) H8 H9 H5 H6))))]) in (H5 (refl_equal C c0) (refl_equal T (THead (Flat
-Appl) w v)) (refl_equal T t2)))))))))))))) (\lambda (c0: C).(\lambda (t2:
-T).(\lambda (t3: T).(\lambda (H0: (ty3 g c0 t2 t3)).(\lambda (H1: ((\forall
-(t4: T).((tau0 g c0 t2 t4) \to (ty3 g c0 t2 t4))))).(\lambda (t0: T).(\lambda
-(_: (ty3 g c0 t3 t0)).(\lambda (H3: ((\forall (t4: T).((tau0 g c0 t3 t4) \to
-(ty3 g c0 t3 t4))))).(\lambda (t4: T).(\lambda (H4: (tau0 g c0 (THead (Flat
-Cast) t3 t2) t4)).(let H5 \def (match H4 in tau0 return (\lambda (c1:
-C).(\lambda (t: T).(\lambda (t5: T).(\lambda (_: (tau0 ? c1 t t5)).((eq C c1
-c0) \to ((eq T t (THead (Flat Cast) t3 t2)) \to ((eq T t5 t4) \to (ty3 g c0
-(THead (Flat Cast) t3 t2) t4)))))))) with [(tau0_sort c1 n) \Rightarrow
-(\lambda (H5: (eq C c1 c0)).(\lambda (H6: (eq T (TSort n) (THead (Flat Cast)
-t3 t2))).(\lambda (H7: (eq T (TSort (next g n)) t4)).(eq_ind C c0 (\lambda
-(_: C).((eq T (TSort n) (THead (Flat Cast) t3 t2)) \to ((eq T (TSort (next g
-n)) t4) \to (ty3 g c0 (THead (Flat Cast) t3 t2) t4)))) (\lambda (H8: (eq T
-(TSort n) (THead (Flat Cast) t3 t2))).(let H9 \def (eq_ind T (TSort n)
-(\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort _)
-\Rightarrow True | (TLRef _) \Rightarrow False | (THead _ _ _) \Rightarrow
-False])) I (THead (Flat Cast) t3 t2) H8) in (False_ind ((eq T (TSort (next g
-n)) t4) \to (ty3 g c0 (THead (Flat Cast) t3 t2) t4)) H9))) c1 (sym_eq C c1 c0
-H5) H6 H7)))) | (tau0_abbr c1 d v i H5 w H6) \Rightarrow (\lambda (H7: (eq C
-c1 c0)).(\lambda (H8: (eq T (TLRef i) (THead (Flat Cast) t3 t2))).(\lambda
-(H9: (eq T (lift (S i) O w) t4)).(eq_ind C c0 (\lambda (c2: C).((eq T (TLRef
-i) (THead (Flat Cast) t3 t2)) \to ((eq T (lift (S i) O w) t4) \to ((getl i c2
-(CHead d (Bind Abbr) v)) \to ((tau0 g d v w) \to (ty3 g c0 (THead (Flat Cast)
-t3 t2) t4)))))) (\lambda (H10: (eq T (TLRef i) (THead (Flat Cast) t3
-t2))).(let H11 \def (eq_ind T (TLRef i) (\lambda (e: T).(match e in T return
-(\lambda (_: T).Prop) with [(TSort _) \Rightarrow False | (TLRef _)
-\Rightarrow True | (THead _ _ _) \Rightarrow False])) I (THead (Flat Cast) t3
-t2) H10) in (False_ind ((eq T (lift (S i) O w) t4) \to ((getl i c0 (CHead d
-(Bind Abbr) v)) \to ((tau0 g d v w) \to (ty3 g c0 (THead (Flat Cast) t3 t2)
-t4)))) H11))) c1 (sym_eq C c1 c0 H7) H8 H9 H5 H6)))) | (tau0_abst c1 d v i H5
-w H6) \Rightarrow (\lambda (H7: (eq C c1 c0)).(\lambda (H8: (eq T (TLRef i)
-(THead (Flat Cast) t3 t2))).(\lambda (H9: (eq T (lift (S i) O v) t4)).(eq_ind
-C c0 (\lambda (c2: C).((eq T (TLRef i) (THead (Flat Cast) t3 t2)) \to ((eq T
-(lift (S i) O v) t4) \to ((getl i c2 (CHead d (Bind Abst) v)) \to ((tau0 g d
-v w) \to (ty3 g c0 (THead (Flat Cast) t3 t2) t4)))))) (\lambda (H10: (eq T
-(TLRef i) (THead (Flat Cast) t3 t2))).(let H11 \def (eq_ind T (TLRef i)
-(\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort _)
-\Rightarrow False | (TLRef _) \Rightarrow True | (THead _ _ _) \Rightarrow
-False])) I (THead (Flat Cast) t3 t2) H10) in (False_ind ((eq T (lift (S i) O
-v) t4) \to ((getl i c0 (CHead d (Bind Abst) v)) \to ((tau0 g d v w) \to (ty3
-g c0 (THead (Flat Cast) t3 t2) t4)))) H11))) c1 (sym_eq C c1 c0 H7) H8 H9 H5
-H6)))) | (tau0_bind b c1 v t5 t6 H5) \Rightarrow (\lambda (H6: (eq C c1
-c0)).(\lambda (H7: (eq T (THead (Bind b) v t5) (THead (Flat Cast) t3
-t2))).(\lambda (H8: (eq T (THead (Bind b) v t6) t4)).(eq_ind C c0 (\lambda
-(c2: C).((eq T (THead (Bind b) v t5) (THead (Flat Cast) t3 t2)) \to ((eq T
-(THead (Bind b) v t6) t4) \to ((tau0 g (CHead c2 (Bind b) v) t5 t6) \to (ty3
-g c0 (THead (Flat Cast) t3 t2) t4))))) (\lambda (H9: (eq T (THead (Bind b) v
-t5) (THead (Flat Cast) t3 t2))).(let H10 \def (eq_ind T (THead (Bind b) v t5)
-(\lambda (e: T).(match e in T return (\lambda (_: T).Prop) with [(TSort _)
-\Rightarrow False | (TLRef _) \Rightarrow False | (THead k _ _) \Rightarrow
-(match k in K return (\lambda (_: K).Prop) with [(Bind _) \Rightarrow True |
-(Flat _) \Rightarrow False])])) I (THead (Flat Cast) t3 t2) H9) in (False_ind
-((eq T (THead (Bind b) v t6) t4) \to ((tau0 g (CHead c0 (Bind b) v) t5 t6)
-\to (ty3 g c0 (THead (Flat Cast) t3 t2) t4))) H10))) c1 (sym_eq C c1 c0 H6)
-H7 H8 H5)))) | (tau0_appl c1 v t5 t6 H5) \Rightarrow (\lambda (H6: (eq C c1
+(TLRef _) \Rightarrow True | (THead _ _ _) \Rightarrow False])) I (THead
+(Flat Cast) t3 t2) H10) in (False_ind ((eq T (lift (S i) O v) t4) \to ((getl
+i c0 (CHead d (Bind Abst) v)) \to ((tau0 g d v w) \to (ty3 g c0 (THead (Flat
+Cast) t3 t2) t4)))) H11))) c1 (sym_eq C c1 c0 H7) H8 H9 H5 H6)))) |
+(tau0_bind b c1 v t5 t6 H5) \Rightarrow (\lambda (H6: (eq C c1 c0)).(\lambda
+(H7: (eq T (THead (Bind b) v t5) (THead (Flat Cast) t3 t2))).(\lambda (H8:
+(eq T (THead (Bind b) v t6) t4)).(eq_ind C c0 (\lambda (c2: C).((eq T (THead
+(Bind b) v t5) (THead (Flat Cast) t3 t2)) \to ((eq T (THead (Bind b) v t6)
+t4) \to ((tau0 g (CHead c2 (Bind b) v) t5 t6) \to (ty3 g c0 (THead (Flat
+Cast) t3 t2) t4))))) (\lambda (H9: (eq T (THead (Bind b) v t5) (THead (Flat
+Cast) t3 t2))).(let H10 \def (eq_ind T (THead (Bind b) v t5) (\lambda (e:
+T).(match e in T return (\lambda (_: T).Prop) with [(TSort _) \Rightarrow
+False | (TLRef _) \Rightarrow False | (THead k _ _) \Rightarrow (match k in K
+return (\lambda (_: K).Prop) with [(Bind _) \Rightarrow True | (Flat _)
+\Rightarrow False])])) I (THead (Flat Cast) t3 t2) H9) in (False_ind ((eq T
+(THead (Bind b) v t6) t4) \to ((tau0 g (CHead c0 (Bind b) v) t5 t6) \to (ty3
+g c0 (THead (Flat Cast) t3 t2) t4))) H10))) c1 (sym_eq C c1 c0 H6) H7 H8
+H5)))) | (tau0_appl c1 v t5 t6 H5) \Rightarrow (\lambda (H6: (eq C c1
c0)).(\lambda (H7: (eq T (THead (Flat Appl) v t5) (THead (Flat Cast) t3
t2))).(\lambda (H8: (eq T (THead (Flat Appl) v t6) t4)).(eq_ind C c0 (\lambda
(c2: C).((eq T (THead (Flat Appl) v t5) (THead (Flat Cast) t3 t2)) \to ((eq T
t6 x0)).(ty3_conv g c0 (THead (Flat Cast) v2 t6) (THead (Flat Cast) x v2)
(ty3_cast g c0 t6 v2 (ty3_sconv g c0 t6 x0 H19 t3 v2 H_y0 H17) x H18) (THead
(Flat Cast) t3 t2) (THead (Flat Cast) v2 t3) (ty3_cast g c0 t2 t3 H0 v2 H_y0)
-(pc3_s c0 (THead (Flat Cast) v2 t3) (THead (Flat Cast) v2 t6) (pc3_thin_dx c0
-t6 t3 H17 v2 Cast))))) (ty3_correct g c0 t2 t6 H_y)))) (ty3_correct g c0 t3
-v2 H_y0))))))) t4 H14)) t5 (sym_eq T t5 t2 H13))) v1 (sym_eq T v1 t3 H12)))
-H11))) c1 (sym_eq C c1 c0 H7) H8 H9 H5 H6))))]) in (H5 (refl_equal C c0)
-(refl_equal T (THead (Flat Cast) t3 t2)) (refl_equal T t4))))))))))))) c u t1
-H))))).
+(pc3_thin_dx c0 t3 t6 (ty3_unique g c0 t2 t3 H0 t6 H_y) v2 Cast))))
+(ty3_correct g c0 t2 t6 H_y)))) (ty3_correct g c0 t3 v2 H_y0))))))) t4 H14))
+t5 (sym_eq T t5 t2 H13))) v1 (sym_eq T v1 t3 H12))) H11))) c1 (sym_eq C c1 c0
+H7) H8 H9 H5 H6))))]) in (H5 (refl_equal C c0) (refl_equal T (THead (Flat
+Cast) t3 t2)) (refl_equal T t4))))))))))))) c u t1 H))))).