refactor: Lorentz action on tensors
This commit is contained in:
parent
d385f72087
commit
757afbc60f
3 changed files with 298 additions and 119 deletions
|
@ -17,12 +17,13 @@ The Lorentz action is currently only defined for finite and decidable types `X`.
|
|||
|
||||
namespace RealLorentzTensor
|
||||
|
||||
variable {d : ℕ} {X : Type} [Fintype X] [DecidableEq X] (T : RealLorentzTensor d X) (c : X → Colors)
|
||||
variable {d : ℕ} {X Y : Type} [Fintype X] [DecidableEq X] [Fintype Y] [DecidableEq Y]
|
||||
variable (T : RealLorentzTensor d X) (c : X → Colors)
|
||||
variable (Λ Λ' : LorentzGroup d)
|
||||
open LorentzGroup
|
||||
open BigOperators
|
||||
|
||||
instance : Fintype (IndexValue d c) := Pi.fintype
|
||||
|
||||
variable {μ : Colors}
|
||||
|
||||
/-- Monoid homomorphism from the Lorentz group to matrices indexed by `ColorsIndex d μ` for a
|
||||
|
@ -56,88 +57,159 @@ def colorMatrix (μ : Colors) : LorentzGroup d →* Matrix (ColorsIndex d μ) (C
|
|||
Matrix.transpose_mul, Matrix.transpose_apply]
|
||||
rfl
|
||||
|
||||
/-- A real number occuring in the action of the Lorentz group on Lorentz tensors. -/
|
||||
@[simp]
|
||||
def prodColorMatrixOnIndexValue (i j : IndexValue d c) : ℝ :=
|
||||
∏ x, colorMatrix (c x) Λ (i x) (j x)
|
||||
|
||||
/-- `prodColorMatrixOnIndexValue` evaluated at `1` on the diagonal returns `1`. -/
|
||||
lemma one_prodColorMatrixOnIndexValue_on_diag (i : IndexValue d c) :
|
||||
prodColorMatrixOnIndexValue c 1 i i = 1 := by
|
||||
simp only [prodColorMatrixOnIndexValue]
|
||||
rw [Finset.prod_eq_one]
|
||||
intro x _
|
||||
simp only [colorMatrix, MonoidHom.map_one, Matrix.one_apply]
|
||||
lemma colorMatrix_cast {μ ν : Colors} (h : μ = ν) (Λ : LorentzGroup d) :
|
||||
colorMatrix μ Λ =
|
||||
Matrix.reindex (castColorsIndex h).symm (castColorsIndex h).symm (colorMatrix ν Λ) := by
|
||||
subst h
|
||||
rfl
|
||||
|
||||
/-- `prodColorMatrixOnIndexValue` evaluated at `1` off the diagonal returns `0`. -/
|
||||
lemma one_prodColorMatrixOnIndexValue_off_diag {i j : IndexValue d c} (hij : j ≠ i) :
|
||||
prodColorMatrixOnIndexValue c 1 i j = 0 := by
|
||||
simp only [prodColorMatrixOnIndexValue]
|
||||
obtain ⟨x, hijx⟩ := Function.ne_iff.mp hij
|
||||
rw [@Finset.prod_eq_zero _ _ _ _ _ x]
|
||||
exact Finset.mem_univ x
|
||||
simp only [map_one]
|
||||
exact Matrix.one_apply_ne' hijx
|
||||
/-- A real number occuring in the action of the Lorentz group on Lorentz tensors. -/
|
||||
@[simps!]
|
||||
def toTensorRepMat {c : X → Colors} :
|
||||
LorentzGroup d →* Matrix (IndexValue d c) (IndexValue d c) ℝ where
|
||||
toFun Λ := fun i j => ∏ x, colorMatrix (c x) Λ (i x) (j x)
|
||||
map_one' := by
|
||||
ext i j
|
||||
by_cases hij : i = j
|
||||
· subst hij
|
||||
simp only [map_one, Matrix.one_apply_eq, Finset.prod_const_one]
|
||||
· obtain ⟨x, hijx⟩ := Function.ne_iff.mp hij
|
||||
simp only [map_one]
|
||||
rw [@Finset.prod_eq_zero _ _ _ _ _ x]
|
||||
exact Eq.symm (Matrix.one_apply_ne' fun a => hij (id (Eq.symm a)))
|
||||
exact Finset.mem_univ x
|
||||
exact Matrix.one_apply_ne' (id (Ne.symm hijx))
|
||||
map_mul' Λ Λ' := by
|
||||
ext i j
|
||||
rw [Matrix.mul_apply]
|
||||
trans ∑ (k : IndexValue d c), ∏ x,
|
||||
(colorMatrix (c x) Λ (i x) (k x)) * (colorMatrix (c x) Λ' (k x) (j x))
|
||||
have h1 : ∑ (k : IndexValue d c), ∏ x,
|
||||
(colorMatrix (c x) Λ (i x) (k x)) * (colorMatrix (c x) Λ' (k x) (j x)) =
|
||||
∏ x, ∑ y, (colorMatrix (c x) Λ (i x) y) * (colorMatrix (c x) Λ' y (j x)) := by
|
||||
rw [Finset.prod_sum]
|
||||
simp only [Finset.prod_attach_univ, Finset.sum_univ_pi]
|
||||
apply Finset.sum_congr
|
||||
simp only [IndexValue, Fintype.piFinset_univ]
|
||||
intro x _
|
||||
rfl
|
||||
rw [h1]
|
||||
simp only [map_mul]
|
||||
exact Finset.prod_congr rfl (fun x _ => rfl)
|
||||
refine Finset.sum_congr rfl (fun k _ => ?_)
|
||||
rw [Finset.prod_mul_distrib]
|
||||
|
||||
lemma mul_prodColorMatrixOnIndexValue (i j : IndexValue d c) :
|
||||
prodColorMatrixOnIndexValue c (Λ * Λ') i j =
|
||||
∑ (k : IndexValue d c),
|
||||
∏ x, (colorMatrix (c x) Λ (i x) (k x)) * (colorMatrix (c x) Λ' (k x) (j x)) := by
|
||||
have h1 : ∑ (k : IndexValue d c), ∏ x,
|
||||
(colorMatrix (c x) Λ (i x) (k x)) * (colorMatrix (c x) Λ' (k x) (j x)) =
|
||||
∏ x, ∑ y, (colorMatrix (c x) Λ (i x) y) * (colorMatrix (c x) Λ' y (j x)) := by
|
||||
rw [Finset.prod_sum]
|
||||
simp only [Finset.prod_attach_univ, Finset.sum_univ_pi]
|
||||
apply Finset.sum_congr
|
||||
simp only [IndexValue, Fintype.piFinset_univ]
|
||||
intro x _
|
||||
rfl
|
||||
rw [h1]
|
||||
simp only [prodColorMatrixOnIndexValue, map_mul]
|
||||
exact Finset.prod_congr rfl (fun x _ => rfl)
|
||||
lemma toTensorRepMat_mul' (i j : IndexValue d c) :
|
||||
toTensorRepMat (Λ * Λ') i j = ∑ (k : IndexValue d c),
|
||||
∏ x, colorMatrix (c x) Λ (i x) (k x) * colorMatrix (c x) Λ' (k x) (j x) := by
|
||||
simp [Matrix.mul_apply]
|
||||
refine Finset.sum_congr rfl (fun k _ => ?_)
|
||||
rw [Finset.prod_mul_distrib]
|
||||
rfl
|
||||
|
||||
@[simp]
|
||||
lemma toTensorRepMat_on_sum {cX : X → Colors} {cY : Y → Colors}
|
||||
(i j : IndexValue d (sumElimIndexColor cX cY)) :
|
||||
toTensorRepMat Λ i j = toTensorRepMat Λ (inlIndexValue i) (inlIndexValue j) *
|
||||
toTensorRepMat Λ (inrIndexValue i) (inrIndexValue j) := by
|
||||
simp only [toTensorRepMat_apply]
|
||||
rw [Fintype.prod_sum_type]
|
||||
rfl
|
||||
|
||||
open Marked
|
||||
|
||||
lemma toTensorRepMap_on_splitIndexValue (T : Marked d X n)
|
||||
(i : T.UnmarkedIndexValue) (k : T.MarkedIndexValue) (j : IndexValue d T.color) :
|
||||
toTensorRepMat Λ (splitIndexValue.symm (i, k)) j =
|
||||
toTensorRepMat Λ i (toUnmarkedIndexValue j) *
|
||||
toTensorRepMat Λ k (toMarkedIndexValue j) := by
|
||||
simp only [toTensorRepMat_apply]
|
||||
rw [Fintype.prod_sum_type]
|
||||
rfl
|
||||
|
||||
/-!
|
||||
|
||||
## Definition of the Lorentz group action on Real Lorentz Tensors.
|
||||
|
||||
-/
|
||||
|
||||
/-- Action of the Lorentz group on `X`-indexed Real Lorentz Tensors. -/
|
||||
@[simps!]
|
||||
instance lorentzAction : MulAction (LorentzGroup d) (RealLorentzTensor d X) where
|
||||
smul Λ T := {color := T.color,
|
||||
coord := fun i => ∑ j, prodColorMatrixOnIndexValue T.color Λ i j * T.coord j}
|
||||
coord := fun i => ∑ j, toTensorRepMat Λ i j * T.coord j}
|
||||
one_smul T := by
|
||||
refine ext' rfl ?_
|
||||
funext i
|
||||
simp only [HSMul.hSMul, map_one]
|
||||
erw [Finset.sum_eq_single_of_mem i]
|
||||
rw [one_prodColorMatrixOnIndexValue_on_diag]
|
||||
simp only [one_mul, IndexValue]
|
||||
simp only [Matrix.one_apply_eq, one_mul, IndexValue]
|
||||
rfl
|
||||
exact Finset.mem_univ i
|
||||
intro j _ hij
|
||||
rw [one_prodColorMatrixOnIndexValue_off_diag]
|
||||
simp only [zero_mul]
|
||||
exact hij
|
||||
exact fun j _ hij => mul_eq_zero.mpr (Or.inl (Matrix.one_apply_ne' hij))
|
||||
mul_smul Λ Λ' T := by
|
||||
refine ext' rfl ?_
|
||||
simp only [HSMul.hSMul]
|
||||
funext i
|
||||
have h1 : ∑ j : IndexValue d T.color, prodColorMatrixOnIndexValue T.color (Λ * Λ') i j
|
||||
have h1 : ∑ j : IndexValue d T.color, toTensorRepMat (Λ * Λ') i j
|
||||
* T.coord j = ∑ j : IndexValue d T.color, ∑ (k : IndexValue d T.color),
|
||||
(∏ x, ((colorMatrix (T.color x) Λ (i x) (k x)) *
|
||||
(colorMatrix (T.color x) Λ' (k x) (j x)))) * T.coord j := by
|
||||
refine Finset.sum_congr rfl (fun j _ => ?_)
|
||||
rw [mul_prodColorMatrixOnIndexValue, Finset.sum_mul]
|
||||
rw [toTensorRepMat_mul', Finset.sum_mul]
|
||||
rw [h1]
|
||||
rw [Finset.sum_comm]
|
||||
refine Finset.sum_congr rfl (fun j _ => ?_)
|
||||
rw [Finset.mul_sum]
|
||||
refine Finset.sum_congr rfl (fun k _ => ?_)
|
||||
simp only [prodColorMatrixOnIndexValue, IndexValue]
|
||||
simp only [toTensorRepMat, IndexValue]
|
||||
rw [← mul_assoc]
|
||||
congr
|
||||
rw [Finset.prod_mul_distrib]
|
||||
rfl
|
||||
|
||||
/-!
|
||||
|
||||
## The Lorentz action on marked tensors.
|
||||
|
||||
-/
|
||||
|
||||
@[simps!]
|
||||
instance : MulAction (LorentzGroup d) (Marked d X n) := lorentzAction
|
||||
instance : MulAction (LorentzGroup d) (Marked d X n) := lorentzAction
|
||||
|
||||
lemma lorentzAction_on_splitIndexValue' (T : Marked d X n)
|
||||
(i : T.UnmarkedIndexValue) (k : T.MarkedIndexValue) :
|
||||
(Λ • T).coord (splitIndexValue.symm (i, k)) =
|
||||
∑ (x : T.UnmarkedIndexValue), ∑ (y : T.MarkedIndexValue),
|
||||
(toTensorRepMat Λ i x * toTensorRepMat Λ k y) * T.coord (splitIndexValue.symm (x, y)) := by
|
||||
erw [lorentzAction_smul_coord]
|
||||
erw [← Equiv.sum_comp splitIndexValue.symm]
|
||||
rw [Fintype.sum_prod_type]
|
||||
refine Finset.sum_congr rfl (fun x _ => ?_)
|
||||
refine Finset.sum_congr rfl (fun y _ => ?_)
|
||||
erw [toTensorRepMap_on_splitIndexValue]
|
||||
rfl
|
||||
|
||||
@[simp]
|
||||
lemma lorentzAction_on_splitIndexValue (T : Marked d X n)
|
||||
(i : T.UnmarkedIndexValue) (k : T.MarkedIndexValue) :
|
||||
(Λ • T).coord (splitIndexValue.symm (i, k)) =
|
||||
∑ (x : T.UnmarkedIndexValue), toTensorRepMat Λ i x *
|
||||
∑ (y : T.MarkedIndexValue), toTensorRepMat Λ k y *
|
||||
T.coord (splitIndexValue.symm (x, y)) := by
|
||||
rw [lorentzAction_on_splitIndexValue']
|
||||
refine Finset.sum_congr rfl (fun x _ => ?_)
|
||||
rw [Finset.mul_sum]
|
||||
refine Finset.sum_congr rfl (fun y _ => ?_)
|
||||
rw [NonUnitalRing.mul_assoc]
|
||||
|
||||
|
||||
/-!
|
||||
|
||||
## Properties of the Lorentz action.
|
||||
|
||||
-/
|
||||
|
||||
|
||||
/-- The action on an empty Lorentz tensor is trivial. -/
|
||||
lemma lorentzAction_on_isEmpty [IsEmpty X] (Λ : LorentzGroup d) (T : RealLorentzTensor d X) :
|
||||
|
@ -146,8 +218,62 @@ lemma lorentzAction_on_isEmpty [IsEmpty X] (Λ : LorentzGroup d) (T : RealLorent
|
|||
funext i
|
||||
erw [lorentzAction_smul_coord]
|
||||
simp only [Finset.univ_unique, Finset.univ_eq_empty, Finset.prod_empty, one_mul,
|
||||
Finset.sum_singleton]
|
||||
simp only [IndexValue, Unique.eq_default]
|
||||
Finset.sum_singleton, toTensorRepMat_apply]
|
||||
erw [toTensorRepMat_apply]
|
||||
simp only [IndexValue, toTensorRepMat, Unique.eq_default]
|
||||
rw [@mul_left_eq_self₀]
|
||||
exact Or.inl rfl
|
||||
|
||||
/-- The Lorentz action commutes with `congrSet`. -/
|
||||
lemma lorentzAction_comm_congrSet (f : X ≃ Y) (Λ : LorentzGroup d) (T : RealLorentzTensor d X) :
|
||||
congrSet f (Λ • T) = Λ • (congrSet f T) := by
|
||||
refine ext' rfl ?_
|
||||
funext i
|
||||
erw [lorentzAction_smul_coord, lorentzAction_smul_coord]
|
||||
erw [← Equiv.sum_comp (congrSetIndexValue d f T.color)]
|
||||
refine Finset.sum_congr rfl (fun j _ => ?_)
|
||||
simp [toTensorRepMat]
|
||||
erw [← Equiv.prod_comp f]
|
||||
apply Or.inl
|
||||
congr
|
||||
funext x
|
||||
have h1 : (T.color (f.symm (f x))) = T.color x := by
|
||||
simp only [Equiv.symm_apply_apply]
|
||||
rw [colorMatrix_cast h1]
|
||||
simp only [Matrix.reindex_apply, Equiv.symm_symm, Matrix.submatrix_apply]
|
||||
erw [castColorsIndex_comp_congrSetIndexValue]
|
||||
apply congrFun
|
||||
apply congrArg
|
||||
symm
|
||||
refine cast_eq_iff_heq.mpr ?_
|
||||
simp only [congrSetIndexValue, Equiv.piCongrLeft'_symm_apply, heq_eqRec_iff_heq, heq_eq_eq]
|
||||
rfl
|
||||
|
||||
open Marked
|
||||
|
||||
lemma lorentzAction_comm_mul (T : Marked d X 1) (S : Marked d Y 1)
|
||||
(h : T.markedColor 0 = τ (S.markedColor 1)) :
|
||||
mul (Λ • T) (Λ • S) h = Λ • mul T S h := by
|
||||
refine ext' rfl ?_
|
||||
funext i
|
||||
trans ∑ j, toTensorRepMat Λ (inlIndexValue i) (inlIndexValue j) *
|
||||
toTensorRepMat Λ (inrIndexValue i) (inrIndexValue j)
|
||||
* (mul T S h).coord j
|
||||
swap
|
||||
refine Finset.sum_congr rfl (fun j _ => ?_)
|
||||
erw [toTensorRepMat_on_sum]
|
||||
rfl
|
||||
change ∑ x, (∑ j, toTensorRepMat Λ (splitIndexValue.symm
|
||||
(inlIndexValue i, T.oneMarkedIndexValue x)) j * T.coord j) *
|
||||
(∑ k, toTensorRepMat Λ _ k * S.coord k) = _
|
||||
trans ∑ x, (∑ j,
|
||||
toTensorRepMat Λ (inlIndexValue i) (toUnmarkedIndexValue j)
|
||||
* toTensorRepMat Λ (T.oneMarkedIndexValue x) (toMarkedIndexValue j)
|
||||
* T.coord j) *
|
||||
|
||||
sorry
|
||||
|
||||
|
||||
|
||||
/-! TODO: Show that the Lorentz action commutes with multiplication. -/
|
||||
/-! TODO: Show that the Lorentz action commutes with contraction. -/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue