l3lab/ntp-mathlib huggingface dataset:
/-- Composition of oplax functors. -/
--@[simps]
def comp (F : OplaxFunctor B C) (G : OplaxFunctor C D) : OplaxFunctor B D :=
  {
    (F : PrelaxFunctor B C).comp G with
    mapId := fun a => by exact (G.mapFunctor _ _).map (F.mapId a) ≫ G.mapId (F.obj a)
    mapComp := fun f g => by
      exact (G.mapFunctor _ _).map (F.mapComp f g) ≫ G.mapComp (F.map f) (F.map g)
    mapComp_naturality_left := fun η g => by
      dsimp
      rw [← map₂_comp_assoc, mapComp_naturality_left, map₂_comp_assoc, mapComp_naturality_left,
        assoc]
    mapComp_naturality_right := fun η => by
      dsimp
      intros
      rw [← map₂_comp_assoc, mapComp_naturality_right, map₂_comp_assoc, mapComp_naturality_right,
        assoc]
    map₂_associator := fun f g h => by
      dsimp
      -- porting note: if you use the `map₂_associator_aux` hack in the definition of
      -- `map₂_associator` then the `simp only` call below does not seem to apply `map₂_associator`
      simp only [map₂_associator, ← map₂_comp_assoc, ← mapComp_naturality_right_assoc,
        whiskerLeft_comp, assoc]
      simp only [map₂_associator, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
    map₂_leftUnitor := fun f => by
      dsimp
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ F : OplaxFunctor B C
G : OplaxFunctor C D
src✝ : PrelaxFunctor B D := PrelaxFunctor.comp F.toPrelaxFunctor G.toPrelaxFunctor
a✝ b✝ : B
f : a✝ ⟶ b✝
⊢ PrelaxFunctor.map₂ G.toPrelaxFunctor (PrelaxFunctor.map₂ F.toPrelaxFunctor (λ_ f).hom) =
    (PrelaxFunctor.map₂ G.toPrelaxFunctor (mapComp F (𝟙 a✝) f) ≫
        mapComp G ((↑F.toPrelaxFunctor).map (𝟙 a✝)) ((↑F.toPrelaxFunctor).map f)) ≫
      (PrelaxFunctor.map₂ G.toPrelaxFunctor (mapId F a✝) ≫ mapId G ((↑F.toPrelaxFunctor).obj a✝)) ▷
          (↑G.toPrelaxFunctor).map ((↑F.toPrelaxFunctor).map f) ≫
        (λ_ ((↑G.toPrelaxFunctor).map ((↑F.toPrelaxFunctor).map f))).hom

Next tactic:
simp only [map₂_leftUnitor, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
/-- Composition of oplax functors. -/
--@[simps]
def comp (F : OplaxFunctor B C) (G : OplaxFunctor C D) : OplaxFunctor B D :=
  {
    (F : PrelaxFunctor B C).comp G with
    mapId := fun a => by exact (G.mapFunctor _ _).map (F.mapId a) ≫ G.mapId (F.obj a)
    mapComp := fun f g => by
      exact (G.mapFunctor _ _).map (F.mapComp f g) ≫ G.mapComp (F.map f) (F.map g)
    mapComp_naturality_left := fun η g => by
      dsimp
      rw [← map₂_comp_assoc, mapComp_naturality_left, map₂_comp_assoc, mapComp_naturality_left,
        assoc]
    mapComp_naturality_right := fun η => by
      dsimp
      intros
      rw [← map₂_comp_assoc, mapComp_naturality_right, map₂_comp_assoc, mapComp_naturality_right,
        assoc]
    map₂_associator := fun f g h => by
      dsimp
      -- porting note: if you use the `map₂_associator_aux` hack in the definition of
      -- `map₂_associator` then the `simp only` call below does not seem to apply `map₂_associator`
      simp only [map₂_associator, ← map₂_comp_assoc, ← mapComp_naturality_right_assoc,
        whiskerLeft_comp, assoc]
      simp only [map₂_associator, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
    map₂_leftUnitor := fun f => by
      dsimp
      simp only [map₂_leftUnitor, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
    map₂_rightUnitor := fun f => by
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ F : OplaxFunctor B C
G : OplaxFunctor C D
src✝ : PrelaxFunctor B D := PrelaxFunctor.comp F.toPrelaxFunctor G.toPrelaxFunctor
a✝ b✝ : B
f : a✝ ⟶ b✝
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (ρ_ f).hom =
    (fun {a b c} f g =>
          (mapFunctor G ((↑F.toPrelaxFunctor).obj a) ((↑F.toPrelaxFunctor).obj c)).map (mapComp F f g) ≫
            mapComp G ((↑F.toPrelaxFunctor).map f) ((↑F.toPrelaxFunctor).map g))
        f (𝟙 b✝) ≫
      (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f ◁
          (fun a =>
              (mapFunctor G ((↑F.toPrelaxFunctor).obj a) ((↑F.toPrelaxFunctor).obj a)).map (mapId F a) ≫
                mapId G ((↑F.toPrelaxFunctor).obj a))
            b✝ ≫
        (ρ_ ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f)).hom

Next tactic:
dsimp
/-- Composition of oplax functors. -/
--@[simps]
def comp (F : OplaxFunctor B C) (G : OplaxFunctor C D) : OplaxFunctor B D :=
  {
    (F : PrelaxFunctor B C).comp G with
    mapId := fun a => by exact (G.mapFunctor _ _).map (F.mapId a) ≫ G.mapId (F.obj a)
    mapComp := fun f g => by
      exact (G.mapFunctor _ _).map (F.mapComp f g) ≫ G.mapComp (F.map f) (F.map g)
    mapComp_naturality_left := fun η g => by
      dsimp
      rw [← map₂_comp_assoc, mapComp_naturality_left, map₂_comp_assoc, mapComp_naturality_left,
        assoc]
    mapComp_naturality_right := fun η => by
      dsimp
      intros
      rw [← map₂_comp_assoc, mapComp_naturality_right, map₂_comp_assoc, mapComp_naturality_right,
        assoc]
    map₂_associator := fun f g h => by
      dsimp
      -- porting note: if you use the `map₂_associator_aux` hack in the definition of
      -- `map₂_associator` then the `simp only` call below does not seem to apply `map₂_associator`
      simp only [map₂_associator, ← map₂_comp_assoc, ← mapComp_naturality_right_assoc,
        whiskerLeft_comp, assoc]
      simp only [map₂_associator, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
    map₂_leftUnitor := fun f => by
      dsimp
      simp only [map₂_leftUnitor, map₂_comp, mapComp_naturality_left_assoc, comp_whiskerRight,
        assoc]
    map₂_rightUnitor := fun f => by
      dsimp
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ F : OplaxFunctor B C
G : OplaxFunctor C D
src✝ : PrelaxFunctor B D := PrelaxFunctor.comp F.toPrelaxFunctor G.toPrelaxFunctor
a✝ b✝ : B
f : a✝ ⟶ b✝
⊢ PrelaxFunctor.map₂ G.toPrelaxFunctor (PrelaxFunctor.map₂ F.toPrelaxFunctor (ρ_ f).hom) =
    (PrelaxFunctor.map₂ G.toPrelaxFunctor (mapComp F f (𝟙 b✝)) ≫
        mapComp G ((↑F.toPrelaxFunctor).map f) ((↑F.toPrelaxFunctor).map (𝟙 b✝))) ≫
      (↑G.toPrelaxFunctor).map ((↑F.toPrelaxFunctor).map f) ◁
          (PrelaxFunctor.map₂ G.toPrelaxFunctor (mapId F b✝) ≫ mapId G ((↑F.toPrelaxFunctor).obj b✝)) ≫
        (ρ_ ((↑G.toPrelaxFunctor).map ((↑F.toPrelaxFunctor).map f))).hom

Next tactic:
simp only [map₂_rightUnitor, map₂_comp, mapComp_naturality_right_assoc, whiskerLeft_comp,
        assoc]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f : a✝ ⟶ b✝
g h : b✝ ⟶ c✝
η : g ⟶ h
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (f ◁ η) =
    ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') f g).hom ≫
      (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f ◁
          PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } η ≫
        ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') f h).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      dsimp
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f : a✝ ⟶ b✝
g h : b✝ ⟶ c✝
η : g ⟶ h
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (f ◁ η) =
    (OplaxFunctor.PseudoCore.mapCompIso F' f g).hom ≫
      (↑F.toPrelaxFunctor).map f ◁ PrelaxFunctor.map₂ F.toPrelaxFunctor η ≫
        (OplaxFunctor.PseudoCore.mapCompIso F' f h).inv

Next tactic:
rw [F'.mapCompIso_hom f g, ← F.mapComp_naturality_right_assoc, ← F'.mapCompIso_hom f h,
        hom_inv_id, comp_id]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [F'.mapCompIso_hom f g, ← F.mapComp_naturality_right_assoc, ← F'.mapCompIso_hom f h,
        hom_inv_id, comp_id]
    map₂_whisker_right := fun η h => by
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f✝ g✝ : a✝ ⟶ b✝
η : f✝ ⟶ g✝
h : b✝ ⟶ c✝
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (η ▷ h) =
    ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') f✝ h).hom ≫
      PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } η ▷
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h ≫
        ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') g✝ h).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [F'.mapCompIso_hom f g, ← F.mapComp_naturality_right_assoc, ← F'.mapCompIso_hom f h,
        hom_inv_id, comp_id]
    map₂_whisker_right := fun η h => by
      dsimp
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f✝ g✝ : a✝ ⟶ b✝
η : f✝ ⟶ g✝
h : b✝ ⟶ c✝
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (η ▷ h) =
    (OplaxFunctor.PseudoCore.mapCompIso F' f✝ h).hom ≫
      PrelaxFunctor.map₂ F.toPrelaxFunctor η ▷ (↑F.toPrelaxFunctor).map h ≫
        (OplaxFunctor.PseudoCore.mapCompIso F' g✝ h).inv

Next tactic:
rw [F'.mapCompIso_hom _ h, ← F.mapComp_naturality_left_assoc, ← F'.mapCompIso_hom _ h,
        hom_inv_id, comp_id]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [F'.mapCompIso_hom f g, ← F.mapComp_naturality_right_assoc, ← F'.mapCompIso_hom f h,
        hom_inv_id, comp_id]
    map₂_whisker_right := fun η h => by
      dsimp
      rw [F'.mapCompIso_hom _ h, ← F.mapComp_naturality_left_assoc, ← F'.mapCompIso_hom _ h,
        hom_inv_id, comp_id]
    map₂_associator := fun f g h => by
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ d✝ : B
f : a✝ ⟶ b✝
g : b✝ ⟶ c✝
h : c✝ ⟶ d✝
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (α_ f g h).hom =
    ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') (f ≫ g) h).hom ≫
      ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') f g).hom ▷
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h ≫
        (α_ ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f)
              ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map g)
              ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h)).hom ≫
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f ◁
              ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') g h).inv ≫
            ((fun {a b c} => OplaxFunctor.PseudoCore.mapCompIso F') f (g ≫ h)).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
def mkOfOplax (F : OplaxFunctor B C) (F' : F.PseudoCore) : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := F'.mapIdIso
    mapComp := F'.mapCompIso
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [F'.mapCompIso_hom f g, ← F.mapComp_naturality_right_assoc, ← F'.mapCompIso_hom f h,
        hom_inv_id, comp_id]
    map₂_whisker_right := fun η h => by
      dsimp
      rw [F'.mapCompIso_hom _ h, ← F.mapComp_naturality_left_assoc, ← F'.mapCompIso_hom _ h,
        hom_inv_id, comp_id]
    map₂_associator := fun f g h => by
      dsimp
      

Proof state:
B : Type u₁
inst✝² : Bicategory B
C : Type u₂
inst✝¹ : Bicategory C
D : Type u₃
inst✝ : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
F' : OplaxFunctor.PseudoCore F
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ d✝ : B
f : a✝ ⟶ b✝
g : b✝ ⟶ c✝
h : c✝ ⟶ d✝
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (α_ f g h).hom =
    (OplaxFunctor.PseudoCore.mapCompIso F' (f ≫ g) h).hom ≫
      (OplaxFunctor.PseudoCore.mapCompIso F' f g).hom ▷ (↑F.toPrelaxFunctor).map h ≫
        (α_ ((↑F.toPrelaxFunctor).map f) ((↑F.toPrelaxFunctor).map g) ((↑F.toPrelaxFunctor).map h)).hom ≫
          (↑F.toPrelaxFunctor).map f ◁ (OplaxFunctor.PseudoCore.mapCompIso F' g h).inv ≫
            (OplaxFunctor.PseudoCore.mapCompIso F' f (g ≫ h)).inv

Next tactic:
rw [F'.mapCompIso_hom (f ≫ g) h, F'.mapCompIso_hom f g, ← F.map₂_associator_assoc, ←
        F'.mapCompIso_hom f (g ≫ h), ← F'.mapCompIso_hom g h, hom_inv_whiskerLeft_assoc,
        hom_inv_id, comp_id]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f : a✝ ⟶ b✝
g h : b✝ ⟶ c✝
η : g ⟶ h
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (f ◁ η) =
    ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) f g).hom ≫
      (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f ◁
          PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } η ≫
        ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) f h).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      dsimp
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f : a✝ ⟶ b✝
g h : b✝ ⟶ c✝
η : g ⟶ h
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (f ◁ η) =
    OplaxFunctor.mapComp F f g ≫
      (↑F.toPrelaxFunctor).map f ◁ PrelaxFunctor.map₂ F.toPrelaxFunctor η ≫ inv (OplaxFunctor.mapComp F f h)

Next tactic:
rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_right]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_right]
    map₂_whisker_right := fun η h => by
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f✝ g✝ : a✝ ⟶ b✝
η : f✝ ⟶ g✝
h : b✝ ⟶ c✝
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (η ▷ h) =
    ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) f✝ h).hom ≫
      PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } η ▷
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h ≫
        ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) g✝ h).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_right]
    map₂_whisker_right := fun η h => by
      dsimp
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ : B
f✝ g✝ : a✝ ⟶ b✝
η : f✝ ⟶ g✝
h : b✝ ⟶ c✝
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (η ▷ h) =
    OplaxFunctor.mapComp F f✝ h ≫
      PrelaxFunctor.map₂ F.toPrelaxFunctor η ▷ (↑F.toPrelaxFunctor).map h ≫ inv (OplaxFunctor.mapComp F g✝ h)

Next tactic:
rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_left]
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_right]
    map₂_whisker_right := fun η h => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_left]
    map₂_associator := fun f g h => by
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ d✝ : B
f : a✝ ⟶ b✝
g : b✝ ⟶ c✝
h : c✝ ⟶ d✝
⊢ PrelaxFunctor.map₂ { toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ } (α_ f g h).hom =
    ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) (f ≫ g) h).hom ≫
      ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) f g).hom ▷
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h ≫
        (α_ ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f)
              ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map g)
              ((↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map h)).hom ≫
          (↑{ toPrefunctor := ↑src✝, map₂ := fun {a b} {f g} => PrelaxFunctor.map₂ src✝ }).map f ◁
              ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) g h).inv ≫
            ((fun {a b c} f g => asIso (OplaxFunctor.mapComp F f g)) f (g ≫ h)).inv

