# How to compute the stabilizer subgroup of a partition with GAP?

A partition $$P$$ of a set $$S$$ is a set of disjoint subsets of $$S$$ whose union is $$S$$. Let $$G$$ be a subgroup of the symmetric group $$S_n$$. Define the stabilizer subgroup of $$G$$ for a partition $$P$$ of $$\{1,2, \dots , n\}$$ by $$G_P:= \{g \in G \ | \ gP=P \}$$ where $$gP:= \{ \{ga \ | \ a \in p \} \ | \ p \in P \}$$.

Question: How to compute explicitly $$G_P$$ with GAP?

• Such a stabilizer should just be the direct product of smaller symmetric groups right? If we write a stabilizer element in cycle notation, each cycle should contain only elements of a set in the partition. – Rylee Lyman Aug 13 at 23:57
• @RyleeLyman No, since a partition is defined as set of sets, the sets could be permuted, so it is (if all sets have the same size) the intersection with a wreath product. – ahulpke Aug 14 at 3:21

Generically it would be a stabilizer

Stabilizer(G,P,OnSetsDisjointSets);


(assuming that $$P$$ is a set of sets in the GAP sense). IIRC this has been introduced only in recent releases, but the underlying function PartitionStabilizerPermGroup(G,P) has been around for longer. The calculation involves a backtrack search, and probably offers many possibilities for improvement.

• I just used your answer in the following answer: mathoverflow.net/a/338339/34538 at the end of which there is a computation my computer was not able to do. If yours can do it, I would be very interested. – Sebastien Palcoux Aug 14 at 14:51