CoCalc Public Filespublic / constructing_irreps.sagews
Author: David Renshaw
Views : 85
Description: notes on Young Symmetrizers
Compute Environment: Ubuntu 20.04 (Default)
# Does g map each element in lst to another element in lst?
def stabilizes(g, lst):
for x in lst:
if lst.count(g(x)) == 0:
return False
return True

# Does g stabilize all parts of the standard tableau t?
def stabilizes_all(g, t):
for lst in t:
if not stabilizes(g, lst):
return False
return True

# See https://en.wikipedia.org/wiki/Young_symmetrizer
# t is a standard tableau
def young_symmetrizer(t):
G = SymmetricGroup(t.size())
A = GroupAlgebra(G, QQ)
a = A(0)
b = A(0)
for g in G:
if stabilizes_all(g, t):
a = a + A(g)
s = t.conjugate()
if stabilizes_all(g, s):
b = b + g.sign() * A(g)
return a * b

# Compute matrices for the representation given by a standard tableau t.
# Returns a dictionary, mapping group elements to matrices.
def compute_representation(t):
G = SymmetricGroup(t.size())
c = young_symmetrizer(t)
basis = [] # basis vectors
basis_in_algebra = [] # basis vectors as elements of the group algebra
for g in G:
z = g * c
zv = z.to_vector()
if Matrix(basis + [zv]).rank() > len(basis):
# not in the span yet
basis.append(zv)
basis_in_algebra.append(z)
basis_matrix = Matrix(basis)
g_to_m = {}
for g in G:
ms = []
# see what g does on each basis vector, and map it back to the basis's coordinates
for ba in basis_in_algebra:
ms.append(basis_matrix.transpose() \ (g * ba).to_vector())
msm = Matrix(ms).transpose()
g_to_m[g] = msm
return g_to_m



for t in StandardTableaux(4):
print("Tableau = {}".format(t))
g_to_m = compute_representation(t)
for (g,m) in g_to_m.items():
for (g1,m1) in g_to_m.items():
assert(g_to_m[g * g1] == m * m1)
print("OK")


Tableau = [[1, 2, 3, 4]] Tableau = [[1, 3, 4], [2]] Tableau = [[1, 2, 4], [3]] Tableau = [[1, 2, 3], [4]] Tableau = [[1, 3], [2, 4]] Tableau = [[1, 2], [3, 4]] Tableau = [[1, 4], [2], [3]] Tableau = [[1, 3], [2], [4]] Tableau = [[1, 2], [3], [4]] Tableau = [[1], [2], [3], [4]] OK
sage.misc.latex.EMBEDDED_MODE = True

g_to_m = compute_representation(StandardTableaux(4)([[1, 2, 3], [4]]))
to_display = []
for (g,m) in g_to_m.items():
# take inverse of g because Sage permutations act on the right
view(g.inverse()([1,2,3,4]), "-->", m)
print()


