]> matita.cs.unibo.it Git - helm.git/blob - matita/matita/contribs/lambdadelta/basic_2/rt_computation/cpms_aaa.ma
update in ground
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / rt_computation / cpms_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_2/rt_transition/cpm_aaa.ma".
16 include "basic_2/rt_computation/cpxs_aaa.ma".
17 include "basic_2/rt_computation/cpms_cpxs.ma".
18 include "basic_2/rt_computation/lprs_cpms.ma".
19
20 (* T-BOUND CONTEXT-SENSITIVE PARALLEL RT-COMPUTATION FOR TERMS **************)
21
22 (* Properties with atomic arity assignment on terms *************************)
23
24 (* Basic_2A1: uses: scpds_aaa_conf *)
25 (* Basic_2A1: includes: cprs_aaa_conf *)
26 lemma cpms_aaa_conf (h) (G) (L) (n): Conf3 … (aaa G L) (cpms h G L n).
27 /3 width=5 by cpms_fwd_cpxs, cpxs_aaa_conf/ qed-.
28
29 lemma cpms_total_aaa (h) (G) (L) (n) (A):
30       ∀T. ❪G,L❫ ⊢ T ⁝ A → ∃U. ❪G,L❫ ⊢ T ➡*[h,n] U.
31 #h #G #L #n elim n -n
32 [ /2 width=3 by ex_intro/
33 | #n #IH #A #T1 #HT1 <plus_SO_dx
34   elim (IH … HT1) -IH #T0 #HT10
35   lapply (cpms_aaa_conf … HT1 … HT10) -HT1 #HT0
36   elim (aaa_cpm_SO h … HT0) -HT0 #T2 #HT02
37   /3 width=4 by cpms_step_dx, ex_intro/
38 ]
39 qed-.
40
41 lemma cpms_abst_dx_le_aaa (h) (G) (L) (T) (W) (p):
42       ∀A. ❪G,L❫ ⊢ T ⁝ A →
43       ∀n1,U1. ❪G,L❫ ⊢ T ➡*[h,n1] ⓛ[p]W.U1 → ∀n2. n1 ≤ n2 →
44       ∃∃U2. ❪G,L❫ ⊢ T ➡*[h,n2] ⓛ[p]W.U2 & ❪G,L.ⓛW❫ ⊢ U1 ➡*[h,n2-n1] U2.
45 #h #G #L #T #W #p #A #HA #n1 #U1 #HTU1 #n2 #Hn12
46 lapply (cpms_aaa_conf … HA … HTU1) -HA #HA
47 elim (cpms_total_aaa h … (n2-n1) … HA) -HA #X #H
48 elim (cpms_inv_abst_sn … H) -H #W0 #U2 #_ #HU12 #H destruct -W0
49 >(plus_minus_m_m_commutative … Hn12) in ⊢ (??%?); -Hn12
50 /4 width=5 by cpms_trans, cpms_bind_dx, ex2_intro/
51 qed-.