]> matita.cs.unibo.it Git - helm.git/blobdiff - matita/matita/contribs/lambdadelta/basic_2/relocation/drops_weight.ma
renaming in basic_2
[helm.git] / matita / matita / contribs / lambdadelta / basic_2 / relocation / drops_weight.ma
index 0116254957011dd23e186b98f7f4ca96ad8723e6..3b75c89f62bd7aef2dff7a58b58fd71639bdb428 100644 (file)
 (*                                                                        *)
 (**************************************************************************)
 
-include "basic_2/grammar/cl_restricted_weight.ma".
-include "basic_2/relocation/lifts_weight.ma".
+include "basic_2/syntax/cl_restricted_weight.ma".
+include "basic_2/relocation/lifts_weight_bind.ma".
 include "basic_2/relocation/drops.ma".
 
-(* GENERAL SLICING FOR LOCAL ENVIRONMENTS ***********************************)
+(* GENERIC SLICING FOR LOCAL ENVIRONMENTS ***********************************)
 
-(* Forward lemmas on weight for local environments **************************)
+(* Forward lemmas with weight for local environments ************************)
 
 (* Basic_2A1: includes: drop_fwd_lw *)
-lemma drops_fwd_lw: ∀L1,L2,c,f. ⬇*[c, f] L1 ≡ L2 → ♯{L2} ≤ ♯{L1}.
-#L1 #L2 #c #f #H elim H -L1 -L2 -f //
+lemma drops_fwd_lw: ∀b,f,L1,L2. ⬇*[b, f] L1 ≘ L2 → ♯{L2} ≤ ♯{L1}.
+#b #f #L1 #L2 #H elim H -f -L1 -L2 //
 [ /2 width=3 by transitive_le/
-| #I #L1 #L2 #V1 #V2 #f #_ #HV21 #IHL12 normalize
-  >(lifts_fwd_tw … HV21) -HV21 /2 width=1 by monotonic_le_plus_l/
+| #f #I1 #I2 #L1 #L2 #_ #HI21 #IHL12 normalize
+  >(liftsb_fwd_bw … HI21) -HI21 /2 width=1 by monotonic_le_plus_l/
 ]
 qed-.
 
 (* Basic_2A1: includes: drop_fwd_lw_lt *)
-(* Note: 𝐈⦃t⦄ → ⊥ is ∥l∥ < |L| *)
-lemma drops_fwd_lw_lt: ∀L1,L2,f. ⬇*[Ⓣ, f] L1 ≡ L2 →
+lemma drops_fwd_lw_lt: ∀f,L1,L2. ⬇*[Ⓣ, f] L1 ≘ L2 →
                        (𝐈⦃f⦄ → ⊥) → ♯{L2} < ♯{L1}.
-#L1 #L2 #f #H elim H -L1 -L2 -f
+#f #L1 #L2 #H elim H -f -L1 -L2
 [ #f #Hf #Hnf elim Hnf -Hnf /2 width=1 by/
 | /3 width=3 by drops_fwd_lw, le_to_lt_to_lt/
-| #I #L1 #L2 #V1 #V2 #f #_ #HV21 #IHL12 #H normalize in ⊢ (?%%); -I
-  >(lifts_fwd_tw … HV21) -V2 /5 width=1 by isid_push, monotonic_lt_plus_l/
+| #f #I1 #I2 #L1 #L2 #_ #HI21 #IHL12 #H normalize in ⊢ (?%%);
+  >(liftsb_fwd_bw … HI21) -I2 /5 width=3 by isid_push, monotonic_lt_plus_l/
 ]
 qed-.
 
-(* Forward lemmas on restricted weight for closures *************************)
+(* Forward lemmas with restricted weight for closures ***********************)
 
 (* Basic_2A1: includes: drop_fwd_rfw *)
-lemma drops_pair2_fwd_rfw: ∀I,L,K,V,c,f. ⬇*[c, f] L ≡ K.ⓑ{I}V → ∀T. ♯{K, V} < ♯{L, T}.
-#I #L #K #V #c #f #HLK lapply (drops_fwd_lw … HLK) -HLK
-normalize in ⊢ (%→?→?%%); /3 width=3 by le_to_lt_to_lt/
+lemma drops_bind2_fwd_rfw: ∀b,f,I,L,K,V. ⬇*[b, f] L ≘ K.ⓑ{I}V → ∀T. ♯{K, V} < ♯{L, T}.
+#b #f #I #L #K #V #HLK lapply (drops_fwd_lw … HLK) -HLK
+normalize in ⊢ (%→?→?%%); /3 width=3 by le_to_lt_to_lt, monotonic_lt_plus_r/
+qed-.
+
+(* Advanced inversion lemma *************************************************)
+
+lemma drops_inv_x_bind_xy: ∀b,f,I,L. ⬇*[b, f] L ≘ L.ⓘ{I} → ⊥.
+#b #f #I #L #H lapply (drops_fwd_lw … H) -b -f
+/2 width=4 by lt_le_false/ (**) (* full auto is a bit slow: 19s *)
 qed-.