]> matita.cs.unibo.it Git - helm.git/commitdiff
propagating the arithmetics library, partial commit
authorFerruccio Guidi <ferruccio.guidi@unibo.it>
Fri, 26 Feb 2021 13:21:42 +0000 (14:21 +0100)
committerFerruccio Guidi <ferruccio.guidi@unibo.it>
Fri, 26 Feb 2021 13:21:42 +0000 (14:21 +0100)
+ counters (was: steps) ported and restyled
+ core notation: "pair" decentralized
+ some corrections and renaming

60 files changed:
.gitignore
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpg.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpm.ma
matita/matita/contribs/lambdadelta/basic_2/rt_transition/cpt.ma
matita/matita/contribs/lambdadelta/bin/recomm/Makefile
matita/matita/contribs/lambdadelta/bin/recomm/bGroundCounters.mrc
matita/matita/contribs/lambdadelta/bin/recomm/dGroundCounters.mrc
matita/matita/contribs/lambdadelta/bin/recomm/rGroundCounters.mrc [new file with mode: 0644]
matita/matita/contribs/lambdadelta/bin/recomm/recomm.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommCheck.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommGc.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommGcbGroundCounters.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommGcdGroundCounters.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.ml [new file with mode: 0644]
matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.mli [new file with mode: 0644]
matita/matita/contribs/lambdadelta/bin/recomm/recommLexer.mll
matita/matita/contribs/lambdadelta/bin/recomm/recommOutput.ml
matita/matita/contribs/lambdadelta/bin/recomm/recommOutput.mli
matita/matita/contribs/lambdadelta/bin/recomm/recommPccFor.ml
matita/matita/contribs/lambdadelta/ground/arith/nat_max.ma
matita/matita/contribs/lambdadelta/ground/arith/nat_plus.ma
matita/matita/contribs/lambdadelta/ground/counters/rtc.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ism.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max_shift.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_plus.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_shift.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ist.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_max.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_plus.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_shift.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_max.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_max_shift.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_plus.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/counters/rtc_shift.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/notation/relations/ism_2.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/notation/relations/isredtype_2.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/notation/relations/ist_1.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/notation/relations/ist_2.ma [new file with mode: 0644]
matita/matita/contribs/lambdadelta/ground/notation/relations/istotal_1.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/notation/relations/istype_2.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max_shift.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_plus.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_shift.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_ist.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_max.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_plus.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_shift.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_max.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_max_shift.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_plus.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/steps/rtc_shift.ma [deleted file]
matita/matita/contribs/lambdadelta/ground/web/ground_src.tbl
matita/matita/lib/basics/core_notation.ma
matita/matita/lib/basics/core_notation/pair_2.ma [new file with mode: 0644]
matita/matita/lib/basics/types.ma
matita/matita/lib/hott/notations.ma

index 9f322dc4ce125c7e6e9d15fe8bcc77560ba5ff44..69568a56b5df2aeffe37e685f964f3252ca6aba3 100644 (file)
@@ -80,6 +80,8 @@ helm/www/lambdadelta/xslt/xhtbl.xsl
 matita/matita/lib/lambda/.depend
 
 matita/matita/contribs/lambdadelta/.depend
