@@ -23,14 +23,10 @@ universe u v' u'
2323open CategoryTheory Limits
2424
2525variable {C : Type u'} [Category.{v'} C] {J : GrothendieckTopology C}
26-
27-
28- variable {R : Sheaf J RingCat.{u}}
26+ {R : Sheaf J RingCat.{u}}
2927
3028namespace SheafOfModules
3129
32- variable (M : SheafOfModules.{u} R)
33-
3430section
3531
3632variable [HasWeakSheafify J AddCommGrpCat.{u}] [J.WEqualsLocallyBijective AddCommGrpCat.{u}]
@@ -39,12 +35,21 @@ variable [HasWeakSheafify J AddCommGrpCat.{u}] [J.WEqualsLocallyBijective AddCom
3935/-- A global presentation of a sheaf of modules `M` consists of a family `generators.s`
4036of sections `s` which generate `M`, and a family of sections which generate
4137the kernel of the morphism `generators.π : free (generators.I) ⟶ M`. -/
42- structure Presentation where
38+ structure Presentation (M : SheafOfModules.{u} R) where
4339 /-- generators -/
4440 generators : M.GeneratingSections
4541 /-- relations -/
4642 relations : (kernel generators.π).GeneratingSections
4743
44+ /-- A global presentation of a sheaf of module if finite if the type
45+ of generators and relations are finite. -/
46+ class Presentation.IsFinite {M : SheafOfModules.{u} R} (p : M.Presentation) : Prop where
47+ isFiniteType_generators : p.generators.IsFiniteType := by infer_instance
48+ finite_relations : Finite p.relations.I := by infer_instance
49+
50+ attribute [instance] Presentation.IsFinite.isFiniteType_generators
51+ Presentation.IsFinite.finite_relations
52+
4853end
4954
5055
@@ -54,7 +59,7 @@ variable [∀ X, (J.over X).HasSheafCompose (forget₂ RingCat.{u} AddCommGrpCat
5459
5560/-- This structure contains the data of a family of objects `X i` which cover
5661the terminal object, and of a presentation of `M.over (X i)` for all `i`. -/
57- structure QuasicoherentData where
62+ structure QuasicoherentData (M : SheafOfModules.{u} R) where
5863 /-- the index type of the covering -/
5964 I : Type u'
6065 /-- a family of objects which cover the terminal object -/
@@ -65,55 +70,65 @@ structure QuasicoherentData where
6570
6671namespace QuasicoherentData
6772
68- variable {M}
69-
7073/-- If `M` is quasicoherent, it is locally generated by sections. -/
7174@[simps]
72- def localGeneratorsData (q : M.QuasicoherentData) : M.LocalGeneratorsData where
75+ def localGeneratorsData {M : SheafOfModules.{u} R} (q : M.QuasicoherentData) :
76+ M.LocalGeneratorsData where
7377 I := q.I
7478 X := q.X
7579 coversTop := q.coversTop
7680 generators i := (q.presentation i).generators
7781
82+ /-- A (local) presentation of a sheaf of module `M` is a finite presentation
83+ if each given presentation of `M.over (X i)` is a finite presentation. -/
84+ class IsFinitePresentation {M : SheafOfModules.{u} R} (q : M.QuasicoherentData) : Prop where
85+ isFinite_presentation (i : q.I) : (q.presentation i).IsFinite := by infer_instance
86+
87+ attribute [instance] IsFinitePresentation.isFinite_presentation
88+
89+ instance {M : SheafOfModules.{u} R } (q : M.QuasicoherentData) [q.IsFinitePresentation] :
90+ q.localGeneratorsData.IsFiniteType where
91+ isFiniteType := by dsimp; infer_instance
92+
7893end QuasicoherentData
7994
8095/-- A sheaf of modules is quasi-coherent if it is locally the cokernel of a
8196morphism between coproducts of copies of the sheaf of rings. -/
82- class IsQuasicoherent : Prop where
83- nonempty_quasicoherentData : Nonempty M.QuasicoherentData
97+ class IsQuasicoherent (M : SheafOfModules.{u} R) : Prop where
98+ nonempty_quasicoherentData : Nonempty M.QuasicoherentData := by infer_instance
99+
100+ variable (R) in
101+ @[inherit_doc IsQuasicoherent]
102+ abbrev isQuasicoherent : ObjectProperty (SheafOfModules.{u} R) :=
103+ IsQuasicoherent
84104
85105/-- A sheaf of modules is finitely presented if it is locally the cokernel of a
86106morphism between coproducts of finitely many copies of the sheaf of rings. -/
87- class IsFinitePresentation : Prop where
88- exists_quasicoherentData :
89- ∃ (σ : M.QuasicoherentData), ∀ (i : σ.I), (Finite (σ.presentation i).generators.I ∧
90- Finite (σ.presentation i).relations.I)
91-
92- section
93-
94- variable [h : M.IsFinitePresentation]
107+ class IsFinitePresentation (M : SheafOfModules.{u} R) : Prop where
108+ exists_quasicoherentData (M) :
109+ ∃ (σ : M.QuasicoherentData), σ.IsFinitePresentation
110+
111+ variable (R) in
112+ @[inherit_doc IsFinitePresentation]
113+ abbrev isFinitePresentation : ObjectProperty (SheafOfModules.{u} R) :=
114+ IsFinitePresentation
115+
116+ instance (M : SheafOfModules.{u} R) [M.IsFinitePresentation] :
117+ M.IsQuasicoherent where
118+ nonempty_quasicoherentData :=
119+ ⟨(IsFinitePresentation.exists_quasicoherentData M).choose⟩
120+
121+ instance (M : SheafOfModules.{u} R) [M.IsFinitePresentation] :
122+ M.IsFiniteType where
123+ exists_localGeneratorsData := by
124+ obtain ⟨σ, _⟩ := IsFinitePresentation.exists_quasicoherentData M
125+ exact ⟨σ.localGeneratorsData, inferInstance⟩
95126
96127/-- A choice of local presentations when `M` is a sheaf of modules of finite presentation. -/
97- noncomputable def quasicoherentDataOfIsFinitePresentation : M.QuasicoherentData :=
98- h.exists_quasicoherentData.choose
99-
100- instance (i : M.quasicoherentDataOfIsFinitePresentation.I) :
101- Finite (M.quasicoherentDataOfIsFinitePresentation.presentation i).generators.I :=
102- have : _ ∧ Finite (M.quasicoherentDataOfIsFinitePresentation.presentation i).relations.I :=
103- h.exists_quasicoherentData.choose_spec i
104- this.1
105-
106- instance (i : M.quasicoherentDataOfIsFinitePresentation.I) :
107- Finite (M.quasicoherentDataOfIsFinitePresentation.presentation i).relations.I :=
108- have : _ ∧ Finite (M.quasicoherentDataOfIsFinitePresentation.presentation i).relations.I :=
109- h.exists_quasicoherentData.choose_spec i
110- this.2
111-
112- end
113-
114- instance [M.IsFinitePresentation] : M.IsFiniteType where
115- exists_localGeneratorsData :=
116- ⟨M.quasicoherentDataOfIsFinitePresentation.localGeneratorsData,
117- by intro; dsimp; infer_instance⟩
128+ @[deprecated "Use the lemma `IsFinitePresentation.exists_quasicoherentData` instead."
129+ (since := "2025-10-28" )]
130+ noncomputable def quasicoherentDataOfIsFinitePresentation
131+ (M : SheafOfModules.{u} R) [M.IsFinitePresentation] : M.QuasicoherentData :=
132+ (IsFinitePresentation.exists_quasicoherentData M).choose
118133
119134end SheafOfModules
0 commit comments