]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/dynamic/cnv_cpmhe.ma
update in ground_2 static_2 basic_2
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / dynamic / cnv_cpmhe.ma
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 include "basic_2/rt_computation/cpms_cnh.ma".
16 include "basic_2/rt_computation/cpmhe_csx.ma".
17 include "basic_2/rt_equivalence/cpes.ma".
18 include "basic_2/dynamic/cnv_preserve.ma".
19
20 (* CONTEXT-SENSITIVE NATIVE VALIDITY FOR TERMS ******************************)
21
22 (* Properties with head evaluation for t-bound rt-transition on terms *******)
23
24 lemma cnv_cpmhe_trans (a) (h) (G) (L):
25       ∀T1. ⦃G,L⦄ ⊢ T1 ![a,h] →
26       ∀T2,n. ⦃G,L⦄ ⊢ T1 ➡*[h,n] 𝐍*⦃T2⦄ → ⦃G,L⦄ ⊢ T2 ![a,h].
27 /3 width=4 by cpmhe_fwd_cpms, cnv_cpms_trans/ qed-.
28
29 lemma cnv_R_cpmhe_total (a) (h) (G) (L):
30       ∀T1. ⦃G,L⦄ ⊢ T1 ![a,h] → ∃n. R_cpmhe h G L T1 n.
31 /4 width=2 by cnv_fwd_fsb, fsb_inv_csx, R_cpmhe_total_csx/ qed-.
32
33 axiom cnv_R_cpmhe_dec (a) (h) (G) (L):
34       ∀T. ⦃G,L⦄ ⊢ T ![a,h] → ∀n. Decidable (R_cpmhe h G L T n).
35
36 (* Main inversions with head evaluation for t-bound rt-transition on terms **)
37
38 theorem cnv_cpmhe_mono (a) (h) (G) (L):
39         ∀T0. ⦃G,L⦄ ⊢ T0 ![a,h] → ∀T1,n1. ⦃G,L⦄ ⊢ T0 ➡*[h,n1] 𝐍*⦃T1⦄ →
40         ∀T2,n2. ⦃G,L⦄ ⊢ T0 ➡*[h,n2] 𝐍*⦃T2⦄ →
41         ∧∧ ⦃G,L⦄ ⊢ T1 ⬌*[h,n2-n1,n1-n2] T2 & T1 ⩳ T2.
42 #a #h #G #L #T0 #HT0 #T1 #n1 * #HT01 #HT1 #T2 #n2 * #HT02 #HT2
43 elim (cnv_cpms_conf … HT0 … HT01 … HT02) -T0 #T0 #HT10 #HT20
44 /4 width=8 by cpms_div, cpms_inv_cnh_sn, theq_canc_dx, conj/
45 qed-.