combinatorics.set_family.compression.uvMathlib.Combinatorics.SetFamily.Compression.UV

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

feat(combinatorics/set_family/compression/uv): UV-compressing reduces the size of the shadow (#13149)

Prove (∂ (𝓒 u v 𝒜)).card ≤ (∂ 𝒜).card, which is key to Kruskal-Katona.

Co-authored-by: Bhavik Mehta <bhavik.mehta8@gmail.com>

Co-authored-by: Mauricio Collares <mauricio@collares.org> Co-authored-by: Eric Rodriguez <ericrboidi@gmail.com>

Diff
@@ -3,7 +3,8 @@ Copyright (c) 2021 Bhavik Mehta. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
 -/
-import data.finset.card
+import combinatorics.set_family.shadow
+import data.finset.sort
 
 /-!
 # UV-compressions
@@ -27,7 +28,9 @@ minimise the shadow.
   It is the compressions of the elements of `s` whose compression is not already in `s` along with
   the element whose compression is already in `s`. This way of splitting into what moves and what
   does not ensures the compression doesn't squash the set family, which is proved by
-  `uv.card_compress`.
+  `uv.card_compression`.
+* `uv.card_shadow_compression_le`: Compressing reduces the size of the shadow. This is a key fact in
+  the proof of Kruskal-Katona.
 
 ## Notation
 
@@ -38,11 +41,6 @@ minimise the shadow.
 Even though our emphasis is on `finset α`, we define UV-compressions more generally in a generalized
 boolean algebra, so that one can use it for `set α`.
 
-## TODO
-
-Prove that compressing reduces the size of shadow. This result and some more already exist on the
-branch `combinatorics`.
-
 ## References
 
 * https://github.com/b-mehta/maths-notes/blob/master/iii/mich/combinatorics.pdf
@@ -79,8 +77,9 @@ variables [generalized_boolean_algebra α] [decidable_rel (@disjoint α _ _)]
 
 local attribute [instance] decidable_eq_of_decidable_le
 
-/-- To UV-compress `a`, if it doesn't touch `U` and does contain `V`, we remove `V` and
-put `U` in. We'll only really use this when `|U| = |V|` and `U ∩ V = ∅`. -/
+/-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
+`v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
+anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
 def compress (u v a : α) : α := if disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 
 /-- To UV-compress a set family, we compress each of its elements, except that we don't want to
@@ -97,12 +96,20 @@ lemma compress_of_disjoint_of_le (hua : disjoint u a) (hva : v ≤ a) :
   compress u v a = (a ⊔ u) \ v :=
 if_pos ⟨hua, hva⟩
 
+lemma compress_of_disjoint_of_le' (hva : disjoint v a) (hua : u ≤ a) :
+  compress u v ((a ⊔ v) \ u) = a :=
+by rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
+  (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
+  sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
+
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
 lemma mem_compression :
   a ∈ 𝓒 u v s ↔ a ∈ s ∧ compress u v a ∈ s ∨ a ∉ s ∧ ∃ b ∈ s, compress u v b = a :=
 by simp_rw [compression, mem_union, mem_filter, mem_image, and_comm (a ∉ s)]
 
+protected lemma is_compressed.eq (h : is_compressed u v s) : 𝓒 u v s = s := h
+
 @[simp] lemma compress_self (u a : α) : compress u u a = a :=
 begin
   unfold compress,
@@ -126,6 +133,14 @@ end
 /-- Any family is compressed along two identical elements. -/
 lemma is_compressed_self (u : α) (s : finset α) : is_compressed u u s := compression_self u s
 
+/-- An element can be compressed to any other element by removing/adding the differences. -/
+@[simp] lemma compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
+begin
+  refine (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _,
+  rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right],
+  exact sdiff_sdiff_le,
+end
+
 lemma compress_disjoint (u v : α) :
   disjoint (s.filter (λ a, compress u v a ∈ s)) ((s.image $ compress u v).filter (λ a, a ∉ s)) :=
 disjoint_left.2 $ λ a ha₁ ha₂, (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
@@ -169,7 +184,7 @@ begin
 end
 
 /-- Compressing a family doesn't change its size. -/
-lemma card_compression (u v : α) (s : finset α) : (𝓒 u v s).card = s.card :=
+@[simp] lemma card_compression (u v : α) (s : finset α) : (𝓒 u v s).card = s.card :=
 begin
   rw [compression, card_disjoint_union (compress_disjoint _ _), image_filter, card_image_of_inj_on,
     ←card_disjoint_union, filter_union_filter_neg_eq],
@@ -187,6 +202,43 @@ begin
   { exact (ha.2 ha.1).elim }
 end
 
+lemma le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
+begin
+  rw mem_compression at h,
+  obtain _ | ⟨-, b, hb, hba⟩ := h,
+  { cases ha h.1 },
+  unfold compress at hba,
+  split_ifs at hba,
+  { rw [←hba, le_sdiff],
+    exact ⟨le_sup_right, h.1.mono_right h.2⟩ },
+  { cases ne_of_mem_of_not_mem hb ha hba }
+end
+
+lemma disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : disjoint v a :=
+begin
+  rw mem_compression at h,
+  obtain _ | ⟨-, b, hb, hba⟩ := h,
+  { cases ha h.1 },
+  unfold compress at hba,
+  split_ifs at hba,
+  { rw ←hba,
+    exact disjoint_sdiff_self_right },
+  { cases ne_of_mem_of_not_mem hb ha hba }
+end
+
+lemma sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
+  (a ⊔ v) \ u ∈ s :=
+begin
+  rw mem_compression at h,
+  obtain _ | ⟨-, b, hb, hba⟩ := h,
+  { cases ha h.1 },
+  unfold compress at hba,
+  split_ifs at hba,
+  { rwa [←hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
+      h.1.symm.sdiff_eq_left] },
+  { cases ne_of_mem_of_not_mem hb ha hba }
+end
+
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
 lemma sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : disjoint u a) :
@@ -219,8 +271,7 @@ begin
   unfold compress at h,
   split_ifs at h,
   { rw [←h, le_sdiff_iff] at hva,
-    rw [hvu hva, hva, sup_bot_eq, sdiff_bot] at h,
-    rwa ←h },
+    rwa [←h, hvu hva, hva, sup_bot_eq, sdiff_bot] },
   { rwa ←h }
 end
 
@@ -230,16 +281,132 @@ end generalized_boolean_algebra
 
 open_locale finset_family
 
-variables [decidable_eq α] {𝒜 : finset (finset α)} {U V A : finset α}
+variables [decidable_eq α] {𝒜 : finset (finset α)} {u v a : finset α}
 
 /-- Compressing a finset doesn't change its size. -/
-lemma card_compress (hUV : U.card = V.card) (A : finset α) : (compress U V A).card = A.card :=
+lemma card_compress (hUV : u.card = v.card) (A : finset α) : (compress u v A).card = A.card :=
 begin
   unfold compress,
   split_ifs,
   { rw [card_sdiff (h.2.trans le_sup_left), sup_eq_union, card_disjoint_union h.1.symm, hUV,
-    add_tsub_cancel_right] },
+      add_tsub_cancel_right] },
   { refl }
 end
 
+private lemma aux (huv : ∀ x ∈ u, ∃ y ∈ v, is_compressed (u.erase x) (v.erase y) 𝒜) :
+  v = ∅ → u = ∅ :=
+by { rintro rfl, refine eq_empty_of_forall_not_mem (λ a ha, _), obtain ⟨_, ⟨⟩, -⟩ := huv a ha }
+
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
+that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
+Kruskal-Katona. -/
+lemma shadow_compression_subset_compression_shadow (u v : finset α)
+  (huv : ∀ x ∈ u, ∃ y ∈ v, is_compressed (u.erase x) (v.erase y) 𝒜) :
+  ∂ (𝓒 u v 𝒜) ⊆ 𝓒 u v (∂ 𝒜) :=
+begin
+  set 𝒜' := 𝓒 u v 𝒜,
+  suffices H : ∀ s, s ∈ ∂ 𝒜' → s ∉ ∂ 𝒜 →
+    u ⊆ s ∧ disjoint v s ∧ (s ∪ v) \ u ∈ ∂ 𝒜 ∧ (s ∪ v) \ u ∉ ∂ 𝒜',
+  { rintro s hs',
+    rw mem_compression,
+    by_cases hs : s ∈ 𝒜.shadow, swap,
+    { obtain ⟨hus, hvs, h, _⟩ := H _ hs' hs,
+      exact or.inr ⟨hs, _, h, compress_of_disjoint_of_le' hvs hus⟩ },
+    refine or.inl ⟨hs, _⟩,
+    rw compress,
+    split_ifs with huvs, swap,
+    { exact hs },
+    rw mem_shadow_iff at hs',
+    obtain ⟨t, Ht, a, hat, rfl⟩ := hs',
+    have hav : a ∉ v := not_mem_mono huvs.2 (not_mem_erase a t),
+    have hvt : v ≤ t := huvs.2.trans (erase_subset _ t),
+    have ht : t ∈ 𝒜 := mem_of_mem_compression Ht hvt (aux huv),
+    by_cases hau : a ∈ u,
+    { obtain ⟨b, hbv, Hcomp⟩ := huv a hau,
+      refine mem_shadow_iff_insert_mem.2 ⟨b, not_mem_sdiff_of_mem_right hbv, _⟩,
+      rw ←Hcomp.eq at ht,
+      have hsb := sup_sdiff_mem_of_mem_compression ht ((erase_subset _ _).trans hvt)
+        (disjoint_erase_comm.2 huvs.1),
+      rwa [sup_eq_union, sdiff_erase (mem_union_left _ $ hvt hbv), union_erase_of_mem hat,
+        ←erase_union_of_mem hau] at hsb },
+    { refine mem_shadow_iff.2 ⟨(t ⊔ u) \ v, sup_sdiff_mem_of_mem_compression Ht hvt $
+        disjoint_of_erase_right hau huvs.1, a, _, _⟩,
+      { rw [sup_eq_union, mem_sdiff, mem_union],
+        exact ⟨or.inl hat, hav⟩ },
+      { rw [←erase_sdiff_comm, sup_eq_union, erase_union_distrib, erase_eq_of_not_mem hau] } } },
+  intros s hs𝒜' hs𝒜,
+  -- This is gonna be useful a couple of times so let's name it.
+  have m : ∀ y ∉ s, insert y s ∉ 𝒜 := λ y h a, hs𝒜 (mem_shadow_iff_insert_mem.2 ⟨y, h, a⟩),
+  obtain ⟨x, _, _⟩ := mem_shadow_iff_insert_mem.1 hs𝒜',
+  have hus : u ⊆ insert x s := le_of_mem_compression_of_not_mem ‹_ ∈ 𝒜'› (m _ ‹x ∉ s›),
+  have hvs : disjoint v (insert x s) := disjoint_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›),
+  have : (insert x s ∪ v) \ u ∈ 𝒜 := sup_sdiff_mem_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›),
+  have hsv : disjoint s v := hvs.symm.mono_left (subset_insert _ _),
+  have hvu : disjoint v u := disjoint_of_subset_right hus hvs,
+  have hxv : x ∉ v := disjoint_right.1 hvs (mem_insert_self _ _),
+  have : v \ u = v := ‹disjoint v u›.sdiff_eq_left,
+  -- The first key part is that `x ∉ u`
+  have : x ∉ u,
+  { intro hxu,
+    obtain ⟨y, hyv, hxy⟩ := huv x hxu,
+    -- If `x ∈ u`, we can get `y ∈ v` so that `𝒜` is `(u.erase x, v.erase y)`-compressed
+    apply m y (disjoint_right.1 hsv hyv),
+    -- and we will use this `y` to contradict `m`, so we would like to show `insert y s ∈ 𝒜`.
+    -- We do this by showing the below
+    have : ((insert x s ∪ v) \ u ∪ erase u x) \ erase v y ∈ 𝒜,
+    { refine sup_sdiff_mem_of_mem_compression (by rwa hxy.eq) _
+        (disjoint_of_subset_left (erase_subset _ _) disjoint_sdiff),
+      rw [union_sdiff_distrib, ‹v \ u = v›],
+      exact (erase_subset _ _).trans (subset_union_right _ _) },
+    -- and then arguing that it's the same
+    convert this,
+    rw [sdiff_union_erase_cancel (hus.trans $ subset_union_left _ _) ‹x ∈ u›, erase_union_distrib,
+      erase_insert ‹x ∉ s›, erase_eq_of_not_mem ‹x ∉ v›, sdiff_erase (mem_union_right _ hyv),
+      union_sdiff_cancel_right hsv] },
+  -- Now that this is done, it's immediate that `u ⊆ s`
+  have hus : u ⊆ s,
+  { rwa [←erase_eq_of_not_mem ‹x ∉ u›, ←subset_insert_iff] },
+  -- and we already had that `v` and `s` are disjoint,
+  -- so it only remains to get `(s ∪ v) \ u ∈ ∂ 𝒜 \ ∂ 𝒜'`
+  simp_rw [mem_shadow_iff_insert_mem],
+  refine ⟨hus, hsv.symm, ⟨x, _, _⟩, _⟩,
+  -- `(s ∪ v) \ u ∈ ∂ 𝒜` is pretty direct:
+  { exact not_mem_sdiff_of_not_mem_left (not_mem_union.2 ⟨‹x ∉ s›, ‹x ∉ v›⟩) },
+  { rwa [←insert_sdiff_of_not_mem _ ‹x ∉ u›, ←insert_union] },
+  -- For (s ∪ v) \ u ∉ ∂ 𝒜', we split up based on w ∈ u
+  rintro ⟨w, hwB, hw𝒜'⟩,
+  have : v ⊆ insert w ((s ∪ v) \ u) := (subset_sdiff.2 ⟨subset_union_right _ _, hvu⟩).trans
+    (subset_insert _ _),
+  by_cases hwu : w ∈ u,
+    -- If `w ∈ u`, we find `z ∈ v`, and contradict `m` again
+  { obtain ⟨z, hz, hxy⟩ := huv w hwu,
+    apply m z (disjoint_right.1 hsv hz),
+    have : insert w ((s ∪ v) \ u) ∈ 𝒜 := mem_of_mem_compression hw𝒜' ‹_› (aux huv),
+    have : (insert w ((s ∪ v) \ u) ∪ erase u w) \ erase v z ∈ 𝒜,
+    { refine sup_sdiff_mem_of_mem_compression (by rwa hxy.eq) ((erase_subset _ _).trans ‹_›) _,
+      rw ←sdiff_erase (mem_union_left _ $ hus hwu),
+      exact disjoint_sdiff },
+    convert this,
+    rw [insert_union_comm, insert_erase ‹w ∈ u›, sdiff_union_of_subset
+      (hus.trans $ subset_union_left _ _), sdiff_erase (mem_union_right _ ‹z ∈ v›),
+      union_sdiff_cancel_right hsv] },
+  -- If `w ∉ u`, we contradict `m` again
+  rw [mem_sdiff, ←not_imp, not_not] at hwB,
+  apply m w (hwu ∘ hwB ∘ mem_union_left _),
+  have : (insert w ((s ∪ v) \ u) ∪ u) \ v ∈ 𝒜 := sup_sdiff_mem_of_mem_compression
+    ‹insert w ((s ∪ v) \ u) ∈ 𝒜'› ‹_› (disjoint_insert_right.2 ⟨‹_›, disjoint_sdiff⟩),
+  convert this,
+  rw [insert_union, sdiff_union_of_subset (hus.trans $ subset_union_left _ _),
+    insert_sdiff_of_not_mem _ (hwu ∘ hwB ∘ mem_union_right _), union_sdiff_cancel_right hsv],
+end
+
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v`
+such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-compression fact needed for
+Kruskal-Katona. -/
+lemma card_shadow_compression_le (u v : finset α)
+  (huv : ∀ x ∈ u, ∃ y ∈ v, is_compressed (u.erase x) (v.erase y) 𝒜) :
+  (∂ (𝓒 u v 𝒜)).card ≤ (∂ 𝒜).card :=
+(card_le_of_subset $ shadow_compression_subset_compression_shadow _ _ huv).trans
+  (card_compression _ _ _).le
+
 end uv

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(first ported)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -132,7 +132,7 @@ theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
 original, or it's not in the original but it's the compression of something in the original. -/
 theorem mem_compression :
     a ∈ 𝓒 u v s ↔ a ∈ s ∧ compress u v a ∈ s ∨ a ∉ s ∧ ∃ b ∈ s, compress u v b = a := by
-  simp_rw [compression, mem_union, mem_filter, mem_image, and_comm' (a ∉ s)]
+  simp_rw [compression, mem_union, mem_filter, mem_image, and_comm (a ∉ s)]
 #align uv.mem_compression UV.mem_compression
 -/
 
Diff
@@ -373,7 +373,7 @@ private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x)
     v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
-/- ./././Mathport/Syntax/Translate/Basic.lean:641:2: warning: expanding binder collection (y «expr ∉ » s) -/
+/- ./././Mathport/Syntax/Translate/Basic.lean:642:2: warning: expanding binder collection (y «expr ∉ » s) -/
 #print UV.shadow_compression_subset_compression_shadow /-
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
Diff
@@ -65,10 +65,10 @@ theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
   rintro a ha b hb hab
   have h : ((a ⊔ u) \ v) \ u ⊔ v = ((b ⊔ u) \ v) \ u ⊔ v :=
     by
-    dsimp at hab 
+    dsimp at hab
     rw [hab]
   rwa [sdiff_sdiff_comm, ha.1.symm.sup_sdiff_cancel_right, sdiff_sdiff_comm,
-    hb.1.symm.sup_sdiff_cancel_right, sdiff_sup_cancel ha.2, sdiff_sup_cancel hb.2] at h 
+    hb.1.symm.sup_sdiff_cancel_right, sdiff_sup_cancel ha.2, sdiff_sup_cancel hb.2] at h
 #align sup_sdiff_inj_on sup_sdiff_injOn
 -/
 
@@ -162,7 +162,7 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
   · ext a
     rw [mem_filter, compress_self, and_self_iff]
   · refine' eq_empty_of_forall_not_mem fun a ha => _
-    simp_rw [mem_filter, mem_image, compress_self] at ha 
+    simp_rw [mem_filter, mem_image, compress_self] at ha
     obtain ⟨⟨b, hb, rfl⟩, hb'⟩ := ha
     exact hb' hb
 #align uv.compression_self UV.compression_self
@@ -252,12 +252,12 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   · rw [disjoint_iff_inter_eq_empty]
     exact filter_inter_filter_neg_eq _ _ _
   intro a ha b hb hab
-  dsimp at hab 
-  rw [mem_coe, mem_filter, Function.comp_apply] at ha hb 
-  rw [compress] at ha hab 
-  split_ifs at ha hab  with has
-  · rw [compress] at hb hab 
-    split_ifs at hb hab  with hbs
+  dsimp at hab
+  rw [mem_coe, mem_filter, Function.comp_apply] at ha hb
+  rw [compress] at ha hab
+  split_ifs at ha hab with has
+  · rw [compress] at hb hab
+    split_ifs at hb hab with hbs
     · exact sup_sdiff_injOn u v has hbs hab
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
@@ -267,11 +267,11 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 #print UV.le_of_mem_compression_of_not_mem /-
 theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
   by
-  rw [mem_compression] at h 
+  rw [mem_compression] at h
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba 
-  split_ifs at hba 
+  unfold compress at hba
+  split_ifs at hba
   · rw [← hba, le_sdiff]
     exact ⟨le_sup_right, h.1.mono_right h.2⟩
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -281,11 +281,11 @@ theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
 #print UV.disjoint_of_mem_compression_of_not_mem /-
 theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : Disjoint v a :=
   by
-  rw [mem_compression] at h 
+  rw [mem_compression] at h
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba 
-  split_ifs at hba 
+  unfold compress at hba
+  split_ifs at hba
   · rw [← hba]
     exact disjoint_sdiff_self_right
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -295,11 +295,11 @@ theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a 
 #print UV.sup_sdiff_mem_of_mem_compression_of_not_mem /-
 theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
     (a ⊔ v) \ u ∈ s := by
-  rw [mem_compression] at h 
+  rw [mem_compression] at h
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba 
-  split_ifs at hba 
+  unfold compress at hba
+  split_ifs at hba
   ·
     rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
       h.1.symm.sdiff_eq_left]
@@ -313,12 +313,12 @@ original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : Disjoint u a) :
     (a ⊔ u) \ v ∈ s :=
   by
-  rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha 
+  rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact ha
   have hu : u = ⊥ :=
     by
-    suffices Disjoint u (u \ v) by rwa [(hua.mono_right hva).sdiff_eq_left, disjoint_self] at this 
+    suffices Disjoint u (u \ v) by rwa [(hua.mono_right hva).sdiff_eq_left, disjoint_self] at this
     refine' hua.mono_right _
     rw [← compress_idem, compress_of_disjoint_of_le hua hva]
     exact sdiff_le_sdiff_right le_sup_right
@@ -336,12 +336,12 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 family. -/
 theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v = ⊥ → u = ⊥) : a ∈ s :=
   by
-  rw [mem_compression] at ha 
+  rw [mem_compression] at ha
   obtain ha | ⟨_, b, hb, h⟩ := ha
   · exact ha.1
-  unfold compress at h 
-  split_ifs at h 
-  · rw [← h, le_sdiff_iff] at hva 
+  unfold compress at h
+  split_ifs at h
+  · rw [← h, le_sdiff_iff] at hva
     rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
 #align uv.mem_of_mem_compression UV.mem_of_mem_compression
@@ -394,7 +394,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     rw [compress]
     split_ifs with huvs; swap
     · exact hs
-    rw [mem_shadow_iff] at hs' 
+    rw [mem_shadow_iff] at hs'
     obtain ⟨t, Ht, a, hat, rfl⟩ := hs'
     have hav : a ∉ v := not_mem_mono huvs.2 (not_mem_erase a t)
     have hvt : v ≤ t := huvs.2.trans (erase_subset _ t)
@@ -402,12 +402,12 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     by_cases hau : a ∈ u
     · obtain ⟨b, hbv, Hcomp⟩ := huv a hau
       refine' mem_shadow_iff_insert_mem.2 ⟨b, not_mem_sdiff_of_mem_right hbv, _⟩
-      rw [← Hcomp.eq] at ht 
+      rw [← Hcomp.eq] at ht
       have hsb :=
         sup_sdiff_mem_of_mem_compression ht ((erase_subset _ _).trans hvt)
           (disjoint_erase_comm.2 huvs.1)
       rwa [sup_eq_union, sdiff_erase (mem_union_left _ <| hvt hbv), union_erase_of_mem hat, ←
-        erase_union_of_mem hau] at hsb 
+        erase_union_of_mem hau] at hsb
     · refine'
         mem_shadow_iff.2
           ⟨(t ⊔ u) \ v,
@@ -475,7 +475,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
       sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
       sdiff_erase (mem_union_right _ ‹z ∈ v›), union_sdiff_cancel_right hsv]
   -- If `w ∉ u`, we contradict `m` again
-  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB 
+  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB
   apply m w (hwu ∘ hwB ∘ mem_union_left _)
   have : (insert w ((s ∪ v) \ u) ∪ u) \ v ∈ 𝒜 :=
     sup_sdiff_mem_of_mem_compression ‹insert w ((s ∪ v) \ u) ∈ 𝒜'› ‹_›
Diff
@@ -493,7 +493,7 @@ Kruskal-Katona. -/
 theorem card_shadow_compression_le (u v : Finset α)
     (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
     ((∂ ) (𝓒 u v 𝒜)).card ≤ ((∂ ) 𝒜).card :=
-  (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
+  (card_le_card <| shadow_compression_subset_compression_shadow _ _ huv).trans
     (card_compression _ _ _).le
 #align uv.card_shadow_compression_le UV.card_shadow_compression_le
 -/
Diff
@@ -168,11 +168,11 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
 #align uv.compression_self UV.compression_self
 -/
 
-#print UV.is_compressed_self /-
+#print UV.isCompressed_self /-
 /-- Any family is compressed along two identical elements. -/
-theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
+theorem isCompressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
-#align uv.is_compressed_self UV.is_compressed_self
+#align uv.is_compressed_self UV.isCompressed_self
 -/
 
 #print UV.compress_sdiff_sdiff /-
Diff
@@ -3,8 +3,8 @@ Copyright (c) 2021 Bhavik Mehta. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
 -/
-import Mathbin.Combinatorics.SetFamily.Shadow
-import Mathbin.Data.Finset.Sort
+import Combinatorics.SetFamily.Shadow
+import Data.Finset.Sort
 
 #align_import combinatorics.set_family.compression.uv from "leanprover-community/mathlib"@"6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1"
 
@@ -373,7 +373,7 @@ private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x)
     v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
-/- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
+/- ./././Mathport/Syntax/Translate/Basic.lean:641:2: warning: expanding binder collection (y «expr ∉ » s) -/
 #print UV.shadow_compression_subset_compression_shadow /-
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
Diff
@@ -2,15 +2,12 @@
 Copyright (c) 2021 Bhavik Mehta. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
-
-! This file was ported from Lean 3 source module combinatorics.set_family.compression.uv
-! leanprover-community/mathlib commit 6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Combinatorics.SetFamily.Shadow
 import Mathbin.Data.Finset.Sort
 
+#align_import combinatorics.set_family.compression.uv from "leanprover-community/mathlib"@"6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1"
+
 /-!
 # UV-compressions
 
@@ -376,7 +373,7 @@ private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x)
     v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
-/- ./././Mathport/Syntax/Translate/Basic.lean:638:2: warning: expanding binder collection (y «expr ∉ » s) -/
+/- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
 #print UV.shadow_compression_subset_compression_shadow /-
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
Diff
@@ -60,6 +60,7 @@ open Finset
 
 variable {α : Type _}
 
+#print sup_sdiff_injOn /-
 /-- UV-compression is injective on the elements it moves. See `uv.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
     {x | Disjoint u x ∧ v ≤ x}.InjOn fun x => (x ⊔ u) \ v :=
@@ -72,6 +73,7 @@ theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
   rwa [sdiff_sdiff_comm, ha.1.symm.sup_sdiff_cancel_right, sdiff_sdiff_comm,
     hb.1.symm.sup_sdiff_cancel_right, sdiff_sup_cancel ha.2, sdiff_sup_cancel hb.2] at h 
 #align sup_sdiff_inj_on sup_sdiff_injOn
+-/
 
 -- The namespace is here to distinguish from other compressions.
 namespace Uv
@@ -103,7 +105,6 @@ def compression (u v : α) (s : Finset α) :=
 #align uv.compression UV.compression
 -/
 
--- mathport name: uv.compression
 scoped[FinsetFamily] notation "𝓒 " => UV.compression
 
 #print UV.IsCompressed /-
@@ -113,24 +114,30 @@ def IsCompressed (u v : α) (s : Finset α) :=
 #align uv.is_compressed UV.IsCompressed
 -/
 
+#print UV.compress_of_disjoint_of_le /-
 theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
     compress u v a = (a ⊔ u) \ v :=
   if_pos ⟨hua, hva⟩
 #align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_le
+-/
 
+#print UV.compress_of_disjoint_of_le' /-
 theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
     compress u v ((a ⊔ v) \ u) = a := by
   rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
       (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
     sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
 #align uv.compress_of_disjoint_of_le' UV.compress_of_disjoint_of_le'
+-/
 
+#print UV.mem_compression /-
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
 theorem mem_compression :
     a ∈ 𝓒 u v s ↔ a ∈ s ∧ compress u v a ∈ s ∨ a ∉ s ∧ ∃ b ∈ s, compress u v b = a := by
   simp_rw [compression, mem_union, mem_filter, mem_image, and_comm' (a ∉ s)]
 #align uv.mem_compression UV.mem_compression
+-/
 
 #print UV.IsCompressed.eq /-
 protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s :=
@@ -171,6 +178,7 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
 #align uv.is_compressed_self UV.is_compressed_self
 -/
 
+#print UV.compress_sdiff_sdiff /-
 /-- An element can be compressed to any other element by removing/adding the differences. -/
 @[simp]
 theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
@@ -179,12 +187,15 @@ theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
   rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
   exact sdiff_sdiff_le
 #align uv.compress_sdiff_sdiff UV.compress_sdiff_sdiff
+-/
 
+#print UV.compress_disjoint /-
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
       ((s.image <| compress u v).filterₓ fun a => a ∉ s) :=
   disjoint_left.2 fun a ha₁ ha₂ => (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
 #align uv.compress_disjoint UV.compress_disjoint
+-/
 
 #print UV.compress_idem /-
 /-- Compressing an element is idempotent. -/
@@ -284,6 +295,7 @@ theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a 
 #align uv.disjoint_of_mem_compression_of_not_mem UV.disjoint_of_mem_compression_of_not_mem
 -/
 
+#print UV.sup_sdiff_mem_of_mem_compression_of_not_mem /-
 theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
     (a ⊔ v) \ u ∈ s := by
   rw [mem_compression] at h 
@@ -296,7 +308,9 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
       h.1.symm.sdiff_eq_left]
   · cases ne_of_mem_of_not_mem hb ha hba
 #align uv.sup_sdiff_mem_of_mem_compression_of_not_mem UV.sup_sdiff_mem_of_mem_compression_of_not_mem
+-/
 
+#print UV.sup_sdiff_mem_of_mem_compression /-
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : Disjoint u a) :
@@ -318,7 +332,9 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
     exact disjoint_sdiff_self_right
   rwa [hu, hv, compress_self, sup_bot_eq, sdiff_bot]
 #align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compression
+-/
 
+#print UV.mem_of_mem_compression /-
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
 theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v = ⊥ → u = ⊥) : a ∈ s :=
@@ -332,6 +348,7 @@ theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v
     rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
 #align uv.mem_of_mem_compression UV.mem_of_mem_compression
+-/
 
 end GeneralizedBooleanAlgebra
 
@@ -342,6 +359,7 @@ open scoped FinsetFamily
 
 variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
 
+#print UV.card_compress /-
 /-- Compressing a finset doesn't change its size. -/
 theorem card_compress (hUV : u.card = v.card) (A : Finset α) : (compress u v A).card = A.card :=
   by
@@ -352,12 +370,14 @@ theorem card_compress (hUV : u.card = v.card) (A : Finset α) : (compress u v A)
       add_tsub_cancel_right]
   · rfl
 #align uv.card_compress UV.card_compress
