File: Mathlib/CategoryTheory/Sites/Sieves.lean

full_name: CategoryTheory.Presieve
code: /-- A set of arrows all with codomain `X`. -/
def Presieve (X : C) 
goal: Type (max u₁ v₁)

full_name: CategoryTheory.instCompleteLatticePresieve
code: instance : CompleteLattice (Presieve X) 
goal: CompleteLattice (CategoryTheory.Presieve X)

full_name: CategoryTheory.Presieve.instInhabited
code: noncomputable instance : Inhabited (Presieve X) 
goal: Inhabited (CategoryTheory.Presieve X)

full_name: CategoryTheory.Presieve.category
code: /-- The full subcategory of the over category `C/X` consisting of arrows which belong to a
    presieve on `X`. -/
abbrev category {X : C} (P : Presieve X) 
goal: Type (max u₁ v₁)

full_name: CategoryTheory.Presieve.categoryMk
code: /-- Construct an object of `P.category`. -/
abbrev categoryMk {X : C} (P : Presieve X) {Y : C} (f : Y ⟶ X) (hf : P f) : P.category 
goal: P.category

full_name: CategoryTheory.Presieve.diagram
code: /-- Given a sieve `S` on `X : C`, its associated diagram `S.diagram` is defined to be
    the natural functor from the full subcategory of the over category `C/X` consisting
    of arrows in `S` to `C`. -/
abbrev diagram (S : Presieve X) : S.category ⥤ C 
goal: CategoryTheory.Functor S.category C

full_name: CategoryTheory.Presieve.cocone
code: /-- Given a sieve `S` on `X : C`, its associated cocone `S.cocone` is defined to be
    the natural cocone over the diagram defined above with cocone point `X`. -/
abbrev cocone (S : Presieve X) : Cocone S.diagram 
goal: CategoryTheory.Limits.Cocone S.diagram

full_name: CategoryTheory.Presieve.bind
code: /-- Given a set of arrows `S` all with codomain `X`, and a set of arrows with codomain `Y` for each
`f : Y ⟶ X` in `S`, produce a set of arrows with codomain `X`:
`{ g ≫ f | (f : Y ⟶ X) ∈ S, (g : Z ⟶ Y) ∈ R f }`.
-/
def bind (S : Presieve X) (R : ∀ ⦃Y⦄ ⦃f : Y ⟶ X⦄, S f → Presieve Y) : Presieve X 
goal: CategoryTheory.Presieve X

full_name: CategoryTheory.Presieve.bind_comp
code: @[simp]
theorem bind_comp {S : Presieve X} {R : ∀ ⦃Y : C⦄ ⦃f : Y ⟶ X⦄, S f → Presieve Y} {g : Z ⟶ Y}
    (h₁ : S f) (h₂ : R h₁ g) : bind S R (g ≫ f) 
goal: S.bind R (CategoryTheory.CategoryStruct.comp g f)

full_name: CategoryTheory.Presieve.singleton'.mk
code: /-- The singleton presieve.  -/
inductive singleton' : ⦃Y : C⦄ → (Y ⟶ X) → Prop
  | mk : singleton' f
goal: CategoryTheory.Presieve.singleton' f f

full_name: CategoryTheory.Presieve.singleton'
code: /-- The singleton presieve.  -/
inductive singleton' : ⦃Y : C⦄ → (Y ⟶ X) → Prop
  | mk : singleton' f
goal: ⦃Y : C⦄ → (Y ⟶ X) → Prop

full_name: CategoryTheory.Presieve.singleton
code: /-- The singleton presieve.  -/
def singleton : Presieve X 
goal: CategoryTheory.Presieve X

full_name: CategoryTheory.Presieve.singleton.mk
code: lemma singleton.mk {f : Y ⟶ X} : singleton f f 
goal: CategoryTheory.Presieve.singleton f f

full_name: CategoryTheory.Presieve.singleton_eq_iff_domain
code: @[simp]
theorem singleton_eq_iff_domain (f g : Y ⟶ X) : singleton f g ↔ f = g 
goal: CategoryTheory.Presieve.singleton f g ↔ f = g

full_name: CategoryTheory.Presieve.singleton_self
code: theorem singleton_self : singleton f f 
goal: CategoryTheory.Presieve.singleton f f

full_name: CategoryTheory.Presieve.pullbackArrows
code: /-- Pullback a set of arrows with given codomain along a fixed map, by taking the pullback in the
category.
This is not the same as the arrow set of `Sieve.pullback`, but there is a relation between them
in `pullbackArrows_comm`.
-/
inductive pullbackArrows [HasPullbacks C] (R : Presieve X) : Presieve Y
  | mk (Z : C) (h : Z ⟶ X) : R h → pullbackArrows _ (pullback.snd h f)
goal: CategoryTheory.Presieve Y

full_name: CategoryTheory.Presieve.pullbackArrows.mk
code: /-- Pullback a set of arrows with given codomain along a fixed map, by taking the pullback in the
category.
This is not the same as the arrow set of `Sieve.pullback`, but there is a relation between them
in `pullbackArrows_comm`.
-/
inductive pullbackArrows [HasPullbacks C] (R : Presieve X) : Presieve Y
  | mk (Z : C) (h : Z ⟶ X) : R h → pullbackArrows _ (pullback.snd h f)
goal: R h → CategoryTheory.Presieve.pullbackArrows f R (CategoryTheory.Limits.pullback.snd h f)

full_name: CategoryTheory.Presieve.pullback_singleton
code: theorem pullback_singleton [HasPullbacks C] (g : Z ⟶ X) :
    pullbackArrows f (singleton g) = singleton (pullback.snd g f) 
goal: CategoryTheory.Presieve.pullbackArrows f (CategoryTheory.Presieve.singleton g) =
  CategoryTheory.Presieve.singleton (CategoryTheory.Limits.pullback.snd g f)

full_name: CategoryTheory.Presieve.ofArrows
code: /-- Construct the presieve given by the family of arrows indexed by `ι`. -/
inductive ofArrows {ι : Type*} (Y : ι → C) (f : ∀ i, Y i ⟶ X) : Presieve X
  | mk (i : ι) : ofArrows _ _ (f i)
goal: CategoryTheory.Presieve X

full_name: CategoryTheory.Presieve.ofArrows.mk
code: /-- Construct the presieve given by the family of arrows indexed by `ι`. -/
inductive ofArrows {ι : Type*} (Y : ι → C) (f : ∀ i, Y i ⟶ X) : Presieve X
  | mk (i : ι) : ofArrows _ _ (f i)
