File: Mathlib/CategoryTheory/Sites/CoverLifting.lean

full_name: CategoryTheory.Functor.IsCocontinuous.cover_lift
code: /-- A functor `G : (C, J) ⥤ (D, K)` between sites is called cocontinuous (SGA 4 III 2.1)
if for all covering sieves `R` in `D`, `R.pullback G` is a covering sieve in `C`.
-/
-- Porting note(#5171): removed `@[nolint has_nonempty_instance]`
class Functor.IsCocontinuous : Prop where
  cover_lift : ∀ {U : C} {S : Sieve (G.obj U)} (_ : S ∈ K (G.obj U)), S.functorPullback G ∈ J U
goal: S ∈ K.sieves (G.obj U) → CategoryTheory.Sieve.functorPullback G S ∈ J.sieves U

full_name: CategoryTheory.Functor.IsCocontinuous
code: /-- A functor `G : (C, J) ⥤ (D, K)` between sites is called cocontinuous (SGA 4 III 2.1)
if for all covering sieves `R` in `D`, `R.pullback G` is a covering sieve in `C`.
-/
-- Porting note(#5171): removed `@[nolint has_nonempty_instance]`
class Functor.IsCocontinuous : Prop where
  cover_lift : ∀ {U : C} {S : Sieve (G.obj U)} (_ : S ∈ K (G.obj U)), S.functorPullback G ∈ J U
goal: Prop

full_name: CategoryTheory.Functor.cover_lift
code: lemma Functor.cover_lift [G.IsCocontinuous J K] {U : C} {S : Sieve (G.obj U)}
    (hS : S ∈ K (G.obj U)) : S.functorPullback G ∈ J U 
goal: CategoryTheory.Sieve.functorPullback G S ∈ J.sieves U

full_name: CategoryTheory.isCocontinuous_id
code: /-- The identity functor on a site is cocontinuous. -/
instance isCocontinuous_id : Functor.IsCocontinuous (𝟭 C) J J 
goal: (𝟭 C).IsCocontinuous J J

full_name: CategoryTheory.isCocontinuous_comp
code: /-- The composition of two cocontinuous functors is cocontinuous. -/
theorem isCocontinuous_comp [G.IsCocontinuous J K] [G'.IsCocontinuous K L] :
    (G ⋙ G').IsCocontinuous J L 
goal: (G ⋙ G').IsCocontinuous J L

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux
code: /-- Auxiliary definition for `lift`. -/
def liftAux {Y : C} (f : G.obj Y ⟶ X) : s.pt ⟶ F.obj (op Y) 
goal: s.pt ⟶ F.obj (Opposite.op Y)

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux_map
code: lemma liftAux_map {Y : C} (f : G.obj Y ⟶ X) {W : C} (g : W ⟶ Y) (i : S.Arrow)
    (h : G.obj W ⟶ i.Y) (w : h ≫ i.f = G.map g ≫ f) :
    liftAux hF α s f ≫ F.map g.op = s.ι i ≫ R.map h.op ≫ α.app _ 
goal: CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux hF α s f ≫ F.map g.op = s.ι i ≫ R.map h.op ≫ α.app (Opposite.op W)

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux_map'
code: lemma liftAux_map' {Y Y' : C} (f : G.obj Y ⟶ X) (f' : G.obj Y' ⟶ X) {W : C}
    (a : W ⟶ Y) (b : W ⟶ Y') (w : G.map a ≫ f = G.map b ≫ f') :
    liftAux hF α s f ≫ F.map a.op = liftAux hF α s f' ≫ F.map b.op 
goal: CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux hF α s f ≫ F.map a.op =
  CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux hF α s f' ≫ F.map b.op

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.lift
code: /-- Auxiliary definition for `isLimitMultifork` -/
def lift : s.pt ⟶ R.obj (op X) 
goal: s.pt ⟶ R.obj (Opposite.op X)

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.fac'
code: lemma fac' (j : StructuredArrow (op X) G.op) :
    lift hF hR s ≫ R.map j.hom ≫ α.app j.right = liftAux hF α s j.hom.unop 
goal: CategoryTheory.RanIsSheafOfIsCocontinuous.lift hF hR s ≫ R.map j.hom ≫ α.app j.right =
  CategoryTheory.RanIsSheafOfIsCocontinuous.liftAux hF α s j.hom.unop

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.fac
code: @[reassoc (attr := simp)]
lemma fac (i : S.Arrow) : lift hF hR s ≫ R.map i.f.op = s.ι i 
goal: CategoryTheory.RanIsSheafOfIsCocontinuous.lift hF hR s ≫ R.map i.f.op = s.ι i

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.hom_ext
code: lemma hom_ext {W : A} {f g : W ⟶ R.obj (op X)}
    (h : ∀ (i : S.Arrow), f ≫ R.map i.f.op = g ≫ R.map i.f.op) : f = g 
goal: f = g

full_name: CategoryTheory.RanIsSheafOfIsCocontinuous.isLimitMultifork
code: /-- Auxiliary definition for `ran_isSheaf_of_isCocontinuous`: if `G : C ⥤ D` is a
cocontinuous functor,   -/
def isLimitMultifork : IsLimit (S.multifork R) 
goal: CategoryTheory.Limits.IsLimit (S.multifork R)

full_name: CategoryTheory.ran_isSheaf_of_isCocontinuous
code: /-- If `G` is cocontinuous, then `G.op.ran` pushes sheaves to sheaves.

This is SGA 4 III 2.2. An alternative reference is
https://stacks.math.columbia.edu/tag/00XK (where results
are obtained under the additional assumption that
`C` and `D` have pullbacks).
-/
theorem ran_isSheaf_of_isCocontinuous (ℱ : Sheaf J A) :
    Presheaf.IsSheaf K (G.op.ran.obj ℱ.val) 
goal: CategoryTheory.Presheaf.IsSheaf K (G.op.ran.obj ℱ.val)

full_name: CategoryTheory.Functor.sheafPushforwardCocontinuous
code: /-- A cocontinuous functor induces a pushforward functor on categories of sheaves. -/
def Functor.sheafPushforwardCocontinuous : Sheaf J A ⥤ Sheaf K A 
goal: CategoryTheory.Sheaf J A ⥤ CategoryTheory.Sheaf K A

full_name: CategoryTheory.Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso
code: /-- `G.sheafPushforwardCocontinuous A J K : Sheaf J A ⥤ Sheaf K A` is induced
by the right Kan extension functor `G.op.ran` on presheaves. -/
@[simps! hom inv]
def Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso :
    G.sheafPushforwardCocontinuous A J K ⋙ sheafToPresheaf K A ≅
      sheafToPresheaf J A ⋙ G.op.ran 
goal: G.sheafPushforwardCocontinuous A J K ⋙ CategoryTheory.sheafToPresheaf K A ≅
  CategoryTheory.sheafToPresheaf J A ⋙ G.op.ran

full_name: CategoryTheory.Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso_hom
code: /-- `G.sheafPushforwardCocontinuous A J K : Sheaf J A ⥤ Sheaf K A` is induced
by the right Kan extension functor `G.op.ran` on presheaves. -/
@[simps! hom inv]
def Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso :
    G.sheafPushforwardCocontinuous A J K ⋙ sheafToPresheaf K A ≅
      sheafToPresheaf J A ⋙ G.op.ran 
goal: (G.sheafPushforwardCocontinuousCompSheafToPresheafIso A J K).hom =
  𝟙 (G.sheafPushforwardCocontinuous A J K ⋙ CategoryTheory.sheafToPresheaf K A)

full_name: CategoryTheory.Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso_inv
code: /-- `G.sheafPushforwardCocontinuous A J K : Sheaf J A ⥤ Sheaf K A` is induced
by the right Kan extension functor `G.op.ran` on presheaves. -/
@[simps! hom inv]
def Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso :
    G.sheafPushforwardCocontinuous A J K ⋙ sheafToPresheaf K A ≅
      sheafToPresheaf J A ⋙ G.op.ran 
goal: (G.sheafPushforwardCocontinuousCompSheafToPresheafIso A J K).inv =
  𝟙 (G.sheafPushforwardCocontinuous A J K ⋙ CategoryTheory.sheafToPresheaf K A)

full_name: CategoryTheory.Functor.sheafAdjunctionCocontinuous
code: /--
Given a functor between sites that is continuous and cocontinuous,
the pushforward for the continuous functor `G` is left adjoint to
the pushforward for the cocontinuous functor `G`. -/
noncomputable def sheafAdjunctionCocontinuous :
    G.sheafPushforwardContinuous A J K ⊣ G.sheafPushforwardCocontinuous A J K 
goal: G.sheafPushforwardContinuous A J K ⊣ G.sheafPushforwardCocontinuous A J K

full_name: CategoryTheory.Functor.sheafAdjunctionCocontinuous_unit_app_val
code: lemma sheafAdjunctionCocontinuous_unit_app_val (F : Sheaf K A) :
    ((G.sheafAdjunctionCocontinuous A J K).unit.app F).val =
      (G.op.ranAdjunction A).unit.app F.val 
goal: ((G.sheafAdjunctionCocontinuous A J K).unit.app F).val = (G.op.ranAdjunction A).unit.app F.val

full_name: CategoryTheory.Functor.sheafAdjunctionCocontinuous_counit_app_val
code: lemma sheafAdjunctionCocontinuous_counit_app_val (F : Sheaf J A) :
    ((G.sheafAdjunctionCocontinuous A J K).counit.app F).val =
      (G.op.ranAdjunction A).counit.app F.val 
goal: ((G.sheafAdjunctionCocontinuous A J K).counit.app F).val = (G.op.ranAdjunction A).counit.app F.val

full_name: CategoryTheory.Functor.sheafAdjunctionCocontinuous_homEquiv_apply_val
code: lemma sheafAdjunctionCocontinuous_homEquiv_apply_val {F : Sheaf K A} {H : Sheaf J A}
    (f : (G.sheafPushforwardContinuous A J K).obj F ⟶ H) :
    ((G.sheafAdjunctionCocontinuous A J K).homEquiv F H f).val =
      (G.op.ranAdjunction A).homEquiv F.val H.val f.val 
goal: (((G.sheafAdjunctionCocontinuous A J K).homEquiv F H) f).val = ((G.op.ranAdjunction A).homEquiv F.val H.val) f.val

full_name: CategoryTheory.Functor.pushforwardContinuousSheafificationCompatibility
code: /-- The natural isomorphism exhibiting compatibility between pushforward and sheafification. -/
def pushforwardContinuousSheafificationCompatibility :
    (whiskeringLeft _ _ A).obj G.op ⋙ presheafToSheaf J A ≅
    presheafToSheaf K A ⋙ G.sheafPushforwardContinuous A J K 
goal: (CategoryTheory.whiskeringLeft Cᵒᵖ Dᵒᵖ A).obj G.op ⋙ CategoryTheory.presheafToSheaf J A ≅
  CategoryTheory.presheafToSheaf K A ⋙ G.sheafPushforwardContinuous A J K

full_name: CategoryTheory.Functor.toSheafify_pullbackSheafificationCompatibility
code: lemma toSheafify_pullbackSheafificationCompatibility (F : Dᵒᵖ ⥤ A) :
    toSheafify J (G.op ⋙ F) ≫
    ((G.pushforwardContinuousSheafificationCompatibility A J K).hom.app F).val =
    whiskerLeft _ (toSheafify K _) 
goal: CategoryTheory.toSheafify J (G.op ⋙ F) ≫ ((G.pushforwardContinuousSheafificationCompatibility A J K).hom.app F).val =
  CategoryTheory.whiskerLeft G.op (CategoryTheory.toSheafify K F)

full_name: CategoryTheory.Functor.pushforwardContinuousSheafificationCompatibility_hom_app_val
code: @[simp]
lemma pushforwardContinuousSheafificationCompatibility_hom_app_val (F : Dᵒᵖ ⥤ A) :
    ((G.pushforwardContinuousSheafificationCompatibility A J K).hom.app F).val =
    sheafifyLift J (whiskerLeft G.op <| toSheafify K F)
      ((presheafToSheaf K A ⋙ G.sheafPushforwardContinuous A J K).obj F).cond 
goal: ((G.pushforwardContinuousSheafificationCompatibility A J K).hom.app F).val =
  CategoryTheory.sheafifyLift J (CategoryTheory.whiskerLeft G.op (CategoryTheory.toSheafify K F)) ⋯