cfahlgren1's picture
download
raw
12.3 kB
import Mathlib
namespace OAI
namespace ThorpNine.Tail
namespace Thorp
open scoped BigOperators
open Filter
abbrev Card (d : ℕ) := Fin d → Bool
def switchFun {d : ℕ} (ξ : Card d → Bool) (x : Card (d + 1)) : Card (d + 1) :=
Fin.cons (Bool.xor (x 0) (ξ (Fin.tail x))) (Fin.tail x)
theorem switchFun_involutive {d : ℕ} (ξ : Card d → Bool) :
Function.Involutive (switchFun ξ) := by
intro x
funext i
refine Fin.cases ?_ (fun j => ?_) i
· simp only [switchFun, Fin.cons_zero, Fin.tail_cons]
cases x 0 <;> cases ξ (Fin.tail x) <;> rfl
· simp [switchFun, Fin.tail]
def pairSwitch {d : ℕ} (ξ : Card d → Bool) : Equiv.Perm (Card (d + 1)) :=
{ toFun := switchFun ξ
invFun := switchFun ξ
left_inv := switchFun_involutive ξ
right_inv := switchFun_involutive ξ }
def Butterfly : ℕ → Type
| 0 => Unit
| d + 1 => (Card d → Bool) × (Bool → Butterfly d)
def childLift {d : ℕ} (p : Bool → Equiv.Perm (Card d)) : Equiv.Perm (Card (d + 1)) where
toFun x := Fin.cons (x 0) (p (x 0) (Fin.tail x))
invFun x := Fin.cons (x 0) ((p (x 0)).symm (Fin.tail x))
left_inv x := by simp only [Fin.cons_zero, Fin.tail_cons, Equiv.symm_apply_apply, Fin.cons_self_tail]
right_inv x := by simp only [Fin.cons_zero, Fin.tail_cons, Equiv.apply_symm_apply, Fin.cons_self_tail]
def butterflyPerm : (d : ℕ) → Butterfly d → Equiv.Perm (Card d)
| 0, _ => 1
| d + 1, b => pairSwitch b.1 * childLift (fun ε => butterflyPerm d (b.2 ε))
noncomputable def finiteMean {Ω : Type*} [Fintype Ω] (f : Ω → ℝ) : ℝ :=
(∑ ω, f ω) / Fintype.card Ω
def SwitchIndex : ℕ → Type
| 0 => Empty
| d + 1 => Sum (Card d) (Bool × SwitchIndex d)
instance (d : ℕ) : Fintype (SwitchIndex d) := by
induction d with
| zero => exact inferInstanceAs (Fintype Empty)
| succ d ih => exact inferInstanceAs (Fintype (Sum (Card d) (Bool × SwitchIndex d)))
instance (d : ℕ) : DecidableEq (SwitchIndex d) := by
induction d with
| zero => exact inferInstanceAs (DecidableEq Empty)
| succ d ih => exact inferInstanceAs (DecidableEq (Sum (Card d) (Bool × SwitchIndex d)))
def decodeButterfly : (d : ℕ) → (SwitchIndex d → Bool) → Butterfly d
| 0, _ => ()
| d + 1, ω => (fun y => ω (Sum.inl y), fun ε =>
decodeButterfly d (fun i => ω (Sum.inr (ε,i))))
end Thorp
namespace Thorp.PairRouting
open scoped BigOperators
open Filter
variable {ι α : Type*} [Fintype ι] [Fintype α] [DecidableEq α]
noncomputable def tupleProbability {Ω β : Type*} [Fintype Ω] [DecidableEq β]
(P : Ω → Equiv.Perm β) (x y : ι → β) : ℝ := by
classical
exact finiteMean (fun ω => if ∀ i, P ω (x i) = y i then 1 else 0)
end Thorp.PairRouting
namespace Thorp.Specht
open scoped BigOperators Classical
abbrev Cell (μ : YoungDiagram) := {x : ℕ × ℕ // x ∈ μ.cells}
def row {μ : YoungDiagram} (x : Cell μ) : ℕ := x.1.1
def col {μ : YoungDiagram} (x : Cell μ) : ℕ := x.1.2
lemma row_lt_colLen {μ : YoungDiagram} (x : Cell μ) : row x < μ.colLen (col x) :=
YoungDiagram.mem_iff_lt_colLen.mp x.2
noncomputable def rowIndex {μ : YoungDiagram} (x : Cell μ) : Fin (μ.colLen 0) :=
⟨row x, (row_lt_colLen x).trans_le (μ.colLen_anti 0 (col x) (Nat.zero_le _))⟩
abbrev Tabloid (μ : YoungDiagram) :=
{f : Cell μ → Fin (μ.colLen 0) // ∃ p : Equiv.Perm (Cell μ), f = rowIndex ∘ p}
noncomputable instance (μ : YoungDiagram) : Fintype (Tabloid μ) := Fintype.ofFinite _
noncomputable def baseTabloid (μ : YoungDiagram) : Tabloid μ := ⟨rowIndex, 1, rfl⟩
noncomputable def tabloidAct {μ : YoungDiagram} (p : Equiv.Perm (Cell μ)) :
Equiv.Perm (Tabloid μ) where
toFun f := ⟨fun x => f.1 (p⁻¹ x), by
obtain ⟨q,hq⟩ := f.2
refine ⟨q*p⁻¹, ?_⟩
funext x
simp only [hq,Function.comp_apply,Equiv.Perm.mul_apply]⟩
invFun f := ⟨fun x => f.1 (p x), by
obtain ⟨q,hq⟩ := f.2
refine ⟨q*p, ?_⟩
funext x
simp only [hq,Function.comp_apply,Equiv.Perm.mul_apply]⟩
left_inv f := by apply Subtype.ext; funext x; simp
right_inv f := by apply Subtype.ext; funext x; simp
@[simp] lemma tabloidAct_apply {μ : YoungDiagram} (p : Equiv.Perm (Cell μ))
(f : Tabloid μ) (x : Cell μ) : (tabloidAct p f).1 x = f.1 (p⁻¹ x) := rfl
@[simp] lemma tabloidAct_one (μ : YoungDiagram) : tabloidAct (1 : Equiv.Perm (Cell μ)) = 1 := by
ext f x
rfl
@[simp] lemma tabloidAct_mul {μ : YoungDiagram} (p q : Equiv.Perm (Cell μ)) :
tabloidAct (p*q) = tabloidAct p * tabloidAct q := by
ext f x
simp only [tabloidAct_apply, mul_inv_rev,Equiv.Perm.mul_apply]
noncomputable def tabloidRep (μ : YoungDiagram) :
Representation ℂ (Equiv.Perm (Cell μ)) (Tabloid μ → ℂ) where
toFun p :=
{ toFun := fun v f => v (tabloidAct p⁻¹ f)
map_add' := by intros; rfl
map_smul' := by intros; rfl }
map_one' := by ext v f; simp
map_mul' p q := by
ext v f
simp only [mul_inv_rev,tabloidAct_mul,Equiv.Perm.mul_apply]
rfl
noncomputable def delta {μ : YoungDiagram} (f : Tabloid μ) : Tabloid μ → ℂ :=
fun g => if g=f then 1 else 0
noncomputable def colGroup (μ : YoungDiagram) : Subgroup (Equiv.Perm (Cell μ)) where
carrier := {p | ∀ x, col (p x) = col x}
one_mem' := by intro x; rfl
mul_mem' := by intro p q hp hq x; exact (hp (q x)).trans (hq x)
inv_mem' := by intro p hp x; simpa using (hp (p⁻¹ x)).symm
noncomputable def permSign {α : Type*} [Fintype α] [DecidableEq α] (p : Equiv.Perm α) : ℂ :=
((Equiv.Perm.sign p : ℤ) : ℂ)
section
variable {α V : Type*} [Fintype α] [DecidableEq α] [AddCommGroup V] [Module ℂ V]
noncomputable def alternator (C : Subgroup (Equiv.Perm α))
(ρ : Representation ℂ (Equiv.Perm α) V) : Module.End ℂ V := by
classical
exact ∑ c : C, permSign (c : Equiv.Perm α) • ρ c
end
noncomputable def polytabloid (μ : YoungDiagram) : Tabloid μ → ℂ :=
alternator (colGroup μ) (tabloidRep μ) (delta (baseTabloid μ))
noncomputable def space (μ : YoungDiagram) : Submodule ℂ (Tabloid μ → ℂ) :=
Submodule.span ℂ (Set.range (fun p : Equiv.Perm (Cell μ) => tabloidRep μ p (polytabloid μ)))
lemma orbit_mem_space (μ : YoungDiagram) (p : Equiv.Perm (Cell μ)) :
tabloidRep μ p (polytabloid μ) ∈ space μ := Submodule.subset_span ⟨p,rfl⟩
lemma action_mem_space (μ : YoungDiagram) (p : Equiv.Perm (Cell μ))
(v : Tabloid μ → ℂ) (hv : v ∈ space μ) : tabloidRep μ p v ∈ space μ := by
induction hv using Submodule.span_induction with
| mem v hv =>
obtain ⟨q,rfl⟩ := hv
change ((tabloidRep μ p)*(tabloidRep μ q)) (polytabloid μ) ∈ space μ
rw [←map_mul]
exact orbit_mem_space μ (p*q)
| zero => simp
| add v w hv hw ihv ihw => simpa using (space μ).add_mem ihv ihw
| smul a v hv ih => simpa using (space μ).smul_mem a ih
noncomputable def subrepresentation (μ : YoungDiagram) : Subrepresentation (tabloidRep μ) :=
⟨space μ, fun p v hv => action_mem_space μ p v hv⟩
noncomputable def representation (μ : YoungDiagram) :
Representation ℂ (Equiv.Perm (Cell μ)) (space μ) :=
(subrepresentation μ).toRepresentation
end Thorp.Specht
namespace Thorp.PermutationHilbert
open scoped BigOperators ComplexConjugate Classical
open Complex
variable {X : Type*} [Fintype X]
abbrev H (X : Type*) [Fintype X] := EuclideanSpace ℂ X
end Thorp.PermutationHilbert
namespace Thorp.Specht
open scoped BigOperators Classical
noncomputable def hilbertEquiv (μ : YoungDiagram) :
(Tabloid μ → ℂ) ≃ₗ[ℂ] PermutationHilbert.H (Tabloid μ) :=
(WithLp.linearEquiv 2 ℂ (Tabloid μ → ℂ)).symm
noncomputable def hilbertSpace (μ : YoungDiagram) :
Submodule ℂ (PermutationHilbert.H (Tabloid μ)) := (space μ).map (hilbertEquiv μ).toLinearMap
end Thorp.Specht
namespace Thorp.UnitaryFinite
section
open scoped BigOperators ComplexConjugate Classical
variable {G : Type*} [Group G] [Fintype G]
variable {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V] [FiniteDimensional ℂ V]
noncomputable def continuousRepresentation (ρ : Representation ℂ G V) : G →* (V →L[ℂ] V) where
toFun g := (ρ g).toContinuousLinearMap
map_one' := by ext v; simp
map_mul' g h := by ext v; simp
end
open scoped BigOperators Classical
variable {G : Type*} [Group G] [Fintype G]
variable {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V] [FiniteDimensional ℂ V]
variable {Ω Ξ : Type*} [Fintype Ω] [Fintype Ξ]
noncomputable def sampleOperator (ρ : Representation ℂ G V) (P : Ω → G) : V →L[ℂ] V :=
(Fintype.card Ω:ℂ)⁻¹ • ∑ ω,continuousRepresentation ρ (P ω)
end Thorp.UnitaryFinite
namespace Thorp.Specht
open scoped BigOperators Classical
noncomputable def spaceHilbertEquiv (μ : YoungDiagram) : space μ ≃ₗ[ℂ] hilbertSpace μ :=
(hilbertEquiv μ).submoduleMap (space μ)
noncomputable def unitaryRepresentation (μ : YoungDiagram) :
Representation ℂ (Equiv.Perm (Cell μ)) (hilbertSpace μ) :=
((spaceHilbertEquiv μ).conjAlgEquiv ℂ).toMonoidHom.comp (representation μ)
variable {α ι : Type*} [Fintype α] [Fintype ι]
noncomputable def relabelledUnitary (μ : YoungDiagram) (e : α ≃ Cell μ) :
Representation ℂ (Equiv.Perm α) (hilbertSpace μ) :=
(unitaryRepresentation μ).comp e.permCongrHom.toMonoidHom
end Thorp.Specht
namespace Thorp.SparseContact
open scoped BigOperators
noncomputable def sweepOperator (d : ℕ) (μ : YoungDiagram)
(e : Card d ≃ Specht.Cell μ) (reverse : Bool) :
Specht.hilbertSpace μ →L[ℂ] Specht.hilbertSpace μ :=
UnitaryFinite.sampleOperator (V := Specht.hilbertSpace μ) (Specht.relabelledUnitary μ e)
(fun ω : SwitchIndex d → Bool => if reverse then
(butterflyPerm d (decodeButterfly d ω))⁻¹ else butterflyPerm d (decodeButterfly d ω))
end Thorp.SparseContact
namespace Thorp.StrongSmoothing
def coordinateRelabel (d : ℕ) (order : Equiv.Perm (Fin d)) : Equiv.Perm (Card d) where
toFun x := fun i => x (order.symm i)
invFun x := fun i => x (order i)
left_inv x := by funext i; simp
right_inv x := by funext i; simp
def sweep (d : ℕ) (order : Equiv.Perm (Fin d)) (ω : SwitchIndex d → Bool) :
Equiv.Perm (Card d) :=
coordinateRelabel d order * butterflyPerm d (decodeButterfly d ω) *
(coordinateRelabel d order)⁻¹
abbrev Tuples (d l : ℕ) := Fin l ↪ Card d
noncomputable def sweepKernel (d l : ℕ) (order : Equiv.Perm (Fin d)) :
Matrix (Tuples d l) (Tuples d l) ℝ :=
fun x y => PairRouting.tupleProbability (sweep d order) x y
noncomputable def reflectedKernel (d l : ℕ) (order : Equiv.Perm (Fin d)) (orientation : Bool) :
Matrix (Tuples d l) (Tuples d l) ℝ :=
let A := sweepKernel d l order
if orientation then A * A.transpose else A.transpose * A
end Thorp.StrongSmoothing
namespace Thorp.StrongTail
open scoped BigOperators Classical
section
open Specht
def tailDiagram (μ : YoungDiagram) : YoungDiagram :=
YoungDiagram.ofRowLens μ.rowLens.tail μ.rowLens_sorted.pairwise.tail.sortedGE
end
open StrongSmoothing
def DensityAt (p C : ℝ) : Prop :=
∀ (d l : ℕ), l ≤ 2^d → ∀ (order : Equiv.Perm (Fin d)) (rev : Bool)
(x : StrongSmoothing.Tuples d l),
let H := StrongSmoothing.reflectedKernel d l order rev
(Thorp.finiteMean (fun y => ((Fintype.card (StrongSmoothing.Tuples d l):ℝ)*H x y)^p)
≤ Real.exp (C*l)) ∧
(Thorp.finiteMean (fun y => ((Fintype.card (StrongSmoothing.Tuples d l):ℝ)*H y x)^p)
≤ Real.exp (C*l)) ∧
(((2:ℝ)^d)^l)⁻¹ * (∑ y, ((((2:ℝ)^d)^l)*H x y)^p) ≤ Real.exp (C*l) ∧
(((2:ℝ)^d)^l)⁻¹ * (∑ y, ((((2:ℝ)^d)^l)*H y x)^p) ≤ Real.exp (C*l)
end Thorp.StrongTail
namespace Thorp.StrongTail
open scoped BigOperators Classical
open Specht UnitaryFinite
def MainStatement : Prop :=
∃ p Cdensity C : ℝ, 1 < p ∧ p ≤ 2 ∧ DensityAt p Cdensity ∧
∀ (d : ℕ) (μ : YoungDiagram) (e : Card d ≃ Specht.Cell μ) (rev : Bool),
‖SparseContact.sweepOperator d μ e rev‖^2 ≤
Real.exp (C*(μ.card-μ.rowLen 0 : ℕ)) *
(Module.finrank ℂ (Specht.space (tailDiagram μ)):ℝ)^(-((p-1)/p))
end Thorp.StrongTail
end ThorpNine.Tail
end OAI

Xet Storage Details

Size:
12.3 kB
·
Xet hash:
90660ff54265b9edd830f8c603210acc83394adb4dfd0bbfbfd0262cdf6dd346

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.