]> matita.cs.unibo.it Git - helm.git/blobdiff - matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_max.ma
propagating the arithmetics library, partial commit
[helm.git] / matita / matita / contribs / lambdadelta / ground / counters / rtc_ist_max.ma
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_max.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_max.ma
new file mode 100644 (file)
index 0000000..3ad4326
--- /dev/null
@@ -0,0 +1,59 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||         The HELM team.                                      *)
+(*      ||A||         http://helm.cs.unibo.it                             *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU General Public License Version 2                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+include "ground/xoa/ex_3_2.ma".
+include "ground/counters/rtc_max.ma".
+include "ground/counters/rtc_ist.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_max ***********************************************)
+
+lemma rtc_ist_max (n1) (n2) (c1) (c2): ๐“โชn1,c1โซ โ†’ ๐“โชn2,c2โซ โ†’ ๐“โชn1โˆจn2,c1โˆจc2โซ.
+#n1 #n2 #c1 #c2 #H1 #H2 destruct //
+qed.
+
+lemma rtc_ist_max_zero_sn (n) (c1) (c2): ๐“โช๐ŸŽ,c1โซ โ†’ ๐“โชn,c2โซ โ†’ ๐“โชn,c1โˆจc2โซ.
+/2 width=1 by rtc_ist_max/ qed.
+
+lemma rtc_ist_max_zero_dx (n) (c1) (c2): ๐“โชn,c1โซ โ†’ ๐“โช๐ŸŽ,c2โซ โ†’ ๐“โชn,c1โˆจc2โซ.
+// qed.
+
+lemma rtc_ist_max_idem_sn (n) (c1) (c2): ๐“โชn,c1โซ โ†’ ๐“โชn,c2โซ โ†’ ๐“โชn,c1โˆจc2โซ.
+#n #c1 #c2 #H1 #H2 >(nmax_idem n) /2 width=1 by rtc_ist_max/
+qed.
+
+(* Inversions with rtc_max **************************************************)
+
+lemma rtc_ist_inv_max (n) (c1) (c2): ๐“โชn,c1 โˆจ c2โซ โ†’
+      โˆƒโˆƒn1,n2. ๐“โชn1,c1โซ & ๐“โชn2,c2โซ & (n1 โˆจ n2) = n.
+#n #c1 #c2 #H
+elim (rtc_max_inv_dx โ€ฆ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #H1 #H2 #H3 #H4 #H5 #H6 destruct
+elim (eq_inv_nmax_zero โ€ฆ H1) -H1 #H11 #H12 destruct
+elim (eq_inv_nmax_zero โ€ฆ H2) -H2 #H21 #H22 destruct
+elim (eq_inv_nmax_zero โ€ฆ H3) -H3 #H31 #H32 destruct
+/2 width=5 by ex3_2_intro/
+qed-.
+
+lemma rtc_ist_inv_zero_max (c1) (c2): ๐“โช๐ŸŽ,c1 โˆจ c2โซ โ†’ โˆงโˆง ๐“โช๐ŸŽ,c1โซ & ๐“โช๐ŸŽ,c2โซ.
+#c1 #c2 #H
+elim (rtc_ist_inv_max โ€ฆ H) -H #n1 #n2 #Hn1 #Hn2 #H
+elim (eq_inv_nmax_zero โ€ฆ H) -H #H1 #H2 destruct
+/2 width=1 by conj/
+qed-.
+
+lemma rtc_ist_inv_max_zero_dx (n) (c1) (c2): ๐“โชn,c1 โˆจ c2โซ โ†’ ๐“โช๐ŸŽ,c2โซ โ†’ ๐“โชn,c1โซ.
+#n #c1 #c2 #H #H2
+elim (rtc_ist_inv_max โ€ฆ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct //
+qed-.