goal: CategoryTheory.Presieve.ofArrows Y f (f i)

full_name: CategoryTheory.Presieve.ofArrows_pUnit
code: theorem ofArrows_pUnit : (ofArrows _ fun _ : PUnit => f) = singleton f 
goal: (CategoryTheory.Presieve.ofArrows (fun x => Y) fun x => f) = CategoryTheory.Presieve.singleton f

full_name: CategoryTheory.Presieve.ofArrows_pullback
code: theorem ofArrows_pullback [HasPullbacks C] {ι : Type*} (Z : ι → C) (g : ∀ i : ι, Z i ⟶ X) :
    (ofArrows (fun i => pullback (g i) f) fun i => pullback.snd _ _) =
      pullbackArrows f (ofArrows Z g) 
goal: (CategoryTheory.Presieve.ofArrows (fun i => CategoryTheory.Limits.pullback (g i) f) fun i =>
    CategoryTheory.Limits.pullback.snd (g i) f) =
  CategoryTheory.Presieve.pullbackArrows f (CategoryTheory.Presieve.ofArrows Z g)

full_name: CategoryTheory.Presieve.ofArrows_bind
code: theorem ofArrows_bind {ι : Type*} (Z : ι → C) (g : ∀ i : ι, Z i ⟶ X)
    (j : ∀ ⦃Y⦄ (f : Y ⟶ X), ofArrows Z g f → Type*) (W : ∀ ⦃Y⦄ (f : Y ⟶ X) (H), j f H → C)
    (k : ∀ ⦃Y⦄ (f : Y ⟶ X) (H i), W f H i ⟶ Y) :
    ((ofArrows Z g).bind fun Y f H => ofArrows (W f H) (k f H)) =
      ofArrows (fun i : Σi, j _ (ofArrows.mk i) => W (g i.1) _ i.2) fun ij =>
        k (g ij.1) _ ij.2 ≫ g ij.1 
goal: ((CategoryTheory.Presieve.ofArrows Z g).bind fun Y f H => CategoryTheory.Presieve.ofArrows (W f H) (k f H)) =
  CategoryTheory.Presieve.ofArrows (fun i => W (g i.fst) ⋯ i.snd) fun ij =>
    CategoryTheory.CategoryStruct.comp (k (g ij.fst) ⋯ ij.snd) (g ij.fst)

full_name: CategoryTheory.Presieve.ofArrows_surj
code: theorem ofArrows_surj {ι : Type*} {Y : ι → C} (f : ∀ i, Y i ⟶ X) {Z : C} (g : Z ⟶ X)
    (hg : ofArrows Y f g) : ∃ (i : ι) (h : Y i = Z),
    g = eqToHom h.symm ≫ f i 
goal: ∃ i, ∃ (h : Y i = Z), g = CategoryTheory.CategoryStruct.comp (CategoryTheory.eqToHom ⋯) (f i)

full_name: CategoryTheory.Presieve.functorPullback
code: /-- Given a presieve on `F(X)`, we can define a presieve on `X` by taking the preimage via `F`. -/
def functorPullback (R : Presieve (F.obj X)) : Presieve X 
goal: CategoryTheory.Presieve X

full_name: CategoryTheory.Presieve.functorPullback_mem
code: @[simp]
theorem functorPullback_mem (R : Presieve (F.obj X)) {Y} (f : Y ⟶ X) :
    R.functorPullback F f ↔ R (F.map f) 
goal: CategoryTheory.Presieve.functorPullback F R f ↔ R (F.map f)

full_name: CategoryTheory.Presieve.functorPullback_id
code: @[simp]
theorem functorPullback_id (R : Presieve X) : R.functorPullback (𝟭 _) = R 
goal: CategoryTheory.Presieve.functorPullback (CategoryTheory.Functor.id C) R = R

full_name: CategoryTheory.Presieve.hasPullbacks
code: /-- Given a presieve `R` on `X`, the predicate `R.hasPullbacks` means that for all arrows `f` and
    `g` in `R`, the pullback of `f` and `g` exists. -/
class hasPullbacks (R : Presieve X) : Prop where
  /-- For all arrows `f` and `g` in `R`, the pullback of `f` and `g` exists. -/
  has_pullbacks : ∀ {Y Z} {f : Y ⟶ X} (_ : R f) {g : Z ⟶ X} (_ : R g), HasPullback f g
goal: Prop

full_name: CategoryTheory.Presieve.hasPullbacks.has_pullbacks
code: /-- Given a presieve `R` on `X`, the predicate `R.hasPullbacks` means that for all arrows `f` and
    `g` in `R`, the pullback of `f` and `g` exists. -/
class hasPullbacks (R : Presieve X) : Prop where
  /-- For all arrows `f` and `g` in `R`, the pullback of `f` and `g` exists. -/
  has_pullbacks : ∀ {Y Z} {f : Y ⟶ X} (_ : R f) {g : Z ⟶ X} (_ : R g), HasPullback f g
goal: R f → ∀ {g : Z ⟶ X}, R g → CategoryTheory.Limits.HasPullback f g

full_name: CategoryTheory.Presieve.instHasPullbacksOfHasPullbacks
code: instance (R : Presieve X) [HasPullbacks C] : R.hasPullbacks 
goal: R.hasPullbacks

full_name: CategoryTheory.Presieve.instHasPullbackOfHasPullbacksOfArrows
code: instance {α : Type v₂} {X : α → C} {B : C} (π : (a : α) → X a ⟶ B)
    [(Presieve.ofArrows X π).hasPullbacks] (a b : α) : HasPullback (π a) (π b) 
goal: CategoryTheory.Limits.HasPullback (π a) (π b)

full_name: CategoryTheory.Presieve.functorPushforward
code: /-- Given a presieve on `X`, we can define a presieve on `F(X)` (which is actually a sieve)
by taking the sieve generated by the image via `F`.
-/
def functorPushforward (S : Presieve X) : Presieve (F.obj X) 
goal: CategoryTheory.Presieve (F.obj X)

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure.cover
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: S self.premap

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure.lift
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: Y ⟶ F.obj self.preobj

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure.preobj
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: C

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure.premap
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: self.preobj ⟶ X

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure.fac
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: f = CategoryTheory.CategoryStruct.comp self.lift (F.map self.premap)

