Skip to content

[Merged by Bors] - feat(Algebra/Category/ModuleCat/Presheaf): presheaves of modules are generated by their sections#18160

Closed
joelriou wants to merge 21 commits intomasterfrom
presheaf-of-modules-generators
Closed

[Merged by Bors] - feat(Algebra/Category/ModuleCat/Presheaf): presheaves of modules are generated by their sections#18160
joelriou wants to merge 21 commits intomasterfrom
presheaf-of-modules-generators

Conversation

@joelriou
Copy link
Copy Markdown
Contributor

@joelriou joelriou commented Oct 24, 2024

We provide a presentation of any presheaf of modules involving coproducts of free presheaves of modules generated by Yoneda presheaves of types.


Open in Gitpod

@joelriou joelriou added the t-category-theory Category theory label Oct 24, 2024
@github-actions github-actions bot added the t-algebra Algebra (groups, rings, fields, etc) label Oct 24, 2024
@github-actions
Copy link
Copy Markdown

github-actions bot commented Oct 24, 2024

PR summary ca1a155f7f

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.Algebra.Category.ModuleCat.Presheaf.Generator 1305

Declarations diff

+ Elements
+ elementsMk
+ freeYonedaCoproduct
+ freeYonedaCoproductMk
+ freeYonedaCoproductsCokernelCofork
+ freeYonedaEquiv
+ freeYonedaEquiv_comp
+ freeYonedaEquiv_symm_app
+ fromFreeYoneda
+ fromFreeYonedaCoproduct
+ fromFreeYonedaCoproduct_app_mk
+ fromFreeYoneda_app_apply
+ instance : Epi M.fromFreeYonedaCoproduct
+ instance : Small.{u} (freeYoneda R) := by
+ isColimitFreeYonedaCoproductsCokernelCofork
+ isDetecting
+ isSeparating
+ toFreeYonedaCoproduct
+ toFreeYonedaCoproduct_fromFreeYonedaCoproduct
+ wellPowered
+ ιFreeYonedaCoproduct
+ ι_fromFreeYonedaCoproduct
+ ι_fromFreeYonedaCoproduct_apply
++ freeYoneda

You can run this locally as follows
## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>

## more verbose report:
./scripts/declarations_diff.sh long <optional_commit>

The doc-module for script/declarations_diff.sh contains some details about this script.


Increase in tech debt: 1.00
Current number Change Type
1555 1 erw

Current commit ca1a155f7f
Reference commit 23ecdee3fc

You can run this locally as

./scripts/technical-debt-metrics.sh pr_summary

@mathlib4-dependent-issues-bot mathlib4-dependent-issues-bot added blocked-by-other-PR This PR depends on another PR (this label is automatically managed by a bot) and removed blocked-by-other-PR This PR depends on another PR (this label is automatically managed by a bot) labels Oct 24, 2024
@mathlib4-dependent-issues-bot
Copy link
Copy Markdown
Collaborator

@leanprover-community-bot-assistant leanprover-community-bot-assistant added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Oct 24, 2024
@leanprover-community-bot-assistant leanprover-community-bot-assistant removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Oct 24, 2024
@joelriou joelriou removed the WIP Work in progress label Oct 31, 2024
@erdOne erdOne added the awaiting-author A reviewer has asked the author a question or requested changes. label Nov 4, 2024
@joelriou joelriou removed the awaiting-author A reviewer has asked the author a question or requested changes. label Nov 4, 2024
Copy link
Copy Markdown
Member

@kbuzzard kbuzzard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very elegant stuff!


In this file, given a presheaf of rings `R` on a category `C`,
we construct a set `FreeYoneda R` of presheaves of modules that
is separating and detecting: this set consists of presheaves of
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not an expert in this area but I would like to see progress in algebraic geometry so I'm attempting to review anyway! This terminology was hard for me to understand. Is a "separating set" the same as a "family of generators" in the sense of https://en.wikipedia.org/wiki/Generator_(category_theory) ?

Edit: Aah, just reading the code and looking at the docstrings is answering my questions. Maybe you could highlight