+matita/matita/contribs/lambdadelta/bin/recomm/srcs
+matita/matita/contribs/lambdadelta/bin/recomm/log.txt
 matita/matita/contribs/lambdadelta/bin/nodes
 matita/matita/contribs/lambdadelta/bin/token
 matita/matita/contribs/lambdadelta/*/probe.txt
index ad020929be506ce06bda80d136da981a207a2294..3bdc93e975173a1cace87a5f801e8efa425b7c60 100644 (file)
@@ -19,9 +19,9 @@ include "ground/xoa/ex_5_2.ma".
 include "ground/xoa/ex_6_9.ma".
 include "ground/xoa/ex_7_10.ma".
 include "ground/xoa/or_5.ma".
-include "ground/steps/rtc_shift.ma".
-include "ground/steps/rtc_plus.ma".
-include "ground/steps/rtc_max.ma".
+include "ground/counters/rtc_shift.ma".
+include "ground/counters/rtc_plus.ma".
+include "ground/counters/rtc_max.ma".
 include "basic_2/notation/relations/predty_7.ma".
 include "static_2/syntax/lenv.ma".
 include "static_2/syntax/genv.ma".
index ac451b66c580f81de831319b96bbc455013c211c..d145044228a6ce5044dc86ec13d03ab0abf713e9 100644 (file)
@@ -16,9 +16,9 @@ include "ground/xoa/ex_4_1.ma".
 include "ground/xoa/ex_4_3.ma".
 include "ground/xoa/ex_5_6.ma".
 include "ground/xoa/ex_6_7.ma".
-include "ground/steps/rtc_max_shift.ma".
-include "ground/steps/rtc_isrt_plus.ma".
-include "ground/steps/rtc_isrt_max_shift.ma".
+include "ground/counters/rtc_max_shift.ma".
+include "ground/counters/rtc_isrt_plus.ma".
+include "ground/counters/rtc_isrt_max_shift.ma".
 include "static_2/syntax/sh.ma".
 include "basic_2/notation/relations/pred_6.ma".
 include "basic_2/rt_transition/cpg.ma".
index 4f41f762df352ca8babcd74183e125c20c992be7..de305d48144bd0551e6b1ddc758b92c0f99f669a 100644 (file)
@@ -13,9 +13,9 @@
 (**************************************************************************)
 
 include "ground/xoa/ex_4_3.ma".
-include "ground/steps/rtc_ist_shift.ma".
-include "ground/steps/rtc_ist_plus.ma".
-include "ground/steps/rtc_ist_max.ma".
+include "ground/counters/rtc_ist_shift.ma".
+include "ground/counters/rtc_ist_plus.ma".
+include "ground/counters/rtc_ist_max.ma".
 include "static_2/syntax/sh.ma".
 include "basic_2/notation/relations/pty_6.ma".
 include "basic_2/rt_transition/cpg.ma".
index fdee8f321d45717ee74cbf97f723a1689c95753a..cb3deebf664f0ffe5facc56325c2703559ab37b1 100644 (file)
@@ -8,7 +8,7 @@ clean::
        @$(RM) recommGc*.ml*
 
 test:
-       @./recomm.native $(O) -C ../../ground/steps . | sort | uniq > log.txt
+       @./recomm.native -r $(O) -C srcs . | sort | uniq > log.txt
 
 MRCS = $(wildcard *.mrc)
 
index bd88c9d6039ddde2281444ab9477713ea96d0543..363f07fcff33877bf0ec2215e7bc2644220950fb 100644 (file)
@@ -1,5 +1,4 @@
 PcsAnd b "" true false
-rtc_max, max
-rtc_shift, shift
-rtc_ism, test for constrained rt-transition counter
-rtc_ist, test for t-transition counter
+rtc_shift
+rtc_max
+rtc_plus
index f78834d6a66cef47c73aa5bce6192fdf113c21de..3352f4295063ebb22a1588b72d0acc3fffde0386 100644 (file)
@@ -1,3 +1,4 @@
 PccFor d "" true false
-T-BOUND RT-TRANSITION COUNTERS, RT-TRANSITION COUNTER
-T-TRANSITION COUNTERS, T-TRANSITION COUNTER
+RT-TRANSITION COUNTERS
+T-BOUND RT-TRANSITION COUNTERS
+T-TRANSITION COUNTERS
diff --git a/matita/matita/contribs/lambdadelta/bin/recomm/rGroundCounters.mrc b/matita/matita/contribs/lambdadelta/bin/recomm/rGroundCounters.mrc
new file mode 100644 (file)
index 0000000..72b0713
--- /dev/null
@@ -0,0 +1,4 @@
+PccFor r "" true false
+ADDITION
+MAXIMUM, MAXIMUN
+SHIFT
index a2336ad9c058a0301a2a3e3d7483c828488ce415..bac315438dea9bc465fbeff79c7946e982c43128 100644 (file)
@@ -10,6 +10,8 @@ module G = RecommGc
 
 let write = ref false
 
+let force = ref false
+
 let chdir path =
   Sys.chdir path
 
@@ -23,7 +25,7 @@ let rec process path name =
     Printf.eprintf "processing: %S\n" file;
     let orig = EI.read_srcs file in
     let lint = EC.recomm_srcs orig in
-    if !write && lint <> orig then EO.write_srcs file lint
+    if !force || (!write && lint <> orig) then EO.write_srcs file lint
   end else begin
     Printf.eprintf "skipping: %S\n" file
   end
@@ -32,13 +34,15 @@ let msg_C = "<dir>  Set this working directory (default: .)"
 let msg_L = " Log lexer tokens (default: no)"
 let msg_c = "<int>  Set these output columns (default: 78)"
 let msg_d = " Log with dark colors (default: no)"
+let msg_f = " Write all output files (default: no)"
 let msg_k = " Log key comments (default: no)"
 let msg_m = " Log mark comments (default: no)"
 let msg_n = " Log with no colors (default: yes)"
 let msg_o = " Log other comments (default: no)"
+let msg_r = " Replace the input files (default: no)"
 let msg_s = " Log section comments (default: no)"
 let msg_t = " Log title comments (default: no)"
-let msg_w = " Write the output files (default: no)"
+let msg_w = " Write the changed output files (default: no)"
 
 let main =
   Arg.parse [
@@ -46,10 +50,12 @@ let main =
     "-L", Arg.Set EL.debug, msg_m;
     "-c", Arg.Int ((:=) EO.width), msg_c;
     "-d", Arg.Clear EC.bw, msg_d;
+    "-f", Arg.Set force, msg_f;
     "-k", Arg.Set EC.log_k, msg_k;
     "-m", Arg.Set EC.log_m, msg_m;
     "-n", Arg.Set EC.bw, msg_n;
     "-o", Arg.Set EC.log_o, msg_o;
+    "-r", Arg.Set EO.replace, msg_r;
     "-s", Arg.Set EC.log_s, msg_s;
     "-t", Arg.Set EC.log_t, msg_t;
     "-w", Arg.Set write, msg_w;
index 93d1d03162f09db324668c9dbb34cad206ef3b94..e5629ccc8468b509b75c3fdb3254c21486185cbf 100644 (file)
@@ -76,7 +76,7 @@ let rec recomm srcs st =
     if middle st then Printf.eprintf "middle: %S\n" s1;
     if !log_k then log prune (s1^s2);
     recomm tl @@ add hd @@ st
-  | ET.Title ss as hd :: tl        ->
+  | ET.Title ss :: tl              ->
     if middle st then Printf.eprintf "middle: TITLE\n";
     let b, ss1, ss2 = !c_line k_final false [] ss in
     let ss2 =
@@ -85,8 +85,8 @@ let rec recomm srcs st =
     let ss = List.rev_append ss1 ss2 in
     let s = String.concat " " ss in
     if !log_t then log blue s;
-    recomm tl @@ add hd @@ st
-  | ET.Slice ss as hd :: tl        ->
+    recomm tl @@ add (ET.Title ss) @@ st
+  | ET.Slice ss :: tl              ->
     if middle st then Printf.eprintf "middle: Section\n";
     let b, ss1, ss2 = !s_line k_final false [] ss in
     let ss2 =
@@ -95,7 +95,7 @@ let rec recomm srcs st =
     let ss = List.rev_append ss1 ss2 in
     let s = String.capitalize_ascii (String.concat " " ss) in
     if !log_s then log sky s;
-    recomm tl @@ add hd @@ st
+    recomm tl @@ add (ET.Slice ss) @@ st
   | ET.Other (_, s, _) as hd :: tl ->
     if !log_o && not (Array.mem s mute_o) then log black s;
     recomm tl @@ add hd @@ st
index 6ffe876a74157ec220af184d84408916de5ca5a8..12a3ec66491ba8a703ac5186e57417602e85c4a3 100644 (file)
@@ -1,5 +1,6 @@
 module G1 = RecommGcbGroundCounters
 module G2 = RecommGcdGroundCounters
-module G3 = RecommGcsAttr
-module G4 = RecommGcsMain
-module G5 = RecommGcsWith
+module G3 = RecommGcrGroundCounters
+module G4 = RecommGcsAttr
+module G5 = RecommGcsMain
+module G6 = RecommGcsWith
index da14eabe1e6ee7a1d5b55629879c7772af745b39..53a98c92e2f30b1297b3f8bd218b2fddab8a726a 100644 (file)
@@ -1,14 +1,9 @@
 let step k ok outs ins =
   if ok then k ok outs ins else
   match ins with
-  | "rtc_ist" :: tl -> k true ("rtc_ist" :: outs) tl
-  | "test" :: "for" :: "t-transition" :: "counter" :: tl -> k true ("rtc_ist" :: outs) tl
-  | "rtc_ism" :: tl -> k true ("rtc_ism" :: outs) tl
-  | "test" :: "for" :: "constrained" :: "rt-transition" :: "counter" :: tl -> k true ("rtc_ism" :: outs) tl
-  | "rtc_shift" :: tl -> k true ("rtc_shift" :: outs) tl
-  | "shift" :: tl -> k true ("rtc_shift" :: outs) tl
+  | "rtc_plus" :: tl -> k true ("rtc_plus" :: outs) tl
   | "rtc_max" :: tl -> k true ("rtc_max" :: outs) tl
-  | "max" :: tl -> k true ("rtc_max" :: outs) tl
+  | "rtc_shift" :: tl -> k true ("rtc_shift" :: outs) tl
   | _ -> k ok outs ins
 
 let main =
index 5f86d75fe114ef5a84923cbf18c214da5894e765..796c21168adf2238cbea618af9ac36e2722a0dfd 100644 (file)
@@ -2,9 +2,8 @@ let step k ok outs ins =
   if ok then k ok outs ins else
   match ins with
   | "T-TRANSITION" :: "COUNTERS" :: tl -> k true ("COUNTERS" :: "T-TRANSITION" :: outs) tl
-  | "T-TRANSITION" :: "COUNTER" :: tl -> k true ("COUNTERS" :: "T-TRANSITION" :: outs) tl
   | "T-BOUND" :: "RT-TRANSITION" :: "COUNTERS" :: tl -> k true ("COUNTERS" :: "RT-TRANSITION" :: "T-BOUND" :: outs) tl
-  | "RT-TRANSITION" :: "COUNTER" :: tl -> k true ("COUNTERS" :: "RT-TRANSITION" :: "T-BOUND" :: outs) tl
+  | "RT-TRANSITION" :: "COUNTERS" :: tl -> k true ("COUNTERS" :: "RT-TRANSITION" :: outs) tl
   | _ -> k ok outs ins
 
 let main =
diff --git a/matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.ml b/matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.ml
new file mode 100644 (file)
index 0000000..d85161f
--- /dev/null
@@ -0,0 +1,11 @@
+let step k ok outs ins =
+  if ok then k ok outs ins else
+  match ins with
+  | "SHIFT" :: tl -> k true ("SHIFT" :: outs) tl
+  | "MAXIMUM" :: tl -> k true ("MAXIMUM" :: outs) tl
+  | "MAXIMUN" :: tl -> k true ("MAXIMUM" :: outs) tl
+  | "ADDITION" :: tl -> k true ("ADDITION" :: outs) tl
+  | _ -> k ok outs ins
+
+let main =
+  RecommPccFor.register_r step
diff --git a/matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.mli b/matita/matita/contribs/lambdadelta/bin/recomm/recommGcrGroundCounters.mli
new file mode 100644 (file)
index 0000000..e69de29
index 0f66fc44bc5ab74bacc2f3c2023eafa37ad0c814..21cca9c6c21529ea6a4a3b0d5f7e1ad387496d53 100644 (file)
@@ -10,6 +10,7 @@
   let heads = [|
     "Advanved";
     "Basic";
+    "Constructions";
     "Forward";
     "Destructions";
     "Eliminations";
index 5189c7f7790141b113491e39e3c4d2085e299d86..fe8bebe945148fdd03ce6450c4b8b3f1bdbc56ec 100644 (file)
@@ -2,6 +2,8 @@ module ET = RecommTypes
 
 let width = ref 78
 
+let replace = ref false
+
 let complete s =
   let l = !width - String.length s - 6 in
   if l < 0 then begin
@@ -19,7 +21,7 @@ let out_src och = function
   | ET.Mark s             ->
     Printf.fprintf och "(* %s**)" s
   | ET.Key (s1, s2)       ->
-    Printf.fprintf och "(* %s1%s2*)" s1 s2
+    Printf.fprintf och "(* %s%s*)" s1 s2
   | ET.Title ss           ->
     let s = String.concat " " ss in
     Printf.fprintf och "(* %s %s*)" s (complete s)
@@ -30,6 +32,14 @@ let out_src och = function
     Printf.fprintf och "%s%s%s" s1 s2 s3
 
 let write_srcs file srcs =
-  let och = open_out (file ^ ".new") in
+  let target =  
+    if !replace then begin
+      Sys.rename file (file ^ ".old");
+      file
+    end else begin
+      file ^ ".new"
+    end
+  in
+  let och = open_out target in
   List.iter (out_src och) srcs;
   close_out och
index e1e85629628ff0ab9f410bf0ce8f91f147b16f7b..088b7fd9ddc5ffbe1a2398a96da726e3d82a2f16 100644 (file)
@@ -1,3 +1,5 @@
 val width: int ref
 
+val replace: bool ref
+
 val write_srcs: string -> RecommTypes.srcs -> unit
index 5d08261c860b3de123ccde2f9bcc5f73dc58e2d0..cdad8df5599a13ce628bc91706fc2a74fba35482 100644 (file)
@@ -8,7 +8,7 @@ let r_line = ref ES.id
 let k_for k ok outs ins =
   if ok then begin
     match ins with
-    | "for" :: tl -> !d_line k false ("for" :: outs) tl
+    | "FOR" :: tl -> !d_line k false ("FOR" :: outs) tl
     | _           -> k true outs ins
   end else begin
     k true outs ins
index c3ca75497f461051d39951f34dd962f57f3dc2d7..44c3539b9eb0035c26509880827f14df182de90e 100644 (file)
@@ -60,11 +60,18 @@ lemma nmax_assoc: associative β€¦ nmax.
 #n1 #n2 #IH #n3 @(nat_ind_succ β€¦ n3) -n3 //
 qed.
 
+lemma nmax_max_comm_23 (o:nat) (m) (n): (o βˆ¨ m βˆ¨ n) = (o βˆ¨ n βˆ¨ m).
+#o #m #n >nmax_assoc >nmax_assoc <nmax_comm in βŠ’ (??(??%)?); //
+qed.
+
 (* Basic inversions *********************************************************)
 
-(*** max_inv_O3 *)
-lemma nmax_inv_zero (n1) (n2): πŸŽ = (n1 βˆ¨ n2) β†’ βˆ§βˆ§ πŸŽ = n1 & πŸŽ = n2.
+lemma eq_inv_zero_nmax (n1) (n2): πŸŽ = (n1 βˆ¨ n2) β†’ βˆ§βˆ§ πŸŽ = n1 & πŸŽ = n2.
 #n1 #n2 @(nat_ind_2_succ β€¦ n1 n2) -n1 -n2 /2 width=1 by conj/
 #n1 #n2 #_ <nmax_succ_bi #H
 elim (eq_inv_zero_nsucc β€¦ H)
 qed-.
+
+(*** max_inv_O3 *)
+lemma eq_inv_nmax_zero (n1) (n2): (n1 βˆ¨ n2) = πŸŽ β†’ βˆ§βˆ§ πŸŽ = n1 & πŸŽ = n2.
+/2 width=1 by eq_inv_zero_nmax/ qed-.
index 40beec972819238df4a5bdd75ed92e403d48d436..2f0f4b658a7251e0f5b69ea023505dfdbb647b6e 100644 (file)
@@ -80,7 +80,7 @@ lemma nplus_one_sn (n): β†‘n = πŸ + n.
 #n <nplus_comm // qed.
 
 lemma nplus_succ_shift (m) (n): β†‘m + n = m + β†‘n.
-// qed-.
+// qed.
 
 (*** assoc_plus1 *)
 lemma nplus_plus_comm_12 (o) (m) (n): m + n + o = n + (m + o).
@@ -89,11 +89,11 @@ lemma nplus_plus_comm_12 (o) (m) (n): m + n + o = n + (m + o).
 (*** plus_plus_comm_23 *)
 lemma nplus_plus_comm_23 (o) (m) (n): o + m + n = o + n + m.
 #o #m #n >nplus_assoc >nplus_assoc <nplus_comm in βŠ’ (??(??%)?); //
-qed-.
+qed.
 
 (* Basic inversions *********************************************************)
 
-(*** plus_inv_O3 zero_eq_plus *) 
+(*** zero_eq_plus *)
 lemma eq_inv_zero_nplus (m) (n): πŸŽ = m + n β†’ βˆ§βˆ§ πŸŽ = m & πŸŽ = n.
 #m #n @(nat_ind_succ β€¦ n) -n
 [ /2 width=1 by conj/
@@ -102,6 +102,11 @@ lemma eq_inv_zero_nplus (m) (n): πŸŽ = m + n β†’ βˆ§βˆ§ πŸŽ = m & πŸŽ = n.
 ]
 qed-.
 
+(*** plus_inv_O3 *)
+lemma eq_inv_nplus_zero (m) (n):
+      m + n = πŸŽ β†’ βˆ§βˆ§ πŸŽ = m & πŸŽ = n.
+/2 width=1 by eq_inv_zero_nplus/ qed-.
+
 (*** injective_plus_l *)
 lemma eq_inv_nplus_bi_dx (o) (m) (n): m + o = n + o β†’ m = n.
 #o @(nat_ind_succ β€¦ o) -o /3 width=1 by eq_inv_nsucc_bi/
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc.ma
new file mode 100644 (file)
index 0000000..414fa1b
--- /dev/null
@@ -0,0 +1,73 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_1_2.ma".
+include "ground/notation/functions/tuple_4.ma".
+include "ground/notation/functions/zerozero_0.ma".
+include "ground/notation/functions/zeroone_0.ma".
+include "ground/notation/functions/onezero_0.ma".
+include "ground/insert_eq/insert_eq_1.ma".
+include "ground/arith/nat.ma".
+
+(* RT-TRANSITION COUNTERS ***************************************************)
+
+record rtc: Type[0] β‰ {
+(* Note: inner r-steps *)
+   ri: nat;
+(* Note: spine r-steps *)
+   rs: nat;
+(* Note: inner t-steps *)
+   ti: nat;
+(* Note: spine t-steps *)
+   ts: nat
+}.
+
+interpretation
+  "constructor (rtc)"
+  'Tuple ri rs ti ts = (mk_rtc ri rs ti ts).
+
+interpretation
+  "one structural step (rtc)"
+  'ZeroZero = (mk_rtc nzero nzero nzero nzero).
+
+interpretation
+  "one r-step (rtc)"
+  'OneZero = (mk_rtc nzero (ninj punit) nzero nzero).
+
+interpretation
+  "one t-step (rtc)"
+  'ZeroOne = (mk_rtc nzero nzero nzero (ninj punit)).
+
+definition rtc_eq_f: relation rtc β‰ Ξ»c1,c2. βŠ€.
+
+inductive rtc_eq_t: relation rtc β‰
+| eq_t_intro: βˆ€ri1,ri2,rs1,rs2,ti,ts.
+              rtc_eq_t (〈ri1,rs1,ti,tsβŒͺ) (〈ri2,rs2,ti,tsβŒͺ)
+.
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_eq_t_refl: reflexive β€¦  rtc_eq_t.
+* // qed.
+
+(* Basic inversions *********************************************************)
+
+lemma rtc_eq_t_inv_dx:
+      βˆ€ri1,rs1,ti,ts,y. rtc_eq_t (〈ri1,rs1,ti,tsβŒͺ) y β†’
+      βˆƒβˆƒri2,rs2. y = βŒ©ri2,rs2,ti,tsβŒͺ.
+#ri0 #rs0 #ti0 #ts0 #y @(insert_eq_1 β€¦ (〈ri0,rs0,ti0,ts0βŒͺ))
+#x * -x -y
+#ri1 #ri2 #rs1 #rs2 #ti1 #ts1 #H destruct -ri1 -rs1
+/2 width=3 by ex1_2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism.ma
new file mode 100644 (file)
index 0000000..335bbbc
--- /dev/null
@@ -0,0 +1,65 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/notation/relations/ism_2.ma".
+include "ground/counters/rtc.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+definition rtc_ism: relation2 nat rtc β‰ Ξ»ts,c.
+           βˆƒβˆƒri,rs. βŒ©ri,rs,𝟎,tsβŒͺ = c.
+
+interpretation
+  "t-bound rt-transition counters (rtc)"
+  'IsM ts c = (rtc_ism ts c).
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_ism_zz: πŒβͺ𝟎,𝟘𝟘❫.
+/2 width=3 by ex1_2_intro/ qed.
+
+lemma rtc_ism_zu: πŒβͺ𝟎,πŸ™πŸ˜β«.
+/2 width=3 by ex1_2_intro/ qed.
+
+lemma rtc_ism_uz: πŒβͺ𝟏,πŸ˜πŸ™β«.
+/2 width=3 by ex1_2_intro/ qed.
+
+lemma rtc_ism_eq_t_trans (n) (c1) (c2): πŒβͺn,c1❫ β†’ rtc_eq_t c1 c2 β†’ πŒβͺn,c2❫.
+#n #c1 #c2 * #ri1 #rs1 #H destruct
+#H elim (rtc_eq_t_inv_dx β€¦ H) -H /2 width=3 by ex1_2_intro/
+qed-.
+
+(* Basic destructions *******************************************************)
+
+lemma rtc_ism_des_zz (n): πŒβͺn,𝟘𝟘❫ β†’ πŸŽ = n.
+#n * #ri #rs #H destruct //
+qed-.
+
+lemma rtc_ism_des_uz (n): πŒβͺn,πŸ™πŸ˜β« β†’ πŸŽ = n.
+#n * #ri #rs #H destruct //
+qed-.
+
+lemma rtc_ism_des_01 (n): πŒβͺn,πŸ˜πŸ™β« β†’ ninj (𝟏) = n.
+#n * #ri #rs #H destruct //
+qed-.
+
+(* Main inversions **********************************************************)
+
+theorem rtc_ism_inj (n1) (n2) (c): πŒβͺn1,c❫ β†’ πŒβͺn2,c❫ β†’ n1 = n2.
+#n1 #n2 #c * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct //
+qed-.
+
+theorem rtc_ism_mono (n) (c1) (c2): πŒβͺn,c1❫ β†’ πŒβͺn,c2❫ β†’ rtc_eq_t c1 c2.
+#n #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max.ma
new file mode 100644 (file)
index 0000000..3e46552
--- /dev/null
@@ -0,0 +1,68 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_ism.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_max ***********************************************)
+
+lemma rtc_ism_max (n1) (n2) (c1) (c2): πŒβͺn1,c1❫ β†’ πŒβͺn2,c2❫ β†’ πŒβͺn1∨n2,c1∨c2❫.
+#n1 #n2 #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct
+/2 width=3 by ex1_2_intro/
+qed.
+
+lemma rtc_ism_max_zero_sn (n) (c1) (c2): πŒβͺ𝟎,c1❫ β†’ πŒβͺn,c2❫ β†’ πŒβͺn,c1∨c2❫.
+/2 width=1 by rtc_ism_max/ qed.
+
+lemma rtc_ism_max_zero_dx (n) (c1) (c2): πŒβͺn,c1❫ β†’ πŒβͺ𝟎,c2❫ β†’ πŒβͺn,c1∨c2❫.
+#n #c1 #c2 #H1 #H2 >(nmax_zero_dx n) /2 width=1 by rtc_ism_max/
+qed.
+
+lemma rtc_ism_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_ism_max/
+qed.
+
+(* Inversions with rtc_max **************************************************)
+
+lemma rtc_ism_inv_max (n) (c1) (c2): πŒβͺn,c1 βˆ¨ c2❫ β†’
+      βˆƒβˆƒn1,n2. πŒβͺn1,c1❫ & πŒβͺn2,c2❫ & (n1 βˆ¨ n2) = n.
+#n #c1 #c2 * #ri #rs #H
+elim (rtc_max_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #_ #_ #H1 #H2 #H3 #H4
+elim (eq_inv_nmax_zero β€¦ H1) -H1 /3 width=5 by ex3_2_intro, ex1_2_intro/
+qed-.
+
+lemma rtc_isr_inv_max (c1) (c2): πŒβͺ𝟎,c1 βˆ¨ c2❫ β†’ βˆ§βˆ§ πŒβͺ𝟎,c1❫ & πŒβͺ𝟎,c2❫.
+#c1 #c2 #H
+elim (rtc_ism_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_ism_inv_max_zero_dx (n) (c1) (c2): πŒβͺn,c1 βˆ¨ c2❫ β†’ πŒβͺ𝟎,c2❫ β†’ πŒβͺn,c1❫.
+#n #c1 #c2 #H #H2
+elim (rtc_ism_inv_max β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
+lapply (rtc_ism_inj β€¦ Hn2 H2) -c2 #H destruct //
+qed-.
+
+lemma rtc_ism_inv_max_eq_t (n) (c1) (c2): πŒβͺn,c1 βˆ¨ c2❫ β†’ rtc_eq_t c1 c2 β†’
+      βˆ§βˆ§ πŒβͺn,c1❫ & πŒβͺn,c2❫.
+#n #c1 #c2 #H #Hc12
+elim (rtc_ism_inv_max β€¦ H) -H #n1 #n2 #Hc1 #Hc2 #H destruct
+lapply (rtc_ism_eq_t_trans β€¦ Hc1 β€¦ Hc12) -Hc12 #H
+<(rtc_ism_inj β€¦ H β€¦ Hc2) -Hc2
+<nmax_idem /2 width=1 by conj/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max_shift.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_max_shift.ma
new file mode 100644 (file)
index 0000000..8d9a450
--- /dev/null
@@ -0,0 +1,28 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/counters/rtc_ism_shift.ma".
+include "ground/counters/rtc_ism_max.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Inversions with rtc_max and rtc_shift ************************************)
+
+lemma rtc_ism_inv_max_shift_sn (n) (c1) (c2): πŒβͺn,↕*c1 βˆ¨ c2❫ β†’
+      βˆ§βˆ§ πŒβͺ𝟎,c1❫ & πŒβͺn,c2❫.
+#n #c1 #c2 #H
+elim (rtc_ism_inv_max β€¦ H) -H #n1 #n2 #Hc1 #Hc2 #H destruct
+elim (rtc_ism_inv_shift β€¦ Hc1) -Hc1 #Hc1 * -n1 <nmax_zero_sn
+/2 width=1 by conj/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_plus.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_plus.ma
new file mode 100644 (file)
index 0000000..5453b63
--- /dev/null
@@ -0,0 +1,61 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_plus.ma".
+include "ground/counters/rtc_ism.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_plus **********************************************)
+
+lemma rtc_ism_plus (n1) (n2) (c1) (c2):  πŒβͺn1,c1❫ β†’ πŒβͺn2,c2❫ β†’ πŒβͺn1+n2,c1+c2❫.
+#n1 #n2 #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct
+/2 width=3 by ex1_2_intro/
+qed.
+
+lemma rtc_ism_plus_zero_sn (n) (c1) (c2): πŒβͺ𝟎,c1❫ β†’ πŒβͺn,c2❫ β†’ πŒβͺn,c1+c2❫.
+#n #c1 #c2 #H1 #H2 >(nplus_zero_sn n) /2 width=1 by rtc_ism_plus/
+qed.
+
+lemma rtc_ism_plus_zero_dx (n) (c1) (c2): πŒβͺn,c1❫ β†’ πŒβͺ𝟎,c2❫ β†’ πŒβͺn,c1+c2❫.
+/2 width=1 by rtc_ism_plus/ qed.
+
+lemma rtc_ism_succ (n) (c): πŒβͺn,c❫ β†’ πŒβͺ↑n,c+πŸ˜πŸ™β«.
+#n #c #H >nplus_one_dx
+/2 width=1 by rtc_ism_plus/
+qed.
+
+(* Inversions with rtc_plus *************************************************)
+
+lemma rtc_ism_inv_plus (n) (c1) (c2): πŒβͺn,c1 + c2❫ β†’
+      βˆƒβˆƒn1,n2. πŒβͺn1,c1❫ & πŒβͺn2,c2❫ & n1 + n2 = n.
+#n #c1 #c2 * #ri #rs #H
+elim (rtc_plus_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #_ #_ #H1 #H2 #H3 #H4
+elim (eq_inv_nplus_zero β€¦ H1) -H1 /3 width=5 by ex3_2_intro, ex1_2_intro/
+qed-.
+
+lemma rtc_ism_inv_plus_zero_dx (n) (c1) (c2): πŒβͺn,c1 + c2❫ β†’ πŒβͺ𝟎,c2❫ β†’ πŒβͺn,c1❫.
+#n #c1 #c2 #H #H2
+elim (rtc_ism_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
+lapply (rtc_ism_inj β€¦ Hn2 H2) -c2 #H destruct //
+qed-.
+
+lemma rtc_ism_inv_plus_unit_dx (n) (c1) (c2): πŒβͺn,c1 + c2❫ β†’ πŒβͺ𝟏,c2❫ β†’
+      βˆƒβˆƒm. πŒβͺm,c1❫ & n = β†‘m.
+#n #c1 #c2 #H #H2
+elim (rtc_ism_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
+lapply (rtc_ism_inj β€¦ Hn2 H2) -c2 #H destruct
+/2 width=3 by ex2_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_shift.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ism_shift.ma
new file mode 100644 (file)
index 0000000..3ecc6d0
--- /dev/null
@@ -0,0 +1,36 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/counters/rtc_shift.ma".
+include "ground/counters/rtc_ism.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_shift *********************************************)
+
+lemma rtc_isr_shift (c):  πŒβͺ𝟎,c❫ β†’ πŒβͺ𝟎,↕*c❫.
+#c * #ri #rs #H destruct /2 width=3 by ex1_2_intro/
+qed.
+
+(* Inversions with rtc_shift ************************************************)
+
+lemma rtc_ism_inv_shift (n) (c): πŒβͺn,↕*c❫ β†’ βˆ§βˆ§ πŒβͺ𝟎,c❫ & πŸŽ = n.
+#n #c * #ri #rs #H
+elim (rtc_shift_inv_dx β€¦ H) -H #rt0 #rs0 #ti0 #ts0 #_ #_ #H1 #H2 #H3
+elim (eq_inv_nmax_zero β€¦ H1) -H1 /3 width=3 by ex1_2_intro, conj/
+qed-.
+
+lemma rtc_isr_inv_shift (c): πŒβͺ𝟎,↕*c❫ β†’ πŒβͺ𝟎,c❫.
+#c #H elim (rtc_ism_inv_shift β€¦ H) -H //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist.ma
new file mode 100644 (file)
index 0000000..38c430a
--- /dev/null
@@ -0,0 +1,57 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/notation/relations/ist_2.ma".
+include "ground/counters/rtc.ma".
+
+(* T-TRANSITION COUNTERS ****************************************************)
+
+definition rtc_ist: relation2 nat rtc β‰
+           Ξ»ts,c. βŒ©πŸŽ,𝟎,𝟎,tsβŒͺ = c.
+
+interpretation
+  "t-transition counters (rtc)"
+  'IsT ts c = (rtc_ist ts c).
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_ist_zz: π“βͺ𝟎,𝟘𝟘❫.
+// qed.
+
+lemma rtc_ist_zu: π“βͺ𝟏,πŸ˜πŸ™β«.
+// qed.
+
+(* Basic inversions *********************************************************)
+
+lemma rtc_ist_inv_zz (n): π“βͺn,𝟘𝟘❫ β†’ πŸŽ = n.
+#n #H destruct //
+qed-.
+
+lemma rtc_ist_inv_zu (n): π“βͺn,πŸ˜πŸ™β« β†’ ninj (𝟏) = n.
+#n #H destruct //
+qed-.
+
+lemma rtc_ist_inv_uz (n): π“βͺn,πŸ™πŸ˜β« β†’ βŠ₯.
+#h #H destruct
+qed-.
+
+(* Main inversions **********************************************************)
+
+theorem rtc_ist_inj (n1) (n2) (c): π“βͺn1,c❫ β†’ π“βͺn2,c❫ β†’ n1 = n2.
+#n1 #n2 #c #H1 #H2 destruct //
+qed-.
+
+theorem rtc_ist_mono (n) (c1) (c2): π“βͺn,c1❫ β†’ π“βͺn,c2❫ β†’ c1 = c2.
+#n #c1 #c2 #H1 #H2 destruct //
+qed-.
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-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_plus.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_plus.ma
new file mode 100644 (file)
index 0000000..08bb3b7
--- /dev/null
@@ -0,0 +1,69 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_plus.ma".
+include "ground/counters/rtc_ist.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_plus **********************************************)
+
+lemma rtc_ist_plus (n1) (n2) (c1) (c2): π“βͺn1,c1❫ β†’ π“βͺn2,c2❫ β†’ π“βͺn1+n2,c1+c2❫.
+#n1 #n2 #c1 #c2 #H1 #H2 destruct //
+qed.
+
+lemma rtc_ist_plus_zero_sn (n) (c1) (c2): π“βͺ𝟎,c1❫ β†’ π“βͺn,c2❫ β†’ π“βͺn,c1+c2❫.
+#n #c1 #c2 #H1 #H2 >(nplus_zero_sn n)
+/2 width=1 by rtc_ist_plus/
+qed.
+
+lemma rtc_ist_plus_zero_dx (n) (c1) (c2): π“βͺn,c1❫ β†’ π“βͺ𝟎,c2❫ β†’ π“βͺn,c1+c2❫.
+/2 width=1 by rtc_ist_plus/ qed.
+
+lemma rtc_ist_succ (n) (c): π“βͺn,c❫ β†’ π“βͺ↑n,c+πŸ˜πŸ™β«.
+#n #c #H >nplus_one_dx
+/2 width=1 by rtc_ist_plus/
+qed.
+
+(* Inversions with rtc_plus *************************************************)
+
+lemma rtc_ist_inv_plus (n) (c1) (c2): π“βͺn,c1 + c2❫ β†’
+      βˆƒβˆƒn1,n2. π“βͺn1,c1❫ & π“βͺn2,c2❫ & n1 + n2 = n.
+#n #c1 #c2 #H
+elim (rtc_plus_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #H1 #H2 #H3 #H4 #H5 #H6 destruct
+elim (eq_inv_nplus_zero β€¦ H1) -H1 #H11 #H12 destruct
+elim (eq_inv_nplus_zero β€¦ H2) -H2 #H21 #H22 destruct
+elim (eq_inv_nplus_zero β€¦ H3) -H3 #H31 #H32 destruct
+/3 width=5 by ex3_2_intro/
+qed-.
+
+lemma rtc_ist_inv_plus_zero_dx (n) (c1) (c2): π“βͺn,c1 + c2❫ β†’ π“βͺ𝟎,c2❫ β†’ π“βͺn,c1❫.
+#n #c1 #c2 #H #H2
+elim (rtc_ist_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct //
+qed-.
+
+lemma rtc_ist_inv_plus_one_dx:
+      βˆ€n,c1,c2. π“βͺn,c1 + c2❫ β†’ π“βͺ𝟏,c2❫ β†’
+      βˆƒβˆƒm. π“βͺm,c1❫ & n = β†‘m.
+#n #c1 #c2 #H #H2 destruct
+elim (rtc_ist_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
+/2 width=3 by ex2_intro/
+qed-.
+
+lemma rtc_ist_inv_plus_zu_dx (n) (c): π“βͺn,c+πŸ™πŸ˜β« β†’ βŠ₯.
+#n #c #H
+elim (rtc_ist_inv_plus β€¦ H) -H #n1 #n2 #_ #H #_
+/2 width=2 by rtc_ist_inv_uz/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_shift.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_ist_shift.ma
new file mode 100644 (file)
index 0000000..fbb72ab
--- /dev/null
@@ -0,0 +1,38 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/counters/rtc_shift.ma".
+include "ground/counters/rtc_ist.ma".
+
+(* T-BOUND RT-TRANSITION COUNTERS *******************************************)
+
+(* Constructions with rtc_shift *********************************************)
+
+lemma rtc_ist_zero_shift (c): π“βͺ𝟎,c❫ β†’ π“βͺ𝟎,↕*c❫.
+#c #H destruct //
+qed.
+
+(* Inversions with rtc_shift ************************************************)
+
+lemma rtc_ist_inv_shift (n) (c): π“βͺn,↕*c❫ β†’ βˆ§βˆ§ π“βͺ𝟎,c❫ & πŸŽ = n.
+#n #c #H
+elim (rtc_shift_inv_dx β€¦ H) -H #rt0 #rs0 #ti0 #ts0 #H1 #_ #H2 #H3 #H4 destruct
+elim (eq_inv_nmax_zero β€¦ H1) -H1 #H11 #H12 destruct
+elim (eq_inv_nmax_zero β€¦ H2) -H2 #H21 #H22 destruct
+/2 width=1 by conj/
+qed-.
+
+lemma rtc_ist_inv_zero_shift (c): π“βͺ𝟎,↕*c❫ β†’ π“βͺ𝟎,c❫.
+#c #H elim (rtc_ist_inv_shift β€¦ H) -H //
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_max.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_max.ma
new file mode 100644 (file)
index 0000000..10fbce4
--- /dev/null
@@ -0,0 +1,64 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_6_8.ma".
+include "ground/arith/nat_max.ma".
+include "ground/counters/rtc.ma".
+
+(* MAXIMUM FOR RT-TRANSITION COUNTERS ***************************************)
+
+definition rtc_max (c1:rtc) (c2:rtc): rtc β‰
+match c1 with
+[ mk_rtc ri1 rs1 ti1 ts1 β‡’
+  match c2 with
+  [ mk_rtc ri2 rs2 ti2 ts2 β‡’ βŒ©ri1∨ri2,rs1∨rs2,ti1∨ti2,ts1∨ts2βŒͺ
+  ]
+].
+
+interpretation
+  "maximum (rtc)"
+  'or c1 c2 = (rtc_max c1 c2).
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_max_rew (ri1) (ri2) (rs1) (rs2) (ti1) (ti2) (ts1) (ts2):
+      βŒ©ri1∨ri2,rs1∨rs2,ti1∨ti2,ts1∨ts2βŒͺ =
+      (〈ri1,rs1,ti1,ts1βŒͺ βˆ¨ βŒ©ri2,rs2,ti2,ts2βŒͺ).
+// qed.
+
+lemma rtc_max_zz_dx (c): c = (c βˆ¨ πŸ˜πŸ˜).
+* #ri #rs #ti #ts <rtc_max_rew //
+qed.
+
+lemma rtc_max_idem (c): c = (c βˆ¨ c).
+* #ri #rs #ti #ts <rtc_max_rew //
+qed.
+
+(* Basic inversions *********************************************************)
+
+lemma rtc_max_inv_dx (ri) (rs) (ti) (ts) (c1) (c2):
+      βŒ©ri,rs,ti,tsβŒͺ = (c1 βˆ¨ c2) β†’
+      βˆƒβˆƒri1,rs1,ti1,ts1,ri2,rs2,ti2,ts2.
+      (ri1∨ri2) = ri & (rs1∨rs2) = rs & (ti1∨ti2) = ti & (ts1∨ts2) = ts &
+      βŒ©ri1,rs1,ti1,ts1βŒͺ = c1 & βŒ©ri2,rs2,ti2,ts2βŒͺ = c2.
+#ri #rs #ti #ts * #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
+<rtc_max_rew #H destruct /2 width=14 by ex6_8_intro/
+qed-.
+
+(* Main constructions *******************************************************)
+
+theorem rtc_max_assoc: associative β€¦ rtc_max.
+* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2 * #ri3 #rs3 #ti3 #ts3
+<rtc_max_rew <rtc_max_rew //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_max_shift.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_max_shift.ma
new file mode 100644 (file)
index 0000000..ed5669c
--- /dev/null
@@ -0,0 +1,26 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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/counters/rtc_shift.ma".
+include "ground/counters/rtc_max.ma".
+
+(* MAXIMUM FOR RT-TRANSITION COUNTERS ***************************************)
+
+(* Constructions with rtc_shift *********************************************)
+
+lemma rtc_max_shift (c1) (c2): ((↕*c1) βˆ¨ (↕*c2)) = β†•*(c1∨c2).
+* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
+<rtc_shift_rew <rtc_shift_rew <rtc_shift_rew <rtc_max_rew
+<nmax_assoc <nmax_assoc <nmax_assoc <nmax_assoc //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_plus.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_plus.ma
new file mode 100644 (file)
index 0000000..9c6d7e7
--- /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_6_8.ma".
+include "ground/arith/nat_plus.ma".
+include "ground/counters/rtc.ma".
+
+(* ADDITION FOR RT-TRANSITION COUNTERS **************************************)
+
+definition rtc_plus (c1:rtc) (c2:rtc): rtc β‰
+match c1 with
+[ mk_rtc ri1 rs1 ti1 ts1 β‡’
+  match c2 with
+  [ mk_rtc ri2 rs2 ti2 ts2 β‡’ βŒ©ri1+ri2,rs1+rs2,ti1+ti2,ts1+ts2βŒͺ
+  ]
+].
+
+interpretation
+  "plus (rtc)"
+  'plus c1 c2 = (rtc_plus c1 c2).
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_plus_rew (ri1) (ri2) (rs1) (rs2) (ti1) (ti2) (ts1) (ts2):
+      βŒ©ri1+ri2,rs1+rs2,ti1+ti2,ts1+ts2βŒͺ = βŒ©ri1,rs1,ti1,ts1βŒͺ+〈ri2,rs2,ti2,ts2βŒͺ.
+// qed.
+
+lemma rtc_plus_zz_dx (c): c = c + πŸ˜πŸ˜.
+* #ri #rs #ti #ts <rtc_plus_rew //
+qed.
+
+(* Basic inversions *********************************************************)
+
+lemma rtc_plus_inv_dx (ri) (rs) (ti) (ts) (c1) (c2):
+      βŒ©ri,rs,ti,tsβŒͺ = c1 + c2 β†’
+      βˆƒβˆƒri1,rs1,ti1,ts1,ri2,rs2,ti2,ts2.
+      ri1+ri2 = ri & rs1+rs2 = rs & ti1+ti2 = ti & ts1+ts2 = ts &
+      βŒ©ri1,rs1,ti1,ts1βŒͺ = c1 & βŒ©ri2,rs2,ti2,ts2βŒͺ = c2.
+#ri #rs #ti #ts * #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
+<rtc_plus_rew #H destruct /2 width=14 by ex6_8_intro/
+qed-.
+
+(* Main constructions *******************************************************)
+
+theorem rtc_plus_assoc: associative β€¦ rtc_plus.
+* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2 * #ri3 #rs3 #ti3 #ts3
+<rtc_plus_rew //
+qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/counters/rtc_shift.ma b/matita/matita/contribs/lambdadelta/ground/counters/rtc_shift.ma
new file mode 100644 (file)
index 0000000..b2f1ed0
--- /dev/null
@@ -0,0 +1,49 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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_5_4.ma".
+include "ground/notation/functions/updownarrowstar_1.ma".
+include "ground/arith/nat_max.ma".
+include "ground/counters/rtc.ma".
+
+(* SHIFT FOR RT-TRANSITION COUNTERS *****************************************)
+
+definition rtc_shift (c:rtc): rtc β‰
+match c with
+[ mk_rtc ri rs ti ts β‡’ βŒ©ri βˆ¨ rs, πŸŽ, ti βˆ¨ ts, πŸŽβŒͺ 
+].
+
+interpretation
+  "shift (rtc)"
+  'UpDownArrowStar c = (rtc_shift c).
+
+(* Basic constructions ******************************************************)
+
+lemma rtc_shift_rew (ri) (rs) (ti) (ts):
+      βŒ©ri βˆ¨ rs, πŸŽ, ti βˆ¨ ts, πŸŽβŒͺ = β†•*〈ri,rs,ti,tsβŒͺ.
+//
+qed.
+
+lemma rtc_shift_zz: πŸ˜πŸ˜ = β†•*𝟘𝟘.
+// qed.
+
+(* Basic inversions *********************************************************)
+
+lemma rtc_shift_inv_dx (ri) (rs) (ti) (ts) (c):
+      βŒ©ri,rs,ti,tsβŒͺ = β†•*c β†’
+      βˆƒβˆƒri0,rs0,ti0,ts0.
+      (ri0∨rs0) = ri & πŸŽ = rs & (ti0∨ts0) = ti & πŸŽ = ts & βŒ©ri0,rs0,ti0,ts0βŒͺ = c.
+#ri #rs #ti #ts * #ri0 #rs0 #ti0 #ts0 <rtc_shift_rew #H destruct
+/2 width=7 by ex5_4_intro/
+qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/ism_2.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/ism_2.ma
new file mode 100644 (file)
index 0000000..e40a895
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
+
+notation "hvbox( πŒβͺ term 46 n, break term 46 c β« )"
+   non associative with precedence 45
+   for @{ 'IsM $n $c }.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/isredtype_2.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/isredtype_2.ma
deleted file mode 100644 (file)
index 58ac256..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
-
-notation "hvbox( π‘𝐓βͺ term 46 n, break term 46 c β« )"
-   non associative with precedence 45
-   for @{ 'IsRedType $n $c }.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/ist_1.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/ist_1.ma
new file mode 100644 (file)
index 0000000..5b44202
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
+
+notation "hvbox( π“βͺ term 46 f β« )"
+   non associative with precedence 45
+   for @{ 'IsT $f }.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/ist_2.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/ist_2.ma
new file mode 100644 (file)
index 0000000..e9a96fa
--- /dev/null
@@ -0,0 +1,19 @@
+(**************************************************************************)
+(*       ___                                                              *)
+(*      ||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                  *)
+(*                                                                        *)
+(**************************************************************************)
+
+(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
+
+notation "hvbox( π“βͺ term 46 n, break term 46 c β« )"
+   non associative with precedence 45
+   for @{ 'IsT $n $c }.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/istotal_1.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/istotal_1.ma
deleted file mode 100644 (file)
index e26e9a3..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
-
-notation "hvbox( π“βͺ term 46 f β« )"
-   non associative with precedence 45
-   for @{ 'IsTotal $f }.
diff --git a/matita/matita/contribs/lambdadelta/ground/notation/relations/istype_2.ma b/matita/matita/contribs/lambdadelta/ground/notation/relations/istype_2.ma
deleted file mode 100644 (file)
index 04c4927..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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                  *)
-(*                                                                        *)
-(**************************************************************************)
-
-(* GENERAL NOTATION USED BY THE FORMAL SYSTEM Ξ»Ξ΄ ****************************)
-
-notation "hvbox( π“βͺ term 46 n, break term 46 c β« )"
-   non associative with precedence 45
-   for @{ 'IsType $n $c }.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc.ma
deleted file mode 100644 (file)
index 8a81ab6..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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_1_2.ma".
-include "ground/notation/functions/tuple_4.ma".
-include "ground/notation/functions/zerozero_0.ma".
-include "ground/notation/functions/zeroone_0.ma".
-include "ground/notation/functions/onezero_0.ma".
-include "ground/lib/arith.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-record rtc: Type[0] β‰ {
-   ri: nat; (* Note: inner r-steps *)
-   rs: nat; (* Note: spine r-steps *)
-   ti: nat; (* Note: inner t-steps *)
-   ts: nat  (* Note: spine t-steps *)
-}.
-
-interpretation "constructor (rtc)"
-   'Tuple ri rs ti ts = (mk_rtc ri rs ti ts).
-
-interpretation "one structural step (rtc)"
-   'ZeroZero = (mk_rtc O O O O).
-
-interpretation "one r-step (rtc)"
-   'OneZero = (mk_rtc O (S O) O O).
-
-interpretation "one t-step (rtc)"
-   'ZeroOne = (mk_rtc O O O (S O)).
-
-definition rtc_eq_f: relation rtc β‰ Ξ»c1,c2. βŠ€.
-
-inductive rtc_eq_t: relation rtc β‰
-| eq_t_intro: βˆ€ri1,ri2,rs1,rs2,ti,ts.
-              rtc_eq_t (〈ri1,rs1,ti,tsβŒͺ) (〈ri2,rs2,ti,tsβŒͺ)
-.
-
-(* Basic properties *********************************************************)
-
-lemma rtc_eq_t_refl: reflexive β€¦  rtc_eq_t.
-* // qed.
-
-(* Basic inversion lemmas ***************************************************)
-
-fact rtc_eq_t_inv_dx_aux:
-     βˆ€x,y. rtc_eq_t x y β†’
-     βˆ€ri1,rs1,ti,ts. x = βŒ©ri1,rs1,ti,tsβŒͺ β†’
-     βˆƒβˆƒri2,rs2. y = βŒ©ri2,rs2,ti,tsβŒͺ.
-#x #y * -x -y
-#ri1 #ri #rs1 #rs #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #H destruct -ri2 -rs2
-/2 width=3 by ex1_2_intro/
-qed-.
-
-lemma rtc_eq_t_inv_dx:
-      βˆ€ri1,rs1,ti,ts,y. rtc_eq_t (〈ri1,rs1,ti,tsβŒͺ) y β†’
-      βˆƒβˆƒri2,rs2. y = βŒ©ri2,rs2,ti,tsβŒͺ.
-/2 width=5 by rtc_eq_t_inv_dx_aux/ qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt.ma
deleted file mode 100644 (file)
index 6671720..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/notation/relations/isredtype_2.ma".
-include "ground/steps/rtc.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-definition isrt: relation2 nat rtc β‰ Ξ»ts,c.
-                 βˆƒβˆƒri,rs. βŒ©ri,rs,0,tsβŒͺ = c.
-
-interpretation "test for constrained rt-transition counter (rtc)"
-   'IsRedType ts c = (isrt ts c).
-
-(* Basic properties *********************************************************)
-
-lemma isrt_00: π‘𝐓βͺ0,𝟘𝟘❫.
-/2 width=3 by ex1_2_intro/ qed.
-
-lemma isrt_10: π‘𝐓βͺ0,πŸ™πŸ˜β«.
-/2 width=3 by ex1_2_intro/ qed.
-
-lemma isrt_01: π‘𝐓βͺ1,πŸ˜πŸ™β«.
-/2 width=3 by ex1_2_intro/ qed.
-
-lemma isrt_eq_t_trans: βˆ€n,c1,c2. π‘𝐓βͺn,c1❫ β†’ rtc_eq_t c1 c2 β†’ π‘𝐓βͺn,c2❫.
-#n #c1 #c2 * #ri1 #rs1 #H destruct
-#H elim (rtc_eq_t_inv_dx β€¦ H) -H /2 width=3 by ex1_2_intro/
-qed-.
-
-(* Basic inversion properties ***********************************************)
-
-lemma isrt_inv_00: βˆ€n. π‘𝐓βͺn,𝟘𝟘❫ β†’ 0 = n.
-#n * #ri #rs #H destruct //
-qed-.
-
-lemma isrt_inv_10: βˆ€n. π‘𝐓βͺn,πŸ™πŸ˜β« β†’ 0 = n.
-#n * #ri #rs #H destruct //
-qed-.
-
-lemma isrt_inv_01: βˆ€n. π‘𝐓βͺn,πŸ˜πŸ™β« β†’ 1 = n.
-#n * #ri #rs #H destruct //
-qed-.
-
-(* Main inversion properties ************************************************)
-
-theorem isrt_inj: βˆ€n1,n2,c. π‘𝐓βͺn1,c❫ β†’ π‘𝐓βͺn2,c❫ β†’ n1 = n2.
-#n1 #n2 #c * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct //
-qed-.
-
-theorem isrt_mono: βˆ€n,c1,c2. π‘𝐓βͺn,c1❫ β†’ π‘𝐓βͺn,c2❫ β†’ rtc_eq_t c1 c2.
-#n #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max.ma
deleted file mode 100644 (file)
index ed314bb..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_max.ma".
-include "ground/steps/rtc_isrt.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for constrained rt-transition counter ***************)
-
-lemma isrt_max: βˆ€n1,n2,c1,c2. π‘𝐓βͺn1,c1❫ β†’ π‘𝐓βͺn2,c2❫ β†’ π‘𝐓βͺn1∨n2,c1∨c2❫.
-#n1 #n2 #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct
-/2 width=3 by ex1_2_intro/
-qed.
-
-lemma isrt_max_O1: βˆ€n,c1,c2. π‘𝐓βͺ0,c1❫ β†’ π‘𝐓βͺn,c2❫ β†’ π‘𝐓βͺn,c1∨c2❫.
-/2 width=1 by isrt_max/ qed.
-
-lemma isrt_max_O2: βˆ€n,c1,c2. π‘𝐓βͺn,c1❫ β†’ π‘𝐓βͺ0,c2❫ β†’ π‘𝐓βͺn,c1∨c2❫.
-#n #c1 #c2 #H1 #H2 >(max_O2 n) /2 width=1 by isrt_max/
-qed.
-
-lemma isrt_max_idem1: βˆ€n,c1,c2. π‘𝐓βͺn,c1❫ β†’ π‘𝐓βͺn,c2❫ β†’ π‘𝐓βͺn,c1∨c2❫.
-#n #c1 #c2 #H1 #H2 >(idempotent_max n) /2 width=1 by isrt_max/
-qed.
-
-(* Inversion properties with test for constrained rt-transition counter *****)
-
-lemma isrt_inv_max: βˆ€n,c1,c2. π‘𝐓βͺn,c1 βˆ¨ c2❫ β†’
-                    βˆƒβˆƒn1,n2. π‘𝐓βͺn1,c1❫ & π‘𝐓βͺn2,c2❫ & (n1 βˆ¨ n2) = n.
-#n #c1 #c2 * #ri #rs #H
-elim (max_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #_ #_ #H1 #H2 #H3 #H4
-elim (max_inv_O3 β€¦ H1) -H1 /3 width=5 by ex3_2_intro, ex1_2_intro/
-qed-.
-
-lemma isrt_O_inv_max: βˆ€c1,c2. π‘𝐓βͺ0,c1 βˆ¨ c2❫ β†’ βˆ§βˆ§ π‘𝐓βͺ0,c1❫ & π‘𝐓βͺ0,c2❫.
-#c1 #c2 #H
-elim (isrt_inv_max β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H
-elim (max_inv_O3 β€¦ H) -H #H1 #H2 destruct
-/2 width=1 by conj/
-qed-.
-
-lemma isrt_inv_max_O_dx: βˆ€n,c1,c2. π‘𝐓βͺn,c1 βˆ¨ c2❫ β†’ π‘𝐓βͺ0,c2❫ β†’ π‘𝐓βͺn,c1❫.
-#n #c1 #c2 #H #H2
-elim (isrt_inv_max β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
-lapply (isrt_inj β€¦ Hn2 H2) -c2 #H destruct //
-qed-.
-
-lemma isrt_inv_max_eq_t: βˆ€n,c1,c2. π‘𝐓βͺn,c1 βˆ¨ c2❫ β†’ rtc_eq_t c1 c2 β†’
-                         βˆ§βˆ§ π‘𝐓βͺn,c1❫ & π‘𝐓βͺn,c2❫.
-#n #c1 #c2 #H #Hc12
-elim (isrt_inv_max β€¦ H) -H #n1 #n2 #Hc1 #Hc2 #H destruct
-lapply (isrt_eq_t_trans β€¦ Hc1 β€¦ Hc12) -Hc12 #H
-<(isrt_inj β€¦ H β€¦ Hc2) -Hc2
-<idempotent_max /2 width=1 by conj/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max_shift.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_max_shift.ma
deleted file mode 100644 (file)
index f3765f8..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_isrt_shift.ma".
-include "ground/steps/rtc_isrt_max.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Inversion properties with test for constrained rt-transition counter *****)
-
-lemma isrt_inv_max_shift_sn: βˆ€n,c1,c2. π‘𝐓βͺn,↕*c1 βˆ¨ c2❫ β†’
-                             βˆ§βˆ§ π‘𝐓βͺ0,c1❫ & π‘𝐓βͺn,c2❫.
-#n #c1 #c2 #H
-elim (isrt_inv_max β€¦ H) -H #n1 #n2 #Hc1 #Hc2 #H destruct
-elim (isrt_inv_shift β€¦ Hc1) -Hc1 #Hc1 * -n1
-/2 width=1 by conj/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_plus.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_plus.ma
deleted file mode 100644 (file)
index 9a14bb1..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_plus.ma".
-include "ground/steps/rtc_isrt.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for constrained rt-transition counter ***************)
-
-lemma isrt_plus: βˆ€n1,n2,c1,c2. π‘𝐓βͺn1,c1❫ β†’ π‘𝐓βͺn2,c2❫ β†’ π‘𝐓βͺn1+n2,c1+c2❫.
-#n1 #n2 #c1 #c2 * #ri1 #rs1 #H1 * #ri2 #rs2 #H2 destruct
-/2 width=3 by ex1_2_intro/
-qed.
-
-lemma isrt_plus_O1: βˆ€n,c1,c2. π‘𝐓βͺ0,c1❫ β†’ π‘𝐓βͺn,c2❫ β†’ π‘𝐓βͺn,c1+c2❫.
-/2 width=1 by isrt_plus/ qed.
-
-lemma isrt_plus_O2: βˆ€n,c1,c2. π‘𝐓βͺn,c1❫ β†’ π‘𝐓βͺ0,c2❫ β†’ π‘𝐓βͺn,c1+c2❫.
-#n #c1 #c2 #H1 #H2 >(plus_n_O n) /2 width=1 by isrt_plus/
-qed.
-
-lemma isrt_succ: βˆ€n,c. π‘𝐓βͺn,c❫ β†’ π‘𝐓βͺ↑n,c+πŸ˜πŸ™β«.
-/2 width=1 by isrt_plus/ qed.
-
-(* Inversion properties with test for constrained rt-transition counter *****)
-
-lemma isrt_inv_plus: βˆ€n,c1,c2. π‘𝐓βͺn,c1 + c2❫ β†’
-                     βˆƒβˆƒn1,n2. π‘𝐓βͺn1,c1❫ & π‘𝐓βͺn2,c2❫ & n1 + n2 = n.
-#n #c1 #c2 * #ri #rs #H
-elim (plus_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #_ #_ #H1 #H2 #H3 #H4
-elim (plus_inv_O3 β€¦ H1) -H1 /3 width=5 by ex3_2_intro, ex1_2_intro/
-qed-.
-
-lemma isrt_inv_plus_O_dx: βˆ€n,c1,c2. π‘𝐓βͺn,c1 + c2❫ β†’ π‘𝐓βͺ0,c2❫ β†’ π‘𝐓βͺn,c1❫.
-#n #c1 #c2 #H #H2
-elim (isrt_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
-lapply (isrt_inj β€¦ Hn2 H2) -c2 #H destruct //
-qed-.
-
-lemma isrt_inv_plus_SO_dx: βˆ€n,c1,c2. π‘𝐓βͺn,c1 + c2❫ β†’ π‘𝐓βͺ1,c2❫ β†’
-                           βˆƒβˆƒm. π‘𝐓βͺm,c1❫ & n = β†‘m.
-#n #c1 #c2 #H #H2
-elim (isrt_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
-lapply (isrt_inj β€¦ Hn2 H2) -c2 #H destruct
-/2 width=3 by ex2_intro/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_shift.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_isrt_shift.ma
deleted file mode 100644 (file)
index 0e0b73f..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_shift.ma".
-include "ground/steps/rtc_isrt.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for constrained rt-transition counter ***************)
-
-lemma isr_shift: βˆ€c. π‘𝐓βͺ0,c❫ β†’ π‘𝐓βͺ0,↕*c❫.
-#c * #ri #rs #H destruct /2 width=3 by ex1_2_intro/
-qed.
-
-(* Inversion properties with test for constrained rt-transition counter *****)
-
-lemma isrt_inv_shift: βˆ€n,c. π‘𝐓βͺn,↕*c❫ β†’ π‘𝐓βͺ0,c❫ βˆ§ 0 = n.
-#n #c * #ri #rs #H
-elim (shift_inv_dx β€¦ H) -H #rt0 #rs0 #ti0 #ts0 #_ #_ #H1 #H2 #H3
-elim (max_inv_O3 β€¦ H1) -H1 /3 width=3 by ex1_2_intro, conj/
-qed-.
-
-lemma isr_inv_shift: βˆ€c. π‘𝐓βͺ0,↕*c❫ β†’ π‘𝐓βͺ0,c❫.
-#c #H elim (isrt_inv_shift β€¦ H) -H //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist.ma
deleted file mode 100644 (file)
index c0bafa7..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/notation/relations/istype_2.ma".
-include "ground/steps/rtc.ma".
-
-(* T-TRANSITION COUNTER *****************************************************)
-
-definition ist: relation2 nat rtc β‰
-           Ξ»ts,c. βŒ©0,0,0,tsβŒͺ = c.
-
-interpretation "test for t-transition counter (rtc)"
-   'IsType ts c = (ist ts c).
-
-(* Basic properties *********************************************************)
-
-lemma ist_00: π“βͺ0,𝟘𝟘❫.
-// qed.
-
-lemma ist_01: π“βͺ1,πŸ˜πŸ™β«.
-// qed.
-
-(* Basic inversion properties ***********************************************)
-
-lemma ist_inv_00: βˆ€n. π“βͺn,𝟘𝟘❫ β†’ 0 = n.
-#n #H destruct //
-qed-.
-
-lemma ist_inv_01: βˆ€n. π“βͺn,πŸ˜πŸ™β« β†’ 1 = n.
-#n #H destruct //
-qed-.
-
-lemma ist_inv_10: βˆ€n. π“βͺn,πŸ™πŸ˜β« β†’ βŠ₯.
-#h #H destruct
-qed-.
-
-(* Main inversion properties ************************************************)
-
-theorem ist_inj: βˆ€n1,n2,c. π“βͺn1,c❫ β†’ π“βͺn2,c❫ β†’ n1 = n2.
-#n1 #n2 #c #H1 #H2 destruct //
-qed-.
-
-theorem ist_mono: βˆ€n,c1,c2. π“βͺn,c1❫ β†’ π“βͺn,c2❫ β†’ c1 = c2.
-#n #c1 #c2 #H1 #H2 destruct //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_max.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_max.ma
deleted file mode 100644 (file)
index 72be5b9..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_max.ma".
-include "ground/steps/rtc_ist.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for t-transition counter ****************************)
-
-lemma ist_max: βˆ€n1,n2,c1,c2. π“βͺn1,c1❫ β†’ π“βͺn2,c2❫ β†’ π“βͺn1∨n2,c1∨c2❫.
-#n1 #n2 #c1 #c2 #H1 #H2 destruct //
-qed.
-
-lemma ist_max_O1: βˆ€n,c1,c2. π“βͺ0,c1❫ β†’ π“βͺn,c2❫ β†’ π“βͺn,c1∨c2❫.
-/2 width=1 by ist_max/ qed.
-
-lemma ist_max_O2: βˆ€n,c1,c2. π“βͺn,c1❫ β†’ π“βͺ0,c2❫ β†’ π“βͺn,c1∨c2❫.
-#n #c1 #c2 #H1 #H2 >(max_O2 n) /2 width=1 by ist_max/
-qed.
-
-lemma ist_max_idem1: βˆ€n,c1,c2. π“βͺn,c1❫ β†’ π“βͺn,c2❫ β†’ π“βͺn,c1∨c2❫.
-#n #c1 #c2 #H1 #H2 >(idempotent_max n) /2 width=1 by ist_max/
-qed.
-
-(* Inversion properties with test for t-transition counter ******************)
-
-lemma ist_inv_max:
-      βˆ€n,c1,c2. π“βͺn,c1 βˆ¨ c2❫ β†’
-      βˆƒβˆƒn1,n2. π“βͺn1,c1❫ & π“βͺn2,c2❫ & (n1 βˆ¨ n2) = n.
-#n #c1 #c2 #H
-elim (max_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #H1 #H2 #H3 #H4 #H5 #H6 destruct
-elim (max_inv_O3 β€¦ H1) -H1 #H11 #H12 destruct
-elim (max_inv_O3 β€¦ H2) -H2 #H21 #H22 destruct
-elim (max_inv_O3 β€¦ H3) -H3 #H31 #H32 destruct
-/2 width=5 by ex3_2_intro/
-qed-.
-
-lemma ist_O_inv_max: βˆ€c1,c2. π“βͺ0,c1 βˆ¨ c2❫ β†’ βˆ§βˆ§ π“βͺ0,c1❫ & π“βͺ0,c2❫.
-#c1 #c2 #H
-elim (ist_inv_max β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H
-elim (max_inv_O3 β€¦ H) -H #H1 #H2 destruct
-/2 width=1 by conj/
-qed-.
-
-lemma ist_inv_max_O_dx: βˆ€n,c1,c2. π“βͺn,c1 βˆ¨ c2❫ β†’ π“βͺ0,c2❫ β†’ π“βͺn,c1❫.
-#n #c1 #c2 #H #H2
-elim (ist_inv_max β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_plus.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_plus.ma
deleted file mode 100644 (file)
index 44f12f0..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_plus.ma".
-include "ground/steps/rtc_ist.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for t-transition counter ****************************)
-
-lemma ist_plus: βˆ€n1,n2,c1,c2. π“βͺn1,c1❫ β†’ π“βͺn2,c2❫ β†’ π“βͺn1+n2,c1+c2❫.
-#n1 #n2 #c1 #c2 #H1 #H2 destruct //
-qed.
-
-lemma ist_plus_O1: βˆ€n,c1,c2. π“βͺ0,c1❫ β†’ π“βͺn,c2❫ β†’ π“βͺn,c1+c2❫.
-/2 width=1 by ist_plus/ qed.
-
-lemma ist_plus_O2: βˆ€n,c1,c2. π“βͺn,c1❫ β†’ π“βͺ0,c2❫ β†’ π“βͺn,c1+c2❫.
-#n #c1 #c2 #H1 #H2 >(plus_n_O n) /2 width=1 by ist_plus/
-qed.
-
-lemma ist_succ: βˆ€n,c. π“βͺn,c❫ β†’ π“βͺ↑n,c+πŸ˜πŸ™β«.
-/2 width=1 by ist_plus/ qed.
-
-(* Inversion properties with test for constrained rt-transition counter *****)
-
-lemma ist_inv_plus:
-      βˆ€n,c1,c2. π“βͺn,c1 + c2❫ β†’
-      βˆƒβˆƒn1,n2. π“βͺn1,c1❫ & π“βͺn2,c2❫ & n1 + n2 = n.
-#n #c1 #c2 #H
-elim (plus_inv_dx β€¦ H) -H #ri1 #rs1 #ti1 #ts1 #ri2 #rs2 #ti2 #ts2 #H1 #H2 #H3 #H4 #H5 #H6 destruct
-elim (plus_inv_O3 β€¦ H1) -H1 #H11 #H12 destruct
-elim (plus_inv_O3 β€¦ H2) -H2 #H21 #H22 destruct
-elim (plus_inv_O3 β€¦ H3) -H3 #H31 #H32 destruct
-/3 width=5 by ex3_2_intro/
-qed-.
-
-lemma ist_inv_plus_O_dx: βˆ€n,c1,c2. π“βͺn,c1 + c2❫ β†’ π“βͺ0,c2❫ β†’ π“βͺn,c1❫.
-#n #c1 #c2 #H #H2
-elim (ist_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct //
-qed-.
-
-lemma ist_inv_plus_SO_dx:
-      βˆ€n,c1,c2. π“βͺn,c1 + c2❫ β†’ π“βͺ1,c2❫ β†’
-      βˆƒβˆƒm. π“βͺm,c1❫ & n = β†‘m.
-#n #c1 #c2 #H #H2 destruct
-elim (ist_inv_plus β€¦ H) -H #n1 #n2 #Hn1 #Hn2 #H destruct
-/2 width=3 by ex2_intro/
-qed-.
-
-lemma ist_inv_plus_10_dx: βˆ€n,c. π“βͺn,c+πŸ™πŸ˜β« β†’ βŠ₯.
-#n #c #H
-elim (ist_inv_plus β€¦ H) -H #n1 #n2 #_ #H #_
-/2 width=2 by ist_inv_10/
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_shift.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_ist_shift.ma
deleted file mode 100644 (file)
index fcaa4d8..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_shift.ma".
-include "ground/steps/rtc_ist.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with test for t-transition counter ****************************)
-
-lemma ist_zero_shift: βˆ€c. π“βͺ0,c❫ β†’ π“βͺ0,↕*c❫.
-#c #H destruct //
-qed.
-
-(* Inversion properties with test for t-transition counter ******************)
-
-lemma ist_inv_shift: βˆ€n,c. π“βͺn,↕*c❫ β†’ βˆ§βˆ§ π“βͺ0,c❫ & 0 = n.
-#n #c #H
-elim (shift_inv_dx β€¦ H) -H #rt0 #rs0 #ti0 #ts0 #H1 #_ #H2 #H3 #H4 destruct
-elim (max_inv_O3 β€¦ H1) -H1 #H11 #H12 destruct
-elim (max_inv_O3 β€¦ H2) -H2 #H21 #H22 destruct
-/2 width=1 by conj/
-qed-.
-
-lemma ist_inv_zero_shift: βˆ€c. π“βͺ0,↕*c❫ β†’ π“βͺ0,c❫.
-#c #H elim (ist_inv_shift β€¦ H) -H //
-qed-.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_max.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_max.ma
deleted file mode 100644 (file)
index 9e76655..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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_6_8.ma".
-include "ground/steps/rtc.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-definition max (c1:rtc) (c2:rtc): rtc β‰ match c1 with [
-   mk_rtc ri1 rs1 ti1 ts1 β‡’ match c2 with [
-      mk_rtc ri2 rs2 ti2 ts2 β‡’ βŒ©ri1∨ri2,rs1∨rs2,ti1∨ti2,ts1∨ts2βŒͺ
-   ]
-].
-
-interpretation "maximum (rtc)"
-   'or c1 c2 = (max c1 c2).
-
-(* Basic properties *********************************************************)
-
-lemma max_rew: βˆ€ri1,ri2,rs1,rs2,ti1,ti2,ts1,ts2.
-                 βŒ©ri1∨ri2,rs1∨rs2,ti1∨ti2,ts1∨ts2βŒͺ =
-                 (〈ri1,rs1,ti1,ts1βŒͺ βˆ¨ βŒ©ri2,rs2,ti2,ts2βŒͺ).
-// qed.
-
-lemma max_O_dx: βˆ€c. c = (c βˆ¨ πŸ˜πŸ˜).
-* #ri #rs #ti #ts <max_rew //
-qed.
-
-lemma max_idem: βˆ€c. c = (c βˆ¨ c).
-* #ri #rs #ti #ts <max_rew //
-qed.
-
-(* Basic inversion properties ***********************************************)
-
-lemma max_inv_dx: βˆ€ri,rs,ti,ts,c1,c2. βŒ©ri,rs,ti,tsβŒͺ = (c1 βˆ¨ c2) β†’
-                  βˆƒβˆƒri1,rs1,ti1,ts1,ri2,rs2,ti2,ts2.
-                  (ri1∨ri2) = ri & (rs1∨rs2) = rs & (ti1∨ti2) = ti & (ts1∨ts2) = ts &
-                  βŒ©ri1,rs1,ti1,ts1βŒͺ = c1 & βŒ©ri2,rs2,ti2,ts2βŒͺ = c2.
-#ri #rs #ti #ts * #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
-<max_rew #H destruct /2 width=14 by ex6_8_intro/
-qed-.
-
-(* Main Properties **********************************************************)
-
-theorem max_assoc: associative β€¦ max.
-* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2 * #ri3 #rs3 #ti3 #ts3
-<max_rew <max_rew //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_max_shift.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_max_shift.ma
deleted file mode 100644 (file)
index 2287512..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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/steps/rtc_shift.ma".
-include "ground/steps/rtc_max.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-(* Properties with max and shift ********************************************)
-
-lemma max_shift: βˆ€c1,c2. ((↕*c1) βˆ¨ (↕*c2)) = β†•*(c1∨c2).
-* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
-<shift_rew <shift_rew <shift_rew <max_rew //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_plus.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_plus.ma
deleted file mode 100644 (file)
index 2c0251c..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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_6_8.ma".
-include "ground/steps/rtc.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-definition plus (c1:rtc) (c2:rtc): rtc β‰ match c1 with [
-   mk_rtc ri1 rs1 ti1 ts1 β‡’ match c2 with [
-      mk_rtc ri2 rs2 ti2 ts2 β‡’ βŒ©ri1+ri2,rs1+rs2,ti1+ti2,ts1+ts2βŒͺ
-   ]
-].
-
-interpretation "plus (rtc)"
-   'plus c1 c2 = (plus c1 c2).
-
-(* Basic properties *********************************************************)
-
-(**) (* plus is not disambiguated parentheses *)
-lemma plus_rew: βˆ€ri1,ri2,rs1,rs2,ti1,ti2,ts1,ts2.
-                 βŒ©ri1+ri2,rs1+rs2,ti1+ti2,ts1+ts2βŒͺ =
-                 (〈ri1,rs1,ti1,ts1βŒͺ) + (〈ri2,rs2,ti2,ts2βŒͺ).
-// qed.
-
-lemma plus_O_dx: βˆ€c. c = c + πŸ˜πŸ˜.
-* #ri #rs #ti #ts <plus_rew //
-qed.
-
-(* Basic inversion properties ***********************************************)
-
-lemma plus_inv_dx: βˆ€ri,rs,ti,ts,c1,c2. βŒ©ri,rs,ti,tsβŒͺ = c1 + c2 β†’
-                   βˆƒβˆƒri1,rs1,ti1,ts1,ri2,rs2,ti2,ts2.
-                   ri1+ri2 = ri & rs1+rs2 = rs & ti1+ti2 = ti & ts1+ts2 = ts &
-                   βŒ©ri1,rs1,ti1,ts1βŒͺ = c1 & βŒ©ri2,rs2,ti2,ts2βŒͺ = c2.
-#ri #rs #ti #ts * #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2
-<plus_rew #H destruct /2 width=14 by ex6_8_intro/
-qed-.
-
-(* Main Properties **********************************************************)
-
-theorem plus_assoc: associative β€¦ plus.
-* #ri1 #rs1 #ti1 #ts1 * #ri2 #rs2 #ti2 #ts2 * #ri3 #rs3 #ti3 #ts3
-<plus_rew //
-qed.
diff --git a/matita/matita/contribs/lambdadelta/ground/steps/rtc_shift.ma b/matita/matita/contribs/lambdadelta/ground/steps/rtc_shift.ma
deleted file mode 100644 (file)
index a19b6ad..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-(**************************************************************************)
-(*       ___                                                              *)
-(*      ||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_5_4.ma".
-include "ground/notation/functions/updownarrowstar_1.ma".
-include "ground/steps/rtc.ma".
-
-(* RT-TRANSITION COUNTER ****************************************************)
-
-definition shift (c:rtc): rtc β‰ match c with
-[ mk_rtc ri rs ti ts β‡’ βŒ©ri∨rs,0,ti∨ts,0βŒͺ ].
-
-interpretation "shift (rtc)"
-   'UpDownArrowStar c = (shift c).
-
-(* Basic properties *********************************************************)
-
-lemma shift_rew: βˆ€ri,rs,ti,ts. βŒ©ri∨rs,0,ti∨ts,0βŒͺ = β†•*〈ri,rs,ti,tsβŒͺ.
-normalize //
-qed.
-
-lemma shift_O: πŸ˜πŸ˜ = β†•*𝟘𝟘.
-// qed.
-
-(* Basic inversion properties ***********************************************)
-
-lemma shift_inv_dx: βˆ€ri,rs,ti,ts,c. βŒ©ri,rs,ti,tsβŒͺ = β†•*c β†’
-                    βˆƒβˆƒri0,rs0,ti0,ts0. (ri0∨rs0) = ri & 0 = rs & (ti0∨ts0) = ti & 0 = ts &
-                                       βŒ©ri0,rs0,ti0,ts0βŒͺ = c.
-#ri #rs #ti #ts * #ri0 #rs0 #ti0 #ts0 <shift_rew #H destruct
-/2 width=7 by ex5_4_intro/
-qed-.
index ca692ea2f2b5fbb643e9501330816989fcce70d2..f5fe3c956b44834b1c7f6e8b4b9d106a2382c254 100644 (file)
@@ -13,7 +13,7 @@ table {
   [ { "generic rt-transition counter" * } {
       [ { "" * } {
           [ "rtc_ist ( π“βͺ?,?❫ )" "rtc_ist_shift" "rtc_ist_plus" "rtc_ist_max" * ]
-          [ "rtc_isrc ( π‘𝐓βͺ?,?❫ )" "rtc_isrt_shift" "rtc_isrt_plus" "rtc_isrt_max" "rtc_isrt_max_shift" * ]
+          [ "rtc_ism ( πŒβͺ?,?❫ )" "rtc_ism_shift" "rtc_ism_plus" "rtc_ism_max" "rtc_ism_max_shift" * ]
           [ "rtc ( βŒ©?,?,?,?βŒͺ ) ( πŸ˜πŸ˜ ) ( πŸ™πŸ˜ ) ( πŸ˜πŸ™ )" "rtc_shift ( β†•*? )" "rtc_plus ( ? + ? )" "rtc_max ( ? βˆ¨ ? )" "rtc_max_shift" * ]
         }
       ]
index 4ed9f326c1f239464b335f56964d6027809df4b2..54bfd22d512e7917f7102f9c5f7ee165f2695e0c 100644 (file)
@@ -111,9 +111,6 @@ for @{ 'congruent $n $m $p }.
 
 (* pairs, projections *******************************************************)
 
-notation "hvbox(\langle term 19 a, break term 19 b\rangle)" 
-with precedence 90 for @{ 'pair $a $b}.
-
 notation "hvbox(x break \times y)" with precedence 70
 for @{ 'product $x $y}.
 
diff --git a/matita/matita/lib/basics/core_notation/pair_2.ma b/matita/matita/lib/basics/core_notation/pair_2.ma
new file mode 100644 (file)
index 0000000..3e22168
--- /dev/null
@@ -0,0 +1,15 @@
+(*
+    ||M||  This file is part of HELM, an Hypertextual, Electronic        
+    ||A||  Library of Mathematics, developed at the Computer Science     
+    ||T||  Department of the University of Bologna, Italy.                     
+    ||I||                                                                 
+    ||T||  
+    ||A||  This file is distributed under the terms of the 
+    \   /  GNU General Public License Version 2        
+     \ /      
+      V_______________________________________________________________ *)
+
+(* Core notation *******************************************************)
+
+notation "hvbox(\langle term 19 a, break term 19 b\rangle)" 
+with precedence 90 for @{ 'pair $a $b}.
index a5e35c9d218a5d756319dd429dd7e1b6d4e8363e..efc213f95da759cb305ef3d1522ee13691de78e0 100644 (file)
@@ -9,6 +9,7 @@
      \ /   GNU General Public License Version 2   
       V_______________________________________________________________ *)
 
+include "basics/core_notation/pair_2.ma".
 include "basics/logic.ma".
 
 (* void *)
index d71589e2a98cf324146388cc5c9218b1de8677ad..09a8c37cc7dcd9cb69118b69ccf2b047368e9eec 100644 (file)
@@ -135,9 +135,6 @@ for @{ 'equiv $n $m }.
 (*
 (* other notations **********************************************************)
 
-notation "hvbox(\langle term 19 a, break term 19 b\rangle)" 
-with precedence 90 for @{ 'pair $a $b}.
-
 notation "hvbox(x break \times y)" with precedence 70
 for @{ 'product $x $y}.