openAI-math-dataset / lean /OAI /Algebra /AuslanderReiten /Resolutions /ResolutionEndpointIso.lean
roseking's picture
Add lean source and binary files (part 6)
2c7d975 verified
Raw History Blame Contribute Delete
3.12 kB
14
private theorem compose_square {A B D X Y Z : C}
    (p : A ⟶ X) (q : B ⟶ Y) (r : D ⟶ Z)
    (f : A ⟶ B) (g : B ⟶ D) (a : X ⟶ Y) (b : Y ⟶ Z) (c : X ⟶ Z)
    (hp : p ≫ a = f ≫ q) (hq : q ≫ b = g ≫ r) (hc : p ≫ c = (f ≫ g) ≫ r) :
    p ≫ c = p ≫ a ≫ b := by
proof · 7 lines
  calc
    p ≫ c = (f ≫ g) ≫ r := hc
    _ = f ≫ g ≫ r := Category.assoc _ _ _
    _ = f ≫ q ≫ b := congrArg (fun z => f ≫ z) hq.symm
    _ = (f ≫ q) ≫ b := (Category.assoc _ _ _).symm
    _ = (p ≫ a) ≫ b := congrArg (fun z => z ≫ b) hp.symm
    _ = p ≫ a ≫ b := Category.assoc _ _ _
27
def resolutionEndpointMap (f : P.complex ⟶ Q.complex) : X ⟶ Y :=
body · 3 lines
  P.isColimitCokernelCofork.desc (CokernelCofork.ofπ (f.f 0 ≫ Q.π.f 0) (by
    rw [← Category.assoc, ← f.comm 1 0, Category.assoc,
      Q.complex_d_comp_π_f_zero, comp_zero]))
32
@[reassoc] theorem resolutionEndpointMap_augmentation (f : P.complex ⟶ Q.complex) :
    P.π.f 0 ≫ resolutionEndpointMap P Q f = f.f 0 ≫ Q.π.f 0 :=
proof · 1 line
  Cofork.IsColimit.π_desc P.isColimitCokernelCofork
36
theorem resolutionEndpointMap_id : resolutionEndpointMap P P (𝟙 _) = 𝟙 X := by
proof · 3 lines
  apply (cancel_epi (P.π.f 0)).1
  erw [resolutionEndpointMap_augmentation]
  exact (Category.id_comp _).trans (Category.comp_id _).symm
41
theorem resolutionEndpointMap_comp (T : ProjectiveResolution Z)
    (f : P.complex ⟶ Q.complex) (g : Q.complex ⟶ T.complex) :
    resolutionEndpointMap P T (f ≫ g) = resolutionEndpointMap P Q f ≫ resolutionEndpointMap Q T g := by
proof · 5 lines
  apply (cancel_epi (P.π.f 0)).1
  exact compose_square (show P.complex.X 0 ⟶ X from P.π.f 0)
    (show Q.complex.X 0 ⟶ Y from Q.π.f 0) (show T.complex.X 0 ⟶ Z from T.π.f 0)
    (f.f 0) (g.f 0) _ _ _ (resolutionEndpointMap_augmentation P Q f)
    (resolutionEndpointMap_augmentation Q T g) (resolutionEndpointMap_augmentation P T (f ≫ g))
50
def resolutionEndpointIso (e : P.complex ≅ Q.complex) : X ≅ Y where
body · 4 lines
  hom := resolutionEndpointMap P Q e.hom
  inv := resolutionEndpointMap Q P e.inv
  hom_inv_id := by erw [← resolutionEndpointMap_comp, e.hom_inv_id, resolutionEndpointMap_id]
  inv_hom_id := by erw [← resolutionEndpointMap_comp, e.inv_hom_id, resolutionEndpointMap_id]
56
@[reassoc] theorem resolutionEndpointIso_augmentation (e : P.complex ≅ Q.complex) :
    P.π.f 0 ≫ (resolutionEndpointIso P Q e).hom = e.hom.f 0 ≫ Q.π.f 0 :=
proof · 1 line
  resolutionEndpointMap_augmentation P Q e.hom
60
theorem resolutionEndpointIso_hom_unique (e : P.complex ≅ Q.complex) (a : X ⟶ Y)
    (ha : P.π.f 0 ≫ a = e.hom.f 0 ≫ Q.π.f 0) :
    (resolutionEndpointIso P Q e).hom = a := by
proof · 2 lines
  apply (cancel_epi (P.π.f 0)).1
  erw [resolutionEndpointIso_augmentation, ha]