]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/apps_2/examples/ex_cpr_omega.ma
7ebb0a3455b51a3ca5042c8a035c379df1638f34
[helm.git] / matita / matita / contribs / lambdadelta / apps_2 / examples / ex_cpr_omega.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_transition/cpr.ma".
16
17 (* EXAMPLES *****************************************************************)
18
19 (* A reduction cycle in two steps: the term Omega ***************************)
20
21 definition Delta: term → term ≝ λW. +ⓛW.ⓐ#0.#0.
22
23 definition Omega1: term → term ≝ λW. ⓐ(Delta W).(Delta W).
24
25 definition Omega2: term → term ≝ λW. +ⓓⓝW.(Delta W).ⓐ#0.#0.
26
27 (* Basic properties *********************************************************)
28
29 lemma Delta_lifts: ∀W1,W2,f. ⬆*[f] W1 ≘ W2 →
30                    ⬆*[f] (Delta W1) ≘ (Delta W2).
31 /4 width=1 by lifts_lref, lifts_bind, lifts_flat/ qed.
32
33 (* Main properties **********************************************************)
34
35 theorem cpr_Omega_12: ∀h,G,L,W. ⦃G, L⦄ ⊢ Omega1 W ➡[h] Omega2 W.
36 /2 width=1 by cpm_beta/ qed.
37
38 theorem cpr_Omega_21: ∀h,G,L,W. ⦃G, L⦄ ⊢ Omega2 W ➡[h] Omega1 W.
39 #h #G #L #W1 elim (lifts_total W1 (𝐔❴1❵))
40 /5 width=5 by lifts_flat, cpm_zeta, cpm_eps, cpm_appl, cpm_delta, Delta_lifts/
41 qed.