+-/
 
 private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
     v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
 /- ./././Mathport/Syntax/Translate/Basic.lean:638:2: warning: expanding binder collection (y «expr ∉ » s) -/
+#print UV.shadow_compression_subset_compression_shadow /-
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
 Kruskal-Katona. -/
@@ -467,7 +487,9 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
   rw [insert_union, sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
     insert_sdiff_of_not_mem _ (hwu ∘ hwB ∘ mem_union_right _), union_sdiff_cancel_right hsv]
 #align uv.shadow_compression_subset_compression_shadow UV.shadow_compression_subset_compression_shadow
+-/
 
+#print UV.card_shadow_compression_le /-
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v`
 such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-compression fact needed for
 Kruskal-Katona. -/
@@ -477,6 +499,7 @@ theorem card_shadow_compression_le (u v : Finset α)
   (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
     (card_compression _ _ _).le
 #align uv.card_shadow_compression_le UV.card_shadow_compression_le
+-/
 
 end Uv
 
Diff
@@ -357,7 +357,7 @@ private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x)
     v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
-/- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
+/- ./././Mathport/Syntax/Translate/Basic.lean:638:2: warning: expanding binder collection (y «expr ∉ » s) -/
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
 Kruskal-Katona. -/
Diff
@@ -123,7 +123,7 @@ theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
   rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
       (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
     sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
-#align uv.compress_of_disjoint_of_le' Uv.compress_of_disjoint_of_le'
+#align uv.compress_of_disjoint_of_le' UV.compress_of_disjoint_of_le'
 
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
@@ -132,9 +132,11 @@ theorem mem_compression :
   simp_rw [compression, mem_union, mem_filter, mem_image, and_comm' (a ∉ s)]
 #align uv.mem_compression UV.mem_compression
 
+#print UV.IsCompressed.eq /-
 protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s :=
   h
 #align uv.is_compressed.eq UV.IsCompressed.eq
+-/
 
 #print UV.compress_self /-
 @[simp]
@@ -176,7 +178,7 @@ theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
   refine' (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _
   rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
   exact sdiff_sdiff_le
-#align uv.compress_sdiff_sdiff Uv.compress_sdiff_sdiff
+#align uv.compress_sdiff_sdiff UV.compress_sdiff_sdiff
 
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
@@ -254,6 +256,7 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 #align uv.card_compression UV.card_compression
 -/
 
+#print UV.le_of_mem_compression_of_not_mem /-
 theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
   by
   rw [mem_compression] at h 
@@ -264,8 +267,10 @@ theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
   · rw [← hba, le_sdiff]
     exact ⟨le_sup_right, h.1.mono_right h.2⟩
   · cases ne_of_mem_of_not_mem hb ha hba
-#align uv.le_of_mem_compression_of_not_mem Uv.le_of_mem_compression_of_not_mem
+#align uv.le_of_mem_compression_of_not_mem UV.le_of_mem_compression_of_not_mem
+-/
 
+#print UV.disjoint_of_mem_compression_of_not_mem /-
 theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : Disjoint v a :=
   by
   rw [mem_compression] at h 
@@ -276,7 +281,8 @@ theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a 
   · rw [← hba]
     exact disjoint_sdiff_self_right
   · cases ne_of_mem_of_not_mem hb ha hba
-#align uv.disjoint_of_mem_compression_of_not_mem Uv.disjoint_of_mem_compression_of_not_mem
+#align uv.disjoint_of_mem_compression_of_not_mem UV.disjoint_of_mem_compression_of_not_mem
+-/
 
 theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
     (a ⊔ v) \ u ∈ s := by
@@ -289,7 +295,7 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
     rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
       h.1.symm.sdiff_eq_left]
   · cases ne_of_mem_of_not_mem hb ha hba
-#align uv.sup_sdiff_mem_of_mem_compression_of_not_mem Uv.sup_sdiff_mem_of_mem_compression_of_not_mem
+#align uv.sup_sdiff_mem_of_mem_compression_of_not_mem UV.sup_sdiff_mem_of_mem_compression_of_not_mem
 
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
@@ -460,7 +466,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
   convert this
   rw [insert_union, sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
     insert_sdiff_of_not_mem _ (hwu ∘ hwB ∘ mem_union_right _), union_sdiff_cancel_right hsv]
-#align uv.shadow_compression_subset_compression_shadow Uv.shadow_compression_subset_compression_shadow
+#align uv.shadow_compression_subset_compression_shadow UV.shadow_compression_subset_compression_shadow
 
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v`
 such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-compression fact needed for
