Suppose $\chi$ is a character of group $G$, how to compute $\chi(g)$ in GAP? For instance, for G := DihedralGroup(30), I want to compute the values of Irr(G)[2] for any elements of G.


To compute the value of a character, one can use the ^ operator. For example

gap> G:=DihedralGroup(30);
<pc group of size 30 with 3 generators>
gap> phi:=Irr(G)[2];
Character( CharacterTable( <pc group of size 30 with 3 generators> ), 
[ 1, -1, 1, 1, 1, 1, 1, 1, 1 ] )
gap> g:=Random(G);
gap> g^phi;
gap> g:=Random(G);
gap> g^phi;

The corresponding section of the GAP manual could be found by entering ??Character value in GAP:

gap> ??Character value                                                
Help: several entries match this topic - type ?2 to get match [2]

[1] Reference: character value of group element using powering operator
[2] Wedderga (not loaded): field of character values
  • $\begingroup$ @H.Shabani: does this answer your question, or do you need more help? $\endgroup$ – Alexander Konovalov Dec 15 '13 at 21:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.