mathlib4 icon indicating copy to clipboard operation
mathlib4 copied to clipboard

feat(FiberCategory/Fibered): definition of a fibered category

Open callesonne opened this issue 1 year ago • 1 comments

We define the class IsFibered p which captures what it means for a functor p : š’³ ℤ š’® to be a fibered category and add some basic API. To define IsFibered, we also define cartesian arrows with respect to p as the structure IsCartesian. We also prove some basic results about cartesian arrows. See the repository Stacks-project for more WIP on fibered categories using these definitions.

Co-authored-by: Paul Lezeau [email protected]


  • [ ] depends on: #12978

Open in Gitpod

callesonne avatar May 17 '24 13:05 callesonne

Let me label this with awaiting-review --- since I presume that, once the dependent PR is merged, you'd like a review :-) awaiting-review

grunweg avatar May 24 '24 18:05 grunweg

I also have a question about design approach @joelriou . In https://github.com/Paul-Lez/Stacks-project, we have a notion of BasedCategory defined as follows:

/-- A based category over `š’®` is a category `š’³` together with a functor `p : š’³ ℤ š’®` -/
structure BasedCategory (š’® : Type u₁) [Category.{v₁} š’®] where
  (cat : Type uā‚‚)
  [isCat : Category.{vā‚‚} cat]
  (p : cat ℤ š’®)

We developed this as a preliminary step to dealing with functors between different fibered categories, and we showed that BasedCategory š’® forms a strict bicategory. Now, do you think it could be good to rewrite the code defining IsFibered and IsCartesian to use š’³ : BasedCategory š’® as a parameter instead of p : š’³ ℤ š’®? Or is it unecessary to lock p inside š’³ : BasedCategory š’®, since we don't talk about functors between (pre-)fibered categories in this PR anyways?

callesonne avatar May 29 '24 07:05 callesonne

Here is an update on this PR. I have split it into 4 smaller PRs. This one now only concerns the definition of a fibered category, defined as in SGA, and also an alternate constructor for using the definition as in e.g. Stacks project.

callesonne avatar Jun 01 '24 10:06 callesonne

PR summary c01f68f57f

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference

Declarations diff

+ Functor.IsFibered + instance (p : š’³ ℤ š’®) [p.IsFibered] {R S T : š’®} (f : R ⟶ S) (g : S ⟶ T) {a b c : š’³} (φ : a ⟶ b) + isStronglyCartesian_of_exists_isCartesian + isStronglyCartesian_of_isCartesian + of_exists_isStronglyCartesian + pullbackPullbackIso ++ domainUniqueUpToIso_hom_isHomLift ++ domainUniqueUpToIso_inv_isHomLift

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.

github-actions[bot] avatar Jun 27 '24 08:06 github-actions[bot]

This PR/issue depends on:

  • ~~leanprover-community/mathlib4#13416~~
  • ~~leanprover-community/mathlib4#13410~~
  • ~~leanprover-community/mathlib4#13393~~
  • ~~leanprover-community/mathlib4#12978~~ By Dependent Issues (šŸ¤–). Happy coding!

Thanks! Note the whitespace comment.

bors d+ joelriou

kbuzzard avatar Sep 24 '24 14:09 kbuzzard

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

mathlib-bors[bot] avatar Sep 24 '24 14:09 mathlib-bors[bot]

Oops. Meant to delegate to @joelriou

bors d-

mattrobball avatar Sep 24 '24 14:09 mattrobball

See if this syntax works

bors d+=joelriou

mattrobball avatar Sep 24 '24 14:09 mattrobball

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

mathlib-bors[bot] avatar Sep 24 '24 14:09 mathlib-bors[bot]

bors d=joelriou

jcommelin avatar Sep 24 '24 14:09 jcommelin

:v: 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.

mathlib-bors[bot] avatar Sep 24 '24 14:09 mathlib-bors[bot]

@joelriou are you happy with this now?

kbuzzard avatar Sep 24 '24 14:09 kbuzzard

Thanks!

bors merge

joelriou avatar Sep 27 '24 22:09 joelriou

Pull request successfully merged into master.

Build succeeded:

mathlib-bors[bot] avatar Sep 27 '24 22:09 mathlib-bors[bot]