import Lib.DiscreteSeries.Bessel.Basic import New.Spanning.MainTerm.SieveSystem /-! # Bessel systems at a real place: length and norm bounds, lattice basis, discriminant The file sets up the objects that connect the analysis at one real place with the filling argument. `New.Shape.G₁` is the unitary group of a hermitian form made of ϱ hyperbolic planes, a positive space X₀ with basis κ and a vector z with h(z, z) = −1. The frame is (e₁, …, e_ϱ, z). The Bessel subgroup `New.Shape.Form.besselS` is generated by the unipotent group 𝖴 = `New.Shape.Form.besselU` and by `New.Shape.Form.besselH` = U(X₀). `New.frameVector y a` is the image under `y⁻¹` of the `a`-th frame vector. The file first proves elementary bounds on the length `New.besselLength y`, the infimum of `‖s * y‖ + 1` over `s` in `besselS`. It then defines the lattice basis, the discriminant 𝗀 and the link, and the structure `New.BesselSystem` listing what is used of a Bessel function W and its cut W♭. Norms on G₁ are those of the Euclidean norm for which the basis e_a, x_i, z, e*_a is orthonormal. The frame has n = ϱ + 1 vectors. ## Main definitions and results * `New.norm_add_one_le_of_mem_frameBox`: `‖y‖` is bounded by the lengths of `y⁻¹ e_a`, `y⁻¹ z` and `y⁻¹ e*_a`. * `New.orthoFrame`, `New.gramSchmidtMatrix`: Gram–Schmidt for the frame. The orthogonal vectors are left invariant under `besselS` (`New.orthoFrame_besselS_mul`), and the Bessel length bounds their lengths on both sides (`New.norm_orthoFrame_mem_Icc`). The triangular matrix depends continuously on the point (`New.continuous_gramSchmidtMatrix`). * `New.besselLength_le_of_norm_orthoFrame`: conversely, these lengths bound `besselLength y`; the proof corrects `y` on the left until the first bound applies. `New.besselLength_le_of_dual` is the case of a frame with a bounded triangular dual system. * `New.besselLatticeBasis`: the basis of the lattice, in which `x_{k₀}` is replaced by `v = x_{k₀} / p̄ + z / N`. `New.gram_besselLatticeBasis` gives its Gram matrix, with middle block `New.latticeMiddleGram`. * `New.frameDisc`: the quantity `|D_{ϱ+1}|² - N² |D_ϱ|²` in the leading minors `New.leadingMinor`, written `𝗀`. Up to sign it is the Gram determinant of the frame and its image under an isometry (`New.det_gram_framePair`). * `New.IsCutPair`: the L² bounds of W and W♭, the support of W♭, and decay below a common integrable majorant (`New.IsDecayMajorant`). Notions from other files: * `New.Shape.besselFrame`: The indices of the frame (e₁, …, e_ϱ, z) among the basis indices. * `New.Shape.middleGram`: for a scalar N, the diagonal matrix on κ plus one point, with entries 1 on κ and −N at the extra point. ## Relation to the literature References on Bessel functions and kernels are in `New.Spanning.Bessel.FillingData`; references on the decay of discrete series coefficients are in `New.Spanning.Bessel.CutTailBound`. -/ noncomputable section /-! ## Frame vectors and the Bessel length Norms of matrices are `L²` operator norms. -/ section SizeFunction open Matrix Subgroup Norms.L2Operator namespace New variable {𝔰 : Shape} {y s : 𝔰.G₁} (a : Fin (𝔰.ϱ + 1)) /-- For y in G₁, the infimum of ‖sy‖ + 1 (operator norm) over s in the Bessel subgroup S. -/ def besselLength (y : 𝔰.G₁) : ℝ := ⨅ s : besselS, (‖(s.val * y).val.val‖ + 1) lemma besselLength_nonneg (y : 𝔰.G₁) : 0 ≤ besselLength y := Real.iInf_nonneg fun _ ↦ by positivity /-- For real ρ, the set of y in G₁ such that every vector y⁻¹f_a of the moved frame has Euclidean norm at most ρ. -/ def frameBox (ρ : ℝ) : Set 𝔰.G₁ := {y : 𝔰.G₁ | ∀ a : Fin (𝔰.ϱ + 1), ‖frameVector y a‖ ≤ ρ} @[fun_prop] lemma continuous_frameVector : Continuous fun y : 𝔰.G₁ ↦ frameVector y a := by fun_prop [frameVector] /-- The frame vectors at `y` do not change when `y` is multiplied on the left by an element of `besselFixer`, the group of the elements that fix the frame. -/ lemma frameVector_mul_of_mem_besselFixer (hs : s ∈ besselFixer) : frameVector (s * y) = frameVector y := by have h_fix (i : 𝔰.BesselIndex) (a : Fin (𝔰.ϱ + 1)) : (s.val.val)⁻¹ i (𝔰.besselFrame a) = (1 : Matrix _ _ ℂ) i (𝔰.besselFrame a) := by simpa using (inv_mem hs : s⁻¹ ∈ besselFixer) i _ ⟨a, rfl⟩ ext simp [frameVector, mul_apply, h_fix, Matrix.one_apply] /-- For `s` in the unipotent group `New.Shape.Form.besselU`, the frame at `y` is the frame at `s * y` times the matrix `frameMatrix s` of the action of `s` on the frame. -/ lemma frameVector_eq_sum (hs : s ∈ besselU) : frameVector y a = ∑ b : Fin (𝔰.ϱ + 1), frameMatrix s b a • frameVector (s * y) b := by -- `y⁻¹ = (s * y)⁻¹ * s`, and `s` maps the span of the frame to itself by `frameMatrix s`. have h_cols : y⁻¹.val.val.submatrix id 𝔰.besselFrame = (s * y)⁻¹.val.val.submatrix id 𝔰.besselFrame * frameMatrix s := by simpa using submatrix_mul_besselFrame hs (y⁻¹ * s⁻¹).val.val id ext i simpa [frameVector, mul_apply, mul_comm] using congrFun₂ h_cols i a /-- The vector `frameVector y a` = y⁻¹ f_a, where f_a is the `a`-th vector of the frame (e₁, …, e_ϱ, z), is not longer than the operator norm of `y`. -/ lemma norm_frameVector_le : ‖frameVector y a‖ ≤ ‖y.val.val‖ := by -- `y⁻¹` applied to a unit vector has norm at most `‖y⁻¹‖`, and `‖y⁻¹‖ = ‖y‖` in the unitary group -- (`U.norm_inv`). have h_col : frameVector y a = WithLp.toLp 2 (y⁻¹.val.val *ᵥ EuclideanSpace.single (𝔰.besselFrame a) (1 : ℂ)) := by ext i simp [frameVector] rw [← U.norm_inv, h_col] exact (l2_opNorm_mulVec _ _).trans (by simp) /-- The norm of the `i`-th entry of `s` applied to `∑ c a • Pi.single (𝔰.besselFrame (e a)) 1` is at most `‖s * y‖` times the norm of `∑ c a • frameVector y (e a)`. -/ lemma norm_sum_le_mul_norm_sum_frameVector {ι : Type*} [Fintype ι] (e : ι → Fin (𝔰.ϱ + 1)) (c : ι → ℂ) (i : 𝔰.BesselIndex) : ‖∑ a : ι, c a * s.val i (𝔰.besselFrame (e a))‖ ≤ ‖(s * y).val.val‖ * ‖∑ a : ι, c a • frameVector y (e a)‖ := by -- The left side is an entry of `(s * y) *ᵥ ∑ c a • frameVector y (e a)`. grw [← l2_opNorm_mulVec, ← PiLp.norm_apply_le _ i] simp [frameVector, mulVec_sum, mulVec_smul, ← mul_apply, mulVec_apply_eq_sum] lemma besselLength_le_norm_mul_add_one (hs : s ∈ besselS) : besselLength y ≤ ‖(s * y).val.val‖ + 1 := csInf_le ⟨1, Set.forall_mem_range.mpr (by simp)⟩ ⟨⟨s, hs⟩, rfl⟩ -- Keeps definitional checks from unfolding the finite sums. seal Finset.sum in /-- If `besselLength y ≤ T`, then some `u` in the unipotent group `besselU` gives `‖u * y‖ ≤ T` in operator norm. -/ lemma RealPlace.exists_norm_le_of_besselLength_le {T : ℝ} (hT : besselLength y ≤ T) : ∃ u ∈ besselU, ‖(u * y).val.val‖ ≤ T := by -- The infimum gives `s` in `besselS` with `‖s * y‖ + 1 < T + 1`. Write `s⁻¹ = u * embedH w` with -- `u` in `besselU`; then `embedH w * s = u⁻¹`, and `embedH w` does not change the norm. obtain ⟨s, hs⟩ := exists_lt_of_ciInf_lt (hT.trans_lt (lt_add_one T)) obtain ⟨u, hu, w, hs_eq⟩ := exists_besselU_mul_toBesselH s⁻¹.2 isUnit_one have h_inv : embedH w * s.val = u⁻¹ := by simp_all [inv_eq_iff_eq_inv] refine ⟨u⁻¹, inv_mem hu, ?_⟩ rw [← h_inv, mul_assoc, norm_embedH_mul] linarith lemma besselLength_besselS_mul (hs : s ∈ besselS) : besselLength (s * y) = besselLength y := (Equiv.mulRight ⟨s, hs⟩).iInf_congr (by simp [mul_assoc]) /-- The length `besselLength` changes by at most the factor `‖x⁻¹ * y‖` from `x` to `y`. -/ lemma besselLength_le_norm_inv_mul_mul_besselLength (x y : 𝔰.G₁) : besselLength y ≤ ‖(x⁻¹ * y).val.val‖ * besselLength x := by -- `‖s * y‖ ≤ ‖s * x‖ * ‖x⁻¹ * y‖` and `1 ≤ ‖x⁻¹ * y‖`; then take the infimum over `s` have h_bound (s : besselS) : besselLength y ≤ ‖(x⁻¹ * y).val.val‖ * (‖(s.val * x).val.val‖ + 1) := by grw [besselLength_le_norm_mul_add_one s.property, mul_comm, add_mul, ← norm_mul_le, ← U.one_le_norm] simp [mul_assoc] simpa [besselLength.eq_1 x, Real.mul_iInf_of_nonneg] using le_ciInf h_bound /-- The length `besselLength y`, the infimum of `‖s * y‖ + 1` (operator norm) over `s` in the Bessel subgroup `besselS`, is a continuous function of `y` in the unitary group `𝔰.G₁`. -/ @[fun_prop] lemma continuous_besselLength : Continuous (besselLength : 𝔰.G₁ → ℝ) := by -- Squeeze: both bounds below tend to `besselLength y` as `x → y`. refine continuous_iff_continuousAt.2 fun y ↦ ?_ have h_div_le (x : 𝔰.G₁) : besselLength y / ‖(x⁻¹ * y).val.val‖ ≤ besselLength x := (div_le_iff₀' (Units.norm_pos _)).2 (besselLength_le_norm_inv_mul_mul_besselLength x y) have h_lower : ContinuousAt (fun x : 𝔰.G₁ ↦ besselLength y / ‖(x⁻¹ * y).val.val‖) y := by fun_prop (disch := simp) have h_upper : ContinuousAt (fun x : 𝔰.G₁ ↦ ‖(y⁻¹ * x).val.val‖ * besselLength y) y := by fun_prop exact Filter.Tendsto.squeeze (by simpa using h_lower.tendsto) (by simpa using h_upper.tendsto) h_div_le (besselLength_le_norm_inv_mul_mul_besselLength y) end New end SizeFunction /-! ## Norm bounds from a frame and its dual frame * `New.realFrameGram_eq_inner`, `New.realFrameGram_mul_of_mem_besselFixer`, `New.realFrameGram_eq_frameMatrix_mul`, `New.norm_realFrameGram_le_mul`: the Gram matrix `New.realFrameGram` as products of moved frames, its behaviour under `New.Shape.Form.besselU` and `New.Shape.Form.besselFixer`, and a bound on its entries. -/ namespace New open Matrix RealPlace Norms.L2Operator Finset WithLp Subgroup CStarRing InnerProductSpace variable {𝔰 : Shape} (γ y : 𝔰.G₁) (a b : Fin (𝔰.ϱ + 1)) {M : ℝ} /-- The Gram matrix `J₁` of the form has operator norm one. -/ @[local simp] lemma norm_J₁ : ‖𝔰.J₁‖ = 1 := norm_of_mem_unitary IsHermitianInvolution.mem_unitary /-- The operator norm of a matrix is the norm of the sum of the rank-one operators given by its columns. -/ lemma norm_sum_rankOne_col {n : Type} [Fintype n] [DecidableEq n] (Z : Matrix n n ℂ) : ‖∑ j : n, rankOne ℂ (toLp 2 (Z · j)) (PiLp.single 2 j (1 : ℂ))‖ = ‖Z‖ := by rw [l2_opNorm_def] congr 1 ext simp [mulVec_eq_sum, inner] /-- Let `1 ≤ M` and let `y` in `𝔰.G₁` be such that (a) `y` lies in `frameBox M`, that is, the vectors y⁻¹ e_a and y⁻¹ z have length at most `M`, and (b) the vectors y⁻¹ e*_a, the columns of y⁻¹ at the indices `eStar a`, have length at most `M`. Then `‖y‖ + 1 ≤ 8 (ϱ + 1) M`. -/ theorem norm_add_one_le_of_mem_frameBox (h_box : y ∈ frameBox M) (hM_one : 1 ≤ M) (h_dual : ∀ a : Fin 𝔰.ϱ, ‖toLp 2 fun i : 𝔰.BesselIndex ↦ y⁻¹.val i (eStar a)‖ ≤ M) : ‖y.val.val‖ + 1 ≤ 8 * (𝔰.ϱ + 1) * M := by -- The Euclidean product is the form plus `1 - J`, twice the projection on the span of the -- negative vectors `z` and `e_a - e*_a`. With `A = y⁻¹`, `A J A⋆ = J` then gives -- `‖A‖ ^ 2 ≤ 1 + ‖A (1 - J)‖ * ‖A‖`, and `1 ≤ ‖A‖ = ‖y‖`. set A : Matrix 𝔰.BesselIndex 𝔰.BesselIndex ℂ := y⁻¹.val.val with hA have h_inv : y.val.val = 𝔰.J₁ * star A * 𝔰.J₁ := by simpa [A, star_eq_conjTranspose] using U.coe_inv IsHermitianInvolution.mul_self y⁻¹ have h_form : A * (𝔰.J₁ * star A) = 𝔰.J₁ := calc _ = A * y.val.val * 𝔰.J₁ := by simp [h_inv, mul_assoc, IsHermitianInvolution.mul_self] _ = 𝔰.J₁ := by simp [A] have h_one : 1 ≤ ‖A‖ := U.one_le_norm _ -- The columns of `1 - J` are `0`, `2 z` and `± (e_a - e*_a)`. have h_cols : ‖A * (1 - 𝔰.J₁)‖ ≤ (4 * 𝔰.ϱ + 2) * M := by obtain ⟨h_frame, h_last⟩ : (∀ a : Fin 𝔰.ϱ, ‖toLp 2 (A · (.inl a))‖ ≤ M) ∧ ‖toLp 2 (A · 𝔰.z)‖ ≤ M := by simpa [A, frameBox, frameVector, Fin.forall_fin_succ'] using h_box grw [mul_sub, mul_one, ← norm_sum_rankOne_col, norm_sum_le] suffices ∑ a : Fin 𝔰.ϱ, ‖toLp 2 (A · (.inl a)) - toLp 2 (A · (eStar a))‖ + (‖toLp 2 (A · 𝔰.z) + toLp 2 (A · 𝔰.z)‖ + ∑ a : Fin 𝔰.ϱ, ‖toLp 2 (A · (eStar a)) - toLp 2 (A · (.inl a))‖) ≤ (4 * 𝔰.ϱ + 2) * M by simpa [↓norm_rankOne, splitGram, middleGram, mul_apply, one_apply, ← Pi.sub_def, ← Pi.neg_def] grw [norm_sub_le, norm_sub_le, norm_add_le, h_frame, h_frame, h_dual, h_dual, h_last] simp linarith have h_sq : ‖A‖ * ‖A‖ ≤ (1 + (4 * 𝔰.ϱ + 2) * M) * ‖A‖ := calc _ = ‖𝔰.J₁ + A * (1 - 𝔰.J₁) * star A‖ := by simp [← norm_self_mul_star, mul_sub, sub_mul, mul_assoc, h_form] _ ≤ 1 + ‖A * (1 - 𝔰.J₁)‖ * ‖A‖ := by grw [norm_add_le, norm_J₁, norm_mul_le, norm_star] _ ≤ (1 + (4 * 𝔰.ϱ + 2) * M) * ‖A‖ := by nlinarith -- Cancel `‖A‖`; then `1 + (4 ϱ + 2) M + 1 ≤ 8 (ϱ + 1) M` as `M ≥ 1`. grw [← U.norm_inv, ← hA, le_of_mul_le_mul_right h_sq (by linarith)] nlinarith /-- Cauchy–Schwarz for the form `h` with matrix `J₁`: `|h(v, w)| ≤ ‖v‖ * ‖w‖`. -/ lemma norm_inner_J₁_le {v w : EuclideanSpace ℂ 𝔰.BesselIndex} : ‖⟪v, toEuclideanLin 𝔰.J₁ w⟫_ℂ‖ ≤ ‖v‖ * ‖w‖ := by -- The operator norm of `𝔰.J₁` is one. grw [norm_inner_le_norm] gcongr simpa [toLpLin_apply] using 𝔰.J₁.l2_opNorm_mulVec w /-- Let h(v, w) = ⟪v, J₁ w⟫ be the hermitian form with Gram matrix `𝔰.J₁`, `𝔰.G₁` its unitary group and f_a the `a`-th vector of the frame (e₁, …, e_ϱ, z); `frameVector y a` is y⁻¹ f_a. For `γ` and `y` in `𝔰.G₁`, the entry `realFrameGram γ a b` = h(f_a, γ f_b), a complex number, equals h(y⁻¹ f_a, y⁻¹ γ f_b). -/ theorem realFrameGram_eq_inner (γ y : 𝔰.G₁) (a b : Fin (𝔰.ϱ + 1)) : realFrameGram γ a b = ⟪frameVector y a, toEuclideanLin 𝔰.J₁ (frameVector (γ⁻¹ * y) b)⟫_ℂ := by -- `y⁻¹` preserves the form, so `J γ = (y⁻¹)ᴴ J (y⁻¹ γ)`; read off the entry `(a, b)`. have h_entry : realFrameGram γ a b = (y⁻¹.val.valᴴ * (𝔰.J₁ * (y⁻¹.val.val * γ.val.val))) (𝔰.besselFrame a) (𝔰.besselFrame b) := by simp only [← mul_assoc, mem_U.1 y⁻¹.property] rfl rw [h_entry] -- both sides are the same dot product of the two frame vectors exact dotProduct_comm .. /-- For `s` in `besselFixer`, the matrix `New.realFrameGram` is unchanged when `γ` is multiplied by `s` on the left or on the right. -/ theorem realFrameGram_mul_of_mem_besselFixer {s : 𝔰.G₁} (hs : s ∈ besselFixer) : realFrameGram (s * γ) = realFrameGram γ ∧ realFrameGram (γ * s) = realFrameGram γ := by -- Write the entries as inner products of frames; multiplication by `s` fixes frames. constructor <;> ext a b · have h_frame : frameVector s = frameVector (1 : 𝔰.G₁) := by simpa using frameVector_mul_of_mem_besselFixer (y := 1) hs simp [realFrameGram_eq_inner (s * γ) s, realFrameGram_eq_inner γ 1, h_frame, mul_assoc] · rw [realFrameGram_eq_inner (γ * s) 1, realFrameGram_eq_inner γ 1, _root_.mul_inv_rev, mul_assoc, frameVector_mul_of_mem_besselFixer (inv_mem hs)] /-- Let `s` lie in the unipotent subgroup `besselU` of G₁ and act on the frame by the matrix `m = frameMatrix s`. Then the matrix `Z(y) = realFrameGram y` of the products `h(f_a, y f_b)` is `mᴴ Z(s * y)`. -/ theorem realFrameGram_eq_frameMatrix_mul (y : 𝔰.G₁) {s : 𝔰.G₁} (hs : s ∈ besselU) : realFrameGram y = (frameMatrix s)ᴴ * realFrameGram (s * y) := by -- the rule `frameGram_inv_mul_mul` for `s⁻¹ * (s * y) * 1 = y` have h_one : frameMatrix (1 : 𝔰.G₁) = 1 := (mem_besselU0_iff.mp (one_mem _)).2 simpa [h_one, realFrameGram] using frameGram_inv_mul_mul (γ := s * y) hs (one_mem _) /-- The entry `realFrameGram γ a b` = h(f_a, γ f_b) has norm at most the product of the lengths of `frameVector y a` = y⁻¹ f_a and `frameVector (γ⁻¹ * y) b` = y⁻¹ γ f_b. -/ lemma norm_realFrameGram_le_mul : ‖realFrameGram γ a b‖ ≤ ‖frameVector y a‖ * ‖frameVector (γ⁻¹ * y) b‖ := by grw [realFrameGram_eq_inner, norm_inner_J₁_le] /-! ### Gram–Schmidt for the frame -/ /-- Gram–Schmidt gives the same vectors for `v` and `w` if each `v a - w a` is a combination of the `w b` with `b < a`. -/ lemma gramSchmidt_eq_of_sub_mem_span {ι V : Type*} [LinearOrder ι] [LocallyFiniteOrderBot ι] [WellFoundedLT ι] [NormedAddCommGroup V] [InnerProductSpace ℂ V] {v w : ι → V} (h_sub : ∀ a : ι, v a - w a ∈ Submodule.span ℂ (w '' Set.Iio a)) : gramSchmidt ℂ v = gramSchmidt ℂ w := by -- The difference `d` of the two vectors of index `a` lies in the span `B` of the earlier ones, -- which agree by induction, and is orthogonal to `B`. funext a induction a using WellFoundedLT.induction with | ind a ih let B : Submodule ℂ V := .span ℂ (gramSchmidt ℂ w '' Set.Iio a) have h_proj (x : ι → V) (hx : ∀ b < a, gramSchmidt ℂ x b = gramSchmidt ℂ w b) : x a - gramSchmidt ℂ x a ∈ B ∧ gramSchmidt ℂ x a ∈ Bᗮ := by constructor · rw [gramSchmidt_def'' ℂ x a, add_sub_cancel_left] exact B.sum_mem fun b hb ↦ B.smul_mem _ (Submodule.subset_span ⟨b, mem_Iio.1 hb, (hx b (mem_Iio.1 hb)).symm⟩) · suffices h_perp : B ⟂ ℂ ∙ gramSchmidt ℂ x a from h_perp.ge (Submodule.mem_span_singleton_self _) refine Submodule.isOrtho_span.2 ?_ rintro _ ⟨b, hb, rfl⟩ _ rfl rw [← hx b hb] exact gramSchmidt_orthogonal ℂ x (ne_of_lt hb) obtain ⟨hv_span, hv_orth⟩ := h_proj v ih obtain ⟨hw_span, hw_orth⟩ := h_proj w fun _ _ ↦ rfl have h_diff : v a - w a ∈ B := (span_gramSchmidt_Iio ℂ w a).ge (h_sub a) have h_span : gramSchmidt ℂ v a - gramSchmidt ℂ w a ∈ B := by simpa [sub_sub_sub_comm] using B.sub_mem h_diff (B.sub_mem hv_span hw_span) exact sub_eq_zero.1 (inner_self_eq_zero.1 (B.inner_right_of_mem_orthogonal h_span (Bᗮ.sub_mem hv_orth hw_orth))) /-- The vectors obtained from the frame `y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z` by the Gram–Schmidt process for the Euclidean product; they are pairwise orthogonal and are not normalised. -/ noncomputable def orthoFrame : Fin (𝔰.ϱ + 1) → EuclideanSpace ℂ 𝔰.BesselIndex := gramSchmidt ℂ (frameVector y) /-- The upper unitriangular matrix of the coefficients of the frame at `y` in the orthogonal vectors `orthoFrame y`. -/ noncomputable def gramSchmidtMatrix : 𝔰.FrameMatrix := unitriangularMatrix fun p ↦ ⟪orthoFrame y p.1.1, frameVector y p.1.2⟫_ℂ / ‖orthoFrame y p.1.1‖ ^ 2 lemma inner_orthoFrame_eq_zero_of_ne {a b : Fin (𝔰.ϱ + 1)} (hab : a ≠ b) : ⟪orthoFrame y a, orthoFrame y b⟫_ℂ = 0 := gramSchmidt_orthogonal ℂ _ hab /-- The frame at `y` is `orthoFrame y` times the matrix `gramSchmidtMatrix y`. -/ lemma frameVector_eq_sum_orthoFrame : frameVector y b = ∑ a : Fin (𝔰.ϱ + 1), gramSchmidtMatrix y a b • orthoFrame y a := by -- This is the Gram–Schmidt formula; the terms `a ≥ b` of the sum are `orthoFrame y b` and zeros. simpa [gramSchmidtMatrix, unitriangularMatrix, orthoFrame, add_comm (gramSchmidt ..), sum_ite, filter_gt_eq_Iio, filter_filter] using gramSchmidt_def'' ℂ (frameVector y) b /-- There is a `u` in the Bessel unipotent group `besselU` whose submatrix `frameMatrix u` on the rows and columns of the frame is `gramSchmidtMatrix y`, and for which `frameVector (u * y)` is `orthoFrame y`. -/ lemma exists_frameVector_mul_eq_orthoFrame (y : 𝔰.G₁) : ∃ u ∈ besselU, frameMatrix u = gramSchmidtMatrix y ∧ frameVector (u * y) = orthoFrame y := by obtain ⟨u, hu, h_matrix⟩ : ∃ u ∈ besselU, frameMatrix u = gramSchmidtMatrix y := exists_mem_besselU_frameMatrix_eq isUnit_one fun a b hba ↦ by simp [gramSchmidtMatrix, unitriangularMatrix, hba.not_gt, Matrix.one_apply] refine ⟨u, hu, h_matrix, funext fun b ↦ ?_⟩ -- compare the two expansions of `frameVector y b`, by induction on `b` induction b using WellFoundedLT.induction with | ind b ih have h_expansions_eq : ∑ a : Fin (𝔰.ϱ + 1), gramSchmidtMatrix y a b • frameVector (u * y) a = ∑ a : Fin (𝔰.ϱ + 1), gramSchmidtMatrix y a b • orthoFrame y a := by rw [← frameVector_eq_sum_orthoFrame, frameVector_eq_sum b hu, h_matrix] simpa +contextual [ih, gramSchmidtMatrix, unitriangularMatrix, sum_ite] using h_expansions_eq /-- For `y` in the unitary group `𝔰.G₁`, let `orthoFrame y` be the Gram–Schmidt vectors of the moved frame. They do not change when `y` is multiplied on the left by an element `s` of the Bessel subgroup `besselS`, the group of the elements of `𝔰.G₁` that map each vector of the frame (e₁, …, e_ϱ, z) to itself plus a combination of the earlier ones. -/ theorem orthoFrame_besselS_mul (y : 𝔰.G₁) {s : 𝔰.G₁} (hs : s ∈ besselS) : orthoFrame (s * y) = orthoFrame y := by obtain ⟨u, hu, k, rfl⟩ : ∃ u ∈ besselU, ∃ k : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ), s = u * toBesselH 𝔰 1 k := exists_besselU_mul_toBesselH hs isUnit_one have h_fix : frameVector (embedH k * y) = frameVector y := frameVector_mul_of_mem_besselFixer (mem_besselFixer_of_mem_besselH (toBesselH_mem k)) rw [orthoFrame, orthoFrame, ← h_fix, mul_assoc] refine (gramSchmidt_eq_of_sub_mem_span fun a ↦ ?_).symm -- `u` acts on the frame by a unitriangular matrix rw [frameVector_eq_sum a hu, ← add_sum_erase _ _ (mem_univ a), frameMatrix_unitriangular hu a a le_rfl, one_apply_eq, one_smul, add_sub_cancel_left] refine Submodule.sum_mem _ fun b hb ↦ ?_ obtain hba | hab := (ne_of_mem_erase hb).lt_or_gt · exact Submodule.smul_mem _ _ (Submodule.subset_span ⟨b, hba, rfl⟩) · simp [frameMatrix_unitriangular hu b a hab.le, hab.ne'] /-- A Gram–Schmidt vector `orthoFrame y a` is not longer than the vector `frameVector y a` of the moved frame (y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z) from which it comes. -/ lemma norm_orthoFrame_le : ‖orthoFrame y a‖ ≤ ‖frameVector y a‖ := by -- `‖f‖ ^ 2 = ⟪f, y⁻¹ f_a⟫` for `f = orthoFrame y a`, by orthogonality have h_inner : ⟪orthoFrame y a, frameVector y a⟫_ℂ = ‖orthoFrame y a‖ ^ 2 := by rw [frameVector_eq_sum_orthoFrame, inner_sum, sum_eq_single a _ (by simp)] · simp [gramSchmidtMatrix, unitriangularMatrix] · simp +contextual [inner_smul_right, inner_orthoFrame_eq_zero_of_ne y (Ne.symm _)] have h_sq : ‖orthoFrame y a‖ * ‖orthoFrame y a‖ ≤ ‖orthoFrame y a‖ * ‖frameVector y a‖ := by simpa [h_inner, sq] using norm_inner_le_norm (𝕜 := ℂ) (orthoFrame y a) (frameVector y a) nlinarith [norm_nonneg (orthoFrame y a), norm_nonneg (frameVector y a)] /-- The Gram–Schmidt vectors `orthoFrame y a` of the moved frame (y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z) have length at least `‖y‖⁻¹`, with the operator norm of `y`. -/ lemma one_le_norm_mul_norm_orthoFrame : 1 ≤ ‖y.val.val‖ * ‖orthoFrame y a‖ := by -- `y` maps `orthoFrame y a` to the frame vector `f_a` plus a combination of the earlier ones obtain ⟨u, hu, -, h_frame⟩ : ∃ u ∈ besselU, frameMatrix u = gramSchmidtMatrix y ∧ frameVector (u * y) = orthoFrame y := exists_frameVector_mul_eq_orthoFrame y have h_expand : orthoFrame y a = ∑ b, frameMatrix u⁻¹ b a • frameVector y b := by rw [← h_frame, frameVector_eq_sum a (inv_mem hu), inv_mul_cancel_left] have h_entry : ‖frameMatrix u⁻¹ a a‖ ≤ ‖y.val.val‖ * ‖orthoFrame y a‖ := by simpa [← h_expand, one_apply, besselFrame_injective.eq_iff] using norm_sum_le_mul_norm_sum_frameVector (s := 1) (y := y) id (frameMatrix u⁻¹ · a) (𝔰.besselFrame a) simpa [frameMatrix_unitriangular (inv_mem hu) a a le_rfl] using h_entry lemma orthoFrame_ne_zero : orthoFrame y a ≠ 0 := fun h_zero ↦ zero_lt_one.not_ge (by simpa [h_zero] using one_le_norm_mul_norm_orthoFrame y a) /-- If `besselLength y`, the infimum of ‖s y‖ + 1 over `s` in the Bessel subgroup `besselS`, is at most `M`, the Gram–Schmidt vectors `orthoFrame y a` of the moved frame (y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z) have length between `M⁻¹` and `M`. -/ theorem norm_orthoFrame_mem_Icc (h_size : besselLength y ≤ M) : ‖orthoFrame y a‖ ∈ Set.Icc M⁻¹ M := by obtain ⟨u, hu, h_norm⟩ : ∃ u ∈ besselU, ‖(u * y).val.val‖ ≤ M := exists_norm_le_of_besselLength_le h_size rw [← orthoFrame_besselS_mul y (mem_partialUnitriangularGroup_of_mem_besselU hu)] have hM : 0 < M := (Units.norm_pos _).trans_le h_norm constructor · grw [inv_le_iff_one_le_mul₀' hM, ← h_norm, ← one_le_norm_mul_norm_orthoFrame] · grw [norm_orthoFrame_le, norm_frameVector_le, h_norm] lemma linearIndependent_orthoFrame : LinearIndependent ℂ (orthoFrame y) := linearIndependent_of_ne_zero_of_inner_eq_zero (orthoFrame_ne_zero y) fun _ _ ↦ inner_orthoFrame_eq_zero_of_ne y /-- For `y` in the unitary group `𝔰.G₁`, let `gramSchmidtMatrix y` be the unitriangular matrix of the moved frame in its Gram–Schmidt vectors. Let `s` lie in the Bessel subgroup `besselS`, the group of the elements of `𝔰.G₁` that map each vector of the frame (e₁, …, e_ϱ, z) to itself plus a combination of the earlier ones, and let `frameMatrix s` be the submatrix of `s` on the rows and columns of the frame. Then `gramSchmidtMatrix y` is `gramSchmidtMatrix (s * y)` times `frameMatrix s`. -/ theorem gramSchmidtMatrix_besselS_mul (y : 𝔰.G₁) {s : 𝔰.G₁} (hs : s ∈ besselS) : gramSchmidtMatrix (s * y) * frameMatrix s = gramSchmidtMatrix y := by -- Both matrices express the frame at `y` in the same orthogonal family of nonzero vectors. have h_orth : orthoFrame (s * y) = orthoFrame y := orthoFrame_besselS_mul y hs obtain ⟨u, hu, k, rfl⟩ : ∃ u ∈ besselU, ∃ k : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ), s = u * toBesselH 𝔰 1 k := exists_besselU_mul_toBesselH hs isUnit_one have h_fix : frameVector (embedH k * y) = frameVector y := frameVector_mul_of_mem_besselFixer (mem_besselFixer_of_mem_besselH (toBesselH_mem k)) set C : 𝔰.FrameMatrix := gramSchmidtMatrix (u * toBesselH 𝔰 1 k * y) * frameMatrix (u * toBesselH 𝔰 1 k) with hC have h_same_expansion (b : Fin (𝔰.ϱ + 1)) : ∑ a : Fin (𝔰.ϱ + 1), C a b • orthoFrame y a = ∑ a : Fin (𝔰.ϱ + 1), gramSchmidtMatrix y a b • orthoFrame y a := by rw [← frameVector_eq_sum_orthoFrame, ← h_fix, frameVector_eq_sum b hu, ← mul_assoc, hC, frameMatrix_mul_besselH u (toBesselH_mem k)] simp only [frameVector_eq_sum_orthoFrame, h_orth, mul_apply, sum_smul, smul_sum, smul_smul, mul_comm] exact sum_comm ext a b exact Fintype.linearIndependent_iffₛ.1 (linearIndependent_orthoFrame y) (C · b) (gramSchmidtMatrix y · b) (h_same_expansion b) a /-- The Gram–Schmidt vectors `orthoFrame y a` of the moved frame (y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z) depend continuously on `y` in the unitary group `𝔰.G₁`. -/ lemma continuous_orthoFrame : Continuous fun y : 𝔰.G₁ ↦ orthoFrame y a := by -- Induction along the Gram–Schmidt recursion, which divides only by nonzero lengths. induction a using WellFoundedLT.induction with | ind a ih have h_step (y : 𝔰.G₁) : orthoFrame y a = frameVector y a - ∑ i ∈ Iio a, (⟪orthoFrame y i, frameVector y a⟫_ℂ / ‖orthoFrame y i‖ ^ 2) • orthoFrame y i := eq_sub_of_add_eq (gramSchmidt_def'' ℂ (frameVector y) a).symm rw [funext h_step] refine (continuous_frameVector a).sub (continuous_finsetSum _ fun i hi ↦ ?_) have := ih i (mem_Iio.1 hi) fun_prop (disch := simp [orthoFrame_ne_zero]) lemma continuous_gramSchmidtMatrix : Continuous (gramSchmidtMatrix : 𝔰.G₁ → 𝔰.FrameMatrix) := by refine continuous_unitriangularMatrix.comp (continuous_pi fun p ↦ ?_) have := continuous_orthoFrame (𝔰 := 𝔰) p.val.1 fun_prop (disch := simp [orthoFrame_ne_zero]) lemma measurable_gramSchmidtMatrix : Measurable fun y : 𝔰.G₁ ↦ gramSchmidtMatrix y a b := (continuous_gramSchmidtMatrix.matrix_elem a b).measurable /-- If `1 ≤ M` and the vectors `orthoFrame y a` have Euclidean length between `M⁻¹` and `M`, then `besselLength y ≤ 8 (ϱ + 1) M`. -/ theorem besselLength_le_of_norm_orthoFrame (y : 𝔰.G₁) {M : ℝ} (hM : 1 ≤ M) (h_len : ∀ a : Fin (𝔰.ϱ + 1), ‖orthoFrame y a‖ ∈ Set.Icc M⁻¹ M) : besselLength y ≤ 8 * (𝔰.ϱ + 1) * M := by -- Make the frame orthogonal by some `u` in `besselU`, with vectors `f a`. The dual frame -- `J (f a) / ‖f a‖ ^ 2` is the image of `(e*_a)` under `(u * y)⁻¹ * unipotentOf q` for some `q`, -- so `norm_add_one_le_of_mem_frameBox` bounds `(unipotentOf q)⁻¹ * u * y`. obtain ⟨u, hu, -, h_frame⟩ : ∃ u ∈ besselU, frameMatrix u = gramSchmidtMatrix y ∧ frameVector (u * y) = orthoFrame y := exists_frameVector_mul_eq_orthoFrame y have h_orth {a b : Fin (𝔰.ϱ + 1)} (hab : a ≠ b) : ⟪orthoFrame y a, orthoFrame y b⟫_ℂ = 0 := inner_orthoFrame_eq_zero_of_ne y hab generalize orthoFrame y = f at h_frame h_orth h_len have hM_pos : 0 < M := one_pos.trans_le hM have h_pos (a : Fin (𝔰.ϱ + 1)) : 0 < ‖f a‖ := (inv_pos.2 hM_pos).trans_le (h_len a).1 -- The vectors `J (v a)` are isotropic and dual to the frame `f`. let v (a : Fin 𝔰.ϱ) : EuclideanSpace ℂ 𝔰.BesselIndex := ‖f a.castSucc‖⁻¹ ^ 2 • f a.castSucc have hv_dual (a : Fin (𝔰.ϱ + 1)) (b : Fin 𝔰.ϱ) : ⟪frameVector (u * y) a, v b⟫_ℂ = if a = b.castSucc then 1 else 0 := by split_ifs with hab <;> simp [v, h_frame, hab, h_orth, norm_pos_iff.1 (h_pos _)] have hv_iso (a b : Fin 𝔰.ϱ) : ⟪v b, toEuclideanLin 𝔰.J₁ (v a)⟫_ℂ = 0 := by -- the `f a` are the image of the frame under an isometry, and the `e_a` span an isotropic space have h_zero : realFrameGram (1 : 𝔰.G₁) b.castSucc a.castSucc = 0 := by simp [frameGram] have h_iso : ⟪f b.castSucc, toEuclideanLin 𝔰.J₁ (f a.castSucc)⟫_ℂ = 0 := by simpa [realFrameGram_eq_inner 1 (u * y), h_frame] using h_zero simp [v, h_iso] -- such a system is the image of `(e*_a)` under `(u * y)⁻¹ * unipotentOf q` for some `q` let B : Matrix 𝔰.BesselIndex (Fin 𝔰.ϱ) ℂ := 𝔰.J₁ * (of fun a i ↦ v a i)ᵀ have h_dual_cols : ((u * y)⁻¹.val.val * 𝔰.frameCols)ᴴ * 𝔰.J₁ * B = inclMatrix ℂ Fin.castSucc := by ext a b -- the entry is the product of `frameVector (u * y) a` and `v b` simp only [B, Matrix.mul_assoc, mul_mul_eq_of_mul_eq IsHermitianInvolution.mul_self, Matrix.one_mul, mul_inclMatrix] exact (dotProduct_comm ..).trans (hv_dual a b) have h_isotropic : Bᴴ * 𝔰.J₁ * B = 0 := by ext a b simp only [B, Matrix.mul_assoc, mul_mul_eq_of_mul_eq IsHermitianInvolution.mul_self, Matrix.one_mul] exact (dotProduct_comm ..).trans (inner_eq_zero_symm.1 (hv_iso a b)) obtain ⟨q, hq⟩ : ∃ q : 𝔰.UnipotentParams, ((u * y)⁻¹ * unipotentOf q).val.val * 𝔰.dualCols = B := exists_mul_unipotentOf_dualCols_eq h_dual_cols h_isotropic have h_mem : (unipotentOf q)⁻¹ ∈ besselU0 := inv_mem (unipotentOf_mem_besselU0 q) have h_box : (unipotentOf q)⁻¹ * (u * y) ∈ frameBox M := fun a ↦ by simpa [frameVector_mul_of_mem_besselFixer (mem_besselFixer_of_mem_besselU0 h_mem), h_frame] using (h_len a).2 have h_norm : ‖((unipotentOf q)⁻¹ * (u * y)).val.val‖ + 1 ≤ 8 * (𝔰.ϱ + 1) * M := by refine norm_add_one_le_of_mem_frameBox _ h_box hM fun j ↦ ?_ -- the column is `J (v j)`, of length `‖f j‖⁻¹ ≤ M` have h_col (i : 𝔰.BesselIndex) : ((u * y)⁻¹ * unipotentOf q).val i (eStar j) = (𝔰.J₁ *ᵥ v j) i := by rw [mul_inclMatrix] at hq exact congrFun₂ hq i j calc _ = ‖toLp 2 (𝔰.J₁ *ᵥ v j)‖ := by rw [← funext h_col, _root_.mul_inv_rev, inv_inv] _ ≤ ‖𝔰.J₁‖ * ‖v j‖ := l2_opNorm_mulVec _ _ _ = ‖f j.castSucc‖⁻¹ := by simp [v, norm_smul, field] _ ≤ M := inv_le_of_inv_le₀ hM_pos (h_len _).1 grw [besselLength_le_norm_mul_add_one (mem_partialUnitriangularGroup_of_mem_besselU (mul_mem (mem_besselU0_iff.1 h_mem).1 hu)), mul_assoc, h_norm] /-- A bounded frame with a bounded triangular dual has bounded length. Let h(v, w) = ⟪v, J₁ w⟫ be the hermitian form with Gram matrix `𝔰.J₁`, made of ϱ hyperbolic planes (e_a, e*_a), a positive space and a vector z with h(z, z) = −1, and let `y` lie in its unitary group `𝔰.G₁`. Let `1 ≤ M` and let `V` be a sequence of vectors with: (a) `V 0, …, V ϱ` is the moved frame `frameVector y` = (y⁻¹ e₁, …, y⁻¹ e_ϱ, y⁻¹ z); (b) `‖V a‖ ≤ M` for `a ≤ 2 ϱ`; (c) `h(V a, V b)` is `-1` if `a + b = 2 ϱ` and `0` if `a + b < 2 ϱ`. Then `besselLength y`, the infimum of ‖s y‖ + 1 (operator norm) over `s` in the Bessel subgroup `besselS`, is at most `8 (ϱ + 1) M`. -/ theorem besselLength_le_of_dual (hM : 1 ≤ M) (V : ℕ → EuclideanSpace ℂ 𝔰.BesselIndex) (hV_frame : ∀ a : Fin (𝔰.ϱ + 1), frameVector y a = V a) (h_len : ∀ a ≤ 2 * 𝔰.ϱ, ‖V a‖ ≤ M) (h_dual : ∀ a b : ℕ, a + b ≤ 2 * 𝔰.ϱ → ⟪V a, toEuclideanLin 𝔰.J₁ (V b)⟫_ℂ = if a + b = 2 * 𝔰.ϱ then -1 else 0) : besselLength y ≤ 8 * (𝔰.ϱ + 1) * M := by -- The orthogonal vector `orthoFrame y a` is `V a` plus a combination of the `V b`, `b < a`, -- orthogonal to these. So it is not longer than `V a`, and it still pairs to `-1` with -- `V (2 ϱ - a)`. refine besselLength_le_of_norm_orthoFrame y hM fun a ↦ ⟨?_, ?_⟩ · obtain ⟨u, hu, -, h_frame⟩ := exists_frameVector_mul_eq_orthoFrame y have h_pair : ⟪V (2 * 𝔰.ϱ - a.val), toEuclideanLin 𝔰.J₁ (orthoFrame y a)⟫_ℂ = -1 := by -- expand in the frame at `y`: terms after `a` vanish by unitriangularity, earlier by `h_dual` rw [← h_frame, frameVector_eq_sum a (inv_mem hu), inv_mul_cancel_left, map_sum, inner_sum, sum_eq_single a] · simp (disch := omega) [frameMatrix_unitriangular (inv_mem hu) a a le_rfl, hV_frame, h_dual] · intro b _ hb obtain hba | hab := hb.lt_or_gt · simp (disch := omega) [inner_smul_right, hV_frame, h_dual, ite_eq_right] · simp [frameMatrix_unitriangular (inv_mem hu) b a hab.le, hab.ne'] · simp rw [inv_le_iff_one_le_mul₀' (one_pos.trans_le hM)] calc 1 = ‖⟪V (2 * 𝔰.ϱ - a.val), toEuclideanLin 𝔰.J₁ (orthoFrame y a)⟫_ℂ‖ := by simp [h_pair] _ ≤ ‖V (2 * 𝔰.ϱ - a.val)‖ * ‖orthoFrame y a‖ := norm_inner_J₁_le _ ≤ M * ‖orthoFrame y a‖ := by grw [h_len _ (by lia)] · grw [norm_orthoFrame_le, hV_frame, h_len a (by lia)] end New namespace New /-! ## Lattice basis, Gram matrix, link and the discriminant 𝗀 The space has the basis `e_a`; `x_i`, `z`; `e*_a` (indices `𝔰.BesselIndex`) and the Gram matrix `T.splitGram`, which pairs `e_a` with `e*_a` and is `T` on the middle block. * `New.link`: the relation on `X^⊥/X` defined by an isometry, built from the matrix `New.linkMatrix`. -/ section LinkDefs open Matrix Fin Filling variable {R : Type*} [CommRing R] (𝔰 : Shape) [StarRing R] (p : Rˣ) (N : R) /-- For a scalar N, the matrix with diagonal 1 at the x_i (i ≠ k₀), 0 at v and −N at z, and entries −1 at (v, z) and (z, v). If N = p p̄, it is the Gram matrix of X₀ ⊕ Ez in the basis x_i (i ≠ k₀), v, z, where v = x_{k₀}/p̄ + z/N (`New.gram_besselLatticeBasis`). -/ def latticeMiddleGram : 𝔰.Form R := let c : Matrix 𝔰.κ Unit R := of fun i _ ↦ if i = 𝔰.k₀ then -1 else 0 (scaleAt 0 𝔰.k₀).fromBlocks c cᵀ (of fun _ _ ↦ -N) /-- The matrix whose columns are the orthonormal basis vectors x_i of X₀ in the lattice basis (x_i for i ≠ k₀, v, z), where v = x_{k₀}/p̄ + z/(p p̄). -/ def middleInclusionMatrix : Matrix (𝔰.κ ⊕ Unit) 𝔰.κ R := fromRows (scaleAt (star p.1) 𝔰.k₀) (of fun () j ↦ if j = 𝔰.k₀ then -p⁻¹ else 0) /-- With the column of z appended, the inclusion matrix `middleInclusionMatrix` from the x_i to the lattice basis is block lower triangular: `scaleAt p̄ k₀` (diagonal, p̄ at k₀ and 1 elsewhere), `1`, and the single entry `-p⁻¹` below the diagonal. -/ lemma fromCols_middleInclusionMatrix (p : Rˣ) : fromCols (middleInclusionMatrix 𝔰 p) (fromRows 0 (1 : Matrix Unit Unit R)) = fromBlocks (scaleAt (star (p : R)) 𝔰.k₀) 0 (of fun (_ : Unit) (j : 𝔰.κ) ↦ if j = 𝔰.k₀ then -(↑p⁻¹ : R) else 0) (1 : Matrix Unit Unit R) := by ext (i | i) (j | j) <;> simp [middleInclusionMatrix] omit [StarRing R] in /-- Two block lower triangular matrices that scale the distinguished coordinate `k₀` of κ by `a`, `a'` and carry it to the last coordinate by `c`, `c'` multiply to `1` if `a * a' = 1` and `c * a' + c' = 0`. -/ lemma fromBlocks_scaleAt_mul_eq_one {a a' c c' : R} (ha : a * a' = 1) (hc : c * a' + c' = 0) : fromBlocks (scaleAt a 𝔰.k₀) 0 (of fun (_ : Unit) (j : 𝔰.κ) ↦ if j = 𝔰.k₀ then c else 0) (1 : Matrix Unit Unit R) * fromBlocks (scaleAt a' 𝔰.k₀) 0 (of fun (_ : Unit) (j : 𝔰.κ) ↦ if j = 𝔰.k₀ then c' else 0) (1 : Matrix Unit Unit R) = 1 := by rw [fromBlocks_multiply, ← fromBlocks_one] congr 1 <;> ext i j <;> simp [Matrix.mul_apply, diagonal, Matrix.one_apply] <;> grind omit [StarRing R] in /-- Two matrices that are the identity outside the middle block, where they are inverse to each other, multiply to `1`. -/ lemma fromBlocks_one_mul_eq_one {X Y : Matrix (𝔰.κ ⊕ Unit) (𝔰.κ ⊕ Unit) R} (hXY : X * Y = 1) : fromBlocks 1 0 0 (fromBlocks X 0 0 1) * fromBlocks 1 0 0 (fromBlocks Y 0 0 1) = (1 : Matrix 𝔰.BesselIndex 𝔰.BesselIndex R) := by simp [fromBlocks_multiply, hXY] /-- The invertible matrix whose columns are the lattice basis (e_a; x_i for i ≠ k₀, v, z; e*_a), v = x_{k₀}/p̄ + z/(p p̄), in the standard basis. -/ def besselLatticeBasis : GL 𝔰.BesselIndex R where -- Both matrices are the identity on the `e_a` and `e*_a`; only the middle block is not trivial. val := fromBlocks 1 0 0 (fromBlocks (fromBlocks (scaleAt (star p⁻¹.1) 𝔰.k₀) 0 (of fun _ j ↦ if j = 𝔰.k₀ then ↑(p * star p)⁻¹ else 0) 1) 0 0 1) inv := fromBlocks 1 0 0 (fromBlocks (fromCols (middleInclusionMatrix 𝔰 p) (fromRows 0 1)) 0 0 1) val_inv := by rw [fromCols_middleInclusionMatrix] refine fromBlocks_one_mul_eq_one 𝔰 (fromBlocks_scaleAt_mul_eq_one 𝔰 ?_ ?_) · simp [← star_mul] · simp [mul_right_comm _ (↑p⁻¹ : R), ← star_mul] inv_val := by rw [fromCols_middleInclusionMatrix] refine fromBlocks_one_mul_eq_one 𝔰 (fromBlocks_scaleAt_mul_eq_one 𝔰 ?_ ?_) · simp [← star_mul] · simp [mul_comm (star (↑p⁻¹ : R))] variable {𝔰} {T : 𝔰.Form R} (γ : T.G) /-- For Z of size ϱ+1 with leading minors D_l, the quantity |D_{ϱ+1}|² − N²|D_ϱ|², where |x|² means x x̄. -/ def frameDisc (N : R) (Z : Matrix (Fin (𝔰.ϱ + 1)) (Fin (𝔰.ϱ + 1)) R) : R := let d : R := leadingMinor Z 𝔰.top.castSucc Z.det * star Z.det - N ^ 2 * (d * star d) /-- For a matrix T on the middle indices (x_i; z), `T.splitGram` is the Gram matrix in the basis (e_a; x_i, z; e*_a) of the form that is T on the middle block and pairs e_a with e*_a as hyperbolic planes. Let p be a unit and N = p p̄, and take T = `𝔰.middleGram N` = diag(1, …, 1, −N). The columns of `besselLatticeBasis 𝔰 p` are the basis in which x_{k₀} is replaced by v = x_{k₀}/p̄ + z/N. Its Gram matrix has the same shape, with middle block `latticeMiddleGram 𝔰 N`: diagonal 1 at the x_i (i ≠ k₀), 0 at v and −N at z, entries −1 at (v, z) and (z, v), and zero elsewhere. -/ lemma gram_besselLatticeBasis (p : Rˣ) (N : R) (hN : p * star ↑p = N) : (besselLatticeBasis 𝔰 p).valᴴ * (𝔰.middleGram N).splitGram * besselLatticeBasis 𝔰 p = (latticeMiddleGram 𝔰 N).splitGram := by subst hN have h_norm : (p : R) * star ↑p * (star (↑p⁻¹ : R) * ↑p⁻¹) = 1 := by grind [p.mul_inv, star_mul, star_one] let A : Matrix 𝔰.MiddleIndex 𝔰.MiddleIndex R := fromBlocks (scaleAt (star (↑p⁻¹ : R)) 𝔰.k₀) 0 (of fun _ j ↦ if j = 𝔰.k₀ then ↑(p * star p)⁻¹ else 0) 1 -- Outside the middle block the basis is standard. In it, the entries away from `k₀` agree at -- once and those at `k₀` follow from `h_norm`. have h_mid : Aᴴ * 𝔰.middleGram ((p : R) * star ↑p) * A = latticeMiddleGram 𝔰 ((p : R) * star ↑p) := by ext (i | i) (j | j) <;> simp [A, Shape.middleGram, latticeMiddleGram, diagonal, fromBlocks_conjTranspose, fromBlocks_multiply, Matrix.mul_apply] <;> grind [star_star, star_mul, star_one, star_zero] -- uses `h_norm` at the entries of `k₀` have h_basis : (besselLatticeBasis 𝔰 p).val = fromBlocks 1 0 0 (fromBlocks A 0 0 1) := rfl simp [h_basis, Shape.Form.splitGram, Floors.hyperbolicGram, fromBlocks_conjTranspose, fromBlocks_multiply, fromBlocks_mul_fromRows, fromCols_mul_fromBlocks, ← h_mid] /-- For γ in the unitary group, the matrix (f | γf) of the frame f and its image under γ, side by side. -/ abbrev framePair : Matrix 𝔰.BesselIndex (Fin (𝔰.ϱ + 1) ⊕ Fin (𝔰.ϱ + 1)) R := (frameImage 1).fromCols (frameImage γ.val.val) /-- The matrix with columns e₁, …, e_ϱ, γe₁, …, γe_ϱ. -/ abbrev isotropicFramePair : Matrix 𝔰.BesselIndex (Fin 𝔰.ϱ ⊕ Fin 𝔰.ϱ) R := (framePair γ).submatrix id (Sum.map castSucc castSucc) /-! ### The Gram determinant of two frames -/ /-- The determinant of a square matrix whose row `i` is the sum of the rows `i` of two matrices that agree with it in all other rows is the sum of their determinants. -/ lemma det_eq_add_of_row_eq_add {R m : Type*} [CommRing R] [Fintype m] [DecidableEq m] {A B C : Matrix m m R} (i : m) (h_row : A i = B i + C i) (hB : ∀ j ≠ i, B j = A j) (hC : ∀ j ≠ i, C j = A j) : A.det = B.det + C.det := by have h_update (X : Matrix m m R) (hX : ∀ j ≠ i, X j = A j) : A.updateRow i (X i) = X := by ext j k by_cases hj : j = i <;> simp [updateRow_apply, hj, hX] conv_lhs => rw [← updateRow_eq_self A i, h_row, det_updateRow_add, h_update B hB, h_update C hC] omit [StarRing R] in /-- For square matrices `Z`, `W` and a scalar `c`, the block matrix `fromBlocks Z (single i i c) (single i i c) W` (off-diagonal blocks have the single entry `c` at `(i, i)`) has determinant `Z.det * W.det - c ^ 2 * (Z.adjugate i i * W.adjugate i i)`. -/ lemma det_fromBlocks_single {n : Type*} [Fintype n] [DecidableEq n] (Z W : Matrix n n R) (i : n) (c : R) : (fromBlocks Z (single i i c) (single i i c) W).det = Z.det * W.det - c ^ 2 * (Z.adjugate i i * W.adjugate i i) := by let C : Matrix n n R := single i i c have h_zero (X : Matrix n n R) : (X.updateRow i 0).det = 0 := det_eq_zero_of_row_eq_zero i (by simp) have h_minor (X : Matrix n n R) : (X.updateRow i (Pi.single i c)).det = c * X.adjugate i i := by simp [adjugate_apply, ← det_updateRow_smul, ← Pi.single_smul'] -- split the row `inl i`, and then the row `inr i` have h_split_inl : (fromBlocks Z C C W).det = (fromBlocks Z 0 C W).det + (fromBlocks (Z.updateRow i 0) C C W).det := by refine det_eq_add_of_row_eq_add (.inl i) (by ext (b | b) <;> simp [C, updateRow_apply]) ?_ ?_ all_goals rintro (a | a) ha <;> ext (b | b) <;> simp_all [C, updateRow_apply, single_apply, eq_comm] have h_split_inr : (fromBlocks (Z.updateRow i 0) C C W).det = (fromBlocks (Z.updateRow i 0) C 0 W).det + (fromBlocks (Z.updateRow i 0) C C (W.updateRow i 0)).det := by refine det_eq_add_of_row_eq_add (.inr i) (by ext (b | b) <;> simp [C, updateRow_apply]) ?_ ?_ all_goals rintro (a | a) ha <;> ext (b | b) <;> simp_all [C, updateRow_apply, single_apply, eq_comm] -- in the last term exchange the two rows have h_swap : fromBlocks (Z.updateRow i 0) C C (W.updateRow i 0) = (fromBlocks (Z.updateRow i (Pi.single i c)) 0 0 (W.updateRow i (Pi.single i c))).submatrix (Equiv.swap (.inl i) (.inr i)) id := by ext (a | a) (b | b) <;> by_cases ha : a = i <;> simp [C, updateRow_apply, single_apply, Pi.single_apply, ha, eq_comm (a := i), Equiv.swap_apply_of_ne_of_ne] rw [h_split_inl, h_split_inr, h_swap, det_permute, Equiv.Perm.sign_swap Sum.inl_ne_inr, det_fromBlocks_zero₁₂, det_fromBlocks_zero₂₁, det_fromBlocks_zero₂₁, h_zero, h_minor, h_minor] push_cast ring /-- Let `N` be self-adjoint in the commutative star ring `R`, let h be the form of ϱ hyperbolic planes and the middle block diag(1, …, 1, −N), and let `γ` be an isometry of h. The Gram matrix of the frame f = (e₁, …, e_ϱ, z) and its image γf, side by side in `framePair γ`, has both diagonal blocks zero except for the entry −N at `𝔰.top`, the position of z. The other two blocks are the matrix `frameGram γ` of the products h(f_a, γ f_b) and its adjoint. -/ lemma gram_framePair (N : R) (hN : star N = N) (γ : (𝔰.middleGram N).G) : (framePair γ)ᴴ * (𝔰.middleGram N).splitGram * framePair γ = fromBlocks (single 𝔰.top 𝔰.top (-N)) ((𝔰.middleGram N).frameGram γ) ((𝔰.middleGram N).frameGram γ)ᴴ (single 𝔰.top 𝔰.top (-N)) := by have h_frame : (𝔰.middleGram N).splitGram.submatrix 𝔰.besselFrame 𝔰.besselFrame = single 𝔰.top 𝔰.top (-N) := by ext a b cases a using lastCases <;> cases b using lastCases <;> simp [Shape.besselFrame, Shape.Form.splitGram, Shape.middleGram, (castSucc_ne_last _).symm] have h_herm : (𝔰.middleGram N).splitGramᴴ = (𝔰.middleGram N).splitGram := by simp [Shape.Form.splitGram, Shape.middleGram, ← Matrix.ext_iff, hN, one_apply, apply_ite star, eq_comm] have h_block (x y : Matrix 𝔰.BesselIndex 𝔰.BesselIndex R) : (frameImage x)ᴴ * (𝔰.middleGram N).splitGram * frameImage y = (xᴴ * (𝔰.middleGram N).splitGram * y).submatrix 𝔰.besselFrame 𝔰.besselFrame := rfl rw [conjTranspose_fromCols_eq_fromRows_conjTranspose, fromRows_mul, fromRows_mul_fromCols, h_block, h_block, h_block, h_block, mem_U.1 γ.property] simp [h_frame, h_herm, Shape.Form.frameGram] /-- Let `N` be self-adjoint in the commutative star ring `R`, let h be the form of ϱ hyperbolic planes and the middle block diag(1, …, 1, −N), and let `γ` be an isometry of h. The columns of `framePair γ` are the frame f = (e₁, …, e_ϱ, z), which has `𝔰.n` = ϱ + 1 vectors, and its image γf. Let Z be the matrix `frameGram γ` of the products h(f_a, γ f_b), and D_ϱ its leading minor of order ϱ. The Gram determinant of `framePair γ` is `(-1) ^ 𝔰.n` times `frameDisc N Z` = |det Z|² − N²|D_ϱ|². -/ theorem det_gram_framePair (N : R) (hN : star N = N) (γ : (𝔰.middleGram N).G) : ((framePair γ)ᴴ * (𝔰.middleGram N).splitGram * framePair γ).det = (-1) ^ 𝔰.n * frameDisc N ((𝔰.middleGram N).frameGram γ) := by -- The Gram matrix is a block matrix with off-diagonal blocks `single top top (-N)`, times the -- exchange of the two frames: apply `det_fromBlocks_single`. set Z : Matrix (Fin (𝔰.ϱ + 1)) (Fin (𝔰.ϱ + 1)) R := (𝔰.middleGram N).frameGram γ let C : Matrix (Fin (𝔰.ϱ + 1)) (Fin (𝔰.ϱ + 1)) R := single 𝔰.top 𝔰.top (-N) have h_gram : (framePair γ)ᴴ * (𝔰.middleGram N).splitGram * framePair γ = fromBlocks Z C C Zᴴ * fromBlocks 0 1 1 0 := by simp [gram_framePair N hN, fromBlocks_multiply, Z, C] have h_sign : (fromBlocks 0 1 1 0 : Matrix (Fin 𝔰.n ⊕ Fin 𝔰.n) (Fin 𝔰.n ⊕ Fin 𝔰.n) R).det = (-1) ^ 𝔰.n := by rw [show (fromBlocks 0 1 1 0 : Matrix (Fin 𝔰.n ⊕ Fin 𝔰.n) _ R) = fromBlocks 1 (-1) 0 1 * fromBlocks 1 1 1 0 by simp [fromBlocks_multiply]] simp [det_mul, det_fromBlocks_one₁₁, det_neg] have h_corner : Z.adjugate 𝔰.top 𝔰.top = leadingMinor Z 𝔰.top.castSucc := by simp [adjugate_fin_succ_eq_det_submatrix, leadingMinor, show castLE (Nat.le_succ 𝔰.ϱ) = castSucc from rfl] rw [h_gram, det_mul, h_sign, det_fromBlocks_single, ← adjugate_conjTranspose, conjTranspose_apply, h_corner, det_conjTranspose, frameDisc, neg_sq, mul_comm] /-! ### The map to pairs of middle coordinates, and the link -/ /-- The matrix of the map t ↦ ([t], [γ⁻¹t]) from the space to two copies of X₀⊕Ez, where [·] takes the middle coordinates. -/ def linkMatrix : Matrix (𝔰.MiddleIndex ⊕ 𝔰.MiddleIndex) 𝔰.BesselIndex R := let m (x : T.G) : Matrix 𝔰.MiddleIndex 𝔰.BesselIndex R := x.val.val.toRows₂.toRows₁ (m 1).fromRows (m γ⁻¹) /-- The link of `γ`. Let `X` be the span of `e₁, …, e_ϱ`. A vector is orthogonal to `X` if its last block of coordinates vanishes, and then its middle block is its class in `X^⊥/X`. The link is the module of the pairs (class of `t`, class of `γ⁻¹ t`) for `t` orthogonal to `X` and to `γ X`. A pair is written as one function on `𝔰.MiddleIndex ⊕ 𝔰.MiddleIndex`. -/ def link : Submodule R (𝔰.MiddleIndex ⊕ 𝔰.MiddleIndex → R) := ((isotropicFramePair γ)ᴴ * T.splitGram).mulVecLin.ker.map (linkMatrix γ).mulVecLin end LinkDefs /-! ## Bessel systems: cut pairs, Schur bounds and local bounds * `New.HasLocalBounds`: local bounds, a system of forms (`New.SieveSystem`) whose top form comes from `New.besselOrbitalIntegral`. -/ section BesselSystem open MeasureTheory Matrix ComplexConjugate Real Fintype Set Norms.L2Operator Floors.FloorGroups RealPlace variable (𝔰 : Shape) /-! ### Constants -/ /-- The constant c_G = vol U(k) · (2π^k/(k−1)!) / vol U(k+2ϱ+1), with the volumes `New.volU`. For k ≥ 1 the middle factor is vol U(k)/vol U(k−1), so that c_G = vol U(k)² / (vol U(k+2ϱ+1) · vol U(k−1)). -/ def Shape.openCellConst : ℝ := volU 𝔰.k / volU 𝔰.r * sphereDensity 𝔰.k 1 lemma Shape.openCellConst_pos (𝔰 : Shape) : 0 < 𝔰.openCellConst := by refine mul_pos (div_pos (volU_pos _) (volU_pos _)) ?_ rw [sphereDensity] positivity /-- The constant Θ = π^{(2ϱ+1)k}·vol U(k)/vol U(r), with k = |κ| and r the rank of G₁. -/ def Shape.scaledVolumeRatio : ℝ := volU 𝔰.k / volU 𝔰.r * π ^ ((2 * 𝔰.ϱ + 1) * 𝔰.k) variable {𝔰} (y : 𝔰.G₁) {I : Type} [Fintype I] [DecidableEq I] (W : 𝔰.G₁ → EuclideanSpace ℂ I) /-! ### The scaled length and the bounds at a real place -/ /-- The length `besselLength y` in units of `b ^ (6 n)`, and at least one; here n = ϱ + 1. -/ def scaledBesselLength (y : 𝔰.G₁) (b : ℝ) : ℝ := max 1 (besselLength y / b ^ (6 * 𝔰.n)) lemma one_le_scaledBesselLength (y : 𝔰.G₁) (b : ℝ) : 1 ≤ scaledBesselLength y b := le_max_left _ _ /-- If `2 ≤ b` and the length `besselLength y` exceeds half of `b ^ (6 n + 2)`, with n = ϱ + 1, then the scaled length `max 1 (besselLength y / b ^ (6 n))` is at least `b`. -/ lemma le_scaledBesselLength {y : 𝔰.G₁} {b : ℝ} (hb : 2 ≤ b) (h_large : b ^ (6 * 𝔰.n + 2) / 2 < besselLength y) : b ≤ scaledBesselLength y b := by refine le_max_of_le_right ((le_div_iff₀ (by positivity)).2 (le_trans ?_ h_large.le)) calc b * b ^ (6 * 𝔰.n) = b * b ^ (6 * 𝔰.n) * 2 / 2 := by ring _ ≤ b * b ^ (6 * 𝔰.n) * b / 2 := by gcongr _ = b ^ (6 * 𝔰.n + 2) / 2 := by ring /-- The condition that the length `New.besselLength` of y is at most b^(6(ϱ+1)+2). -/ abbrev InCut (y : 𝔰.G₁) (b : ℝ) : Prop := besselLength y ≤ b ^ (6 * 𝔰.n + 2) /-- For a (ϱ+1)×(ϱ+1) complex matrix Z, the real number 𝗀(Z) = |det Z|² − |D_ϱ|², D_ϱ the leading principal minor of order ϱ. -/ def RealPlace.gramDiscReal (Z : 𝔰.FrameMatrix) : ℝ := (frameDisc 1 Z).re /-- The number (ρ^(9n)/𝗀)^(10⁵n⁴)·d²/(deg·c_G·(𝗀/2)^(k−1)), with n = ϱ+1, k = |κ|, c_G = `New.Shape.openCellConst` and 𝗀 = `New.RealPlace.gramDiscReal (New.realFrameGram y)`, taken at the matrix of the products h(f_a, y f_b) of the frame with its image under y. It bounds a mass in `New.BesselSystem.IsOpenCellBound`, where deg is the degree of a Bessel system, d the dimension of its value space and ρ a bound on the lengths of frame vectors. -/ def pairingBoundSq (y : 𝔰.G₁) (deg ρ d : ℝ) : ℝ := (ρ ^ (9 * 𝔰.n) / gramDiscReal (realFrameGram y)) ^ (10 ^ 5 * 𝔰.n ^ 4) * (d ^ 2 / (deg * 𝔰.openCellConst * (gramDiscReal (realFrameGram y) / 2) ^ (𝔰.k - 1))) /-- The tensor J(γ) = ∫ W(y) ⊗ W(γ⁻¹y)^* dμ(y), with coordinates ∫ W_i(y) conj(W_j(γ⁻¹y)) dμ(y), for a vector-valued function W on a group G. -/ def besselOrbitalIntegral {G I : Type*} [Group G] [MeasurableSpace G] (μ : Measure G) (W : G → EuclideanSpace ℂ I) (γ : G) : EuclideanSpace ℂ (I × I) := WithLp.toLp 2 fun x ↦ ∫ y : G, W y x.1 * conj (W (γ⁻¹ * y) x.2) ∂μ /-- Schur's bound: for every integrable φ on G₁, the function γ ↦ ∫ φ(y)W(γy) dy has squared L² norm on 𝖴∖G₁ (for the measure `New.besselQuotMeasure`) at most D·∫|φ|². -/ def SchurLe (W : 𝔰.G₁ → EuclideanSpace ℂ I) (D : ENNReal) : Prop := ∀ φ : 𝔰.G₁ → ℂ, Integrable φ → ∫⁻ γ : 𝔰.G₁, ‖∫ y : 𝔰.G₁, φ y • W (γ * y)‖ₑ ^ 2 ∂besselQuotMeasure ≤ D * ∫⁻ y : 𝔰.G₁, ‖φ y‖ₑ ^ 2 /-- There is a family `V w` of continuous vector-valued functions on `G₁`, `w` a word in pairs of indices, with `V [] = W`, such that (a) each `V w` is a Bessel function of type `rep`: it is bounded and transforms on the left by a fixed character under 𝖴 and by `rep` under U(κ); (b) the `V ((a, b) :: w)` are the coefficients of the right derivative of `V w`: if a curve has `γ' t = γ t * X`, then `(V w ∘ γ)' t = ∑ a b, X a b • V ((a, b) :: w) (γ t)`; (c) if `w` has length at most `2 (ϱ + 1) ^ 2`, then `V w` satisfies `New.SchurLe` with constant `B ^ (2 * w.length) * D`. -/ def RealPlace.HasSchurBound (W : 𝔰.G₁ → EuclideanSpace ℂ I) (rep : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ) →* unitaryGroup I ℂ) (B : ℝ) (D : ENNReal) : Prop := ∃ V : List (𝔰.BesselIndex × 𝔰.BesselIndex) → C(𝔰.G₁, EuclideanSpace ℂ I), W = V [] ∧ ∀ w : List (𝔰.BesselIndex × 𝔰.BesselIndex), -- (a) `V w` is a Bessel function IsBesselFunction rep (V w) ∧ -- (b) the chain rule along a curve `γ` with logarithmic derivative `X` at `t` (∀ (γ : ℝ → 𝔰.G₁) (X : Matrix 𝔰.BesselIndex 𝔰.BesselIndex ℂ) (t : ℝ), HasDerivAt (fun s : ℝ ↦ (γ s).val.val) (γ t * X) t → HasDerivAt (V w ∘ γ) (∑ a : 𝔰.BesselIndex, ∑ b : 𝔰.BesselIndex, X a b • V ((a, b) :: w) (γ t)) t) ∧ -- (c) Schur's bound for short words, at the price of `B ^ 2` for each letter (w.length ≤ 2 * 𝔰.n ^ 2 → SchurLe (V w) (ENNReal.ofReal (B ^ (2 * w.length)) * D)) /-- The tensor J(w_p y) of `New.besselOrbitalIntegral` for W, times √c_G · (|p_ϱ|² − 1)^((k−1)/2) · |I|⁻¹ · ∏_{a<ϱ} |p_a|^(k+1+2(ϱ−a−1)), where k = |κ| and c_G = `New.Shape.openCellConst`. The Weyl element w_p = `weylElem ϱ p` maps e_a to p_a e*_a and e*_a to e_a/p̄_a for a < ϱ, and fixes the other basis vectors. -/ def normalizedOrbitalIntegral (p : ℕ → ℂˣ) : EuclideanSpace ℂ (I × I) := (√𝔰.openCellConst * √(‖(p 𝔰.ϱ).val‖ ^ 2 - 1) ^ (𝔰.k - 1) / card I * ∏ a ∈ Finset.range 𝔰.ϱ, ‖(p a).val‖ ^ (𝔰.k + 1 + 2 * (𝔰.ϱ - (a + 1)))) • besselOrbitalIntegral volume W (weylElem 𝔰.ϱ p * y) /-- Local bounds for given forms J_i(p, q) on tuples of nonzero complex numbers, with n = ϱ + 1 and k = |κ|: (a) J is a system `New.SieveSystem`, in which each J_i (i < n) is the integral of J_(i+1) over a common entry and the integrals twisted by the character e^(c − c̄) are bounded, with |J_0| ≤ (1 + b^(−10))/deg, weights `New.headWeight` with exponent n⁶ that vanish unless the products of the first entries have modulus at most b^(60n²), and decay Θ b^(2000n⁹) ℓ_{k−n⁷}(1/|ξ|), where Θ = `New.Shape.scaledVolumeRatio` and ℓ_j(r) = r^j min(1, r)⁶ (`New.dampedPower`); (b) if σ fixes the hyperbolic basis vectors (σ in `floorGroup ϱ`) and the last entries p_ϱ, q_ϱ both equal h(z, σz), then J_n(p, q) is the inner product of the tensors `New.normalizedOrbitalIntegral` of W and σ at p and at q. -/ def HasLocalBounds (b : ℝ) (W : 𝔰.G₁ → EuclideanSpace ℂ I) (deg : ℝ) (J : ℕ → (ℕ → ℂˣ) → (ℕ → ℂˣ) → ℂ) : Prop := -- (a) `J` is a system over `ℂ` with the character `wave` and these bounds SieveSystem unitOrOne (fun z ↦ z⁻¹.1) 𝔰.ϱ J wave ((1 + b⁻¹ ^ 10) / deg) (headWeight (b ^ (60 * 𝔰.n ^ 2)) (𝔰.n ^ 6)) (fun ξ ↦ 𝔰.scaledVolumeRatio * b ^ (2000 * 𝔰.n ^ 9) * dampedPower (𝔰.k - 𝔰.n ^ 7) ‖ξ‖⁻¹) ∧ -- (b) its top form is an inner product of values of `normalizedOrbitalIntegral σ`, if both last -- entries are `h(z, σ z)` ∀ σ ∈ floorGroup 𝔰.ϱ, ∀ p q : ℕ → ℂˣ, realFrameGram σ 𝔰.top 𝔰.top = p 𝔰.ϱ → q 𝔰.ϱ = p 𝔰.ϱ → J 𝔰.n p q = inner ℂ (normalizedOrbitalIntegral σ W p) (normalizedOrbitalIntegral σ W q) /-- The two functions of a Bessel system: the Bessel function W (`full`) and its cut W♭ (`cut`). -/ inductive FullOrCut /-- The Bessel function W itself. -/ | full /-- Its cut W♭. -/ | cut /-- The family that is `W` on the full side and `W'` on the cut side. -/ abbrev FullOrCut.select {α : Type*} (W W' : α) : FullOrCut → α | .full => W | .cut => W' /-- `A` bounds the norms of both functions `W t` times a power, growing with `f`, of their scaled length; the number `a` bounds `A`; and `a` times the integral of `A` over 𝖴∖G₁ is at most `b ^ (400 r ^ 2)` times the dimension. Here r is the rank of G₁. -/ structure IsDecayMajorant (b : ℝ) (f : ℕ) (W : FullOrCut → C(𝔰.G₁, EuclideanSpace ℂ I)) (A : 𝔰.G₁ → ENNReal) (a : ENNReal) : Prop where /-- The majorant is measurable. -/ measurable : Measurable A /-- The majorant is left invariant under the Bessel subgroup. -/ fixesLeft : besselS.FixesLeft A /-- `‖W t y‖` times the power `3 r ^ 3 f` of the scaled length of `y` is at most `A y`. -/ pow_mul_enorm_le (t : FullOrCut) (y : 𝔰.G₁) : .ofReal (scaledBesselLength y b ^ (3 * 𝔰.r ^ 3 * f)) * ‖W t y‖ₑ ≤ A y /-- The majorant is bounded by `a`. -/ le_bound (y : 𝔰.G₁) : A y ≤ a /-- The bound is finite. -/ bound_ne_top : a ≠ ⊤ /-- The bound times the integral of the majorant over 𝖴∖G₁ is at most `b ^ (400 r ^ 2)` times the dimension. -/ bound_mul_lintegral_le : a * ∫⁻ y : 𝔰.G₁, A y ∂besselQuotMeasure ≤ .ofReal (b ^ (400 * 𝔰.r ^ 2)) * card I /-- A normalised Bessel function and its cut, for the type `rep`: they differ only where the length exceeds half of `b ^ (6 n + 2)`, are close in L², and decay in the length at a rate given by `f`. Here n = ϱ + 1 and r is the rank of G₁. -/ structure IsCutPair (b : ℝ) (f : ℕ) (rep : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ) →* unitaryGroup I ℂ) (W : FullOrCut → C(𝔰.G₁, EuclideanSpace ℂ I)) : Prop where /-- W and W♭ are Bessel functions. -/ isBesselFunction (t : FullOrCut) : IsBesselFunction rep (W t) /-- W is integrable on 𝖴∖G₁. -/ integrable : Integrable (W .full) besselQuotMeasure /-- The squared L²(𝖴∖G₁) norm of W is the dimension of the value space. -/ lintegral_sq_full_eq : ∫⁻ y : 𝔰.G₁, ‖W .full y‖ₑ ^ 2 ∂besselQuotMeasure = card I /-- The squared L²(𝖴∖G₁) norm of W♭ is at most that dimension. -/ lintegral_sq_cut_le : ∫⁻ y : 𝔰.G₁, ‖W .cut y‖ₑ ^ 2 ∂besselQuotMeasure ≤ card I /-- W♭ vanishes off `InCut`. -/ inCut_of_ne_zero (y : 𝔰.G₁) : W .cut y ≠ 0 → InCut y b /-- The squared L²(𝖴∖G₁) distance of W♭ from W is at most `b ^ (-2 r ^ 3 f)` times the dimension. -/ lintegral_sq_sub_le : ∫⁻ y : 𝔰.G₁, ‖W .cut y - W .full y‖ₑ ^ 2 ∂besselQuotMeasure ≤ .ofReal (b⁻¹ ^ (𝔰.r ^ 3 * f)) ^ 2 * card I /-- The cut changes W only where the length exceeds half the radius of `InCut`. -/ lt_besselLength_of_ne (y : 𝔰.G₁) : W .cut y ≠ W .full y → b ^ (6 * 𝔰.n + 2) / 2 < besselLength y /-- W and W♭ decay in the length, below a common integrable majorant. -/ exists_majorant : ∃ (A : 𝔰.G₁ → ENNReal) (a : ENNReal), IsDecayMajorant b f W A a variable (𝔰) /-! ### Bessel systems -/ /-- A Bessel system: two continuous functions W (full) and W♭ (cut), given by the field `besselFn`, from G₁ to π = ℂ^Index, where `Index` is a field, Bessel functions of an irreducible type rep. W obeys the Schur bounds; W♭ has bounded support modulo the Bessel subgroup `besselS` and local bounds; together they form a cut pair; and b is at least 8r. The size parameter b sets the radius of the cut and the constants; f sets the rate of decay in `New.IsCutPair`; r is the rank of G₁. -/ structure BesselSystem (b : ℝ) (f : ℕ) where /-- The index set of a basis of the value space π. -/ Index : Type /-- π is finite-dimensional. -/ [fintype : Fintype Index] [decEq : DecidableEq Index] /-- π is not zero. -/ [nonempty : Nonempty Index] /-- The Bessel function W (`.full`) and its cut W♭ (`.cut`), from G₁ to π. -/ besselFn : FullOrCut → C(𝔰.G₁, EuclideanSpace ℂ Index) /-- The degree; its inverse scales the constant in `New.RealPlace.HasSchurBound` and the bound of J_0 in `New.HasLocalBounds`. -/ deg : ℝ /-- The degree is positive. -/ deg_pos : 0 < deg /-- The type of the Bessel functions W and W♭. -/ rep : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ) →* unitaryGroup Index ℂ /-- W and W♭ form a cut pair: L² bounds, the support of W♭ and decay below a common majorant. -/ isCutPair : IsCutPair b f rep besselFn /-- Every matrix that commutes with all rep(h) is scalar. -/ irreducible (M : Matrix Index Index ℂ) : (∀ h : U (1 : Matrix 𝔰.κ 𝔰.κ ℂ), Commute M (rep h).1) → M ∈ range (scalar Index) /-- For every P ≥ b^5, W satisfies `New.RealPlace.HasSchurBound` with constants P and |Index|/deg. -/ hasSchurBound : ∀ P ≥ b ^ 5, HasSchurBound (besselFn FullOrCut.full) rep P (ENNReal.ofReal deg⁻¹ * card Index) /-- The parameter b is at least 8r, with r the rank of G₁. -/ eight_mul_rank_le : 8 * 𝔰.r ≤ b /-- The forms J of the local bounds of W♭. -/ bandLimit : ℕ → (ℕ → ℂˣ) → (ℕ → ℂˣ) → ℂ /-- W♭ has local bounds. -/ hasLocalBounds : HasLocalBounds b (besselFn .cut) deg bandLimit attribute [instance] BesselSystem.fintype BesselSystem.decEq BesselSystem.nonempty end BesselSystem end New end