module public import Mathlib.CategoryTheory.Limits.Final.Type public import Lib.Cohomology.ProjectiveLine.ChernClass /-! # Integration over ℙ¹, compared cohomology theories, and moving kernel classes in (ℙ¹)^d The file gives the geometric step of the duality for a zero locus in (ℙ¹)^d: a kernel class is moved between points one coordinate at a time. In the first section, g is a functor from C to tests over A, ℓ is invertible in A, and I is a family of ideals on the points of a functor X on tests. η denotes the class `New.Variety.etaClass`; `M.HasLineFormula` (the projective line formula) says that, for every S, each class from S over the points of ℙ¹ is a·1 + b·η for unique a, b restricted from the base. The file then sets up the formal comparison of two cohomology theories on tests over `A`, using integration over `ℙ¹`. ## Main definitions and results * `New.Variety.IdealFamily.exists_move_kernel`: a class at the point t(q) is moved to t(q') by multiplying with the classes η(q_j) + η(q'_j). * `New.Variety.TorsionCoeff.HasLineFormula.integrate`: integration `a + η b ↦ b` over `ℙ¹`, given `New.Variety.TorsionCoeff.HasLineFormula`. * `New.Variety.ComparedTheory`, `New.Variety.ComparedTheory.IsFiniteLerayHirsch`: a theory with maps from the locally constant `ZMod ℓ` coefficients, and the property that these maps compute its cohomology from finite groups. * `New.Variety.NaturalOp`: operations on cohomology, natural in the theory, with parameters in `ℙ¹`. * `New.Variety.ComparedTheory.isClosedClass_isFiniteLerayHirsch`, `New.Variety.ComparedTheory.isFiniteLerayHirsch_of_shortExact`, `New.Variety.ComparedTheory.isFiniteLerayHirsch_iff_of_isCohomEquiv`, `New.Variety.ComparedTheory.isFiniteLerayHirsch_of_retract`: the property passes along short exact sequences, equivalences and retracts by operations. * `New.Variety.ComparedTheory.isFiniteLerayHirsch_of_integrate_params`, `New.Variety.ComparedTheory.isFiniteLerayHirsch_topPoints_of_surjective`: it passes to pairs in `(ℙ¹)^m`, by self-duality. Notions from other files: * `New.Variety.TestOver`: The category of tests over A: the full subcategory of commutative A-algebras whose underlying rings are test rings. * `New.Variety.TorsionCoeff`: a functor F on C to abelian groups, killed by ℓ, with Zariski descent for the rings g(c). A `New.Variety.Theory` is one that also behaves well on closed loci. * `New.Variety.IdealFamily`: For a functor ι from C to commutative rings, ideals I_c of ι(c) such that I_b is generated by the image of I_a for every morphism a → b. * `New.Variety.IdealFamily.topLocus`: the subfunctor of the one-point functor that is non-empty exactly where I_c is the unit ideal. ## Implementation notes `exists_move_kernel_of_eq_imp_eq` is preceded by `seal TorsionCoeff.mulClass Abelian.Ext Abelian.Ext.instAddCommGroup in`. Sealing the product `mulClass`, the Ext groups and their group structure makes unification compare them by their arguments instead of unfolding them into the derived category, which is slow. ## Relation to the literature Known; see `Lib.PadicComparison.Duality.GoodPairs` for sources. -/ @[expose] public section noncomputable section namespace New.Variety /-! ## Moving a kernel class between points of (ℙ¹)^d `New.Variety.TotalH` N F is the total Ext group and `New.Variety.TotalH.comp` the Yoneda product. `New.Variety.relFreeAb` U is ℤ[V]/ℤ[U] for U ⊆ V. `New.Variety.TorsionCoeff.etaAt` b is the product with the class η = `New.Variety.etaClass` pulled back along b, as a class in Ext²(F, F). -/ section MovingKernel open CategoryTheory Fin TotalH variable {C : Type 1} [Category C] {ℓ : ℕ} {A : Type} [CommRing A] [InvertsPrime A ℓ] {g : C ⥤ TestOver A} {d : ℕ} /-- For a section q of (P¹)^ι along g and i in ι, its i-th component, a section of P¹ along g. -/ def projLinePow.component {ι : Type} (q : (ringOf g ⋙ projLinePow ι).sections) (i : ι) : (projLineAlong g).sections := ⟨fun c ↦ q.val c i, fun f ↦ congrFun (q.property f) i⟩ section AtSection variable (Θ : Theory g) namespace IdealFamily variable {X : TestOver A ⥤ Type 1} (I : IdealFamily (ringOf (elementsProj X ⋙ 𝟭 (TestOver A)))) (q : (g ⋙ X).sections) /-- For a compatible family I of ideals on the elements of X, the subfunctor of X of points x in X(c) at which I is the unit ideal. -/ def topPoints : Subfunctor X where obj c := {x : X.obj c | I.ideal (X.elementsMk c x) = ⊤} map f _ := I.topLocus.map ⟨f, rfl⟩ (a := ⟨⟩) /-- The morphism ℤ[pt]/ℤ[O] → (ℤ[X]/ℤ[U])∘g induced by the section q, where U ⊆ X and O ⊆ pt are the loci where I and its pull-back along q are the unit ideal. -/ def atSection : relFreeAb (I.whisker (sectionLift g q)).topLocus ⟶ g ⋙ relFreeAb I.topPoints := relFreeAb.map (U := I.topPoints.whisker g) (sectionMap q) le_rfl /-- The reduction modulo ℓ of `New.Variety.IdealFamily.atSection`: the morphism (ℤ[pt]/ℤ[O])/ℓ → ((ℤ[X]/ℤ[U])∘g)/ℓ induced by the section q, where U ⊆ X and O ⊆ pt are the loci where I and its pull-back along q are the unit ideal. -/ def atSectionMod : abCoker (ℓ • 𝟙 (relFreeAb (I.whisker (sectionLift g q)).topLocus)) ⟶ abCoker (ℓ • 𝟙 (g ⋙ relFreeAb I.topPoints)) := abCoker.desc (I.atSection q ≫ abCoker.π (ℓ • 𝟙 (g ⋙ relFreeAb I.topPoints))) (by simpa using I.atSection q ≫= shortExact_nsmul_abCoker.1) /-- The isomorphism of total Ext groups into Θ given by pull-back along `New.Variety.IdealFamily.constToZeros` (constants mod ℓ to functions on the zeros of I), restricted along the section q. -/ def zerosEquiv : TotalH (sectionLift g q ⋙ zerosCoeff (locConstAlong (elementsProj X ⋙ 𝟭 (TestOver A))) I) Θ.functor ≃+ TotalH (sectionLift g q ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topLocus))) Θ.functor := AddEquiv.ofBijective (pullbackAlong ((sectionLift g q).whiskerLeft I.constToZeros)) (I.isCohomEquiv_constToZeros (sectionLift g q) (Theory.onElements Theory.locallyConstant) rfl Θ.zariski_descent).bijective_pullbackAlong /-- From classes on (ℤ[X]/ℤ[`New.Variety.IdealFamily.topPoints`])/ℓ along g to classes on the locally constant ℤ/ℓ-valued functions modulo those dying where I = 0 (`New.Variety.IdealFamily.zerosCoeff`), taken along q: pull back along q, then invert `New.Variety.IdealFamily.zerosEquiv`. -/ def extendToZeros : TotalH (abCoker (ℓ • 𝟙 (g ⋙ relFreeAb I.topPoints))) Θ.functor →+ TotalH (sectionLift g q ⋙ zerosCoeff (locConstAlong (elementsProj X ⋙ 𝟭 (TestOver A))) I) Θ.functor := (I.zerosEquiv Θ q).symm.toAddMonoidHom.comp (pullbackAlong (I.atSectionMod q)) /-- The defining property of `I.extendToZeros Θ q x`: its image under `I.zerosEquiv Θ q` is the pull-back of `x` along the section `q`. -/ lemma zerosEquiv_extendToZeros (x : TotalH (abCoker (ℓ • 𝟙 (g ⋙ relFreeAb I.topPoints))) Θ.functor) : I.zerosEquiv Θ q (I.extendToZeros Θ q x) = pullbackAlong (I.atSectionMod q) x := (I.zerosEquiv Θ q).apply_symm_apply _ /-- Let `I` be a family of ideals on the points of a functor `X` on tests, `q` a section of `X` along `g`, `Θ` a theory along `g`, `φ : C' ⥤ C` a functor, `K` a theory along `φ ⋙ g`, and `b` a class in the total Ext group from `φ ⋙ Θ.functor` to `K.functor`. Write `R` for the map `y ↦ (y restricted along φ) · b` from classes with coefficients in `Θ.functor` to classes with coefficients in `K.functor`. Then `R` commutes with `extendToZeros`: for a class `x` on `(ℤ[X]/ℤ[I.topPoints])/ℓ` along `g`, the image under `R` of the extension of `x` for `Θ` and `q` is the extension of `R x` for `K` and the restriction of `q` along `φ`. -/ lemma extendToZeros_naturality {C' : Type 1} [Category C'] (φ : C' ⥤ C) (K : Theory (φ ⋙ g)) (b : TotalH (φ ⋙ Θ.functor) K.functor) (x : TotalH (g ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) Θ.functor) : mapThenComp (restrictAlong φ) b (I.extendToZeros Θ q x) = I.extendToZeros K (φ.sectionsPrecomp q) (mapThenComp (restrictAlong φ) b x) := by -- Apply `zerosEquiv` to both sides: each becomes `R` of the pull-back of `x` along `q`, since -- `R` commutes with pull-backs and `zerosEquiv` is one. let q' : ((φ ⋙ g) ⋙ X).sections := φ.sectionsPrecomp q let R {N : AbFunctor C} : TotalH N Θ.functor →+ TotalH (φ ⋙ N) K.functor := mapThenComp (restrictAlong φ) b have R_pullback {N N' : AbFunctor C} (f : N ⟶ N') (y : TotalH N' Θ.functor) : R (pullbackAlong f y) = pullbackAlong (φ.whiskerLeft f) (R y) := mapThenComp_comp map_homClass -- (The next facts keep the types they are born with; `apply` then compares them with the goal -- once. Restating them first would repeat each of the costly definitional checks.) have R_zerosEquiv := R_pullback ((sectionLift g q).whiskerLeft I.constToZeros) (I.extendToZeros Θ q x) have R_atSectionMod := R_pullback (I.atSectionMod q) x -- `zerosEquiv K q'` of the left side is `R` of the pull-back of `x` along `q`, restricted have h_left := R_zerosEquiv.symm.trans ((congrArg R (I.zerosEquiv_extendToZeros Θ q x)).trans R_atSectionMod) -- and so is `zerosEquiv K q'` of the right side (`(R x :)`: elaborate `R x` on its own) have h_right := I.zerosEquiv_extendToZeros K q' (R x :) apply (I.zerosEquiv K q').injective apply h_left.trans apply h_right.symm end IdealFamily end AtSection namespace IdealFamily variable {X : TestOver A ⥤ Type 1} (I : IdealFamily (ringOf (elementsProj X ⋙ 𝟭 (TestOver A)))) /-- Let every maximal ideal `m` of a ring `g(c)` be the kernel of `g(f)` for some `f : c ⟶ c'` (`h_max`), and let the families `L` and `L'` of ideals agree at every object where the family `J` is zero. Then, inside the locus where `L'` is the unit ideal, the locus where `L` or `J` is the unit ideal is locally everything. -/ lemma isZariskiLocallyTop_preimage_topLocus_inf_sup (h_max : ∀ (c : C) (m : Ideal ((ringOf g).obj c)), m.IsMaximal → ∃ (c' : C) (f : c ⟶ c'), RingHom.ker ((ringOf g).map f).hom = m) {L L' J : IdealFamily (ringOf g)} (h_eq : ∀ c : C, J.ideal c = ⊥ → L.ideal c = L'.ideal c) : IsZariskiLocallyTop (ringOf g) ((L'.topLocus ⊓ (L.topLocus ⊔ J.topLocus)).preimage L'.topLocus.ι) := by intro c y m hm obtain ⟨c', f, hf⟩ : ∃ (c' : C) (f : c ⟶ c'), RingHom.ker ((ringOf g).map f).hom = m := h_max c m hm -- a family is zero at `c'` exactly when its ideal at `c` lies in `m` have bot_iff (T : IdealFamily (ringOf g)) : T.ideal c' = ⊥ ↔ T.ideal c ≤ m := by rw [← T.map_eq f, ← hf, Ideal.map_eq_bot_iff_le_ker] have hL'_top : L'.ideal c = ⊤ := y.property -- if `L` and `J` both lay in `m`, then at `c'` the family `L'` would agree with `L` and be zero have h_not : ¬L.ideal c ≤ m ∨ ¬J.ideal c ≤ m := by refine not_and_or.1 fun ⟨hL_le, hJ_le⟩ ↦ hm.ne_top ?_ have hL_eq : L.ideal c' = L'.ideal c' := h_eq c' ((bot_iff J).2 hJ_le) have hL'_bot : L'.ideal c' = ⊥ := by rw [← hL_eq] exact (bot_iff L).2 hL_le exact eq_top_mono ((bot_iff L').1 hL'_bot) hL'_top rcases h_not with hL | hJ · obtain ⟨a, ha, h_top⟩ := L.exists_notMem_eq_top hL exact ⟨a, ha, fun B f hf ↦ ⟨Subtype.prop _, .inl (h_top B f hf)⟩⟩ · obtain ⟨a, ha, h_top⟩ := J.exists_notMem_eq_top hJ exact ⟨a, ha, fun B f hf ↦ ⟨Subtype.prop _, .inr (h_top B f hf)⟩⟩ seal TorsionCoeff.mulClass Abelian.Ext Abelian.Ext.instAddCommGroup in /-- The one-coordinate case of `exists_move_kernel`. Let `K` be an `ℓ`-torsion coefficient along `g`, and let the sections `s` and `s'` of `X` agree wherever the sections `x` and `x'` of `ℙ¹` do. Let `h_max` say that each maximal ideal of a ring `g(c)` is the kernel of some `g(f)`. Then for every total Ext class `δ` into `K` from ℤ[pt]/ℤ[O], with O the locus where the pull-back of `I` along `s` is the unit ideal, there is a class `δ'` of the same kind for `s'` with the following property. For every `φ : C' ⥤ C`, theory `Θ` along `φ ⋙ g` (a coefficient that behaves well on closed loci), class `T` from `K` restricted along `φ` to `Θ`, and class `v` from `ℤ[X]/ℤ[I.topPoints]` along `φ ⋙ g` to `Θ`: if the Yoneda product `δ · T` (of `δ` restricted along `φ` with `T`) is the pull-back of `v` along `I.atSection s`, then `δ' · T` is that of `v · (η(x) + η(x'))` along `I.atSection s'`. -/ lemma exists_move_kernel_of_eq_imp_eq (K : TorsionCoeff g) (h_max : ∀ (c : C) (m : Ideal ((ringOf g).obj c)), m.IsMaximal → ∃ (c' : C) (f : c ⟶ c'), RingHom.ker ((ringOf g).map f).hom = m) (x x' : (projLineAlong g).sections) (s s' : (g ⋙ X).sections) (h_agree : ∀ c : C, x.val c = x'.val c → s.val c = s'.val c) (δ : TotalH (relFreeAb (I.whisker (sectionLift g s)).topLocus) K.functor) : ∃ δ' : TotalH (relFreeAb (I.whisker (sectionLift g s')).topLocus) K.functor, ∀ (C' : Type 1) [Category C'] (φ : C' ⥤ C) (Θ : Theory (φ ⋙ g)) (T : TotalH ((restrictAlong φ).obj K.functor) Θ.functor) (v : TotalH (φ ⋙ g ⋙ relFreeAb I.topPoints) Θ.functor), mapThenComp (restrictAlong φ) T δ = pullbackAlong (φ.whiskerLeft (I.atSection s)) v → mapThenComp (restrictAlong φ) T δ' = pullbackAlong (φ.whiskerLeft (I.atSection s')) (comp.flip (Θ.etaAt (φ.whiskerLeft (freeAbSectionMap x + freeAbSectionMap x'))).toTotalH v) := by -- The product with a class ξ supported where `x = x'` moves δ from `s` to `s'`. Take ideals `J` -- with `x = x'` where `J` is zero (`hJ`), and a class `ξ` relative to `J.topLocus` that gives -- η(x) + η(x') when its support is forgotten (`hξ`). obtain ⟨J, hJ, ξ, hξ⟩ := exists_etaClass_supported_diagonal x x' -- `L r` is the family `I` at the section `r` of `X` let L (r : (g ⋙ X).sections) : IdealFamily (ringOf g) := I.whisker (sectionLift g r) -- the sections `s` and `s'` agree where `J` is zero, and so do `L s` and `L s'` have hs_eq (c : C) (hc : J.ideal c = ⊥) : s.val c = s'.val c := h_agree c (hJ c hc) have h_L_eq (c : C) (hc : J.ideal c = ⊥) : (L s).ideal c = (L s').ideal c := by change I.ideal (X.elementsMk (g.obj c) (s.val c)) = I.ideal (X.elementsMk (g.obj c) (s'.val c)) rw [hs_eq c hc] -- Where `L s'` is the unit ideal, locally `L s` or `J` is the unit ideal too. have h_loc : IsZariskiLocallyTop (ringOf g) (((L s').topLocus ⊓ ((L s).topLocus ⊔ J.topLocus)).preimage (L s').topLocus.ι) := isZariskiLocallyTop_preimage_topLocus_inf_sup h_max h_L_eq -- By Zariski descent, classes relative to `(L s').topLocus ⊓ ((L s).topLocus ⊔ J.topLocus)` -- come from classes relative to `(L s').topLocus`. Let δ' be the class that restricts to the -- product of δ and ξ, pulled back along the diagonal: a point where `L s'` is the unit ideal, -- and `L s` or `J` is, lies in `((L s).topLocus ⊓ (L s').topLocus) × pt` or in `pt × J.topLocus`. -- (inline: as a separate `have`, the diagonal map no longer matches the `simp only` below) obtain ⟨δ', hδ'⟩ := (relFreeAb.isCohomEquiv_of_le inf_le_left (K.zariski_descent h_loc)).bijective_pullbackAlong.surjective (pullbackAlong (relFreeAb.map {app _ := ↾Function.diag} (by rintro c y ⟨hy_L', hy_L | hy_J⟩ · exact .inl ⟨hy_L, hy_L'⟩ · exact .inr hy_J) ≫ relFreeAb.prod _ J.topLocus) (K.mulClass ξ.toTotalH (pullbackAlong (relFreeAb.map (𝟙 _) (inf_le_left (b := (L s').topLocus))) δ))) refine ⟨δ', fun C' _ φ Θ T v hv ↦ ?_⟩ -- The same restriction is injective for Θ, so the claim may be checked after it. apply (relFreeAb.isCohomEquiv_of_le (U := (L s').topLocus.whisker φ) (U' := .whisker (_ ⊓ _) φ) (fun c y hy ↦ hy.1) (Θ.zariski_descent (h_loc.whisker φ))).bijective_pullbackAlong.injective -- Restrict the defining equations of δ' and ξ along φ. (`↓`: `map_restrictAlong_etaClass` -- must rewrite η before `map_of` unfolds it.) replace hδ' := congrArg (mapThenComp (restrictAlong φ) T) hδ' replace hξ := congrArg (TotalH.map (restrictAlong φ)) hξ simp only [map_pullbackAlong, map_of, mapThenComp_comp map_homClass, ↓map_restrictAlong_etaClass, K.mulClass_naturality] at hδ' hξ ⊢ -- After `hδ'` and `hv`: in the product with ξ the section s may be replaced by s' -- (`mulClass_congr_of_eq_on_zeros`), and the product with ξ, its support forgotten, is the -- operator of η(x) + η(x') (`mulClass_eq_comp_etaAt`). -- (erw: the restricted functors agree with the rewritten ones only up to definitional equality) erw [hδ', hv, pullbackAlong_pullbackAlong, Θ.mulClass_congr_of_eq_on_zeros (J.whisker φ) _ (a' := φ.whiskerLeft (relFreeAb.map (𝟙 _) inf_le_right ≫ I.atSection _)), ← Θ.mulClass_eq_comp_etaAt _ (relFreeAb.π _), pullbackAlong_pullbackAlong, pullbackAlong_pullbackAlong, pullbackAlong_pullbackAlong] · -- Both sides are pulled back along maps that agree on generators. (`congr(…)`: `congrArg` -- elaborates the equation of maps without its expected type, and fails.) exact congr(pullbackAlong $(relFreeAb.hom_ext fun _ _ ↦ .refl (relFreeAb.mk I.topPoints _ ⊗ₜ _)) _) · exact hξ · -- the two points agree where J is zero intro c hc exact AddCommGrpCat.ext <| relFreeAb.mem_of_mk_mem (A := φ.obj c) (AddMonoidHom.eqLocus _ _) fun _ ↦ congrArg (relFreeAb.mk _) (hs_eq _ hc) /-- Let `K` be a torsion coefficient along `g`. Suppose every maximal ideal of each ring `g c` is the kernel of the ring map along some `c ⟶ c'` (`h_max`). Let `t` send `d` sections of `ℙ¹` to a section of `g ⋙ X`, pointwise (`t_congr`). Let `δ` be a class in the total Ext group from `ℤ[pt]/ℤ[O_q]` to `K.functor`, where `O_q` is where the pull-back of `I` along `t q` is the unit ideal. Then some `δ'` (for `q'`) satisfies the following. Take any `φ : C' ⥤ C`, theory `Θ` along `φ ⋙ g`, class `T` from `K.functor` restricted along `φ` to `Θ.functor`, and class `w` from `ℤ[X]/ℤ[I.topPoints]` along `φ ⋙ g` to `Θ.functor`. If `δ · T` is the pull-back of `w` along `t q`, then `δ' · T` is the pull-back along `t q'` of `w` followed by the products with `η` at `q_j + q'_j` for all `j`. -/ lemma exists_move_kernel (K : TorsionCoeff g) (h_max : ∀ (c : C) (m : Ideal ((ringOf g).obj c)), m.IsMaximal → ∃ (c' : C) (f : c ⟶ c'), RingHom.ker ((ringOf g).map f).hom = m) (t : (Fin d → (projLineAlong g).sections) → (g ⋙ X).sections) (t_congr : ∀ {r r' : Fin d → (projLineAlong g).sections} (c : C), (∀ j : Fin d, (r j).val c = (r' j).val c) → (t r).val c = (t r').val c) : ∀ (q q' : Fin d → (projLineAlong g).sections) (δ : TotalH (relFreeAb (I.whisker (sectionLift g (t q))).topLocus) K.functor), ∃ δ' : TotalH (relFreeAb (I.whisker (sectionLift g (t q'))).topLocus) K.functor, ∀ (C' : Type 1) [Category C'] (φ : C' ⥤ C) (Θ : Theory (φ ⋙ g)) (T : TotalH ((restrictAlong φ).obj K.functor) Θ.functor) (w : TotalH (φ ⋙ g ⋙ relFreeAb I.topPoints) Θ.functor), mapThenComp (restrictAlong φ) T δ = pullbackAlong (φ.whiskerLeft (I.atSection (t q))) w → mapThenComp (restrictAlong φ) T δ' = pullbackAlong (φ.whiskerLeft (I.atSection (t q'))) (foldr d (fun (j : Fin d) ↦ comp.flip (Θ.etaAt (φ.whiskerLeft (freeAbSectionMap (q j) + freeAbSectionMap (q' j)))).toTotalH) w) := by -- Induction on `d`: move the last `d` coordinates, then the first one. induction d with | zero => -- with no coordinates the families `q` and `q'` are empty, so `t q = t q'`, and the product -- over `j` is empty: take `δ' = δ` simp only [forall_fin_zero_pi] intro δ exact ⟨δ, fun C' _ φ Θ T w hw ↦ hw⟩ | succ d ih => simp only [forall_fin_succ_pi] intro x q x' q' δ₀ have t_congr_tail : ∀ {r r' : Fin d → (projLineAlong g).sections} (c : C), (∀ j : Fin d, (r j).val c = (r' j).val c) → (t (cons x r)).val c = (t (cons x r')).val c := fun c hr ↦ t_congr c (cases rfl hr) -- the induction hypothesis moves the last `d` coordinates, with first coordinate `x` obtain ⟨δ, hδ⟩ := ih (fun r ↦ t (cons x r)) t_congr_tail q q' δ₀ -- the sections `t (x, q')` and `t (x', q')` agree wherever `x` and `x'` do have h_agree (c : C) (hc : x.val c = x'.val c) : (t (cons x q')).val c = (t (cons x' q')).val c := t_congr c (cases hc fun _ ↦ rfl) -- the first coordinate is moved from `x` to `x'` by the one-coordinate case obtain ⟨δ', hδ'⟩ := I.exists_move_kernel_of_eq_imp_eq K h_max x x' (t (cons x q')) (t (cons x' q')) h_agree δ refine ⟨δ', fun C' _ φ Θ T w hw ↦ ?_⟩ rw [foldr_succ] exact hδ' C' φ Θ T _ (hδ C' φ Θ T w hw) end IdealFamily end MovingKernel /-! ## Integration over the line and compared cohomology theories `New.Variety.lerayHirsch θ` is the map `w ↦ ∑ Φ (w i) · θ i` for an exact functor `Φ`, here a restriction, where x · y = `New.Variety.TotalH.comp x y` is the Yoneda product (x followed by y). -/ section IntegrationOverLine open CategoryTheory Fin TotalH Functor.Elements Finsupp open Function hiding comp comp_id id_comp variable {C : Type 1} {C' D : Type _} [Category C] [Category C'] [Category D] {ℓ : ℕ} {A : Type} [CommRing A] [InvertsPrime A ℓ] {g : C ⥤ TestOver A} {M : TorsionCoeff g} {S F : AbFunctor C} (φ : C' ⥤ C) (ψ : D ⥤ C') (x : TotalH S F) /-! ### Integration over the projective line -/ lemma map_restrictAlong_restrictAlong : TotalH.map (restrictAlong ψ) (TotalH.map (restrictAlong φ) x) = TotalH.map (restrictAlong (ψ ⋙ φ)) x := TotalH.map_map (restrictAlong φ) (restrictAlong ψ) x /-- Restriction to the points of `X` passes through a product of classes `M.etaAt (b j)` factor by factor. -/ lemma map_foldr_etaAt {X : C ⥤ Type 1} {J : Type*} (b : J → (freeAb (onePointFunctor C) ⟶ freeAb (projLineAlong g))) (l : List J) (y : TotalH S M.functor) : TotalH.map (restrictAlong (elementsProj X)) (l.foldr (fun j : J ↦ comp.flip (M.etaAt (b j)).toTotalH) y) = l.foldr (fun j : J ↦ comp.flip (M.onElements.etaAt ((elementsProj X).whiskerLeft (b j))).toTotalH) (TotalH.map (restrictAlong (elementsProj X)) y) := by induction l with | nil => rfl | cons j l ih => exact (map_comp _).trans congr(comp $ih $(M.map_etaAt_onElements X (b j))) variable (h : M.HasLineFormula) {φ} {M' : TorsionCoeff (φ ⋙ g)} (β : φ ⋙ M.functor ⟶ M'.functor) /-- Restriction along `φ` followed by the product with a class `T` from `M.functor` restricted along `φ` to `M'.functor` commutes with the two maps `x ↦ x · 1` and `x ↦ x · η` to the cohomology over the points of the line. -/ lemma lineBasis_naturality (T : TotalH ((restrictAlong φ).obj M.functor) M'.functor) (i : Bool) (x : TotalH S M.functor) : mapThenComp (restrictAlong (elementsProj (projLineAlong (φ ⋙ g)))) (M'.lineBasis i).toTotalH (mapThenComp (restrictAlong φ) T x) = mapThenComp (F := elementsProj (projLineAlong g) ⋙ M.functor) (restrictAlong (precomp φ (projLineAlong g))) (TotalH.map (restrictAlong (elementsProj (φ ⋙ projLineAlong g))) T) (mapThenComp (restrictAlong (elementsProj (projLineAlong g))) (M.lineBasis i).toTotalH x) := by -- Both sides are products of three factors, and the two restrictions of `x` agree; it remains -- to commute the restriction of `T` with the member of the family. let π := elementsProj (projLineAlong g) let π' := elementsProj (projLineAlong (φ ⋙ g)) let ψ := precomp φ (projLineAlong g) change comp (map (restrictAlong π') (comp (map (restrictAlong φ) x) T)) (M'.lineBasis i).toTotalH = comp (map (restrictAlong ψ) (comp (map (restrictAlong π) x) (M.lineBasis i).toTotalH)) (map (restrictAlong π') T) rw [map_comp_assoc, map_comp_assoc, map_restrictAlong_restrictAlong, map_restrictAlong_restrictAlong] cases i · -- `T` commutes with the class η by naturality of `TorsionCoeff.etaAt`. rw [TorsionCoeff.lineBasis_false, TorsionCoeff.lineBasis_false] refine congrArg (comp (map (restrictAlong (elementsProj (projLineAlong (φ ⋙ g)) ⋙ φ)) x)) ?_ exact (M.onElements.etaAt_naturality (precomp φ (projLineAlong g)) M'.onElements (map (restrictAlong (elementsProj (projLineAlong (φ ⋙ g)))) T) (freeAb.map (tautologicalSection (X := projLineAlong g)))).symm · -- the class `1` is the identity, so the products with it drop out have h_id : (M.lineBasis true).toTotalH = homClass (𝟙 (elementsProj (projLineAlong g) ⋙ M.functor)) := rfl have h_id' : (M'.lineBasis true).toTotalH = homClass (𝟙 (elementsProj (projLineAlong (φ ⋙ g)) ⋙ M'.functor)) := rfl rw [h_id, h_id', map_homClass] have h_map := (restrictAlong (precomp φ (projLineAlong g))).map_id (elementsProj (projLineAlong g) ⋙ M.functor) rw [h_map] exact (congrArg (comp (map (restrictAlong (elementsProj (projLineAlong (φ ⋙ g)) ⋙ φ)) x)) comp_id).trans (congrArg (comp (map (restrictAlong (precomp φ (projLineAlong g) ⋙ elementsProj (projLineAlong g))) x)) pullbackAlong_id).symm namespace TorsionCoeff.HasLineFormula /-- If the comparison `(φ, β)` has universal points along `u : Y' ⟶ φ ⋙ Y`, the projective line formula holds for `M` at `ℤ[Y]` (each class from ℤ[Y] over the points of ℙ¹ is a·1 + b·η for unique a, b from the base) if and only if it holds for `M'` at `ℤ[Y']`. -/ lemma bijective_iff_of_hasUniversalPoints {Y : C ⥤ Type 1} {Y' : C' ⥤ Type 1} {u : Y' ⟶ φ ⋙ Y} (hu : (Comparison.of φ β).HasUniversalPoints u) : IsLerayHirschBasis M.lineBasis (freeAb Y) ↔ IsLerayHirschBasis M'.lineBasis (freeAb Y') := by -- The two maps `lerayHirsch` form a commutative square with the comparison maps from `C` to `C'`, -- on the base (one for each member of the family) and on the points of the line; these are -- bijective by `hu`. refine Comparison.bijective_iff_of_comm_sq (lerayHirsch_naturality _ (.comp ..) (r' := .comp ..) fun i x ↦ ?_) (mapRange_bijective _ _ hu.isBijective.bijective_totalH) hu.on_elements.isBijective.bijective_totalH -- The square commutes on each member of the family by `lineBasis_naturality`. refine (mapThenComp_comp map_homClass).trans (congrArg _ ((lineBasis_naturality (homClass β) i x).trans ?_)) rw [map_homClass] rfl /-- The projective line formula passes to categories of elements: if it holds for `M`, it holds for the restriction of `M` to the category of elements of any set-valued functor `X` on `C`. -/ protected lemma onElements (h : M.HasLineFormula) {X : C ⥤ Type 1} : (M.onElements (X := X)).HasLineFormula := by -- It suffices to treat the functors represented by points `c` of `X`; maps out of `c` are maps -- out of the object under it, so this case is an instance of `h`. exact isLerayHirschBasis_of_reprBy fun c ↦ (bijective_iff_of_hasUniversalPoints _ (hasUniversalPoints_reprBy_elements c)).mp (h _) /-- Integration over the projective line: given the projective line formula for M, the map sending a class a + ηb over the points of P¹ to b. -/ def integrate : TotalH (elementsProj (projLineAlong g) ⋙ S) (elementsProj (projLineAlong g) ⋙ M.functor) →+ TotalH S M.functor := (applyAddHom false).comp (LinearEquiv.ofBijective (lerayHirsch M.lineBasis S) (h S)).symm.toAddMonoidHom /-- If additive maps `f` on the base and `f'` over the points of the line are compatible with the products with `1` and with `η`, they are compatible with integration over the line. -/ lemma integrate_naturality (hM' : M'.HasLineFormula) {T : AbFunctor C'} {f : TotalH S M.functor →+ TotalH T M'.functor} {f' : TotalH ((restrictAlong (elementsProj (projLineAlong g))).obj S) (elementsProj (projLineAlong g) ⋙ M.functor) →+ TotalH ((restrictAlong (elementsProj (projLineAlong (φ ⋙ g)))).obj T) (elementsProj (projLineAlong (φ ⋙ g)) ⋙ M'.functor)} (h_fam : ∀ w : Bool →₀ TotalH S M.functor, lerayHirsch M'.lineBasis T (w.mapRange f f.map_zero) = f' (lerayHirsch M.lineBasis S w)) : ∀ x : TotalH (elementsProj (projLineAlong g) ⋙ S) (elementsProj (projLineAlong g) ⋙ M.functor), f (h.integrate x) = hM'.integrate (f' x) := by -- Every class is `lerayHirsch M.lineBasis S w` for a pair `w`, since `h S` is onto. have h_surj : Surjective (lerayHirsch M.lineBasis S) := Bijective.surjective (h S) refine h_surj.forall.mpr fun w ↦ ?_ -- `f'` acts on such a class by applying `f` to both entries of `w`, and on either side -- `integrate` reads off the coefficient of η. rw [← h_fam w] simp [integrate] /-- The integral over the line of `y · (η + ξ)`, with η here the class `M.cupClass` placed in degree 2 (η in `M.lineBasis`), is `y`, for `y` and `ξ` pulled back from the base. -/ lemma integrate_mul_cupClass (y : TotalH S M.functor) (ξ : TotalH M.functor M.functor) : h.integrate (S := S) (comp (TotalH.map (restrictAlong (elementsProj (projLineAlong g))) y) -- (`by exact`: elaborates `.of` only once the type of the sum is known. Elaborated -- eagerly, its type is still unknown and Lean builds the hint of an error message -- that is then discarded.) ((by exact .of _ 2 M.cupClass) + TotalH.map (restrictAlong (elementsProj (projLineAlong g))) ξ) :) = y := by let Φ : AbFunctor C ⥤ AbFunctor (projLineAlong g).Elements := restrictAlong (elementsProj (projLineAlong g)) have h_eta : lerayHirsch M.lineBasis S (.single false y) = comp (TotalH.map Φ y) (.of _ 2 M.cupClass) := lerayHirsch_single M.lineBasis false y have h_one : lerayHirsch M.lineBasis S (.single true (comp y ξ)) = comp (TotalH.map Φ y) (TotalH.map Φ ξ) := ((lerayHirsch_single M.lineBasis true (comp y ξ)).trans comp_id).trans (map_comp ..) have h_product := (map_add (comp (TotalH.map Φ y)) _ _).trans (congrArg₂ (· + ·) h_eta.symm h_one.symm) refine (congrArg (h.integrate (S := S)) h_product).trans ?_ refine (congrArg (h.integrate (S := S)) (map_add (lerayHirsch M.lineBasis S) (single false y) (single true (comp y ξ))).symm).trans ?_ simp [integrate] end TorsionCoeff.HasLineFormula end IntegrationOverLine section ComparedTheories open CategoryTheory Fin TotalH Functor.Elements Finsupp open Function hiding comp comp_id id_comp variable {C : Type 1} [Category C] {ℓ : ℕ} {A : Type} [CommRing A] [InvertsPrime A ℓ] {g : C ⥤ TestOver A} {N N' : AbFunctor (TestOver A)} {d : ℕ} {ι : Type*} [Fintype ι] /-! ### Compared theories and natural operations -/ /-- A theory along g with morphisms b i (the field `comparison`, indexed by `Index`) to its coefficient F (the field `functor`) from the locally constant ℤ/ℓ-valued functions, such that it and `New.Variety.Theory.locallyConstant` satisfy the projective line formula. -/ structure ComparedTheory (g : C ⥤ TestOver A) extends Theory g where /-- The index set of the comparison morphisms. -/ Index : Type /-- The morphisms from the locally constant `ℤ/ℓ`-valued functions along `g` to `functor`. -/ comparison : Index → H (restrictAlong g Theory.locallyConstant.functor) functor 0 /-- The coefficient `functor` satisfies the projective line formula. -/ line_formula : toTorsionCoeff.HasLineFormula /-- The theory of locally constant functions satisfies the projective line formula. -/ line_formula_const : (Theory.locallyConstant (A := A)).HasLineFormula variable (A) in /-- A functor g (the field `toTestOver`) from a category C (the field `Base`) to tests over A, a theory Θ (the field `theory`) along g satisfying the projective line formula, and d compatible points of P¹ over the rings g(c). -/ structure LineStage (d : ℕ) where /-- The category on which the stage lives. -/ {Base : Type 1} /-- The category structure on `Base`. -/ [category : Category Base] /-- The functor from `Base` to tests over `A`. -/ {toTestOver : Base ⥤ TestOver A} /-- A theory along `toTestOver`. -/ theory : Theory toTestOver /-- The theory satisfies the projective line formula. -/ line_formula : theory.HasLineFormula /-- A compatible family of points of `(ℙ¹)^d` over the rings of the tests `toTestOver.obj c`. -/ points : (ringOf toTestOver ⋙ projLinePow (Fin d)).sections attribute [instance] LineStage.category /-- Operations with d parameters: additive maps from total Ext(N∘g, Θ) to total Ext(N'∘g, Θ), for every g, theory Θ with the projective line formula and section of (P¹)^d, commuting with comparisons along functors. -/ structure NaturalOp (d : ℕ) (N N' : AbFunctor (TestOver A)) where /-- For a stage `t`, with theory `Θ = t.theory` along `g = t.toTestOver`, the projective line formula and the section `t.points` of `(ℙ¹)^d`, an additive map from the total cohomology of `g ⋙ N` to that of `g ⋙ N'`, coefficients in `Θ.functor`. -/ app (t : LineStage A d) : TotalH (t.toTestOver ⋙ N) t.theory.functor →+ TotalH (t.toTestOver ⋙ N') t.theory.functor /-- The maps `app` commute with restriction along a functor `φ`, followed by the product with a class `b` from `φ ⋙ t.theory.functor` to `Θ.functor`. -/ naturality : ∀ {C : Type 1} [Category C] (t : LineStage A d) (φ : C ⥤ t.Base) (Θ : Theory (φ ⋙ t.toTestOver)) (l : Θ.HasLineFormula) (b : TotalH (φ ⋙ t.theory.functor) Θ.functor) (x : TotalH (t.toTestOver ⋙ N) t.theory.functor), mapThenComp (restrictAlong φ) b (app t x) = app ⟨Θ, l, φ.sectionsPrecomp t.points⟩ (mapThenComp (restrictAlong φ) b x) /-- The restriction of t to the category of pairs (c, x) with x ∈ P¹(t.toTestOver(c)), with the tautological point x placed before the d points of t. -/ def LineStage.consTautologicalPoint (t : LineStage A d) : LineStage A (d + 1) where theory := t.theory.onElements (X := projLineAlong t.toTestOver) line_formula := t.line_formula.onElements points := ⟨fun x ↦ Fin.cons x.2 (t.points.1 ((elementsProj (projLineAlong t.toTestOver)).obj x)), fun f ↦ funext (cases f.map_val (congrFun (t.points.property ((elementsProj (projLineAlong t.toTestOver)).map f))))⟩ /-- Integrating out the first parameter of r: pull back to the points of P¹, apply r with the tautological point as first parameter, and integrate over the line. -/ def NaturalOp.integrate (r : NaturalOp (d + 1) N N') : NaturalOp d N N' where app t := t.line_formula.integrate.comp ((r.app t.consTautologicalPoint).comp (TotalH.map (restrictAlong (elementsProj (projLineAlong t.toTestOver))))) naturality t φ K l b x := by -- Integration, `r` and restriction to the line each commute with maps of theories. refine (t.line_formula.integrate_naturality _ (lerayHirsch_naturality _ _ (lineBasis_naturality b)) _).trans (congrArg _ ?_) refine (r.naturality t.consTautologicalPoint (precomp ..) K.onElements ..).trans (congrArg _ ?_) -- This is `lineBasis_naturality` for the class `1`, which is the identity. exact (congrArg _ comp_id).symm.trans ((lineBasis_naturality b true x).symm.trans comp_id) /-- If `K → I → P` is exact at `I`, with `f` any map and `g` additive, and `K` and `P` are finite, then `I` is finite. -/ lemma finite_of_exact {K I P : Type*} [AddGroup I] [AddGroup P] {f : K → I} {g : I →+ P} (h : Exact f g) [Finite K] [Finite P] : Finite I := by -- The kernel of `g` lies in the finite image of `f`, and its range lies in `P`. refine g.finite_iff_finite_ker_range.mpr ⟨?_, inferInstance⟩ exact (Set.finite_range f).subset fun x hx ↦ (h x).mp hx namespace ComparedTheory variable (D : ComparedTheory g) {m : ℕ} (I : IdealFamily (ringOf (testOfPoint A (projLinePow (Fin m))))) /-! ### The comparison property and its permanence -/ /-- `D.IsFiniteLerayHirsch N`, for a functor `N` from tests over `A` to abelian groups. Write `L` for the locally constant `ℤ/ℓ`-valued functions and `F` for the coefficient of `D`. Then (1) the Leray–Hirsch map of the classes `D.comparison i`, which sends a family `(w i)` of classes in the total Ext group of `N` into `L` to `∑ i, (w i restricted along g) · D.comparison i`, is a bijection onto the total Ext group of `g ⋙ N` into `F`, and (2) the total Ext group of `N` into `L` is finite. -/ def IsFiniteLerayHirsch (N : AbFunctor (TestOver A)) : Prop := IsLerayHirschBasis D.comparison N ∧ Finite (TotalH N (locConstAlong (𝟭 (TestOver A)))) /-- `D.IsFiniteLerayHirsch` is a closed class (`IsClosedClass`): it holds for zero functors, and in a short exact sequence `0 → X₁ → X₂ → X₃ → 0` with `D.IsFiniteLerayHirsch X₁` it holds for `X₂` if and only if for `X₃`. -/ lemma isClosedClass_isFiniteLerayHirsch : IsClosedClass D.IsFiniteLerayHirsch := by classical -- The bijectivity half of `IsFiniteLerayHirsch` is `isClosedClass_isLerayHirschBasis`; it remains -- to treat finiteness. let L : AbFunctor (TestOver A) := locConstAlong (𝟭 (TestOver A)) obtain ⟨h_LH_zero, h_LH_ses⟩ : IsClosedClass fun S ↦ IsLerayHirschBasis D.comparison S := isClosedClass_isLerayHirschBasis refine ⟨fun N hN ↦ ⟨h_LH_zero N hN, ?_⟩, fun X hX hX₁ ↦ ?_⟩ · -- The cohomology of a zero functor is trivial in every degree. have h_zero : ∀ (F : AbFunctor (TestOver A)) (n : ℕ), Subsingleton (H N F n) := H.subsingleton_of_id_eq_zero hN infer_instance obtain ⟨h_bij₁, h_fin₁⟩ := hX₁ have h_bij_iff : IsLerayHirschBasis D.comparison X.X₂ ↔ IsLerayHirschBasis D.comparison X.X₃ := h_LH_ses X hX h_bij₁ -- In the exact triangle, each of the groups of `X.X₂` and `X.X₃` lies between the other one -- and that of `X.X₁`. obtain ⟨h_exact_mid, -, h_exact_quot⟩ := exact_triangle hX L have h_fin_iff : Finite (TotalH X.X₂ L) ↔ Finite (TotalH X.X₃ L) := by constructor · intro h_fin₂ exact finite_of_exact h_exact_quot · intro h_fin₃ exact finite_of_exact h_exact_mid exact h_bij_iff.and h_fin_iff /-- In a short exact sequence `0 → X₁ → X₂ → X₃ → 0` of functors on tests over `A`, if `D.IsFiniteLerayHirsch` holds for `X₂` and `X₃`, it holds for `X₁`. -/ lemma isFiniteLerayHirsch_of_shortExact {X : ShortComplex (AbFunctor (TestOver A))} (h : ShortComplex.ShortExact X) (h_good₂ : D.IsFiniteLerayHirsch X.X₂) (h_good₃ : D.IsFiniteLerayHirsch X.X₃) : D.IsFiniteLerayHirsch X.X₁ := by classical obtain ⟨h_bij₂, h_fin₂⟩ := h_good₂ obtain ⟨h_bij₃, h_fin₃⟩ := h_good₃ -- Finite: in the exact triangle, the group of `X.X₁` lies between those of `X.X₂` and `X.X₃`. obtain ⟨-, h_exact_sub, -⟩ := exact_triangle h (locConstAlong (𝟭 (TestOver A))) have h_fin₁ : Finite (TotalH X.X₁ (locConstAlong (𝟭 (TestOver A)))) := finite_of_exact h_exact_sub -- Bijective: five lemma in the rotated ladder, whose terms are those of `X.X₁` (shifted by one -- degree), `X.X₃` and `X.X₂`; it is applied degree by degree to the truncated maps. have h_trunc₁ : ∀ n : ℕ, Bijective (truncMap (degreeTrunc_comp_lerayHirsch D.comparison X.X₁ n)) := fun n ↦ ((lerayHirsch.longExact_hom h).rotate.five_lemma (isLerayHirschBasis_iff_allBijective_truncMap.mp h_bij₂)).mp (isLerayHirschBasis_iff_allBijective_truncMap.mp h_bij₃) (n + 1) exact ⟨isLerayHirschBasis_iff_allBijective_truncMap.mpr h_trunc₁, h_fin₁⟩ /-- Let `α : N ⟶ N'` be a map of functors on tests over `A` such that, for every functor `g` from a category `C` to tests over `A` and every functor `F` on `C` with Zariski descent along `g`, pull-back along `α` (restricted along `g`) is a bijection of total Ext groups into `F` (`IsCohomEquiv`). Then `D.IsFiniteLerayHirsch N` holds if and only if `D.IsFiniteLerayHirsch N'` holds. -/ lemma isFiniteLerayHirsch_iff_of_isCohomEquiv (α : N ⟶ N') (h : ∀ {C : Type 1} [Category C] {F : AbFunctor C} (g : C ⥤ TestOver A), HasZariskiDescent (ringOf g) F → IsCohomEquiv F (g.whiskerLeft α)) : D.IsFiniteLerayHirsch N ↔ D.IsFiniteLerayHirsch N' := by classical -- Pull-back along `α` is bijective in the constant theory and in `D`. have h_const : Bijective (pullbackAlong (G := locConstAlong (𝟭 (TestOver A))) α) := (h (𝟭 (TestOver A)) Theory.locallyConstant.zariski_descent).bijective_pullbackAlong have h_D : Bijective (pullbackAlong (G := D.functor) (g.whiskerLeft α)) := (h g D.zariski_descent).bijective_pullbackAlong -- The two comparison maps `lerayHirsch` form a commutative square with these pull-backs. have h_bij_iff : IsLerayHirschBasis D.comparison N' ↔ IsLerayHirschBasis D.comparison N := Comparison.bijective_iff_of_comm_sq (lerayHirsch_mapRange_comp _ map_homClass) (mapRange_bijective _ _ h_const) h_D exact (h_bij_iff.and h_const.finite_iff).symm /-- The zero-parameter stage for the locally constant theory of `D`. -/ private abbrev constStage : LineStage A 0 := ⟨Theory.locallyConstant, D.line_formula_const, nofun, fun _ ↦ funext nofun⟩ /-- The zero-parameter stage for `D` itself, with empty point family pulled back along `g`. -/ private abbrev targetStage : LineStage A 0 := ⟨D.toTheory, D.line_formula, g.sectionsPrecomp D.constStage.points⟩ /-- A zero-parameter natural operation commutes with `lerayHirsch D.comparison` between `D.constStage` and `D.targetStage`. -/ private lemma lerayHirsch_mapRange_naturalOp {M M' : AbFunctor (TestOver A)} (s : NaturalOp 0 M M') (w : D.Index →₀ TotalH M Theory.locallyConstant.functor) : lerayHirsch D.comparison M' (w.mapRange (s.app D.constStage) (s.app D.constStage).map_zero) = s.app D.targetStage (lerayHirsch D.comparison M w) := -- `(… :)`: the stated type is that of `lerayHirsch_naturality` with `D.constStage` and -- `D.targetStage` unfolded. (lerayHirsch_naturality D.comparison (s.app D.constStage) (fun i ↦ s.naturality D.constStage g _ D.line_formula (D.comparison i).toTotalH) w :) /-- Surjectivity of `lerayHirsch D.comparison N` in `isFiniteLerayHirsch_of_retract`: each term `ρ i (r i x)` lies in the range because `lerayHirsch D.comparison N'` is surjective and commutes with `ρ i`. -/ private lemma lerayHirsch_surjective_of_retract [HasFlatValues N] (r : ι → NaturalOp 0 (abCoker (ℓ • 𝟙 N)) N') (ρ : ι → NaturalOp 0 N' N) (h_sum : ∀ x : TotalH (D.targetStage.toTestOver ⋙ abCoker (ℓ • 𝟙 N)) D.targetStage.theory.functor, ∑ i : ι, (ρ i).app D.targetStage ((r i).app D.targetStage x) = pullbackAlong (D.targetStage.toTestOver.whiskerLeft (abCoker.π (ℓ • 𝟙 N))) x) (hN'_surj : Surjective (lerayHirsch D.comparison N')) : Surjective (lerayHirsch D.comparison N) := by classical intro y obtain ⟨x, rfl⟩ := D.pullbackAlong_abCoker_pi_surjective (N := g ⋙ N) y -- By `h_sum` for `D`, the pull-back of `x` is `∑ i, ρ i (r i x)`. have h_mem : ∑ i, (ρ i).app D.targetStage ((r i).app D.targetStage x) ∈ LinearMap.range (lerayHirsch D.comparison N) := by refine (lerayHirsch D.comparison N).range.sum_mem fun i _ ↦ ?_ obtain ⟨w, hw⟩ := hN'_surj ((r i).app D.targetStage x) exact ⟨w.mapRange ((ρ i).app D.constStage) ((ρ i).app D.constStage).map_zero, (D.lerayHirsch_mapRange_naturalOp (ρ i) w).trans (congrArg _ hw)⟩ obtain ⟨a, ha⟩ := h_mem exact ⟨a, ha.trans (h_sum x)⟩ /-- Injectivity of `lerayHirsch D.comparison N` in `isFiniteLerayHirsch_of_retract`: any kernel element lifts to `N / ℓ`, becomes a coboundary `δ u` in `D`, and agrees with `δ u` after each `r i` by injectivity on `N'`. -/ private lemma lerayHirsch_injective_of_retract [HasFlatValues N] (r : ι → NaturalOp 0 (abCoker (ℓ • 𝟙 N)) N') (ρ : ι → NaturalOp 0 N' N) (hπ_sum : ∀ x : TotalH (abCoker (ℓ • 𝟙 N)) Theory.locallyConstant.functor, ∑ i : ι, (ρ i).app D.constStage ((r i).app D.constStage x) = pullbackAlong (abCoker.π (ℓ • 𝟙 N)) x) (hN'_inj : Injective (lerayHirsch D.comparison N')) (h_surj : Surjective (lerayHirsch D.comparison N)) : Injective (lerayHirsch D.comparison N) := by classical let L : AbFunctor (TestOver A) := Theory.locallyConstant.functor -- `N` is flat and the coefficients are killed by `ℓ`, so pull-back `π` from `N / ℓ` is onto. let π : TotalH (abCoker (ℓ • 𝟙 N)) L →+ TotalH N L := pullbackAlong (abCoker.π (ℓ • 𝟙 N)) have hπ : Surjective π := D.constStage.theory.pullbackAlong_abCoker_pi_surjective refine (injective_iff_map_eq_zero _).2 ((mapRange_surjective _ π.map_zero hπ).forall.mpr fun w hw ↦ Finsupp.ext fun m ↦ ?_) have hw' : comp (homClass ((restrictAlong g).map (abCoker.π (ℓ • 𝟙 N)))) (lerayHirsch D.comparison (abCoker (ℓ • 𝟙 N)) w) = 0 := (lerayHirsch_mapRange_comp D.comparison map_homClass w).symm.trans hw -- `δ` is the connecting map of `0 → N → N → N / ℓ → 0`; its image is the kernel of `π`. -- `h_ses` is stated in terms of `h_comp_zero`, so that fact stays in context. obtain ⟨h_comp_zero, h_ses⟩ := shortExact_nsmul_abCoker (ℓ := ℓ) (N := N) let δ : TotalH N L →+ TotalH (abCoker (ℓ • 𝟙 N)) L := comp h_ses.extClass.toTotalH obtain ⟨-, -, h_exact⟩ := exact_triangle h_ses L -- `lerayHirsch D.comparison _ w` pulls back to zero, so it is a coboundary, of some -- `lerayHirsch D.comparison N u` since `lerayHirsch D.comparison N` is onto. obtain ⟨-, -, h_exact_g⟩ := exact_triangle (h_ses.map_of_exact (restrictAlong g)) D.functor obtain ⟨v, hv⟩ := (h_exact_g _).mp hw' obtain ⟨u, hu⟩ := h_surj v have h_cob : lerayHirsch D.comparison (abCoker (ℓ • 𝟙 N)) (u.mapRange δ δ.map_zero) = lerayHirsch D.comparison (abCoker (ℓ • 𝟙 N)) w := calc lerayHirsch D.comparison (abCoker (ℓ • 𝟙 N)) (u.mapRange δ δ.map_zero) _ = comp (h_ses.map_of_exact (restrictAlong g)).extClass.toTotalH (lerayHirsch D.comparison N u) := lerayHirsch_mapRange_comp D.comparison (map_extClass h_ses) u _ = comp (h_ses.map_of_exact (restrictAlong g)).extClass.toTotalH v := by rw [hu] _ = lerayHirsch D.comparison (abCoker (ℓ • 𝟙 N)) w := hv have h_r (i : ι) : (r i).app D.constStage (δ (u m)) = (r i).app D.constStage (w m) := by have h_image : lerayHirsch D.comparison N' ((u.mapRange δ δ.map_zero).mapRange ((r i).app D.constStage) ((r i).app D.constStage).map_zero) = lerayHirsch D.comparison N' (w.mapRange ((r i).app D.constStage) ((r i).app D.constStage).map_zero) := by rw [D.lerayHirsch_mapRange_naturalOp, D.lerayHirsch_mapRange_naturalOp, h_cob] -- Evaluate the equality of finitely supported functions at `m`. exact DFunLike.congr_fun (hN'_inj h_image) m rw [Finsupp.mapRange_apply, Finsupp.zero_apply, ← hπ_sum (w m), ← h_exact.apply_apply_eq_zero (u m), ← hπ_sum (δ (u m))] simp only [h_r] /-- `D.IsFiniteLerayHirsch` passes to retracts by natural operations. Let `N` have flat values, write `N / ℓ` for `abCoker (ℓ • 𝟙 N)`, and let `r i : N / ℓ → N'` and `ρ i : N' → N` be operations without parameters (`NaturalOp 0`). If `∑ i, ρ i (r i x)` is always the pull-back of `x` along `N → N / ℓ`, then `D.IsFiniteLerayHirsch N'` implies `D.IsFiniteLerayHirsch N`. -/ lemma isFiniteLerayHirsch_of_retract [HasFlatValues N] (r : ι → NaturalOp 0 (abCoker (ℓ • 𝟙 N)) N') (ρ : ι → NaturalOp 0 N' N) (h_sum : ∀ (t : LineStage A 0) (x : TotalH (t.toTestOver ⋙ abCoker (ℓ • 𝟙 N)) t.theory.functor), ∑ i : ι, (ρ i).app t ((r i).app t x) = pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π (ℓ • 𝟙 N))) x) (hN' : D.IsFiniteLerayHirsch N') : D.IsFiniteLerayHirsch N := by obtain ⟨⟨hN'_inj, hN'_surj⟩, hN'_fin⟩ := hN' have h_surj : Surjective (lerayHirsch D.comparison N) := D.lerayHirsch_surjective_of_retract r ρ (h_sum D.targetStage) hN'_surj have h_inj : Injective (lerayHirsch D.comparison N) := D.lerayHirsch_injective_of_retract r ρ (h_sum D.constStage) hN'_inj h_surj -- Finite: the cohomology of `N` is the image of a finite product of copies of that of `N'`. have h_onto : Surjective fun v : ι → TotalH N' (locConstAlong (𝟭 (TestOver A))) ↦ ∑ i, (ρ i).app D.constStage (v i) := by intro y obtain ⟨x, rfl⟩ := D.constStage.theory.pullbackAlong_abCoker_pi_surjective y exact ⟨fun i ↦ (r i).app D.constStage x, h_sum D.constStage x⟩ exact ⟨⟨h_inj, h_surj⟩, .of_surjective _ h_onto⟩ /-! ### Pairs in a power of the projective line -/ /-- For an ideal family `I` on `(ℙ¹)^m` over a ring `A` inverting a prime `ℓ`, a compared theory `D`, a functor `N` with `D.IsFiniteLerayHirsch N`, a finite family of classes `β : ι → TotalH (relFreeAb I.topPoints) N`, and zero-parameter natural operations `T : ι → NaturalOp 0 (abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) N`, if for every zero-parameter stage `t : LineStage A 0`, section `q'` of `(ℙ¹)^m` over `t.toTestOver`, and class `w` on the quotient by `ℓ`, the pull-backs along `I.atSection q'` of `∑ i, β i · (T i).app t w` and of the pull-back of `w` along `abCoker.π (ℓ • 𝟙 (relFreeAb I.topPoints))` agree, then `D.IsFiniteLerayHirsch (relFreeAb I.topPoints)`. -/ private lemma isFiniteLerayHirsch_of_zero_params (β : ι → TotalH (relFreeAb I.topPoints) N) (hN : D.IsFiniteLerayHirsch N) (T : ι → NaturalOp 0 (abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) N) (h_sum_eq : ∀ (t : LineStage A 0) (q' : (t.toTestOver ⋙ ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m)).sections) (w : TotalH (t.toTestOver ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) t.theory.functor), pullbackAlong (I.atSection q') (∑ i : ι, mapThenComp (restrictAlong t.toTestOver) ((T i).app t w) (β i)) = pullbackAlong (I.atSection q') (pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π (ℓ • 𝟙 (relFreeAb I.topPoints)))) w)) : D.IsFiniteLerayHirsch (relFreeAb I.topPoints) := by -- No parameter: `isFiniteLerayHirsch_of_retract` applies once the `T i` followed by composition -- with the `β i` sum to pull-back along the projection to the cokernel of `ℓ`. let ρ (i : ι) : NaturalOp 0 N (relFreeAb I.topPoints) := ⟨fun t ↦ comp (map (restrictAlong t.toTestOver) (β i)), fun t φ _Θ _l _b _x ↦ mapThenComp_comp (map_restrictAlong_restrictAlong t.toTestOver φ (β i))⟩ refine D.isFiniteLerayHirsch_of_retract T ρ (fun t x ↦ ?_) hN -- The identity may be checked after restriction `r` to the points of `X` and evaluation at -- the tautological section (`isBijective_relFreeAb_tautologicalSection`): there it is `h_sum_eq`. let X : t.Base ⥤ Type 1 := t.toTestOver ⋙ ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m) let r {S : AbFunctor t.Base} : TotalH S t.theory.functor →+ TotalH (elementsProj X ⋙ S) (t.theory.onElements (X := X)).functor := mapThenComp (restrictAlong (elementsProj X)) (.homClass (𝟙 _)) let t' : LineStage A 0 := ⟨t.theory.onElements (X := X), t.line_formula.onElements, (elementsProj X).sectionsPrecomp t.points⟩ -- `r` commutes with every operation and with pull-back from the cokernel of `ℓ`. have h_nat {M M' : AbFunctor (TestOver A)} (s : NaturalOp 0 M M') (y : TotalH (t.toTestOver ⋙ M) t.theory.functor) : r (s.app t y) = s.app t' (r y) := s.naturality t (elementsProj X) t.theory.onElements t.line_formula.onElements (.homClass (𝟙 _)) y have h_proj : r (pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π _)) x) = pullbackAlong ((elementsProj X ⋙ t.toTestOver).whiskerLeft (abCoker.π _)) (r x :) := mapThenComp_comp map_homClass refine (isBijective_relFreeAb_tautologicalSection (I.topPoints.whisker t.toTestOver)).bijective_totalH.injective ?_ -- After `r`, the left side is the sum of the operations at `t'` applied to `r x`. have h_sum_r : r (∑ i, (ρ i).app t ((T i).app t x)) = ∑ i, (ρ i).app t' ((T i).app t' (r x :)) := by rw [map_sum] exact Finset.sum_congr rfl fun i _ ↦ (h_nat (ρ i) _).trans (congrArg _ (h_nat (T i) x)) change comp _ (r _) = comp _ (r _) refine (congrArg (comp _) h_sum_r).trans ?_ refine Eq.trans ?_ (congrArg (comp _) h_proj).symm -- This is `h_sum_eq` at `t'` and the tautological section `a ↦ a.2` of `X`. exact h_sum_eq t' ⟨fun a ↦ a.val, fun f ↦ f.map_val⟩ (r x :) /-- `D.IsFiniteLerayHirsch` passes from `N` to `ℤ[(ℙ¹)^m]/ℤ[U]`, `U = I.topPoints`, given classes `β i` from it to `N`, operations `T i` with `d` parameters in `ℙ¹` from its quotient by `ℓ` to `N`, and `σ` sending parameters to coordinates, such that (`h_sum_eq_foldr`) for every stage `t` with points `t.points`, section `q'` and class `w`, `∑ i, β i · T i (w)` and `w · ∏ j, (η(t.points j) + η(q' (σ j)))` agree after pull-back along `I.atSection q'`. -/ lemma isFiniteLerayHirsch_of_integrate_params (β : ι → TotalH (relFreeAb I.topPoints) N) (hN : D.IsFiniteLerayHirsch N) (σ : Fin d → Fin m) (T : ι → NaturalOp d (abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) N) (h_sum_eq_foldr : ∀ (t : LineStage A d) (q' : (t.toTestOver ⋙ ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m)).sections) (w : TotalH (t.toTestOver ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) t.theory.functor), pullbackAlong (I.atSection q') (∑ i : ι, mapThenComp (restrictAlong t.toTestOver) ((T i).app t w) (β i)) = pullbackAlong (I.atSection q') (foldr d (fun j : Fin d ↦ comp.flip (t.theory.etaAt (freeAbSectionMap (projLinePow.component t.points j) + freeAbSectionMap (projLinePow.component q' (σ j)))).toTotalH) (pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π (ℓ • 𝟙 (relFreeAb I.topPoints)))) w))) : D.IsFiniteLerayHirsch (relFreeAb I.topPoints) := by -- Induction on the number `d` of parameters: the zero-parameter case is -- `isFiniteLerayHirsch_of_zero_params`, and integrating over the line removes the first one. induction d with | zero => exact D.isFiniteLerayHirsch_of_zero_params I β hN T h_sum_eq_foldr | succ d ih => -- Apply the induction hypothesis to the integrated operations. refine ih (fun j ↦ σ j.succ) (fun i ↦ (T i).integrate) fun t q' w ↦ ?_ -- By `integrate_mul_cupClass`, the right side is the integral of its restriction to the line -- times the factor of the first parameter. refine Eq.trans ?_ (t.line_formula.integrate_mul_cupClass _ (t.theory.etaAt (freeAbSectionMap (projLinePow.component q' (σ 0)))).toTotalH) -- Composition on the left commutes with integration, so the left side is an integral too. have comp_int {S S' : AbFunctor t.Base} (ξ : TotalH S' S) : ∀ x : TotalH (elementsProj (projLineAlong t.toTestOver) ⋙ S) (elementsProj (projLineAlong t.toTestOver) ⋙ t.theory.functor), comp ξ (t.line_formula.integrate x) = t.line_formula.integrate (comp (map (restrictAlong (elementsProj (projLineAlong t.toTestOver))) ξ) x) := t.line_formula.integrate_naturality (φ := 𝟭 _) t.line_formula (lerayHirsch_mapRange_comp _ rfl) -- `change`: the summands match `comp_int` only after unfolding `NaturalOp.integrate`. change pullbackAlong _ (∑ i, comp (map (restrictAlong t.toTestOver) (β i)) (t.line_formula.integrate _)) = _ rw [Finset.sum_congr rfl fun i _ ↦ comp_int .., ← map_sum, comp_int] -- Push restriction into the products, split off the first factor in `h_sum_eq_foldr`, and -- write the remaining products as folds over lists. simp only [map_comp_assoc, map_restrictAlong_restrictAlong, map_homClass, TorsionCoeff.map_etaAt_onElements, foldr_succ, foldr_eq_finRange_foldr] at h_sum_eq_foldr ⊢ -- Restriction to the line passes through the fold factor by factor. conv_rhs => erw [← map_add, ← map_add, map_foldr_etaAt (X := projLineAlong t.toTestOver), map_pullbackAlong (Φ := restrictAlong (elementsProj (projLineAlong t.toTestOver)))] -- The integrands agree by `h_sum_eq_foldr` over the points of the line, with the tautological -- point as first parameter. -- (`apply`: compares the statement with the goal once; `exact congrArg _ (…)` does it twice) refine congrArg _ ?_ apply h_sum_eq_foldr t.consTautologicalPoint ((elementsProj _).sectionsPrecomp q') /-- Extending a class to the zeros of `I` at the section `t.points` and then pulling it back along the kernel `I.constToZeros` is the same as restricting the class to the section and pulling it back along `I.atSection t.points`. -/ private lemma pullbackAlong_extendToZeros_eq (t : LineStage A m) (w : TotalH (t.toTestOver ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) t.theory.functor) : pullbackAlong ((sectionLift (X := ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m)) t.toTestOver t.points).whiskerLeft (abCoker.π _)) (pullbackAlong ((sectionLift (X := ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m)) t.toTestOver t.points).whiskerLeft I.constToZeros) (I.extendToZeros t.theory t.points w)) = pullbackAlong (I.atSection t.points) (pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π _)) w) := by refine ((congrArg (pullbackAlong _) (I.zerosEquiv_extendToZeros t.theory t.points w)).trans (pullbackAlong_pullbackAlong ..)).trans ?_ exact (pullbackAlong_pullbackAlong (f := I.atSection t.points) (t.toTestOver.whiskerLeft (abCoker.π _)) w).symm /-- Let I be a compatible family of ideals on points of (P¹)^m, U the locus where I is the unit ideal, and Q = ℤ[(P¹)^m]/ℤ[U]. Let `θ i` be classes of degree `d i`, over the points of (P¹)^m, from N to the locally constant ℤ/ℓ-valued functions modulo those dying where I = 0 (`I.zerosCoeff`). Suppose their Leray–Hirsch map, sending families `(w i)` of total Ext classes from Q to N to `∑ i, θ i ∘ w i` (with `w i` restricted to points), is surjective. Then `D.IsFiniteLerayHirsch` passes from N to Q; this property includes bijectivity of the analogous map built from the classes `D.comparison i`. -/ lemma isFiniteLerayHirsch_topPoints_of_surjective {J : Type*} {d : J → ℕ} {θ : ∀ i : J, H (restrictAlong (elementsProj (ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m))) N) (I.zerosCoeff (locConstAlong (elementsProj (ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m))))) (d i)} (h_surj : Surjective (lerayHirsch θ (relFreeAb I.topPoints))) (hN : D.IsFiniteLerayHirsch N) : D.IsFiniteLerayHirsch (relFreeAb I.topPoints) := by -- `IdealFamily.exists_move_kernel` moves the kernel `I.constToZeros` from a point `points` of -- `X = (ℙ¹)^m` to a second point `q'`. -- The moved kernel is `∑ β i · θ i` by `h_surj`; this gives the identity that -- `isFiniteLerayHirsch_of_integrate_params` asks for, with the operations -- `T i : w ↦ θ i · I.extendToZeros w`. let X := ringOf (𝟭 (TestOver A)) ⋙ projLinePow (Fin m) -- Pulled back along `I.constToZeros`, the extension of `w` is the restriction of `w` to `points`. have h_ext (t : LineStage A m) (w : TotalH (t.toTestOver ⋙ abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) t.theory.functor) := pullbackAlong_extendToZeros_eq (t := t) (w := w) let T (i : J) : NaturalOp m (abCoker (ℓ • 𝟙 (relFreeAb I.topPoints))) N := { app t := (comp (map (restrictAlong (sectionLift (X := X) t.toTestOver t.points)) (θ i).toTotalH :)).comp (I.extendToZeros t.theory t.points) naturality t φ K _ b x := ((mapThenComp_comp (map_restrictAlong_restrictAlong (sectionLift (X := X) t.toTestOver t.points) φ (θ i).toTotalH)).trans (congrArg _ (I.extendToZeros_naturality t.theory t.points φ K b x)) :) } -- `E` is the category of tests with two points of `X`; there every maximal ideal is the kernel -- of the map to a quotient test. let E := ((elementsProj X ⋙ 𝟭 (TestOver A)) ⋙ X).Elements have h_max (c : E) (𝔪 : Ideal _) (h𝔪 : 𝔪.IsMaximal) : ∃ (c' : E) (f : c ⟶ c'), RingHom.ker ((ringOf (elementsProj _ ⋙ elementsProj X ⋙ 𝟭 _)).map f).hom = 𝔪 := by obtain ⟨_, π, hπ⟩ := TestOver.exists_quotient _ 𝔪 rw [← h𝔪.isPrime.radical] exact ⟨.mk (obj := ⟨X.map π c.obj.val⟩) (X.map π c.val), ⟨⟨π, rfl⟩, rfl⟩, hπ.1⟩ -- For the two tautological points `points`, `q'` of `E` there is a class `δ'` such that every -- class into a theory that carries the kernel to `w` at `points` carries `δ'` to -- `w · ∏ j, (η(points j) + η(q' j))` at `q'`. have h_chain := I.exists_move_kernel (((Theory.locallyConstant.onElements (X := X)).onZeros I).onElements (X := _ ⋙ X)) h_max (fun r ↦ ⟨_, fun f ↦ funext fun j ↦ (r j).property f⟩) (fun _ hr ↦ funext hr) (projLinePow.component ⟨_, fun f ↦ f.hom.map_val⟩) (projLinePow.component ⟨_, fun f ↦ f.2⟩) (pullbackAlong ((elementsProj _).whiskerLeft (abCoker.π _)) (.homClass ((elementsProj _).whiskerLeft I.constToZeros))) -- Pull-back to `E` at the second point is bijective, so the moved kernel comes from some -- `lerayHirsch θ _ β`. obtain ⟨β, hβ⟩ := ((isBijective_relFreeAb_tautologicalSection (I.topPoints.whisker (elementsProj X))).bijective_totalH.2.comp h_surj).exists.1 h_chain refine D.isFiniteLerayHirsch_of_integrate_params I (β.1.restrict β) hN id (fun i ↦ T i) fun t q' w ↦ ?_ -- The sum over the support of `β` is the pairing of `lerayHirsch θ _ β` with the extension of -- `w`. have h_sum : ∑ i : β.support, mapThenComp (restrictAlong t.toTestOver) ((T i).app t w) (β i) = comp (TotalH.map (restrictAlong (sectionLift t.toTestOver t.points)) (lerayHirsch θ _ β) :) (I.extendToZeros t.theory t.points w) := by simp_rw [show lerayHirsch θ _ β = _ from (β.support.sum_coe_sort _).symm, map_sum, AddMonoidHom.finsetSum_apply] refine Finset.sum_congr rfl fun i _ ↦ ?_ exact (mapThenComp_comp (map_restrictAlong_restrictAlong (elementsProj X) (sectionLift _ t.points) (β i))).symm -- Specialise `hβ` to the pair `(t.points, q')`; its hypothesis is `h_ext`. let s : t.Base ⥤ E := sectionLift (X := (elementsProj X ⋙ 𝟭 (TestOver A)) ⋙ X) (sectionLift (X := X) t.toTestOver t.points) q' have h_move := hβ _ s t.theory (I.extendToZeros t.theory t.points w) (pullbackAlong (t.toTestOver.whiskerLeft (abCoker.π _)) w) (by -- (`apply`: compares `h_ext t w` with the goal once; as a term it is compared twice) refine (mapThenComp_comp map_homClass).trans ((congrArg _ congr(comp $map_homClass _)).trans ?_) apply h_ext t w) refine (congrArg _ h_sum).trans (.trans (comp_assoc_of_eq (.symm ?_) _) h_move) -- The moved kernel at `(t.points, q')` is `lerayHirsch θ _ β` restricted along `t.points`, then -- pulled back by `I.atSection q'`. refine map_pullbackAlong.trans (congrArg _ ((congrArg _ comp_id).trans ?_)) exact map_restrictAlong_restrictAlong (elementsProj _) s (lerayHirsch θ _ β) end ComparedTheory end ComparedTheories end New.Variety end