@@ -470,7 +476,7 @@ theorem card_shadow_compression_le (u v : Finset α)
     ((∂ ) (𝓒 u v 𝒜)).card ≤ ((∂ ) 𝒜).card :=
   (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
     (card_compression _ _ _).le
-#align uv.card_shadow_compression_le Uv.card_shadow_compression_le
+#align uv.card_shadow_compression_le UV.card_shadow_compression_le
 
 end Uv
 
Diff
@@ -62,7 +62,7 @@ variable {α : Type _}
 
 /-- UV-compression is injective on the elements it moves. See `uv.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
-    { x | Disjoint u x ∧ v ≤ x }.InjOn fun x => (x ⊔ u) \ v :=
+    {x | Disjoint u x ∧ v ≤ x}.InjOn fun x => (x ⊔ u) \ v :=
   by
   rintro a ha b hb hab
   have h : ((a ⊔ u) \ v) \ u ⊔ v = ((b ⊔ u) \ v) \ u ⊔ v :=
@@ -245,9 +245,9 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   dsimp at hab 
   rw [mem_coe, mem_filter, Function.comp_apply] at ha hb 
   rw [compress] at ha hab 
-  split_ifs  at ha hab  with has
+  split_ifs at ha hab  with has
   · rw [compress] at hb hab 
-    split_ifs  at hb hab  with hbs
+    split_ifs at hb hab  with hbs
     · exact sup_sdiff_injOn u v has hbs hab
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
@@ -260,7 +260,7 @@ theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
   unfold compress at hba 
-  split_ifs  at hba 
+  split_ifs at hba 
   · rw [← hba, le_sdiff]
     exact ⟨le_sup_right, h.1.mono_right h.2⟩
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -272,7 +272,7 @@ theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a 
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
   unfold compress at hba 
-  split_ifs  at hba 
+  split_ifs at hba 
   · rw [← hba]
     exact disjoint_sdiff_self_right
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -284,7 +284,7 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
   unfold compress at hba 
-  split_ifs  at hba 
+  split_ifs at hba 
   ·
     rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
       h.1.symm.sdiff_eq_left]
@@ -321,7 +321,7 @@ theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v
   obtain ha | ⟨_, b, hb, h⟩ := ha
   · exact ha.1
   unfold compress at h 
-  split_ifs  at h 
+  split_ifs at h 
   · rw [← h, le_sdiff_iff] at hva 
     rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
Diff
@@ -67,10 +67,10 @@ theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
   rintro a ha b hb hab
   have h : ((a ⊔ u) \ v) \ u ⊔ v = ((b ⊔ u) \ v) \ u ⊔ v :=
     by
-    dsimp at hab
+    dsimp at hab 
     rw [hab]
   rwa [sdiff_sdiff_comm, ha.1.symm.sup_sdiff_cancel_right, sdiff_sdiff_comm,
-    hb.1.symm.sup_sdiff_cancel_right, sdiff_sup_cancel ha.2, sdiff_sup_cancel hb.2] at h
+    hb.1.symm.sup_sdiff_cancel_right, sdiff_sup_cancel ha.2, sdiff_sup_cancel hb.2] at h 
 #align sup_sdiff_inj_on sup_sdiff_injOn
 
 -- The namespace is here to distinguish from other compressions.
@@ -156,7 +156,7 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
   · ext a
     rw [mem_filter, compress_self, and_self_iff]
   · refine' eq_empty_of_forall_not_mem fun a ha => _
-    simp_rw [mem_filter, mem_image, compress_self] at ha
+    simp_rw [mem_filter, mem_image, compress_self] at ha 
     obtain ⟨⟨b, hb, rfl⟩, hb'⟩ := ha
     exact hb' hb
 #align uv.compression_self UV.compression_self
@@ -212,7 +212,7 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : compress u v a ∈ 𝓒 u v s :=
   by
-  rw [mem_compression] at ha⊢
+  rw [mem_compression] at ha ⊢
   simp only [compress_idem, exists_prop]
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact Or.inl ⟨ha, ha⟩
@@ -242,12 +242,12 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   · rw [disjoint_iff_inter_eq_empty]
     exact filter_inter_filter_neg_eq _ _ _
   intro a ha b hb hab
-  dsimp at hab
-  rw [mem_coe, mem_filter, Function.comp_apply] at ha hb
-  rw [compress] at ha hab
-  split_ifs  at ha hab with has
-  · rw [compress] at hb hab
-    split_ifs  at hb hab with hbs
+  dsimp at hab 
+  rw [mem_coe, mem_filter, Function.comp_apply] at ha hb 
+  rw [compress] at ha hab 
+  split_ifs  at ha hab  with has
+  · rw [compress] at hb hab 
+    split_ifs  at hb hab  with hbs
     · exact sup_sdiff_injOn u v has hbs hab
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
@@ -256,11 +256,11 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 
 theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
   by
-  rw [mem_compression] at h
+  rw [mem_compression] at h 
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba
-  split_ifs  at hba
+  unfold compress at hba 
+  split_ifs  at hba 
   · rw [← hba, le_sdiff]
     exact ⟨le_sup_right, h.1.mono_right h.2⟩
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -268,11 +268,11 @@ theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
 
 theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : Disjoint v a :=
   by
-  rw [mem_compression] at h
+  rw [mem_compression] at h 
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba
-  split_ifs  at hba
+  unfold compress at hba 
+  split_ifs  at hba 
   · rw [← hba]
     exact disjoint_sdiff_self_right
   · cases ne_of_mem_of_not_mem hb ha hba
@@ -280,11 +280,11 @@ theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a 
 
 theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
     (a ⊔ v) \ u ∈ s := by
-  rw [mem_compression] at h
+  rw [mem_compression] at h 
   obtain _ | ⟨-, b, hb, hba⟩ := h
   · cases ha h.1
-  unfold compress at hba
-  split_ifs  at hba
+  unfold compress at hba 
+  split_ifs  at hba 
   ·
     rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
       h.1.symm.sdiff_eq_left]
@@ -296,12 +296,12 @@ original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : Disjoint u a) :
     (a ⊔ u) \ v ∈ s :=
   by
-  rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha
+  rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha 
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact ha
   have hu : u = ⊥ :=
     by
-    suffices Disjoint u (u \ v) by rwa [(hua.mono_right hva).sdiff_eq_left, disjoint_self] at this
+    suffices Disjoint u (u \ v) by rwa [(hua.mono_right hva).sdiff_eq_left, disjoint_self] at this 
     refine' hua.mono_right _
     rw [← compress_idem, compress_of_disjoint_of_le hua hva]
     exact sdiff_le_sdiff_right le_sup_right
@@ -317,12 +317,12 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 family. -/
 theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v = ⊥ → u = ⊥) : a ∈ s :=
   by
-  rw [mem_compression] at ha
+  rw [mem_compression] at ha 
   obtain ha | ⟨_, b, hb, h⟩ := ha
   · exact ha.1
-  unfold compress at h
-  split_ifs  at h
-  · rw [← h, le_sdiff_iff] at hva
+  unfold compress at h 
+  split_ifs  at h 
+  · rw [← h, le_sdiff_iff] at hva 
     rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
 #align uv.mem_of_mem_compression UV.mem_of_mem_compression
@@ -371,7 +371,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     rw [compress]
     split_ifs with huvs; swap
     · exact hs
-    rw [mem_shadow_iff] at hs'
+    rw [mem_shadow_iff] at hs' 
     obtain ⟨t, Ht, a, hat, rfl⟩ := hs'
     have hav : a ∉ v := not_mem_mono huvs.2 (not_mem_erase a t)
     have hvt : v ≤ t := huvs.2.trans (erase_subset _ t)
@@ -379,12 +379,12 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     by_cases hau : a ∈ u
     · obtain ⟨b, hbv, Hcomp⟩ := huv a hau
       refine' mem_shadow_iff_insert_mem.2 ⟨b, not_mem_sdiff_of_mem_right hbv, _⟩
-      rw [← Hcomp.eq] at ht
+      rw [← Hcomp.eq] at ht 
       have hsb :=
         sup_sdiff_mem_of_mem_compression ht ((erase_subset _ _).trans hvt)
           (disjoint_erase_comm.2 huvs.1)
       rwa [sup_eq_union, sdiff_erase (mem_union_left _ <| hvt hbv), union_erase_of_mem hat, ←
-        erase_union_of_mem hau] at hsb
+        erase_union_of_mem hau] at hsb 
     · refine'
         mem_shadow_iff.2
           ⟨(t ⊔ u) \ v,
@@ -452,7 +452,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
       sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
       sdiff_erase (mem_union_right _ ‹z ∈ v›), union_sdiff_cancel_right hsv]
   -- If `w ∉ u`, we contradict `m` again
-  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB
+  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB 
   apply m w (hwu ∘ hwB ∘ mem_union_left _)
   have : (insert w ((s ∪ v) \ u) ∪ u) \ v ∈ 𝒜 :=
     sup_sdiff_mem_of_mem_compression ‹insert w ((s ∪ v) \ u) ∈ 𝒜'› ‹_›
Diff
@@ -86,26 +86,32 @@ variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
 
 attribute [local instance] decidableEqOfDecidableLE
 
+#print UV.compress /-
 /-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
 `v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
 anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
 def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
+-/
 
+#print UV.compression /-
 /-- To UV-compress a set family, we compress each of its elements, except that we don't want to
 reduce the cardinality, so we keep all elements whose compression is already present. -/
 def compression (u v : α) (s : Finset α) :=
   (s.filterₓ fun a => compress u v a ∈ s) ∪ (s.image <| compress u v).filterₓ fun a => a ∉ s
 #align uv.compression UV.compression
+-/
 
 -- mathport name: uv.compression
 scoped[FinsetFamily] notation "𝓒 " => UV.compression
 
+#print UV.IsCompressed /-
 /-- `is_compressed u v s` expresses that `s` is UV-compressed. -/
 def IsCompressed (u v : α) (s : Finset α) :=
   𝓒 u v s = s
 #align uv.is_compressed UV.IsCompressed
+-/
 
 theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
     compress u v a = (a ⊔ u) \ v :=
@@ -130,6 +136,7 @@ protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s :=
   h
 #align uv.is_compressed.eq UV.IsCompressed.eq
 
+#print UV.compress_self /-
 @[simp]
 theorem compress_self (u a : α) : compress u u a = a :=
   by
@@ -138,7 +145,9 @@ theorem compress_self (u a : α) : compress u u a = a :=
   · exact h.1.symm.sup_sdiff_cancel_right
   · rfl
 #align uv.compress_self UV.compress_self
+-/
 
+#print UV.compression_self /-
 @[simp]
 theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
   by
@@ -151,11 +160,14 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
     obtain ⟨⟨b, hb, rfl⟩, hb'⟩ := ha
     exact hb' hb
 #align uv.compression_self UV.compression_self
+-/
 
+#print UV.is_compressed_self /-
 /-- Any family is compressed along two identical elements. -/
 theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
 #align uv.is_compressed_self UV.is_compressed_self
+-/
 
 /-- An element can be compressed to any other element by removing/adding the differences. -/
 @[simp]
@@ -172,6 +184,7 @@ theorem compress_disjoint (u v : α) :
   disjoint_left.2 fun a ha₁ ha₂ => (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
 #align uv.compress_disjoint UV.compress_disjoint
 
+#print UV.compress_idem /-
 /-- Compressing an element is idempotent. -/
 @[simp]
 theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a :=
@@ -182,7 +195,9 @@ theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u
   · rfl
   · rfl
 #align uv.compress_idem UV.compress_idem
+-/
 
+#print UV.compress_mem_compression /-
 theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s :=
   by
   rw [mem_compression]
@@ -191,7 +206,9 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
     exact Or.inl ⟨h, h⟩
   · exact Or.inr ⟨h, a, ha, rfl⟩
 #align uv.compress_mem_compression UV.compress_mem_compression
+-/
 
+#print UV.compress_mem_compression_of_mem_compression /-
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : compress u v a ∈ 𝓒 u v s :=
   by
@@ -201,7 +218,9 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : co
   · exact Or.inl ⟨ha, ha⟩
   · exact Or.inr ⟨by rwa [compress_idem], b, hb, (compress_idem _ _ _).symm⟩
 #align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compression
+-/
 
+#print UV.compression_idem /-
 /-- Compressing a family is idempotent. -/
 @[simp]
 theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s :=
@@ -211,7 +230,9 @@ theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 
   rw [compression, image_filter, h, image_empty, ← h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
+-/
 
+#print UV.card_compression /-
 /-- Compressing a family doesn't change its size. -/
 @[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card :=
@@ -231,6 +252,7 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
 #align uv.card_compression UV.card_compression
+-/
 
 theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
   by
@@ -310,7 +332,7 @@ end GeneralizedBooleanAlgebra
 /-! ### UV-compression on finsets -/
 
 
-open FinsetFamily
+open scoped FinsetFamily
 
 variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
 
Diff
@@ -60,12 +60,6 @@ open Finset
 
 variable {α : Type _}
 
-/- warning: sup_sdiff_inj_on -> sup_sdiff_injOn is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
-Case conversion may be inaccurate. Consider using '#align sup_sdiff_inj_on sup_sdiff_injOnₓ'. -/
 /-- UV-compression is injective on the elements it moves. See `uv.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
     { x | Disjoint u x ∧ v ≤ x }.InjOn fun x => (x ⊔ u) \ v :=
@@ -92,12 +86,6 @@ variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
 
 attribute [local instance] decidableEqOfDecidableLE
 
-/- warning: uv.compress -> UV.compress is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> α -> α
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258)], α -> α -> α -> α
-Case conversion may be inaccurate. Consider using '#align uv.compress UV.compressₓ'. -/
 /-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
 `v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
 anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
@@ -105,12 +93,6 @@ def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
 
-/- warning: uv.compression -> UV.compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> (Finset.{u1} α) -> (Finset.{u1} α)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.335 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.337 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.335 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.337)], α -> α -> (Finset.{u1} α) -> (Finset.{u1} α)
-Case conversion may be inaccurate. Consider using '#align uv.compression UV.compressionₓ'. -/
 /-- To UV-compress a set family, we compress each of its elements, except that we don't want to
 reduce the cardinality, so we keep all elements whose compression is already present. -/
 def compression (u v : α) (s : Finset α) :=
@@ -120,23 +102,11 @@ def compression (u v : α) (s : Finset α) :=
 -- mathport name: uv.compression
 scoped[FinsetFamily] notation "𝓒 " => UV.compression
 
-/- warning: uv.is_compressed -> UV.IsCompressed is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> (Finset.{u1} α) -> Prop
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.959 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.961 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.959 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.961)], α -> α -> (Finset.{u1} α) -> Prop
-Case conversion may be inaccurate. Consider using '#align uv.is_compressed UV.IsCompressedₓ'. -/
 /-- `is_compressed u v s` expresses that `s` is UV-compressed. -/
 def IsCompressed (u v : α) (s : Finset α) :=
   𝓒 u v s = s
 #align uv.is_compressed UV.IsCompressed
 
-/- warning: uv.compress_of_disjoint_of_le -> UV.compress_of_disjoint_of_le is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019)] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
-Case conversion may be inaccurate. Consider using '#align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_leₓ'. -/
 theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
     compress u v a = (a ⊔ u) \ v :=
   if_pos ⟨hua, hva⟩
@@ -149,12 +119,6 @@ theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
     sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
 #align uv.compress_of_disjoint_of_le' Uv.compress_of_disjoint_of_le'
 
-/- warning: uv.mem_compression -> UV.mem_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => Exists.{0} (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) (fun (H : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) => Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1090 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1092 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1090 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1092)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => And (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) b s) (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
-Case conversion may be inaccurate. Consider using '#align uv.mem_compression UV.mem_compressionₓ'. -/
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
 theorem mem_compression :
@@ -166,12 +130,6 @@ protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s :=
   h
 #align uv.is_compressed.eq UV.IsCompressed.eq
 
-/- warning: uv.compress_self -> UV.compress_self is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u a) a
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1210 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1212 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1210 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1212)] (u : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u a) a
-Case conversion may be inaccurate. Consider using '#align uv.compress_self UV.compress_selfₓ'. -/
 @[simp]
 theorem compress_self (u a : α) : compress u u a = a :=
   by
