Imports
/-
Copyright (c) 2024 Joseph Tooby-Smith. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Joseph Tooby-Smith
-/
module
public import Physlib.QFT.AnomalyCancellation.Basic
public import Mathlib.Tactic.LinearCombinationAnomaly cancellation conditions for the n-family SM.
We define the ACC system for the Standard Model withn-families and no RHN.
@[expose] public sectionAssociate to each (including RHN) SM fermion a set of charges
@[simps!]
def SMCharges (n : ℕ) : ACCSystemCharges := ⟨5 * n⟩The vector space associated with a single species of fermions.
@[simps!]
def SMSpecies (n : ℕ) : ACCSystemCharges := ⟨n⟩lemma sum_SMSpecies_numberCharges_one {M} [AddCommMonoid M]
(f : Fin (SMSpecies 1).numberCharges → M) :
∑ i, f i = f ⟨0, n:ℕM:Type ?u.4inst✝:AddCommMonoid Mf:Fin (SMSpecies 1).numberCharges → M⊢ 0 < (SMSpecies 1).numberCharges All goals completed! 🐙⟩ := M:Type u_1inst✝:AddCommMonoid Mf:Fin (SMSpecies 1).numberCharges → M⊢ ∑ i, f i = f ⟨0, ⋯⟩
M:Type u_1inst✝:AddCommMonoid Mf:Fin (SMSpecies 1).numberCharges → M⊢ ∑ i, f i = f ⟨0, ⋯⟩
M:Type u_1inst✝:AddCommMonoid Mf:Fin (SMSpecies 1).numberCharges → M⊢ f 0 = f ⟨0, ⋯⟩
All goals completed! 🐙
An equivalence between the set (SMCharges n).charges and the set
(Fin 5 → Fin n → ℚ).
@[simps!]
def toSpeciesEquiv : (SMCharges n).Charges ≃ (Fin 5 → Fin (SMSpecies n).numberCharges → ℚ) :=
((Equiv.curry _ _ _).symm.trans ((@finProdFinEquiv 5
(SMSpecies n).numberCharges).arrowCongr (Equiv.refl ℚ))).symm
For a given i ∈ Fin 5, the projection of a charge onto that species.
@[simps!]
def toSpecies (i : Fin 5) : (SMCharges n).Charges →ₗ[ℚ] (SMSpecies n).Charges where
toFun S := toSpeciesEquiv S i
map_add' _ _ := n:ℕi:Fin 5x✝¹:(SMCharges n).Chargesx✝:(SMCharges n).Charges⊢ toSpeciesEquiv (x✝¹ + x✝) i = toSpeciesEquiv x✝¹ i + toSpeciesEquiv x✝ i All goals completed! 🐙
map_smul' _ _ := n:ℕi:Fin 5x✝¹:ℚx✝:(SMCharges n).Charges⊢ toSpeciesEquiv (x✝¹ • x✝) i = (RingHom.id ℚ) x✝¹ • toSpeciesEquiv x✝ i All goals completed! 🐙lemma toSpecies_apply_eq (i : Fin 5) (S : (SMCharges n).Charges) :
toSpecies i S = fun j => toSpeciesEquiv S i j := n:ℕi:Fin 5S:(SMCharges n).Charges⊢ (toSpecies i) S = fun j => toSpeciesEquiv S i j All goals completed! 🐙lemma charges_eq_toSpecies_eq (S T : (SMCharges n).Charges) :
S = T ↔ ∀ i, toSpecies i S = toSpecies i T := n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ S = T ↔ ∀ (i : Fin 5), (toSpecies i) S = (toSpecies i) T
n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (i : Fin 5), (toSpecies i) S = (toSpecies i) T⊢ S = T
n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (i : Fin 5), (toSpecies i) S = (toSpecies i) T⊢ toSpeciesEquiv S = toSpeciesEquiv T
All goals completed! 🐙lemma toSMSpecies_toSpecies_inv (i : Fin 5) (f : Fin 5 → Fin n → ℚ) :
(toSpecies i) (toSpeciesEquiv.symm f) = f i := n:ℕi:Fin 5f:Fin 5 → Fin n → ℚ⊢ (toSpecies i) (toSpeciesEquiv.symm f) = f i
n:ℕi:Fin 5f:Fin 5 → Fin n → ℚ⊢ (⇑toSpeciesEquiv ∘ ⇑toSpeciesEquiv.symm) f i = f i
All goals completed! 🐙
The Q charges as a map Fin n → ℚ.
abbrev Q := @toSpecies n 0
The U charges as a map Fin n → ℚ.
abbrev U := @toSpecies n 1
The D charges as a map Fin n → ℚ.
abbrev D := @toSpecies n 2
The L charges as a map Fin n → ℚ.
abbrev L := @toSpecies n 3
The E charges as a map Fin n → ℚ.
abbrev E := @toSpecies n 4The gravitational anomaly equation.
n:ℕa:ℚS:(SMCharges n).Charges⊢ 6 * (a * ∑ i, toSpeciesEquiv S 0 i) + 3 * (a * ∑ i, toSpeciesEquiv S 1 i) + 3 * (a * ∑ i, toSpeciesEquiv S 2 i) +
2 * (a * ∑ i, toSpeciesEquiv S 3 i) +
a * ∑ i, toSpeciesEquiv S 4 i =
a *
(6 * ∑ i, toSpeciesEquiv S 0 i + 3 * ∑ i, toSpeciesEquiv S 1 i + 3 * ∑ i, toSpeciesEquiv S 2 i +
2 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, toSpeciesEquiv S 4 x)
--rw [show Rat.cast a = a from rfl]
ring All goals completed! 🐙
Extensionality lemma for accGrav.
lemma accGrav_ext {S T : (SMCharges n).Charges}
(hj : ∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i) :
accGrav S = accGrav T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ accGrav S = accGrav T
simp only [accGrav, toSpecies_apply, Fin.isValue, LinearMap.coe_mk,
AddHom.coe_mk] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x,
(6 * toSpeciesEquiv S 0 x + 3 * toSpeciesEquiv S 1 x + 3 * toSpeciesEquiv S 2 x + 2 * toSpeciesEquiv S 3 x +
toSpeciesEquiv S 4 x) =
∑ x,
(6 * toSpeciesEquiv T 0 x + 3 * toSpeciesEquiv T 1 x + 3 * toSpeciesEquiv T 2 x + 2 * toSpeciesEquiv T 3 x +
toSpeciesEquiv T 4 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, (6 * toSpeciesEquiv S 0 x + 3 * toSpeciesEquiv S 1 x + 3 * toSpeciesEquiv S 2 x + 2 * toSpeciesEquiv S 3 x) +
∑ x, toSpeciesEquiv S 4 x =
∑ x,
(6 * toSpeciesEquiv T 0 x + 3 * toSpeciesEquiv T 1 x + 3 * toSpeciesEquiv T 2 x + 2 * toSpeciesEquiv T 3 x +
toSpeciesEquiv T 4 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 6 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv S 1 x + ∑ x, 3 * toSpeciesEquiv S 2 x +
∑ x, 2 * toSpeciesEquiv S 3 x +
∑ x, toSpeciesEquiv S 4 x =
∑ x, 6 * toSpeciesEquiv T 0 x + ∑ x, 3 * toSpeciesEquiv T 1 x + ∑ x, 3 * toSpeciesEquiv T 2 x +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 6 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv S 1 x + ∑ x, 3 * toSpeciesEquiv S 2 x +
∑ x, 2 * toSpeciesEquiv S 3 x +
∑ x, toSpeciesEquiv S 4 x =
∑ x, (6 * toSpeciesEquiv T 0 x + 3 * toSpeciesEquiv T 1 x) + ∑ x, 3 * toSpeciesEquiv T 2 x +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 6 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv S 1 x + ∑ x, 3 * toSpeciesEquiv S 2 x +
∑ x, 2 * toSpeciesEquiv S 3 x +
∑ x, toSpeciesEquiv S 4 x =
∑ x, 6 * toSpeciesEquiv T 0 x + ∑ x, 3 * toSpeciesEquiv T 1 x + ∑ x, 3 * toSpeciesEquiv T 2 x +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 6 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv S 1 x + ∑ x, 3 * toSpeciesEquiv S 2 x +
∑ x, 2 * toSpeciesEquiv S 3 x +
∑ x, toSpeciesEquiv S 4 x =
∑ x, 6 * toSpeciesEquiv T 0 x + ∑ x, 3 * toSpeciesEquiv T 1 x + ∑ x, 3 * toSpeciesEquiv T 2 x +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 6 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, 3 * toSpeciesEquiv S 1 x + ∑ x, 3 * toSpeciesEquiv S 2 x +
∑ x, 2 * toSpeciesEquiv S 3 x +
∑ x, toSpeciesEquiv S 4 x =
∑ x, 6 * toSpeciesEquiv T 0 x + ∑ x, 3 * toSpeciesEquiv T 1 x + ∑ x, 3 * toSpeciesEquiv T 2 x +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 6 * ∑ i, toSpeciesEquiv S 0 i + 3 * ∑ i, toSpeciesEquiv S 1 i + 3 * ∑ i, toSpeciesEquiv S 2 i +
2 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, toSpeciesEquiv S 4 x =
6 * ∑ i, toSpeciesEquiv T 0 i + 3 * ∑ i, toSpeciesEquiv T 1 i + 3 * ∑ i, toSpeciesEquiv T 2 i +
2 * ∑ i, toSpeciesEquiv T 3 i +
∑ x, toSpeciesEquiv T 4 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 6 * ∑ i, toSpeciesEquiv S 0 i + 3 * ∑ i, toSpeciesEquiv S 1 i + 3 * ∑ i, toSpeciesEquiv S 2 i +
2 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, toSpeciesEquiv S 4 x =
6 * ∑ i, toSpeciesEquiv T 0 i + 3 * ∑ i, toSpeciesEquiv T 1 i + 3 * ∑ i, toSpeciesEquiv T 2 i +
∑ x, 2 * toSpeciesEquiv T 3 x +
∑ x, toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 6 * ∑ i, toSpeciesEquiv S 0 i + 3 * ∑ i, toSpeciesEquiv S 1 i + 3 * ∑ i, toSpeciesEquiv S 2 i +
2 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, toSpeciesEquiv S 4 x =
6 * ∑ i, toSpeciesEquiv T 0 i + 3 * ∑ i, toSpeciesEquiv T 1 i + 3 * ∑ i, toSpeciesEquiv T 2 i +
2 * ∑ i, toSpeciesEquiv T 3 i +
∑ x, toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 6 * ∑ i, toSpeciesEquiv S 0 i + 3 * ∑ i, toSpeciesEquiv S 1 i + 3 * ∑ i, toSpeciesEquiv S 2 i +
2 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, toSpeciesEquiv S 4 x =
6 * ∑ i, toSpeciesEquiv T 0 i + 3 * ∑ i, toSpeciesEquiv T 1 i + 3 * ∑ i, toSpeciesEquiv T 2 i +
2 * ∑ i, toSpeciesEquiv T 3 i +
∑ x, toSpeciesEquiv T 4 x
simp_all All goals completed! 🐙
The SU(2) anomaly equation.
def accSU2 : (SMCharges n).Charges →ₗ[ℚ] ℚ where
toFun S := ∑ i, (3 * Q S i + L S i)
map_add' S T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * Q (S + T) i + L (S + T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i)
repeat rw [map_add n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * (Q S + Q T) i + L (S + T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * (Q S + Q T) i + (L S + L T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * (Q S + Q T) i + L (S + T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * (Q S + Q T) i + (L S + L T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (3 * (Q S + Q T) i + (L S + L T) i) = ∑ i, (3 * Q S i + L S i) + ∑ i, (3 * Q T i + L T i)
simp only [ACCSystemCharges.chargesAddCommMonoid_add, toSpecies_apply,
Fin.isValue, mul_add] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, (3 * toSpeciesEquiv S 0 x + 3 * toSpeciesEquiv T 0 x + (toSpeciesEquiv S 3 x + toSpeciesEquiv T 3 x)) =
∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x) + ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, (3 * toSpeciesEquiv S 0 x + 3 * toSpeciesEquiv T 0 x) + ∑ x, (toSpeciesEquiv S 3 x + toSpeciesEquiv T 3 x) =
∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x) + ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 3 x + ∑ x, toSpeciesEquiv T 3 x) =
∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x +
(∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 3 x + ∑ x, toSpeciesEquiv T 3 x) =
∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x + ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 3 x + ∑ x, toSpeciesEquiv T 3 x) =
∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x +
(∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, 3 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 3 x + ∑ x, toSpeciesEquiv T 3 x) =
∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x +
(∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x)
ring All goals completed! 🐙
map_smul' a S := by n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * Q (a • S) i + L (a • S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i)
repeat rw [map_smul n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * (a • Q S) i + L (a • S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * (a • Q S) i + (a • L S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * (a • Q S) i + L (a • S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * (a • Q S) i + (a • L S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (3 * (a • Q S) i + (a • L S) i) = (RingHom.id ℚ) a • ∑ i, (3 * Q S i + L S i)
simp only [ HSMul.hSMul, SMul.smul, toSpecies_apply, Fin.isValue,
eq_ratCast, Rat.cast_eq_id, id_eq] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, (3 * (a * toSpeciesEquiv S 0 x) + a * toSpeciesEquiv S 3 x) =
a * ∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x)
repeat rw [Finset.sum_add_distrib n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 3 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 3 x =
a * ∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 3 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 3 x =
a * (∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 3 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 3 x =
a * ∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 3 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 3 x =
a * (∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 3 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 3 x =
a * (∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x)
repeat rw [← Finset.mul_sum n:ℕa:ℚS:(SMCharges n).Charges⊢ 3 * ∑ i, a * toSpeciesEquiv S 0 i + ∑ x, a * toSpeciesEquiv S 3 x =
a * (∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 3 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 3 i =
a * (3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x)] n:ℕa:ℚS:(SMCharges n).Charges⊢ 3 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 3 i =
a * (∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 3 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 3 i =
a * (3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 3 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 3 i =
a * (3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x)
--rw [show Rat.cast a = a from rfl]
ring All goals completed! 🐙
Extensionality lemma for accSU2.
lemma accSU2_ext {S T : (SMCharges n).Charges}
(hj : ∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i) :
accSU2 S = accSU2 T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ accSU2 S = accSU2 T
simp only [accSU2, toSpecies_apply, Fin.isValue, LinearMap.coe_mk,
AddHom.coe_mk] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, (3 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 3 x) = ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x = ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x = ∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x = ∑ x, (3 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 3 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x = ∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 3 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 3 x = ∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x = ∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x = 3 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 3 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x = ∑ x, 3 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 3 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x = 3 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 3 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 3 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 3 x = 3 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 3 x
exact Mathlib.Tactic.LinearCombination.add_eq_eq (congrArg (HMul.hMul 3) (hj 0)) (hj 3) All goals completed! 🐙
The SU(3) anomaly equations.
def accSU3 : (SMCharges n).Charges →ₗ[ℚ] ℚ where
toFun S := ∑ i, (2 * Q S i + U S i + D S i)
map_add' S T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * Q (S + T) i + U (S + T) i + D (S + T) i) = ∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i)
repeat rw [map_add n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * (Q S + Q T) i + U (S + T) i + D (S + T) i) =
∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * (Q S + Q T) i + (U S + U T) i + (D S + D T) i) =
∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * (Q S + Q T) i + (U S + U T) i + D (S + T) i) =
∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * (Q S + Q T) i + (U S + U T) i + (D S + D T) i) =
∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (2 * (Q S + Q T) i + (U S + U T) i + (D S + D T) i) =
∑ i, (2 * Q S i + U S i + D S i) + ∑ i, (2 * Q T i + U T i + D T i)
simp only [ACCSystemCharges.chargesAddCommMonoid_add, toSpecies_apply,
Fin.isValue, mul_add] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(2 * toSpeciesEquiv S 0 x + 2 * toSpeciesEquiv T 0 x + (toSpeciesEquiv S 1 x + toSpeciesEquiv T 1 x) +
(toSpeciesEquiv S 2 x + toSpeciesEquiv T 2 x)) =
∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x + toSpeciesEquiv S 2 x) +
∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x + toSpeciesEquiv T 2 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, (2 * toSpeciesEquiv S 0 x + 2 * toSpeciesEquiv T 0 x + (toSpeciesEquiv S 1 x + toSpeciesEquiv T 1 x)) +
∑ x, (toSpeciesEquiv S 2 x + toSpeciesEquiv T 2 x) =
∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x + toSpeciesEquiv S 2 x) +
∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x + toSpeciesEquiv T 2 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, 2 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv T 1 x) +
(∑ x, toSpeciesEquiv S 2 x + ∑ x, toSpeciesEquiv T 2 x) =
∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x +
(∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, 2 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv T 1 x) +
(∑ x, toSpeciesEquiv S 2 x + ∑ x, toSpeciesEquiv T 2 x) =
∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x +
(∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x) + ∑ x, toSpeciesEquiv T 2 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, 2 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv T 1 x) +
(∑ x, toSpeciesEquiv S 2 x + ∑ x, toSpeciesEquiv T 2 x) =
∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x +
(∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, 2 * toSpeciesEquiv T 0 x +
(∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv T 1 x) +
(∑ x, toSpeciesEquiv S 2 x + ∑ x, toSpeciesEquiv T 2 x) =
∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x +
(∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x)
ring All goals completed! 🐙
map_smul' a S := by n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * Q (a • S) i + U (a • S) i + D (a • S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i)
repeat rw [map_smul n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * (a • Q S) i + U (a • S) i + D (a • S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * (a • Q S) i + (a • U S) i + (a • D S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * (a • Q S) i + (a • U S) i + D (a • S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * (a • Q S) i + (a • U S) i + (a • D S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (2 * (a • Q S) i + (a • U S) i + (a • D S) i) = (RingHom.id ℚ) a • ∑ i, (2 * Q S i + U S i + D S i)
simp only [HSMul.hSMul, SMul.smul, toSpecies_apply, Fin.isValue,
eq_ratCast, Rat.cast_eq_id, id_eq] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, (2 * (a * toSpeciesEquiv S 0 x) + a * toSpeciesEquiv S 1 x + a * toSpeciesEquiv S 2 x) =
a * ∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x + toSpeciesEquiv S 2 x)
repeat rw [Finset.sum_add_distrib n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, (2 * (a * toSpeciesEquiv S 0 x) + a * toSpeciesEquiv S 1 x) + ∑ x, a * toSpeciesEquiv S 2 x =
a * ∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x + toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 2 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 1 x + ∑ x, a * toSpeciesEquiv S 2 x =
a * (∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 2 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 1 x + ∑ x, a * toSpeciesEquiv S 2 x =
a * (∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x) + ∑ x, toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 2 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 1 x + ∑ x, a * toSpeciesEquiv S 2 x =
a * (∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, 2 * (a * toSpeciesEquiv S 0 x) + ∑ x, a * toSpeciesEquiv S 1 x + ∑ x, a * toSpeciesEquiv S 2 x =
a * (∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x)
repeat rw [← Finset.mul_sum n:ℕa:ℚS:(SMCharges n).Charges⊢ 2 * ∑ i, a * toSpeciesEquiv S 0 i + ∑ x, a * toSpeciesEquiv S 1 x + ∑ x, a * toSpeciesEquiv S 2 x =
a * (∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 2 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 1 i + a * ∑ i, toSpeciesEquiv S 2 i =
a * (2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x)] n:ℕa:ℚS:(SMCharges n).Charges⊢ 2 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 1 i + a * ∑ i, toSpeciesEquiv S 2 i =
a * (∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 2 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 1 i + a * ∑ i, toSpeciesEquiv S 2 i =
a * (2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ 2 * (a * ∑ i, toSpeciesEquiv S 0 i) + a * ∑ i, toSpeciesEquiv S 1 i + a * ∑ i, toSpeciesEquiv S 2 i =
a * (2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x)
--rw [show Rat.cast a = a from rfl]
ring All goals completed! 🐙
Extensionality lemma for accSU3.
lemma accSU3_ext {S T : (SMCharges n).Charges}
(hj : ∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i) :
accSU3 S = accSU3 T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ accSU3 S = accSU3 T
simp only [accSU3, toSpecies_apply, Fin.isValue, LinearMap.coe_mk,
AddHom.coe_mk] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x + toSpeciesEquiv S 2 x) =
∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x + toSpeciesEquiv T 2 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, (2 * toSpeciesEquiv S 0 x + toSpeciesEquiv S 1 x) + ∑ x, toSpeciesEquiv S 2 x =
∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x + toSpeciesEquiv T 2 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, (2 * toSpeciesEquiv T 0 x + toSpeciesEquiv T 1 x) + ∑ x, toSpeciesEquiv T 2 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, 2 * toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
2 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
∑ x, 2 * toSpeciesEquiv T 0 x + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
2 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ 2 * ∑ i, toSpeciesEquiv S 0 i + ∑ x, toSpeciesEquiv S 1 x + ∑ x, toSpeciesEquiv S 2 x =
2 * ∑ i, toSpeciesEquiv T 0 i + ∑ x, toSpeciesEquiv T 1 x + ∑ x, toSpeciesEquiv T 2 x
simp_all All goals completed! 🐙
The Y² anomaly equation.
def accYY : (SMCharges n).Charges →ₗ[ℚ] ℚ where
toFun S := ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i
+ 6 * E S i)
map_add' S T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, (Q (S + T) i + 8 * U (S + T) i + 2 * D (S + T) i + 3 * L (S + T) i + 6 * E (S + T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i)
repeat rw [map_add n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, ((Q S + Q T) i + 8 * U (S + T) i + 2 * D (S + T) i + 3 * L (S + T) i + 6 * E (S + T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, ((Q S + Q T) i + 8 * (U S + U T) i + 2 * (D S + D T) i + 3 * (L S + L T) i + 6 * (E S + E T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, ((Q S + Q T) i + 8 * (U S + U T) i + 2 * (D S + D T) i + 3 * (L S + L T) i + 6 * E (S + T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, ((Q S + Q T) i + 8 * (U S + U T) i + 2 * (D S + D T) i + 3 * (L S + L T) i + 6 * (E S + E T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i, ((Q S + Q T) i + 8 * (U S + U T) i + 2 * (D S + D T) i + 3 * (L S + L T) i + 6 * (E S + E T) i) =
∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) +
∑ i, (Q T i + 8 * U T i + 2 * D T i + 3 * L T i + 6 * E T i)
simp only [ACCSystemCharges.chargesAddCommMonoid_add, toSpecies_apply,
Fin.isValue, mul_add] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(toSpeciesEquiv S 0 x + toSpeciesEquiv T 0 x + (8 * toSpeciesEquiv S 1 x + 8 * toSpeciesEquiv T 1 x) +
(2 * toSpeciesEquiv S 2 x + 2 * toSpeciesEquiv T 2 x) +
(3 * toSpeciesEquiv S 3 x + 3 * toSpeciesEquiv T 3 x) +
(6 * toSpeciesEquiv S 4 x + 6 * toSpeciesEquiv T 4 x)) =
∑ x,
(toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x +
6 * toSpeciesEquiv S 4 x) +
∑ x,
(toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x + 2 * toSpeciesEquiv T 2 x + 3 * toSpeciesEquiv T 3 x +
6 * toSpeciesEquiv T 4 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(toSpeciesEquiv S 0 x + toSpeciesEquiv T 0 x + (8 * toSpeciesEquiv S 1 x + 8 * toSpeciesEquiv T 1 x) +
(2 * toSpeciesEquiv S 2 x + 2 * toSpeciesEquiv T 2 x) +
(3 * toSpeciesEquiv S 3 x + 3 * toSpeciesEquiv T 3 x)) +
∑ x, (6 * toSpeciesEquiv S 4 x + 6 * toSpeciesEquiv T 4 x) =
∑ x,
(toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x +
6 * toSpeciesEquiv S 4 x) +
∑ x,
(toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x + 2 * toSpeciesEquiv T 2 x + 3 * toSpeciesEquiv T 3 x +
6 * toSpeciesEquiv T 4 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv T 0 x +
(∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 8 * toSpeciesEquiv T 1 x) +
(∑ x, 2 * toSpeciesEquiv S 2 x + ∑ x, 2 * toSpeciesEquiv T 2 x) +
(∑ x, 3 * toSpeciesEquiv S 3 x + ∑ x, 3 * toSpeciesEquiv T 3 x) +
(∑ x, 6 * toSpeciesEquiv S 4 x + ∑ x, 6 * toSpeciesEquiv T 4 x) =
∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x +
(∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv T 0 x +
(∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 8 * toSpeciesEquiv T 1 x) +
(∑ x, 2 * toSpeciesEquiv S 2 x + ∑ x, 2 * toSpeciesEquiv T 2 x) +
(∑ x, 3 * toSpeciesEquiv S 3 x + ∑ x, 3 * toSpeciesEquiv T 3 x) +
(∑ x, 6 * toSpeciesEquiv S 4 x + ∑ x, 6 * toSpeciesEquiv T 4 x) =
∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x +
(∑ x, (toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x) + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv T 0 x +
(∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 8 * toSpeciesEquiv T 1 x) +
(∑ x, 2 * toSpeciesEquiv S 2 x + ∑ x, 2 * toSpeciesEquiv T 2 x) +
(∑ x, 3 * toSpeciesEquiv S 3 x + ∑ x, 3 * toSpeciesEquiv T 3 x) +
(∑ x, 6 * toSpeciesEquiv S 4 x + ∑ x, 6 * toSpeciesEquiv T 4 x) =
∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x +
(∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, toSpeciesEquiv T 0 x +
(∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 8 * toSpeciesEquiv T 1 x) +
(∑ x, 2 * toSpeciesEquiv S 2 x + ∑ x, 2 * toSpeciesEquiv T 2 x) +
(∑ x, 3 * toSpeciesEquiv S 3 x + ∑ x, 3 * toSpeciesEquiv T 3 x) +
(∑ x, 6 * toSpeciesEquiv S 4 x + ∑ x, 6 * toSpeciesEquiv T 4 x) =
∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x +
(∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x)
ring All goals completed! 🐙
map_smul' a S := by n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, (Q (a • S) i + 8 * U (a • S) i + 2 * D (a • S) i + 3 * L (a • S) i + 6 * E (a • S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i)
repeat rw [map_smul n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, ((a • Q S) i + 8 * U (a • S) i + 2 * D (a • S) i + 3 * L (a • S) i + 6 * E (a • S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, ((a • Q S) i + 8 * (a • U S) i + 2 * (a • D S) i + 3 * (a • L S) i + 6 * (a • E S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, ((a • Q S) i + 8 * (a • U S) i + 2 * (a • D S) i + 3 * (a • L S) i + 6 * E (a • S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, ((a • Q S) i + 8 * (a • U S) i + 2 * (a • D S) i + 3 * (a • L S) i + 6 * (a • E S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ i, ((a • Q S) i + 8 * (a • U S) i + 2 * (a • D S) i + 3 * (a • L S) i + 6 * (a • E S) i) =
(RingHom.id ℚ) a • ∑ i, (Q S i + 8 * U S i + 2 * D S i + 3 * L S i + 6 * E S i)
simp only [HSMul.hSMul, SMul.smul, toSpecies_apply, Fin.isValue,
eq_ratCast, Rat.cast_eq_id, id_eq] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x,
(a * toSpeciesEquiv S 0 x + 8 * (a * toSpeciesEquiv S 1 x) + 2 * (a * toSpeciesEquiv S 2 x) +
3 * (a * toSpeciesEquiv S 3 x) +
6 * (a * toSpeciesEquiv S 4 x)) =
a *
∑ x,
(toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x +
6 * toSpeciesEquiv S 4 x)
repeat rw [Finset.sum_add_distrib n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x,
(a * toSpeciesEquiv S 0 x + 8 * (a * toSpeciesEquiv S 1 x) + 2 * (a * toSpeciesEquiv S 2 x) +
3 * (a * toSpeciesEquiv S 3 x)) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
∑ x,
(toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x +
6 * toSpeciesEquiv S 4 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, a * toSpeciesEquiv S 0 x + ∑ x, 8 * (a * toSpeciesEquiv S 1 x) + ∑ x, 2 * (a * toSpeciesEquiv S 2 x) +
∑ x, 3 * (a * toSpeciesEquiv S 3 x) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
(∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x)] n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, a * toSpeciesEquiv S 0 x + ∑ x, 8 * (a * toSpeciesEquiv S 1 x) + ∑ x, 2 * (a * toSpeciesEquiv S 2 x) +
∑ x, 3 * (a * toSpeciesEquiv S 3 x) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
(∑ x, (toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x) + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, a * toSpeciesEquiv S 0 x + ∑ x, 8 * (a * toSpeciesEquiv S 1 x) + ∑ x, 2 * (a * toSpeciesEquiv S 2 x) +
∑ x, 3 * (a * toSpeciesEquiv S 3 x) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
(∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ ∑ x, a * toSpeciesEquiv S 0 x + ∑ x, 8 * (a * toSpeciesEquiv S 1 x) + ∑ x, 2 * (a * toSpeciesEquiv S 2 x) +
∑ x, 3 * (a * toSpeciesEquiv S 3 x) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
(∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x)
repeat rw [← Finset.mul_sum n:ℕa:ℚS:(SMCharges n).Charges⊢ a * ∑ i, toSpeciesEquiv S 0 i + ∑ x, 8 * (a * toSpeciesEquiv S 1 x) + ∑ x, 2 * (a * toSpeciesEquiv S 2 x) +
∑ x, 3 * (a * toSpeciesEquiv S 3 x) +
∑ x, 6 * (a * toSpeciesEquiv S 4 x) =
a *
(∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ a * ∑ i, toSpeciesEquiv S 0 i + 8 * (a * ∑ i, toSpeciesEquiv S 1 i) + 2 * (a * ∑ i, toSpeciesEquiv S 2 i) +
3 * (a * ∑ i, toSpeciesEquiv S 3 i) +
6 * (a * ∑ i, toSpeciesEquiv S 4 i) =
a *
(∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i)] n:ℕa:ℚS:(SMCharges n).Charges⊢ a * ∑ i, toSpeciesEquiv S 0 i + 8 * (a * ∑ i, toSpeciesEquiv S 1 i) + 2 * (a * ∑ i, toSpeciesEquiv S 2 i) +
3 * (a * ∑ i, toSpeciesEquiv S 3 i) +
6 * (a * ∑ i, toSpeciesEquiv S 4 i) =
a *
(∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
∑ x, 6 * toSpeciesEquiv S 4 x) n:ℕa:ℚS:(SMCharges n).Charges⊢ a * ∑ i, toSpeciesEquiv S 0 i + 8 * (a * ∑ i, toSpeciesEquiv S 1 i) + 2 * (a * ∑ i, toSpeciesEquiv S 2 i) +
3 * (a * ∑ i, toSpeciesEquiv S 3 i) +
6 * (a * ∑ i, toSpeciesEquiv S 4 i) =
a *
(∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i) n:ℕa:ℚS:(SMCharges n).Charges⊢ a * ∑ i, toSpeciesEquiv S 0 i + 8 * (a * ∑ i, toSpeciesEquiv S 1 i) + 2 * (a * ∑ i, toSpeciesEquiv S 2 i) +
3 * (a * ∑ i, toSpeciesEquiv S 3 i) +
6 * (a * ∑ i, toSpeciesEquiv S 4 i) =
a *
(∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i)
ring All goals completed! 🐙
Extensionality lemma for accYY.
lemma accYY_ext {S T : (SMCharges n).Charges}
(hj : ∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i) :
accYY S = accYY T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ accYY S = accYY T
simp only [accYY, toSpecies_apply, Fin.isValue, LinearMap.coe_mk,
AddHom.coe_mk] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x,
(toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x +
6 * toSpeciesEquiv S 4 x) =
∑ x,
(toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x + 2 * toSpeciesEquiv T 2 x + 3 * toSpeciesEquiv T 3 x +
6 * toSpeciesEquiv T 4 x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, (toSpeciesEquiv S 0 x + 8 * toSpeciesEquiv S 1 x + 2 * toSpeciesEquiv S 2 x + 3 * toSpeciesEquiv S 3 x) +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x,
(toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x + 2 * toSpeciesEquiv T 2 x + 3 * toSpeciesEquiv T 3 x +
6 * toSpeciesEquiv T 4 x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x, (toSpeciesEquiv T 0 x + 8 * toSpeciesEquiv T 1 x) + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + ∑ x, 8 * toSpeciesEquiv S 1 x + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + ∑ x, 2 * toSpeciesEquiv S 2 x +
∑ x, 3 * toSpeciesEquiv S 3 x +
∑ x, 6 * toSpeciesEquiv S 4 x =
∑ x, toSpeciesEquiv T 0 x + ∑ x, 8 * toSpeciesEquiv T 1 x + ∑ x, 2 * toSpeciesEquiv T 2 x +
∑ x, 3 * toSpeciesEquiv T 3 x +
∑ x, 6 * toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i =
∑ x, toSpeciesEquiv T 0 x + 8 * ∑ i, toSpeciesEquiv T 1 i + 2 * ∑ i, toSpeciesEquiv T 2 i +
3 * ∑ i, toSpeciesEquiv T 3 i +
6 * ∑ i, toSpeciesEquiv T 4 i] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i =
∑ x, toSpeciesEquiv T 0 x + 8 * ∑ i, toSpeciesEquiv T 1 i + 2 * ∑ i, toSpeciesEquiv T 2 i +
3 * ∑ i, toSpeciesEquiv T 3 i +
∑ x, 6 * toSpeciesEquiv T 4 x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i =
∑ x, toSpeciesEquiv T 0 x + 8 * ∑ i, toSpeciesEquiv T 1 i + 2 * ∑ i, toSpeciesEquiv T 2 i +
3 * ∑ i, toSpeciesEquiv T 3 i +
6 * ∑ i, toSpeciesEquiv T 4 i n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargeshj:∀ (j : Fin 5), ∑ i, (toSpecies j) S i = ∑ i, (toSpecies j) T i⊢ ∑ x, toSpeciesEquiv S 0 x + 8 * ∑ i, toSpeciesEquiv S 1 i + 2 * ∑ i, toSpeciesEquiv S 2 i +
3 * ∑ i, toSpeciesEquiv S 3 i +
6 * ∑ i, toSpeciesEquiv S 4 i =
∑ x, toSpeciesEquiv T 0 x + 8 * ∑ i, toSpeciesEquiv T 1 i + 2 * ∑ i, toSpeciesEquiv T 2 i +
3 * ∑ i, toSpeciesEquiv T 3 i +
6 * ∑ i, toSpeciesEquiv T 4 i
simp_all All goals completed! 🐙The quadratic bilinear map.
@[simps!]
def quadBiLin : BiLinearSymm (SMCharges n).Charges := BiLinearSymm.mk₂
(fun S => ∑ i, (Q S.1 i * Q S.2 i +
- 2 * (U S.1 i * U S.2 i) +
D S.1 i * D S.2 i +
(- 1) * (L S.1 i * L S.2 i) +
E S.1 i * E S.2 i))
(by n:ℕ⊢ ∀ (a : ℚ) (S T : (SMCharges n).Charges),
∑ i,
(Q (a • S, T).1 i * Q (a • S, T).2 i + -2 * (U (a • S, T).1 i * U (a • S, T).2 i) +
D (a • S, T).1 i * D (a • S, T).2 i +
-1 * (L (a • S, T).1 i * L (a • S, T).2 i) +
E (a • S, T).1 i * E (a • S, T).2 i) =
a *
∑ i,
(Q (S, T).1 i * Q (S, T).2 i + -2 * (U (S, T).1 i * U (S, T).2 i) + D (S, T).1 i * D (S, T).2 i +
-1 * (L (S, T).1 i * L (S, T).2 i) +
E (S, T).1 i * E (S, T).2 i)
intro a S T n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i,
(Q (a • S, T).1 i * Q (a • S, T).2 i + -2 * (U (a • S, T).1 i * U (a • S, T).2 i) +
D (a • S, T).1 i * D (a • S, T).2 i +
-1 * (L (a • S, T).1 i * L (a • S, T).2 i) +
E (a • S, T).1 i * E (a • S, T).2 i) =
a *
∑ i,
(Q (S, T).1 i * Q (S, T).2 i + -2 * (U (S, T).1 i * U (S, T).2 i) + D (S, T).1 i * D (S, T).2 i +
-1 * (L (S, T).1 i * L (S, T).2 i) +
E (S, T).1 i * E (S, T).2 i)
simp only n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (a • S) x * Q T x + -2 * (U (a • S) x * U T x) + D (a • S) x * D T x + -1 * (L (a • S) x * L T x) +
E (a • S) x * E T x) =
a * ∑ x, (Q S x * Q T x + -2 * (U S x * U T x) + D S x * D T x + -1 * (L S x * L T x) + E S x * E T x)
rw [Finset.mul_sum n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (a • S) x * Q T x + -2 * (U (a • S) x * U T x) + D (a • S) x * D T x + -1 * (L (a • S) x * L T x) +
E (a • S) x * E T x) =
∑ i, a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (a • S) x * Q T x + -2 * (U (a • S) x * U T x) + D (a • S) x * D T x + -1 * (L (a • S) x * L T x) +
E (a • S) x * E T x) =
∑ i, a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i)] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (a • S) x * Q T x + -2 * (U (a • S) x * U T x) + D (a • S) x * D T x + -1 * (L (a • S) x * L T x) +
E (a • S) x * E T x) =
∑ i, a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i)
apply Fintype.sum_congr n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∀ (a_1 : Fin (SMSpecies n).numberCharges),
Q (a • S) a_1 * Q T a_1 + -2 * (U (a • S) a_1 * U T a_1) + D (a • S) a_1 * D T a_1 + -1 * (L (a • S) a_1 * L T a_1) +
E (a • S) a_1 * E T a_1 =
a *
(Q S a_1 * Q T a_1 + -2 * (U S a_1 * U T a_1) + D S a_1 * D T a_1 + -1 * (L S a_1 * L T a_1) + E S a_1 * E T a_1)
intro i n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ Q (a • S) i * Q T i + -2 * (U (a • S) i * U T i) + D (a • S) i * D T i + -1 * (L (a • S) i * L T i) +
E (a • S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i)
repeat rw [map_smul n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (a • Q S) i * Q T i + -2 * (U (a • S) i * U T i) + D (a • S) i * D T i + -1 * (L (a • S) i * L T i) +
E (a • S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (a • Q S) i * Q T i + -2 * ((a • U S) i * U T i) + (a • D S) i * D T i + -1 * ((a • L S) i * L T i) +
(a • E S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i)] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (a • Q S) i * Q T i + -2 * ((a • U S) i * U T i) + (a • D S) i * D T i + -1 * ((a • L S) i * L T i) +
E (a • S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (a • Q S) i * Q T i + -2 * ((a • U S) i * U T i) + (a • D S) i * D T i + -1 * ((a • L S) i * L T i) +
(a • E S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (a • Q S) i * Q T i + -2 * ((a • U S) i * U T i) + (a • D S) i * D T i + -1 * ((a • L S) i * L T i) +
(a • E S) i * E T i =
a * (Q S i * Q T i + -2 * (U S i * U T i) + D S i * D T i + -1 * (L S i * L T i) + E S i * E T i)
simp only [HSMul.hSMul, SMul.smul, toSpecies_apply, Fin.isValue, neg_mul, one_mul] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ a * toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i + -(2 * (a * toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i)) +
a * toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i +
-(a * toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i) +
a * toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i =
a *
(toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i + -(2 * (toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i)) +
toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i +
-(toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i)
ring All goals completed! 🐙)
(by n:ℕ⊢ ∀ (S1 S2 T : (SMCharges n).Charges),
∑ i,
(Q (S1 + S2, T).1 i * Q (S1 + S2, T).2 i + -2 * (U (S1 + S2, T).1 i * U (S1 + S2, T).2 i) +
D (S1 + S2, T).1 i * D (S1 + S2, T).2 i +
-1 * (L (S1 + S2, T).1 i * L (S1 + S2, T).2 i) +
E (S1 + S2, T).1 i * E (S1 + S2, T).2 i) =
∑ i,
(Q (S1, T).1 i * Q (S1, T).2 i + -2 * (U (S1, T).1 i * U (S1, T).2 i) + D (S1, T).1 i * D (S1, T).2 i +
-1 * (L (S1, T).1 i * L (S1, T).2 i) +
E (S1, T).1 i * E (S1, T).2 i) +
∑ i,
(Q (S2, T).1 i * Q (S2, T).2 i + -2 * (U (S2, T).1 i * U (S2, T).2 i) + D (S2, T).1 i * D (S2, T).2 i +
-1 * (L (S2, T).1 i * L (S2, T).2 i) +
E (S2, T).1 i * E (S2, T).2 i)
intro S1 S2 T n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i,
(Q (S1 + S2, T).1 i * Q (S1 + S2, T).2 i + -2 * (U (S1 + S2, T).1 i * U (S1 + S2, T).2 i) +
D (S1 + S2, T).1 i * D (S1 + S2, T).2 i +
-1 * (L (S1 + S2, T).1 i * L (S1 + S2, T).2 i) +
E (S1 + S2, T).1 i * E (S1 + S2, T).2 i) =
∑ i,
(Q (S1, T).1 i * Q (S1, T).2 i + -2 * (U (S1, T).1 i * U (S1, T).2 i) + D (S1, T).1 i * D (S1, T).2 i +
-1 * (L (S1, T).1 i * L (S1, T).2 i) +
E (S1, T).1 i * E (S1, T).2 i) +
∑ i,
(Q (S2, T).1 i * Q (S2, T).2 i + -2 * (U (S2, T).1 i * U (S2, T).2 i) + D (S2, T).1 i * D (S2, T).2 i +
-1 * (L (S2, T).1 i * L (S2, T).2 i) +
E (S2, T).1 i * E (S2, T).2 i)
simp only n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (S1 + S2) x * Q T x + -2 * (U (S1 + S2) x * U T x) + D (S1 + S2) x * D T x + -1 * (L (S1 + S2) x * L T x) +
E (S1 + S2) x * E T x) =
∑ x, (Q S1 x * Q T x + -2 * (U S1 x * U T x) + D S1 x * D T x + -1 * (L S1 x * L T x) + E S1 x * E T x) +
∑ x, (Q S2 x * Q T x + -2 * (U S2 x * U T x) + D S2 x * D T x + -1 * (L S2 x * L T x) + E S2 x * E T x)
rw [← Finset.sum_add_distrib n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (S1 + S2) x * Q T x + -2 * (U (S1 + S2) x * U T x) + D (S1 + S2) x * D T x + -1 * (L (S1 + S2) x * L T x) +
E (S1 + S2) x * E T x) =
∑ x,
(Q S1 x * Q T x + -2 * (U S1 x * U T x) + D S1 x * D T x + -1 * (L S1 x * L T x) + E S1 x * E T x +
(Q S2 x * Q T x + -2 * (U S2 x * U T x) + D S2 x * D T x + -1 * (L S2 x * L T x) + E S2 x * E T x)) n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (S1 + S2) x * Q T x + -2 * (U (S1 + S2) x * U T x) + D (S1 + S2) x * D T x + -1 * (L (S1 + S2) x * L T x) +
E (S1 + S2) x * E T x) =
∑ x,
(Q S1 x * Q T x + -2 * (U S1 x * U T x) + D S1 x * D T x + -1 * (L S1 x * L T x) + E S1 x * E T x +
(Q S2 x * Q T x + -2 * (U S2 x * U T x) + D S2 x * D T x + -1 * (L S2 x * L T x) + E S2 x * E T x))] n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(Q (S1 + S2) x * Q T x + -2 * (U (S1 + S2) x * U T x) + D (S1 + S2) x * D T x + -1 * (L (S1 + S2) x * L T x) +
E (S1 + S2) x * E T x) =
∑ x,
(Q S1 x * Q T x + -2 * (U S1 x * U T x) + D S1 x * D T x + -1 * (L S1 x * L T x) + E S1 x * E T x +
(Q S2 x * Q T x + -2 * (U S2 x * U T x) + D S2 x * D T x + -1 * (L S2 x * L T x) + E S2 x * E T x))
apply Fintype.sum_congr n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∀ (a : Fin (SMSpecies n).numberCharges),
Q (S1 + S2) a * Q T a + -2 * (U (S1 + S2) a * U T a) + D (S1 + S2) a * D T a + -1 * (L (S1 + S2) a * L T a) +
E (S1 + S2) a * E T a =
Q S1 a * Q T a + -2 * (U S1 a * U T a) + D S1 a * D T a + -1 * (L S1 a * L T a) + E S1 a * E T a +
(Q S2 a * Q T a + -2 * (U S2 a * U T a) + D S2 a * D T a + -1 * (L S2 a * L T a) + E S2 a * E T a)
intro i n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ Q (S1 + S2) i * Q T i + -2 * (U (S1 + S2) i * U T i) + D (S1 + S2) i * D T i + -1 * (L (S1 + S2) i * L T i) +
E (S1 + S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i)
repeat rw [map_add n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (Q S1 + Q S2) i * Q T i + -2 * (U (S1 + S2) i * U T i) + D (S1 + S2) i * D T i + -1 * (L (S1 + S2) i * L T i) +
E (S1 + S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i) n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (Q S1 + Q S2) i * Q T i + -2 * ((U S1 + U S2) i * U T i) + (D S1 + D S2) i * D T i + -1 * ((L S1 + L S2) i * L T i) +
(E S1 + E S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i)] n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (Q S1 + Q S2) i * Q T i + -2 * ((U S1 + U S2) i * U T i) + (D S1 + D S2) i * D T i + -1 * ((L S1 + L S2) i * L T i) +
E (S1 + S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i) n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (Q S1 + Q S2) i * Q T i + -2 * ((U S1 + U S2) i * U T i) + (D S1 + D S2) i * D T i + -1 * ((L S1 + L S2) i * L T i) +
(E S1 + E S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i) n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (Q S1 + Q S2) i * Q T i + -2 * ((U S1 + U S2) i * U T i) + (D S1 + D S2) i * D T i + -1 * ((L S1 + L S2) i * L T i) +
(E S1 + E S2) i * E T i =
Q S1 i * Q T i + -2 * (U S1 i * U T i) + D S1 i * D T i + -1 * (L S1 i * L T i) + E S1 i * E T i +
(Q S2 i * Q T i + -2 * (U S2 i * U T i) + D S2 i * D T i + -1 * (L S2 i * L T i) + E S2 i * E T i)
simp only [ACCSystemCharges.chargesAddCommMonoid_add, toSpecies_apply, Fin.isValue, neg_mul,
one_mul] n:ℕS1:(SMCharges n).ChargesS2:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ (toSpeciesEquiv S1 0 i + toSpeciesEquiv S2 0 i) * toSpeciesEquiv T 0 i +
-(2 * ((toSpeciesEquiv S1 1 i + toSpeciesEquiv S2 1 i) * toSpeciesEquiv T 1 i)) +
(toSpeciesEquiv S1 2 i + toSpeciesEquiv S2 2 i) * toSpeciesEquiv T 2 i +
-((toSpeciesEquiv S1 3 i + toSpeciesEquiv S2 3 i) * toSpeciesEquiv T 3 i) +
(toSpeciesEquiv S1 4 i + toSpeciesEquiv S2 4 i) * toSpeciesEquiv T 4 i =
toSpeciesEquiv S1 0 i * toSpeciesEquiv T 0 i + -(2 * (toSpeciesEquiv S1 1 i * toSpeciesEquiv T 1 i)) +
toSpeciesEquiv S1 2 i * toSpeciesEquiv T 2 i +
-(toSpeciesEquiv S1 3 i * toSpeciesEquiv T 3 i) +
toSpeciesEquiv S1 4 i * toSpeciesEquiv T 4 i +
(toSpeciesEquiv S2 0 i * toSpeciesEquiv T 0 i + -(2 * (toSpeciesEquiv S2 1 i * toSpeciesEquiv T 1 i)) +
toSpeciesEquiv S2 2 i * toSpeciesEquiv T 2 i +
-(toSpeciesEquiv S2 3 i * toSpeciesEquiv T 3 i) +
toSpeciesEquiv S2 4 i * toSpeciesEquiv T 4 i)
ring All goals completed! 🐙)
(by n:ℕ⊢ ∀ (S T : (SMCharges n).Charges),
∑ i,
(Q (S, T).1 i * Q (S, T).2 i + -2 * (U (S, T).1 i * U (S, T).2 i) + D (S, T).1 i * D (S, T).2 i +
-1 * (L (S, T).1 i * L (S, T).2 i) +
E (S, T).1 i * E (S, T).2 i) =
∑ i,
(Q (T, S).1 i * Q (T, S).2 i + -2 * (U (T, S).1 i * U (T, S).2 i) + D (T, S).1 i * D (T, S).2 i +
-1 * (L (T, S).1 i * L (T, S).2 i) +
E (T, S).1 i * E (T, S).2 i)
intro S T n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ i,
(Q (S, T).1 i * Q (S, T).2 i + -2 * (U (S, T).1 i * U (S, T).2 i) + D (S, T).1 i * D (S, T).2 i +
-1 * (L (S, T).1 i * L (S, T).2 i) +
E (S, T).1 i * E (S, T).2 i) =
∑ i,
(Q (T, S).1 i * Q (T, S).2 i + -2 * (U (T, S).1 i * U (T, S).2 i) + D (T, S).1 i * D (T, S).2 i +
-1 * (L (T, S).1 i * L (T, S).2 i) +
E (T, S).1 i * E (T, S).2 i)
simp only [toSpecies_apply, Fin.isValue, neg_mul, one_mul] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∑ x,
(toSpeciesEquiv S 0 x * toSpeciesEquiv T 0 x + -(2 * (toSpeciesEquiv S 1 x * toSpeciesEquiv T 1 x)) +
toSpeciesEquiv S 2 x * toSpeciesEquiv T 2 x +
-(toSpeciesEquiv S 3 x * toSpeciesEquiv T 3 x) +
toSpeciesEquiv S 4 x * toSpeciesEquiv T 4 x) =
∑ x,
(toSpeciesEquiv T 0 x * toSpeciesEquiv S 0 x + -(2 * (toSpeciesEquiv T 1 x * toSpeciesEquiv S 1 x)) +
toSpeciesEquiv T 2 x * toSpeciesEquiv S 2 x +
-(toSpeciesEquiv T 3 x * toSpeciesEquiv S 3 x) +
toSpeciesEquiv T 4 x * toSpeciesEquiv S 4 x)
apply Fintype.sum_congr n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Charges⊢ ∀ (a : Fin (SMSpecies n).numberCharges),
toSpeciesEquiv S 0 a * toSpeciesEquiv T 0 a + -(2 * (toSpeciesEquiv S 1 a * toSpeciesEquiv T 1 a)) +
toSpeciesEquiv S 2 a * toSpeciesEquiv T 2 a +
-(toSpeciesEquiv S 3 a * toSpeciesEquiv T 3 a) +
toSpeciesEquiv S 4 a * toSpeciesEquiv T 4 a =
toSpeciesEquiv T 0 a * toSpeciesEquiv S 0 a + -(2 * (toSpeciesEquiv T 1 a * toSpeciesEquiv S 1 a)) +
toSpeciesEquiv T 2 a * toSpeciesEquiv S 2 a +
-(toSpeciesEquiv T 3 a * toSpeciesEquiv S 3 a) +
toSpeciesEquiv T 4 a * toSpeciesEquiv S 4 a
intro i n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i + -(2 * (toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i)) +
toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i +
-(toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i =
toSpeciesEquiv T 0 i * toSpeciesEquiv S 0 i + -(2 * (toSpeciesEquiv T 1 i * toSpeciesEquiv S 1 i)) +
toSpeciesEquiv T 2 i * toSpeciesEquiv S 2 i +
-(toSpeciesEquiv T 3 i * toSpeciesEquiv S 3 i) +
toSpeciesEquiv T 4 i * toSpeciesEquiv S 4 i
ring All goals completed! 🐙)The quadratic anomaly cancellation condition.
@[simp]
def accQuad : HomogeneousQuadratic (SMCharges n).Charges :=
(@quadBiLin n).toHomogeneousQuad
Extensionality lemma for accQuad.
set_option backward.isDefEq.respectTransparency false in
lemma accQuad_ext {S T : (SMCharges n).Charges}
(h : ∀ j, ∑ i, ((fun a => a^2) ∘ toSpecies j S) i =
∑ i, ((fun a => a^2) ∘ toSpecies j T) i) :
accQuad S = accQuad T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ accQuad S = accQuad T
simp only [HomogeneousQuadratic, accQuad, BiLinearSymm.toHomogeneousQuad_apply] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ (quadBiLin S) S = (quadBiLin T) T
simp only [quadBiLin, BiLinearSymm.mk₂_toFun_apply] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, (Q S x * Q S x + -2 * (U S x * U S x) + D S x * D S x + -1 * (L S x * L S x) + E S x * E S x) =
∑ x, (Q T x * Q T x + -2 * (U T x * U T x) + D T x * D T x + -1 * (L T x * L T x) + E T x * E T x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, (Q S x * Q S x + -2 * (U S x * U S x) + D S x * D S x + -1 * (L S x * L S x)) + ∑ x, E S x * E S x =
∑ x, (Q T x * Q T x + -2 * (U T x * U T x) + D T x * D T x + -1 * (L T x * L T x) + E T x * E T x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + ∑ x, -2 * (U S x * U S x) + ∑ x, D S x * D S x + ∑ x, -1 * (L S x * L S x) + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + ∑ x, -2 * (U T x * U T x) + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + ∑ x, -2 * (U S x * U S x) + ∑ x, D S x * D S x + ∑ x, -1 * (L S x * L S x) + ∑ x, E S x * E S x =
∑ x, (Q T x * Q T x + -2 * (U T x * U T x)) + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + ∑ x, -2 * (U S x * U S x) + ∑ x, D S x * D S x + ∑ x, -1 * (L S x * L S x) + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + ∑ x, -2 * (U T x * U T x) + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + ∑ x, -2 * (U S x * U S x) + ∑ x, D S x * D S x + ∑ x, -1 * (L S x * L S x) + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + ∑ x, -2 * (U T x * U T x) + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + -2 * ∑ i, U S i * U S i + ∑ x, D S x * D S x + ∑ x, -1 * (L S x * L S x) + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + ∑ x, -2 * (U T x * U T x) + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + -2 * ∑ i, U S i * U S i + ∑ x, D S x * D S x + -1 * ∑ i, L S i * L S i + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + -2 * ∑ i, U T i * U T i + ∑ x, D T x * D T x + -1 * ∑ i, L T i * L T i + ∑ x, E T x * E T x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + -2 * ∑ i, U S i * U S i + ∑ x, D S x * D S x + -1 * ∑ i, L S i * L S i + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + -2 * ∑ i, U T i * U T i + ∑ x, D T x * D T x + ∑ x, -1 * (L T x * L T x) + ∑ x, E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + -2 * ∑ i, U S i * U S i + ∑ x, D S x * D S x + -1 * ∑ i, L S i * L S i + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + -2 * ∑ i, U T i * U T i + ∑ x, D T x * D T x + -1 * ∑ i, L T i * L T i + ∑ x, E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x * Q S x + -2 * ∑ i, U S i * U S i + ∑ x, D S x * D S x + -1 * ∑ i, L S i * L S i + ∑ x, E S x * E S x =
∑ x, Q T x * Q T x + -2 * ∑ i, U T i * U T i + ∑ x, D T x * D T x + -1 * ∑ i, L T i * L T i + ∑ x, E T x * E T x
ring_nf n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 2) ∘ (toSpecies j) T) i⊢ ∑ x, Q S x ^ 2 - (∑ x, U S x ^ 2) * 2 + ∑ x, D S x ^ 2 - ∑ x, L S x ^ 2 + ∑ x, E S x ^ 2 =
∑ x, Q T x ^ 2 - (∑ x, U T x ^ 2) * 2 + ∑ x, D T x ^ 2 - ∑ x, L T x ^ 2 + ∑ x, E T x ^ 2
simp_all All goals completed! 🐙The trilinear function defining the cubic.
@[simps!]
def cubeTriLin : TriLinearSymm (SMCharges n).Charges := TriLinearSymm.mk₃
(fun S => ∑ i, (6 * ((Q S.1 i) * (Q S.2.1 i) * (Q S.2.2 i))
+ 3 * ((U S.1 i) * (U S.2.1 i) * (U S.2.2 i))
+ 3 * ((D S.1 i) * (D S.2.1 i) * (D S.2.2 i))
+ 2 * ((L S.1 i) * (L S.2.1 i) * (L S.2.2 i))
+ ((E S.1 i) * (E S.2.1 i) * (E S.2.2 i))))
(by n:ℕ⊢ ∀ (a : ℚ) (S T L : (SMCharges n).Charges),
∑ i,
(6 * (Q (a • S, T, L).1 i * Q (a • S, T, L).2.1 i * Q (a • S, T, L).2.2 i) +
3 * (U (a • S, T, L).1 i * U (a • S, T, L).2.1 i * U (a • S, T, L).2.2 i) +
3 * (D (a • S, T, L).1 i * D (a • S, T, L).2.1 i * D (a • S, T, L).2.2 i) +
2 * (SMCharges.L (a • S, T, L).1 i * SMCharges.L (a • S, T, L).2.1 i * SMCharges.L (a • S, T, L).2.2 i) +
E (a • S, T, L).1 i * E (a • S, T, L).2.1 i * E (a • S, T, L).2.2 i) =
a *
∑ i,
(6 * (Q (S, T, L).1 i * Q (S, T, L).2.1 i * Q (S, T, L).2.2 i) +
3 * (U (S, T, L).1 i * U (S, T, L).2.1 i * U (S, T, L).2.2 i) +
3 * (D (S, T, L).1 i * D (S, T, L).2.1 i * D (S, T, L).2.2 i) +
2 * (SMCharges.L (S, T, L).1 i * SMCharges.L (S, T, L).2.1 i * SMCharges.L (S, T, L).2.2 i) +
E (S, T, L).1 i * E (S, T, L).2.1 i * E (S, T, L).2.2 i)
intro a S T R n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∑ i,
(6 * (Q (a • S, T, R).1 i * Q (a • S, T, R).2.1 i * Q (a • S, T, R).2.2 i) +
3 * (U (a • S, T, R).1 i * U (a • S, T, R).2.1 i * U (a • S, T, R).2.2 i) +
3 * (D (a • S, T, R).1 i * D (a • S, T, R).2.1 i * D (a • S, T, R).2.2 i) +
2 * (L (a • S, T, R).1 i * L (a • S, T, R).2.1 i * L (a • S, T, R).2.2 i) +
E (a • S, T, R).1 i * E (a • S, T, R).2.1 i * E (a • S, T, R).2.2 i) =
a *
∑ i,
(6 * (Q (S, T, R).1 i * Q (S, T, R).2.1 i * Q (S, T, R).2.2 i) +
3 * (U (S, T, R).1 i * U (S, T, R).2.1 i * U (S, T, R).2.2 i) +
3 * (D (S, T, R).1 i * D (S, T, R).2.1 i * D (S, T, R).2.2 i) +
2 * (L (S, T, R).1 i * L (S, T, R).2.1 i * L (S, T, R).2.2 i) +
E (S, T, R).1 i * E (S, T, R).2.1 i * E (S, T, R).2.2 i)
simp only n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (a • S) x * Q T x * Q R x) + 3 * (U (a • S) x * U T x * U R x) + 3 * (D (a • S) x * D T x * D R x) +
2 * (L (a • S) x * L T x * L R x) +
E (a • S) x * E T x * E R x) =
a *
∑ x,
(6 * (Q S x * Q T x * Q R x) + 3 * (U S x * U T x * U R x) + 3 * (D S x * D T x * D R x) +
2 * (L S x * L T x * L R x) +
E S x * E T x * E R x)
rw [Finset.mul_sum n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (a • S) x * Q T x * Q R x) + 3 * (U (a • S) x * U T x * U R x) + 3 * (D (a • S) x * D T x * D R x) +
2 * (L (a • S) x * L T x * L R x) +
E (a • S) x * E T x * E R x) =
∑ i,
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (a • S) x * Q T x * Q R x) + 3 * (U (a • S) x * U T x * U R x) + 3 * (D (a • S) x * D T x * D R x) +
2 * (L (a • S) x * L T x * L R x) +
E (a • S) x * E T x * E R x) =
∑ i,
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i)] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (a • S) x * Q T x * Q R x) + 3 * (U (a • S) x * U T x * U R x) + 3 * (D (a • S) x * D T x * D R x) +
2 * (L (a • S) x * L T x * L R x) +
E (a • S) x * E T x * E R x) =
∑ i,
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i)
apply Fintype.sum_congr n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Charges⊢ ∀ (a_1 : Fin (SMSpecies n).numberCharges),
6 * (Q (a • S) a_1 * Q T a_1 * Q R a_1) + 3 * (U (a • S) a_1 * U T a_1 * U R a_1) +
3 * (D (a • S) a_1 * D T a_1 * D R a_1) +
2 * (L (a • S) a_1 * L T a_1 * L R a_1) +
E (a • S) a_1 * E T a_1 * E R a_1 =
a *
(6 * (Q S a_1 * Q T a_1 * Q R a_1) + 3 * (U S a_1 * U T a_1 * U R a_1) + 3 * (D S a_1 * D T a_1 * D R a_1) +
2 * (L S a_1 * L T a_1 * L R a_1) +
E S a_1 * E T a_1 * E R a_1)
intro i n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * (Q (a • S) i * Q T i * Q R i) + 3 * (U (a • S) i * U T i * U R i) + 3 * (D (a • S) i * D T i * D R i) +
2 * (L (a • S) i * L T i * L R i) +
E (a • S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i)
repeat rw [map_smul n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((a • Q S) i * Q T i * Q R i) + 3 * (U (a • S) i * U T i * U R i) + 3 * (D (a • S) i * D T i * D R i) +
2 * (L (a • S) i * L T i * L R i) +
E (a • S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((a • Q S) i * Q T i * Q R i) + 3 * ((a • U S) i * U T i * U R i) + 3 * ((a • D S) i * D T i * D R i) +
2 * ((a • L S) i * L T i * L R i) +
(a • E S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i)] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((a • Q S) i * Q T i * Q R i) + 3 * ((a • U S) i * U T i * U R i) + 3 * ((a • D S) i * D T i * D R i) +
2 * ((a • L S) i * L T i * L R i) +
E (a • S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((a • Q S) i * Q T i * Q R i) + 3 * ((a • U S) i * U T i * U R i) + 3 * ((a • D S) i * D T i * D R i) +
2 * ((a • L S) i * L T i * L R i) +
(a • E S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i) n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((a • Q S) i * Q T i * Q R i) + 3 * ((a • U S) i * U T i * U R i) + 3 * ((a • D S) i * D T i * D R i) +
2 * ((a • L S) i * L T i * L R i) +
(a • E S) i * E T i * E R i =
a *
(6 * (Q S i * Q T i * Q R i) + 3 * (U S i * U T i * U R i) + 3 * (D S i * D T i * D R i) +
2 * (L S i * L T i * L R i) +
E S i * E T i * E R i)
simp only [HSMul.hSMul, SMul.smul, toSpecies_apply, Fin.isValue] n:ℕa:ℚS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * (a * toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i * toSpeciesEquiv R 0 i) +
3 * (a * toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i * toSpeciesEquiv R 1 i) +
3 * (a * toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i * toSpeciesEquiv R 2 i) +
2 * (a * toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i * toSpeciesEquiv R 3 i) +
a * toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i * toSpeciesEquiv R 4 i =
a *
(6 * (toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i * toSpeciesEquiv R 0 i) +
3 * (toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i * toSpeciesEquiv R 1 i) +
3 * (toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i * toSpeciesEquiv R 2 i) +
2 * (toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i * toSpeciesEquiv R 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i * toSpeciesEquiv R 4 i)
ring All goals completed! 🐙)
(by n:ℕ⊢ ∀ (S1 S2 T L : (SMCharges n).Charges),
∑ i,
(6 * (Q (S1 + S2, T, L).1 i * Q (S1 + S2, T, L).2.1 i * Q (S1 + S2, T, L).2.2 i) +
3 * (U (S1 + S2, T, L).1 i * U (S1 + S2, T, L).2.1 i * U (S1 + S2, T, L).2.2 i) +
3 * (D (S1 + S2, T, L).1 i * D (S1 + S2, T, L).2.1 i * D (S1 + S2, T, L).2.2 i) +
2 *
(SMCharges.L (S1 + S2, T, L).1 i * SMCharges.L (S1 + S2, T, L).2.1 i * SMCharges.L (S1 + S2, T, L).2.2 i) +
E (S1 + S2, T, L).1 i * E (S1 + S2, T, L).2.1 i * E (S1 + S2, T, L).2.2 i) =
∑ i,
(6 * (Q (S1, T, L).1 i * Q (S1, T, L).2.1 i * Q (S1, T, L).2.2 i) +
3 * (U (S1, T, L).1 i * U (S1, T, L).2.1 i * U (S1, T, L).2.2 i) +
3 * (D (S1, T, L).1 i * D (S1, T, L).2.1 i * D (S1, T, L).2.2 i) +
2 * (SMCharges.L (S1, T, L).1 i * SMCharges.L (S1, T, L).2.1 i * SMCharges.L (S1, T, L).2.2 i) +
E (S1, T, L).1 i * E (S1, T, L).2.1 i * E (S1, T, L).2.2 i) +
∑ i,
(6 * (Q (S2, T, L).1 i * Q (S2, T, L).2.1 i * Q (S2, T, L).2.2 i) +
3 * (U (S2, T, L).1 i * U (S2, T, L).2.1 i * U (S2, T, L).2.2 i) +
3 * (D (S2, T, L).1 i * D (S2, T, L).2.1 i * D (S2, T, L).2.2 i) +
2 * (SMCharges.L (S2, T, L).1 i * SMCharges.L (S2, T, L).2.1 i * SMCharges.L (S2, T, L).2.2 i) +
E (S2, T, L).1 i * E (S2, T, L).2.1 i * E (S2, T, L).2.2 i)
intro S T R L n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ i,
(6 * (Q (S + T, R, L).1 i * Q (S + T, R, L).2.1 i * Q (S + T, R, L).2.2 i) +
3 * (U (S + T, R, L).1 i * U (S + T, R, L).2.1 i * U (S + T, R, L).2.2 i) +
3 * (D (S + T, R, L).1 i * D (S + T, R, L).2.1 i * D (S + T, R, L).2.2 i) +
2 * (SMCharges.L (S + T, R, L).1 i * SMCharges.L (S + T, R, L).2.1 i * SMCharges.L (S + T, R, L).2.2 i) +
E (S + T, R, L).1 i * E (S + T, R, L).2.1 i * E (S + T, R, L).2.2 i) =
∑ i,
(6 * (Q (S, R, L).1 i * Q (S, R, L).2.1 i * Q (S, R, L).2.2 i) +
3 * (U (S, R, L).1 i * U (S, R, L).2.1 i * U (S, R, L).2.2 i) +
3 * (D (S, R, L).1 i * D (S, R, L).2.1 i * D (S, R, L).2.2 i) +
2 * (SMCharges.L (S, R, L).1 i * SMCharges.L (S, R, L).2.1 i * SMCharges.L (S, R, L).2.2 i) +
E (S, R, L).1 i * E (S, R, L).2.1 i * E (S, R, L).2.2 i) +
∑ i,
(6 * (Q (T, R, L).1 i * Q (T, R, L).2.1 i * Q (T, R, L).2.2 i) +
3 * (U (T, R, L).1 i * U (T, R, L).2.1 i * U (T, R, L).2.2 i) +
3 * (D (T, R, L).1 i * D (T, R, L).2.1 i * D (T, R, L).2.2 i) +
2 * (SMCharges.L (T, R, L).1 i * SMCharges.L (T, R, L).2.1 i * SMCharges.L (T, R, L).2.2 i) +
E (T, R, L).1 i * E (T, R, L).2.1 i * E (T, R, L).2.2 i)
simp only n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (S + T) x * Q R x * Q L x) + 3 * (U (S + T) x * U R x * U L x) + 3 * (D (S + T) x * D R x * D L x) +
2 * (SMCharges.L (S + T) x * SMCharges.L R x * SMCharges.L L x) +
E (S + T) x * E R x * E L x) =
∑ x,
(6 * (Q S x * Q R x * Q L x) + 3 * (U S x * U R x * U L x) + 3 * (D S x * D R x * D L x) +
2 * (SMCharges.L S x * SMCharges.L R x * SMCharges.L L x) +
E S x * E R x * E L x) +
∑ x,
(6 * (Q T x * Q R x * Q L x) + 3 * (U T x * U R x * U L x) + 3 * (D T x * D R x * D L x) +
2 * (SMCharges.L T x * SMCharges.L R x * SMCharges.L L x) +
E T x * E R x * E L x)
rw [← Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (S + T) x * Q R x * Q L x) + 3 * (U (S + T) x * U R x * U L x) + 3 * (D (S + T) x * D R x * D L x) +
2 * (SMCharges.L (S + T) x * SMCharges.L R x * SMCharges.L L x) +
E (S + T) x * E R x * E L x) =
∑ x,
(6 * (Q S x * Q R x * Q L x) + 3 * (U S x * U R x * U L x) + 3 * (D S x * D R x * D L x) +
2 * (SMCharges.L S x * SMCharges.L R x * SMCharges.L L x) +
E S x * E R x * E L x +
(6 * (Q T x * Q R x * Q L x) + 3 * (U T x * U R x * U L x) + 3 * (D T x * D R x * D L x) +
2 * (SMCharges.L T x * SMCharges.L R x * SMCharges.L L x) +
E T x * E R x * E L x)) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (S + T) x * Q R x * Q L x) + 3 * (U (S + T) x * U R x * U L x) + 3 * (D (S + T) x * D R x * D L x) +
2 * (SMCharges.L (S + T) x * SMCharges.L R x * SMCharges.L L x) +
E (S + T) x * E R x * E L x) =
∑ x,
(6 * (Q S x * Q R x * Q L x) + 3 * (U S x * U R x * U L x) + 3 * (D S x * D R x * D L x) +
2 * (SMCharges.L S x * SMCharges.L R x * SMCharges.L L x) +
E S x * E R x * E L x +
(6 * (Q T x * Q R x * Q L x) + 3 * (U T x * U R x * U L x) + 3 * (D T x * D R x * D L x) +
2 * (SMCharges.L T x * SMCharges.L R x * SMCharges.L L x) +
E T x * E R x * E L x))] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (Q (S + T) x * Q R x * Q L x) + 3 * (U (S + T) x * U R x * U L x) + 3 * (D (S + T) x * D R x * D L x) +
2 * (SMCharges.L (S + T) x * SMCharges.L R x * SMCharges.L L x) +
E (S + T) x * E R x * E L x) =
∑ x,
(6 * (Q S x * Q R x * Q L x) + 3 * (U S x * U R x * U L x) + 3 * (D S x * D R x * D L x) +
2 * (SMCharges.L S x * SMCharges.L R x * SMCharges.L L x) +
E S x * E R x * E L x +
(6 * (Q T x * Q R x * Q L x) + 3 * (U T x * U R x * U L x) + 3 * (D T x * D R x * D L x) +
2 * (SMCharges.L T x * SMCharges.L R x * SMCharges.L L x) +
E T x * E R x * E L x))
apply Fintype.sum_congr n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∀ (a : Fin (SMSpecies n).numberCharges),
6 * (Q (S + T) a * Q R a * Q L a) + 3 * (U (S + T) a * U R a * U L a) + 3 * (D (S + T) a * D R a * D L a) +
2 * (SMCharges.L (S + T) a * SMCharges.L R a * SMCharges.L L a) +
E (S + T) a * E R a * E L a =
6 * (Q S a * Q R a * Q L a) + 3 * (U S a * U R a * U L a) + 3 * (D S a * D R a * D L a) +
2 * (SMCharges.L S a * SMCharges.L R a * SMCharges.L L a) +
E S a * E R a * E L a +
(6 * (Q T a * Q R a * Q L a) + 3 * (U T a * U R a * U L a) + 3 * (D T a * D R a * D L a) +
2 * (SMCharges.L T a * SMCharges.L R a * SMCharges.L L a) +
E T a * E R a * E L a)
intro i n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * (Q (S + T) i * Q R i * Q L i) + 3 * (U (S + T) i * U R i * U L i) + 3 * (D (S + T) i * D R i * D L i) +
2 * (SMCharges.L (S + T) i * SMCharges.L R i * SMCharges.L L i) +
E (S + T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i)
repeat rw [map_add n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((Q S + Q T) i * Q R i * Q L i) + 3 * (U (S + T) i * U R i * U L i) + 3 * (D (S + T) i * D R i * D L i) +
2 * (SMCharges.L (S + T) i * SMCharges.L R i * SMCharges.L L i) +
E (S + T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((Q S + Q T) i * Q R i * Q L i) + 3 * ((U S + U T) i * U R i * U L i) + 3 * ((D S + D T) i * D R i * D L i) +
2 * ((SMCharges.L S + SMCharges.L T) i * SMCharges.L R i * SMCharges.L L i) +
(E S + E T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i)] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((Q S + Q T) i * Q R i * Q L i) + 3 * ((U S + U T) i * U R i * U L i) + 3 * ((D S + D T) i * D R i * D L i) +
2 * ((SMCharges.L S + SMCharges.L T) i * SMCharges.L R i * SMCharges.L L i) +
E (S + T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((Q S + Q T) i * Q R i * Q L i) + 3 * ((U S + U T) i * U R i * U L i) + 3 * ((D S + D T) i * D R i * D L i) +
2 * ((SMCharges.L S + SMCharges.L T) i * SMCharges.L R i * SMCharges.L L i) +
(E S + E T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((Q S + Q T) i * Q R i * Q L i) + 3 * ((U S + U T) i * U R i * U L i) + 3 * ((D S + D T) i * D R i * D L i) +
2 * ((SMCharges.L S + SMCharges.L T) i * SMCharges.L R i * SMCharges.L L i) +
(E S + E T) i * E R i * E L i =
6 * (Q S i * Q R i * Q L i) + 3 * (U S i * U R i * U L i) + 3 * (D S i * D R i * D L i) +
2 * (SMCharges.L S i * SMCharges.L R i * SMCharges.L L i) +
E S i * E R i * E L i +
(6 * (Q T i * Q R i * Q L i) + 3 * (U T i * U R i * U L i) + 3 * (D T i * D R i * D L i) +
2 * (SMCharges.L T i * SMCharges.L R i * SMCharges.L L i) +
E T i * E R i * E L i)
simp only [ACCSystemCharges.chargesAddCommMonoid_add, toSpecies_apply, Fin.isValue] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesR:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * ((toSpeciesEquiv S 0 i + toSpeciesEquiv T 0 i) * toSpeciesEquiv R 0 i * toSpeciesEquiv L 0 i) +
3 * ((toSpeciesEquiv S 1 i + toSpeciesEquiv T 1 i) * toSpeciesEquiv R 1 i * toSpeciesEquiv L 1 i) +
3 * ((toSpeciesEquiv S 2 i + toSpeciesEquiv T 2 i) * toSpeciesEquiv R 2 i * toSpeciesEquiv L 2 i) +
2 * ((toSpeciesEquiv S 3 i + toSpeciesEquiv T 3 i) * toSpeciesEquiv R 3 i * toSpeciesEquiv L 3 i) +
(toSpeciesEquiv S 4 i + toSpeciesEquiv T 4 i) * toSpeciesEquiv R 4 i * toSpeciesEquiv L 4 i =
6 * (toSpeciesEquiv S 0 i * toSpeciesEquiv R 0 i * toSpeciesEquiv L 0 i) +
3 * (toSpeciesEquiv S 1 i * toSpeciesEquiv R 1 i * toSpeciesEquiv L 1 i) +
3 * (toSpeciesEquiv S 2 i * toSpeciesEquiv R 2 i * toSpeciesEquiv L 2 i) +
2 * (toSpeciesEquiv S 3 i * toSpeciesEquiv R 3 i * toSpeciesEquiv L 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv R 4 i * toSpeciesEquiv L 4 i +
(6 * (toSpeciesEquiv T 0 i * toSpeciesEquiv R 0 i * toSpeciesEquiv L 0 i) +
3 * (toSpeciesEquiv T 1 i * toSpeciesEquiv R 1 i * toSpeciesEquiv L 1 i) +
3 * (toSpeciesEquiv T 2 i * toSpeciesEquiv R 2 i * toSpeciesEquiv L 2 i) +
2 * (toSpeciesEquiv T 3 i * toSpeciesEquiv R 3 i * toSpeciesEquiv L 3 i) +
toSpeciesEquiv T 4 i * toSpeciesEquiv R 4 i * toSpeciesEquiv L 4 i)
ring All goals completed! 🐙)
(by n:ℕ⊢ ∀ (S T L : (SMCharges n).Charges),
∑ i,
(6 * (Q (S, T, L).1 i * Q (S, T, L).2.1 i * Q (S, T, L).2.2 i) +
3 * (U (S, T, L).1 i * U (S, T, L).2.1 i * U (S, T, L).2.2 i) +
3 * (D (S, T, L).1 i * D (S, T, L).2.1 i * D (S, T, L).2.2 i) +
2 * (SMCharges.L (S, T, L).1 i * SMCharges.L (S, T, L).2.1 i * SMCharges.L (S, T, L).2.2 i) +
E (S, T, L).1 i * E (S, T, L).2.1 i * E (S, T, L).2.2 i) =
∑ i,
(6 * (Q (T, S, L).1 i * Q (T, S, L).2.1 i * Q (T, S, L).2.2 i) +
3 * (U (T, S, L).1 i * U (T, S, L).2.1 i * U (T, S, L).2.2 i) +
3 * (D (T, S, L).1 i * D (T, S, L).2.1 i * D (T, S, L).2.2 i) +
2 * (SMCharges.L (T, S, L).1 i * SMCharges.L (T, S, L).2.1 i * SMCharges.L (T, S, L).2.2 i) +
E (T, S, L).1 i * E (T, S, L).2.1 i * E (T, S, L).2.2 i)
intro S T L n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ i,
(6 * (Q (S, T, L).1 i * Q (S, T, L).2.1 i * Q (S, T, L).2.2 i) +
3 * (U (S, T, L).1 i * U (S, T, L).2.1 i * U (S, T, L).2.2 i) +
3 * (D (S, T, L).1 i * D (S, T, L).2.1 i * D (S, T, L).2.2 i) +
2 * (SMCharges.L (S, T, L).1 i * SMCharges.L (S, T, L).2.1 i * SMCharges.L (S, T, L).2.2 i) +
E (S, T, L).1 i * E (S, T, L).2.1 i * E (S, T, L).2.2 i) =
∑ i,
(6 * (Q (T, S, L).1 i * Q (T, S, L).2.1 i * Q (T, S, L).2.2 i) +
3 * (U (T, S, L).1 i * U (T, S, L).2.1 i * U (T, S, L).2.2 i) +
3 * (D (T, S, L).1 i * D (T, S, L).2.1 i * D (T, S, L).2.2 i) +
2 * (SMCharges.L (T, S, L).1 i * SMCharges.L (T, S, L).2.1 i * SMCharges.L (T, S, L).2.2 i) +
E (T, S, L).1 i * E (T, S, L).2.1 i * E (T, S, L).2.2 i)
simp only [toSpecies_apply, Fin.isValue] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (toSpeciesEquiv S 0 x * toSpeciesEquiv T 0 x * toSpeciesEquiv L 0 x) +
3 * (toSpeciesEquiv S 1 x * toSpeciesEquiv T 1 x * toSpeciesEquiv L 1 x) +
3 * (toSpeciesEquiv S 2 x * toSpeciesEquiv T 2 x * toSpeciesEquiv L 2 x) +
2 * (toSpeciesEquiv S 3 x * toSpeciesEquiv T 3 x * toSpeciesEquiv L 3 x) +
toSpeciesEquiv S 4 x * toSpeciesEquiv T 4 x * toSpeciesEquiv L 4 x) =
∑ x,
(6 * (toSpeciesEquiv T 0 x * toSpeciesEquiv S 0 x * toSpeciesEquiv L 0 x) +
3 * (toSpeciesEquiv T 1 x * toSpeciesEquiv S 1 x * toSpeciesEquiv L 1 x) +
3 * (toSpeciesEquiv T 2 x * toSpeciesEquiv S 2 x * toSpeciesEquiv L 2 x) +
2 * (toSpeciesEquiv T 3 x * toSpeciesEquiv S 3 x * toSpeciesEquiv L 3 x) +
toSpeciesEquiv T 4 x * toSpeciesEquiv S 4 x * toSpeciesEquiv L 4 x)
apply Fintype.sum_congr n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∀ (a : Fin (SMSpecies n).numberCharges),
6 * (toSpeciesEquiv S 0 a * toSpeciesEquiv T 0 a * toSpeciesEquiv L 0 a) +
3 * (toSpeciesEquiv S 1 a * toSpeciesEquiv T 1 a * toSpeciesEquiv L 1 a) +
3 * (toSpeciesEquiv S 2 a * toSpeciesEquiv T 2 a * toSpeciesEquiv L 2 a) +
2 * (toSpeciesEquiv S 3 a * toSpeciesEquiv T 3 a * toSpeciesEquiv L 3 a) +
toSpeciesEquiv S 4 a * toSpeciesEquiv T 4 a * toSpeciesEquiv L 4 a =
6 * (toSpeciesEquiv T 0 a * toSpeciesEquiv S 0 a * toSpeciesEquiv L 0 a) +
3 * (toSpeciesEquiv T 1 a * toSpeciesEquiv S 1 a * toSpeciesEquiv L 1 a) +
3 * (toSpeciesEquiv T 2 a * toSpeciesEquiv S 2 a * toSpeciesEquiv L 2 a) +
2 * (toSpeciesEquiv T 3 a * toSpeciesEquiv S 3 a * toSpeciesEquiv L 3 a) +
toSpeciesEquiv T 4 a * toSpeciesEquiv S 4 a * toSpeciesEquiv L 4 a
intro i n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * (toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i * toSpeciesEquiv L 0 i) +
3 * (toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i * toSpeciesEquiv L 1 i) +
3 * (toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i * toSpeciesEquiv L 2 i) +
2 * (toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i * toSpeciesEquiv L 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i * toSpeciesEquiv L 4 i =
6 * (toSpeciesEquiv T 0 i * toSpeciesEquiv S 0 i * toSpeciesEquiv L 0 i) +
3 * (toSpeciesEquiv T 1 i * toSpeciesEquiv S 1 i * toSpeciesEquiv L 1 i) +
3 * (toSpeciesEquiv T 2 i * toSpeciesEquiv S 2 i * toSpeciesEquiv L 2 i) +
2 * (toSpeciesEquiv T 3 i * toSpeciesEquiv S 3 i * toSpeciesEquiv L 3 i) +
toSpeciesEquiv T 4 i * toSpeciesEquiv S 4 i * toSpeciesEquiv L 4 i
ring All goals completed! 🐙)
(by n:ℕ⊢ ∀ (S T L : (SMCharges n).Charges),
∑ i,
(6 * (Q (S, T, L).1 i * Q (S, T, L).2.1 i * Q (S, T, L).2.2 i) +
3 * (U (S, T, L).1 i * U (S, T, L).2.1 i * U (S, T, L).2.2 i) +
3 * (D (S, T, L).1 i * D (S, T, L).2.1 i * D (S, T, L).2.2 i) +
2 * (SMCharges.L (S, T, L).1 i * SMCharges.L (S, T, L).2.1 i * SMCharges.L (S, T, L).2.2 i) +
E (S, T, L).1 i * E (S, T, L).2.1 i * E (S, T, L).2.2 i) =
∑ i,
(6 * (Q (S, L, T).1 i * Q (S, L, T).2.1 i * Q (S, L, T).2.2 i) +
3 * (U (S, L, T).1 i * U (S, L, T).2.1 i * U (S, L, T).2.2 i) +
3 * (D (S, L, T).1 i * D (S, L, T).2.1 i * D (S, L, T).2.2 i) +
2 * (SMCharges.L (S, L, T).1 i * SMCharges.L (S, L, T).2.1 i * SMCharges.L (S, L, T).2.2 i) +
E (S, L, T).1 i * E (S, L, T).2.1 i * E (S, L, T).2.2 i)
intro S T L n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ i,
(6 * (Q (S, T, L).1 i * Q (S, T, L).2.1 i * Q (S, T, L).2.2 i) +
3 * (U (S, T, L).1 i * U (S, T, L).2.1 i * U (S, T, L).2.2 i) +
3 * (D (S, T, L).1 i * D (S, T, L).2.1 i * D (S, T, L).2.2 i) +
2 * (SMCharges.L (S, T, L).1 i * SMCharges.L (S, T, L).2.1 i * SMCharges.L (S, T, L).2.2 i) +
E (S, T, L).1 i * E (S, T, L).2.1 i * E (S, T, L).2.2 i) =
∑ i,
(6 * (Q (S, L, T).1 i * Q (S, L, T).2.1 i * Q (S, L, T).2.2 i) +
3 * (U (S, L, T).1 i * U (S, L, T).2.1 i * U (S, L, T).2.2 i) +
3 * (D (S, L, T).1 i * D (S, L, T).2.1 i * D (S, L, T).2.2 i) +
2 * (SMCharges.L (S, L, T).1 i * SMCharges.L (S, L, T).2.1 i * SMCharges.L (S, L, T).2.2 i) +
E (S, L, T).1 i * E (S, L, T).2.1 i * E (S, L, T).2.2 i)
simp only [toSpecies_apply, Fin.isValue] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∑ x,
(6 * (toSpeciesEquiv S 0 x * toSpeciesEquiv T 0 x * toSpeciesEquiv L 0 x) +
3 * (toSpeciesEquiv S 1 x * toSpeciesEquiv T 1 x * toSpeciesEquiv L 1 x) +
3 * (toSpeciesEquiv S 2 x * toSpeciesEquiv T 2 x * toSpeciesEquiv L 2 x) +
2 * (toSpeciesEquiv S 3 x * toSpeciesEquiv T 3 x * toSpeciesEquiv L 3 x) +
toSpeciesEquiv S 4 x * toSpeciesEquiv T 4 x * toSpeciesEquiv L 4 x) =
∑ x,
(6 * (toSpeciesEquiv S 0 x * toSpeciesEquiv L 0 x * toSpeciesEquiv T 0 x) +
3 * (toSpeciesEquiv S 1 x * toSpeciesEquiv L 1 x * toSpeciesEquiv T 1 x) +
3 * (toSpeciesEquiv S 2 x * toSpeciesEquiv L 2 x * toSpeciesEquiv T 2 x) +
2 * (toSpeciesEquiv S 3 x * toSpeciesEquiv L 3 x * toSpeciesEquiv T 3 x) +
toSpeciesEquiv S 4 x * toSpeciesEquiv L 4 x * toSpeciesEquiv T 4 x)
apply Fintype.sum_congr n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Charges⊢ ∀ (a : Fin (SMSpecies n).numberCharges),
6 * (toSpeciesEquiv S 0 a * toSpeciesEquiv T 0 a * toSpeciesEquiv L 0 a) +
3 * (toSpeciesEquiv S 1 a * toSpeciesEquiv T 1 a * toSpeciesEquiv L 1 a) +
3 * (toSpeciesEquiv S 2 a * toSpeciesEquiv T 2 a * toSpeciesEquiv L 2 a) +
2 * (toSpeciesEquiv S 3 a * toSpeciesEquiv T 3 a * toSpeciesEquiv L 3 a) +
toSpeciesEquiv S 4 a * toSpeciesEquiv T 4 a * toSpeciesEquiv L 4 a =
6 * (toSpeciesEquiv S 0 a * toSpeciesEquiv L 0 a * toSpeciesEquiv T 0 a) +
3 * (toSpeciesEquiv S 1 a * toSpeciesEquiv L 1 a * toSpeciesEquiv T 1 a) +
3 * (toSpeciesEquiv S 2 a * toSpeciesEquiv L 2 a * toSpeciesEquiv T 2 a) +
2 * (toSpeciesEquiv S 3 a * toSpeciesEquiv L 3 a * toSpeciesEquiv T 3 a) +
toSpeciesEquiv S 4 a * toSpeciesEquiv L 4 a * toSpeciesEquiv T 4 a
intro i n:ℕS:(SMCharges n).ChargesT:(SMCharges n).ChargesL:(SMCharges n).Chargesi:Fin (SMSpecies n).numberCharges⊢ 6 * (toSpeciesEquiv S 0 i * toSpeciesEquiv T 0 i * toSpeciesEquiv L 0 i) +
3 * (toSpeciesEquiv S 1 i * toSpeciesEquiv T 1 i * toSpeciesEquiv L 1 i) +
3 * (toSpeciesEquiv S 2 i * toSpeciesEquiv T 2 i * toSpeciesEquiv L 2 i) +
2 * (toSpeciesEquiv S 3 i * toSpeciesEquiv T 3 i * toSpeciesEquiv L 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv T 4 i * toSpeciesEquiv L 4 i =
6 * (toSpeciesEquiv S 0 i * toSpeciesEquiv L 0 i * toSpeciesEquiv T 0 i) +
3 * (toSpeciesEquiv S 1 i * toSpeciesEquiv L 1 i * toSpeciesEquiv T 1 i) +
3 * (toSpeciesEquiv S 2 i * toSpeciesEquiv L 2 i * toSpeciesEquiv T 2 i) +
2 * (toSpeciesEquiv S 3 i * toSpeciesEquiv L 3 i * toSpeciesEquiv T 3 i) +
toSpeciesEquiv S 4 i * toSpeciesEquiv L 4 i * toSpeciesEquiv T 4 i
ring All goals completed! 🐙)The cubic acc.
@[simp]
def accCube : HomogeneousCubic (SMCharges n).Charges := cubeTriLin.toCubic
Extensionality lemma for accCube.
set_option backward.isDefEq.respectTransparency false in
lemma accCube_ext {S T : (SMCharges n).Charges}
(h : ∀ j, ∑ i, ((fun a => a^3) ∘ toSpecies j S) i =
∑ i, ((fun a => a^3) ∘ toSpecies j T) i) :
accCube S = accCube T := by n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ accCube S = accCube T
simp only [HomogeneousCubic, accCube, cubeTriLin, TriLinearSymm.toCubic_apply,
TriLinearSymm.mk₃_toFun_apply_apply] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x,
(6 * (Q S x * Q S x * Q S x) + 3 * (U S x * U S x * U S x) + 3 * (D S x * D S x * D S x) +
2 * (L S x * L S x * L S x) +
E S x * E S x * E S x) =
∑ x,
(6 * (Q T x * Q T x * Q T x) + 3 * (U T x * U T x * U T x) + 3 * (D T x * D T x * D T x) +
2 * (L T x * L T x * L T x) +
E T x * E T x * E T x)
repeat rw [Finset.sum_add_distrib n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x,
(6 * (Q S x * Q S x * Q S x) + 3 * (U S x * U S x * U S x) + 3 * (D S x * D S x * D S x) +
2 * (L S x * L S x * L S x)) +
∑ x, E S x * E S x * E S x =
∑ x,
(6 * (Q T x * Q T x * Q T x) + 3 * (U T x * U T x * U T x) + 3 * (D T x * D T x * D T x) +
2 * (L T x * L T x * L T x) +
E T x * E T x * E T x) n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x, 6 * (Q S x * Q S x * Q S x) + ∑ x, 3 * (U S x * U S x * U S x) + ∑ x, 3 * (D S x * D S x * D S x) +
∑ x, 2 * (L S x * L S x * L S x) +
∑ x, E S x * E S x * E S x =
∑ x, 6 * (Q T x * Q T x * Q T x) + ∑ x, 3 * (U T x * U T x * U T x) + ∑ x, 3 * (D T x * D T x * D T x) +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x, 6 * (Q S x * Q S x * Q S x) + ∑ x, 3 * (U S x * U S x * U S x) + ∑ x, 3 * (D S x * D S x * D S x) +
∑ x, 2 * (L S x * L S x * L S x) +
∑ x, E S x * E S x * E S x =
∑ x, (6 * (Q T x * Q T x * Q T x) + 3 * (U T x * U T x * U T x)) + ∑ x, 3 * (D T x * D T x * D T x) +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x, 6 * (Q S x * Q S x * Q S x) + ∑ x, 3 * (U S x * U S x * U S x) + ∑ x, 3 * (D S x * D S x * D S x) +
∑ x, 2 * (L S x * L S x * L S x) +
∑ x, E S x * E S x * E S x =
∑ x, 6 * (Q T x * Q T x * Q T x) + ∑ x, 3 * (U T x * U T x * U T x) + ∑ x, 3 * (D T x * D T x * D T x) +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ ∑ x, 6 * (Q S x * Q S x * Q S x) + ∑ x, 3 * (U S x * U S x * U S x) + ∑ x, 3 * (D S x * D S x * D S x) +
∑ x, 2 * (L S x * L S x * L S x) +
∑ x, E S x * E S x * E S x =
∑ x, 6 * (Q T x * Q T x * Q T x) + ∑ x, 3 * (U T x * U T x * U T x) + ∑ x, 3 * (D T x * D T x * D T x) +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x
repeat rw [← Finset.mul_sum n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ 6 * ∑ i, Q S i * Q S i * Q S i + ∑ x, 3 * (U S x * U S x * U S x) + ∑ x, 3 * (D S x * D S x * D S x) +
∑ x, 2 * (L S x * L S x * L S x) +
∑ x, E S x * E S x * E S x =
∑ x, 6 * (Q T x * Q T x * Q T x) + ∑ x, 3 * (U T x * U T x * U T x) + ∑ x, 3 * (D T x * D T x * D T x) +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ 6 * ∑ i, Q S i * Q S i * Q S i + 3 * ∑ i, U S i * U S i * U S i + 3 * ∑ i, D S i * D S i * D S i +
2 * ∑ i, L S i * L S i * L S i +
∑ x, E S x * E S x * E S x =
6 * ∑ i, Q T i * Q T i * Q T i + 3 * ∑ i, U T i * U T i * U T i + 3 * ∑ i, D T i * D T i * D T i +
2 * ∑ i, L T i * L T i * L T i +
∑ x, E T x * E T x * E T x] n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ 6 * ∑ i, Q S i * Q S i * Q S i + 3 * ∑ i, U S i * U S i * U S i + 3 * ∑ i, D S i * D S i * D S i +
2 * ∑ i, L S i * L S i * L S i +
∑ x, E S x * E S x * E S x =
6 * ∑ i, Q T i * Q T i * Q T i + 3 * ∑ i, U T i * U T i * U T i + 3 * ∑ i, D T i * D T i * D T i +
∑ x, 2 * (L T x * L T x * L T x) +
∑ x, E T x * E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ 6 * ∑ i, Q S i * Q S i * Q S i + 3 * ∑ i, U S i * U S i * U S i + 3 * ∑ i, D S i * D S i * D S i +
2 * ∑ i, L S i * L S i * L S i +
∑ x, E S x * E S x * E S x =
6 * ∑ i, Q T i * Q T i * Q T i + 3 * ∑ i, U T i * U T i * U T i + 3 * ∑ i, D T i * D T i * D T i +
2 * ∑ i, L T i * L T i * L T i +
∑ x, E T x * E T x * E T x n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ 6 * ∑ i, Q S i * Q S i * Q S i + 3 * ∑ i, U S i * U S i * U S i + 3 * ∑ i, D S i * D S i * D S i +
2 * ∑ i, L S i * L S i * L S i +
∑ x, E S x * E S x * E S x =
6 * ∑ i, Q T i * Q T i * Q T i + 3 * ∑ i, U T i * U T i * U T i + 3 * ∑ i, D T i * D T i * D T i +
2 * ∑ i, L T i * L T i * L T i +
∑ x, E T x * E T x * E T x
ring_nf n:ℕS:(SMCharges n).ChargesT:(SMCharges n).Chargesh:∀ (j : Fin 5), ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) S) i = ∑ i, ((fun a => a ^ 3) ∘ (toSpecies j) T) i⊢ (∑ x, Q S x ^ 3) * 6 + (∑ x, U S x ^ 3) * 3 + (∑ x, D S x ^ 3) * 3 + (∑ x, L S x ^ 3) * 2 + ∑ x, E S x ^ 3 =
(∑ x, Q T x ^ 3) * 6 + (∑ x, U T x ^ 3) * 3 + (∑ x, D T x ^ 3) * 3 + (∑ x, L T x ^ 3) * 2 + ∑ x, E T x ^ 3
simp_all All goals completed! 🐙