import Mathlib import Definitions.Def_AlgebraicGeometry_TwoChartCechCupProduct import Definitions.Def_AlgebraicGeometry_TwoAffineOpenCoverKaehler import Definitions.Def_AlgebraicGeometry_TwoChartCechLaurentChart set_option autoImplicit false noncomputable section universe u v w namespace TwoChartCech.Cover variable {R : Type u} [CommRing R] (๐’ฐ : Cover.{u, v} R) {ฮน : Type w} [Fintype ฮน] def residueSum (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) : ฮฉ[๐’ฐ.A01โ„R] โ†’โ‚—[R] R := โˆ‘ i, (ฮ› i).residue theorem residueSum_apply (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (ฮท : ฮฉ[๐’ฐ.A01โ„R]) : ๐’ฐ.residueSum ฮ› ฮท = โˆ‘ i, (ฮ› i).residue ฮท := by rw [residueSum, LinearMap.sum_apply] def ResiduesVanishOnCoboundaries (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) : Prop := LinearMap.range ๐’ฐ.kaehler.cechDiff โ‰ค LinearMap.ker (๐’ฐ.residueSum ฮ›) theorem residuesVanishOnCoboundaries_iff (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ› โ†” (โˆ€ ฯ‰ : ฮฉ[๐’ฐ.A0โ„R], ๐’ฐ.residueSum ฮ› (๐’ฐ.kaehler.r0 ฯ‰) = 0) โˆง โˆ€ ฯ‰ : ฮฉ[๐’ฐ.A1โ„R], ๐’ฐ.residueSum ฮ› (๐’ฐ.kaehler.r1 ฯ‰) = 0 := by constructor ยท intro h refine โŸจfun ฯ‰ => ?_, fun ฯ‰ => ?_โŸฉ ยท have hmem := h (LinearMap.mem_range_self ๐’ฐ.kaehler.cechDiff ((ฯ‰, 0) : _ ร— _)) rwa [LinearMap.mem_ker, Sections.cechDiff_apply, map_zero, zero_sub, map_neg, neg_eq_zero] at hmem ยท have hmem := h (LinearMap.mem_range_self ๐’ฐ.kaehler.cechDiff ((0, ฯ‰) : _ ร— _)) rwa [LinearMap.mem_ker, Sections.cechDiff_apply, map_zero, sub_zero] at hmem ยท rintro โŸจh0, h1โŸฉ _ โŸจs, rflโŸฉ rw [LinearMap.mem_ker, Sections.cechDiff_apply, map_sub, h0, h1, sub_zero] def kaehlerTrace (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) : ๐’ฐ.kaehler.H1 โ†’โ‚—[R] R := ๐’ฐ.kaehler.traceForm (๐’ฐ.residueSum ฮ›) hv @[simp] theorem kaehlerTrace_mk (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) (ฮท : ฮฉ[๐’ฐ.A01โ„R]) : ๐’ฐ.kaehlerTrace ฮ› hv (Submodule.Quotient.mk ฮท) = โˆ‘ i, (ฮ› i).residue ฮท := by rw [kaehlerTrace, Sections.traceForm_mk, residueSum_apply] def serrePairingInt (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) : ๐’ฐ.kaehler.H0 โ†’โ‚—[R] ๐’ฐ.structureSheaf.H1 โ†’โ‚—[R] R := ๐’ฐ.kaehler.tracePairing (๐’ฐ.residueSum ฮ›) hv theorem serrePairingInt_apply_mk (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) (ฯ‰ : ๐’ฐ.kaehler.H0) (f : ๐’ฐ.A01) : ๐’ฐ.serrePairingInt ฮ› hv ฯ‰ (Submodule.Quotient.mk f) = โˆ‘ i, (ฮ› i).residue (f โ€ข ๐’ฐ.kaehler.r0 ฯ‰.val.1) := by rw [serrePairingInt, Sections.tracePairing_apply_mk, residueSum_apply] theorem serrePairingInt_apply_mk' (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) (ฯ‰ : ๐’ฐ.kaehler.H0) (f : ๐’ฐ.A01) : ๐’ฐ.serrePairingInt ฮ› hv ฯ‰ (Submodule.Quotient.mk f) = โˆ‘ i, (ฮ› i).residue (f โ€ข ๐’ฐ.kaehler.r1 ฯ‰.val.2) := by rw [serrePairingInt_apply_mk, (๐’ฐ.kaehler.mem_H0_iff _).mp ฯ‰.2] theorem serrePairingInt_eq_kaehlerTrace_cupProduct (ฮ› : ฮน โ†’ ๐’ฐ.LaurentChart) (hv : ๐’ฐ.ResiduesVanishOnCoboundaries ฮ›) (ฯ‰ : ๐’ฐ.kaehler.H0) (x : ๐’ฐ.structureSheaf.H1) : ๐’ฐ.serrePairingInt ฮ› hv ฯ‰ x = ๐’ฐ.kaehlerTrace ฮ› hv (๐’ฐ.kaehler.cupProduct ฯ‰ x) := rfl end TwoChartCech.Cover end