@@ -181,12 +139,6 @@ theorem compress_self (u a : α) : compress u u a = a :=
   · rfl
 #align uv.compress_self UV.compress_self
 
-/- warning: uv.compression_self -> UV.compression_self is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s) s
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1300 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1302 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1300 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1302)] (u : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s) s
-Case conversion may be inaccurate. Consider using '#align uv.compression_self UV.compression_selfₓ'. -/
 @[simp]
 theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
   by
@@ -200,12 +152,6 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
     exact hb' hb
 #align uv.compression_self UV.compression_self
 
-/- warning: uv.is_compressed_self -> UV.is_compressed_self is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (s : Finset.{u1} α), UV.IsCompressed.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1478 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1480 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1478 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1480)] (u : α) (s : Finset.{u1} α), UV.IsCompressed.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s
-Case conversion may be inaccurate. Consider using '#align uv.is_compressed_self UV.is_compressed_selfₓ'. -/
 /-- Any family is compressed along two identical elements. -/
 theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
@@ -220,24 +166,12 @@ theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
   exact sdiff_sdiff_le
 #align uv.compress_sdiff_sdiff Uv.compress_sdiff_sdiff
 
-/- warning: uv.compress_disjoint -> UV.compress_disjoint is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
-Case conversion may be inaccurate. Consider using '#align uv.compress_disjoint UV.compress_disjointₓ'. -/
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
       ((s.image <| compress u v).filterₓ fun a => a ∉ s) :=
   disjoint_left.2 fun a ha₁ ha₂ => (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
 #align uv.compress_disjoint UV.compress_disjoint
 
-/- warning: uv.compress_idem -> UV.compress_idem is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1631 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1633 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1631 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1633)] (u : α) (v : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)
-Case conversion may be inaccurate. Consider using '#align uv.compress_idem UV.compress_idemₓ'. -/
 /-- Compressing an element is idempotent. -/
 @[simp]
 theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a :=
@@ -249,12 +183,6 @@ theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u
   · rfl
 #align uv.compress_idem UV.compress_idem
 
-/- warning: uv.compress_mem_compression -> UV.compress_mem_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1776 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1778 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1776 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1778)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
-Case conversion may be inaccurate. Consider using '#align uv.compress_mem_compression UV.compress_mem_compressionₓ'. -/
 theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s :=
   by
   rw [mem_compression]
@@ -264,12 +192,6 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
   · exact Or.inr ⟨h, a, ha, rfl⟩
 #align uv.compress_mem_compression UV.compress_mem_compression
 
-/- warning: uv.compress_mem_compression_of_mem_compression -> UV.compress_mem_compression_of_mem_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1951 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1953 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1951 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1953)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
-Case conversion may be inaccurate. Consider using '#align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compressionₓ'. -/
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : compress u v a ∈ 𝓒 u v s :=
   by
@@ -280,12 +202,6 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : co
   · exact Or.inr ⟨by rwa [compress_idem], b, hb, (compress_idem _ _ _).symm⟩
 #align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compression
 
-/- warning: uv.compression_idem -> UV.compression_idem is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2122 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2124 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2122 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2124)] (u : α) (v : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)
-Case conversion may be inaccurate. Consider using '#align uv.compression_idem UV.compression_idemₓ'. -/
 /-- Compressing a family is idempotent. -/
 @[simp]
 theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s :=
@@ -296,12 +212,6 @@ theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
 
-/- warning: uv.card_compression -> UV.card_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (s : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Finset.card.{u1} α s)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338)] (u : α) (v : α) (s : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Finset.card.{u1} α s)
-Case conversion may be inaccurate. Consider using '#align uv.card_compression UV.card_compressionₓ'. -/
 /-- Compressing a family doesn't change its size. -/
 @[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card :=
@@ -359,12 +269,6 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
   · cases ne_of_mem_of_not_mem hb ha hba
 #align uv.sup_sdiff_mem_of_mem_compression_of_not_mem Uv.sup_sdiff_mem_of_mem_compression_of_not_mem
 
-/- warning: uv.sup_sdiff_mem_of_mem_compression -> UV.sup_sdiff_mem_of_mem_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
-Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : Disjoint u a) :
@@ -387,12 +291,6 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
   rwa [hu, hv, compress_self, sup_bot_eq, sdiff_bot]
 #align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compression
 
-/- warning: uv.mem_of_mem_compression -> UV.mem_of_mem_compression is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
-Case conversion may be inaccurate. Consider using '#align uv.mem_of_mem_compression UV.mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
 theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v = ⊥ → u = ⊥) : a ∈ s :=
@@ -416,12 +314,6 @@ open FinsetFamily
 
 variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
 
-/- warning: uv.card_compress -> UV.card_compress is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {u : Finset.{u1} α} {v : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α u) (Finset.card.{u1} α v)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.generalizedBooleanAlgebra.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) u v A)) (Finset.card.{u1} α A))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {u : Finset.{u1} α} {v : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α u) (Finset.card.{u1} α v)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.instGeneralizedBooleanAlgebraFinset.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) u v A)) (Finset.card.{u1} α A))
-Case conversion may be inaccurate. Consider using '#align uv.card_compress UV.card_compressₓ'. -/
 /-- Compressing a finset doesn't change its size. -/
 theorem card_compress (hUV : u.card = v.card) (A : Finset α) : (compress u v A).card = A.card :=
   by
Diff
@@ -434,9 +434,7 @@ theorem card_compress (hUV : u.card = v.card) (A : Finset α) : (compress u v A)
 #align uv.card_compress UV.card_compress
 
 private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
-    v = ∅ → u = ∅ := by
-  rintro rfl
-  refine' eq_empty_of_forall_not_mem fun a ha => _
+    v = ∅ → u = ∅ := by rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha => _;
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
 /- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
@@ -452,14 +450,12 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
       s ∈ (∂ ) 𝒜' → s ∉ (∂ ) 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ (∂ ) 𝒜 ∧ (s ∪ v) \ u ∉ (∂ ) 𝒜'
   · rintro s hs'
     rw [mem_compression]
-    by_cases hs : s ∈ 𝒜.shadow
-    swap
+    by_cases hs : s ∈ 𝒜.shadow; swap
     · obtain ⟨hus, hvs, h, _⟩ := H _ hs' hs
       exact Or.inr ⟨hs, _, h, compress_of_disjoint_of_le' hvs hus⟩
     refine' Or.inl ⟨hs, _⟩
     rw [compress]
-    split_ifs with huvs
-    swap
+    split_ifs with huvs; swap
     · exact hs
     rw [mem_shadow_iff] at hs'
     obtain ⟨t, Ht, a, hat, rfl⟩ := hs'
Diff
@@ -438,7 +438,6 @@ private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x)
   rintro rfl
   refine' eq_empty_of_forall_not_mem fun a ha => _
   obtain ⟨_, ⟨⟩, -⟩ := huv a ha
-#align uv.aux uv.aux
 
 /- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
Diff
@@ -4,11 +4,12 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
 
 ! This file was ported from Lean 3 source module combinatorics.set_family.compression.uv
-! leanprover-community/mathlib commit 4c19a16e4b705bf135cf9a80ac18fcc99c438514
+! leanprover-community/mathlib commit 6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
-import Mathbin.Data.Finset.Card
+import Mathbin.Combinatorics.SetFamily.Shadow
+import Mathbin.Data.Finset.Sort
 
 /-!
 # UV-compressions
@@ -32,7 +33,9 @@ minimise the shadow.
   It is the compressions of the elements of `s` whose compression is not already in `s` along with
   the element whose compression is already in `s`. This way of splitting into what moves and what
   does not ensures the compression doesn't squash the set family, which is proved by
-  `uv.card_compress`.
+  `uv.card_compression`.
+* `uv.card_shadow_compression_le`: Compressing reduces the size of the shadow. This is a key fact in
+  the proof of Kruskal-Katona.
 
 ## Notation
 
@@ -43,11 +46,6 @@ minimise the shadow.
 Even though our emphasis is on `finset α`, we define UV-compressions more generally in a generalized
 boolean algebra, so that one can use it for `set α`.
 
-## TODO
-
-Prove that compressing reduces the size of shadow. This result and some more already exist on the
-branch `combinatorics`.
-
 ## References
 
 * https://github.com/b-mehta/maths-notes/blob/master/iii/mich/combinatorics.pdf
@@ -100,8 +98,9 @@ lean 3 declaration is
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258)], α -> α -> α -> α
 Case conversion may be inaccurate. Consider using '#align uv.compress UV.compressₓ'. -/
