]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/apps_2/examples/ex_fpbg_refl.ma
f15bbd19c1bde336d8f8b33c8a60e2d1352ba4ed
[helm.git] / matita / matita / contribs / lambdadelta / apps_2 / examples / ex_fpbg_refl.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/fpbs_cpxs.ma".
16 include "basic_2/rt_computation/fpbg_fqup.ma".
17 include "basic_2/rt_computation/fpbg_fpbs.ma".
18
19 (* EXAMPLES *****************************************************************)
20
21 (* Reflexivity of proper rst-computation: the term ApplOmega ****************)
22
23 definition ApplDelta: term → nat → term ≝ λW,s. +ⓛW.ⓐ⋆s.ⓐ#0.#0.
24
25 definition ApplOmega1: term → nat → term ≝ λW,s. ⓐ(ApplDelta W s).(ApplDelta W s).
26
27 definition ApplOmega2: term → nat → term ≝ λW,s. +ⓓⓝW.(ApplDelta W s).ⓐ⋆s.ⓐ#0.#0.
28
29 definition ApplOmega3: term → nat → term ≝ λW,s. ⓐ⋆s.(ApplOmega1 W s).
30
31 (* Basic properties *********************************************************)
32
33 lemma ApplDelta_lifts (f:rtmap):
34                       ∀W1,W2,s. ⬆*[f] W1 ≘ W2 →
35                       ⬆*[f] (ApplDelta W1 s) ≘ (ApplDelta W2 s).
36 /5 width=1 by lifts_sort, lifts_lref, lifts_bind, lifts_flat/ qed.
37
38 lemma cpr_ApplOmega_12 (h): ∀G,L,W,s. ⦃G, L⦄ ⊢ ApplOmega1 W s ➡[h] ApplOmega2 W s.
39 /2 width=1 by cpm_beta/ qed.
40
41 lemma cpr_ApplOmega_23 (h): ∀G,L,W,s. ⦃G, L⦄ ⊢ ApplOmega2 W s ➡[h] ApplOmega3 W s.
42 #h #G #L #W1 #s elim (lifts_total W1 (𝐔❴1❵)) #W2 #HW12
43 @(cpm_zeta … (ApplOmega3 W2 s)) /4 width=1 by ApplDelta_lifts, lifts_flat/
44 @cpm_appl // @cpm_appl @(cpm_delta … (ApplDelta W1 s))
45 /2 width=1 by ApplDelta_lifts, cpm_eps/
46 qed.
47
48 lemma cpxs_ApplOmega_13 (h): ∀G,L,W,s. ⦃G, L⦄ ⊢ ApplOmega1 W s ⬈*[h] ApplOmega3 W s.
49 /4 width=4 by cpxs_strap1, cpm_fwd_cpx/ qed.
50
51 lemma fqup_ApplOmega_13: ∀G,L,W,s. ⦃G, L, ApplOmega3 W s⦄ ⊐+ ⦃G, L, ApplOmega1 W s⦄.
52 /2 width=1 by/ qed.
53
54 (* Main properties **********************************************************)
55
56 theorem fpbg_refl (h) (o): ∀G,L,W,s. ⦃G, L, ApplOmega1 W s⦄ >[h,o] ⦃G, L, ApplOmega1 W s⦄.
57 /3 width=5 by fpbs_fpbg_trans, fqup_fpbg, cpxs_fpbs/ qed.