PresheafOfModules.freeYoneda.isSeparating : IsSeparating (freeYoneda R) 
PresheafOfModules.freeYoneda.isDetecting : IsDetecting (freeYoneda R) 

as "main results" in the module docstring?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the reviews! I have rewritten the module docstring.

/-- The set of `PresheafOfModules.{v} R` consisting of objects of the
form `(free R).obj (yoneda.obj X)` for some `X`. -/
def freeYoneda : Set (PresheafOfModules.{v} R) := Set.range (yoneda ⋙ free R).obj

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aah, you could have used yoneda ⋙ free R earlier, for example line 43 could have been (((yoneda ⋙ free R).obj X) ⟶ M) ≃ M.obj (Opposite.op X) . Is it worth choosing a standard form for this?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When applied on a X, the better (dsimp) form is (free R).obj (yoneda.obj X).

lemma fromFreeYonedaCoproduct_app_mk (e : M.Elements) :
M.fromFreeYonedaCoproduct.app _ (M.freeYonedaCoproductMk e) = e.2 := by
dsimp [freeYonedaCoproductMk]
erw [M.ι_fromFreeYonedaCoproduct_apply e]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know why rw [M.ι_fromFreeYonedaCoproduct_apply e e.fst (ModuleCat.freeMk (𝟙 (Opposite.unop e.fst)))] doesn't work?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is basically the same reason why ι_fromFreeYonedaCoproduct_apply cannot be a simp lemma, as, according to the linter, it is not in simpNF. If we apply dsimp to the statement, for the "human" eye, nothing changes, but there are hidden changes behind a DFunLike.coe: the definition of some types can be unfolded by dsimp. See also https://leanprover.zulipchat.com/#narrow/channel/287929-mathlib4/topic/attribute.20simp_NF_my_lemma.3F/near/443101462

@jcommelin jcommelin added the awaiting-author A reviewer has asked the author a question or requested changes. label Nov 11, 2024
joelriou and others added 3 commits November 12, 2024 10:14
Co-authored-by: Kevin Buzzard <k.buzzard@imperial.ac.uk>
Co-authored-by: Kevin Buzzard <k.buzzard@imperial.ac.uk>
Co-authored-by: Kevin Buzzard <k.buzzard@imperial.ac.uk>
@joelriou joelriou removed the awaiting-author A reviewer has asked the author a question or requested changes. label Nov 12, 2024
Copy link
Copy Markdown
Member

@TwoFX TwoFX left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!
bors d+

@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Nov 14, 2024

✌️ joelriou can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@ghost ghost added the delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). label Nov 14, 2024
@joelriou
Copy link
Copy Markdown
Contributor Author

Thanks!

bors merge

@github-actions github-actions bot added the ready-to-merge This PR has been sent to bors. label Nov 14, 2024
mathlib-bors bot pushed a commit that referenced this pull request Nov 14, 2024
…generated by their sections (#18160)

We provide a presentation of any presheaf of modules involving coproducts of free presheaves of modules generated by Yoneda presheaves of types.



Co-authored-by: Joël Riou <37772949+joelriou@users.noreply.github.com>
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Nov 14, 2024

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(Algebra/Category/ModuleCat/Presheaf): presheaves of modules are generated by their sections [Merged by Bors] - feat(Algebra/Category/ModuleCat/Presheaf): presheaves of modules are generated by their sections Nov 14, 2024
@mathlib-bors mathlib-bors bot closed this Nov 14, 2024
@mathlib-bors mathlib-bors bot deleted the presheaf-of-modules-generators branch November 14, 2024 20:28
TobiasLeichtfried pushed a commit that referenced this pull request Nov 21, 2024
…generated by their sections (#18160)

We provide a presentation of any presheaf of modules involving coproducts of free presheaves of modules generated by Yoneda presheaves of types.



Co-authored-by: Joël Riou <37772949+joelriou@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). ready-to-merge This PR has been sent to bors. t-algebra Algebra (groups, rings, fields, etc) t-category-theory Category theory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants