Ask Your Question

How to find the longest word in a subgroup of the symmetric group using Sage?

asked 2020-04-12 15:25:40 -0500

lijr07 gravatar image

Let $S_n$ be the symmetric group over $\{1,2,\ldots,n\}$. Let $J$ be a subset of $\{1,\ldots, n-1\}$ and let $W_J$ be the subgroup of $S_n$ generated by $s_j, j\in J \subset \{1, \ldots, n-1\}$, where $s_j$'s are simple reflections. How to find the longest word in $W_J$ in Sage? The following is some codes.

W = SymmetricGroup(8)
[s1,s2,s3,s4,s5,s6,s7] = W.simple_reflections()

Thank you very much.

edit retag flag offensive close merge delete


Something like the following...?!

sage: S8 = SymmetricGroup(8)                                                                                                                                                                          
sage: S7 = SymmetricGroup(7)                                                                                                                                                                          
sage: S8( S7.long_element() )                                                                                                                                                                         
dan_fulea gravatar imagedan_fulea ( 2020-04-13 11:52:10 -0500 )edit

@lijr07 could you please provide a definition of longest word ?

tmonteil gravatar imagetmonteil ( 2020-04-13 14:17:20 -0500 )edit

1 answer

Sort by » oldest newest most voted

answered 2020-04-13 14:56:07 -0500

FrédéricC gravatar image

Here is a starting point. The rest is standard Coxeter theory.

sage: W = CoxeterGroup(['A',4])
sage: w = W.long_element()
sage: t = w.coset_representative([1,2])
edit flag offensive delete link more


@FrédéricC, thank you very much. I tried to use the following commands to find the longest word in $W_{J}$, $J=\{1,2\}$. But it doesn't give the answer $s_1 s_2 s_1$.

W = CoxeterGroup(['A',4])
w = W.long_element()
t = w.coset_representative([1,2])
lijr07 gravatar imagelijr07 ( 2020-04-13 17:24:52 -0500 )edit

You need to look at the other factor of the canonical factorisation

  sage: (~t*w).reduced_word()
  [1, 2, 1]
FrédéricC gravatar imageFrédéricC ( 2020-04-14 03:11:37 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2020-04-12 15:25:40 -0500

Seen: 40 times

Last updated: Apr 13