Definitions for Homotopy types of topological stacks
DefinitionQAlgorithms_Papers_Independent_Intake100_P19The objects the formalized statements of Homotopy types of topological stacks (arXiv:0808.3799) are stated in. Each was checked against the paper by a blind read-back and a moderator.
restrictedFunctor: The actual restriction of a functor to two full subcategories (§7, PDF p. 14).localizedFunctor: The functor induced on actual category localizations by a functor carrying S-morphisms to T-morphisms (§7, PDF p. 14).RightSpan: An R-span X ← V → Y, with its actual apex and its left leg in R (§13, PDF pp. 28–29).SpanHom: A map of spans is any map of apices respecting both legs (§13, PDF p. 29). Its map is not required to be invertible or to belong to R.spanStep: A directed step is the existence of a map in the actual span category (§13, PDF p. 29).SpanComponent:Quotidentifies the equivalence relation generated by directed steps: finite zigzags in the full category of spans, not only common refinements (§13, PDF p. 29).honestSpan: The honest arrow f is represented by (id,f) (§13, PDF p. 29).composeSpan: Compose spans using a pullback of the second denominator. Only pullbacks along R-morphisms are required (§13, PDF pp. 28–29).spanValue: The canonical value of a span in the actual localization is Q(r)⁻¹Q(g) (§13, PDF p. 29). The inverse is the explicit formal inverse.elementaryRHomotopy: Elementary R-homotopy uses one R-map with two specified sections and one common map out of its domain (§13, PDF p. 29).RHomotopyQuotient: Hom modulo the equivalence relation generated by elementary R-homotopy;Quotsupplies reflexive, symmetric, and transitive closure (PDF p. 29).
import Mathlib
/-!
Statements from Noohi, Homotopy types of topological stacks, arXiv:0808.3799v2.
Only the ordinary categorical results with complete local interfaces are stated.
The accompanying HARD.md and GAPS.json inventory every deferred plan node.
-/
noncomputable section
namespace QAlgorithms.Papers.Independent.Intake100.P19
open CategoryTheory CategoryTheory.Limits
universe uB vB uC vC
/-- The actual restriction of a functor to two full subcategories (§7, PDF p. 14). -/
def restrictedFunctor {B : Type uB} [Category.{vB} B]
{C : Type uC} [Category.{vC} C] (F : B ⥤ C)
(P : ObjectProperty B) (Q : ObjectProperty C)
(hF : ∀ b, P b → Q (F.obj b)) : P.FullSubcategory ⥤ Q.FullSubcategory :=
Q.lift (P.ι ⋙ F) (fun b => hF b.obj b.property)
example {B : Type uB} [Category.{vB} B]
{C : Type uC} [Category.{vC} C] (F : B ⥤ C)
(P : ObjectProperty B) (Q : ObjectProperty C)
(hF : ∀ b, P b → Q (F.obj b)) (b : P.FullSubcategory) :
((restrictedFunctor F P Q hF).obj b).obj = F.obj b.obj := rfl
/-- The functor induced on actual category localizations by a functor carrying
S-morphisms to T-morphisms (§7, PDF p. 14). -/
def localizedFunctor {B : Type uB} [Category.{vB} B]
{C : Type uC} [Category.{vC} C] (F : B ⥤ C)
(S : MorphismProperty B) (T : MorphismProperty C)
(hF : ∀ ⦃b b2 : B⦄ (f : b ⟶ b2), S f → T (F.map f)) :
S.Localization ⥤ T.Localization :=
Localization.Construction.lift (F ⋙ T.Q) (fun _ _ f hf => T.Q_inverts _ (hF f hf))
example {B : Type uB} [Category.{vB} B]
{C : Type uC} [Category.{vC} C] (F : B ⥤ C)
(S : MorphismProperty B) (T : MorphismProperty C)
(hF : ∀ ⦃b b2 : B⦄ (f : b ⟶ b2), S f → T (F.map f)) :
S.Q ⋙ localizedFunctor F S T hF = F ⋙ T.Q := by
exact Localization.Construction.fac _ _
/-- An R-span X ← V → Y, with its actual apex and its left leg in R
(§13, PDF pp. 28–29). -/
structure RightSpan {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) where
apex : C
left : apex ⟶ X
right : apex ⟶ Y
left_mem : R left
/-- A map of spans is any map of apices respecting both legs (§13, PDF p. 29).
Its map is not required to be invertible or to belong to R. -/
@[ext]
structure SpanHom {C : Type uC} [Category.{vC} C]
{R : MorphismProperty C} {X Y : C} (a b : RightSpan R X Y) where
map : a.apex ⟶ b.apex
left_comm : map ≫ b.left = a.left
right_comm : map ≫ b.right = a.right
/-- The full ordinary category of spans and maps of spans (§13, PDF p. 29). -/
instance spanCategory {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) : Category (RightSpan R X Y) where
Hom a b := SpanHom a b
id a := ⟨𝟙 a.apex, by simp, by simp⟩
comp f g :=
⟨f.map ≫ g.map, by rw [Category.assoc, g.left_comm, f.left_comm],
by rw [Category.assoc, g.right_comm, f.right_comm]⟩
id_comp := by
intros
apply SpanHom.ext
exact Category.id_comp _
comp_id := by
intros
apply SpanHom.ext
exact Category.comp_id _
assoc := by
intros
apply SpanHom.ext
exact Category.assoc _ _ _
/-- A directed step is the existence of a map in the actual span category
(§13, PDF p. 29). -/
def spanStep {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) (a b : RightSpan R X Y) : Prop :=
Nonempty (a ⟶ b)
/-- `Quot` identifies the equivalence relation generated by directed steps:
finite zigzags in the full category of spans, not only common refinements
(§13, PDF p. 29). -/
abbrev SpanComponent {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) := Quot (spanStep R X Y)
/-- The honest arrow f is represented by (id,f) (§13, PDF p. 29). -/
def honestSpan {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) [R.ContainsIdentities]
{X Y : C} (f : X ⟶ Y) : RightSpan R X Y where
apex := X
left := 𝟙 X
right := f
left_mem := R.id_mem X
example {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) [R.ContainsIdentities]
{X Y : C} (f : X ⟶ Y) : (honestSpan R f).right = f := rfl
example {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) (s : RightSpan R X Y) :
spanStep R X Y s s := by
exact ⟨𝟙 s⟩
/-- Compose spans using a pullback of the second denominator. Only pullbacks
along R-morphisms are required (§13, PDF pp. 28–29). -/
def composeSpan {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) [R.HasPullbacks]
[R.IsStableUnderBaseChange] [R.IsStableUnderComposition]
{X Y Z : C} (s : RightSpan R X Y) (t : RightSpan R Y Z) : RightSpan R X Z := by
letI : HasPullback t.left s.right := R.hasPullback s.right t.left_mem
exact
{ apex := pullback t.left s.right
left := pullback.snd t.left s.right ≫ s.left
right := pullback.fst t.left s.right ≫ t.right
left_mem := R.comp_mem _ _ (R.pullback_snd _ _ t.left_mem) s.left_mem }
/-- The canonical value of a span in the actual localization is Q(r)⁻¹Q(g)
(§13, PDF p. 29). The inverse is the explicit formal inverse. -/
def spanValue {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) {X Y : C} (s : RightSpan R X Y) :
R.Q.obj X ⟶ R.Q.obj Y :=
Localization.Construction.wInv s.left s.left_mem ≫ R.Q.map s.right
/-- Elementary R-homotopy uses one R-map with two specified sections and
one common map out of its domain (§13, PDF p. 29). -/
def elementaryRHomotopy {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) {X Y : C} (f g : X ⟶ Y) : Prop :=
∃ (V : C) (r : V ⟶ X) (t t2 : X ⟶ V) (k : V ⟶ Y),
R r ∧ t ≫ r = 𝟙 X ∧ t2 ≫ r = 𝟙 X ∧ t ≫ k = f ∧ t2 ≫ k = g
/-- Hom modulo the equivalence relation generated by elementary R-homotopy;
`Quot` supplies reflexive, symmetric, and transitive closure (PDF p. 29). -/
abbrev RHomotopyQuotient {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) (X Y : C) :=
Quot (elementaryRHomotopy R : (X ⟶ Y) → (X ⟶ Y) → Prop)
example {C : Type uC} [Category.{vC} C]
(R : MorphismProperty C) [R.ContainsIdentities]
{X Y : C} (f : X ⟶ Y) : elementaryRHomotopy R f f := by
exact ⟨X, 𝟙 X, 𝟙 X, 𝟙 X, f, R.id_mem X, by simp, by simp, by simp, by simp⟩
end QAlgorithms.Papers.Independent.Intake100.P19
Read-back
What the Lean code literally says, in plain math · gpt-6.1-sol
QAlgorithms.Papers.Independent.Intake100.P19.RHomotopyQuotient
Let be any category, with objects in universe and morphisms in universe , let be any property of its morphisms, and let be objects. The type is the set of morphisms modulo the smallest equivalence relation containing every pair for which there exist an object and morphisms , , satisfying
Consequently, classes identify morphisms connected by a finite zigzag of such elementary relations, including a zigzag of length zero; a single elementary relation is not required. No assumptions are imposed on . Even if there are no elementary witnesses, each morphism represents its own class, and if there are no morphisms , this quotient is empty.
QAlgorithms.Papers.Independent.Intake100.P19.RightSpan
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, and objects of , this defines the type of data consisting of an object of , morphisms and , and a proof that holds. Thus a right span has the form , with only its left leg required to satisfy . No condition on the right leg, no closure condition on , and no existence of such a span are asserted.
QAlgorithms.Papers.Independent.Intake100.P19.SpanComponent
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, and objects , this abbreviates the quotient of the type of spans equipped with a proof of by the equivalence relation generated by the following relation: a span is related to whenever there exists with and . Consequently, two spans represent the same quotient element exactly when they can be connected by a finite zigzag of such morphisms, allowing either direction at each step and a zigzag of length zero. If there are no such spans, the quotient is empty.
QAlgorithms.Papers.Independent.Intake100.P19.SpanHom
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, objects , and two spans and equipped with proofs of and , this defines a morphism of spans from to to consist of a morphism satisfying and . There is no requirement that satisfy or be invertible.
QAlgorithms.Papers.Independent.Intake100.P19.composeSpan
For a category of arbitrary object and morphism universe sizes and a predicate on its morphisms, assume that pullbacks of morphisms satisfying along arbitrary morphisms exist, that is stable under base change, and that is stable under composition. For objects and spans and equipped with proofs of and , this defines a span from to . Its apex is the chosen pullback of and , with projections and satisfying ; its left leg is , and its right leg is . Base-change stability gives , and composition stability then gives , providing the required proof for the new left leg.
QAlgorithms.Papers.Independent.Intake100.P19.elementaryRHomotopy
Let be any category, with objects in universe and morphisms in universe , let be any property of its morphisms, let be objects, and let . The proposition means that there exist an object , morphisms , , and , such that
The two sections are permitted to coincide. No closure or identity assumptions are imposed on ; in particular, witnesses need not exist even when .
QAlgorithms.Papers.Independent.Intake100.P19.honestSpan
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms such that holds for every object , objects , and a morphism , this defines the span . Its apex is , its left leg is , its right leg is , and its proof that the left leg satisfies is supplied by the assumption that contains all identities. The morphism itself need not satisfy .
QAlgorithms.Papers.Independent.Intake100.P19.localizedFunctor
For categories and of arbitrary object and morphism universe sizes, a functor , predicates on morphisms of and on morphisms of , and a proof that for every pair of objects of and every morphism , this defines a functor between the constructed localizations, which formally invert all morphisms satisfying and , respectively. It is the localization lift of the composite of with the canonical functor , using the supplied preservation proof to show that this composite sends every -morphism to an isomorphism. Thus it sends an object represented by to the localized object represented by , original morphisms according to , and formal inverses of -morphisms to inverses of their images. No closure or identity conditions on or are assumed.
QAlgorithms.Papers.Independent.Intake100.P19.restrictedFunctor
For categories and of arbitrary object and morphism universe sizes, a functor , predicates on objects of and on objects of , and a proof that implies for every object of , this defines a functor between the corresponding full subcategories. Its source objects are objects equipped with a proof of , and its target objects are objects equipped with a proof of ; morphisms are the ambient category morphisms without additional conditions. The functor sends to , equipped with the supplied proof of , and sends each morphism to . The predicates may select no objects.
QAlgorithms.Papers.Independent.Intake100.P19.spanCategory
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, and objects , this equips the type of spans carrying a proof of with a category structure. A morphism from to is a morphism satisfying and . The identity is represented by , and the composite of morphisms represented by and is represented by . These operations satisfy the identity and associativity laws. No additional property of is assumed, and the category may have no objects.
QAlgorithms.Papers.Independent.Intake100.P19.spanStep
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, objects , and spans and whose left legs satisfy , this defines the relation “a step from to ” to mean that there exists a morphism satisfying and . Only existence is required; no particular such morphism is selected, and neither invertibility nor membership in is required of it.
QAlgorithms.Papers.Independent.Intake100.P19.spanValue
For a category of arbitrary object and morphism universe sizes, a predicate on its morphisms, objects , and a span equipped with a proof of , this defines a morphism from to in the constructed localization , where is the canonical functor formally inverting all morphisms satisfying . The defined morphism is , using the formal inverse of the left leg supplied by its membership in . No condition on the right leg and no closure or identity condition on are assumed.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.