]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/dynamic/cnv_cpue.ma
milestone in basic_2 with additions in static_2
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / dynamic / cnv_cpue.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_cnu.ma".
16 include "basic_2/rt_computation/cpue.ma".
17 include "basic_2/dynamic/cnv_preserve.ma".
18
19 (* CONTEXT-SENSITIVE NATIVE VALIDITY FOR TERMS ******************************)
20
21 (* Properties with evaluation for t-unbound rt-transition on terms **********)
22
23 lemma cnv_cpue_trans (a) (h) (G) (L):
24       ∀T1. ⦃G,L⦄ ⊢ T1 ![a,h] →
25       ∀T2. ⦃G,L⦄ ⊢ T1 ⥲*[h] 𝐍⦃T2⦄ → ⦃G,L⦄ ⊢ T2 ![a,h].
26 #a #h #G #L #T1 #HT1 #T2 * #n #HT12 #_
27 /2 width=4 by cnv_cpms_trans/
28 qed-.
29
30 lemma cnv_cpue_cpms_conf (a) (h) (n) (G) (L):
31       ∀T0. ⦃G,L⦄ ⊢ T0 ![a,h] → ∀T1. ⦃G,L⦄ ⊢ T0 ➡*[n,h] T1 →
32       ∀T2. ⦃G,L⦄ ⊢ T0 ⥲*[h] 𝐍⦃T2⦄ →
33       ∃∃T. ⦃G,L⦄ ⊢ T1 ⥲*[h] 𝐍⦃T⦄ & T2 ≅ T.
34 #a #h #n1 #G #L #T0 #HT0 #T1 #HT01 #T2 * #n2 #HT02 #HT2
35 elim (cnv_cpms_conf … HT0 … HT01 … HT02) -T0 #T0 #HT10 #HT20
36 lapply (cpms_inv_cnu_sn … HT20 HT2) -HT20 #HT20
37 /4 width=8 by cnu_tueq_trans, ex2_intro/
38 qed-.
39
40 (* Main properties with evaluation for t-unbound rt-transition on terms *****)
41
42 theorem cnv_cpue_mono (a) (h) (G) (L):
43         ∀T0. ⦃G,L⦄ ⊢ T0 ![a,h] → ∀T1. ⦃G,L⦄ ⊢ T0 ⥲*[h] 𝐍⦃T1⦄ →
44         ∀T2. ⦃G,L⦄ ⊢ T0 ⥲*[h] 𝐍⦃T2⦄ → T1 ≅ T2.
45 #a #h #G #L #T0 #HT0 #T1 * #n1 #HT01 #HT1 #T2 * #n2 #HT02 #HT2
46 elim (cnv_cpms_conf … HT0 … HT01 … HT02) -T0 #T0 #HT10 #HT20
47 /3 width=8 by cpms_inv_cnu_sn, tueq_canc_dx/
48 qed-.