import Mathlib import OAI.Geometry.BallPacking.Annuli.QuadricNormalizedCycle namespace OAI noncomputable section namespace PackingSufficiencySupport.Hamiltonian open scoped ContDiff Manifold Topology open Set Function Manifold MeasureTheory section variable {P E : Type} [NormedAddCommGroup P] [NormedSpace ℝ P] [FiniteDimensional ℝ P] [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] {M : Type} [TopologicalSpace M] [ChartedSpace E M] [IsManifold π“˜(ℝ,E) ∞ M] [T2Space M] [NormalSpace M] [SigmaCompactSpace M] theorem exists_normalized_primitive_on_annular_chart {V : Set P} {I : Set ℝ} {K : Set M} (hV : IsOpen V) (hI : IsOpen I) (hc : Convex ℝ I) {a : ℝ} (ha : a∈I) (e : PartialDiffeomorph π“˜(ℝ,CylinderModel) π“˜(ℝ,E) HandleCylinder M ∞) (he_source : e.source=I Γ—Λ’ univ) (hK : IsCompact K) (hKA : KβŠ†e.target) {Ξ“ N : P β†’ ManifoldOneForm E M} {Ξ² : ManifoldOneForm E M} (hΞ“ : βˆ€ c,ContDiffOn ℝ ∞ (fun q : P Γ— E => chartOneForm (Ξ“ q.1) c q.2) (V Γ—Λ’ (extChartAt π“˜(ℝ,E) c).target)) (hN : βˆ€ p∈V,βˆ€ x∈e.target,ContDiffAt ℝ ∞ (fun q : P Γ— E => chartOneForm (N q.1) x q.2) (p,extChartAt π“˜(ℝ,E) x x)) (hcurv : βˆ€ p∈V,βˆ€ x∈e.target,manifoldExteriorOneForm (Ξ“ p) x=manifoldExteriorOneForm (N p) x) (hΞ² : βˆ€ c,ContDiffOn ℝ ∞ (chartOneForm Ξ² c) (extChartAt π“˜(ℝ,E) c).target) (hΞ²closed : βˆ€ x,manifoldExteriorOneForm Ξ² x=0) (hΞ²compact : HasCompactSupport Ξ²) {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (hfint : (∫ t in (0:ℝ)..1,f (circleTurn t))=1) (hΞ²coord : βˆ€ z∈e.source,βˆ€ v : CylinderModel, Ξ² (e z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) e z v)=f z.2*circleAngular z.2 v.2) : βˆƒ (Γ₁ : P β†’ ManifoldOneForm E M) (L W : Set M), IsCompact L ∧ LβŠ†e.target ∧ IsOpen W ∧ KβŠ†W ∧ WβŠ†e.target ∧ (βˆ€ c,ContDiffOn ℝ ∞ (fun q : P Γ— E => chartOneForm (Γ₁ q.1) c q.2) (V Γ—Λ’ (extChartAt π“˜(ℝ,E) c).target)) ∧ (βˆ€ p,support (Γ₁ p-Ξ“ p)βŠ†tsupport Ξ²βˆͺL) ∧ (βˆ€ p,HasCompactSupport (Γ₁ p-Ξ“ p)) ∧ (βˆ€ p∈V,βˆ€ x,manifoldExteriorOneForm (Γ₁ p) x=manifoldExteriorOneForm (Ξ“ p) x) ∧ (βˆ€ p∈V,βˆ€ x∈W,Γ₁ p x=N p x) := by let Ξ΄ : P β†’ ManifoldOneForm E M := fun p => Ξ“ p-N p let Ξ± := parameterManifoldPullbackOneForm (E := E) (F := CylinderModel) Ξ΄ e have hΞ“at (p : P) (hp : p∈V) (x : M) : ContDiffAt ℝ ∞ (fun q : P Γ— E => chartOneForm (Ξ“ q.1) x q.2) (p,extChartAt π“˜(ℝ,E) x x) := (hΞ“ x).contDiffAt ((hV.prod (isOpen_extChartAt_target (I := π“˜(ℝ,E)) x)).mem_nhds ⟨hp,(extChartAt π“˜(ℝ,E) x).map_source (mem_extChartAt_source x)⟩) have hΞ΄ (p : P) (hp : p∈V) (x : M) (hx : x∈e.target) : ContDiffAt ℝ ∞ (fun q : P Γ— E => chartOneForm (Ξ΄ q.1) x q.2) (p,extChartAt π“˜(ℝ,E) x x) := by apply ((hΞ“at p hp x).sub (hN p hp x hx)).congr_of_eventuallyEq exact Filter.Eventually.of_forall (fun q => chartOneForm_sub (Ξ“ q.1) (N q.1) x q.2) have hΞ΄closed (p : P) (hp : p∈V) (x : M) (hx : x∈e.target) : manifoldExteriorOneForm (Ξ΄ p) x=0 := by change manifoldExteriorOneForm (Ξ“ p-N p) x=0 rw [manifoldExteriorOneForm_sub_at (Ξ± := Ξ“ p) (Ξ² := N p) (x := x) ((hΞ“at p hp x).comp _ (contDiffAt_const.prodMk contDiffAt_id)) ((hN p hp x hx).comp _ (contDiffAt_const.prodMk contDiffAt_id)),hcurv p hp x hx] ext u v simp have hsrc (z : HandleCylinder) (hz : z.1∈I) : z∈e.source := by rw [he_source]; exact ⟨hz,mem_univ _⟩ have hΞ± (p : P) (hp : p∈V) (z : HandleCylinder) (hz : z.1∈I) : ContDiffAt ℝ ∞ (fun q : P Γ— CylinderModel => chartOneForm (Ξ± q.1) z q.2) (p,extChartAt π“˜(ℝ,CylinderModel) z z) := parameterManifoldPullbackOneForm_contDiffAt (Ξ± := Ξ΄) (g := e) (hΞ΄ p hp (e z) (e.map_source (hsrc z hz))) (e.contMDiffOn.contMDiffAt (e.open_source.mem_nhds (hsrc z hz))) have hclosed (p : P) (hp : p∈V) (z : HandleCylinder) (hz : z.1∈I) : manifoldExteriorOneForm (Ξ± p) z=0 := by change manifoldExteriorOneForm (manifoldPullbackOneForm (E := E) (F := CylinderModel) (fun _ => Ξ΄ p) e 0) z=0 rw [manifold_pullback_exterior_at (Ξ± := Ξ΄ p) (g := e) (b := z) ((hΞ΄ p hp (e z) (e.map_source (hsrc z hz))).comp _ (contDiffAt_const.prodMk contDiffAt_id)) (e.contMDiffOn.contMDiffAt (e.open_source.mem_nhds (hsrc z hz)))] dsimp only [manifoldPullbackTwoForm] rw [hΞ΄closed p hp (e z) (e.map_source (hsrc z hz))] rfl have hmem (x : M) (hx : x∈e.target) : (e.symm x).1∈I := by have hm := e.map_target hx rw [he_source] at hm exact hm.1 obtain ⟨F,hF,hFd⟩ := exists_intrinsic_annular_coordinate_potential hV hI e.open_target hc ha hΞ± hclosed hf hfint e.symm.contMDiffOn hmem have hFd' : βˆ€ p∈V,βˆ€ x∈e.target, manifoldScalarDifferential (E := E) (fun y => F (p,y)) x= Ξ“ p x-N p x-cylinderFormPeriod a Ξ± p β€’ Ξ² x := by intro p hp x hx apply ContinuousLinearMap.ext intro v rw [hFd p hp x hx v] have hd := parameterManifoldPullbackOneForm_inverse_apply e Ξ΄ p hx v change Ξ± p (e.symm x) (mfderiv π“˜(ℝ,E) π“˜(ℝ,CylinderModel) e.symm x v)=_ at hd rw [hd] have hbc := hΞ²coord (e.symm x) (e.map_target hx) (mfderiv π“˜(ℝ,E) π“˜(ℝ,CylinderModel) e.symm x v) have hb := parameterManifoldPullbackOneForm_inverse_apply e (fun _ : P => Ξ²) p hx v change Ξ² (e (e.symm x)) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) e (e.symm x) (mfderiv π“˜(ℝ,E) π“˜(ℝ,CylinderModel) e.symm x v))=Ξ² x v at hb rw [hb] at hbc simp only [Ξ΄,Pi.sub_apply,sub_apply,smul_apply,smul_eq_mul] rw [hbc] ring exact exists_normalized_manifold_primitive_neighborhood hV hK e.open_target hKA hΞ“ hΞ² hΞ²closed hΞ²compact (cylinderFormPeriod_smooth hV ha hΞ±) hF hFd' end def cylinderClockPrimitive (S : ℝ β†’ ℝ) (f : Circle β†’ ℝ) : ManifoldOneForm CylinderModel HandleCylinder := weightedCylinderAngular (fun z => S z.1*f z.2) theorem cylinderClockPrimitive_smoothAt {S : ℝ β†’ ℝ} (hS : ContDiff ℝ ∞ S) {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (z : HandleCylinder) : ContDiffAt ℝ ∞ (chartOneForm (cylinderClockPrimitive S f) z) (extChartAt π“˜(ℝ,CylinderModel) z z) := by have hp : ContMDiff π“˜(ℝ,CylinderModel) π“˜(ℝ,ℝ) ∞ (Prod.fst : HandleCylinder β†’ ℝ) := by rw [show π“˜(ℝ,CylinderModel) = (π“˜(ℝ,ℝ)).prod π“˜(ℝ,CircleModel) from modelWithCornersSelf_prod] exact contMDiff_fst exact weightedCylinderAngular_smoothAt (((hS.contMDiff.comp hp).mul (hf.comp cylinder_snd_smooth)).contMDiffAt) theorem cylinderClockPrimitive_exterior_cover {S : ℝ β†’ ℝ} (hS : ContDiff ℝ ∞ S) {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (q : Plane) : (manifoldExteriorOneForm (cylinderClockPrimitive S f) (cylinderCover q)).bilinearComp (mfderiv π“˜(ℝ,Plane) π“˜(ℝ,CylinderModel) cylinderCover q) (mfderiv π“˜(ℝ,Plane) π“˜(ℝ,CylinderModel) cylinderCover q)= (deriv S q.1*f (circleTurn q.2)) β€’ planarArea := by have hn := euclidean_manifold_pullback_exterior_at cylinderCover_smooth.contMDiffAt (cylinderClockPrimitive_smoothAt hS hf (cylinderCover q)) have he : (fun y => euclideanPullbackOneForm (fun _ => cylinderClockPrimitive S f) cylinderCover (0,y))= (fun y => planarCovector 0 (S y.1*f (circleTurn y.2))) := by funext y apply ContinuousLinearMap.ext intro v change (S y.1*f (circleTurn y.2))*cylinderAngular (cylinderCover y) (mfderiv π“˜(ℝ,Plane) π“˜(ℝ,CylinderModel) cylinderCover y v)=_ rw [cylinderAngular_cover] simp only [planarCovector_apply,zero_mul,zero_add] have hc : ContDiff ℝ ∞ (fun y : Plane => S y.1*f (circleTurn y.2)) := (hS.comp contDiff_fst).mul (((hf.comp circleTurn_smooth).contDiff).comp contDiff_snd) have hd : deriv (fun s => S s*f (circleTurn q.2)) q.1=deriv S q.1*f (circleTurn q.2) := ((hS.differentiable (by simp) q.1).hasDerivAt.mul_const _).deriv calc _ = euclideanExteriorOneForm (fun y => euclideanPullbackOneForm (fun _ => cylinderClockPrimitive S f) cylinderCover (0,y)) q := hn.symm _ = _ := by rw [he,planarCovector_exterior contDiff_const hc,hd,deriv_const,sub_zero] theorem cylinderClockPrimitive_exterior {S : ℝ β†’ ℝ} (hS : ContDiff ℝ ∞ S) {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (z : HandleCylinder) : manifoldExteriorOneForm (cylinderClockPrimitive S f) z= (deriv S z.1*f z.2) β€’ cylinderAreaForm z := by let q : Plane := (z.1,shortCircleArgument z.2) have hq : cylinderCover q=z := by apply Prod.ext Β· rfl Β· exact circleTurn_shortCircleArgument z.2 rw [← hq] let D : Plane β†’L[ℝ] CylinderModel := mfderiv π“˜(ℝ,Plane) π“˜(ℝ,CylinderModel) cylinderCover q have he : (manifoldExteriorOneForm (cylinderClockPrimitive S f) (cylinderCover q)).bilinearComp D D= (deriv S q.1*f (circleTurn q.2)) β€’ planarArea := cylinderClockPrimitive_exterior_cover hS hf q have hd (u : CylinderModel) : D (u.1,circleAngular (circleTurn q.2) u.2)=u := cylinderCover_derivative_right_inverse q u apply ContinuousLinearMap.ext intro v apply ContinuousLinearMap.ext intro w have hv := congrArg (fun Ξ© : Plane β†’L[ℝ] Plane β†’L[ℝ] ℝ => Ξ© (v.1,circleAngular (circleTurn q.2) v.2) (w.1,circleAngular (circleTurn q.2) w.2)) he simp only [ContinuousLinearMap.bilinearComp_apply,smul_apply,smul_eq_mul] at hv rw [hd v,hd w] at hv simpa only [planarArea_apply,cylinderAreaForm_apply,cylinderCover,smul_apply,smul_eq_mul] using hv variable {E M : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] [TopologicalSpace M] [ChartedSpace E M] [IsManifold π“˜(ℝ,E) ∞ M] [T2Space M] [NormalSpace M] [SigmaCompactSpace M] theorem exists_compact_annular_dual_normalization (e : PartialDiffeomorph π“˜(ℝ,CylinderModel) π“˜(ℝ,E) HandleCylinder M ∞) {I : Set ℝ} (hI : IsOpen I) (hc : Convex ℝ I) (he : e.source=I Γ—Λ’ univ) {a : ℝ} (ha : a∈I) {K : Set M} (hK : IsCompact K) (hKA : KβŠ†e.target) {Ξ² : ManifoldOneForm E M} (hΞ² : SmoothOneFormFamily (fun _ : ℝ => Ξ²)) (hclosed : βˆ€ x,manifoldExteriorOneForm Ξ² x=0) (hcompact : HasCompactSupport Ξ²) (hperiod : cylinderFormPeriod a (parameterManifoldPullbackOneForm (fun _ : ℝ => Ξ²) e) 0=1) {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (hfint : (∫ t in (0:ℝ)..1,f (circleTurn t))=1) : βˆƒ (Ξ²' : ManifoldOneForm E M) (L W : Set M), IsCompact L ∧ LβŠ†e.target ∧ IsOpen W ∧ KβŠ†W ∧ WβŠ†e.target ∧ SmoothOneFormFamily (fun _ : ℝ => Ξ²') ∧ HasCompactSupport Ξ²' ∧ (βˆ€ x,manifoldExteriorOneForm Ξ²' x=0) ∧ support (Ξ²'-Ξ²)βŠ†L ∧ βˆ€ z∈e.source,e z∈W β†’ βˆ€ v : CylinderModel, Ξ²' (e z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) e z v)= f z.2*circleAngular z.2 v.2 := by let Ξ± := parameterManifoldPullbackOneForm (E := E) (F := CylinderModel) (fun _ : ℝ => Ξ²) e have hΞ²at (p : ℝ) (x : M) : ContDiffAt ℝ ∞ (fun q : ℝ Γ— E => chartOneForm Ξ² x q.2) (p,extChartAt π“˜(ℝ,E) x x) := (hΞ² x).contDiffAt ((isOpen_univ.prod (isOpen_extChartAt_target (I := π“˜(ℝ,E)) x)).mem_nhds ⟨mem_univ _,(extChartAt π“˜(ℝ,E) x).map_source (mem_extChartAt_source x)⟩) have hsrc (z : HandleCylinder) (hz : z.1∈I) : z∈e.source := by rw [he]; exact ⟨hz,mem_univ _⟩ have hΞ± (p : ℝ) (_hp : p∈(univ : Set ℝ)) (z : HandleCylinder) (hz : z.1∈I) : ContDiffAt ℝ ∞ (fun q : ℝ Γ— CylinderModel => chartOneForm (Ξ± q.1) z q.2) (p,extChartAt π“˜(ℝ,CylinderModel) z z) := parameterManifoldPullbackOneForm_contDiffAt (hΞ²at p (e z)) (e.contMDiffOn.contMDiffAt (e.open_source.mem_nhds (hsrc z hz))) have hΞ±closed (p : ℝ) (_hp : p∈(univ : Set ℝ)) (z : HandleCylinder) (hz : z.1∈I) : manifoldExteriorOneForm (Ξ± p) z=0 := by change manifoldExteriorOneForm (manifoldPullbackOneForm (E := E) (F := CylinderModel) (fun _ => Ξ²) e 0) z=0 rw [manifold_pullback_exterior_at (Ξ± := Ξ²) (g := e) (b := z) ((hΞ²at p (e z)).comp _ (contDiffAt_const.prodMk contDiffAt_id)) (e.contMDiffOn.contMDiffAt (e.open_source.mem_nhds (hsrc z hz)))] dsimp only [manifoldPullbackTwoForm] rw [hclosed] rfl have hmem (x : M) (hx : x∈e.target) : (e.symm x).1∈I := by have hm := e.map_target hx rw [he] at hm exact hm.1 obtain ⟨F,hF,hFd⟩ := exists_intrinsic_annular_coordinate_potential isOpen_univ hI e.open_target hc ha hΞ± hΞ±closed hf hfint e.symm.contMDiffOn hmem let N : ℝ β†’ ManifoldOneForm E M := fun _ => manifoldPullbackOneForm (fun _ => cylinderClockPrimitive (fun _ => 1) f) e.symm 0 have hFd' : βˆ€ p∈(univ : Set ℝ),βˆ€ x∈e.target, manifoldScalarDifferential (E := E) (fun y => F (p,y)) x= Ξ² x-N p x-(0:ℝ) β€’ (0 : ManifoldOneForm E M) x := by intro p hp x hx apply ContinuousLinearMap.ext intro v rw [hFd p hp x hx v] have hd := parameterManifoldPullbackOneForm_inverse_apply e (fun _ : ℝ => Ξ²) p hx v change Ξ± p (e.symm x) (mfderiv π“˜(ℝ,E) π“˜(ℝ,CylinderModel) e.symm x v)=_ at hd rw [hd] have hp' : cylinderFormPeriod a Ξ± p=1 := hperiod rw [hp',one_mul] simp only [N, sub_apply, zero_smul, sub_zero, manifoldPullbackOneForm, cylinderClockPrimitive, weightedCylinderAngular, one_mul, manifoldMapDifferential] change Ξ² x v - _ = Ξ² x v - f (e.symm x).2 * cylinderAngular (e.symm x) (mfderiv π“˜(ℝ,E) π“˜(ℝ,CylinderModel) e.symm x v) erw [cylinderAngular_apply] have hz : βˆ€ c,ContDiffOn ℝ ∞ (chartOneForm (0 : ManifoldOneForm E M) c) (extChartAt π“˜(ℝ,E) c).target := by intro c simpa only [show chartOneForm (0 : ManifoldOneForm E M) c=(fun _ => 0) from funext (chartOneForm_zero c)] using (contDiffOn_const : ContDiffOn ℝ ∞ (fun _ : E => (0 : E β†’L[ℝ] ℝ)) (extChartAt π“˜(ℝ,E) c).target) obtain βŸ¨Ξ“,L,W,hL,hLA,hW,hKW,hWA,hΞ“,hsp,hcp,hd,hn⟩ := exists_normalized_manifold_primitive_neighborhood (E := E) (M := M) (Ξ“ := fun _ : ℝ => Ξ²) (N := N) (Ξ² := 0) (a := fun _ => 0) isOpen_univ hK e.open_target hKA hΞ² hz (fun x => manifoldExteriorOneForm_zero x) (HasCompactSupport.zero) (contDiffOn_const : ContDiffOn ℝ ∞ (fun _ : ℝ => (0:ℝ)) univ) hF hFd' refine βŸ¨Ξ“ 0,L,W,hL,hLA,hW,hKW,hWA,?_,?_,?_,?_,?_⟩ Β· intro c exact (hΞ“ c).comp (contDiff_const.prodMk contDiff_snd).contDiffOn (fun q hq => ⟨mem_univ _,hq.2⟩) Β· have hp := (hcp 0).add hcompact simpa only [sub_add_cancel] using hp Β· intro x rw [hd 0 (mem_univ _) x,hclosed] Β· simpa only [tsupport_zero,empty_union] using hsp 0 Β· intro z hz' hw v rw [hn 0 (mem_univ _) (e z) hw] have hi := parameterManifoldPullbackOneForm_inverse_apply e.symm (fun _ : ℝ => cylinderClockPrimitive (fun _ => 1) f) 0 hz' v change (N 0 (e z)) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) e z v)=_ rw [show N 0 (e z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) e z v)= cylinderClockPrimitive (fun _ => 1) f z v from hi] simp only [cylinderClockPrimitive,weightedCylinderAngular,smul_apply,smul_eq_mul, one_mul,cylinderAngular_apply] end PackingSufficiencySupport.Hamiltonian namespace PackingSufficiencySupport.DiagonalQuadrics.Explicit open scoped ContDiff Manifold Topology open Set Function Manifold MeasureTheory open Hamiltonian variable (m : β„•) instance surfaceSigmaCompact : SigmaCompactSpace (Surface m) := by exact IsClosed.sigmaCompactSpace (locus_isClosed (parameters m)) def restrictedTransverseCylinder (a : ℝ) : PartialDiffeomorph π“˜(ℝ,CylinderModel) π“˜(ℝ,RealModel) HandleCylinder (Surface m) ∞ := restrictHandleDiffeomorph (transverseCylinder m) (Ioo (-a) a Γ—Λ’ univ) (isOpen_Ioo.prod isOpen_univ) theorem restrictedTransverseCylinder_source {a : ℝ} (ha : a≀transverseCylinderWidth m) : (restrictedTransverseCylinder m a).source=Ioo (-a) a Γ—Λ’ univ := by apply inter_eq_right.mpr intro z hz exact transverseCylinderWidth_subset m ⟨⟨by linarith [hz.1.1],by linarith [hz.1.2]⟩,hz.2⟩ theorem exists_actual_compact_normalized_dual_fixed {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (hfi : (∫ t in (0:ℝ)..1,f (circleTurn t))=1) : βˆƒ (a : ℝ) (e : PartialDiffeomorph π“˜(ℝ,CylinderModel) π“˜(ℝ,RealModel) HandleCylinder (Surface m) ∞) (Ξ² : ManifoldOneForm RealModel (Surface m)), a=transverseCylinderWidth m/2 ∧ e=restrictedTransverseCylinder m (transverseCylinderWidth m/2) ∧ 0 Ξ²) ∧ HasCompactSupport Ξ² ∧ (βˆ€ x,manifoldExteriorOneForm Ξ² x=0) ∧ βˆ€ z∈e.source,βˆ€ v : CylinderModel, Ξ² (e z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,RealModel) e z v)= f z.2*circleAngular z.2 v.2 := by let a := transverseCylinderWidth m have ha : 0 e.map_source (hsub hz)) have hp : cylinderFormPeriod 0 (parameterManifoldPullbackOneForm (fun _ : ℝ => compactDualForm m) e) 0=1 := cylinderDualForm_period m 0 obtain ⟨β,L,W,_,_,_,hKW,_,hΞ²,hcp,hcl,_,hn⟩ := exists_compact_annular_dual_normalization e isOpen_Ioo (convex_Ioo (-a) a) he (show (0:ℝ)∈Ioo (-a) a by constructor <;> linarith) hK hKA (compactDualForm_smooth m) (compactDualForm_closed m) (compactDualForm_compact m) hp hf hfi let d := restrictedTransverseCylinder m (a/2) have hd : d.source=Ioo (-(a/2)) (a/2) Γ—Λ’ univ := restrictedTransverseCylinder_source m (by dsimp [a]; linarith [transverseCylinderWidth_pos m]) have hdK : d.targetβŠ†K := by intro x hx obtain ⟨z,hz,hzx⟩ := d.toPartialEquiv.surjOn hx rw [hd] at hz exact ⟨z,⟨⟨by linarith [hz.1.1],hz.1.2.le⟩,hz.2⟩,hzx⟩ refine ⟨a/2,d,Ξ²,rfl,rfl,half_pos ha,hd,hK.of_isClosed_subset isClosed_closure (closure_minimal hdK hK.isClosed),hΞ²,hcp,hcl,?_⟩ intro z hz v have hzK : z∈Icc (-a/2) (a/2) Γ—Λ’ (univ : Set Circle) := by rw [hd] at hz exact ⟨⟨by linarith [hz.1.1],hz.1.2.le⟩,hz.2⟩ exact hn z (hsub hzK) (hKW ⟨z,hzK,rfl⟩) v theorem exists_actual_compact_normalized_dual {f : Circle β†’ ℝ} (hf : ContMDiff π“˜(ℝ,CircleModel) π“˜(ℝ,ℝ) ∞ f) (hfi : (∫ t in (0:ℝ)..1,f (circleTurn t))=1) : βˆƒ (a : ℝ) (e : PartialDiffeomorph π“˜(ℝ,CylinderModel) π“˜(ℝ,RealModel) HandleCylinder (Surface m) ∞) (Ξ² : ManifoldOneForm RealModel (Surface m)), 0 Ξ²) ∧ HasCompactSupport Ξ² ∧ (βˆ€ x,manifoldExteriorOneForm Ξ² x=0) ∧ βˆ€ z∈e.source,βˆ€ v : CylinderModel, Ξ² (e z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,RealModel) e z v)= f z.2*circleAngular z.2 v.2 := by obtain ⟨a,e,Ξ²,_,_,h⟩ := exists_actual_compact_normalized_dual_fixed m hf hfi exact ⟨a,e,Ξ²,h⟩ end PackingSufficiencySupport.DiagonalQuadrics.Explicit namespace PackingSufficiencySupport.Hamiltonian open scoped ContDiff Manifold Topology open Set Function Manifold MeasureTheory variable {E M : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [TopologicalSpace M] [ChartedSpace E M] structure AnnularHandleData (E M : Type*) [NormedAddCommGroup E] [NormedSpace ℝ E] [TopologicalSpace M] [ChartedSpace E M] where width : ℝ width_pos : 0 dual) dual_compact : HasCompactSupport dual dual_closed : βˆ€ x,manifoldExteriorOneForm dual x=0 dual_pullback : βˆ€ z∈chart.source,βˆ€ v : CylinderModel, dual (chart z) (mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,E) chart z v)= clock z.2*circleAngular z.2 v.2 namespace AnnularHandleData def band (b : ℝ) : Set HandleCylinder := Icc (-b) b Γ—Λ’ univ def core (H : AnnularHandleData E M) (b : ℝ) : Set HandleCylinder := Icc (-b) b Γ—Λ’ tsupport H.clock theorem band_compact (b : ℝ) : IsCompact (band b) := isCompact_Icc.prod isCompact_univ theorem core_compact (H : AnnularHandleData E M) (b : ℝ) : IsCompact (H.core b) := isCompact_Icc.prod (isClosed_tsupport H.clock).isCompact theorem core_subset_band (H : AnnularHandleData E M) (b : ℝ) : H.core bβŠ†band b := prod_mono_right (subset_univ _) theorem band_subset_source (H : AnnularHandleData E M) {b : ℝ} (hb : b intervalClock (-b) b z.1) theorem cylinder_fst_smooth : ContMDiff π“˜(ℝ,CylinderModel) π“˜(ℝ,ℝ) ∞ (Prod.fst : HandleCylinder β†’ ℝ) := by rw [show π“˜(ℝ,CylinderModel) = (π“˜(ℝ,ℝ)).prod π“˜(ℝ,CircleModel) from modelWithCornersSelf_prod] exact contMDiff_fst theorem cylinderRadialForm_smooth (b : ℝ) (c : HandleCylinder) : ContDiffOn ℝ ∞ (chartOneForm (cylinderRadialForm b) c) (extChartAt π“˜(ℝ,CylinderModel) c).target := manifoldScalarDifferential_smooth ((intervalClock_smooth (-b) b).contMDiff.comp cylinder_fst_smooth) c theorem cylinderRadialForm_apply (b : ℝ) (z : HandleCylinder) (v : CylinderModel) : cylinderRadialForm b z v=deriv (intervalClock (-b) b) z.1*v.1 := by unfold cylinderRadialForm manifoldScalarDifferential change mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,ℝ) (intervalClock (-b) b ∘ Prod.fst) z v=_ rw [mfderiv_comp z ((intervalClock_smooth (-b) b).contMDiff.mdifferentiableAt (by simp)) (cylinder_fst_smooth.mdifferentiableAt (by simp)),mfderiv_eq_fderiv] have he : mfderiv π“˜(ℝ,CylinderModel) π“˜(ℝ,ℝ) (Prod.fst : HandleCylinder β†’ ℝ) z= ContinuousLinearMap.fst ℝ ℝ CircleModel := by rw [show π“˜(ℝ,CylinderModel) = (π“˜(ℝ,ℝ)).prod π“˜(ℝ,CircleModel) from modelWithCornersSelf_prod] exact mfderiv_fst rw [he] change fderiv ℝ (intervalClock (-b) b) z.1 v.1=_ exact fderiv_eq_deriv_mul theorem cylinderRadialForm_zero {b : ℝ} (hb : 0 hz ⟨hk,mem_univ _⟩ have hd : deriv (intervalClock (-b) b) z.1=0 := by simp only [mem_Icc,not_and_or,not_le] at hn rcases hn with h|h Β· exact intervalClock_deriv_zero_left (by linarith) h Β· exact intervalClock_deriv_zero_right (by linarith) h apply ContinuousLinearMap.ext intro v simp [cylinderRadialForm_apply,hd] theorem cylinderRadialForm_closed (b : ℝ) (z : HandleCylinder) : manifoldExteriorOneForm (cylinderRadialForm b) z=0 := manifoldScalarDifferential_closed ((intervalClock_smooth (-b) b).contMDiff.comp cylinder_fst_smooth) z end PackingSufficiencySupport.Hamiltonian end end OAI