Skip to content

[Merged by Bors] - feat(CategoryTheory/Monoidal): left action of monoidal categories#25761

Closed
robin-carlier wants to merge 20 commits intoleanprover-community:masterfrom
robin-carlier:robin-carlier/monoidal_left_actions_1
Closed

[Merged by Bors] - feat(CategoryTheory/Monoidal): left action of monoidal categories#25761
robin-carlier wants to merge 20 commits intoleanprover-community:masterfrom
robin-carlier:robin-carlier/monoidal_left_actions_1

Conversation

@robin-carlier
Copy link
Copy Markdown
Contributor

@robin-carlier robin-carlier commented Jun 12, 2025

Define (left) actions of a monoidal category on a category: a MonoidalLeftAction of a monoidal category C on a category D consists of an action bifunctor - ⊙ₗ - : C ⥤ D ⥤ D, equipped with structural natural isomorphisms (- ⊗ -) ⊙ₗ - ≅ - ⊙ₗ - ⊙ₗ - and 𝟙_ C ⊙ₗ - ≅ -, subject to coherence conditions.

The code in this PR is parallel to the existing code for monoidal category.

We provide a battery of basic simp lemmas to ease working with this type class, and show that every monoidal category acts on itself via its tensor product.

The code is put in a new subdirectory CategoryTheory/Monoidal/Action.

Future wok on the subject includes

  • Providing a constructor for MonoidalLeftAction taking a monoidal functor from C to D ⥤ D, where the latter has the "composition" monoidal structure.
  • Constructing the action of C ⥤ C on C.
  • Extending the notion of module objects internal to a monoidal category to allow the Mon_ object to be in C, and the module to be in D where D has a monoidal left action of C.
  • Using the two previous points, show that given a monad M, there is an equivalence of categories between Algebra M and modules in C over the monoid M.toMon : Mon_ (C ⥤ C)̀.

Open in Gitpod


This PR continues the work from #25499.

Original PR: #25499

@github-actions
Copy link
Copy Markdown

github-actions bot commented Jun 12, 2025

PR summary db52f0992d

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.CategoryTheory.Monoidal.Action.Basic (new file) 312

Declarations diff

+ MonoidalLeftAction
+ MonoidalLeftActionStruct
+ actionAssocIso_inv_naturality
+ actionAssocNatIso
+ actionHomLeft_action
+ actionHomRight_comp
+ actionHomRight_hom_inv
+ actionHomRight_hom_inv'
+ actionHomRight_inv_hom
+ actionHomRight_inv_hom'
+ actionHom_def'
+ actionHom_id
+ actionLeft
+ actionRight
+ actionUnitIso_inv_naturality
+ actionUnitNatIso
+ action_exchange
+ comp_actionHomLeft
+ curriedAction
+ hom_inv_actionHomLeft
+ hom_inv_actionHomLeft'
+ id_actionHom
+ inv_actionHom
+ inv_actionHomLeft
+ inv_actionHomRight
+ inv_hom_actionHomLeft
+ inv_hom_actionHomLeft'
+ isIso_actionHom
+ isIso_actionHomLeft
+ isIso_actionHomRight
+ selfAction
+ tensor_actionHomRight
+ unit_actionHomRight

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.


No changes to technical debt.

You can run this locally as

./scripts/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

@joelriou joelriou added the awaiting-author A reviewer has asked the author a question or requested changes. label Jun 15, 2025
@robin-carlier robin-carlier removed the awaiting-author A reviewer has asked the author a question or requested changes. label Jun 15, 2025
Co-authored-by: Joël Riou <37772949+joelriou@users.noreply.github.com>
@joelriou joelriou added the awaiting-author A reviewer has asked the author a question or requested changes. label Jun 16, 2025
@robin-carlier
Copy link
Copy Markdown
Contributor Author

Since apparently we’re changing the notation for the tensor product of morphisms, I’ve changed the notation for actionHom from ⊙ₗ to ⊙ₗₘ.

@robin-carlier robin-carlier removed the awaiting-author A reviewer has asked the author a question or requested changes. label Jun 16, 2025
@joelriou
Copy link
Copy Markdown
Contributor

Thanks!

bors merge

@ghost ghost added the ready-to-merge This PR has been sent to bors. label Jun 17, 2025
mathlib-bors bot pushed a commit that referenced this pull request Jun 17, 2025
…5761)

Define (left) actions of a monoidal category on a category: a `MonoidalLeftAction` of a monoidal category `C` on a category `D` consists of an action bifunctor `- ⊙ₗ - : C ⥤ D ⥤ D`, equipped with structural natural isomorphisms `(- ⊗ -) ⊙ₗ - ≅ - ⊙ₗ - ⊙ₗ -` and `𝟙_ C ⊙ₗ - ≅ -`, subject to coherence conditions.

The code in this PR is parallel to the existing code for monoidal category. 

We provide a battery of basic `simp` lemmas to ease working with this type class, and show that every monoidal category acts on itself via its tensor product.  

The code is put in a new subdirectory `CategoryTheory/Monoidal/Action`.

