File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -349,6 +349,17 @@ theorem image_id' [DecidableEq α] : (s.image fun x => x) = s :=
349349theorem image_image [DecidableEq γ] {g : β → γ} : (s.image f).image g = s.image (g ∘ f) :=
350350 eq_of_veq <| by simp only [image_val, dedup_map_dedup_eq, Multiset.map_map]
351351
352+ /-- Reverse of `Finset.image_image`. The `Finset` analogue of `Set.image_comp`. -/
353+ theorem image_comp [DecidableEq γ] {g : β → γ} : s.image (g ∘ f) = (s.image f).image g :=
354+ image_image.symm
355+
356+ /-- Point-free form of `Finset.image_image`: `image` distributes over `Function.comp`. -/
357+ theorem image_comp_image [DecidableEq γ] {g : β → γ} :
358+ image g ∘ image f = image (g ∘ f) := by ext s; simp [image_image]
359+
360+ theorem image_comp_eq [DecidableEq γ] {g : β → γ} :
361+ image (g ∘ f) = image g ∘ image f := image_comp_image.symm
362+
352363theorem image_comm {β'} [DecidableEq β'] [DecidableEq γ] {f : β → γ} {g : α → β} {f' : α → β'}
353364 {g' : β' → γ} (h_comm : ∀ a, f (g a) = g' (f' a)) :
354365 (s.image g).image f = (s.image f').image g' := by simp_rw [image_image, comp_def, h_comm]
Original file line number Diff line number Diff line change @@ -219,6 +219,8 @@ theorem image_comp (f : β → γ) (g : α → β) (a : Set α) : f ∘ g '' a =
219219
220220theorem image_comp_eq {g : β → γ} : image (g ∘ f) = image g ∘ image f := by grind
221221
222+ theorem image_comp_image {g : β → γ} : image g ∘ image f = image (g ∘ f) := by grind
223+
222224/-- A variant of `image_comp`, useful for rewriting -/
223225@ [grind =]
224226theorem image_image (g : β → γ) (f : α → β) (s : Set α) : g '' f '' s = (fun x => g (f x)) '' s :=
You can’t perform that action at this time.
0 commit comments