full_name: CategoryTheory.Presieve.FunctorPushforwardStructure
code: /-- An auxiliary definition in order to fix the choice of the preimages between various definitions.
-/
structure FunctorPushforwardStructure (S : Presieve X) {Y} (f : Y ⟶ F.obj X) where
  /-- an object in the source category -/
  preobj : C
  /-- a map in the source category which has to be in the presieve -/
  premap : preobj ⟶ X
  /-- the morphism which appear in the factorisation -/
  lift : Y ⟶ F.obj preobj
  /-- the condition that `premap` is in the presieve -/
  cover : S premap
  /-- the factorisation of the morphism -/
  fac : f = lift ≫ F.map premap
goal: Type (max (max u₁ v₁) v₂)

full_name: CategoryTheory.Presieve.getFunctorPushforwardStructure
code: /-- The fixed choice of a preimage. -/
noncomputable def getFunctorPushforwardStructure {F : C ⥤ D} {S : Presieve X} {Y : D}
    {f : Y ⟶ F.obj X} (h : S.functorPushforward F f) : FunctorPushforwardStructure F S f 
goal: CategoryTheory.Presieve.FunctorPushforwardStructure F S f

full_name: CategoryTheory.Presieve.functorPushforward_comp
code: theorem functorPushforward_comp (R : Presieve X) :
    R.functorPushforward (F ⋙ G) = (R.functorPushforward F).functorPushforward G 
goal: CategoryTheory.Presieve.functorPushforward (F.comp G) R =
  CategoryTheory.Presieve.functorPushforward G (CategoryTheory.Presieve.functorPushforward F R)

full_name: CategoryTheory.Presieve.image_mem_functorPushforward
code: theorem image_mem_functorPushforward (R : Presieve X) {f : Y ⟶ X} (h : R f) :
    R.functorPushforward F (F.map f) 
goal: CategoryTheory.Presieve.functorPushforward F R (F.map f)

full_name: CategoryTheory.Sieve.downward_closed
code: /--
For an object `X` of a category `C`, a `Sieve X` is a set of morphisms to `X` which is closed under
left-composition.
-/
structure Sieve {C : Type u₁} [Category.{v₁} C] (X : C) where
  /-- the underlying presieve -/
  arrows : Presieve X
  /-- stability by precomposition -/
  downward_closed : ∀ {Y Z f} (_ : arrows f) (g : Z ⟶ Y), arrows (g ≫ f)
goal: self.arrows f → ∀ (g : Z ⟶ Y), self.arrows (CategoryTheory.CategoryStruct.comp g f)

full_name: CategoryTheory.Sieve.arrows
code: /--
For an object `X` of a category `C`, a `Sieve X` is a set of morphisms to `X` which is closed under
left-composition.
-/
structure Sieve {C : Type u₁} [Category.{v₁} C] (X : C) where
  /-- the underlying presieve -/
  arrows : Presieve X
  /-- stability by precomposition -/
  downward_closed : ∀ {Y Z f} (_ : arrows f) (g : Z ⟶ Y), arrows (g ≫ f)
goal: CategoryTheory.Presieve X

full_name: CategoryTheory.Sieve
code: /--
For an object `X` of a category `C`, a `Sieve X` is a set of morphisms to `X` which is closed under
left-composition.
-/
structure Sieve {C : Type u₁} [Category.{v₁} C] (X : C) where
  /-- the underlying presieve -/
  arrows : Presieve X
  /-- stability by precomposition -/
  downward_closed : ∀ {Y Z f} (_ : arrows f) (g : Z ⟶ Y), arrows (g ≫ f)
goal: Type (max u₁ v₁)

full_name: CategoryTheory.Sieve.instCoeFunPresieve
code: instance : CoeFun (Sieve X) fun _ => Presieve X 
goal: CoeFun (CategoryTheory.Sieve X) fun x => CategoryTheory.Presieve X

full_name: CategoryTheory.Sieve.arrows_ext
code: theorem arrows_ext : ∀ {R S : Sieve X}, R.arrows = S.arrows → R = S 
goal: R.arrows = S.arrows → R = S

full_name: CategoryTheory.Sieve.ext
code: @[ext]
protected theorem ext {R S : Sieve X} (h : ∀ ⦃Y⦄ (f : Y ⟶ X), R f ↔ S f) : R = S 
goal: R = S

full_name: CategoryTheory.Sieve.ext_iff
code: protected theorem ext_iff {R S : Sieve X} : R = S ↔ ∀ ⦃Y⦄ (f : Y ⟶ X), R f ↔ S f 
goal: R = S ↔ ∀ ⦃Y : C⦄ (f : Y ⟶ X), R.arrows f ↔ S.arrows f

full_name: CategoryTheory.Sieve.sup
code: /-- The supremum of a collection of sieves: the union of them all. -/
protected def sup (𝒮 : Set (Sieve X)) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.inf
code: /-- The infimum of a collection of sieves: the intersection of them all. -/
protected def inf (𝒮 : Set (Sieve X)) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.union
code: /-- The union of two sieves is a sieve. -/
protected def union (S R : Sieve X) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.inter
code: /-- The intersection of two sieves is a sieve. -/
protected def inter (S R : Sieve X) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.instCompleteLattice
code: /-- Sieves on an object `X` form a complete lattice.
We generate this directly rather than using the galois insertion for nicer definitional properties.
-/
instance : CompleteLattice (Sieve X) 
goal: CompleteLattice (CategoryTheory.Sieve X)

full_name: CategoryTheory.Sieve.sieveInhabited
code: /-- The maximal sieve always exists. -/
instance sieveInhabited : Inhabited (Sieve X) 
goal: Inhabited (CategoryTheory.Sieve X)

full_name: CategoryTheory.Sieve.sInf_apply
code: @[simp]
theorem sInf_apply {Ss : Set (Sieve X)} {Y} (f : Y ⟶ X) :
    sInf Ss f ↔ ∀ (S : Sieve X) (_ : S ∈ Ss), S f 
goal: (sInf Ss).arrows f ↔ ∀ S ∈ Ss, S.arrows f

full_name: CategoryTheory.Sieve.sSup_apply
code: @[simp]
theorem sSup_apply {Ss : Set (Sieve X)} {Y} (f : Y ⟶ X) :
    sSup Ss f ↔ ∃ (S : Sieve X) (_ : S ∈ Ss), S f 
goal: (sSup Ss).arrows f ↔ ∃ S, ∃ (_ : S ∈ Ss), S.arrows f

full_name: CategoryTheory.Sieve.inter_apply
code: @[simp]
theorem inter_apply {R S : Sieve X} {Y} (f : Y ⟶ X) : (R ⊓ S) f ↔ R f ∧ S f 
goal: (R ⊓ S).arrows f ↔ R.arrows f ∧ S.arrows f