Future wok on the subject includes 
- Providing a constructor for `MonoidalLeftAction` taking a monoidal functor from `C` to `D ⥤ D`, where the latter has the "composition" monoidal structure.
- Constructing the action of `C ⥤ C` on `C`.
- Extending the notion of module objects internal to a monoidal category to allow the `Mon_ ` object to be in `C`, and the module to be in `D` where `D` has a monoidal left action of `C`.
- Using the two previous points, show that given a monad `M`, there is an equivalence of categories between `Algebra M` and modules in `C` over the monoid `M.toMon : Mon_ (C ⥤ C)̀`.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Jun 17, 2025

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(CategoryTheory/Monoidal): left action of monoidal categories [Merged by Bors] - feat(CategoryTheory/Monoidal): left action of monoidal categories Jun 17, 2025
@mathlib-bors mathlib-bors bot closed this Jun 17, 2025
mathlib-bors bot pushed a commit that referenced this pull request Jun 22, 2025
We introduce the notion of a right action of a monoidal category `C` on a category `D`. This notion is formally conjugate to that of a left action introduced in #25761, and so are every results in this PR. Please refer to #25761 for a more detailed overview of the notion. The notion comes with its set of notations.

We show basic simp lemmas for these objects, and we show that any monoidal category acts on the right on itself.
mathlib-bors bot pushed a commit that referenced this pull request Jun 22, 2025
We introduce the notion of a right action of a monoidal category `C` on a category `D`. This notion is formally conjugate to that of a left action introduced in #25761, and so are every results in this PR. Please refer to #25761 for a more detailed overview of the notion. The notion comes with its set of notations.

We show basic simp lemmas for these objects, and we show that any monoidal category acts on the right on itself.
Rida-Hamadani pushed a commit to Rida-Hamadani/mathlib4 that referenced this pull request Jun 24, 2025
…anprover-community#25761)

Define (left) actions of a monoidal category on a category: a `MonoidalLeftAction` of a monoidal category `C` on a category `D` consists of an action bifunctor `- ⊙ₗ - : C ⥤ D ⥤ D`, equipped with structural natural isomorphisms `(- ⊗ -) ⊙ₗ - ≅ - ⊙ₗ - ⊙ₗ -` and `𝟙_ C ⊙ₗ - ≅ -`, subject to coherence conditions.

The code in this PR is parallel to the existing code for monoidal category. 

We provide a battery of basic `simp` lemmas to ease working with this type class, and show that every monoidal category acts on itself via its tensor product.  

The code is put in a new subdirectory `CategoryTheory/Monoidal/Action`.

Future wok on the subject includes 
- Providing a constructor for `MonoidalLeftAction` taking a monoidal functor from `C` to `D ⥤ D`, where the latter has the "composition" monoidal structure.
- Constructing the action of `C ⥤ C` on `C`.
- Extending the notion of module objects internal to a monoidal category to allow the `Mon_ ` object to be in `C`, and the module to be in `D` where `D` has a monoidal left action of `C`.
- Using the two previous points, show that given a monad `M`, there is an equivalence of categories between `Algebra M` and modules in `C` over the monoid `M.toMon : Mon_ (C ⥤ C)̀`.
Rida-Hamadani pushed a commit to Rida-Hamadani/mathlib4 that referenced this pull request Jun 24, 2025
…ver-community#25840)

We introduce the notion of a right action of a monoidal category `C` on a category `D`. This notion is formally conjugate to that of a left action introduced in leanprover-community#25761, and so are every results in this PR. Please refer to leanprover-community#25761 for a more detailed overview of the notion. The notion comes with its set of notations.

We show basic simp lemmas for these objects, and we show that any monoidal category acts on the right on itself.
joelriou pushed a commit to joelriou/mathlib4 that referenced this pull request Jul 7, 2025
…ver-community#25840)

We introduce the notion of a right action of a monoidal category `C` on a category `D`. This notion is formally conjugate to that of a left action introduced in leanprover-community#25761, and so are every results in this PR. Please refer to leanprover-community#25761 for a more detailed overview of the notion. The notion comes with its set of notations.

We show basic simp lemmas for these objects, and we show that any monoidal category acts on the right on itself.
callesonne pushed a commit to callesonne/mathlib4 that referenced this pull request Jul 24, 2025
…anprover-community#25761)

Define (left) actions of a monoidal category on a category: a `MonoidalLeftAction` of a monoidal category `C` on a category `D` consists of an action bifunctor `- ⊙ₗ - : C ⥤ D ⥤ D`, equipped with structural natural isomorphisms `(- ⊗ -) ⊙ₗ - ≅ - ⊙ₗ - ⊙ₗ -` and `𝟙_ C ⊙ₗ - ≅ -`, subject to coherence conditions.

The code in this PR is parallel to the existing code for monoidal category. 

We provide a battery of basic `simp` lemmas to ease working with this type class, and show that every monoidal category acts on itself via its tensor product.  

The code is put in a new subdirectory `CategoryTheory/Monoidal/Action`.

Future wok on the subject includes 
- Providing a constructor for `MonoidalLeftAction` taking a monoidal functor from `C` to `D ⥤ D`, where the latter has the "composition" monoidal structure.
- Constructing the action of `C ⥤ C` on `C`.
- Extending the notion of module objects internal to a monoidal category to allow the `Mon_ ` object to be in `C`, and the module to be in `D` where `D` has a monoidal left action of `C`.
- Using the two previous points, show that given a monad `M`, there is an equivalence of categories between `Algebra M` and modules in `C` over the monoid `M.toMon : Mon_ (C ⥤ C)̀`.
callesonne pushed a commit to callesonne/mathlib4 that referenced this pull request Jul 24, 2025
…ver-community#25840)

We introduce the notion of a right action of a monoidal category `C` on a category `D`. This notion is formally conjugate to that of a left action introduced in leanprover-community#25761, and so are every results in this PR. Please refer to leanprover-community#25761 for a more detailed overview of the notion. The notion comes with its set of notations.

We show basic simp lemmas for these objects, and we show that any monoidal category acts on the right on itself.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge This PR has been sent to bors. t-category-theory Category theory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants