Skip to content
This repository was archived by the owner on Jul 24, 2024. It is now read-only.

Commit ef51d23

Browse files
kim-emjcommelin
andcommitted
feat(category_theory/shift): restricting shift functors to a subcategory (#13265)
Given a family of endomorphisms of `C` which are interwined by a fully faithful `F : C ⥤ D` with shift functors on `D`, we can promote that family to shift functors on `C`. For LTE. Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Johan Commelin <johan@commelin.net>
1 parent c916b64 commit ef51d23

File tree

2 files changed

+92
-2
lines changed

2 files changed

+92
-2
lines changed

src/category_theory/functor/fully_faithful.lean

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,15 @@ def iso_equiv_of_fully_faithful {X Y} : (X ≅ Y) ≃ (F.obj X ≅ F.obj Y) :=
120120
left_inv := λ f, by simp,
121121
right_inv := λ f, by { ext, simp, } }
122122

123+
/-- We can construct a natural isomorphism between functors by constructing a natural isomorphism
124+
between those functors composed with a fully faithful functor. -/
125+
@[simps]
126+
def nat_iso_of_comp_fully_faithful {E : Type*} [category E]
127+
{F G : C ⥤ D} (H : D ⥤ E) [full H] [faithful H] (i : F ⋙ H ≅ G ⋙ H) : F ≅ G :=
128+
nat_iso.of_components
129+
(λ X, (iso_equiv_of_fully_faithful H).symm (i.app X))
130+
(λ X Y f, by { dsimp, apply H.map_injective, simpa using i.hom.naturality f, })
131+
123132
end category_theory
124133

125134
namespace category_theory

src/category_theory/shift.lean

Lines changed: 83 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ would be the degree `i+n`-th term of `C`.
2424
2525
## Implementation Notes
2626
27-
Most of the definitions in this file is marked as an `abbreviation` so that the simp lemmas in
28-
`category_theory/monoidal/End` could apply.
27+
Many of the definitions in this file are marked as an `abbreviation` so that the simp lemmas in
28+
`category_theory/monoidal/End` can apply.
2929
3030
-/
3131
namespace category_theory
@@ -342,4 +342,85 @@ by rw [shift_comm', ← shift_comm_symm, iso.symm_hom, iso.inv_hom_id_assoc]
342342

343343
end add_comm_monoid
344344

345+
variables {D : Type*} [category D] [add_monoid A] [has_shift D A]
346+
variables (F : C ⥤ D) [full F] [faithful F]
347+
348+
/-- Given a family of endomorphisms of `C` which are interwined by a fully faithful `F : C ⥤ D`
349+
with shift functors on `D`, we can promote that family to shift functors on `C`. -/
350+
def has_shift_of_fully_faithful
351+
(s : A → C ⥤ C) (i : ∀ i, s i ⋙ F ≅ F ⋙ shift_functor D i) : has_shift C A :=
352+
has_shift_mk C A
353+
{ F := s,
354+
ε := nat_iso_of_comp_fully_faithful F
355+
(calc 𝟭 C ⋙ F ≅ F : functor.left_unitor _
356+
... ≅ F ⋙ 𝟭 D : (functor.right_unitor _).symm
357+
... ≅ F ⋙ shift_functor D (0 : A) :
358+
iso_whisker_left F (shift_functor_zero D A).symm
359+
... ≅ s 0 ⋙ F : (i 0).symm),
360+
μ := λ a b, nat_iso_of_comp_fully_faithful F
361+
(calc (s a ⋙ s b) ⋙ F ≅ s a ⋙ s b ⋙ F : functor.associator _ _ _
362+
... ≅ s a ⋙ F ⋙ shift_functor D b : iso_whisker_left _ (i b)
363+
... ≅ (s a ⋙ F) ⋙ shift_functor D b : (functor.associator _ _ _).symm
364+
... ≅ (F ⋙ shift_functor D a) ⋙ shift_functor D b : iso_whisker_right (i a) _
365+
... ≅ F ⋙ shift_functor D a ⋙ shift_functor D b : functor.associator _ _ _
366+
... ≅ F ⋙ shift_functor D (a + b) :
367+
iso_whisker_left _ (shift_functor_add D a b).symm
368+
... ≅ s (a + b) ⋙ F : (i (a + b)).symm),
369+
associativity := begin
370+
intros, apply F.map_injective, dsimp,
371+
simp only [category.comp_id, category.id_comp, category.assoc,
372+
category_theory.functor.map_comp, functor.image_preimage,
373+
eq_to_hom_map, iso.inv_hom_id_app_assoc],
374+
erw (i m₃).hom.naturality_assoc,
375+
congr' 1,
376+
dsimp,
377+
simp only [eq_to_iso.inv, eq_to_hom_app, eq_to_hom_map, obj_μ_app, μ_naturality_assoc,
378+
category.assoc, category_theory.functor.map_comp, functor.image_preimage],
379+
congr' 3,
380+
dsimp,
381+
simp only [←(shift_functor D m₃).map_comp_assoc, iso.inv_hom_id_app],
382+
erw [(shift_functor D m₃).map_id, category.id_comp],
383+
erw [((shift_monoidal_functor D A).μ_iso (m₁ + m₂) m₃).inv_hom_id_app_assoc],
384+
congr' 1,
385+
have := dcongr_arg (λ a, (i a).inv.app X) (add_assoc m₁ m₂ m₃),
386+
dsimp at this,
387+
simp [this],
388+
end,
389+
left_unitality := begin
390+
intros, apply F.map_injective, dsimp,
391+
simp only [category.comp_id, category.id_comp, category.assoc, category_theory.functor.map_comp,
392+
eq_to_hom_app, eq_to_hom_map, functor.image_preimage],
393+
erw (i n).hom.naturality_assoc,
394+
dsimp,
395+
simp only [eq_to_iso.inv, eq_to_hom_app, category.assoc, category_theory.functor.map_comp,
396+
eq_to_hom_map, obj_ε_app, functor.image_preimage],
397+
simp only [←(shift_functor D n).map_comp_assoc, iso.inv_hom_id_app],
398+
dsimp,
399+
simp only [category.id_comp, μ_inv_hom_app_assoc, category_theory.functor.map_id],
400+
have := dcongr_arg (λ a, (i a).inv.app X) (zero_add n),
401+
dsimp at this,
402+
simp [this],
403+
end,
404+
right_unitality := begin
405+
intros, apply F.map_injective, dsimp,
406+
simp only [category.comp_id, category.id_comp, category.assoc,
407+
iso.inv_hom_id_app_assoc, eq_to_iso.inv, eq_to_hom_app, eq_to_hom_map,
408+
category_theory.functor.map_comp, functor.image_preimage,
409+
obj_zero_map_μ_app, ε_hom_inv_app_assoc],
410+
have := dcongr_arg (λ a, (i a).inv.app X) (add_zero n),
411+
dsimp at this,
412+
simp [this],
413+
end, }
414+
415+
/-- When we construct shifts on a subcategory from shifts on the ambient category,
416+
the inclusion functor intertwines the shifts. -/
417+
@[nolint unused_arguments] -- incorrectly reports that `[full F]` and `[faithful F]` are unused.
418+
def has_shift_of_fully_faithful_comm
419+
(s : A → C ⥤ C) (i : ∀ i, s i ⋙ F ≅ F ⋙ shift_functor D i) (m : A) :
420+
begin
421+
haveI := has_shift_of_fully_faithful F s i,
422+
exact (shift_functor C m) ⋙ F ≅ F ⋙ shift_functor D m
423+
end :=
424+
i m
425+
345426
end category_theory

0 commit comments

Comments
 (0)