full_name: CategoryTheory.Sieve.union_apply
code: @[simp]
theorem union_apply {R S : Sieve X} {Y} (f : Y ⟶ X) : (R ⊔ S) f ↔ R f ∨ S f 
goal: (R ⊔ S).arrows f ↔ R.arrows f ∨ S.arrows f

full_name: CategoryTheory.Sieve.top_apply
code: @[simp]
theorem top_apply (f : Y ⟶ X) : (⊤ : Sieve X) f 
goal: ⊤.arrows f

full_name: CategoryTheory.Sieve.generate_apply
code: /-- Generate the smallest sieve containing the given set of arrows. -/
@[simps]
def generate (R : Presieve X) : Sieve X 
goal: (CategoryTheory.Sieve.generate R).arrows f = ∃ Y h g, R g ∧ CategoryTheory.CategoryStruct.comp h g = f

full_name: CategoryTheory.Sieve.generate
code: /-- Generate the smallest sieve containing the given set of arrows. -/
@[simps]
def generate (R : Presieve X) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.bind_apply
code: /-- Given a presieve on `X`, and a sieve on each domain of an arrow in the presieve, we can bind to
produce a sieve on `X`.
-/
@[simps]
def bind (S : Presieve X) (R : ∀ ⦃Y⦄ ⦃f : Y ⟶ X⦄, S f → Sieve Y) : Sieve X 
goal: (CategoryTheory.Sieve.bind S R).arrows = S.bind fun Y f h => (R h).arrows

full_name: CategoryTheory.Sieve.bind
code: /-- Given a presieve on `X`, and a sieve on each domain of an arrow in the presieve, we can bind to
produce a sieve on `X`.
-/
@[simps]
def bind (S : Presieve X) (R : ∀ ⦃Y⦄ ⦃f : Y ⟶ X⦄, S f → Sieve Y) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.generate_le_iff
code: theorem generate_le_iff (R : Presieve X) (S : Sieve X) : generate R ≤ S ↔ R ≤ S 
goal: CategoryTheory.Sieve.generate R ≤ S ↔ R ≤ S.arrows

full_name: CategoryTheory.Sieve.giGenerate
code: /-- Show that there is a galois insertion (generate, set_over). -/
def giGenerate : GaloisInsertion (generate : Presieve X → Sieve X) arrows 
goal: GaloisInsertion CategoryTheory.Sieve.generate CategoryTheory.Sieve.arrows

full_name: CategoryTheory.Sieve.le_generate
code: theorem le_generate (R : Presieve X) : R ≤ generate R 
goal: R ≤ (CategoryTheory.Sieve.generate R).arrows

full_name: CategoryTheory.Sieve.generate_sieve
code: @[simp]
theorem generate_sieve (S : Sieve X) : generate S = S 
goal: CategoryTheory.Sieve.generate S.arrows = S

full_name: CategoryTheory.Sieve.id_mem_iff_eq_top
code: /-- If the identity arrow is in a sieve, the sieve is maximal. -/
theorem id_mem_iff_eq_top : S (𝟙 X) ↔ S = ⊤ 
goal: S.arrows (CategoryTheory.CategoryStruct.id X) ↔ S = ⊤

full_name: CategoryTheory.Sieve.generate_of_contains_isSplitEpi
code: /-- If an arrow set contains a split epi, it generates the maximal sieve. -/
theorem generate_of_contains_isSplitEpi {R : Presieve X} (f : Y ⟶ X) [IsSplitEpi f] (hf : R f) :
    generate R = ⊤ 
goal: CategoryTheory.Sieve.generate R = ⊤

full_name: CategoryTheory.Sieve.generate_of_singleton_isSplitEpi
code: @[simp]
theorem generate_of_singleton_isSplitEpi (f : Y ⟶ X) [IsSplitEpi f] :
    generate (Presieve.singleton f) = ⊤ 
goal: CategoryTheory.Sieve.generate (CategoryTheory.Presieve.singleton f) = ⊤

full_name: CategoryTheory.Sieve.generate_top
code: @[simp]
theorem generate_top : generate (⊤ : Presieve X) = ⊤ 
goal: CategoryTheory.Sieve.generate ⊤ = ⊤

full_name: CategoryTheory.Sieve.comp_mem_iff
code: @[simp]
lemma comp_mem_iff (i : X ⟶ Y) (f : Y ⟶ Z) [IsIso i] (S : Sieve Z) :
    S (i ≫ f) ↔ S f 
goal: S.arrows (CategoryTheory.CategoryStruct.comp i f) ↔ S.arrows f

full_name: CategoryTheory.Sieve.ofArrows
code: /-- The sieve of `X` generated by family of morphisms `Y i ⟶ X`. -/
abbrev ofArrows {I : Type*} {X : C} (Y : I → C) (f : ∀ i, Y i ⟶ X) :
    Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.ofArrows_mk
code: lemma ofArrows_mk {I : Type*} {X : C} (Y : I → C) (f : ∀ i, Y i ⟶ X) (i : I) :
    ofArrows Y f (f i) 
goal: (CategoryTheory.Sieve.ofArrows Y f).arrows (f i)

full_name: CategoryTheory.Sieve.mem_ofArrows_iff
code: lemma mem_ofArrows_iff {I : Type*} {X : C} (Y : I → C) (f : ∀ i, Y i ⟶ X)
    {W : C} (g : W ⟶ X) :
    ofArrows Y f g ↔ ∃ (i : I) (a : W ⟶ Y i), g = a ≫ f i 
goal: (CategoryTheory.Sieve.ofArrows Y f).arrows g ↔ ∃ i a, g = CategoryTheory.CategoryStruct.comp a (f i)

full_name: CategoryTheory.Sieve.ofObjects
code: /-- The sieve of `X : C` that is generated by a family of objects `Y : I → C`:
it consists of morphisms to `X` which factor through at least one of the `Y i`. -/
def ofObjects {I : Type*} (Y : I → C) (X : C) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.mem_ofObjects_iff
code: lemma mem_ofObjects_iff {I : Type*} (Y : I → C) {Z X : C} (g : Z ⟶ X) :
    ofObjects Y X g ↔ ∃ (i : I), Nonempty (Z ⟶ Y i) 
goal: (CategoryTheory.Sieve.ofObjects Y X).arrows g ↔ ∃ i, Nonempty (Z ⟶ Y i)

