]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2A/computation/fsb_aaa.ma
update in lambdadelta
[helm.git] / matita / matita / contribs / lambdadelta / basic_2A / computation / fsb_aaa.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_2A/computation/fpbs_aaa.ma".
16 include "basic_2A/computation/csx_aaa.ma".
17 include "basic_2A/computation/fsb_csx.ma".
18
19 (* "QRST" STRONGLY NORMALIZING CLOSURES *************************************)
20
21 (* Main properties **********************************************************)
22
23 (* Note: this is the "big tree" theorem ("RST" version) *)
24 theorem aaa_fsb: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦥[h, g] ⦃G, L, T⦄.
25 /3 width=2 by aaa_csx, csx_fsb/ qed.
26
27 (* Note: this is the "big tree" theorem ("QRST" version) *)
28 theorem aaa_fsba: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦥⦥[h, g] ⦃G, L, T⦄.
29 /3 width=2 by fsb_fsba, aaa_fsb/ qed.
30
31 (* Advanced eliminators on atomica arity assignment for terms ***************)
32
33 fact aaa_ind_fpb_aux: ∀h,g. ∀R:relation3 genv lenv term.
34                       (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
35                                     (∀G2,L2,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
36                                     R G1 L1 T1
37                       ) →
38                       ∀G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ∀A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
39 #h #g #R #IH #G #L #T #H @(csx_ind_fpb … H) -G -L -T
40 #G1 #L1 #T1 #H1 #IH1 #A1 #HTA1 @IH -IH //
41 #G2 #L2 #T2 #H12 elim (fpbs_aaa_conf h g … G2 … L2 … T2 … HTA1) -A1
42 /2 width=2 by fpb_fpbs/
43 qed-.
44
45 lemma aaa_ind_fpb: ∀h,g. ∀R:relation3 genv lenv term.
46                    (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
47                                  (∀G2,L2,T2. ⦃G1, L1, T1⦄ ≻[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
48                                  R G1 L1 T1
49                    ) →
50                    ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
51 /4 width=4 by aaa_ind_fpb_aux, aaa_csx/ qed-.
52
53 fact aaa_ind_fpbg_aux: ∀h,g. ∀R:relation3 genv lenv term.
54                        (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
55                                      (∀G2,L2,T2. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
56                                      R G1 L1 T1
57                        ) →
58                        ∀G,L,T. ⦃G, L⦄ ⊢ ⬊*[h, g] T → ∀A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
59 #h #g #R #IH #G #L #T #H @(csx_ind_fpbg … H) -G -L -T
60 #G1 #L1 #T1 #H1 #IH1 #A1 #HTA1 @IH -IH //
61 #G2 #L2 #T2 #H12 elim (fpbs_aaa_conf h g … G2 … L2 … T2 … HTA1) -A1
62 /2 width=2 by fpbg_fwd_fpbs/
63 qed-.
64
65 lemma aaa_ind_fpbg: ∀h,g. ∀R:relation3 genv lenv term.
66                     (∀G1,L1,T1,A. ⦃G1, L1⦄ ⊢ T1 ⁝ A →
67                                   (∀G2,L2,T2. ⦃G1, L1, T1⦄ >≡[h, g] ⦃G2, L2, T2⦄ → R G2 L2 T2) →
68                                   R G1 L1 T1
69                     ) →
70                     ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
71 /4 width=4 by aaa_ind_fpbg_aux, aaa_csx/ qed-.