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/static/frees_fqup.ma".
16 include "basic_2/static/fle.ma".
18 (* FREE VARIABLES INCLUSION FOR RESTRICTED CLOSURES *************************)
20 (* Advanced properties ******************************************************)
22 lemma fle_refl: bi_reflexive … fle.
23 #L #T elim (frees_total L T) /2 width=5 by sle_refl, ex3_2_intro/
26 lemma fle_bind_dx_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ⊆ ⦃L2, V2⦄ →
27 ∀p,I,T2. ⦃L1, V1⦄ ⊆ ⦃L2, ⓑ{p,I}V2.T2⦄.
28 #L1 #L2 #V1 #V2 * -L1 #f1 #g1 #L1 #n #Hf1 #Hg1 #HL12 #Hfg1 #p #I #T2
29 elim (frees_total (L2.ⓧ) T2) #g2 #Hg2
30 elim (sor_isfin_ex g1 (⫱g2)) /3 width=3 by frees_fwd_isfin, isfin_tl/ #g #Hg #_
31 /4 width=8 by fle_intro, frees_bind_void, sor_inv_sle_sn, sle_trans/
34 lemma fle_bind_dx_dx: ∀L1,L2,T1,T2. ⦃L1.ⓧ, T1⦄ ⊆ ⦃L2.ⓧ, T2⦄ →
35 ∀p,I,V2. ⦃L1.ⓧ, T1⦄ ⊆ ⦃L2, ⓑ{p,I}V2.T2⦄.
36 #L1 #L2 #T1 #T2 * -L1 #f2 #g2 #L1 #n #Hf2 #Hg2 #HL12 #Hfg2 #p #I #V2
37 elim (frees_total L2 V2) #g1 #Hg1
38 elim (sor_isfin_ex g1 (⫱g2)) /3 width=3 by frees_fwd_isfin, isfin_tl/ #g #Hg #_
39 @(fle_intro … g … Hf2) /2 width=5 by frees_bind_void/
40 @(sle_trans … Hfg1) @(sor_inv_sle_sn … Hg)
44 /4 width=8 by fle_intro, frees_bind_void, sor_inv_sle_dx, sle_trans/
47 lemma fle_flat_dx_sn: ∀L1,L2,V1,V2. ⦃L1, V1⦄ ⊆ ⦃L2, V2⦄ →
48 ∀I,T2. ⦃L1, V1⦄ ⊆ ⦃L2, ⓕ{I}V2.T2⦄.
49 #L1 #L2 #V1 #V2 * -L1 #f1 #g1 #L1 #n #Hf1 #Hg1 #HL12 #Hfg1 #I #T2
50 elim (frees_total L2 T2) #g2 #Hg2
51 elim (sor_isfin_ex g1 g2) /2 width=3 by frees_fwd_isfin/ #g #Hg #_
52 /4 width=8 by fle_intro, frees_flat, sor_inv_sle_sn, sle_trans/
55 lemma fle_flat_dx_dx: ∀L1,L2,T1,T2. ⦃L1, T1⦄ ⊆ ⦃L2, T2⦄ →
56 ∀I,V2. ⦃L1, T1⦄ ⊆ ⦃L2, ⓕ{I}V2.T2⦄.
57 #L1 #L2 #T1 #T2 * -L1 #f2 #g2 #L1 #n #Hf2 #Hg2 #HL12 #Hfg2 #I #V2
58 elim (frees_total L2 V2) #g1 #Hg1
59 elim (sor_isfin_ex g1 g2) /2 width=3 by frees_fwd_isfin/ #g #Hg #_
60 /4 width=8 by fle_intro, frees_flat, sor_inv_sle_dx, sle_trans/