-/-- To UV-compress `a`, if it doesn't touch `U` and does contain `V`, we remove `V` and
-put `U` in. We'll only really use this when `|U| = |V|` and `U ∩ V = ∅`. -/
+/-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
+`v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
+anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
 def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
@@ -143,6 +142,13 @@ theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
   if_pos ⟨hua, hva⟩
 #align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_le
 
+theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
+    compress u v ((a ⊔ v) \ u) = a := by
+  rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
+      (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
+    sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
+#align uv.compress_of_disjoint_of_le' Uv.compress_of_disjoint_of_le'
+
 /- warning: uv.mem_compression -> UV.mem_compression is a dubious translation:
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => Exists.{0} (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) (fun (H : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) => Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
@@ -156,6 +162,10 @@ theorem mem_compression :
   simp_rw [compression, mem_union, mem_filter, mem_image, and_comm' (a ∉ s)]
 #align uv.mem_compression UV.mem_compression
 
+protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s :=
+  h
+#align uv.is_compressed.eq UV.IsCompressed.eq
+
 /- warning: uv.compress_self -> UV.compress_self is a dubious translation:
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u a) a
@@ -201,6 +211,15 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
 #align uv.is_compressed_self UV.is_compressed_self
 
+/-- An element can be compressed to any other element by removing/adding the differences. -/
+@[simp]
+theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a :=
+  by
+  refine' (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _
+  rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
+  exact sdiff_sdiff_le
+#align uv.compress_sdiff_sdiff Uv.compress_sdiff_sdiff
+
 /- warning: uv.compress_disjoint -> UV.compress_disjoint is a dubious translation:
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
@@ -284,6 +303,7 @@ but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338)] (u : α) (v : α) (s : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Finset.card.{u1} α s)
 Case conversion may be inaccurate. Consider using '#align uv.card_compression UV.card_compressionₓ'. -/
 /-- Compressing a family doesn't change its size. -/
+@[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card :=
   by
   rw [compression, card_disjoint_union (compress_disjoint _ _), image_filter, card_image_of_inj_on,
@@ -302,6 +322,43 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   · exact (ha.2 ha.1).elim
 #align uv.card_compression UV.card_compression
 
+theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a :=
+  by
+  rw [mem_compression] at h
+  obtain _ | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs  at hba
+  · rw [← hba, le_sdiff]
+    exact ⟨le_sup_right, h.1.mono_right h.2⟩
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.le_of_mem_compression_of_not_mem Uv.le_of_mem_compression_of_not_mem
+
+theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : Disjoint v a :=
+  by
+  rw [mem_compression] at h
+  obtain _ | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs  at hba
+  · rw [← hba]
+    exact disjoint_sdiff_self_right
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.disjoint_of_mem_compression_of_not_mem Uv.disjoint_of_mem_compression_of_not_mem
+
+theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
+    (a ⊔ v) \ u ∈ s := by
+  rw [mem_compression] at h
+  obtain _ | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs  at hba
+  ·
+    rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
+      h.1.symm.sdiff_eq_left]
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.sup_sdiff_mem_of_mem_compression_of_not_mem Uv.sup_sdiff_mem_of_mem_compression_of_not_mem
+
 /- warning: uv.sup_sdiff_mem_of_mem_compression -> UV.sup_sdiff_mem_of_mem_compression is a dubious translation:
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
@@ -346,8 +403,7 @@ theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v
   unfold compress at h
   split_ifs  at h
   · rw [← h, le_sdiff_iff] at hva
-    rw [hvu hva, hva, sup_bot_eq, sdiff_bot] at h
-    rwa [← h]
+    rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
 #align uv.mem_of_mem_compression UV.mem_of_mem_compression
 
@@ -358,16 +414,16 @@ end GeneralizedBooleanAlgebra
 
 open FinsetFamily
 
-variable [DecidableEq α] {𝒜 : Finset (Finset α)} {U V A : Finset α}
+variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
 
 /- warning: uv.card_compress -> UV.card_compress is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {U : Finset.{u1} α} {V : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α U) (Finset.card.{u1} α V)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.generalizedBooleanAlgebra.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) U V A)) (Finset.card.{u1} α A))
+  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {u : Finset.{u1} α} {v : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α u) (Finset.card.{u1} α v)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.generalizedBooleanAlgebra.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) u v A)) (Finset.card.{u1} α A))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {U : Finset.{u1} α} {V : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α U) (Finset.card.{u1} α V)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.instGeneralizedBooleanAlgebraFinset.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) U V A)) (Finset.card.{u1} α A))
+  forall {α : Type.{u1}} [_inst_1 : DecidableEq.{succ u1} α] {u : Finset.{u1} α} {v : Finset.{u1} α}, (Eq.{1} Nat (Finset.card.{u1} α u) (Finset.card.{u1} α v)) -> (forall (A : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compress.{u1} (Finset.{u1} α) (Finset.instGeneralizedBooleanAlgebraFinset.{u1} α (fun (a : α) (b : α) => _inst_1 a b)) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDisjoint.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a b) (fun (a : Finset.{u1} α) (b : Finset.{u1} α) => Finset.decidableDforallFinset.{u1} α a (fun (a_1 : α) (ᾰ : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 b) (fun (a_1 : α) (h : Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a_1 a) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => _inst_1 a b) a_1 b)) u v A)) (Finset.card.{u1} α A))
 Case conversion may be inaccurate. Consider using '#align uv.card_compress UV.card_compressₓ'. -/
 /-- Compressing a finset doesn't change its size. -/
-theorem card_compress (hUV : U.card = V.card) (A : Finset α) : (compress U V A).card = A.card :=
+theorem card_compress (hUV : u.card = v.card) (A : Finset α) : (compress u v A).card = A.card :=
   by
   unfold compress
   split_ifs
@@ -377,5 +433,135 @@ theorem card_compress (hUV : U.card = V.card) (A : Finset α) : (compress U V A)
   · rfl
 #align uv.card_compress UV.card_compress
 
+private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
+    v = ∅ → u = ∅ := by
+  rintro rfl
+  refine' eq_empty_of_forall_not_mem fun a ha => _
+  obtain ⟨_, ⟨⟩, -⟩ := huv a ha
+#align uv.aux uv.aux
+
+/- ./././Mathport/Syntax/Translate/Basic.lean:635:2: warning: expanding binder collection (y «expr ∉ » s) -/
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
+that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
+Kruskal-Katona. -/
+theorem shadow_compression_subset_compression_shadow (u v : Finset α)
+    (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
+    (∂ ) (𝓒 u v 𝒜) ⊆ 𝓒 u v ((∂ ) 𝒜) := by
+  set 𝒜' := 𝓒 u v 𝒜
+  suffices H :
+    ∀ s,
+      s ∈ (∂ ) 𝒜' → s ∉ (∂ ) 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ (∂ ) 𝒜 ∧ (s ∪ v) \ u ∉ (∂ ) 𝒜'
+  · rintro s hs'
+    rw [mem_compression]
+    by_cases hs : s ∈ 𝒜.shadow
+    swap
+    · obtain ⟨hus, hvs, h, _⟩ := H _ hs' hs
+      exact Or.inr ⟨hs, _, h, compress_of_disjoint_of_le' hvs hus⟩
+    refine' Or.inl ⟨hs, _⟩
+    rw [compress]
+    split_ifs with huvs
+    swap
+    · exact hs
+    rw [mem_shadow_iff] at hs'
+    obtain ⟨t, Ht, a, hat, rfl⟩ := hs'
+    have hav : a ∉ v := not_mem_mono huvs.2 (not_mem_erase a t)
+    have hvt : v ≤ t := huvs.2.trans (erase_subset _ t)
+    have ht : t ∈ 𝒜 := mem_of_mem_compression Ht hvt (aux huv)
+    by_cases hau : a ∈ u
+    · obtain ⟨b, hbv, Hcomp⟩ := huv a hau
+      refine' mem_shadow_iff_insert_mem.2 ⟨b, not_mem_sdiff_of_mem_right hbv, _⟩
+      rw [← Hcomp.eq] at ht
+      have hsb :=
+        sup_sdiff_mem_of_mem_compression ht ((erase_subset _ _).trans hvt)
+          (disjoint_erase_comm.2 huvs.1)
+      rwa [sup_eq_union, sdiff_erase (mem_union_left _ <| hvt hbv), union_erase_of_mem hat, ←
+        erase_union_of_mem hau] at hsb
+    · refine'
+        mem_shadow_iff.2
+          ⟨(t ⊔ u) \ v,
+            sup_sdiff_mem_of_mem_compression Ht hvt <| disjoint_of_erase_right hau huvs.1, a, _, _⟩
+      · rw [sup_eq_union, mem_sdiff, mem_union]
+        exact ⟨Or.inl hat, hav⟩
+      · rw [← erase_sdiff_comm, sup_eq_union, erase_union_distrib, erase_eq_of_not_mem hau]
+  intro s hs𝒜' hs𝒜
+  -- This is gonna be useful a couple of times so let's name it.
+  have m : ∀ (y) (_ : y ∉ s), insert y s ∉ 𝒜 := fun y h a =>
+    hs𝒜 (mem_shadow_iff_insert_mem.2 ⟨y, h, a⟩)
+  obtain ⟨x, _, _⟩ := mem_shadow_iff_insert_mem.1 hs𝒜'
+  have hus : u ⊆ insert x s := le_of_mem_compression_of_not_mem ‹_ ∈ 𝒜'› (m _ ‹x ∉ s›)
+  have hvs : Disjoint v (insert x s) := disjoint_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›)
+  have : (insert x s ∪ v) \ u ∈ 𝒜 := sup_sdiff_mem_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›)
+  have hsv : Disjoint s v := hvs.symm.mono_left (subset_insert _ _)
+  have hvu : Disjoint v u := disjoint_of_subset_right hus hvs
+  have hxv : x ∉ v := disjoint_right.1 hvs (mem_insert_self _ _)
+  have : v \ u = v := ‹Disjoint v u›.sdiff_eq_left
+  -- The first key part is that `x ∉ u`
+  have : x ∉ u := by
+    intro hxu
+    obtain ⟨y, hyv, hxy⟩ := huv x hxu
+    -- If `x ∈ u`, we can get `y ∈ v` so that `𝒜` is `(u.erase x, v.erase y)`-compressed
+    apply m y (disjoint_right.1 hsv hyv)
+    -- and we will use this `y` to contradict `m`, so we would like to show `insert y s ∈ 𝒜`.
+    -- We do this by showing the below
+    have : ((insert x s ∪ v) \ u ∪ erase u x) \ erase v y ∈ 𝒜 :=
+      by
+      refine'
+        sup_sdiff_mem_of_mem_compression (by rwa [hxy.eq]) _
+          (disjoint_of_subset_left (erase_subset _ _) disjoint_sdiff)
+      rw [union_sdiff_distrib, ‹v \ u = v›]
+      exact (erase_subset _ _).trans (subset_union_right _ _)
+    -- and then arguing that it's the same
+    convert this
+    rw [sdiff_union_erase_cancel (hus.trans <| subset_union_left _ _) ‹x ∈ u›, erase_union_distrib,
+      erase_insert ‹x ∉ s›, erase_eq_of_not_mem ‹x ∉ v›, sdiff_erase (mem_union_right _ hyv),
+      union_sdiff_cancel_right hsv]
+  -- Now that this is done, it's immediate that `u ⊆ s`
+  have hus : u ⊆ s := by rwa [← erase_eq_of_not_mem ‹x ∉ u›, ← subset_insert_iff]
+  -- and we already had that `v` and `s` are disjoint,
+  -- so it only remains to get `(s ∪ v) \ u ∈ ∂ 𝒜 \ ∂ 𝒜'`
+  simp_rw [mem_shadow_iff_insert_mem]
+  refine' ⟨hus, hsv.symm, ⟨x, _, _⟩, _⟩
+  -- `(s ∪ v) \ u ∈ ∂ 𝒜` is pretty direct:
+  · exact not_mem_sdiff_of_not_mem_left (not_mem_union.2 ⟨‹x ∉ s›, ‹x ∉ v›⟩)
+  · rwa [← insert_sdiff_of_not_mem _ ‹x ∉ u›, ← insert_union]
+  -- For (s ∪ v) \ u ∉ ∂ 𝒜', we split up based on w ∈ u
+  rintro ⟨w, hwB, hw𝒜'⟩
+  have : v ⊆ insert w ((s ∪ v) \ u) :=
+    (subset_sdiff.2 ⟨subset_union_right _ _, hvu⟩).trans (subset_insert _ _)
+  by_cases hwu : w ∈ u
+  -- If `w ∈ u`, we find `z ∈ v`, and contradict `m` again
+  · obtain ⟨z, hz, hxy⟩ := huv w hwu
+    apply m z (disjoint_right.1 hsv hz)
+    have : insert w ((s ∪ v) \ u) ∈ 𝒜 := mem_of_mem_compression hw𝒜' ‹_› (aux huv)
+    have : (insert w ((s ∪ v) \ u) ∪ erase u w) \ erase v z ∈ 𝒜 :=
+      by
+      refine' sup_sdiff_mem_of_mem_compression (by rwa [hxy.eq]) ((erase_subset _ _).trans ‹_›) _
+      rw [← sdiff_erase (mem_union_left _ <| hus hwu)]
+      exact disjoint_sdiff
+    convert this
+    rw [insert_union_comm, insert_erase ‹w ∈ u›,
+      sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
+      sdiff_erase (mem_union_right _ ‹z ∈ v›), union_sdiff_cancel_right hsv]
+  -- If `w ∉ u`, we contradict `m` again
+  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB
+  apply m w (hwu ∘ hwB ∘ mem_union_left _)
+  have : (insert w ((s ∪ v) \ u) ∪ u) \ v ∈ 𝒜 :=
+    sup_sdiff_mem_of_mem_compression ‹insert w ((s ∪ v) \ u) ∈ 𝒜'› ‹_›
+      (disjoint_insert_right.2 ⟨‹_›, disjoint_sdiff⟩)
+  convert this
+  rw [insert_union, sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
+    insert_sdiff_of_not_mem _ (hwu ∘ hwB ∘ mem_union_right _), union_sdiff_cancel_right hsv]
+#align uv.shadow_compression_subset_compression_shadow Uv.shadow_compression_subset_compression_shadow
+
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v`
+such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-compression fact needed for
+Kruskal-Katona. -/
+theorem card_shadow_compression_le (u v : Finset α)
+    (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.eraseₓ x) (v.eraseₓ y) 𝒜) :
+    ((∂ ) (𝓒 u v 𝒜)).card ≤ ((∂ ) 𝒜).card :=
+  (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
+    (card_compression _ _ _).le
+#align uv.card_shadow_compression_le Uv.card_shadow_compression_le
+
 end Uv
 
Diff
@@ -64,7 +64,7 @@ variable {α : Type _}
 
 /- warning: sup_sdiff_inj_on -> sup_sdiff_injOn is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
 Case conversion may be inaccurate. Consider using '#align sup_sdiff_inj_on sup_sdiff_injOnₓ'. -/
@@ -92,37 +92,49 @@ section GeneralizedBooleanAlgebra
 variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
   [DecidableRel ((· ≤ ·) : α → α → Prop)] {s : Finset α} {u v a b : α}
 
-attribute [local instance] decidableEqOfDecidableLe
+attribute [local instance] decidableEqOfDecidableLE
 
-#print UV.compress /-
+/- warning: uv.compress -> UV.compress is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> α -> α
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.256 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.258)], α -> α -> α -> α
+Case conversion may be inaccurate. Consider using '#align uv.compress UV.compressₓ'. -/
 /-- To UV-compress `a`, if it doesn't touch `U` and does contain `V`, we remove `V` and
 put `U` in. We'll only really use this when `|U| = |V|` and `U ∩ V = ∅`. -/
 def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
--/
 
-#print UV.compression /-
+/- warning: uv.compression -> UV.compression is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> (Finset.{u1} α) -> (Finset.{u1} α)
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.335 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.337 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.335 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.337)], α -> α -> (Finset.{u1} α) -> (Finset.{u1} α)
+Case conversion may be inaccurate. Consider using '#align uv.compression UV.compressionₓ'. -/
 /-- To UV-compress a set family, we compress each of its elements, except that we don't want to
 reduce the cardinality, so we keep all elements whose compression is already present. -/
 def compression (u v : α) (s : Finset α) :=
   (s.filterₓ fun a => compress u v a ∈ s) ∪ (s.image <| compress u v).filterₓ fun a => a ∉ s
 #align uv.compression UV.compression
--/
 
 -- mathport name: uv.compression
 scoped[FinsetFamily] notation "𝓒 " => UV.compression
 
-#print UV.IsCompressed /-
+/- warning: uv.is_compressed -> UV.IsCompressed is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))], α -> α -> (Finset.{u1} α) -> Prop
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.959 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.961 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.959 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.961)], α -> α -> (Finset.{u1} α) -> Prop
+Case conversion may be inaccurate. Consider using '#align uv.is_compressed UV.IsCompressedₓ'. -/
 /-- `is_compressed u v s` expresses that `s` is UV-compressed. -/
 def IsCompressed (u v : α) (s : Finset α) :=
   𝓒 u v s = s
 #align uv.is_compressed UV.IsCompressed
--/
 
 /- warning: uv.compress_of_disjoint_of_le -> UV.compress_of_disjoint_of_le is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019)] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
 Case conversion may be inaccurate. Consider using '#align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_leₓ'. -/
@@ -133,7 +145,7 @@ theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
 
 /- warning: uv.mem_compression -> UV.mem_compression is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => Exists.{0} (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) (fun (H : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) => Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => Exists.{0} (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) (fun (H : Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) b s) => Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1090 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1092 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1090 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1092)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, Iff (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Or (And (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s)) (And (Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (Exists.{succ u1} α (fun (b : α) => And (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) b s) (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v b) a)))))
 Case conversion may be inaccurate. Consider using '#align uv.mem_compression UV.mem_compressionₓ'. -/
@@ -144,7 +156,12 @@ theorem mem_compression :
   simp_rw [compression, mem_union, mem_filter, mem_image, and_comm' (a ∉ s)]
 #align uv.mem_compression UV.mem_compression
 
-#print UV.compress_self /-
+/- warning: uv.compress_self -> UV.compress_self is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u a) a
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1210 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1212 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1210 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1212)] (u : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u a) a
+Case conversion may be inaccurate. Consider using '#align uv.compress_self UV.compress_selfₓ'. -/
 @[simp]
 theorem compress_self (u a : α) : compress u u a = a :=
   by
@@ -153,9 +170,13 @@ theorem compress_self (u a : α) : compress u u a = a :=
   · exact h.1.symm.sup_sdiff_cancel_right
   · rfl
 #align uv.compress_self UV.compress_self
--/
 
-#print UV.compression_self /-
+/- warning: uv.compression_self -> UV.compression_self is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s) s
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1300 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1302 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1300 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1302)] (u : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s) s
+Case conversion may be inaccurate. Consider using '#align uv.compression_self UV.compression_selfₓ'. -/
 @[simp]
 theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
   by
@@ -168,18 +189,21 @@ theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s :=
     obtain ⟨⟨b, hb, rfl⟩, hb'⟩ := ha
     exact hb' hb
 #align uv.compression_self UV.compression_self
--/
 
-#print UV.is_compressed_self /-
+/- warning: uv.is_compressed_self -> UV.is_compressed_self is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (s : Finset.{u1} α), UV.IsCompressed.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1478 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1480 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1478 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1480)] (u : α) (s : Finset.{u1} α), UV.IsCompressed.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u u s
+Case conversion may be inaccurate. Consider using '#align uv.is_compressed_self UV.is_compressed_selfₓ'. -/
 /-- Any family is compressed along two identical elements. -/
 theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
 #align uv.is_compressed_self UV.is_compressed_self
--/
 
 /- warning: uv.compress_disjoint -> UV.compress_disjoint is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 Case conversion may be inaccurate. Consider using '#align uv.compress_disjoint UV.compress_disjointₓ'. -/
@@ -189,7 +213,12 @@ theorem compress_disjoint (u v : α) :
   disjoint_left.2 fun a ha₁ ha₂ => (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
 #align uv.compress_disjoint UV.compress_disjoint
 
-#print UV.compress_idem /-
+/- warning: uv.compress_idem -> UV.compress_idem is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1631 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1633 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1631 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1633)] (u : α) (v : α) (a : α), Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a)
+Case conversion may be inaccurate. Consider using '#align uv.compress_idem UV.compress_idemₓ'. -/
 /-- Compressing an element is idempotent. -/
 @[simp]
 theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a :=
@@ -200,9 +229,13 @@ theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u
   · rfl
   · rfl
 #align uv.compress_idem UV.compress_idem
--/
 
-#print UV.compress_mem_compression /-
+/- warning: uv.compress_mem_compression -> UV.compress_mem_compression is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1776 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1778 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1776 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1778)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
+Case conversion may be inaccurate. Consider using '#align uv.compress_mem_compression UV.compress_mem_compressionₓ'. -/
 theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s :=
   by
   rw [mem_compression]
@@ -211,9 +244,13 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
     exact Or.inl ⟨h, h⟩
   · exact Or.inr ⟨h, a, ha, rfl⟩
 #align uv.compress_mem_compression UV.compress_mem_compression
--/
 
-#print UV.compress_mem_compression_of_mem_compression /-
+/- warning: uv.compress_mem_compression_of_mem_compression -> UV.compress_mem_compression_of_mem_compression is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1951 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1953 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1951 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1953)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s))
+Case conversion may be inaccurate. Consider using '#align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compressionₓ'. -/
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : compress u v a ∈ 𝓒 u v s :=
   by
@@ -223,9 +260,13 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) : co
   · exact Or.inl ⟨ha, ha⟩
   · exact Or.inr ⟨by rwa [compress_idem], b, hb, (compress_idem _ _ _).symm⟩
 #align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compression
--/
 
-#print UV.compression_idem /-
+/- warning: uv.compression_idem -> UV.compression_idem is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2122 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2124 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2122 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2124)] (u : α) (v : α) (s : Finset.{u1} α), Eq.{succ u1} (Finset.{u1} α) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)
+Case conversion may be inaccurate. Consider using '#align uv.compression_idem UV.compression_idemₓ'. -/
 /-- Compressing a family is idempotent. -/
 @[simp]
 theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s :=
@@ -235,9 +276,13 @@ theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 
   rw [compression, image_filter, h, image_empty, ← h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
--/
 
-#print UV.card_compression /-
+/- warning: uv.card_compression -> UV.card_compression is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] (u : α) (v : α) (s : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Finset.card.{u1} α s)
+but is expected to have type
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2336 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2338)] (u : α) (v : α) (s : Finset.{u1} α), Eq.{1} Nat (Finset.card.{u1} α (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) (Finset.card.{u1} α s)
+Case conversion may be inaccurate. Consider using '#align uv.card_compression UV.card_compressionₓ'. -/
 /-- Compressing a family doesn't change its size. -/
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card :=
   by
@@ -256,11 +301,10 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
 #align uv.card_compression UV.card_compression
--/
 
 /- warning: uv.sup_sdiff_mem_of_mem_compression -> UV.sup_sdiff_mem_of_mem_compression is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
@@ -288,7 +332,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 
 /- warning: uv.mem_of_mem_compression -> UV.mem_of_mem_compression is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toHasLe.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
 but is expected to have type
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
 Case conversion may be inaccurate. Consider using '#align uv.mem_of_mem_compression UV.mem_of_mem_compressionₓ'. -/
Diff
@@ -181,7 +181,7 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 Case conversion may be inaccurate. Consider using '#align uv.compress_disjoint UV.compress_disjointₓ'. -/
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
Diff
@@ -181,7 +181,7 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1534 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1534)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1530 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 Case conversion may be inaccurate. Consider using '#align uv.compress_disjoint UV.compress_disjointₓ'. -/
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
@@ -262,7 +262,7 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2647 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2649 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2647 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2649)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2641 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2643)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
@@ -290,7 +290,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3037 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3039 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3037 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3039)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3031 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3033)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
 Case conversion may be inaccurate. Consider using '#align uv.mem_of_mem_compression UV.mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
Diff
@@ -181,7 +181,7 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) (fun (a : α) => Not.decidable (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEqOfDecidableLe.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1449 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1451 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1449 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1451)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1534 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1532 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1534)] {s : Finset.{u1} α} (u : α) (v : α), Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} α) (Finset.filter.{u1} α (fun (a : α) => Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) (fun (a : α) => Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) s) s) (Finset.filter.{u1} α (fun (a : α) => Not (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)) (fun (a : α) => instDecidableNot (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s) (Finset.decidableMem.{u1} α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) a s)) (Finset.image.{u1, u1} α α (fun (a : α) (b : α) => decidableEq_of_decidableLE.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (fun (a : α) (b : α) => _inst_3 a b) a b) (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v) s))
 Case conversion may be inaccurate. Consider using '#align uv.compress_disjoint UV.compress_disjointₓ'. -/
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filterₓ fun a => compress u v a ∈ s)
@@ -262,7 +262,7 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2564 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2564 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2647 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2649 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2647 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2649)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
@@ -290,7 +290,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2954 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2954 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3037 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3039 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3037 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.3039)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
 Case conversion may be inaccurate. Consider using '#align uv.mem_of_mem_compression UV.mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
Diff
@@ -262,7 +262,7 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2564 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2564 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
@@ -290,7 +290,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a)
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toHasBot.{u1} α _inst_1)))) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2958 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2958)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2954 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2954 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2956)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> ((Eq.{succ u1} α v (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1))) -> (Eq.{succ u1} α u (Bot.bot.{u1} α (GeneralizedBooleanAlgebra.toBot.{u1} α _inst_1)))) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a s)
 Case conversion may be inaccurate. Consider using '#align uv.mem_of_mem_compression UV.mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
Diff
@@ -64,9 +64,9 @@ variable {α : Type _}
 
 /- warning: sup_sdiff_inj_on -> sup_sdiff_injOn is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] (u : α) (v : α), Set.InjOn.{u1, u1} α α (fun (x : α) => SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) x u) v) (setOf.{u1} α (fun (x : α) => And (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u x) (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v x)))
 Case conversion may be inaccurate. Consider using '#align sup_sdiff_inj_on sup_sdiff_injOnₓ'. -/
 /-- UV-compression is injective on the elements it moves. See `uv.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
