Skip to content

Commit 893f50b

Browse files
committed
feat(CategoryTheory/MorphismProperty): HasPullbacksAgainst (#39534)
Given `P P̀': MorphismProperty C`, we add a type class `HasPullbacksAgainst` expressing that any morphism satisfying `P` admits a pullback along any morphism satisfying `P'`. We also add a type-class expressing that pullbacks of morphisms of `P` along any morphism satisfying `P'` still satisfies `P`. This will be used to encode pairs of morphism properties for which suitable bicategories of spans exist. From [SymmMonCoherence](https://github.com/robin-carlier/SymmMonCoherence)
1 parent aefd553 commit 893f50b

1 file changed

Lines changed: 96 additions & 0 deletions

File tree

Mathlib/CategoryTheory/MorphismProperty/Limits.lean

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -978,6 +978,102 @@ instance {X Y Z : C} (f : X ⟶ Y) (g : Y ⟶ Z) [P.IsStableUnderCobaseChangeAlo
978978
IsStableUnderCobaseChangeAlong.of_isPushout (IsPushout.of_left' pb right.flip)
979979
(IsStableUnderCobaseChangeAlong.of_isPushout right.flip hp)
980980

981+
/-- `P.IsStableUnderBaseChangeAgainst P'` states that for any morphism `f` satisfying `P` and
982+
any morphism `g` with the same codomain as `f` satisfying `P'`, any pullback of `f` along `g`
983+
also satisfies `P`. -/
984+
class IsStableUnderBaseChangeAgainst
985+
(P P' : MorphismProperty C) : Prop where
986+
isStableUnderBaseChangeAlong ⦃X Y : C⦄ (f : X ⟶ Y) (hf : P' f) :
987+
P.IsStableUnderBaseChangeAlong f
988+
989+
instance (P : MorphismProperty C) [P.IsStableUnderBaseChange]
990+
(P' : MorphismProperty C) :
991+
P.IsStableUnderBaseChangeAgainst P' where
992+
isStableUnderBaseChangeAlong := inferInstance
993+
994+
lemma isStableUnderBaseChangeAgainst_top_iff
995+
(P : MorphismProperty C) :
996+
P.IsStableUnderBaseChangeAgainst ⊤ ↔ P.IsStableUnderBaseChange where
997+
mp h :=
998+
fun {_ _ _ _} _ _ _ _ h' h'' ↦
999+
(h.isStableUnderBaseChangeAlong _ (by tauto)).of_isPullback h' h''⟩
1000+
mpr _ := inferInstance
1001+
1002+
/-- `P.HasPullbacksAgainst P'` states that for any morphism `f` satisfying `P'`,
1003+
`P` has pullbacks along `f`. -/
1004+
class HasPullbacksAgainst
1005+
(P P' : MorphismProperty C) : Prop where
1006+
hasPullbacksAlong ⦃X Y : C ⦄ (f : X ⟶ Y) (hf : P' f) :
1007+
P.HasPullbacksAlong f
1008+
1009+
instance (P : MorphismProperty C) [P.HasPullbacks] (P' : MorphismProperty C) :
1010+
P.HasPullbacksAgainst P' where
1011+
hasPullbacksAlong := inferInstance
1012+
1013+
lemma hasPullbacksAgainst_top_iff
1014+
(P : MorphismProperty C) :
1015+
P.IsStableUnderBaseChangeAgainst ⊤ ↔ P.IsStableUnderBaseChange where
1016+
mp h :=
1017+
fun {_ _ _ _} _ _ _ _ h' h'' ↦
1018+
(h.isStableUnderBaseChangeAlong _ (by tauto)).of_isPullback h' h''⟩
1019+
mpr _ := inferInstance
1020+
1021+
lemma _root_.CategoryTheory.Limits.hasPullback_ofHasPullbacksAgainst
1022+
{P : MorphismProperty C} {P' : MorphismProperty C} {c c' c'' : C}
1023+
{f : c ⟶ c'} {g : c'' ⟶ c'} [P.HasPullbacksAgainst P'] (hf : P f) (hg : P' g) :
1024+
Limits.HasPullback f g :=
1025+
letI : P.HasPullbacksAlong g :=
1026+
MorphismProperty.HasPullbacksAgainst.hasPullbacksAlong g hg
1027+
MorphismProperty.HasPullbacksAlong.hasPullback f hf
1028+
1029+
/-- `P.IsStableUnderCobaseChangeAgainst P'` states that for any morphism `f` satisfying `P` and
1030+
any morphism `g` with the same codomain as `f` satisfying `P'`, any pullback of `f` along `g`
1031+
also satisfies `P`. -/
1032+
class IsStableUnderCobaseChangeAgainst
1033+
(P P' : MorphismProperty C) : Prop where
1034+
isStableUnderCobaseChangeAlong ⦃X Y : C ⦄ (f : X ⟶ Y) (hf : P' f) :
1035+
P.IsStableUnderCobaseChangeAlong f
1036+
1037+
instance (P : MorphismProperty C) [P.IsStableUnderCobaseChange]
1038+
(P' : MorphismProperty C) :
1039+
P.IsStableUnderCobaseChangeAgainst P' where
1040+
isStableUnderCobaseChangeAlong := inferInstance
1041+
1042+
lemma isStableUnderCobaseChangeAgainst_top_iff
1043+
(P : MorphismProperty C) :
1044+
P.IsStableUnderCobaseChangeAgainst ⊤ ↔ P.IsStableUnderCobaseChange where
1045+
mp h :=
1046+
fun {_ _ _ _} _ _ _ _ h' h'' ↦
1047+
(h.isStableUnderCobaseChangeAlong _ (by tauto)).of_isPushout h' h''⟩
1048+
mpr _ := inferInstance
1049+
1050+
/-- `P.HasPullbacksAgainst P'` states that for any morphism `f` satisfying `P'`,
1051+
`P` has pushouts along `f`. -/
1052+
class HasPushoutsAgainst
1053+
(P P' : MorphismProperty C) : Prop where
1054+
hasPushoutsAlong ⦃X Y : C ⦄ (f : X ⟶ Y) (hf : P' f) :
1055+
P.HasPushoutsAlong f
1056+
1057+
instance (P : MorphismProperty C) [P.HasPushouts] (P' : MorphismProperty C) :
1058+
P.HasPushoutsAgainst P' where
1059+
hasPushoutsAlong := inferInstance
1060+
1061+
lemma hasPushoutsAgainst_top_iff
1062+
(P : MorphismProperty C) :
1063+
P.IsStableUnderCobaseChangeAgainst ⊤ ↔ P.IsStableUnderCobaseChange where
1064+
mp h :=
1065+
fun {_ _ _ _} _ _ _ _ h' h'' ↦
1066+
(h.isStableUnderCobaseChangeAlong _ (by tauto)).of_isPushout h' h''⟩
1067+
mpr _ := inferInstance
1068+
1069+
lemma _root_.CategoryTheory.Limits.hasPushout_ofHasPushoutsAgainst
1070+
{P : MorphismProperty C} {P' : MorphismProperty C} {c c' c'' : C}
1071+
{f : c ⟶ c'} {g : c ⟶ c''} [P.HasPushoutsAgainst P'] (hf : P f) (hg : P' g) :
1072+
Limits.HasPushout f g :=
1073+
letI : P.HasPushoutsAlong g :=
1074+
MorphismProperty.HasPushoutsAgainst.hasPushoutsAlong g hg
1075+
MorphismProperty.HasPushoutsAlong.hasPushout f hf
1076+
9811077
end MorphismProperty
9821078

9831079
end CategoryTheory

0 commit comments

Comments
 (0)