Download lean/OAI/Algebra/AuslanderReiten/Resolutions/CProjectiveResolution.lean from roseking/openAI-math-dataset: direct link, hf CLI and curl.
- Browser
- Download file 5.34 kB
-
https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Algebra/AuslanderReiten/Resolutions/CProjectiveResolution.lean
- Command line
-
hf download hf://datasets/roseking/openAI-math-dataset/lean/OAI/Algebra/AuslanderReiten/Resolutions/CProjectiveResolution.lean
-
curl -L -o CProjectiveResolution.lean https://huggingface.co/datasets/roseking/openAI-math-dataset/resolve/main/lean/OAI/Algebra/AuslanderReiten/Resolutions/CProjectiveResolution.lean
5.34 kB
Lean 4 · 22
declarations statementsfull
abbrev Simple := (F q) ⧸ LinearMap.range (dU q) def objects : ℕ → ModuleCat C body · 2 lines
| 0 => ModuleCat.of C (F q)
| _ + 1 => ModuleCat.of C (E q)def differential : (n : ℕ) → objects q (n + 1) ⟶ objects q n body · 2 lines
| 0 => ModuleCat.ofHom (dU q)
| n + 1 => ModuleCat.ofHom (dEll q (q ^ n))theorem differential_comp (n : ℕ) : differential q (n + 1) ≫ differential q n = 0 := by proof · 9 lines
cases n with
| zero =>
apply ModuleCat.hom_ext
change (dU q).comp (dEll q (q ^ 0)) = 0
simpa only [pow_zero] using dU_comp_dEll_one q
| succ n =>
apply ModuleCat.hom_ext
change (dEll q (q ^ n)).comp (dEll q (q ^ (n + 1))) = 0
simpa only [pow_succ'] using dEll_comp_successor q (q ^ n)def complex : ChainComplex (ModuleCat C) ℕ := body · 1 line
ChainComplex.of (objects q) (differential q) (differential_comp q)instance complex_projective (n : ℕ) : CategoryTheory.Projective ((complex q).X n) := by body · 1 line
cases n <;> dsimp [complex, objects] <;> infer_instance
instance complex_scalar (n : ℕ) : Module k ((complex q).X n) := by body · 3 lines
cases n with
| zero => exact (inferInstance : Module k (F q))
| succ n => exact (inferInstance : Module k (E q))instance complex_finite (n : ℕ) : Module.Finite k ((complex q).X n) := by body · 3 lines
cases n with
| zero => exact (inferInstance : Module.Finite k (F q))
| succ n => exact (inferInstance : Module.Finite k (E q))def NoPositivePowerOne : Prop := ∀ m : ℕ, 0 < m → 1 + q ^ m ≠ 0 theorem denominator_power_ne (h : NoPositivePowerOne q) (n : ℕ) :
1 + q ^ 2 * q ^ n ≠ 0 := by proof · 2 lines
rw [← pow_add]
exact h (2 + n) (by omega)theorem differential_exact (h : NoPositivePowerOne q) (n : ℕ) :
Function.Exact (differential q (n + 1)) (differential q n) := by proof · 9 lines
cases n with
| zero =>
change Function.Exact (dEll q (q ^ 0)) (dU q)
simpa only [pow_zero] using exact_dU q (by simpa using h 1 (by decide)) (h 2 (by decide))
| succ n =>
change Function.Exact (dEll q (q ^ (n + 1))) (dEll q (q ^ n))
simpa only [pow_succ'] using exact_dEll q (q ^ n)
(denominator_power_ne q h n)
(by simpa [pow_succ'] using denominator_power_ne q h (n + 1))theorem complex_exactAt_succ (h : NoPositivePowerOne q) (n : ℕ) :
(complex q).ExactAt (n + 1) := by proof · 4 lines
rw [HomologicalComplex.exactAt_iff' _ (n + 1 + 1) (n + 1) n (by simp) (by simp)]
apply (ShortComplex.ShortExact.moduleCat_exact_iff_function_exact _).mpr
simpa [complex, HomologicalComplex.sc', HomologicalComplex.shortComplexFunctor',
ChainComplex.of_d] using! differential_exact q h ndef augmentation : (complex q).X 0 ⟶ ModuleCat.of C (Simple q) := body · 1 line
ModuleCat.ofHom (LinearMap.range (dU q)).mkQinstance augmentation_epi : Epi (augmentation q) := body · 1 line
(ModuleCat.epi_iff_surjective _).mpr (Submodule.mkQ_surjective _)theorem differential_augmentation : (complex q).d 1 0 ≫ augmentation q = 0 := by proof · 3 lines
apply ModuleCat.hom_ext
change (LinearMap.range (dU q)).mkQ.comp (dU q) = 0
exact LinearMap.range_mkQ_comp (dU q)def toSimple : complex q ⟶ (ChainComplex.single₀ (ModuleCat C)).obj (ModuleCat.of C (Simple q)) := body · 1 line
(ChainComplex.toSingle₀Equiv _ _).symm ⟨augmentation q, differential_augmentation q⟩@[simp] theorem toSimple_zero : (toSimple q).f 0 = augmentation q := proof · 1 line
ChainComplex.toSingle₀Equiv_symm_apply_f_zero _ _theorem augmentation_exact :
(ShortComplex.mk ((complex q).d 1 0) (augmentation q) (differential_augmentation q)).Exact := by proof · 3 lines
apply (ShortComplex.ShortExact.moduleCat_exact_iff_function_exact _).mpr
change Function.Exact (dU q) (LinearMap.range (dU q)).mkQ
exact LinearMap.exact_map_mkQ_range (dU q)theorem toSimple_quasiIso (h : NoPositivePowerOne q) : QuasiIso (toSimple q) := by proof · 15 lines
constructor
intro n
cases n with
| zero =>
rw [ChainComplex.quasiIsoAt₀_iff, ShortComplex.quasiIso_iff_of_zeros']
· change (ShortComplex.mk ((complex q).d 1 0) ((toSimple q).f 0) _).Exact ∧
Epi ((toSimple q).f 0)
simpa only [toSimple_zero, ChainComplex.single₀_obj_zero] using And.intro (augmentation_exact q) (augmentation_epi q)
· rfl
· rfl
· rfl
| succ n =>
rw [quasiIsoAt_iff_exactAt']
· exact complex_exactAt_succ q h n
· exact ChainComplex.exactAt_succ_single_obj _ _def projectiveResolution (h : NoPositivePowerOne q) :
CategoryTheory.ProjectiveResolution (ModuleCat.of C (Simple q)) where body · 3 lines
complex := complex q
π := toSimple q
quasiIso := toSimple_quasiIso q htheorem baseField_noPositivePowerOne : NoPositivePowerOne ArExplicit.q := by proof · 2 lines
intro m hm
simpa [add_comm] using ArExplicit.q_pow_add_one_ne_zero m hmdef baseFieldProjectiveResolution :
CategoryTheory.ProjectiveResolution
(ModuleCat.of (BaseAlgebra BaseField ArExplicit.q) (Simple ArExplicit.q)) := body · 1 line
projectiveResolution ArExplicit.q baseField_noPositivePowerOneOutline
- abbrev
Simple19 - def
objects21 - def
differential25 - theorem
differential_comp29 - def
complex40 - instance
complex_projective43 - instance
complex_scalar46 - instance
complex_finite51 - def
NoPositivePowerOne56 - theorem
denominator_power_ne59 - theorem
differential_exact64 - theorem
complex_exactAt_succ76 - def
augmentation83 - instance
augmentation_epi86 - theorem
differential_augmentation89 - def
toSimple94 - theorem
toSimple_zero97 - theorem
augmentation_exact100 - theorem
toSimple_quasiIso106 - def
projectiveResolution123 - theorem
baseField_noPositivePowerOne129 - def
baseFieldProjectiveResolution133