File size: 7,470 Bytes
0dd3af4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 | import Mathlib
import OAI.GroupTheory.SimpleAmenable.Simplicial.PolygonPositionalMonoidal
namespace OAI
open scoped symmDiff
namespace SimpleAmenable
open scoped commutatorElement
section PolygonStringGroupoid
open Classical CategoryTheory
open scoped MonoidalCategory
namespace PolygonObject
variable {a : ℕ}
abbrev RawString (a n : ℕ) := Fin (n+1) ⥤ PolygonObject a
def ladderProperty (a n : ℕ) : MorphismProperty (RawString a n) :=
(positionalProperty a).functorCategory (Fin (n+1))
instance ladderProperty_multiplicative (n : ℕ) : (ladderProperty a n).IsMultiplicative where
id_mem F i := identity_positional (F.obj i)
comp_mem _ _ hf hg i := positional_comp (hf i) (hg i)
instance ladderProperty_monoidal (n : ℕ) : (ladderProperty a n).IsMonoidalStable where
whiskerLeft F _ _ _ hg i := sumArrow_positional (identity_positional (F.obj i)) (hg i)
whiskerRight _ hf G i := sumArrow_positional (hf i) (identity_positional (G.obj i))
associator_hom_mem F G H i := sumAssoc_positional (F.obj i) (G.obj i) (H.obj i)
associator_inv_mem F G H i := positional_inv (sumAssoc_positional (F.obj i) (G.obj i) (H.obj i))
leftUnitor_hom_mem F i := leftUnit_positional (F.obj i)
leftUnitor_inv_mem F i := positional_inv (leftUnit_positional (F.obj i))
rightUnitor_hom_mem F i := rightUnit_positional (F.obj i)
rightUnitor_inv_mem F i := positional_inv (rightUnit_positional (F.obj i))
instance ladderProperty_braided (n : ℕ) : (ladderProperty a n).IsStableUnderBraiding where
braiding_hom_mem F G i := sumSwap_positional (F.obj i) (G.obj i)
braiding_inv_mem F G i := positional_inv (sumSwap_positional (F.obj i) (G.obj i))
abbrev StringGroupoid (a n : ℕ) := WideSubcategory (ladderProperty a n)
noncomputable instance stringGroupoid_isIso {n : ℕ} (F G : StringGroupoid a n) (f : F ⟶ G) : IsIso f := by
let : IsIso f.hom := NatIso.isIso_of_isIso_app f.hom
refine ⟨⟨⟨CategoryTheory.inv f.hom,?_⟩,?_,?_⟩⟩
· intro i
rw [NatIso.isIso_inv_app]
exact positional_inv (f.property i)
· apply WideSubcategory.hom_ext
exact IsIso.hom_inv_id f.hom
· apply WideSubcategory.hom_ext
exact IsIso.inv_hom_id f.hom
noncomputable instance stringGroupoid (n : ℕ) : Groupoid (StringGroupoid a n) :=
Groupoid.ofIsIso (fun _ => inferInstance)
noncomputable def stringReindex {n m : ℕ} (u : Fin (n+1) ⥤ Fin (m+1)) :
StringGroupoid a m ⥤ StringGroupoid a n where
obj F := ⟨u ⋙ F.obj⟩
map f := ⟨CategoryTheory.Functor.whiskerLeft u f.hom,fun i => f.property (u.obj i)⟩
map_id F := by apply WideSubcategory.hom_ext; rfl
map_comp f g := by apply WideSubcategory.hom_ext; rfl
@[simp] theorem stringReindex_id (n : ℕ) : stringReindex (a:=a) (𝟭 (Fin (n+1)))=𝟭 _ := by
apply CategoryTheory.Functor.ext
· intro F G f; rfl
· intro F; cases F; rfl
@[simp] theorem stringReindex_comp {n m k : ℕ}
(u : Fin (n+1) ⥤ Fin (m+1)) (v : Fin (m+1) ⥤ Fin (k+1)) :
stringReindex (a:=a) (u⋙v)=stringReindex v ⋙ stringReindex u := by
apply CategoryTheory.Functor.ext
· intro F G f; rfl
· intro F; rfl
noncomputable instance stringReindex_monoidal {n m : ℕ} (u : Fin (n+1) ⥤ Fin (m+1)) :
(stringReindex (a:=a) u).Monoidal :=
Functor.CoreMonoidal.toMonoidal {
εIso := Iso.refl _
μIso := fun _ _ => Iso.refl _
μIso_hom_natural_left := by intros; simp; apply WideSubcategory.hom_ext; rfl
μIso_hom_natural_right := by intros; simp; apply WideSubcategory.hom_ext; rfl
associativity := by
intro first second third
apply WideSubcategory.hom_ext
apply NatTrans.ext
funext point
change (𝟙 _ ▷ _ ≫ 𝟙 _ ≫ (α_ _ _ _).hom) =
((α_ _ _ _).hom ≫ _ ◁ 𝟙 _ ≫ 𝟙 _)
simp
left_unitality := by
intro object
apply WideSubcategory.hom_ext
apply NatTrans.ext
funext point
change (λ_ _).hom = 𝟙 _ ▷ _ ≫ 𝟙 _ ≫ (λ_ _).hom
simp
right_unitality := by
intro object
apply WideSubcategory.hom_ext
apply NatTrans.ext
funext point
change (ρ_ _).hom = _ ◁ 𝟙 _ ≫ 𝟙 _ ≫ (ρ_ _).hom
simp }
end PolygonObject
end PolygonStringGroupoid
open Classical CategoryTheory
namespace PolygonObject
variable {a n : ℕ}
def baseArrow (F : RawString a n) (i : Fin (n+1)) : F.obj 0 ⟶ F.obj i :=
F.map (homOfLE (Fin.zero_le i))
@[simp] theorem baseArrow_zero (F : RawString a n) : baseArrow F 0=𝟙 _ := by
unfold baseArrow
exact (congrArg F.map (show homOfLE (Fin.zero_le (0 : Fin (n+1)))=𝟙 (0 : Fin (n+1))
from Subsingleton.elim _ _)).trans (F.map_id _)
@[simp, reassoc] theorem baseArrow_comp (F : RawString a n) {i j : Fin (n+1)}
(f : i ⟶ j) : baseArrow F i ≫ F.map f=baseArrow F j := by
rw [baseArrow,←F.map_comp]
congr 1
noncomputable def extendLadder {F G : RawString a n} (h : F.obj 0 ⟶ G.obj 0) : F ⟶ G where
app i := CategoryTheory.inv (baseArrow F i) ≫ h ≫ baseArrow G i
naturality i j f := by
have he : F.map f ≫ CategoryTheory.inv (baseArrow F j)=CategoryTheory.inv (baseArrow F i) := by
apply (cancel_epi (baseArrow F i)).mp
rw [←Category.assoc,baseArrow_comp]
simp
simp only [←Category.assoc,he]
simp only [Category.assoc,baseArrow_comp]
@[simp] theorem extendLadder_zero {F G : RawString a n} (h : F.obj 0 ⟶ G.obj 0) :
(extendLadder h).app 0=h := by
simp [extendLadder]
theorem ladder_ext {F G : RawString a n} {h k : F ⟶ G}
(h0 : h.app 0=k.app 0) : h=k := by
apply NatTrans.ext
funext i
apply (cancel_epi (baseArrow F i)).mp
rw [show baseArrow F i=F.map (homOfLE (Fin.zero_le i)) from rfl,
h.naturality,k.naturality,h0]
@[simp] theorem extendLadder_app_zero {F G : RawString a n} (h : F ⟶ G) :
extendLadder (h.app 0)=h := ladder_ext (extendLadder_zero _)
def trajectory (F : RawString a n) (x : (F.obj 0).Point) (i : Fin (n+1)) :=
((baseArrow F i).toEquiv x).val.2
theorem ladder_preserves_trajectory {F G : StringGroupoid a n} (h : F ⟶ G)
(x : (F.obj.obj 0).Point) :
trajectory G.obj ((h.hom.app 0).toEquiv x)=trajectory F.obj x := by
funext i
have he := congrArg (fun k : F.obj.obj 0 ⟶ G.obj.obj i => k.toEquiv x)
(h.hom.naturality (homOfLE (Fin.zero_le i)))
change (h.hom.app i).toEquiv ((baseArrow F.obj i).toEquiv x) =
(baseArrow G.obj i).toEquiv ((h.hom.app 0).toEquiv x) at he
unfold trajectory
rw [←he]
exact h.property i _
theorem extendLadder_positional {F G : RawString a n} (h : F.obj 0 ⟶ G.obj 0)
(he : ∀x,trajectory G (h.toEquiv x)=trajectory F x) :
(ladderProperty a n) (extendLadder h) := by
intro i y
let x := (baseArrow F i).toEquiv.symm y
have hi := congrFun (he x) i
change ((baseArrow G i).toEquiv (h.toEquiv x)).val.2=
((baseArrow F i).toEquiv x).val.2 at hi
simpa only [extendLadder,arrow_comp_apply,inv_arrow_apply,x,Equiv.apply_symm_apply] using hi
noncomputable def ladderEquiv (F G : StringGroupoid a n) :
(F ⟶ G) ≃ {h : F.obj.obj 0 ⟶ G.obj.obj 0 //
∀x,trajectory G.obj (h.toEquiv x)=trajectory F.obj x} where
toFun h := ⟨h.hom.app 0,ladder_preserves_trajectory h⟩
invFun h := ⟨extendLadder h.val,extendLadder_positional h.val h.property⟩
left_inv h := by apply WideSubcategory.hom_ext; exact extendLadder_app_zero h.hom
right_inv h := by apply Subtype.ext; exact extendLadder_zero h.val
end PolygonObject
end SimpleAmenable
end OAI
|