-(**************************************************************************)
-(* ___ *)
-(* ||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/relocation/gr_tls.ma".
-include "ground/relocation/gr_pat.ma".
-(**) (* it should not depend on gr_isi *)
-include "ground/relocation/gr_isi_uni.ma".
-include "ground/relocation/gr_after_isi.ma".
-
-(* RELATIONAL COMPOSITION FOR GENERIC RELOCATION MAPS ***********************************************************)
-
-(* Properties with pat and uni *******************************************************)
-
-(*** after_uni_succ_dx *)
-lemma gr_after_uni_dx (i2) (i1):
- āf2. @āŖi1, f2ā« ā i2 ā
- āf. f2 ā š®āØi1ā© ā f ā š®āØi2ā© ā ā«±*[i2] f2 ā f.
-#i2 elim i2 -i2
-[ #i1 #f2 #Hf2 #f #Hf
- elim (gr_pat_inv_unit_dx ā¦ Hf2) -Hf2 // #g2 #H1 #H2 destruct
- elim (gr_after_inv_push_next ā¦ Hf) -Hf [ |*: // ] #g #Hg #H
- lapply (gr_after_isi_inv_dx ā¦ Hg ?) -Hg
- /4 width=5 by gr_after_isi_sn, gr_after_eq_repl_back, gr_after_next/
-| #i2 #IH #i1 #f2 #Hf2 #f #Hf >nsucc_inj
- elim (gr_pat_inv_succ_dx ā¦ Hf2) -Hf2 [1,3: * |*: // ]
- [ #g2 #j1 #Hg2 #H1 #H2 destruct >nsucc_inj in Hf; #Hf
- elim (gr_after_inv_push_next ā¦ Hf) -Hf [ |*: // ] #g #Hg #H destruct
- <gr_tls_swap /3 width=5 by gr_after_next/
- | #g2 #Hg2 #H2 destruct
- elim (gr_after_inv_next_sn ā¦ Hf) -Hf [2,3: // ] #g #Hg #H destruct
- <gr_tls_swap /3 width=5 by gr_after_next/
- ]
-]
-qed.
-
-(*** after_uni_succ_sn *)
-lemma gr_after_uni_sn (i2) (i1):
- āf2. @āŖi1, f2ā« ā i2 ā
- āf. š®āØi2ā© ā ā«±*[i2] f2 ā f ā f2 ā š®āØi1ā© ā f.
-#i2 elim i2 -i2
-[ #i1 #f2 #Hf2 #f #Hf
- elim (gr_pat_inv_unit_dx ā¦ Hf2) -Hf2 // #g2 #H1 #H2 destruct
- elim (gr_after_inv_next_sn ā¦ Hf) -Hf [ |*: // ] #g #Hg #H destruct
- lapply (gr_after_isi_inv_sn ā¦ Hg ?) -Hg
- /4 width=7 by gr_after_isi_dx, gr_after_eq_repl_back, gr_after_push/
-| #i2 #IH #i1 #f2 #Hf2 #f >nsucc_inj #Hf
- elim (gr_after_inv_next_sn ā¦ Hf) -Hf [2,3: // ] #g #Hg #H destruct
- elim (gr_pat_inv_succ_dx ā¦ Hf2) -Hf2 [1,3: * |*: // ]
- [ #g2 #j1 #Hg2 #H1 #H2 destruct <gr_tls_swap in Hg; /3 width=7 by gr_after_push/
- | #g2 #Hg2 #H2 destruct <gr_tls_swap in Hg; /3 width=5 by gr_after_next/
- ]
-]
-qed-.
-
-(* Advanced properties with uni *)
-
-(*** after_uni_one_dx *)
-lemma gr_after_uni_one_dx:
- āf2,f. ā«Æf2 ā š®āØšā© ā f ā š®āØšā© ā f2 ā f.
-#f2 #f #H
-@(gr_after_uni_dx ā¦ (ā«Æf2))
-/2 width=3 by gr_pat_refl/
-qed.
-
-(*** after_uni_one_sn *)
-lemma gr_after_uni_one_sn:
- āf1,f. š®āØšā© ā f1 ā f ā ā«Æf1 ā š®āØšā© ā f.
-/3 width=3 by gr_after_uni_sn, gr_pat_refl/ qed-.