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 "static_2/static/aaa_drops.ma".
16 include "static_2/static/lsubc.ma".
18 (* LOCAL ENVIRONMENT REFINEMENT FOR GENERIC REDUCIBILITY ********************)
20 (* Properties with generic slicing ******************************************)
22 (* Note: the premise 𝐔❨f❩ cannot be removed *)
23 (* Basic_1: includes: csubc_drop_conf_O *)
24 (* Basic_2A1: includes: lsubc_drop_O1_trans *)
25 lemma lsubc_drops_trans_isuni: ∀RP,G,L1,L2. G ⊢ L1 ⫃[RP] L2 →
26 ∀b,f,K2. 𝐔❨f❩ → ⇩*[b,f] L2 ≘ K2 →
27 ∃∃K1. ⇩*[b,f] L1 ≘ K1 & G ⊢ K1 ⫃[RP] K2.
28 #RP #G #L1 #L2 #H elim H -L1 -L2
29 [ /2 width=3 by ex2_intro/
30 | #I #L1 #L2 #HL12 #IH #b #f #K2 #Hf #H
31 elim (drops_inv_bind1_isuni … Hf H) -Hf -H *
33 /3 width=3 by lsubc_bind, drops_refl, ex2_intro/
34 | #g #Hg #HLK2 #H destruct -HL12
35 elim (IH … Hg HLK2) -L2 -Hg /3 width=3 by drops_drop, ex2_intro/
37 | #L1 #L2 #V #W #A #HV #H1W #H2W #HL12 #IH #b #f #K2 #Hf #H
38 elim (drops_inv_bind1_isuni … Hf H) -Hf -H *
40 /3 width=8 by drops_refl, lsubc_beta, ex2_intro/
41 | #g #Hg #HLK2 #H destruct -HL12
42 elim (IH … Hg HLK2) -L2 -Hg /3 width=3 by drops_drop, ex2_intro/
47 (* Basic_1: was: csubc_drop1_conf_rev *)
48 (* Basic_1: includes: csubc_drop_conf_rev *)
49 (* Basic_2A1: includes: drop_lsubc_trans *)
50 lemma drops_lsubc_trans: ∀RR,RS,RP. gcp RR RS RP →
51 ∀b,f,G,L1,K1. ⇩*[b,f] L1 ≘ K1 → ∀K2. G ⊢ K1 ⫃[RP] K2 →
52 ∃∃L2. G ⊢ L1 ⫃[RP] L2 & ⇩*[b,f] L2 ≘ K2.
53 #RR #RS #RP #HR #b #f #G #L1 #K1 #H elim H -f -L1 -K1
54 [ #f #Hf #Y #H lapply (lsubc_inv_atom1 … H) -H
55 #H destruct /4 width=3 by lsubc_atom, drops_atom, ex2_intro/
56 | #f #I #L1 #K1 #_ #IH #K2 #HK12 elim (IH … HK12) -K1
57 /3 width=5 by lsubc_bind, drops_drop, ex2_intro/
58 | #f #Z #I #L1 #K1 #HLK1 #HZ #IH #Y #H elim (lsubc_inv_bind1 … H) -H *
59 [ #K2 #HK12 #H destruct -HLK1
60 elim (IH … HK12) -K1 /3 width=5 by lsubc_bind, drops_skip, ex2_intro/
61 | #K2 #V2 #W2 #A #HV2 #H1W2 #H2W2 #HK12 #H1 #H2 destruct
62 elim (liftsb_inv_pair_sn … HZ) -HZ #V1 #HV21 #H destruct
63 elim (lifts_inv_flat1 … HV21) -HV21 #W3 #V3 #HW23 #HV3 #H destruct
64 elim (IH … HK12) -IH -HK12 #K #HL1K #HK2
65 lapply (acr_lifts … HR … HV2 … HLK1 … HV3) -HV2
66 lapply (acr_lifts … HR … H1W2 … HLK1 … HW23) -H1W2
67 /4 width=10 by lsubc_beta, aaa_lifts, drops_skip, ext2_pair, ex2_intro/