full_name: CategoryTheory.Sieve.ofArrows_le_ofObjects
code: lemma ofArrows_le_ofObjects
    {I : Type*} (Y : I → C) {X : C} (f : ∀ i, Y i ⟶ X) :
    Sieve.ofArrows Y f ≤ Sieve.ofObjects Y X 
goal: CategoryTheory.Sieve.ofArrows Y f ≤ CategoryTheory.Sieve.ofObjects Y X

full_name: CategoryTheory.Sieve.ofArrows_eq_ofObjects
code: lemma ofArrows_eq_ofObjects {X : C} (hX : IsTerminal X)
    {I : Type*} (Y : I → C) (f : ∀ i, Y i ⟶ X) :
    ofArrows Y f = ofObjects Y X 
goal: CategoryTheory.Sieve.ofArrows Y f = CategoryTheory.Sieve.ofObjects Y X

full_name: CategoryTheory.Sieve.pullback
code: /-- Given a morphism `h : Y ⟶ X`, send a sieve S on X to a sieve on Y
    as the inverse image of S with `_ ≫ h`.
    That is, `Sieve.pullback S h := (≫ h) '⁻¹ S`. -/
@[simps]
def pullback (h : Y ⟶ X) (S : Sieve X) : Sieve Y 
goal: CategoryTheory.Sieve Y

full_name: CategoryTheory.Sieve.pullback_apply
code: /-- Given a morphism `h : Y ⟶ X`, send a sieve S on X to a sieve on Y
    as the inverse image of S with `_ ≫ h`.
    That is, `Sieve.pullback S h := (≫ h) '⁻¹ S`. -/
@[simps]
def pullback (h : Y ⟶ X) (S : Sieve X) : Sieve Y 
goal: ∀ (Y_1 : C) (sl : Y_1 ⟶ Y),
  (CategoryTheory.Sieve.pullback h S).arrows sl = S.arrows (CategoryTheory.CategoryStruct.comp sl h)

full_name: CategoryTheory.Sieve.pullback_id
code: @[simp]
theorem pullback_id : S.pullback (𝟙 _) = S 
goal: CategoryTheory.Sieve.pullback (CategoryTheory.CategoryStruct.id X) S = S

full_name: CategoryTheory.Sieve.pullback_top
code: @[simp]
theorem pullback_top {f : Y ⟶ X} : (⊤ : Sieve X).pullback f = ⊤ 
goal: CategoryTheory.Sieve.pullback f ⊤ = ⊤

full_name: CategoryTheory.Sieve.pullback_comp
code: theorem pullback_comp {f : Y ⟶ X} {g : Z ⟶ Y} (S : Sieve X) :
    S.pullback (g ≫ f) = (S.pullback f).pullback g 
goal: CategoryTheory.Sieve.pullback (CategoryTheory.CategoryStruct.comp g f) S =
  CategoryTheory.Sieve.pullback g (CategoryTheory.Sieve.pullback f S)

full_name: CategoryTheory.Sieve.pullback_inter
code: @[simp]
theorem pullback_inter {f : Y ⟶ X} (S R : Sieve X) :
    (S ⊓ R).pullback f = S.pullback f ⊓ R.pullback f 
goal: CategoryTheory.Sieve.pullback f (S ⊓ R) = CategoryTheory.Sieve.pullback f S ⊓ CategoryTheory.Sieve.pullback f R

full_name: CategoryTheory.Sieve.pullback_eq_top_iff_mem
code: theorem pullback_eq_top_iff_mem (f : Y ⟶ X) : S f ↔ S.pullback f = ⊤ 
goal: S.arrows f ↔ CategoryTheory.Sieve.pullback f S = ⊤

full_name: CategoryTheory.Sieve.pullback_eq_top_of_mem
code: theorem pullback_eq_top_of_mem (S : Sieve X) {f : Y ⟶ X} : S f → S.pullback f = ⊤ 
goal: S.arrows f → CategoryTheory.Sieve.pullback f S = ⊤

full_name: CategoryTheory.Sieve.pullback_ofObjects_eq_top
code: lemma pullback_ofObjects_eq_top
    {I : Type*} (Y : I → C) {X : C} {i : I} (g : X ⟶ Y i) :
    ofObjects Y X = ⊤ 
goal: CategoryTheory.Sieve.ofObjects Y X = ⊤

full_name: CategoryTheory.Sieve.pushforward_apply
code: /-- Push a sieve `R` on `Y` forward along an arrow `f : Y ⟶ X`: `gf : Z ⟶ X` is in the sieve if `gf`
factors through some `g : Z ⟶ Y` which is in `R`.
-/
@[simps]
def pushforward (f : Y ⟶ X) (R : Sieve Y) : Sieve X 
goal: (CategoryTheory.Sieve.pushforward f R).arrows gf = ∃ g, CategoryTheory.CategoryStruct.comp g f = gf ∧ R.arrows g

full_name: CategoryTheory.Sieve.pushforward
code: /-- Push a sieve `R` on `Y` forward along an arrow `f : Y ⟶ X`: `gf : Z ⟶ X` is in the sieve if `gf`
factors through some `g : Z ⟶ Y` which is in `R`.
-/
@[simps]
def pushforward (f : Y ⟶ X) (R : Sieve Y) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.pushforward_apply_comp
code: theorem pushforward_apply_comp {R : Sieve Y} {Z : C} {g : Z ⟶ Y} (hg : R g) (f : Y ⟶ X) :
    R.pushforward f (g ≫ f) 
goal: (CategoryTheory.Sieve.pushforward f R).arrows (CategoryTheory.CategoryStruct.comp g f)

full_name: CategoryTheory.Sieve.pushforward_comp
code: theorem pushforward_comp {f : Y ⟶ X} {g : Z ⟶ Y} (R : Sieve Z) :
    R.pushforward (g ≫ f) = (R.pushforward g).pushforward f 
goal: CategoryTheory.Sieve.pushforward (CategoryTheory.CategoryStruct.comp g f) R =
  CategoryTheory.Sieve.pushforward f (CategoryTheory.Sieve.pushforward g R)

full_name: CategoryTheory.Sieve.galoisConnection
code: theorem galoisConnection (f : Y ⟶ X) : GaloisConnection (Sieve.pushforward f) (Sieve.pullback f) 
goal: GaloisConnection (CategoryTheory.Sieve.pushforward f) (CategoryTheory.Sieve.pullback f)

full_name: CategoryTheory.Sieve.pullback_monotone
code: theorem pullback_monotone (f : Y ⟶ X) : Monotone (Sieve.pullback f) 
goal: Monotone (CategoryTheory.Sieve.pullback f)

