import OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.ResidueSplitInjection import OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.KernelDetectorTensor import OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.DetectedKernelContraction /-! # Unit Kernel Contraction -/ namespace OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.Global.UnitKernelContraction noncomputable section /-! A finite projective complex whose maximal residue kernels are generated by an injective unit has a global contraction in degree zero. The contraction formula survives every scalar extension. -/ theorem global_kernel_contraction_of_residue_unit {R M N : Type} [CommRing R] [AddCommGroup M] [Module R M] [Module.Finite R M] [Module.Projective R M] [AddCommGroup N] [Module R N] [Module.Finite R N] [Module.Projective R N] (d : M →ₗ[R] N) (u : R →ₗ[R] M) (hd : d.comp u = 0) (hu : ∀ (P : Ideal R) (_ : P.IsMaximal), Function.Injective (u.lTensor (IsLocalRing.ResidueField (Localization.AtPrime P)))) (hex : ∀ (P : Ideal R) (_ : P.IsMaximal), (d.lTensor (IsLocalRing.ResidueField (Localization.AtPrime P))).ker = (u.lTensor (IsLocalRing.ResidueField (Localization.AtPrime P))).range) : ∃ (s : M →ₗ[R] R) (v : N →ₗ[R] M), s.comp u = LinearMap.id ∧ v.comp d + u.comp s = LinearMap.id := by obtain ⟨s, hs⟩ := ResidueSplitInjection.split_injective_of_residue_fields u hu obtain ⟨p, hp⟩ := ResidueSplitInjection.split_injective_of_residue_fields (d.prod s) (fun P hP => KernelDetectorTensor.tensor_kernel_detector_injective d s u hs (hex P hP)) obtain ⟨v, hv⟩ := DetectedKernelContraction.kernel_contraction_of_split_detector d s u hs hd p hp exact ⟨s, v, hs, hv⟩ end end OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.Global.UnitKernelContraction