Download data/lean/OAI/Probability/BinarySweep/Representations/IsotypicProjectionMoment.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 9.39 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Probability/BinarySweep/Representations/IsotypicProjectionMoment.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Probability/BinarySweep/Representations/IsotypicProjectionMoment.lean
-
curl -L -o IsotypicProjectionMoment.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Probability/BinarySweep/Representations/IsotypicProjectionMoment.lean
9.39 kB
Lean 4 Β· 18
declarations fullstatements
| import Mathlib | |
| import OAI.Probability.BinarySweep.TensorBounds.SignedTypeCentrality | |
| import OAI.Probability.BinarySweep.MatrixBounds.SpectralMoment | |
| namespace OAI | |
| noncomputable section | |
| section | |
| open scoped BigOperators Classical ComplexOrder MonoidAlgebra | |
| open Matrix | |
| namespace BinaryCoordinateSweeps | |
| open Density Irrep Representation | |
| lemma euclidean_pow {I : Type*} [Fintype I] [DecidableEq I] | |
| (M : Matrix I I β) (q : β) : (M^q).toEuclideanLin=M.toEuclideanLin^q := by | |
| induction q with | |
| | zero => simp only [pow_zero,Matrix.toLpLin_one,Module.End.one_eq_id] | |
| | succ q ih => rw [pow_succ,Matrix.toLpLin_mul_same,ih,pow_succ,Module.End.mul_eq_comp] | |
| lemma projected_gram_power {I : Type*} [Fintype I] [DecidableEq I] | |
| (P M : Matrix I I β) (hP : P.IsHermitian) (hPP : P*P=P) (hPM : P*M=M*P) | |
| {q : β} (hq : 0 < q) : | |
| (star (P*M)*(P*M))^q = (star M*M)^q*P := by | |
| have hs : P*star M=star M*P := by | |
| have hh := congrArg star hPM | |
| simpa only [star_mul,show star P=P from hP.eq] using hh.symm | |
| have hc : Commute (star M*M) P := by | |
| change star M*M*P=P*(star M*M) | |
| rw [mul_assoc,β hPM,β mul_assoc,β hs,mul_assoc] | |
| have he : star (P*M)*(P*M)=(star M*M)*P := by | |
| simp only [star_mul,show star P=P from hP.eq] | |
| rw [mul_assoc,β mul_assoc P P M,hPP,hPM,β mul_assoc] | |
| rw [he,hc.mul_pow,(show IsIdempotentElem P from hPP).pow_eq (ne_of_gt hq)] | |
| lemma trace_mul_projection {W : Type*} [NormedAddCommGroup W] [InnerProductSpace β W] | |
| [FiniteDimensional β W] (S : Submodule β W) (B : W ββ[β] W) | |
| (hS : βwβS, B wβS) : | |
| LinearMap.trace β W (B*S.starProjection.toLinearMap)= | |
| LinearMap.trace β S (B.restrict hS) := by | |
| have hm (w : W) : (B*S.starProjection.toLinearMap) wβS := | |
| hS _ (S.starProjection_apply_mem w) | |
| have he : (B*S.starProjection.toLinearMap).restrict (fun w _ => hm w)=B.restrict hS := by | |
| ext w | |
| change B (S.starProjection w.val)=B w.val | |
| rw [Submodule.starProjection_eq_self_iff.mpr w.property] | |
| rw [β LinearMap.trace_restrict_eq_of_forall_mem S _ hm,he] | |
| namespace Signed | |
| variable {A : Type*} [Fintype A] [DecidableEq A] {n : β} | |
| {V : Type*} [NormedAddCommGroup V] [InnerProductSpace β V] [FiniteDimensional β V] | |
| def signedAverage (p : A β Bool) (w : Equiv.Perm (Fin n) β β) : | |
| Matrix (Fin n β A) (Fin n β A) β := βg, w g β’ actionMatrix p g | |
| lemma signedAverage_linear (p : A β Bool) (w : Equiv.Perm (Fin n) β β) : | |
| (signedAverage p w).toEuclideanLin=groupAverage (hilbertTensorRep p n) w := by | |
| simp only [signedAverage,map_sum,map_smul,actionMatrix_linear,groupAverage] | |
| omit [FiniteDimensional β V] in | |
| lemma isotypicProjection_commutes_average (p : A β Bool) | |
| (Ο : Representation β (Equiv.Perm (Fin n)) V) (w : Equiv.Perm (Fin n) β β) : | |
| isotypicProjection p Ο*signedAverage p w=signedAverage p w*isotypicProjection p Ο := by | |
| simp only [signedAverage,Finset.mul_sum,Finset.sum_mul,mul_smul_comm,smul_mul_assoc, | |
| typeProjection_commutes_action] | |
| theorem local_projected_moment (p : A β Bool) | |
| (Ο : Representation β (Equiv.Perm (Fin n)) V) [Ο.IsIrreducible] | |
| (hΟ : βg v, βΟ g vβ=βvβ) (w : Equiv.Perm (Fin n) β β) {q : β} (hq : 0 < q) : | |
| TraceHolder.matrixMoment q (isotypicProjection p Ο*signedAverage p w)= | |
| (Module.finrank β (IntertwiningMap Ο (hilbertTensorRep p n)):β)*evenMoment q (groupAverage Ο w) := by | |
| unfold TraceHolder.matrixMoment | |
| rw [projected_gram_power _ _ (isotypicProjection_psd p Ο).isHermitian | |
| (projectionMatrix_idempotent _) (isotypicProjection_commutes_average p Ο w) hq] | |
| rw [β trace_toEuclideanLinear] | |
| simp only [Matrix.toLpLin_mul_same,β Module.End.mul_eq_comp,euclidean_pow, | |
| Matrix.star_eq_conjTranspose,Matrix.toEuclideanLin_conjTranspose_eq_adjoint,signedAverage_linear] | |
| have hP : (isotypicProjection p Ο).toEuclideanLin= | |
| (isotypicSpan Ο (hilbertTensorRep p n)).starProjection.toLinearMap := by | |
| rw [hilbert_isotypic_eq]; exact projectionMatrix_linear _ | |
| rw [hP] | |
| have hc := even_compatible Ο (hilbertTensorRep p n) w hΟ (hilbertTensorRep_unitary p) q | |
| rw [trace_mul_projection _ _ (isotypic_invariant_of_compatible Ο _ _ _ hc), | |
| isotypic_trace Ο _ _ _ hc] | |
| simp only [evenMoment,Complex.mul_re,Complex.natCast_re,Complex.natCast_im,zero_mul,sub_zero] | |
| lemma hilbert_multiplicity_bound (p : A β Bool) | |
| (Ο : Representation β (Equiv.Perm (Fin n)) V) [Ο.IsIrreducible] : | |
| Module.finrank β (IntertwiningMap Ο (hilbertTensorRep p n)) β€ (n+1)^((Fintype.card A)^2) := by | |
| have hd : 0 < Module.finrank β V := by | |
| let : Nontrivial Ο.asModule := IsSimpleModule.nontrivial β[Equiv.Perm (Fin n)] Ο.asModule | |
| rw [β Ο.asModuleEquiv.finrank_eq] | |
| exact Module.finrank_pos | |
| have h := isotypicSpan_rank_bound p Ο | |
| rw [β hilbertSubspace_finrank,β hilbert_isotypic_eq p Ο,isotypicSpan_finrank_eq] at h | |
| exact Nat.le_of_mul_le_mul_left h hd | |
| theorem local_projected_moment_le (p : A β Bool) | |
| (Ο : Representation β (Equiv.Perm (Fin n)) V) [Ο.IsIrreducible] | |
| (hΟ : βg v, βΟ g vβ=βvβ) (w : Equiv.Perm (Fin n) β β) {q : β} (hq : 0 < q) : | |
| TraceHolder.matrixMoment q (isotypicProjection p Ο*signedAverage p w) β€ | |
| (n+1:β)^((Fintype.card A)^2)*evenMoment q (groupAverage Ο w) := by | |
| rw [local_projected_moment p Ο hΟ w hq] | |
| apply mul_le_mul_of_nonneg_right | |
| Β· exact_mod_cast hilbert_multiplicity_bound p Ο | |
| Β· exact (Complex.nonneg_iff.mp (positive_pow (LinearMap.isPositive_adjoint_comp_self _) q).trace_nonneg).1 | |
| end Signed | |
| end BinaryCoordinateSweeps | |
| end | |
| open scoped BigOperators Classical | |
| namespace BinaryCoordinateSweeps.Fourier | |
| open Representation | |
| variable (G : Type*) [Group G] [Fintype G] | |
| abbrev RegularSpace := EuclideanSpace β G | |
| def regularMap (g : G) : RegularSpace G ββ[β] RegularSpace G where | |
| toFun v := WithLp.toLp 2 (fun x => v (gβ»ΒΉ*x)) | |
| map_add' v w := by ext x; rfl | |
| map_smul' a v := by ext x; rfl | |
| def regular : Representation β G (RegularSpace G) where | |
| toFun := regularMap G | |
| map_one' := by ext v x; simp [regularMap] | |
| map_mul' g h := by ext v x; simp [regularMap,mul_assoc] | |
| omit [Fintype G] in | |
| lemma regular_apply (g : G) (v : RegularSpace G) (x : G) : | |
| regular G g v x=v (gβ»ΒΉ*x) := rfl | |
| lemma regular_unitary (g : G) (v : RegularSpace G) : βregular G g vβ=βvβ := by | |
| simp only [EuclideanSpace.norm_eq] | |
| congr 1 | |
| exact Equiv.sum_comp (Equiv.mulLeft gβ»ΒΉ) (fun x => βv xβ^2) | |
| lemma regular_character (g : G) : | |
| (regular G).character g=if g=1 then (Fintype.card G:β) else 0 := by | |
| rw [Representation.character,LinearMap.trace_eq_sum_inner _ (EuclideanSpace.basisFun G β)] | |
| by_cases hg : g=1 | |
| Β· subst g; simp | |
| Β· rw [ite_eq_right hg] | |
| apply Finset.sum_eq_zero | |
| intro x _ | |
| rw [EuclideanSpace.basisFun_inner,regular_apply,EuclideanSpace.basisFun_apply] | |
| simp only [PiLp.single_apply] | |
| have hh : gβ»ΒΉ*xβ x := by | |
| intro he | |
| have := mul_right_cancel (show gβ»ΒΉ*x=1*x from by simpa using he) | |
| exact hg (inv_eq_one.mp this) | |
| simp [hh] | |
| lemma regular_multiplicity {V : Type*} [AddCommGroup V] [Module β V] | |
| [FiniteDimensional β V] (Ο : Representation β G V) : | |
| Module.finrank β (IntertwiningMap Ο (regular G))=Module.finrank β V := by | |
| have hc : (Nat.card G:β)β 0 := by | |
| rw [Nat.card_eq_fintype_card] | |
| exact_mod_cast Fintype.card_ne_zero | |
| let : Invertible (Nat.card G:β) := invertibleOfNonzero hc | |
| have hh := card_inv_mul_sum_char_mul_char_eq_finrank Ο (regular G) | |
| simp only [regular_character,ite_mul,zero_mul] at hh | |
| simp only [Finset.sum_ite_eq',Finset.mem_univ,ite_true,inv_one,char_one] at hh | |
| rw [βNat.card_eq_fintype_card,βmul_assoc,inv_mul_cancelβ hc,one_mul] at hh | |
| exact_mod_cast hh.symm | |
| lemma regular_average_apply (p : G β β) (v : RegularSpace G) (x : G) : | |
| Irrep.groupAverage (regular G) p v x=βg,p g*v (gβ»ΒΉ*x) := by | |
| simp [Irrep.groupAverage,LinearMap.sum_apply,LinearMap.smul_apply] | |
| lemma regular_moment_one (p : G β β) : | |
| Irrep.evenMoment 1 (Irrep.groupAverage (regular G) p)= | |
| (Fintype.card G:β)*(βg,βp gβ^2) := by | |
| unfold Irrep.evenMoment | |
| rw [pow_one,LinearMap.trace_eq_sum_inner _ (EuclideanSpace.basisFun G β)] | |
| simp only [Complex.re_sum,Module.End.mul_apply,LinearMap.adjoint_inner_right,inner_self_eq_norm_sq_to_K] | |
| have he (x : G) : βIrrep.groupAverage (regular G) p ((EuclideanSpace.basisFun G β) x)β^2= | |
| βg,βp gβ^2 := by | |
| rw [EuclideanSpace.norm_sq_eq] | |
| have ha (y : G) : Irrep.groupAverage (regular G) p ((EuclideanSpace.basisFun G β) x) y=p (y*xβ»ΒΉ) := by | |
| rw [regular_average_apply] | |
| simp only [EuclideanSpace.basisFun_apply,PiLp.single_apply] | |
| have hiff (g : G) : x=gβ»ΒΉ*y β g=y*xβ»ΒΉ := by | |
| constructor <;> intro hh | |
| Β· calc g=(g*x)*xβ»ΒΉ := by group | |
| _=y*xβ»ΒΉ := by rw [hh]; simp | |
| Β· subst g; group | |
| simp_rw [eq_comm (a:=_β»ΒΉ*y) (b:=x),hiff,mul_ite,mul_one,mul_zero] | |
| simp | |
| simp_rw [ha] | |
| exact Equiv.sum_comp (Equiv.mulRight xβ»ΒΉ) (fun g => βp gβ^2) | |
| change (βi, ((βIrrep.groupAverage (regular G) p ((EuclideanSpace.basisFun G β) i)β:β)^2).re)=_ | |
| simp only [βComplex.ofReal_pow,Complex.ofReal_re] | |
| simp_rw [he] | |
| simp | |
| end BinaryCoordinateSweeps.Fourier | |
| end | |
| end OAI | |
Outline
- lemma
euclidean_pow17 - lemma
projected_gram_power23 - lemma
trace_mul_projection38 - def
signedAverage55 - lemma
signedAverage_linear58 - lemma
isotypicProjection_commutes_average63 - theorem
local_projected_moment69 - lemma
hilbert_multiplicity_bound89 - theorem
local_projected_moment_le100 - abbrev
RegularSpace122 - def
regularMap124 - def
regular129 - lemma
regular_apply135 - lemma
regular_unitary138 - lemma
regular_character143 - lemma
regular_multiplicity159 - lemma
regular_average_apply172 - lemma
regular_moment_one176