full_name: CategoryTheory.Sieve.pushforward_monotone
code: theorem pushforward_monotone (f : Y ⟶ X) : Monotone (Sieve.pushforward f) 
goal: Monotone (CategoryTheory.Sieve.pushforward f)

full_name: CategoryTheory.Sieve.le_pushforward_pullback
code: theorem le_pushforward_pullback (f : Y ⟶ X) (R : Sieve Y) : R ≤ (R.pushforward f).pullback f 
goal: R ≤ CategoryTheory.Sieve.pullback f (CategoryTheory.Sieve.pushforward f R)

full_name: CategoryTheory.Sieve.pullback_pushforward_le
code: theorem pullback_pushforward_le (f : Y ⟶ X) (R : Sieve X) : (R.pullback f).pushforward f ≤ R 
goal: CategoryTheory.Sieve.pushforward f (CategoryTheory.Sieve.pullback f R) ≤ R

full_name: CategoryTheory.Sieve.pushforward_union
code: theorem pushforward_union {f : Y ⟶ X} (S R : Sieve Y) :
    (S ⊔ R).pushforward f = S.pushforward f ⊔ R.pushforward f 
goal: CategoryTheory.Sieve.pushforward f (S ⊔ R) = CategoryTheory.Sieve.pushforward f S ⊔ CategoryTheory.Sieve.pushforward f R

full_name: CategoryTheory.Sieve.pushforward_le_bind_of_mem
code: theorem pushforward_le_bind_of_mem (S : Presieve X) (R : ∀ ⦃Y : C⦄ ⦃f : Y ⟶ X⦄, S f → Sieve Y)
    (f : Y ⟶ X) (h : S f) : (R h).pushforward f ≤ bind S R 
goal: CategoryTheory.Sieve.pushforward f (R h) ≤ CategoryTheory.Sieve.bind S R

full_name: CategoryTheory.Sieve.le_pullback_bind
code: theorem le_pullback_bind (S : Presieve X) (R : ∀ ⦃Y : C⦄ ⦃f : Y ⟶ X⦄, S f → Sieve Y) (f : Y ⟶ X)
    (h : S f) : R h ≤ (bind S R).pullback f 
goal: R h ≤ CategoryTheory.Sieve.pullback f (CategoryTheory.Sieve.bind S R)

full_name: CategoryTheory.Sieve.galoisCoinsertionOfMono
code: /-- If `f` is a monomorphism, the pushforward-pullback adjunction on sieves is coreflective. -/
def galoisCoinsertionOfMono (f : Y ⟶ X) [Mono f] :
    GaloisCoinsertion (Sieve.pushforward f) (Sieve.pullback f) 
goal: GaloisCoinsertion (CategoryTheory.Sieve.pushforward f) (CategoryTheory.Sieve.pullback f)

full_name: CategoryTheory.Sieve.galoisInsertionOfIsSplitEpi
code: /-- If `f` is a split epi, the pushforward-pullback adjunction on sieves is reflective. -/
def galoisInsertionOfIsSplitEpi (f : Y ⟶ X) [IsSplitEpi f] :
    GaloisInsertion (Sieve.pushforward f) (Sieve.pullback f) 
goal: GaloisInsertion (CategoryTheory.Sieve.pushforward f) (CategoryTheory.Sieve.pullback f)

full_name: CategoryTheory.Sieve.pullbackArrows_comm
code: theorem pullbackArrows_comm [HasPullbacks C] {X Y : C} (f : Y ⟶ X) (R : Presieve X) :
    Sieve.generate (R.pullbackArrows f) = (Sieve.generate R).pullback f 
goal: CategoryTheory.Sieve.generate (CategoryTheory.Presieve.pullbackArrows f R) =
  CategoryTheory.Sieve.pullback f (CategoryTheory.Sieve.generate R)

full_name: CategoryTheory.Sieve.functorPullback_apply
code: /--
If `R` is a sieve, then the `CategoryTheory.Presieve.functorPullback` of `R` is actually a sieve.
-/
@[simps]
def functorPullback (R : Sieve (F.obj X)) : Sieve X 
goal: (CategoryTheory.Sieve.functorPullback F R).arrows = CategoryTheory.Presieve.functorPullback F R.arrows

full_name: CategoryTheory.Sieve.functorPullback
code: /--
If `R` is a sieve, then the `CategoryTheory.Presieve.functorPullback` of `R` is actually a sieve.
-/
@[simps]
def functorPullback (R : Sieve (F.obj X)) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.functorPullback_arrows
code: @[simp]
theorem functorPullback_arrows (R : Sieve (F.obj X)) :
    (R.functorPullback F).arrows = R.arrows.functorPullback F 
goal: (CategoryTheory.Sieve.functorPullback F R).arrows = CategoryTheory.Presieve.functorPullback F R.arrows

full_name: CategoryTheory.Sieve.functorPullback_id
code: @[simp]
theorem functorPullback_id (R : Sieve X) : R.functorPullback (𝟭 _) = R 
goal: CategoryTheory.Sieve.functorPullback (CategoryTheory.Functor.id C) R = R

full_name: CategoryTheory.Sieve.functorPullback_comp
code: theorem functorPullback_comp (R : Sieve ((F ⋙ G).obj X)) :
    R.functorPullback (F ⋙ G) = (R.functorPullback G).functorPullback F 
goal: CategoryTheory.Sieve.functorPullback (F.comp G) R =
  CategoryTheory.Sieve.functorPullback F (CategoryTheory.Sieve.functorPullback G R)

full_name: CategoryTheory.Sieve.functorPushforward_extend_eq
code: theorem functorPushforward_extend_eq {R : Presieve X} :
    (generate R).arrows.functorPushforward F = R.functorPushforward F 
goal: CategoryTheory.Presieve.functorPushforward F (CategoryTheory.Sieve.generate R).arrows =
  CategoryTheory.Presieve.functorPushforward F R

full_name: CategoryTheory.Sieve.functorPushforward
code: /-- The sieve generated by the image of `R` under `F`. -/
@[simps]
def functorPushforward (R : Sieve X) : Sieve (F.obj X) 
goal: CategoryTheory.Sieve (F.obj X)

full_name: CategoryTheory.Sieve.functorPushforward_apply
code: /-- The sieve generated by the image of `R` under `F`. -/
@[simps]
def functorPushforward (R : Sieve X) : Sieve (F.obj X) 
goal: (CategoryTheory.Sieve.functorPushforward F R).arrows = CategoryTheory.Presieve.functorPushforward F R.arrows

