1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "basic_2/computation/fpbs_aaa.ma".
16 include "basic_2/computation/csx_aaa.ma".
17 include "basic_2/computation/fsb_csx.ma".
19 (* "BIG TREE" STRONGLY NORMALIZING TERMS ************************************)
21 (* Main properties **********************************************************)
23 (* Note: this is the "big tree" theorem ("small step" version) *)
24 theorem aaa_fsb: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦃G, L⦄ ⊢ ⦥[h, g] T.
25 /3 width=2 by aaa_csx, csx_fsb/ qed.
27 (* Note: this is the "big tree" theorem ("big step" version) *)
28 theorem aaa_fsba: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ⦃G, L⦄ ⊢ ⦥⦥[h, g] T.
29 /3 width=2 by fsb_fsba, aaa_fsb/ qed.
31 (* Advanced eliminators on atomica arity assignment for terms ***************)
33 fact aaa_ind_fpbu_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) →
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_fpbu … 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 fpbu_fwd_fpbs/
45 lemma aaa_ind_fpbu: ∀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) →
50 ∀G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → R G L T.
51 /4 width=4 by aaa_ind_fpbu_aux, aaa_csx/ qed-.
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) →
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/
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) →
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-.