]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/reduction/cnf_lift.ma
acbb020ce1b6d19a69b8917852a265441f0156a5
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / reduction / cnf_lift.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/reduction/cpr_lift.ma".
16 include "basic_2/reduction/cnf.ma".
17
18 (* CONTEXT-SENSITIVE NORMAL TERMS *******************************************)
19
20 (* Advanced properties ******************************************************)
21
22 (* Basic_1: was only: nf2_csort_lref *)
23 lemma cnf_lref_atom: ∀L,i. ⇩[0, i] L ≡ ⋆ → L  ⊢ 𝐍⦃#i⦄.
24 #L #i #HL #X #H
25 elim (cpr_inv_lref1 … H) -H // *
26 #K #V1 #V2 #HLK #_ #_
27 lapply (ldrop_mono … HL … HLK) -L #H destruct
28 qed.
29
30 (* Basic_1: was: nf2_lref_abst *)
31 lemma cnf_lref_abst: ∀L,K,V,i. ⇩[0, i] L ≡ K. ⓛV → L ⊢ 𝐍⦃#i⦄.
32 #L #K #V #i #HLK #X #H
33 elim (cpr_inv_lref1 … H) -H // *
34 #K0 #V1 #V2 #HLK0 #_ #_
35 lapply (ldrop_mono … HLK … HLK0) -L #H destruct
36 qed.
37
38 (* Relocation properties ****************************************************)
39
40 (* Basic_1: was: nf2_lift *)
41 lemma cnf_lift: ∀L0,L,T,T0,d,e.
42                 L ⊢ 𝐍⦃T⦄ → ⇩[d, e] L0 ≡ L → ⇧[d, e] T ≡ T0 → L0 ⊢ 𝐍⦃T0⦄.
43 #L0 #L #T #T0 #d #e #HLT #HL0 #HT0 #X #H
44 elim (cpr_inv_lift1 … H … HL0 … HT0) -L0 #T1 #HT10 #HT1
45 <(HLT … HT1) in HT0; -L #HT0
46 >(lift_mono … HT10 … HT0) -T1 -X //
47 qed.