full_name: CategoryTheory.Sieve.functorPushforward_id
code: @[simp]
theorem functorPushforward_id (R : Sieve X) : R.functorPushforward (𝟭 _) = R 
goal: CategoryTheory.Sieve.functorPushforward (CategoryTheory.Functor.id C) R = R

full_name: CategoryTheory.Sieve.functorPushforward_comp
code: theorem functorPushforward_comp (R : Sieve X) :
    R.functorPushforward (F ⋙ G) = (R.functorPushforward F).functorPushforward G 
goal: CategoryTheory.Sieve.functorPushforward (F.comp G) R =
  CategoryTheory.Sieve.functorPushforward G (CategoryTheory.Sieve.functorPushforward F R)

full_name: CategoryTheory.Sieve.functor_galoisConnection
code: theorem functor_galoisConnection (X : C) :
    GaloisConnection (Sieve.functorPushforward F : Sieve X → Sieve (F.obj X))
      (Sieve.functorPullback F) 
goal: GaloisConnection (CategoryTheory.Sieve.functorPushforward F) (CategoryTheory.Sieve.functorPullback F)

full_name: CategoryTheory.Sieve.functorPullback_monotone
code: theorem functorPullback_monotone (X : C) :
    Monotone (Sieve.functorPullback F : Sieve (F.obj X) → Sieve X) 
goal: Monotone (CategoryTheory.Sieve.functorPullback F)

full_name: CategoryTheory.Sieve.functorPushforward_monotone
code: theorem functorPushforward_monotone (X : C) :
    Monotone (Sieve.functorPushforward F : Sieve X → Sieve (F.obj X)) 
goal: Monotone (CategoryTheory.Sieve.functorPushforward F)

full_name: CategoryTheory.Sieve.le_functorPushforward_pullback
code: theorem le_functorPushforward_pullback (R : Sieve X) :
    R ≤ (R.functorPushforward F).functorPullback F 
goal: R ≤ CategoryTheory.Sieve.functorPullback F (CategoryTheory.Sieve.functorPushforward F R)

full_name: CategoryTheory.Sieve.functorPullback_pushforward_le
code: theorem functorPullback_pushforward_le (R : Sieve (F.obj X)) :
    (R.functorPullback F).functorPushforward F ≤ R 
goal: CategoryTheory.Sieve.functorPushforward F (CategoryTheory.Sieve.functorPullback F R) ≤ R

full_name: CategoryTheory.Sieve.functorPushforward_union
code: theorem functorPushforward_union (S R : Sieve X) :
    (S ⊔ R).functorPushforward F = S.functorPushforward F ⊔ R.functorPushforward F 
goal: CategoryTheory.Sieve.functorPushforward F (S ⊔ R) =
  CategoryTheory.Sieve.functorPushforward F S ⊔ CategoryTheory.Sieve.functorPushforward F R

full_name: CategoryTheory.Sieve.functorPullback_union
code: theorem functorPullback_union (S R : Sieve (F.obj X)) :
    (S ⊔ R).functorPullback F = S.functorPullback F ⊔ R.functorPullback F 
goal: CategoryTheory.Sieve.functorPullback F (S ⊔ R) =
  CategoryTheory.Sieve.functorPullback F S ⊔ CategoryTheory.Sieve.functorPullback F R

full_name: CategoryTheory.Sieve.functorPullback_inter
code: theorem functorPullback_inter (S R : Sieve (F.obj X)) :
    (S ⊓ R).functorPullback F = S.functorPullback F ⊓ R.functorPullback F 
goal: CategoryTheory.Sieve.functorPullback F (S ⊓ R) =
  CategoryTheory.Sieve.functorPullback F S ⊓ CategoryTheory.Sieve.functorPullback F R

full_name: CategoryTheory.Sieve.functorPushforward_bot
code: @[simp]
theorem functorPushforward_bot (F : C ⥤ D) (X : C) : (⊥ : Sieve X).functorPushforward F = ⊥ 
goal: CategoryTheory.Sieve.functorPushforward F ⊥ = ⊥

full_name: CategoryTheory.Sieve.functorPushforward_top
code: @[simp]
theorem functorPushforward_top (F : C ⥤ D) (X : C) : (⊤ : Sieve X).functorPushforward F = ⊤ 
goal: CategoryTheory.Sieve.functorPushforward F ⊤ = ⊤

full_name: CategoryTheory.Sieve.functorPullback_bot
code: @[simp]
theorem functorPullback_bot (F : C ⥤ D) (X : C) : (⊥ : Sieve (F.obj X)).functorPullback F = ⊥ 
goal: CategoryTheory.Sieve.functorPullback F ⊥ = ⊥

full_name: CategoryTheory.Sieve.functorPullback_top
code: @[simp]
theorem functorPullback_top (F : C ⥤ D) (X : C) : (⊤ : Sieve (F.obj X)).functorPullback F = ⊤ 
goal: CategoryTheory.Sieve.functorPullback F ⊤ = ⊤

full_name: CategoryTheory.Sieve.image_mem_functorPushforward
code: theorem image_mem_functorPushforward (R : Sieve X) {V} {f : V ⟶ X} (h : R f) :
    R.functorPushforward F (F.map f) 
goal: (CategoryTheory.Sieve.functorPushforward F R).arrows (F.map f)

full_name: CategoryTheory.Sieve.essSurjFullFunctorGaloisInsertion
code: /-- When `F` is essentially surjective and full, the galois connection is a galois insertion. -/
def essSurjFullFunctorGaloisInsertion [F.EssSurj] [F.Full] (X : C) :
    GaloisInsertion (Sieve.functorPushforward F : Sieve X → Sieve (F.obj X))
      (Sieve.functorPullback F) 
goal: GaloisInsertion (CategoryTheory.Sieve.functorPushforward F) (CategoryTheory.Sieve.functorPullback F)

full_name: CategoryTheory.Sieve.fullyFaithfulFunctorGaloisCoinsertion
code: /-- When `F` is fully faithful, the galois connection is a galois coinsertion. -/
def fullyFaithfulFunctorGaloisCoinsertion [F.Full] [F.Faithful] (X : C) :
    GaloisCoinsertion (Sieve.functorPushforward F : Sieve X → Sieve (F.obj X))
      (Sieve.functorPullback F) 
goal: GaloisCoinsertion (CategoryTheory.Sieve.functorPushforward F) (CategoryTheory.Sieve.functorPullback F)

