Definition associator_profunctor_nat_trans_mor {C₁ C₂ C₃ C₄ : category} (P₁ : C₁ ↛ C₂) (P₂ : C₂ ↛ C₃) (P₃ : C₃ ↛ C₄) (z : C₄) (w : C₁) : comp_profunctor P₁ (comp_profunctor P₂ P₃) z w → comp_profunctor (comp_profunctor P₁ P₂) P₃ z w. Proof. use from_comp_profunctor_ob. - exact (λ x h, associator_profunctor_nat_trans_mor_ob P₁ P₂ P₃ z w x h). - abstract (intros x₁ x₂ f h h' ; cbn in * ; use (mor_from_comp_profunctor_ob_eq P₂ P₃ _ _ (λ k, associator_profunctor_nat_trans_mor_ob P₁ P₂ P₃ z w x₂ h (comp_profunctor_mor P₂ P₃ (identity z) f k)) (associator_profunctor_nat_trans_mor_ob P₁ P₂ P₃ z w x₁ (lmap P₁ f h))) ; clear h' ; intros y k k' ; cbn ; rewrite comp_profunctor_mor_comm ; rewrite lmap_id ; refine (associator_profunctor_nat_trans_mor_ob_comm P₁ P₂ P₃ h (rmap P₂ f k) k' @ _) ; refine (!_) ; etrans ; [ apply associator_profunctor_nat_trans_mor_ob_comm | ] ; rewrite comp_profunctor_ob_in_comm ; apply idpath). Defined.
Require Import UniMath.Foundations.All. Require Import UniMath.MoreFoundations.All. Require Import UniMath.CategoryTheory.Core.Prelude. Require Import UniMath.CategoryTheory.FunctorCategory. Require Import UniMath.CategoryTheory.PrecategoryBinProduct. Require Import UniMath.CategoryTheory.opp_precat. Require Import UniMath.CategoryTheory.Categories.HSET.All. Require Import UniMath.CategoryTheory.Categories.HSET.SetCoends. Require Import UniMath.CategoryTheory.Profunctors.Core. Require Import UniMath.CategoryTheory.Profunctors.Examples.