@@ -122,9 +122,9 @@ def IsCompressed (u v : α) (s : Finset α) :=
 
 /- warning: uv.compress_of_disjoint_of_le -> UV.compress_of_disjoint_of_le is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019)] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1017 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.1019)] {u : α} {v : α} {a : α}, (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Eq.{succ u1} α (UV.compress.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v a) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v))
 Case conversion may be inaccurate. Consider using '#align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_leₓ'. -/
 theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
     compress u v a = (a ⊔ u) \ v :=
@@ -260,9 +260,9 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
 
 /- warning: uv.sup_sdiff_mem_of_mem_compression -> UV.sup_sdiff_mem_of_mem_compression is a dubious translation:
 lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))))] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toHasSdiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (HasSup.sup.{u1} α (SemilatticeSup.toHasSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
+  forall {α : Type.{u1}} [_inst_1 : GeneralizedBooleanAlgebra.{u1} α] [_inst_2 : DecidableRel.{succ u1} α (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1))] [_inst_3 : DecidableRel.{succ u1} α (fun (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 : α) (x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568 : α) => LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2566 x._@.Mathlib.Combinatorics.SetFamily.Compression.UV._hyg.2568)] {s : Finset.{u1} α} {u : α} {v : α} {a : α}, (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) a (UV.compression.{u1} α _inst_1 (fun (a : α) (b : α) => _inst_2 a b) (fun (a : α) (b : α) => _inst_3 a b) u v s)) -> (LE.le.{u1} α (Preorder.toLE.{u1} α (PartialOrder.toPreorder.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))))) v a) -> (Disjoint.{u1} α (SemilatticeInf.toPartialOrder.{u1} α (Lattice.toSemilatticeInf.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) (GeneralizedBooleanAlgebra.toOrderBot.{u1} α _inst_1) u a) -> (Membership.mem.{u1, u1} α (Finset.{u1} α) (Finset.instMembershipFinset.{u1} α) (SDiff.sdiff.{u1} α (GeneralizedBooleanAlgebra.toSDiff.{u1} α _inst_1) (Sup.sup.{u1} α (SemilatticeSup.toSup.{u1} α (Lattice.toSemilatticeSup.{u1} α (GeneralizedCoheytingAlgebra.toLattice.{u1} α (GeneralizedBooleanAlgebra.toGeneralizedCoheytingAlgebra.{u1} α _inst_1)))) a u) v) s)
 Case conversion may be inaccurate. Consider using '#align uv.sup_sdiff_mem_of_mem_compression UV.sup_sdiff_mem_of_mem_compressionₓ'. -/
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/

Changes in mathlib4

mathlib3
mathlib4
chore: remove stream-of-consciousness uses of have, replace and suffices (#10640)

No changes to tactic file, it's just boring fixes throughout the library.

This follows on from #6964.

Co-authored-by: sgouezel <sebastien.gouezel@univ-rennes1.fr> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>

Diff
@@ -321,8 +321,8 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     ∂ (𝓒 u v 𝒜) ⊆ 𝓒 u v (∂ 𝒜) := by
   set 𝒜' := 𝓒 u v 𝒜
   suffices H : ∀ s ∈ ∂ 𝒜',
-      s ∉ ∂ 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ ∂ 𝒜 ∧ (s ∪ v) \ u ∉ ∂ 𝒜'
-  · rintro s hs'
+      s ∉ ∂ 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ ∂ 𝒜 ∧ (s ∪ v) \ u ∉ ∂ 𝒜' by
+    rintro s hs'
     rw [mem_compression]
     by_cases hs : s ∈ 𝒜.shadow
     swap
feat: (s ∩ t).card = s.card + t.card - (s ∪ t).card (#10224)

once coerced to an AddGroupWithOne. Also unify Finset.card_disjoint_union and Finset.card_union_eq

From LeanAPAP

Diff
@@ -212,8 +212,8 @@ theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 
 /-- Compressing a family doesn't change its size. -/
 @[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card := by
-  rw [compression, card_disjoint_union compress_disjoint, filter_image,
-    card_image_of_injOn compress_injOn, ← card_disjoint_union (disjoint_filter_filter_neg s _ _),
+  rw [compression, card_union_of_disjoint compress_disjoint, filter_image,
+    card_image_of_injOn compress_injOn, ← card_union_of_disjoint (disjoint_filter_filter_neg s _ _),
     filter_union_filter_neg_eq]
 #align uv.card_compression UV.card_compression
 
@@ -297,7 +297,7 @@ variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α} {r : 
 theorem card_compress (huv : u.card = v.card) (a : Finset α) : (compress u v a).card = a.card := by
   unfold compress
   split_ifs with h
-  · rw [card_sdiff (h.2.trans le_sup_left), sup_eq_union, card_disjoint_union h.1.symm, huv,
+  · rw [card_sdiff (h.2.trans le_sup_left), sup_eq_union, card_union_of_disjoint h.1.symm, huv,
       add_tsub_cancel_right]
   · rfl
 #align uv.card_compress UV.card_compress
chore(*): replace $ with <| (#9319)

See Zulip thread for the discussion.

Diff
@@ -408,7 +408,7 @@ theorem shadow_compression_subset_compression_shadow (u v : Finset α)
       exact disjoint_sdiff
     convert this using 1
     rw [insert_union_comm, insert_erase ‹w ∈ u›,
-      sdiff_union_of_subset (hus.trans $ subset_union_left _ _),
+      sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
       sdiff_erase (mem_union_right _ ‹z ∈ v›), union_sdiff_cancel_right hsv]
   -- If `w ∉ u`, we contradict `m` again
   rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB
chore: Improve Finset lemma names (#8894)

Change a few lemma names that have historically bothered me.

  • Finset.card_le_of_subsetFinset.card_le_card
  • Multiset.card_le_of_leMultiset.card_le_card
  • Multiset.card_lt_of_ltMultiset.card_lt_card
  • Set.ncard_le_of_subsetSet.ncard_le_ncard
  • Finset.image_filterFinset.filter_image
  • CompleteLattice.finset_sup_compact_of_compactCompleteLattice.isCompactElement_finset_sup
Diff
@@ -205,14 +205,14 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
 theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
   have h : filter (compress u v · ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
     filter_false_of_mem fun a ha h ↦ h <| compress_mem_compression_of_mem_compression ha
-  rw [compression, image_filter, h, image_empty, ← h]
+  rw [compression, filter_image, h, image_empty, ← h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
 
 /-- Compressing a family doesn't change its size. -/
 @[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card := by
-  rw [compression, card_disjoint_union compress_disjoint, image_filter,
+  rw [compression, card_disjoint_union compress_disjoint, filter_image,
     card_image_of_injOn compress_injOn, ← card_disjoint_union (disjoint_filter_filter_neg s _ _),
     filter_union_filter_neg_eq]
 #align uv.card_compression UV.card_compression
@@ -427,7 +427,7 @@ Kruskal-Katona. -/
 theorem card_shadow_compression_le (u v : Finset α)
     (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
     (∂ (𝓒 u v 𝒜)).card ≤ (∂ 𝒜).card :=
-  (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
+  (card_le_card <| shadow_compression_subset_compression_shadow _ _ huv).trans
     (card_compression _ _ _).le
 #align uv.card_shadow_compression_le UV.card_shadow_compression_le
 
chore: space after (#8178)

Co-authored-by: Moritz Firsching <firsching@google.com>

Diff
@@ -205,7 +205,7 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
 theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
   have h : filter (compress u v · ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
     filter_false_of_mem fun a ha h ↦ h <| compress_mem_compression_of_mem_compression ha
-  rw [compression, image_filter, h, image_empty, ←h]
+  rw [compression, image_filter, h, image_empty, ← h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
 
@@ -213,7 +213,7 @@ theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 
 @[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card := by
   rw [compression, card_disjoint_union compress_disjoint, image_filter,
-    card_image_of_injOn compress_injOn, ←card_disjoint_union (disjoint_filter_filter_neg s _ _),
+    card_image_of_injOn compress_injOn, ← card_disjoint_union (disjoint_filter_filter_neg s _ _),
     filter_union_filter_neg_eq]
 #align uv.card_compression UV.card_compression
 
chore: remove some double spaces (#7983)

Co-authored-by: Moritz Firsching <firsching@google.com>

Diff
@@ -143,9 +143,9 @@ theorem compress_injOn : Set.InjOn (compress u v) ↑(s.filter (compress u v ·
   intro a ha b hb hab
   rw [mem_coe, mem_filter] at ha hb
   rw [compress] at ha hab
-  split_ifs at ha hab  with has
+  split_ifs at ha hab with has
   · rw [compress] at hb hab
-    split_ifs at hb hab  with hbs
+    split_ifs at hb hab with hbs
     · exact sup_sdiff_injOn u v has hbs hab
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
chore: Fix decidability issues in UV-compression (#7708)

We had been a bit lazy in Lean 3 with the decidability instances here, and it recently bit me.

This PR reorders the lemmas to avoid decidableEqOfDecidableLE. There's only one new lemma: Set.Sized.uvCompression. Also golf a bit and fix style.

Diff
@@ -75,8 +75,6 @@ section GeneralizedBooleanAlgebra
 variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
   [DecidableRel ((· ≤ ·) : α → α → Prop)] {s : Finset α} {u v a b : α}
 
-attribute [local instance] decidableEqOfDecidableLE
-
 /-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
 `v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
 anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
@@ -84,91 +82,106 @@ def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
 
+theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
+    compress u v a = (a ⊔ u) \ v :=
+  if_pos ⟨hua, hva⟩
+#align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_le
+
+theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
+    compress u v ((a ⊔ v) \ u) = a := by
+  rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
+      (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
+    sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
+#align uv.compress_of_disjoint_of_le' UV.compress_of_disjoint_of_le'
+
+@[simp]
+theorem compress_self (u a : α) : compress u u a = a := by
+  unfold compress
+  split_ifs with h
+  · exact h.1.symm.sup_sdiff_cancel_right
+  · rfl
+#align uv.compress_self UV.compress_self
+
+/-- An element can be compressed to any other element by removing/adding the differences. -/
+@[simp]
+theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a := by
+  refine' (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _
+  rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
+  exact sdiff_sdiff_le
+#align uv.compress_sdiff_sdiff UV.compress_sdiff_sdiff
+
+/-- Compressing an element is idempotent. -/
+@[simp]
+theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a := by
+  unfold compress
+  split_ifs with h h'
+  · rw [le_sdiff_iff.1 h'.2, sdiff_bot, sdiff_bot, sup_assoc, sup_idem]
+  · rfl
+  · rfl
+#align uv.compress_idem UV.compress_idem
+
+variable [DecidableEq α]
+
 /-- To UV-compress a set family, we compress each of its elements, except that we don't want to
 reduce the cardinality, so we keep all elements whose compression is already present. -/
 def compression (u v : α) (s : Finset α) :=
-  (s.filter fun a => compress u v a ∈ s) ∪ (s.image <| compress u v).filter fun a => a ∉ s
+  (s.filter (compress u v · ∈ s)) ∪ (s.image <| compress u v).filter (· ∉ s)
 #align uv.compression UV.compression
 
 @[inherit_doc]
 scoped[FinsetFamily] notation "𝓒 " => UV.compression
-open FinsetFamily
+
+open scoped FinsetFamily
 
 /-- `IsCompressed u v s` expresses that `s` is UV-compressed. -/
 def IsCompressed (u v : α) (s : Finset α) :=
   𝓒 u v s = s
 #align uv.is_compressed UV.IsCompressed
 
-theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
-    compress u v a = (a ⊔ u) \ v :=
-  if_pos ⟨hua, hva⟩
-#align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_le
-
-theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
-    compress u v ((a ⊔ v) \ u) = a := by
-  rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
-      (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
-    sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
-#align uv.compress_of_disjoint_of_le' UV.compress_of_disjoint_of_le'
+/-- UV-compression is injective on the sets that are not UV-compressed. -/
+theorem compress_injOn : Set.InjOn (compress u v) ↑(s.filter (compress u v · ∉ s)) := by
+  intro a ha b hb hab
+  rw [mem_coe, mem_filter] at ha hb
+  rw [compress] at ha hab
+  split_ifs at ha hab  with has
+  · rw [compress] at hb hab
+    split_ifs at hb hab  with hbs
+    · exact sup_sdiff_injOn u v has hbs hab
+    · exact (hb.2 hb.1).elim
+  · exact (ha.2 ha.1).elim
+#align uv.compress_inj_on UV.compress_injOn
 
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
 theorem mem_compression :
-    a ∈ 𝓒 u v s ↔
-      a ∈ s ∧ compress u v a ∈ s ∨ a ∉ s ∧ ∃ b ∈ s, compress u v b = a := by
-  simp [compression, mem_union, mem_filter, mem_image, and_comm]
+    a ∈ 𝓒 u v s ↔ a ∈ s ∧ compress u v a ∈ s ∨ a ∉ s ∧ ∃ b ∈ s, compress u v b = a := by
+  simp_rw [compression, mem_union, mem_filter, mem_image, and_comm]
 #align uv.mem_compression UV.mem_compression
 
 protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s := h
 #align uv.is_compressed.eq UV.IsCompressed.eq
 
-@[simp]
-theorem compress_self (u a : α) : compress u u a = a := by
-  unfold compress
-  split_ifs
-  · exact ‹Disjoint u a ∧ u ≤ a›.1.symm.sup_sdiff_cancel_right
-  · rfl
-#align uv.compress_self UV.compress_self
-
 @[simp]
 theorem compression_self (u : α) (s : Finset α) : 𝓒 u u s = s := by
   unfold compression
   convert union_empty s
   · ext a
-    simp [mem_filter, compress_self, and_self_iff]
-  · refine' eq_empty_of_forall_not_mem fun a ha => _
+    rw [mem_filter, compress_self, and_self_iff]
+  · refine' eq_empty_of_forall_not_mem fun a ha ↦ _
     simp_rw [mem_filter, mem_image, compress_self] at ha
     obtain ⟨⟨b, hb, rfl⟩, hb'⟩ := ha
     exact hb' hb
 #align uv.compression_self UV.compression_self
 
 /-- Any family is compressed along two identical elements. -/
-theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
-  compression_self u s
-#align uv.is_compressed_self UV.is_compressed_self
+theorem isCompressed_self (u : α) (s : Finset α) : IsCompressed u u s := compression_self u s
+#align uv.is_compressed_self UV.isCompressed_self
 
-/-- An element can be compressed to any other element by removing/adding the differences. -/
-@[simp]
-theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a := by
-  refine' (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _
-  rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
-  exact sdiff_sdiff_le
-#align uv.compress_sdiff_sdiff UV.compress_sdiff_sdiff
-
-theorem compress_disjoint (u v : α) :
-    Disjoint (s.filter fun a => compress u v a ∈ s)
-      ((s.image <| compress u v).filter fun a => a ∉ s) :=
-  disjoint_left.2 fun _a ha₁ ha₂ => (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
+theorem compress_disjoint :
+    Disjoint (s.filter (compress u v · ∈ s)) ((s.image <| compress u v).filter (· ∉ s)) :=
+  disjoint_left.2 fun _a ha₁ ha₂ ↦ (mem_filter.1 ha₂).2 (mem_filter.1 ha₁).1
 #align uv.compress_disjoint UV.compress_disjoint
 
-/-- Compressing an element is idempotent. -/
-@[simp]
-theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a := by
-  unfold compress
-  split_ifs with h h' <;> try rfl
-  rw [le_sdiff_iff.1 h'.2, sdiff_bot, sdiff_bot, sup_assoc, sup_idem]
-#align uv.compress_idem UV.compress_idem
-
 theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s := by
   rw [mem_compression]
   by_cases h : compress u v a ∈ s
@@ -179,7 +192,7 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
 
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
-    compress u v a ∈ compression u v s := by
+    compress u v a ∈ 𝓒 u v s := by
   rw [mem_compression] at ha ⊢
   simp only [compress_idem, exists_prop]
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
@@ -189,31 +202,19 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
 
 /-- Compressing a family is idempotent. -/
 @[simp]
-theorem compression_idem (u v : α) (s : Finset α) :
-    𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
-  have h : filter (fun a => compress u v a ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
-    filter_false_of_mem fun a ha h => h <| compress_mem_compression_of_mem_compression ha
-  rw [compression, image_filter]
-  rw [h, image_empty, ← h]
+theorem compression_idem (u v : α) (s : Finset α) : 𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
+  have h : filter (compress u v · ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
+    filter_false_of_mem fun a ha h ↦ h <| compress_mem_compression_of_mem_compression ha
+  rw [compression, image_filter, h, image_empty, ←h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
 
 /-- Compressing a family doesn't change its size. -/
+@[simp]
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card := by
-  rw [compression, card_disjoint_union (compress_disjoint _ _), image_filter, card_image_of_injOn,
-    ← card_disjoint_union]
-  rw [filter_union_filter_neg_eq]
-  · rw [disjoint_iff_inter_eq_empty]
-    exact filter_inter_filter_neg_eq _ _ _
-  intro a ha b hb hab
-  rw [mem_coe, mem_filter] at ha hb
-  rw [compress] at ha hab
-  split_ifs at ha hab with has
-  · rw [compress] at hb hab
-    split_ifs at hb hab with hbs
-    · exact sup_sdiff_injOn u v has hbs hab
-    · exact (hb.2 hb.1).elim
-  · exact (ha.2 ha.1).elim
+  rw [compression, card_disjoint_union compress_disjoint, image_filter,
+    card_image_of_injOn compress_injOn, ←card_disjoint_union (disjoint_filter_filter_neg s _ _),
+    filter_union_filter_neg_eq]
 #align uv.card_compression UV.card_compression
 
 theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a := by
@@ -252,8 +253,7 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
 
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
-theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s)
-    (hva : v ≤ a) (hua : Disjoint u a) :
+theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hua : Disjoint u a) :
     (a ⊔ u) \ v ∈ s := by
   rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
@@ -291,11 +291,7 @@ end GeneralizedBooleanAlgebra
 
 open FinsetFamily
 
-variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
-
--- porting note: Lean doesn't see through `≤` here anymore
-/-- TODO: Make a proper instance -/
-local instance : @DecidableRel (Finset α) (· ≤ ·) := fun _ _ ↦ Finset.decidableDforallFinset
+variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α} {r : ℕ}
 
 /-- Compressing a finset doesn't change its size. -/
 theorem card_compress (huv : u.card = v.card) (a : Finset α) : (compress u v a).card = a.card := by
@@ -306,11 +302,16 @@ theorem card_compress (huv : u.card = v.card) (a : Finset α) : (compress u v a)
   · rfl
 #align uv.card_compress UV.card_compress
 
+lemma _root_.Set.Sized.uvCompression (huv : u.card = v.card) (h𝒜 : (𝒜 : Set (Finset α)).Sized r) :
+    (𝓒 u v 𝒜 : Set (Finset α)).Sized r := by
+  simp_rw [Set.Sized, mem_coe, mem_compression]
+  rintro s (hs | ⟨huvt, t, ht, rfl⟩)
+  · exact h𝒜 hs.1
+  · rw [card_compress huv, h𝒜 ht]
+
 private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
     v = ∅ → u = ∅ := by
-  rintro rfl
-  refine' eq_empty_of_forall_not_mem fun a ha => _
-  obtain ⟨_, ⟨⟩, -⟩ := huv a ha
+  rintro rfl; refine' eq_empty_of_forall_not_mem fun a ha ↦ _; obtain ⟨_, ⟨⟩, -⟩ := huv a ha
 
 /-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
 that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
chore: exactly 4 spaces in theorems (#7328)

Co-authored-by: Moritz Firsching <firsching@google.com>

Diff
@@ -253,7 +253,7 @@ theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha :
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s)
-  (hva : v ≤ a) (hua : Disjoint u a) :
+    (hva : v ≤ a) (hua : Disjoint u a) :
     (a ⊔ u) \ v ∈ s := by
   rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
feat: Miscellaneous Finset lemmas (#7379)
Diff
@@ -194,7 +194,6 @@ theorem compression_idem (u v : α) (s : Finset α) :
   have h : filter (fun a => compress u v a ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
     filter_false_of_mem fun a ha h => h <| compress_mem_compression_of_mem_compression ha
   rw [compression, image_filter]
-  simp_rw [Function.comp]
   rw [h, image_empty, ← h]
   exact filter_union_filter_neg_eq _ (compression u v s)
 #align uv.compression_idem UV.compression_idem
@@ -203,12 +202,11 @@ theorem compression_idem (u v : α) (s : Finset α) :
 theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card := by
   rw [compression, card_disjoint_union (compress_disjoint _ _), image_filter, card_image_of_injOn,
     ← card_disjoint_union]
-  simp_rw [Function.comp]
   rw [filter_union_filter_neg_eq]
   · rw [disjoint_iff_inter_eq_empty]
     exact filter_inter_filter_neg_eq _ _ _
   intro a ha b hb hab
-  rw [mem_coe, mem_filter, Function.comp_apply] at ha hb
+  rw [mem_coe, mem_filter] at ha hb
   rw [compress] at ha hab
   split_ifs at ha hab with has
   · rw [compress] at hb hab
chore: only four spaces for subsequent lines (#7286)

Co-authored-by: Moritz Firsching <firsching@google.com>

Diff
@@ -190,7 +190,7 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
 /-- Compressing a family is idempotent. -/
 @[simp]
 theorem compression_idem (u v : α) (s : Finset α) :
-  𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
+    𝓒 u v (𝓒 u v s) = 𝓒 u v s := by
   have h : filter (fun a => compress u v a ∉ 𝓒 u v s) (𝓒 u v s) = ∅ :=
     filter_false_of_mem fun a ha h => h <| compress_mem_compression_of_mem_compression ha
   rw [compression, image_filter]
@@ -276,7 +276,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s)
 /-- If `a` is in the `u, v`-compression but `v ≤ a`, then `a` must have been in the original
 family. -/
 theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v = ⊥ → u = ⊥) :
-  a ∈ s := by
+    a ∈ s := by
   rw [mem_compression] at ha
   obtain ha | ⟨_, b, hb, h⟩ := ha
   · exact ha.1
chore: remove unused simps (#6632)

Co-authored-by: Eric Wieser <wieser.eric@gmail.com>

Diff
@@ -208,7 +208,6 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   · rw [disjoint_iff_inter_eq_empty]
     exact filter_inter_filter_neg_eq _ _ _
   intro a ha b hb hab
-  dsimp at hab
   rw [mem_coe, mem_filter, Function.comp_apply] at ha hb
   rw [compress] at ha hab
   split_ifs at ha hab with has
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -51,7 +51,7 @@ compression, UV-compression, shadow
 
 open Finset
 
-variable {α : Type _}
+variable {α : Type*}
 
 /-- UV-compression is injective on the elements it moves. See `UV.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,14 +2,11 @@
 Copyright (c) 2021 Bhavik Mehta. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
-
-! This file was ported from Lean 3 source module combinatorics.set_family.compression.uv
-! leanprover-community/mathlib commit 6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Combinatorics.SetFamily.Shadow
 
+#align_import combinatorics.set_family.compression.uv from "leanprover-community/mathlib"@"6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1"
+
 /-!
 # UV-compressions
 
fix: precedence of shadow (#5620)
Diff
@@ -323,10 +323,10 @@ that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about c
 Kruskal-Katona. -/
 theorem shadow_compression_subset_compression_shadow (u v : Finset α)
     (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
-    (∂ ) (𝓒 u v 𝒜) ⊆ 𝓒 u v ((∂ ) 𝒜) := by
+    ∂ (𝓒 u v 𝒜) ⊆ 𝓒 u v (∂ 𝒜) := by
   set 𝒜' := 𝓒 u v 𝒜
-  suffices H : ∀ s ∈ (∂ ) 𝒜',
-      s ∉ (∂ ) 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ (∂ ) 𝒜 ∧ (s ∪ v) \ u ∉ (∂ ) 𝒜'
+  suffices H : ∀ s ∈ ∂ 𝒜',
+      s ∉ ∂ 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ ∂ 𝒜 ∧ (s ∪ v) \ u ∉ ∂ 𝒜'
   · rintro s hs'
     rw [mem_compression]
     by_cases hs : s ∈ 𝒜.shadow
@@ -431,7 +431,7 @@ such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-comp
 Kruskal-Katona. -/
 theorem card_shadow_compression_le (u v : Finset α)
     (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
-    ((∂ ) (𝓒 u v 𝒜)).card ≤ ((∂ ) 𝒜).card :=
+    (∂ (𝓒 u v 𝒜)).card ≤ (∂ 𝒜).card :=
   (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
     (card_compression _ _ _).le
 #align uv.card_shadow_compression_le UV.card_shadow_compression_le
chore: clean up spacing around at and goals (#5387)

Changes are of the form

  • some_tactic at h⊢ -> some_tactic at h ⊢
  • some_tactic at h -> some_tactic at h
Diff
@@ -183,7 +183,7 @@ theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s
 -- This is a special case of `compress_mem_compression` once we have `compression_idem`.
 theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
     compress u v a ∈ compression u v s := by
-  rw [mem_compression] at ha⊢
+  rw [mem_compression] at ha ⊢
   simp only [compress_idem, exists_prop]
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact Or.inl ⟨ha, ha⟩
Diff
@@ -4,11 +4,11 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies, Bhavik Mehta
 
 ! This file was ported from Lean 3 source module combinatorics.set_family.compression.uv
-! leanprover-community/mathlib commit 9003f28797c0664a49e4179487267c494477d853
+! leanprover-community/mathlib commit 6f8ab7de1c4b78a68ab8cf7dd83d549eb78a68a1
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
-import Mathlib.Data.Finset.Card
+import Mathlib.Combinatorics.SetFamily.Shadow
 
 /-!
 # UV-compressions
@@ -29,7 +29,9 @@ minimise the shadow.
   It is the compressions of the elements of `s` whose compression is not already in `s` along with
   the element whose compression is already in `s`. This way of splitting into what moves and what
   does not ensures the compression doesn't squash the set family, which is proved by
-  `UV.card_compress`.
+  `UV.card_compression`.
+* `UV.card_shadow_compression_le`: Compressing reduces the size of the shadow. This is a key fact in
+  the proof of Kruskal-Katona.
 
 ## Notation
 
@@ -40,11 +42,6 @@ minimise the shadow.
 Even though our emphasis is on `Finset α`, we define UV-compressions more generally in a generalized
 boolean algebra, so that one can use it for `Set α`.
 
-## TODO
-
-Prove that compressing reduces the size of shadow. This result and some more already exist on the
-branch `Combinatorics`.
-
 ## References
 
 * https://github.com/b-mehta/maths-notes/blob/master/iii/mich/combinatorics.pdf
@@ -83,8 +80,9 @@ variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
 
 attribute [local instance] decidableEqOfDecidableLE
 
-/-- To UV-compress `a`, if it doesn't touch `U` and does contain `V`, we remove `V` and
-put `U` in. We'll only really use this when `|U| = |V|` and `U ∩ V = ∅`. -/
+/-- UV-compressing `a` means removing `v` from it and adding `u` if `a` and `u` are disjoint and
+`v ≤ a` (it replaces the `v` part of `a` by the `u` part). Else, UV-compressing `a` doesn't do
+anything. This is most useful when `u` and `v` are disjoint finsets of the same size. -/
 def compress (u v a : α) : α :=
   if Disjoint u a ∧ v ≤ a then (a ⊔ u) \ v else a
 #align uv.compress UV.compress
@@ -109,6 +107,13 @@ theorem compress_of_disjoint_of_le (hua : Disjoint u a) (hva : v ≤ a) :
   if_pos ⟨hua, hva⟩
 #align uv.compress_of_disjoint_of_le UV.compress_of_disjoint_of_le
 
+theorem compress_of_disjoint_of_le' (hva : Disjoint v a) (hua : u ≤ a) :
+    compress u v ((a ⊔ v) \ u) = a := by
+  rw [compress_of_disjoint_of_le disjoint_sdiff_self_right
+      (le_sdiff.2 ⟨(le_sup_right : v ≤ a ⊔ v), hva.mono_right hua⟩),
+    sdiff_sup_cancel (le_sup_of_le_left hua), hva.symm.sup_sdiff_cancel_right]
+#align uv.compress_of_disjoint_of_le' UV.compress_of_disjoint_of_le'
+
 /-- `a` is in the UV-compressed family iff it's in the original and its compression is in the
 original, or it's not in the original but it's the compression of something in the original. -/
 theorem mem_compression :
@@ -117,6 +122,9 @@ theorem mem_compression :
   simp [compression, mem_union, mem_filter, mem_image, and_comm]
 #align uv.mem_compression UV.mem_compression
 
+protected theorem IsCompressed.eq (h : IsCompressed u v s) : 𝓒 u v s = s := h
+#align uv.is_compressed.eq UV.IsCompressed.eq
+
 @[simp]
 theorem compress_self (u a : α) : compress u u a = a := by
   unfold compress
@@ -142,6 +150,14 @@ theorem is_compressed_self (u : α) (s : Finset α) : IsCompressed u u s :=
   compression_self u s
 #align uv.is_compressed_self UV.is_compressed_self
 
+/-- An element can be compressed to any other element by removing/adding the differences. -/
+@[simp]
+theorem compress_sdiff_sdiff (a b : α) : compress (a \ b) (b \ a) b = a := by
+  refine' (compress_of_disjoint_of_le disjoint_sdiff_self_left sdiff_le).trans _
+  rw [sup_sdiff_self_right, sup_sdiff, disjoint_sdiff_self_right.sdiff_eq_left, sup_eq_right]
+  exact sdiff_sdiff_le
+#align uv.compress_sdiff_sdiff UV.compress_sdiff_sdiff
+
 theorem compress_disjoint (u v : α) :
     Disjoint (s.filter fun a => compress u v a ∈ s)
       ((s.image <| compress u v).filter fun a => a ∉ s) :=
@@ -198,14 +214,48 @@ theorem card_compression (u v : α) (s : Finset α) : (𝓒 u v s).card = s.card
   dsimp at hab
   rw [mem_coe, mem_filter, Function.comp_apply] at ha hb
   rw [compress] at ha hab
-  split_ifs  at ha hab with has
+  split_ifs at ha hab with has
   · rw [compress] at hb hab
-    split_ifs  at hb hab with hbs
+    split_ifs at hb hab with hbs
     · exact sup_sdiff_injOn u v has hbs hab
     · exact (hb.2 hb.1).elim
   · exact (ha.2 ha.1).elim
 #align uv.card_compression UV.card_compression
 
+theorem le_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : u ≤ a := by
+  rw [mem_compression] at h
+  obtain h | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs at hba with h
+  · rw [← hba, le_sdiff]
+    exact ⟨le_sup_right, h.1.mono_right h.2⟩
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.le_of_mem_compression_of_not_mem UV.le_of_mem_compression_of_not_mem
+
+theorem disjoint_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) : Disjoint v a := by
+  rw [mem_compression] at h
+  obtain h | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs at hba
+  · rw [← hba]
+    exact disjoint_sdiff_self_right
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.disjoint_of_mem_compression_of_not_mem UV.disjoint_of_mem_compression_of_not_mem
+
+theorem sup_sdiff_mem_of_mem_compression_of_not_mem (h : a ∈ 𝓒 u v s) (ha : a ∉ s) :
+    (a ⊔ v) \ u ∈ s := by
+  rw [mem_compression] at h
+  obtain h | ⟨-, b, hb, hba⟩ := h
+  · cases ha h.1
+  unfold compress at hba
+  split_ifs at hba with h
+  · rwa [← hba, sdiff_sup_cancel (le_sup_of_le_left h.2), sup_sdiff_right_self,
+      h.1.symm.sdiff_eq_left]
+  · cases ne_of_mem_of_not_mem hb ha hba
+#align uv.sup_sdiff_mem_of_mem_compression_of_not_mem UV.sup_sdiff_mem_of_mem_compression_of_not_mem
+
 /-- If `a` is in the family compression and can be compressed, then its compression is in the
 original family. -/
 theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s)
@@ -237,8 +287,7 @@ theorem mem_of_mem_compression (ha : a ∈ 𝓒 u v s) (hva : v ≤ a) (hvu : v
   unfold compress at h
   split_ifs at h
   · rw [← h, le_sdiff_iff] at hva
-    rw [hvu hva, hva, sup_bot_eq, sdiff_bot] at h
-    rwa [← h]
+    rwa [← h, hvu hva, hva, sup_bot_eq, sdiff_bot]
   · rwa [← h]
 #align uv.mem_of_mem_compression UV.mem_of_mem_compression
 
@@ -248,17 +297,143 @@ end GeneralizedBooleanAlgebra
 
 open FinsetFamily
 
-variable [DecidableEq α] {𝒜 : Finset (Finset α)} {U V A : Finset α}
+variable [DecidableEq α] {𝒜 : Finset (Finset α)} {u v a : Finset α}
+
+-- porting note: Lean doesn't see through `≤` here anymore
+/-- TODO: Make a proper instance -/
+local instance : @DecidableRel (Finset α) (· ≤ ·) := fun _ _ ↦ Finset.decidableDforallFinset
 
--- porting note: needed to insert decidableDforallFinset instance here
 /-- Compressing a finset doesn't change its size. -/
-theorem card_compress (hUV : U.card = V.card) (A : Finset α) :
-    (@compress (Finset α) _ _ (fun _ _ => Finset.decidableDforallFinset) U V A).card = A.card := by
+theorem card_compress (huv : u.card = v.card) (a : Finset α) : (compress u v a).card = a.card := by
   unfold compress
   split_ifs with h
-  · rw [card_sdiff (h.2.trans le_sup_left), sup_eq_union, card_disjoint_union h.1.symm, hUV,
+  · rw [card_sdiff (h.2.trans le_sup_left), sup_eq_union, card_disjoint_union h.1.symm, huv,
       add_tsub_cancel_right]
   · rfl
 #align uv.card_compress UV.card_compress
 
+private theorem aux (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
+    v = ∅ → u = ∅ := by
+  rintro rfl
+  refine' eq_empty_of_forall_not_mem fun a ha => _
+  obtain ⟨_, ⟨⟩, -⟩ := huv a ha
+
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v` such
+that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key fact about compression for
+Kruskal-Katona. -/
+theorem shadow_compression_subset_compression_shadow (u v : Finset α)
+    (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
+    (∂ ) (𝓒 u v 𝒜) ⊆ 𝓒 u v ((∂ ) 𝒜) := by
+  set 𝒜' := 𝓒 u v 𝒜
+  suffices H : ∀ s ∈ (∂ ) 𝒜',
+      s ∉ (∂ ) 𝒜 → u ⊆ s ∧ Disjoint v s ∧ (s ∪ v) \ u ∈ (∂ ) 𝒜 ∧ (s ∪ v) \ u ∉ (∂ ) 𝒜'
+  · rintro s hs'
+    rw [mem_compression]
+    by_cases hs : s ∈ 𝒜.shadow
+    swap
+    · obtain ⟨hus, hvs, h, _⟩ := H _ hs' hs
+      exact Or.inr ⟨hs, _, h, compress_of_disjoint_of_le' hvs hus⟩
+    refine' Or.inl ⟨hs, _⟩
+    rw [compress]
+    split_ifs with huvs
+    swap
+    · exact hs
+    rw [mem_shadow_iff] at hs'
+    obtain ⟨t, Ht, a, hat, rfl⟩ := hs'
+    have hav : a ∉ v := not_mem_mono huvs.2 (not_mem_erase a t)
+    have hvt : v ≤ t := huvs.2.trans (erase_subset _ t)
+    have ht : t ∈ 𝒜 := mem_of_mem_compression Ht hvt (aux huv)
+    by_cases hau : a ∈ u
+    · obtain ⟨b, hbv, Hcomp⟩ := huv a hau
+      refine' mem_shadow_iff_insert_mem.2 ⟨b, not_mem_sdiff_of_mem_right hbv, _⟩
+      rw [← Hcomp.eq] at ht
+      have hsb :=
+        sup_sdiff_mem_of_mem_compression ht ((erase_subset _ _).trans hvt)
+          (disjoint_erase_comm.2 huvs.1)
+      rwa [sup_eq_union, sdiff_erase (mem_union_left _ <| hvt hbv), union_erase_of_mem hat, ←
+        erase_union_of_mem hau] at hsb
+    · refine'
+        mem_shadow_iff.2
+          ⟨(t ⊔ u) \ v,
+            sup_sdiff_mem_of_mem_compression Ht hvt <| disjoint_of_erase_right hau huvs.1, a, _, _⟩
+      · rw [sup_eq_union, mem_sdiff, mem_union]
+        exact ⟨Or.inl hat, hav⟩
+      · rw [← erase_sdiff_comm, sup_eq_union, erase_union_distrib, erase_eq_of_not_mem hau]
+  intro s hs𝒜' hs𝒜
+  -- This is gonna be useful a couple of times so let's name it.
+  have m : ∀ y, y ∉ s → insert y s ∉ 𝒜 := fun y h a => hs𝒜 (mem_shadow_iff_insert_mem.2 ⟨y, h, a⟩)
+  obtain ⟨x, _, _⟩ := mem_shadow_iff_insert_mem.1 hs𝒜'
+  have hus : u ⊆ insert x s := le_of_mem_compression_of_not_mem ‹_ ∈ 𝒜'› (m _ ‹x ∉ s›)
+  have hvs : Disjoint v (insert x s) := disjoint_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›)
+  have : (insert x s ∪ v) \ u ∈ 𝒜 := sup_sdiff_mem_of_mem_compression_of_not_mem ‹_› (m _ ‹x ∉ s›)
+  have hsv : Disjoint s v := hvs.symm.mono_left (subset_insert _ _)
+  have hvu : Disjoint v u := disjoint_of_subset_right hus hvs
+  have hxv : x ∉ v := disjoint_right.1 hvs (mem_insert_self _ _)
+  have : v \ u = v := ‹Disjoint v u›.sdiff_eq_left
+  -- The first key part is that `x ∉ u`
+  have : x ∉ u := by
+    intro hxu
+    obtain ⟨y, hyv, hxy⟩ := huv x hxu
+    -- If `x ∈ u`, we can get `y ∈ v` so that `𝒜` is `(u.erase x, v.erase y)`-compressed
+    apply m y (disjoint_right.1 hsv hyv)
+    -- and we will use this `y` to contradict `m`, so we would like to show `insert y s ∈ 𝒜`.
+    -- We do this by showing the below
+    have : ((insert x s ∪ v) \ u ∪ erase u x) \ erase v y ∈ 𝒜 := by
+      refine'
+        sup_sdiff_mem_of_mem_compression (by rwa [hxy.eq]) _
+          (disjoint_of_subset_left (erase_subset _ _) disjoint_sdiff)
+      rw [union_sdiff_distrib, ‹v \ u = v›]
+      exact (erase_subset _ _).trans (subset_union_right _ _)
+    -- and then arguing that it's the same
+    convert this using 1
+    rw [sdiff_union_erase_cancel (hus.trans <| subset_union_left _ _) ‹x ∈ u›, erase_union_distrib,
+      erase_insert ‹x ∉ s›, erase_eq_of_not_mem ‹x ∉ v›, sdiff_erase (mem_union_right _ hyv),
+      union_sdiff_cancel_right hsv]
+  -- Now that this is done, it's immediate that `u ⊆ s`
+  have hus : u ⊆ s := by rwa [← erase_eq_of_not_mem ‹x ∉ u›, ← subset_insert_iff]
+  -- and we already had that `v` and `s` are disjoint,
+  -- so it only remains to get `(s ∪ v) \ u ∈ ∂ 𝒜 \ ∂ 𝒜'`
+  simp_rw [mem_shadow_iff_insert_mem]
+  refine' ⟨hus, hsv.symm, ⟨x, _, _⟩, _⟩
+  -- `(s ∪ v) \ u ∈ ∂ 𝒜` is pretty direct:
+  · exact not_mem_sdiff_of_not_mem_left (not_mem_union.2 ⟨‹x ∉ s›, ‹x ∉ v›⟩)
+  · rwa [← insert_sdiff_of_not_mem _ ‹x ∉ u›, ← insert_union]
+  -- For (s ∪ v) \ u ∉ ∂ 𝒜', we split up based on w ∈ u
+  rintro ⟨w, hwB, hw𝒜'⟩
+  have : v ⊆ insert w ((s ∪ v) \ u) :=
+    (subset_sdiff.2 ⟨subset_union_right _ _, hvu⟩).trans (subset_insert _ _)
+  by_cases hwu : w ∈ u
+  -- If `w ∈ u`, we find `z ∈ v`, and contradict `m` again
+  · obtain ⟨z, hz, hxy⟩ := huv w hwu
+    apply m z (disjoint_right.1 hsv hz)
+    have : insert w ((s ∪ v) \ u) ∈ 𝒜 := mem_of_mem_compression hw𝒜' ‹_› (aux huv)
+    have : (insert w ((s ∪ v) \ u) ∪ erase u w) \ erase v z ∈ 𝒜 := by
+      refine' sup_sdiff_mem_of_mem_compression (by rwa [hxy.eq]) ((erase_subset _ _).trans ‹_›) _
+      rw [← sdiff_erase (mem_union_left _ <| hus hwu)]
+      exact disjoint_sdiff
+    convert this using 1
+    rw [insert_union_comm, insert_erase ‹w ∈ u›,
+      sdiff_union_of_subset (hus.trans $ subset_union_left _ _),
+      sdiff_erase (mem_union_right _ ‹z ∈ v›), union_sdiff_cancel_right hsv]
+  -- If `w ∉ u`, we contradict `m` again
+  rw [mem_sdiff, ← not_imp, Classical.not_not] at hwB
+  apply m w (hwu ∘ hwB ∘ mem_union_left _)
+  have : (insert w ((s ∪ v) \ u) ∪ u) \ v ∈ 𝒜 :=
+    sup_sdiff_mem_of_mem_compression ‹insert w ((s ∪ v) \ u) ∈ 𝒜'› ‹_›
+      (disjoint_insert_right.2 ⟨‹_›, disjoint_sdiff⟩)
+  convert this using 1
+  rw [insert_union, sdiff_union_of_subset (hus.trans <| subset_union_left _ _),
+    insert_sdiff_of_not_mem _ (hwu ∘ hwB ∘ mem_union_right _), union_sdiff_cancel_right hsv]
+#align uv.shadow_compression_subset_compression_shadow UV.shadow_compression_subset_compression_shadow
+
+/-- UV-compression reduces the size of the shadow of `𝒜` if, for all `x ∈ u` there is `y ∈ v`
+such that `𝒜` is `(u.erase x, v.erase y)`-compressed. This is the key UV-compression fact needed for
+Kruskal-Katona. -/
+theorem card_shadow_compression_le (u v : Finset α)
+    (huv : ∀ x ∈ u, ∃ y ∈ v, IsCompressed (u.erase x) (v.erase y) 𝒜) :
+    ((∂ ) (𝓒 u v 𝒜)).card ≤ ((∂ ) 𝒜).card :=
+  (card_le_of_subset <| shadow_compression_subset_compression_shadow _ _ huv).trans
+    (card_compression _ _ _).le
+#align uv.card_shadow_compression_le UV.card_shadow_compression_le
+
 end UV
feat: add Mathlib.Tactic.Common, and import (#4056)

This makes a mathlib4 version of mathlib3's tactic.basic, now called Mathlib.Tactic.Common, which imports all tactics which do not have significant theory requirements, and then is imported all across the base of the hierarchy.

This ensures that all common tactics are available nearly everywhere in the library, rather than having to be imported one-by-one as you need them.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -9,7 +9,6 @@ Authors: Yaël Dillies, Bhavik Mehta
 ! if you have ported upstream changes.
 -/
 import Mathlib.Data.Finset.Card
-import Mathlib.Tactic.ScopedNS -- Porting note: scoped
 
 /-!
 # UV-compressions
fix: correct names of LinearOrder decidable fields (#4006)

This renames

  • decidable_eq to decidableEq
  • decidable_lt to decidableLT
  • decidable_le to decidableLE
  • decidableLT_of_decidableLE to decidableLTOfDecidableLE
  • decidableEq_of_decidableLE to decidableEqOfDecidableLE

These fields are data not proofs, so they should be lowerCamelCased.

Diff
@@ -82,7 +82,7 @@ section GeneralizedBooleanAlgebra
 variable [GeneralizedBooleanAlgebra α] [DecidableRel (@Disjoint α _ _)]
   [DecidableRel ((· ≤ ·) : α → α → Prop)] {s : Finset α} {u v a b : α}
 
-attribute [local instance] decidableEq_of_decidableLE
+attribute [local instance] decidableEqOfDecidableLE
 
 /-- To UV-compress `a`, if it doesn't touch `U` and does contain `V`, we remove `V` and
 put `U` in. We'll only really use this when `|U| = |V|` and `U ∩ V = ∅`. -/
chore: bye-bye, solo bys! (#3825)

This PR puts, with one exception, every single remaining by that lies all by itself on its own line to the previous line, thus matching the current behaviour of start-port.sh. The exception is when the by begins the second or later argument to a tuple or anonymous constructor; see https://github.com/leanprover-community/mathlib4/pull/3825#discussion_r1186702599.

Essentially this is s/\n *by$/ by/g, but with manual editing to satisfy the linter's max-100-char-line requirement. The Python style linter is also modified to catch these "isolated bys".

Diff
@@ -62,11 +62,9 @@ variable {α : Type _}
 
 /-- UV-compression is injective on the elements it moves. See `UV.compress`. -/
 theorem sup_sdiff_injOn [GeneralizedBooleanAlgebra α] (u v : α) :
-    { x | Disjoint u x ∧ v ≤ x }.InjOn fun x => (x ⊔ u) \ v :=
-  by
+    { x | Disjoint u x ∧ v ≤ x }.InjOn fun x => (x ⊔ u) \ v := by
   rintro a ha b hb hab
-  have h : ((a ⊔ u) \ v) \ u ⊔ v = ((b ⊔ u) \ v) \ u ⊔ v :=
-    by
+  have h : ((a ⊔ u) \ v) \ u ⊔ v = ((b ⊔ u) \ v) \ u ⊔ v := by
     dsimp at hab
     rw [hab]
   rwa [sdiff_sdiff_comm, ha.1.symm.sup_sdiff_cancel_right, sdiff_sdiff_comm,
@@ -153,8 +151,7 @@ theorem compress_disjoint (u v : α) :
 
 /-- Compressing an element is idempotent. -/
 @[simp]
-theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a :=
-  by
+theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u v a := by
   unfold compress
   split_ifs with h h' <;> try rfl
   rw [le_sdiff_iff.1 h'.2, sdiff_bot, sdiff_bot, sup_assoc, sup_idem]
@@ -218,8 +215,7 @@ theorem sup_sdiff_mem_of_mem_compression (ha : a ∈ 𝓒 u v s)
   rw [mem_compression, compress_of_disjoint_of_le hua hva] at ha
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact ha
-  have hu : u = ⊥ :=
-    by
+  have hu : u = ⊥ := by
     suffices Disjoint u (u \ v) by rwa [(hua.mono_right hva).sdiff_eq_left, disjoint_self] at this
     refine' hua.mono_right _
     rw [← compress_idem, compress_of_disjoint_of_le hua hva]
chore: fix #align lines (#3640)

This PR fixes two things:

  • Most align statements for definitions and theorems and instances that are separated by two newlines from the relevant declaration (s/\n\n#align/\n#align). This is often seen in the mathport output after ending calc blocks.
  • All remaining more-than-one-line #align statements. (This was needed for a script I wrote for #3630.)
Diff
@@ -176,9 +176,7 @@ theorem compress_mem_compression_of_mem_compression (ha : a ∈ 𝓒 u v s) :
   obtain ⟨_, ha⟩ | ⟨_, b, hb, rfl⟩ := ha
   · exact Or.inl ⟨ha, ha⟩
   · exact Or.inr ⟨by rwa [compress_idem], b, hb, (compress_idem _ _ _).symm⟩
-#align
-  uv.compress_mem_compression_of_mem_compression
-  UV.compress_mem_compression_of_mem_compression
+#align uv.compress_mem_compression_of_mem_compression UV.compress_mem_compression_of_mem_compression
 
 /-- Compressing a family is idempotent. -/
 @[simp]
chore: add missing hypothesis names to by_cases (#2679)
Diff
@@ -162,7 +162,7 @@ theorem compress_idem (u v a : α) : compress u v (compress u v a) = compress u
 
 theorem compress_mem_compression (ha : a ∈ s) : compress u v a ∈ 𝓒 u v s := by
   rw [mem_compression]
-  by_cases compress u v a ∈ s
+  by_cases h : compress u v a ∈ s
   · rw [compress_idem]
     exact Or.inl ⟨h, h⟩
   · exact Or.inr ⟨h, a, ha, rfl⟩
feat: port Combinatorics.SetFamily.Compression.UV (#1600)

Co-authored-by: Lukas Miaskiwskyi <lukas.mias@gmail.com> Co-authored-by: ChrisHughes24 <chrishughes24@gmail.com> Co-authored-by: Yaël Dillies <yael.dillies@gmail.com>

Dependencies 7 + 236

237 files ported (97.1%)
102191 lines ported (97.1%)
Show graph

The unported dependencies are