[$\displaystyle 1$, $\displaystyle 2$, $\displaystyle 3$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 4$, $\displaystyle 1$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & -1 \\ 1 & 0 & -1 \\ 0 & 0 & -1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 3$, $\displaystyle 2$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 1 \\ 0 & -1 & 0 \\ 1 & -1 & 0 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 1$, $\displaystyle 4$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 0 \\ -1 & 0 & 1 \\ -1 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 4$, $\displaystyle 2$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 1 & 0 \\ -1 & 0 & 0 \\ -1 & 0 & 1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 3$, $\displaystyle 1$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & -1 & 0 \\ 0 & -1 & 1 \\ 0 & -1 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 2$, $\displaystyle 4$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & -1 \\ 0 & 1 & -1 \\ 1 & 0 & -1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 1$, $\displaystyle 3$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & 1 \\ 1 & 0 & 0 \\ 0 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 3$, $\displaystyle 4$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 0 \\ 1 & -1 & 0 \\ 0 & -1 & 1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 2$, $\displaystyle 1$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 1 \\ -1 & 1 & 0 \\ -1 & 0 & 0 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 4$, $\displaystyle 3$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 1$, $\displaystyle 2$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & -1 \\ 0 & 0 & -1 \\ 0 & 1 & -1 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 2$, $\displaystyle 4$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 0 \\ -1 & 1 & 0 \\ -1 & 0 & 1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 3$, $\displaystyle 1$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 1 \\ 1 & -1 & 0 \\ 0 & -1 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 4$, $\displaystyle 2$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & -1 \\ 0 & 0 & -1 \\ 1 & 0 & -1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 1$, $\displaystyle 3$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & 0 \\ 0 & 0 & 1 \\ 0 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 3$, $\displaystyle 2$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & -1 & 0 \\ 0 & -1 & 0 \\ 0 & -1 & 1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 4$, $\displaystyle 1$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 1 & 0 \\ -1 & 0 & 1 \\ -1 & 0 & 0 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 2$, $\displaystyle 3$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & 1 \\ 0 & 1 & 0 \\ 1 & 0 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 1$, $\displaystyle 4$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & -1 \\ 1 & 0 & -1 \\ 0 & 1 & -1 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 4$, $\displaystyle 3$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & 0 \\ 1 & 0 & 0 \\ 0 & 0 & 1 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 2$, $\displaystyle 1$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & -1 \\ 0 & 1 & -1 \\ 0 & 0 & -1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 3$, $\displaystyle 4$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 0 \\ 0 & -1 & 1 \\ 1 & -1 & 0 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 1$, $\displaystyle 2$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 1 \\ -1 & 0 & 0 \\ -1 & 1 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 4$, $\displaystyle 1$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & -1 \\ 1 & 0 & -1 \\ 0 & 0 & -1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 3$, $\displaystyle 2$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 1 \\ 0 & -1 & 0 \\ 1 & -1 & 0 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 1$, $\displaystyle 4$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 0 \\ -1 & 0 & 1 \\ -1 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 4$, $\displaystyle 2$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 1 & 0 \\ -1 & 0 & 0 \\ -1 & 0 & 1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 3$, $\displaystyle 1$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & -1 & 0 \\ 0 & -1 & 1 \\ 0 & -1 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 2$, $\displaystyle 4$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & -1 \\ 0 & 1 & -1 \\ 1 & 0 & -1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 1$, $\displaystyle 3$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & 1 \\ 1 & 0 & 0 \\ 0 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 3$, $\displaystyle 4$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 0 \\ 1 & -1 & 0 \\ 0 & -1 & 1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 2$, $\displaystyle 1$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 1 \\ -1 & 1 & 0 \\ -1 & 0 & 0 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 4$, $\displaystyle 3$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 1$, $\displaystyle 2$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & -1 \\ 0 & 0 & -1 \\ 0 & 1 & -1 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 2$, $\displaystyle 4$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 0 \\ -1 & 1 & 0 \\ -1 & 0 & 1 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 3$, $\displaystyle 1$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 1 \\ 1 & -1 & 0 \\ 0 & -1 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 4$, $\displaystyle 2$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & -1 \\ 0 & 0 & -1 \\ 1 & 0 & -1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 1$, $\displaystyle 3$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & 0 \\ 0 & 0 & 1 \\ 0 & 1 & 0 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 3$, $\displaystyle 2$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & -1 & 0 \\ 0 & -1 & 0 \\ 0 & -1 & 1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 4$, $\displaystyle 1$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 1 & 0 \\ -1 & 0 & 1 \\ -1 & 0 & 0 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 2$, $\displaystyle 3$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & 1 \\ 0 & 1 & 0 \\ 1 & 0 & 0 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 1$, $\displaystyle 4$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 0 & -1 \\ 1 & 0 & -1 \\ 0 & 1 & -1 \end{array}\right)$
[$\displaystyle 1$, $\displaystyle 4$, $\displaystyle 3$, $\displaystyle 2$] --> $\displaystyle \left(\begin{array}{rrr} 0 & 1 & 0 \\ 1 & 0 & 0 \\ 0 & 0 & 1 \end{array}\right)$
[$\displaystyle 3$, $\displaystyle 2$, $\displaystyle 1$, $\displaystyle 4$] --> $\displaystyle \left(\begin{array}{rrr} 1 & 0 & -1 \\ 0 & 1 & -1 \\ 0 & 0 & -1 \end{array}\right)$
[$\displaystyle 2$, $\displaystyle 3$, $\displaystyle 4$, $\displaystyle 1$] --> $\displaystyle \left(\begin{array}{rrr} 0 & -1 & 0 \\ 0 & -1 & 1 \\ 1 & -1 & 0 \end{array}\right)$
[$\displaystyle 4$, $\displaystyle 1$, $\displaystyle 2$, $\displaystyle 3$] --> $\displaystyle \left(\begin{array}{rrr} -1 & 0 & 1 \\ -1 & 0 & 0 \\ -1 & 1 & 0 \end{array}\right)$