math / data /lean /OAI /Algebra /Finitistic /Rectification /DiagramAssembly.lean
introvoyz045's picture
Migrated from GitHub
4a56cd6 verified
Raw History Blame Contribute Delete
3.77 kB
import OAI.Algebra.Finitistic.Rectification.ColumnComplex
namespace OAI
open CategoryTheory CategoryTheory.Limits HomologicalComplex
noncomputable section
namespace ExternalTensor.Section4
universe u
variable {k : Type u} [Field k]
variable {C : Type u} [Category C] [Preadditive C] [Linear k C] [HasFiniteBiproducts C] [HasBinaryBiproducts C]
variable {A J R : Type} [Fintype A] [Fintype J] [Fintype R]
/-- The concrete column/map interface. No composite or null-homotopy is assumed.
The three equations are path naturality, the algebra relations, and the chosen
relation homotopies after column induction. -/
structure AssemblyData where
Vβ‚€ : C
V₁ : C
Vβ‚‚ : C
U : A β†’ C
V : J β†’ C
W : R β†’ C
paβ‚€ : βˆ€ a, U a ⟢ Vβ‚€
pa₁ : βˆ€ a, U a ⟢ V₁
pb₁ : βˆ€ b, V b ⟢ V₁
pbβ‚‚ : βˆ€ b, V b ⟢ Vβ‚‚
qa : βˆ€ relation arrow, J β†’ (W relation ⟢ U arrow)
qb : βˆ€ relation, A β†’ βˆ€ arrow, W relation ⟢ V arrow
rel : βˆ€ r, W r ⟢ Vβ‚‚
middle : βˆ€ r a b, qa r a b ≫ pa₁ a = qb r a b ≫ pb₁ b
first : βˆ€ r, βˆ‘ a, βˆ‘ b, qa r a b ≫ paβ‚€ a = 0
last : βˆ€ r, βˆ‘ a, βˆ‘ b, qb r a b ≫ pbβ‚‚ b = rel r
namespace AssemblyData
variable (s : AssemblyData (C := C) (A := A) (J := J) (R := R))
abbrev Lβ‚€ := s.Vβ‚€ ⊞ (s.V₁ ⊞ s.Vβ‚‚)
abbrev L₁ := (⨁ s.U) ⊞ (⨁ s.V)
abbrev Lβ‚‚ := ⨁ s.W
abbrev inβ‚€ : s.Vβ‚€ ⟢ s.Lβ‚€ := biprod.inl
abbrev in₁ : s.V₁ ⟢ s.Lβ‚€ := biprod.inl ≫ biprod.inr
abbrev inβ‚‚ : s.Vβ‚‚ ⟢ s.Lβ‚€ := biprod.inr ≫ biprod.inr
def p : s.L₁ ⟢ s.Lβ‚€ :=
biprod.desc
(biproduct.desc fun a => s.paβ‚€ a ≫ s.inβ‚€ - s.pa₁ a ≫ s.in₁)
(biproduct.desc fun b => s.pb₁ b ≫ s.in₁ - s.pbβ‚‚ b ≫ s.inβ‚‚)
def q : s.Lβ‚‚ ⟢ s.L₁ :=
biproduct.desc fun r => βˆ‘ a, βˆ‘ b,
(s.qa r a b ≫ biproduct.ΞΉ s.U a ≫ biprod.inl +
s.qb r a b ≫ biproduct.ΞΉ s.V b ≫ biprod.inr)
/-- The complete cancellation in Section 4, including the minus sign. -/
theorem composite : s.q ≫ s.p =
-(biproduct.desc fun r => s.rel r ≫ s.inβ‚‚) := by
apply biproduct.hom_ext'
intro r
simp only [q, biproduct.ΞΉ_desc_assoc, Preadditive.comp_neg,
biproduct.ΞΉ_desc]
simp only [Preadditive.sum_comp, Preadditive.add_comp, Category.assoc, p,
biprod.inl_desc, biprod.inr_desc, biproduct.ΞΉ_desc, Preadditive.comp_sub,
]
simp only [← Category.assoc, s.middle]
simp only [Category.assoc]
have cancel (a : A) (b : J) :
s.qa r a b ≫ s.paβ‚€ a ≫ s.inβ‚€ - s.qb r a b ≫ s.pb₁ b ≫ s.in₁ +
(s.qb r a b ≫ s.pb₁ b ≫ s.in₁ - s.qb r a b ≫ s.pbβ‚‚ b ≫ s.inβ‚‚) =
s.qa r a b ≫ s.paβ‚€ a ≫ s.inβ‚€ - s.qb r a b ≫ s.pbβ‚‚ b ≫ s.inβ‚‚ := by abel
simp_rw [cancel, Finset.sum_sub_distrib]
have hf := congrArg (fun z => z ≫ s.inβ‚€) (s.first r)
have hl := congrArg (fun z => z ≫ s.inβ‚‚) (s.last r)
simp only [Preadditive.sum_comp, Category.assoc, zero_comp] at hf hl
rw [hf, hl]
simp
/-- A componentwise specified finite sum of homotopies. -/
def sumHomotopy {E : Type*} [Category E] [Preadditive E]
{X Y : CochainComplex E β„€} {I : Type} [Fintype I]
(f : I β†’ (X ⟢ Y)) (H : βˆ€ i, Homotopy (f i) 0) :
Homotopy (βˆ‘ i, f i) 0 where
hom n m := βˆ‘ i, (H i).hom n m
zero n m h := by simp [fun i => (H i).zero n m h]
comm n := by
change Hom.fAddMonoidHom n (βˆ‘ i, f i) = _
rw [map_sum]
change (βˆ‘ i, (f i).f n) = _
calc
_ = βˆ‘ i, (dNext n (H i).hom + prevD n (H i).hom + (0 : X ⟢ Y).f n) :=
Finset.sum_congr rfl (fun i _ => (H i).comm n)
_ = _ := by
simp [dNext, prevD, Preadditive.comp_sum, Preadditive.sum_comp,
Finset.sum_add_distrib]
end AssemblyData
end ExternalTensor.Section4
end
end OAI