1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "basic_2/substitution/fsupp.ma".
17 (* STAR-ITERATED SUPCLOSURE *************************************************)
19 definition fsups: bi_relation lenv term ≝ bi_star … fsup.
21 interpretation "star-iterated structural successor (closure)"
22 'SupTermStar L1 T1 L2 T2 = (fsups L1 T1 L2 T2).
24 (* Basic eliminators ********************************************************)
26 lemma fsups_ind: ∀L1,T1. ∀R:relation2 lenv term. R L1 T1 →
27 (∀L,L2,T,T2. ⦃L1, T1⦄ ⊃* ⦃L, T⦄ → ⦃L, T⦄ ⊃ ⦃L2, T2⦄ → R L T → R L2 T2) →
28 ∀L2,T2. ⦃L1, T1⦄ ⊃* ⦃L2, T2⦄ → R L2 T2.
29 #L1 #T1 #R #IH1 #IH2 #L2 #T2 #H
30 @(bi_star_ind … IH1 IH2 ? ? H)
33 lemma fsups_ind_dx: ∀L2,T2. ∀R:relation2 lenv term. R L2 T2 →
34 (∀L1,L,T1,T. ⦃L1, T1⦄ ⊃ ⦃L, T⦄ → ⦃L, T⦄ ⊃* ⦃L2, T2⦄ → R L T → R L1 T1) →
35 ∀L1,T1. ⦃L1, T1⦄ ⊃* ⦃L2, T2⦄ → R L1 T1.
36 #L2 #T2 #R #IH1 #IH2 #L1 #T1 #H
37 @(bi_star_ind_dx … IH1 IH2 ? ? H)
40 (* Basic properties *********************************************************)
42 lemma fsups_refl: bi_reflexive … fsups.
45 lemma fsupp_fsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⊃* ⦃L2, T2⦄.
48 lemma fsup_fsups: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⊃* ⦃L2, T2⦄.
51 lemma fsups_strap1: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⊃* ⦃L, T⦄ → ⦃L, T⦄ ⊃ ⦃L2, T2⦄ →
55 lemma fsups_strap2: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⊃ ⦃L, T⦄ → ⦃L, T⦄ ⊃* ⦃L2, T2⦄ →
59 lemma fsups_fsupp_fsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⊃* ⦃L, T⦄ →
60 ⦃L, T⦄ ⊃+ ⦃L2, T2⦄ → ⦃L1, T1⦄ ⊃+ ⦃L2, T2⦄.
63 lemma fsupp_fsups_fsupp: ∀L1,L,L2,T1,T,T2. ⦃L1, T1⦄ ⊃+ ⦃L, T⦄ →
64 ⦃L, T⦄ ⊃* ⦃L2, T2⦄ → ⦃L1, T1⦄ ⊃+ ⦃L2, T2⦄.
67 (* Basic forward lemmas *****************************************************)
69 lemma fsups_fwd_cw: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊃* ⦃L2, T2⦄ → ♯{L2, T2} ≤ ♯{L1, T1}.
70 #L1 #L2 #T1 #T2 #H @(fsups_ind … H) -L2 -T2 //
71 /4 width=3 by fsup_fwd_cw, lt_to_le_to_lt, lt_to_le/ (**) (* slow even with trace *)
74 (* Advanced inversion lemmas on plus-iterated supclosure ********************)
76 lemma fsupp_inv_bind1_fsups: ∀b,J,L1,L2,W,U,T2. ⦃L1, ⓑ{b,J}W.U⦄ ⊃+ ⦃L2, T2⦄ →
77 ⦃L1, W⦄ ⊃* ⦃L2, T2⦄ ∨ ⦃L1.ⓑ{J}W, U⦄ ⊃* ⦃L2, T2⦄.
78 #b #J #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -L2 -T2
80 elim (fsup_inv_bind1 … H) -H * #H1 #H2 destruct /2 width=1/
81 | #L #T #L2 #T2 #_ #HT2 * /3 width=4/
85 lemma fsupp_inv_flat1_fsups: ∀J,L1,L2,W,U,T2. ⦃L1, ⓕ{J}W.U⦄ ⊃+ ⦃L2, T2⦄ →
86 ⦃L1, W⦄ ⊃* ⦃L2, T2⦄ ∨ ⦃L1, U⦄ ⊃* ⦃L2, T2⦄.
87 #J #L1 #L2 #W #U #T2 #H @(fsupp_ind … H) -L2 -T2
89 elim (fsup_inv_flat1 … H) -H #H1 * #H2 destruct /2 width=1/
90 | #L #T #L2 #T2 #_ #HT2 * /3 width=4/