Next tactic:
dsimp
/-- Construct a pseudofunctor from an oplax functor whose `mapId` and `mapComp` are isomorphisms.
-/
@[simps]
noncomputable def mkOfOplax' (F : OplaxFunctor B C) [∀ a, IsIso (F.mapId a)]
    [∀ {a b c} (f : a ⟶ b) (g : b ⟶ c), IsIso (F.mapComp f g)] : Pseudofunctor B C :=
  { (F : PrelaxFunctor B C) with
    mapId := fun a => asIso (F.mapId a)
    mapComp := fun f g => asIso (F.mapComp f g)
    map₂_whisker_left := fun f g h η => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_right]
    map₂_whisker_right := fun η h => by
      dsimp
      rw [← assoc, IsIso.eq_comp_inv, F.mapComp_naturality_left]
    map₂_associator := fun f g h => by
      dsimp
      

Proof state:
B : Type u₁
inst✝⁴ : Bicategory B
C : Type u₂
inst✝³ : Bicategory C
D : Type u₃
inst✝² : Bicategory D
F✝ : Pseudofunctor B C
F : OplaxFunctor B C
inst✝¹ : ∀ (a : B), IsIso (OplaxFunctor.mapId F a)
inst✝ : ∀ {a b c : B} (f : a ⟶ b) (g : b ⟶ c), IsIso (OplaxFunctor.mapComp F f g)
src✝ : PrelaxFunctor B C := F.toPrelaxFunctor
a✝ b✝ c✝ d✝ : B
f : a✝ ⟶ b✝
g : b✝ ⟶ c✝
h : c✝ ⟶ d✝
⊢ PrelaxFunctor.map₂ F.toPrelaxFunctor (α_ f g h).hom =
    OplaxFunctor.mapComp F (f ≫ g) h ≫
      OplaxFunctor.mapComp F f g ▷ (↑F.toPrelaxFunctor).map h ≫
        (α_ ((↑F.toPrelaxFunctor).map f) ((↑F.toPrelaxFunctor).map g) ((↑F.toPrelaxFunctor).map h)).hom ≫
          (↑F.toPrelaxFunctor).map f ◁ inv (OplaxFunctor.mapComp F g h) ≫ inv (OplaxFunctor.mapComp F f (g ≫ h))

Next tactic:
simp only [← assoc]