include "basic_2/multiple/frees_lreq.ma".
include "basic_2/multiple/frees_lift.ma".
*)
+include "basic_2/relocation/drops_lexs.ma".
include "basic_2/s_computation/fqup_weight.ma".
+include "basic_2/static/frees_drops.ma".
include "basic_2/rt_transition/cpx_drops.ma".
-include "basic_2/rt_transition/lfpx.ma".
(* UNCOUNTED PARALLEL RT-TRANSITION FOR LOCAL ENV.S ON REFERRED ENTRIES *****)
-(* Properties with context-sensitive free variables ***************************)
+(* Properties with context-sensitive free variables *************************)
-lemma lpx_cpx_frees_fwd_sge: ∀h,G,L1,U1,U2. ⦃G, L1⦄ ⊢ U1 ⬈[h] U2 →
- ∀L2. ⦃G, L1⦄ ⊢ ⬈[h, U1] L2 →
- ∀g1. L1 ⊢ 𝐅*⦃U1⦄ ≡ g1 → ∀g2. L2 ⊢ 𝐅*⦃U2⦄ ≡ g2 →
- g2 ⊆ g1.
-#h #G #L1 #U1 @(fqup_wf_ind_eq … G L1 U1) -G -L1 -U1
-#G0 #L0 #U0 #IH #G #L1 * *
-[ #s #HG #HL #HU #U2 #H0 #L2 #_ #g1 #H1 #g2 #H2 -IH -G0 -L0 -U0
- elim (cpx_inv_sort1 … H0) -H0 #H destruct
- /3 width=3 by frees_inv_sort, sle_isid_sn/
-| #i #HG #HL #HU #U2 #H0 #L2 #HL12 #g1 #H1 #g2 #H2 destruct
- elim (cpx_inv_lref1_drops … H0) -H0
- [ #H destruct
- lapply (frees_inv_lref … H1) -H1 #Hg1
- lapply (frees_inv_sort … H2) -H2 #Hg2 /2 width=1 by sle_isid_sn/
+axiom pippo: ∀RN,RP,L1,i. ⬇*[Ⓕ, 𝐔❴i❵] L1 ≡ ⋆ →
+ ∀f,L2. L1 ⦻*[RN, RP, f] L2 →
+ ⬇*[Ⓕ, 𝐔❴i❵] L2 ≡ ⋆.
+(*
+#RN #RP #L1 #i #H1 #f #L2 #H2
+lapply (lexs_co_dropable_sn … H1 … H2) // -HL1 -H2
+*)
+lemma coafter_uni_sn: ∀i,f. 𝐔❴i❵ ~⊚ f ≡ ↑*[i] f.
+#i elim i -i /2 width=5 by coafter_isid_sn, coafter_next/
+qed.
+lemma sle_pushs: ∀f1,f2. f1 ⊆ f2 → ∀i. ↑*[i] f1 ⊆ ↑*[i] f2.
+#f1 #f2 #Hf12 #i elim i -i /2 width=5 by sle_push/
+qed.
-| #l #HG #HL #HU #U2 #H0 #L2 #_ #g1 #H1 #g2 #H2 -IH -G0 -L0 -U0
- lapply (cpx_inv_gref1 … H0) -H0 #H destruct
- /3 width=3 by frees_inv_gref, sle_isid_sn/
-
-| #j #HG #HL #HU #U2 #H1 #L2 #HL12 #i #H2 elim (cpx_inv_lref1 … H1) -H1
- [ #H destruct elim (frees_inv_lref … H2) -H2 //
- * #I #K2 #W2 #Hj #Hji #HLK2 #HW2
- elim (lpx_drop_trans_O1 … HL12 … HLK2) -HL12 #Y #HLK1 #H
- elim (lpx_inv_pair2 … H) -H #K1 #W1 #HK12 #HW12 #H destruct
- /4 width=11 by frees_lref_be, fqup_lref/
- | * #I #K1 #W1 #W0 #HLK1 #HW10 #HW0U2
- lapply (drop_fwd_drop2 … HLK1) #H0
- elim (lpx_drop_conf … H0 … HL12) -H0 -HL12 #K2 #HK12 #HLK2
- elim (ylt_split i (j+1)) >yplus_SO2 #Hji
- [ -IH elim (frees_inv_lift_be … H2 … HLK2 … HW0U2) /2 width=1 by ylt_fwd_succ2/
- | lapply (frees_inv_lift_ge … H2 … HLK2 … HW0U2 ?) -L2 -U2 // destruct
- /4 width=11 by frees_lref_be, fqup_lref, yle_succ1_inj/
- ]
- ]
-| -IH #p #HG #HL #HU #U2 #H1 >(cpx_inv_gref1 … H1) -H1 destruct
- #L2 #_ #i #H2 elim (frees_inv_gref … H2)
-| #a #I #W1 #U1 #HG #HL #HU #X #HX #L2 #HL12 #i #Hi destruct
- elim (cpx_inv_bind1 … HX) -HX *
- [ #W2 #U2 #HW12 #HU12 #H destruct
- elim (frees_inv_bind_O … Hi) -Hi
- /4 width=7 by frees_bind_dx_O, frees_bind_sn, lpx_pair/
- | #U2 #HU12 #HXU2 #H1 #H2 destruct
- lapply (frees_lift_ge … Hi (L2.ⓓW1) (Ⓕ) … HXU2 ?)
- /4 width=7 by frees_bind_dx_O, lpx_pair, drop_drop/
- ]
-| #I #W1 #X1 #HG #HL #HU #X2 #HX2 #L2 #HL12 #i #Hi destruct
- elim (cpx_inv_flat1 … HX2) -HX2 *
- [ #W2 #U2 #HW12 #HU12 #H destruct
- elim (frees_inv_flat … Hi) -Hi /3 width=7 by frees_flat_dx, frees_flat_sn/
- | #HU12 #H destruct /3 width=7 by frees_flat_dx/
- | #HW12 #H destruct /3 width=7 by frees_flat_sn/
- | #b #W2 #V1 #V2 #U1 #U2 #HW12 #HV12 #HU12 #H1 #H2 #H3 destruct
- elim (frees_inv_bind … Hi) -Hi #Hi
- [ elim (frees_inv_flat … Hi) -Hi
- /4 width=7 by frees_flat_dx, frees_flat_sn, frees_bind_sn/
- | lapply (lreq_frees_trans … Hi (L2.ⓛV2) ?) /2 width=1 by lreq_succ/ -Hi #HU2
- lapply (frees_weak … HU2 0 ?) -HU2
- /5 width=7 by frees_bind_dx_O, frees_flat_dx, lpx_pair/
+axiom monotonic_sle_sor: ∀f1,g1. f1 ⊆ g1 → ∀f2,g2. f2 ⊆ g2 →
+ ∀f. f1 ⋓ f2 ≡ f → ∀g. g1 ⋓ g2 ≡ g → f ⊆ g.
+
+axiom sle_tl: ∀f1,f2. f1 ⊆ f2 → ⫱f1 ⊆ ⫱f2.
+
+axiom frees_inv_lifts_SO: ∀b,f,L,U. L ⊢ 𝐅*⦃U⦄ ≡ f →
+ ∀K. ⬇*[b, 𝐔❴1❵] L ≡ K → ∀T. ⬆*[1] T ≡ U →
+ K ⊢ 𝐅*⦃T⦄ ≡ ⫱f.
+
+(* Basic_2A1: was: lpx_cpx_frees_trans *)
+lemma cpx_frees_trans_lexs: ∀h,G,L1,T1,f1. L1 ⊢ 𝐅*⦃T1⦄ ≡ f1 →
+ ∀L2. L1 ⦻*[cpx h G, cfull, f1] L2 →
+ ∀T2. ⦃G, L1⦄ ⊢ T1 ⬈[h] T2 →
+ ∃∃f2. L2 ⊢ 𝐅*⦃T2⦄ ≡ f2 & f2 ⊆ f1.
+#h #G #L1 #T1 @(fqup_wf_ind_eq … G L1 T1) -G -L1 -T1
+#G0 #L0 #U0 #IH #G #L1 * *
+[ -IH #s #HG #HL #HU #g1 #H1 #L2 #_ #U2 #H0 destruct
+ lapply (frees_inv_sort … H1) -H1 #Hg1
+ elim (cpx_inv_sort1 … H0) -H0 #H destruct
+ /3 width=3 by frees_sort_gen, sle_refl, ex2_intro/
+| #i #HG #HL #HU #g1 #H1 #L2 #H2 #U2 #H0 destruct
+ elim (frees_inv_lref_drops … H1) -H1 *
+ [ -IH #HL1 #Hg1
+ elim (cpx_inv_lref1_drops … H0) -H0
+ [ #H destruct lapply (pippo … HL1 … H2) -HL1 -H2
+ /3 width=3 by frees_lref_atom, sle_refl, ex2_intro/
+ | * -H2 -Hg1 #I #K1 #V1 #V2 #HLK1
+ lapply (drops_TF … HLK1) -HLK1 #HLK1
+ lapply (drops_mono … HLK1 … HL1) -L1 #H destruct
]
- | #b #W2 #W0 #V1 #V2 #U1 #U2 #HW12 #HW20 #HV12 #HU12 #H1 #H2 #H3 destruct
- elim (frees_inv_bind_O … Hi) -Hi #Hi
- [ /4 width=7 by frees_flat_dx, frees_bind_sn/
- | elim (frees_inv_flat … Hi) -Hi
- [ #HW0 lapply (frees_inv_lift_ge … HW0 L2 (Ⓕ) … HW20 ?) -W0
- /3 width=7 by frees_flat_sn, drop_drop/
- | /5 width=7 by frees_bind_dx_O, frees_flat_dx, lpx_pair/
- ]
+ | #f1 #I #K1 #V1 #Hf1 #HLK1 #H destruct
+ elim (cpx_inv_lref1_drops … H0) -H0
+ [ #H destruct
+ elim (lexs_drops_conf_next … H2 … HLK1) -H2 [ |*: // ] #K2 #V2 #HLK2 #HK12 #HV12
+ elim (IH … Hf1 … HK12 … HV12) /2 width=2 by fqup_lref/ -L1 -K1 -V1 #f2 #Hf2 #Hf21
+ /4 width=7 by frees_lref_pushs, frees_lref_pair, drops_refl, sle_next, ex2_intro, sle_pushs/
+ | * #J #Y #X #V2 #H #HV12 #HVU2
+ lapply (drops_mono … H … HLK1) -H #H destruct
+ elim (lexs_drops_conf_next … H2 … HLK1) -H2 [ |*: // ] #K2 #V0 #HLK2 #HK12 #_
+ lapply (drops_isuni_fwd_drop2 … HLK2) // -V0 #HLK2
+ elim (IH … Hf1 … HK12 … HV12) /2 width=2 by fqup_lref/ -I -L1 -K1 -V1 #f2 #Hf2 #Hf21
+ lapply (frees_lifts … Hf2 … HLK2 … HVU2 ??) /4 width=7 by sle_weak, ex2_intro, sle_pushs/
]
]
-]
-qed-.
+| -IH #l #HG #HL #HU #g1 #H1 #L2 #_ #U2 #H0 destruct
+ lapply (frees_inv_gref … H1) -H1 #Hg1
+ lapply (cpx_inv_gref1 … H0) -H0 #H destruct
+ /3 width=3 by frees_gref_gen, sle_refl, ex2_intro/
+| #p #I #V1 #T1 #HG #HL #HU #g1 #H1 #L2 #H2 #U2 #H0 destruct
+ elim (frees_inv_bind … H1) -H1 #gV1 #gT1 #HgV1 #HgT1 #Hg1
+ elim (cpx_inv_bind1 … H0) -H0 *
+ [ #V2 #T2 #HV12 #HT12 #H destruct
+ lapply (sle_lexs_trans … H2 gV1 ?) /2 width=2 by sor_inv_sle_sn/ #HL12V
+ lapply (sle_lexs_trans … H2 (⫱gT1) ?) /2 width=2 by sor_inv_sle_dx/ -H2 #HL12T
+ lapply (lexs_inv_tl … I … HL12T … HV12 ?) // -HL12T #HL12T
+ elim (IH … HgV1 … HL12V … HV12) // -HgV1 -HL12V -HV12 #gV2 #HgV2 #HgV21
+ elim (IH … HgT1 … HL12T … HT12) // -IH -HgT1 -HL12T -HT12 #gT2 #HgT2 #HgT21
+ elim (sor_isfin_ex gV2 (⫱gT2)) /3 width=3 by frees_fwd_isfin, isfin_tl/
+ /4 width=10 by frees_bind, monotonic_sle_sor, sle_tl, ex2_intro/
+ | #T2 #HT12 #HUT2 #H0 #H1 destruct -HgV1
+ lapply (sle_lexs_trans … H2 (⫱gT1) ?) /2 width=2 by sor_inv_sle_dx/ -H2 #HL12T
+ lapply (lexs_inv_tl … Abbr … V1 V1 HL12T ??) // -HL12T #HL12T
+ elim (IH … HgT1 … HL12T … HT12) // -IH -HgT1 -HL12T -HT12 #gT2 #HgT2 #HgT21
+ lapply (frees_inv_lifts_SO (Ⓣ) … HgT2 … L2 … HUT2) [ /3 width=1 by drops_refl, drops_drop/ ]
lemma cpx_frees_trans: ∀h,o,G. frees_trans (cpx h o G).
/2 width=8 by lpx_cpx_frees_trans/ qed-.
(* *)
(**************************************************************************)
+include "basic_2/relocation/drops.ma".
include "basic_2/s_computation/fqup_weight.ma".
include "basic_2/static/frees.ma".
]
]
qed-.
+
+(* Properties with plus-iterated supclosure *********************************)
+
+lemma frees_drops_next: ∀f1,L1,T1. L1 ⊢ 𝐅*⦃T1⦄ ≡ f1 →
+ ∀I2,L2,V2,n. ⬇*[n] L1 ≡ L2.ⓑ{I2}V2 →
+ ∀g1. ⫯g1 = ⫱*[n] f1 →
+ ∃∃g2. L2 ⊢ 𝐅*⦃V2⦄ ≡ g2 & g2 ⊆ g1.
+#f1 #L1 #T1 #H elim H -f1 -L1 -T1
+[ #f1 #I1 #Hf1 #I2 #L2 #V2 #n #HL12
+ elim (drops_inv_atom1 … HL12) -HL12 #H destruct
+| #f1 #I1 #L1 #V1 #s #_ #IH #I2 #L2 #V2 *
+ [ -IH #_ #g1 #Hgf1 elim (discr_next_push … Hgf1)
+ | #n #HL12 lapply (drops_inv_drop1 … HL12) -HL12
+ #HL12 #g1 <tls_xn #Hgf1 elim (IH … HL12 … Hgf1) -IH -HL12 -Hgf1
+ /2 width=3 by ex2_intro/
+ ]
+| #f1 #I1 #L1 #V1 #Hf1 #IH #I2 #L2 #V2 *
+ [ -IH #HL12 lapply (drops_fwd_isid … HL12 ?) -HL12 //
+ #H destruct #g1 #Hgf1 >(injective_next … Hgf1) -g1
+ /2 width=3 by sle_refl, ex2_intro/
+ | -Hf1 #n #HL12 lapply (drops_inv_drop1 … HL12) -HL12
+ #HL12 #g1 <tls_xn <tl_next_rew #Hgf1 elim (IH … HL12 … Hgf1) -IH -HL12 -Hgf1
+ /2 width=3 by ex2_intro/
+ ]
+| #f1 #I1 #L1 #V1 #i #_ #IH #I2 #L2 #V2 *
+ [ -IH #_ #g1 #Hgf1 elim (discr_next_push … Hgf1)
+ | #n #HL12 lapply (drops_inv_drop1 … HL12) -HL12
+ #HL12 #g1 <tls_xn #Hgf1 elim (IH … HL12 … Hgf1) -IH -HL12 -Hgf1
+ /2 width=3 by ex2_intro/
+ ]
+| #f1 #I1 #L1 #V1 #l #_ #IH #I2 #L2 #V2 *
+ [ -IH #_ #g1 #Hgf1 elim (discr_next_push … Hgf1)
+ | #n #HL12 lapply (drops_inv_drop1 … HL12) -HL12
+ #HL12 #g1 <tls_xn #Hgf1 elim (IH … HL12 … Hgf1) -IH -HL12 -Hgf1
+ /2 width=3 by ex2_intro/
+ ]
+| #fV1 #fT1 #f1 #p #I1 #L1 #V1 #T1 #_ #_ #Hf1 #IHV1 #IHT1 #I2 #L2 #V2 #n #HL12 #g1 #Hgf1
+ lapply (sor_tls … Hf1 n) -Hf1 <Hgf1 -Hgf1 #Hf1
+ elim (sor_xxn_tl … Hf1) [1,2: * |*: // ] -Hf1
+ #gV1 #gT1 #Hg1
+ [ -IHT1 #H1 #_ elim (IHV1 … HL12 … H1) -IHV1 -HL12 -H1
+ /3 width=6 by sor_sle_sn, ex2_intro/
+ | -IHV1 #_ >tls_xn #H2 elim (IHT1 … H2) -IHT1 -H2
+ /3 width=6 by drops_drop, sor_sle_dx, ex2_intro/
+ ]
+| #fV1 #fT1 #f1 #I1 #L1 #V1 #T1 #_ #_ #Hf1 #IHV1 #IHT1 #I2 #L2 #V2 #n #HL12 #g1 #Hgf1
+ lapply (sor_tls … Hf1 n) -Hf1 <Hgf1 -Hgf1 #Hf1
+ elim (sor_xxn_tl … Hf1) [1,2: * |*: // ] -Hf1
+ #gV1 #gT1 #Hg1
+ [ -IHT1 #H1 #_ elim (IHV1 … HL12 … H1) -IHV1 -HL12 -H1
+ /3 width=6 by sor_sle_sn, ex2_intro/
+ | -IHV1 #_ #H2 elim (IHT1 … HL12 … H2) -IHT1 -HL12 -H2
+ /3 width=6 by sor_sle_dx, ex2_intro/
+ ]
+]
+qed-.
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||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 "basic_2/static/lfxs_lfxs.ma".
+include "basic_2/static/frees_fqup.ma".
+include "basic_2/static/frees_frees.ma".
+
+(* GENERIC EXTENSION ON REFERRED ENTRIES OF A CONTEXT-SENSITIVE REALTION ****)
+
+axiom frees_lexs_conf_sle: ∀RN,RP,f1,L1,T. L1 ⊢ 𝐅*⦃T⦄ ≡ f1 →
+ ∀L2. L1 ⦻*[RN, RP, f1] L2 →
+ ∃∃f2. L2 ⊢ 𝐅*⦃T⦄ ≡ f2 & f2 ⊆ f1.
+
+theorem lfxs_conf: ∀R. R_confluent_lfxs R R R R →
+ ∀T. confluent … (lfxs R T).
+#R #H1R #T #L0 #L1 * #f1 #Hf1 #HL01 #L2 * #f #Hf #HL02
+lapply (frees_mono … Hf1 … Hf) -Hf1 #Hf12
+lapply (lexs_eq_repl_back … HL01 … Hf12) -f1 #HL01
+elim (lexs_conf … HL01 … HL02) /2 width=3 by ex2_intro/ [ | -HL01 -HL02 ]
+[ #L #HL1 #HL2
+ elim (frees_lexs_conf_sle … Hf … HL01) -HL01 #f1 #Hf1 #H1
+ elim (frees_lexs_conf_sle … Hf … HL02) -HL02 #f2 #Hf2 #H2
+ lapply (sle_lexs_trans … HL1 … H1) // -HL1 -H1 #HL1
+ lapply (sle_lexs_trans … HL2 … H2) // -HL2 -H2 #HL2
+ /3 width=5 by ex2_intro/
+| #g #I #K0 #V0 #n #HLK0 #Hgf #V1 #HV01 #V2 #HV02 #K1 #HK01 #K2 #HK02
+ elim (frees_drops_next … Hf … HLK0 … Hgf) -Hf -HLK0 -Hgf #g0 #Hg0 #H0
+ lapply (sle_lexs_trans … HK01 … H0) // -HK01 #HK01
+ lapply (sle_lexs_trans … HK02 … H0) // -HK02 #HK02
+ elim (H1R … HV01 … HV02 K1 … K2) /2 width=3 by ex2_intro/
+]
+qed-.
+
+(*
+lemma pippo: ∀R1,R2,RP1,RP2. R_confluent_lfxs R1 R2 RP1 RP2 →
+ lexs_confluent R1 R2 RP1 cfull RP2 cfull.
+#R1 #R2 #RP1 #RP2 #HR #f #L0 #T0 #T1 #HT01 #T2 #HT02 #L1 #HL01 #L2
+#HL02
+*)
\ No newline at end of file