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 "ground/xoa/ex_3_2.ma".
16 include "ground/counters/rtc_max.ma".
17 include "ground/counters/rtc_ism.ma".
19 (* T-BOUND RT-TRANSITION COUNTERS *******************************************)
21 (* Constructions with rtc_max ***********************************************)
23 lemma rtc_ism_max (n1) (n2) (c1) (c2): ๐โจn1,c1โฉ โ ๐โจn2,c2โฉ โ ๐โจn1โจn2,c1โจc2โฉ.
24 #n1 #n2 #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct
25 /2 width=3 by ex1_2_intro/
28 lemma rtc_ism_max_zero_sn (n) (c1) (c2): ๐โจ๐,c1โฉ โ ๐โจn,c2โฉ โ ๐โจn,c1โจc2โฉ.
29 /2 width=1 by rtc_ism_max/ qed.
31 lemma rtc_ism_max_zero_dx (n) (c1) (c2): ๐โจn,c1โฉ โ ๐โจ๐,c2โฉ โ ๐โจn,c1โจc2โฉ.
32 #n #c1 #c2 #H1 #H2 >(nmax_zero_dx n) /2 width=1 by rtc_ism_max/
35 lemma rtc_ism_max_idem_sn (n) (c1) (c2): ๐โจn,c1โฉ โ ๐โจn,c2โฉ โ ๐โจn,c1โจc2โฉ.
36 #n #c1 #c2 #H1 #H2 >(nmax_idem n) /2 width=1 by rtc_ism_max/
39 (* Inversions with rtc_max **************************************************)
41 lemma rtc_ism_inv_max (n) (c1) (c2): ๐โจn,c1 โจ c2โฉ โ
42 โโn1,n2. ๐โจn1,c1โฉ & ๐โจn2,c2โฉ & (n1 โจ n2) = n.
43 #n #c1 #c2 * #ri #rs #H
44 elim (rtc_max_inv_dx โฆ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #_ #_ #H1 #H2 #H3 #H4
45 elim (eq_inv_nmax_zero โฆ H1) -H1 /3 width=5 by ex3_2_intro, ex1_2_intro/
48 lemma rtc_isr_inv_max (c1) (c2): ๐โจ๐,c1 โจ c2โฉ โ โงโง ๐โจ๐,c1โฉ & ๐โจ๐,c2โฉ.
50 elim (rtc_ism_inv_max โฆ H) -H #n1 #n2 #Hn1 #Hn2 #H
51 elim (eq_inv_nmax_zero โฆ H) -H #H1 #H2 destruct
55 lemma rtc_ism_inv_max_zero_dx (n) (c1) (c2): ๐โจn,c1 โจ c2โฉ โ ๐โจ๐,c2โฉ โ ๐โจn,c1โฉ.
57 elim (rtc_ism_inv_max โฆ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
58 lapply (rtc_ism_inj โฆ Hn2 H2) -c2 #H destruct //
61 lemma rtc_ism_inv_max_eq_t (n) (c1) (c2): ๐โจn,c1 โจ c2โฉ โ rtc_eq_t c1 c2 โ
62 โงโง ๐โจn,c1โฉ & ๐โจn,c2โฉ.
64 elim (rtc_ism_inv_max โฆ H) -H #n1 #n2 #Hc1 #Hc2 #H destruct
65 lapply (rtc_ism_eq_t_trans โฆ Hc1 โฆ Hc12) -Hc12 #H
66 <(rtc_ism_inj โฆ H โฆ Hc2) -Hc2
67 <nmax_idem /2 width=1 by conj/