full_name: CategoryTheory.Sieve.functorPushforward_functor
code: lemma functorPushforward_functor (S : Sieve X) (e : C ≌ D) :
    S.functorPushforward e.functor = (S.pullback (e.unitInv.app X)).functorPullback e.inverse 
goal: CategoryTheory.Sieve.functorPushforward e.functor S =
  CategoryTheory.Sieve.functorPullback e.inverse (CategoryTheory.Sieve.pullback (e.unitInv.app X) S)

full_name: CategoryTheory.Sieve.mem_functorPushforward_functor
code: @[simp]
lemma mem_functorPushforward_functor {Y : D} {S : Sieve X} {e : C ≌ D} {f : Y ⟶ e.functor.obj X} :
    S.functorPushforward e.functor f ↔ S (e.inverse.map f ≫ e.unitInv.app X) 
goal: (CategoryTheory.Sieve.functorPushforward e.functor S).arrows f ↔
  S.arrows (CategoryTheory.CategoryStruct.comp (e.inverse.map f) (e.unitInv.app X))

full_name: CategoryTheory.Sieve.functorPushforward_inverse
code: lemma functorPushforward_inverse {X : D} (S : Sieve X) (e : C ≌ D) :
    S.functorPushforward e.inverse = (S.pullback (e.counit.app X)).functorPullback e.functor 
goal: CategoryTheory.Sieve.functorPushforward e.inverse S =
  CategoryTheory.Sieve.functorPullback e.functor (CategoryTheory.Sieve.pullback (e.counit.app X) S)

full_name: CategoryTheory.Sieve.mem_functorPushforward_inverse
code: @[simp]
lemma mem_functorPushforward_inverse {X : D} {S : Sieve X} {e : C ≌ D} {f : Y ⟶ e.inverse.obj X} :
    S.functorPushforward e.inverse f ↔ S (e.functor.map f ≫ e.counit.app X) 
goal: (CategoryTheory.Sieve.functorPushforward e.inverse S).arrows f ↔
  S.arrows (CategoryTheory.CategoryStruct.comp (e.functor.map f) (e.counit.app X))

full_name: CategoryTheory.Sieve.functor_map_coe
code: /-- A sieve induces a presheaf. -/
@[simps]
def functor (S : Sieve X) : Cᵒᵖ ⥤ Type v₁ 
goal: ∀ {X_1 Y : Cᵒᵖ} (f : X_1 ⟶ Y) (g : { g // S.arrows g }),
  ↑(S.functor.map f g) = CategoryTheory.CategoryStruct.comp f.unop ↑g

full_name: CategoryTheory.Sieve.functor
code: /-- A sieve induces a presheaf. -/
@[simps]
def functor (S : Sieve X) : Cᵒᵖ ⥤ Type v₁ 
goal: CategoryTheory.Functor Cᵒᵖ (Type v₁)

full_name: CategoryTheory.Sieve.functor_obj
code: /-- A sieve induces a presheaf. -/
@[simps]
def functor (S : Sieve X) : Cᵒᵖ ⥤ Type v₁ 
goal: S.functor.obj Y = { g // S.arrows g }

full_name: CategoryTheory.Sieve.natTransOfLe_app_coe
code: /-- If a sieve S is contained in a sieve T, then we have a morphism of presheaves on their induced
presheaves.
-/
@[simps]
def natTransOfLe {S T : Sieve X} (h : S ≤ T) : S.functor ⟶ T.functor 
goal: ↑((CategoryTheory.Sieve.natTransOfLe h).app Y f) = ↑f

full_name: CategoryTheory.Sieve.natTransOfLe
code: /-- If a sieve S is contained in a sieve T, then we have a morphism of presheaves on their induced
presheaves.
-/
@[simps]
def natTransOfLe {S T : Sieve X} (h : S ≤ T) : S.functor ⟶ T.functor 
goal: S.functor ⟶ T.functor

full_name: CategoryTheory.Sieve.functorInclusion_app
code: /-- The natural inclusion from the functor induced by a sieve to the yoneda embedding. -/
@[simps]
def functorInclusion (S : Sieve X) : S.functor ⟶ yoneda.obj X 
goal: S.functorInclusion.app Y f = ↑f

full_name: CategoryTheory.Sieve.functorInclusion
code: /-- The natural inclusion from the functor induced by a sieve to the yoneda embedding. -/
@[simps]
def functorInclusion (S : Sieve X) : S.functor ⟶ yoneda.obj X 
goal: S.functor ⟶ CategoryTheory.yoneda.obj X

full_name: CategoryTheory.Sieve.natTransOfLe_comm
code: theorem natTransOfLe_comm {S T : Sieve X} (h : S ≤ T) :
    natTransOfLe h ≫ functorInclusion _ = functorInclusion _ 
goal: CategoryTheory.CategoryStruct.comp (CategoryTheory.Sieve.natTransOfLe h) T.functorInclusion = S.functorInclusion

full_name: CategoryTheory.Sieve.functorInclusion_is_mono
code: /-- The presheaf induced by a sieve is a subobject of the yoneda embedding. -/
instance functorInclusion_is_mono : Mono S.functorInclusion 
goal: CategoryTheory.Mono S.functorInclusion

full_name: CategoryTheory.Sieve.sieveOfSubfunctor_apply
code: /-- A natural transformation to a representable functor induces a sieve. This is the left inverse of
`functorInclusion`, shown in `sieveOfSubfunctor_functorInclusion`.
-/
@[simps]
def sieveOfSubfunctor {R} (f : R ⟶ yoneda.obj X) : Sieve X 
goal: (CategoryTheory.Sieve.sieveOfSubfunctor f).arrows g = ∃ t, f.app (Opposite.op Y) t = g

full_name: CategoryTheory.Sieve.sieveOfSubfunctor
code: /-- A natural transformation to a representable functor induces a sieve. This is the left inverse of
`functorInclusion`, shown in `sieveOfSubfunctor_functorInclusion`.
-/
@[simps]
def sieveOfSubfunctor {R} (f : R ⟶ yoneda.obj X) : Sieve X 
goal: CategoryTheory.Sieve X

full_name: CategoryTheory.Sieve.sieveOfSubfunctor_functorInclusion
code: theorem sieveOfSubfunctor_functorInclusion : sieveOfSubfunctor S.functorInclusion = S 
goal: CategoryTheory.Sieve.sieveOfSubfunctor S.functorInclusion = S

full_name: CategoryTheory.Sieve.functorInclusion_top_isIso
code: instance functorInclusion_top_isIso : IsIso (⊤ : Sieve X).functorInclusion 
goal: CategoryTheory.IsIso ⊤.functorInclusion