topology.continuous_function.cocompact_map
⟷
Mathlib.Topology.ContinuousFunction.CocompactMap
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.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(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)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -82,7 +82,7 @@ instance : CocompactMapClass (CocompactMap α β) α β
/-- Helper instance for when there's too many metavariables to apply `fun_like.has_coe_to_fun`
directly. -/
instance : CoeFun (CocompactMap α β) fun _ => α → β :=
- FunLike.hasCoeToFun
+ DFunLike.hasCoeToFun
#print CocompactMap.coe_toContinuousMap /-
@[simp]
@@ -94,7 +94,7 @@ theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α
#print CocompactMap.ext /-
@[ext]
theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
- FunLike.ext _ _ h
+ DFunLike.ext _ _ h
#align cocompact_map.ext CocompactMap.ext
-/
@@ -118,7 +118,7 @@ theorem coe_copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : ⇑(f.
#print CocompactMap.copy_eq /-
theorem copy_eq (f : CocompactMap α β) (f' : α → β) (h : f' = f) : f.copy f' h = f :=
- FunLike.ext' h
+ DFunLike.ext' h
#align cocompact_map.copy_eq CocompactMap.copy_eq
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,7 +3,7 @@ Copyright (c) 2022 Jireh Loreaux. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jireh Loreaux
-/
-import Mathbin.Topology.ContinuousFunction.Basic
+import Topology.ContinuousFunction.Basic
#align_import topology.continuous_function.cocompact_map from "leanprover-community/mathlib"@"3e32bc908f617039c74c06ea9a897e30c30803c2"
@@ -219,7 +219,7 @@ theorem isCompact_preimage [T2Space β] (f : CocompactMap α β) ⦃s : Set β
(cocompact_tendsto f <|
mem_cocompact.mpr ⟨s, hs, compl_subset_compl.mpr (image_preimage_subset f _)⟩))
exact
- isCompact_of_isClosed_subset ht (hs.is_closed.preimage <| map_continuous f) (by simpa using hts)
+ IsCompact.of_isClosed_subset ht (hs.is_closed.preimage <| map_continuous f) (by simpa using hts)
#align cocompact_map.is_compact_preimage CocompactMap.isCompact_preimage
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,14 +2,11 @@
Copyright (c) 2022 Jireh Loreaux. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jireh Loreaux
-
-! This file was ported from Lean 3 source module topology.continuous_function.cocompact_map
-! leanprover-community/mathlib commit 3e32bc908f617039c74c06ea9a897e30c30803c2
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.Topology.ContinuousFunction.Basic
+#align_import topology.continuous_function.cocompact_map from "leanprover-community/mathlib"@"3e32bc908f617039c74c06ea9a897e30c30803c2"
+
/-!
# Cocompact continuous maps
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -87,16 +87,21 @@ directly. -/
instance : CoeFun (CocompactMap α β) fun _ => α → β :=
FunLike.hasCoeToFun
+#print CocompactMap.coe_toContinuousMap /-
@[simp]
theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
rfl
#align cocompact_map.coe_to_continuous_fun CocompactMap.coe_toContinuousMap
+-/
+#print CocompactMap.ext /-
@[ext]
theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
FunLike.ext _ _ h
#align cocompact_map.ext CocompactMap.ext
+-/
+#print CocompactMap.copy /-
/-- Copy of a `cocompact_map` with a new `to_fun` equal to the old one. Useful
to fix definitional equalities. -/
protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : CocompactMap α β
@@ -105,21 +110,28 @@ protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : Coco
continuous_toFun := by rw [h]; exact f.continuous_to_fun
cocompact_tendsto' := by simp_rw [h]; exact f.cocompact_tendsto'
#align cocompact_map.copy CocompactMap.copy
+-/
+#print CocompactMap.coe_copy /-
@[simp]
theorem coe_copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : ⇑(f.copy f' h) = f' :=
rfl
#align cocompact_map.coe_copy CocompactMap.coe_copy
+-/
+#print CocompactMap.copy_eq /-
theorem copy_eq (f : CocompactMap α β) (f' : α → β) (h : f' = f) : f.copy f' h = f :=
FunLike.ext' h
#align cocompact_map.copy_eq CocompactMap.copy_eq
+-/
+#print CocompactMap.coe_mk /-
@[simp]
theorem coe_mk (f : C(α, β)) (h : Tendsto f (cocompact α) (cocompact β)) :
⇑(⟨f, h⟩ : CocompactMap α β) = f :=
rfl
#align cocompact_map.coe_mk CocompactMap.coe_mk
+-/
section
@@ -132,10 +144,12 @@ protected def id : CocompactMap α α :=
#align cocompact_map.id CocompactMap.id
-/
+#print CocompactMap.coe_id /-
@[simp]
theorem coe_id : ⇑(CocompactMap.id α) = id :=
rfl
#align cocompact_map.coe_id CocompactMap.coe_id
+-/
end
@@ -149,31 +163,41 @@ def comp (f : CocompactMap β γ) (g : CocompactMap α β) : CocompactMap α γ
#align cocompact_map.comp CocompactMap.comp
-/
+#print CocompactMap.coe_comp /-
@[simp]
theorem coe_comp (f : CocompactMap β γ) (g : CocompactMap α β) : ⇑(comp f g) = f ∘ g :=
rfl
#align cocompact_map.coe_comp CocompactMap.coe_comp
+-/
+#print CocompactMap.comp_apply /-
@[simp]
theorem comp_apply (f : CocompactMap β γ) (g : CocompactMap α β) (a : α) : comp f g a = f (g a) :=
rfl
#align cocompact_map.comp_apply CocompactMap.comp_apply
+-/
+#print CocompactMap.comp_assoc /-
@[simp]
theorem comp_assoc (f : CocompactMap γ δ) (g : CocompactMap β γ) (h : CocompactMap α β) :
(f.comp g).comp h = f.comp (g.comp h) :=
rfl
#align cocompact_map.comp_assoc CocompactMap.comp_assoc
+-/
+#print CocompactMap.id_comp /-
@[simp]
theorem id_comp (f : CocompactMap α β) : (CocompactMap.id _).comp f = f :=
ext fun _ => rfl
#align cocompact_map.id_comp CocompactMap.id_comp
+-/
+#print CocompactMap.comp_id /-
@[simp]
theorem comp_id (f : CocompactMap α β) : f.comp (CocompactMap.id _) = f :=
ext fun _ => rfl
#align cocompact_map.comp_id CocompactMap.comp_id
+-/
#print CocompactMap.tendsto_of_forall_preimage /-
theorem tendsto_of_forall_preimage {f : α → β} (h : ∀ s, IsCompact s → IsCompact (f ⁻¹' s)) :
@@ -184,6 +208,7 @@ theorem tendsto_of_forall_preimage {f : α → β} (h : ∀ s, IsCompact s → I
#align cocompact_map.tendsto_of_forall_preimage CocompactMap.tendsto_of_forall_preimage
-/
+#print CocompactMap.isCompact_preimage /-
/-- If the codomain is Hausdorff, preimages of compact sets are compact under a cocompact
continuous map. -/
theorem isCompact_preimage [T2Space β] (f : CocompactMap α β) ⦃s : Set β⦄ (hs : IsCompact s) :
@@ -199,6 +224,7 @@ theorem isCompact_preimage [T2Space β] (f : CocompactMap α β) ⦃s : Set β
exact
isCompact_of_isClosed_subset ht (hs.is_closed.preimage <| map_continuous f) (by simpa using hts)
#align cocompact_map.is_compact_preimage CocompactMap.isCompact_preimage
+-/
end Basics
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -38,7 +38,7 @@ when the codomain is Hausdorff (see `cocompact_map.tendsto_of_forall_preimage` a
Cocompact maps thus generalise proper maps, with which they correspond when the codomain is
Hausdorff. -/
structure CocompactMap (α : Type u) (β : Type v) [TopologicalSpace α] [TopologicalSpace β] extends
- ContinuousMap α β : Type max u v where
+ ContinuousMap α β : Type max u v where
cocompact_tendsto' : Tendsto to_fun (cocompact α) (cocompact β)
#align cocompact_map CocompactMap
-/
@@ -50,7 +50,7 @@ section
You should also extend this typeclass when you extend `cocompact_map`. -/
class CocompactMapClass (F : Type _) (α β : outParam <| Type _) [TopologicalSpace α]
- [TopologicalSpace β] extends ContinuousMapClass F α β where
+ [TopologicalSpace β] extends ContinuousMapClass F α β where
cocompact_tendsto (f : F) : Tendsto f (cocompact α) (cocompact β)
#align cocompact_map_class CocompactMapClass
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -87,34 +87,16 @@ directly. -/
instance : CoeFun (CocompactMap α β) fun _ => α → β :=
FunLike.hasCoeToFun
-/- warning: cocompact_map.coe_to_continuous_fun -> CocompactMap.coe_toContinuousMap is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] {f : CocompactMap.{u1, u2} α β _inst_1 _inst_2}, Eq.{max (succ u1) (succ u2)} ((fun (_x : ContinuousMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.toContinuousMap.{u1, u2} α β _inst_1 _inst_2 f)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (ContinuousMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : ContinuousMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (ContinuousMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.toContinuousMap.{u1, u2} α β _inst_1 _inst_2 f)) (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f)
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] {f : CocompactMap.{u2, u1} α β _inst_1 _inst_2}, Eq.{max (succ u2) (succ u1)} (forall (a : α), (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (ContinuousMap.instContinuousMapClassContinuousMap.{u2, u1} α β _inst_1 _inst_2)) (CocompactMap.toContinuousMap.{u2, u1} α β _inst_1 _inst_2 f)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) f)
-Case conversion may be inaccurate. Consider using '#align cocompact_map.coe_to_continuous_fun CocompactMap.coe_toContinuousMapₓ'. -/
@[simp]
theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
rfl
#align cocompact_map.coe_to_continuous_fun CocompactMap.coe_toContinuousMap
-/- warning: cocompact_map.ext -> CocompactMap.ext is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] {f : CocompactMap.{u1, u2} α β _inst_1 _inst_2} {g : CocompactMap.{u1, u2} α β _inst_1 _inst_2}, (forall (x : α), Eq.{succ u2} β (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f x) (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) g x)) -> (Eq.{succ (max u1 u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) f g)
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] {f : CocompactMap.{u2, u1} α β _inst_1 _inst_2} {g : CocompactMap.{u2, u1} α β _inst_1 _inst_2}, (forall (x : α), Eq.{succ u1} ((fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) x) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) f x) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) g x)) -> (Eq.{max (succ u2) (succ u1)} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) f g)
-Case conversion may be inaccurate. Consider using '#align cocompact_map.ext CocompactMap.extₓ'. -/
@[ext]
theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
FunLike.ext _ _ h
#align cocompact_map.ext CocompactMap.ext
-/- warning: cocompact_map.copy -> CocompactMap.copy is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) (f' : α -> β), (Eq.{max (succ u1) (succ u2)} (α -> β) f' (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f)) -> (CocompactMap.{u1, u2} α β _inst_1 _inst_2)
-but is expected to have type
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) (f' : α -> β), (Eq.{max (succ u1) (succ u2)} (α -> β) f' (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u2} α β _inst_1 _inst_2))) f)) -> (CocompactMap.{u1, u2} α β _inst_1 _inst_2)
-Case conversion may be inaccurate. Consider using '#align cocompact_map.copy CocompactMap.copyₓ'. -/
/-- Copy of a `cocompact_map` with a new `to_fun` equal to the old one. Useful
to fix definitional equalities. -/
protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : CocompactMap α β
@@ -124,33 +106,15 @@ protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : Coco
cocompact_tendsto' := by simp_rw [h]; exact f.cocompact_tendsto'
#align cocompact_map.copy CocompactMap.copy
-/- warning: cocompact_map.coe_copy -> CocompactMap.coe_copy is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) (f' : α -> β) (h : Eq.{max (succ u1) (succ u2)} (α -> β) f' (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f)), Eq.{max (succ u1) (succ u2)} (α -> β) (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.copy.{u1, u2} α β _inst_1 _inst_2 f f' h)) f'
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] (f : CocompactMap.{u2, u1} α β _inst_1 _inst_2) (f' : α -> β) (h : Eq.{max (succ u2) (succ u1)} (α -> β) f' (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) f)), Eq.{max (succ u2) (succ u1)} (forall (ᾰ : α), (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) ᾰ) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) (CocompactMap.copy.{u2, u1} α β _inst_1 _inst_2 f f' h)) f'
-Case conversion may be inaccurate. Consider using '#align cocompact_map.coe_copy CocompactMap.coe_copyₓ'. -/
@[simp]
theorem coe_copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : ⇑(f.copy f' h) = f' :=
rfl
#align cocompact_map.coe_copy CocompactMap.coe_copy
-/- warning: cocompact_map.copy_eq -> CocompactMap.copy_eq is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) (f' : α -> β) (h : Eq.{max (succ u1) (succ u2)} (α -> β) f' (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f)), Eq.{succ (max u1 u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.copy.{u1, u2} α β _inst_1 _inst_2 f f' h) f
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] (f : CocompactMap.{u2, u1} α β _inst_1 _inst_2) (f' : α -> β) (h : Eq.{max (succ u2) (succ u1)} (α -> β) f' (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) f)), Eq.{max (succ u2) (succ u1)} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) (CocompactMap.copy.{u2, u1} α β _inst_1 _inst_2 f f' h) f
-Case conversion may be inaccurate. Consider using '#align cocompact_map.copy_eq CocompactMap.copy_eqₓ'. -/
theorem copy_eq (f : CocompactMap α β) (f' : α → β) (h : f' = f) : f.copy f' h = f :=
FunLike.ext' h
#align cocompact_map.copy_eq CocompactMap.copy_eq
-/- warning: cocompact_map.coe_mk -> CocompactMap.coe_mk is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : ContinuousMap.{u1, u2} α β _inst_1 _inst_2) (h : Filter.Tendsto.{u1, u2} α β (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (ContinuousMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : ContinuousMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (ContinuousMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f) (Filter.cocompact.{u1} α _inst_1) (Filter.cocompact.{u2} β _inst_2)), Eq.{max (succ u1) (succ u2)} (α -> β) (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.mk.{u1, u2} α β _inst_1 _inst_2 f h)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (ContinuousMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : ContinuousMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (ContinuousMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f)
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] (f : ContinuousMap.{u2, u1} α β _inst_1 _inst_2) (h : Filter.Tendsto.{u2, u1} α β (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (ContinuousMap.instContinuousMapClassContinuousMap.{u2, u1} α β _inst_1 _inst_2)) f) (Filter.cocompact.{u2} α _inst_1) (Filter.cocompact.{u1} β _inst_2)), Eq.{max (succ u2) (succ u1)} (forall (ᾰ : α), (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) ᾰ) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u2 u1, u2, u1} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u2, u1} α β _inst_1 _inst_2))) (CocompactMap.mk.{u2, u1} α β _inst_1 _inst_2 f h)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u2 u1, u2, u1} (ContinuousMap.{u2, u1} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (ContinuousMap.instContinuousMapClassContinuousMap.{u2, u1} α β _inst_1 _inst_2)) f)
-Case conversion may be inaccurate. Consider using '#align cocompact_map.coe_mk CocompactMap.coe_mkₓ'. -/
@[simp]
theorem coe_mk (f : C(α, β)) (h : Tendsto f (cocompact α) (cocompact β)) :
⇑(⟨f, h⟩ : CocompactMap α β) = f :=
@@ -168,12 +132,6 @@ protected def id : CocompactMap α α :=
#align cocompact_map.id CocompactMap.id
-/
-/- warning: cocompact_map.coe_id -> CocompactMap.coe_id is a dubious translation:
-lean 3 declaration is
- forall (α : Type.{u1}) [_inst_1 : TopologicalSpace.{u1} α], Eq.{succ u1} (α -> α) (coeFn.{succ u1, succ u1} (CocompactMap.{u1, u1} α α _inst_1 _inst_1) (fun (_x : CocompactMap.{u1, u1} α α _inst_1 _inst_1) => α -> α) (CocompactMap.hasCoeToFun.{u1, u1} α α _inst_1 _inst_1) (CocompactMap.id.{u1} α _inst_1)) (id.{succ u1} α)
-but is expected to have type
- forall (α : Type.{u1}) [_inst_1 : TopologicalSpace.{u1} α], Eq.{succ u1} (forall (ᾰ : α), (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => α) ᾰ) (FunLike.coe.{succ u1, succ u1, succ u1} (CocompactMap.{u1, u1} α α _inst_1 _inst_1) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => α) _x) (ContinuousMapClass.toFunLike.{u1, u1, u1} (CocompactMap.{u1, u1} α α _inst_1 _inst_1) α α _inst_1 _inst_1 (CocompactMapClass.toContinuousMapClass.{u1, u1, u1} (CocompactMap.{u1, u1} α α _inst_1 _inst_1) α α _inst_1 _inst_1 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u1} α α _inst_1 _inst_1))) (CocompactMap.id.{u1} α _inst_1)) (id.{succ u1} α)
-Case conversion may be inaccurate. Consider using '#align cocompact_map.coe_id CocompactMap.coe_idₓ'. -/
@[simp]
theorem coe_id : ⇑(CocompactMap.id α) = id :=
rfl
@@ -191,57 +149,27 @@ def comp (f : CocompactMap β γ) (g : CocompactMap α β) : CocompactMap α γ
#align cocompact_map.comp CocompactMap.comp
-/
-/- warning: cocompact_map.coe_comp -> CocompactMap.coe_comp is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} {γ : Type.{u3}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_3 : TopologicalSpace.{u3} γ] (f : CocompactMap.{u2, u3} β γ _inst_2 _inst_3) (g : CocompactMap.{u1, u2} α β _inst_1 _inst_2), Eq.{max (succ u1) (succ u3)} (α -> γ) (coeFn.{succ (max u1 u3), max (succ u1) (succ u3)} (CocompactMap.{u1, u3} α γ _inst_1 _inst_3) (fun (_x : CocompactMap.{u1, u3} α γ _inst_1 _inst_3) => α -> γ) (CocompactMap.hasCoeToFun.{u1, u3} α γ _inst_1 _inst_3) (CocompactMap.comp.{u1, u2, u3} α β γ _inst_1 _inst_2 _inst_3 f g)) (Function.comp.{succ u1, succ u2, succ u3} α β γ (coeFn.{succ (max u2 u3), max (succ u2) (succ u3)} (CocompactMap.{u2, u3} β γ _inst_2 _inst_3) (fun (_x : CocompactMap.{u2, u3} β γ _inst_2 _inst_3) => β -> γ) (CocompactMap.hasCoeToFun.{u2, u3} β γ _inst_2 _inst_3) f) (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) g))
-but is expected to have type
- forall {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u3} β] [_inst_3 : TopologicalSpace.{u2} γ] (f : CocompactMap.{u3, u2} β γ _inst_2 _inst_3) (g : CocompactMap.{u1, u3} α β _inst_1 _inst_2), Eq.{max (succ u1) (succ u2)} (forall (ᾰ : α), (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => γ) ᾰ) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => γ) _x) (ContinuousMapClass.toFunLike.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α γ _inst_1 _inst_3 (CocompactMapClass.toContinuousMapClass.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α γ _inst_1 _inst_3 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u2} α γ _inst_1 _inst_3))) (CocompactMap.comp.{u1, u3, u2} α β γ _inst_1 _inst_2 _inst_3 f g)) (Function.comp.{succ u1, succ u3, succ u2} α β γ (FunLike.coe.{max (succ u3) (succ u2), succ u3, succ u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β (fun (_x : β) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : β) => γ) _x) (ContinuousMapClass.toFunLike.{max u3 u2, u3, u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β γ _inst_2 _inst_3 (CocompactMapClass.toContinuousMapClass.{max u3 u2, u3, u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β γ _inst_2 _inst_3 (CocompactMap.instCocompactMapClassCocompactMap.{u3, u2} β γ _inst_2 _inst_3))) f) (FunLike.coe.{max (succ u1) (succ u3), succ u1, succ u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u1 u3, u1, u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u1 u3, u1, u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u3} α β _inst_1 _inst_2))) g))
-Case conversion may be inaccurate. Consider using '#align cocompact_map.coe_comp CocompactMap.coe_compₓ'. -/
@[simp]
theorem coe_comp (f : CocompactMap β γ) (g : CocompactMap α β) : ⇑(comp f g) = f ∘ g :=
rfl
#align cocompact_map.coe_comp CocompactMap.coe_comp
-/- warning: cocompact_map.comp_apply -> CocompactMap.comp_apply is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} {γ : Type.{u3}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_3 : TopologicalSpace.{u3} γ] (f : CocompactMap.{u2, u3} β γ _inst_2 _inst_3) (g : CocompactMap.{u1, u2} α β _inst_1 _inst_2) (a : α), Eq.{succ u3} γ (coeFn.{succ (max u1 u3), max (succ u1) (succ u3)} (CocompactMap.{u1, u3} α γ _inst_1 _inst_3) (fun (_x : CocompactMap.{u1, u3} α γ _inst_1 _inst_3) => α -> γ) (CocompactMap.hasCoeToFun.{u1, u3} α γ _inst_1 _inst_3) (CocompactMap.comp.{u1, u2, u3} α β γ _inst_1 _inst_2 _inst_3 f g) a) (coeFn.{succ (max u2 u3), max (succ u2) (succ u3)} (CocompactMap.{u2, u3} β γ _inst_2 _inst_3) (fun (_x : CocompactMap.{u2, u3} β γ _inst_2 _inst_3) => β -> γ) (CocompactMap.hasCoeToFun.{u2, u3} β γ _inst_2 _inst_3) f (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) g a))
-but is expected to have type
- forall {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u3} β] [_inst_3 : TopologicalSpace.{u2} γ] (f : CocompactMap.{u3, u2} β γ _inst_2 _inst_3) (g : CocompactMap.{u1, u3} α β _inst_1 _inst_2) (a : α), Eq.{succ u2} ((fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => γ) a) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => γ) _x) (ContinuousMapClass.toFunLike.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α γ _inst_1 _inst_3 (CocompactMapClass.toContinuousMapClass.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α γ _inst_1 _inst_3) α γ _inst_1 _inst_3 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u2} α γ _inst_1 _inst_3))) (CocompactMap.comp.{u1, u3, u2} α β γ _inst_1 _inst_2 _inst_3 f g) a) (FunLike.coe.{max (succ u3) (succ u2), succ u3, succ u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β (fun (_x : β) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : β) => γ) _x) (ContinuousMapClass.toFunLike.{max u3 u2, u3, u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β γ _inst_2 _inst_3 (CocompactMapClass.toContinuousMapClass.{max u3 u2, u3, u2} (CocompactMap.{u3, u2} β γ _inst_2 _inst_3) β γ _inst_2 _inst_3 (CocompactMap.instCocompactMapClassCocompactMap.{u3, u2} β γ _inst_2 _inst_3))) f (FunLike.coe.{max (succ u1) (succ u3), succ u1, succ u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u1 u3, u1, u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u1 u3, u1, u3} (CocompactMap.{u1, u3} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u3} α β _inst_1 _inst_2))) g a))
-Case conversion may be inaccurate. Consider using '#align cocompact_map.comp_apply CocompactMap.comp_applyₓ'. -/
@[simp]
theorem comp_apply (f : CocompactMap β γ) (g : CocompactMap α β) (a : α) : comp f g a = f (g a) :=
rfl
#align cocompact_map.comp_apply CocompactMap.comp_apply
-/- warning: cocompact_map.comp_assoc -> CocompactMap.comp_assoc is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} {γ : Type.{u3}} {δ : Type.{u4}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_3 : TopologicalSpace.{u3} γ] [_inst_4 : TopologicalSpace.{u4} δ] (f : CocompactMap.{u3, u4} γ δ _inst_3 _inst_4) (g : CocompactMap.{u2, u3} β γ _inst_2 _inst_3) (h : CocompactMap.{u1, u2} α β _inst_1 _inst_2), Eq.{succ (max u1 u4)} (CocompactMap.{u1, u4} α δ _inst_1 _inst_4) (CocompactMap.comp.{u1, u2, u4} α β δ _inst_1 _inst_2 _inst_4 (CocompactMap.comp.{u2, u3, u4} β γ δ _inst_2 _inst_3 _inst_4 f g) h) (CocompactMap.comp.{u1, u3, u4} α γ δ _inst_1 _inst_3 _inst_4 f (CocompactMap.comp.{u1, u2, u3} α β γ _inst_1 _inst_2 _inst_3 g h))
-but is expected to have type
- forall {α : Type.{u1}} {β : Type.{u2}} {γ : Type.{u4}} {δ : Type.{u3}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_3 : TopologicalSpace.{u4} γ] [_inst_4 : TopologicalSpace.{u3} δ] (f : CocompactMap.{u4, u3} γ δ _inst_3 _inst_4) (g : CocompactMap.{u2, u4} β γ _inst_2 _inst_3) (h : CocompactMap.{u1, u2} α β _inst_1 _inst_2), Eq.{max (succ u1) (succ u3)} (CocompactMap.{u1, u3} α δ _inst_1 _inst_4) (CocompactMap.comp.{u1, u2, u3} α β δ _inst_1 _inst_2 _inst_4 (CocompactMap.comp.{u2, u4, u3} β γ δ _inst_2 _inst_3 _inst_4 f g) h) (CocompactMap.comp.{u1, u4, u3} α γ δ _inst_1 _inst_3 _inst_4 f (CocompactMap.comp.{u1, u2, u4} α β γ _inst_1 _inst_2 _inst_3 g h))
-Case conversion may be inaccurate. Consider using '#align cocompact_map.comp_assoc CocompactMap.comp_assocₓ'. -/
@[simp]
theorem comp_assoc (f : CocompactMap γ δ) (g : CocompactMap β γ) (h : CocompactMap α β) :
(f.comp g).comp h = f.comp (g.comp h) :=
rfl
#align cocompact_map.comp_assoc CocompactMap.comp_assoc
-/- warning: cocompact_map.id_comp -> CocompactMap.id_comp is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2), Eq.{succ (max u1 u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.comp.{u1, u2, u2} α β β _inst_1 _inst_2 _inst_2 (CocompactMap.id.{u2} β _inst_2) f) f
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] (f : CocompactMap.{u2, u1} α β _inst_1 _inst_2), Eq.{max (succ u2) (succ u1)} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) (CocompactMap.comp.{u2, u1, u1} α β β _inst_1 _inst_2 _inst_2 (CocompactMap.id.{u1} β _inst_2) f) f
-Case conversion may be inaccurate. Consider using '#align cocompact_map.id_comp CocompactMap.id_compₓ'. -/
@[simp]
theorem id_comp (f : CocompactMap α β) : (CocompactMap.id _).comp f = f :=
ext fun _ => rfl
#align cocompact_map.id_comp CocompactMap.id_comp
-/- warning: cocompact_map.comp_id -> CocompactMap.comp_id is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2), Eq.{succ (max u1 u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (CocompactMap.comp.{u1, u1, u2} α α β _inst_1 _inst_1 _inst_2 f (CocompactMap.id.{u1} α _inst_1)) f
-but is expected to have type
- forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : TopologicalSpace.{u2} α] [_inst_2 : TopologicalSpace.{u1} β] (f : CocompactMap.{u2, u1} α β _inst_1 _inst_2), Eq.{max (succ u2) (succ u1)} (CocompactMap.{u2, u1} α β _inst_1 _inst_2) (CocompactMap.comp.{u2, u2, u1} α α β _inst_1 _inst_1 _inst_2 f (CocompactMap.id.{u2} α _inst_1)) f
-Case conversion may be inaccurate. Consider using '#align cocompact_map.comp_id CocompactMap.comp_idₓ'. -/
@[simp]
theorem comp_id (f : CocompactMap α β) : f.comp (CocompactMap.id _) = f :=
ext fun _ => rfl
@@ -256,12 +184,6 @@ theorem tendsto_of_forall_preimage {f : α → β} (h : ∀ s, IsCompact s → I
#align cocompact_map.tendsto_of_forall_preimage CocompactMap.tendsto_of_forall_preimage
-/
-/- warning: cocompact_map.is_compact_preimage -> CocompactMap.isCompact_preimage is a dubious translation:
-lean 3 declaration is
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_5 : T2Space.{u2} β _inst_2] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) {{s : Set.{u2} β}}, (IsCompact.{u2} β _inst_2 s) -> (IsCompact.{u1} α _inst_1 (Set.preimage.{u1, u2} α β (coeFn.{succ (max u1 u2), max (succ u1) (succ u2)} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) (fun (_x : CocompactMap.{u1, u2} α β _inst_1 _inst_2) => α -> β) (CocompactMap.hasCoeToFun.{u1, u2} α β _inst_1 _inst_2) f) s))
-but is expected to have type
- forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : TopologicalSpace.{u1} α] [_inst_2 : TopologicalSpace.{u2} β] [_inst_5 : T2Space.{u2} β _inst_2] (f : CocompactMap.{u1, u2} α β _inst_1 _inst_2) {{s : Set.{u2} β}}, (IsCompact.{u2} β _inst_2 s) -> (IsCompact.{u1} α _inst_1 (Set.preimage.{u1, u2} α β (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α (fun (_x : α) => (fun (x._@.Mathlib.Topology.ContinuousFunction.Basic._hyg.699 : α) => β) _x) (ContinuousMapClass.toFunLike.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMapClass.toContinuousMapClass.{max u1 u2, u1, u2} (CocompactMap.{u1, u2} α β _inst_1 _inst_2) α β _inst_1 _inst_2 (CocompactMap.instCocompactMapClassCocompactMap.{u1, u2} α β _inst_1 _inst_2))) f) s))
-Case conversion may be inaccurate. Consider using '#align cocompact_map.is_compact_preimage CocompactMap.isCompact_preimageₓ'. -/
/-- If the codomain is Hausdorff, preimages of compact sets are compact under a cocompact
continuous map. -/
theorem isCompact_preimage [T2Space β] (f : CocompactMap α β) ⦃s : Set β⦄ (hs : IsCompact s) :
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -78,10 +78,7 @@ variable {α β γ δ : Type _} [TopologicalSpace α] [TopologicalSpace β] [Top
instance : CocompactMapClass (CocompactMap α β) α β
where
coe f := f.toFun
- coe_injective' f g h := by
- obtain ⟨⟨_, _⟩, _⟩ := f
- obtain ⟨⟨_, _⟩, _⟩ := g
- congr
+ coe_injective' f g h := by obtain ⟨⟨_, _⟩, _⟩ := f; obtain ⟨⟨_, _⟩, _⟩ := g; congr
map_continuous f := f.continuous_toFun
cocompact_tendsto f := f.cocompact_tendsto'
@@ -123,12 +120,8 @@ to fix definitional equalities. -/
protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : CocompactMap α β
where
toFun := f'
- continuous_toFun := by
- rw [h]
- exact f.continuous_to_fun
- cocompact_tendsto' := by
- simp_rw [h]
- exact f.cocompact_tendsto'
+ continuous_toFun := by rw [h]; exact f.continuous_to_fun
+ cocompact_tendsto' := by simp_rw [h]; exact f.cocompact_tendsto'
#align cocompact_map.copy CocompactMap.copy
/- warning: cocompact_map.coe_copy -> CocompactMap.coe_copy is a dubious translation:
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
The FunLike hierarchy is very big and gets scanned through each time we need a coercion (via the CoeFun
instance). It looks like unbundled inheritance suits Lean 4 better here. The only class that still extends FunLike
is EquivLike
, since that has a custom coe_injective'
field that is easier to implement. All other classes should take FunLike
or EquivLike
as a parameter.
Previously, morphism classes would be Type
-valued and extend FunLike
:
/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
extends FunLike F A B :=
(map_op : ∀ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))
After this PR, they should be Prop
-valued and take FunLike
as a parameter:
/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
[FunLike F A B] : Prop :=
(map_op : ∀ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))
(Note that A B
stay marked as outParam
even though they are not purely required to be so due to the FunLike
parameter already filling them in. This is required to see through type synonyms, which is important in the category theory library. Also, I think keeping them as outParam
is slightly faster.)
Similarly, MyEquivClass
should take EquivLike
as a parameter.
As a result, every mention of [MyHomClass F A B]
should become [FunLike F A B] [MyHomClass F A B]
.
While overall this gives some great speedups, there are some cases that are noticeably slower. In particular, a failing application of a lemma such as map_mul
is more expensive. This is due to suboptimal processing of arguments. For example:
variable [FunLike F M N] [Mul M] [Mul N] (f : F) (x : M) (y : M)
theorem map_mul [MulHomClass F M N] : f (x * y) = f x * f y
example [AddHomClass F A B] : f (x * y) = f x * f y := map_mul f _ _
Before this PR, applying map_mul f
gives the goals [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]
. Since M
and N
are out_param
s, [MulHomClass F ?M ?N]
is synthesized first, supplies values for ?M
and ?N
and then the Mul M
and Mul N
instances can be found.
After this PR, the goals become [FunLike F ?M ?N] [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]
. Now [FunLike F ?M ?N]
is synthesized first, supplies values for ?M
and ?N
and then the Mul M
and Mul N
instances can be found, before trying MulHomClass F M N
which fails. Since the Mul
hierarchy is very big, this can be slow to fail, especially when there is no such Mul
instance.
A long-term but harder to achieve solution would be to specify the order in which instance goals get solved. For example, we'd like to change the arguments to map_mul
to look like [FunLike F M N] [Mul M] [Mul N] [highPriority <| MulHomClass F M N]
because MulHomClass
fails or succeeds much faster than the others.
As a consequence, the simpNF
linter is much slower since by design it tries and fails to apply many map_
lemmas. The same issue occurs a few times in existing calls to simp [map_mul]
, where map_mul
is tried "too soon" and fails. Thanks to the speedup of leanprover/lean4#2478 the impact is very limited, only in files that already were close to the timeout.
simp
not firing sometimesThis affects map_smulₛₗ
and related definitions. For simp
lemmas Lean apparently uses a slightly different mechanism to find instances, so that rw
can find every argument to map_smulₛₗ
successfully but simp
can't: leanprover/lean4#3701.
Especially in the category theory library, we might sometimes have a type A
which is also accessible as a synonym (Bundled A hA).1
. Instance synthesis doesn't always work if we have f : A →* B
but x * y : (Bundled A hA).1
or vice versa. This seems to be mostly fixed by keeping A B
as outParam
s in MulHomClass F A B
. (Presumably because Lean will do a definitional check A =?= (Bundled A hA).1
instead of using the syntax in the discrimination tree.)
The timeouts can be worked around for now by specifying which map_mul
we mean, either as map_mul f
for some explicit f
, or as e.g. MonoidHomClass.map_mul
.
map_smulₛₗ
not firing as simp
lemma can be worked around by going back to the pre-FunLike situation and making LinearMap.map_smulₛₗ
a simp
lemma instead of the generic map_smulₛₗ
. Writing simp [map_smulₛₗ _]
also works.
Co-authored-by: Matthew Ballard <matt@mrb.email> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Scott Morrison <scott@tqft.net> Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>
@@ -42,7 +42,7 @@ section
You should also extend this typeclass when you extend `CocompactMap`. -/
class CocompactMapClass (F : Type*) (α β : outParam <| Type*) [TopologicalSpace α]
- [TopologicalSpace β] extends ContinuousMapClass F α β where
+ [TopologicalSpace β] [FunLike F α β] extends ContinuousMapClass F α β : Prop where
/-- The cocompact filter on `α` tends to the cocompact filter on `β` under the function -/
cocompact_tendsto (f : F) : Tendsto f (cocompact α) (cocompact β)
#align cocompact_map_class CocompactMapClass
@@ -51,7 +51,8 @@ end
namespace CocompactMapClass
-variable {F α β : Type*} [TopologicalSpace α] [TopologicalSpace β] [CocompactMapClass F α β]
+variable {F α β : Type*} [TopologicalSpace α] [TopologicalSpace β]
+variable [FunLike F α β] [CocompactMapClass F α β]
/-- Turn an element of a type `F` satisfying `CocompactMapClass F α β` into an actual
`CocompactMap`. This is declared as the default coercion from `F` to `CocompactMap α β`. -/
@@ -74,21 +75,17 @@ section Basics
variable {α β γ δ : Type*} [TopologicalSpace α] [TopologicalSpace β] [TopologicalSpace γ]
[TopologicalSpace δ]
-instance : CocompactMapClass (CocompactMap α β) α β where
+instance : FunLike (CocompactMap α β) α β where
coe f := f.toFun
coe_injective' f g h := by
obtain ⟨⟨_, _⟩, _⟩ := f
obtain ⟨⟨_, _⟩, _⟩ := g
congr
+
+instance : CocompactMapClass (CocompactMap α β) α β where
map_continuous f := f.continuous_toFun
cocompact_tendsto f := f.cocompact_tendsto'
-/- Porting note: not needed anymore
-/-- Helper instance for when there's too many metavariables to apply `DFunLike.hasCoeToFun`
-directly. -/
-instance : CoeFun (CocompactMap α β) fun _ => α → β :=
- DFunLike.hasCoeToFun-/
-
@[simp]
theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
rfl
FunLike
to DFunLike
(#9785)
This prepares for the introduction of a non-dependent synonym of FunLike, which helps a lot with keeping #8386 readable.
This is entirely search-and-replace in 680197f combined with manual fixes in 4145626, e900597 and b8428f8. The commands that generated this change:
sed -i 's/\bFunLike\b/DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoFunLike\b/toDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/import Mathlib.Data.DFunLike/import Mathlib.Data.FunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bHom_FunLike\b/Hom_DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\binstFunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bfunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoo many metavariables to apply `fun_like.has_coe_to_fun`/too many metavariables to apply `DFunLike.hasCoeToFun`/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>
@@ -84,10 +84,10 @@ instance : CocompactMapClass (CocompactMap α β) α β where
cocompact_tendsto f := f.cocompact_tendsto'
/- Porting note: not needed anymore
-/-- Helper instance for when there's too many metavariables to apply `fun_like.has_coe_to_fun`
+/-- Helper instance for when there's too many metavariables to apply `DFunLike.hasCoeToFun`
directly. -/
instance : CoeFun (CocompactMap α β) fun _ => α → β :=
- FunLike.hasCoeToFun-/
+ DFunLike.hasCoeToFun-/
@[simp]
theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
@@ -96,7 +96,7 @@ theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α
@[ext]
theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
- FunLike.ext _ _ h
+ DFunLike.ext _ _ h
#align cocompact_map.ext CocompactMap.ext
/-- Copy of a `CocompactMap` with a new `toFun` equal to the old one. Useful
@@ -117,7 +117,7 @@ theorem coe_copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : ⇑(f.
#align cocompact_map.coe_copy CocompactMap.coe_copy
theorem copy_eq (f : CocompactMap α β) (f' : α → β) (h : f' = f) : f.copy f' h = f :=
- FunLike.ext' h
+ DFunLike.ext' h
#align cocompact_map.copy_eq CocompactMap.copy_eq
@[simp]
@@ -195,7 +195,7 @@ theorem isCompact_preimage [T2Space β] (f : CocompactMap α β) ⦃s : Set β
(cocompact_tendsto f <|
mem_cocompact.mpr ⟨s, hs, compl_subset_compl.mpr (image_preimage_subset f _)⟩))
exact
- isCompact_of_isClosed_subset ht (hs.isClosed.preimage <| map_continuous f) (by simpa using hts)
+ ht.of_isClosed_subset (hs.isClosed.preimage <| map_continuous f) (by simpa using hts)
#align cocompact_map.is_compact_preimage CocompactMap.isCompact_preimage
end Basics
@@ -53,8 +53,15 @@ namespace CocompactMapClass
variable {F α β : Type*} [TopologicalSpace α] [TopologicalSpace β] [CocompactMapClass F α β]
+/-- Turn an element of a type `F` satisfying `CocompactMapClass F α β` into an actual
+`CocompactMap`. This is declared as the default coercion from `F` to `CocompactMap α β`. -/
+@[coe]
+def toCocompactMap (f : F) : CocompactMap α β :=
+ { (f : C(α, β)) with
+ cocompact_tendsto' := cocompact_tendsto f }
+
instance : CoeTC F (CocompactMap α β) :=
- ⟨fun f => ⟨f, cocompact_tendsto f⟩⟩
+ ⟨toCocompactMap⟩
end CocompactMapClass
Type _
and Sort _
(#6499)
We remove all possible occurences of Type _
and Sort _
in favor of Type*
and Sort*
.
This has nice performance benefits.
@@ -41,7 +41,7 @@ section
/-- `CocompactMapClass F α β` states that `F` is a type of cocompact continuous maps.
You should also extend this typeclass when you extend `CocompactMap`. -/
-class CocompactMapClass (F : Type _) (α β : outParam <| Type _) [TopologicalSpace α]
+class CocompactMapClass (F : Type*) (α β : outParam <| Type*) [TopologicalSpace α]
[TopologicalSpace β] extends ContinuousMapClass F α β where
/-- The cocompact filter on `α` tends to the cocompact filter on `β` under the function -/
cocompact_tendsto (f : F) : Tendsto f (cocompact α) (cocompact β)
@@ -51,7 +51,7 @@ end
namespace CocompactMapClass
-variable {F α β : Type _} [TopologicalSpace α] [TopologicalSpace β] [CocompactMapClass F α β]
+variable {F α β : Type*} [TopologicalSpace α] [TopologicalSpace β] [CocompactMapClass F α β]
instance : CoeTC F (CocompactMap α β) :=
⟨fun f => ⟨f, cocompact_tendsto f⟩⟩
@@ -64,7 +64,7 @@ namespace CocompactMap
section Basics
-variable {α β γ δ : Type _} [TopologicalSpace α] [TopologicalSpace β] [TopologicalSpace γ]
+variable {α β γ δ : Type*} [TopologicalSpace α] [TopologicalSpace β] [TopologicalSpace γ]
[TopologicalSpace δ]
instance : CocompactMapClass (CocompactMap α β) α β where
@@ -197,7 +197,7 @@ end CocompactMap
/-- A homeomorphism is a cocompact map. -/
@[simps]
-def Homeomorph.toCocompactMap {α β : Type _} [TopologicalSpace α] [TopologicalSpace β]
+def Homeomorph.toCocompactMap {α β : Type*} [TopologicalSpace α] [TopologicalSpace β]
(f : α ≃ₜ β) : CocompactMap α β where
toFun := f
continuous_toFun := f.continuous
@@ -2,14 +2,11 @@
Copyright (c) 2022 Jireh Loreaux. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jireh Loreaux
-
-! This file was ported from Lean 3 source module topology.continuous_function.cocompact_map
-! leanprover-community/mathlib commit 0a0ec35061ed9960bf0e7ffb0335f44447b58977
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.Topology.ContinuousFunction.Basic
+#align_import topology.continuous_function.cocompact_map from "leanprover-community/mathlib"@"0a0ec35061ed9960bf0e7ffb0335f44447b58977"
+
/-!
# Cocompact continuous maps
@@ -198,7 +198,7 @@ end Basics
end CocompactMap
-/-- A homemomorphism is a cocompact map. -/
+/-- A homeomorphism is a cocompact map. -/
@[simps]
def Homeomorph.toCocompactMap {α β : Type _} [TopologicalSpace α] [TopologicalSpace β]
(f : α ≃ₜ β) : CocompactMap α β where
by
s! (#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 by
s".
@@ -204,8 +204,7 @@ def Homeomorph.toCocompactMap {α β : Type _} [TopologicalSpace α] [Topologica
(f : α ≃ₜ β) : CocompactMap α β where
toFun := f
continuous_toFun := f.continuous
- cocompact_tendsto' :=
- by
+ cocompact_tendsto' := by
refine' CocompactMap.tendsto_of_forall_preimage fun K hK => _
erw [K.preimage_equiv_eq_image_symm]
exact hK.image f.symm.continuous
@@ -70,8 +70,7 @@ section Basics
variable {α β γ δ : Type _} [TopologicalSpace α] [TopologicalSpace β] [TopologicalSpace γ]
[TopologicalSpace δ]
-instance : CocompactMapClass (CocompactMap α β) α β
- where
+instance : CocompactMapClass (CocompactMap α β) α β where
coe f := f.toFun
coe_injective' f g h := by
obtain ⟨⟨_, _⟩, _⟩ := f
@@ -87,9 +86,9 @@ instance : CoeFun (CocompactMap α β) fun _ => α → β :=
FunLike.hasCoeToFun-/
@[simp]
-theorem coe_to_continuous_fun {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
+theorem coe_toContinuousMap {f : CocompactMap α β} : (f.toContinuousMap : α → β) = f :=
rfl
-#align cocompact_map.coe_to_continuous_fun CocompactMap.coe_to_continuous_fun
+#align cocompact_map.coe_to_continuous_fun CocompactMap.coe_toContinuousMap
@[ext]
theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
@@ -98,8 +97,7 @@ theorem ext {f g : CocompactMap α β} (h : ∀ x, f x = g x) : f = g :=
/-- Copy of a `CocompactMap` with a new `toFun` equal to the old one. Useful
to fix definitional equalities. -/
-protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : CocompactMap α β
- where
+protected def copy (f : CocompactMap α β) (f' : α → β) (h : f' = f) : CocompactMap α β where
toFun := f'
continuous_toFun := by
rw [h]
The unported dependencies are